From 0000e9a82360e1e8ff312fe993912382430182f2 Mon Sep 17 00:00:00 2001
From: zhuzhuanzhuan
Date: 星期三, 20 三月 2024 15:35:26 +0800
Subject: [PATCH] 调整看板设备运行状态玫瑰图类型
---
src/views/eam/modules/repairorder/moudles/select/FaultReportRepair.vue | 148 ++++++++++++++++++++++++++++++++++--------------
1 files changed, 104 insertions(+), 44 deletions(-)
diff --git a/src/views/eam/modules/repairorder/moudles/select/FaultReportRepair.vue b/src/views/eam/modules/repairorder/moudles/select/FaultReportRepair.vue
index cd9a830..8c7fa97 100644
--- a/src/views/eam/modules/repairorder/moudles/select/FaultReportRepair.vue
+++ b/src/views/eam/modules/repairorder/moudles/select/FaultReportRepair.vue
@@ -1,7 +1,7 @@
<template>
<a-modal
:title="title"
- :width="1250"
+ :width="1600"
:visible="visible"
:confirmLoading="confirmLoading"
:okButtonProps="{ props: {disabled: disableSubmit} }"
@@ -22,10 +22,10 @@
:sm="8"
>
<a-form-item label="鍗曟嵁鍙�">
- <j-input
+ <a-input
placeholder="璇疯緭鍏ュ崟鎹彿妫�绱�"
v-model="queryParam.num"
- ></j-input>
+ ></a-input>
</a-form-item>
</a-col>
@@ -34,10 +34,21 @@
:sm="8"
>
<a-form-item label="璁惧鍚嶇О">
- <j-input
+ <a-input
placeholder="璇疯緭鍏ヨ澶囧悕绉版绱�"
v-model="queryParam.equipmentName"
- ></j-input>
+ ></a-input>
+ </a-form-item>
+ </a-col>
+ <a-col
+ :md="6"
+ :sm="8"
+ >
+ <a-form-item label="缁熶竴缂栫爜">
+ <a-input
+ placeholder="璇疯緭鍏ョ粺涓�缂栫爜妫�绱�"
+ v-model="queryParam.equipmentNum"
+ ></a-input>
</a-form-item>
</a-col>
<a-col
@@ -72,12 +83,14 @@
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
- :loading="loading"
+ :loading="confirmLoading"
@change="handleTableChange"
:customRow="clickThenCheck"
- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange,type:type}"
+ :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
>
-
+ <span slot="faultDescription" slot-scope="text">
+ <j-ellipsis :value="text" :length="10" />
+ </span>
</a-table>
</div>
</a-form>
@@ -102,6 +115,7 @@
JDate,
Tooltip,
JEllipsis,
+ store
},
data() {
return {
@@ -134,29 +148,59 @@
confirmLoading: false,
form: this.$form.createForm(this),
columns: [
- {
+ {
title: '#',
dataIndex: '',
key: 'rowIndex',
- align: 'center',
+ width: 60,
+ align: "center",
customRender: function (t, r, index) {
- return parseInt(index) + 1
+ return parseInt(index) + 1;
}
},
{
+ title: '鐘舵��',
+ align: "center",
+ dataIndex: 'statusName',
+ },
+ {
title: '鍗曟嵁鍙�',
- align: 'center',
- dataIndex: 'num',
+ align: "center",
+ dataIndex: 'num'
+ },
+ {
+ title: '缁熶竴缂栫爜',
+ align: "center",
+ dataIndex: 'equipmentNum'
},
{
title: '璁惧鍚嶇О',
- align: 'center',
+ align: "center",
dataIndex: 'equipmentName',
+ },
+ {
+ title: '璁惧鍨嬪彿',
+ align: "center",
+ dataIndex: 'equipmentModel',
+ },
+ {
+ title: '瑙勬牸',
+ align: "center",
+ dataIndex: 'equipmentSpecification',
+ },
+ {
+ title: '浣跨敤閮ㄩ棬',
+ align: "center",
+ dataIndex: 'departName',
},
{
title: '鏁呴殰鎻忚堪',
align: "center",
- dataIndex: 'faultDescription'
+ dataIndex: 'faultDescription',
+ scopedSlots: {
+ customRender: 'faultDescription'
+ }
+
},
{
title: '鏁呴殰鏃堕棿',
@@ -164,17 +208,35 @@
dataIndex: 'faultTime'
},
{
- title: '绱ф�ョ▼搴�',
- align: 'center',
- dataIndex: 'urgency_dictText',
+ title: '鏄惁鍋滄満',
+ align: "center",
+ dataIndex: 'isStopName',
+ },
+ {
+ title: '鍒涘缓浜�',
+ align: "center",
+ dataIndex: 'createBy'
+ },
+ {
+ title: '鍒涘缓鏃堕棿',
+ align: "center",
+ dataIndex: 'createTime',
+ },
+ {
+ title: '澶囨敞',
+ align: "center",
+ dataIndex: 'remark',
+ scopedSlots: {
+ customRender: 'faultDescription'
+ }
},
],
url: {
- list: "/eam/equipmentReportRepair/list",
+ list: "/eam/equipmentReportRepair/getReportRepairList",
+ add: "/eam/repairOrder/addBySelectReport"
},
}
},
-
methods: {
@@ -187,6 +249,8 @@
if (arg === 1) {
this.ipagination.current = 1
}
+ this.queryParam.status = '1';
+ this.queryParam.userId = store.getters.userInfo.id
var params = this.getQueryParams() //鏌ヨ鏉′欢
this.loading = true
params.isCreateOrder = 0
@@ -207,19 +271,12 @@
this.loading = false
})
},
-
searchQuery() {
this.loadData(1);
},
searchReset() {
this.queryParam = {};
this.loadData(1)
- },
- list(params) {
- this.selectedRowKeys = [];
- this.selectedRowRecord = [];
- this.visible = true;
- this.loadData(1);
},
clickThenCheck(record) {
return {
@@ -231,30 +288,36 @@
}
};
},
- onSelectChange(selectedRowKeys, selectedRows) {
+ onSelectChange(selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys;
- this.selectedRowRecord = selectedRows[0];
+ this.selectionRows = selectionRows;
},
close() {
this.queryParam = {};
this.$emit('close');
+ this.dataSource=[];
this.visible = false;
},
handleOk() {
const that = this;
// 瑙﹀彂琛ㄥ崟楠岃瘉
- if (that.selectedRowKeys.length > 0) {
- if (that.selectedRowRecord.id != null && that.selectedRowRecord.id != "") {
- that.$emit('sendFaultReportRepairRecord', { record: that.selectedRowRecord });
- that.close();
- } else {
- that.$message.error("璇烽�夋嫨鏁呴殰鎶ヤ慨淇℃伅锛�")
- }
- } else {
- that.$message.error("璇烽�夋嫨鏁呴殰鎶ヤ慨淇℃伅锛�")
+ this.confirmLoading=true;
+ if (that.selectedRowKeys.length === 0) {
+ that.$message.error("璇烽�夋嫨鏁呴殰鎶ヤ慨鍗曞悗鎻愪氦锛�")
+ return false;
}
+ postAction(this.url.add,this.selectionRows).then(res=>{
+ if(res.success){
+ that.$message.success("棰嗗彇鎴愬姛锛�")
+ that.$emit('ok');
+ }else{
+ that.$message.error("棰嗗彇鍑虹幇寮傚父锛�")
+ }
+ }).finally(res=>{
+ that.confirmLoading = false;
+ that.close();
+ });
},
-
handleCancel() {
this.close();
},
@@ -311,8 +374,7 @@
height: 90% !important;
overflow-y: hidden;
}
-
-/deep/ .notshow {
+ .notshow {
display: none;
}
@@ -330,9 +392,7 @@
}
.dataUnKnow {
color: #1890ff;
-}
-
-/deep/ .frozenRowClass {
+} .frozenRowClass {
color: #c9c9c9;
}
</style>
\ No newline at end of file
--
Gitblit v1.9.3