371ab015 by 田浩浩

增加登簿功能

1 parent 49adeb62
...@@ -215,6 +215,7 @@ export default { ...@@ -215,6 +215,7 @@ export default {
215 }, 215 },
216 methods: { 216 methods: {
217 list (bsmSldy) { 217 list (bsmSldy) {
218 debugger;
218 var formdata = new FormData(); 219 var formdata = new FormData();
219 formdata.append("bsmSldy", bsmSldy); 220 formdata.append("bsmSldy", bsmSldy);
220 Init(formdata).then((res) => { 221 Init(formdata).then((res) => {
......
...@@ -58,13 +58,24 @@ ...@@ -58,13 +58,24 @@
58 <p class="splitScreen tabsList-title">材料信息</p> 58 <p class="splitScreen tabsList-title">材料信息</p>
59 <div class="splitScreen"></div> 59 <div class="splitScreen"></div>
60 </div> 60 </div>
61 <div style="width:100%"> 61 <div style="width: 100%">
62 <el-tabs v-model="activeName" @tab-click='activeClick'> 62 <el-tabs v-model="activeName" @tab-click="activeClick">
63 <el-tab-pane :label="item.name" :name="item.value" v-for="(item, index) in tabList" :key="index"> 63 <el-tab-pane
64 :label="item.name"
65 :name="item.value"
66 v-for="(item, index) in tabList"
67 :key="index"
68 >
64 </el-tab-pane> 69 </el-tab-pane>
65 </el-tabs> 70 </el-tabs>
66 <div class="splitScreen-con"> 71 <div class="splitScreen-con">
67 <component ref='slxx' v-if="activeName == 'slsq'" :is="editItem" :flag="flag" :key="key" /> 72 <component
73 ref="slxx"
74 v-if="activeName == 'slsq'"
75 :is="editItem"
76 :flag="flag"
77 :key="key"
78 />
68 <component :is="editItem" :key="key" /> 79 <component :is="editItem" :key="key" />
69 </div> 80 </div>
70 </div> 81 </div>
...@@ -117,11 +128,11 @@ export default { ...@@ -117,11 +128,11 @@ export default {
117 }, 128 },
118 watch: { 129 watch: {
119 activeName: { 130 activeName: {
120 handler (newName, oldName) { 131 handler(newName, oldName) {
121 if (newName === 'qlxx') { 132 if (newName === "qlxx") {
122 this.editItem = this.loadViewSlsq() 133 this.editItem = this.loadViewSlsq();
123 } else { 134 } else {
124 this.editItem = this.loadView(newName) 135 this.editItem = this.loadView(newName);
125 } 136 }
126 }, 137 },
127 immediate: true, 138 immediate: true,
...@@ -142,13 +153,13 @@ export default { ...@@ -142,13 +153,13 @@ export default {
142 that.id = id; 153 that.id = id;
143 var formdata = new FormData(); 154 var formdata = new FormData();
144 formdata.append("bsmSlsq", id); 155 formdata.append("bsmSlsq", id);
145 leftMenu(formdata).then(res => { 156 leftMenu(formdata).then((res) => {
146 if (res.code === 200) { 157 if (res.code === 200) {
147 this.unitData = res.result ? res.result : []; 158 this.unitData = res.result ? res.result : [];
148 setTimeout(() => { 159 setTimeout(() => {
149 that.$refs.slxx?.[0].list(that.unitData?.[0]?.bsmSldy) 160 that.$refs.slxx?.[0].list(that.unitData?.[0]?.bsmSldy);
150 this.taskId = that.unitData?.[0]?.taskId 161 this.taskId = that.unitData?.[0]?.taskId;
151 this.bsmBusiness = that.unitData?.[0]?.bsmBusiness 162 this.bsmBusiness = that.unitData?.[0]?.bsmBusiness;
152 }, 300); 163 }, 300);
153 } 164 }
154 }); 165 });
...@@ -161,8 +172,8 @@ export default { ...@@ -161,8 +172,8 @@ export default {
161 formdata.append("bestepid", bestepid); 172 formdata.append("bestepid", bestepid);
162 stepExpandInfo(formdata).then((res) => { 173 stepExpandInfo(formdata).then((res) => {
163 if (res.code === 200) { 174 if (res.code === 200) {
164 this.tabList1 = [...res.result.form] 175 this.tabList1 = [...res.result.form];
165 this.tabList = res.result.form 176 this.tabList = res.result.form;
166 this.headerleftList = res.result.button; 177 this.headerleftList = res.result.button;
167 this.headerRightList = res.result.operation; 178 this.headerRightList = res.result.operation;
168 } 179 }
...@@ -209,15 +220,33 @@ export default { ...@@ -209,15 +220,33 @@ export default {
209 case "tc": 220 case "tc":
210 window.close(); 221 window.close();
211 break; 222 break;
212 case "db": 223 case "db":
213 // comMsg;
214 var formdata = new FormData(); 224 var formdata = new FormData();
215 formdata.append("bsmSlsq", this.$route.query.bsmSlsq); 225 formdata.append("bsmSlsq", this.$route.query.bsmSlsq);
216 formdata.append("bestepid", this.$route.query.bestepid); 226 formdata.append("bestepid", this.$route.query.bestepid);
217 record(formdata).then((res) => { 227 // comMsg;
218 if (res.code === 200) { 228 this.$confirm("请确认是否登簿", "提示", {
219 } 229 iconClass: "el-icon-question", //自定义图标样式
220 }); 230 confirmButtonText: "确认", //确认按钮文字更换
231 cancelButtonText: "取消", //取消按钮文字更换
232 showClose: true, //是否显示右上角关闭按钮
233 type: "warning", //提示类型 success/info/warning/error
234 })
235 .then(function () {
236 record(formdata).then((res) => {
237 debugger;
238 if (res.code === 200 || res.code === 2002) {
239 this.$alert(res.message);
240 }
241 });
242 })
243 .then((data) => {
244 this.$alert("res.Message");
245 })
246 .catch(function (err) {
247 //捕获异常
248 });
249
221 break; 250 break;
222 } 251 }
223 }, 252 },
...@@ -225,8 +254,11 @@ export default { ...@@ -225,8 +254,11 @@ export default {
225 return (r) => 254 return (r) =>
226 require.ensure([], () => r(require(`./components/${view}.vue`))); 255 require.ensure([], () => r(require(`./components/${view}.vue`)));
227 }, 256 },
228 loadViewSlsq () { 257 loadViewSlsq() {
229 return r => require.ensure([], () => r(require('../../components/jsydsyq/jsydsyq.vue'))) 258 return (r) =>
259 require.ensure([], () =>
260 r(require("../../components/jsydsyq/jsydsyq.vue"))
261 );
230 }, 262 },
231 }, 263 },
232 }; 264 };
...@@ -256,7 +288,6 @@ export default { ...@@ -256,7 +288,6 @@ export default {
256 margin: 0 !important; 288 margin: 0 !important;
257 } 289 }
258 290
259
260 .splitScreen-con { 291 .splitScreen-con {
261 padding: 0 15px; 292 padding: 0 15px;
262 box-sizing: border-box; 293 box-sizing: border-box;
......