创建商品转跳店铺状态维护
This commit is contained in:
@@ -10,8 +10,8 @@ import router from '../router'
|
|||||||
|
|
||||||
// 基础配置
|
// 基础配置
|
||||||
const config = {
|
const config = {
|
||||||
// apiUrl : 'https://oapi.lianshang.vip/api/', // 正式环境
|
apiUrl : 'https://oapi.lianshang.vip/api/', // 正式环境
|
||||||
apiUrl : 'http://api.ahxh.shangkelian.cn/api/', // 测试环境
|
// apiUrl : 'http://api.ahxh.shangkelian.cn/api/', // 测试环境
|
||||||
apiUrls : 'https://storage.lianshang.vip/', // 图片路径(测试/正式)
|
apiUrls : 'https://storage.lianshang.vip/', // 图片路径(测试/正式)
|
||||||
timeout : 60000
|
timeout : 60000
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -279,7 +279,6 @@
|
|||||||
padding-left: 200rpx;
|
padding-left: 200rpx;
|
||||||
line-height: 90rpx;
|
line-height: 90rpx;
|
||||||
min-height: 90rpx;
|
min-height: 90rpx;
|
||||||
|
|
||||||
label {
|
label {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@@ -287,18 +286,15 @@
|
|||||||
width: 200rpx;
|
width: 200rpx;
|
||||||
font-size: $title-size;
|
font-size: $title-size;
|
||||||
}
|
}
|
||||||
|
|
||||||
input {
|
input {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 90rpx;
|
height: 90rpx;
|
||||||
line-height: 90rpx;
|
line-height: 90rpx;
|
||||||
font-size: $title-size;
|
font-size: $title-size;
|
||||||
}
|
}
|
||||||
|
|
||||||
.picker-text {
|
.picker-text {
|
||||||
position: relative;
|
position: relative;
|
||||||
padding-right: 90rpx;
|
padding-right: 90rpx;
|
||||||
|
|
||||||
.picker-icon {
|
.picker-icon {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0;
|
right: 0;
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="info-item" v-if="details.type.value === 2">
|
<view class="info-item" v-if="details.type.value === 2">
|
||||||
<view class="info-item-title">满减</view>
|
<view class="info-item-title">满减</view>
|
||||||
<view class="info-item-text">满{{details.price}}减{{details.full}}</view>
|
<view class="info-item-text">满{{details.full}}减{{details.price}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="info-item">
|
<view class="info-item">
|
||||||
<view class="info-item-title">券发放量</view>
|
<view class="info-item-title">券发放量</view>
|
||||||
|
|||||||
@@ -149,18 +149,31 @@
|
|||||||
<!-- 选择店铺 -->
|
<!-- 选择店铺 -->
|
||||||
<uni-popup ref="storePopup">
|
<uni-popup ref="storePopup">
|
||||||
<view class="category-popup">
|
<view class="category-popup">
|
||||||
<view class="header">
|
<block v-if="storesArr.length <0">
|
||||||
<view class="title">选择店铺</view>
|
<view class="header">
|
||||||
</view>
|
<view class="title">选择店铺</view>
|
||||||
<view class="category-flex">
|
|
||||||
<view class="category-flex-item" :class="{'show' : item.check}" v-for="(item, index) in storesArr" :key="index" @click="item.check = !item.check">
|
|
||||||
<view class="category-name">{{item.name}}</view>
|
|
||||||
<view class="category-content">{{item.address}}</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
<view class="category-flex">
|
||||||
<view class="btns">
|
<view class="category-flex-item" :class="{'show' : item.check}" v-for="(item, index) in storesArr" :key="index" @click="item.check = !item.check">
|
||||||
<button type="default" size="default" @click="affirmCategory('stores', 'storePopup')">确定</button>
|
<view class="category-name">{{item.name}}</view>
|
||||||
</view>
|
<view class="category-content">{{item.address}}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="btns">
|
||||||
|
<button type="default" size="default" @click="affirmCategory('stores', 'storePopup')">确定</button>
|
||||||
|
</view>
|
||||||
|
</block>
|
||||||
|
<block v-else>
|
||||||
|
<no-list name="no-shop" txt='您还没有创建店铺~' />
|
||||||
|
<view class="btns" v-if="storePer">
|
||||||
|
<button type="default" size="default" @click="$Router.push({name:'shopCreate'})">新建店铺</button>
|
||||||
|
</view>
|
||||||
|
<view class=""v-else>
|
||||||
|
<view class="btns" v-if="storePer">
|
||||||
|
<button type="default" size="default">当前没有创建店铺的权限</button>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</block>
|
||||||
</view>
|
</view>
|
||||||
</uni-popup>
|
</uni-popup>
|
||||||
<!-- 安全区 -->
|
<!-- 安全区 -->
|
||||||
@@ -207,6 +220,7 @@
|
|||||||
tagsIndex : 0, // 选择标签的下标
|
tagsIndex : 0, // 选择标签的下标
|
||||||
servicesArr : [], // 可选服务
|
servicesArr : [], // 可选服务
|
||||||
type : 1, // 1为商品,2为服务
|
type : 1, // 1为商品,2为服务
|
||||||
|
storePer : true,// 默认可以创建门店
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed:{
|
computed:{
|
||||||
@@ -214,6 +228,12 @@
|
|||||||
return this.percent * this.skus_price
|
return this.percent * this.skus_price
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
beforeRouteLeave(to, from, next){
|
||||||
|
console.log(to)
|
||||||
|
console.log(from)
|
||||||
|
console.log(next)
|
||||||
|
next()
|
||||||
|
},
|
||||||
created() {
|
created() {
|
||||||
// 编辑状态信息
|
// 编辑状态信息
|
||||||
if(this.$Route.query.type && this.$Route.query.type === 'edit'){
|
if(this.$Route.query.type && this.$Route.query.type === 'edit'){
|
||||||
@@ -258,7 +278,7 @@
|
|||||||
this.services = services
|
this.services = services
|
||||||
this.stores = stores
|
this.stores = stores
|
||||||
this.percent = Number(res.percent)
|
this.percent = Number(res.percent)
|
||||||
|
this.storePer = res.storePer
|
||||||
|
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -291,6 +311,7 @@
|
|||||||
this.categoryId = this.$Route.query.id
|
this.categoryId = this.$Route.query.id
|
||||||
this.categoryCid= this.$Route.query.cid
|
this.categoryCid= this.$Route.query.cid
|
||||||
this.percent = Number(res.percent)
|
this.percent = Number(res.percent)
|
||||||
|
this.storePer = res.storePer
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: err.message,
|
title: err.message,
|
||||||
@@ -633,7 +654,7 @@
|
|||||||
.btns{
|
.btns{
|
||||||
padding-top: $padding * 2;
|
padding-top: $padding * 2;
|
||||||
button{
|
button{
|
||||||
background: $text-price;
|
background: $mian-color;
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
height: 90rpx;
|
height: 90rpx;
|
||||||
line-height: 90rpx;
|
line-height: 90rpx;
|
||||||
|
|||||||
@@ -173,11 +173,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<!-- 企业工具 -->
|
<!-- 企业工具 -->
|
||||||
<view class="userPartner" v-if="userData.is_company">
|
<view class="userPartner" v-if="userData.is_company">
|
||||||
<view class="partner-title">
|
<view class="partner-title">企业工具</view>
|
||||||
企业工具
|
|
||||||
</view>
|
|
||||||
<!-- orderShipment -->
|
|
||||||
<!-- orderRefund -->
|
|
||||||
<view class="tool-list">
|
<view class="tool-list">
|
||||||
<view class="tool-label" v-if="permission.manageGoods" @click="$Router.push({name: 'goodsManagement'})">
|
<view class="tool-label" v-if="permission.manageGoods" @click="$Router.push({name: 'goodsManagement'})">
|
||||||
<image class="tool-label-img" src="/static/user/userTool-00.png" mode=""></image>
|
<image class="tool-label-img" src="/static/user/userTool-00.png" mode=""></image>
|
||||||
@@ -209,6 +205,12 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="userPartner" style="display: flex;flex-direction: column;" v-else>
|
||||||
|
<block v-if="companyCreateInfo.code !== 1" >
|
||||||
|
<view class="partner-title"> 企业工具</view>
|
||||||
|
<view class="onOpen" @click="company(companyCreateInfo.code)">{{companyCreateInfo.code === -1?'立即开通企业认证':companyCreateInfo.code === 0?'企业认证审核中':companyCreateInfo.code === 2?'企业认证被已驳回':''}}</view>
|
||||||
|
</block>
|
||||||
|
</view>
|
||||||
<!-- 我的权证 -->
|
<!-- 我的权证 -->
|
||||||
<view class="userPartner">
|
<view class="userPartner">
|
||||||
<view class="partner-title">
|
<view class="partner-title">
|
||||||
@@ -268,6 +270,7 @@
|
|||||||
userNotice,
|
userNotice,
|
||||||
userCustomer
|
userCustomer
|
||||||
} from '@/apis/interfaces/user'
|
} from '@/apis/interfaces/user'
|
||||||
|
import {companyStatus,companyIsallow} from '@/apis/interfaces/setting.js'
|
||||||
import h5Copy from '@/js_sdk/junyi-h5-copy/junyi-h5-copy/junyi-h5-copy'
|
import h5Copy from '@/js_sdk/junyi-h5-copy/junyi-h5-copy/junyi-h5-copy'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
@@ -298,7 +301,8 @@
|
|||||||
},
|
},
|
||||||
// 是否为企业主
|
// 是否为企业主
|
||||||
isOwnCompany: false,
|
isOwnCompany: false,
|
||||||
shoeCardType: false
|
shoeCardType: false,
|
||||||
|
companyCreateInfo:{},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
@@ -313,6 +317,8 @@
|
|||||||
|
|
||||||
// 获取公告列表
|
// 获取公告列表
|
||||||
this.newInfo();
|
this.newInfo();
|
||||||
|
|
||||||
|
this.companyStatus()
|
||||||
},
|
},
|
||||||
onHide() {
|
onHide() {
|
||||||
// 移除vip模块跳动样式
|
// 移除vip模块跳动样式
|
||||||
@@ -338,6 +344,53 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 获取企业认证状态
|
||||||
|
companyStatus(){
|
||||||
|
companyStatus().then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
this.companyCreateInfo = res
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 是否展示企业信息 企业认证 -1.未认证,0.审核中,1.审核通过,2.驳回
|
||||||
|
company(code) {
|
||||||
|
console.log(code)
|
||||||
|
if (code === -1) {
|
||||||
|
// 跳转到企业认证页面
|
||||||
|
companyIsallow().then(res=>{
|
||||||
|
this.$Router.push({
|
||||||
|
name:'companyApprove'
|
||||||
|
})
|
||||||
|
}).catch(err=>{
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: err.message,
|
||||||
|
type: 'primary',
|
||||||
|
duration: 3000
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
} else if (code === 2) {
|
||||||
|
// 跳转到企业认证页面
|
||||||
|
this.$Router.push({
|
||||||
|
name:'companyApprove',
|
||||||
|
params:{
|
||||||
|
form_type:'put'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else if (code === 0) {
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '审核中',
|
||||||
|
type: 'primary',
|
||||||
|
duration: 3000
|
||||||
|
})
|
||||||
|
} else if (code === 1) {
|
||||||
|
// 跳转到企业认证页面
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '认证通过!',
|
||||||
|
type: 'primary',
|
||||||
|
duration: 3000
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
// 开通VIP
|
// 开通VIP
|
||||||
openVip(identityId) {
|
openVip(identityId) {
|
||||||
// if (!this.userData.certification) {
|
// if (!this.userData.certification) {
|
||||||
@@ -924,7 +977,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 我的伙伴
|
// 我的伙伴
|
||||||
.userPartner {
|
.userPartner {
|
||||||
margin-bottom: 30rpx;
|
margin-bottom: 30rpx;
|
||||||
@@ -933,6 +985,20 @@
|
|||||||
padding: 30rpx 0;
|
padding: 30rpx 0;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
border-radius: 15rpx;
|
border-radius: 15rpx;
|
||||||
|
|
||||||
|
.onOpen{
|
||||||
|
background-color: #ee4c47;
|
||||||
|
color: #FFFFFF;
|
||||||
|
padding: 10rpx 40rpx;
|
||||||
|
width:400rpx;
|
||||||
|
border-radius: 30rpx;
|
||||||
|
display: inline-block;
|
||||||
|
text-align: center;
|
||||||
|
margin-top: 30rpx;
|
||||||
|
position: relative;
|
||||||
|
margin-left: -200rpx;
|
||||||
|
left: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
.partner-title {
|
.partner-title {
|
||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
|
|||||||
21
unpackage/dist/build/app-plus/app-service.js
vendored
21
unpackage/dist/build/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
1
unpackage/dist/build/app-plus/app-view.js
vendored
1
unpackage/dist/build/app-plus/app-view.js
vendored
File diff suppressed because one or more lines are too long
1
unpackage/dist/build/app-plus/manifest.json
vendored
1
unpackage/dist/build/app-plus/manifest.json
vendored
File diff suppressed because one or more lines are too long
3867
unpackage/dist/dev/app-plus/app-service.js
vendored
3867
unpackage/dist/dev/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
1
unpackage/dist/dev/app-plus/manifest.json
vendored
1
unpackage/dist/dev/app-plus/manifest.json
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user