投放时候选择站点信息
This commit is contained in:
parent
80a2227352
commit
f385b2f2b5
@ -8,7 +8,7 @@
|
|||||||
@confirm="search" />
|
@confirm="search" />
|
||||||
</view>
|
</view>
|
||||||
<view class="searchmore" @click="showDrawer('showRight')">
|
<view class="searchmore" @click="showDrawer('showRight')">
|
||||||
<image :src="`${imgPath}static/image/更多.png`" alt="" />
|
<image :src="`${imgPath}static/image/更多.png`" alt="" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -83,12 +83,12 @@
|
|||||||
<view class="popup-content" :class="{ 'popup-height': typepopup === 'left' || typepopup === 'right' }">
|
<view class="popup-content" :class="{ 'popup-height': typepopup === 'left' || typepopup === 'right' }">
|
||||||
<view class="padding plcrk">
|
<view class="padding plcrk">
|
||||||
<uni-forms ref="customForm" :rules="customRules" :modelValue="customFormData">
|
<uni-forms ref="customForm" :rules="customRules" :modelValue="customFormData">
|
||||||
<!-- <uni-section title="运营区域" type="line">
|
<uni-section title="站点" type="line">
|
||||||
<uni-forms-item name="reginvalue">
|
<uni-forms-item required name="reginvalue">
|
||||||
<uni-data-select v-model="customFormData.reginvalue" :localdata="regindata"
|
<uni-data-select v-model="customFormData.reginvalue" :localdata="regindata"
|
||||||
@change="changeZT"></uni-data-select>
|
@change="changeZT"></uni-data-select>
|
||||||
</uni-forms-item>
|
</uni-forms-item>
|
||||||
</uni-section> -->
|
</uni-section>
|
||||||
<uni-section title="请添加设备" type="line">
|
<uni-section title="请添加设备" type="line">
|
||||||
<uni-forms-item required name="deviceValues">
|
<uni-forms-item required name="deviceValues">
|
||||||
<uni-easyinput type="textarea" v-model="customFormData.deviceValues"
|
<uni-easyinput type="textarea" v-model="customFormData.deviceValues"
|
||||||
@ -129,24 +129,12 @@
|
|||||||
const rangevalue = ref(0);
|
const rangevalue = ref(0);
|
||||||
|
|
||||||
//运营区域下拉值 和列表
|
//运营区域下拉值 和列表
|
||||||
const regindata = ref([{
|
const regindata = ref([])
|
||||||
value: 0,
|
|
||||||
text: "四川"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
value: 1,
|
|
||||||
text: "成都"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
value: 2,
|
|
||||||
text: "武侯区"
|
|
||||||
},
|
|
||||||
])
|
|
||||||
|
|
||||||
//提交表单相关信息
|
//提交表单相关信息
|
||||||
const customForm = ref(null)
|
const customForm = ref(null)
|
||||||
const customFormData = ref({
|
const customFormData = ref({
|
||||||
reginvalue: 0,
|
reginvalue: "",
|
||||||
deviceValues: ""
|
deviceValues: ""
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -155,13 +143,15 @@
|
|||||||
reginvalue: {
|
reginvalue: {
|
||||||
rules: [{
|
rules: [{
|
||||||
required: true,
|
required: true,
|
||||||
errorMessage: '运营区域不能为空'
|
errorMessage: '站点信息不能为空',
|
||||||
|
trigger: 'blur'
|
||||||
}]
|
}]
|
||||||
},
|
},
|
||||||
deviceValues: {
|
deviceValues: {
|
||||||
rules: [{
|
rules: [{
|
||||||
required: true,
|
required: true,
|
||||||
errorMessage: '车辆编号不能为空!'
|
errorMessage: '车辆编号不能为空!',
|
||||||
|
trigger: 'blur'
|
||||||
}]
|
}]
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -196,13 +186,28 @@
|
|||||||
const statusBarHeight = systemInfo.statusBarHeight;
|
const statusBarHeight = systemInfo.statusBarHeight;
|
||||||
// 计算去掉状态栏后的可用区域高度
|
// 计算去掉状态栏后的可用区域高度
|
||||||
usableHeight.value = screenHeight - statusBarHeight - 170;
|
usableHeight.value = screenHeight - statusBarHeight - 170;
|
||||||
getUserRegionInfo();
|
// getUserRegionInfo();
|
||||||
|
let userDefultOperation = uni.getStorageSync('userDefultOperation');
|
||||||
|
//获取站点信息
|
||||||
|
api.callOperateApi("ebikeRegion/getRegion?regionId="+userDefultOperation.regionId,{} ,"get").then(res=>{
|
||||||
|
if(res.code==200){
|
||||||
|
res.data.forEach(res => {
|
||||||
|
let quyuemap = {
|
||||||
|
"text": res.regionName,
|
||||||
|
"value": res.regionId
|
||||||
|
};
|
||||||
|
regindata.value.push(quyuemap);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const getUserRegionInfo = () => {
|
const getUserRegionInfo = () => {
|
||||||
api.callOperateApi("ebikeRegion/pageSite?pageNum=1&pageSize=20",{},"get").then(res => {
|
api.callOperateApi("ebikeRegion/pageSite?pageNum=1&pageSize=20", {}, "get").then(res => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user