10 Commits

Author SHA1 Message Date
jiangyinzhi 63dc3bcc89 xiugai 2025-07-29 10:21:59 +08:00
jiangyinzhi 3523dcade7 修改 2025-06-06 09:34:27 +08:00
jiangyinzhi 0a9ab6ea26 安徽去除留言 2025-05-27 17:13:13 +08:00
jiangyinzhi 2e5613a65c 计划完成时间控制在当年 2025-05-27 17:12:37 +08:00
jiangyinzhi c633e1edce 淘汰数量、二氧化碳系数 2025-05-26 16:11:23 +08:00
jiangyinzhi 91be51e568 设备生产日期可选最小值修改、任务列表增加审核状态 2025-05-20 09:12:17 +08:00
jiangyinzhi d8e4579003 修改 2025-04-29 10:44:41 +08:00
jiangyinzhi 1f689a1b89 2025修订内容更改 2025-04-25 14:25:40 +08:00
jiangyinzhi af0c479609 新疆加警示 2025-04-17 10:44:14 +08:00
jiangyinzhi 561624a90c 修改 2025-01-16 16:21:23 +08:00
58 changed files with 1541 additions and 1119 deletions
+1 -1
View File
@@ -6,7 +6,7 @@ NODE_ENV=production
# 测试0 生产1 # 测试0 生产1
VUE_APP_ENV = '1' VUE_APP_ENV = '1'
# 定义变量 # 定义变量
VUE_APP_CITY_TYPE = 'xj' VUE_APP_CITY_TYPE = 'cq'
# base api # base api
VUE_APP_BASE_API = '' VUE_APP_BASE_API = ''
-47
View File
@@ -5633,11 +5633,6 @@
} }
} }
}, },
"dompurify": {
"version": "3.0.3",
"resolved": "https://registry.npmmirror.com/dompurify/-/dompurify-3.0.3.tgz",
"integrity": "sha512-axQ9zieHLnAnHh0sfAamKYiqXMJAVwu+LM/alQ7WDagoWessyWvMSFyW65CqF3owufNu8HBcE4cM2Vflu7YWcQ=="
},
"domutils": { "domutils": {
"version": "1.7.0", "version": "1.7.0",
"resolved": "https://registry.npmjs.org/domutils/-/domutils-1.7.0.tgz", "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.7.0.tgz",
@@ -15099,48 +15094,6 @@
} }
} }
}, },
"vue-pdf": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/vue-pdf/-/vue-pdf-4.3.0.tgz",
"integrity": "sha512-zd3lJj6CbtrawgaaDDciTDjkJMUKiLWtbEmBg5CvFn9Noe9oAO/GNy/fc5c59qGuFCJ14ibIV1baw4S07e5bSQ==",
"dev": true,
"requires": {
"babel-plugin-syntax-dynamic-import": "^6.18.0",
"loader-utils": "^1.4.0",
"pdfjs-dist": "2.6.347",
"raw-loader": "^4.0.2",
"vue-resize-sensor": "^2.0.0",
"worker-loader": "^2.0.0"
},
"dependencies": {
"emojis-list": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz",
"integrity": "sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q==",
"dev": true
},
"json5": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz",
"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==",
"dev": true,
"requires": {
"minimist": "^1.2.0"
}
},
"loader-utils": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.0.tgz",
"integrity": "sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA==",
"dev": true,
"requires": {
"big.js": "^5.2.2",
"emojis-list": "^3.0.0",
"json5": "^1.0.1"
}
}
}
},
"vue-resize-sensor": { "vue-resize-sensor": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/vue-resize-sensor/-/vue-resize-sensor-2.0.0.tgz", "resolved": "https://registry.npmjs.org/vue-resize-sensor/-/vue-resize-sensor-2.0.0.tgz",
-2
View File
@@ -22,7 +22,6 @@
"core-js": "^3.21.1", "core-js": "^3.21.1",
"crypto-js": "^4.0.0", "crypto-js": "^4.0.0",
"cube-ui": "~1.12.15", "cube-ui": "~1.12.15",
"dompurify": "^3.0.3",
"dsbridge": "^3.1.4", "dsbridge": "^3.1.4",
"echarts": "^4.9.0", "echarts": "^4.9.0",
"es6-promise": "^4.2.8", "es6-promise": "^4.2.8",
@@ -64,7 +63,6 @@
"stylus": "^0.54.5", "stylus": "^0.54.5",
"stylus-loader": "^3.0.2", "stylus-loader": "^3.0.2",
"vue-cli-plugin-cube-ui": "^0.2.5", "vue-cli-plugin-cube-ui": "^0.2.5",
"vue-pdf": "^4.3.0",
"vue-template-compiler": "^2.7.14", "vue-template-compiler": "^2.7.14",
"webpack-bundle-analyzer": "^4.9.0" "webpack-bundle-analyzer": "^4.9.0"
}, },
+2 -2
View File
@@ -18,9 +18,9 @@
content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no"> content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
<link rel="icon" href="<%= BASE_URL %>favicon.ico"> <link rel="icon" href="<%= BASE_URL %>favicon.ico">
<script src="static/lib/echarts.min.js"></script> <script src="static/lib/echarts.min.js"></script>
<!-- <script src="https://cdn.bootcss.com/html2canvas/0.5.0-beta4/html2canvas.min.js"></script> <script src="https://cdn.bootcss.com/html2canvas/0.5.0-beta4/html2canvas.min.js"></script>
<script src="https://unpkg.com/vconsole@latest/dist/vconsole.min.js"></script> <!-- <script src="https://unpkg.com/vconsole@latest/dist/vconsole.min.js"></script>
<script> <script>
var vConsole = new window.VConsole(); var vConsole = new window.VConsole();
</script> --> </script> -->
+27 -1
View File
@@ -282,7 +282,33 @@ export function getPositionData(params) {
// 获取配电信息 // 获取配电信息
export function getNxzdPower(params) { export function getNxzdPower(params) {
return myAxios({ return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdUseEnergyEquipNet/getNxzdPower?customerId=${params}`, url: `${sx}/energy-effcicency-net-service/nxzdUseEnergyEquipNet/getNxzdPower`,
// ?customerId=${params}
method: 'get', method: 'get',
params: { "customerId": params }
})
}
// 建筑面积查重
export function duplicateCheck(params) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdBuildInfoNet/duplicateCheck`,
method: 'POST',
data: params
})
}
// 催办详情查重
export function getList(params) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdUrgingTaskNet/list`,
method: 'POST',
data: params
})
}
//复核记录
export const queryCheckList = (params) => {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdReportTemplaNet/queryCheckList`,
method: 'post',
data:params
}) })
} }
+1 -1
View File
@@ -35,7 +35,7 @@ const LoadingInstance = {
function myAxios(axiosConfig, customOptions) { function myAxios(axiosConfig, customOptions) {
const service = axios.create({ const service = axios.create({
baseURL: axiosConfig.type ? '' : baseURLs, // 设置统一的请求前缀 baseURL: axiosConfig.type ? '' : baseURLs, // 设置统一的请求前缀
timeout: 10000, // 设置统一的超时时长 timeout: 20000, // 设置统一的超时时长
}); });
// 自定义配置 // 自定义配置
+2 -17
View File
@@ -2,6 +2,7 @@
import myAxios from "./axios"; import myAxios from "./axios";
import myAxios2 from "./axios2"; import myAxios2 from "./axios2";
const sx = process.env.VUE_APP_CITY_TYPE == 'sx'?'/ferry_service/ferryController/conveyor':'' const sx = process.env.VUE_APP_CITY_TYPE == 'sx'?'/ferry_service/ferryController/conveyor':''
const sxAdmin = (process.env.VUE_APP_CITY_TYPE == 'sx'||process.env.VUE_APP_CITY_TYPE == 'cq')?'/admin/grsg2':'/thirdpart/grsg'
/** /**
* 查询系统码表 * 查询系统码表
@@ -39,7 +40,7 @@ export function getUserInfo(params) {
//获取ai //获取ai
export function getLoginInfoByGrsg(params) { export function getLoginInfoByGrsg(params) {
return myAxios({ return myAxios({
url: `/thirdpart/grsg/loginGrsg`, //后端接口路由 url: `${sxAdmin}/loginGrsg`, //后端接口路由
method: 'post', method: 'post',
data: params data: params
}) })
@@ -63,21 +64,5 @@ export function getUserLevel() {
} }
//获取返回base64
export function downReportTime(data) {
return myAxios2({
url: `${sx}/energy-effcicency-net-service/nxzdReportTemplaNet/downReportTime`, //后端接口路由
method: 'post',
data
})
}
// 保存日志
export function saveLog(data) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/log/saveLog`, //后端接口路由
method: 'post',
data
})
}
+4 -9
View File
@@ -4,22 +4,17 @@ let baseURL = ''
if (process.env.NODE_ENV === 'development') { if (process.env.NODE_ENV === 'development') {
// 测试环境 // 测试环境
// baseURL = 'http://172.29.69.38:28083/' //后端ip和端口 // baseURL = 'http://172.29.69.38:28083/' //后端ip和端口
// baseURL = 'http://192.168.1.116:28083/' //南京国网测试后端ip和端口 // baseURL = 'http://192.168.1.116:28083/' //测试后端ip和端口
baseURL = 'http://172.29.69.38:19012/' //南京国网测试后端ip和端口 baseURL = 'http://172.29.69.38:19012/' //测试后端ip和端口
// baseURL = 'https://portal.xt.nfjbill.ren:30004/proxy-ah/' //后端ip和端口
// baseURL = 'https://www.greensgcc.com/proxy-ah/effcicency/' //安徽本地测试
// baseURL = 'https://www.greensgcc.com/proxy-nx/' //宁夏本地测试
// baseURL = 'https://www.greensgcc.com/proxy-xj/' //新疆本地测试
// baseURL = 'https://www.greensgcc.com/proxy-sx/' //山西本地测试
} else { } else {
// 生产环境 // 生产环境
// baseURL = '' // 本地 打包以后只需要空路径就行 // baseURL = '' // 本地 打包以后只需要空路径就行
// baseURL = '/proxy-ah' //安徽 打包以后的路径 // baseURL = '/proxy-ah' //安徽 打包以后的路径
// baseURL = '/proxy-nx' //宁夏 打包以后的路径 // baseURL = '/proxy-nx' //宁夏 打包以后的路径
baseURL = '/proxy-xj' //新疆 打包以后的路径 // baseURL = '/proxy-xj' //新疆 打包以后的路径
// baseURL = '/proxy-sx' //山西 打包以后的路径 // baseURL = '/proxy-sx' //山西 打包以后的路径
baseURL = '/proxy-cq' //重庆 打包以后的路径
} }
-12
View File
@@ -43,15 +43,3 @@ export function getSingleTaskInfo(id) {
/**
* 查询客户用电户号列表
* @param data
*/
// nxzdCustomerBasicInfoNet
export function getUseele(data) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdCConsNet/list`, //后端接口路由
method: 'post',
data
})
}
-16
View File
@@ -264,19 +264,3 @@ export function enterprisEdit(params) {
data: params data: params
}) })
} }
// 新增保存企业通用能源系统信息主
export function systemInfoAdd(params) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdEnterprisSystemInfoNet/add`,
method: 'POST',
data: params
})
}
// 修改保存企业通用能源系统信息主
export function systemInfoEdit(params) {
return myAxios({
url: `${sx}/energy-effcicency-net-service/nxzdEnterprisSystemInfoNet/edit`,
method: 'POST',
data: params
})
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

-38
View File
@@ -1,38 +0,0 @@
// 在运行和打包前根据不同的环境切换对应地址和缓存的地址
// picBaseUrl 为接口请求图片的地址前缀 picCachingUrl 为缓存图片的地址前缀 打包前请两者都对应修改
// 民防环境
// const picBaseUrl = 'https://mam1.ft-power.com.cn:10001/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'http://mam6.ft-power.com.cn:10030/fzSP/fileAction.do?method=execute&'
// 策划部环境
// const picBaseUrl = 'https://mam2.ft-power.com.cn:19092/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'https://mam4.ft-power.com.cn:9001/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'http://10.20.32.134:7002/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'http://10.20.32.36:7001/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'http://10.20.32.128:10010/fzSP/fileAction.do?method=execute&'
// 公司本地环境地址
// const picBaseUrl = 'http://10.30.15.7:7009/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = "http://webapp.hoperun.com:9002/fzSP/fileAction.do?method=execute&"
// 生产地址IP和端口
// const picBaseUrl = 'http://10.20.32.161:7007/fzSP/fileAction.do?method=execute&'
const picBaseUrl = 'https://mam.sgcc.com.cn:443/fzSP/fileAction.do?method=execute&'
// const picBaseUrl = 'http://127.0.0.1:10086/fzSP/fileAction.do?method=execute&'
// 缓存图片地址 使用tempFile
const picCachingUrl = 'https://mam.sgcc.com.cn:443/fzSP/tempFile/'
// const picCachingUrl = 'https://mam1.ft-power.com.cn:10001/fzSP/tempFile/'
// const picCachingUrl = 'http://mam6.ft-power.com.cn:10030/fzSP/tempFile/'
// const picCachingUrl = 'https://mam2.ft-power.com.cn:19092/fzSP/tempFile/'
// const picCachingUrl = 'http://10.20.32.134:7002/fzSP/tempFile/'
// const picCachingUrl = 'http://10.30.15.7:7009/fzSP/tempFile/'
// const picCachingUrl = "http://webapp.hoperun.com:9002/fzSP/tempFile/"
// const picCachingUrl = 'http://10.20.32.161:7007/fzSP/tempFile/'
// const picCachingUrl = 'http://10.20.32.36:7001/fzSP/tempFile/'
// const picCachingUrl = 'http://10.20.32.128:10010/fzSP/tempFile/'
// 暂时无用的地址
// http://10.20.32.36:7001/fzSP/
// const picCachingUrl = 'http://10.30.15.7:7009/fzSP/fileAction.do?method=execute&'
// const picCachingUrl = 'http://10.20.32.134:7002/fzSP/fileAction.do?method=execute&'
export { picBaseUrl, picCachingUrl }
-2
View File
@@ -24,8 +24,6 @@ Vue.use(inputDirective);
Vue.use(Vant); Vue.use(Vant);
Vue.prototype.Regexp = Regexp Vue.prototype.Regexp = Regexp
Vue.prototype.$store = store Vue.prototype.$store = store
// Vue.prototype.$picBaseUrl = picBaseUrl
// Vue.prototype.$picCachingUrl = picCachingUrl
const bus = new Vue() const bus = new Vue()
Vue.prototype.$bus = bus Vue.prototype.$bus = bus
+81 -1
View File
@@ -3,6 +3,7 @@ import { getCodeCommon } from '../views/facilityManage/common'
const mixin = { const mixin = {
data() { data() {
return { return {
showOption: false,
/** /**
* 字典表数据 * 字典表数据
*/ */
@@ -23,10 +24,70 @@ const mixin = {
* vuex方法 * vuex方法
*/ */
vuexFunc: '', vuexFunc: '',
vuexChangeFun: '' vuexChangeFun: '',
datePicker: false,
currentDate: new Date(),
maxDate: new Date(),
minDate: new Date('1980/1/2'),
equipTypeOption: {
'01':[
{value: "0101", text: "螺杆式空压机"},
{value: "0102", text: "活塞式空压机"},
{value: "0103", text: "离心式空压机"},
{value: "0104", text: "涡旋式空压机"},
{value: "0105", text: "滑片式空压机"},
{value: "0106", text: "无油空压机"},
],
'02':[
{value: "0201", text: "离心泵"},
{value: "0202", text: "轴流泵"},
{value: "0203", text: "混流泵"},
{value: "0204", text: "往复泵"},
{value: "0205", text: "旋转泵"},
{value: "0206", text: "喷射泵"},
{value: "0207", text: "空气提升泵"},
],
'03':[
{value: "0301", text: "离心式风机"},
{value: "0302", text: "轴流式风机"},
{value: "0303", text: "混流式(斜流式)风机"},
{value: "0304", text: "横流式(贯流式)风机"},
{value: "0305", text: "罗茨风机(容积式)"},
]
},
equipEfficiencyOption: [
{ value: '01', text: '一级能效'},
{ value: '02', text: '二级能效'},
{ value: '03', text: '三级能效'},
{ value: '04', text: '四级能效'},
{ value: '05', text: '五级能效'},
],
element: '',
columnsList: [],
} }
}, },
methods: { methods: {
// 企业公用弹窗
handelClickOptionShow(name, key){
this.element = name
if(key){
this.columnsList = this[name+'Option'][key]
}else{
this.columnsList = this[name+'Option']
}
this.showOption = true
},
onConfirmOption(data){
if(this.$route.params&&this.$route.params.type=='3'){
this.$set(this.form1, this.element, data.value)
this.form1[this.element+'Name'] = data.text
}else{
this.form[this.element] = data.value
this.form[this.element+'Name'] = data.text
}
this.showOption = false
},
//通用的弹框获取数据 //通用的弹框获取数据
async handelClickHeatingShow(type, id, feildName, feild, title) { async handelClickHeatingShow(type, id, feildName, feild, title) {
this.show = !this.showForm this.show = !this.showForm
@@ -153,7 +214,26 @@ const mixin = {
//控制年份取消 //控制年份取消
onCancelYear() { onCancelYear() {
this.yearShow = false this.yearShow = false
},
// 日期选择赋值
onConfirmDate(val) {
var date2 = new Date(val);
var y = date2.getFullYear();
var m = date2.getMonth() + 1;
m = m < 10 ? "0" + m : m;
var d = date2.getDate();
d = d < 10 ? "0" + d : d;
this.form.produceDate = y + "-" + m + "-" + d;
console.log(this.form.produceDate);
if(this.$route.query&&this.$route.query.id=='heating'){
this.$store.commit('search/SET_HEAT_YEAR', this.form)
} }
if(this.$route.params&&this.$route.params.type=='3'){
this.form1.produceDate = y + "-" + m + "-" + d;
}
this.datePicker = false;
},
// change(data) { // change(data) {
// console.log(data); // console.log(data);
// } // }
+1 -10
View File
@@ -303,16 +303,7 @@ export default [
component: () => import('@/views/enterprise/customer.vue') component: () => import('@/views/enterprise/customer.vue')
}, },
// 工业企业-用电户号
{
path: '/useele',
name: 'useele',
meta: {
title: '用电户号',
keepAlive: true
},
component: () => import('@/views/enterprise/useEle.vue')
},
// 工业企业-部分报告 // 工业企业-部分报告
{ {
path: '/partialreport', path: '/partialreport',
+1 -5
View File
@@ -10,11 +10,7 @@ module.exports = {
*/ */
sidebarLogo: true, sidebarLogo: true,
menuExclude: [], menuExclude: [],
// ${process.env.VUE_APP_BASE_API} downloadUrl: `${process.env.VUE_APP_BASE_API}/proxy-cq/file/minio/download/`,
// https://portal.xt.nfjbill.ren:30004
downloadUrl: `${process.env.VUE_APP_BASE_API}/file/minio/download/`,
// downloadUrl: `https://www.greensgcc.com/proxy-xj/file/minio/download/`,
// downloadUrl: `http://172.29.69.38:19012/proxy-sx/file/minio/download/`,
uploadUrl: `${process.env.VUE_APP_BASE_API}/file/minio/upload/`, uploadUrl: `${process.env.VUE_APP_BASE_API}/file/minio/upload/`,
statusCode: { statusCode: {
SUCCESS: 0 SUCCESS: 0
+2
View File
@@ -28,6 +28,7 @@ export default {
cityIsNx: state => state.user.cityIsNx, cityIsNx: state => state.user.cityIsNx,
imageRecognition: state => state.user.imageRecognition, imageRecognition: state => state.user.imageRecognition,
validate: state => state.user.validate, validate: state => state.user.validate,
cityisXj: state => state.user.cityisXj,
/** /**
* 询问的数据 * 询问的数据
*/ */
@@ -57,6 +58,7 @@ export default {
heatMode: state => state.search.heatMode, //采暖方式 heatMode: state => state.search.heatMode, //采暖方式
pumpYear: state => state.search.pumpYear, //输送泵组设备年份 pumpYear: state => state.search.pumpYear, //输送泵组设备年份
pumpNum: state => state.search.pumpNum, //输送泵组台数 pumpNum: state => state.search.pumpNum, //输送泵组台数
produceDate: state => state.search.produceDate, //输送泵组台数
/** /**
* 集中式空调 * 集中式空调
*/ */
+3
View File
@@ -30,6 +30,7 @@ const getDefaultState = () => ({
pumpNum: '', pumpNum: '',
pumpTotalPower: '', pumpTotalPower: '',
pumpYear: '', pumpYear: '',
produceDate: '',
/** /**
* 集中式空调 * 集中式空调
*/ */
@@ -104,7 +105,9 @@ const mutations = {
state.heatIntellectModifyYear = data.heatIntellectModifyYear state.heatIntellectModifyYear = data.heatIntellectModifyYear
state.heatModifyYear = data.heatModifyYear state.heatModifyYear = data.heatModifyYear
state.pumpYear = data.pumpYear state.pumpYear = data.pumpYear
state.produceDate = data.produceDate
}, },
/** /**
* 集中式空调 * 集中式空调
*/ */
+9 -5
View File
@@ -6,7 +6,9 @@ const tokenKey = 'stk',
uidKey = 'suid', uidKey = 'suid',
userTypeKey = 'sut', userTypeKey = 'sut',
duidKey = 'sduid', duidKey = 'sduid',
sak = 'saikey' sak = 'saikey',
useridKey= 'userId',
username= 'username'
const getValueByKey = key => { const getValueByKey = key => {
return sessionStorage.getItem(key) ? sessionStorage.getItem(key) : '' return sessionStorage.getItem(key) ? sessionStorage.getItem(key) : ''
} }
@@ -15,8 +17,8 @@ const getDefaultState = () => ({
token: getValueByKey(tokenKey), token: getValueByKey(tokenKey),
ai: getValueByKey(sak), ai: getValueByKey(sak),
platform: getValueByKey(platformKey), platform: getValueByKey(platformKey),
userid: '', userid: getValueByKey(useridKey),
username: '', username: getValueByKey(username),
realname: '', realname: '',
mobile: '', mobile: '',
uno: '', //0500024691 uno: '', //0500024691
@@ -38,7 +40,8 @@ const getDefaultState = () => ({
cityType: true, //外观图片必填 cityType: true, //外观图片必填
cityIsNx: process.env.VUE_APP_CITY_TYPE=='nx', //宁夏特供-公共机构配电获取 cityIsNx: process.env.VUE_APP_CITY_TYPE=='nx', //宁夏特供-公共机构配电获取
imageRecognition: process.env.VUE_APP_CITY_TYPE=='ah', // 图像识别 imageRecognition: process.env.VUE_APP_CITY_TYPE=='ah', // 图像识别
validate: process.env.VUE_APP_CITY_TYPE=='ah', // 大区间校验 validate: process.env.VUE_APP_CITY_TYPE=='ah', // 大区间校验 任务列表 用户客户标识
cityisXj: process.env.VUE_APP_CITY_TYPE=='xj', // 报告-二氧化碳系数
}) })
const state = getDefaultState() const state = getDefaultState()
@@ -85,6 +88,7 @@ const mutations = {
}, },
SET_USER_NAME: (state, username) => { SET_USER_NAME: (state, username) => {
state.username = username state.username = username
sessionStorage.setItem('username', username)
}, },
SET_REALNAME: (state, realname) => { SET_REALNAME: (state, realname) => {
state.realname = realname state.realname = realname
@@ -152,7 +156,7 @@ const actions = {
getUserInfo({ commit }) { getUserInfo({ commit }) {
console.log(this); console.log(this);
return new Promise((resolve) => { return new Promise((resolve) => {
getUserInfo().then(res => { getUserInfo({t: new Date().getTime()}).then(res => {
// if (res.code == vm.$StatusCode.SUCCESS) { // if (res.code == vm.$StatusCode.SUCCESS) {
if(res.code == 0) { if(res.code == 0) {
console.log(res); console.log(res);
-10
View File
@@ -1,7 +1,6 @@
import html2Canvas from 'html2canvas' import html2Canvas from 'html2canvas'
import JsPDF from 'jspdf' import JsPDF from 'jspdf'
import { buildPDF } from '@/utils/dsbridge.js' import { buildPDF } from '@/utils/dsbridge.js'
// import { downReportTime } from '@/api/common.js'
//前端不作不分页 //前端不作不分页
var getPdf = async function(title, date) { var getPdf = async function(title, date) {
@@ -47,10 +46,6 @@ export default getPdf
// // var getBase64 = async function (data) {
// // const res = await downReportTime(data)
// // }
//前端作分页 //前端作分页
// var getPdf = async function(title, id) { // var getPdf = async function(title, id) {
@@ -175,10 +170,5 @@ export default getPdf
// let formData = new FormData() // let formData = new FormData()
// let fileOfBlob = new File([u8Arr], fileName + '.jpg', options) //返回文件流 // let fileOfBlob = new File([u8Arr], fileName + '.jpg', options) //返回文件流
// formData.append('file', fileOfBlob) // formData.append('file', fileOfBlob)
// const res = await downReportTime(formData)
// if(res.code == 0) {
// const ba64 = `filename=${fileName}.pdf;base64,` + res.data
// buildPDF(ba64)
// }
// } // }
-60
View File
@@ -154,8 +154,6 @@ export function callApi(funName, params) {
export function fileDown (downLoadUrl, fileName, id,data) { export function fileDown (downLoadUrl, fileName, id,data) {
// 测试app // 测试app
// let url = `https://mam.zeus2.top:10030/xtkb-web/file/fileDownload?id=${downLoadUrl}`
// const url = `https://mamjs.sgcc.com.cn:10443/xtkb-web/file/fileDownload?id=${downLoadUrl}`
//正式app //正式app
if (process.env.NODE_ENV === 'production') { if (process.env.NODE_ENV === 'production') {
let url = `/xtkb-web/file/fileDownload?id=${downLoadUrl}` let url = `/xtkb-web/file/fileDownload?id=${downLoadUrl}`
@@ -163,64 +161,6 @@ export function fileDown (downLoadUrl, fileName, id,data) {
}else{ }else{
} }
// // let url = `https://mamjs.sgcc.com.cn:10443/xtkb-web/file/fileDownload?id=${downLoadUrl}`
// function success (result) {
// let type = result.data.event
// switch (type) {
// case 'fail':
// Toast.$create({
// txt: '下载失败',
// type: 'error'
// }).show();
// break;
// case 'progress':
// Toast.$create({
// txt: '正在下载',
// type: 'warn'
// }).show();
// break;
// case 'success':
// Toast.$create({
// txt: '下载成功',
// type: 'success'
// }).show();
// // let urlData = result.fileUrl.split('/serverfile')
// // let newUrl
// // if (urlData.length === 2) {
// // newUrl = urlData[0] + '/serverfile/' + fileName
// // } else {
// // newUrl = result.fileUrl
// // }
// // let dataUrl = data.split('data:')
// mam.navigator.appfilemanage.openFile(url,fileName);
// break;
// }
// }
// // JSINTXTKB
// Dialog.$create({
// type: 'confirm',
// icon: 'cubeic-alert',
// title: '文件',
// content: '是否下载文件',
// confirmBtn: {
// text: '确定下载',
// active: true,
// disabled: false,
// href: 'javascript:;'
// },
// cancelBtn: {
// text: '取消下载',
// active: false,
// disabled: false,
// href: 'javascript:;'
// },
// onConfirm: () => {
// // JSINTXTWZS
// mam.navigator.appfilemanage.fileDownload2(success, 'JSINTXTWZS', '', url, '/serverfile', fileName, id, { id: id })
// },
// onCancel: () => {
// }
// }).show()
} }
// function diyDownload() // function diyDownload()
// { // {
+12
View File
@@ -40,6 +40,18 @@
{{ EnergyReportInfo.refrigeType }} {{ EnergyReportInfo.refrigeType }}
</div> </div>
</div> </div>
<div
class="device-table"
v-if="EnergyReportInfo.existSplitting == 'true'"
>
<div class="device-table-header">分体式空调</div>
<div class="device-table-main con">
合计{{ EnergyReportInfo.splittingNum }}台,<span>负载系数为{{ EnergyReportInfo.splittingLoadFactor }},每日运行{{
EnergyReportInfo.splittingRunHours
}}小时,</span>年平均运行时间为{{ EnergyReportInfo.splittingRunDays }}天,单位面积冷量为{{ EnergyReportInfo.splittingColdPerArea
}}千瓦/平方米,淘汰设备数量{{EnergyReportInfo.splittingDieoutNum}}台。
</div>
</div>
<div <div
class="device-table" class="device-table"
v-if="EnergyReportInfo.existCentralize == 'true'" v-if="EnergyReportInfo.existCentralize == 'true'"
@@ -74,7 +74,7 @@
<p v-else>贵单位无相关节能改造措施,评定不得分。</p> <p v-else>贵单位无相关节能改造措施,评定不得分。</p>
<!-- <p v-else>{{ EnergyReportInfo.conservationScoreNull }}</p> --> <!-- <p v-else>{{ EnergyReportInfo.conservationScoreNull }}</p> -->
<br> <br>
<p>注:各个维度满分为5分。</p> <p>注:各个维度满分为100分。</p>
</div> </div>
</div> </div>
<div class="summarize-btn" style="display:none"> <div class="summarize-btn" style="display:none">
+4 -1
View File
@@ -31,7 +31,7 @@
</div> </div>
</div> </div>
<div class="detail2-right-bottom"> <div class="detail2-right-bottom">
用电户号: {{userCode}}:
<div>{{ EnergyReportInfo.consNo }}</div> <div>{{ EnergyReportInfo.consNo }}</div>
</div> </div>
</div> </div>
@@ -191,6 +191,9 @@ export default {
localStorage.removeItem('firstEnter') localStorage.removeItem('firstEnter')
}, },
computed: { computed: {
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
timeSelectShow() { timeSelectShow() {
if(sessionStorage.getItem('level') == 2 && this.taskType != 5 && this.energyData.taskId && !this.EnergyReportInfo.handState && this.EnergyReportInfo.grsgState == '2') { if(sessionStorage.getItem('level') == 2 && this.taskType != 5 && this.energyData.taskId && !this.EnergyReportInfo.handState && this.EnergyReportInfo.grsgState == '2') {
return true return true
+4 -1
View File
@@ -48,7 +48,7 @@
</div> --> </div> -->
</div> </div>
<div class="detail2-right-bottom"> <div class="detail2-right-bottom">
用电户号:{{ EnergyReportInfo.consNo }} {{userCode}}:{{ EnergyReportInfo.consNo }}
</div> </div>
</div> </div>
</div> </div>
@@ -416,6 +416,9 @@ export default {
}) })
}, },
computed: { computed: {
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
getName(){ getName(){
let res = '' let res = ''
if(this.EnergyReportInfo.buildType&&this.EnergyReportInfo.buildType.indexOf('/')>0){ if(this.EnergyReportInfo.buildType&&this.EnergyReportInfo.buildType.indexOf('/')>0){
@@ -13,7 +13,7 @@
<van-cell-group> <van-cell-group>
<van-cell required title="客户名称" is-link :value="customerName" @click="clientSelect" /> <van-cell required :title="userName" is-link :value="customerName" @click="clientSelect" />
<van-field v-model="address" label="地址" placeholder="请输入" input-align="right"> <van-field v-model="address" label="地址" placeholder="请输入" input-align="right">
@@ -41,7 +41,7 @@
<van-popup v-model="datePicker" position="bottom"> <van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" @confirm="onConfirm" @cancel="datePicker = false" /> <van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirm" @cancel="datePicker = false" />
</van-popup> </van-popup>
@@ -49,7 +49,7 @@
<van-popup v-model="datePicker2" position="bottom"> <van-popup v-model="datePicker2" position="bottom">
<van-datetime-picker v-model="currentDate2" type="date" :min-date="minDate" @confirm="onConfirm2" @cancel="datePicker2 = false" /> <van-datetime-picker v-model="currentDate2" type="date" :min-date="minDate2" :max-date="maxDate" @confirm="onConfirm2" @cancel="datePicker2 = false" />
</van-popup> </van-popup>
@@ -82,6 +82,19 @@ export default {
computedTime: "请选择" computedTime: "请选择"
}; };
}, },
computed:{
userName(){
return this.$store.getters.validate? '用户名称':'客户名称'
},
maxDate(){
const now = new Date()
return new Date(now.getFullYear(), 11, 31)
},
minDate2(){
return new Date(this.currentDate)
},
},
created() { created() {
let customer = sessionStorage.getItem("customer"); let customer = sessionStorage.getItem("customer");
let customerMsg = JSON.parse(customer) let customerMsg = JSON.parse(customer)
@@ -109,6 +122,10 @@ export default {
d = d < 10 ? "0" + d : d; d = d < 10 ? "0" + d : d;
this.dateTime = y + "-" + m + "-" + d; this.dateTime = y + "-" + m + "-" + d;
this.datePicker = false; this.datePicker = false;
if (this.computedTime&&!(Date.parse(this.computedTime) > Date.parse(this.dateTime))) {
console.log('true');
this.computedTime = '请选择'
}
}, },
// 日期选择赋值 // 日期选择赋值
onConfirm2(val) { onConfirm2(val) {
@@ -625,6 +625,18 @@ export default {
}, },
//提交页面信息 //提交页面信息
saveAllInfo() { saveAllInfo() {
const city = process.env.VUE_APP_CITY_TYPE=='cq'
const must = this.iconList&&this.iconList.some(ele => ele.typeId == '1'||ele.typeId=='8'||ele.typeId=='9')&&this.iconList.some(ele => ele.typeId=='3')&&this.iconList.some(ele => ele.typeId=='4')
// )&&ele.typeId=='3'&&ele.typeId=='4'}
console.log(city, must ,this.iconList, 'lllllllllllllllllll')
if(!must&&city){
this.$notify({
message: '主要用能设备空调至少填一个、照明系统与配电系统必填',
duration: 1000,
type: 'warning'
})
return
}
let item = JSON.parse(sessionStorage.getItem('tidCid')).item let item = JSON.parse(sessionStorage.getItem('tidCid')).item
if(!item.isPosition){ if(!item.isPosition){
this.$notify({ this.$notify({
@@ -1,78 +1,179 @@
<template> <template>
<div> <div>
<Loading :loading="loading"/> <Loading :loading="loading" />
<div class="list"> <div class="list">
<div class="container"> <div class="container">
<van-form ref="form" @submit="handelClickSave"> <van-form ref="form" @submit="handelClickSave">
<div class="part"> <div class="part">
<div class="nengyuan"> <div class="nengyuan">
<van-cell-group> <van-cell-group>
<!--客户名称 --> <!--客户名称 -->
<van-field v-model="customer.customerName" label="客户名称" placeholder="请输入" required :rules="[{ required: true }]" input-align="right" disabled /> <van-field
v-model="customer.customerName"
:label="userName"
placeholder="请输入"
required
:rules="[{ required: true }]"
input-align="right"
disabled
/>
<!-- 客户类型 --> <!-- 客户类型 -->
<van-field v-model="customerTypeName" is-link readonly required label="客户类型" placeholder="请选择" disabled /> <van-field
v-model="customerTypeName"
is-link
readonly
required
label="客户类型"
placeholder="请选择"
disabled
/>
<!-- 用电户号 --> <!-- 用电户号 -->
<van-field v-model="customer.consNo" is-link readonly required label="用电户号" placeholder="" disabled /> <van-field
v-model="customer.consNo"
is-link
readonly
required
:label="userCode"
placeholder=""
disabled
/>
<!-- 所属区域 --> <!-- 所属区域 -->
<van-field v-model="provOrgName" is-link readonly required label="所属区域" placeholder="请选择" @click="provOrgNoShow = true" /> <van-field
v-model="provOrgName"
is-link
readonly
required
label="所属区域"
placeholder="请选择"
@click="provOrgNoShow = true"
/>
<!-- 供电公司 --> <!-- 供电公司 -->
<van-field v-model="powerCompanyName" is-link readonly required label="供电公司" placeholder="请选择" @click="handelClickPowerCompany"/> <van-field
v-model="powerCompanyName"
is-link
readonly
required
label="供电公司"
placeholder="请选择"
@click="handelClickPowerCompany"
/>
<!-- 社会信用代码 --> <!-- 社会信用代码 -->
<van-field v-model="customer.creditCode" label="社会信用代码" placeholder="请输入" input-align="right"> <van-field
required
:rules="[{ required: true }]"
v-model="customer.creditCode"
label="社会信用代码"
placeholder="请输入"
input-align="right"
>
</van-field> </van-field>
<div class="tips" v-if="tip1">社会信用代码长度为18位</div>
<!-- 联系人 --> <!-- 联系人 -->
<van-field v-model="customer.contactName" label="联系人" placeholder="请输入" input-align="right"> <van-field
required
:rules="[{ required: true }]"
v-model="customer.contactName"
label="联系人"
placeholder="请输入"
input-align="right"
>
</van-field> </van-field>
<div class="tips" v-if="tip2">2≤字符串长度≤10</div>
<!--联系电话 --> <!--联系电话 -->
<van-field v-input.num v-model="customer.contactPhone" label="联系电话" maxlength="11" placeholder="请输入" input-align="right"> <van-field
required
:rules="[{ required: true }]"
v-input.num
v-model="customer.contactPhone"
label="联系电话"
maxlength="11"
placeholder="请输入"
input-align="right"
>
</van-field> </van-field>
<!--详细地址 --> <!--详细地址 -->
<van-field v-model="customer.detailAddress" label="详细地址" placeholder="请输入" input-align="right"> <van-field
v-model="customer.detailAddress"
label="详细地址"
placeholder="请输入"
input-align="right"
>
</van-field> </van-field>
<div class="tips" v-if="tip3">
4≤字符串长度≤100
</div>
<!-- 立户时间 --> <!-- 立户时间 -->
<van-field v-if="show" v-model="customer.registerTime" is-link readonly required :rules="[{ required: true }]" label="立户时间" placeholder="请选择" @click="handelClickYearShow"/> <van-field
v-if="show"
v-model="customer.registerTime"
is-link
readonly
required
:rules="[{ required: true }]"
label="立户时间"
placeholder="请选择"
@click="handelClickYearShow"
/>
<!-- 接入电压(V) --> <!-- 接入电压(V) -->
<van-field v-if="show" v-model="customer.inVoltage" label="接入电压(V)" placeholder="请输入" required :rules="[{ required: true }]" input-align="right" /> <van-field
v-if="show"
v-model="customer.inVoltageText"
label="接入电压(kV)"
required
:rules="[{ required: true }]"
input-align="right"
is-link
placeholder="请选择"
readonly
@click="levelShow = true"
/>
<!-- 产品类型 --> <!-- 产品类型 -->
<van-field v-if="show" v-model="customer.productType" label="产品类型" placeholder="请输入" required :rules="[{ required: true }]" input-align="right" /> <van-field
v-if="show"
v-model="customer.productType"
label="产品类型"
placeholder="请输入"
required
:rules="[{ required: true }]"
input-align="right"
/>
<!-- 产品单耗 --> <!-- 产品单耗 -->
<van-field v-if="show" required :rules="[{ required: true }]" v-model="customer.productUnitConsume" v-input.float label="产品单耗(kgce/t)" placeholder="请输入" input-align="right" /> <van-field
v-if="show"
required
:rules="[{ required: true }]"
v-model="customer.productUnitConsume"
v-input.float
label="产品单耗(kgce/t)"
placeholder="请输入"
input-align="right"
/>
</van-cell-group> </van-cell-group>
</div> </div>
<div class="btn"> <div class="btn">
@@ -85,11 +186,27 @@
</div> </div>
<!-- 客户类型 --> <!-- 客户类型 -->
<van-popup disabled v-model="customerTypeShow" round position="bottom"> <van-popup disabled v-model="customerTypeShow" round position="bottom">
<van-cascader :field-names="fieldNames" v-model="customer.customerType" title="请选择客户类型" :options="customerTypeList" @close="customerTypeShow = false" @finish="onFinish" /> <van-cascader
:field-names="fieldNames"
v-model="customer.customerType"
title="请选择客户类型"
:options="customerTypeList"
@close="customerTypeShow = false"
@finish="onFinish"
/>
</van-popup> </van-popup>
<!-- 所属区域 --> <!-- 所属区域 -->
<van-popup v-model="provOrgNoShow" round position="bottom"> <van-popup v-model="provOrgNoShow" round position="bottom">
<van-cascader :field-names="orgFieldNames" v-model="customer.provOrgNo" title="请选择所属区域" :options="provOrgList" :props="backList" @close="provOrgNoShow = false" @finish="onFinish1" @change="changeProv" /> <van-cascader
:field-names="orgFieldNames"
v-model="customer.provOrgNo"
title="请选择所属区域"
:options="provOrgList"
:props="backList"
@close="provOrgNoShow = false"
@finish="onFinish1"
@change="changeProv"
/>
</van-popup> </van-popup>
<!-- 供电公司 --> <!-- 供电公司 -->
<van-popup v-model="powerCompanyShow" round position="bottom"> <van-popup v-model="powerCompanyShow" round position="bottom">
@@ -123,10 +240,34 @@
@cancel="onCancelYear" @cancel="onCancelYear"
/> />
</van-popup> --> </van-popup> -->
<!-- 电压等级 -->
<VanPickerNew :show="levelShow">
<div class="content">
<div class="content-head">
<div @click="onCancelLe">取消</div>
<div @click="onConfirmLe">确认</div>
</div>
<div class="content-main">
<van-cell
v-for="item in levelList"
:key="item.value"
clickable
style="font-weight: 400 !important; font-size: 15px !important"
>
<van-checkbox
:name="item"
checked-color="#009999"
v-model="item.checked"
@click="clickCheckbox(item)"
>
{{ item.name }}
</van-checkbox>
</van-cell>
</div>
</div>
</VanPickerNew>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
@@ -135,39 +276,95 @@ import { Notify } from 'vant'
import { getCode, getOrgList } from '@/api/common.js' import { getCode, getOrgList } from '@/api/common.js'
import { customerEdit, getSingleInfo } from '@/api/customer.js' import { customerEdit, getSingleInfo } from '@/api/customer.js'
import Loading from '@/components/loading' import Loading from '@/components/loading'
import VanPickerNew from '@/components/vanPickerNew'
export default { export default {
name: 'burstingList', name: 'burstingList',
components: { components: {
Loading, Loading,
VanPickerNew,
}, },
computed: { computed: {
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
userName(){
return this.$store.getters.validate? '用户名称':'客户名称'
},
show() { show() {
if (sessionStorage.getItem('customerType') == 2) { if (sessionStorage.getItem('customerType') == 2) {
return true return true
} }
return false return false
}, },
tip1() {
return this.customer.creditCode.length != 18
},
tip2() {
let flag = this.handelChange('contactName', 2, 10)
return flag
},
tip3() {
let flag = this.handelChange('detailAddress', 4, 100)
return flag
},
}, },
data() { data() {
return { return {
currentDate:new Date(), levelList: [
{
name: '10',
value: '01',
checked: false,
},
{
name: '35',
value: '04',
checked: false,
},
{
name: '110',
value: '05',
checked: false,
},
{
name: '220',
value: '06',
checked: false,
},
{
name: '20',
value: '07',
checked: false,
},
{
name: '66',
value: '09',
checked: false,
},
{
name: '330',
value: '10',
checked: false,
},
],
currentDate: new Date(),
yearShow: false, yearShow: false,
value5: '', //产品单耗 value5: '', //产品单耗
value4: '', //产品类型 value4: '', //产品类型
value3: '', //接入电压(V) value3: '', //接入电压(V)
value2: '2023-10-10', //立户时间 value2: '2023-10-10', //立户时间
value1: '', //用电户号 value1: '', //用电户号
loading: false,//loading参数 loading: false, //loading参数
powerCompanyShow:false, powerCompanyShow: false,
powerCompanyName: '', powerCompanyName: '',
powerColumns:[], powerColumns: [],
//客户展示及传递的参数 //客户展示及传递的参数
customer: { customer: {
customerName: '', customerName: '',
customerType: '', customerType: '',
provOrgNo: '', provOrgNo: '',
powerCompany:'', powerCompany: '',
// //区号 // //区号
orgNo: '', orgNo: '',
// //省份编号 // //省份编号
@@ -177,23 +374,24 @@ export default {
contactPhone: '', contactPhone: '',
detailAddress: '', detailAddress: '',
consNo: '', consNo: '',
registerTime:'', registerTime: '',
inVoltage:'', inVoltage: '',
productType:'', inVoltageText: '',
productUnitConsume:'', productType: '',
productUnitConsume: '',
}, },
//自定义客户字段名称 //自定义客户字段名称
fieldNames: { fieldNames: {
text: 'name', text: 'name',
value: 'code', value: 'code',
children: 'child' children: 'child',
}, },
//自定义所属区域字段名称 //自定义所属区域字段名称
orgFieldNames: { orgFieldNames: {
text: 'codeName', text: 'codeName',
pCode: 'pcodeValue', pCode: 'pcodeValue',
value: 'codeValue', value: 'codeValue',
children: 'children' children: 'children',
}, },
backList: [], backList: [],
//客户类型中文展示 //客户类型中文展示
@@ -210,15 +408,20 @@ export default {
provOrgList: [], provOrgList: [],
//错误提示 //错误提示
errorMessage: '', errorMessage: '',
takPath: this.$store.getters.takPath.path ? this.$store.getters.takPath.path : JSON.parse(sessionStorage.getItem('goPage')).path takPath: this.$store.getters.takPath.path
? this.$store.getters.takPath.path
: JSON.parse(sessionStorage.getItem('goPage')).path,
levelShow: false,
//电压等级选中的数据
resultCheckboxLevel: [],
} }
}, },
watch: { watch: {
provOrgList: function(newVal) { provOrgList: function (newVal) {
this.getOrgData(newVal, this.customer.orgNo) this.getOrgData(newVal, this.customer.orgNo)
}
}, },
beforeDestroy () { },
beforeDestroy() {
sessionStorage.removeItem('numArr') sessionStorage.removeItem('numArr')
}, },
created() { created() {
@@ -229,14 +432,59 @@ export default {
this.getPersonData() this.getPersonData()
}, },
methods: { methods: {
handelChange(params, min, max) {
console.log(this.customer[params].length > min, 'this.customer[params]')
if (
(this.customer[params] && this.customer[params].length < min) ||
this.customer[params].length > max
) {
return true
} else {
return false
}
},
getData(value) {
let res = this.levelList.filter((ele) => {
return ele.value == value
})
return res && res[0] && res[0].name
},
/**
* 电压等级
*/
onCancelLe() {
this.levelList.forEach((v) => {
this.resultCheckboxLevel.forEach((rv) => {
if (v.value == rv.value) {
v.checked = true
}
})
})
this.levelShow = false
},
onConfirmLe() {
const leName = this.levelList.filter((ele) => ele.checked)
this.resultCheckboxLevel = leName
this.customer.inVoltage = leName.map((ele) => ele.value).join(',')
this.customer.inVoltageText = leName.map((ele) => ele.name).join(',')
this.levelShow = false
},
clickCheckbox(item) {
this.levelList.forEach((v) => {
v.checked = false
if (v.value == item.value) {
v.checked = true
}
})
},
async powerList() { async powerList() {
const data = { const data = {
codeSortId: "80000001100", codeSortId: '80000001100',
codeType: "gdgs" codeType: 'gdgs',
} }
const res = await getCode(data) const res = await getCode(data)
if(res.code == 0) { if (res.code == 0) {
const list = res.data.map((v)=> { const list = res.data.map((v) => {
return { return {
text: v.name, text: v.name,
code: v.code, code: v.code,
@@ -244,16 +492,15 @@ export default {
} }
}) })
this.powerColumns = list this.powerColumns = list
this.powerColumns.forEach(element => { this.powerColumns.forEach((element) => {
if (element.code == this.customer.powerCompany && element.text) { if (element.code == this.customer.powerCompany && element.text) {
this.powerCompanyName = element.text this.powerCompanyName = element.text
} }
}); })
} }
}, },
async handelClickPowerCompany() { async handelClickPowerCompany() {
this.powerCompanyShow = true this.powerCompanyShow = true
}, },
onConfirmPowerCompanyShow(val) { onConfirmPowerCompanyShow(val) {
this.powerCompanyName = val.text this.powerCompanyName = val.text
@@ -262,15 +509,15 @@ export default {
}, },
formatter(type, val) { formatter(type, val) {
if (type === 'year') { if (type === 'year') {
return val + '年'; return val + '年'
} }
if (type === 'month') { if (type === 'month') {
return val + '月'; return val + '月'
} }
if (type === 'day') { if (type === 'day') {
return val + '日'; return val + '日'
} }
return val; return val
}, },
handelClickYearShow() { handelClickYearShow() {
this.yearShow = true this.yearShow = true
@@ -280,8 +527,8 @@ export default {
const y = data.getFullYear() const y = data.getFullYear()
const m = data.getMonth() + 1 const m = data.getMonth() + 1
const d = data.getDate() const d = data.getDate()
const fm = m < 10? '0' + m : m const fm = m < 10 ? '0' + m : m
const fd = d < 10? '0' + d : d const fd = d < 10 ? '0' + d : d
const time = y + '-' + fm + '-' + fd const time = y + '-' + fm + '-' + fd
this.customer.registerTime = time this.customer.registerTime = time
this.yearShow = false this.yearShow = false
@@ -292,11 +539,11 @@ export default {
}, },
getOrgData(list, code) { getOrgData(list, code) {
list.forEach(v => { list.forEach((v) => {
if (!v.children) { if (!v.children) {
return return
} }
v.children.forEach(ev => { v.children.forEach((ev) => {
if (ev.codeValue == code) { if (ev.codeValue == code) {
this.provOrgName = ev.codeName this.provOrgName = ev.codeName
} }
@@ -323,19 +570,37 @@ export default {
this.customer.powerCompany = res.data.powerCompany this.customer.powerCompany = res.data.powerCompany
this.getCustomerType() this.getCustomerType()
this.powerList() this.powerList()
if(numArr) { if (numArr) {
this.customer.consNos = JSON.parse(numArr) this.customer.consNos = JSON.parse(numArr)
this.customer.consNo = JSON.parse(numArr).map((ele)=> ele.consNo).join('/') this.customer.consNo = JSON.parse(numArr)
.map((ele) => ele.consNo)
.join('/')
return return
} }
const data = { const data = {
name:res.data.customerName, name: res.data.customerName,
list: res.data.consNos list: res.data.consNos,
}
if (this.customer.inVoltage) {
this.resultCheckboxLevel = []
this.levelList.forEach((ele) => {
ele.checked = false
if (ele.value == this.customer.inVoltage) {
ele.checked = true
this.resultCheckboxLevel.push(ele)
}
})
this.customer.inVoltage = this.resultCheckboxLevel
.map((ele) => ele.value)
.join(',')
this.customer.inVoltageText = this.resultCheckboxLevel
.map((ele) => ele.name)
.join(',')
} }
sessionStorage.setItem('customer', JSON.stringify(data)) sessionStorage.setItem('customer', JSON.stringify(data))
} }
} } finally {
finally {
this.loading = false this.loading = false
} }
}, },
@@ -343,7 +608,7 @@ export default {
async getCustomerType() { async getCustomerType() {
const data = { const data = {
codeSortId: '80000001004', codeSortId: '80000001004',
codeType: 'khlx' codeType: 'khlx',
} }
const res = await getCode(data) const res = await getCode(data)
if (res.code === 0) { if (res.code === 0) {
@@ -362,11 +627,11 @@ export default {
}, },
//递归获取客户数据 //递归获取客户数据
getData(data, type) { getData(data, type) {
data.forEach(ele => { data.forEach((ele) => {
if (!(ele.child && ele.child.length)) { if (!(ele.child && ele.child.length)) {
return return
} }
ele.child.forEach(v => { ele.child.forEach((v) => {
if (v.code == type && v.name) { if (v.code == type && v.name) {
this.customerTypeName = v.name this.customerTypeName = v.name
} }
@@ -389,7 +654,7 @@ export default {
}, },
//递归获取多选数据 //递归获取多选数据
getCheckboxInfo(list, code) { getCheckboxInfo(list, code) {
const data = list.find(v => { const data = list.find((v) => {
if (!v.children) { if (!v.children) {
return v return v
} }
@@ -417,7 +682,10 @@ export default {
}, },
//点击确认提交 //点击确认提交
async handelClickSave() { async handelClickSave() {
this.$refs.form.validate(); this.$refs.form.validate()
if(this.tip1||this.tip2||this.tip3){
return
}
// eslint-disable-next-line no-empty-pattern, no-unused-vars // eslint-disable-next-line no-empty-pattern, no-unused-vars
for (const _key in this.customer) { for (const _key in this.customer) {
delete this.customer['changeTime'] delete this.customer['changeTime']
@@ -438,16 +706,13 @@ export default {
customerTypeSure() {}, customerTypeSure() {},
//所属区域点击确认 //所属区域点击确认
provOrgSure() {}, provOrgSure() {},
//用电户号点击操作 },
// goUseele() {
// this.$router.push('/useele')
// }
}
} }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@import '../facilityManage/common-vue/common.less';
@import '../facilityManage/common-vue/checkbox.less';
/deep/ .van-field__control, /deep/ .van-field__control,
/deep/.van-field__error-message { /deep/.van-field__error-message {
text-align: right; text-align: right;
@@ -492,4 +757,11 @@ export default {
color: #63cbb6; color: #63cbb6;
font-weight: 500; font-weight: 500;
} }
.tips {
padding: 0 16px;
display: flex;
justify-content: flex-end;
color: #ee0a24;
font-size: 12px;
}
</style> </style>
+10 -2
View File
@@ -2,7 +2,7 @@
<div class="list"> <div class="list">
<!-- <Header :title="title" @onClickLeft="onClickLeft" /> --> <!-- <Header :title="title" @onClickLeft="onClickLeft" /> -->
<van-search <van-search
placeholder="请输入客户名称/联系人/联系电话/地址" :placeholder="placeholder"
v-model="value" v-model="value"
@search="search" @search="search"
/> />
@@ -22,7 +22,7 @@
@click="clickRadio(item, index)" @click="clickRadio(item, index)"
> >
<p>{{item.customerName}}</p> <p>{{item.customerName}}</p>
用电户号:{{ item.consNo }} {{userCode}}:{{ item.consNo }}
<!-- <van-radio :name="index" /> --> <!-- <van-radio :name="index" /> -->
</van-cell> </van-cell>
</van-list> </van-list>
@@ -62,6 +62,14 @@ export default {
pages: 1, // 页数 pages: 1, // 页数
}; };
}, },
computed:{
placeholder(){
return this.$store.getters.validate? '请输入用户名称/联系人/联系电话/地址':'请输入客户名称/联系人/联系电话/地址'
},
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
},
mounted() { mounted() {
this.getData(); this.getData();
}, },
+7 -6
View File
@@ -148,11 +148,12 @@ export default {
getPositionData({taskId: this.taskId}).then(res => { getPositionData({taskId: this.taskId}).then(res => {
console.log(res.code , res.data); console.log(res.code , res.data);
if(res.code == 0&&res.data){ if(res.code == 0&&res.data){
for (const key in this.formData) { // for (const key in this.formData) {
if (Object.hasOwnProperty.call(this.formData, key)) { // if (Object.hasOwnProperty.call(this.formData, key)) {
this.formData[key] = res.data[key] // this.formData[key] = res.data[key]
} // }
} // }
this.formData = res.data
if (res.data.fileId) { if (res.data.fileId) {
this.$set(this.text1,0, { this.$set(this.text1,0, {
fileName: res.data.fileName, fileName: res.data.fileName,
@@ -162,7 +163,7 @@ export default {
console.log(this.text1); console.log(this.text1);
} }
this.$forceUpdate() this.$forceUpdate()
this.showSubmit = false this.showSubmit = true
}else{ }else{
this.showSubmit = true this.showSubmit = true
this.getLocation() this.getLocation()
+30 -21
View File
@@ -13,13 +13,15 @@
<van-field v-model="formData.buildName" label="建筑名称" required :rules="[{ required: true, message: '请填写建筑名称' }]" placeholder="请输入" input-align="right"> <van-field v-model="formData.buildName" label="建筑名称" required :rules="[{ required: true, message: '请填写建筑名称' }]" placeholder="请输入" input-align="right">
</van-field> </van-field>
<van-cell title="建筑类型" is-link :value="showData.buildType1" required @click="showPicker = !showForm"/> <van-cell title="建筑类型" is-link :value="showData.buildType1" required @click="showPicker = !showForm"/>
<van-cell title="用电户名称" :value="formData.consNo" /> <van-cell :title="userCode" :value="formData.consNo" />
<van-cell title="统一社会识别编码" :value="formData.creditCode" /> <van-cell title="统一社会识别编码" :value="formData.creditCode" />
<van-cell title="联系人" :value="formData.contactName" /> <van-cell title="联系人" :value="formData.contactName" />
<van-cell title="联系人手机号" :value="formData.contactPhone" /> <van-cell title="联系人手机号" :value="formData.contactPhone" />
<van-cell title="详细地址" :value="formData.detailAddress" /> <van-cell title="详细地址" :value="formData.detailAddress" />
<van-field v-model="formData.totalArea" v-input.float label="总建筑面积(㎡)" placeholder="请输入" @input="showTips" type="number" required :rules="[{ required: true }]" input-align="right"> <van-field v-model="formData.totalArea" v-input.float label="总建筑面积(㎡)" placeholder="请输入" @input="showTips" @blur="checkArea" type="number" required :rules="[{ required: true }]" input-align="right">
</van-field> </van-field>
<div class="tips" v-if="checkAreaTip">同一社会信用代码下建筑面积和用能人数重复</div>
<div class="tips" v-if="!checkAreaTip&&formData.totalArea>50000">总建筑面积&gt;5万平方米,请确认是否属实</div>
<div class="tips" v-if="tips0 == true">0&lt;总建筑面积&lt;{{validateData}}万平方米</div> <div class="tips" v-if="tips0 == true">0&lt;总建筑面积&lt;{{validateData}}万平方米</div>
<div class="tips" v-if="tips1 == true">要大于可利用屋面面积或者地下车库面积</div> <div class="tips" v-if="tips1 == true">要大于可利用屋面面积或者地下车库面积</div>
<van-field v-model="formData.availableArea" v-input.float label="可利用屋面面积(㎡)" placeholder="请输入" required :rules="[{ required: true}]" @input="showTips1" type="number" input-align="right"> <van-field v-model="formData.availableArea" v-input.float label="可利用屋面面积(㎡)" placeholder="请输入" required :rules="[{ required: true}]" @input="showTips1" type="number" input-align="right">
@@ -39,8 +41,9 @@
<div class="tips" v-if="tips7 == true">数据机房面积≤0.5*总建筑面积</div> <div class="tips" v-if="tips7 == true">数据机房面积≤0.5*总建筑面积</div>
<van-cell title="建筑投运年份(年)" is-link required :rules="[{ required: true, message: '请选择建筑投运年份年份' }]" :value="formData.operationYear" @click="handelOpen" /> <van-cell title="建筑投运年份(年)" is-link required :rules="[{ required: true, message: '请选择建筑投运年份年份' }]" :value="formData.operationYear" @click="handelOpen" />
<!-- <van-field v-model="formData.operationYear" label="建筑投运年份(年)" label-width="140" input-align="right" is-link placeholder="请选择" readonly @click="handelClickYear('operationYear', 'SET_HEAT_YEAR')" /> --> <!-- <van-field v-model="formData.operationYear" label="建筑投运年份(年)" label-width="140" input-align="right" is-link placeholder="请选择" readonly @click="handelClickYear('operationYear', 'SET_HEAT_YEAR')" /> -->
<van-field v-model="formData.peopleNum" v-input.numNo0 required :rules="[{required: true, message: `请先选择建筑类型再填写` }]" :label="peopleShow" placeholder="" type="number" input-align="right"> <van-field v-model="formData.peopleNum" v-input.numNo0 required @blur="checkArea" :rules="[{required: true, message: `请先选择建筑类型再填写` }]" :label="peopleShow" placeholder="" type="number" input-align="right">
</van-field> </van-field>
<div class="tips" v-if="checkAreaTip">同一社会信用代码下建筑面积和用能人数重复</div>
<van-cell title="建筑外观照片" :required="$store.getters.cityType" :rules="[{ required: $store.getters.cityType}] "/> <van-cell title="建筑外观照片" :required="$store.getters.cityType" :rules="[{ required: $store.getters.cityType}] "/>
<van-uploader v-model="fileList" :max-count="3" :after-read="afterRead" :before-delete="delImg" @click-upload="onUpload" preview-size="100px" class="uploader" ref="file" /> <van-uploader v-model="fileList" :max-count="3" :after-read="afterRead" :before-delete="delImg" @click-upload="onUpload" preview-size="100px" class="uploader" ref="file" />
<div class="tips tipImage" v-if="$store.getters.cityType&&fileList.length<1">请上传建筑外观照片</div> <div class="tips tipImage" v-if="$store.getters.cityType&&fileList.length<1">请上传建筑外观照片</div>
@@ -57,9 +60,9 @@
<van-cell title="是否享受峰谷平电价" required is-link :value="showData.valleyElectricityPrices1" @click="showPicker3 = !showForm" /> <van-cell title="是否享受峰谷平电价" required is-link :value="showData.valleyElectricityPrices1" @click="showPicker3 = !showForm" />
<van-cell title="是否使用绿电交易" required is-link :value="showData.greenElectricityTrading1" @click="showPickerLd = !showForm" /> <van-cell title="是否使用绿电交易" required is-link :value="showData.greenElectricityTrading1" @click="showPickerLd = !showForm" />
<van-cell title="已使用清洁能源" required is-link :value="result1" @click="showPicker4 = !showForm" /> <van-cell title="已使用清洁能源" required is-link :value="result1" @click="showPicker4 = !showForm" />
<van-field v-model="formData.photovoltaicArea" required :rules="[{ required: gfShow == 1 }]" label="光伏总建设面积(㎡)" placeholder="请输入" type="number" input-align="right" v-if="gfShow == 1"> <van-field v-model="formData.photovoltaicArea" required :rules="[{ required: gfShow == 1 }]" label="光伏已建设面积(㎡)" placeholder="请输入" type="number" input-align="right" v-if="gfShow == 1">
</van-field> </van-field>
<div class="tips" v-if="tips8 == true&&gfShow == 1">光伏总建设面积+可利用屋面面积<总建筑面积</div> <div class="tips" v-if="tips8 == true&&gfShow == 1">光伏已建设面积+可利用屋面面积<总建筑面积</div>
<van-field v-model="formData.photovoltaicPhotovoltaic" required :rules="[{ required: gfShow == 1 }]" label="光伏总装机容量(kW)" placeholder="请输入" type="number" input-align="right" v-if="gfShow == 1"> <van-field v-model="formData.photovoltaicPhotovoltaic" required :rules="[{ required: gfShow == 1 }]" label="光伏总装机容量(kW)" placeholder="请输入" type="number" input-align="right" v-if="gfShow == 1">
</van-field> </van-field>
<div class="tips" v-if="tips9 == true&&gfShow == 1">50×光伏已建设面积/1000<光伏总装机容量<200×光伏已建设面积/1000</div> <div class="tips" v-if="tips9 == true&&gfShow == 1">50×光伏已建设面积/1000<光伏总装机容量<200×光伏已建设面积/1000</div>
@@ -296,7 +299,6 @@
import Year from '@/views/facilityManage/common-vue/year.vue' import Year from '@/views/facilityManage/common-vue/year.vue'
import mixin from '@/mixins/mixin' import mixin from '@/mixins/mixin'
// import { Toast } from 'vant' // import { Toast } from 'vant'
// saveLog
import { getCode } from '@/api/common.js' import { getCode } from '@/api/common.js'
import { addEnergyEquip } from '@/api/energyConsumption' import { addEnergyEquip } from '@/api/energyConsumption'
import { downloadUrl } from '@/settings' import { downloadUrl } from '@/settings'
@@ -312,6 +314,7 @@ import {
uploadFile, uploadFile,
changeSaveStateAPI, changeSaveStateAPI,
// downloadFile, // downloadFile,
duplicateCheck,
} from '@/api/api.js' } from '@/api/api.js'
// import { debuglog } from 'util' // import { debuglog } from 'util'
import {debounce} from '@/utils/common.js' import {debounce} from '@/utils/common.js'
@@ -500,7 +503,7 @@ export default {
purchasePower: '1', // 购电方式 purchasePower: '1', // 购电方式
basicCharge: '1', // 基本电费 basicCharge: '1', // 基本电费
valleyElectricityPrices: '2', // 是否享受峰谷平电价 valleyElectricityPrices: '2', // 是否享受峰谷平电价
photovoltaicArea: '0', // 光伏总建设面积 photovoltaicArea: '0', // 光伏已建设面积
photovoltaicPhotovoltaic: '0', // 光伏总装机容量 photovoltaicPhotovoltaic: '0', // 光伏总装机容量
reclaimedWater: '2', // 是否采用再生水 reclaimedWater: '2', // 是否采用再生水
reclaimedWaterType: '', // 再生水类型 reclaimedWaterType: '', // 再生水类型
@@ -597,12 +600,17 @@ export default {
], ],
validateData: '', validateData: '',
doDebounce: null, doDebounce: null,
checkAreaTip: false
} }
}, },
watch: { watch: {
}, },
computed: { computed: {
userCode(){
console.log(this.$store.getters.validate, 'this.$store.getters.validate')
return this.$store.getters.validate? '用户编号':'用电户号'
},
resulta() { resulta() {
if (!this.result) { if (!this.result) {
return return
@@ -722,6 +730,19 @@ export default {
}, },
methods: { methods: {
async checkArea(){
if(this.formData.totalArea>50000&&this.formData.peopleNum){
let params = {
totalArea: this.formData.totalArea,
customerId: this.formData.customerId,
peopleNum: this.formData.peopleNum,
year: this.tidCid.item&&this.tidCid.item.year
}
let res = await duplicateCheck(params)
this.checkAreaTip = res.data
}
},
showTips() { showTips() {
if (Number(this.formData.totalArea)>0&&Number(this.formData.totalArea)<this.validateData*10000) { if (Number(this.formData.totalArea)>0&&Number(this.formData.totalArea)<this.validateData*10000) {
this.tips0 = false this.tips0 = false
@@ -837,18 +858,6 @@ export default {
}) })
}, },
//保存绿网传来的数据
// async saveGreenComeData(content) {
// const tidCid = JSON.parse(sessionStorage.getItem('tidCid'))
// console.log(tidCid);
// const data = {
// businessKey: "buildBusinessKey",
// content: content,
// customerId: tidCid.customerId
// }
// const res = await saveLog(data)
// console.log(res);
// },
//点击选择日期时只展示年份 //点击选择日期时只展示年份
handelOpen() { handelOpen() {
@@ -1864,7 +1873,7 @@ export default {
// this.formData.enquireIds = this.aarr1.concat(this.aarr) // this.formData.enquireIds = this.aarr1.concat(this.aarr)
// } // }
// this.tips6 == true || // this.tips6 == true ||
if(this.tips0 == true || this.tips1 == true || this.tips2 == true || this.tips3 == true || this.tips4 == true || this.tips6 == true || this.tips7){ if(this.checkAreaTip|| this.tips0 == true || this.tips1 == true || this.tips2 == true || this.tips3 == true || this.tips4 == true || this.tips6 == true || this.tips7){
return; return;
} }
if(this.gfShow == 1&&(this.tips8||this.tips9)){ if(this.gfShow == 1&&(this.tips8||this.tips9)){
@@ -2021,7 +2030,7 @@ export default {
purchasePower: '1', // 购电方式 purchasePower: '1', // 购电方式
basicCharge: '1', // 基本电费 basicCharge: '1', // 基本电费
valleyElectricityPrices: '2', // 是否享受峰谷平电价 valleyElectricityPrices: '2', // 是否享受峰谷平电价
photovoltaicArea: '', // 光伏总建设面积 photovoltaicArea: '', // 光伏已建设面积
photovoltaicPhotovoltaic: '', // 光伏总装机容量 photovoltaicPhotovoltaic: '', // 光伏总装机容量
reclaimedWater: '2', // 是否采用再生水 reclaimedWater: '2', // 是否采用再生水
reclaimedWaterType: '', // 再生水类型 reclaimedWaterType: '', // 再生水类型
@@ -287,7 +287,7 @@ export default {
const id = JSON.parse(sessionStorage.getItem('tidCid')).customerId const id = JSON.parse(sessionStorage.getItem('tidCid')).customerId
const res = await getCustomerStatisticAPI(id) const res = await getCustomerStatisticAPI(id)
if (res.code == 0) { if (res.code == 0) {
this.customerStatistic = res.data this.customerStatistic = res.data||{}
} }
}, },
//获取当前页面信息 //获取当前页面信息
+42 -27
View File
@@ -1,6 +1,8 @@
<template> <template>
<div class="energyindex"> <div class="energyindex">
<!-- <Header :title="title" @onClickLeft="onClickLeft" /> --> <!-- <Header :title="title" @onClickLeft="onClickLeft" /> -->
<img v-if="warningShow" src="@/assets/warning.jpg" alt="" />
<!-- 原本的回退存放地 --> <!-- 原本的回退存放地 -->
<van-nav-bar class="energyindex-header" /> <van-nav-bar class="energyindex-header" />
<div class="all"> <div class="all">
@@ -215,7 +217,15 @@ export default {
return { return {
ai: '', ai: '',
title: '能效管理', title: '能效管理',
total: [ total0: [
{ name: '已完成用户数', num: '', color: '#00ad9f' },
{ name: '已完成公共机构', num: '', color: '#ffae00' },
{ name: '已完成工业企业', num: '', color: '#0078ff' },
{ name: '用户总数', num: '', color: '#00ad9f' },
{ name: '公共机构', num: '', color: '#ffae00' },
{ name: '工业企业', num: '', color: '#0078ff' }
],
total1: [
{ name: '已完成客户数', num: '', color: '#00ad9f' }, { name: '已完成客户数', num: '', color: '#00ad9f' },
{ name: '已完成公共机构', num: '', color: '#ffae00' }, { name: '已完成公共机构', num: '', color: '#ffae00' },
{ name: '已完成工业企业', num: '', color: '#0078ff' }, { name: '已完成工业企业', num: '', color: '#0078ff' },
@@ -241,10 +251,14 @@ export default {
searchValue: '', //搜索的内容 searchValue: '', //搜索的内容
searchRespon: {}, //搜索结果 searchRespon: {}, //搜索结果
searchFaly: false, //展示搜索结果 searchFaly: false, //展示搜索结果
type: '' //01公共建筑02工业企业 type: '', //01公共建筑02工业企业
warningShow: false,
} }
}, },
computed: { computed: {
total(){
return this.$store.getters.validate? this.total0: this.total1
},
fomtList() { fomtList() {
this.list.forEach(v => { this.list.forEach(v => {
this.typeList.forEach(ev => { this.typeList.forEach(ev => {
@@ -273,9 +287,10 @@ export default {
this.getStatistic() this.getStatistic()
this.getCustomerType() this.getCustomerType()
// this.init() // this.init()
this.warningShow= process.env.VUE_APP_CITY_TYPE=='xj'
}, },
mounted() { mounted() {
this.getAi() // this.getAi()
if(this.$route.query.type == 2) { if(this.$route.query.type == 2) {
this.handleSelect('2') this.handleSelect('2')
} else { } else {
@@ -283,30 +298,30 @@ export default {
} }
}, },
methods: { methods: {
//获取到ai // //获取到ai
async getAi() { // async getAi() {
const params = sessionStorage.getItem('saikey') // const params = sessionStorage.getItem('saikey')
const res = await getAi({ai: params}) // const res = await getAi({ai: params})
if(res.code == 0 && !res.data) { // if(res.code == 0 && !res.data) {
return // return
} // }
this.ai = res.data // this.ai = res.data
// Dialog.confirm({ // // Dialog.confirm({
// title: '标题', // // title: '标题',
// message: `${res.data}`, // // message: `${res.data}`,
//}).then(() => { // //}).then(() => {
// var cInput = document.createElement("input"); // // var cInput = document.createElement("input");
// cInput.value = res.data; // // cInput.value = res.data;
// document.body.appendChild(cInput); // // document.body.appendChild(cInput);
// cInput.select(); // 选取文本框内容 // // cInput.select(); // 选取文本框内容
// // 执行浏览器复制命令 // // // 执行浏览器复制命令
// // 复制命令会将当前选中的内容复制到剪切板中(这里就是创建的input标签) // // // 复制命令会将当前选中的内容复制到剪切板中(这里就是创建的input标签)
// // Input要在正常的编辑状态下原生复制方法才会生效 // // // Input要在正常的编辑状态下原生复制方法才会生效
// document.execCommand("copy"); // // document.execCommand("copy");
// document.body.removeChild(cInput); // // document.body.removeChild(cInput);
// // on confirm // // // on confirm
//}) // //})
}, // },
// 搜索 // 搜索
async searchEveryItem() { async searchEveryItem() {
if (!this.searchValue) { if (!this.searchValue) {
+134 -6
View File
@@ -18,7 +18,7 @@
v-model="page.consName" v-model="page.consName"
@keydown.enter="onSearch" @keydown.enter="onSearch"
type="text" type="text"
placeholder="请输入客户名称" :placeholder="placeholder"
/> />
</div> </div>
</div> </div>
@@ -173,18 +173,33 @@
<div class="location"> <div class="location">
<img src="@/assets/gyqy/three.png" alt="" /> <img src="@/assets/gyqy/three.png" alt="" />
</div> </div>
<div class="address">用电户号: {{ item.consNo }}</div> <div class="address">{{userCode}}: {{ item.consNo }}</div>
</div> </div>
<!-- </div> --> <!-- </div> -->
<div class="list-bot"> <div class="list-bot">
<div >
<van-tag
@click="stateShow(item)"
v-if="item.checkState" :type="item.checkState=='0'?'danger':item.checkState=='10'?'warning':item.checkState=='20'?'warning':'success'" round >
{{checkStateObj[item.checkState]}}
</van-tag>
</div>
<div> <div>
<button <button
@click="show=true" @click="show=true"
style="margin-left: 10px;" style="margin-left: 10px;"
v-if="!$store.getters.validate"
> >
留言 留言
</button> </button>
<button
v-if="item.urgingStatus =='1'&&!$store.getters.validate"
@click="cuiban(item)"
style="margin-left: 10px;"
>
催办详情
</button>
<button <button
@click="goClockIn(item)" @click="goClockIn(item)"
style="margin-left: 10px;" style="margin-left: 10px;"
@@ -204,7 +219,7 @@
@click="goUserEvaluatePage(item)" @click="goUserEvaluatePage(item)"
style="margin-left: 10px;" style="margin-left: 10px;"
> >
用户评价 查看评价
</button> </button>
<button <button
@@ -247,10 +262,27 @@
</van-field> </van-field>
</van-dialog> </van-dialog>
<van-dialog class="cuiban" v-model="showCuiban" :title="isCuiban?'催办详情':'驳回详情'" show-confirm-button :show-cancel-button="false" :lazy-render="false" @confirm="showCuiban=false" >
<div class="item-user-time" v-for="(item, index) in cuibanList" :key="index">
<div class="user-time">
<div class="item-user">
<span class="label">{{isCuiban?'催办人':item.stateName+'人'}}:</span>
<span>{{item.urgingUser}}</span>
</div>
<div class="item-time">
<span>{{item.urgingTime}}</span>
</div>
</div>
<div class="cuiban-content">
<span class="label">{{isCuiban?'催办内容':item.stateName+'意见'}}:</span>
{{ item.text }}
</div>
</div>
</van-dialog>
</div> </div>
</template> </template>
<script> <script>
import { taskList, genReport } from '@/api/api.js' import { taskList, genReport, getList, queryCheckList } from '@/api/api.js'
import { getCurrentPersonInfoAPI } from "@/api/customerIformation.js"; import { getCurrentPersonInfoAPI } from "@/api/customerIformation.js";
import { getCode } from '@/api/common.js' import { getCode } from '@/api/common.js'
import Year from '@/views/facilityManage/common-vue/year.vue' import Year from '@/views/facilityManage/common-vue/year.vue'
@@ -264,6 +296,12 @@ export default {
}, },
data() { data() {
return { return {
checkStateObj: {
'0': '审批驳回',
'10': '地市待审批',
'20': '省级待审批',
'90': '审批通过',
},
show: false, show: false,
message: '', message: '',
statusPopup: false, statusPopup: false,
@@ -302,6 +340,10 @@ export default {
pageN: 1, pageN: 1,
isList: false, isList: false,
doDebounce: null, doDebounce: null,
cuibanList: [],
showCuiban: false,
isCuiban: false,
gridData: []
} }
}, },
watch: { watch: {
@@ -319,6 +361,14 @@ export default {
beforeDestroy() { beforeDestroy() {
// sessionStorage.removeItem('tidCid') // sessionStorage.removeItem('tidCid')
}, },
computed:{
placeholder(){
return this.$store.getters.validate? '请输入用户名称':'请输入客户名称'
},
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
},
async mounted() { async mounted() {
this.doDebounce = debounce(function (item) { this.doDebounce = debounce(function (item) {
this.getReport(item) this.getReport(item)
@@ -343,6 +393,44 @@ export default {
} }
}, },
methods: { methods: {
async stateShow(item){
if(item.checkState == '0'){
let obj = {
templaId: item.templaId,
}
let res = await queryCheckList(obj)
let {code, data} = res
if (code === 0) {
data.forEach((item) => {
item.urgingUser = item.checkUserName
item.urgingTime = item.createTime
item.text = item.checkDesc
if (item.state == '1') {
item.stateName = '通过'
}
if (item.state == '2') {
item.stateName = '驳回'
}
})
this.cuibanList = data
this.isCuiban = false
this.showCuiban = true
}
}
},
async cuiban(data){
let params = {taskId: data.id}
let res = await getList(params)
if(res.code == 0 ){
this.cuibanList = res.data&&res.data.records||[]
}
this.isCuiban = true
this.showCuiban = true
},
onRefresh() { onRefresh() {
// 清空列表数据 // 清空列表数据
this.finished = false this.finished = false
@@ -476,7 +564,7 @@ export default {
Initiateappointment() { Initiateappointment() {
this.$router.push('/Initiateappointment') this.$router.push('/Initiateappointment')
}, },
// 用户评价 // 查看评价
goUserEvaluatePage(item) { goUserEvaluatePage(item) {
this.setCurrentTidCidPersonInfo(item) this.setCurrentTidCidPersonInfo(item)
this.$router.push({ this.$router.push({
@@ -642,7 +730,11 @@ export default {
height: 100vh; height: 100vh;
overflow-y: auto; overflow-y: auto;
} }
/deep/.van-dialog__content{
max-height: 250px;
overflow-y: auto;
}
.select-box { .select-box {
width: 100%; width: 100%;
background: #fff; background: #fff;
@@ -734,7 +826,12 @@ export default {
.list-bot { .list-bot {
margin-top: 6px; margin-top: 6px;
display: flex; display: flex;
justify-content: flex-end; align-items: center;
justify-content: space-between;
.van-tag{
padding: 4px 8px!important;
word-break: keep-all;
}
div { div {
color: #a1a1a1; color: #a1a1a1;
margin-top: 3px; margin-top: 3px;
@@ -863,5 +960,36 @@ export default {
::v-deep .van-picker__confirm { ::v-deep .van-picker__confirm {
color: #34baae; color: #34baae;
} }
.item-user-time {
width: 100%;
display: flex;
flex-direction: column;
font-size: 12px;
align-items: center;
color: #646566;;
justify-content: space-around;
.label{
width: 60px;
display: inline-block;
text-align: right;
}
.user-time {
justify-content: space-between;
width: 85%;
height: 20px;
display: flex;
align-items: center;
}
.item-user{
margin-right: 10px;
}
.cuiban-content {
margin: 5px 0 20px;
text-align: left;
width: 85%;
}
}
</style> </style>
+14 -1
View File
@@ -250,7 +250,19 @@ export default {
} }
}, },
enterpriseenergy() { enterpriseenergy() {
taskList({ consNo: this.info.consNo }).then((res) => {
this.records = res.data.list[0]
if (!this.records.enterpriseId) {
this.$notify({
message: '请填写能源管理信息',
duration: 1000,
// background: '#34baae',
type: 'danger'
})
return false
}
this.$router.push('./enterpriseenergy') this.$router.push('./enterpriseenergy')
})
}, },
// 返回 // 返回
onClickLeft() { onClickLeft() {
@@ -302,13 +314,14 @@ export default {
if (res.code === 0) { if (res.code === 0) {
this.info = res.data this.info = res.data
// const data = { // const data = {
console.log(res.data, 'pppp')
// customerId: JSON.parse(sessionStorage.getItem('tidCid')).customerId, // customerId: JSON.parse(sessionStorage.getItem('tidCid')).customerId,
// taskId: JSON.parse(sessionStorage.getItem('tidCid')).taskId, // taskId: JSON.parse(sessionStorage.getItem('tidCid')).taskId,
// taskType: JSON.parse(sessionStorage.getItem('tidCid')).taskType, // taskType: JSON.parse(sessionStorage.getItem('tidCid')).taskType,
// enterpriseSystemId: JSON.parse(sessionStorage.getItem('tidCid')).enterpriseSystemId, // enterpriseSystemId: JSON.parse(sessionStorage.getItem('tidCid')).enterpriseSystemId,
// item: res.data // item: res.data
// } // }
// sessionStorage.setItem('tidCid', JSON.stringify(data)) sessionStorage.setItem('inVoltage', this.info.inVoltage)
}else{ }else{
this.info = JSON.parse(sessionStorage.getItem('tidCid')).item this.info = JSON.parse(sessionStorage.getItem('tidCid')).item
} }
+4
View File
@@ -405,6 +405,10 @@ export default {
}, },
save() { save() {
if(!(this.list&&this.list.length>0)){
this.$toast('请输入泵机系统信息')
return
}
if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) { if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) {
return return
} }
@@ -8,6 +8,8 @@
<van-cell-group> <van-cell-group>
<van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" maxlength="20" label="泵机型号" placeholder="请输入泵机型号"/> <van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" maxlength="20" label="泵机型号" placeholder="请输入泵机型号"/>
<van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" maxlength="20" label="电机型号" placeholder="请输入电机型号"/> <van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" maxlength="20" label="电机型号" placeholder="请输入电机型号"/>
<van-field label="设备类型" v-model="form.equipTypeName" required :rules="[{ required: true }]" placeholder="请选择设备类型" is-link readonly @click="handelClickOptionShow('equipType','02')" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" /> <van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" />
<van-field v-input.floatNo0 v-model="form.ratedPowerValue" type="number" required :rules="[{ required: true }]" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange"/> <van-field v-input.floatNo0 v-model="form.ratedPowerValue" type="number" required :rules="[{ required: true }]" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange"/>
<van-field v-input.float v-model="form.frequencyPerValue" type="number" required :rules="[{ required: true }]" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" /> <van-field v-input.float v-model="form.frequencyPerValue" type="number" required :rules="[{ required: true }]" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" />
@@ -15,6 +17,8 @@
<van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰泵机数量" placeholder="请输入" /> <van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰泵机数量" placeholder="请输入" />
<van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="泵机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','泵机效率')" /> <van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="泵机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','泵机效率')" />
<van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" /> <van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.runHours" type="number" label="累计运行小时数" required :rules="[{ required: true }]" placeholder="请输入" />
</van-cell-group> </van-cell-group>
</div> </div>
</div> </div>
@@ -33,10 +37,16 @@
</div> </div>
</van-overlay> </van-overlay>
<Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" /> <Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" />
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</template> </template>
<script> <script>
import VanPickerNew from '@/components/vanPickerNew'
import { pumpAdd, pumpGetInfo, pumpEdit } from "@/api/universalEnergy.js" import { pumpAdd, pumpGetInfo, pumpEdit } from "@/api/universalEnergy.js"
import { Notify } from "vant"; import { Notify } from "vant";
import mixin from '@/mixins/mixin' import mixin from '@/mixins/mixin'
@@ -45,6 +55,7 @@ import {debounce} from '@/utils/common.js'
export default { export default {
components: { components: {
// Header, // Header,
VanPickerNew,
Year Year
}, },
mixins: [mixin], mixins: [mixin],
@@ -64,6 +75,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}, },
show: false, show: false,
doDebounce: null, doDebounce: null,
@@ -81,6 +96,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}; };
let msg = JSON.parse(sessionStorage.getItem('tidCid')); let msg = JSON.parse(sessionStorage.getItem('tidCid'));
this.userMsg = msg this.userMsg = msg
@@ -164,6 +183,10 @@ export default {
const res = await pumpGetInfo(this.id); const res = await pumpGetInfo(this.id);
if(res.code == 0) { if(res.code == 0) {
this.form = res.data this.form = res.data
let Efficiency = res.data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == res.data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
let equipType = res.data.equipType&&this.equipTypeOption['02'].find(item => item.value == res.data.equipType)
this.form.equipTypeName = equipType&&equipType.text
this.show = false this.show = false
}else { }else {
this.show = false this.show = false
+10 -2
View File
@@ -330,7 +330,7 @@ export default {
dataDetail: {}, dataDetail: {},
active: 0, active: 0,
list: [], // 企业具有的通用能源系统 list: [], // 企业具有的通用能源系统
listValue: [], //企业具有的通用能源系统value值 listValue: ['01'], //企业具有的通用能源系统value值
list2: [], // 一级计量(进出用能企业) list2: [], // 一级计量(进出用能企业)
listValue2: ['01'], listValue2: ['01'],
listValue3: [], listValue3: [],
@@ -380,6 +380,7 @@ export default {
}, },
watch: { watch: {
result: function(newVal, oldVal) { result: function(newVal, oldVal) {
console.log(newVal,'12344');
if (oldVal != newVal) { if (oldVal != newVal) {
if (this.listValue != []) { if (this.listValue != []) {
this.listValue = [] this.listValue = []
@@ -784,9 +785,11 @@ export default {
let res1 = await getCode(info1) let res1 = await getCode(info1)
if (res1.code === 0) { if (res1.code === 0) {
res1.data.forEach(v => { res1.data.forEach(v => {
this.list.push({ name: v.name, value: v.value }) this.list.push({ name: v.name, value: v.value })
}) })
} }
}, },
handleClick(){ handleClick(){
this.doDebounce() this.doDebounce()
@@ -796,7 +799,12 @@ export default {
if(this.showForm) { if(this.showForm) {
return return
} }
console.log(this.listValue2, 'this.listValue2'); if( this.listValue.indexOf("01") === -1){
this.$toast('通用能源系统必须有配电系统')
return
}
console.log(this.listValue2, 'this.listValue2', this.list);
return
if( this.listValue2.indexOf("01") === -1){ if( this.listValue2.indexOf("01") === -1){
this.$toast('一级计量必须有勾选电') this.$toast('一级计量必须有勾选电')
return return
+4
View File
@@ -407,6 +407,10 @@ export default {
this.doDebounce() this.doDebounce()
}, },
save() { save() {
if(!(this.list&&this.list.length>0)){
this.$toast('请输入风机系统信息')
return
}
if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) { if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) {
return return
} }
@@ -8,6 +8,8 @@
<van-cell-group> <van-cell-group>
<van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="风机型号" placeholder="请输入风机型号" maxlength="20" /> <van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="风机型号" placeholder="请输入风机型号" maxlength="20" />
<van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="电机型号" placeholder="请输入电机型号" maxlength="20"/> <van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="电机型号" placeholder="请输入电机型号" maxlength="20"/>
<van-field label="设备类型" v-model="form.equipTypeName" required :rules="[{ required: true }]" placeholder="请选择设备类型" is-link readonly @click="handelClickOptionShow('equipType','03')" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field v-input.numNo0 v-model="form.systemNum" required :rules="[{ required: true }]" type="number" label="台数(台)" placeholder="请输入台数" /> <van-field v-input.numNo0 v-model="form.systemNum" required :rules="[{ required: true }]" type="number" label="台数(台)" placeholder="请输入台数" />
<van-field v-input.floatNo0 v-model="form.ratedPowerValue" required :rules="[{ required: true }]" type="number" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange('ratedPowerValue',20,'单台额定功率')"/> <van-field v-input.floatNo0 v-model="form.ratedPowerValue" required :rules="[{ required: true }]" type="number" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange('ratedPowerValue',20,'单台额定功率')"/>
<van-field v-input.float v-model="form.frequencyPerValue" required :rules="[{ required: true }]" type="number" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" /> <van-field v-input.float v-model="form.frequencyPerValue" required :rules="[{ required: true }]" type="number" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" />
@@ -15,6 +17,8 @@
<van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰风机数量" placeholder="请输入" /> <van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰风机数量" placeholder="请输入" />
<van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="风机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','风机效率')" /> <van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="风机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','风机效率')" />
<van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" /> <van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.runHours" type="number" label="累计运行小时数" required :rules="[{ required: true }]" placeholder="请输入" />
</van-cell-group> </van-cell-group>
</div> </div>
</div> </div>
@@ -33,10 +37,16 @@
</div> </div>
</van-overlay> </van-overlay>
<Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" /> <Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" />
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</template> </template>
<script> <script>
import VanPickerNew from '@/components/vanPickerNew'
import { fanAdd, fanGetInfo, fanEdit } from "@/api/universalEnergy.js" import { fanAdd, fanGetInfo, fanEdit } from "@/api/universalEnergy.js"
import { Notify } from "vant"; import { Notify } from "vant";
// import Header from "@/components/headerNew"; // import Header from "@/components/headerNew";
@@ -46,6 +56,7 @@ import {debounce} from '@/utils/common.js'
export default { export default {
components: { components: {
// Header, // Header,
VanPickerNew,
Year Year
}, },
mixins: [mixin], mixins: [mixin],
@@ -64,6 +75,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}, },
show: false, show: false,
doDebounce: null, doDebounce: null,
@@ -81,6 +96,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}; };
let msg = JSON.parse(sessionStorage.getItem('tidCid')); let msg = JSON.parse(sessionStorage.getItem('tidCid'));
this.userMsg = msg this.userMsg = msg
@@ -164,6 +183,10 @@ export default {
const res = await fanGetInfo(this.id); const res = await fanGetInfo(this.id);
if(res.code == 0) { if(res.code == 0) {
this.form = res.data this.form = res.data
let Efficiency = res.data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == res.data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
let equipType = res.data.equipType&&this.equipTypeOption['03'].find(item => item.value == res.data.equipType)
this.form.equipTypeName = equipType&&equipType.text
this.show = false this.show = false
}else { }else {
this.show = false this.show = false
+40 -1
View File
@@ -21,7 +21,7 @@
<span>型号 {{ item.systemModel }} </span><span><van-icon name="arrow" color="#fff" /></span> <span>型号 {{ item.systemModel }} </span><span><van-icon name="arrow" color="#fff" /></span>
</div> </div>
<div class="space-between" style="margin-top: 10px;font-size: 12px;"> <div class="space-between" style="margin-top: 10px;font-size: 12px;">
<span>单台额定容量:{{ item.ratedCapacityValue }} kVA</span><span>额定一次电压:{{ item.ratedVoltageValue }} kV</span> <span>单台额定容量:{{ item.ratedCapacityValue }} kVA</span><span>额定一次电压:{{ getData(item.ratedVoltageValue) }} </span>
</div> </div>
</div> </div>
</div> </div>
@@ -136,6 +136,37 @@ export default {
}, },
data() { data() {
return { return {
voltageLevelData:[{
name:'10kV',
value:"01",
// },{
// name:'380V',
// value:"02",
// },{
// name:'6kV',
// value:"03",
},{
name:'35kV',
value:"04",
},{
name:'110kV',
value:"05",
},{
name:'220kV',
value:"06",
},{
name:'20kV',
value:"07",
// },{
// name:'220V',
// value:"08",
},{
name:'66kV',
value:"09",
},{
name:'330kV',
value:"10",
}],
newAnswer: [], // 问答题存 newAnswer: [], // 问答题存
title: '配电系统', title: '配电系统',
userMsg: {}, // 任务列表单条数据 userMsg: {}, // 任务列表单条数据
@@ -198,6 +229,10 @@ export default {
}, },
}, },
methods: { methods: {
getData(value){
let res = this.voltageLevelData.filter(ele => {return ele.value == value})
return res&&res[0]&&res[0].name
},
/** /**
* 图片方法 * 图片方法
*/ */
@@ -393,6 +428,10 @@ export default {
}, },
// 保存 // 保存
save() { save() {
if(!(this.list&&this.list.length>0)){
this.$toast('请输入配电系统信息')
return
}
if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) { if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) {
return return
} }
+68 -11
View File
@@ -9,11 +9,13 @@
<van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="型号" maxlength="20" placeholder="请输入型号"/> <van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="型号" maxlength="20" placeholder="请输入型号"/>
<van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" /> <van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" />
<van-field v-input.numNo0 v-model="form.ratedCapacityValue" required :rules="[{ required: true }]" ltype="number" label="单台额定容量(kVA)" placeholder="请输入" @blur="handelChange('ratedCapacityValue',50,'单台额定容量')"/> <van-field v-input.numNo0 v-model="form.ratedCapacityValue" required :rules="[{ required: true }]" ltype="number" label="单台额定容量(kVA)" placeholder="请输入" @blur="handelChange('ratedCapacityValue',50,'单台额定容量')"/>
<van-field v-input.floatNo0 v-model="form.ratedVoltageValue" required :rules="[{ required: true }]" type="number" label="额定一次电压(kV)" input-align="right" is-link placeholder="请选择" readonly @click="levelShow = true"/> <van-field v-input.floatNo0 v-model="form.ratedVoltageValueText" required :rules="[{ required: true }]" type="number" label="额定一次电压(kV)" input-align="right" is-link placeholder="请选择" readonly @click="levelShow = true"/>
<van-field v-input.num v-model="form.absoleteElecNum" type="number" label="淘汰电机数量" placeholder="请输入" /> <van-field v-input.num v-model="form.absoleteElecNum" type="number" label="淘汰电机数量" placeholder="请输入" />
<van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰变压器数量" placeholder="请输入" /> <van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰变压器数量" placeholder="请输入" />
<van-field v-input.floatNo0 v-model="form.loadRate" required :rules="[{ required: true }]" type="number" label="负载率(%)" placeholder="请输入" @input="handelChangeNumber('loadRate','负载率')" /> <van-field v-input.floatNo0 v-model="form.loadRate" required :rules="[{ required: true }]" type="number" label="负载率(%)" placeholder="请输入" @input="handelChangeNumber('loadRate','负载率')" />
<van-field v-input.num v-model="form.userYear" required :rules="[{ required: true }]" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" /> <van-field v-input.num v-model="form.userYear" required :rules="[{ required: true }]" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" />
<van-cell title="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" type="number" placeholder="请选择设备生产日期" is-link readonly @click="datePicker = true" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
</van-cell-group> </van-cell-group>
</div> </div>
</div> </div>
@@ -42,13 +44,21 @@
</div> </div>
<div class="content-main"> <div class="content-main">
<van-cell v-for="item in levelList" :key="item.value" clickable style="font-weight: 400 !important; font-size: 15px !important"> <van-cell v-for="item in levelList" :key="item.value" clickable style="font-weight: 400 !important; font-size: 15px !important">
<van-checkbox :name="item" checked-color="#009999" v-model="item.checked" @click="clickCheckbox(item)"> <van-checkbox :name="item" checked-color="#009999" v-model="item.checked" @click="clickCheckbox(item)"
{{ item.value }}kV :disabled="parseFloat(inVoltage)<parseFloat(item.name)"
>
{{ item.name }}
</van-checkbox> </van-checkbox>
</van-cell> </van-cell>
</div> </div>
</div> </div>
</VanPickerNew> </VanPickerNew>
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</template> </template>
@@ -67,14 +77,49 @@ export default {
mixins: [mixin], mixins: [mixin],
data() { data() {
return { return {
inVoltage: '',
datePicker: false,
currentDate: new Date(),
maxDate: new Date(),
levelShow: false, levelShow: false,
levelList:[ levelList:[{
{value:'10', checked: false}, name:'10',
{value:'35', checked: false}, value:"01",
{value:'110', checked: false}, checked: false
{value:'220', checked: false}, },{
{value:'330', checked: false}, name:'35',
], value:"04",
checked: false
},{
name:'110',
value:"05",
checked: false
},{
name:'220',
value:"06",
checked: false
},{
name:'20',
value:"07",
checked: false
},{
name:'66',
value:"09",
checked: false
},{
name:'330',
value:"10",
checked: false
}],
// [
// {value:'10', checked: false},
// {value:'20', checked: false},
// {value:'35', checked: false},
// {value:'66', checked: false},
// {value:'110', checked: false},
// {value:'220', checked: false},
// {value:'330', checked: false},
// ],
//电压等级选中的数据 //电压等级选中的数据
resultCheckboxLevel: [], resultCheckboxLevel: [],
addeditId: '', // 新增修改提交id addeditId: '', // 新增修改提交id
@@ -90,11 +135,14 @@ export default {
absoleteNum: "", absoleteNum: "",
loadRate: '', loadRate: '',
userYear: '', userYear: '',
produceDate: ''
}, },
show: false show: false
}; };
}, },
activated() { activated() {
let inVoltage = sessionStorage.getItem('inVoltage')
this.inVoltage = this.getData(inVoltage)
this.id = '', this.id = '',
this.form = { this.form = {
systemModel: "", systemModel: "",
@@ -105,6 +153,7 @@ export default {
absoleteNum: "", absoleteNum: "",
loadRate: '', loadRate: '',
userYear: '', userYear: '',
produceDate: ''
}; };
let msg = JSON.parse(sessionStorage.getItem('tidCid')); let msg = JSON.parse(sessionStorage.getItem('tidCid'));
// let msg2 = localStorage.getItem('customerItem'); // let msg2 = localStorage.getItem('customerItem');
@@ -133,6 +182,10 @@ export default {
mounted() { mounted() {
}, },
methods: { methods: {
getData(value){
let res = this.levelList.filter(ele => {return ele.value == value})
return res&&res[0]&&res[0].name
},
/** /**
* 电压等级 * 电压等级
*/ */
@@ -150,6 +203,7 @@ export default {
const leName = this.levelList.filter((ele) => ele.checked) const leName = this.levelList.filter((ele) => ele.checked)
this.resultCheckboxLevel = leName this.resultCheckboxLevel = leName
this.form.ratedVoltageValue = leName.map((ele)=> ele.value).join(',') this.form.ratedVoltageValue = leName.map((ele)=> ele.value).join(',')
this.form.ratedVoltageValueText = leName.map((ele)=> ele.name).join(',')
this.levelShow = false this.levelShow = false
}, },
clickCheckbox(item){ clickCheckbox(item){
@@ -208,6 +262,8 @@ export default {
const res = await distributeGetInfo(this.id); const res = await distributeGetInfo(this.id);
if(res.code == 0) { if(res.code == 0) {
this.form = res.data this.form = res.data
let Efficiency = res.data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == res.data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
this.show = false this.show = false
if (this.form.ratedVoltageValue) { if (this.form.ratedVoltageValue) {
this.resultCheckboxLevel=[] this.resultCheckboxLevel=[]
@@ -220,11 +276,12 @@ export default {
}) })
this.form.ratedVoltageValue = this.resultCheckboxLevel.map((ele) => ele.value).join(',') this.form.ratedVoltageValue = this.resultCheckboxLevel.map((ele) => ele.value).join(',')
this.form.ratedVoltageValueText = this.resultCheckboxLevel.map((ele) => ele.name).join(',')
} }
}else { }else {
this.show = false this.show = false
} }
} },
}, },
}; };
</script> </script>
+4
View File
@@ -407,6 +407,10 @@ export default {
this.doDebounce() this.doDebounce()
}, },
save() { save() {
if(!(this.list&&this.list.length>0)){
this.$toast('请输入空压机系统信息')
return
}
if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) { if(this.showForm||(this.$store.getters.cityType&&(this.text1.length<1||this.text2.length<1||this.text3.length<1))) {
return return
} }
@@ -8,6 +8,8 @@
<van-cell-group> <van-cell-group>
<van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="空压机型号" placeholder="请输入空压机型号" maxlength="20" /> <van-field v-model="form.systemModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="空压机型号" placeholder="请输入空压机型号" maxlength="20" />
<van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="电机型号" placeholder="请输入电机型号" maxlength="20" /> <van-field v-model="form.motorModel" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" label="电机型号" placeholder="请输入电机型号" maxlength="20" />
<van-field label="设备类型" v-model="form.equipTypeName" required :rules="[{ required: true }]" placeholder="请选择设备类型" is-link readonly @click="handelClickOptionShow('equipType','01')" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" /> <van-field v-input.numNo0 v-model="form.systemNum" type="number" required :rules="[{ required: true }]" label="台数(台)" placeholder="请输入台数" />
<van-field v-input.floatNo0 v-model="form.ratedPowerValue" required :rules="[{ required: true }]" type="number" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange('ratedPowerValue',5,'单台额定功率')"/> <van-field v-input.floatNo0 v-model="form.ratedPowerValue" required :rules="[{ required: true }]" type="number" label="单台额定功率(kW)" placeholder="请输入" @blur="handelChange('ratedPowerValue',5,'单台额定功率')"/>
<van-field v-input.float v-model="form.frequencyPerValue" required :rules="[{ required: true }]" type="number" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" /> <van-field v-input.float v-model="form.frequencyPerValue" required :rules="[{ required: true }]" type="number" label="变频占比(%)" placeholder="请输入" @input="handelChangeNumber('frequencyPerValue','变频占比')" />
@@ -15,6 +17,8 @@
<van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰空压机数量" placeholder="请输入" /> <van-field v-input.num v-model="form.absoleteNum" type="number" label="淘汰空压机数量" placeholder="请输入" />
<van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="空压机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','空压机效率')" /> <van-field v-input.floatNo0 v-model="form.efficiency" type="number" label="空压机效率(%)" placeholder="请输入" @input="handelChangeNumber('efficiency','空压机效率')" />
<van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" /> <van-field v-input.num v-model="form.userYear" type="number" label="投入年份" placeholder="请选择投入年份" is-link readonly @click="handelClickYear('userYear', 'SET_CON_YEAR')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.runHours" type="number" label="累计运行小时数" required :rules="[{ required: true }]" placeholder="请输入" />
</van-cell-group> </van-cell-group>
</div> </div>
</div> </div>
@@ -33,10 +37,16 @@
</div> </div>
</van-overlay> </van-overlay>
<Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" /> <Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" />
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</template> </template>
<script> <script>
import VanPickerNew from '@/components/vanPickerNew'
import { airAdd, airGetInfo, airEdit } from "@/api/universalEnergy.js" import { airAdd, airGetInfo, airEdit } from "@/api/universalEnergy.js"
import { Notify } from "vant"; import { Notify } from "vant";
import mixin from '@/mixins/mixin' import mixin from '@/mixins/mixin'
@@ -46,6 +56,7 @@ import {debounce} from '@/utils/common.js'
export default { export default {
components: { components: {
// Header, // Header,
VanPickerNew,
Year Year
}, },
mixins: [mixin], mixins: [mixin],
@@ -64,6 +75,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}, },
show: false, show: false,
doDebounce: null, doDebounce: null,
@@ -81,6 +96,10 @@ export default {
absoleteNum: '', absoleteNum: '',
efficiency: '', efficiency: '',
userYear: '', userYear: '',
produceDate: '',
equipType: '',
equipEfficiency: '',
runHours: '',
}; };
let msg = JSON.parse(sessionStorage.getItem('tidCid')); let msg = JSON.parse(sessionStorage.getItem('tidCid'));
// let msg2 = localStorage.getItem('customerItem'); // let msg2 = localStorage.getItem('customerItem');
@@ -163,6 +182,10 @@ export default {
const res = await airGetInfo(this.id); const res = await airGetInfo(this.id);
if(res.code == 0) { if(res.code == 0) {
this.form = res.data this.form = res.data
let Efficiency = res.data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == res.data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
let equipType = res.data.equipType&&this.equipTypeOption['01'].find(item => item.value == res.data.equipType)
this.form.equipTypeName = equipType&&equipType.text
this.show = false this.show = false
}else { }else {
this.show = false this.show = false
-237
View File
@@ -1,237 +0,0 @@
<template>
<div class="list">
<!-- 搜索框 -->
<!-- <div class="search">
<img src="@/assets/search.png" alt="" />
<input
type="text"
placeholder="请输入搜索文字"
@keydown.enter="searchEveryItem"
v-model="searchValue"
/>
</div> -->
<div class="container">
<van-radio-group v-model="radio">
<van-cell
v-for="(item, index) in client"
:title="item.consName +' '+ item.consNo"
:key="index"
clickable
@click="clickRadio(item, index)"
:style="item.checked ? 'background: #e5f6f3; ' : ''"
>
<!-- <van-radio :name="index" /> -->
</van-cell>
</van-radio-group>
</div>
<div class="btn">
<van-button size="large" class="faqi" @click="sureEle">
确认
</van-button>
</div>
</div>
</template>
<script>
// import Header from "@/components/headerNew";
import { getUseele } from '@/api/customer'
import { Notify } from 'vant'
export default {
name: '',
components: {
// Header,
},
beforeRouteEnter(to, from, next) {
next(vm => {
vm.title = to.meta.title
})
},
data() {
return {
// 标题
title: '客户选择',
// 单选框
radio: '',
searchValue:'',
client: [],
loading: false, //加载
finished: false, //完成
pageNum: 1, //当前页数
pageSize: 10, //每页多少条
allPage: 0, //总共多少条
numArr: [],
currentItem: {}
}
},
mounted() {
// this.getData();
},
created() {
// this.getUseele()
this.getUseele()
},
methods: {
//反显数据
editData(data) {
const arr = sessionStorage.getItem('customer')
if(arr) {
this.numArr = JSON.parse(arr).list
data.forEach((ele)=> {
this.numArr.forEach((v)=>{
if(ele.consId == v.consId) {
ele.checked = true
}
})
})
}
},
//获取列表数据
async getUseele() {
const customer = sessionStorage.getItem('customer')
const data = {
pageNum: this.pageNum,
pagesize: this.pageSize,
}
if(customer) {
data.consName = JSON.parse(customer).name
} else {
data.consName = ''
}
const res = await getUseele(data)
if(res.code == 0) {
res.data.records.forEach((v) => {
v.checked = false
})
this.client = res.data.records
this.editData(res.data.records)
} else {
Notify({ type: 'danger', message: res.msg })
}
},
// 滑动加载
// onLoad() {
// // 异步更新数据
// setTimeout(async () => {
// this.pageNum++
// const data = {
// pageNum: this.pageNum,
// pagesize: this.pageSize,
// }
// // 加载状态结束
// this.loading = false
// const res = await getUseele(data)
// if(res.code == 0) {
// res.data.records.forEach((v) => {
// v.checked = false
// })
// // this.client = res.data.records
// this.client.push(...res.data.records)
// this.editData(res.data.records)
// // 数据全部加载完成
// if (this.client.length == res.data.total) {
// this.finished = true
// return
// }
// } else {
// this.finished = true
// }
// }, 1000)
// },
// 选择客户数据处理
clickRadio(item, index) {
item.checked = !item.checked
if(item.checked == true) {
this.numArr.push(item)
} else {
this.numArr.splice(index, 1)
}
console.log(this.numArr);
},
// 点击确认
sureEle() {
if (this.numArr.length == 0 ) {
Notify({ type: 'danger', message: '请至少选择一条' })
return
}
sessionStorage.setItem('numArr', JSON.stringify(this.numArr))
this.$router.go(-1)
}
},
}
</script>
<style lang="less" scoped>
.list {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
}
.container {
height: calc(100vh - 60px);
overflow-y: auto;
.van-cell {
padding: 20px;
font-size: 17px;
opacity: 0.9;
}
.item {
background: #fff;
padding: 30px;
box-sizing: border-box;
font-size: 18px;
color: #797b7b;
border-bottom: 1px solid #e9e9e9;
}
}
::v-deep .van-radio__icon {
-webkit-box-flex: 0;
-webkit-flex: none;
flex: none;
height: 1em;
font-size: 0.533333rem;
line-height: 1em;
cursor: pointer;
position: absolute;
right: 0;
top: 0px;
}
.btn {
padding: 0 20px;
}
.faqi {
background-color: #63cbb6;
color: #fff;
border-radius: 8px;
margin-top: -20px;
}
/deep/ .van-radio-group{
height: 100%;
background: #fff;
}
.search {
width: 100%;
height: 60px;
display: flex;
// border: 1px solid #f2f2f2;
// opacity: 0.5;
border-radius: 6px;
padding: 5px 10px;
box-sizing: border-box;
align-items: center;
background: #fff;
margin-bottom: 10px;
img {
width: 15px;
height: 15px;
margin-right: 10px;
}
}
</style>
+14 -11
View File
@@ -106,7 +106,7 @@
/> />
<van-field <van-field
v-input.reset v-input.reset
v-input.floatNo0 v-input.float
:disabled="showForm" :disabled="showForm"
type="number" type="number"
@blur="checkData" @blur="checkData"
@@ -518,13 +518,13 @@ export default {
readOnly(){ readOnly(){
return this.yearForm.energyUnutilizedVO&&this.yearForm.energyUnutilizedVO.notUsedResidueEnergyType!='01' return this.yearForm.energyUnutilizedVO&&this.yearForm.energyUnutilizedVO.notUsedResidueEnergyType!='01'
}, },
tips2(){ // tips2(){
let rate = Number(this.yearForm.actualPowerValue)/Number(this.yearForm.installedCapacityValue) // let rate = Number(this.yearForm.actualPowerValue)/Number(this.yearForm.installedCapacityValue)
if(0 < rate && 2000 > rate){ // if(0 < rate && 2000 > rate){
return false // return false
} // }
return true // return true
} // }
}, },
mounted() { mounted() {
this.doDebounce=debounce(async function () { this.doDebounce=debounce(async function () {
@@ -756,6 +756,9 @@ export default {
Notify({ type: 'danger', duration: 500, message: '请选择年份' }) Notify({ type: 'danger', duration: 500, message: '请选择年份' })
return return
} }
if(this.tabName == 'a'){
this.checkData()
}
if(this.tabName == 'b') { if(this.tabName == 'b') {
if(this.heatDemandOtherName) { if(this.heatDemandOtherName) {
this.yearForm.energyUnutilizedVO.heatDemandOther = this.heatDemandOtherName this.yearForm.energyUnutilizedVO.heatDemandOther = this.heatDemandOtherName
@@ -771,9 +774,9 @@ export default {
if(this.tabName == 'c'&&this.tips0){ if(this.tabName == 'c'&&this.tips0){
return return
} }
if(this.yearForm.isPvInstallCondition == '1'&&this.tips2){ // if(this.yearForm.isPvInstallCondition == '1'&&this.tips2){
return // return
} // }
let params = Object.assign(this.customerInfo, this.yearForm) let params = Object.assign(this.customerInfo, this.yearForm)
params.taskId = this.tidCid.taskId params.taskId = this.tidCid.taskId
if(this.$route.query.id) { if(this.$route.query.id) {
@@ -1,9 +1,9 @@
<template> <template>
<div class="list"> <div class="list">
<van-form ref="detailForm" @submit="handelClickSave"> <van-form ref="detailForm" @submit="handelClickSave">
<div class="list-upload" v-if="(type == 1||type == 2) && $store.getters.imageRecognition"> <!-- <div class="list-upload" v-if="(type == 1||type == 2) && $store.getters.imageRecognition">
<btn-uploader type="filePic" :value="filePic" @afterRead="afterRead" @delImg="delImg" @onUpload="onUpload" /> <btn-uploader type="filePic" :value="filePic" @afterRead="afterRead" @delImg="delImg" @onUpload="onUpload" />
</div> </div> -->
<div class="container" v-if="type == 1"> <div class="container" v-if="type == 1">
<div class="inputStyle"> <div class="inputStyle">
<van-cell-group> <van-cell-group>
@@ -12,6 +12,7 @@
<van-field v-model="refrigeNum" v-input.numNo0 label="数量(台)" readonly type="number" required :rules="[{ required: true }]" input-align="right" placeholder="自动计算" /> <van-field v-model="refrigeNum" v-input.numNo0 label="数量(台)" readonly type="number" required :rules="[{ required: true }]" input-align="right" placeholder="自动计算" />
<div class="tips" v-if="refrigeNum+''=='0'">数量>0</div> <div class="tips" v-if="refrigeNum+''=='0'">数量>0</div>
<van-field v-model="edgl" v-input.floatNo0 label="额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="edgl" v-input.floatNo0 label="额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<div class="tips" v-if="ratio1">0<额定功率<1000</div>
<div class="tips" v-if="ratio">{{ refrigeTypeData[form.refrigeType][0]}} ≤额定制冷量/额定功率≤ {{refrigeTypeData[form.refrigeType][1]}}</div> <div class="tips" v-if="ratio">{{ refrigeTypeData[form.refrigeType][0]}} ≤额定制冷量/额定功率≤ {{refrigeTypeData[form.refrigeType][1]}}</div>
<van-field v-model="hyl" v-input.float label="耗用量(t或m3)" type="number" label-width="100" input-align="right" placeholder="请输入" /> <van-field v-model="hyl" v-input.float label="耗用量(t或m3)" type="number" label-width="100" input-align="right" placeholder="请输入" />
<van-field v-model="form.coolCapacity" v-input.floatNo0 label="额定制冷量(kW)" required :rules="[{ required: true }]" type="number" input-align="right" placeholder="请输入" /> <van-field v-model="form.coolCapacity" v-input.floatNo0 label="额定制冷量(kW)" required :rules="[{ required: true }]" type="number" input-align="right" placeholder="请输入" />
@@ -23,6 +24,10 @@
<van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" input-align="right" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" input-align="right" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.cumulativeRunHours" required :rules="[{ required: true }]" type="number" label="累计运行小时数" placeholder="请输入" label-width="200" input-align="right"/>
<van-field v-input.num v-model="form.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/>
</van-cell-group> </van-cell-group>
<van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/> <van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/>
<Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" /> <Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" />
@@ -46,12 +51,13 @@
<!-- 设备类型选择 --> <!-- 设备类型选择 -->
<div class="inputStyle"> <div class="inputStyle">
<van-cell-group> <van-cell-group>
<van-field v-model="formColumns.refrigeTypeName" label="设备类型" required :rules="[{ required: true }]" input-align="right" is-link placeholder="请选择" @click="handelClickHeatingShow('jzlx', 80000001016,'refrigeTypeName','refrigeType','lqt' )" readonly /> <van-field v-model="formColumns.refrigeTypeName" label="设备类型1" required :rules="[{ required: true }]" input-align="right" is-link placeholder="请选择" @click="handelClickHeatingShow('jzlx', 80000001016,'refrigeTypeName','refrigeType','lqt' )" readonly />
<!-- <van-cell title="设备类型" is-link :value="form.refrigeTypeName" @click="showPicker = true" readonly /> --> <!-- <van-cell title="设备类型" is-link :value="form.refrigeTypeName" @click="showPicker = true" readonly /> -->
<van-field v-model="form.model" label="设备型号" required :rules="[{ required: true },{pattern:/^.{2,30}$/, message:'2≤型号长度≤30'}]" input-align="right" maxlength="30" placeholder="请输入设备型号"/> <van-field v-model="form.model" label="设备型号" required :rules="[{ required: true },{pattern:/^.{2,30}$/, message:'2≤型号长度≤30'}]" input-align="right" maxlength="30" placeholder="请输入设备型号"/>
<van-field v-model="refrigeNum" v-input.numNo0 label="数量(台)" readonly type="number" required :rules="[{ required: true }]" input-align="right" placeholder="自动计算" /> <van-field v-model="refrigeNum" v-input.numNo0 label="数量(台)" readonly type="number" required :rules="[{ required: true }]" input-align="right" placeholder="自动计算" />
<div class="tips" v-if="refrigeNum+''=='0'">数量>0</div> <div class="tips" v-if="refrigeNum+''=='0'">数量>0</div>
<van-field v-model="form.ratedPower" v-input.floatNo0 label="额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="form.ratedPower" v-input.floatNo0 label="额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<div class="tips" v-if="ratio2">0<额定功率<500</div>
<van-field v-model="form.useExpl" v-input.num label="在用台数(台)" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="form.useExpl" v-input.num label="在用台数(台)" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<van-field v-model="form.backupExpl" v-input.num label="备用台数(台)" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="form.backupExpl" v-input.num label="备用台数(台)" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<van-field v-model="form.useYear" label="设备投用年份" label-width="140" required :rules="[{ required: true }]" input-align="right" is-link placeholder="请选择" readonly @click="handelClickYear('useYear')" /> <van-field v-model="form.useYear" label="设备投用年份" label-width="140" required :rules="[{ required: true }]" input-align="right" is-link placeholder="请选择" readonly @click="handelClickYear('useYear')" />
@@ -59,6 +65,10 @@
<van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" input-align="right" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" input-align="right" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.cumulativeRunHours" required :rules="[{ required: true }]" type="number" label="累计运行小时数" placeholder="请输入" label-width="200" input-align="right"/>
<van-field v-input.num v-model="form.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/>
</van-cell-group> </van-cell-group>
<van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/> <van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/>
<Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" /> <Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" />
@@ -90,6 +100,10 @@
<van-field v-model="form1.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form1.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form1.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form1.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form1.heatPerArea" v-input.float label="单位面积热量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form1.heatPerArea" v-input.float label="单位面积热量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field label="设备能效等级" v-model="form1.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" input-align="right" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field label="设备生产日期" v-model="form1.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" input-align="right" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form1.cumulativeRunHours" required :rules="[{ required: true }]" type="number" label="累计运行小时数" placeholder="请输入" label-width="200" input-align="right"/>
<van-field v-input.num v-model="form1.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/>
</van-cell-group> </van-cell-group>
<van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/> <van-cell class="img-box box1" title="设备外观" :required="$store.getters.cityType"/>
<Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" /> <Uploader type="exteriorImage1" :value="exteriorImage1" @afterRead="afterRead1" @delImg="delImg1" @onUpload="onUpload1" />
@@ -112,6 +126,12 @@
</van-form> </van-form>
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</template> </template>
@@ -160,6 +180,12 @@ export default {
return !data return !data
} }
}, },
ratio1(){
return this.edgl==0 || this.edgl>1000
},
ratio2(){
return this.form.ratedPower==0 || this.form.ratedPower>500
},
heatNum: { heatNum: {
get(){ get(){
if( this.form1.useExpl && this.form1.backupExpl ){ if( this.form1.useExpl && this.form1.backupExpl ){
@@ -210,7 +236,11 @@ export default {
loadFactor: '', loadFactor: '',
runHours:'', runHours:'',
runDays: '', runDays: '',
coldPerArea: '' coldPerArea: '',
equipEfficiency: '',
produceDate:'',
cumulativeRunHours: '',
dieoutNum: ''
}, },
form1: { form1: {
equipId:'', equipId:'',
@@ -230,7 +260,11 @@ export default {
loadFactor: '', loadFactor: '',
runHours:'', runHours:'',
runDays: '', runDays: '',
heatPerArea: '' heatPerArea: '',
equipEfficiency: '',
produceDate:'',
cumulativeRunHours: '',
dieoutNum: ''
}, },
formColumns: { formColumns: {
refrigeType: "", refrigeType: "",
@@ -429,6 +463,9 @@ export default {
for (const key in this.form) { for (const key in this.form) {
this.form[key] = data[key] this.form[key] = data[key]
} }
let Efficiency = data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
if(data.refrigeTypeName) { if(data.refrigeTypeName) {
this.formColumns.refrigeTypeName = data.refrigeTypeName this.formColumns.refrigeTypeName = data.refrigeTypeName
} }
@@ -483,6 +520,9 @@ export default {
for (const key in this.form) { for (const key in this.form) {
this.form[key] = data[key] this.form[key] = data[key]
} }
let Efficiency = data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == data.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
if(data.refrigeTypeName) { if(data.refrigeTypeName) {
this.formColumns.refrigeTypeName = data.refrigeTypeName this.formColumns.refrigeTypeName = data.refrigeTypeName
} }
@@ -547,6 +587,9 @@ export default {
for (const key in this.form1) { for (const key in this.form1) {
this.form1[key] = data[key] this.form1[key] = data[key]
} }
let Efficiency = data.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == data.equipEfficiency)
this.form1.equipEfficiencyName = Efficiency&&Efficiency.text
if(heatCnLx && data) { if(heatCnLx && data) {
heatCnLx.forEach((v)=> { heatCnLx.forEach((v)=> {
if (data.unitType == v.code) { if (data.unitType == v.code) {
@@ -654,7 +697,7 @@ export default {
const item = this.$route.params.item const item = this.$route.params.item
console.log(this.type, this.exteriorImage1.length); console.log(this.type, this.exteriorImage1.length);
if (this.type == 1) { if (this.type == 1) {
if(this.form.refrigeNum<1 || this.ratio){ if(this.form.refrigeNum<1 || this.ratio||this.ratio1){
return return
} }
if(this.$store.getters.cityType&&(this.form.exteriorImage.length<1||this.form.tagImage.length<1||this.form.markImage.length<1)){ if(this.$store.getters.cityType&&(this.form.exteriorImage.length<1||this.form.tagImage.length<1||this.form.markImage.length<1)){
@@ -694,6 +737,9 @@ export default {
}) })
} }
} else if (this.type == 2) { } else if (this.type == 2) {
if(this.ratio2){
return
}
if(this.$store.getters.cityType&&(this.form.exteriorImage.length<1||this.form.tagImage.length<1||this.form.markImage.length<1)){ if(this.$store.getters.cityType&&(this.form.exteriorImage.length<1||this.form.tagImage.length<1||this.form.markImage.length<1)){
return return
} }
@@ -742,6 +788,7 @@ export default {
ele.ratedPower = this.edgl + "," + this.hyl ele.ratedPower = this.edgl + "," + this.hyl
// ele.unitType = this.form.refrigeType // ele.unitType = this.form.refrigeType
ele.unitType = this.form1.unitType ele.unitType = this.form1.unitType
ele.dieoutNum = this.form1.dieoutNum
ele.unitTypeName = this.formColumns.refrigeTypeName ele.unitTypeName = this.formColumns.refrigeTypeName
return ele return ele
} }
@@ -761,7 +808,6 @@ export default {
this.form1.unitType = this.formColumns.refrigeType this.form1.unitType = this.formColumns.refrigeType
this.form1.unitTypeName = this.formColumns.refrigeTypeName this.form1.unitTypeName = this.formColumns.refrigeTypeName
this.heatPicArrtoStr() this.heatPicArrtoStr()
console.log(this.form1.unitType, 'this.form1.unitType');
this.$store.getters.heatingUnitList.push(this.form1) this.$store.getters.heatingUnitList.push(this.form1)
this.clearPage() this.clearPage()
this.$router.push({ this.$router.push({
@@ -8,13 +8,20 @@
<van-field v-model="trName" label="变压器类型" name="trName" required :rules="[{ required: true, message:'请至少选择一个变压器类型' }]" is-link input-align="right" placeholder="请选择" readonly @click="handelClcikTrShow = !showForm" /> <van-field v-model="trName" label="变压器类型" name="trName" required :rules="[{ required: true, message:'请至少选择一个变压器类型' }]" is-link input-align="right" placeholder="请选择" readonly @click="handelClcikTrShow = !showForm" />
<van-field v-input.numNo0 v-show="s15show" v-model="form.s15AboveNum" label="变压器S15及以上台数" type="number" required :rules="[{ required: s15show, message:'请输入变压器S15及以上台数' }]" label-width="180" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s14show" v-model="form.s14Num" label="变压器S14台数" type="number" required :rules="[{ required: s14show, message:'请输入变压器S14台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s13show" v-model="form.s13Num" label="变压器S13台数" type="number" required :rules="[{ required: s13show, message:'请输入变压器S13台数' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s13show" v-model="form.s13Num" label="变压器S13台数" type="number" required :rules="[{ required: s13show, message:'请输入变压器S13台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s12show" v-model="form.s12Num" label="变压器S12台数" type="number" required :rules="[{ required: s12show, message:'请输入变压器S12台数' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s12show" v-model="form.s12Num" label="变压器S12台数" type="number" required :rules="[{ required: s12show, message:'请输入变压器S12台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s11show" v-model="form.s11Num" label="变压器S11台数" type="number" required :rules="[{ required: s11show, message:'请输入变压器S11台数' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s11show" v-model="form.s11Num" label="变压器S11台数" type="number" required :rules="[{ required: s11show, message:'请输入变压器S11台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s10show" v-model="form.s10Num" label="变压器S10台数量" type="number" required :rules="[{ required: s10show, message:'请输入变压器S10台数量' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s10show" v-model="form.s10Num" label="变压器S10台数量" type="number" required :rules="[{ required: s10show, message:'请输入变压器S10台数量' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s9show" v-model="form.s9Num" label="变压器S9台数" type="number" required :rules="[{ required: s9show, message:'请输入变压器S9台数' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s9show" v-model="form.s9Num" label="变压器S9台数" type="number" required :rules="[{ required: s9show, message:'请输入变压器S9台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="otherShow" v-model="form.otherNum" label="其他变压器数量" type="number" required :rules="[{ required: otherShow, message:'请输入其他变压器数量' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-show="s8show" v-model="form.s8Num" label="变压器S8台数" type="number" required :rules="[{ required: s8show, message:'请输入变压器S8台数' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="s7show" v-model="form.s7BelowNum" label="变压器S7及以下台数" type="number" required :rules="[{ required: s7show, message:'请输入变压器S7及以下台数' }]" label-width="180" input-align="right" placeholder="请输入" />
<van-field v-input.numNo0 v-show="othershow" v-model="form.otherNum" label="其他变压器数量" type="number" required :rules="[{ required: othershow, message:'请输入其他变压器数量' }]" label-width="140" input-align="right" placeholder="请输入" />
<van-field v-model="form.useYear" required :rules="[{ required: true, message:'请选择变压器最早投运年限' }]" label="变压器最早投运年限(年)" label-width="140" input-align="right" placeholder="请输入" is-link readonly @click="handelClickYear('useYear')" /> <van-field v-model="form.useYear" required :rules="[{ required: true, message:'请选择变压器最早投运年限' }]" label="变压器最早投运年限(年)" label-width="140" input-align="right" placeholder="请输入" is-link readonly @click="handelClickYear('useYear')" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" input-align="right" label-width="140" placeholder="请选择设备能效等级" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field label="变压器生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择变压器生产日期" label-width="140" input-align="right" is-link readonly @click="datePicker = true" />
<van-field v-input.num v-model="form.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/>
<van-field v-input.numNo0 v-model="form.distributeCapacity" label="总额定容量(kVA)" type="number" name="distributeCapacity" required :rules="[{ required: true, message:'请填写总额定容量' }]" label-width="100" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-model="form.distributeCapacity" label="总额定容量(kVA)" type="number" name="distributeCapacity" required :rules="[{ required: true, message:'请填写总额定容量' }]" label-width="100" input-align="right" placeholder="请输入" />
@@ -175,6 +182,11 @@
</VanPickerNew> </VanPickerNew>
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</div> </div>
</van-form> </van-form>
@@ -231,15 +243,22 @@ export default {
distributeModiy: '', //是否进行过设备改造 distributeModiy: '', //是否进行过设备改造
modifyMode: '', //改造方式 modifyMode: '', //改造方式
modifyYear: '', //台区新增扩容改造年份 modifyYear: '', //台区新增扩容改造年份
s15AboveNum: '',
s14Num: '',
s13Num: '', s13Num: '',
s12Num: '', s12Num: '',
s11Num: '', s11Num: '',
s10Num: '', s10Num: '',
s9Num: '', s9Num: '',
s8Num: '',
s7BelowNum: '',
otherNum: '', otherNum: '',
useYear:'', useYear:'',
makeModifyYear:'', makeModifyYear:'',
addModifyYear:'', addModifyYear:'',
produceDate:'',
equipEfficiency: '',
dieoutNum: '',
}, },
//页面展示的中文名称 //页面展示的中文名称
formColumns: { formColumns: {
@@ -257,15 +276,31 @@ export default {
*/ */
handelClcikTrShow: false, handelClcikTrShow: false,
trName: '', trName: '',
s15show: false,
s14show: false,
s13show: false, s13show: false,
s12show: false, s12show: false,
s11show: false, s11show: false,
s10show: false, s10show: false,
s9show: false, s9show: false,
otherShow: false, s8show: false,
s7show: false,
othershow: false,
//变压器类型数组 //变压器类型数组
trTypeList: [{ // trTypeList: [],
trTypeList: [
{
text: 's15',
title:'s15AboveNum',
value: '9',
checked: false,
},{
text: 's14',
title:'s14Num',
value: '10',
checked: false,
},{
text: 's13', text: 's13',
title:'s13Num', title:'s13Num',
value: '1', value: '1',
@@ -295,6 +330,18 @@ export default {
value: '5', value: '5',
checked: false, checked: false,
}, },
{
text: 's8',
title:'s8Num',
value: '8',
checked: false,
},
{
text: 's7',
title:'s7BelowNum',
value: '7',
checked: false,
},
{ {
text: '其他', text: '其他',
title:'otherNum', title:'otherNum',
@@ -360,7 +407,40 @@ export default {
//定时器 //定时器
edSet: null, edSet: null,
modifyTimer:null, modifyTimer:null,
required: false required: false,
voltageLevelData:[
{
text:'10kV',name:'10kV',
value:'01',code:'01',
},{
text:'380V',name:'380V',
value:'02',code:'02',
},{
text:'6kV',name:'6kV',
value:'03',code:'03',
},{
text:'35kV',name:'35kV',
value:'04',code:'04',
},{
text:'110kV',name:'110kV',
value:'05',code:'05',
},{
text:'220kV',name:'220kV',
value:'06',code:'06',
},{
text:'20kV',name:'20kV',
value:'07',code:'07',
},{
text:'200V',name:'200V',
value:'08',code:'08',
},{
text:'66kV',name:'66kV',
value:'09',code:'09',
},{
text:'330kV',name:'330kV',
value:'10',code:'10',
},
],
// notData: { // notData: {
// charging: { // charging: {
// formColumnsField: ['deviceTypeName', 'computeName'], // formColumnsField: ['deviceTypeName', 'computeName'],
@@ -462,11 +542,12 @@ export default {
//获取系统码表返回值数据 //获取系统码表返回值数据
//电压等级 //电压等级
async getList() { async getList() {
const dydj = { // const dydj = {
id: 80000001022, // id: 80000001022,
type: 'dydj', // type: 'dydj',
} // }
const level = await getCodeCommon(dydj) // const level = await getCodeCommon(dydj)
const level = this.voltageLevelData
console.log(level,335); console.log(level,335);
level.forEach((v) => { level.forEach((v) => {
v.checked = false v.checked = false
@@ -525,12 +606,16 @@ export default {
this.handelClcikTrShow = false this.handelClcikTrShow = false
this.deviceTypeShow = false this.deviceTypeShow = false
this.trName = '' this.trName = ''
this.s15show = false
this.s14show = false
this.s13show = false this.s13show = false
this.s12show = false this.s12show = false
this.s11show = false this.s11show = false
this.s10show = false this.s10show = false
this.s9show = false this.s9show = false
this.otherShow = false this.s8show = false
this.s7show = false
this.othershow = false
this.v2Show = false this.v2Show = false
this.resultTrList = [] this.resultTrList = []
this.resultTrSpliceList = [] this.resultTrSpliceList = []
@@ -612,6 +697,8 @@ export default {
//问询 //问询
this.editDataSearch(data) this.editDataSearch(data)
let Efficiency = this.form.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == this.form.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
// this.getList2() // this.getList2()
} else { } else {
for (const key in this.form) { for (const key in this.form) {
@@ -634,125 +721,24 @@ export default {
* editData变压器 * editData变压器
*/ */
editDataTrName() { editDataTrName() {
if (this.form.s13Num) { this.trTypeList.map(item => {
this.s13show = true console.log(item, 'item');
this.resultTrList.push({ let key = item.value=='6'?'other':item.text
text: 's13', console.log(key, this.form[key]);
title:'s13Num', if(this.form[item.title]){
value: '1', this[key+'show'] = true
this.resultTrList.push({...item,
checked: true, checked: true,
}) })
} }else {
this[key+'show'] = false
if (this.form.s12Num) { this.resultTrSpliceList.push({...item,
this.s12show = true
this.resultTrList.push({
text: 's12',
title:'s12Num',
value: '2',
checked: true,
})
}
if (this.form.s11Num) {
this.s11show = true
this.resultTrList.push({
text: 's11',
title:'s11Num',
value: '3',
checked: true,
})
}
if (this.form.s10Num) {
this.s10show = true
this.resultTrList.push({
text: 's10',
title:'s10Num',
value: '4',
checked: true,
})
}
if (this.form.s9Num) {
this.s9show = true
this.resultTrList.push({
text: 's9',
title:'s9Num',
value: '5',
checked: true,
})
}
if (this.form.otherNum) {
this.otherShow = true
this.resultTrList.push({
text: '其他',
title:'otherNum',
value: '6',
checked: true,
})
}
if (!this.form.s13Num) {
this.s13show = false
this.resultTrSpliceList.push({
text: 's13',
title:'s13Num',
value: '1',
checked: false, checked: false,
}) })
}
if (!this.form.s12Num) {
this.s12show = false
this.resultTrSpliceList.push({
text: 's12',
title:'s12Num',
value: '2',
checked: false,
})
} }
if (!this.form.s11Num) {
this.s11show = false
this.resultTrSpliceList.push({
text: 's11',
title:'s11Num',
value: '3',
checked: false,
}) })
} console.log(this.resultTrSpliceList, this.resultTrList, 'pppppppppppp');
if (!this.form.s10Num) {
this.s10show = false
this.resultTrSpliceList.push({
text: 's10',
title:'s10Num',
value: '4',
checked: false,
})
}
if (!this.form.s9Num) {
this.s9show = false
this.resultTrSpliceList.push({
text: 's9',
title:'s9Num',
value: '5',
checked: false,
})
}
if (!this.form.otherNum) {
this.otherShow = false
this.resultTrSpliceList.push({
text: '其他',
title:'otherNum',
value: '6',
checked: false,
})
}
this.trName = this.resultTrList.map((ele) => ele.text).join(',') this.trName = this.resultTrList.map((ele) => ele.text).join(',')
this.form.transformerType = this.resultTrList.map((ele) => ele.value).join(',') this.form.transformerType = this.resultTrList.map((ele) => ele.value).join(',')
@@ -970,52 +956,25 @@ export default {
this.trName = trName.map((ele)=> ele.text).join(',') this.trName = trName.map((ele)=> ele.text).join(',')
this.form.transformerType = trName.map((ele)=> ele.value).join(',') this.form.transformerType = trName.map((ele)=> ele.value).join(',')
this.resultTrList.forEach((v) => { this.resultTrList.forEach((v) => {
if (v.text == 's13' && v.checked) { this.trTypeList.map(ele => {
this.s13show = true let key = ele.value=='6'?'other':ele.text
} if(v.text == ele.text&&v.checked){
if (v.text == 's12' && v.checked) { this[key+'show']=true
this.s12show = true
}
if (v.text == 's11' && v.checked) {
this.s11show = true
}
if (v.text == 's10' && v.checked) {
this.s10show = true
}
if (v.text == 's9' && v.checked) {
this.s9show = true
}
if (v.text == '其他' && v.checked) {
this.otherShow = true
} }
}) })
})
this.resultTrSpliceList.forEach((v) => { this.resultTrSpliceList.forEach((v) => {
if (v.text == 's13' && !v.checked) {
this.s13show = false this.trTypeList.map(ele => {
this.form.s13Num = '' let key = ele.value=='6'?'other':ele.text
} if(v.text == ele.text&&!v.checked){
if (v.text == 's12' && !v.checked) { this[key+'show']=false
this.s12show = false this.form[ele.title]=''
this.form.s12Num = ''
}
if (v.text == 's11' && !v.checked) {
this.s11show = false
this.form.s11Num = ''
}
if (v.text == 's10' && !v.checked) {
this.s10show = false
this.form.s10Num = ''
}
if (v.text == 's9' && !v.checked) {
this.s9show = false
this.form.s9Num = ''
}
if (v.text == '其他' && !v.checked) {
this.otherShow = false
this.form.otherNum = ''
} }
}) })
})
this.handelClcikTrShow = false this.handelClcikTrShow = false
}, },
clickCheckbox(item){ clickCheckbox(item){
@@ -1222,4 +1181,8 @@ export default {
color: #ee0a24; color: #ee0a24;
font-size: 12px; font-size: 12px;
} }
.content-main{
height: calc(100% - 40px);
overflow: auto;
}
</style> </style>
@@ -3,10 +3,12 @@
<div class="fissionItem"> <div class="fissionItem">
<van-cell-group> <van-cell-group>
<van-field v-model="form.refrigeNum" v-input.numNo0 label="空调数量" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="form.refrigeNum" v-input.numNo0 label="空调数量" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<van-field v-model="form.dieoutNum" v-input.num label="淘汰设备数量" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<van-field v-model="form.loadFactor" v-input.float label="负载系数" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="form.loadFactor" v-input.float label="负载系数" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<!-- <van-field v-input.num v-model="form.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/> -->
</van-cell-group> </van-cell-group>
</div> </div>
<!-- <div class="bottom"><van-button type="primary" block>保存</van-button></div> --> <!-- <div class="bottom"><van-button type="primary" block>保存</van-button></div> -->
@@ -26,7 +28,8 @@ export default {
loadFactor: '', loadFactor: '',
runHours:'', runHours:'',
runDays: '', runDays: '',
coldPerArea: '' coldPerArea: '',
dieoutNum: ''
}, },
eqid: '', eqid: '',
@@ -18,6 +18,7 @@
validator:validateisData}]" label="输送泵组总功率(kW)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelInput('pumpTotalPower', form.pumpTotalPower)" /> validator:validateisData}]" label="输送泵组总功率(kW)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelInput('pumpTotalPower', form.pumpTotalPower)" />
<van-field v-model="form.pumpYear" :required="form.heatMode!='1'" :rules="[{ required: form.heatMode!='1'}]" label="输送泵组设备年份" label-width="140" input-align="right" placeholder="请选择" is-link readonly @click="handelClickYear('pumpYear', 'SET_HEAT_YEAR')" /> <van-field v-model="form.pumpYear" :required="form.heatMode!='1'" :rules="[{ required: form.heatMode!='1'}]" label="输送泵组设备年份" label-width="140" input-align="right" placeholder="请选择" is-link readonly @click="handelClickYear('pumpYear', 'SET_HEAT_YEAR')" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" input-align="right" is-link readonly @click="datePicker = true" />
<!-- 是否进行过设备改造 --> <!-- 是否进行过设备改造 -->
@@ -152,6 +153,10 @@
</VanPickerNew> </VanPickerNew>
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
</div> </div>
</van-form> </van-form>
</template> </template>
@@ -222,6 +227,8 @@ export default {
modifyMode: '', //改造方式 modifyMode: '', //改造方式
heatIntellectModifyYear: '', //增加主机智能化集中控制系统年份 heatIntellectModifyYear: '', //增加主机智能化集中控制系统年份
heatModifyYear: '', //更换高能效设备年份 heatModifyYear: '', //更换高能效设备年份
produceDate: '',
}, },
//展示名称 //展示名称
formColumns: { formColumns: {
@@ -10,6 +10,7 @@
<div class="tips" v-if="tips0 == true">35℃ ≤设定水温≤100℃</div> <div class="tips" v-if="tips0 == true">35℃ ≤设定水温≤100℃</div>
<!-- <van-field v-model="form.useYear" label="变压器投运年限(年)" label-width="140" input-align="right" placeholder="请输入" is-link readonly @click="handelClickYear('useYear')" /> --> <!-- <van-field v-model="form.useYear" label="变压器投运年限(年)" label-width="140" input-align="right" placeholder="请输入" is-link readonly @click="handelClickYear('useYear')" /> -->
<van-field v-model="formColumns.deviceTypeName" label="热水设备类型" required :rules="[{ required: true, message:'请选择热水设备类型' }]" input-align="right" placeholder="请选择" readonly is-link @click="deviceTypeShow = !showForm" /> <van-field v-model="formColumns.deviceTypeName" label="热水设备类型" required :rules="[{ required: true, message:'请选择热水设备类型' }]" input-align="right" placeholder="请选择" readonly is-link @click="deviceTypeShow = !showForm" />
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" input-align="right" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<!-- 是否进行过设备改造 --> <!-- 是否进行过设备改造 -->
<Whether required :rules="[{ required: true, message:'请选择设备改造' }]" :value="formColumns.waterModiyName" @onConfirmTrueFalse="onConfirmTrueFalse" feildName="waterModiy" special="1" /> <Whether required :rules="[{ required: true, message:'请选择设备改造' }]" :value="formColumns.waterModiyName" @onConfirmTrueFalse="onConfirmTrueFalse" feildName="waterModiy" special="1" />
<!-- 改造方式 --> <!-- 改造方式 -->
@@ -85,8 +86,8 @@
</div> </div>
</VanPickerNew> </VanPickerNew>
</div> </div>
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
</van-form> </van-form>
</template> </template>
<script> <script>
@@ -131,7 +132,8 @@ export default {
modifyMode: '', //改造方式 modifyMode: '', //改造方式
modifyYear: '', //增加主机智能化集中控制系统年份 modifyYear: '', //增加主机智能化集中控制系统年份
useYear: '', useYear: '',
intellectModifyYear:'' intellectModifyYear:'',
equipEfficiency: '',
}, },
//页面展示的中文名称 //页面展示的中文名称
formColumns: { formColumns: {
@@ -286,6 +288,7 @@ export default {
this.edSet = setTimeout(async () => { this.edSet = setTimeout(async () => {
//前页面存起来的数据 //前页面存起来的数据
const data = this.$store.getters.editData const data = this.$store.getters.editData
console.log(data, 'data=============');
//问询问题 //问询问题
const searchInfo = this.$store.getters.searchInfo const searchInfo = this.$store.getters.searchInfo
if (searchInfo) { if (searchInfo) {
@@ -321,14 +324,14 @@ export default {
} }
} }
} }
let Efficiency = this.form.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == this.form.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
if(this.form.modifyYear) { if(this.form.modifyYear) {
this.modifyYearShow = true this.modifyYearShow = true
} }
if(this.form.intellectModifyYear) { if(this.form.intellectModifyYear) {
this.intellectModifyYearShow = true this.intellectModifyYearShow = true
} }
//判断是否 //判断是否
this.editIsTrue() this.editIsTrue()
//消耗能源类型 //消耗能源类型
@@ -8,15 +8,15 @@
<van-field v-model="radioName" label="主要灯具类型" input-align="right" is-link placeholder="请选择" required :rules="[{ required: true, message:'请至少选择一个灯具类型' }]" readonly @click="handelClickRadioName" /> <van-field v-model="radioName" label="主要灯具类型" input-align="right" is-link placeholder="请选择" required :rules="[{ required: true, message:'请至少选择一个灯具类型' }]" readonly @click="handelClickRadioName" />
<van-field v-input.float v-show="ledRatioShow" required :rules="[{ required: ledRatioShow, message: '请填写占比' }]" v-model="form.ledRatio" label="LED灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('ledRatio')" /> <van-field v-input.floatNo0 v-show="ledRatioShow" required :rules="[{ required: ledRatioShow}]" v-model="form.ledRatio" label="LED灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('ledRatio')" />
<van-field v-input.float v-show="fluorescentRadioShow" required :rules="[{ required: fluorescentRadioShow, message:'请填写占比' }]" v-model="form.fluorescentRadio" label="普通荧光灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('fluorescentRadio')" /> <van-field v-input.float v-show="fluorescentRadioShow" required :rules="[{ required: fluorescentRadioShow}]" v-model="form.fluorescentRadio" label="普通荧光灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('fluorescentRadio')" />
<van-field v-input.float v-show="incandescentRadioShow" required :rules="[{ required: incandescentRadioShow, message:'请填写占比' }]" v-model="form.incandescentRadio" label="白炽灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('incandescentRadio')" /> <van-field v-input.float v-show="incandescentRadioShow" required :rules="[{ required: incandescentRadioShow}]" v-model="form.incandescentRadio" label="白炽灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('incandescentRadio')" />
<van-field v-input.float v-show="energySaviRatioShow" required :rules="[{ required: energySaviRatioShow, message:'请填写占比' }]" v-model="form.energySaviRatio" label="节能灯占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" @input="handelChangeNumber('energySaviRatio')" /> <van-field v-input.float v-show="energySaviRatioShow" required :rules="[{ required: energySaviRatioShow}]" v-model="form.energySaviRatio" label="非LED节能灯占比(%)" type="number" label-width="148" input-align="right" placeholder="请输入" @input="handelChangeNumber('energySaviRatio')" />
<van-field v-input.float v-show="showOther" required v-model="form.otherRatio" label="其它占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" readonly /> <van-field v-input.float v-show="showOther" required v-model="form.otherRatio" label="其它灯具占比(%)" type="number" label-width="140" input-align="right" placeholder="请输入" readonly />
<van-field v-input.numNo0 v-model="form.totalNum" label="合计数量约(盏)" type="number" required :rules="[{ required: true, message: '请填写合计数量' }]" label-width="140" input-align="right" placeholder="请输入" /> <van-field v-input.numNo0 v-model="form.totalNum" label="合计数量约(盏)" type="number" required :rules="[{ required: true, message: '请填写合计数量' }]" label-width="140" input-align="right" placeholder="请输入" />
@@ -133,7 +133,7 @@ export default {
ledRatio: '', //LED灯具占比(%) ledRatio: '', //LED灯具占比(%)
fluorescentRadio: '', //普通荧光灯(%) fluorescentRadio: '', //普通荧光灯(%)
incandescentRadio: '', //白炽灯占比(%) incandescentRadio: '', //白炽灯占比(%)
energySaviRatio: '', //节能灯占比(%) energySaviRatio: '', //非LED节能灯占比(%)
totalNum: '', // 合计数量约 totalNum: '', // 合计数量约
equipModiy: '', // 是否进行过照明系统改造 equipModiy: '', // 是否进行过照明系统改造
modifyMode: '', //改造方式 modifyMode: '', //改造方式
@@ -165,7 +165,7 @@ export default {
checked: false, checked: false,
}, },
{ {
text: '节能灯', text: '非LED节能灯',
value: '4', value: '4',
field: 'energySaviRatio', field: 'energySaviRatio',
checked: false, checked: false,
@@ -177,7 +177,7 @@ export default {
ledRatioShow: false, ledRatioShow: false,
//普通灯是否展示 //普通灯是否展示
fluorescentRadioShow: false, fluorescentRadioShow: false,
//节能灯是否展示 //非LED节能灯是否展示
incandescentRadioShow: false, incandescentRadioShow: false,
//白炽灯是否展示 //白炽灯是否展示
energySaviRatioShow: false, energySaviRatioShow: false,
@@ -417,7 +417,7 @@ export default {
if (this.form.energySaviRatio) { if (this.form.energySaviRatio) {
this.energySaviRatioShow = true this.energySaviRatioShow = true
this.resultCheckbox.push({ this.resultCheckbox.push({
text: '节能灯', text: '非LED节能灯',
value: this.form.energySaviRatio, value: this.form.energySaviRatio,
field: 'energySaviRatio', field: 'energySaviRatio',
checked: true, checked: true,
@@ -454,7 +454,7 @@ export default {
if (!this.form.energySaviRatio) { if (!this.form.energySaviRatio) {
this.energySaviRatioShow = false this.energySaviRatioShow = false
this.spliceBox.push({ this.spliceBox.push({
text: '节能灯', text: '非LED节能灯',
value: this.form.energySaviRatio, value: this.form.energySaviRatio,
field: 'energySaviRatio', field: 'energySaviRatio',
checked: false, checked: false,
@@ -594,7 +594,7 @@ export default {
if (v.text == '白炽灯' && v.checked) { if (v.text == '白炽灯' && v.checked) {
this.incandescentRadioShow = true this.incandescentRadioShow = true
} }
if (v.text == '节能灯' && v.checked) { if (v.text == '非LED节能灯' && v.checked) {
this.energySaviRatioShow = true this.energySaviRatioShow = true
} }
}) })
@@ -611,7 +611,7 @@ export default {
this.incandescentRadioShow = false this.incandescentRadioShow = false
this.form.incandescentRadio = '' this.form.incandescentRadio = ''
} }
if (v.text == '节能灯' && !v.checked) { if (v.text == '非LED节能灯' && !v.checked) {
this.energySaviRatioShow = false this.energySaviRatioShow = false
this.form.energySaviRatio = '' this.form.energySaviRatio = ''
} }
@@ -636,14 +636,19 @@ export default {
if(!this.form.energySaviRatio) { if(!this.form.energySaviRatio) {
this.form.energySaviRatio = 0 this.form.energySaviRatio = 0
} }
console.log(this.resultCheckbox, 'this.resultCheckbox')
if(this.resultCheckbox.length > 0) { if(this.resultCheckbox.length > 0) {
let num = 0 let num = null
this.resultCheckbox.forEach((v)=> { this.resultCheckbox.forEach((v)=> {
this.form[v.field] = this.form[v.field] || ''
num += Number(this.form[v.field]) num += Number(this.form[v.field])
}) })
if(this.form[title] == 0){
this.form[title] = null
}
if(num > 100) { if(num > 100) {
Notify({ type: "danger", message: '不可超过100%' }); Notify({ type: "danger", message: '不可超过100%' });
this.form[title] = 0 this.form[title] = null
}else{ }else{
this.form.otherRatio = 100 - num this.form.otherRatio = 100 - num
} }
@@ -1,18 +1,15 @@
<template> <template>
<div class="multipleAir"> <div class="multipleAir">
<div class="list-upload" v-if="$store.getters.imageRecognition"> <!-- <div class="list-upload" v-if="$store.getters.imageRecognition">
<btnUploader type="filePic" :value="filePic" <btnUploader type="filePic" :value="filePic"
@afterRead="afterRead1" @afterRead="afterRead1"
@delImg="delImg1" @delImg="delImg1"
@onUpload="onUpload1" /> @onUpload="onUpload1" />
<!-- <Uploader type="exteriorImage" :value="exteriorImage" </div> -->
@afterRead="afterRead"
@delImg="delImg"
@onUpload="onUpload" /> -->
</div>
<div class="focusItem"> <div class="focusItem">
<div class="inputStyle"> <div class="inputStyle">
<van-cell-group> <van-cell-group>
<van-field v-model="form.model" required :rules="[{ required: true },{pattern:/^.{2,20}$/, message:'2≤型号长度≤20'}]" maxlength="20" label="型号" label-width="120" input-align="right" placeholder="请输入型号"/>
<van-field v-model="form.refrigeNum" v-input.numNo0 label="空调数量" type="number" required :rules="[{ required: true}]" input-align="right" placeholder="请输入" /> <van-field v-model="form.refrigeNum" v-input.numNo0 label="空调数量" type="number" required :rules="[{ required: true}]" input-align="right" placeholder="请输入" />
<van-field v-model="edgl" v-input.floatNo0 label="总额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" /> <van-field v-model="edgl" v-input.floatNo0 label="总额定功率(kW)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入" />
<div class="tips" v-if="ratio">{{validateData[0]}}≤额定制冷量/额定功率≤{{validateData[1]}}</div> <div class="tips" v-if="ratio">{{validateData[0]}}≤额定制冷量/额定功率≤{{validateData[1]}}</div>
@@ -40,6 +37,12 @@
<van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runHours" v-input.maxDayHour label="每日运行时间(小时)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.runDays" v-input.maxYearDay label="年平均运行时间(天)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" /> <van-field v-model="form.coldPerArea" v-input.float label="单位面积冷量(kw/平方米)" type="number" required :rules="[{ required: true }]" label-width="220" input-align="right" placeholder="请输入" />
<van-field label="设备生产日期" v-model="form.produceDate" required :rules="[{ required: true }]" placeholder="请选择设备生产日期" label-width="140" input-align="right" is-link readonly @click="datePicker = true" />
<van-field v-model="form.useExpl" v-input.num label="在用台数(台)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入"/>
<van-field v-model="form.backupExpl" v-input.num label="备用台数(台)" type="number" required :rules="[{ required: true }]" input-align="right" placeholder="请输入"/>
<van-field label="设备能效等级" v-model="form.equipEfficiencyName" required :rules="[{ required: true }]" placeholder="请选择设备能效等级" input-align="right" is-link readonly @click="handelClickOptionShow('equipEfficiency')" />
<van-field v-input.num v-model="form.cumulativeRunHours" required :rules="[{ required: true }]" type="number" label="累计运行小时数" placeholder="请输入" label-width="200" input-align="right"/>
<van-field v-input.num v-model="form.dieoutNum" type="number" label="淘汰设备数量" placeholder="请输入" required :rules="[{ required: true }]" label-width="200" input-align="right"/>
</van-cell-group> </van-cell-group>
<div v-if="form.refrigeNum"> <div v-if="form.refrigeNum">
<van-cell class="img-box box1" style="padding:10px 15px;" title="设备外观" :required="$store.getters.cityType"/> <van-cell class="img-box box1" style="padding:10px 15px;" title="设备外观" :required="$store.getters.cityType"/>
@@ -109,6 +112,12 @@
<!-- <div class="bottom"><van-button type="primary" block>保存</van-button></div> --> <!-- <div class="bottom"><van-button type="primary" block>保存</van-button></div> -->
<VanPickerNew :show="show" :columns="list" :loading="loading" @onConfirm="onConfirm" @onCancel="onCancel" /> <VanPickerNew :show="show" :columns="list" :loading="loading" @onConfirm="onConfirm" @onCancel="onCancel" />
<Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" /> <Year :show="yearShow" :num="1" @onConfirmYear="onConfirmYear" @onCancelYear="onCancelYear" />
<VanPickerNew :show="showOption" :columns="columnsList" :loading="loading" @onConfirm="onConfirmOption" @onCancel="showOption=false" />
<!-- 年份选择 -->
<van-popup v-model="datePicker" position="bottom">
<van-datetime-picker v-model="currentDate" type="date" :min-date="minDate" :max-date="maxDate" @confirm="onConfirmDate" @cancel="datePicker = false" />
</van-popup>
</div> </div>
</template> </template>
@@ -150,6 +159,7 @@ export default {
}, },
eqid: '', eqid: '',
form: { form: {
model: '',
modifyMode: '', //改造方式 modifyMode: '', //改造方式
conEquipModiy: '', //是否进行过设备改造 conEquipModiy: '', //是否进行过设备改造
ratedPower: "", ratedPower: "",
@@ -165,7 +175,13 @@ export default {
loadFactor: '', loadFactor: '',
runHours:'', runHours:'',
runDays: '', runDays: '',
coldPerArea: '' coldPerArea: '',
useExpl: '',
backupExpl: '',
equipEfficiency: '',
cumulativeRunHours: '',
produceDate:'',
dieoutNum: ''
}, },
/** /**
@@ -351,7 +367,9 @@ export default {
this.form.conEquipModiy = data.info.conEquipModiy this.form.conEquipModiy = data.info.conEquipModiy
this.formColumns.conEquipModiyName = data.info.conEquipModiy == 1 ? '是' : '否' this.formColumns.conEquipModiyName = data.info.conEquipModiy == 1 ? '是' : '否'
console.log(this.form.equipEfficiency, 'data.equipEfficiency');
let Efficiency = this.form.equipEfficiency&&this.equipEfficiencyOption.find(item => item.value == this.form.equipEfficiency)
this.form.equipEfficiencyName = Efficiency&&Efficiency.text
if (data.info.conIntellectModifyYear) { if (data.info.conIntellectModifyYear) {
this.form.conIntellectModifyYear = data.info.conIntellectModifyYear this.form.conIntellectModifyYear = data.info.conIntellectModifyYear
this.resultList.push({ this.resultList.push({
+4 -1
View File
@@ -202,6 +202,7 @@ export default {
if (res.data.nxzdHeatSystemDTO && this.parentPath.split('/facilityManage').length < 2) { if (res.data.nxzdHeatSystemDTO && this.parentPath.split('/facilityManage').length < 2) {
this.$store.dispatch('saveList/getHea', res.data.nxzdHeatSystemDTO) this.$store.dispatch('saveList/getHea', res.data.nxzdHeatSystemDTO)
} }
console.log(res.data, 'res.data==================');
const data = { const data = {
info: res.data, info: res.data,
pageKey: this.pageKey, pageKey: this.pageKey,
@@ -318,6 +319,7 @@ export default {
pumpNum: '', // 输送泵组台数 pumpNum: '', // 输送泵组台数
pumpTotalPower: '', //输送泵组总功率 pumpTotalPower: '', //输送泵组总功率
pumpYear: '', // 输送泵组设备年份 pumpYear: '', // 输送泵组设备年份
produceDate: ''
} }
this.commonForm.operDetailCode = '' // 用能设备明细类型编号用逗号隔开 this.commonForm.operDetailCode = '' // 用能设备明细类型编号用逗号隔开
}, },
@@ -378,7 +380,7 @@ export default {
// console.log(cn); // console.log(cn);
// eslint-disable-next-line no-case-declarations // eslint-disable-next-line no-case-declarations
const heatObj = this.$refs.component const heatObj = this.$refs.component
console.log(heatObj, 'heatObj===============');
// eslint-disable-next-line no-case-declarations // eslint-disable-next-line no-case-declarations
const heatRes = await this.flagNo(heatObj.$refs.heat) const heatRes = await this.flagNo(heatObj.$refs.heat)
flag = heatRes flag = heatRes
@@ -475,6 +477,7 @@ export default {
this.commonForm.nxzdUseEnergyEquipDTO.heatType = store.heatType this.commonForm.nxzdUseEnergyEquipDTO.heatType = store.heatType
this.commonForm.nxzdUseEnergyEquipDTO.heatMode = store.heatMode this.commonForm.nxzdUseEnergyEquipDTO.heatMode = store.heatMode
this.commonForm.nxzdUseEnergyEquipDTO.produceDate = store.produceDate
this.commonForm.nxzdUseEnergyEquipDTO.pumpTotalPower = store.pumpTotalPower||0 this.commonForm.nxzdUseEnergyEquipDTO.pumpTotalPower = store.pumpTotalPower||0
@@ -23,6 +23,7 @@
<th>名称</th> <th>名称</th>
<th>实物量</th> <th>实物量</th>
<th>折标量(吨折煤)</th> <th>折标量(吨折煤)</th>
<th v-if="cityisXj">二氧化碳系数(千克)</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@@ -31,48 +32,56 @@
<td>外购电</td> <td>外购电</td>
<td>{{ enterpriseEnergy81['电'].val }}(千瓦时)</td> <td>{{ enterpriseEnergy81['电'].val }}(千瓦时)</td>
<td>{{ enterpriseEnergy81['电'].standardVal }}</td> <td>{{ enterpriseEnergy81['电'].standardVal }}</td>
<td v-if="cityisXj"></td>
</tr> </tr>
<tr> <tr>
<td>2</td> <td>2</td>
<td>天然气</td> <td>天然气</td>
<td>{{ enterpriseEnergy81['天然气'].val }}(立方米)</td> <td>{{ enterpriseEnergy81['天然气'].val }}(立方米)</td>
<td>{{ enterpriseEnergy81['天然气'].standardVal }}</td> <td>{{ enterpriseEnergy81['天然气'].standardVal }}</td>
<td v-if="cityisXj">{{ enterpriseEnergy81['天然气'].co2 }}</td>
</tr> </tr>
<tr> <tr>
<td>3</td> <td>3</td>
<td>外购低压蒸汽</td> <td>外购低压蒸汽</td>
<td>{{ enterpriseEnergy81['低压蒸汽'].val }}(吨)</td> <td>{{ enterpriseEnergy81['低压蒸汽'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['低压蒸汽'].standardVal }}</td> <td>{{ enterpriseEnergy81['低压蒸汽'].standardVal }}</td>
<td v-if="cityisXj"></td>
</tr> </tr>
<tr> <tr>
<td>4</td> <td>4</td>
<td>外购中压蒸汽</td> <td>外购中压蒸汽</td>
<td>{{ enterpriseEnergy81['中压蒸汽'].val }}(吨)</td> <td>{{ enterpriseEnergy81['中压蒸汽'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['中压蒸汽'].standardVal }}</td> <td>{{ enterpriseEnergy81['中压蒸汽'].standardVal }}</td>
<td v-if="cityisXj"></td>
</tr> </tr>
<tr> <tr>
<td>5</td> <td>5</td>
<td>外购高压蒸汽</td> <td>外购高压蒸汽</td>
<td>{{ enterpriseEnergy81['高压蒸汽'].val }}(吨)</td> <td>{{ enterpriseEnergy81['高压蒸汽'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['高压蒸汽'].standardVal }}</td> <td>{{ enterpriseEnergy81['高压蒸汽'].standardVal }}</td>
<td v-if="cityisXj"></td>
</tr> </tr>
<tr> <tr>
<td>6</td> <td>6</td>
<td>煤</td> <td>煤</td>
<td>{{ enterpriseEnergy81['煤'].val }}(吨)</td> <td>{{ enterpriseEnergy81['煤'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['煤'].standardVal }}</td> <td>{{ enterpriseEnergy81['煤'].standardVal }}</td>
<td v-if="cityisXj">{{ enterpriseEnergy81['煤'].co2 }}</td>
</tr> </tr>
<tr> <tr>
<td>7</td> <td>7</td>
<td>汽油</td> <td>汽油</td>
<td>{{ enterpriseEnergy81['汽油'].val }}(吨)</td> <td>{{ enterpriseEnergy81['汽油'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['汽油'].standardVal }}</td> <td>{{ enterpriseEnergy81['汽油'].standardVal }}</td>
<td v-if="cityisXj">{{ enterpriseEnergy81['汽油'].co2 }}</td>
</tr> </tr>
<tr> <tr>
<td>8</td> <td>8</td>
<td>柴油</td> <td>柴油</td>
<td>{{ enterpriseEnergy81['柴油'].val }}(吨)</td> <td>{{ enterpriseEnergy81['柴油'].val }}(吨)</td>
<td>{{ enterpriseEnergy81['柴油'].standardVal }}</td> <td>{{ enterpriseEnergy81['柴油'].standardVal }}</td>
<td v-if="cityisXj">{{ enterpriseEnergy81['柴油'].co2 }}</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
@@ -150,7 +159,7 @@
<script> <script>
import commonTitle from './commonTitle.vue' import commonTitle from './commonTitle.vue'
import { mapState } from 'vuex' import { mapState, mapGetters } from 'vuex'
export default { export default {
data() { data() {
return { return {
@@ -198,11 +207,12 @@ export default {
} }
] ]
}, },
improveList:[] improveList:[],
} }
}, },
components: { commonTitle }, components: { commonTitle },
computed: { computed: {
...mapGetters(['cityisXj']),
...mapState('report', ['EnergyReportInfo']), ...mapState('report', ['EnergyReportInfo']),
enterpriseEnergy81() { enterpriseEnergy81() {
if (this.EnergyReportInfo.enterpriseEnergy81) { if (this.EnergyReportInfo.enterpriseEnergy81) {
+4 -1
View File
@@ -32,7 +32,7 @@
</div> --> </div> -->
</div> </div>
<div class="detail2-right-bottom"> <div class="detail2-right-bottom">
用电户号: <div>{{ EnergyReportInfo.consNo }}</div> {{userCode}}: <div>{{ EnergyReportInfo.consNo }}</div>
</div> </div>
</div> </div>
</div> </div>
@@ -234,6 +234,9 @@ export default {
}, },
computed: { computed: {
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
changeTime() { changeTime() {
return formatymd(this.EnergyReportInfo.changeTime) return formatymd(this.EnergyReportInfo.changeTime)
}, },
+4 -1
View File
@@ -36,7 +36,7 @@
</div> </div>
</div> </div>
<div class="detail2-right-bottom"> <div class="detail2-right-bottom">
用电户号: <div>{{ EnergyReportInfo.consNo }}</div> {{userCode}}: <div>{{ EnergyReportInfo.consNo }}</div>
</div> </div>
</div> </div>
</div> </div>
@@ -213,6 +213,9 @@ export default {
// this.getTime() // this.getTime()
}, },
computed: { computed: {
userCode(){
return this.$store.getters.validate? '用户编号':'用电户号'
},
reportYear() { reportYear() {
if (this.EnergyReportInfo.reportYear) { if (this.EnergyReportInfo.reportYear) {
return this.EnergyReportInfo.reportYear return this.EnergyReportInfo.reportYear
+24 -5
View File
@@ -22,6 +22,7 @@ module.exports = {
// outputDir: ('1006028-' + pkgInfo.version), //生产包 // outputDir: ('1006028-' + pkgInfo.version), //生产包
outputDir: 'dist', //测试环境 outputDir: 'dist', //测试环境
lintOnSave: false, lintOnSave: false,
parallel: false,
publicPath: '', publicPath: '',
chainWebpack: config => { chainWebpack: config => {
// config.plugin('webpack-bundle-analyzer').use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin), // config.plugin('webpack-bundle-analyzer').use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin),
@@ -126,15 +127,33 @@ module.exports = {
devServer: { devServer: {
host: '0.0.0.0', host: '0.0.0.0',
port: port, port: port,
hot: true,
open: true, open: true,
proxy: { proxy: {
[process.env.VUE_APP_BASE_API]: {
target: `http://172.29.69.38:28083`, "/admin": {
// target: "http://121.28.84.19:9004",
target: "http://172.29.69.38:19012",
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: '' "^/admin": "",
} },
} }, "/energy-effcicency-net-service": {
// target: "http://121.28.84.19:9004",
target: "http://172.29.69.38:19012",
changeOrigin: true,
pathRewrite: {
"^/energy-effcicency-net-service": "",
},
},
// [process.env.VUE_APP_BASE_API]: {
// target: process.env.VUE_APP_SERVER_Url,
// changeOrigin: true,
// secure: false,
// pathRewrite: {
// [`^${process.env.VUE_APP_BASE_API}`]: '',
// },
// },
}, },
disableHostCheck: true disableHostCheck: true
}, },