|
@@ -1,11 +1,11 @@
|
|
|
<template>
|
|
|
<div id="handsontable" v-loading="isLoading">
|
|
|
<el-row class="left">
|
|
|
- <div style="display: inline-block">
|
|
|
+ <div style="display: inline-block" v-show="!onlyRead && zoneCode === 'OtherZone'">
|
|
|
<!-- <div v-show="!onlyRead && zoneCode === 'other'">-->
|
|
|
- <el-button @click="addZoneBtn">添加分区</el-button>
|
|
|
- <el-select v-model="zoneValue" placeholder="请选择">
|
|
|
- <el-option v-for="item in addZone" :key="item.value" :label="item.label" :value="item.value">
|
|
|
+ <el-button @click="addZoneBtn" type="primary">添加分区</el-button>
|
|
|
+ <el-select v-model="OtherValue" placeholder="请选择分区类型">
|
|
|
+ <el-option v-for="item in OtherList" :key="item.value" :label="item.label" :value="item.value">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
|
|
|
@@ -40,7 +40,7 @@
|
|
|
<qrcode :dialog="dialog" :qrcodeUrl="qrcodeUrl" :addBody="true" ref="qrcode"></qrcode>
|
|
|
<!-- 上传图片-->
|
|
|
<upload-img-dialog :read="onlyRead" @changeFile="imgChange" :keysArr="imgsArr" :dialog="myDialog" />
|
|
|
- <dialogZone ref="zone" />
|
|
|
+ <dialogZone ref="zone" @createSuccess="grtOtherType" />
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
@@ -66,6 +66,7 @@ import {
|
|
|
createZone,
|
|
|
BeatchQueryParam,
|
|
|
updateRelateInSpAndBuild,
|
|
|
+ queryAllZoneType
|
|
|
|
|
|
} from "@/api/scan/request";
|
|
|
import { mapGetters, mapActions } from "vuex";
|
|
@@ -132,23 +133,8 @@ export default {
|
|
|
uploadImgs: false, //上传图片弹窗
|
|
|
},
|
|
|
imgsArr: [], //空间图片
|
|
|
- addZone: [{
|
|
|
- value: '选项1',
|
|
|
- label: '黄金糕'
|
|
|
- }, {
|
|
|
- value: '选项2',
|
|
|
- label: '双皮奶'
|
|
|
- }, {
|
|
|
- value: '选项3',
|
|
|
- label: '蚵仔煎'
|
|
|
- }, {
|
|
|
- value: '选项4',
|
|
|
- label: '龙须面'
|
|
|
- }, {
|
|
|
- value: '选项5',
|
|
|
- label: '北京烤鸭'
|
|
|
- }],
|
|
|
- zoneValue: '',
|
|
|
+ OtherList:[],//其他分区筛选框
|
|
|
+ OtherValue: '',
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
@@ -716,6 +702,24 @@ export default {
|
|
|
},
|
|
|
addZoneBtn() {
|
|
|
this.$refs.zone.dialogFormVisible = true
|
|
|
+ },
|
|
|
+ // 其他分区类型查询
|
|
|
+ grtOtherType() {
|
|
|
+ let param = {
|
|
|
+ Cascade: [{ Name: 'zoneType' }],
|
|
|
+ Filters: `Code="OtherZone"`
|
|
|
+ }
|
|
|
+ queryAllZoneType(param,res=> {
|
|
|
+ if(res.Content[0].ZoneType && res.Content[0].ZoneType.length) {
|
|
|
+ this.OtherList = res.Content[0].ZoneType.map(res=> {
|
|
|
+ t.value = t.Code
|
|
|
+ t.label = t.Name
|
|
|
+ return t
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.OtherList = []
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
},
|
|
|
watch: {
|