Commit 39fbb01a authored by wuqinghua's avatar wuqinghua

Merge remote-tracking branch 'origin/master'

parents 9b70cb49 0f2b1cdb
package com.zehong.web.controller.complainDeal; package com.zehong.web.controller.complainDeal;
import java.util.Date;
import java.util.List; import java.util.List;
import com.zehong.common.core.domain.model.LoginUser; import com.zehong.common.core.domain.model.LoginUser;
...@@ -51,7 +52,6 @@ public class TComplainDealController extends BaseController ...@@ -51,7 +52,6 @@ public class TComplainDealController extends BaseController
if(loginUser.getUser().getDeptId()!=-2){ if(loginUser.getUser().getDeptId()!=-2){
tComplainDeal.setComplainAssignEnterproseId(loginUser.getUser().getDeptId()); tComplainDeal.setComplainAssignEnterproseId(loginUser.getUser().getDeptId());
} }
System.out.println("=========="+loginUser.getUser().getDeptId());
startPage(); startPage();
List<TComplainDeal> list = tComplainDealService.selectTComplainDealList(tComplainDeal); List<TComplainDeal> list = tComplainDealService.selectTComplainDealList(tComplainDeal);
return getDataTable(list); return getDataTable(list);
...@@ -99,6 +99,9 @@ public class TComplainDealController extends BaseController ...@@ -99,6 +99,9 @@ public class TComplainDealController extends BaseController
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody TComplainDeal tComplainDeal) public AjaxResult edit(@RequestBody TComplainDeal tComplainDeal)
{ {
if(tComplainDeal.getComplainStatus().equals("2")){
tComplainDeal.setDealTime(new Date());
}
return toAjax(tComplainDealService.updateTComplainDeal(tComplainDeal)); return toAjax(tComplainDealService.updateTComplainDeal(tComplainDeal));
} }
......
...@@ -8,13 +8,15 @@ import com.zehong.common.utils.file.FileUploadUtils; ...@@ -8,13 +8,15 @@ import com.zehong.common.utils.file.FileUploadUtils;
import com.zehong.common.utils.file.FileUtils; import com.zehong.common.utils.file.FileUtils;
import com.zehong.framework.config.ServerConfig; import com.zehong.framework.config.ServerConfig;
import com.zehong.system.domain.THiddenDangerStandingBook; import com.zehong.system.domain.THiddenDangerStandingBook;
import com.zehong.system.domain.TSafeEquipmentStandingBook;
import com.zehong.system.domain.TTroubleStandingBook; import com.zehong.system.domain.TTroubleStandingBook;
import com.zehong.system.domain.TVideoManager;
import com.zehong.system.domain.form.THiddenDangerStandingBookForm; import com.zehong.system.domain.form.THiddenDangerStandingBookForm;
import com.zehong.system.domain.form.TTroubleStandingBookForm; import com.zehong.system.domain.form.TTroubleStandingBookForm;
import com.zehong.system.domain.vo.HomepageVo;
import com.zehong.system.domain.vo.THiddenDangerStandingBookVo; import com.zehong.system.domain.vo.THiddenDangerStandingBookVo;
import com.zehong.system.domain.vo.TTroubleStandingBookVo; import com.zehong.system.domain.vo.TTroubleStandingBookVo;
import com.zehong.system.service.ITHiddenDangerStandingBookService; import com.zehong.system.service.*;
import com.zehong.system.service.ITTroubleStandingBookService;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -41,10 +43,18 @@ public class StatisticController ...@@ -41,10 +43,18 @@ public class StatisticController
{ {
private static final Logger log = LoggerFactory.getLogger(StatisticController.class); private static final Logger log = LoggerFactory.getLogger(StatisticController.class);
@Autowired
private ITVideoManagerService tVideoManagerService;
@Autowired
private ITSafeEquipmentStandingBookService tSafeEquipmentStandingBookService;
@Autowired @Autowired
private ITTroubleStandingBookService tTroubleStandingBookService; private ITTroubleStandingBookService tTroubleStandingBookService;
@Autowired @Autowired
private ITHiddenDangerStandingBookService tHiddenDangerStandingBookService; private ITHiddenDangerStandingBookService tHiddenDangerStandingBookService;
@Autowired
private ITComplainDealService tComplainDealService;
@Autowired
private ITWorkOrderService tWorkOrderService;
/** /**
* 燃气事故台账统计 * 燃气事故台账统计
...@@ -64,4 +74,29 @@ public class StatisticController ...@@ -64,4 +74,29 @@ public class StatisticController
return AjaxResult.success(tHiddenDangerStandingBookService.selectTHiddenDangerStandingBookStatistic()); return AjaxResult.success(tHiddenDangerStandingBookService.selectTHiddenDangerStandingBookStatistic());
} }
/**
* 首页统计
*/
@GetMapping("/homepageStatistic")
public AjaxResult homepageStatistic()
{
HomepageVo homepageVo = new HomepageVo();
homepageVo = tComplainDealService.countTComplainDeal();
homepageVo.setTaskTotal(tWorkOrderService.countTWorkOrder().getTaskTotal());
homepageVo.setTaskFeedbackTotal(tWorkOrderService.countTWorkOrder().getTaskFeedbackTotal());
List<TVideoManager> tVideoManagerList = tVideoManagerService.selectTVideoManagerList(null);
List<TSafeEquipmentStandingBook> tSafeEquipmentStandingBookList = tSafeEquipmentStandingBookService.selectTSafeEquipmentStandingBookList(null);
List<TTroubleStandingBook> tTroubleStandingBookList = tTroubleStandingBookService.selectTTroubleStandingBookList(null);
List<THiddenDangerStandingBook> tHiddenDangerStandingBookList = tHiddenDangerStandingBookService.selectTHiddenDangerStandingBookList(null);
homepageVo.setVideoTotal(tVideoManagerList.size());
homepageVo.setEquipmentTotal(tSafeEquipmentStandingBookList.size());
homepageVo.setTroubleTotal(tTroubleStandingBookList.size());
homepageVo.setHiddenTotal(tHiddenDangerStandingBookList.size());
return AjaxResult.success(homepageVo);
}
} }
package com.zehong.system.domain; package com.zehong.system.domain;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle; import org.apache.commons.lang3.builder.ToStringStyle;
import com.zehong.common.annotation.Excel; import com.zehong.common.annotation.Excel;
import com.zehong.common.core.domain.BaseEntity; import com.zehong.common.core.domain.BaseEntity;
import java.util.Date;
/** /**
* 投诉处置对象 t_complain_deal * 投诉处置对象 t_complain_deal
* *
...@@ -34,8 +37,11 @@ public class TComplainDeal extends BaseEntity ...@@ -34,8 +37,11 @@ public class TComplainDeal extends BaseEntity
@Excel(name = "转办记录") @Excel(name = "转办记录")
private String transferRecord; private String transferRecord;
@Excel(name = "反馈事件")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date dealTime;
/** 办理情况 */ /** 办理情况 */
@Excel(name = "办理情况") @Excel(name = "办理反馈情况")
private String dealCondition; private String dealCondition;
/** 指派单位名称 */ /** 指派单位名称 */
...@@ -184,6 +190,14 @@ public class TComplainDeal extends BaseEntity ...@@ -184,6 +190,14 @@ public class TComplainDeal extends BaseEntity
return remarks; return remarks;
} }
public Date getDealTime() {
return dealTime;
}
public void setDealTime(Date dealTime) {
this.dealTime = dealTime;
}
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
......
package com.zehong.system.domain.vo;
import lombok.Data;
@Data
public class HomepageVo
{
// 任务总数
private int taskTotal;
// 任务反馈总数
private int taskFeedbackTotal;
// 投诉总数
private int complaintTotal;
// 投诉反馈总数
private int complaintFeedbackTotal;
// 视频监控总数
private int videoTotal;
// 安全装置总数
private int equipmentTotal;
// 事故总数
private int troubleTotal;
// 隐患总数
private int hiddenTotal;
}
...@@ -5,6 +5,7 @@ import java.util.Map; ...@@ -5,6 +5,7 @@ import java.util.Map;
import java.util.Objects; import java.util.Objects;
import com.zehong.system.domain.TComplainDeal; import com.zehong.system.domain.TComplainDeal;
import com.zehong.system.domain.vo.HomepageVo;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
/** /**
...@@ -31,6 +32,13 @@ public interface TComplainDealMapper ...@@ -31,6 +32,13 @@ public interface TComplainDealMapper
*/ */
public List<TComplainDeal> selectTComplainDealList(TComplainDeal tComplainDeal); public List<TComplainDeal> selectTComplainDealList(TComplainDeal tComplainDeal);
/**
* 投诉处置统计
*
* @return 投诉处置统计
*/
public HomepageVo countTComplainDeal();
/** /**
* 新增投诉处置 * 新增投诉处置
* *
......
...@@ -2,6 +2,7 @@ package com.zehong.system.mapper; ...@@ -2,6 +2,7 @@ package com.zehong.system.mapper;
import java.util.List; import java.util.List;
import com.zehong.system.domain.TWorkOrder; import com.zehong.system.domain.TWorkOrder;
import com.zehong.system.domain.vo.HomepageVo;
/** /**
* 燃气任务Mapper接口 * 燃气任务Mapper接口
...@@ -27,6 +28,13 @@ public interface TWorkOrderMapper ...@@ -27,6 +28,13 @@ public interface TWorkOrderMapper
*/ */
public List<TWorkOrder> selectTWorkOrderList(TWorkOrder tWorkOrder); public List<TWorkOrder> selectTWorkOrderList(TWorkOrder tWorkOrder);
/**
* 燃气任务统计
*
* @return 燃气任务统计
*/
public HomepageVo countTWorkOrder();
/** /**
* 新增燃气任务 * 新增燃气任务
* *
......
...@@ -4,6 +4,7 @@ import java.util.List; ...@@ -4,6 +4,7 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import com.zehong.system.domain.TComplainDeal; import com.zehong.system.domain.TComplainDeal;
import com.zehong.system.domain.vo.HomepageVo;
/** /**
* 投诉处置Service接口 * 投诉处置Service接口
...@@ -29,6 +30,13 @@ public interface ITComplainDealService ...@@ -29,6 +30,13 @@ public interface ITComplainDealService
*/ */
public List<TComplainDeal> selectTComplainDealList(TComplainDeal tComplainDeal); public List<TComplainDeal> selectTComplainDealList(TComplainDeal tComplainDeal);
/**
* 投诉处置统计
*
* @return 投诉处置统计
*/
public HomepageVo countTComplainDeal();
/** /**
* 新增投诉处置 * 新增投诉处置
* *
......
...@@ -2,6 +2,7 @@ package com.zehong.system.service; ...@@ -2,6 +2,7 @@ package com.zehong.system.service;
import java.util.List; import java.util.List;
import com.zehong.system.domain.TWorkOrder; import com.zehong.system.domain.TWorkOrder;
import com.zehong.system.domain.vo.HomepageVo;
/** /**
* 燃气任务Service接口 * 燃气任务Service接口
...@@ -27,6 +28,13 @@ public interface ITWorkOrderService ...@@ -27,6 +28,13 @@ public interface ITWorkOrderService
*/ */
public List<TWorkOrder> selectTWorkOrderList(TWorkOrder tWorkOrder); public List<TWorkOrder> selectTWorkOrderList(TWorkOrder tWorkOrder);
/**
* 燃气任务统计
*
* @return 燃气任务统计
*/
public HomepageVo countTWorkOrder();
/** /**
* 新增燃气任务 * 新增燃气任务
* *
......
...@@ -4,6 +4,7 @@ import java.util.List; ...@@ -4,6 +4,7 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import com.zehong.common.utils.DateUtils; import com.zehong.common.utils.DateUtils;
import com.zehong.system.domain.vo.HomepageVo;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.zehong.system.mapper.TComplainDealMapper; import com.zehong.system.mapper.TComplainDealMapper;
...@@ -46,6 +47,16 @@ public class TComplainDealServiceImpl implements ITComplainDealService ...@@ -46,6 +47,16 @@ public class TComplainDealServiceImpl implements ITComplainDealService
return tComplainDealMapper.selectTComplainDealList(tComplainDeal); return tComplainDealMapper.selectTComplainDealList(tComplainDeal);
} }
/**
* 投诉处置统计
*
* @return 投诉处置统计
*/
public HomepageVo countTComplainDeal()
{
return tComplainDealMapper.countTComplainDeal();
}
/** /**
* 新增投诉处置 * 新增投诉处置
* *
......
...@@ -5,6 +5,7 @@ import com.zehong.common.utils.SecurityUtils; ...@@ -5,6 +5,7 @@ import com.zehong.common.utils.SecurityUtils;
import com.zehong.common.utils.StringUtils; import com.zehong.common.utils.StringUtils;
import com.zehong.system.domain.TEnterpriseInfo; import com.zehong.system.domain.TEnterpriseInfo;
import com.zehong.system.domain.TWorkOrder; import com.zehong.system.domain.TWorkOrder;
import com.zehong.system.domain.vo.HomepageVo;
import com.zehong.system.mapper.TEnterpriseInfoMapper; import com.zehong.system.mapper.TEnterpriseInfoMapper;
import com.zehong.system.mapper.TWorkOrderMapper; import com.zehong.system.mapper.TWorkOrderMapper;
import com.zehong.system.service.ITWorkOrderService; import com.zehong.system.service.ITWorkOrderService;
...@@ -52,6 +53,16 @@ public class TWorkOrderServiceImpl implements ITWorkOrderService ...@@ -52,6 +53,16 @@ public class TWorkOrderServiceImpl implements ITWorkOrderService
return tWorkOrderMapper.selectTWorkOrderList(tWorkOrder); return tWorkOrderMapper.selectTWorkOrderList(tWorkOrder);
} }
/**
* 燃气任务统计
*
* @return 燃气任务统计
*/
public HomepageVo countTWorkOrder()
{
return tWorkOrderMapper.countTWorkOrder();
}
/** /**
* 新增燃气任务 * 新增燃气任务
* *
...@@ -92,6 +103,9 @@ public class TWorkOrderServiceImpl implements ITWorkOrderService ...@@ -92,6 +103,9 @@ public class TWorkOrderServiceImpl implements ITWorkOrderService
{ {
tWorkOrder.setUpdateTime(DateUtils.getNowDate()); tWorkOrder.setUpdateTime(DateUtils.getNowDate());
tWorkOrder.setUpdateBy(SecurityUtils.getUsername()); tWorkOrder.setUpdateBy(SecurityUtils.getUsername());
/*if(StringUtils.isNotEmpty(tWorkOrder.getIconUrl()) || StringUtils.isNotEmpty(tWorkOrder.getRectificationResult())){
tWorkOrder.setWorkStatus("2");
}*/
return tWorkOrderMapper.updateTWorkOrder(tWorkOrder); return tWorkOrderMapper.updateTWorkOrder(tWorkOrder);
} }
......
...@@ -10,6 +10,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -10,6 +10,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="complainPhone" column="complain_phone" /> <result property="complainPhone" column="complain_phone" />
<result property="complainMatter" column="complain_matter" /> <result property="complainMatter" column="complain_matter" />
<result property="transferRecord" column="transfer_record" /> <result property="transferRecord" column="transfer_record" />
<result property="dealTime" column="deal_time" />
<result property="dealCondition" column="deal_condition" /> <result property="dealCondition" column="deal_condition" />
<result property="complainAssignEnterproseName" column="complain_assign_enterprose_name" /> <result property="complainAssignEnterproseName" column="complain_assign_enterprose_name" />
<result property="complainAssignEnterproseId" column="complain_assign_enterprose_id" /> <result property="complainAssignEnterproseId" column="complain_assign_enterprose_id" />
...@@ -25,7 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -25,7 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap> </resultMap>
<sql id="selectTComplainDealVo"> <sql id="selectTComplainDealVo">
select complain_deal_id, complain_name, complain_phone, complain_matter, transfer_record, deal_condition, complain_assign_enterprose_name, complain_assign_enterprose_id, complain_assign_man_id, complain_assign_man, complain_status, create_by, create_time, update_by, update_time, is_del, remarks from t_complain_deal select complain_deal_id, complain_name, complain_phone, complain_matter, transfer_record, deal_time,deal_condition, complain_assign_enterprose_name, complain_assign_enterprose_id, complain_assign_man_id, complain_assign_man, complain_status, create_by, create_time, update_by, update_time, is_del, remarks from t_complain_deal
</sql> </sql>
<select id="selectTComplainDealList" parameterType="TComplainDeal" resultMap="TComplainDealResult"> <select id="selectTComplainDealList" parameterType="TComplainDeal" resultMap="TComplainDealResult">
...@@ -44,13 +45,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -44,13 +45,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="isDel != null and isDel != ''"> and is_del = #{isDel}</if> <if test="isDel != null and isDel != ''"> and is_del = #{isDel}</if>
<if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if> <if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if>
</where> </where>
order by create_time desc
</select> </select>
<select id="selectTComplainDealById" parameterType="Long" resultMap="TComplainDealResult"> <select id="selectTComplainDealById" parameterType="Long" resultMap="TComplainDealResult">
<include refid="selectTComplainDealVo"/> <include refid="selectTComplainDealVo"/>
where complain_deal_id = #{complainDealId} where complain_deal_id = #{complainDealId}
</select> </select>
<select id="countTComplainDeal" resultType="HomepageVo">
select COUNT(t.complain_deal_id) AS complaintTotal,
SUM(CASE t.complain_status WHEN '2' THEN 1 ELSE 0 END) AS complaintFeedbackTotal
from (select * from t_complain_deal where is_del = '0') t
</select>
<insert id="insertTComplainDeal" parameterType="TComplainDeal" useGeneratedKeys="true" keyProperty="complainDealId"> <insert id="insertTComplainDeal" parameterType="TComplainDeal" useGeneratedKeys="true" keyProperty="complainDealId">
insert into t_complain_deal insert into t_complain_deal
<trim prefix="(" suffix=")" suffixOverrides=","> <trim prefix="(" suffix=")" suffixOverrides=",">
...@@ -58,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -58,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="complainPhone != null">complain_phone,</if> <if test="complainPhone != null">complain_phone,</if>
<if test="complainMatter != null">complain_matter,</if> <if test="complainMatter != null">complain_matter,</if>
<if test="transferRecord != null">transfer_record,</if> <if test="transferRecord != null">transfer_record,</if>
<if test="dealTime !=null">deal_time,</if>
<if test="dealCondition != null">deal_condition,</if> <if test="dealCondition != null">deal_condition,</if>
<if test="complainAssignEnterproseName != null">complain_assign_enterprose_name,</if> <if test="complainAssignEnterproseName != null">complain_assign_enterprose_name,</if>
<if test="complainAssignEnterproseId != null">complain_assign_enterprose_id,</if> <if test="complainAssignEnterproseId != null">complain_assign_enterprose_id,</if>
...@@ -76,6 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -76,6 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="complainPhone != null">#{complainPhone},</if> <if test="complainPhone != null">#{complainPhone},</if>
<if test="complainMatter != null">#{complainMatter},</if> <if test="complainMatter != null">#{complainMatter},</if>
<if test="transferRecord != null">#{transferRecord},</if> <if test="transferRecord != null">#{transferRecord},</if>
<if test="dealTime != null">#{dealTime},</if>
<if test="dealCondition != null">#{dealCondition},</if> <if test="dealCondition != null">#{dealCondition},</if>
<if test="complainAssignEnterproseName != null">#{complainAssignEnterproseName},</if> <if test="complainAssignEnterproseName != null">#{complainAssignEnterproseName},</if>
<if test="complainAssignEnterproseId != null">#{complainAssignEnterproseId},</if> <if test="complainAssignEnterproseId != null">#{complainAssignEnterproseId},</if>
...@@ -98,6 +108,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -98,6 +108,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="complainPhone != null">complain_phone = #{complainPhone},</if> <if test="complainPhone != null">complain_phone = #{complainPhone},</if>
<if test="complainMatter != null">complain_matter = #{complainMatter},</if> <if test="complainMatter != null">complain_matter = #{complainMatter},</if>
<if test="transferRecord != null">transfer_record = #{transferRecord},</if> <if test="transferRecord != null">transfer_record = #{transferRecord},</if>
<if test="dealTime != null">deal_time = #{dealTime},</if>
<if test="dealCondition != null">deal_condition = #{dealCondition},</if> <if test="dealCondition != null">deal_condition = #{dealCondition},</if>
<if test="complainAssignEnterproseName != null">complain_assign_enterprose_name = #{complainAssignEnterproseName},</if> <if test="complainAssignEnterproseName != null">complain_assign_enterprose_name = #{complainAssignEnterproseName},</if>
<if test="complainAssignEnterproseId != null">complain_assign_enterprose_id = #{complainAssignEnterproseId},</if> <if test="complainAssignEnterproseId != null">complain_assign_enterprose_id = #{complainAssignEnterproseId},</if>
......
...@@ -28,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -28,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectTVideoManagerList" parameterType="TVideoManager" resultMap="TVideoManagerResult"> <select id="selectTVideoManagerList" parameterType="TVideoManager" resultMap="TVideoManagerResult">
<include refid="selectTVideoManagerVo"/> <include refid="selectTVideoManagerVo"/>
<where> <where> is_del = '0'
<if test="videoName != null and videoName != ''"> and video_name like concat('%', #{videoName}, '%')</if> <if test="videoName != null and videoName != ''"> and video_name like concat('%', #{videoName}, '%')</if>
<if test="resourceId != null and resourceId != ''"> and resource_id = #{resourceId}</if> <if test="resourceId != null and resourceId != ''"> and resource_id = #{resourceId}</if>
<if test="longitude != null "> and longitude = #{longitude}</if> <if test="longitude != null "> and longitude = #{longitude}</if>
...@@ -37,7 +37,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -37,7 +37,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="type != null and type != ''"> and type = #{type}</if> <if test="type != null and type != ''"> and type = #{type}</if>
<if test="beyondEnterpriseId != null "> and beyond_enterprise_id = #{beyondEnterpriseId}</if> <if test="beyondEnterpriseId != null "> and beyond_enterprise_id = #{beyondEnterpriseId}</if>
<if test="beyondEnterpriseName != null and beyondEnterpriseName != ''"> and beyond_enterprise_name like concat('%', #{beyondEnterpriseName}, '%')</if> <if test="beyondEnterpriseName != null and beyondEnterpriseName != ''"> and beyond_enterprise_name like concat('%', #{beyondEnterpriseName}, '%')</if>
<if test="isDel != null and isDel != ''"> and is_del = #{isDel}</if>
<if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if> <if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if>
</where> </where>
</select> </select>
......
...@@ -34,39 +34,77 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -34,39 +34,77 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap> </resultMap>
<sql id="selectTWorkOrderVo"> <sql id="selectTWorkOrderVo">
select work_id, work_title, work_type, work_content, work_create_enterprise_name, work_create_enterprise_id, work_assign_enterprose_name, work_assign_enterprose_id, work_assign_man_id, work_assign_man, work_status, inspection_date, inspection_route, problem_description, icon_url, rectification_plan, rectification_result, responsible_unit, responsible_person, expiry_date, create_by, create_time, update_by, update_time, is_del, remarks from t_work_order SELECT
workOrder.work_id,
workOrder.work_title,
workOrder.work_type,
workOrder.work_content,
workOrder.work_create_enterprise_name,
workOrder.work_create_enterprise_id,
info.enterprise_name AS work_assign_enterprose_name,
workOrder.work_assign_enterprose_id,
workOrder.work_assign_man_id,
usr.user_name AS work_assign_man,
workOrder.work_status,
workOrder.inspection_date,
workOrder.inspection_route,
workOrder.problem_description,
workOrder.icon_url,
workOrder.rectification_plan,
workOrder.rectification_result,
workOrder.responsible_unit,
workOrder.responsible_person,
workOrder.expiry_date,
workOrder.create_by,
workOrder.create_time,
workOrder.update_by,
workOrder.update_time,
workOrder.is_del,
workOrder.remarks
FROM
t_work_order workOrder
LEFT JOIN sys_user usr ON usr.user_id = workOrder.work_assign_man_id
LEFT JOIN t_enterprise_info info ON info.enterprise_id = workOrder.work_assign_enterprose_id
</sql> </sql>
<select id="selectTWorkOrderList" parameterType="TWorkOrder" resultMap="TWorkOrderResult"> <select id="selectTWorkOrderList" parameterType="TWorkOrder" resultMap="TWorkOrderResult">
<include refid="selectTWorkOrderVo"/> <include refid="selectTWorkOrderVo"/>
<where> <where>
<if test="workTitle != null and workTitle != ''"> and work_title like concat('%', #{workTitle}, '%')</if> <if test="workTitle != null and workTitle != ''"> and workOrder.work_title like concat('%', #{workTitle}, '%')</if>
<if test="workType != null and workType != ''"> and work_type = #{workType}</if> <if test="workType != null and workType != ''"> and workOrder.work_type = #{workType}</if>
<if test="workContent != null and workContent != ''"> and work_content = #{workContent}</if> <if test="workContent != null and workContent != ''"> and workOrder.work_content = #{workContent}</if>
<if test="workCreateEnterpriseName != null and workCreateEnterpriseName != ''"> and work_create_enterprise_name like concat('%', #{workCreateEnterpriseName}, '%')</if> <if test="workCreateEnterpriseName != null and workCreateEnterpriseName != ''"> and workOrder.work_create_enterprise_name like concat('%', #{workCreateEnterpriseName}, '%')</if>
<if test="workCreateEnterpriseId != null and workCreateEnterpriseId != ''"> and work_create_enterprise_id = #{workCreateEnterpriseId}</if> <if test="workCreateEnterpriseId != null and workCreateEnterpriseId != ''"> and workOrder.work_create_enterprise_id = #{workCreateEnterpriseId}</if>
<if test="workAssignEnterproseName != null and workAssignEnterproseName != ''"> and work_assign_enterprose_name like concat('%', #{workAssignEnterproseName}, '%')</if> <if test="workAssignEnterproseName != null and workAssignEnterproseName != ''"> and info.work_assign_enterprose_name like concat('%', #{workAssignEnterproseName}, '%')</if>
<if test="workAssignEnterproseId != null "> and work_assign_enterprose_id = #{workAssignEnterproseId}</if> <if test="workAssignEnterproseId != null "> and workOrder.work_assign_enterprose_id = #{workAssignEnterproseId}</if>
<if test="workAssignManId != null "> and work_assign_man_id = #{workAssignManId}</if> <if test="workAssignManId != null "> and workOrder.work_assign_man_id = #{workAssignManId}</if>
<if test="workAssignMan != null and workAssignMan != ''"> and work_assign_man = #{workAssignMan}</if> <if test="workAssignMan != null and workAssignMan != ''"> and user.work_assign_man = #{workAssignMan}</if>
<if test="workStatus != null and workStatus != ''"> and work_status = #{workStatus}</if> <if test="workStatus != null and workStatus != ''"> and workOrder.work_status = #{workStatus}</if>
<if test="inspectionDate != null "> and inspection_date = #{inspectionDate}</if> <if test="inspectionDate != null "> and workOrder.inspection_date = #{inspectionDate}</if>
<if test="inspectionRoute != null and inspectionRoute != ''"> and inspection_route = #{inspectionRoute}</if> <if test="inspectionRoute != null and inspectionRoute != ''"> and workOrder.inspection_route = #{inspectionRoute}</if>
<if test="problemDescription != null and problemDescription != ''"> and problem_description = #{problemDescription}</if> <if test="problemDescription != null and problemDescription != ''"> and workOrder.problem_description = #{problemDescription}</if>
<if test="iconUrl != null and iconUrl != ''"> and icon_url = #{iconUrl}</if> <if test="iconUrl != null and iconUrl != ''"> and workOrder.icon_url = #{iconUrl}</if>
<if test="rectificationPlan != null and rectificationPlan != ''"> and rectification_plan = #{rectificationPlan}</if> <if test="rectificationPlan != null and rectificationPlan != ''"> and workOrder.rectification_plan = #{rectificationPlan}</if>
<if test="rectificationResult != null and rectificationResult != ''"> and rectification_result = #{rectificationResult}</if> <if test="rectificationResult != null and rectificationResult != ''"> and workOrder.rectification_result = #{rectificationResult}</if>
<if test="responsibleUnit != null and responsibleUnit != ''"> and responsible_unit = #{responsibleUnit}</if> <if test="responsibleUnit != null and responsibleUnit != ''"> and workOrder.responsible_unit = #{responsibleUnit}</if>
<if test="responsiblePerson != null and responsiblePerson != ''"> and responsible_person = #{responsiblePerson}</if> <if test="responsiblePerson != null and responsiblePerson != ''"> and workOrder.responsible_person = #{responsiblePerson}</if>
<if test="expiryDate != null "> and expiry_date = #{expiryDate}</if> <if test="expiryDate != null "> and workOrder.expiry_date = #{expiryDate}</if>
<if test="isDel != null and isDel != ''"> and is_del = #{isDel}</if> <if test="isDel != null and isDel != ''"> and workOrder.is_del = #{isDel}</if>
<if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if> <if test="remarks != null and remarks != ''"> and workOrder.remarks = #{remarks}</if>
</where> </where>
ORDER BY workOrder.create_time DESC
</select> </select>
<select id="selectTWorkOrderById" parameterType="Long" resultMap="TWorkOrderResult"> <select id="selectTWorkOrderById" parameterType="Long" resultMap="TWorkOrderResult">
<include refid="selectTWorkOrderVo"/> <include refid="selectTWorkOrderVo"/>
where work_id = #{workId} where workOrder.work_id = #{workId}
</select>
<select id="countTWorkOrder" resultType="HomepageVo">
select COUNT(t.work_id) AS taskTotal,
SUM(CASE t.work_status WHEN '2' THEN 1 ELSE 0 END) AS taskFeedbackTotal
from (select * from t_work_order where is_del = '0') t
</select> </select>
<insert id="insertTWorkOrder" parameterType="TWorkOrder" useGeneratedKeys="true" keyProperty="workId"> <insert id="insertTWorkOrder" parameterType="TWorkOrder" useGeneratedKeys="true" keyProperty="workId">
...@@ -137,7 +175,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -137,7 +175,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="workCreateEnterpriseId != null">work_create_enterprise_id = #{workCreateEnterpriseId},</if> <if test="workCreateEnterpriseId != null">work_create_enterprise_id = #{workCreateEnterpriseId},</if>
<if test="workAssignEnterproseName != null">work_assign_enterprose_name = #{workAssignEnterproseName},</if> <if test="workAssignEnterproseName != null">work_assign_enterprose_name = #{workAssignEnterproseName},</if>
<if test="workAssignEnterproseId != null">work_assign_enterprose_id = #{workAssignEnterproseId},</if> <if test="workAssignEnterproseId != null">work_assign_enterprose_id = #{workAssignEnterproseId},</if>
<if test="workAssignManId == null">work_assign_man_id = null,</if> <if test="workAssignManId == null and workAssignMan == ''">work_assign_man_id = null,</if>
<if test="workAssignManId != null">work_assign_man_id = #{workAssignManId},</if> <if test="workAssignManId != null">work_assign_man_id = #{workAssignManId},</if>
<if test="workAssignMan != null">work_assign_man = #{workAssignMan},</if> <if test="workAssignMan != null">work_assign_man = #{workAssignMan},</if>
<if test="workStatus != null">work_status = #{workStatus},</if> <if test="workStatus != null">work_status = #{workStatus},</if>
......
import request from '@/utils/request' import request from '@/utils/request'
// 燃气事故台账统计 // 燃气事故台账统计
export function troubleStatistic(query) { export function troubleStatistic() {
return request({ return request({
url: '/statistic/troubleStatistic', url: '/statistic/troubleStatistic',
method: 'get', method: 'get'
params: query
}) })
} }
// 隐患整治台账统计 // 隐患整治台账统计
export function hiddenStatistic(query) { export function hiddenStatistic() {
return request({ return request({
url: '/statistic/hiddenStatistic', url: '/statistic/hiddenStatistic',
method: 'get', method: 'get'
params: query })
}
// 隐患整治台账统计
export function homepageStatistic() {
return request({
url: '/statistic/homepageStatistic',
method: 'get'
}) })
} }
...@@ -82,10 +82,20 @@ ...@@ -82,10 +82,20 @@
<el-table-column label="投诉人姓名" align="center" prop="complainName" /> <el-table-column label="投诉人姓名" align="center" prop="complainName" />
<el-table-column label="投诉人电话" align="center" prop="complainPhone" /> <el-table-column label="投诉人电话" align="center" prop="complainPhone" />
<el-table-column label="投诉事项" align="center" prop="complainMatter" /> <el-table-column label="投诉事项" align="center" prop="complainMatter" />
<el-table-column label="办理情况" align="center" prop="dealCondition" /> <!--<el-table-column label="反馈内容" align="center" prop="dealCondition" />-->
<el-table-column label="指派单位名称" align="center" prop="complainAssignEnterproseName" /> <el-table-column label="指派单位名称" align="center" prop="complainAssignEnterproseName" />
<el-table-column label="指派人" align="center" prop="complainAssignMan" /> <el-table-column label="指派人" align="center" prop="complainAssignMan" />
<el-table-column label="任务状态" align="center" prop="complainStatus" :formatter="taskStateFormat" /> <el-table-column label="任务状态" align="center" prop="complainStatus" :formatter="taskStateFormat" />
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template>
</el-table-column>
<el-table-column label="反馈时间" align="center" prop="dealTime" width="180" >
<!--<template slot-scope="scope">-->
<!--<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>-->
<!--</template>-->
</el-table-column>
<el-table-column label="备注" align="center" prop="remarks" /> <el-table-column label="备注" align="center" prop="remarks" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200">
<template slot-scope="scope" > <template slot-scope="scope" >
...@@ -181,7 +191,7 @@ ...@@ -181,7 +191,7 @@
<el-form-item label="投诉事项" prop="complainMatter"> <el-form-item label="投诉事项" prop="complainMatter">
<el-input v-model="form.complainMatter" type = "textarea" placeholder="请输入投诉事项" :disabled="readonly"/> <el-input v-model="form.complainMatter" type = "textarea" placeholder="请输入投诉事项" :disabled="readonly"/>
</el-form-item> </el-form-item>
<el-form-item label="办理情况" prop="dealCondition" :style="display"> <el-form-item label="反馈内容" prop="dealCondition" :style="display">
<el-input v-model="form.dealCondition" type = "textarea" placeholder="请输入办理情况" :disabled="readonly"/> <el-input v-model="form.dealCondition" type = "textarea" placeholder="请输入办理情况" :disabled="readonly"/>
</el-form-item> </el-form-item>
<el-form-item label="转办记录" prop="transferRecord" :style="display"> <el-form-item label="转办记录" prop="transferRecord" :style="display">
...@@ -208,9 +218,16 @@ ...@@ -208,9 +218,16 @@
</el-dialog> </el-dialog>
<el-dialog title="反馈内容" :visible.sync="dialogFormVisible" width="600px"> <el-dialog title="反馈内容" :visible.sync="dialogFormVisible" width="600px">
<el-form :model="form2"> <el-form :model="form2">
<textarea class="inputstyle" v-model="form2.concent" type ="textarea" ></textarea> <div style="width: 100%;min-height: 100px;margin-top: -20px">
<el-form-item label="投诉事项" prop="complainMatter">
<textarea class="inputstyle1" v-model="form2.complainMatter" readonly></textarea>
</el-form-item>
</div>
<el-form-item label="反馈" style = "margin-top: -15px;">
<textarea class="inputstyle" v-model="form2.concent" type ="textarea" ></textarea>
</el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer" style="margin-top: -30px;">
<el-button @click="dialogFormVisible = false"> </el-button> <el-button @click="dialogFormVisible = false"> </el-button>
<el-button type="primary" @click="submint2"> </el-button> <el-button type="primary" @click="submint2"> </el-button>
</div> </div>
...@@ -278,6 +295,7 @@ export default { ...@@ -278,6 +295,7 @@ export default {
}, },
form2:{ form2:{
complainDealId:'', complainDealId:'',
complainMatter:'',
concent:'', concent:'',
}, },
//身份 //身份
...@@ -498,6 +516,7 @@ export default { ...@@ -498,6 +516,7 @@ export default {
this.form2.concent=""; this.form2.concent="";
this.dialogFormVisible = true; this.dialogFormVisible = true;
this.form2.complainDealId=row.complainDealId; this.form2.complainDealId=row.complainDealId;
this.form2.complainMatter = row.complainMatter;
}, },
//提交反馈信息 //提交反馈信息
submint2(){ submint2(){
...@@ -539,5 +558,13 @@ export default { ...@@ -539,5 +558,13 @@ export default {
border-color: 0.5px #99a9bf; border-color: 0.5px #99a9bf;
outline:none; outline:none;
} }
.inputstyle1{
min-height: 50px;
max-height: 200px;
width: 100%;
border : none;
resize:none;
outline:none;
}
</style> </style>
This diff is collapsed.
...@@ -155,7 +155,7 @@ ...@@ -155,7 +155,7 @@
/> />
<!-- 添加或修改应急预案对话框 --> <!-- 添加或修改应急预案对话框 -->
<el-dialog :title="title" :visible.sync="open" width="1200px" append-to-body> <el-dialog :title="title" :visible.sync="open" @closed="dialogClose" @open="dialogOpen" width="1200px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<div class="division"> <div class="division">
<div style="width: 40%;"> <div style="width: 40%;">
...@@ -199,7 +199,7 @@ ...@@ -199,7 +199,7 @@
<el-form-item label="备注" prop="remarks"> <el-form-item label="备注" prop="remarks">
<el-input v-model="form.remarks" placeholder="请输入备注" :disabled="readonly" /> <el-input v-model="form.remarks" placeholder="请输入备注" :disabled="readonly" />
</el-form-item> </el-form-item>
<el-form-item label="预案附件" id="fujian" prop="iconUrl"> <el-form-item label="预案附件" v-if="!readonly" prop="iconUrl">
<FileUpload <FileUpload
listType="picture" listType="picture"
@resFun="getFileInfo" @resFun="getFileInfo"
...@@ -212,7 +212,7 @@ ...@@ -212,7 +212,7 @@
<!--<img width="100%" :src="dialogImageUrl" alt="">--> <!--<img width="100%" :src="dialogImageUrl" alt="">-->
<!--</el-dialog>--> <!--</el-dialog>-->
</el-form-item> </el-form-item>
<el-form-item label="预案附件" id="fujianxia" prop="iconUrl" style="display: none"> <el-form-item label="预案附件" v-if="readonly" prop="iconUrl" >
<span <span
class="dbtn" class="dbtn"
@click="checkFile(form.iconUrl)" @click="checkFile(form.iconUrl)"
...@@ -226,15 +226,10 @@ ...@@ -226,15 +226,10 @@
</div> </div>
<div style="width: 58%;margin-left: 2%"> <div style="width: 58%;margin-left: 2%">
<div class="titletitle">方案内容</div> <div class="titletitle">方案内容</div>
<!--<el-form-item label="应急方案" prop="planContents">--> <!--<editor v-model="form.planContents" style="height: 300px;" readonly="false"/>-->
<!--<el-input v-model="form.planContents" placeholder="" />--> <editor v-if="isOpen" id="editor" v-model="form.planContents" :min-height="300" :readOnly="readonly"/>
<editor v-model="form.planContents" style="height: 300px;" :readOnly="readonly"/>
<!--<textarea id="editorA" v-model="form.planContents" height="100%"></textarea>-->
<!--</el-form-item>-->
</div> </div>
</div> </div>
<!--<el-form-item label="所属企业名称" prop="beyondEnterpriseName">--> <!--<el-form-item label="所属企业名称" prop="beyondEnterpriseName">-->
<!--<el-input v-model="form.beyondEnterpriseName" placeholder="请输入所属企业名称" />--> <!--<el-input v-model="form.beyondEnterpriseName" placeholder="请输入所属企业名称" />-->
<!--</el-form-item>--> <!--</el-form-item>-->
...@@ -244,7 +239,7 @@ ...@@ -244,7 +239,7 @@
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button id="yesbutton" type="primary" @click="submitForm"> </el-button> <el-button type="primary" v-if="!readonly" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
...@@ -265,7 +260,7 @@ export default { ...@@ -265,7 +260,7 @@ export default {
return { return {
// 遮罩层 // 遮罩层
loading: true, loading: true,
readonly: true, readonly: false,
// 导出遮罩层 // 导出遮罩层
exportLoading: false, exportLoading: false,
// 选中数组 // 选中数组
...@@ -287,6 +282,7 @@ export default { ...@@ -287,6 +282,7 @@ export default {
title: "", title: "",
// 是否显示弹出层 // 是否显示弹出层
open: false, open: false,
isOpen:false,
dialogImageUrl: '', dialogImageUrl: '',
dialogVisible: false, dialogVisible: false,
fileList:[], fileList:[],
...@@ -301,7 +297,8 @@ export default { ...@@ -301,7 +297,8 @@ export default {
beyondEnterpriseId: null, beyondEnterpriseId: null,
}, },
// 表单参数 // 表单参数
form: {}, form: {
},
// 表单校验 // 表单校验
rules: { rules: {
planTitle: [ planTitle: [
...@@ -345,6 +342,12 @@ export default { ...@@ -345,6 +342,12 @@ export default {
this.enterpriseList = response.data; this.enterpriseList = response.data;
}); });
}, },
dialogClose(){
this.isOpen=false;
},
dialogOpen(){
this.isOpen=true;
},
qiyechang(value){ qiyechang(value){
let obj = {}; let obj = {};
obj = this.enterpriseList.find((item)=>{ obj = this.enterpriseList.find((item)=>{
...@@ -433,33 +436,23 @@ export default { ...@@ -433,33 +436,23 @@ export default {
}, },
/** 新增按钮操作 */ /** 新增按钮操作 */
handleAdd() { handleAdd() {
this.open = true;
this.readonly=false; this.readonly=false;
this.open = true;
this.fileList = []; this.fileList = [];
this.reset(); this.reset();
this.title = "添加应急预案"; this.title = "添加应急预案";
document.getElementById("fujian").style.display=""
document.getElementById("fujianxia").style.display="none"
document.getElementById("yesbutton").style.display="" ;
document.getElementsByClassName("el-upload--picture-card")[0].style.display="";
}, },
handleDtail(row){ handleDtail(row){
this.readonly=true; this.readonly=true;
this.open = true;
this.fileList = []; this.fileList = [];
this.reset(); this.reset();
this.open = true;
const planId = row.planId || this.ids const planId = row.planId || this.ids
getPlanInfo(planId).then(response => { getPlanInfo(planId).then(response => {
this.form = response.data; this.form = response.data;
this.title = "应急预案详情"; this.title = "应急预案详情";
this.fileList = [{name: '附件', url:uploadfile}]; this.fileList = [{name: '附件', url:uploadfile}];
this.fileurl = row.iconUrl; this.fileurl = row.iconUrl;
document.getElementById("yesbutton").style.display="none" ;
document.getElementById("fujian").style.display="none"
document.getElementById("fujianxia").style.display=""
}); });
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */
...@@ -475,9 +468,6 @@ export default { ...@@ -475,9 +468,6 @@ export default {
if(this.form.iconUrl!=null||this.form.iconUrl==""){ if(this.form.iconUrl!=null||this.form.iconUrl==""){
this.fileList = [{name: 'file', url:uploadfile}]; this.fileList = [{name: 'file', url:uploadfile}];
} }
document.getElementById("yesbutton").style.display="" ;
document.getElementById("fujian").style.display=""
document.getElementById("fujianxia").style.display="none"
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
......
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