f96d4091 by renchao@pashanhoo.com

style:材料明细

1 parent b8917a94
1 <!-- 1 <!--
2 * @Description: 2 * @Description:
3 * @Autor: renchao 3 * @Autor: renchao
4 * @LastEditTime: 2023-07-31 13:59:45 4 * @LastEditTime: 2023-08-01 09:41:01
5 --> 5 -->
6 <template> 6 <template>
7 <div class="clxx"> 7 <div class="clxx">
...@@ -68,6 +68,16 @@ ...@@ -68,6 +68,16 @@
68 created () { 68 created () {
69 this.clmlInitList(1) 69 this.clmlInitList(1)
70 }, 70 },
71 computed: {
72 ...mapGetters(['workFresh'])
73 },
74 watch: {
75 workFresh: {
76 handler (newVal, oldVal) {
77 if (newVal) this.clmlInitList(1)
78 }
79 }
80 },
71 mounted () { 81 mounted () {
72 this.ableOperation = this.$parent.ableOperation 82 this.ableOperation = this.$parent.ableOperation
73 }, 83 },
...@@ -254,7 +264,8 @@ ...@@ -254,7 +264,8 @@
254 viewDetail () { 264 viewDetail () {
255 this.$popupDialog("查看明细", "workflow/components/dialog/clxxDetailDialog", { 265 this.$popupDialog("查看明细", "workflow/components/dialog/clxxDetailDialog", {
256 data: this.tableData, 266 data: this.tableData,
257 unitData: this.$parent.unitData 267 unitData: this.$parent.unitData,
268 ableOperation: this.$parent.ableOperation
258 }, "60%") 269 }, "60%")
259 }, 270 },
260 //设置tableData 271 //设置tableData
......
1 <!-- 1 <!--
2 * @Description: 2 * @Description:
3 * @Autor: renchao 3 * @Autor: renchao
4 * @LastEditTime: 2023-07-31 14:27:07 4 * @LastEditTime: 2023-08-01 09:43:19
5 --> 5 -->
6 <template> 6 <template>
7 <div class="clmlmx-box"> 7 <div class="clmlmx-box">
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
10 </lb-table> 10 </lb-table>
11 <div class="text-center"> 11 <div class="text-center">
12 <el-button @click="$popupCacel">取消</el-button> 12 <el-button @click="$popupCacel">取消</el-button>
13 <el-button type="primary" @click="handleSubmit" v-if="formData.ableOperation">确定</el-button>
13 </div> 14 </div>
14 </div> 15 </div>
15 </template> 16 </template>
...@@ -58,16 +59,28 @@ ...@@ -58,16 +59,28 @@
58 { 59 {
59 prop: "sjmc", 60 prop: "sjmc",
60 label: "材料名称", 61 label: "材料名称",
62 render: (h, scope) => {
63 return (
64 <el-input value={scope.row[scope.column.property]} onInput={(val) => { scope.row[scope.column.property] = val }}></el-input>
65 )
66 }
61 }, 67 },
62 { 68 {
63 prop: "sjlx", 69 prop: "sjlx",
64 label: "材料类型", 70 label: "材料类型",
65 width: "80", 71 width: "110",
66 render: (h, scope) => { 72 render: (h, scope) => {
67 return ( 73 return (
68 <div> 74 <el-select value={scope.row[scope.column.property]}
69 <span>{this.dicStatus(scope.row.sjlx, "A40")}</span> 75 onChange={(val) => { scope.row[scope.column.property] = val }}>
70 </div> 76 {
77 store.getters.dictData['A40'].map(option => {
78 return (
79 <el-option label={option.dname} value={option.dcode}></el-option>
80 )
81 })
82 }
83 </el-select>
71 ) 84 )
72 } 85 }
73 }, 86 },
...@@ -127,7 +140,7 @@ ...@@ -127,7 +140,7 @@
127 }, 140 },
128 { 141 {
129 label: "操作", 142 label: "操作",
130 width: "80", 143 width: "100",
131 render: (h, scope) => { 144 render: (h, scope) => {
132 return ( 145 return (
133 <div> 146 <div>
...@@ -149,10 +162,13 @@ ...@@ -149,10 +162,13 @@
149 > 162 >
150 下移 163 下移
151 </el-button> 164 </el-button>
152 </div> 165 <i v-show={scope.row.isrequired != '1' && formData.ableOperation} onClick={() => {
153 ); 166 this.handleDelete(scope.$index, scope.row);
154 }, 167 }} class="el-icon-delete pointer" style="color:#409EFF;margin-left:5px;position: relative;top: 1px;"></i>
155 }, 168 </div >
169 )
170 }
171 }
156 ], 172 ],
157 key: 0, 173 key: 0,
158 tableData: [] 174 tableData: []
...@@ -168,6 +184,12 @@ ...@@ -168,6 +184,12 @@
168 } 184 }
169 }, 185 },
170 methods: { 186 methods: {
187 handleSubmit () {
188 // saveClml(this.tableData).then(res => {
189 // console.log(res, '11111111111111');
190 // })
191 // store.dispatch('user/reWorkFresh', true)
192 },
171 /** 193 /**
172 * @description: 材料目录明细初始化 194 * @description: 材料目录明细初始化
173 * @author: renchao 195 * @author: renchao
...@@ -187,7 +209,6 @@ ...@@ -187,7 +209,6 @@
187 } else { 209 } else {
188 this.tableData = [] 210 this.tableData = []
189 } 211 }
190 console.log(this.tableData, 'this.tableData');
191 } else { 212 } else {
192 this.$message.error(res.message) 213 this.$message.error(res.message)
193 } 214 }
...@@ -248,7 +269,6 @@ ...@@ -248,7 +269,6 @@
248 } 269 }
249 }) 270 })
250 }, 271 },
251 // 材料目录删除
252 /** 272 /**
253 * @description: 材料目录删除 273 * @description: 材料目录删除
254 * @param {*} index 274 * @param {*} index
...@@ -268,7 +288,7 @@ ...@@ -268,7 +288,7 @@
268 if (res == 200) { 288 if (res == 200) {
269 that.$message({ 289 that.$message({
270 message: "删除成功", 290 message: "删除成功",
271 type: "success", 291 type: "success"
272 }) 292 })
273 } 293 }
274 } 294 }
......