Commit 7110c2ab authored by 耿迪迪's avatar 耿迪迪

工商业安检任务修改

parent eaf9791e
......@@ -187,6 +187,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="inspectStatus!=null and inspectStatus== -1"> and taskInspect.status is null</if>
<if test="inspectSign != null"> and taskInspect.sign = #{inspectSign}</if>
<if test="inspector != null and inspector != ''"> and us.nick_name like concat('%',#{inspector},'%')</if>
<if test="taskType != null and taskType != ''">and industry.task_type = #{taskType}</if>
</where>
order by taskInspect.create_time desc
</select>
......
......@@ -176,7 +176,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
IFNULL(inspect.status,-1) AS inspectStatus,
inspect.satisfy ,
u.usernum,u.username,u.phone,u.id AS userId,u.company AS companyName,
u.contract,
u.contract,u.task_type as taskType,
u.type as btype,u.address,u.create_time as userTime,u.status as ustatus,
t.`area_name` AS countyName,
ts.`area_name` AS streetName,
......@@ -200,6 +200,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="inspectStatus!=null and inspectStatus != -1" > and inspect.status = #{inspectStatus}</if>
<if test="inspectStatus!=null and inspectStatus== -1"> and inspect.status is null</if>
<if test="nickName!=null and nickName!=''"> and su.nick_name like concat('%',#{nickName},'%')</if>
<if test="taskType !=null and taskType!=''"> and u.task_type = #{taskType}</if>
</where>
order by inspect.create_time desc
</select>
......
......@@ -248,8 +248,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
(select count(1) from t_user u where u.village in (select re.relation_id from t_task_relation_info re where re.task_id = t.id and re.type = '1')),
(select count(1) from t_user u WHERE u.task_type = t.task_type and u.village in (select re.relation_id from t_task_relation_info re where re.task_id = t.id and re.type = '1'))
)
when 3 then (select count(1) from t_industry)
else (select count(1) from t_business)
when 3 then (select count(1) from t_industry ind where ind.task_type = t.check_type)
else (select count(1) from t_business busi where busi.task_type = t.business_type)
end)as totalInspectNum
FROM
t_task t
......@@ -261,9 +261,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="taskInspectDetailInfo" parameterType="Map" resultType="Map">
SELECT
SUM(IF(ISNULL(ti.status),1,0))AS noInspectNum,
SUM(IF(ti.status = 0 and ti.totalMissNum = 1 ,1,0))AS firstMissNum,
SUM(IF(ti.status = 0 and ti.totalMissNum = 2 ,1,0))AS secondeMissNum,
SUM(IF(ti.status = 0 and ti.totalMissNum = 3 ,1,0))AS thirdMissNum,
<if test="type == 1">
SUM(IF(ti.status = 0 and ti.totalMissNum = 1 ,1,0))AS firstMissNum,
SUM(IF(ti.status = 0 and ti.totalMissNum = 2 ,1,0))AS secondeMissNum,
SUM(IF(ti.status = 0 and ti.totalMissNum = 3 ,1,0))AS thirdMissNum,
</if>
<if test="type != 1">
SUM(IF(ti.status = 0,1,0))AS missNum,
</if>
SUM(IF(ti.status = 1,1,0))AS refuseNum,
SUM(IF(ti.status = 2,1,0))AS inspectNum,
SUM(IF(ti.status = 3,1,0))AS beforeNum
......
......@@ -466,6 +466,7 @@ export default {
created() {
this.queryParams.taskId = this.$route.query.taskId;
this.queryParams.type = this.$route.query.type;
this.queryParams.taskType = this.$route.query.taskType;
console.log(this.$route.query.taskId);
this.getDicts("t_meter_type").then((response) => {
this.typeOptions = response.data;
......@@ -637,7 +638,7 @@ export default {
})
},
taskInspectDetail(){
taskInspectDetailInfo({taskId:this.$route.query.taskId,type:this.$route.query.type}).then(res =>{
taskInspectDetailInfo({taskId:this.$route.query.taskId,type:this.$route.query.type,taskType:this.$route.query.taskType}).then(res =>{
if(res.code == 200){
let data = res.data;
this.itemDataA[0].val = data.noInspectNum;
......
......@@ -316,6 +316,7 @@ export default {
created() {
this.queryParams.taskId = this.$route.query.taskId;
this.queryParams.type = this.$route.query.type;
this.queryParams.taskType = this.$route.query.checkType;
this.getList();
this.getDicts("t_user_status").then((response) => {
this.statusOptions = response.data;
......@@ -350,7 +351,7 @@ export default {
})
},
taskInspectDetail(){
taskInspectDetailInfo({taskId:this.$route.query.taskId,type:this.$route.query.type}).then(res =>{
taskInspectDetailInfo({taskId:this.$route.query.taskId,type:this.$route.query.type,taskType: this.$route.query.checkType}).then(res =>{
if(res.code == 200){
let data = res.data;
this.itemDataA[0].val = data.noInspectNum;
......
......@@ -504,7 +504,7 @@ export default {
//this.$router.push("inspect?taskId="+row.id)
this.$router.push({
path: "/checktask/cyInspect",
query: { taskId: row.id,type:row.type },
query: { taskId: row.id,type:row.type, taskType: row.businessType },
});
},
/** 提交按钮 */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment