Compare commits
4 Commits
9a41479bec
...
f3735dbced
Author | SHA1 | Date |
---|---|---|
|
f3735dbced | |
|
7820a68145 | |
|
c02f15dc7b | |
|
248f3e1042 |
|
@ -25,6 +25,17 @@ public class PageUtils extends PageHelper
|
||||||
PageHelper.startPage(pageNum, pageSize, orderBy).setReasonable(reasonable);
|
PageHelper.startPage(pageNum, pageSize, orderBy).setReasonable(reasonable);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置请求分页数据
|
||||||
|
*/
|
||||||
|
public static void startPage(Integer pageNum, Integer pageSize)
|
||||||
|
{
|
||||||
|
PageDomain pageDomain = TableSupport.buildPageRequest();
|
||||||
|
String orderBy = SqlUtil.escapeOrderBySql(pageDomain.getOrderBy());
|
||||||
|
Boolean reasonable = pageDomain.getReasonable();
|
||||||
|
PageHelper.startPage(pageNum, pageSize, orderBy).setReasonable(reasonable);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 清理分页的线程变量
|
* 清理分页的线程变量
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -49,6 +49,14 @@ public class BaseController
|
||||||
PageUtils.startPage();
|
PageUtils.startPage();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置请求分页数据
|
||||||
|
*/
|
||||||
|
protected void startPage(Integer pageNum, Integer pageSize)
|
||||||
|
{
|
||||||
|
PageUtils.startPage(pageNum,pageSize);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 清理分页的线程变量
|
* 清理分页的线程变量
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -145,6 +145,10 @@ public class SmzSspProblemmodify extends BaseEntity
|
||||||
@Excel(name = "问题类型", readConverterExp = "1=常规问题,2专项问题")
|
@Excel(name = "问题类型", readConverterExp = "1=常规问题,2专项问题")
|
||||||
private String problemType;
|
private String problemType;
|
||||||
|
|
||||||
|
private String problemTypeName;
|
||||||
|
private String dangerTypeName;
|
||||||
|
private String createUserName;
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
|
@ -434,6 +438,30 @@ public class SmzSspProblemmodify extends BaseEntity
|
||||||
return problemType;
|
return problemType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getProblemTypeName() {
|
||||||
|
return problemTypeName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setProblemTypeName(String problemTypeName) {
|
||||||
|
this.problemTypeName = problemTypeName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDangerTypeName() {
|
||||||
|
return dangerTypeName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDangerTypeName(String dangerTypeName) {
|
||||||
|
this.dangerTypeName = dangerTypeName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCreateUserName() {
|
||||||
|
return createUserName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCreateUserName(String createUserName) {
|
||||||
|
this.createUserName = createUserName;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
|
|
@ -153,7 +153,7 @@
|
||||||
|
|
||||||
<!--查询我的已办任务-->
|
<!--查询我的已办任务-->
|
||||||
<select id="selectMySubdeptsGroups" resultType="Map">
|
<select id="selectMySubdeptsGroups" resultType="Map">
|
||||||
select id, sub_dept_group from pro_project_info_subdepts_users where project_id = #{proId} and user_id = #{userId} and user_post = 3 and approve_status <![CDATA[ >= ]]> 100 and is_del=0 and sub_dept_group is not null
|
select id, sub_dept_name, sub_dept_group, user_post from pro_project_info_subdepts_users where project_id = #{proId} and user_id = #{userId} and approve_status <![CDATA[ >= ]]> 100 and is_del=0 and sub_dept_group is not null
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
|
@ -405,7 +405,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="comId != null "> and pi.com_id = #{comId}</if>
|
<if test="comId != null "> and pi.com_id = #{comId}</if>
|
||||||
<if test="disDeptId != null "> and pi.dis_dept_id = #{disDeptId}</if>
|
<if test="disDeptId != null "> and pi.dis_dept_id = #{disDeptId}</if>
|
||||||
<if test="activeComId != null "> and pi.com_id = #{activeComId}</if>
|
<if test="activeComId != null "> and pi.com_id = #{activeComId}</if>
|
||||||
<if test="currentUserId != null"> and psu.user_id = #{currentUserId} and psu.approve_status <![CDATA[ >= ]]> 100 and psu.user_id = #{currentUserId} and psu.use_status='0' and psu.is_del=0</if>
|
<if test="currentUserId != null"> and psu.user_id = #{currentUserId} and psu.approve_status <![CDATA[ >= ]]> 100 and psu.use_status='0' and psu.is_del=0</if>
|
||||||
<if test="projectName != null and projectName != ''"> and pi.project_name like concat('%', #{projectName}, '%')</if>
|
<if test="projectName != null and projectName != ''"> and pi.project_name like concat('%', #{projectName}, '%')</if>
|
||||||
<if test="projectCode != null and projectCode != ''"> and pi.project_code = #{projectCode}</if>
|
<if test="projectCode != null and projectCode != ''"> and pi.project_code = #{projectCode}</if>
|
||||||
<if test="simpleName != null and simpleName != ''"> and pi.simple_name like concat('%', #{simpleName}, '%')</if>
|
<if test="simpleName != null and simpleName != ''"> and pi.simple_name like concat('%', #{simpleName}, '%')</if>
|
||||||
|
|
|
@ -96,7 +96,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="userPhone != null and userPhone != ''"> and psu.user_phone = #{userPhone}</if>
|
<if test="userPhone != null and userPhone != ''"> and psu.user_phone = #{userPhone}</if>
|
||||||
<if test='activeTags == "finished"'> and psu.approve_status <![CDATA[ >= ]]> 100 </if>
|
<if test='activeTags == "finished"'> and psu.approve_status <![CDATA[ >= ]]> 100 </if>
|
||||||
<if test="isDel != null "> and psu.is_del = #{isDel}</if>
|
<if test="isDel != null "> and psu.is_del = #{isDel}</if>
|
||||||
<if test='searchValue == "active1"'> and psu.user_post != '66' </if>
|
<if test='searchValue == "subUsers"'> and psu.user_post != '66' </if>
|
||||||
|
<if test='searchValue == "sedUsers"'> and psu.sub_dept_type in ('1','4','5') and psu.user_post not in ('4','5') </if>
|
||||||
<if test="params.beginTime != null and params.beginTime != '' and params.endTime != null and params.endTime != ''"> and date(psu.use_date) between #{params.beginTime} and #{params.endTime}</if>
|
<if test="params.beginTime != null and params.beginTime != '' and params.endTime != null and params.endTime != ''"> and date(psu.use_date) between #{params.beginTime} and #{params.endTime}</if>
|
||||||
and psu.is_del != 2
|
and psu.is_del != 2
|
||||||
</where>
|
</where>
|
||||||
|
|
|
@ -92,18 +92,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<!--查询角色相关菜单-->
|
<!--查询角色相关菜单-->
|
||||||
<select id="findUserMenuList" parameterType="WxMenuConfig" resultMap="WxMenuConfigResult">
|
<select id="findUserMenuList" parameterType="WxMenuConfig" resultMap="WxMenuConfigResult">
|
||||||
SELECT
|
select
|
||||||
DISTINCT smc.id,
|
distinct smc.id,
|
||||||
smc.menu_name,
|
smc.menu_name,
|
||||||
smc.menu_identi,
|
smc.menu_identi,
|
||||||
smc.menu_img,
|
smc.menu_img,
|
||||||
smc.menu_url,
|
smc.menu_url,
|
||||||
smc.menu_sort
|
smc.menu_sort
|
||||||
FROM
|
from
|
||||||
wx_menu_config smc
|
wx_menu_config smc
|
||||||
LEFT JOIN wx_menu_config_role smcr ON smcr.smcid = smc.id
|
left join wx_menu_config_role smcr on smcr.smcid = smc.id
|
||||||
LEFT JOIN sys_user_role ur ON ur.role_id = smcr.role_id
|
left join sys_user_role ur on ur.role_id = smcr.role_id
|
||||||
WHERE smc.del_flag = 0
|
where smc.del_flag = 0
|
||||||
and (ur.user_id = #{currentUserId} or smcr.user_id = #{currentUserId})
|
and (ur.user_id = #{currentUserId} or smcr.user_id = #{currentUserId})
|
||||||
<if test="activeProjectId != null"> and smc.project_id = #{activeProjectId}</if>
|
<if test="activeProjectId != null"> and smc.project_id = #{activeProjectId}</if>
|
||||||
<if test="menuType != null and menuType != ''"> and smc.menu_type = #{menuType}</if>
|
<if test="menuType != null and menuType != ''"> and smc.menu_type = #{menuType}</if>
|
||||||
|
|
|
@ -31,62 +31,99 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<result property="smarkUrl" column="smark_url" />
|
<result property="smarkUrl" column="smark_url" />
|
||||||
<result property="isDel" column="isDel" />
|
<result property="isDel" column="isDel" />
|
||||||
<result property="createUser" column="createUser" />
|
<result property="createUser" column="createUser" />
|
||||||
|
<result property="createUserName" column="createUserName" />
|
||||||
<result property="createTime" column="createTime" />
|
<result property="createTime" column="createTime" />
|
||||||
<result property="updateUser" column="updateUser" />
|
<result property="updateUser" column="updateUser" />
|
||||||
<result property="updateTime" column="updateTime" />
|
<result property="updateTime" column="updateTime" />
|
||||||
<result property="dangerType" column="danger_type" />
|
<result property="dangerType" column="danger_type" />
|
||||||
|
<result property="dangerTypeName" column="danger_type_name" />
|
||||||
<result property="recheckSend" column="recheckSend" />
|
<result property="recheckSend" column="recheckSend" />
|
||||||
<result property="recheckSendUser" column="recheckSendUser" />
|
<result property="recheckSendUser" column="recheckSendUser" />
|
||||||
<result property="roleType" column="roleType" />
|
<result property="roleType" column="roleType" />
|
||||||
<result property="problemType" column="problemType" />
|
<result property="problemType" column="problemType" />
|
||||||
|
<result property="problemTypeName" column="problemTypeName" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectSmzSspProblemmodifyVo">
|
<sql id="selectSmzSspProblemmodifyVo">
|
||||||
select id, comId, projectId, infoType, marks_picture, marks_video, correction_picture, problemArea, workParts, changeInfo, lordSent, lordSentUser, copySend, copySendUser, checkState, nickedArea, nickedTime, projectType, processName, projectName, nickedInfo, checkUser, checkUserPhone, smark_url, isDel, createUser, createTime, updateUser, updateTime, danger_type, recheckSend, recheckSendUser, roleType, problemType from smz_ssp_problemmodify
|
select
|
||||||
|
ssp.id,
|
||||||
|
ssp.comId,
|
||||||
|
ssp.projectId,
|
||||||
|
ssp.infoType,
|
||||||
|
ssp.marks_picture,
|
||||||
|
ssp.marks_video,
|
||||||
|
ssp.correction_picture,
|
||||||
|
ssp.problemArea,
|
||||||
|
ssp.workParts,
|
||||||
|
ssp.changeInfo,
|
||||||
|
ssp.lordSent,
|
||||||
|
ssp.lordSentUser,
|
||||||
|
ssp.copySend,
|
||||||
|
ssp.copySendUser,
|
||||||
|
ssp.checkState,
|
||||||
|
ssp.nickedArea,
|
||||||
|
ssp.nickedTime,
|
||||||
|
ssp.projectType,
|
||||||
|
ssp.processName,
|
||||||
|
ssp.projectName,
|
||||||
|
ssp.nickedInfo,
|
||||||
|
ssp.checkUser,
|
||||||
|
ssp.checkUserPhone,
|
||||||
|
ssp.smark_url,
|
||||||
|
ssp.isDel,
|
||||||
|
ssp.createUser,
|
||||||
|
su.nick_name as createUserName
|
||||||
|
ssp.createTime,
|
||||||
|
ssp.updateUser,
|
||||||
|
ssp.updateTime,
|
||||||
|
ssp.danger_type,
|
||||||
|
sdd2.dict_label AS danger_type_name,
|
||||||
|
ssp.recheckSend,
|
||||||
|
ssp.recheckSendUser,
|
||||||
|
ssp.roleType,
|
||||||
|
ssp.problemType,
|
||||||
|
sdd1.dict_label AS problemTypeName
|
||||||
|
from
|
||||||
|
smz_ssp_problemmodify ssp
|
||||||
|
left join sys_dict_data sdd1 on sdd1.dict_type = 'ssp_proble_type'
|
||||||
|
and sdd1.dict_value = ssp.problemType
|
||||||
|
left join sys_dict_data sdd2 on sdd2.dict_type = 'ssp_proble_sub_type'
|
||||||
|
and sdd2.dict_value = ssp.danger_type
|
||||||
|
left join sys_user su on su.user_id = ssp.createUser
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectSmzSspProblemmodifyList" parameterType="SmzSspProblemmodify" resultMap="SmzSspProblemmodifyResult">
|
<select id="selectSmzSspProblemmodifyList" parameterType="SmzSspProblemmodify" resultMap="SmzSspProblemmodifyResult">
|
||||||
<include refid="selectSmzSspProblemmodifyVo"/>
|
<include refid="selectSmzSspProblemmodifyVo"/>
|
||||||
<where>
|
<where>
|
||||||
<if test="comId != null "> and comId = #{comId}</if>
|
<if test="comId != null "> and ssp.comId = #{comId}</if>
|
||||||
<if test="projectId != null "> and projectId = #{projectId}</if>
|
<if test="projectId != null "> and ssp.projectId = #{projectId}</if>
|
||||||
<if test="infoType != null "> and infoType = #{infoType}</if>
|
<if test="infoType != null "> and ssp.infoType = #{infoType}</if>
|
||||||
<if test="marksPicture != null and marksPicture != ''"> and marks_picture = #{marksPicture}</if>
|
<if test="lordSent != null and lordSent != ''"> and ssp.lordSent = #{lordSent}</if>
|
||||||
<if test="marksVideo != null and marksVideo != ''"> and marks_video = #{marksVideo}</if>
|
<if test="lordSentUser != null and lordSentUser != ''"> and ssp.lordSentUser = #{lordSentUser}</if>
|
||||||
<if test="correctionPicture != null and correctionPicture != ''"> and correction_picture = #{correctionPicture}</if>
|
<if test="copySend != null and copySend != ''"> and find_in_set(#{copySend},ssp.copySend)</if>
|
||||||
<if test="problemArea != null and problemArea != ''"> and problemArea = #{problemArea}</if>
|
<if test="copySendUser != null and copySendUser != ''"> and find_in_set(#{copySendUser},ssp.copySendUser)</if>
|
||||||
<if test="workParts != null and workParts != ''"> and workParts = #{workParts}</if>
|
<if test="checkState != null "> and ssp.checkState = #{checkState}</if>
|
||||||
<if test="changeInfo != null and changeInfo != ''"> and changeInfo = #{changeInfo}</if>
|
<if test="checkUser != null and checkUser != ''"> and ssp.checkUser = #{checkUser}</if>
|
||||||
<if test="lordSent != null and lordSent != ''"> and lordSent = #{lordSent}</if>
|
<if test="checkUserPhone != null and checkUserPhone != ''"> and ssp.checkUserPhone = #{checkUserPhone}</if>
|
||||||
<if test="lordSentUser != null and lordSentUser != ''"> and lordSentUser = #{lordSentUser}</if>
|
<if test="createUser != null and createUser != ''"> and ssp.createUser = #{createUser}</if>
|
||||||
<if test="copySend != null and copySend != ''"> and copySend = #{copySend}</if>
|
<if test="dangerType != null and dangerType != ''"> and ssp.danger_type = #{dangerType}</if>
|
||||||
<if test="copySendUser != null and copySendUser != ''"> and copySendUser = #{copySendUser}</if>
|
<if test="recheckSend != null and recheckSend != ''"> and ssp.recheckSend = #{recheckSend}</if>
|
||||||
<if test="checkState != null "> and checkState = #{checkState}</if>
|
<if test="recheckSendUser != null and recheckSendUser != ''"> and ssp.recheckSendUser = #{recheckSendUser}</if>
|
||||||
<if test="nickedArea != null and nickedArea != ''"> and nickedArea = #{nickedArea}</if>
|
<if test="problemType != null and problemType != ''"> and ssp.problemType = #{problemType}</if>
|
||||||
<if test="nickedTime != null "> and nickedTime = #{nickedTime}</if>
|
<if test="currentUserId != null and currentUserId!=''">
|
||||||
<if test="projectType != null and projectType != ''"> and projectType = #{projectType}</if>
|
and
|
||||||
<if test="processName != null and processName != ''"> and processName like concat('%', #{processName}, '%')</if>
|
(
|
||||||
<if test="projectName != null and projectName != ''"> and projectName like concat('%', #{projectName}, '%')</if>
|
ssp.createUser=#{currentUserId} or ssp.lordSent=#{currentUserId} or find_in_set(#{currentUserId},ssp.copySend) or ssp.recheckSend=#{currentUserId}
|
||||||
<if test="nickedInfo != null and nickedInfo != ''"> and nickedInfo = #{nickedInfo}</if>
|
)
|
||||||
<if test="checkUser != null and checkUser != ''"> and checkUser = #{checkUser}</if>
|
</if>
|
||||||
<if test="checkUserPhone != null and checkUserPhone != ''"> and checkUserPhone = #{checkUserPhone}</if>
|
and isDel = 0
|
||||||
<if test="smarkUrl != null and smarkUrl != ''"> and smark_url = #{smarkUrl}</if>
|
|
||||||
<if test="isDel != null "> and isDel = #{isDel}</if>
|
|
||||||
<if test="createUser != null and createUser != ''"> and createUser = #{createUser}</if>
|
|
||||||
<if test="createTime != null "> and createTime = #{createTime}</if>
|
|
||||||
<if test="updateUser != null and updateUser != ''"> and updateUser = #{updateUser}</if>
|
|
||||||
<if test="updateTime != null "> and updateTime = #{updateTime}</if>
|
|
||||||
<if test="dangerType != null and dangerType != ''"> and danger_type = #{dangerType}</if>
|
|
||||||
<if test="recheckSend != null and recheckSend != ''"> and recheckSend = #{recheckSend}</if>
|
|
||||||
<if test="recheckSendUser != null and recheckSendUser != ''"> and recheckSendUser = #{recheckSendUser}</if>
|
|
||||||
<if test="roleType != null "> and roleType = #{roleType}</if>
|
|
||||||
<if test="problemType != null and problemType != ''"> and problemType = #{problemType}</if>
|
|
||||||
</where>
|
</where>
|
||||||
|
order by ssp.id desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectSmzSspProblemmodifyById" parameterType="Long" resultMap="SmzSspProblemmodifyResult">
|
<select id="selectSmzSspProblemmodifyById" parameterType="Long" resultMap="SmzSspProblemmodifyResult">
|
||||||
<include refid="selectSmzSspProblemmodifyVo"/>
|
<include refid="selectSmzSspProblemmodifyVo"/>
|
||||||
where id = #{id}
|
where ssp.id = #{id}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertSmzSspProblemmodify" parameterType="SmzSspProblemmodify" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insertSmzSspProblemmodify" parameterType="SmzSspProblemmodify" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
|
|
@ -0,0 +1,43 @@
|
||||||
|
package com.yanzhu.flowable.enums;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户岗位
|
||||||
|
*/
|
||||||
|
public enum UserPostEnums {
|
||||||
|
|
||||||
|
WTDL("1", "委托代理"),
|
||||||
|
XMJL("2", "项目经理"),
|
||||||
|
BZZ("3", "班组长"),
|
||||||
|
LWGR("4", "劳务工人"),
|
||||||
|
TSGZ("5", "特殊工种"),
|
||||||
|
CLRY("6", "材料员"),
|
||||||
|
AQRY("8", "安全员"),
|
||||||
|
JSDWGL("66", "建设单位管理"),
|
||||||
|
JLDWGL("71", "监理单位管理"),
|
||||||
|
SGDWGL("72", "施工单位管理"),
|
||||||
|
CLFBGL("73", "材料分包管理"),
|
||||||
|
HQFBGL("74", "后勤分包管理"),
|
||||||
|
TSSBGL("75", "特殊设备管理"),
|
||||||
|
KTDWGL("76", "勘探单位管理"),
|
||||||
|
SJDWGL("77", "设计单位管理"),
|
||||||
|
QTDWGL("78", "其它单位管理");
|
||||||
|
|
||||||
|
private final String code;
|
||||||
|
private final String info;
|
||||||
|
|
||||||
|
UserPostEnums(String code, String info)
|
||||||
|
{
|
||||||
|
this.code = code;
|
||||||
|
this.info = info;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCode()
|
||||||
|
{
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getInfo()
|
||||||
|
{
|
||||||
|
return info;
|
||||||
|
}
|
||||||
|
}
|
|
@ -4,8 +4,10 @@ import com.yanzhu.common.core.text.Convert;
|
||||||
import com.yanzhu.common.core.utils.StringUtils;
|
import com.yanzhu.common.core.utils.StringUtils;
|
||||||
import com.yanzhu.common.security.utils.SecurityUtils;
|
import com.yanzhu.common.security.utils.SecurityUtils;
|
||||||
import com.yanzhu.flowable.domain.my.FlowTaskEntity;
|
import com.yanzhu.flowable.domain.my.FlowTaskEntity;
|
||||||
|
import com.yanzhu.flowable.enums.UserPostEnums;
|
||||||
import com.yanzhu.flowable.mapper.FlowBusinessKeyMapper;
|
import com.yanzhu.flowable.mapper.FlowBusinessKeyMapper;
|
||||||
import com.yanzhu.flowable.service.IFlowBusinessKeyService;
|
import com.yanzhu.flowable.service.IFlowBusinessKeyService;
|
||||||
|
import liquibase.pro.packaged.S;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
@ -99,10 +101,24 @@ public class FlowBusinessKeyServiceImpl implements IFlowBusinessKeyService {
|
||||||
public List<Map<String, Object>> selectMyAwaitFlowTask(FlowTaskEntity flowTaskEntity){
|
public List<Map<String, Object>> selectMyAwaitFlowTask(FlowTaskEntity flowTaskEntity){
|
||||||
// 查询用户是否是班组长...
|
// 查询用户是否是班组长...
|
||||||
if(Objects.nonNull(flowTaskEntity.getAssigneeId())){
|
if(Objects.nonNull(flowTaskEntity.getAssigneeId())){
|
||||||
List<Map<String, Object>> groups = flowBusinessKeyMapper.selectMySubdeptsGroups(Convert.toLong(flowTaskEntity.getStartProId()),SecurityUtils.getUserId());
|
List<Map<String, Object>> users = flowBusinessKeyMapper.selectMySubdeptsGroups(Convert.toLong(flowTaskEntity.getStartProId()),SecurityUtils.getUserId());
|
||||||
if(StringUtils.isNotEmpty(groups)){
|
if(StringUtils.isNotEmpty(users)){
|
||||||
List<Long> groupIds = groups.stream().map(group -> Convert.toLong(group.get("sub_dept_group"))).collect(Collectors.toList());
|
List<Long> groupIds = new ArrayList<>();
|
||||||
flowTaskEntity.setGroupIds(groupIds);
|
for(Map<String, Object> userMap:users){
|
||||||
|
String userPost = Convert.toStr(userMap.get("user_post"));
|
||||||
|
if(Objects.equals(userPost, UserPostEnums.JSDWGL.getCode())){
|
||||||
|
//总包审批时忽略分包单位
|
||||||
|
}else if(Objects.equals(userPost, UserPostEnums.BZZ.getCode())){
|
||||||
|
groupIds.add(Convert.toLong(userMap.get("sub_dept_group")));
|
||||||
|
flowTaskEntity.setStartDeptName(Convert.toStr(userMap.get("sub_dept_name")));
|
||||||
|
}else{
|
||||||
|
flowTaskEntity.setStartDeptName(Convert.toStr(userMap.get("sub_dept_name")));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//班组长信息...
|
||||||
|
if(groupIds.size()>0){
|
||||||
|
flowTaskEntity.setGroupIds(groupIds);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return flowBusinessKeyMapper.selectMyAwaitFlowTask(flowTaskEntity);
|
return flowBusinessKeyMapper.selectMyAwaitFlowTask(flowTaskEntity);
|
||||||
|
|
|
@ -16,7 +16,7 @@ spring:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: @discovery.server-addr@
|
server-addr: @discovery.server-addr@
|
||||||
# 服务分组
|
# 服务分组
|
||||||
group: lijun
|
group: JiangYuQi
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: @discovery.server-addr@
|
server-addr: @discovery.server-addr@
|
||||||
|
|
|
@ -142,7 +142,6 @@ public class ProProjectInfoController extends BaseController
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||||
proProjectInfo.setComId(loginUser.getSysUser().getComId());
|
|
||||||
if(!SecurityUtils.isAdmin(loginUser.getUserid())){
|
if(!SecurityUtils.isAdmin(loginUser.getUserid())){
|
||||||
if(SecurityUtils.isGSAdmin()){
|
if(SecurityUtils.isGSAdmin()){
|
||||||
proProjectInfo.setActiveComId(SecurityUtils.getLoginUser().getProjectDeptId());
|
proProjectInfo.setActiveComId(SecurityUtils.getLoginUser().getProjectDeptId());
|
||||||
|
|
|
@ -2,6 +2,7 @@ package com.yanzhu.manage.controller;
|
||||||
|
|
||||||
import com.alibaba.fastjson2.JSONObject;
|
import com.alibaba.fastjson2.JSONObject;
|
||||||
import com.yanzhu.common.core.domain.R;
|
import com.yanzhu.common.core.domain.R;
|
||||||
|
import com.yanzhu.common.core.enums.UseStateEnums;
|
||||||
import com.yanzhu.common.core.text.Convert;
|
import com.yanzhu.common.core.text.Convert;
|
||||||
import com.yanzhu.common.core.utils.DateUtils;
|
import com.yanzhu.common.core.utils.DateUtils;
|
||||||
import com.yanzhu.common.core.utils.poi.ExcelUtil;
|
import com.yanzhu.common.core.utils.poi.ExcelUtil;
|
||||||
|
@ -305,4 +306,17 @@ public class ProProjectInfoSubdeptsUsersController extends BaseController
|
||||||
return success();
|
return success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询分包单位工人列表
|
||||||
|
*/
|
||||||
|
@GetMapping("/findAll")
|
||||||
|
public AjaxResult findAll(ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers)
|
||||||
|
{
|
||||||
|
proProjectInfoSubdeptsUsers.setUseStatus(UseStateEnums.IN.getCode());
|
||||||
|
proProjectInfoSubdeptsUsers.setActiveTags("finished");
|
||||||
|
proProjectInfoSubdeptsUsers.setSearchValue("sedUsers");
|
||||||
|
List<ProProjectInfoSubdeptsUsers> list = proProjectInfoSubdeptsUsersService.selectProProjectInfoSubdeptsUsersList(proProjectInfoSubdeptsUsers);
|
||||||
|
return success(list);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,8 @@ import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.yanzhu.common.core.text.Convert;
|
||||||
|
import com.yanzhu.common.core.utils.StringUtils;
|
||||||
import com.yanzhu.common.security.utils.SecurityUtils;
|
import com.yanzhu.common.security.utils.SecurityUtils;
|
||||||
import com.yanzhu.manage.domain.SmzSspProblemmodify;
|
import com.yanzhu.manage.domain.SmzSspProblemmodify;
|
||||||
import com.yanzhu.manage.service.ISmzSspProblemmodifyService;
|
import com.yanzhu.manage.service.ISmzSspProblemmodifyService;
|
||||||
|
@ -143,4 +145,20 @@ public class SmzSspProblemmodifyController extends BaseController
|
||||||
{
|
{
|
||||||
return toAjax(smzSspProblemmodifyService.deleteSmzSspProblemmodifyByIds(ids));
|
return toAjax(smzSspProblemmodifyService.deleteSmzSspProblemmodifyByIds(ids));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询我上次提交的隐患信息
|
||||||
|
* 自动填充整改人,复检人,抄送人
|
||||||
|
*/
|
||||||
|
@GetMapping(value = "/findMyLastProblemmodify/{proId}")
|
||||||
|
public AjaxResult findMyLastProblemmodify(@PathVariable("proId") Long proId,Long infoType)
|
||||||
|
{
|
||||||
|
startPage(1,1);
|
||||||
|
SmzSspProblemmodify query = new SmzSspProblemmodify();
|
||||||
|
query.setProjectId(proId);
|
||||||
|
query.setInfoType(infoType);
|
||||||
|
query.setCreateUser(Convert.toStr(SecurityUtils.getUserId()));
|
||||||
|
List<SmzSspProblemmodify> data = smzSspProblemmodifyService.selectSmzSspProblemmodifyList(query);
|
||||||
|
return success(data);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,6 @@ package com.yanzhu.manage.service.impl;
|
||||||
|
|
||||||
import cn.binarywang.wx.miniapp.api.WxMaService;
|
import cn.binarywang.wx.miniapp.api.WxMaService;
|
||||||
import com.yanzhu.common.core.constant.SecurityConstants;
|
import com.yanzhu.common.core.constant.SecurityConstants;
|
||||||
import com.yanzhu.common.core.domain.R;
|
|
||||||
import com.yanzhu.common.core.enums.*;
|
import com.yanzhu.common.core.enums.*;
|
||||||
import com.yanzhu.common.core.exception.ServiceException;
|
import com.yanzhu.common.core.exception.ServiceException;
|
||||||
import com.yanzhu.common.core.text.Convert;
|
import com.yanzhu.common.core.text.Convert;
|
||||||
|
@ -473,7 +472,9 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
sysUser.setUpdateBy(SecurityUtils.getUsername());
|
sysUser.setUpdateBy(SecurityUtils.getUsername());
|
||||||
sysUser.setUpdateTime(DateUtils.getNowDate());
|
sysUser.setUpdateTime(DateUtils.getNowDate());
|
||||||
sysUser.setRemark(proProjectInfoSubdeptsUsers.getSubDeptName());
|
sysUser.setRemark(proProjectInfoSubdeptsUsers.getSubDeptName());
|
||||||
|
log.info("insertProProjectInfoSubdeptsUsersWX==>{}",sysUser.getUserName());
|
||||||
Long userId = remoteUserService.registerUserInfo(sysUser, SecurityConstants.INNER).getData();
|
Long userId = remoteUserService.registerUserInfo(sysUser, SecurityConstants.INNER).getData();
|
||||||
|
log.info("insertProProjectInfoSubdeptsUsersWX==>{}",userId);
|
||||||
proProjectInfoSubdeptsUsers.setUserId(userId);
|
proProjectInfoSubdeptsUsers.setUserId(userId);
|
||||||
proProjectInfoSubdeptsUsersMapper.insertProProjectInfoSubdeptsUsers(proProjectInfoSubdeptsUsers);
|
proProjectInfoSubdeptsUsersMapper.insertProProjectInfoSubdeptsUsers(proProjectInfoSubdeptsUsers);
|
||||||
return proProjectInfoSubdeptsUsers;
|
return proProjectInfoSubdeptsUsers;
|
||||||
|
@ -627,6 +628,7 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
@Transactional
|
@Transactional
|
||||||
public ProProjectInfoSubdeptsUsers updateProProjectInfoSubdeptsUsersWX(ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers)
|
public ProProjectInfoSubdeptsUsers updateProProjectInfoSubdeptsUsersWX(ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers)
|
||||||
{
|
{
|
||||||
|
log.info("updateProProjectInfoSubdeptsUsersWX==>");
|
||||||
ProProjectInfoSubdeptsUsers parUsers = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersById(proProjectInfoSubdeptsUsers.getParId());
|
ProProjectInfoSubdeptsUsers parUsers = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersById(proProjectInfoSubdeptsUsers.getParId());
|
||||||
if(Objects.isNull(parUsers)){
|
if(Objects.isNull(parUsers)){
|
||||||
throw new ServiceException("用户信息异常...请重新扫码");
|
throw new ServiceException("用户信息异常...请重新扫码");
|
||||||
|
@ -1378,14 +1380,16 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
@Override
|
@Override
|
||||||
@Transactional
|
@Transactional
|
||||||
public int editDefaultProjectById(Long id){
|
public int editDefaultProjectById(Long id){
|
||||||
int res = proProjectInfoSubdeptsUsersMapper.editDefaultProjectById(SecurityUtils.getUserId());
|
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||||
|
Long userId = loginUser.getUserid();
|
||||||
|
int res = proProjectInfoSubdeptsUsersMapper.editDefaultProjectById(userId);
|
||||||
if(res>0){
|
if(res>0){
|
||||||
ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersByParamId(id,SecurityUtils.getUserId());
|
ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersByParamId(id,userId);
|
||||||
proProjectInfoSubdeptsUsers.setSortBy(0L);
|
proProjectInfoSubdeptsUsers.setSortBy(0L);
|
||||||
res = proProjectInfoSubdeptsUsersMapper.updateProProjectInfoSubdeptsUsers(proProjectInfoSubdeptsUsers);
|
res = proProjectInfoSubdeptsUsersMapper.updateProProjectInfoSubdeptsUsers(proProjectInfoSubdeptsUsers);
|
||||||
}
|
}
|
||||||
boolean isAdmin= (SecurityUtils.isAdmin(SecurityUtils.getUserId()) || SecurityUtils.isGSAdmin());
|
boolean isAdmin= (SecurityUtils.isAdmin(userId) || SecurityUtils.isGSAdmin());
|
||||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
|
||||||
if(isAdmin){
|
if(isAdmin){
|
||||||
SysUserExt userExt = new SysUserExt();
|
SysUserExt userExt = new SysUserExt();
|
||||||
userExt.setUserId(loginUser.getUserid());
|
userExt.setUserId(loginUser.getUserid());
|
||||||
|
|
|
@ -0,0 +1,20 @@
|
||||||
|
import {
|
||||||
|
request
|
||||||
|
} from '../utils/request'
|
||||||
|
|
||||||
|
// 查询隐患列表
|
||||||
|
export function list(query) {
|
||||||
|
return request({
|
||||||
|
url: '/manage/problemmodify/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询我上次提交的隐患信息
|
||||||
|
export function findMyLastProblemmodify(proId,type) {
|
||||||
|
return request({
|
||||||
|
url: '/manage/problemmodify/findMyLastProblemmodify/'+proId+'?infoType='+type,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
|
@ -98,4 +98,13 @@ export function findProjectDepts(proId) {
|
||||||
url: '/manage/proProjectInfoDepts/findAllDepts/' + proId,
|
url: '/manage/proProjectInfoDepts/findAllDepts/' + proId,
|
||||||
method: 'get'
|
method: 'get'
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询项目参建单位
|
||||||
|
export function findProjectDeptUsers(query) {
|
||||||
|
return request({
|
||||||
|
url: '/manage/proProjectInfoDepts/findAllDepts/' + proId,
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
}
|
}
|
|
@ -2028,3 +2028,14 @@ swiper-item video {
|
||||||
height: 180rpx;
|
height: 180rpx;
|
||||||
padding-right: 15rpx;
|
padding-right: 15rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.markers{
|
||||||
|
background: url("https://xiangguan.sxyanzhu.com/profile/icon/req.png") no-repeat left/40rpx;
|
||||||
|
height: 20px;
|
||||||
|
line-height: 20px;
|
||||||
|
padding-left: 42rpx;
|
||||||
|
white-space: nowrap;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
word-break: break-all;
|
||||||
|
}
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
timeout: 60000,
|
timeout: 60000,
|
||||||
appId: "wx46466c7828eede2b",
|
appId: "wx46466c7828eede2b",
|
||||||
baseUrl: 'https://xiangguan.sxyanzhu.com',
|
//baseUrl: 'https://xiangguan.sxyanzhu.com',
|
||||||
//baseUrl: 'http://127.0.0.1:8080',
|
baseUrl: 'http://127.0.0.1:8080',
|
||||||
baseImgUrl: 'https://xiangguan.sxyanzhu.com',
|
//baseImgUrl: 'https://xiangguan.sxyanzhu.com',
|
||||||
//baseImgUrl: 'https:xiangguan.sxyanzhu.com/file',
|
//baseImgUrl: 'https:xiangguan.sxyanzhu.com/file',
|
||||||
//baseImgUrl: 'http://127.0.0.1:9300',
|
baseImgUrl: 'http://127.0.0.1:9300',
|
||||||
noSecuritys:['/code','/auth/wxLogin','/auth/getMaOpenId','/auth/getMaPhoneNumber','/auth/maLogin']
|
noSecuritys:['/code','/auth/wxLogin','/auth/getMaOpenId','/auth/getMaPhoneNumber','/auth/maLogin']
|
||||||
};
|
};
|
|
@ -44,7 +44,6 @@ Page({
|
||||||
this.setData({
|
this.setData({
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
lastDataSize: 10,
|
|
||||||
listData: [],
|
listData: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
dshCount: 0,
|
dshCount: 0,
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title module_title_flex">
|
<view class="module_title module_title_flex">
|
||||||
<text wx:if="{{!item.endTime}}" class="color_purple">申请时间 {{item.createTime}}</text>
|
<text wx:if="{{!item.endTime}}" class="color_purple">申请时间 {{item.createTime}}</text>
|
||||||
<text wx:if="{{item.endTime}}" class="color_purple">办结时间 {{item.endTime}}</text>
|
<text wx:if="{{item.endTime}}" class="color_purple">办结时间 {{item.endTime}}</text>
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title module_title_flex">
|
<view class="module_title module_title_flex">
|
||||||
<text wx:if="{{!item.endTime}}" class="color_purple">申请时间 {{item.createTime}}</text>
|
<text wx:if="{{!item.endTime}}" class="color_purple">申请时间 {{item.createTime}}</text>
|
||||||
<text wx:if="{{item.endTime}}" class="color_purple">办结时间 {{item.endTime}}</text>
|
<text wx:if="{{item.endTime}}" class="color_purple">办结时间 {{item.endTime}}</text>
|
||||||
|
|
|
@ -194,7 +194,7 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title module_title_flex inspect_list_title_label">考勤时间:{{format.dateStrEv(item.inTime,item.outTime)}}</view>
|
<view class="module_title module_title_flex inspect_list_title_label">考勤时间:{{format.dateStrEv(item.inTime,item.outTime)}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -15,17 +15,12 @@ Page({
|
||||||
* 页面的初始数据
|
* 页面的初始数据
|
||||||
*/
|
*/
|
||||||
data: {
|
data: {
|
||||||
active: 4,
|
active: 0,
|
||||||
projectId: '',
|
projectId: '',
|
||||||
projectName: '',
|
projectName: '',
|
||||||
subDeptUserInfo:{},
|
subDeptUserInfo:{},
|
||||||
loginName: '',
|
|
||||||
remark: '',
|
|
||||||
roleId: '',
|
|
||||||
roleName: '',
|
|
||||||
menuList: [],
|
menuList: [],
|
||||||
initData: {},
|
initData: {},
|
||||||
hiddenn: true,
|
|
||||||
todoDB: 0,
|
todoDB: 0,
|
||||||
fbdwDB: 0,
|
fbdwDB: 0,
|
||||||
fbrtDB: 0
|
fbrtDB: 0
|
||||||
|
@ -87,12 +82,23 @@ Page({
|
||||||
*/
|
*/
|
||||||
getProSubDeptsUserInfo() {
|
getProSubDeptsUserInfo() {
|
||||||
const proUserInfo = getUserInfo();
|
const proUserInfo = getUserInfo();
|
||||||
|
let _act = this.data.active;
|
||||||
|
let _projectUserInfo = proUserInfo.projectUserInfo;
|
||||||
|
if(_projectUserInfo.subDeptType=='1'){
|
||||||
|
_act = 4;
|
||||||
|
}else{
|
||||||
|
if(_projectUserInfo.userPost=='1' || _projectUserInfo.userPost=='2' || _projectUserInfo.userPost=='3'){
|
||||||
|
_act = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
this.setData({
|
this.setData({
|
||||||
subDeptUserInfo: proUserInfo.projectUserInfo
|
active:_act,
|
||||||
|
subDeptUserInfo: _projectUserInfo,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
goMenu: function (event) {
|
goMenu: function (event) {
|
||||||
|
wx.setStorageSync('nav-menu', "gdgn");
|
||||||
wx.redirectTo({
|
wx.redirectTo({
|
||||||
url: event.currentTarget.dataset.url
|
url: event.currentTarget.dataset.url
|
||||||
})
|
})
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<van-tabbar wx:if="{{subDeptUserInfo.userPost!='3' && subDeptUserInfo.userPost!='4' && subDeptUserInfo.userPost!='5'}}" active="{{ active }}" bind:change="onChange" active-color="#ffffff" inactive-color="#7d95d6">
|
<van-tabbar wx:if="{{subDeptUserInfo.userPost!='4' && subDeptUserInfo.userPost!='5' && subDeptUserInfo.userPost!='6' && subDeptUserInfo.userPost!='8'}}" active="{{ active }}" bind:change="onChange" active-color="#ffffff" inactive-color="#7d95d6">
|
||||||
<van-tabbar-item bindtap="XMGK">
|
<van-tabbar-item bindtap="XMGK">
|
||||||
<image
|
<image
|
||||||
slot="icon"
|
slot="icon"
|
||||||
|
|
|
@ -1,3 +1,17 @@
|
||||||
|
import config from '../../../config'
|
||||||
|
import {
|
||||||
|
getToken,
|
||||||
|
getUserInfo
|
||||||
|
} from '../../../utils/auth'
|
||||||
|
import {
|
||||||
|
findDictCache
|
||||||
|
} from '../../../api/publics'
|
||||||
|
import {
|
||||||
|
findProjectDeptUsers
|
||||||
|
} from '../../../api/project'
|
||||||
|
import {
|
||||||
|
findMyLastProblemmodify
|
||||||
|
} from '../../../api/problemmodify'
|
||||||
const app = getApp()
|
const app = getApp()
|
||||||
Page({
|
Page({
|
||||||
|
|
||||||
|
@ -6,15 +20,26 @@ Page({
|
||||||
*/
|
*/
|
||||||
data: {
|
data: {
|
||||||
maxDate: new Date(2088, 1, 1).getTime(),
|
maxDate: new Date(2088, 1, 1).getTime(),
|
||||||
minDate: new Date().getTime() + (3600 * 48 * 1000),
|
type:"",
|
||||||
projectId: "",
|
typeName:"",
|
||||||
projectName: "",
|
projectId:"",
|
||||||
|
projectName:"",
|
||||||
|
problemTypeList: [],
|
||||||
|
problemSubTypeList: [],
|
||||||
|
imageInfoData: [],
|
||||||
|
form:{
|
||||||
|
infoType:"",
|
||||||
|
problemType:"1",
|
||||||
|
dangerType:null,
|
||||||
|
nickedTime:"",
|
||||||
|
},
|
||||||
|
active: 0,
|
||||||
|
flowNodes:[{text:'开始'},{text:'提交隐患'},{text:'隐患整改'},{text:'隐患复检'},{text:'结束'}],
|
||||||
loginName: "",
|
loginName: "",
|
||||||
userName: "",
|
userName: "",
|
||||||
rectifierData: [],
|
rectifierData: [],
|
||||||
rectifierData2: [],
|
rectifierData2: [],
|
||||||
rectifierData3: [],
|
rectifierData3: [],
|
||||||
imageInfoData: [],
|
|
||||||
//验收时间
|
//验收时间
|
||||||
nickedTime: '',
|
nickedTime: '',
|
||||||
loadShow: false,
|
loadShow: false,
|
||||||
|
@ -32,53 +57,85 @@ Page({
|
||||||
selectIndex: "",
|
selectIndex: "",
|
||||||
problemType: "1",
|
problemType: "1",
|
||||||
showHis: false,
|
showHis: false,
|
||||||
problemTypeList: [{
|
|
||||||
id: "1",
|
|
||||||
text: "常规检查"
|
|
||||||
}, {
|
|
||||||
id: "2",
|
|
||||||
text: "专项检查"
|
|
||||||
}],
|
|
||||||
flowNodes:[{text:'开始'},{text:'提交隐患'},{text:'隐患整改'},{text:'隐患复检'},{text:'结束'}],
|
|
||||||
active: 0
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 生命周期函数--监听页面加载
|
* 生命周期函数--监听页面加载
|
||||||
*/
|
*/
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
let {
|
if(!getToken()){
|
||||||
ts
|
wx.redirectTo({
|
||||||
} = options
|
url: '../../login/login',
|
||||||
this.setData({
|
})
|
||||||
projectId: app.globalData.projectId,
|
}
|
||||||
projectName: app.globalData.projectName,
|
const proUserInfo = getUserInfo();
|
||||||
loginName: res.data.loginName,
|
this.setData({
|
||||||
userName: res.data.nickName,
|
type:options.type,
|
||||||
recheckSend: res.data.nickName,
|
typeName:options.type==1?"质量":"安全",
|
||||||
recheckSendUser: res.data.loginName
|
projectId:app.globalData.useProjectId,
|
||||||
});
|
projectName:app.globalData.useProjectName,
|
||||||
//获取缓存数据
|
"form.infoType":options.type,
|
||||||
wx.getStorage({
|
"form.recheckSend": proUserInfo.nickName,
|
||||||
key: 'YanZhu-XD-App-UserInfoKey',
|
"form.recheckSendUser": proUserInfo.userId
|
||||||
success: res => {
|
});
|
||||||
this.setData({
|
this.getDictCache();
|
||||||
projectId: app.globalData.projectId,
|
this.getHisInfo(options.type);
|
||||||
projectName: app.globalData.projectName,
|
this.getProjectUsers();
|
||||||
loginName: res.data.loginName,
|
|
||||||
userName: res.data.nickName,
|
|
||||||
recheckSend: res.data.nickName,
|
|
||||||
recheckSendUser: res.data.loginName
|
|
||||||
});
|
|
||||||
this.getAllProjectUserData();
|
|
||||||
this.getDangerTypeList();
|
|
||||||
this.getHisInfo();
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
//查询项目人员数据
|
/**
|
||||||
getAllProjectUserData() {
|
* 获取字典缓存数据
|
||||||
|
*/
|
||||||
|
getDictCache(signId) {
|
||||||
|
// 初始化检查类型
|
||||||
|
findDictCache("ssp_proble_type").then(res => {
|
||||||
|
if (res.code == 200) {
|
||||||
|
let list = [];
|
||||||
|
res.data.forEach(item => {
|
||||||
|
list.push({
|
||||||
|
"id": item.dictValue,
|
||||||
|
"text": item.dictLabel
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.setData({
|
||||||
|
problemTypeList: list
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
//初始化隐患类型
|
||||||
|
findDictCache("ssp_proble_sub_type").then(res => {
|
||||||
|
if (res.code == 200) {
|
||||||
|
let list = [];
|
||||||
|
res.data.forEach(item => {
|
||||||
|
list.push({
|
||||||
|
"id": item.dictValue,
|
||||||
|
"text": item.dictLabel
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.setData({
|
||||||
|
problemSubTypeList: list
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询项目人员数据
|
||||||
|
* 获取项目所有人员,在页面组装数据...
|
||||||
|
*/
|
||||||
|
getProjectUsers() {
|
||||||
|
let params = "projectId="+app.globalData.useProjectId;
|
||||||
|
findProjectDeptUsers(params).then(res =>{
|
||||||
|
let _lordSentList = [];
|
||||||
|
let _copySendList = [];
|
||||||
|
let _checkUserList = [];
|
||||||
|
res.data.forEach(item =>{
|
||||||
|
//if(item.subDeptType!='1' && _lordSentList)
|
||||||
|
});
|
||||||
|
});
|
||||||
let that = this
|
let that = this
|
||||||
wx.request({
|
wx.request({
|
||||||
url: app.globalData.reqUrl + '/wechat/projectuserinfo/queryAllProjectUserByParams',
|
url: app.globalData.reqUrl + '/wechat/projectuserinfo/queryAllProjectUserByParams',
|
||||||
|
@ -136,96 +193,52 @@ Page({
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
getHisInfo() {
|
/**
|
||||||
//这里查询当前登录人上次提交隐患,自动填充整改人,复检人,抄送人
|
* 这里查询当前登录人上次提交隐患
|
||||||
let that = this
|
* 自动填充整改人,复检人,抄送人
|
||||||
wx.request({
|
* @param {*} type
|
||||||
url: app.globalData.reqUrl + '/wechat/projectProblemmodify/findLastDataByParams',
|
*/
|
||||||
method: "get",
|
getHisInfo(type) {
|
||||||
data: {
|
findMyLastProblemmodify(app.globalData.useProjectId,type).then(res => {
|
||||||
projectId: that.data.projectId,
|
if(res.code==200 && res.data && res.data.length>0){
|
||||||
createUser: that.data.loginName,
|
this.setData({
|
||||||
infoType: 1
|
showHis: true,
|
||||||
},
|
"form.lordSent": res.data[0].lordSent,
|
||||||
header: {
|
"form.lordSentUser": res.data[0].lordSentUser,
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
"form.recheckSend": res.data[0].recheckSend,
|
||||||
},
|
"form.recheckSendUser": res.data[0].recheckSendUser,
|
||||||
success(res) {
|
"form.copySend": res.data[0].copySend,
|
||||||
res = res.data
|
"form.copySendUser": res.data[0].copySendUser
|
||||||
if (res.code == 200 && res.data) {
|
})
|
||||||
that.setData({
|
|
||||||
showHis: true,
|
|
||||||
lordSent: res.data.lordSent,
|
|
||||||
lordSentUser: res.data.lordSentUser,
|
|
||||||
recheckSend: res.data.recheckSend,
|
|
||||||
recheckSendUser: res.data.recheckSendUser,
|
|
||||||
copySend: res.data.copySend,
|
|
||||||
copySendUser: res.data.copySendUser
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
},
|
|
||||||
|
|
||||||
getDangerTypeList() {
|
|
||||||
let that = this
|
|
||||||
wx.request({
|
|
||||||
url: app.globalData.reqUrl + '/wechat/projectProblemmodify/queryDangerType',
|
|
||||||
method: "get",
|
|
||||||
data: {
|
|
||||||
type: 'ssp_zlyhlx'
|
|
||||||
},
|
|
||||||
header: {
|
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
|
||||||
},
|
|
||||||
success(res) {
|
|
||||||
res = res.data
|
|
||||||
if (res.code == 200) {
|
|
||||||
let list = [];
|
|
||||||
res.data.forEach(it => {
|
|
||||||
list.push({
|
|
||||||
"id": it.dictValue,
|
|
||||||
"text": it.dictLabel
|
|
||||||
});
|
|
||||||
})
|
|
||||||
that.setData({
|
|
||||||
dangerTypeList: list
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
//隐患描述
|
//隐患描述
|
||||||
onInputWorkParts(e) {
|
onInputWorkParts(e) {
|
||||||
let workParts = e.detail.value
|
|
||||||
this.setData({
|
this.setData({
|
||||||
workParts
|
"form.workParts":e.detail.value
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
//整改要求
|
//整改要求
|
||||||
onInputChangeInfoValue(e) {
|
onInputChangeInfoValue(e) {
|
||||||
let changeInfo = e.detail.value
|
|
||||||
this.setData({
|
this.setData({
|
||||||
changeInfo
|
"form.changeInfo":e.detail.value
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
//验收时间
|
//验收时间
|
||||||
onInputTime(e) {
|
onInputTime(e) {
|
||||||
let nickedTime = e.detail
|
|
||||||
this.setData({
|
this.setData({
|
||||||
nickedTime
|
"form.nickedTime":e.detail
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
// list 上传图片
|
// 上传图片
|
||||||
onImagesArr(e) {
|
onImagesArr(e) {
|
||||||
var data = this.data.imageInfoData
|
|
||||||
data = e.detail
|
|
||||||
this.setData({
|
this.setData({
|
||||||
imageInfoData: data
|
imageInfoData: e.detail
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -435,53 +448,17 @@ Page({
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
|
||||||
* 这里考虑上传图片异步问题,封装为同步
|
|
||||||
*/
|
|
||||||
syncUploadImage(url, uploadFile, name) {
|
|
||||||
return new Promise((resolve, reject) => {
|
|
||||||
wx.uploadFile({
|
|
||||||
url, // 上传的服务器接口地址
|
|
||||||
filePath: uploadFile,
|
|
||||||
header: {
|
|
||||||
"Content-Type": "application/x-www-form-urlencoded;charset=UTF-8"
|
|
||||||
},
|
|
||||||
name, //上传的所需字段,后端提供
|
|
||||||
formData: {
|
|
||||||
user: 'test'
|
|
||||||
},
|
|
||||||
success: (res) => {
|
|
||||||
// 上传完成操作
|
|
||||||
const data = JSON.parse(res.data)
|
|
||||||
resolve({
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
},
|
|
||||||
fail: (err) => {
|
|
||||||
//上传失败:修改pedding为reject
|
|
||||||
console.log("访问接口失败", err);
|
|
||||||
wx.showToast({
|
|
||||||
title: "网络出错,上传失败",
|
|
||||||
icon: 'none',
|
|
||||||
duration: 1000
|
|
||||||
});
|
|
||||||
reject(err)
|
|
||||||
}
|
|
||||||
});
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
//选择检查类型
|
//选择检查类型
|
||||||
onSelectProblemType(e) {
|
onSelectProblemType(e) {
|
||||||
this.setData({
|
this.setData({
|
||||||
problemType: e.detail.id
|
"form.problemType": e.detail.id
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
//选择隐患类型
|
//选择隐患类型
|
||||||
onSelectDangerType(e) {
|
onSelectDangerType(e) {
|
||||||
this.setData({
|
this.setData({
|
||||||
dangerType: e.detail.id
|
"form.dangerType": e.detail.id
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -12,64 +12,64 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="max_content">
|
<view class="max_content">
|
||||||
<van-steps steps="{{ flowNodes }}" active="{{ active }}" />
|
<van-steps steps="{{ flowNodes }}" active="{{ active }}" />
|
||||||
<view class="inspect_info ">
|
<view class="inspect_info">
|
||||||
<view class="module_title module_title_flex">
|
<view class="video_address_min_2">
|
||||||
<view>{{projectName}}</view>
|
<view>{{projectName}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">隐患图片</view>
|
<view class="markers inspect_info_title">隐患图片</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<file-uploader bindimages="onImagesArr"></file-uploader>
|
<file-uploader bindimages="onImagesArr"></file-uploader>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">检查类型</view>
|
<view class="markers inspect_info_title">检查类型</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<voucher-select columns="{{problemTypeList}}" placeholder="请选择检查类型" bindchange="onSelectProblemType"></voucher-select>
|
<voucher-select columns="{{problemTypeList}}" placeholder="请选择检查类型" bindchange="onSelectProblemType"></voucher-select>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">隐患类型</view>
|
<view class="markers inspect_info_title">隐患类型</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<voucher-select columns="{{dangerTypeList}}" placeholder="请选择隐患类型" bindchange="onSelectDangerType" selectValue="{{activeName}}" selectIndex="{{activeIndex}}"></voucher-select>
|
<voucher-select columns="{{problemSubTypeList}}" placeholder="请选择隐患类型" bindchange="onSelectDangerType" selectValue="{{form.dangerType}}"></voucher-select>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list" >
|
<view class="inspect_info_list" >
|
||||||
<view class="inspect_info_title">隐患描述</view>
|
<view class="markers inspect_info_title">隐患描述</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<textarea class="add_textarea" placeholder="请填写质量隐患描述"
|
<textarea class="add_textarea" placeholder="请填写质量隐患描述"
|
||||||
placeholder-style="color:#6777aa;" bindinput="onInputWorkParts" maxlength="200"/>
|
placeholder-style="color:#6777aa;" bindinput="onInputWorkParts" maxlength="200"/>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list" >
|
<view class="inspect_info_list" >
|
||||||
<view class="inspect_info_title">整改要求</view>
|
<view class="markers inspect_info_title">整改要求</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<textarea class="add_textarea" placeholder="请填写隐患整改要求"
|
<textarea class="add_textarea" placeholder="请填写隐患整改要求"
|
||||||
placeholder-style="color:#6777aa;" bindinput="onInputChangeInfoValue" maxlength="200"/>
|
placeholder-style="color:#6777aa;" bindinput="onInputChangeInfoValue" maxlength="200"/>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title">整改截至时间</view>
|
<view class="markers inspect_info_title">整改截至时间</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<voucher-date counts="5" placeholder="请选择整改截至时间" minDate="{{minDate}}" maxDate="{{maxDate}}" bindchange="onInputTime"></voucher-date>
|
<voucher-date counts="5" placeholder="请选择整改截至时间" maxDate="{{maxDate}}" bindchange="onInputTime"></voucher-date>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">整改人</view>
|
<view class="markers inspect_info_title">整改人</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<select-group-person rectifierData="{{rectifierData}}" multiple="{{fales}}" bindselected="onAddLordSent" index="1" title="请选择整改人" choose="{{lordSent}}">
|
<select-group-person rectifierData="{{rectifierData}}" multiple="{{fales}}" bindselected="onAddLordSent" index="1" title="请选择整改人" choose="{{lordSent}}">
|
||||||
</select-group-person>
|
</select-group-person>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">复检人</view>
|
<view class="markers inspect_info_title">复检人</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<select-group-person rectifierData="{{rectifierData2}}" multiple="{{fales}}" bindselected="onAddRecheckSend" index="2" title="请选择复检人" choose="{{recheckSend}}">
|
<select-group-person rectifierData="{{rectifierData2}}" multiple="{{fales}}" bindselected="onAddRecheckSend" index="2" title="请选择复检人" choose="{{recheckSend}}">
|
||||||
</select-group-person>
|
</select-group-person>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_info_list">
|
<view class="inspect_info_list">
|
||||||
<view class="inspect_info_title" style="padding: 20rpx 0 10rpx;">抄送人</view>
|
<view class="markers inspect_info_title">抄送人</view>
|
||||||
<view class="inspect_info_content">
|
<view class="inspect_info_content">
|
||||||
<select-group-person rectifierData="{{rectifierData3}}" multiple="{{true}}" bindselected="onAddCopySend" index="3" title="请选择抄送人" choose="{{copySend}}">
|
<select-group-person rectifierData="{{rectifierData3}}" multiple="{{true}}" bindselected="onAddCopySend" index="3" title="请选择抄送人" choose="{{copySend}}">
|
||||||
</select-group-person>
|
</select-group-person>
|
||||||
|
|
|
@ -4,3 +4,22 @@
|
||||||
.van-image__img{
|
.van-image__img{
|
||||||
border-radius: 10rpx !important;
|
border-radius: 10rpx !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.van-steps {
|
||||||
|
background-color: transparent !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-step--horizontal .van-step__circle-container {
|
||||||
|
background-color: transparent !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-steps--horizontal {
|
||||||
|
padding: 10px 20px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.video_address_min_2 {
|
||||||
|
background: url("http://fileimg.makalu.cc/CORE_B1C818B4CF2C44FE9D96624589329EBC.png") no-repeat left/40rpx;
|
||||||
|
height: 40rpx;
|
||||||
|
line-height: 40rpx;
|
||||||
|
padding-left: 40rpx;
|
||||||
|
}
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
|
import config from '../../../config'
|
||||||
import {
|
import {
|
||||||
getToken
|
getToken
|
||||||
} from '../../../utils/auth'
|
} from '../../../utils/auth'
|
||||||
|
import {
|
||||||
|
list
|
||||||
|
} from '../../../api/problemmodify'
|
||||||
const app = getApp()
|
const app = getApp()
|
||||||
Page({
|
Page({
|
||||||
|
|
||||||
|
@ -10,61 +14,30 @@ import {
|
||||||
data: {
|
data: {
|
||||||
type:"",
|
type:"",
|
||||||
typeName:"",
|
typeName:"",
|
||||||
addFlag:false,
|
addFlag:true,
|
||||||
addDraftFlag:false,
|
addDraftFlag:true,
|
||||||
deptId:"",
|
|
||||||
loginName:"",
|
|
||||||
userName:"",
|
|
||||||
projectId:"",
|
projectId:"",
|
||||||
projectData:{},
|
projectName:"",
|
||||||
projectNameArgs:"",
|
|
||||||
initData: {},
|
initData: {},
|
||||||
show:false,
|
pageNum:1,
|
||||||
|
pageSize:10,
|
||||||
|
total:0,
|
||||||
listData:[],
|
listData:[],
|
||||||
activeState:"zg",
|
activeState:"dzg",
|
||||||
dzgCount:0,
|
dzgCount:0,
|
||||||
dfjCount:0,
|
dfjCount:0,
|
||||||
yclCount:0,
|
yclCount:0,
|
||||||
zgcsCOunt:0,
|
imgBaseUrl: config.baseImgUrl,
|
||||||
request:app.globalData.reqUrl,
|
|
||||||
pageNum:1,
|
|
||||||
pageSize:10,
|
|
||||||
lastDataSize:10,
|
|
||||||
minRoleId:"",
|
|
||||||
list:[],
|
|
||||||
},
|
|
||||||
|
|
||||||
skipAdd(){
|
|
||||||
wx.redirectTo({
|
|
||||||
url: `../add/index?projectId=${this.data.initData.id}&projectName=`+this.data.initData.text,
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
skipAddDarft(){
|
|
||||||
wx.setStorageSync('nav-menu', "list");
|
|
||||||
wx.redirectTo({
|
|
||||||
url: `../draft/index`,
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
getInfo(e){
|
|
||||||
let {id,checkState,lordSentUser,recheckSendUser} = e.currentTarget.dataset.set
|
|
||||||
if((checkState==0 || checkState==3) && lordSentUser==this.data.loginName){
|
|
||||||
//整改页面(状态时待整改&&整改人是当前登录人)
|
|
||||||
wx.redirectTo({
|
|
||||||
url: `../modify/index?id=${id}`,
|
|
||||||
})
|
|
||||||
}else if(checkState==1 && recheckSendUser==this.data.loginName){
|
|
||||||
//复检页面 (状态时待复检&&复检人是当前登录人)
|
|
||||||
wx.redirectTo({
|
|
||||||
url: `../check/index?id=${id}`,
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
wx.redirectTo({
|
|
||||||
url: `../info/index?id=${id}`,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
//项目切换 返回值
|
||||||
|
onProjectSelect(e) {
|
||||||
|
let projectId = e.detail.id;
|
||||||
|
let projectName = e.detail.text;
|
||||||
|
app.globalData.useProjectId = projectId;
|
||||||
|
app.globalData.useProjectName = projectName;
|
||||||
|
this.onLoad({type:this.data.type});
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 生命周期函数--监听页面加载
|
* 生命周期函数--监听页面加载
|
||||||
|
@ -72,83 +45,76 @@ import {
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
if(!getToken()){
|
if(!getToken()){
|
||||||
wx.redirectTo({
|
wx.redirectTo({
|
||||||
url: '../../login/index',
|
url: '../../login/login',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
//获取缓存数据
|
this.setData({
|
||||||
wx.getStorage({
|
type:options.type,
|
||||||
key: 'YanZhu-XD-App-UserInfoKey',
|
typeName:options.type==1?"质量":"安全",
|
||||||
success:res=>{
|
projectId:app.globalData.useProjectId,
|
||||||
console.log("YanZhu-XD-App-UserInfoKey");
|
projectName:app.globalData.useProjectName,
|
||||||
this.setData({
|
initData: {
|
||||||
type:options.type,
|
id: app.globalData.useProjectId,
|
||||||
typeName:options.type==1?"质量":"安全",
|
text: app.globalData.useProjectName,
|
||||||
deptId:res.data.deptId,
|
},
|
||||||
loginName:res.data.loginName,
|
pageNum:1,
|
||||||
userName:res.data.userName,
|
pageSize:10,
|
||||||
minRoleId:res.data.minRoleId,
|
listData: [],
|
||||||
projectId:app.globalData.projectId,
|
total: 0
|
||||||
projectNameArgs:app.globalData.projectName,
|
});
|
||||||
initData:{id:app.globalData.useProjectId,text:app.globalData.useProjectName},
|
this.getListData();
|
||||||
pageNum:1,
|
|
||||||
pageSize:10,
|
|
||||||
lastDataSize:10,
|
|
||||||
listData:[]
|
|
||||||
});
|
|
||||||
//this.getListData();
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加隐患信息
|
||||||
|
*/
|
||||||
|
skipAdd(){
|
||||||
|
wx.redirectTo({
|
||||||
|
url: `../add/index?projectId=${this.data.initData.id}&projectName=`+this.data.initData.text,
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加隐患草稿
|
||||||
|
*/
|
||||||
|
skipAddDarft(){
|
||||||
|
wx.redirectTo({
|
||||||
|
url: `../draft/index`,
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
getInfo(e){
|
||||||
|
let {id,checkState,lordSentUser,recheckSendUser} = e.currentTarget.dataset.set
|
||||||
|
if((checkState==0 || checkState==3) && lordSentUser==this.data.loginName){
|
||||||
|
//整改页面(状态时待整改&&整改人是当前登录人)
|
||||||
|
wx.redirectTo({
|
||||||
|
url: `../modify/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}else if(checkState==1 && recheckSendUser==this.data.loginName){
|
||||||
|
//复检页面 (状态时待复检&&复检人是当前登录人)
|
||||||
|
wx.redirectTo({
|
||||||
|
url: `../check/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
wx.redirectTo({
|
||||||
|
url: `../info/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询项目质量隐患排查数据
|
* 查询项目质量隐患排查数据
|
||||||
*/
|
*/
|
||||||
getListData() {
|
getListData() {
|
||||||
//进入这里说明数据加载完毕
|
let params = "pageNum=" + this.data.pageNum + "&pageSize=" + this.data.pageSize + "&projectId" + app.globalData.useProjectId+"&infoType="+this.data.type;
|
||||||
if(this.data.lastDataSize<this.data.pageSize){
|
list(params).then(res =>{
|
||||||
//app.toast("已经到底了,暂无可继续加载数据!")
|
if(res.data == 200){
|
||||||
return;
|
this.setData({
|
||||||
}
|
total: res.total,
|
||||||
let nowRole = "99";
|
listData: this.data.listData.concat(res.rows)
|
||||||
//判断角色,
|
})
|
||||||
if(this.data.minRoleId==2||this.data.minRoleId==3||this.data.minRoleId==4){
|
|
||||||
nowRole="-1";
|
|
||||||
}
|
|
||||||
let param = {
|
|
||||||
"infoType":"1",//1质量类,0安全类
|
|
||||||
"projectId": this.data.projectId,
|
|
||||||
"nowRole":nowRole,//默认传普通角色,真实角色查看的数据量太大,这里只查看自己相关的数据
|
|
||||||
"nowUser":this.data.loginName,
|
|
||||||
"activeName":this.data.activeState
|
|
||||||
}
|
|
||||||
var that = this;
|
|
||||||
that.queryCount(param);
|
|
||||||
param.pageNum=that.data.pageNum;
|
|
||||||
param.pageSize=that.data.pageSize;
|
|
||||||
wx.request({
|
|
||||||
url: app.globalData.reqUrl + '/wechat/projectProblemmodify/list',
|
|
||||||
data:param,
|
|
||||||
method: "get",
|
|
||||||
success: function (res) {
|
|
||||||
res = res.data;
|
|
||||||
if(res.code=="200"){
|
|
||||||
//这里处理this.data.lastDataSize=this.data.pageSize
|
|
||||||
if(that.data.list.length>0 && res.data.length>0 && that.data.list[0].id==res.data[0].id){
|
|
||||||
that.setData({
|
|
||||||
lastDataSize:0,
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.setData({
|
|
||||||
pageNum:that.data.pageNum+1,
|
|
||||||
lastDataSize:res.data.length,
|
|
||||||
list:res.data,
|
|
||||||
listData:that.data.listData.concat(res.data)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
queryCount(param){
|
queryCount(param){
|
||||||
|
@ -195,22 +161,17 @@ import {
|
||||||
let index = e.currentTarget.dataset.index;
|
let index = e.currentTarget.dataset.index;
|
||||||
let nav = "";
|
let nav = "";
|
||||||
if(index == 1){
|
if(index == 1){
|
||||||
nav = 'zg';
|
nav = 'dzg';
|
||||||
}if(index == 2){
|
}if(index == 2){
|
||||||
nav = 'fj';
|
nav = 'dfj';
|
||||||
}else if(index == 3){
|
}else if(index == 3){
|
||||||
nav = 'ycl';
|
nav = 'ycl';
|
||||||
}else if(index == 4){
|
|
||||||
nav = 'zgcs';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this.setData({
|
this.setData({
|
||||||
activeState:nav,
|
activeState:nav,
|
||||||
pageNum:1,
|
pageNum: 1,
|
||||||
pageSize:10,
|
pageSize: 10,
|
||||||
lastDataSize:10,
|
listData: [],
|
||||||
listData:[],
|
|
||||||
list:[]
|
|
||||||
});
|
});
|
||||||
this.getListData();
|
this.getListData();
|
||||||
},
|
},
|
||||||
|
@ -231,14 +192,20 @@ import {
|
||||||
|
|
||||||
returnToPage: function () {
|
returnToPage: function () {
|
||||||
/*关闭当前页面,跳转到应用内的某个页面。但是不允许跳转到 tabbar 页面*/
|
/*关闭当前页面,跳转到应用内的某个页面。但是不允许跳转到 tabbar 页面*/
|
||||||
if(wx.getStorageSync('nav-menu')=="gd"){
|
if(wx.getStorageSync('nav-menu')=="gdgn"){
|
||||||
wx.redirectTo({
|
wx.redirectTo({
|
||||||
url: '../../../../pages/gengduogongneng/index',
|
url: '../../project_more/index',
|
||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
wx.redirectTo({
|
if(this.data.type==1){
|
||||||
url: '../../../../pages/quality_manage/index',
|
wx.redirectTo({
|
||||||
})
|
url: '../../../../pages/quality_manage/index',
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
wx.redirectTo({
|
||||||
|
url: '../../../../pages/quality_manage/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -252,8 +219,15 @@ import {
|
||||||
},
|
},
|
||||||
|
|
||||||
onScrollToLower(){
|
onScrollToLower(){
|
||||||
console.log("滚动条到底了,开始加载新数据");
|
let nal = Math.ceil(this.data.total / this.data.pageSize);
|
||||||
this.getListData();
|
if (this.data.pageNum < nal) {
|
||||||
|
this.setData({
|
||||||
|
pageNum: this.data.pageNum + 1
|
||||||
|
});
|
||||||
|
this.getListData();
|
||||||
|
}else{
|
||||||
|
console.log("已经到底了,没有数据可加载!!!");
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -15,10 +15,9 @@
|
||||||
<scroll-view class="max_content_scroll" type="list" scroll-y bindscrolltolower="onScrollToLower">
|
<scroll-view class="max_content_scroll" type="list" scroll-y bindscrolltolower="onScrollToLower">
|
||||||
<project-select init="{{initData}}" bindchange="onProjectSelect" id="projectSel"></project-select>
|
<project-select init="{{initData}}" bindchange="onProjectSelect" id="projectSel"></project-select>
|
||||||
<view class="modify_video_nav" style="margin-top: 5rpx;">
|
<view class="modify_video_nav" style="margin-top: 5rpx;">
|
||||||
<view class="{{activeState=='zg'?'active':''}}" bindtap="trainingTypeJump" data-index="1"><text>整改({{dzgCount}})</text></view>
|
<view class="{{activeState=='dzg'?'active':''}}" bindtap="trainingTypeJump" data-index="1"><text>整改({{dzgCount}})</text></view>
|
||||||
<view class="{{activeState=='fj'?'active':''}}" bindtap="trainingTypeJump" data-index="2"><text>复检({{dfjCount}})</text></view>
|
<view class="{{activeState=='dfj'?'active':''}}" bindtap="trainingTypeJump" data-index="2"><text>复检({{dfjCount}})</text></view>
|
||||||
<view class="{{activeState=='ycl'?'active':''}}" bindtap="trainingTypeJump" data-index="3"><text>完成({{yclCount}})</text></view>
|
<view class="{{activeState=='ycl'?'active':''}}" bindtap="trainingTypeJump" data-index="3"><text>完成({{yclCount}})</text></view>
|
||||||
<view class="{{activeState=='zgcs'?'active':''}}" bindtap="trainingTypeJump" data-index="4"><text>超时({{zgcsCount}})</text></view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="inspect_max_scroll">
|
<view class="inspect_max_scroll">
|
||||||
<!--专项检查样式zxjc-->
|
<!--专项检查样式zxjc-->
|
||||||
|
@ -26,7 +25,7 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title_3 module_title_flex inspect_list_title_text_2">
|
<view class="module_title_3 module_title_flex inspect_list_title_text_2">
|
||||||
<view wx:if="{{item.checkState==0}}" class="code_label code_label_yellow">待整改</view>
|
<view wx:if="{{item.checkState==0}}" class="code_label code_label_yellow">待整改</view>
|
||||||
<view wx:if="{{item.checkState==1}}" class="code_label code_label_blueviolet">待复检</view>
|
<view wx:if="{{item.checkState==1}}" class="code_label code_label_blueviolet">待复检</view>
|
||||||
|
|
|
@ -505,9 +505,10 @@ Page({
|
||||||
let videoSize = this.data.eduVideoItem.length;
|
let videoSize = this.data.eduVideoItem.length;
|
||||||
let currentVideo = this.data.videoIdx + 1;
|
let currentVideo = this.data.videoIdx + 1;
|
||||||
if (currentVideo >= videoSize) {
|
if (currentVideo >= videoSize) {
|
||||||
finishEduVideo(this.data.eduVideoItem[this.data.videoIdx].remark);
|
finishEduVideo(this.data.eduVideoItem[this.data.videoIdx].remark).then(res =>{
|
||||||
//视频学习完成...
|
//视频学习完成...
|
||||||
app.toast("学习完成,您可以开始考试了。", "none", 3000);
|
app.toast("学习完成,您可以开始考试了。", "none", 3000);
|
||||||
|
});
|
||||||
} else {
|
} else {
|
||||||
endPlayUserEduVideo(this.data.eduVideoItem[this.data.videoIdx].remark);
|
endPlayUserEduVideo(this.data.eduVideoItem[this.data.videoIdx].remark);
|
||||||
startPlayUserEduVideo(this.data.eduVideoItem[currentVideo].remark);
|
startPlayUserEduVideo(this.data.eduVideoItem[currentVideo].remark);
|
||||||
|
@ -1211,7 +1212,6 @@ Page({
|
||||||
this.setData({
|
this.setData({
|
||||||
"form.cardImgPos": file
|
"form.cardImgPos": file
|
||||||
});
|
});
|
||||||
console.log("filefilefilefile", file)
|
|
||||||
file.forEach(async (item, idx) => {
|
file.forEach(async (item, idx) => {
|
||||||
let obj = await this.syncUploadImage(item);
|
let obj = await this.syncUploadImage(item);
|
||||||
findCardOcrFront(obj.data.data.url).then(res => {
|
findCardOcrFront(obj.data.data.url).then(res => {
|
||||||
|
|
|
@ -687,8 +687,8 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title module_title_flex inspect_list_title_text" style="font-weight: 600;">第{{index < 9 ?'0'+(index+1):(index+1)}}题({{item.mark}}分)</view>
|
<view class="module_title module_title_flex inspect_list_title_text" style="font-weight: 600;">第{{index < 10 ?'0'+(index+1):(index+1)}}题({{item.mark}}分)</view>
|
||||||
<view class="code_label_4 code_label_blue">
|
<view class="code_label_4 code_label_blue">
|
||||||
<text wx:if="{{item.questionType==1}}">单选题</text>
|
<text wx:if="{{item.questionType==1}}">单选题</text>
|
||||||
<text wx:if="{{item.questionType==2}}">多选题</text>
|
<text wx:if="{{item.questionType==2}}">多选题</text>
|
||||||
|
@ -753,8 +753,8 @@
|
||||||
<view class="inspect_for_bgd">
|
<view class="inspect_for_bgd">
|
||||||
<view class="inspect_list_title">
|
<view class="inspect_list_title">
|
||||||
<view class="inspect_list_title_label inspect_list_title_width">
|
<view class="inspect_list_title_label inspect_list_title_width">
|
||||||
<view class="inspect_list_title_number">{{index < 9 ?'0'+(index+1):(index+1)}}</view>
|
<view class="inspect_list_title_number">{{index < 10 ?'0'+(index+1):(index+1)}}</view>
|
||||||
<view class="module_title module_title_flex inspect_list_title_text" style="font-weight: 600;">第{{index < 9 ?'0'+(index+1):(index+1)}}题({{item.mark}}分)</view>
|
<view class="module_title module_title_flex inspect_list_title_text" style="font-weight: 600;">第{{index < 10 ?'0'+(index+1):(index+1)}}题({{item.mark}}分)</view>
|
||||||
<view class="code_label_4 code_label_blue">
|
<view class="code_label_4 code_label_blue">
|
||||||
<text wx:if="{{item.questionType==1}}">单选题</text>
|
<text wx:if="{{item.questionType==1}}">单选题</text>
|
||||||
<text wx:if="{{item.questionType==2}}">多选题</text>
|
<text wx:if="{{item.questionType==2}}">多选题</text>
|
||||||
|
|
|
@ -336,14 +336,3 @@
|
||||||
.problem_submit_to_save_s:active {
|
.problem_submit_to_save_s:active {
|
||||||
background: #372a70;
|
background: #372a70;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markers{
|
|
||||||
background: url("https://xiangguan.sxyanzhu.com/profile/icon/req.png") no-repeat left/40rpx;
|
|
||||||
height: 20px;
|
|
||||||
line-height: 20px;
|
|
||||||
padding-left: 42rpx;
|
|
||||||
white-space: nowrap;
|
|
||||||
text-overflow: ellipsis;
|
|
||||||
overflow: hidden;
|
|
||||||
word-break: break-all;
|
|
||||||
}
|
|
|
@ -11,7 +11,7 @@
|
||||||
{
|
{
|
||||||
"name": "pages/project_qr/index",
|
"name": "pages/project_qr/index",
|
||||||
"pathName": "pages/project_qr/index",
|
"pathName": "pages/project_qr/index",
|
||||||
"query": "QRPID=133&SIGID=1",
|
"query": "QRPID=133&SIGID=3&PARID=109",
|
||||||
"launchMode": "default",
|
"launchMode": "default",
|
||||||
"scene": null
|
"scene": null
|
||||||
},
|
},
|
||||||
|
|
|
@ -387,7 +387,7 @@ const data = reactive({
|
||||||
userWorkType: null,
|
userWorkType: null,
|
||||||
workType: null,
|
workType: null,
|
||||||
activeTags:"finished",
|
activeTags:"finished",
|
||||||
searchValue:"active1"
|
searchValue:"subUsers"
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
subDeptId: [{ required: true, trigger: ['blur', 'change'], message: "请选择所属单位" }],
|
subDeptId: [{ required: true, trigger: ['blur', 'change'], message: "请选择所属单位" }],
|
||||||
|
|
Loading…
Reference in New Issue