动火作业添加电子围栏

pull/4/head
fangjiakai 2024-01-25 16:00:38 +08:00
parent f23f7f09d6
commit 563a0cbd3a
6 changed files with 48 additions and 9 deletions

View File

@ -1,6 +1,7 @@
package com.zcloud.controller.eightwork; package com.zcloud.controller.eightwork;
import com.alibaba.fastjson.JSONObject;
import com.zcloud.controller.base.BaseController; import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page; import com.zcloud.entity.Page;
import com.zcloud.entity.PageData; import com.zcloud.entity.PageData;
@ -135,4 +136,28 @@ public class AppEightWorkController extends BaseController {
map.put("result",errorInfo); map.put("result",errorInfo);
return map; return map;
} }
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/25/025 9:02
* @Param: [com.zcloud.entity.Page] [page]
* @Return: java.lang.Object
*/
@RequestMapping(value = "/getPlsList")
@ResponseBody
public Object getPlsList(Page page) throws Exception {
ReturnMap returnMap = new ReturnMap();
PageData pd = new PageData();
pd = this.getPageData();
JSONObject body = PLSUtil.getRyRegionList(pd.getString("CORPINFO_ID"),"",1,99999);
if (body != null) {
List<JSONObject> list = body.getJSONArray("rows").toJavaList(JSONObject.class);
returnMap.put("varList", list);
returnMap.put("page", page);
return returnMap;
}
return ReturnMap.error("查询失败");
}
} }

View File

@ -12,4 +12,6 @@ public interface EightWorkTaskMapper {
* @throws Exception * @throws Exception
*/ */
void save(PageData pd); void save(PageData pd);
PageData checkWorkCount(PageData pd);
} }

View File

@ -2,8 +2,7 @@ package com.zcloud.service.eightwork.impl;
import com.zcloud.entity.Page; import com.zcloud.entity.Page;
import com.zcloud.entity.PageData; import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.eightwork.EightWorkFlowLogMapper; import com.zcloud.mapper.datasource.eightwork.*;
import com.zcloud.mapper.datasource.eightwork.EightWorkTaskFlowMapper;
import com.zcloud.service.eightwork.EightWorkService; import com.zcloud.service.eightwork.EightWorkService;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
@ -22,7 +21,7 @@ public class EightWorkServiceImpl implements EightWorkService {
@Autowired @Autowired
private EightWorkTaskFlowMapper eightWorkTaskFlowMapper; private EightWorkTaskFlowMapper eightWorkTaskFlowMapper;
@Autowired @Autowired
private EightWorkFlowLogMapper eightWorkFlowLogMapper; private EightWorkTaskMapper eightWorkTaskMapper;
@Autowired @Autowired
private EightWorkMapper eightworkMapper; private EightWorkMapper eightworkMapper;
@ -34,7 +33,7 @@ public class EightWorkServiceImpl implements EightWorkService {
@Override @Override
public PageData checkWork(PageData pd) { public PageData checkWork(PageData pd) {
return null; return eightWorkTaskMapper.checkWorkCount(pd);
} }
/** /**

View File

@ -273,6 +273,7 @@ public class HotworkServiceImpl implements HotworkService {
sign.put("DESCR", pd.get("DESCR")); sign.put("DESCR", pd.get("DESCR"));
hotworkSignMapper.edit(sign); hotworkSignMapper.edit(sign);
//保存日志 //保存日志
work.put("STEP_ID", flow.get("NEXT_STEP_ID"));
saveLog(work,pd.getString("USER_ID"),"-2"); saveLog(work,pd.getString("USER_ID"),"-2");
work.put("STEP_ID",-1); work.put("STEP_ID",-1);
hotworkMapper.editStep(work); hotworkMapper.editStep(work);

View File

@ -41,4 +41,8 @@
) )
</insert> </insert>
<select id="checkWorkCount" parameterType="pd" resultType="pd" >
select (select count(1) COUNT from bus_hotwork_sign sign where sign.SIGN_TIME is null and sign.SIGN_USER_ID = #{USER_ID}) HOTWORK_COUNT
</select>
</mapper> </mapper>

View File

@ -54,7 +54,9 @@
f.WORK_START_USER_ID, f.WORK_START_USER_ID,
f.WORK_END_DEPARTMENT_ID, f.WORK_END_DEPARTMENT_ID,
f.WORK_END_USER_ID, f.WORK_END_USER_ID,
f.ACCEPT_TIME f.ACCEPT_TIME,
f.PLS_ID,
f.PLS_NAME
</sql> </sql>
<!-- 字段用于新增 --> <!-- 字段用于新增 -->
@ -105,7 +107,9 @@
WORK_START_USER_ID, WORK_START_USER_ID,
WORK_END_DEPARTMENT_ID, WORK_END_DEPARTMENT_ID,
WORK_END_USER_ID, WORK_END_USER_ID,
ACCEPT_TIME ACCEPT_TIME,
PLS_ID,
PLS_NAME
</sql> </sql>
<!-- 字段值 --> <!-- 字段值 -->
@ -156,7 +160,9 @@
#{WORK_START_USER_ID}, #{WORK_START_USER_ID},
#{WORK_END_DEPARTMENT_ID}, #{WORK_END_DEPARTMENT_ID},
#{WORK_END_USER_ID}, #{WORK_END_USER_ID},
#{ACCEPT_TIME} #{ACCEPT_TIME},
#{PLS_ID},
#{PLS_NAME}
</sql> </sql>
<!-- 获取编码 --> <!-- 获取编码 -->
@ -236,7 +242,9 @@
WORK_START_USER_ID=#{WORK_START_USER_ID}, WORK_START_USER_ID=#{WORK_START_USER_ID},
WORK_END_DEPARTMENT_ID=#{WORK_END_DEPARTMENT_ID}, WORK_END_DEPARTMENT_ID=#{WORK_END_DEPARTMENT_ID},
WORK_END_USER_ID=#{WORK_END_USER_ID}, WORK_END_USER_ID=#{WORK_END_USER_ID},
ACCEPT_TIME = #{ACCEPT_TIME} ACCEPT_TIME = #{ACCEPT_TIME},
PLS_ID = #{PLS_ID},
PLS_NAME = #{PLS_NAME}
where where
HOTWORK_ID = #{HOTWORK_ID} HOTWORK_ID = #{HOTWORK_ID}
</update> </update>
@ -471,7 +479,7 @@
) )
</if> </if>
<if test="pd.STEP_ID != null and pd.STEP_ID != ''"><!-- 关键词检索 --> <if test="pd.STEP_ID != null and pd.STEP_ID != ''"><!-- 关键词检索 -->
and log.NEXT_STEP_ID = #{pd.STEP_ID} and log.NEXT_STEP_ID = #{pd.STEP_ID} and f.STEP_ID != -1
</if> </if>
<if test="pd.CREATOR != null and pd.CREATOR != ''"><!-- 关键词检索 --> <if test="pd.CREATOR != null and pd.CREATOR != ''"><!-- 关键词检索 -->
and f.CREATOR = #{pd.CREATOR} and f.CREATOR = #{pd.CREATOR}