| | |
| | | return newStriveForFeign.editProjectPlanData(item); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "项目规划确认完工") |
| | | @PostMapping("/editProjectPlanAccomplish") |
| | | public R editProjectPlanAccomplish(@RequestParam("id") String id) |
| | | { |
| | | NewFightProjectPlanDTO item =new NewFightProjectPlanDTO(); |
| | | item.setId(id); |
| | | item.setAffirmTime(new Date()); |
| | | item.setAccomplish("1"); |
| | | return newStriveForFeign.editProjectPlanData(item); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "项目规划删除") |
| | | @DeleteMapping("/expurgateProjectPlanData") |
| | | public R expurgateProjectPlanData(@RequestParam("id") String id) |
| | |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date updateTime; |
| | | |
| | | @ApiModelProperty("确认完工时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date affirmTime; |
| | | |
| | | @ApiModelProperty("是否完成 0未完成 1完成") |
| | | private String accomplish; |
| | | |
| | | } |
| | |
| | | @DeleteMapping("/expurgateProjectPlanData") |
| | | public R expurgateProjectPlanData(@RequestParam("id") String id) |
| | | { |
| | | return projectPlanService.expurgateData(id); |
| | | return projectPlanService.expurgateData(id,null); |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | int editData(@Param("item") NewFightProjectPlanDTO userId); |
| | | |
| | | int expurgateData(@Param("id") String id); |
| | | int expurgateData(@Param("id") String id,@Param("projectId") String projectId); |
| | | |
| | | } |
| | |
| | | |
| | | R editData(NewFightProjectPlanDTO item); |
| | | |
| | | R expurgateData(String id); |
| | | R expurgateData(String id,String projectId); |
| | | |
| | | } |
| | |
| | | int num=baseMapper.editData(item); |
| | | if(num>0) |
| | | { |
| | | if(item.getList()!=null && item.getList().size()>0 ) |
| | | { |
| | | for (NewFightProjectPlanDTO dto:item.getList()) |
| | | { |
| | | if(StringUtils.isEmpty(dto.getId())) |
| | | { |
| | | return R.fail("项目规划进度id不能为空"); |
| | | } |
| | | projectPlanService.editData(dto); |
| | | } |
| | | } |
| | | return R.ok(); |
| | | } |
| | | return R.fail("操作失败"); |
| | |
| | | int num= baseMapper.expurgateData(id); |
| | | if(num>0) |
| | | { |
| | | //删除相关项目规划进度 |
| | | projectPlanService.expurgateData(null,id); |
| | | return R.ok(); |
| | | } |
| | | return R.fail("操作失败"); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R expurgateData(String id) |
| | | public R expurgateData(String id,String projectId) |
| | | { |
| | | int num= baseMapper.expurgateData(id); |
| | | int num= baseMapper.expurgateData(id,projectId); |
| | | if(num>0) |
| | | { |
| | | return R.ok(); |
| | |
| | | service_time, |
| | | unit_id, |
| | | creation_time, |
| | | update_time |
| | | update_time, |
| | | |
| | | </sql> |
| | | |
| | | |
| | |
| | | <if test="item.unitId !=null and item.unitId != '' "> |
| | | unit_id, |
| | | </if> |
| | | |
| | | creation_time |
| | | </trim> |
| | | values |
| | |
| | | <if test="item.unitId !=null and item.unitId != '' "> |
| | | #{item.unitId}, |
| | | </if> |
| | | |
| | | sysdate() |
| | | </trim> |
| | | </insert> |
| | |
| | | <if test="item.unitId !=null and item.unitId != '' "> |
| | | unit_id=#{item.unitId}, |
| | | </if> |
| | | |
| | | update_time=sysdate() |
| | | </set> |
| | | where id = #{item.id} |
| | |
| | | completion_time, |
| | | plan_content, |
| | | creation_time, |
| | | update_time |
| | | |
| | | update_time, |
| | | affirm_time, |
| | | accomplish |
| | | </sql> |
| | | |
| | | <select id="getList" resultType="com.panzhihua.common.model.dtos.partybuilding.NewFightProjectPlanDTO"> |
| | |
| | | <if test="item.planContent != null and item.planContent != '' " > |
| | | plan_content, |
| | | </if> |
| | | <if test="item.affirmTime !=null and item.affirmTime != '' "> |
| | | affirm_time, |
| | | </if> |
| | | <if test="item.accomplish !=null and item.accomplish != '' "> |
| | | accomplish, |
| | | </if> |
| | | creation_time |
| | | </trim> |
| | | values |
| | |
| | | </if> |
| | | <if test="item.planContent != null and item.planContent != '' " > |
| | | #{item.planContent}, |
| | | </if> |
| | | <if test="item.affirmTime !=null and item.affirmTime != '' "> |
| | | #{item.affirmTime}, |
| | | </if> |
| | | <if test="item.accomplish !=null and item.accomplish != '' "> |
| | | #{item.accomplish}, |
| | | </if> |
| | | sysdate() |
| | | </trim> |
| | |
| | | <if test="item.planContent != null and item.planContent != '' " > |
| | | plan_content=#{item.planContent}, |
| | | </if> |
| | | <if test="item.affirmTime !=null and item.affirmTime != '' "> |
| | | affirm_time=#{item.affirmTime}, |
| | | </if> |
| | | <if test="item.accomplish !=null and item.accomplish != '' "> |
| | | accomplish=#{item.accomplish}, |
| | | </if> |
| | | update_time=sysdate() |
| | | </set> |
| | | where id = #{item.id} |
| | | </update> |
| | | |
| | | <delete id="expurgateData" parameterType="String"> |
| | | delete from new_fight_project_plan where id=#{id} |
| | | delete from new_fight_project_plan |
| | | <where> |
| | | 1=1 |
| | | <if test="id!=null and id !='' "> |
| | | and id=#{id} |
| | | </if> |
| | | <if test="projectId!=null and projectId !='' "> |
| | | and project_id=#{projectId} |
| | | </if> |
| | | </where> |
| | | </delete> |
| | | |
| | | |