|
@@ -77,6 +77,12 @@
|
|
|
<view class="tui-title ">门牌</view>
|
|
<view class="tui-title ">门牌</view>
|
|
|
<input v-model="form.floor" placeholder-class="phcolor" class="tui-input" name="floor" placeholder="楼号门牌号(选填)" />
|
|
<input v-model="form.floor" placeholder-class="phcolor" class="tui-input" name="floor" placeholder="楼号门牌号(选填)" />
|
|
|
</tui-list-cell>
|
|
</tui-list-cell>
|
|
|
|
|
+
|
|
|
|
|
+ <tui-list-cell class="line-cell" :hover="false">
|
|
|
|
|
+ <view class="tui-title ">打包费</view>
|
|
|
|
|
+ <input v-model="form.packCost" @focus="form.packCost=''" placeholder-class="phcolor" class="tui-input" name="packCost" placeholder="打包费" />
|
|
|
|
|
+ </tui-list-cell>
|
|
|
|
|
+
|
|
|
<tui-list-cell class="line-cell remark-wrap" :hover="false">
|
|
<tui-list-cell class="line-cell remark-wrap" :hover="false">
|
|
|
<view class="tui-title">简介</view>
|
|
<view class="tui-title">简介</view>
|
|
|
<view class="tui-input">
|
|
<view class="tui-input">
|
|
@@ -104,6 +110,7 @@ import AppUploader from "@/components/app-uploader";
|
|
|
const form = require('@/utils/formValidation.js')
|
|
const form = require('@/utils/formValidation.js')
|
|
|
import { updateShop as update, addShop as add } from '@/api/shop'
|
|
import { updateShop as update, addShop as add } from '@/api/shop'
|
|
|
import {mapActions} from "vuex";
|
|
import {mapActions} from "vuex";
|
|
|
|
|
+import {getDetail} from "@/api/shop"
|
|
|
export default {
|
|
export default {
|
|
|
name: 'staff-add',
|
|
name: 'staff-add',
|
|
|
components: {
|
|
components: {
|
|
@@ -132,6 +139,7 @@ export default {
|
|
|
openEndTime: '',
|
|
openEndTime: '',
|
|
|
introduction: '',
|
|
introduction: '',
|
|
|
mobile: '',
|
|
mobile: '',
|
|
|
|
|
+ packCost:0,
|
|
|
img: []
|
|
img: []
|
|
|
},
|
|
},
|
|
|
showRegion: false,
|
|
showRegion: false,
|
|
@@ -159,35 +167,41 @@ export default {
|
|
|
methods: {
|
|
methods: {
|
|
|
...mapActions(['setUserShopAll']),
|
|
...mapActions(['setUserShopAll']),
|
|
|
init() {
|
|
init() {
|
|
|
- this._getDet()
|
|
|
|
|
|
|
+ this._getDet()
|
|
|
},
|
|
},
|
|
|
_resultData(val) {
|
|
_resultData(val) {
|
|
|
console.log(val)
|
|
console.log(val)
|
|
|
this.form.img = val;
|
|
this.form.img = val;
|
|
|
},
|
|
},
|
|
|
_getDet() {
|
|
_getDet() {
|
|
|
- let data = uni.getStorageSync('modifyShopB')
|
|
|
|
|
- if (this.$util.isEmpty(data)) return
|
|
|
|
|
- Object.keys(this.form).forEach((i, index) => {
|
|
|
|
|
- this.form[i] = data[i]
|
|
|
|
|
- })
|
|
|
|
|
- this.region.lat = data.lat
|
|
|
|
|
- this.region.long = data.long
|
|
|
|
|
|
|
|
|
|
- this.visible = this.form.open == 1 ? true : false
|
|
|
|
|
- this.openTimeVisible = true
|
|
|
|
|
- this.form.openType = 1
|
|
|
|
|
- this.start_time = this.form.openStartTime
|
|
|
|
|
- this.end_time = this.form.openEndTime
|
|
|
|
|
- if (data.openStartTime == '') {
|
|
|
|
|
- this.openTimeVisible = false
|
|
|
|
|
- this.form.openType = 0
|
|
|
|
|
- this.start_time = '09:00'
|
|
|
|
|
- this.form.openStartTime = this.start_time
|
|
|
|
|
- }
|
|
|
|
|
- if (data.openEndTime == '') {
|
|
|
|
|
- this.end_time = '18:00'
|
|
|
|
|
- this.form.openEndTime = this.end_time
|
|
|
|
|
|
|
+ if(this.option.id && !this.$util.isEmpty(this.option.id)){
|
|
|
|
|
+ getDetail({shopId:this.option.id}).then(res=>{
|
|
|
|
|
+ let data = res.data.info
|
|
|
|
|
+
|
|
|
|
|
+ if (this.$util.isEmpty(data)) return
|
|
|
|
|
+ Object.keys(this.form).forEach((i, index) => {
|
|
|
|
|
+ this.form[i] = data[i]
|
|
|
|
|
+ })
|
|
|
|
|
+ this.region.lat = data.lat
|
|
|
|
|
+ this.region.long = data.long
|
|
|
|
|
+
|
|
|
|
|
+ this.visible = this.form.open == 1 ? true : false
|
|
|
|
|
+ this.openTimeVisible = true
|
|
|
|
|
+ this.form.openType = 1
|
|
|
|
|
+ this.start_time = this.form.openStartTime
|
|
|
|
|
+ this.end_time = this.form.openEndTime
|
|
|
|
|
+ if (data.openStartTime == '') {
|
|
|
|
|
+ this.openTimeVisible = false
|
|
|
|
|
+ this.form.openType = 0
|
|
|
|
|
+ this.start_time = '09:00'
|
|
|
|
|
+ this.form.openStartTime = this.start_time
|
|
|
|
|
+ }
|
|
|
|
|
+ if (data.openEndTime == '') {
|
|
|
|
|
+ this.end_time = '18:00'
|
|
|
|
|
+ this.form.openEndTime = this.end_time
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
openChange(e) {
|
|
openChange(e) {
|
|
@@ -314,7 +328,7 @@ export default {
|
|
|
.remark-wrap {
|
|
.remark-wrap {
|
|
|
align-items: flex-start;
|
|
align-items: flex-start;
|
|
|
.remark {
|
|
.remark {
|
|
|
- height: 240upx;
|
|
|
|
|
|
|
+ height: 180upx;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|