feat: init "瑞彩" code
This commit is contained in:
parent
d8b6ee8b30
commit
bebf516a57
|
@ -6,7 +6,7 @@ npm-debug.log*
|
|||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
*.log
|
||||
|
||||
*.zip
|
||||
# Editor directories and files
|
||||
.idea
|
||||
.vscode
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 6.7 KiB After Width: | Height: | Size: 27 KiB |
Binary file not shown.
Before Width: | Height: | Size: 400 KiB After Width: | Height: | Size: 1.2 MiB |
|
@ -4,46 +4,39 @@
|
|||
<div style="display:flex">
|
||||
<el-form inline>
|
||||
<el-form-item label="客户">
|
||||
<el-input v-model="searchData_Subset.clientName" placeholder="请输入客户名称" clearable size="small" width="100"></el-input>
|
||||
<el-input v-model="searchData_Subset.clientName" placeholder="请输入客户名称" clearable size="small"
|
||||
width="100"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="单据日期">
|
||||
<el-date-picker
|
||||
style="width:350px"
|
||||
v-model="time"
|
||||
type="datetimerange"
|
||||
format="yyyy-MM-dd HH:mm:ss"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
range-separator="—"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
></el-date-picker>
|
||||
<el-date-picker style="width:350px" v-model="time" type="datetimerange" format="yyyy-MM-dd HH:mm:ss"
|
||||
value-format="yyyy-MM-dd HH:mm:ss" range-separator="—" start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"></el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="物料">
|
||||
<el-input v-model="searchData_Subset.materielName" placeholder="请输入物料名称" clearable size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="客户合同编号">
|
||||
<el-input v-model="searchData_Subset.clientContractCode" placeholder="请输入" clearable size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="searchSubset">查询</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="sys-table">
|
||||
<el-table
|
||||
@row-click="clickRow"
|
||||
ref="tb"
|
||||
:data="subsetList"
|
||||
border
|
||||
v-loading="dialogLoading"
|
||||
:header-cell-style="{fontWeight: 'normal', textAlign: 'center', backgroundColor: '#eceff4', color: '#222'}"
|
||||
>
|
||||
<el-table-column prop="thisSourceTypeName" label="源单类型" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="code" label="单据编号" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="contractDate" label="单据时间" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="clientName" label="客户名称" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="materielSerialNo" label="物料代码" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="materielName" label="物料名称" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="specification" label="规格型号" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="count" label="数量" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="quoteCount" label="未执行数量" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table @row-click="clickRow" ref="tb" :data="subsetList" border v-loading="dialogLoading"
|
||||
:header-cell-style="{ fontWeight: 'normal', textAlign: 'center', backgroundColor: '#eceff4', color: '#222' }">
|
||||
<el-table-column prop="thisSourceTypeName" label="源单类型" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="code" label="单据编号" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="clientContractCode" label="客户合同编号" align="center"
|
||||
show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="contractDate" label="单据时间" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="clientName" label="客户名称" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="materielSerialNo" label="物料代码" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="materielName" label="物料名称" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="specification" label="规格型号" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="count" label="数量" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="quoteCount" label="未执行数量" align="center" show-overflow-tooltip></el-table-column>
|
||||
|
||||
<el-table-column label="操作" align="center" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
|
@ -54,21 +47,15 @@
|
|||
</el-table>
|
||||
</div>
|
||||
<div class="sys-pagination">
|
||||
<el-pagination
|
||||
:current-page.sync="searchData_Subset.pageno"
|
||||
:page-sizes="[5, 10, 20]"
|
||||
:page-size="searchData_Subset.pagesize"
|
||||
@size-change="subsetSizeChange"
|
||||
@current-change="subsetCurrentChange"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="subsetTotal"
|
||||
></el-pagination>
|
||||
<el-pagination :current-page.sync="searchData_Subset.pageno" :page-sizes="[5, 10, 20]"
|
||||
:page-size="searchData_Subset.pagesize" @size-change="subsetSizeChange" @current-change="subsetCurrentChange"
|
||||
layout="total, sizes, prev, pager, next, jumper" :total="subsetTotal"></el-pagination>
|
||||
</div>
|
||||
|
||||
<!-- <span slot="footer" class="dialog-footer">-->
|
||||
<!-- <el-button type="primary" :loading="loading" @click="submit()">确定</el-button>-->
|
||||
<!-- <el-button type="primary" @click="innerVisible = false">关闭</el-button>-->
|
||||
<!-- </span>-->
|
||||
<!-- <span slot="footer" class="dialog-footer">-->
|
||||
<!-- <el-button type="primary" :loading="loading" @click="submit()">确定</el-button>-->
|
||||
<!-- <el-button type="primary" @click="innerVisible = false">关闭</el-button>-->
|
||||
<!-- </span>-->
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
@ -225,7 +212,7 @@
|
|||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-input {
|
||||
width: 150px;
|
||||
}
|
||||
.el-input {
|
||||
width: 150px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -2,14 +2,21 @@
|
|||
<div class="home">
|
||||
<dv-border-box-11 title="废水在线监测看板">
|
||||
<div class="head_title"></div>
|
||||
<img :src="logoUrl ? logoUrl : logoUrlDefault" v-if="logoUrlFlag" class="logo_kanban" />
|
||||
<img
|
||||
:src="logoUrl ? logoUrl : logoUrlDefault"
|
||||
v-if="logoUrlFlag"
|
||||
class="logo_kanban"
|
||||
/>
|
||||
<!-- <div class="time">{{time}}</div>
|
||||
<div class="date"><div>{{date}}</div><div>星期{{weekday}}</div></div> -->
|
||||
<div class="main">
|
||||
<div class="item_out-new item_out7">
|
||||
<div class="item_name">总排口</div>
|
||||
<div class="item_container item7_container">
|
||||
<img src="../../assets/item_border.png" class="item_container_back" />
|
||||
<img
|
||||
src="../../assets/item_border.png"
|
||||
class="item_container_back"
|
||||
/>
|
||||
<table class="table" border="0" cellpadding="0" cellspacing="0">
|
||||
<div class="tr table_head">
|
||||
<div class="td" style="width:14%">监控时间</div>
|
||||
|
@ -26,51 +33,70 @@
|
|||
<div class="td" style="width:7.6%">标准值</div>
|
||||
<div class="td" style="width:7.6%">状态</div>
|
||||
</div>
|
||||
<div class="tr table_list" v-for="(items, index) in dataList7" :key="items.id">
|
||||
<div
|
||||
class="tr table_list"
|
||||
v-for="(items, index) in dataList7"
|
||||
:key="items.id"
|
||||
>
|
||||
<div class="td" style="width:14%">{{ items.jksj }}</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.ssllzt)">{{ items.ssll
|
||||
}}</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.phzzt)">
|
||||
<div class="td" style="width:7.6%">{{ items.ssll }}</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz,items.bzz1,items.phzzt)">
|
||||
{{ items.phz }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.bzz1zt)">
|
||||
<div class="td" style="width:7.6%">
|
||||
{{ items.bzz1 }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.cod, items.bzz2, items.codzt)">
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.cod,items.bzz2,items.codzt)">
|
||||
{{ items.cod }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.bzz2zt)">
|
||||
<div class="td" style="width:7.6%">
|
||||
{{ items.bzz2 }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.zt, items.bzz3, items.ztzt)">
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.zt,items.bzz3,items.ztzt)">
|
||||
{{ items.zt }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.bzz3zt)">
|
||||
<div class="td" style="width:7.6%">
|
||||
{{ items.bzz3 }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.zx, items.bzz4, items.zxzt)">
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.zx,items.bzz4,items.zxzt)">
|
||||
{{ items.zx }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.bzz4zt)">
|
||||
<div class="td" style="width:7.6%">
|
||||
{{ items.bzz4 }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.ad, items.bzz5, items.adzt)">
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.ad,items.bzz5,items.adzt)">
|
||||
{{ items.ad }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%" :class="isDanger(items.phz, items.bzz1, items.bzz5zt)">
|
||||
<div class="td" style="width:7.6%">
|
||||
{{ items.bzz5 }}
|
||||
</div>
|
||||
<div class="td" style="width:7.6%">
|
||||
<div class="status_btn" v-if="items.zt2 == '超标'" style="color:#A30014;border:1px solid #A30014">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-if="items.zt2 == '超标'"
|
||||
style="color:#A30014;border:1px solid #A30014"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '正常'" style="color:#95f204;border:1px solid #95f204;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '正常'"
|
||||
style="color:#95f204;border:1px solid #95f204;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '异常'" style="color:#D9001B;border:1px solid #D9001B;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '异常'"
|
||||
style="color:#D9001B;border:1px solid #D9001B;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else style="color:#3c2ed1;border:1px solid #3c2ed1;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else
|
||||
style="color:#3c2ed1;border:1px solid #3c2ed1;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -112,7 +138,10 @@
|
|||
<div class="item_out item_out9">
|
||||
<div class="item_name">车间排口1</div>
|
||||
<div class="item_container item9_container">
|
||||
<img src="../../assets/item_border.png" class="item_container_back" />
|
||||
<img
|
||||
src="../../assets/item_border.png"
|
||||
class="item_container_back"
|
||||
/>
|
||||
<table class="table" border="0" cellpadding="0" cellspacing="0">
|
||||
<div class="tr table_head">
|
||||
<div class="td" style="width:22%">监控时间</div>
|
||||
|
@ -121,23 +150,42 @@
|
|||
<div class="td">标准值</div>
|
||||
<div class="td" style="width:14%">状态</div>
|
||||
</div>
|
||||
<div class="tr table_list" v-for="(items, index) in dataList9" :key="index">
|
||||
<div class="td" style="width:22%" :class="isDanger(items.phz, items.bzz1, items.jksjzt)">{{ items.jksj
|
||||
}}</div>
|
||||
<div class="td" :class="isDanger(items.phz, items.bzz1, items.ssllzt)">{{ items.ssll }}</div>
|
||||
<div class="td" :class="isDanger(items.zn, items.bzz1, items.znzt)">{{ items.zn }}</div>
|
||||
<div class="td" :class="isDanger(items.phz, items.bzz1, items.bzz1zt)">{{ items.bzz1 }}</div>
|
||||
<div
|
||||
class="tr table_list"
|
||||
v-for="(items, index) in dataList9"
|
||||
:key="index"
|
||||
>
|
||||
<div class="td" style="width:22%">{{ items.jksj }}</div>
|
||||
<div class="td">{{ items.ssll }}</div>
|
||||
<div class="td" :class="isDanger(items.zn,items.bzz1,items.znzt)">{{ items.zn }}</div>
|
||||
<div class="td">{{ items.bzz1 }}</div>
|
||||
<div class="td" style="width:14%">
|
||||
<div class="status_btn" v-if="items.zt2 == '超标'" style="color:#A30014;border:1px solid #A30014">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-if="items.zt2 == '超标'"
|
||||
style="color:#A30014;border:1px solid #A30014"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '正常'" style="color:#95f204;border:1px solid #95f204;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '正常'"
|
||||
style="color:#95f204;border:1px solid #95f204;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '异常'" style="color:#D9001B;border:1px solid #D9001B;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '异常'"
|
||||
style="color:#D9001B;border:1px solid #D9001B;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else style="color:#3c2ed1;border:1px solid #3c2ed1;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else
|
||||
style="color:#3c2ed1;border:1px solid #3c2ed1;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -148,7 +196,10 @@
|
|||
<div class="item_out item_out10">
|
||||
<div class="item_name">车间排口2</div>
|
||||
<div class="item_container item10_container">
|
||||
<img src="../../assets/item_border.png" class="item_container_back" />
|
||||
<img
|
||||
src="../../assets/item_border.png"
|
||||
class="item_container_back"
|
||||
/>
|
||||
<table class="table" border="0" cellpadding="0" cellspacing="0">
|
||||
<div class="tr table_head">
|
||||
<div class="td" style="width:25%">监控时间</div>
|
||||
|
@ -159,30 +210,46 @@
|
|||
<div class="td" style="width:14%">标准值</div>
|
||||
<div class="td" style="width:14%">状态</div>
|
||||
</div>
|
||||
<div class="tr table_list" v-for="(items, index) in dataList10" :key="index">
|
||||
<div
|
||||
class="tr table_list"
|
||||
v-for="(items, index) in dataList10"
|
||||
:key="index"
|
||||
>
|
||||
<div class="td" style="width:25%">{{ items.jksj }}</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.phz, items.bzz1, items.ssllzt)">{{ items.ssll
|
||||
}}</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.zg, items.bzz1, items.zgzt)">{{ items.zg }}
|
||||
</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.phz, items.bzz1, items.bzz1zt)">
|
||||
<div class="td" style="width:14%">{{ items.ssll }}</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.zg,items.bzz1,items.zg)">{{ items.zg }}</div>
|
||||
<div class="td" style="width:14%">
|
||||
{{ items.bzz1 }}
|
||||
</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.ljg, items.bzz2, items.ljgzt)">{{ items.ljg }}
|
||||
</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.phz, items.bzz1, items.bzz2zt)">{{ items.bzz2
|
||||
}}</div>
|
||||
<div class="td" style="width:14%" :class="isDanger(items.ljg,items.bzz1,items.ljgzt)">{{ items.ljg }}</div>
|
||||
<div class="td" style="width:14%">{{ items.bzz2 }}</div>
|
||||
<div class="td" style="width:14%">
|
||||
<div class="status_btn" v-if="items.zt2 == '超标'" style="color:#A30014;border:1px solid #A30014">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-if="items.zt2 == '超标'"
|
||||
style="color:#A30014;border:1px solid #A30014"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '正常'" style="color:#95f204;border:1px solid #95f204;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '正常'"
|
||||
style="color:#95f204;border:1px solid #95f204;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else-if="items.zt2 == '异常'" style="color:#D9001B;border:1px solid #D9001B;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else-if="items.zt2 == '异常'"
|
||||
style="color:#D9001B;border:1px solid #D9001B;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
<div class="status_btn" v-else style="color:#3c2ed1;border:1px solid #3c2ed1;">
|
||||
<div
|
||||
class="status_btn"
|
||||
v-else
|
||||
style="color:#3c2ed1;border:1px solid #3c2ed1;"
|
||||
>
|
||||
{{ items.zt2 }}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -259,31 +326,22 @@ export default {
|
|||
methods: {
|
||||
// 标准值定义
|
||||
isDanger(val, bz,zt) {
|
||||
if(zt==0){
|
||||
return ''
|
||||
if (!val || !bz) {
|
||||
return false;
|
||||
}
|
||||
if(zt==1){
|
||||
return 'td-warn'
|
||||
if (val > bz) {
|
||||
if(zt){
|
||||
return 'error td-err'
|
||||
}else{
|
||||
return 'error'
|
||||
}
|
||||
} else {
|
||||
if(zt){
|
||||
return 'td-err'
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
}
|
||||
if(zt==2){
|
||||
return 'td-err'
|
||||
}
|
||||
// if (!val || !bz) {
|
||||
// return false;
|
||||
// }
|
||||
// if (val > bz) {
|
||||
// if(zt){
|
||||
// return 'error td-err'
|
||||
// }else{
|
||||
// return 'error'
|
||||
// }
|
||||
// } else {
|
||||
// if(zt){
|
||||
// return 'td-err'
|
||||
// }else{
|
||||
// return ''
|
||||
// }
|
||||
// }
|
||||
},
|
||||
getLogo() {
|
||||
this.$api.fileAPI.getLogo().then(res => {
|
||||
|
@ -505,7 +563,6 @@ export default {
|
|||
.error {
|
||||
color: red !important;
|
||||
}
|
||||
|
||||
.logo_kanban {
|
||||
width: 120px;
|
||||
height: 29px;
|
||||
|
@ -513,7 +570,6 @@ export default {
|
|||
left: 20px;
|
||||
top: 20px;
|
||||
}
|
||||
|
||||
.home {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
|
@ -523,7 +579,6 @@ export default {
|
|||
min-height: 700px;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.head_title {
|
||||
position: relative;
|
||||
height: 80px;
|
||||
|
@ -532,7 +587,6 @@ export default {
|
|||
background-size: contain;
|
||||
margin: auto;
|
||||
}
|
||||
|
||||
.main {
|
||||
position: absolute;
|
||||
top: 80px;
|
||||
|
@ -546,7 +600,6 @@ export default {
|
|||
justify-content: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.time {
|
||||
font-family: "黑体";
|
||||
position: absolute;
|
||||
|
@ -559,7 +612,6 @@ export default {
|
|||
-moz-transform: translate3d(0, 0, 0);
|
||||
-o-transform: translate3d(0, 0, 0);
|
||||
}
|
||||
|
||||
.date {
|
||||
font-family: "黑体";
|
||||
position: absolute;
|
||||
|
@ -573,43 +625,36 @@ export default {
|
|||
-moz-transform: translate3d(0, 0, 0);
|
||||
-o-transform: translate3d(0, 0, 0);
|
||||
}
|
||||
|
||||
.item_out {
|
||||
/*height: calc((100% - 60px)/3);*/
|
||||
width: calc((100% - 60px) / 2);
|
||||
margin: 10px;
|
||||
}
|
||||
|
||||
.item_out-new {
|
||||
/*height: calc((100% - 60px)/3);*/
|
||||
width: calc(100% - 60px);
|
||||
margin: 10px;
|
||||
}
|
||||
|
||||
.item_out10 {
|
||||
height: calc((100% - 60px) / 2);
|
||||
left: 10px;
|
||||
bottom: 10px;
|
||||
}
|
||||
|
||||
.item_out9 {
|
||||
height: calc((100% - 60px) / 2);
|
||||
left: 10px;
|
||||
top: 10px;
|
||||
}
|
||||
|
||||
.item_out7 {
|
||||
height: calc((100% - 55px) / 2);
|
||||
right: 10px;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.item_out8 {
|
||||
height: calc((100% - 60px) / 2);
|
||||
right: 10px;
|
||||
bottom: 10px;
|
||||
}
|
||||
|
||||
.item_name {
|
||||
position: relative;
|
||||
font-size: 16px;
|
||||
|
@ -629,7 +674,6 @@ export default {
|
|||
background-repeat: no-repeat;
|
||||
background-size: contain;
|
||||
}
|
||||
|
||||
.item_container_back,
|
||||
.charts_item_container {
|
||||
position: absolute;
|
||||
|
@ -639,7 +683,6 @@ export default {
|
|||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.item_container {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
|
@ -657,7 +700,6 @@ export default {
|
|||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.table_head {
|
||||
position: relative;
|
||||
display: flex;
|
||||
|
@ -673,7 +715,6 @@ export default {
|
|||
-moz-transform: translate3d(0, 0, 0);
|
||||
-o-transform: translate3d(0, 0, 0);
|
||||
}
|
||||
|
||||
.table_head .td {
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
|
@ -684,7 +725,6 @@ export default {
|
|||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.table_list {
|
||||
width: 100%;
|
||||
height: 35px;
|
||||
|
@ -693,7 +733,6 @@ export default {
|
|||
justify-content: space-around;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.table_list .td {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
|
@ -713,11 +752,10 @@ export default {
|
|||
-moz-transform: translate3d(0, 0, 0);
|
||||
-o-transform: translate3d(0, 0, 0);
|
||||
}
|
||||
|
||||
.table_list .td-err {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
width: 35%;
|
||||
width: 40%;
|
||||
height: 60%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
|
@ -727,30 +765,6 @@ export default {
|
|||
color: #fff !important;
|
||||
background-color: red;
|
||||
font-size: 13px;
|
||||
margin-left: 5px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
transform: translate3d(0, 0, 0);
|
||||
-webkit-transform: translate3d(0, 0, 0);
|
||||
-moz-transform: translate3d(0, 0, 0);
|
||||
-o-transform: translate3d(0, 0, 0);
|
||||
}
|
||||
|
||||
.table_list .td-warn {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
width: 35%;
|
||||
height: 60%;
|
||||
margin-left: 5px;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
box-sizing: border-box;
|
||||
color: #fff !important;
|
||||
background-color: #E6A23C;
|
||||
font-size: 13px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
|
@ -764,27 +778,22 @@ export default {
|
|||
.table_list .td:nth-child(1) {
|
||||
width: 10%;
|
||||
}
|
||||
|
||||
.table_head .td:nth-child(2),
|
||||
.table_list .td:nth-child(2) {
|
||||
width: 21%;
|
||||
}
|
||||
|
||||
.table_head .td:nth-child(3),
|
||||
.table_list .td:nth-child(3) {
|
||||
width: 20%;
|
||||
}
|
||||
|
||||
.table_head .td:nth-child(4),
|
||||
.table_list .td:nth-child(4) {
|
||||
width: 12%;
|
||||
}
|
||||
|
||||
.table_head .td:nth-child(5),
|
||||
.table_list .td:nth-child(5) {
|
||||
width: 21%;
|
||||
}
|
||||
|
||||
.table_head .td:nth-child(6),
|
||||
.table_list .td:nth-child(6) {
|
||||
width: 16%;
|
||||
|
@ -815,7 +824,6 @@ export default {
|
|||
left: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
footer {
|
||||
position: absolute;
|
||||
left: 0px;
|
||||
|
@ -827,17 +835,13 @@ footer {
|
|||
font-size: 12px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
footer span {
|
||||
padding: 0px 20px;
|
||||
}
|
||||
|
||||
footer span a {
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
@media (max-width: 1600px) {
|
||||
|
||||
.table_list .td,
|
||||
.table_head,
|
||||
.items2_chartname,
|
||||
|
@ -846,9 +850,7 @@ footer span a {
|
|||
font-size: 14px !important;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 1600px) {
|
||||
|
||||
.table_list .td,
|
||||
.table_head,
|
||||
.items2_chartname,
|
||||
|
|
|
@ -107,7 +107,7 @@
|
|||
</div>
|
||||
<div class="yxk-content yxk-flex">
|
||||
<div class="header">
|
||||
<p class="title">实时库存统计</p>
|
||||
<p class="title">产能趋势图</p>
|
||||
</div>
|
||||
<div style="width:100%;height: calc(100% - 2rem);" id="container"></div>
|
||||
</div>
|
||||
|
@ -515,7 +515,7 @@ export default {
|
|||
color: "#333"
|
||||
},
|
||||
formatter: function(params) {
|
||||
return params[0].name + ":<br/>" + params[0].value + "万件";
|
||||
return params[0].name + ":<br/>" + params[0].value + "万米";
|
||||
}
|
||||
},
|
||||
grid: {
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<div class="header-wrap">
|
||||
<div class="myheader">
|
||||
<p class="header-title">
|
||||
江西液压件工业互联网平台数字化展示中心
|
||||
瑞彩科技工业互联网平台数字化展示中心
|
||||
</p>
|
||||
<div class="time">{{ time }}</div>
|
||||
<!-- <div class="weather">{{ "🌤晴 22℃" }}</div> -->
|
||||
|
|
|
@ -93,7 +93,7 @@
|
|||
<el-form-item label="批号" prop="ph" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.ph" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="浓度" prop="nd" class="form-inline">
|
||||
<!-- <el-form-item label="浓度" prop="nd" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.nd" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="径距" prop="jj" class="form-inline">
|
||||
|
@ -110,12 +110,13 @@
|
|||
</el-form-item>
|
||||
<el-form-item label="D[4,3]" prop="f2" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.f2" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="Dv(10)" prop="f3" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.f3" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="Dv(50)" prop="f4" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.f4" placeholder="请输入" />
|
||||
<el-input style="width:100%" v-model="formData.f4" @change="handleCheck(formData.bzfw, formData.f4)"
|
||||
placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="Dv(90)" prop="f5" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.f5" placeholder="请输入" />
|
||||
|
@ -123,13 +124,21 @@
|
|||
<el-form-item label="Dv(97)" prop="f6" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.f6" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="检测方式" prop="jcfs" class="form-inline">
|
||||
<el-input
|
||||
style="width:100%"
|
||||
v-model="formData.jcfs"
|
||||
placeholder="请输入"
|
||||
/>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="标准范围" prop="bzfw" class="form-inline">
|
||||
<el-select clearable v-model="formData.bzfwid" @change="
|
||||
el => {
|
||||
formData.bzfw = bzfwList.filter(
|
||||
item => item.id == el
|
||||
)[0].name;
|
||||
handleCheck(formData.bzfw, formData.f4)
|
||||
}
|
||||
" placeholder="请选择">
|
||||
<el-option v-for="item in bzfwList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="检测结果" prop="jcjg" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.jcjg" disabled />
|
||||
</el-form-item>
|
||||
</div>
|
||||
<el-form-item label="检测结果分析">
|
||||
<el-input type="textarea" :autosize="{ minRows: 4 }" v-model="formData.jcjgfx"
|
||||
|
@ -205,6 +214,7 @@ export default {
|
|||
}
|
||||
],
|
||||
depOptions: [],
|
||||
bzfwList: [],
|
||||
selectDeptId: [],
|
||||
formData: {},
|
||||
start_datetime: {
|
||||
|
@ -258,7 +268,7 @@ export default {
|
|||
},
|
||||
mounted() {
|
||||
this.userInfo = JSON.parse(Cookies.get("userInfo"));
|
||||
// this.initialize();
|
||||
this.initialize();
|
||||
if (this.$route.query.id) {
|
||||
this.formData.id = this.$route.query.id;
|
||||
this.getDetail();
|
||||
|
@ -290,6 +300,18 @@ export default {
|
|||
...mapMutations({
|
||||
removeTagNav: "tagNav/removeTagNav"
|
||||
}),
|
||||
handleCheck(pre,rec){
|
||||
if(pre&&rec){
|
||||
let list = pre.split('~')
|
||||
if(rec-list[0]>-1&&rec-list[1]<=0){
|
||||
this.$set(this.formData, "jcjg", 'OK');
|
||||
}else{
|
||||
this.$set(this.formData, "jcjg", 'NG');
|
||||
}
|
||||
}else{
|
||||
this.$set(this.formData, "jcjg", '');
|
||||
}
|
||||
},
|
||||
currentIndex(newv) {
|
||||
this.currentChildIndex = newv;
|
||||
},
|
||||
|
@ -491,15 +513,15 @@ export default {
|
|||
*/
|
||||
initialize() {
|
||||
Promise.all([
|
||||
this.$api.commonAPI.getUsers(),
|
||||
this.$api.commonAPI.getDeptsTree(),
|
||||
this.$api.dictAPI.getDictsByType("qy"),
|
||||
this.$api.dictAPI.getDictsByType("jllx"),
|
||||
this.$api.dictAPI.getDictsByType("dywz")
|
||||
// this.$api.commonAPI.getUsers(),
|
||||
// this.$api.commonAPI.getDeptsTree(),
|
||||
this.$api.dictAPI.getDictsByType("bzfw"),
|
||||
// this.$api.dictAPI.getDictsByType("jllx"),
|
||||
// this.$api.dictAPI.getDictsByType("dywz")
|
||||
])
|
||||
.then(([r1, r2, r3, r4, r5]) => {
|
||||
.then(([r1]) => {
|
||||
if (r1.code === 0) {
|
||||
this.getUserList = r1.datas;
|
||||
this.bzfwList = r1.datas;
|
||||
}
|
||||
if (r2.code === 0) {
|
||||
this.depOptions = r2.data.children;
|
||||
|
|
|
@ -138,16 +138,19 @@
|
|||
</el-tooltip>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="nd" label="浓度" align="center" show-overflow-tooltip></el-table-column>
|
||||
<!-- <el-table-column prop="nd" label="浓度" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jj" align="center" label="径距"></el-table-column>
|
||||
<el-table-column prop="yzx" align="center" label="一致性" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="bbmj" align="center" label="比表面积" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f1" align="center" label="D[3,2]" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f2" align="center" label="D[4,3]" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f3" align="center" label="Dv(10)" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f3" align="center" label="Dv(10)" show-overflow-tooltip></el-table-column> -->
|
||||
<el-table-column prop="f4" align="center" label="Dv(50)" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f5" align="center" label="Dv(90)" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f6" align="center" label="Dv(97)" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f6" align="center" label="Dv(97)" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="bzfw" align="center" label="标准范围" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jcjg" align="center" label="检测结果" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jyjgfx" align="center" label="检验结果分析" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jjfa" align="center" label="解决方案" show-overflow-tooltip></el-table-column>
|
||||
</el-table>
|
||||
|
|
|
@ -0,0 +1,543 @@
|
|||
<template>
|
||||
<!-- 保养计划列表页 -->
|
||||
<div class="sys-box knowledge-box">
|
||||
<div class="sys-operate">
|
||||
<!-- <el-button type="primary" v-has="'jcfx:xz'" @click="add()">新增</el-button>
|
||||
<el-button type="primary" v-has="'jcfx:sc'" @click="remove()" :disabled="btnDelDisabled">删除</el-button> -->
|
||||
<!-- <el-button
|
||||
type="primary"
|
||||
v-has="'upkeep:plan:remove'"
|
||||
@click="reback()"
|
||||
:disabled="btnDelDisabled"
|
||||
>撤回</el-button
|
||||
> -->
|
||||
<!-- <el-button
|
||||
type="primary"
|
||||
v-has="'upkeep:plan:startUsing'"
|
||||
@click="startUsing()"
|
||||
:disabled="btnDelDisabled"
|
||||
>启用</el-button
|
||||
>
|
||||
<el-button
|
||||
type="primary"
|
||||
v-has="'upkeep:plan:forbidden'"
|
||||
@click="forbidden()"
|
||||
:disabled="btnDelDisabled"
|
||||
>禁用</el-button
|
||||
> -->
|
||||
<el-button type="primary" @click="exportExcel()">导出</el-button>
|
||||
</div>
|
||||
<div class="sys-search">
|
||||
<el-form inline class="form_item_search_out">
|
||||
<div class="form_item_input_out">
|
||||
<el-form-item label="客户名称" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.khmc" placeholder="请输入"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="物流公司" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.wlgs" placeholder="请输入"></el-input>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="批号" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.ph" placeholder="批号"></el-input>
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item
|
||||
label="规格型号"
|
||||
style="width:22%"
|
||||
class="form_item-inline"
|
||||
>
|
||||
<el-input
|
||||
v-model="search_data.xh"
|
||||
placeholder="规格型号"
|
||||
></el-input>
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="区域" style="width:22%" class="form_item-inline">
|
||||
<el-select
|
||||
v-model="search_data.qyid"
|
||||
filterable
|
||||
clearable
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in qyList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
label="记录类型"
|
||||
style="width:22%"
|
||||
class="form_item-inline"
|
||||
>
|
||||
<el-select
|
||||
v-model="search_data.jllxid"
|
||||
filterable
|
||||
clearable
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in jllxList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<!-- <btn-input
|
||||
:valueText.sync="search_data.engineerName"
|
||||
:valueId.sync="search_data.engineerId"
|
||||
:chooseVisible.sync="chooseUserVisible"
|
||||
></btn-input>
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="状态" style="width:22%" class="form_item-inline">
|
||||
<el-select v-model="search_data.ztid" clearable placeholder="请选择">
|
||||
<el-option v-for="item in ztList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="配送日期" style="width:34%" class="form_item-inline">
|
||||
<el-date-picker v-model="planTime" type="daterange" range-separator="-" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"></el-date-picker>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<div class="form_item_btn_out">
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="search()">查询</el-button>
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="sys-table">
|
||||
<el-table border @sort-change="sortChange" v-loading="pictLoading" @row-click="clickRow" ref="tb"
|
||||
:data="tableData" @selection-change="handleSelectionChange" :header-cell-style="{
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'center',
|
||||
backgroundColor: '#eceff4',
|
||||
color: '#222'
|
||||
}">
|
||||
<!-- <el-table-column type="selection" width="55" align="center"></el-table-column> -->
|
||||
<!-- <el-table-column prop="jcdh" align="center" width="200" label="检测单号" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-link type="primary" @click="viewDetail(scope.row)">{{
|
||||
scope.row.jcdh
|
||||
}}</el-link>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column prop="psrq" label="配送日期" align="center" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="wlgs" label="物流公司" align="center" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="mdd" align="center" label="目的地" width="220" show-overflow-tooltip></el-table-column>
|
||||
<!-- <el-table-column prop="nd" label="浓度" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jj" align="center" label="径距"></el-table-column>
|
||||
<el-table-column prop="yzx" align="center" label="一致性" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="bbmj" align="center" label="比表面积" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f1" align="center" label="D[3,2]" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f2" align="center" label="D[4,3]" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="f3" align="center" label="Dv(10)" show-overflow-tooltip></el-table-column> -->
|
||||
<el-table-column prop="khmc" align="center" label="客户名称" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="lxr" align="center" label="联系人" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="wldh" align="center" label="物流单号" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="js" align="center" label="件数" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="jjdw" align="center" label="计价单位" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="zl" align="center" label="重量" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="dj" align="center" label="单价" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="je" align="center" label="金额" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="shf" align="center" label="送货费" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="sfk" align="center" label="实付款" width="220" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="hddj" align="center" label="回单单价" width="220" show-overflow-tooltip></el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="sys-pagination">
|
||||
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
|
||||
:current-page="search_data.pageno" :page-sizes="pageSizes" :page-size="search_data.pagesize"
|
||||
layout="total, sizes, prev, pager, next, jumper" :total="total"></el-pagination>
|
||||
</div>
|
||||
<!-- 选择负责人-->
|
||||
<!-- <dialogChooseSingleUser
|
||||
:visible.sync="chooseUserVisible"
|
||||
@change="getUser"
|
||||
></dialogChooseSingleUser> -->
|
||||
<!-- <chooseSbjh :visible.sync="chooseSbjhVisible" /> -->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { formatDateTime } from "@/utils/tools.js";
|
||||
// import btnInput from "@/components/btnInput.vue";
|
||||
// import chooseSbjh from "./components/chooseSbjh.vue";
|
||||
// import dialogChooseSingleUser from "@/components/System/dialogChooseSingleUser";
|
||||
let api = {
|
||||
page: "/apis/mdh/wlps/pageList",
|
||||
del: "/apis/rc/zdhjy/del",
|
||||
edit: "/apis/rc/zdhjy/edit",
|
||||
export:'/apis/mdh/wlps/exportExcel'
|
||||
};
|
||||
export default {
|
||||
name: "xqgl",
|
||||
components: {
|
||||
// btnInput
|
||||
// dialogChooseSingleUser
|
||||
// chooseSbjh
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
ztList: [
|
||||
{
|
||||
name: "未开始",
|
||||
id: 1
|
||||
},
|
||||
{
|
||||
name: "对应中",
|
||||
id: 2
|
||||
},
|
||||
{
|
||||
name: "已完成",
|
||||
id: 3
|
||||
}
|
||||
],
|
||||
qyList: [],
|
||||
total: 0, //总条数
|
||||
pageSizes: [10, 20, 50], //每页展示多少条
|
||||
search_data: {
|
||||
pageno: 1,
|
||||
pagesize: 10
|
||||
},
|
||||
|
||||
planTime: "",
|
||||
|
||||
statusList: [], //计划状态
|
||||
getUserList: [], //用户
|
||||
|
||||
btnDelDisabled: true,
|
||||
btnOtherDisabled: true,
|
||||
chooseUserVisible: false,
|
||||
chooseSbjhVisible: false,
|
||||
rowIds: [],
|
||||
tableData: [],
|
||||
dialogVisible: false,
|
||||
pictLoading: false,
|
||||
qyList: [],
|
||||
jllxList: [],
|
||||
dywzList: []
|
||||
};
|
||||
},
|
||||
created() {
|
||||
var _this = this;
|
||||
document.onkeydown = e => {
|
||||
if (e.key === "Enter") {
|
||||
_this.search();
|
||||
}
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
//let user = JSON.parse(sessionStorage.getItem("userInfo"));
|
||||
//console.log(user);
|
||||
//this.search_data.engineerId = user.userId;
|
||||
this.getList();
|
||||
// this.initData();
|
||||
},
|
||||
methods: {
|
||||
exportExcel(){
|
||||
this.$api.yxkAPI.yxkExport(api.export, {}).then(res=>{
|
||||
if(res.code==0){
|
||||
this.$message.success("导出成功");
|
||||
}
|
||||
})
|
||||
},
|
||||
async reback() {
|
||||
if (this.rowIds.length > 0) {
|
||||
let r = this.rowIds[0];
|
||||
let pass = r.zt == 3 ? true : false;
|
||||
if (pass) {
|
||||
const params = {
|
||||
id: r.id,
|
||||
zt: 2,
|
||||
zczt: 0
|
||||
};
|
||||
const res = await this.$api.yxkAPI.yxkPost(api.edit, params);
|
||||
if (res.code == 0) {
|
||||
this.$message({
|
||||
message: "撤回成功",
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
}
|
||||
} else {
|
||||
this.$message({
|
||||
message: "非已提交状态不能撤回",
|
||||
type: "warning"
|
||||
});
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
this.$message({
|
||||
message: "请选择一条数据",
|
||||
type: "warning"
|
||||
});
|
||||
return false;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取选择的负责人
|
||||
*/
|
||||
getUser(val) {
|
||||
if (val) {
|
||||
this.$set(this.search_data, "engineerName", val.name);
|
||||
this.$set(this.search_data, "engineerId", val.id);
|
||||
} else {
|
||||
this.$set(this.search_data, "engineerName", "");
|
||||
this.$set(this.search_data, "engineerId", "");
|
||||
}
|
||||
},
|
||||
sortChange({ column, prop, order }) {
|
||||
let j = { column, prop, order };
|
||||
let order_ = j.order == "ascending" ? "asc" : "desc";
|
||||
this.$set(this.search_data, "sort", j.prop);
|
||||
this.$set(this.search_data, "order", order_);
|
||||
this.getList();
|
||||
},
|
||||
clickRow(row) {
|
||||
this.$refs.tb.toggleRowSelection(row);
|
||||
},
|
||||
initData() {
|
||||
Promise.all([
|
||||
this.$api.dictAPI.getDictsByType("qy"),
|
||||
this.$api.dictAPI.getDictsByType("jllx"),
|
||||
this.$api.dictAPI.getDictsByType("dywz")
|
||||
])
|
||||
.then(([r1, r2, r3]) => {
|
||||
if (r1.code === 0) {
|
||||
this.qyList = r1.datas;
|
||||
}
|
||||
if (r2.code == 0) {
|
||||
this.jllxList = r2.datas;
|
||||
}
|
||||
if (r3.code == 0) {
|
||||
this.dywzList = r3.datas;
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 获取列表
|
||||
*/
|
||||
getList() {
|
||||
this.pictLoading = true;
|
||||
if (this.planTime) {
|
||||
this.search_data.startTime = formatDateTime(this.planTime[0]);
|
||||
this.search_data.endTime = formatDateTime(this.planTime[1]);
|
||||
} else {
|
||||
this.search_data.startTime = null;
|
||||
this.search_data.endTime = null;
|
||||
}
|
||||
this.$api.yxkAPI
|
||||
.yxkPost(api.page, this.search_data)
|
||||
.then(res => {
|
||||
this.pictLoading = false;
|
||||
if (res.data) {
|
||||
this.total = res.data.total;
|
||||
let result = res.data.records;
|
||||
result.map((el)=>{
|
||||
el.jcwj = el.jcwj?JSON.parse(el.jcwj):null
|
||||
})
|
||||
this.tableData = result;
|
||||
} else {
|
||||
this.total = 0;
|
||||
this.tableData = [];
|
||||
}
|
||||
})
|
||||
.catch(r => {
|
||||
console.log(r);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
search() {
|
||||
this.search_data.pageno = 1;
|
||||
this.getList();
|
||||
},
|
||||
// 上下分页
|
||||
handleCurrentChange(val) {
|
||||
this.search_data.pageno = val;
|
||||
this.getList();
|
||||
},
|
||||
// 每页显示多少条
|
||||
handleSizeChange(val) {
|
||||
this.search_data.pagesize = val;
|
||||
this.getList();
|
||||
},
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
add() {
|
||||
this.$router.push({
|
||||
path: "/khgxgl/jcfx-add",
|
||||
query: {
|
||||
t: Date.now()
|
||||
}
|
||||
});
|
||||
},
|
||||
/**查看明细 */
|
||||
viewDetail(r) {
|
||||
if (r.zt == 2) {
|
||||
this.$router.push({
|
||||
path: "/khgxgl/jcfx-add",
|
||||
query: { id: r.id, t: Date.now() }
|
||||
});
|
||||
} else {
|
||||
this.$router.push({
|
||||
path: "/khgxgl/jcfx-add",
|
||||
query: { id: r.id, t: Date.now() }
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* 保养执行
|
||||
*/
|
||||
execution() {
|
||||
// let id = this.rowIds[0].reventId;
|
||||
// this.$router.push({
|
||||
// path: "/upkeep/record",
|
||||
// query: { id: id }
|
||||
// });
|
||||
},
|
||||
/**
|
||||
* 删除
|
||||
*/
|
||||
remove() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认删除选中的数据吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.yxkAPI
|
||||
.yxkPost(api.del, ids)
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code == 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "删除失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "删除失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 启用
|
||||
*/
|
||||
startUsing() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认启用选中的保养计划吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.upkeepPlanAPI
|
||||
.startUsing({ ids: ids })
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code === 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "启用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "启用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 禁用
|
||||
*/
|
||||
forbidden() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认禁用选中的保养计划吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.upkeepPlanAPI
|
||||
.forbidden({ ids: ids })
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code === 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "禁用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "禁用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 处理选中
|
||||
*/
|
||||
handleSelectionChange(val) {
|
||||
this.rowIds = val;
|
||||
this.setBtn(val);
|
||||
},
|
||||
/**
|
||||
* 控件操作按钮状态
|
||||
*/
|
||||
setBtn(val) {
|
||||
let isFlag = true;
|
||||
let isDelFlag = true;
|
||||
if (val.length > 0) {
|
||||
isDelFlag = false;
|
||||
if (val.length == 1) {
|
||||
isFlag = false;
|
||||
}
|
||||
} else {
|
||||
isFlag = true;
|
||||
isDelFlag = true;
|
||||
}
|
||||
this.btnDelDisabled = isDelFlag;
|
||||
this.btnOtherDisabled = isFlag;
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
|
@ -118,12 +118,12 @@
|
|||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="物流方式" prop="wlfs" class="form-inline">
|
||||
<!-- <el-form-item label="物流方式" prop="wlfs" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.wlfs" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="物流单号" prop="wldh" class="form-inline">
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="物流单号" prop="wldh" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.wldh" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="订单编号" prop="ddbh" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.ddbh" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
|
@ -149,7 +149,53 @@
|
|||
<btn-input :valueText.sync="formData.xsdh" :valueId.sync="formData.xsdhid"
|
||||
:chooseVisible.sync="chooseXsdhVisible"></btn-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="客户合同编号" prop="khhtbh" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.khhtbh" disabled />
|
||||
</el-form-item>
|
||||
<el-form-item label="物流公司" prop="wlgs" class="form-inline">
|
||||
<el-select clearable v-model="formData.wlgsid" @change="
|
||||
el => {
|
||||
formData.wlgs = wlgsList.filter(
|
||||
item => item.id == el
|
||||
)[0].name;
|
||||
}
|
||||
" placeholder="请选择">
|
||||
<el-option v-for="item in wlgsList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="物流方式" prop="wlfs" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.wlfs" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目的地" prop="mdd" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.mdd" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="件数" prop="js" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.js" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="计价单位" prop="jjdw" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.jjdw" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="物流单号" prop="wldh" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.wldh" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="单价" prop="dj" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.dj" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="金额" prop="je" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.je" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="重量" prop="zl" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.zl" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="实付款" prop="mdd" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.sfk" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="回单单价" prop="hddj" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.hddj" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<el-form-item label="送货费" prop="shs" class="form-inline">
|
||||
<el-input style="width:100%" v-model="formData.shf" placeholder="请输入" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="客户名称" prop="khmc" class="form-inline">
|
||||
<btn-input :valueText.sync="formData.khmc" :valueId.sync="formData.khmcid"
|
||||
:chooseVisible.sync="chooseUserVisible"></btn-input>
|
||||
|
@ -274,6 +320,7 @@ export default {
|
|||
chooseFwdhVisible:false,
|
||||
chooseXsdhVisible:false,
|
||||
shlxList: [],
|
||||
wlgsList:[],
|
||||
ztList: [
|
||||
{
|
||||
name: "未开始",
|
||||
|
@ -312,6 +359,9 @@ export default {
|
|||
],
|
||||
dywzid: [
|
||||
{ required: true, message: "请选择对应位置", trigger: "change" }
|
||||
],
|
||||
wlgs: [
|
||||
{ required: true, message: "请选择物流公司", trigger: "change" }
|
||||
],
|
||||
rl: [{ required: true, message: "请输入容量", trigger: "blur" }]
|
||||
},
|
||||
|
@ -403,6 +453,7 @@ export default {
|
|||
getXsdh(val) {
|
||||
this.$set(this.formData, "xsdh", val.code);
|
||||
this.$set(this.formData, "xsdhid", val.id);
|
||||
this.$set(this.formData, "khhtbh", val.clientContractCode);
|
||||
},
|
||||
// 选择生箔卷号
|
||||
getSbjh(val) {
|
||||
|
@ -600,13 +651,18 @@ export default {
|
|||
Promise.all([
|
||||
// this.$api.commonAPI.getUsers(),
|
||||
// this.$api.commonAPI.getDeptsTree(),
|
||||
this.$api.dictAPI.getDictsByType("shlx")
|
||||
this.$api.dictAPI.getDictsByType("shlx"),
|
||||
this.$api.dictAPI.getDictsByType("wlgs")
|
||||
|
||||
// this.$api.dictAPI.getDictsByType("jllx"),
|
||||
// this.$api.dictAPI.getDictsByType("dywz")
|
||||
])
|
||||
.then(([r1]) => {
|
||||
.then(([r1,r2]) => {
|
||||
if (r1.code == 0) {
|
||||
this.shlxList = r1.datas;
|
||||
}
|
||||
if (r2.code == 0) {
|
||||
this.wlgsList = r2.datas;
|
||||
}
|
||||
// if (r2.code === 0) {
|
||||
// this.depOptions = r2.data.children;
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
<template>
|
||||
<div class="sys-login" style="overflow: hidden;">
|
||||
<div class="login-logo" style="display:flex;">
|
||||
<img style="width:50px;height:50px;" src="../../assets/logo_yxk.png" alt />
|
||||
<h2 style="margin-left:10px;color:#fff">江西液压件股份有限公司</h2>
|
||||
<img
|
||||
style="width:50px;height:50px;"
|
||||
src="../../assets/logo_yxk.png"
|
||||
alt
|
||||
/>
|
||||
<h2 style="margin-left:10px;color:#fff">瑞彩科技股份有限公司</h2>
|
||||
<!-- <img src="../../assets/logo1.png" alt /> -->
|
||||
</div>
|
||||
<!-- <div class="login-slogan">
|
||||
|
@ -13,20 +17,41 @@
|
|||
<div class="login-title">登录</div>
|
||||
</el-divider>
|
||||
<div class="form-group1">
|
||||
<el-form :model="loginForm" :rules="loginRules" ref="loginForm" label-position="top" label-width="">
|
||||
<el-form
|
||||
:model="loginForm"
|
||||
:rules="loginRules"
|
||||
ref="loginForm"
|
||||
label-position="top"
|
||||
label-width=""
|
||||
>
|
||||
<el-form-item prop="name">
|
||||
<el-input v-model="loginForm.name" type="text" placeholder="请输入用户名"
|
||||
prefix-icon="iconfont icon-iLinkapp-"></el-input>
|
||||
<el-input
|
||||
v-model="loginForm.name"
|
||||
type="text"
|
||||
placeholder="请输入用户名"
|
||||
prefix-icon="iconfont icon-iLinkapp-"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item prop="password" class="login-psw">
|
||||
<el-input v-model="loginForm.password" type="password" placeholder="请输入密码"
|
||||
@keyup.enter.native="submitForm()" show-password></el-input>
|
||||
<el-input
|
||||
v-model="loginForm.password"
|
||||
type="password"
|
||||
placeholder="请输入密码"
|
||||
@keyup.enter.native="submitForm()"
|
||||
show-password
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item>-->
|
||||
<!-- <el-checkbox v-model="loginForm.auto">自动登录</el-checkbox>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item>
|
||||
<el-button type="primary" ref="loginBtn" class="login-btn" @click="submitForm()">登录</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
ref="loginBtn"
|
||||
class="login-btn"
|
||||
@click="submitForm()"
|
||||
>登录</el-button
|
||||
>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
|
@ -94,35 +119,27 @@ export default {
|
|||
height: 100%;
|
||||
/* background: #fff; */
|
||||
background-image: url(../../assets/bg_login.png);
|
||||
background-position: center center;
|
||||
/* 图片居中 */
|
||||
background-repeat: no-repeat;
|
||||
/* 不重复 */
|
||||
background-size: cover;
|
||||
/* 覆盖整个屏幕 */
|
||||
background-position: center center; /* 图片居中 */
|
||||
background-repeat: no-repeat; /* 不重复 */
|
||||
background-size: cover; /* 覆盖整个屏幕 */
|
||||
/* background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' version='1.1' xmlns:xlink='http://www.w3.org/1999/xlink' xmlns:svgjs='http://svgjs.dev/svgjs' width='1440' height='560' preserveAspectRatio='none' viewBox='0 0 1440 560'%3e%3cg clip-path='url(%26quot%3b%23SvgjsClipPath1041%26quot%3b)' fill='none'%3e%3crect width='1440' height='560' x='0' y='0' fill='%2332325d'%3e%3c/rect%3e%3ccircle r='35.605' cx='185.1' cy='286.35' fill='url(%26quot%3b%23SvgjsLinearGradient1042%26quot%3b)'%3e%3c/circle%3e%3ccircle r='17.8' cx='57.44' cy='151.68' fill='%2343468b'%3e%3c/circle%3e%3ccircle r='27.595' cx='843.22' cy='195.61' fill='url(%26quot%3b%23SvgjsLinearGradient1043%26quot%3b)'%3e%3c/circle%3e%3ccircle r='55.4' cx='79.95' cy='304.45' fill='url(%26quot%3b%23SvgjsLinearGradient1044%26quot%3b)'%3e%3c/circle%3e%3ccircle r='17.2' cx='419.65' cy='331.62' fill='url(%26quot%3b%23SvgjsLinearGradient1045%26quot%3b)'%3e%3c/circle%3e%3ccircle r='33.66' cx='1110.51' cy='176.8' fill='url(%26quot%3b%23SvgjsLinearGradient1046%26quot%3b)'%3e%3c/circle%3e%3ccircle r='24.325' cx='51.8' cy='349.83' fill='url(%26quot%3b%23SvgjsLinearGradient1047%26quot%3b)'%3e%3c/circle%3e%3ccircle r='43.22' cx='693.82' cy='50.84' fill='%2343468b'%3e%3c/circle%3e%3c/g%3e%3cdefs%3e%3cclipPath id='SvgjsClipPath1041'%3e%3crect width='1440' height='560' x='0' y='0'%3e%3c/rect%3e%3c/clipPath%3e%3clinearGradient x1='113.89' y1='286.35' x2='256.31' y2='286.35' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1042'%3e%3cstop stop-color='%23ab3c51' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%234f4484' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient x1='788.03' y1='195.61' x2='898.41' y2='195.61' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1043'%3e%3cstop stop-color='%2384b6e0' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%23464a8f' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient x1='-30.849999999999994' y1='304.45' x2='190.75' y2='304.45' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1044'%3e%3cstop stop-color='%23f29b7c' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%237e6286' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient x1='385.25' y1='331.62' x2='454.05' y2='331.62' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1045'%3e%3cstop stop-color='%23e298de' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%23484687' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient x1='1043.19' y1='176.8' x2='1177.83' y2='176.8' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1046'%3e%3cstop stop-color='%23ab3c51' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%234f4484' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient x1='3.1499999999999986' y1='349.83' x2='100.44999999999999' y2='349.83' gradientUnits='userSpaceOnUse' id='SvgjsLinearGradient1047'%3e%3cstop stop-color='%23f29b7c' offset='0.1'%3e%3c/stop%3e%3cstop stop-color='%237e6286' offset='0.9'%3e%3c/stop%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"); */
|
||||
color: #fff;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.login-logo {
|
||||
padding: 2%;
|
||||
}
|
||||
|
||||
.login-logo img {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.login-logo img:first-child {
|
||||
width: 10%;
|
||||
max-width: 97px;
|
||||
}
|
||||
|
||||
.login-logo img:last-child {
|
||||
width: 18%;
|
||||
max-width: 294px;
|
||||
}
|
||||
|
||||
/* .login-logo span {
|
||||
margin: 0px 1%;
|
||||
display: inline-block;
|
||||
|
@ -147,7 +164,6 @@ export default {
|
|||
word-break: break-all;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* 打印效果 */
|
||||
@keyframes login-slogan {
|
||||
from {
|
||||
|
@ -161,7 +177,6 @@ export default {
|
|||
|
||||
/* 光标 */
|
||||
@keyframes blink-caret {
|
||||
|
||||
from,
|
||||
to {
|
||||
border-color: transparent;
|
||||
|
@ -171,7 +186,6 @@ export default {
|
|||
border-color: currentColor;
|
||||
}
|
||||
}
|
||||
|
||||
.login-area {
|
||||
position: fixed;
|
||||
right: 6%;
|
||||
|
@ -194,7 +208,6 @@ export default {
|
|||
/* background-image: linear-gradient(to top, #4481eb 0%, #04befe 100%); */
|
||||
padding: 90px 60px;
|
||||
}
|
||||
|
||||
.login-divider {
|
||||
position: absolute !important;
|
||||
top: 10px;
|
||||
|
@ -202,7 +215,6 @@ export default {
|
|||
right: 0px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.login-title {
|
||||
/* position: absolute;
|
||||
top: 10px;
|
||||
|
@ -212,7 +224,6 @@ export default {
|
|||
font-size: 18px;
|
||||
color: #3d69e1;
|
||||
}
|
||||
|
||||
.login-area input.el-input__inner {
|
||||
margin-bottom: 5px;
|
||||
padding-left: 45px;
|
||||
|
@ -222,26 +233,21 @@ export default {
|
|||
color: #2591ed;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
.login-area input.el-input__inner::placeholder {
|
||||
color: #2591ed;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
.login-area .el-input__icon {
|
||||
padding-left: 10px;
|
||||
color: #2591ed;
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
.login-area .el-checkbox {
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.login-psw {
|
||||
margin: 20px 0 !important;
|
||||
}
|
||||
|
||||
.login-btn {
|
||||
width: 100%;
|
||||
font-size: 16px !important;
|
||||
|
@ -250,7 +256,6 @@ export default {
|
|||
background: #3d69e1;
|
||||
margin-top: 50px !important;
|
||||
}
|
||||
|
||||
.login-btn:hover {
|
||||
background: #3457b2 !important;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,557 @@
|
|||
<template>
|
||||
<div class="sys-box plan-box">
|
||||
<div class="sys-operate">
|
||||
<el-button type="primary" @click="back()">{{
|
||||
config.cancelText
|
||||
}}</el-button>
|
||||
<el-button type="primary" @click="save('form')" :disabled="isDisabled"
|
||||
>提交</el-button
|
||||
>
|
||||
</div>
|
||||
<div class="sys-form">
|
||||
<el-form
|
||||
v-loading="loading"
|
||||
label-width="120px"
|
||||
:model="formData"
|
||||
ref="form"
|
||||
:rules="ruleForm"
|
||||
>
|
||||
<div class="flex">
|
||||
<el-form-item label="月份" prop="rq" class="form-inline">
|
||||
<el-date-picker
|
||||
readonly
|
||||
v-model="formData.rq"
|
||||
format="yyyy-MM"
|
||||
value-format="yyyy-MM"
|
||||
type="month"
|
||||
clearable
|
||||
placeholder="选择月份"
|
||||
></el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="产能" prop="cn" class="form-inline">
|
||||
<el-input
|
||||
readonly
|
||||
style="width:100%"
|
||||
placeholder="产能"
|
||||
v-model="formData.cn"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="比例" prop="bl" class="form-inline">
|
||||
<el-input-number
|
||||
style="width:100%"
|
||||
placeholder="比例"
|
||||
v-model="formData.bl"
|
||||
/>
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { formatDateTime } from "@/utils/tools.js";
|
||||
import btnInput from "@/components/btnInput.vue";
|
||||
// import ChooseParts from "../../../components/System/dialogChooseParts";
|
||||
import { mapState, mapActions, mapGetters, mapMutations } from "vuex";
|
||||
import config from "@/utils/config.js";
|
||||
let api = {
|
||||
add: "/apis/hl/nygl/addOrUpdateBl",
|
||||
detail: "/apis/hl/nygl/dnh/detail",
|
||||
edit: "/apis/hl/nygl/dnh/edit"
|
||||
};
|
||||
export default {
|
||||
name: "ydnhtj-add",
|
||||
components: {
|
||||
btnInput
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
depOptions: [],
|
||||
selectDeptId: [],
|
||||
formData: {},
|
||||
start_datetime: {
|
||||
disabledDate: time => {
|
||||
return time.getTime() < Date.now();
|
||||
}
|
||||
},
|
||||
end_datetime: {
|
||||
disabledDate: time => {
|
||||
return time.getTime() < Date.now();
|
||||
}
|
||||
},
|
||||
ruleForm: {
|
||||
date: [{ required: true, message: "请选择月份", trigger: "change" }],
|
||||
val: [{ required: true, message: "请输入电能耗", trigger: "blur" }],
|
||||
deviceName: [
|
||||
{ required: true, message: "请选择设备", trigger: "change" }
|
||||
],
|
||||
startTime: [
|
||||
{ required: true, message: "请选择计划开始时间", trigger: "change" }
|
||||
],
|
||||
endTime: [
|
||||
{ required: true, message: "请选择计划完成时间", trigger: "change" }
|
||||
],
|
||||
expireday: [
|
||||
{ required: true, message: "请填写提醒天数", trigger: "blur" }
|
||||
],
|
||||
intervalTime: [
|
||||
{ required: true, message: "请填写间隔天数", trigger: "blur" }
|
||||
],
|
||||
type: [{ required: true, message: "请选择保养级别", trigger: "change" }]
|
||||
},
|
||||
chooseMaterielVisible: false,
|
||||
chooseDevicesVisible: false,
|
||||
chooseUserVisible: false,
|
||||
getUserList: [], //用户
|
||||
levelList: [], //任务等级
|
||||
tableData: [],
|
||||
deptList: [], //部门集合
|
||||
chooseVisible: false,
|
||||
projects: [], //项目
|
||||
chooseProjects: [],
|
||||
choosePartsVisible: false,
|
||||
parts: [], //项目
|
||||
choosePartss: [],
|
||||
loading: false,
|
||||
isDisabled: false,
|
||||
config: config
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
// this.initialize();
|
||||
if (this.$route.query.info) {
|
||||
this.formData = JSON.parse(this.$route.query.info);
|
||||
// this.getDetail();
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
formData: {
|
||||
handler(newVal, oldVal) {
|
||||
if (newVal.deviceId == "") {
|
||||
this.formData.deviceModel = "";
|
||||
this.formData.deviceUser = "";
|
||||
this.formData.deviceSite = "";
|
||||
this.formData.deviceDept = "";
|
||||
this.formData.deviceName = "";
|
||||
}
|
||||
if (newVal.engineerId == "") {
|
||||
this.formData.engineerName = "";
|
||||
this.formData.cellphone = "";
|
||||
(this.formData.deptId = ""), (this.selectDeptId = []);
|
||||
}
|
||||
},
|
||||
deep: true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
...mapMutations({
|
||||
removeTagNav: "tagNav/removeTagNav"
|
||||
}),
|
||||
/**
|
||||
* 选择产品
|
||||
*/
|
||||
getPart(val) {
|
||||
if (val) {
|
||||
if (val.convCoefficient && this.formData.countSupport) {
|
||||
this.formData.count =
|
||||
this.formData.countSupport * val.convCoefficient;
|
||||
}
|
||||
this.$set(this.formData, "materielId", val.id);
|
||||
this.$set(this.formData, "materielName", val.name ? val.name : "");
|
||||
this.$set(
|
||||
this.formData,
|
||||
"materielSerialNo",
|
||||
val.serialNo ? val.serialNo : ""
|
||||
);
|
||||
this.$set(
|
||||
this.formData,
|
||||
"specification",
|
||||
val.specification ? val.specification : ""
|
||||
);
|
||||
this.$set(
|
||||
this.formData,
|
||||
"unitUomName",
|
||||
val.unitUomName ? val.unitUomName : ""
|
||||
);
|
||||
this.formData.supportUomName = val.supportUomName
|
||||
? val.supportUomName
|
||||
: "";
|
||||
this.formData.supportUom = val.supportUom;
|
||||
this.formData.convCoefficient = val.convCoefficient;
|
||||
} else {
|
||||
this.$set(this.formData, "materielId", "");
|
||||
this.$set(this.formData, "materielName", "");
|
||||
this.$set(this.formData, "materielSerialNo", "");
|
||||
this.$set(this.formData, "specification", "");
|
||||
this.$set(this.formData, "unitUomName", "");
|
||||
}
|
||||
},
|
||||
setTotal(scope) {
|
||||
if (scope.num && scope.salePrice) {
|
||||
return parseFloat(scope.num) * parseFloat(scope.salePrice);
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
},
|
||||
//根据当前id,获取一条树枝上的所有id数据
|
||||
treeFindPath(tree, func, path = []) {
|
||||
if (!tree) return [];
|
||||
for (const data of tree) {
|
||||
path.push(data.id);
|
||||
if (func(data)) return path;
|
||||
if (data.children) {
|
||||
const findChildren = this.treeFindPath(data.children, func, path);
|
||||
if (findChildren.length) return findChildren;
|
||||
}
|
||||
path.pop();
|
||||
}
|
||||
return [];
|
||||
},
|
||||
//当选择器选项没有下一级时,将children设置为undefined,就能选则该项了
|
||||
setDeptList(tree) {
|
||||
for (const data of tree) {
|
||||
if (!data.hasChildren) {
|
||||
data.children = undefined;
|
||||
} else {
|
||||
this.setDeptList(data.children);
|
||||
}
|
||||
}
|
||||
},
|
||||
// 选择部门
|
||||
handleChange: function(value) {
|
||||
this.formData.deptId = value.length >= 1 ? value[value.length - 1] : "";
|
||||
this.selectDeptId = value;
|
||||
},
|
||||
/**
|
||||
* 获取选择的设备
|
||||
*/
|
||||
getDevice(data) {
|
||||
if (data) {
|
||||
this.formData.deviceId = data.id;
|
||||
this.formData.deviceModel = data.model;
|
||||
this.formData.deviceUser = data.userName;
|
||||
this.formData.deviceSite = data.site;
|
||||
this.formData.deviceDept = data.deptName;
|
||||
this.formData.deviceName = data.name;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取用户
|
||||
*/
|
||||
getUser(data) {
|
||||
var self = this;
|
||||
if (data) {
|
||||
this.$set(this.formData, "engineerId", data.id);
|
||||
this.$set(this.formData, "engineerName", data.name);
|
||||
this.$set(this.formData, "cellphone", data.mobile);
|
||||
this.getUserList.forEach(item => {
|
||||
if (data.id === item.id) {
|
||||
self.formData.selectDeptId = item.deptId;
|
||||
self.formData.deptId = item.deptId;
|
||||
return;
|
||||
}
|
||||
});
|
||||
// if (self.formData.deptId == 0) {
|
||||
// self.formData.selectDeptId = "";
|
||||
// }
|
||||
this.setDefaultDept();
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取选择的项目
|
||||
*/
|
||||
getProject(val) {
|
||||
if (val) {
|
||||
val.forEach(p => {
|
||||
this.projects.push(p);
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 移除选择的项目
|
||||
*/
|
||||
removeProject() {
|
||||
if (this.chooseProjects) {
|
||||
this.chooseProjects.forEach(p => {
|
||||
var index = this.projects.findIndex(item => {
|
||||
if (item.id == p.id) {
|
||||
return true;
|
||||
}
|
||||
});
|
||||
this.projects.splice(index, 1);
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 处理选择
|
||||
*/
|
||||
handleProjectChange(val) {
|
||||
this.chooseProjects = val;
|
||||
},
|
||||
|
||||
/**
|
||||
* 获取选择的备件
|
||||
*/
|
||||
getPart(val) {
|
||||
if (val) {
|
||||
val.forEach(p => {
|
||||
// p.num=1;
|
||||
this.parts.push(p);
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 移除选择的项目
|
||||
*/
|
||||
removePart() {
|
||||
if (this.chooseParts) {
|
||||
this.chooseParts.forEach(p => {
|
||||
var index = this.parts.findIndex(item => {
|
||||
if (item.id == p.id) {
|
||||
return true;
|
||||
}
|
||||
});
|
||||
this.parts.splice(index, 1);
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 处理选择
|
||||
*/
|
||||
handlePartChange(val) {
|
||||
this.chooseParts = val;
|
||||
},
|
||||
/**
|
||||
* 初始化数据
|
||||
*/
|
||||
initialize() {
|
||||
Promise.all([
|
||||
this.$api.commonAPI.getUsers(),
|
||||
this.$api.commonAPI.getDeptsTree(),
|
||||
this.$api.dictAPI.getDictsByType("device_upkeep")
|
||||
])
|
||||
.then(([r1, r2, r3]) => {
|
||||
if (r1.code === 0) {
|
||||
this.getUserList = r1.datas;
|
||||
}
|
||||
if (r2.code === 0) {
|
||||
this.depOptions = r2.data.children;
|
||||
this.setDeptList(this.depOptions);
|
||||
this.setDefaultDept();
|
||||
// this.deptList = r2.datas;
|
||||
}
|
||||
if (r3.code === 0) {
|
||||
this.levelList = r3.datas;
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 取消方法
|
||||
*/
|
||||
back() {
|
||||
this.removeTagNav({
|
||||
path: this.$route.path,
|
||||
title: this.$route.meta.name
|
||||
});
|
||||
this.$router.push({ path: "/nygl/ycntj", query: { t: Date.now() } });
|
||||
},
|
||||
/**
|
||||
* 获取计划明细
|
||||
*/
|
||||
getDetail() {
|
||||
this.loading = true;
|
||||
this.$api.yxkAPI
|
||||
.yxkGet(api.detail, { id: this.formData.id })
|
||||
.then(res => {
|
||||
if (res.code == 0) {
|
||||
this.formData = { ...res.data };
|
||||
//this.formData = Object.assign({}, this.formData.planMsg);
|
||||
}
|
||||
this.loading = false;
|
||||
})
|
||||
.catch(res => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
//显示默认部门
|
||||
setDefaultDept() {
|
||||
if (this.depOptions.length > 0 && this.formData.selectDeptId) {
|
||||
let id = JSON.stringify(this.formData.selectDeptId);
|
||||
let select_id = this.treeFindPath(
|
||||
this.depOptions,
|
||||
data => data.id === id
|
||||
);
|
||||
this.selectDeptId = JSON.parse(JSON.stringify(select_id));
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 暂存
|
||||
*/
|
||||
tempSave(form) {
|
||||
this.$refs[form].validate(valid => {
|
||||
if (valid) {
|
||||
const diff =
|
||||
new Date(this.formData.endTime).getTime() -
|
||||
new Date(this.formData.startTime).getTime();
|
||||
if (diff < 0) {
|
||||
this.$alert("计划完成时间必须大于计划开始时间!", "提示", {
|
||||
confirmButtonText: "知道啦"
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.projects.length == 0) {
|
||||
this.$message({
|
||||
message: "请至少选择一项保养项目",
|
||||
type: "error"
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (this.projects) {
|
||||
let projectIDs = "";
|
||||
this.projects.forEach(p => {
|
||||
projectIDs += p.id + ",";
|
||||
});
|
||||
projectIDs =
|
||||
projectIDs.substring(projectIDs.length - 1) == ","
|
||||
? projectIDs.substring(0, projectIDs.length - 1)
|
||||
: projectIDs;
|
||||
|
||||
this.formData.projectIds = projectIDs;
|
||||
}
|
||||
if (this.parts) {
|
||||
let parstids = [];
|
||||
this.parts.forEach(p => {
|
||||
p.salePrice = p.salePrice ? p.salePrice : 0;
|
||||
let inum = parseInt(p.num) ? parseInt(p.num) : 0;
|
||||
let spartSum = inum * p.salePrice;
|
||||
let obj = {
|
||||
partId: p.id,
|
||||
amount: inum,
|
||||
remark: p.remark,
|
||||
spartPrice: p.salePrice,
|
||||
spartSum: spartSum
|
||||
};
|
||||
parstids.push(obj);
|
||||
});
|
||||
let parstid = { dataList: parstids };
|
||||
this.formData.partIdArray = JSON.stringify(parstid);
|
||||
}
|
||||
if (this.isDisabled) {
|
||||
return;
|
||||
}
|
||||
this.isDisabled = true;
|
||||
this.$api.upkeepPlanAPI
|
||||
.newPlanAndChangePlan(this.formData)
|
||||
.then(res => {
|
||||
this.isDisabled = false;
|
||||
if (res.code === 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.back();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
save(form) {
|
||||
this.$refs[form].validate(valid => {
|
||||
if (valid) {
|
||||
this.isDisabled = true;
|
||||
this.$api.yxkAPI
|
||||
.yxkPost(this.formData.id ? api.edit : api.add, this.formData)
|
||||
.then(res => {
|
||||
this.isDisabled = false;
|
||||
if (res.code == 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.back();
|
||||
} else {
|
||||
// this.$message({
|
||||
// message: res.msg,
|
||||
// type: "error"
|
||||
// });
|
||||
}
|
||||
});
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.flex {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
.sys-form {
|
||||
padding: 20px 20px 20px 20px;
|
||||
}
|
||||
.sys-form .form-inline {
|
||||
width: 33.33%;
|
||||
}
|
||||
.sys-form .form-line {
|
||||
width: 66.66%;
|
||||
}
|
||||
.sys-form .form-half {
|
||||
width: 50%;
|
||||
}
|
||||
.sys-form .form-inline .el-input,
|
||||
.sys-form .form-inline .el-select .el-input {
|
||||
width: 100%;
|
||||
}
|
||||
.sys-form .form-short .el-input,
|
||||
.sys-form .form-short .el-select .el-input {
|
||||
margin-right: 5px;
|
||||
width: 60% !important;
|
||||
}
|
||||
.icon-luyin {
|
||||
color: #2589ee;
|
||||
font-size: 24px;
|
||||
cursor: pointer;
|
||||
}
|
||||
.form-ts {
|
||||
padding-left: 20px;
|
||||
color: #aaa;
|
||||
display: inline-block;
|
||||
}
|
||||
.el-form-item__content .sys-operate {
|
||||
padding: 10px 0px;
|
||||
}
|
||||
</style>
|
||||
<style>
|
||||
.el-cascader .el-input {
|
||||
width: 100% !important;
|
||||
}
|
||||
.plan-box .sys-form .form-inline .el-select,
|
||||
.plan-box .sys-form .form-inline .el-select .el-input {
|
||||
width: 100%;
|
||||
}
|
||||
.plan-box .el-table thead {
|
||||
line-height: 1;
|
||||
}
|
||||
.el-input {
|
||||
width: 100% !important;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,531 @@
|
|||
<template>
|
||||
<!-- 保养计划列表页 -->
|
||||
<div class="sys-box knowledge-box">
|
||||
<div class="sys-operate">
|
||||
<!-- <el-button type="primary" v-has="'upkeep:plan:add'" @click="add()"
|
||||
>新增</el-button
|
||||
> -->
|
||||
<!-- <el-button
|
||||
type="primary"
|
||||
v-has="'upkeep:plan:remove'"
|
||||
@click="remove()"
|
||||
:disabled="btnDelDisabled"
|
||||
>删除</el-button
|
||||
>
|
||||
<el-button
|
||||
type="primary"
|
||||
v-has="'upkeep:plan:remove'"
|
||||
@click="reback()"
|
||||
:disabled="btnDelDisabled"
|
||||
>撤回</el-button
|
||||
> -->
|
||||
</div>
|
||||
<div class="sys-search">
|
||||
<el-form inline class="form_item_search_out">
|
||||
<div class="form_item_input_out">
|
||||
<el-form-item label="设备名称" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.sbmc" placeholder="设备名称"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="负责人" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.fzr" placeholder="负责人"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="使用部门" style="width:22%" class="form_item-inline">
|
||||
<el-input v-model="search_data.sybm" placeholder="设备部门"></el-input>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="状态" style="width:22%" class="form_item-inline">
|
||||
<el-select v-model="search_data.zt" clearable placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in statusList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="日期" style="width:34%" class="form_item-inline">
|
||||
<el-date-picker v-model="planTime" type="daterange" range-separator="-" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"></el-date-picker>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<div class="form_item_btn_out">
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="search()">查询</el-button>
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="sys-table">
|
||||
<el-table border @sort-change="sortChange" v-loading="pictLoading" @row-click="clickRow" ref="tb"
|
||||
:data="tableData" @selection-change="handleSelectionChange" :header-cell-style="{
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'center',
|
||||
backgroundColor: '#eceff4',
|
||||
color: '#222'
|
||||
}">
|
||||
<el-table-column prop="sbbh" label="设备编号" width="220" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="sbmc" align="center" width="220" label="设备名称" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="ggxh" align="center" width="220" label="规格型号" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="sblx" align="center" width="220" label="设备类型" show-overflow-tooltip />
|
||||
<el-table-column prop="sbkdl" align="center" width="220" label="设备开动率(%)" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-link @click="hanldKdl(scope.row)">{{ scope.row.kdl }}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="yxsc" align="center" width="220" label="运行时长(min)" show-overflow-tooltip />
|
||||
<el-table-column prop="gzsc" align="center" width="220" label="故障时长(h)" show-overflow-tooltip />
|
||||
<el-table-column prop="tjsc" align="center" width="220" label="停机时长(h)" show-overflow-tooltip />
|
||||
<el-table-column prop="bysc" align="center" width="220" label="保养时长(h)" show-overflow-tooltip />
|
||||
<el-table-column prop="ljgzcs" align="center" width="220" label="累计故障次数" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-link @click="toLink(scope.row, '/repair/index')">{{
|
||||
scope.row.ljgzcs
|
||||
}}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="xjcs" align="center" width="220" label="巡检次数" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-link @click="toLink(scope.row, '/inspection/daily')">{{
|
||||
scope.row.xjcs
|
||||
}}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="ljbycs" align="center" width="220" label="累计保养次数" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-link @click="toLink(scope.row, '/upkeep/execution')">{{
|
||||
scope.row.ljbycs
|
||||
}}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="syzk" align="center" width="220" label="使用状况" show-overflow-tooltip />
|
||||
<el-table-column prop="azdd" align="center" width="220" label="安装地点" show-overflow-tooltip />
|
||||
<el-table-column prop="sybm" align="center" width="220" label="使用部门" show-overflow-tooltip />
|
||||
<el-table-column prop="fzr" align="center" width="220" label="负责人" show-overflow-tooltip />
|
||||
<el-table-column prop="gzsj" align="center" width="220" label="购置时间" show-overflow-tooltip />
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="sys-pagination">
|
||||
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
|
||||
:current-page="search_data.pageno" :page-sizes="pageSizes" :page-size="search_data.pagesize"
|
||||
layout="total, sizes, prev, pager, next, jumper" :total="total"></el-pagination>
|
||||
</div>
|
||||
<el-dialog title="设备开动率" :visible.sync="dialogVisible" width="60%">
|
||||
<div class="sys-search">
|
||||
<el-form inline class="form_item_search_out">
|
||||
<div class="form_item_input_out">
|
||||
<el-form-item label="日期" style="width:34%" class="form_item-inline">
|
||||
<el-date-picker v-model="time" type="daterange" range-separator="-" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"></el-date-picker>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<div class="form_item_btn_out">
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="hanldKdl(kdlInfo)">查询</el-button>
|
||||
<el-button type="primary" @click="dialogVisible = false">返回</el-button>
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="sys-table">
|
||||
<el-table border :data="kdlData" height="50vh" :header-cell-style="{
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'center',
|
||||
backgroundColor: '#eceff4',
|
||||
color: '#222'
|
||||
}">
|
||||
<el-table-column prop="sbbh" label="设备编号" align="center" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="sbmc" align="center" label="设备名称" show-overflow-tooltip></el-table-column>
|
||||
<el-table-column prop="kdl" align="center" label="开动率" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.kdl }}%</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getTimeToDate } from "@/utils/tools.js";
|
||||
let api = {
|
||||
page: "/apis/qx/kanban/sbfxbb",
|
||||
del: "/apis/mdh/hcl/del",
|
||||
edit: "/apis/mdh/hcl/edit"
|
||||
};
|
||||
export default {
|
||||
name: "sbfxbb",
|
||||
data() {
|
||||
return {
|
||||
total: 0, //总条数
|
||||
pageSizes: [10, 20, 50], //每页展示多少条
|
||||
search_data: {
|
||||
pageno: 1,
|
||||
pagesize: 10
|
||||
},
|
||||
planTime: "",
|
||||
time: "",
|
||||
statusList: [], //计划状态
|
||||
getUserList: [], //用户
|
||||
|
||||
btnDelDisabled: true,
|
||||
btnOtherDisabled: true,
|
||||
chooseUserVisible: false,
|
||||
chooseSbjhVisible: false,
|
||||
rowIds: [],
|
||||
tableData: [],
|
||||
dialogVisible: false,
|
||||
pictLoading: false,
|
||||
kdlData: [],
|
||||
kdlInfo: {}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
var _this = this;
|
||||
document.onkeydown = e => {
|
||||
if (e.key === "Enter") {
|
||||
_this.search();
|
||||
}
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
//let user = JSON.parse(sessionStorage.getItem("userInfo"));
|
||||
//console.log(user);
|
||||
//this.search_data.engineerId = user.userId;
|
||||
this.getList();
|
||||
// this.initData();
|
||||
},
|
||||
methods: {
|
||||
toLink(val, url) {
|
||||
if (url == "/repair/index") {
|
||||
this.$router.push({
|
||||
path: url,
|
||||
query: { id: val.id, activeName: "four", sbmc: val.sbmc }
|
||||
});
|
||||
}
|
||||
if (url == "/inspection/daily") {
|
||||
this.$router.push({
|
||||
path: url,
|
||||
query: { id: val.id, activeName: "three", sbmc: val.sbmc }
|
||||
});
|
||||
}
|
||||
if (url == "/upkeep/execution") {
|
||||
this.$router.push({
|
||||
path: url,
|
||||
query: { id: val.id, activeName: "three", sbmc: val.sbmc }
|
||||
});
|
||||
}
|
||||
},
|
||||
async hanldKdl(val) {
|
||||
this.kdlInfo = val;
|
||||
const { deviceId } = val;
|
||||
let kssj;
|
||||
let jssj;
|
||||
if (this.time) {
|
||||
kssj = getTimeToDate(this.time[0]);
|
||||
jssj = getTimeToDate(this.time[1]);
|
||||
} else {
|
||||
kssj = null;
|
||||
jssj = null;
|
||||
}
|
||||
const params = {
|
||||
sbid: deviceId,
|
||||
kssj: kssj,
|
||||
jssj: jssj
|
||||
};
|
||||
const res = await this.$api.yxkAPI.yxkPost(
|
||||
"/apis/qx/kanban/sbkdl",
|
||||
params
|
||||
);
|
||||
this.kdlData = res.data.records;
|
||||
this.dialogVisible = true;
|
||||
},
|
||||
async reback() {
|
||||
if (this.rowIds.length > 0) {
|
||||
let r = this.rowIds[0];
|
||||
let pass = r.zt == 3 ? true : false;
|
||||
if (pass) {
|
||||
const params = {
|
||||
id: r.id,
|
||||
zt: 2,
|
||||
zczt: 0
|
||||
};
|
||||
const res = await this.$api.yxkAPI.yxkPost(api.edit, params);
|
||||
if (res.code == 0) {
|
||||
this.$message({
|
||||
message: "撤回成功",
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
}
|
||||
} else {
|
||||
this.$message({
|
||||
message: "非已提交状态不能撤回",
|
||||
type: "warning"
|
||||
});
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
this.$message({
|
||||
message: "请选择一条数据",
|
||||
type: "warning"
|
||||
});
|
||||
return false;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取选择的负责人
|
||||
*/
|
||||
getUser(val) {
|
||||
if (val) {
|
||||
this.$set(this.search_data, "engineerName", val.name);
|
||||
this.$set(this.search_data, "engineerId", val.id);
|
||||
} else {
|
||||
this.$set(this.search_data, "engineerName", "");
|
||||
this.$set(this.search_data, "engineerId", "");
|
||||
}
|
||||
},
|
||||
sortChange({ column, prop, order }) {
|
||||
let j = { column, prop, order };
|
||||
let order_ = j.order == "ascending" ? "asc" : "desc";
|
||||
this.$set(this.search_data, "sort", j.prop);
|
||||
this.$set(this.search_data, "order", order_);
|
||||
this.getList();
|
||||
},
|
||||
clickRow(row) {
|
||||
this.$refs.tb.toggleRowSelection(row);
|
||||
},
|
||||
initData() {
|
||||
Promise.all([
|
||||
this.$api.commonAPI.getUsers(),
|
||||
this.$api.dictAPI.getDictsByType("plan_status")
|
||||
])
|
||||
.then(([r1, r2]) => {
|
||||
if (r1.code === 0) {
|
||||
this.getUserList = r1.datas;
|
||||
}
|
||||
if (r2.code === 0) {
|
||||
this.statusList = r2.datas;
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 获取列表
|
||||
*/
|
||||
getList() {
|
||||
this.pictLoading = true;
|
||||
if (this.planTime) {
|
||||
this.search_data.kssj = getTimeToDate(this.planTime[0]);
|
||||
this.search_data.jssj = getTimeToDate(this.planTime[1]);
|
||||
} else {
|
||||
this.search_data.kssj = null;
|
||||
this.search_data.jssj = null;
|
||||
}
|
||||
this.$api.yxkAPI
|
||||
.yxkPost(api.page, this.search_data)
|
||||
.then(res => {
|
||||
this.pictLoading = false;
|
||||
if (res.data) {
|
||||
this.total = res.data.total;
|
||||
let result = res.data.records;
|
||||
this.tableData = result;
|
||||
} else {
|
||||
this.total = 0;
|
||||
this.tableData = [];
|
||||
}
|
||||
})
|
||||
.catch(r => {
|
||||
console.log(r);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
search() {
|
||||
this.search_data.pageno = 1;
|
||||
this.getList();
|
||||
},
|
||||
// 上下分页
|
||||
handleCurrentChange(val) {
|
||||
this.search_data.pageno = val;
|
||||
this.getList();
|
||||
},
|
||||
// 每页显示多少条
|
||||
handleSizeChange(val) {
|
||||
this.search_data.pagesize = val;
|
||||
this.getList();
|
||||
},
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
add() {
|
||||
this.$router.push({
|
||||
path: "/nygl/ycntj-add",
|
||||
query: {
|
||||
t: Date.now()
|
||||
}
|
||||
});
|
||||
},
|
||||
/**查看明细 */
|
||||
viewDetail(r) {
|
||||
// if (r.zczt === 0) {
|
||||
// this.$router.push({
|
||||
// path: "/basic/hclbg-add",
|
||||
// query: { id: r.id, t: Date.now() }
|
||||
// });
|
||||
// } else {
|
||||
this.$router.push({
|
||||
path: "/nygl/ycntj-add",
|
||||
query: { info: JSON.stringify(r), t: Date.now() }
|
||||
});
|
||||
// }
|
||||
},
|
||||
|
||||
/**
|
||||
* 保养执行
|
||||
*/
|
||||
execution() {
|
||||
// let id = this.rowIds[0].reventId;
|
||||
// this.$router.push({
|
||||
// path: "/upkeep/record",
|
||||
// query: { id: id }
|
||||
// });
|
||||
},
|
||||
/**
|
||||
* 删除
|
||||
*/
|
||||
remove() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认删除选中的数据吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.yxkAPI
|
||||
.yxkPost(api.del, ids)
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code == 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "删除失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "删除失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 启用
|
||||
*/
|
||||
startUsing() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认启用选中的保养计划吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.upkeepPlanAPI
|
||||
.startUsing({ ids: ids })
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code === 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "启用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "启用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 禁用
|
||||
*/
|
||||
forbidden() {
|
||||
let ids = [];
|
||||
this.rowIds.forEach(item => {
|
||||
ids.push(item.id);
|
||||
});
|
||||
this.$confirm("确认禁用选中的保养计划吗?", "提示", {
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$api.upkeepPlanAPI
|
||||
.forbidden({ ids: ids })
|
||||
.then(res => {
|
||||
console.log(res);
|
||||
if (res.code === 0) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success"
|
||||
});
|
||||
this.getList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: res.msg ? res.msg : "禁用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message({
|
||||
message: "禁用失败,请重试",
|
||||
type: "error"
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 处理选中
|
||||
*/
|
||||
handleSelectionChange(val) {
|
||||
this.rowIds = val;
|
||||
this.setBtn(val);
|
||||
},
|
||||
/**
|
||||
* 控件操作按钮状态
|
||||
*/
|
||||
setBtn(val) {
|
||||
let isFlag = true;
|
||||
let isDelFlag = true;
|
||||
if (val.length > 0) {
|
||||
isDelFlag = false;
|
||||
if (val.length == 1) {
|
||||
isFlag = false;
|
||||
}
|
||||
} else {
|
||||
isFlag = true;
|
||||
isDelFlag = true;
|
||||
}
|
||||
this.btnDelDisabled = isDelFlag;
|
||||
this.btnOtherDisabled = isFlag;
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
|
@ -118,12 +118,12 @@ export default {
|
|||
{ label: "样品名称", value: "ypmc",width:"200" },
|
||||
{ label: "批号", value: "ph",width:"200" },
|
||||
{ label: "检测结果", value: "jcjg",width:"200" },
|
||||
{ label: "浓度", value: "nd",width:"200" },
|
||||
{ label: "径距", value: "jj",width:"200" },
|
||||
{ label: "一致性", value: "yzx",width:"200"},
|
||||
{ label: "比表面积", value: "bbmj",width:"200" },
|
||||
{ label: "D[3,2]", value: "f1",width:"200",isState:true },
|
||||
{ label: "D[4,3]", value: "f2",width:"200",isState:true },
|
||||
// { label: "浓度", value: "nd",width:"200" },
|
||||
// { label: "径距", value: "jj",width:"200" },
|
||||
// { label: "一致性", value: "yzx",width:"200"},
|
||||
// { label: "比表面积", value: "bbmj",width:"200" },
|
||||
// { label: "D[3,2]", value: "f1",width:"200",isState:true },
|
||||
// { label: "D[4,3]", value: "f2",width:"200",isState:true },
|
||||
{ label: "Dv(10)", value: "f3",width:"200",isState:true },
|
||||
{ label: "Dv(50)", value: "f4",width:"200",isState:true },
|
||||
{ label: "Dv(90)", value: "f5",width:"200",isState:true },
|
||||
|
|
|
@ -4611,6 +4611,17 @@ const staticRoute = [
|
|||
/* webpackChunkName: 'equipment' */ "../pages/khgxgl/shgl/detail.vue"
|
||||
)
|
||||
},
|
||||
{
|
||||
path: "wlbb",
|
||||
name: "wlbb",
|
||||
meta: {
|
||||
name: "物流报表"
|
||||
},
|
||||
component: () =>
|
||||
import(
|
||||
/* webpackChunkName: 'equipment' */ "../pages/khgxgl/wlbb/index.vue"
|
||||
)
|
||||
},
|
||||
{
|
||||
path: "wlps",
|
||||
name: "wlps",
|
||||
|
|
Loading…
Reference in New Issue