提交 469e017b 编写于 作者: changdi.hao's avatar changdi.hao

优化地址

上级 1dcea8ea
...@@ -653,7 +653,8 @@ ...@@ -653,7 +653,8 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item prop="townId" label="乡/镇" label-width="70px"> <!-- <el-form-item prop="townId" label="乡/镇" label-width="70px"> -->
<el-form-item label="乡/镇" label-width="70px">
<el-select <el-select
v-model="warehouseAdressForm.townId" v-model="warehouseAdressForm.townId"
class="warehouseAdress-input" class="warehouseAdress-input"
...@@ -792,7 +793,7 @@ export default { ...@@ -792,7 +793,7 @@ export default {
key: '' key: ''
}, },
warehouseAdressFormVisible: false, warehouseAdressFormVisible: false,
warehouseAdressFormTitle: '创建地址', warehouseAdressFormTitle: '添加地址',
provincesList: [], provincesList: [],
cityList: [], cityList: [],
countyList: [], countyList: [],
...@@ -1082,9 +1083,16 @@ export default { ...@@ -1082,9 +1083,16 @@ export default {
}, },
// 返回 // 返回
back() { back() {
this.$router.push({ this.$confirm('确认要返回吗?', '提示', {
path: "/shop-list", confirmButtonText: '确定',
}); cancelButtonText: '取消',
type: 'error'
}).then(() => {
this.$router.push({
path: "/shop-list",
});
}).catch(() => {
});
}, },
checkPhone(val) { checkPhone(val) {
if (!/^1[3456789]\d{9}$/.test(val)) { if (!/^1[3456789]\d{9}$/.test(val)) {
...@@ -1521,7 +1529,7 @@ export default { ...@@ -1521,7 +1529,7 @@ export default {
// 编辑第几条数据 index // 编辑第几条数据 index
createAdress(type,index) { createAdress(type,index) {
this.warehouseAdressType = type; this.warehouseAdressType = type;
this.warehouseAdressFormTitle = type ? '编辑地址' : '创建地址'; this.warehouseAdressFormTitle = type ? '编辑地址' : '添加地址';
this.warehouseAdressIndex = type ? index : ''; this.warehouseAdressIndex = type ? index : '';
if (type) { if (type) {
Object.assign(this.warehouseAdressForm,this.formData.repotList[index]); Object.assign(this.warehouseAdressForm,this.formData.repotList[index]);
...@@ -1685,7 +1693,8 @@ export default { ...@@ -1685,7 +1693,8 @@ export default {
}, },
// 格式化地址 // 格式化地址
setAddress(arg) { setAddress(arg) {
return arg.provinceName + arg.cityName + arg.countyName + arg.townName + arg.addr; let townName = arg.townName || '';
return arg.provinceName + arg.cityName + arg.countyName + townName + arg.addr;
}, },
// 获取退货物流 // 获取退货物流
getCompanyList() { getCompanyList() {
...@@ -1901,7 +1910,12 @@ export default { ...@@ -1901,7 +1910,12 @@ export default {
margin-bottom: 0; margin-bottom: 0;
} }
} }
.el-radio__label {
display: flex;
flex: 1;
}
.warehouseAdress-main { .warehouseAdress-main {
flex: 1;
padding-right: 60px; padding-right: 60px;
} }
.warehouseAdress-msg { .warehouseAdress-msg {
...@@ -1914,6 +1928,7 @@ export default { ...@@ -1914,6 +1928,7 @@ export default {
color: #449284; color: #449284;
background: #fff; background: #fff;
padding: 0 10px 0 10px; padding: 0 10px 0 10px;
width: 100px;
} }
} }
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册