Commit ebc05cf7 authored by Your Name's avatar Your Name

Merge branch 'development' of http://gitlab-ebiz.yiyao365.cn/newshop/newshopfront into development

parents 444d3932 44c60bda
...@@ -66,7 +66,8 @@ ...@@ -66,7 +66,8 @@
<a-divider type="vertical" /> <a-divider type="vertical" />
<a type="primary" @click="handleEdit(record)">编辑</a> <a type="primary" @click="handleEdit(record)">编辑</a>
<a-divider type="vertical" /> <a-divider type="vertical" />
<a type="primary">启用</a> <a type="primary" @click="modifyStatus(record)" v-if="record.STATUS==0">启用</a>
<a type="primary" @click="modifyStatus(record)" v-else>停用</a>
<a-divider type="vertical" /> <a-divider type="vertical" />
<a-popconfirm title="是否要删除此行?" @confirm="remove(record.GUID)"> <a-popconfirm title="是否要删除此行?" @confirm="remove(record.GUID)">
<a>删除</a> <a>删除</a>
...@@ -99,7 +100,7 @@ ...@@ -99,7 +100,7 @@
required required
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol"> :wrapperCol="wrapperCol">
<a-select v-decorator="['STATUS ',{rules:[{required:true,message:'请选择是否启用'}],initialValue:'1',normalize:checkNull}]" placeholder="请选择"> <a-select v-decorator="['STATUS',{rules:[{required:true,message:'请选择是否启用'}],initialValue:'1',normalize:checkNull}]" placeholder="请选择">
<a-select-option value="0">不启用</a-select-option> <a-select-option value="0">不启用</a-select-option>
<a-select-option value="1">启用</a-select-option> <a-select-option value="1">启用</a-select-option>
</a-select> </a-select>
...@@ -251,6 +252,26 @@ export default { ...@@ -251,6 +252,26 @@ export default {
}, },
methods: { methods: {
moment, moment,
// 修改状态
modifyStatus(record){
const statusChange={
GUID:record.GUID,
STATUS:record.STATUS
};
if(statusChange.STATUS==1){
statusChange.STATUS=0;
}else{
statusChange.STATUS=1;
}
modifyGoodsTemplate(statusChange).then(res => {
if(res.status==200){
this.$message.success(res.message)
this.$refs.table.refresh();
}
}).catch(err => {
})
},
// 删除 // 删除
remove(value){ remove(value){
deleteGoodsTemplate(value).then(res => { deleteGoodsTemplate(value).then(res => {
......
...@@ -570,14 +570,14 @@ ...@@ -570,14 +570,14 @@
}; };
getDCDetails(id).then(res => { getDCDetails(id).then(res => {
this.$nextTick(() => { this.$nextTick(() => {
this.addressProvince=res.RECIVER_PROVINCE; this.addressProvince=res.data[0].RECIVER_PROVINCE;
this.addressCity=res.RECIVER_CITY; this.addressCity=res.data[0].RECIVER_CITY;
this.addressRegion=resizeBy.RECIVER_REGION; this.addressRegion=res.data[0].RECIVER_REGION;
res.WORK_TIME_START=this.timeGet(res.WORK_TIME)[0] res.data[0].WORK_TIME_START=this.timeGet(res.data[0].WORK_TIME)[0]
res.WORK_TIME_END=this.timeGet(res.WORK_TIME)[1] res.data[0].WORK_TIME_END=this.timeGet(res.data[0].WORK_TIME)[1]
res.DELIVERY_TIME_START=this.timeGet(res.DELIVERY_TIME)[0] res.data[0].DELIVERY_TIME_START=this.timeGet(res.data[0].DELIVERY_TIME)[0]
res.DELIVERY_TIME_END=this.timeGet(res.DELIVERY_TIME)[1] res.data[0].DELIVERY_TIME_END=this.timeGet(res.data[0].DELIVERY_TIME)[1]
this.form.setFieldsValue(res) this.form.setFieldsValue(res.data[0])
}) })
}).catch(err => { }).catch(err => {
......
...@@ -245,12 +245,12 @@ ...@@ -245,12 +245,12 @@
<a-col :span="3"></a-col> <a-col :span="3"></a-col>
<a-col :span="8"> <a-col :span="8">
<span>开始营业时间</span> <span>开始营业时间</span>
<a-time-picker @change="(val,dateStrings)=>changeTime(val,dateStrings,'worktime_start')" v-decorator="['WORK_TIME_START',{normalize:checkDate}]" /> <a-time-picker id="startWorktime" @change="(val,dateStrings)=>changeTime(val,dateStrings,'worktime_start')" v-decorator="['WORK_TIME_START',{normalize:checkDate}]" />
</a-col> </a-col>
<a-col :span="2"></a-col> <a-col :span="2"></a-col>
<a-col :span="8"> <a-col :span="8">
<span>结束营业时间</span> <span>结束营业时间</span>
<a-time-picker hideDisabledOptions @change="(val,dateStrings)=>changeTime(val,dateStrings,'worktime_end')" :disabledHours="getDisabledHours" :disabledMinutes="getDisabledMinutes" :disabledSeconds="getDisabledSeconds" v-decorator="['WORK_TIME_END',{normalize:checkDate}]" /> <a-time-picker id="endWorktime" hideDisabledOptions @change="(val,dateStrings)=>changeTime(val,dateStrings,'worktime_end')" :disabledHours="getDisabledHours" :disabledMinutes="getDisabledMinutes" :disabledSeconds="getDisabledSeconds" v-decorator="['WORK_TIME_END',{normalize:checkDate}]" />
</a-col> </a-col>
<a-col :span="3"></a-col> <a-col :span="3"></a-col>
</a-form-item> </a-form-item>
...@@ -261,12 +261,12 @@ ...@@ -261,12 +261,12 @@
<a-col :span="3"></a-col> <a-col :span="3"></a-col>
<a-col :span="8"> <a-col :span="8">
<span>开始配送时间</span> <span>开始配送时间</span>
<a-time-picker @change="(val,dateStrings)=>changeTime(val,dateStrings,'develiytime_start')" v-decorator="['DELIVERY_TIME_START',{normalize:checkDate}]" /> <a-time-picker id="startDeliveritime" @change="(val,dateStrings)=>changeTime(val,dateStrings,'develiytime_start')" v-decorator="['DELIVERY_TIME_START',{normalize:checkDate}]" />
</a-col> </a-col>
<a-col :span="2"></a-col> <a-col :span="2"></a-col>
<a-col :span="8"> <a-col :span="8">
<span>结束配送时间</span> <span>结束配送时间</span>
<a-time-picker hideDisabledOptions @change="(val,dateStrings)=>changeTime(val,dateStrings,'develiytime_end')" :disabledHours="getDisabledHoursDeveliy" :disabledMinutes="getDisabledMinutesDeveliy" :disabledSeconds="getDisabledSecondsDeveliy" v-decorator="['DELIVERY_TIME_END',{normalize:checkDate}]" /> <a-time-picker id="endDeliveritime" hideDisabledOptions @change="(val,dateStrings)=>changeTime(val,dateStrings,'develiytime_end')" :disabledHours="getDisabledHoursDeveliy" :disabledMinutes="getDisabledMinutesDeveliy" :disabledSeconds="getDisabledSecondsDeveliy" v-decorator="['DELIVERY_TIME_END',{normalize:checkDate}]" />
</a-col> </a-col>
<a-col :span="3"></a-col> <a-col :span="3"></a-col>
</a-form-item> </a-form-item>
...@@ -794,31 +794,31 @@ ...@@ -794,31 +794,31 @@
var id=this.$route.query.GUID; var id=this.$route.query.GUID;
getStoreDetails(id).then(res => { getStoreDetails(id).then(res => {
this.$nextTick(() => { this.$nextTick(() => {
this.addressProvince=res.RECIVER_PROVINCE; this.addressProvince=res.data[0].RECIVER_PROVINCE;
this.addressCity=res.RECIVER_CITY; this.addressCity=res.data[0].RECIVER_CITY;
this.addressRegion=resizeBy.RECIVER_REGION; this.addressRegion=res.data[0].RECIVER_REGION;
res.WORK_TIME_START=this.timeGet(res.WORK_TIME)[0] res.data[0].WORK_TIME_START=this.timeGet(res.data[0].WORK_TIME)[0]
res.WORK_TIME_END=this.timeGet(res.WORK_TIME)[1] res.data[0].WORK_TIME_END=this.timeGet(res.data[0].WORK_TIME)[1]
res.DELIVERY_TIME_START=this.timeGet(res.DELIVERY_TIME)[0] res.data[0].DELIVERY_TIME_START=this.timeGet(res.data[0].DELIVERY_TIME)[0]
res.DELIVERY_TIME_END=this.timeGet(res.DELIVERY_TIME)[1] res.data[0].DELIVERY_TIME_END=this.timeGet(res.data[0].DELIVERY_TIME)[1]
if(res.LICENCE_IMAGE_PATH){ if(res.data[0].LICENCE_IMAGE_PATH){
this.fileList.push({ this.fileList.push({
uid:'-1', uid:'-1',
name:'test.png', name:'test.png',
status:'done', status:'done',
url:res.LICENCE_IMAGE_PATH, url:res.data[0].LICENCE_IMAGE_PATH,
}) })
} }
if(res.BRANCH_IMAGE_PATH){ if(res.data[0].BRANCH_IMAGE_PATH){
this.BranchfileList.push({ this.BranchfileList.push({
uid:'-1', uid:'-1',
name:'test.png', name:'test.png',
status:'done', status:'done',
url:res.BRANCH_IMAGE_PATH, url:res.data[0].BRANCH_IMAGE_PATH,
}) })
} }
console.log(res) console.log(res.data[0])
this.form.setFieldsValue(res) this.form.setFieldsValue(res.data[0])
}) })
}).catch(err => { }).catch(err => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment