|
|
@@ -37,8 +37,11 @@ |
|
|
|
:show-file-list="false" |
|
|
|
:multiple="false" |
|
|
|
> |
|
|
|
<el-button type="primary" class="btn" icon="Upload" @click="handleImport(scope.row)" size="small"> |
|
|
|
导入 |
|
|
|
<el-button type="primary" class="btn" icon="Upload" @click="handleImport(scope.row,true)" size="small"> |
|
|
|
办理点导入 |
|
|
|
</el-button> |
|
|
|
<el-button type="primary" class="btn" icon="Upload" @click="handleImport(scope.row,false)" size="small"> |
|
|
|
禁止办理点导入 |
|
|
|
</el-button> |
|
|
|
</el-upload> |
|
|
|
|
|
|
@@ -133,11 +136,10 @@ |
|
|
|
|
|
|
|
|
|
|
|
<div style="padding: 0 0 30px 0;text-align: right;"> |
|
|
|
<el-button type="success" icon="Plus" @click="addBtn" style="margin-bottom: 10px;"> |
|
|
|
添加 |
|
|
|
</el-button> |
|
|
|
<div style="padding: 20px 50px;text-align: left;font-weight: 700;" v-if="addForm.locationModels.length > 0">办理点信息</div> |
|
|
|
|
|
|
|
|
|
|
|
<el-form v-for="(item,index) in addForm.locationModels" :key="index" label-width="150" :rules="rules"> |
|
|
|
<div style="padding: 20px 50px;text-align: left;font-weight: 700;" v-if="addForm.locationModels.length > 0">{{item.isVerity?'办理点信息':'禁止办理点信息'}}</div> |
|
|
|
<el-form-item label="名称:" prop="name" > |
|
|
|
<div style="width: 100%"> |
|
|
|
<el-input maxlength="60" v-trim clearable v-model="item.name" placeholder="请输入办理点名称" /> |
|
|
@@ -167,6 +169,13 @@ |
|
|
|
删除 |
|
|
|
</el-button> |
|
|
|
</el-form> |
|
|
|
|
|
|
|
<el-button type="success" style="margin-top: 20px;" icon="Plus" @click="addBtn(true)" > |
|
|
|
添加办理点信息 |
|
|
|
</el-button> |
|
|
|
<el-button type="default" icon="Plus" @click="addBtn(false)" style="margin-top: 20px;"> |
|
|
|
添加禁止办理点信息 |
|
|
|
</el-button> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
@@ -199,6 +208,7 @@ |
|
|
|
const dataFormRef = ref() |
|
|
|
const url = ref() |
|
|
|
const servicehallId = ref() |
|
|
|
const isVerity = ref() |
|
|
|
const data = { bucket: 'default-bucket' } |
|
|
|
const parentSelectList = ref([] as IObject[]) |
|
|
|
const upload = ref<UploadInstance>() |
|
|
@@ -260,8 +270,9 @@ |
|
|
|
getAgencyList() |
|
|
|
}) |
|
|
|
// 添加 |
|
|
|
const addBtn = () => { |
|
|
|
const addBtn = (start) => { |
|
|
|
addForm.value.locationModels.push({ |
|
|
|
isVerity: start, // 可办理地点true/禁入区域false |
|
|
|
address: '', |
|
|
|
latitude: '', |
|
|
|
longitude: '', |
|
|
@@ -296,7 +307,7 @@ const addBtn = () => { |
|
|
|
const { ossFilePath, originalFileName } = response.data |
|
|
|
url.value = 'default-bucket' + '/' + ossFilePath |
|
|
|
console.log(url.value, originalFileName) |
|
|
|
BaseService.postN('/userw/serviceHall/registerLocationBath', { excelFileUrl: url.value, serviceHallId:servicehallId.value}).then((res: any) => { |
|
|
|
BaseService.postN('/userw/serviceHall/registerLocationBath', { excelFileUrl: url.value, serviceHallId:servicehallId.value,isVerity:isVerity.value}).then((res: any) => { |
|
|
|
if (res && res.code === 0) { |
|
|
|
console.log(res) |
|
|
|
const errUrl = res.data?.path ?? '' |
|
|
@@ -311,6 +322,8 @@ const addBtn = () => { |
|
|
|
url.value = '' |
|
|
|
} |
|
|
|
} |
|
|
|
}).catch((err) => { |
|
|
|
ElMessage.success(err); |
|
|
|
}) |
|
|
|
} |
|
|
|
const handleExceed: UploadProps['onExceed'] = (files) => { |
|
|
@@ -380,7 +393,7 @@ const handleExceed: UploadProps['onExceed'] = (files) => { |
|
|
|
titleDialog: '', //table 标题 |
|
|
|
dataListLoading: false, |
|
|
|
operateTitle: '操作', //操作栏标题(默认为"") |
|
|
|
operateWidth: "350px", //操作栏宽度 |
|
|
|
operateWidth: "500px", //操作栏宽度 |
|
|
|
crud: { |
|
|
|
add: IsPermission(route, 'ADD_BASE'), |
|
|
|
}, |
|
|
@@ -670,8 +683,9 @@ const handleExceed: UploadProps['onExceed'] = (files) => { |
|
|
|
return newData |
|
|
|
} |
|
|
|
//导入 |
|
|
|
function handleImport(row) { |
|
|
|
function handleImport(row,start) { |
|
|
|
servicehallId.value = row.servicehallId |
|
|
|
isVerity.value = start |
|
|
|
} |
|
|
|
//模板下载 |
|
|
|
function handleFileName() { |