Commit 968365b0 authored by 耿迪迪's avatar 耿迪迪
parents 164a799f c1e5c241
......@@ -107,7 +107,7 @@ public class TPipeOldPlanProcessController extends BaseController
}
/**
* 上传计划和进度
* 政府端 上传计划和进度
* @param fOldPlanProcessId 计划id
* @return
*/
......@@ -120,4 +120,14 @@ public class TPipeOldPlanProcessController extends BaseController
return AjaxResult.error("上传计划和进度接口异常");
}
}
/**
* 企业端 上传计划和进度
* @param fOldPlanProcessId 计划id
* @return
*/
@GetMapping("/entReportPipeOldPlanProcess")
public AjaxResult entReportPipeOldPlanProcess(Long fOldPlanProcessId) {
return toAjax(tPipeOldPlanProcessService.entReportPipeOldPlanProcess(fOldPlanProcessId));
}
}
......@@ -74,6 +74,18 @@ public class TEnterpriseInfoController extends BaseController
return getDataTable(list);
}
/**
*无条件查询所有企业
* @return
*/
@GetMapping("/queryAllEnterprise")
public List<TEnterpriseInfo> queryAllEnterprise()
{
//获取用户信息
return tEnterpriseInfoService.queryAllEnterprise();
}
/**
*查询所有企业信息
* @param tEnterpriseInfo
......
......@@ -109,4 +109,15 @@ public class TConGasProIncController extends BaseController
return AjaxResult.error("上传第三方施工意外事件接口异常");
}
}
/**
* 企业端上传第三方施工意外事件
* @param fConGasProIncId 第三方施工意外事件id
* @return
*/
@GetMapping("/entReportConGasProInfo")
public AjaxResult entReportConGasProInfo(Long fConGasProIncId){
return toAjax(tConGasProIncService.entReportConGasProInfo(fConGasProIncId));
}
}
package com.zehong.system.domain;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.zehong.common.annotation.Excel;
import com.zehong.common.core.domain.BaseEntity;
import java.util.Date;
/**
* 第三方施工-涉气第三方施工意外事件对象 t_con_gas_pro_inc
*
......@@ -48,7 +51,69 @@ public class TConGasProInc extends BaseEntity
@Excel(name = "最后修改时间")
private String fUpdateTime;
public void setfConGasProIncId(Long fConGasProIncId)
/**
* 企业端上传时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date entUploadTime;
/**
* 企业端上传状态 0-未上传,1-已上传*/
private String entUploadState;
/**
* 政府端上传时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date govUploadTime;
/**
* 企业端上传状态 0-未上传,1-已上传*/
private String govUploadState;
/** 燃气企业编码 */
@Excel(name = "燃气企业编码")
private String fCompanyInfoId;
public Date getEntUploadTime() {
return entUploadTime;
}
public void setEntUploadTime(Date entUploadTime) {
this.entUploadTime = entUploadTime;
}
public String getEntUploadState() {
return entUploadState;
}
public void setEntUploadState(String entUploadState) {
this.entUploadState = entUploadState;
}
public Date getGovUploadTime() {
return govUploadTime;
}
public void setGovUploadTime(Date govUploadTime) {
this.govUploadTime = govUploadTime;
}
public String getGovUploadState() {
return govUploadState;
}
public void setGovUploadState(String govUploadState) {
this.govUploadState = govUploadState;
}
public String getfCompanyInfoId() {
return fCompanyInfoId;
}
public void setfCompanyInfoId(String fCompanyInfoId) {
this.fCompanyInfoId = fCompanyInfoId;
}
public void setfConGasProIncId(Long fConGasProIncId)
{
this.fConGasProIncId = fConGasProIncId;
}
......
......@@ -5,6 +5,8 @@ import org.apache.commons.lang3.builder.ToStringStyle;
import com.zehong.common.annotation.Excel;
import com.zehong.common.core.domain.BaseEntity;
import java.util.Date;
/**
* 老旧管网-改造计划和进度对象 t_pipe_old_plan_process
*
......@@ -89,11 +91,11 @@ public class TPipeOldPlanProcess extends BaseEntity
/** 当前改造进度,填写百分比,100为完成 */
@Excel(name = "当前改造进度")
private Long fReconstructionProgress;
private Float fReconstructionProgress;
/** 当前资金拨付进度,填写百分比,100为完成 */
@Excel(name = "当前资金拨付进度")
private Long fFundsDisbursementProgress;
private Float fFundsDisbursementProgress;
/** 是否已上传,1-是,0-否 */
@Excel(name = "是否已上传",readConverterExp = "1=是,0=否")
......@@ -105,6 +107,29 @@ public class TPipeOldPlanProcess extends BaseEntity
private Long fEnterpriseId;
/**
* 政府端上传数据
*/
private String govUploadState;
private Date govUploadTime;
public String getGovUploadState() {
return govUploadState;
}
public void setGovUploadState(String govUploadState) {
this.govUploadState = govUploadState;
}
public Date getGovUploadTime() {
return govUploadTime;
}
public void setGovUploadTime(Date govUploadTime) {
this.govUploadTime = govUploadTime;
}
public Long getfEnterpriseId() {
return fEnterpriseId;
}
......@@ -266,21 +291,21 @@ public class TPipeOldPlanProcess extends BaseEntity
{
return fActualFinishTime;
}
public void setfReconstructionProgress(Long fReconstructionProgress)
public void setfReconstructionProgress(Float fReconstructionProgress)
{
this.fReconstructionProgress = fReconstructionProgress;
}
public Long getfReconstructionProgress()
public Float getfReconstructionProgress()
{
return fReconstructionProgress;
}
public void setfFundsDisbursementProgress(Long fFundsDisbursementProgress)
public void setfFundsDisbursementProgress(Float fFundsDisbursementProgress)
{
this.fFundsDisbursementProgress = fFundsDisbursementProgress;
}
public Long getfFundsDisbursementProgress()
public Float getfFundsDisbursementProgress()
{
return fFundsDisbursementProgress;
}
......
package com.zehong.system.mapper;
import java.util.Date;
import java.util.List;
import com.zehong.system.domain.TConGasProInc;
import org.apache.ibatis.annotations.Param;
/**
* 第三方施工-涉气第三方施工意外事件Mapper接口
......@@ -43,6 +45,11 @@ public interface TConGasProIncMapper
*/
public int updateTConGasProInc(TConGasProInc tConGasProInc);
/**
*
* 根据id修改 企业端上传状态*/
public int updateEntUploadStateById(@Param("state") String state, @Param("entUploadTime") Date entUploadTime,
@Param("fConGasProIncId") Long fConGasProIncId);
/**
* 删除第三方施工-涉气第三方施工意外事件
*
......
......@@ -35,6 +35,12 @@ public interface TEnterpriseInfoMapper
*/
public List<TEnterpriseInfo> selectTEnterpriseInfoList(TEnterpriseInfo tEnterpriseInfo);
/**
* 无条件查询所有企业
* @return r
*/
public List<TEnterpriseInfo> queryAllEnterprise();
/**
* 新增企业信息
*
......
package com.zehong.system.mapper;
import java.util.Date;
import java.util.List;
import com.zehong.system.domain.TPipeOldPlanProcess;
import org.apache.ibatis.annotations.Param;
/**
* 老旧管网-改造计划和进度Mapper接口
......@@ -43,6 +45,13 @@ public interface TPipeOldPlanProcessMapper
*/
public int updateTPipeOldPlanProcess(TPipeOldPlanProcess tPipeOldPlanProcess);
/**
* 企业端上传数据
* @return
*/
public int entReportPipeOldPlanProcess(@Param("state") String state, @Param("entUploadTime") Date entUploadTime,
@Param("fOldPlanProcessId") Long fOldPlanProcessId);
/**
* 删除老旧管网-改造计划和进度
*
......
......@@ -65,4 +65,11 @@ public interface ITConGasProIncService
* @return
*/
int reportAccidentInfo(Long fConGasProIncId) throws Exception ;
/**
* 企业端上传第三方施工意外事件
* @param fConGasProIncId 意外事件工id
* @return
*/
int entReportConGasProInfo(Long fConGasProIncId);
}
......@@ -30,6 +30,11 @@ public interface ITEnterpriseInfoService
*/
public List<TEnterpriseInfo> selectTEnterpriseInfoList(TEnterpriseInfo tEnterpriseInfo);
/**
* 无条件查询所有企业
*/
public List<TEnterpriseInfo> queryAllEnterprise();
/**
* 新增企业信息
*
......
......@@ -65,4 +65,11 @@ public interface ITPipeOldPlanProcessService
* @return
*/
int reportPipeOldPlanProcess(Long fOldPlanProcessId) throws Exception;
/**
* 企业端上传 计划
* @param fOldPlanProcessId f
* @return r
*/
int entReportPipeOldPlanProcess(Long fOldPlanProcessId);
}
package com.zehong.system.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.zehong.common.core.domain.entity.SysRole;
import com.zehong.common.exception.CustomException;
import com.zehong.common.utils.GovernmentDataCopyUtil;
import com.zehong.common.utils.GovernmentDataUtil;
import com.zehong.common.utils.SecurityUtils;
import com.zehong.system.domain.TConGasProInc;
import com.zehong.system.domain.vo.TConGasProIncVo;
import com.zehong.system.mapper.TConGasProIncMapper;
......@@ -30,7 +32,7 @@ public class TConGasProIncServiceImpl implements ITConGasProIncService
{
private static final Logger log = LoggerFactory.getLogger(TConGasProIncServiceImpl.class);
@Autowired
@Resource
private TConGasProIncMapper tConGasProIncMapper;
@Resource
......@@ -58,6 +60,12 @@ public class TConGasProIncServiceImpl implements ITConGasProIncService
@Override
public List<TConGasProInc> selectTConGasProIncList(TConGasProInc tConGasProInc)
{
SysRole sysRole = SecurityUtils.getLoginUser().getUser().getRoles().get(0);
// 不是超级管理员也不是企业
if (sysRole.getRoleId() != 1 && sysRole.getRoleId() != 5) {
tConGasProInc.setEntUploadState("1");
}
return tConGasProIncMapper.selectTConGasProIncList(tConGasProInc);
}
......@@ -127,6 +135,20 @@ public class TConGasProIncServiceImpl implements ITConGasProIncService
JSONObject reportResult = governmentDataUtil.setInfo("construction/gas/project/incident","WRITE",data);
log.info("上传第三方施工意外事件结果===================" + reportResult.toJSONString());
if(!"0".equals(reportResult.getString("resultCode"))) throw new CustomException("上传第三方施意外事件工接口失败");
conGasProInc.setGovUploadState("1");
conGasProInc.setGovUploadTime(new Date());
tConGasProIncMapper.updateTConGasProInc(conGasProInc);
return 1;
}
/**
* 企业端上传
* @param fConGasProIncId 意外事件工id
* @return r
*/
@Override
public int entReportConGasProInfo(Long fConGasProIncId) {
tConGasProIncMapper.updateEntUploadStateById("1",new Date(),fConGasProIncId);
return 1;
}
}
......@@ -76,6 +76,16 @@ public class TEnterpriseInfoServiceImpl implements ITEnterpriseInfoService
return tEnterpriseInfoMapper.selectTEnterpriseInfoList(tEnterpriseInfo);
}
/**
* 无条件查询所有企业
* @return re
*/
@Override
public List<TEnterpriseInfo> queryAllEnterprise() {
return tEnterpriseInfoMapper.queryAllEnterprise();
}
/**
* 新增企业信息
*
......
......@@ -31,7 +31,7 @@ public class TPipeOldPlanProcessServiceImpl implements ITPipeOldPlanProcessServi
{
private static final Logger log = LoggerFactory.getLogger(TPipeOldPlanProcessServiceImpl.class);
@Autowired
@Resource
private TPipeOldPlanProcessMapper tPipeOldPlanProcessMapper;
@Resource
......@@ -121,6 +121,20 @@ public class TPipeOldPlanProcessServiceImpl implements ITPipeOldPlanProcessServi
JSONObject reportResult = governmentDataUtil.setInfo("pipeline/old/plan/process","WRITE",data);
log.info("上传计划和进度结果===================" + reportResult.toJSONString());
if(!"0".equals(reportResult.getString("resultCode"))) throw new CustomException("上传计划和进度接口失败");
tPipeOldPlanProcess.setGovUploadState("1");
tPipeOldPlanProcess.setGovUploadTime(new Date());
tPipeOldPlanProcessMapper.updateTPipeOldPlanProcess(tPipeOldPlanProcess);
return 1;
}
/**
* 企业端上传数据
* @param fOldPlanProcessId f
* @return r
*/
@Override
public int entReportPipeOldPlanProcess(Long fOldPlanProcessId) {
tPipeOldPlanProcessMapper.entReportPipeOldPlanProcess("1",new Date(),fOldPlanProcessId);
return 1;
}
}
......@@ -13,6 +13,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="fAttachment" column="f_attachment" />
<result property="fRemark" column="f_remark" />
<result property="fUpdateTime" column="f_update_time" />
<result property="fCompanyInfoId" column="f_company_info_id" />
<result property="entUploadTime" column="f_ent_upload_time" />
<result property="entUploadState" column="f_ent_upload_state" />
<result property="govUploadTime" column="f_gov_upload_time" />
<result property="govUploadState" column="f_gov_upload_state" />
</resultMap>
<sql id="selectTConGasProIncVo">
......@@ -25,6 +31,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
inc.f_attachment,
inc.f_remark,
inc.f_update_time,
inc.f_ent_upload_time,
inc.f_ent_upload_state,
inc.f_gov_upload_time,
inc.f_gov_upload_state,
info.f_project_code AS projectCode
FROM
t_con_gas_pro_inc inc
......@@ -34,13 +44,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectTConGasProIncList" parameterType="TConGasProInc" resultMap="TConGasProIncResult">
<include refid="selectTConGasProIncVo"/>
<where>
<if test="fIntersectConstructionId != null and fIntersectConstructionId != ''"> and inc.f_intersect_construction_id = #{fIntersectConstructionId}</if>
<if test="fTitle != null and fTitle != ''"> and inc.f_title = #{fTitle}</if>
<if test="fIntersectConstructionId != null and fIntersectConstructionId != ''"> and info.f_project_code like concat('%', #{fIntersectConstructionId}, '%')</if>
<if test="fTitle != null and fTitle != ''"> and inc.f_title like concat('%', #{fTitle}, '%')</if>
<if test="fDescription != null and fDescription != ''"> and inc.f_description = #{fDescription}</if>
<if test="fOccurrenctTime != null and fOccurrenctTime != ''"> and inc.f_occurrenct_time = #{fOccurrenctTime}</if>
<if test="fAttachment != null and fAttachment != ''"> and inc.f_attachment = #{fAttachment}</if>
<if test="fRemark != null and fRemark != ''"> and inc.f_remark = #{fRemark}</if>
<if test="fUpdateTime != null and fUpdateTime != ''"> and inc.f_update_time = #{fUpdateTime}</if>
<if test="fCompanyInfoId != null and fCompanyInfoId != ''"> and inc.f_company_info_id = #{fCompanyInfoId}</if>
<if test="entUploadState != null and entUploadState != ''"> and inc.f_ent_upload_state = #{entUploadState}</if>
</where>
order by f_update_time desc
</select>
......@@ -60,6 +72,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fAttachment != null and fAttachment != ''">f_attachment,</if>
<if test="fRemark != null and fRemark != ''">f_remark,</if>
<if test="fUpdateTime != null and fUpdateTime != ''">f_update_time,</if>
<if test="fCompanyInfoId != null and fCompanyInfoId != ''">f_company_info_id,</if>
<if test="entUploadTime != null and entUploadTime != ''">f_ent_upload_time,</if>
<if test="entUploadState != null and entUploadState != ''">f_ent_upload_state,</if>
<if test="govUploadTime != null and govUploadTime != ''">f_gov_upload_time,</if>
<if test="govUploadState != null and govUploadState != ''">f_gov_upload_state,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="fIntersectConstructionId != null and fIntersectConstructionId != ''">#{fIntersectConstructionId},</if>
......@@ -69,6 +87,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fAttachment != null and fAttachment != ''">#{fAttachment},</if>
<if test="fRemark != null and fRemark != ''">#{fRemark},</if>
<if test="fUpdateTime != null and fUpdateTime != ''">#{fUpdateTime},</if>
<if test="fCompanyInfoId != null and fCompanyInfoId != ''">#{fCompanyInfoId},</if>
<if test="entUploadTime != null and entUploadTime != ''">#{entUploadTime},</if>
<if test="entUploadState != null and entUploadState != ''">#{entUploadState},</if>
<if test="govUploadTime != null and govUploadTime != ''">#{govUploadTime},</if>
<if test="govUploadState != null and govUploadState != ''">#{govUploadState},</if>
</trim>
</insert>
......@@ -82,6 +106,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fAttachment != null and fAttachment != ''">f_attachment = #{fAttachment},</if>
<if test="fRemark != null and fRemark != ''">f_remark = #{fRemark},</if>
<if test="fUpdateTime != null and fUpdateTime != ''">f_update_time = #{fUpdateTime},</if>
<if test="entUploadTime != null">f_ent_upload_time = #{entUploadTime},</if>
<if test="entUploadState != null and entUploadState != ''">f_ent_upload_state = #{entUploadState},</if>
<if test="govUploadTime != null">f_gov_upload_time = #{govUploadTime},</if>
<if test="govUploadState != null and govUploadState != ''">f_gov_upload_state = #{govUploadState},</if>
</trim>
where f_con_gas_pro_inc_id = #{fConGasProIncId}
</update>
......@@ -90,6 +119,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
delete from t_con_gas_pro_inc where f_con_gas_pro_inc_id = #{fConGasProIncId}
</delete>
<update id="updateEntUploadStateById">
update t_con_gas_pro_inc set f_ent_upload_state = #{state}, f_ent_upload_time = #{entUploadTime} where f_con_gas_pro_inc_id = #{fConGasProIncId}
</update>
<delete id="deleteTConGasProIncByIds" parameterType="String">
delete from t_con_gas_pro_inc where f_con_gas_pro_inc_id in
<foreach item="fConGasProIncId" collection="array" open="(" separator="," close=")">
......
......@@ -64,6 +64,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fProjectName != null and fProjectName != ''"> and f_project_name like concat('%', #{fProjectName}, '%')</if>
<if test="fPipePress != null and fPipePress != ''"> and f_pipe_press = #{fPipePress}</if>
<if test="entUploadState != null and entUploadState != ''"> and f_ent_upload_state = #{entUploadState}</if>
<if test="fCompanyInfoId != null and fCompanyInfoId != ''"> and f_company_info_id = #{fCompanyInfoId}</if>
</where>
order by f_update_time desc
</select>
......
......@@ -52,6 +52,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
order by enterprise_id desc
</select>
<select id="queryAllEnterprise" resultMap="TEnterpriseInfoResult">
<include refid="selectTEnterpriseInfoVo"/>
</select>
<select id="selectTEnterpriseInfoById" parameterType="String" resultMap="TEnterpriseInfoResult">
<include refid="selectTEnterpriseInfoVo"/>
......
......@@ -27,10 +27,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="fUploadType" column="f_upload_type" />
<result property="fUploadTime" column="f_upload_time" />
<result property="fEnterpriseId" column="f_enterprise_id" />
<result property="govUploadState" column="f_gov_upload_state" />
<result property="govUploadTime" column="f_gov_upload_time" />
</resultMap>
<sql id="selectTPipeOldPlanProcessVo">
select f_old_plan_process_id, f_uuid, f_enterprise_id,f_ent_uuid, f_region, f_project_name, f_relation_object_type, f_year, f_start_time, f_end_time, f_total_investment, f_create_time, f_update_time, f_subject_implementation, f_concat_person, f_concat_tel, f_construction_content, f_actual_finish_time, f_reconstruction_progress, f_funds_disbursement_progress, f_upload_type, f_upload_time from t_pipe_old_plan_process
select f_old_plan_process_id, f_uuid, f_enterprise_id,f_ent_uuid, f_region, f_project_name, f_relation_object_type, f_year, f_start_time, f_end_time, f_total_investment, f_create_time, f_update_time, f_subject_implementation, f_concat_person, f_concat_tel, f_construction_content, f_actual_finish_time, f_reconstruction_progress, f_funds_disbursement_progress, f_upload_type, f_upload_time,f_gov_upload_state, f_gov_upload_time from t_pipe_old_plan_process
</sql>
<select id="selectTPipeOldPlanProcessList" parameterType="TPipeOldPlanProcess" resultMap="TPipeOldPlanProcessResult">
......@@ -42,6 +45,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fConcatTel != null and fConcatTel != ''"> and f_concat_tel like concat('%', #{fConcatTel}, '%')</if>
<if test="fFundsDisbursementProgress != null "> and f_funds_disbursement_progress = #{fFundsDisbursementProgress}</if>
<if test="fUploadType != null and fUploadType != ''"> and f_upload_type = #{fUploadType}</if>
<if test="fEnterpriseId != null and fEnterpriseId != ''"> and f_enterprise_id = #{fEnterpriseId}</if>
</where>
</select>
......@@ -74,6 +78,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fUploadType != null">f_upload_type,</if>
<if test="fUploadTime != null">f_upload_time,</if>
<if test="fEnterpriseId != null">f_enterprise_id,</if>
<if test="govUploadState != null">f_gov_upload_state,</if>
<if test="govUploadTime != null">f_gov_upload_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="fUuid != null and fUuid != ''">#{fUuid},</if>
......@@ -97,6 +104,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fUploadType != null">#{fUploadType},</if>
<if test="fUploadTime != null">#{fUploadTime},</if>
<if test="fEnterpriseId != null">#{fEnterpriseId},</if>
<if test="govUploadState != null">#{govUploadState},</if>
<if test="govUploadTime != null">#{govUploadTime},</if>
</trim>
</insert>
......@@ -124,6 +134,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fUploadType != null">f_upload_type = #{fUploadType},</if>
<if test="fUploadTime != null">f_upload_time = #{fUploadTime},</if>
<if test="fEnterpriseId != null">f_enterprise_id = #{fEnterpriseId},</if>
<if test="govUploadState != null">f_gov_upload_state = #{govUploadState},</if>
<if test="govUploadTime != null">f_gov_upload_time = #{govUploadTime},</if>
</trim>
where f_old_plan_process_id = #{fOldPlanProcessId}
</update>
......@@ -132,6 +145,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
delete from t_pipe_old_plan_process where f_old_plan_process_id = #{fOldPlanProcessId}
</delete>
<update id="entReportPipeOldPlanProcess">
update t_pipe_old_plan_process set f_upload_type = #{state}, f_upload_time = #{entUploadTime} where f_old_plan_process_id = #{fOldPlanProcessId}
</update>
<delete id="deleteTPipeOldPlanProcessByIds" parameterType="String">
delete from t_pipe_old_plan_process where f_old_plan_process_id in
<foreach item="fOldPlanProcessId" collection="array" open="(" separator="," close=")">
......
......@@ -51,3 +51,21 @@ export function exportProcess(query) {
params: query
})
}
// 企业端上传 老旧官网
export function entReportPipeOldPlanProcess(query) {
return request({
url: '/oldPipeSystem/plan/entReportPipeOldPlanProcess',
method: 'get',
params: query
})
}
// 政府端上传 老旧官网
export function reportPipeOldPlanProcess(query) {
return request({
url: '/oldPipeSystem/plan/reportPipeOldPlanProcess',
method: 'get',
params: query
})
}
\ No newline at end of file
......@@ -19,6 +19,14 @@ export function enterpriseLists(query) {
}
// 无条件查询企业所有信息
export function queryAllEnterprise() {
return request({
url: '/regulation/info/queryAllEnterprise',
method: 'get',
})
}
// 查询企业信息详细
export function getInfo(enterpriseId) {
......
......@@ -59,3 +59,11 @@ export function reportAccidentInfo(query) {
params: query
})
}
export function entReportConGasProInfo(query) {
return request({
url: '/third/accident/entReportConGasProInfo',
method: 'get',
params: query
})
}
\ No newline at end of file
......@@ -745,4 +745,8 @@
box-shadow:none !important;
// pointer-events:auto !important;
// top:-30px !important;
}
\ No newline at end of file
}
......@@ -8,7 +8,7 @@
-->
<template>
<div>
<div class="pipePressure">
<!-- <div class="pipePressure"> -->
<!--
<div style="float: left;margin-right: 5px;">
<div class="hasColorBox">
......@@ -32,7 +32,7 @@
监控
</div>
</div> -->
<div>
<!-- <div>
<div class="hasColorBox" :style="{ color: pipeColor[`1`] }">
<div :style="{ backgroundColor: pipeColor[`1`] }"></div>
低压管线
......@@ -50,7 +50,7 @@
高压管线
</div>
</div>
</div>
</div> -->
<div class="mapChange">
<div :class="{ active: mapStyle }" @click="mapChange(2)">全景地图</div>
......
......@@ -1151,6 +1151,7 @@ export default {
.rightb {
width: 98%;
height: 100%;
}
.rightbar1 {
width: 90%;
......@@ -1161,7 +1162,7 @@ export default {
.rightbar2 {
width: 76%;
height: 37%;
padding-top: 15px;
padding-top: 30px;
margin-left: 20%;
pointer-events: auto;
}
......
<!--
* @Author: 纪泽龙 jizelong@qq.com
* @Date: 2023-07-12 13:58:25
* @Date: 2024-07-15 10:26:41
* @LastEditors: 纪泽龙 jizelong@qq.com
* @LastEditTime: 2023-07-12 17:12:59
* @FilePath: /gassafetyprogress-web/src/views/bigWindow/components/Bottom.vue
* @LastEditTime: 2024-07-16 17:27:41
* @FilePath: /zh-baseversion-web/src/views/bigWindow/components/Bottom.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<template>
<div class="bigwindow-bottom listingsSty">
<img
src="~@/assets/firstimage/bottombk.svg"
alt=""
style="backdrop-filter: blur(4px)"
/>
<div class="listingsSty">
<div class="big-bottom">
<div class="left">
<img
v-if="cont != list.length - 3"
@click.stop="cont++"
src="@/assets/firstimage/l.png"
alt=""
/>
</div>
<div class="container">
<transition name="fade" mode="out-in">
<div v-if="activeCom.label" class="children">
<div
v-for="item in activeCom.children"
:key="item.value"
:title="'河北冉盛升新能源有限公123123123司'"
class="child zzz"
:class="[{ active: selectActive.includes(item.value) }]"
@click.stop="selectActiveChange(item.value)"
>
{{ item.label }}
</div>
</div>
</transition>
<div
class="firsty selectAll"
class="all"
@click.stop="selectAll"
:class="[
{
active:
selectActive.length == listFlatArr.length &&
selectActive.length > 1,
},
]"
:class="{
active:
selectActive.length == listFlatArr.length &&
selectActive.length > 1,
}"
>
全部
</div>
<div class="firsty item" v-for="(item, index) in list" :key="item.value">
<div
class="itemCompany"
@click.stop="selectChange(item.value)"
:class="[
{ active: selectSome(index) },
{ activeAll: selectEvery(index) },
]"
>
{{ item.label }}
</div>
<div
class="up-select"
:class="[{ hide: !selectShowNum.includes(item.value) }]"
:style="{ height: item.children.length * 35 + 'px' }"
>
<div
class="selectItem"
v-for="selectItem in item.children"
:class="[{ active: selectActive.includes(selectItem.value) }]"
:key="selectItem.value"
@click.stop="selectActiveChange(selectItem.value)"
>
{{ selectItem.label }}
<div class="other">
<div class="other2">
<div class="move" :style="{ left: -cont * 144 + 'px' }">
<div
v-for="item in list"
@click.stop="itemClick(item)"
:key="item.value"
class="item"
:class="[
{ active: item.label == activeCom.label },
{ minOne: selectSome(item) },
{ maxAll: selectEvery(item) },
]"
>
{{ item.label }}
</div>
</div>
</div>
</div>
</div>
<div class="right">
<img
v-if="cont != 0"
@click.stop="cont--"
src="@/assets/firstimage/r.png"
alt=""
/>
</div>
</div>
</template>
<script>
import { mapGetters, mapActions } from "vuex";
export default {
name: "",
data() {
return {
cont: 0,
list: [
{
value: 1,
......@@ -92,6 +108,8 @@ export default {
],
},
],
// 被选中的公司
activeCom: {},
selectShowNum: [],
// 被选中的值
selectActive: [],
......@@ -101,12 +119,10 @@ export default {
computed: {
...mapGetters(["company", "systemSetting"]),
},
beforeCreate() {},
mounted() {
this.GetCompany().then((res) => {
this.company.forEach((item) => {
this.list[item.companyType-1].children.push({
this.list[item.companyType - 1].children.push({
value: item.conpanyId,
label: item.companyName,
});
......@@ -118,9 +134,8 @@ export default {
...mapActions({
GetCompany: "bigWindowCompany/GetCompany",
}),
// 把下拉框放下
selectUpClear(){
this.selectShowNum=[];
selectUpClear() {
this.activeCom = {};
},
selectAll() {
// 生成所有都选中的数组
......@@ -141,12 +156,12 @@ export default {
}
this.$emit("listChange", this.selectActive);
},
selectChange(value) {
const num = this.selectShowNum.indexOf(value);
if (num >= 0) {
this.selectShowNum.splice(num, 1);
itemClick(item) {
if (item.children.length == 0) return;
if (this.activeCom == item) {
this.activeCom = {};
} else {
this.selectShowNum.push(value);
this.activeCom = item;
}
},
selectActiveChange(value) {
......@@ -158,20 +173,19 @@ export default {
}
this.$emit("listChange", this.selectActive);
},
// 至少有一个被选中
selectSome(index) {
selectSome(item) {
return (
this.list[index].children.length > 0 &&
this.list[index].children.some((item) => {
item.children.length > 0 &&
item.children.some((item) => {
return this.selectActive.includes(item.value);
})
);
},
// 都被选中
selectEvery(index) {
selectEvery(item) {
return (
this.list[index].children.length > 0 &&
this.list[index].children.every((item) => {
item.children.length > 0 &&
item.children.every((item) => {
return this.selectActive.includes(item.value);
})
);
......@@ -180,84 +194,188 @@ export default {
};
</script>
<style lang="scss" scoped>
.bigwindow-bottom {
width: 40%;
height: 70px;
.big-bottom {
width: 810px;
height: 50px;
position: fixed;
bottom: 0;
margin-left: 30%;
bottom: 38px;
left: 50%;
margin-left: -405px;
background: url("~@/assets/firstimage/btmA.png") no-repeat bottom center,
url("~@/assets/firstimage/btmB.png") no-repeat bottom center;
box-sizing: border-box;
padding: 0 80px;
display: flex;
// z-index: 1000;
img {
width: 100%;
height: 100%;
position: absolute;
z-index: -1;
bottom: -10px;
}
.listingsSty {
padding-left: 15%;
padding-right: 15%;
box-sizing: border-box;
width: 180%;
justify-content: space-between;
align-items: center;
.container {
// background: red;
flex: 1;
margin-right: 22px;
height: 28px;
display: flex;
justify-content: space-between;
.firsty {
// width: 15%;
min-width: 80px;
height: 35px;
.all {
transition: all 0.2s linear;
width: 128px;
margin-right: 16px;
text-align: center;
line-height: 35px;
line-height: 28px;
color: #fff;
font-size: 16px;
cursor: pointer;
&.selectAll {
transition: all 0.5s ease;
&.active {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 1),
0 0 35px rgb(0, 255, 255, 1);
}
background: url("~@/assets/firstimage/btm-item.png") no-repeat bottom
center;
&.active {
background: url("~@/assets/firstimage/btm-item-active.png") no-repeat
bottom center;
}
&:hover {
opacity: 0.7;
}
}
.other {
flex: 1;
width: 0;
position: relative;
.other2 {
width: 100%;
height: 100%;
overflow: hidden;
&.item {
min-width: 180px;
position: relative;
.itemCompany {
transition: all 0.5s ease;
&.active {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 0.3),
0 0 35px rgb(0, 255, 255, 0.3);
}
&.activeAll {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 1),
0 0 35px rgb(0, 255, 255, 1);
}
}
.up-select {
transition: all 0.5s ease;
position: absolute;
bottom: 50px;
left: 0;
width: 100%;
background: rgb(18, 92, 155, 0.3);
overflow: hidden;
&.hide {
height: 0px !important;
}
.selectItem {
transition: all 0.5s ease;
.move {
transition: all 0.5s linear;
width: 1000px;
height: 100%;
// background: blue;
position: relative;
display: flex;
align-items: center;
left: 0px;
.item {
transition: all 0.2s linear;
width: 128px;
margin-right: 16px;
text-align: center;
line-height: 28px;
color: #fff;
font-size: 16px;
cursor: pointer;
background: url("~@/assets/firstimage/btm-item.png") no-repeat
bottom center;
&.active {
color: #00ffff;
text-shadow: 0 0 20px #00ffff, 0 0 35px #00ffff;
color: #1ec9e3;
}
// 最少选中一个
&.minOne {
background: url("~@/assets/firstimage/btm-item-one.png") no-repeat
bottom center;
}
// 全选中
&.maxAll {
background: url("~@/assets/firstimage/btm-item-active.png")
no-repeat bottom center;
}
&:hover {
opacity: 0.7;
}
}
}
}
}
.children {
transition: all 1s linear;
width: 620px;
max-height: 214px;
position: absolute;
// background: red;
background: rgba(2, 26, 51, 0.9);
border: 1px solid #127bd1;
box-shadow: inset 0px 0px 10px 0px #164db2;
left: 50%;
margin-left: -310px;
// top: -215px;
bottom: 50px;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
box-sizing: border-box;
padding: 20px 20px 0px 20px;
// 滚动条
overflow-y: auto;
&::-webkit-scrollbar {
width: 10px;
background: #012a53;
position: absolute;
top: 0;
}
&::-webkit-scrollbar-thumb {
/*滚动条里面小方块*/
// border-radius: 10px;
// box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #00000052;
border-radius: 8px;
}
&::-webkit-scrollbar-track {
/*滚动条里面轨道*/
// box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
// border-radius: 10px;
// background-color: red;
}
&::-webkit-scrollbar-button:start {
// overflow: hidden;
}
&::-webkit-scrollbar-button:end {
// overflow: hidden;
}
.child {
width: 275px;
height: 32px;
margin-bottom: 16px;
background: #0b2d47;
box-sizing: border-box;
padding-left: 21px;
line-height: 32px;
color: #fff;
border: 1px solid rgba(54, 136, 255, 0.2392);
cursor: pointer;
&.active {
background: rgba(255, 141, 70, 0.29);
box-sizing: border-box;
border: 1px solid rgba(255, 178, 130, 0.4);
}
&:hover {
opacity: 0.7;
}
}
}
}
.left {
margin-right: 32px;
color: white;
}
.right {
color: white;
}
.left,
.right {
width: 14px;
height: 20px;
img {
transition: all 0.5s linear;
width: 100%;
height: 100%;
cursor: pointer;
&:hover {
opacity: 0.7;
}
}
}
// background: red;
}
</style>
<!--
* @Author: 纪泽龙 jizelong@qq.com
* @Date: 2023-07-12 13:58:25
* @LastEditors: 纪泽龙 jizelong@qq.com
* @LastEditTime: 2023-07-12 17:12:59
* @FilePath: /gassafetyprogress-web/src/views/bigWindow/components/Bottom.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<template>
<div class="bigwindow-bottom listingsSty">
<img
src="~@/assets/firstimage/bottombk.svg"
alt=""
style="backdrop-filter: blur(4px)"
/>
<div class="listingsSty">
<div
class="firsty selectAll"
@click.stop="selectAll"
:class="[
{
active:
selectActive.length == listFlatArr.length &&
selectActive.length > 1,
},
]"
>
全部
</div>
<div class="firsty item" v-for="(item, index) in list" :key="item.value">
<div
class="itemCompany"
@click.stop="selectChange(item.value)"
:class="[
{ active: selectSome(index) },
{ activeAll: selectEvery(index) },
]"
>
{{ item.label }}
</div>
<div
class="up-select"
:class="[{ hide: !selectShowNum.includes(item.value) }]"
:style="{ height: item.children.length * 35 + 'px' }"
>
<div
class="selectItem"
v-for="selectItem in item.children"
:class="[{ active: selectActive.includes(selectItem.value) }]"
:key="selectItem.value"
@click.stop="selectActiveChange(selectItem.value)"
>
{{ selectItem.label }}
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapGetters, mapActions } from "vuex";
export default {
name: "",
data() {
return {
list: [
{
value: 1,
label: "天然气公司",
children: [
// { value: 10, label: "东阿道夫阿" },
// { value: 11, label: "阿发送到" },
// { value: 19, label: "发打算发大水" },
],
},
{
value: 2,
label: "液化气公司",
children: [
// { value: 21, label: "2-1" },
// { value: 22, label: "2-2" },
],
},
{
value: 3,
label: "加气站",
children: [
// { value: 31, label: "3-1" },
// { value: 32, label: "3-2" },
],
},
],
selectShowNum: [],
// 被选中的值
selectActive: [],
listFlatArr: [],
};
},
computed: {
...mapGetters(["company", "systemSetting"]),
},
beforeCreate() {},
mounted() {
this.GetCompany().then((res) => {
this.company.forEach((item) => {
this.list[item.companyType-1].children.push({
value: item.conpanyId,
label: item.companyName,
});
});
this.selectAll();
});
},
methods: {
...mapActions({
GetCompany: "bigWindowCompany/GetCompany",
}),
// 把下拉框放下
selectUpClear(){
this.selectShowNum=[];
},
selectAll() {
// 生成所有都选中的数组
this.listFlatArr = this.list
.map((item) => {
return item.children.map((iten) => {
return iten.value;
});
})
.flat();
// 如果是全选中状态,则全取消,否则全选
if (this.selectActive.length == this.listFlatArr.length) {
this.selectActive = [];
} else {
this.selectActive = [...this.listFlatArr];
}
this.$emit("listChange", this.selectActive);
},
selectChange(value) {
const num = this.selectShowNum.indexOf(value);
if (num >= 0) {
this.selectShowNum.splice(num, 1);
} else {
this.selectShowNum.push(value);
}
},
selectActiveChange(value) {
const num = this.selectActive.indexOf(value);
if (num >= 0) {
this.selectActive.splice(num, 1);
} else {
this.selectActive.push(value);
}
this.$emit("listChange", this.selectActive);
},
// 至少有一个被选中
selectSome(index) {
return (
this.list[index].children.length > 0 &&
this.list[index].children.some((item) => {
return this.selectActive.includes(item.value);
})
);
},
// 都被选中
selectEvery(index) {
return (
this.list[index].children.length > 0 &&
this.list[index].children.every((item) => {
return this.selectActive.includes(item.value);
})
);
},
},
};
</script>
<style lang="scss" scoped>
.bigwindow-bottom {
width: 40%;
height: 70px;
position: fixed;
bottom: 0;
margin-left: 30%;
display: flex;
// z-index: 1000;
img {
width: 100%;
height: 100%;
position: absolute;
z-index: -1;
bottom: -10px;
}
.listingsSty {
padding-left: 15%;
padding-right: 15%;
box-sizing: border-box;
width: 180%;
display: flex;
justify-content: space-between;
.firsty {
// width: 15%;
min-width: 80px;
height: 35px;
text-align: center;
line-height: 35px;
color: #fff;
font-size: 16px;
cursor: pointer;
&.selectAll {
transition: all 0.5s ease;
&.active {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 1),
0 0 35px rgb(0, 255, 255, 1);
}
}
&.item {
min-width: 180px;
position: relative;
.itemCompany {
transition: all 0.5s ease;
&.active {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 0.3),
0 0 35px rgb(0, 255, 255, 0.3);
}
&.activeAll {
color: #00ffff;
text-shadow: 0 0 20px rgba(0, 255, 255, 1),
0 0 35px rgb(0, 255, 255, 1);
}
}
.up-select {
transition: all 0.5s ease;
position: absolute;
bottom: 50px;
left: 0;
width: 100%;
background: rgb(18, 92, 155, 0.3);
overflow: hidden;
&.hide {
height: 0px !important;
}
.selectItem {
transition: all 0.5s ease;
&.active {
color: #00ffff;
text-shadow: 0 0 20px #00ffff, 0 0 35px #00ffff;
}
}
}
}
}
}
}
</style>
<!--
* @Author: your name
* @Date: 2022-01-11 13:44:17
* @LastEditTime: 2023-07-12 17:13:16
* @LastEditTime: 2024-07-15 14:29:45
* @LastEditors: 纪泽龙 jizelong@qq.com
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /test/hello-world/src/views/Home.vue
-->
<template>
<div class="home bigwindow" @click='windowClick'>
<div class="home bigwindow" @click="windowClick">
<div class="goSystem" @click="$router.push('/index')">进入管理系统</div>
<div id="map"></div>
<!-- <Center :show="show" :centerData="centerData" /> -->
......@@ -30,7 +30,10 @@
:pageSize="20"
/>
<PipeColor />
<PipeSelect @transmit="getPipeSelectMessage" @closeMediumPressureLine="clearBigWindowsSelectPipe"/>
<!-- <PipeSelect
@transmit="getPipeSelectMessage"
@closeMediumPressureLine="clearBigWindowsSelectPipe"
/> -->
<!-- 底部按钮 -->
<!-- <div class="home-div">
......@@ -54,7 +57,7 @@
</div>
</div>
</div> -->
<Bottom v-if="enterpriseId==-2" @listChange="listChange" ref='Bottom'/>
<Bottom v-if="enterpriseId == -2" @listChange="listChange" ref="Bottom" />
<!-- 设备按钮 -->
<div class="typelist-div">
<div
......@@ -83,18 +86,21 @@
<!-- 头部 -->
<div class="banner-test">
<!-- <dv-decoration-5 style="width:100%;height:100%;" /> -->
<img v-if="this.enterpriseId==-2" src="../../assets/images/zibk.png" alt="" />
<img v-else src="../../assets/images/20230805152711.png" alt="" />
<img
v-if="this.enterpriseId == -2"
src="../../assets/images/zibk.png"
alt=""
/>
<img v-else src="../../assets/images/20230805152711.png" alt="" />
</div>
<!-- 左边 -->
<div class="leftbar">
<div class="leftbar" :style="changeLeftBarStyle">
<leftBar ref="mychild2"></leftBar>
</div>
<!-- 右边 -->
<div class="rightbar">
<div class="rightbar" :style="changeRightBarStyle">
<rightBar ref="mychild"></rightBar>
</div>
<!-- <img src="../../assets/images/leftbk.svg" alt=""> -->
......@@ -150,7 +156,11 @@
import { EditorMap } from "@/utils/mapClass/map";
import { mapGetters, mapActions } from "vuex";
import { listDetectorInfo } from "@/api/detector/detectorInfo";
import { detectorUserList,massMarksDetectorUserList,labelsLayerMarksDetectorUserList } from "@/api/detector/detectorUser";
import {
detectorUserList,
massMarksDetectorUserList,
labelsLayerMarksDetectorUserList,
} from "@/api/detector/detectorUser";
import {
pipeData,
tiaoyaxiang,
......@@ -171,7 +181,7 @@ import {
userAlarm,
getTcqDevice,
getYhq,
deviceUser
deviceUser,
} from "@/api/bigWindow/getDevice";
import Line from "@/components/bigWindow/Line.vue";
import VideoView from "@/components/bigWindow/VideoView.vue";
......@@ -190,9 +200,9 @@ import { getUserProfile } from "@/api/system/user";
import leftBar from "@/components/bigWindow/leftBar.vue";
import rightBar from "@/components/bigWindow/rightBar.vue";
import Bottom from "./components/Bottom.vue";
import { mapState } from 'vuex'
import MediumPressureLineVue from '../../components/bigWindow/MediumPressureLine.vue';
import PipeSelect from '../../components/bigWindow/PipeSelect.vue';
import { mapState } from "vuex";
import MediumPressureLineVue from "../../components/bigWindow/MediumPressureLine.vue";
import PipeSelect from "../../components/bigWindow/PipeSelect.vue";
export default {
name: "Home",
components: {
......@@ -217,6 +227,8 @@ export default {
nowDate: "",
nowweek: "",
nowtime: "", // 当前日期
changeRightBarStyle: "",
changeLeftBarStyle: "",
typeList: [
{
val: 1,
......@@ -300,7 +312,7 @@ export default {
},
computed: {
...mapGetters(["company", "systemSetting","enterpriseId"]),
...mapGetters(["company", "systemSetting", "enterpriseId"]),
companyLength() {
return this.typeList.length;
},
......@@ -313,6 +325,12 @@ export default {
}
},
},
created() {
window.addEventListener("resize", this.leftRightBarChange);
this.leftRightBarChange();
// changeRightBarStyle
},
async mounted() {
// console.log(99999999999999)
// getPipe().then(res=>{
......@@ -334,12 +352,12 @@ export default {
this
);
getUserProfile().then(response => {
var user = response.data;
if(user.deptId ==13){
this.map.setCenter(["117.908541","39.688353"])
}
});
getUserProfile().then((response) => {
var user = response.data;
if (user.deptId == 13) {
this.map.setCenter(["117.908541", "39.688353"]);
}
});
console.log("--");
// 这是测试,用本地数据
......@@ -369,22 +387,32 @@ export default {
await this.goMap(getEnterprise, this.addDevice, Company, true);
// this.goMap(getPipe, this.addPipeLine, Line, true);
//管道
this.goMediumPressureLineMap(getPipe, this.addMediumPipeLine, Line,MediumPressureLineVue, true);
this.goMediumPressureLineMap(
getPipe,
this.addMediumPipeLine,
Line,
MediumPressureLineVue,
true
);
//调压箱
this.labelsLayerMarksTysGoMap(getTyx, Device, false);
//阀门井
this.labelsLayerMarksFmjGoMap(getFm, Device, false);
//场站
this.labelsLayerMarksCzGoMap(getCz,Cz, false);
this.labelsLayerMarksCzGoMap(getCz, Cz, false);
//监控
this.labelsLayerMarksVideoGoMap(getVideo,VideoView, false);
this.labelsLayerMarksVideoGoMap(getVideo, VideoView, false);
//this.goMap(getYhq, this.addDevice2, yhqUser, false); //液化气用户上图
if (this.enterpriseId==-2){
if (this.enterpriseId == -2) {
this.labelsLayerMarksDeviceUserGoMap(deviceUser, yhqUser, false); //用户上图
}
// 用户要等一下 因为有报警数据
this.labelsLayerMarksDetectorUserGoMap(labelsLayerMarksDetectorUserList,User, false).then((res) => {
this.labelsLayerMarksDetectorUserGoMap(
labelsLayerMarksDetectorUserList,
User,
false
).then((res) => {
// 先查一下,然后开启定时器
this.userAlarm();
this.alarmTimer = setInterval(() => {
......@@ -403,17 +431,42 @@ export default {
...mapActions({
GetCompany: "bigWindowCompany/GetCompany",
}),
windowClick(){
leftRightBarChange() {
const scale = window.innerHeight / 1080;
let right = 0;
if (scale >= 1) {
right = (585 / 2) * (scale - 1) - 20;
} else {
right = (585 / 2) * (scale - 1) - 20;
}
// console.log("right", right, "scale", scale);
this.changeRightBarStyle = [
{ right: right + "px" },
{ transform: `scale(${scale})` },
];
this.changeLeftBarStyle = [
{ left: right + 20 + "px" },
{ transform: `scale(${scale})` },
];
},
windowClick() {
this.$refs.Bottom.selectUpClear();
},
// 点击了 大屏端 管道搜索的清除键
clearBigWindowsSelectPipe(){
clearBigWindowsSelectPipe() {
this.map.infowindowClose();
},
getPipeSelectMessage(data,id) {
let arrArea = data.split(',');
this.map.setCenter([arrArea[0],arrArea[1]])
this.map.filterSelectPipe(id,MediumPressureLineVue,arrArea[0],arrArea[1]);
getPipeSelectMessage(data, id) {
let arrArea = data.split(",");
this.map.setCenter([arrArea[0], arrArea[1]]);
this.map.filterSelectPipe(
id,
MediumPressureLineVue,
arrArea[0],
arrArea[1]
);
},
// 管道上图
addPipeLine(data, component) {
......@@ -424,10 +477,10 @@ export default {
}
},
// 管道上图
addMediumPipeLine(data, component,mediumComponent) {
addMediumPipeLine(data, component, mediumComponent) {
for (let comp in data) {
data[comp].forEach((pipe) => {
this.map.addMediumPipeLine(pipe, component,mediumComponent);
this.map.addMediumPipeLine(pipe, component, mediumComponent);
});
}
},
......@@ -461,7 +514,13 @@ export default {
});
}
},
goMediumPressureLineMap(httpFunc, addFunc, component,mediumComponent, show){
goMediumPressureLineMap(
httpFunc,
addFunc,
component,
mediumComponent,
show
) {
return httpFunc().then((res) => {
// 给用户加icontype
if (res.data && !res.data[0].iconType) {
......@@ -482,50 +541,45 @@ export default {
} else {
config = { data: res.data || res.rows };
}
addFunc(config, component, mediumComponent,show);
addFunc(config, component, mediumComponent, show);
return config.iconType;
});
},
labelsLayerMarksDeviceUserGoMap(httpFunc,component,show){
labelsLayerMarksDeviceUserGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksDeviceUserGoMap(mapData, component, show);
})
}
,
labelsLayerMarksVideoGoMap(httpFunc,component,show){
});
},
labelsLayerMarksVideoGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksVideoGoMap(mapData, component, show);
})
}
,
labelsLayerMarksCzGoMap(httpFunc,component,show){
});
},
labelsLayerMarksCzGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksCzGoMap(mapData, component, show);
})
}
,
labelsLayerMarksFmjGoMap(httpFunc,component,show){
});
},
labelsLayerMarksFmjGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksFmjGoMap(mapData, component, show);
})
}
,
labelsLayerMarksTysGoMap(httpFunc,component,show){
});
},
labelsLayerMarksTysGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksTysGoMap(mapData, component, show);
})
}
,
});
},
labelsLayerMarksDetectorUserGoMap(httpFunc, component, show) {
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksDetectorUserList(mapData, component, show);
return httpFunc().then((res) => {
const mapData = res.data;
this.map.labelsLayerMarksDetectorUserList(mapData, component, show);
});
},
goMap(httpFunc, addFunc, component, show) {
......@@ -572,9 +626,9 @@ export default {
// },
// 更改下方列表
listChange(arr) {
console.log(arr)
console.log(arr);
// return;
this.selarr=[...arr]
this.selarr = [...arr];
this.map.allfilter(this.selarr, this.selarr1);
this.map.infowindowClose();
this.show = false;
......@@ -653,7 +707,6 @@ export default {
getTcqDevice(queryParams, title) {
console.log(queryParams);
return getTcqDevice(queryParams).then((res) => {
this.detcetorList = res;
this.centerUserId = queryParams.devId;
// 总数据
......@@ -700,6 +753,7 @@ export default {
},
// 销毁定时器
beforeDestroy() {
window.removeEventListener("resize",this.leftRightBarChange);
if (this.formatDate) {
clearInterval(this.formatDate); // 在Vue实例销毁前,清除时间定时器
}
......@@ -755,9 +809,13 @@ export default {
.leftbar {
width: 565px;
height: 93%;
// height: 93%;
height: 1010px;
position: fixed;
top: 70px;
// top: 70px;
top: 50%;
margin-top: -470px;
z-index: 999;
background: url("../../assets/firstimage/le.png");
background-size: 105% 100%;
......@@ -767,15 +825,15 @@ export default {
}
.rightbar {
width: 585px;
height: 93%;
height: 1010px;
position: fixed;
top: 70px;
top: 50%;
margin-top: -470px;
z-index: 999;
right: 0;
// right: 861px;
background: url("../../assets/firstimage/ri.png");
background-size: 100% 100%;
background-repeat: no-repeat;
margin-right: -20px;
pointer-events: none;
}
.home-div {
......
<template>
<el-dialog title="详情" :visible.sync="detailOpen" width="1000px" append-to-body destroy-on-close :close-on-click-modal="false">
<el-form label-width="170px">
<el-row class="el-row-table">
<el-row class="el-row-table">
<el-col :span="12">
<el-form-item label="项目名称">
<span v-if="detailInfo.fProjectName">{{ detailInfo.fProjectName }}</span>
<span v-else>-</span>
<el-form-item label="燃气企业" >
<span>{{ enterpriseName }}</span>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="燃气企业编码" >
<span v-if="detailInfo.fEntUuid">{{ detailInfo.fEntUuid }}</span>
<el-form-item label="项目名称">
<span v-if="detailInfo.fProjectName">{{ detailInfo.fProjectName }}</span>
<span v-else>-</span>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="项目所在县级行政区ID" >
<el-form-item label="项目所在县级行政区" >
<span v-if="detailInfo.fRegion">{{ detailInfo.fRegion }}</span>
<span v-else>-</span>
</el-form-item>
......@@ -143,19 +143,55 @@
<script>
import { getProcess } from "@/api/oldpipesystem/process";
import { enterpriseLists ,queryAllEnterprise} from "@/api/regulation/info";
import { getDefaultCountyList } from "@/api/area/county";
export default {
name: "detail-info",
data(){
return{
enterprises: [],
countyInfo: [],
detailInfo: {},
enterpriseName:"",
detailOpen: false
}
},
created() {
this.getCountyInfo();
this.getEnterpriseLists();
},
methods:{
//获取县级
getCountyInfo(){
getDefaultCountyList().then(res =>{
if(res.code == 200 && res.data){
this.countyInfo = res.data;
}
})
},
//所属单位
getEnterpriseLists(){
queryAllEnterprise().then(response => {
this.enterprises = response;
});
},
beyondCountyFormat(row){
let info = this.countyInfo.find(item => item.fId == row.fRegion);
return info?info.fName:"-";
},
beyondCompanyFormat(row){
let info = this.enterprises.find(item => item.enterpriseId == row.fEnterpriseId);
return info?info.enterpriseName:"-";
},
getDetailInfo(id){
getProcess(id).then(res =>{
if(res.code == 200 && res.data){
this.detailInfo = res.data;
this.detailInfo.fRegion = this.beyondCountyFormat(this.detailInfo);
let fEnterpriseId = this.detailInfo.fEnterpriseId;
if (fEnterpriseId != null) {
this.enterpriseName= this.beyondCompanyFormat(this.detailInfo);
}
this.detailOpen = true;
}
})
......
......@@ -131,18 +131,9 @@
<span v-else>-</span>
</template>
</el-table-column>
<el-table-column label="是否已上传" align="center" prop="fUploadType">
<template slot-scope="scope">
<span v-if="scope.row.fUploadType == '0'"></span>
<span v-else-if="scope.row.fUploadType == '1'"></span>
<span v-else>-</span>
</template>
<el-table-column label="上传状态" align="center" prop="fUploadType" :formatter="uploadStateFormat">
</el-table-column>
<el-table-column label="上传时间" align="center" prop="fUploadTime" width="150">
<template slot-scope="scope">
<span v-if="scope.row.fUploadTime != null">{{ scope.row.fUploadTime }}</span>
<span v-else>-</span>
</template>
<el-table-column label="上传时间" align="center" prop="fUploadTime" width="150" :formatter="uploadTimeFormat">
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="180">
<template slot-scope="scope">
......@@ -170,14 +161,8 @@
size="mini"
type="text"
@click="handleReport(scope.row)"
v-if="(user.roleId==1||user.roleId==5)&&scope.row.fUploadType==0"
>上传</el-button>
<el-button
size="mini"
type="text"
@click="handleReport2(scope.row)"
v-if="(user.roleId==1||user.roleId==3)&&scope.row.fUploadType==1"
>上传</el-button>
v-if="judgeUploadIsShow((scope.row))"
>上传</el-button>
</template>
</el-table-column>
</el-table>
......@@ -203,14 +188,7 @@
<el-col :span="12">
<el-form-item label="燃气企业" prop="beyondEnterpriseId">
<el-select v-model="form.fEnterpriseId" placeholder="请选择所属企业名称" style="width: 100%" >
<el-option
v-for="item in enterprises"
:key="parseInt(item.enterpriseId)"
:label="item.enterpriseName"
:value="parseInt(item.enterpriseId)">
</el-option>
</el-select>
<el-input v-model="enterpriseName" :disabled="true"></el-input>
</el-form-item>
<!--<el-form-item label="燃气企业编码" prop="fEntUuid">-->
<!--<el-input v-model="form.fEntUuid" placeholder="请输入燃气企业编码" />-->
......@@ -287,7 +265,7 @@
<el-col :span="12">
<el-form-item label="项目总投资/万元" prop="fTotalInvestment">
<el-input v-model="form.fTotalInvestment" placeholder="请输入项目总投资/万元" />
<el-input-number style="width: 100%;" v-model="form.fTotalInvestment" class="left-aligned-input" :controls="false" :min="0" placeholder="请输入项目总投资/万元" />
</el-form-item>
</el-col>
......@@ -330,13 +308,13 @@
<el-col :span="12">
<el-form-item label="当前改造进度/百分比" prop="fReconstructionProgress">
<el-input v-model="form.fReconstructionProgress" placeholder="请输入当前改造进度/百分比" />
<el-input-number style="width: 100%;" v-model="form.fReconstructionProgress" class="left-aligned-input" :controls="false" :min="0" :max="100" precision="2" placeholder="请输入当前改造进度/百分比" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="当前资金拨付进度/百分比" prop="fFundsDisbursementProgress">
<el-input v-model="form.fFundsDisbursementProgress" placeholder="请输入当前资金拨付进度/百分比" />
<el-input-number style="width: 100%;" v-model="form.fFundsDisbursementProgress" class="left-aligned-input" :controls="false" :min="0" :max="100" precision="2" placeholder="请输入当前资金拨付进度/百分比" />
</el-form-item>
</el-col>
</el-row>
......@@ -354,7 +332,7 @@
</template>
<script>
import { listProcess, getProcess, delProcess, addProcess, updateProcess, exportProcess } from "@/api/oldpipesystem/process";
import { listProcess, getProcess, delProcess, addProcess, updateProcess, exportProcess,reportPipeOldPlanProcess,entReportPipeOldPlanProcess } from "@/api/oldpipesystem/process";
import DetailInfo from "./components/DetailInfo";
import{getInfo} from "@/api/login"
import { enterpriseLists } from "@/api/regulation/info";
......@@ -368,6 +346,7 @@ export default {
},
data() {
return {
enterpriseName:"",
user:{},
enterprises: [],
countyInfo: [],
......@@ -426,7 +405,6 @@ export default {
};
},
created() {
this.getList();
this.getuserInfo();
this.getDicts("t_relation_object_type").then(response => {
this.fRelationObjectTypeOptions = response.data;
......@@ -451,6 +429,7 @@ export default {
getInfo().then(response => {
console.log(response);
this.user = response.user.roles[0]
this.getList();
});
},
//所属单位
......@@ -460,9 +439,10 @@ export default {
enterpriseLists(param).then(response => {
if (response.rows.length>1){
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}else {
this.form.fEnterpriseId=response.rows[0].enterpriseId;
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}
});
......@@ -475,6 +455,10 @@ export default {
/** 查询老旧管网改造计划列表 */
getList() {
this.loading = true;
// 企业查自己的数据
if (this.user.roleId == 5) {
this.queryParams.fEnterpriseId = this.$store.state.user.enterpriseId
}
listProcess(this.queryParams).then(response => {
this.processList = response.rows;
this.total = response.total;
......@@ -490,6 +474,66 @@ export default {
this.open = false;
this.reset();
},
//判断 上传是否需要显示,上传分为企业上传 和 政府端上传
judgeUploadIsShow(row) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
// 企业端 上传状态 0-未上传,1-已上传
let entUploadState = row.fUploadType;
// 政府端 上传状态 0-未上传,1-已上传
let govUploadState = row.govUploadState;
// 如果政府端都已经上传,那就不能显示了。
if(govUploadState === '1') {
return false;
}
// 如果企业端上传了,则企业端就不能显示了,政府端和 超级管理员能显示
if(entUploadState === '1' && govUploadState === '0') {
if (roleId === 5) {
return false;
} else {
return true;
}
}
// 别的情况,都显示
return true;
},
//上传状态动态展示
uploadStateFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
if (row.fUploadType == '0') {
return "未上传"
} else{
return "已上传"
}
} else {
if (row.govUploadState == '0') {
return "未上传"
} else{
return "已上传"
}
}
},
//上传时间动态展示
uploadTimeFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
return row.fUploadTime;
} else {
return row.govUploadTime;
}
},
// 表单重置
reset() {
this.form = {
......@@ -561,6 +605,7 @@ export default {
this.getList();
});
} else {
this.form.fEnterpriseId=this.enterprises[0].enterpriseId;
addProcess(this.form).then(response => {
this.msgSuccess("新增成功");
this.open = false;
......@@ -605,35 +650,42 @@ export default {
this.$refs.detail.getDetailInfo(row.fOldPlanProcessId);
},
handleReport(row){
console.log("-----------------------------"+row.fOldPlanProcessId)
this.$confirm('是否确认上传老旧管网改造计划项目名称为"' + row.fProjectName + '"的数据项?', "警告", {
// 如果是 超级管理员或者 企业,并且 企业端上传状态为0
if ((this.user.roleId == 5 || this.user.roleId == 1) && row.fUploadType == '0') {
this.$confirm('是否确认上传老旧管网改造计划项目名称为"' + row.fProjectName + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function() {
return entReportPipeOldPlanProcess({fOldPlanProcessId : row.fOldPlanProcessId});
}).then(() => {
this.getList();
this.msgSuccess("上传成功");
}).catch(() => {});
}
// 如果是 超级管理员或者 政府,并且 政府端上传状态为0
if ((this.user.roleId == 3 || this.user.roleId == 1) && row.govUploadState == '0') {
this.$confirm('是否确认上传老旧管网改造计划项目名称为"' + row.fProjectName + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function() {
updateProcess({fOldPlanProcessId:row.fOldPlanProcessId,fUploadType:1}).then(response => {
this.msgSuccess("上传成功");
this.open = false;
}).then(function() {
return reportPipeOldPlanProcess({fOldPlanProcessId : row.fOldPlanProcessId});
}).then(() => {
this.getList();
});
return ;
}).then(() => {
this.getList();
this.msgSuccess("上传成功");
}).catch(() => {});
this.msgSuccess("上传成功");
}).catch(() => {});
}
},
handleReport2(row){
var that = this
this.$confirm('是否确认上传老旧管网改造计划项目名称为"' + row.fProjectName + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function() {
that.msgSuccess("上传成功");
this.open = false;
return ;
}).catch(() => {});
}
}
};
</script>
<style>
/* 自定义输入框样式 */
.left-aligned-input .el-input__inner{
text-align: left;
padding-left: 5px; /* 根据需要调整内边距 */
}
</style>
\ No newline at end of file
......@@ -33,6 +33,7 @@
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-if="user.roleId==1||user.roleId==5"
>新增</el-button>
</el-col>
<el-col :span="1.5">
......@@ -43,6 +44,7 @@
size="mini"
:disabled="single"
@click="handleUpdate"
v-if="user.roleId==1||user.roleId==5"
>修改</el-button>
</el-col>
<el-col :span="1.5">
......@@ -53,6 +55,7 @@
size="mini"
:disabled="multiple"
@click="handleDelete"
v-if="user.roleId==1||user.roleId==5"
>删除</el-button>
</el-col>
<el-col :span="1.5">
......@@ -94,7 +97,8 @@
<span v-else>-</span>
</template>
</el-table-column>
<el-table-column label="最后修改时间" align="center" prop="fUpdateTime" />
<el-table-column label="上传状态" align="center" prop="uploadState" :formatter="uploadStateFormat" />
<el-table-column label="上传时间" align="center" prop="uploadTime" :formatter="uploadTimeFormat" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
......@@ -108,17 +112,20 @@
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-if="user.roleId==1||user.roleId==5"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-if="user.roleId==1||user.roleId==5"
>删除</el-button>
<el-button
size="mini"
type="text"
@click="handleReport(scope.row)"
v-if="judgeUploadIsShow((scope.row))"
>上传</el-button>
</template>
</el-table-column>
......@@ -210,10 +217,12 @@
</template>
<script>
import { listInc, getInc, delInc, addInc, updateInc, exportInc, reportAccidentInfo} from "@/api/thirdbuild/accident";
import { listInc, getInc, delInc, addInc, updateInc, exportInc, reportAccidentInfo,entReportConGasProInfo} from "@/api/thirdbuild/accident";
import { conGasProInfoList } from "@/api/thirdbuild/project";
import FileUpload from '@/components/FileUpload';
import{getInfo} from "@/api/login"
let uploadfile = require("@/assets/uploadfile.png");
import { enterpriseLists } from "@/api/regulation/info";
import DetailInfo from "./components/DetailInfo";
export default {
name: "Inc",
......@@ -223,6 +232,8 @@ export default {
},
data() {
return {
user:{},
enterprises: [],
// 遮罩层
loading: true,
// 导出遮罩层
......@@ -280,19 +291,104 @@ export default {
};
},
created() {
this.getList();
this.getProjectInfo();
this.getuserInfo();
this.getEnterpriseLists();
},
methods: {
//所属单位
getEnterpriseLists(){
const param = {};
enterpriseLists(param).then(response => {
if (response.rows.length>1){
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}else {
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}
});
},
getuserInfo(){
getInfo().then(response => {
this.user = response.user.roles[0]
this.getList();
this.getProjectInfo();
});
},
//上传状态动态展示
uploadStateFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
if (row.entUploadState == '0') {
return "未上传"
} else{
return "已上传"
}
} else {
if (row.govUploadState == '0') {
return "未上传"
} else{
return "已上传"
}
}
},
//上传时间动态展示
uploadTimeFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
return row.entUploadTime;
} else {
return row.govUploadTime;
}
},
/** 查询涉气第三方施工意外事件列表 */
getList() {
this.loading = true;
// 企业查自己的数据
if (this.user.roleId == 5) {
this.queryParams.fCompanyInfoId = this.$store.state.user.enterpriseId
}
listInc(this.queryParams).then(response => {
this.incList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//判断 上传是否需要显示,上传分为企业上传 和 政府端上传
judgeUploadIsShow(row) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
// 企业端 上传状态 0-未上传,1-已上传
let entUploadState = row.entUploadState;
// 政府端 上传状态 0-未上传,1-已上传
let govUploadState = row.govUploadState;
// 如果政府端都已经上传,那就不能显示了。
if(govUploadState === '1') {
return false;
}
// 如果企业端上传了,则企业端就不能显示了,政府端和 超级管理员能显示
if(entUploadState === '1' && govUploadState === '0') {
if (roleId === 5) {
return false;
} else {
return true;
}
}
// 别的情况,都显示
return true;
},
// 取消按钮
cancel() {
this.open = false;
......@@ -340,6 +436,10 @@ export default {
const fConGasProIncId = row.fConGasProIncId || this.ids
getInc(fConGasProIncId).then(response => {
this.form = response.data;
if (this.form.fAttachment) {
this.fileList = [{name: '附件', url: uploadfile}];
}
this.open = true;
this.title = "修改涉气第三方施工意外事件";
});
......@@ -355,6 +455,7 @@ export default {
this.getList();
});
} else {
this.form.fCompanyInfoId=this.enterprises[0].enterpriseId;
addInc(this.form).then(response => {
this.msgSuccess("新增成功");
this.open = false;
......@@ -395,14 +496,19 @@ export default {
},
//获取第三方施工项目信息
getProjectInfo(){
conGasProInfoList({}).then(res =>{
// 企业查自己的数据
let conGasProInfoQueryParams = {};
if (this.user.roleId == 5) {
conGasProInfoQueryParams.fCompanyInfoId= this.$store.state.user.enterpriseId
}
conGasProInfoList(conGasProInfoQueryParams).then(res =>{
if(res.code == 200 && res.data){
this.projectInfo = res.data;
}
})
},
//上传
getFileInfo(res){
getFileInfo(res){
this.form.fAttachment = res.url;
this.fileList.push({
name: res.fileName,
......@@ -420,9 +526,26 @@ export default {
handleDetail(row){
this.$refs.detail.getDetailInfo(row.fConGasProIncId);
},
/** 删除按钮操作 */
handleReport(row) {
this.$confirm('是否确认上传项目编号为"' + row.projectCode + '"的数据项?', "警告", {
/** 上传按钮操作 */
handleReport(row) {
// 如果是 超级管理员 或这企业,并且 企业端上传状态为0
if ((this.user.roleId == 5 || this.user.roleId == 1) && row.entUploadState == '0') {
this.$confirm('是否确认上传项目编号为"' + row.projectCode + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function() {
return entReportConGasProInfo({fConGasProIncId : row.fConGasProIncId});
}).then(() => {
this.getList();
this.msgSuccess("上传成功");
}).catch(() => {});
}
// 如果是 超级管理员 或这政府,并且 政府端上传状态为0
if ((this.user.roleId == 3 || this.user.roleId == 1) && row.govUploadState == '0') {
this.$confirm('是否确认上传项目编号为"' + row.projectCode + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
......@@ -431,7 +554,8 @@ export default {
}).then(() => {
this.getList();
this.msgSuccess("上传成功");
}).catch(() => {});
}).catch(() => {});
}
},
}
};
......
......@@ -257,37 +257,55 @@
<script>
import { getInfor } from "@/api/thirdbuild/project";
import { enterpriseLists } from "@/api/regulation/info";
import { enterpriseLists ,queryAllEnterprise} from "@/api/regulation/info";
import { getDefaultCountyList } from "@/api/area/county";
export default {
name: "detail-info",
data(){
return{
enterprises: [],
countyInfo: [],
enterpriseName:"",
detailInfo: {},
detailOpen: false
}
},
created() {
this.getCountyInfo();
this.getEnterpriseLists();
},
methods:{
//获取县级
getCountyInfo(){
getDefaultCountyList().then(res =>{
if(res.code == 200 && res.data){
this.countyInfo = res.data;
}
})
},
beyondCountyFormat(row){
let info = this.countyInfo.find(item => item.fId == row.fDistrictId);
return info?info.fName:"-";
},
beyondCompanyFormat(row){
let info = this.enterprises.find(item => item.enterpriseId == row.fCompanyInfoId);
return info?info.enterpriseName:"-";
},
//所属单位
getEnterpriseLists(){
const param = {};
enterpriseLists(param).then(response => {
if (response.rows.length>1){
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}else {
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}
getEnterpriseLists(){
queryAllEnterprise().then(response => {
this.enterprises = response;
});
},
getDetailInfo(id){
getInfor(id).then(res =>{
if(res.code == 200 && res.data){
this.detailInfo = res.data;
this.detailInfo.fDistrictId = this.beyondCountyFormat(this.detailInfo);
let companyInfoId = this.detailInfo.fCompanyInfoId;
if (companyInfoId != null) {
this.enterpriseName= this.beyondCompanyFormat(this.detailInfo);
}
this.detailOpen = true;
}
})
......
......@@ -99,6 +99,8 @@
</template>
</el-table-column>
<el-table-column label="管道压力等级分类" align="center" prop="fPipePress" :formatter="fPipePressFormat" />
<el-table-column label="上传状态" align="center" prop="uploadState" :formatter="uploadStateFormat" />
<el-table-column label="上传时间" align="center" prop="uploadTime" :formatter="uploadTimeFormat" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="210">
<template slot-scope="scope">
<el-button
......@@ -144,7 +146,7 @@
<el-form ref="form" :model="form" :rules="rules" label-width="180px">
<el-row class="el-row-table">
<el-col :span="12">
<el-form-item label="燃气企业" prop="fEnterpriseId">
<el-form-item label="燃气企业" prop="fCompanyInfoId">
<el-input v-model="enterpriseName" :disabled="true"></el-input>
</el-form-item>
</el-col>
......@@ -496,6 +498,7 @@ export default {
data() {
return {
enterpriseName:"",
enterprises: [],
user:{},
countyInfo: [],
// 遮罩层
......@@ -529,6 +532,7 @@ export default {
fProjectNo: null,
fProjectName: null,
fPipePress: null,
fCompanyInfoId: null,
},
// 表单参数
form: {},
......@@ -577,7 +581,6 @@ export default {
},
created() {
this.getuserInfo();
this.getList();
this.getCountyInfo();
this.getEnterpriseLists();
this.getDicts("t_pipe_press").then(response => {
......@@ -589,14 +592,12 @@ export default {
getEnterpriseLists(){
const param = {};
enterpriseLists(param).then(response => {
if (response.rows.length>1){
this.enterprises = response.rows;
this.form.fEnterpriseId=response.rows[0].enterpriseId;
this.enterpriseName = response.rows[0].enterpriseName;
}else {
if (response.rows.length>1){
this.enterprises = response.rows;
this.enterpriseName = response.rows[0].enterpriseName;
}else {
this.enterprises = response.rows;
this.form.fEnterpriseId=response.rows[0].enterpriseId;
this.enterpriseName = response.rows[0].enterpriseName;
this.enterpriseName = response.rows[0].enterpriseName;
}
});
},
......@@ -614,7 +615,12 @@ export default {
},
/** 查询涉气第三方施工项目档案列表 */
getList() {
this.loading = true;
this.loading = true;
// 企业查自己的数据
if (this.user.roleId == 5) {
this.queryParams.fCompanyInfoId = this.$store.state.user.enterpriseId
}
console.log("this.queryParams = " + this.queryParams)
listInfor(this.queryParams).then(response => {
this.inforList = response.rows;
this.total = response.total;
......@@ -625,6 +631,35 @@ export default {
fPipePressFormat(row, column) {
return this.selectDictLabel(this.fPipePressOptions, row.fPipePress);
},
//上传状态动态展示
uploadStateFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
if (row.entUploadState == '0') {
return "未上传"
} else{
return "已上传"
}
} else {
if (row.govUploadState == '0') {
return "未上传"
} else{
return "已上传"
}
}
},
//上传时间动态展示
uploadTimeFormat(row, column) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
if (roleId == 5) {
return row.entUploadTime;
} else {
return row.govUploadTime;
}
},
// 取消按钮
cancel() {
this.open = false;
......@@ -698,8 +733,6 @@ export default {
this.reset();
this.open = true;
this.title = "添加涉气第三方施工项目档案";
this.formData.operator_id = this.operatorLists[0].id
},
/** 修改按钮操作 */
handleUpdate(row) {
......@@ -712,9 +745,7 @@ export default {
});
},
//判断 上传是否需要显示,上传分为企业上传 和 政府端上传
judgeUploadIsShow(row) {
console.log("judgeUploadIsShow"+row)
judgeUploadIsShow(row) {
//角色 1 超级管理员 5 企业
let roleId = this.user.roleId;
......@@ -730,9 +761,9 @@ export default {
return false;
}
// 如果企业端上传了,则企业端就不能显示了,政府端能显示
// 如果企业端上传了,则企业端就不能显示了,政府端和 超级管理员能显示
if(entUploadState === '1' && govUploadState === '0') {
if (roleId === 1 | roleId === 5) {
if (roleId === 5) {
return false;
} else {
return true;
......@@ -745,12 +776,13 @@ export default {
},
getuserInfo(){
getInfo().then(response => {
console.log(response);
this.user = response.user.roles[0]
this.getList();
});
},
/** 提交按钮 */
submitForm() {
this.form.fCompanyInfoId=this.enterprises[0].enterpriseId;
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.fConGasProInforId != null) {
......@@ -827,8 +859,8 @@ export default {
/** 上传按钮操作 */
handleReport(row) {
if (this.user.roleId == 1 || this.user.roleId == 5 ) {
// 如果是 超级管理员 或这企业,并且 企业端上传状态为0
if ((this.user.roleId == 5 || this.user.roleId == 1) && row.entUploadState == '0') {
this.$confirm('是否确认上传涉气第三方施工项目档案名称为"' + row.fProjectName + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
......@@ -839,7 +871,10 @@ export default {
this.getList();
this.msgSuccess("上传成功");
}).catch(() => {});
} else {
}
// 如果是 超级管理员 或这政府,并且 政府端上传状态为0
if ((this.user.roleId == 3 || this.user.roleId == 1) && row.govUploadState == '0') {
this.$confirm('是否确认上传涉气第三方施工项目档案名称为"' + row.fProjectName + '"的数据项?', "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
......
......@@ -35,8 +35,9 @@ module.exports = {
// detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: {
target: `http://localhost:8905/gassafety`,
// target: `http://localhost:8905/gassafety`,
// target: `http://27.128.233.145:8905/gassafety`,
target: ` http://36.138.180.82:8905/gassafety`,
changeOrigin: true,
pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: ''
......@@ -81,7 +82,7 @@ module.exports = {
.plugin('ScriptExtHtmlWebpackPlugin')
.after('html')
.use('script-ext-html-webpack-plugin', [{
// `runtime` must same as runtimeChunk name. default is `runtime`
// `runtime` must same as runtimeChunk name. default is `runtime`
inline: /runtime\..*\.js$/
}])
.end()
......@@ -111,8 +112,8 @@ module.exports = {
})
config.optimization.runtimeChunk('single'),
{
from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件
to: './', //到根目录下
from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件
to: './', //到根目录下
}
}
)
......
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