style:编辑企业
Showing
5 changed files
with
80 additions
and
55 deletions
| 1 | /* | 1 | /* |
| 2 | * @Description: 企业银行接口 | 2 | * @Description: 企业银行接口 |
| 3 | * @Autor: renchao | 3 | * @Autor: renchao |
| 4 | * @LastEditTime: 2023-09-07 14:42:19 | 4 | * @LastEditTime: 2023-09-07 16:53:25 |
| 5 | */ | 5 | */ |
| 6 | import request from '@/utils/request' | 6 | import request from '@/utils/request' |
| 7 | let SERVER = window.config ? window.config : JSON.parse(localStorage.getItem('ApiUrl')) | 7 | let SERVER = window.config ? window.config : JSON.parse(localStorage.getItem('ApiUrl')) |
| ... | @@ -20,4 +20,44 @@ export function getCompanyMaterialList (bsmCompany) { | ... | @@ -20,4 +20,44 @@ export function getCompanyMaterialList (bsmCompany) { |
| 20 | bsmCompany: bsmCompany | 20 | bsmCompany: bsmCompany |
| 21 | } | 21 | } |
| 22 | }) | 22 | }) |
| 23 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 23 | } | ||
| 24 | /** | ||
| 25 | * @description: 添加材料目录 | ||
| 26 | * @param {*} bsmCompany | ||
| 27 | * @author: renchao | ||
| 28 | */ | ||
| 29 | export function addCompanyMaterial (data) { | ||
| 30 | return request({ | ||
| 31 | url: SERVER.SERVERAPI + '/rest/sys/company/addCompanyMaterial', | ||
| 32 | method: 'post', | ||
| 33 | data | ||
| 34 | }) | ||
| 35 | } | ||
| 36 | |||
| 37 | /** | ||
| 38 | * @description: 获取文件材料列表 | ||
| 39 | * @param {*} bsmCompany | ||
| 40 | * @author: renchao | ||
| 41 | */ | ||
| 42 | export function getFileListByBsmMaterial (bsmMaterial) { | ||
| 43 | return request({ | ||
| 44 | url: SERVER.SERVERAPI + '/rest/sys/company/getFileListByBsmMaterial', | ||
| 45 | method: 'get', | ||
| 46 | params: { | ||
| 47 | bsmMaterial: bsmMaterial | ||
| 48 | } | ||
| 49 | }) | ||
| 50 | } | ||
| 51 | |||
| 52 | /** | ||
| 53 | * @description: 批量上传材料目录 | ||
| 54 | * @param {*} bsmCompany | ||
| 55 | * @author: renchao | ||
| 56 | */ | ||
| 57 | export function uploadBatch (data) { | ||
| 58 | return request({ | ||
| 59 | url: SERVER.SERVERAPI + '/rest/sys/company/uploadBatch', | ||
| 60 | method: 'post', | ||
| 61 | data | ||
| 62 | }) | ||
| 63 | } | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Description: | 2 | * @Description: |
| 3 | * @Autor: renchao | 3 | * @Autor: renchao |
| 4 | * @LastEditTime: 2023-08-03 14:50:08 | 4 | * @LastEditTime: 2023-09-07 16:28:14 |
| 5 | --> | 5 | --> |
| 6 | <template> | 6 | <template> |
| 7 | <transition name="msgbox-fade"> | 7 | <transition name="msgbox-fade"> |
| ... | @@ -167,6 +167,7 @@ | ... | @@ -167,6 +167,7 @@ |
| 167 | min-height: 30%; | 167 | min-height: 30%; |
| 168 | max-height: 90vh; | 168 | max-height: 90vh; |
| 169 | overflow-y: scroll; | 169 | overflow-y: scroll; |
| 170 | box-sizing: border-box; | ||
| 170 | } | 171 | } |
| 171 | 172 | ||
| 172 | .ls-mask-footer { | 173 | .ls-mask-footer { | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Description: | 2 | * @Description: |
| 3 | * @Autor: renchao | 3 | * @Autor: renchao |
| 4 | * @LastEditTime: 2023-08-15 09:43:46 | 4 | * @LastEditTime: 2023-09-07 16:13:07 |
| 5 | --> | 5 | --> |
| 6 | <template> | 6 | <template> |
| 7 | <div class="clmlmx-box"> | 7 | <div class="clmlmx-box"> |
| ... | @@ -209,13 +209,6 @@ | ... | @@ -209,13 +209,6 @@ |
| 209 | this.unitData = this.$parent.unitData; | 209 | this.unitData = this.$parent.unitData; |
| 210 | var formdata = new FormData(); | 210 | var formdata = new FormData(); |
| 211 | formdata.append("bsmSlsq", Vue.prototype.$currentRoute.query.bsmSlsq); | 211 | formdata.append("bsmSlsq", Vue.prototype.$currentRoute.query.bsmSlsq); |
| 212 | if (Vue.prototype.$currentRoute.query.sqywbm == "DJBBL") { | ||
| 213 | formdata.append("bsmSldy", this.formData.bsmRepair); | ||
| 214 | formdata.append("clfl", 3); | ||
| 215 | } else { | ||
| 216 | formdata.append("bsmSldy", this.formData.unitData[0]?.bsmSldy); | ||
| 217 | formdata.append("clfl", 2); | ||
| 218 | } | ||
| 219 | InitClml(formdata).then((res) => { | 212 | InitClml(formdata).then((res) => { |
| 220 | if (res.code == 200) { | 213 | if (res.code == 200) { |
| 221 | resolve(res.code) | 214 | resolve(res.code) | ... | ... |
This diff is collapsed.
Click to expand it.
| 1 | <!-- | 1 | <!-- |
| 2 | * @Description: | 2 | * @Description: |
| 3 | * @Autor: renchao | 3 | * @Autor: renchao |
| 4 | * @LastEditTime: 2023-09-07 15:06:42 | 4 | * @LastEditTime: 2023-09-07 16:54:32 |
| 5 | --> | 5 | --> |
| 6 | <template> | 6 | <template> |
| 7 | <div class="clxx"> | 7 | <div class="clxx"> |
| ... | @@ -29,12 +29,11 @@ | ... | @@ -29,12 +29,11 @@ |
| 29 | </div> | 29 | </div> |
| 30 | <div | 30 | <div |
| 31 | v-for="(item, index) in tableData" | 31 | v-for="(item, index) in tableData" |
| 32 | :key="item.bsmSj" | 32 | :key="item.bsmMaterial" |
| 33 | :class="['child', treeCheckId == item.bsmSj ? 'checked' : '']" | 33 | :class="['child', treeCheckId == item.bsmMaterial ? 'checked' : '']" |
| 34 | @click="treeClick(item, index)"> | 34 | @click="treeClick(item, index)"> |
| 35 | <span v-if="item.isrequired == 1" class="required">必选</span> | 35 | {{ item.clmc }} |
| 36 | {{ item.sjmc }} | 36 | <span class="cl_number" :key="key">({{ item.sxh }})</span> |
| 37 | <span class="cl_number" :key="key">({{ item.children ? item.children.length : 0 }})</span> | ||
| 38 | </div> | 37 | </div> |
| 39 | </div> | 38 | </div> |
| 40 | </div> | 39 | </div> |
| ... | @@ -60,8 +59,8 @@ | ... | @@ -60,8 +59,8 @@ |
| 60 | import store from '@/store/index.js' | 59 | import store from '@/store/index.js' |
| 61 | import clxxAddDialog from "./dialog/clxxAddDialog.vue"; | 60 | import clxxAddDialog from "./dialog/clxxAddDialog.vue"; |
| 62 | import clxxDetailDialog from "./dialog/clxxDetailDialog.vue"; | 61 | import clxxDetailDialog from "./dialog/clxxDetailDialog.vue"; |
| 63 | import imagePreview from "@/views/components/imagePreview.vue"; | 62 | import imagePreview from "./dialog/imagePreview.vue"; |
| 64 | import { getCompanyMaterialList } from "@/api/company.js"; | 63 | import { getCompanyMaterialList, addCompanyMaterial, getFileListByBsmMaterial } from "@/api/company.js"; |
| 65 | export default { | 64 | export default { |
| 66 | components: { clxxAddDialog, imagePreview, clxxDetailDialog }, | 65 | components: { clxxAddDialog, imagePreview, clxxDetailDialog }, |
| 67 | props: { | 66 | props: { |
| ... | @@ -82,9 +81,7 @@ | ... | @@ -82,9 +81,7 @@ |
| 82 | key: 0, | 81 | key: 0, |
| 83 | tableData: [], | 82 | tableData: [], |
| 84 | previewImg: { | 83 | previewImg: { |
| 85 | // 收件标识码 | 84 | bsmMaterial: "", |
| 86 | bsmSj: "", | ||
| 87 | bsmSlsq: this.$parent.bsmSlsq, | ||
| 88 | index: 0, | 85 | index: 0, |
| 89 | selectedIndex: 0, | 86 | selectedIndex: 0, |
| 90 | imgList: [], | 87 | imgList: [], |
| ... | @@ -102,10 +99,10 @@ | ... | @@ -102,10 +99,10 @@ |
| 102 | nextPriview () { | 99 | nextPriview () { |
| 103 | if (this.treeCheckIndex < this.tableData.length) { | 100 | if (this.treeCheckIndex < this.tableData.length) { |
| 104 | this.treeCheckIndex++; | 101 | this.treeCheckIndex++; |
| 105 | this.treeCheckId = this.tableData[this.treeCheckIndex].bsmSj; | 102 | this.treeCheckId = this.tableData[this.treeCheckIndex].bsmMaterial; |
| 106 | this.previewImg.index = 0; | 103 | this.previewImg.index = 0; |
| 107 | this.previewImg.imgList = this.tableData[this.treeCheckIndex].children; | 104 | this.previewImg.imgList = this.tableData[this.treeCheckIndex].children; |
| 108 | this.previewImg.bsmSj = this.tableData[this.treeCheckIndex].bsmSj; | 105 | this.previewImg.bsmMaterial = this.tableData[this.treeCheckIndex].bsmMaterial; |
| 109 | } | 106 | } |
| 110 | }, | 107 | }, |
| 111 | /** | 108 | /** |
| ... | @@ -115,10 +112,10 @@ | ... | @@ -115,10 +112,10 @@ |
| 115 | prevPriview () { | 112 | prevPriview () { |
| 116 | if (this.treeCheckIndex >= 1) { | 113 | if (this.treeCheckIndex >= 1) { |
| 117 | this.treeCheckIndex--; | 114 | this.treeCheckIndex--; |
| 118 | this.treeCheckId = this.tableData[this.treeCheckIndex].bsmSj; | 115 | this.treeCheckId = this.tableData[this.treeCheckIndex].bsmMaterial; |
| 119 | this.previewImg.index = this.previewImg.imgList.length; | 116 | this.previewImg.index = this.previewImg.imgList.length; |
| 120 | this.previewImg.imgList = this.tableData[this.treeCheckIndex].children; | 117 | this.previewImg.imgList = this.tableData[this.treeCheckIndex].children; |
| 121 | this.previewImg.bsmSj = this.tableData[this.treeCheckIndex].bsmSj; | 118 | this.previewImg.bsmMaterial = this.tableData[this.treeCheckIndex].bsmMaterial; |
| 122 | } | 119 | } |
| 123 | }, | 120 | }, |
| 124 | /** | 121 | /** |
| ... | @@ -156,12 +153,12 @@ | ... | @@ -156,12 +153,12 @@ |
| 156 | * @author: renchao | 153 | * @author: renchao |
| 157 | */ | 154 | */ |
| 158 | setChecked (item) { | 155 | setChecked (item) { |
| 159 | this.treeCheckId = item.bsmSj; | 156 | this.treeCheckId = item.bsmMaterial; |
| 160 | this.title = item.sjmc; | 157 | this.title = item.sjmc; |
| 161 | this.titleYs = 1; | 158 | this.titleYs = 1; |
| 162 | this.titleNum = item.children.length; | 159 | this.titleNum = item.children.length; |
| 163 | this.previewImg.imgList = item.children; | 160 | // this.previewImg.imgList = item.children; |
| 164 | this.previewImg.bsmSj = item.bsmSj; | 161 | this.previewImg.bsmMaterial = item.bsmMaterial; |
| 165 | }, | 162 | }, |
| 166 | /** | 163 | /** |
| 167 | * @description: updateList | 164 | * @description: updateList |
| ... | @@ -173,7 +170,7 @@ | ... | @@ -173,7 +170,7 @@ |
| 173 | if (val.children.length != 0) { | 170 | if (val.children.length != 0) { |
| 174 | //删除最后一张图片时 val=null | 171 | //删除最后一张图片时 val=null |
| 175 | this.tableData.forEach((item) => { | 172 | this.tableData.forEach((item) => { |
| 176 | if (item.bsmSj === val.bsmSj) { | 173 | if (item.bsmMaterial === val.bsmMaterial) { |
| 177 | item.children = val.children; | 174 | item.children = val.children; |
| 178 | } | 175 | } |
| 179 | }); | 176 | }); |
| ... | @@ -185,11 +182,11 @@ | ... | @@ -185,11 +182,11 @@ |
| 185 | } else { | 182 | } else { |
| 186 | this.previewImg.imgList = []; | 183 | this.previewImg.imgList = []; |
| 187 | this.tableData.forEach((item, index) => { | 184 | this.tableData.forEach((item, index) => { |
| 188 | if (this.treeCheckId == item.bsmSj) { | 185 | if (this.treeCheckId == item.bsmMaterial) { |
| 189 | item.children = []; | 186 | item.children = []; |
| 190 | that.treeCheckIndex = index; | 187 | that.treeCheckIndex = index; |
| 191 | } | 188 | } |
| 192 | }); | 189 | }) |
| 193 | } | 190 | } |
| 194 | }, | 191 | }, |
| 195 | /** | 192 | /** |
| ... | @@ -206,28 +203,20 @@ | ... | @@ -206,28 +203,20 @@ |
| 206 | */ | 203 | */ |
| 207 | addSave (data) { | 204 | addSave (data) { |
| 208 | let obj = { | 205 | let obj = { |
| 209 | bsmSlsq: this.$parent.bsmSlsq, | 206 | bsmCompany: this.formData.bsmCompany, |
| 210 | isrequired: "1", | 207 | clmc: data.clmc, |
| 211 | sjmc: data.clmc, | 208 | cllx: data.cllx |
| 212 | sjsl: 0, | ||
| 213 | smzt: "", | ||
| 214 | ys: 0, | ||
| 215 | sjlx: data.cllx, | ||
| 216 | sfxjcl: "1", // 是否必选 | ||
| 217 | }; | 209 | }; |
| 218 | if (this.$route.query.sqywbm == "DJBBL") { | 210 | addCompanyMaterial(obj).then(async (res) => { |
| 219 | obj.bsmSldy = this.$parent.bsmRepair | ||
| 220 | } | ||
| 221 | saveClml(obj).then(async (res) => { | ||
| 222 | if (res.code == 200) { | 211 | if (res.code == 200) { |
| 223 | let res = await this.clmlInitList(2); | 212 | let res = await this.clmlInitList(2); |
| 224 | if (res == 200) | 213 | if (res == 200) |
| 225 | this.$message({ | 214 | this.$message({ |
| 226 | message: "新增成功", | 215 | message: "新增成功", |
| 227 | type: "success", | 216 | type: "success" |
| 228 | }); | 217 | }) |
| 229 | } | 218 | } |
| 230 | }); | 219 | }) |
| 231 | }, | 220 | }, |
| 232 | /** | 221 | /** |
| 233 | * @description: 材料目录点击选中 | 222 | * @description: 材料目录点击选中 |
| ... | @@ -237,10 +226,12 @@ | ... | @@ -237,10 +226,12 @@ |
| 237 | */ | 226 | */ |
| 238 | treeClick (item, index) { | 227 | treeClick (item, index) { |
| 239 | this.previewImg.index = 0; | 228 | this.previewImg.index = 0; |
| 240 | this.treeCheckId = item?.bsmSj; | 229 | this.treeCheckId = item?.bsmMaterial; |
| 241 | this.treeCheckIndex = index; | 230 | this.treeCheckIndex = index; |
| 242 | this.previewImg.imgList = item.children ? item.children : []; | 231 | getFileListByBsmMaterial(item.bsmMaterial).then(res => { |
| 243 | this.previewImg.bsmSj = item?.bsmSj; | 232 | this.previewImg.imgList = res.result ? res.result : [] |
| 233 | }) | ||
| 234 | this.previewImg.bsmMaterial = item?.bsmMaterial; | ||
| 244 | }, | 235 | }, |
| 245 | /** | 236 | /** |
| 246 | * @description: 小图片点击 | 237 | * @description: 小图片点击 |
| ... | @@ -269,14 +260,13 @@ | ... | @@ -269,14 +260,13 @@ |
| 269 | setTableData (tableData) { | 260 | setTableData (tableData) { |
| 270 | this.$nextTick((res) => { | 261 | this.$nextTick((res) => { |
| 271 | this.tableData = tableData; | 262 | this.tableData = tableData; |
| 272 | }); | 263 | }) |
| 273 | }, | 264 | } |
| 274 | }, | 265 | } |
| 275 | }; | 266 | } |
| 276 | </script> | 267 | </script> |
| 277 | <style scoped lang="scss"> | 268 | <style scoped lang="scss"> |
| 278 | @import "~@/styles/mixin.scss"; | 269 | @import "~@/styles/mixin.scss"; |
| 279 | |||
| 280 | .active { | 270 | .active { |
| 281 | background: $light-blue !important; | 271 | background: $light-blue !important; |
| 282 | color: #fff; | 272 | color: #fff; |
| ... | @@ -294,6 +284,7 @@ | ... | @@ -294,6 +284,7 @@ |
| 294 | 284 | ||
| 295 | .clxx { | 285 | .clxx { |
| 296 | width: 100%; | 286 | width: 100%; |
| 287 | height: 94%; | ||
| 297 | display: flex; | 288 | display: flex; |
| 298 | padding-left: 5px; | 289 | padding-left: 5px; |
| 299 | .left { | 290 | .left { | ... | ... |
-
Please register or sign in to post a comment