|
@@ -86,7 +86,13 @@
|
|
|
|
|
|
<el-form-item label-width="100px" label="保税区" prop="bondedName">
|
|
|
<el-select v-model="form.bondedName" placeholder="请选择保税区" clearable filterable @change="selectBondedChange" style="width:100%">
|
|
|
- <el-option v-for="dict in BONDEDList" :key="dict.id" :label="dict.bondedName" :value="dict" />
|
|
|
+<!-- <el-option v-for="dict in BONDEDList" :key="dict.id" :label="dict.bondedName" :value="dict" />-->
|
|
|
+ <el-option
|
|
|
+ v-for="item in deptList"
|
|
|
+ :key="item.deptId"
|
|
|
+ :label="item.deptName"
|
|
|
+ :value="item.deptName">
|
|
|
+ </el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label-width="100px" label="辅助指标" prop="quotaName">
|
|
@@ -138,6 +144,7 @@ import { listQUOTABONDED, getQUOTABONDED, delQUOTABONDED, addQUOTABONDED, update
|
|
|
import { listQUOTAFEE } from "@/api/norm/QUOTAFEE";
|
|
|
import { listBONDED } from "@/api/portal/BONDED/BONDED.js";
|
|
|
import { uploadFile } from '@/api/common';
|
|
|
+import { listDept } from '@/api/system/dept'
|
|
|
|
|
|
export default {
|
|
|
name: "QUOTABONDED",
|
|
@@ -166,6 +173,8 @@ export default {
|
|
|
QUOTAFEEList: [],
|
|
|
BONDEDList: [],
|
|
|
fileList: [],
|
|
|
+ // 保税区列表
|
|
|
+ deptList: [],
|
|
|
// 查询参数
|
|
|
queryParams: {
|
|
|
pageNum: 1,
|
|
@@ -213,11 +222,25 @@ export default {
|
|
|
this.BONDEDList = response.rows;
|
|
|
});
|
|
|
this.getList();
|
|
|
+ this.getDeptList()
|
|
|
},
|
|
|
methods: {
|
|
|
+
|
|
|
+ // 获取保税区列表
|
|
|
+ getDeptList() {
|
|
|
+ this.loading = true;
|
|
|
+ listDept({parentId: '100'}).then(response => {
|
|
|
+ this.deptList = response.data
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ },
|
|
|
selectBondedChange(val) {
|
|
|
- this.form.bondedId = val.id;
|
|
|
- this.form.bondedName = val.bondedName;
|
|
|
+ const selectedDept = this.deptList.find(item => item.deptName === this.form.bondedName);
|
|
|
+ if (selectedDept) {
|
|
|
+ this.form.bondedId = selectedDept.deptId;
|
|
|
+ }
|
|
|
+ // this.form.bondedId = val.id;
|
|
|
+ // this.form.bondedName = val.bondedName;
|
|
|
},
|
|
|
selectQuotaChange(val) {
|
|
|
this.form.quotaId = val.id;
|
|
@@ -288,6 +311,11 @@ export default {
|
|
|
const id = row.id || this.ids
|
|
|
getQUOTABONDED(id).then(response => {
|
|
|
this.form = response.data;
|
|
|
+ this.form.linkUrls = this.baseURL + response.data.linkUrls;
|
|
|
+ this.fileList.push({
|
|
|
+ name: response.data.fileNames,
|
|
|
+ url: response.data.linkUrls,
|
|
|
+ });
|
|
|
this.open = true;
|
|
|
this.title = "辅助指标录入修改";
|
|
|
});
|
|
@@ -353,7 +381,6 @@ export default {
|
|
|
let formData = new FormData()
|
|
|
formData.append('file',file.file)
|
|
|
uploadFile(formData).then(res=>{
|
|
|
- console.log("11111111",res)
|
|
|
if(res.code == 200){
|
|
|
if(this.form.linkUrls == null) {
|
|
|
this.form.linkUrls = res.fileName + ",";
|