Merge pull request '邓洁 : 修改细节' (#45) from dj into master
Reviewed-on: http://git.feashow.cn/odjbin/city-store-transfer/pulls/45
This commit is contained in:
@@ -47,7 +47,6 @@
|
|||||||
this.getNotice()
|
this.getNotice()
|
||||||
this.getStat()
|
this.getStat()
|
||||||
this.open()
|
this.open()
|
||||||
this.getRegionList()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getBanner(){
|
getBanner(){
|
||||||
@@ -89,8 +88,6 @@
|
|||||||
success(res) {
|
success(res) {
|
||||||
console.log('res.latitude', res.latitude);
|
console.log('res.latitude', res.latitude);
|
||||||
console.log('res.longitude', res.longitude);
|
console.log('res.longitude', res.longitude);
|
||||||
uni.setStorageSync('latitude', res.latitude);
|
|
||||||
uni.setStorageSync('longitude', res.longitude);
|
|
||||||
qqmapsdk.reverseGeocoder({
|
qqmapsdk.reverseGeocoder({
|
||||||
location: {
|
location: {
|
||||||
latitude: res.latitude,
|
latitude: res.latitude,
|
||||||
@@ -106,6 +103,7 @@
|
|||||||
uni.setStorageSync('city_code', re.result.ad_info.city_code.substring(3));
|
uni.setStorageSync('city_code', re.result.ad_info.city_code.substring(3));
|
||||||
uni.setStorageSync('city', city.slice(0, 2));
|
uni.setStorageSync('city', city.slice(0, 2));
|
||||||
uni.setStorageSync('district', district);
|
uni.setStorageSync('district', district);
|
||||||
|
that.getRegionList()
|
||||||
// that.position = city.slice(0, 2) + district.slice(0, 2)
|
// that.position = city.slice(0, 2) + district.slice(0, 2)
|
||||||
},
|
},
|
||||||
fail: (re) => {
|
fail: (re) => {
|
||||||
|
|||||||
@@ -6,55 +6,61 @@
|
|||||||
<text class="count">发布房源图片({{ShopInfomation.count}}/5)</text>
|
<text class="count">发布房源图片({{ShopInfomation.count}}/5)</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<u-form-item label="标题" label-position="top" border-bottom="true" prop="title">
|
<u-form-item label="标题" label-position="top" border-bottom="true" prop="title">
|
||||||
<u-input v-model="form.title" placeholder="请输入标题以便吸引人的注意哦" placeholder-class="input-class" border="none"></u-input>
|
<u-input v-model="form.title" placeholder="请输入标题以便吸引人的注意哦" placeholder-class="input-class"
|
||||||
</u-form-item>
|
border="none"></u-input>
|
||||||
<u-form-item label="区域" label-position="top" border-bottom="true" right-icon="arrow-right" prop="region">
|
</u-form-item>
|
||||||
<text @click="show1 = true" class="checktext">请选择所属区域</text>
|
<u-form-item label="区域" label-position="top" border-bottom="true" right-icon="arrow-right" prop="region">
|
||||||
<view class="arrow-icon">
|
<text @click="show1 = true" class="checktext">请选择所属区域</text>
|
||||||
<u-icon name="arrow-right" size="30px"></u-icon>
|
<view class="arrow-icon">
|
||||||
</view>
|
<u-icon name="arrow-right" size="30px"></u-icon>
|
||||||
<u-picker :columns="regionColumns" :show="show1" :closeOnClickOverlay="true" @close="show1 = false" v-model="form.region"></u-picker>
|
</view>
|
||||||
</u-form-item>
|
<u-picker :columns="regionColumns" :show="show1" :closeOnClickOverlay="true" @close="show1 = false"
|
||||||
<u-form-item label="地址" label-position="top" border-bottom="true" prop="place">
|
v-model="form.region"></u-picker>
|
||||||
<u-input v-model="form.place" placeholder="请输入店铺地址" placeholder-class="input-class" border="none" ></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="地址" label-position="top" border-bottom="true" prop="place">
|
||||||
<u-form-item label="行业" label-position="top" border-bottom="true" class="picker">
|
<u-input v-model="form.place" placeholder="请输入店铺地址" placeholder-class="input-class" border="none"
|
||||||
<text @click="show2 = true" class="checktext">请选择行业类型</text>
|
@change="change"></u-input>
|
||||||
<view class="arrow-icon">
|
</u-form-item>
|
||||||
<u-icon name="arrow-right" size="30px"></u-icon>
|
<u-form-item label="行业" label-position="top" border-bottom="true" class="picker">
|
||||||
</view>
|
<text @click="show2 = true" class="checktext">请选择行业类型</text>
|
||||||
<u-picker mode="region" :show="show2" :closeOnClickOverlay="true" @close="show2 = false" v-model="form.trade"></u-picker>
|
<view class="arrow-icon">
|
||||||
</u-form-item>
|
<u-icon name="arrow-right" size="30px"></u-icon>
|
||||||
<u-form-item label="业态" label-position="top" border-bottom="true">
|
</view>
|
||||||
<text @click="show3 = true" class="checktext">请选择行业业态</text>
|
<u-picker mode="region" :show="show2" :closeOnClickOverlay="true" @close="show2 = false"
|
||||||
<view class="arrow-icon">
|
v-model="form.trade"></u-picker>
|
||||||
<u-icon name="arrow-right" size="30px"></u-icon>
|
</u-form-item>
|
||||||
</view>
|
<u-form-item label="业态" label-position="top" border-bottom="true">
|
||||||
<u-picker mode="region" :show="show3" :closeOnClickOverlay="true" @close="show3 = false" v-model="form.karma"></u-picker>
|
<text @click="show3 = true" class="checktext">请选择行业业态</text>
|
||||||
</u-form-item>
|
<view class="arrow-icon">
|
||||||
<u-form-item label="面积" label-position="top" border-bottom="true" prop="size">
|
<u-icon name="arrow-right" size="30px"></u-icon>
|
||||||
<u-input v-model="form.size" placeholder="请输入店铺面积" placeholder-class="input-class" border="none"></u-input>
|
</view>
|
||||||
</u-form-item>
|
<u-picker mode="region" :show="show3" :closeOnClickOverlay="true" @close="show3 = false"
|
||||||
<u-form-item label="租金(元/月)" label-position="top" border-bottom="true" label-width="100%" prop="rent">
|
v-model="form.karma"></u-picker>
|
||||||
<u-input v-model="form.rent" placeholder="请输入店铺租金" placeholder-class="input-class" border="none"></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="面积" label-position="top" border-bottom="true" prop="size">
|
||||||
<u-form-item label="转让费(万元)" label-position="top" border-bottom="true" label-width="100%" prop="sell">
|
<u-input v-model="form.size" placeholder="请输入店铺面积" placeholder-class="input-class" border="none"></u-input>
|
||||||
<u-input v-model="form.sell" placeholder="请输入店铺转让费" placeholder-class="input-class" border="none"></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="租金(元/月)" label-position="top" border-bottom="true" label-width="100%" prop="rent">
|
||||||
<u-form-item label="联系人" label-position="top" border-bottom="true" label-width="100%" prop="name">
|
<u-input v-model="form.rent" placeholder="请输入店铺租金" placeholder-class="input-class" border="none"></u-input>
|
||||||
<u-input v-model="form.name" placeholder="请输入联系人姓名" placeholder-class="input-class" border="none"></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="转让费(万元)" label-position="top" border-bottom="true" label-width="100%" prop="sell">
|
||||||
<u-form-item label="手机号码" label-position="top" border-bottom="true" label-width="100%" prop="call">
|
<u-input v-model="form.sell" placeholder="请输入店铺转让费" placeholder-class="input-class" border="none"></u-input>
|
||||||
<u-input v-model="form.call" placeholder="请输入联系人手机号码" placeholder-class="input-class" border="none"></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="联系人" label-position="top" border-bottom="true" label-width="100%" prop="name">
|
||||||
<u-form-item label="详情介绍" label-position="top" border-bottom="true" label-width="100%" prop="introduce">
|
<u-input v-model="form.name" placeholder="请输入联系人姓名" placeholder-class="input-class" border="none"></u-input>
|
||||||
<u-input v-model="form.introduce" placeholder="请输入介绍详情" placeholder-class="input-class" border="none"></u-input>
|
</u-form-item>
|
||||||
</u-form-item>
|
<u-form-item label="手机号码" label-position="top" border-bottom="true" label-width="100%" prop="call">
|
||||||
</u-form>
|
<u-input v-model="form.call" placeholder="请输入联系人手机号码" placeholder-class="input-class" border="none"></u-input>
|
||||||
<view class="bug-figure"></view>
|
</u-form-item>
|
||||||
<u-button @click="submit" color="linear-gradient(to right, #E86262, #CC3333)" :size="normal" shape="circle" class="submit-btn">发布</u-button>
|
<u-form-item label="详情介绍" label-position="top" border-bottom="true" label-width="100%" prop="introduce">
|
||||||
<view class="bug-figure"></view>
|
<u-input v-model="form.introduce" placeholder="请输入介绍详情" placeholder-class="input-class" border="none"></u-input>
|
||||||
|
</u-form-item>
|
||||||
|
</u-form>
|
||||||
|
<view class="bug-figure"></view>
|
||||||
|
<u-button @click="submit" color="linear-gradient(to right, #E86262, #CC3333)" :size="normal" shape="circle"
|
||||||
|
class="submit-btn">发布</u-button>
|
||||||
|
<view class="bug-figure"></view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -62,91 +68,96 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
regionColumns:[JSON.parse(uni.getStorageSync('regionList'))]||[],
|
regionColumns: [JSON.parse(uni.getStorageSync('regionList'))] || [],
|
||||||
ShopInfomation:{
|
ShopInfomation: {
|
||||||
city:'',
|
city: '',
|
||||||
area:'',
|
area: '',
|
||||||
count:0,
|
count: 0,
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
form:{
|
form: {
|
||||||
title:'',
|
title: '',
|
||||||
region:'',
|
region: '',
|
||||||
place:'',
|
place: '',
|
||||||
trade:'',
|
trade: '',
|
||||||
karma:'',
|
karma: '',
|
||||||
size:'',
|
size: '',
|
||||||
rent:'',
|
rent: '',
|
||||||
sell:'',
|
sell: '',
|
||||||
name:'',
|
name: '',
|
||||||
call:'',
|
call: '',
|
||||||
introduce:''
|
introduce: ''
|
||||||
},
|
},
|
||||||
columns:[
|
columns: [
|
||||||
|
|
||||||
],
|
],
|
||||||
show1:false,
|
show1: false,
|
||||||
show2:false,
|
show2: false,
|
||||||
show3:false,
|
show3: false,
|
||||||
rules:{
|
rules: {
|
||||||
'title':[{
|
'title': [{
|
||||||
type:'string',
|
type: 'string',
|
||||||
require:true,
|
require: true,
|
||||||
message:'请输入姓名',
|
message: '请输入姓名',
|
||||||
trigger: ['change','blur']
|
trigger: ['change', 'blur']
|
||||||
}],
|
}],
|
||||||
'place':[{
|
'place': [{
|
||||||
type:'string',
|
type: 'string',
|
||||||
require:true,
|
require: true,
|
||||||
message:'请输入地址',
|
message: '请输入地址',
|
||||||
trigger:['change','blur']
|
trigger: ['change', 'blur']
|
||||||
}],
|
}],
|
||||||
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleSearchAddress() {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages/publish/chooseAddress/chooseAddress'
|
||||||
|
})
|
||||||
|
},
|
||||||
confirmArea(e) {
|
confirmArea(e) {
|
||||||
this.ShopInfomation.city = e.value[0]
|
this.ShopInfomation.city = e.value[0]
|
||||||
this.ShopInfomation.area = e.value[1]
|
this.ShopInfomation.area = e.value[1]
|
||||||
this.show1 = false
|
this.show1 = false
|
||||||
},
|
},
|
||||||
submit() {
|
submit() {
|
||||||
this.$refs.uForm.validate().then(res => {
|
this.$refs.uForm.validate().then(res => {
|
||||||
console.log("提交表单信息:" + JSON.stringify(this.form))
|
console.log("提交表单信息:" + JSON.stringify(this.form))
|
||||||
uni.$u.toast('发布成功')
|
uni.$u.toast('发布成功')
|
||||||
// 调用服务端入表接口W
|
// 调用服务端入表接口W
|
||||||
}).catch(errors => {
|
}).catch(errors => {
|
||||||
console.log("失败信息:" + JSON.stringify(errors))
|
console.log("失败信息:" + JSON.stringify(errors))
|
||||||
// uni.$u.toast('校验失败')
|
// uni.$u.toast('校验失败')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onReady() {
|
onReady() {
|
||||||
this.$refs.uForm.setRules(this.rules)
|
this.$refs.uForm.setRules(this.rules)
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.count{
|
.count {}
|
||||||
|
|
||||||
}
|
.form {
|
||||||
.form{
|
|
||||||
margin-left: 20px;
|
margin-left: 20px;
|
||||||
margin-right: 20px;
|
margin-right: 20px;
|
||||||
}
|
}
|
||||||
.input-class{
|
|
||||||
|
.input-class {
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
font-weight:1px;
|
font-weight: 1px;
|
||||||
border-style: none;
|
border-style: none;
|
||||||
|
|
||||||
}
|
}
|
||||||
.upload{
|
|
||||||
|
.upload {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -155,28 +166,33 @@
|
|||||||
height: 300rpx;
|
height: 300rpx;
|
||||||
// margin-right: 20px;
|
// margin-right: 20px;
|
||||||
}
|
}
|
||||||
.submit-btn{
|
|
||||||
|
.submit-btn {
|
||||||
width: 80%;
|
width: 80%;
|
||||||
}
|
}
|
||||||
.bug-figure{
|
|
||||||
|
.bug-figure {
|
||||||
height: 100rpx;
|
height: 100rpx;
|
||||||
}
|
}
|
||||||
.checkbox1{
|
|
||||||
|
.checkbox1 {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.checktext{
|
|
||||||
|
.checktext {
|
||||||
margin-top: 5rpx;
|
margin-top: 5rpx;
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
font-weight:1px;
|
font-weight: 1px;
|
||||||
color: #c1c4c7;
|
color: #c1c4c7;
|
||||||
}
|
}
|
||||||
|
|
||||||
.picker{
|
.picker {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.arrow-icon{
|
|
||||||
|
.arrow-icon {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 10rpx;
|
right: 10rpx;
|
||||||
transform: translateY(-20rpx);
|
transform: translateY(-20rpx);
|
||||||
|
|||||||
Reference in New Issue
Block a user