add
This commit is contained in:
parent
b69e51fe9f
commit
a0ed531272
@ -38,7 +38,9 @@ export const aboutUsApi = (data) => {
|
||||
|
||||
|
||||
export const applysApi = (data) => {
|
||||
return request.post('shop/index/apply', data);
|
||||
return request.post('shop/index/apply', data, {
|
||||
tokenName: 1
|
||||
});
|
||||
}
|
||||
|
||||
export const merchatTypeApi = (data) => {
|
||||
@ -48,8 +50,23 @@ export const merchatTypeApi = (data) => {
|
||||
}
|
||||
|
||||
export const getSTokenApi = (data) => {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', 'asdfdsfsdfsdfds')
|
||||
return request.get('shop/index/get_token', data, {
|
||||
tokenName: 1
|
||||
});
|
||||
}
|
||||
|
||||
export const getapplyRecordApi = (data) => {
|
||||
return request.get('shop/index/record', data, {
|
||||
tokenName: 1
|
||||
});
|
||||
}
|
||||
|
||||
export const reSubmitApi = (data) => {
|
||||
return request.get('shop/index/apply_detail', data, {
|
||||
tokenName: 1
|
||||
});
|
||||
}
|
||||
|
||||
export const UserWithdrawListsdate_listsApi = (data) => {
|
||||
return request.get('operation/OpurchaseGoodsOffer/date_lists', data);
|
||||
}
|
@ -15,9 +15,9 @@ let openPlantGrass = '-openPlantGrass-'
|
||||
|
||||
let httpSix, httpApi, httpTwo;
|
||||
|
||||
// const env = 'dev'; // 开发
|
||||
const env = 'dev'; // 开发
|
||||
// const env = 'prod'; // 生产
|
||||
const env = 'prew'; // 预上线
|
||||
// const env = 'prew'; // 预上线
|
||||
|
||||
switch (env) {
|
||||
case 'prod':
|
||||
@ -29,15 +29,13 @@ switch (env) {
|
||||
case 'prew':
|
||||
httpApi = 'https://test.shop.lihaink.cn' //预发布环境
|
||||
httpSix = 'https://ceshi-new-wokr.lihaink.cn'
|
||||
httpTwo = 'http://192.168.1.22:8546'
|
||||
httpTwo = 'https://erp.lihaink.cn'
|
||||
wsApi = 'wss://test.shop.lihaink.cn'
|
||||
break;
|
||||
default:
|
||||
httpApi = "https://crmeb-test.shop.lihaink.cn" // 测试
|
||||
httpSix = 'https://ceshi-new-wokr.lihaink.cn'
|
||||
// httpTwo = 'https://erp.lihaink.cn'
|
||||
httpTwo = 'http://192.168.1.22:8546'
|
||||
// wsApi = 'ws://192.168.1.22:8324'
|
||||
httpTwo = 'https://erp.lihaink.cn'
|
||||
wsApi = 'wss://crmeb-test.shop.lihaink.cn'
|
||||
}
|
||||
|
||||
|
@ -2,8 +2,8 @@
|
||||
"name": "惠农生活",
|
||||
"appid": "__UNI__3A527D1",
|
||||
"description": "",
|
||||
"versionName": "2.0.55",
|
||||
"versionCode": 2055,
|
||||
"versionName": "2.0.56",
|
||||
"versionCode": 2056,
|
||||
"transformPx": false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus": {
|
||||
|
23
pages.json
23
pages.json
@ -61,8 +61,7 @@
|
||||
"path": "pages/quote/list",
|
||||
"style": {
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationBarTitleText": "报价",
|
||||
"navigationStyle": "custom"
|
||||
"navigationBarTitleText": "报价"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -96,10 +95,17 @@
|
||||
{
|
||||
"path": "pages/bindSupplier/index",
|
||||
"style": {
|
||||
"enablePullDownRefresh": false,
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "供应商入驻"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/bindSupplier/record",
|
||||
"style": {
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationBarTitleText": "申请记录"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/gather/gather",
|
||||
"style": {
|
||||
@ -1657,13 +1663,6 @@
|
||||
"selectedIconPath": "static/tabbar_icon/b-a.png",
|
||||
"text": "批发"
|
||||
},
|
||||
|
||||
// {
|
||||
// "pagePath": "pages/plant_grass/index",
|
||||
// "iconPath": "static/tabbar_icon/b.png",
|
||||
// "selectedIconPath": "static/tabbar_icon/b-a.png",
|
||||
// "text": "逛逛"
|
||||
// },
|
||||
{
|
||||
"pagePath": "pages/gather/gather",
|
||||
"iconPath": "static/tabbar_icon/c.png",
|
||||
@ -1678,8 +1677,8 @@
|
||||
},
|
||||
{
|
||||
"pagePath": "pages/quote/list",
|
||||
"iconPath": "static/tabbar_icon/d.png",
|
||||
"selectedIconPath": "static/tabbar_icon/d-a.png",
|
||||
"iconPath": "static/tabbar_icon/bjd.png",
|
||||
"selectedIconPath": "static/tabbar_icon/bjdact.png",
|
||||
"text": "报价"
|
||||
},
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<view class="">
|
||||
<view class="bar" style="padding-top:var(--status-bar-height) ;">
|
||||
<!-- <view class="bar" style="padding-top:var(--status-bar-height) ;">
|
||||
<view class="" style="height: 30rpx;">
|
||||
</view>
|
||||
<view class="" style="display: flex;justify-content: space-between;padding: 0 20rpx;">
|
||||
@ -8,14 +8,11 @@
|
||||
<view class="" style="transform: translateX(50rpx);">
|
||||
商户入住
|
||||
</view>
|
||||
<view class="">
|
||||
申请记录
|
||||
<view style="width: 100rpx;">
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="content" style="padding-top: var(--status-bar-height);">
|
||||
<view class="" style="height: 80rpx;">
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="content">
|
||||
<view class="heder-tips">
|
||||
简单3步 商户入驻
|
||||
</view>
|
||||
@ -81,10 +78,19 @@
|
||||
<view class="card-tit">
|
||||
商户位置
|
||||
</view>
|
||||
<!-- #ifdef APP-PLUS -->
|
||||
<view @click="getLocation"
|
||||
style="width: 100%;padding: 20rpx;border: 1px solid #F3F3F3;;color:#999999;border-radius: 16rpx;">
|
||||
{{formData.storeAddress||'点击获取当前位置'}}
|
||||
</view>
|
||||
<!-- #endif -->
|
||||
|
||||
<!-- #ifndef APP-PLUS -->
|
||||
<view @click="getLocation"
|
||||
style="width: 100%;padding: 20rpx;border: 1px solid #F3F3F3;;color:#999999;border-radius: 16rpx;">
|
||||
{{ formData.long?formData.long+','+formData.lat:'点击获取当前位置'}}
|
||||
</view>
|
||||
<!-- #endif -->
|
||||
</view>
|
||||
</view>
|
||||
</u-transition>
|
||||
@ -129,7 +135,9 @@
|
||||
<view class="card-cont-li">
|
||||
<view class="ellipsis" style="display: flex;align-items: center;">
|
||||
法人名称 <u--input style="margin-left: 40rpx;width: 500rpx;" border="none"
|
||||
v-model="formData.name">
|
||||
v-model="formData.company_nickname">
|
||||
|
||||
|
||||
</u--input>
|
||||
</view>
|
||||
</view>
|
||||
@ -152,31 +160,27 @@
|
||||
店铺等待审核
|
||||
</view>
|
||||
<view style="font-size: 32rpx;font-family: PFR;margin-bottom: 40rpx;text-align:center">
|
||||
店铺已提交入驻申请
|
||||
|
||||
</view>
|
||||
<view class="step3-card">
|
||||
<view class="" style="display: flex;justify-content: space-between;font-size: 32rpx;">
|
||||
<text>{{formData.mer_name}}</text>
|
||||
<text style="font-family: PFR;" v-if='formData.status==0'>等待审核</text>
|
||||
<text style="font-family: PFR;color: #20B128;" v-if='formData.status==1'>审核通过</text>
|
||||
<text style="font-family: PFR;color: #FC452F;" v-if='formData.status==2'>审核失败</text>
|
||||
<text>{{successData.mer_name}}</text>
|
||||
<text style="font-family: PFR;" v-if='successData.apply_status==0'>等待审核</text>
|
||||
<text style="font-family: PFR;color: #20B128;"
|
||||
v-if='successData.apply_status==1'>审核通过</text>
|
||||
<text style="font-family: PFR;color: #FC452F;"
|
||||
v-if='successData.apply_status== -1'>审核失败</text>
|
||||
</view>
|
||||
<view class="" style="color: #777;font-size: 24rpx;margin-top: 28rpx;">
|
||||
提交时间:{{formData.create_time}}
|
||||
提交时间:{{successData.create_time}}
|
||||
</view>
|
||||
<u-line color="#ECECEC" style="margin: 36rpx 0;" v-if='formData.status !=0'></u-line>
|
||||
<view v-if='formData.status==2' class=""
|
||||
<u-line color="#ECECEC" style="margin: 36rpx 0;" v-if='formData.apply_status !=0'></u-line>
|
||||
<view v-if='successData.apply_status== -1' class=""
|
||||
style="color: #777;font-size: 24rpx;margin-top: 28rpx;margin-bottom: 36rpx;">
|
||||
备注:{{formData.fail_msg}}
|
||||
备注:{{successData.mark}}
|
||||
</view>
|
||||
<u-button v-if='formData.status==2' @click="step=1" style="color: #FC452F;" color="#F8E9E7"
|
||||
shape="circle" type='error' text="重新申请"></u-button>
|
||||
<view v-if='formData.status==1' class=""
|
||||
style="color: #777;font-size: 24rpx;margin-top: 28rpx;margin-bottom: 36rpx;">
|
||||
可以登录我们的工作台,把您的商品推向市场了
|
||||
</view>
|
||||
<u-button v-if='formData.status==1' @click="openApplet" color="#3ABD40" shape="circle"
|
||||
text="立即发布产品"></u-button>
|
||||
<u-button v-if='successData.apply_status==-1' @click="reSubmit" style="color: #FC452F;"
|
||||
color="#F8E9E7" shape="circle" type='error' text="重新申请"></u-button>
|
||||
</view>
|
||||
</view>
|
||||
</u-transition>
|
||||
@ -197,7 +201,6 @@
|
||||
返回上一步
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<u-picker cancelColor='#3ABE40' confirmColor='#3ABE40' @cancel='showMerchantCategoryPicker=false'
|
||||
@confirm='confirmCate' :show="showMerchantCategoryPicker" keyName="category_name"
|
||||
:columns="MerchantCategoryColumn"></u-picker>
|
||||
@ -219,17 +222,11 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <Verify @success="success" :captchaType="'blockPuzzle'" :imgSize="{ width: '330px', height: '155px' }"
|
||||
ref="verify">
|
||||
</Verify> -->
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// #ifdef APP
|
||||
import uniMP from '@/utils/uniMP.js';
|
||||
// #endif
|
||||
import {
|
||||
configMap
|
||||
} from "@/utils";
|
||||
@ -247,16 +244,16 @@
|
||||
getStoreTypeApi,
|
||||
getIntention,
|
||||
getGoodsDetails,
|
||||
getUnimpInfo,
|
||||
agreeiness,
|
||||
} from '@/api/store.js';
|
||||
import {
|
||||
merchatTypeApi,
|
||||
applysApi,
|
||||
UserWithdrawApi
|
||||
getapplyRecordApi,
|
||||
bankListApi,
|
||||
reSubmitApi
|
||||
} from "@/api/supplier.js"
|
||||
|
||||
// import Verify from '@/components/verify/verify.vue';
|
||||
export default {
|
||||
// components: {
|
||||
// Verify
|
||||
@ -285,6 +282,13 @@
|
||||
StoreTypeColumn: [
|
||||
|
||||
],
|
||||
successData: {
|
||||
"mer_name": "",
|
||||
"id": '',
|
||||
"apply_status": 0,
|
||||
"create_time": "",
|
||||
"mark": null
|
||||
},
|
||||
companyColumn: [
|
||||
[{
|
||||
label: '对公户',
|
||||
@ -296,14 +300,13 @@
|
||||
],
|
||||
text: '获取验证码',
|
||||
detail: {},
|
||||
uniMpInfo: "",
|
||||
num: 10,
|
||||
formData: {
|
||||
lat: "",
|
||||
long: "",
|
||||
"phone": "",
|
||||
"mer_name": "",
|
||||
"name": "",
|
||||
"company_nickname": "",
|
||||
"code": "",
|
||||
category_id: 1,
|
||||
type_id: "",
|
||||
@ -318,7 +321,7 @@
|
||||
mer_intention_id: "",
|
||||
storeAddress: "",
|
||||
"images": [],
|
||||
|
||||
is_merchant_type: 2,
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -328,43 +331,18 @@
|
||||
},
|
||||
mapGetters(['isLogin', 'viewColor', 'keyColor'])),
|
||||
methods: {
|
||||
navgo(url) {
|
||||
uni.navigateTo({
|
||||
url
|
||||
})
|
||||
},
|
||||
creditCodeInput() {
|
||||
this.formData.social_credit_code = this.formData.social_credit_code.replace(/[\u4E00-\u9FA5]/g, '');
|
||||
},
|
||||
countDown() {
|
||||
let {
|
||||
num
|
||||
} = this;
|
||||
num = num > 0 ? num - 1 : "0";
|
||||
setTimeout(() => {
|
||||
this.num = num;
|
||||
if (num == '0') {
|
||||
return
|
||||
}
|
||||
if (this.isshow == false && this.num > 0) {
|
||||
this.num = 10
|
||||
return
|
||||
}
|
||||
this.countDown();
|
||||
}, 1000);
|
||||
},
|
||||
|
||||
back() {
|
||||
uni.navigateBack()
|
||||
},
|
||||
openApplet() {
|
||||
this.uniMpInfo.showToast = true
|
||||
uniMP.loadAppletMP(this.uniMpInfo)
|
||||
},
|
||||
splitAddress(str) {
|
||||
var reg = /.+?(省|市|自治区|自治州|县|区)/g; // 省市区的正则
|
||||
let list = str.match(reg)
|
||||
if (!list[0].includes("省")) {
|
||||
list.unshift('')
|
||||
}
|
||||
this.formData.province_name = list[0]
|
||||
this.formData.city_name = list[1]
|
||||
this.formData.area_name = list[2]
|
||||
|
||||
},
|
||||
confirmCate(e) {
|
||||
@ -387,14 +365,6 @@
|
||||
// 获取配置
|
||||
this.protocol = this.sys_intention_agree;
|
||||
},
|
||||
generateRandomNumbers(count, min, max) {
|
||||
const randomNumbers = [];
|
||||
for (let i = 0; i < count; i++) {
|
||||
const number = Math.floor(Math.random() * (max - min + 1) + min);
|
||||
randomNumbers.push(number);
|
||||
}
|
||||
return randomNumbers;
|
||||
},
|
||||
// 选择图片
|
||||
handleChooseImage(type = 0) {
|
||||
let that = this;
|
||||
@ -419,9 +389,10 @@
|
||||
uni.hideLoading();
|
||||
if (res.status == 200) {
|
||||
that.formData.address = res.data.address;
|
||||
that.formData.name = res.data.legal_person;
|
||||
this.formData.company_nickname = res.data.legal_person;
|
||||
that.formData.social_credit_code = res.data.register_number;
|
||||
that.formData.company_name = res.data.name;
|
||||
console.log(this.formData.company_nickname)
|
||||
} else {
|
||||
that.$util.Tips({
|
||||
title: "识别失败!"
|
||||
@ -434,47 +405,29 @@
|
||||
})
|
||||
})
|
||||
},
|
||||
handleVerify() {
|
||||
this.$refs.verify.show();
|
||||
},
|
||||
success(data) {
|
||||
this.$refs.verify.hide();
|
||||
this.code(data);
|
||||
},
|
||||
reSubmit() {
|
||||
reSubmitApi({
|
||||
id: this.successData.id
|
||||
}).then(res => {
|
||||
this.formData = res.data
|
||||
this.formData.phone = res.data.service_phone
|
||||
console.log(JSON.parse(res.data.data_json))
|
||||
let obj = JSON.parse(res.data.data_json)
|
||||
this.formData.images = [obj.images]
|
||||
this.formData.company_nickname = obj.company_nickname
|
||||
this.formData.company_name = obj.company_name
|
||||
this.formData.address = obj.company_address
|
||||
this.formData.social_credit_code = obj.social_credit_code
|
||||
|
||||
})
|
||||
this.step = 1
|
||||
|
||||
},
|
||||
async code(data) {
|
||||
let that = this;
|
||||
await verify({
|
||||
phone: that.formData.phone,
|
||||
type: 'intention',
|
||||
captchaType: 'blockPuzzle',
|
||||
captchaVerification: data.captchaVerification
|
||||
}).then(res => {
|
||||
that.$util.Tips({
|
||||
title: res.msg
|
||||
});
|
||||
that.sendCode();
|
||||
}).catch(res => {
|
||||
that.$util.Tips({
|
||||
title: res
|
||||
});
|
||||
});
|
||||
},
|
||||
sendCode() {
|
||||
if (this.disabled) return;
|
||||
this.disabled = true;
|
||||
let n = 60;
|
||||
this.text = "剩余 " + n + "s";
|
||||
const run = setInterval(() => {
|
||||
n = n - 1;
|
||||
if (n < 0) {
|
||||
clearInterval(run);
|
||||
}
|
||||
this.text = "剩余 " + n + "s";
|
||||
if (this.text < "剩余 " + 0 + "s") {
|
||||
this.disabled = false;
|
||||
this.text = "重新获取";
|
||||
}
|
||||
}, 1000);
|
||||
|
||||
},
|
||||
shoplist(val) {
|
||||
agreeiness({
|
||||
@ -484,16 +437,23 @@
|
||||
})
|
||||
},
|
||||
getLocation() {
|
||||
uni.showLoading({
|
||||
title: '获取定位中',
|
||||
mask: true
|
||||
});
|
||||
// uni.show
|
||||
|
||||
// #ifndef APP-PLUS
|
||||
uni.getLocation({
|
||||
type: 'wgs84 ',
|
||||
success: (res) => {
|
||||
this.formData.long = res.longitude
|
||||
this.formData.lat = res.latitude
|
||||
console.log('res', res)
|
||||
uni.hideLoading()
|
||||
},
|
||||
fail: (res) => {
|
||||
console.log('err', res)
|
||||
uni.hideLoading()
|
||||
|
||||
},
|
||||
});
|
||||
@ -508,110 +468,52 @@
|
||||
this.formData.lat = res.latitude
|
||||
this.formData.storeAddress = res.address.city + res.address.district + res.address
|
||||
.street + res.address.streetNum
|
||||
console.log('res', res)
|
||||
uni.hideLoading()
|
||||
},
|
||||
fail: (res) => {
|
||||
console.log('err', res)
|
||||
|
||||
uni.hideLoading()
|
||||
},
|
||||
});
|
||||
// #endif
|
||||
|
||||
},
|
||||
submit() {
|
||||
if (this.formData.data_json) {
|
||||
delete this.formData.data_json
|
||||
}
|
||||
this.formData.is_merchant_type = 2
|
||||
applysApi({
|
||||
...this.formData
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
}).then(ress => {
|
||||
this.getSuccessData()
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
return
|
||||
create(this.formData).then(res => {
|
||||
console.log(res.data.mer_intention_id, 'res')
|
||||
this.formData.mer_intention_id = res.data.mer_intention_id
|
||||
this.formData.status = 0
|
||||
if (this.step == 2) {
|
||||
getIntention(this.$store.state.app.userInfo.uid).then(res => {
|
||||
if (Object.keys(res.data).length == 0) return
|
||||
this.formData = res.data
|
||||
this.step = this.formData.step
|
||||
this.formData.phone = this.$store.state.app.userInfo.account
|
||||
})
|
||||
},
|
||||
agree() {},
|
||||
getSuccessData() {
|
||||
getapplyRecordApi().then(res => {
|
||||
console.log(res)
|
||||
if (res.data.id) {
|
||||
this.step = 3
|
||||
this.successData = res.data
|
||||
}
|
||||
this.step++
|
||||
}).catch(err => {
|
||||
console.log(err, 'err')
|
||||
Toast(err)
|
||||
})
|
||||
|
||||
},
|
||||
agree() {
|
||||
this.isshow = false
|
||||
create(this.formData).then(res => {
|
||||
console.log(res.data.mer_intention_id, 'res')
|
||||
this.formData.mer_intention_id = res.data.mer_intention_id
|
||||
this.formData.status = 0
|
||||
if (this.step == 2) {
|
||||
getIntention(this.$store.state.app.userInfo.uid).then(res => {
|
||||
if (Object.keys(res.data).length == 0) return
|
||||
this.formData = res.data
|
||||
this.step = this.formData.step
|
||||
this.formData.phone = this.$store.state.app.userInfo.account
|
||||
})
|
||||
}
|
||||
this.step++
|
||||
}).catch(err => {
|
||||
console.log(err, 'err')
|
||||
Toast(err)
|
||||
})
|
||||
},
|
||||
jumpToList() {
|
||||
uni.navigateTo({
|
||||
url: "/pages/store/applicationRecord/index"
|
||||
})
|
||||
},
|
||||
}
|
||||
},
|
||||
onPullDownRefresh: function() {
|
||||
getIntention(this.$store.state.app.userInfo.uid).then(res => {
|
||||
if (Object.keys(res.data).length == 0) return
|
||||
this.formData = res.data
|
||||
this.step = this.formData.step
|
||||
this.formData.phone = this.$store.state.app.userInfo.account
|
||||
if (this.formData.status == 1) {
|
||||
getUnimpInfo().then(res => {
|
||||
this.uniMpInfo = res.data
|
||||
})
|
||||
}
|
||||
})
|
||||
this.getSuccessData()
|
||||
uni.stopPullDownRefresh()
|
||||
},
|
||||
onLoad(option) {
|
||||
UserWithdrawApi()
|
||||
this.shoplist('mer_services_agree')
|
||||
this.formData.phone = this.$store.state.app.userInfo.account
|
||||
// merClassifly().then(res => {
|
||||
// this.MerchantCategoryColumn = [res.data]
|
||||
// })
|
||||
this.getSuccessData()
|
||||
merchatTypeApi().then(res => {
|
||||
console.log('res', res.data)
|
||||
this.StoreTypeColumn = [res.data]
|
||||
})
|
||||
// getIntention(this.$store.state.app.uid || this.$store.state.app.userInfo.uid).then(res => {
|
||||
// if (Object.keys(res.data).length == 0) return
|
||||
// this.formData = res.data
|
||||
// this.step = this.formData.step
|
||||
// this.formData.phone = this.$store.state.app.userInfo.account
|
||||
// if (option.type == 1) {
|
||||
// this.step = 1
|
||||
// }
|
||||
// if (this.formData.status == 1) {
|
||||
// getUnimpInfo().then(res => {
|
||||
// this.uniMpInfo = res.data
|
||||
// })
|
||||
// }
|
||||
// })
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@ -621,7 +523,6 @@
|
||||
background-color: #fff;
|
||||
padding: 40rpx;
|
||||
box-sizing: border-box;
|
||||
font-family: PF;
|
||||
padding-bottom: 200rpx;
|
||||
|
||||
.heder-tips {
|
||||
|
228
pages/bindSupplier/record.vue
Normal file
228
pages/bindSupplier/record.vue
Normal file
@ -0,0 +1,228 @@
|
||||
<template>
|
||||
<view style="padding: 42rpx 50rpx;">
|
||||
|
||||
<view class="card" v-for="item in listData" :key="item.mer_intention_id">
|
||||
<view class="" style="display: flex;align-items: center;">
|
||||
<view class="ciecle"
|
||||
style="width: 24rpx;height: 24rpx;border-radius: 24rpx;border: 1px solid #DDDDDD;margin-right: 30rpx;">
|
||||
</view>
|
||||
<view class="" style="color: #777777;font-size: 24rpx;">
|
||||
{{item.create_time}}
|
||||
</view>
|
||||
</view>
|
||||
<view class=""
|
||||
style="padding:40rpx;margin: 30rpx 0; width: 606rpx;margin-left: 30rpx;border-radius: 16rpx;box-shadow: 0rpx 6rpx 12rpx 2rpx rgba(0,0,0,0.16);">
|
||||
<view class="" v-if="item.status==0" style="color: #20B128;font-size: 32rpx;">
|
||||
待审核
|
||||
</view>
|
||||
|
||||
<view class="" v-if="item.status==1" style="color: #20B128;font-size: 32rpx;">
|
||||
审核通过
|
||||
</view>
|
||||
<view class="" v-if="item.status==2"
|
||||
style="color: #FC452F;font-size: 32rpx;display: flex;justify-content: space-between;">
|
||||
审核失败
|
||||
<view style="color: #20B128;" @click="navgo">
|
||||
重新申请
|
||||
</view>
|
||||
</view>
|
||||
<u-line style="margin: 28rpx 0;"></u-line>
|
||||
<view class="" style="margin-bottom: 20rpx;">
|
||||
{{item.mer_name}}
|
||||
</view>
|
||||
<view class="" v-if="item.status==1" style="font-size: 24rpx; color: #777777;">
|
||||
可以登录我们的工作台,把您的商品推向市场了
|
||||
</view>
|
||||
<view class="" v-if='item.status==2' style="font-size: 24rpx; color: #777777;">
|
||||
备注:{{item.fail_msg}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<u-button v-if="showBtn" @click="openApplet" color="#3ABD40" shape="circle" text="立即发布产品"></u-button>
|
||||
|
||||
|
||||
<view class="application-record" v-if="listData.length">
|
||||
<!-- <view class="card-list" v-for="item in listData" :key="item.mer_intention_id">
|
||||
<view class="card-top">
|
||||
<view class="title">{{item.mer_name}}</view>
|
||||
<view class="time">提交时间:{{item.create_time}}</view>
|
||||
<view v-if="item.fail_msg" class="reason">原因:{{item.fail_msg}}</view>
|
||||
</view>
|
||||
<view class="line"></view>
|
||||
<view class="card-bottom">
|
||||
<view class="card-status">
|
||||
<image class="status-icon" v-if="item.status === 0" src="../static/images/pending.png" mode=""></image>
|
||||
<image class="status-icon" v-else-if="item.status === 1" src="../static/images/passed.png" mode=""></image>
|
||||
<image class="status-icon" v-else-if="item.status === 2" src="../static/images/not-pass.png" mode=""></image>
|
||||
<text class="status-text">{{statusText(item.status)}}</text>
|
||||
</view>
|
||||
<view class="status-btn" @click="jump(item)">{{statusBtn(item.status)}}</view>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
<view class='no-shop' v-if="!listData.length && !loading">
|
||||
<view class='pictrue' style="margin: 0 auto;">
|
||||
<image :src="`${domain}/static/images/noCart.png`"></image>
|
||||
<text>暂无申请记录,快去申请入驻吧!</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// +----------------------------------------------------------------------
|
||||
// | CRMEB [ CRMEB赋能开发者,助力企业发展 ]
|
||||
// +----------------------------------------------------------------------
|
||||
// | Copyright (c) 2016~2023 https://www.crmeb.com All rights reserved.
|
||||
// +----------------------------------------------------------------------
|
||||
// | Licensed CRMEB并不是自由软件,未经许可不能去掉CRMEB相关版权
|
||||
// +----------------------------------------------------------------------
|
||||
// | Author: CRMEB Team <admin@crmeb.com>
|
||||
// +----------------------------------------------------------------------
|
||||
import {
|
||||
getApplicationRecordList,
|
||||
getUnimpInfo
|
||||
} from '@/api/store.js'
|
||||
|
||||
import {
|
||||
getapplyRecordApi
|
||||
} from "@/api/supplier"
|
||||
|
||||
import {
|
||||
HTTP_REQUEST_URL
|
||||
} from '@/config/app';
|
||||
|
||||
import uniMP from '@/utils/uniMP.js';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
domain: HTTP_REQUEST_URL,
|
||||
loading: false,
|
||||
showBtn: false,
|
||||
listData: [],
|
||||
uniMpInfo: {},
|
||||
pageData: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
}
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
this.getListData()
|
||||
},
|
||||
// 滚动到底部
|
||||
onReachBottom() {
|
||||
if (this.count == this.listData.length) {
|
||||
uni.showToast({
|
||||
title: '没有更多啦',
|
||||
icon: 'none',
|
||||
duration: 1000
|
||||
});
|
||||
} else {
|
||||
this.pageData.page += 1
|
||||
this.getListData()
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
openApplet() {
|
||||
this.uniMpInfo.showToast = true
|
||||
uniMP.loadAppletMP(this.uniMpInfo)
|
||||
},
|
||||
getListData() {
|
||||
this.loading = true
|
||||
uni.showLoading({
|
||||
title: '数据加载中',
|
||||
});
|
||||
getapplyRecordApi().then(res => {
|
||||
console.log(res)
|
||||
uni.hideLoading();
|
||||
this.count = res.data.count
|
||||
this.listData = this.listData.concat(res.data.list)
|
||||
})
|
||||
return
|
||||
getApplicationRecordList(this.pageData).then(res => {
|
||||
this.count = res.data.count
|
||||
this.listData = this.listData.concat(res.data.list)
|
||||
this.showBtn = (this.listData[this.listData.length - 1].status == 1)
|
||||
// if (this.showBtn) {
|
||||
// getUnimpInfo().then(res => {
|
||||
// this.uniMpInfo = res.data
|
||||
// })
|
||||
// }
|
||||
uni.hideLoading();
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
navgo() {
|
||||
// uni.navigateBack()
|
||||
uni.navigateTo({
|
||||
url: '/pages/store/settled/index?type=1'
|
||||
})
|
||||
},
|
||||
// 跳转逻辑
|
||||
jump(item) {
|
||||
console.log(item)
|
||||
if ([0, 2].includes(item.status)) {
|
||||
uni.navigateTo({
|
||||
url: `/pages/store/settled/index?mer_i_id=${item.mer_intention_id}`
|
||||
})
|
||||
} else if (item.status === 1) {
|
||||
uni.navigateTo({
|
||||
url: `/pages/store/merchantDetails/index?mer_i_id=${item.mer_intention_id}&mer_id=${item.mer_id}`
|
||||
})
|
||||
}
|
||||
},
|
||||
//状态判断
|
||||
statusText(number) {
|
||||
// 使用对象
|
||||
let statusData = {
|
||||
0: "待审核",
|
||||
1: "审核通过",
|
||||
2: "审核未通过",
|
||||
};
|
||||
return statusData[number]
|
||||
},
|
||||
// button显示文字
|
||||
statusBtn(number) {
|
||||
// 使用对象
|
||||
let statusData = {
|
||||
0: "编辑",
|
||||
1: "查看",
|
||||
2: "重新提交",
|
||||
};
|
||||
return statusData[number]
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.application-record {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
background-color: #F5F5F5;
|
||||
padding: 20rpx 30rpx;
|
||||
|
||||
}
|
||||
|
||||
.no-shop {
|
||||
width: 100%;
|
||||
background-color: #fff;
|
||||
height: 100vh;
|
||||
|
||||
.pictrue {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
color: $uni-nothing-text;
|
||||
|
||||
image {
|
||||
width: 414rpx;
|
||||
height: 380rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -629,8 +629,6 @@
|
||||
this.activeRouter = '/' + curRoute
|
||||
},
|
||||
onLoad(options) {
|
||||
|
||||
|
||||
let that = this
|
||||
this._options = options;
|
||||
this.diyId = options.diyId || 0;
|
||||
@ -650,10 +648,14 @@
|
||||
},
|
||||
|
||||
onShow() {
|
||||
getSTokenApi().then(res => {
|
||||
if (res.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', 'asdfdsfsdfsdfds')
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data?.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', (res.data?.token || ''))
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log("获取报错", err)
|
||||
})
|
||||
if (uni.getStorageSync('newStore')) this.openDiver();
|
||||
let that = this;
|
||||
|
@ -11,6 +11,7 @@
|
||||
<text>账户绑定</text> <u-icon color="#20B128" name="arrow-right"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
{{form}}
|
||||
<view class="form">
|
||||
<u-form labelPosition="left" borderBottom :label-style="{fontSize:'30rpx'}" labelWidth='70'>
|
||||
<u-form-item label="开户银行" prop="userInfo.name" borderBottom ref="item1" @click="showPop=true">
|
||||
@ -74,7 +75,9 @@
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
bindCradApi
|
||||
bindCradApi,
|
||||
bankListApi,
|
||||
amountAccountApi
|
||||
} from "@/api/supplier.js"
|
||||
export default {
|
||||
data() {
|
||||
@ -95,64 +98,8 @@
|
||||
|
||||
},
|
||||
showPop: false,
|
||||
bankList: [{
|
||||
"id": 2,
|
||||
"name": "农业银行5445",
|
||||
"image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114200646493168.png"
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"name": "中国银行",
|
||||
"image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114142858ca3838.png"
|
||||
}
|
||||
],
|
||||
|
||||
|
||||
hasBindAccount: [{
|
||||
"id": 297,
|
||||
"supplier_id": 0,
|
||||
"mer_id": 500,
|
||||
"bank_id": 1,
|
||||
"bank_code": "6213362109985515778",
|
||||
"bank_branch": "迎晖路支行",
|
||||
"name": "赵明军",
|
||||
"id_card": "513701200012105613",
|
||||
"phone": "19130550023",
|
||||
"financial_img": "",
|
||||
"is_own": 0,
|
||||
"is_check": 1,
|
||||
"fail_msg": null,
|
||||
"admin_id": 1,
|
||||
"create_time": "2024-05-14 16:49:31",
|
||||
"update_time": "2024-05-14 16:50:04",
|
||||
"delete_time": null,
|
||||
"bank_name": "中国银行",
|
||||
"bank_image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114142858ca3838.png"
|
||||
},
|
||||
{
|
||||
"id": 298,
|
||||
"supplier_id": 0,
|
||||
"mer_id": 500,
|
||||
"bank_id": 1,
|
||||
"bank_code": "6213362109985515778",
|
||||
"bank_branch": "迎晖路支行",
|
||||
"name": "赵明军",
|
||||
"id_card": "513701200012105613",
|
||||
"phone": "19130550023",
|
||||
"financial_img": "",
|
||||
"is_own": 1,
|
||||
"is_check": 1,
|
||||
"fail_msg": null,
|
||||
"admin_id": 1,
|
||||
"create_time": "2024-05-14 18:16:21",
|
||||
"update_time": "2024-05-14 18:17:21",
|
||||
"delete_time": null,
|
||||
"bank_name": "中国银行",
|
||||
"bank_image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114142858ca3838.png"
|
||||
}
|
||||
],
|
||||
|
||||
|
||||
bankList: [],
|
||||
hasBindAccount: [],
|
||||
showPop1: false
|
||||
}
|
||||
},
|
||||
@ -163,12 +110,9 @@
|
||||
})
|
||||
},
|
||||
async getHasBindBankList() {
|
||||
this.getFormData(this.form, this.hasBindAccount[0])
|
||||
return
|
||||
let res = await amountAccountApi({})
|
||||
this.balance = res.data.balance
|
||||
// this.hasBindAccount = res.data.hasBindAccount
|
||||
// this.target_bank = res.data.hasBindAccount[0] || {}
|
||||
this.hasBindAccount = res.data.bank_list
|
||||
this.form = res.data.bank_list[0] || {}
|
||||
},
|
||||
getFormData(form, target) {
|
||||
if (!target) {
|
||||
@ -186,6 +130,7 @@
|
||||
},
|
||||
choseAccount(type) {
|
||||
this.getFormData(this.form, this.hasBindAccount[type])
|
||||
this.form.is_own = type
|
||||
this.showPop1 = false
|
||||
},
|
||||
|
||||
@ -194,10 +139,16 @@
|
||||
this.form.bank_id = item.id
|
||||
this.showPop = false
|
||||
},
|
||||
async getBankList() {
|
||||
let res = await bankListApi()
|
||||
this.bankList = res.data.lists
|
||||
|
||||
},
|
||||
submit() {
|
||||
bindCradApi({
|
||||
...this.form
|
||||
}).then(res => {
|
||||
// return
|
||||
uni.navigateBack()
|
||||
})
|
||||
}
|
||||
@ -207,6 +158,7 @@
|
||||
onLoad() {
|
||||
uni.showTabBar()
|
||||
this.getHasBindBankList()
|
||||
this.getBankList()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<view style="padding: 100rpx 0;">
|
||||
<view style="padding: 100rpx 0;min-height: 100vh;">
|
||||
<view class="head">
|
||||
<view class="">
|
||||
<view class="" style="display: flex;justify-content: space-around;margin-top: 24rpx;color:#777777">
|
||||
@ -32,7 +32,7 @@
|
||||
{{item.goods.name}}
|
||||
</view>
|
||||
<view class="need">
|
||||
需求量: {{item.need_num}}{{item.unit_name}}
|
||||
需求量: {{item.need_num}}{{item.goods.unit_name}}
|
||||
</view>
|
||||
<view class="ipt">
|
||||
<u--input placeholder="输入报价数量" :readonly="tabIndex==2" v-model="item.nums"
|
||||
@ -44,6 +44,16 @@
|
||||
@blur="priceBlur(index)" :readonly="tabIndex==2" v-model="item.price"></u--input>
|
||||
</view>
|
||||
</view>
|
||||
<view class="status-png" v-if="tabIndex==2">
|
||||
<!-- <image :src="item.is_adopt?successPng:errPng" style="width: 108rpx; height: 84rpx;">
|
||||
</image> -->
|
||||
<image v-if="item.is_adopt==1" :src="waitPng" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
<image v-else-if="item.is_adopt==2" :src="successPng" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
<image v-else :src="errPng" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="card-footer" v-if="item.nums && item.price">
|
||||
共{{item.nums}}{{item.unit_name}} 合计:<text
|
||||
@ -51,14 +61,12 @@
|
||||
</view>
|
||||
<u-line style="margin-top: 30rpx;" color="#F3F3F3"></u-line>
|
||||
</view>
|
||||
<u-empty v-if="lists.length==0" mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</u-empty>
|
||||
</view>
|
||||
|
||||
<!-- <up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty> -->
|
||||
|
||||
<!-- <view class="detail" @click="navgo('/pageQuota/Balance/index')">
|
||||
<view class="detail" @click="navgo('/pages/quote/supplierFinancialy')">
|
||||
提现
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="submit-btn" v-if="tabIndex==1">
|
||||
<u-button shape='circle' color='#20B128' @click="submit" text="提交"></u-button>
|
||||
</view>
|
||||
@ -67,12 +75,10 @@
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
OpurchaseGoodsOfferApi,
|
||||
OpurchaseGoodsOfferListApi
|
||||
} from "@/api/supplier.js"
|
||||
|
||||
|
||||
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@ -80,421 +86,20 @@
|
||||
tabsLeft: 0,
|
||||
tabsRight: 0,
|
||||
loading: false,
|
||||
lists: [{
|
||||
"id": 15,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 113,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 400,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 113,
|
||||
"name": "火龙果花",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"497"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "富含维生素C、钙、磷、铁等营养成分",
|
||||
"class": 497,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151405465afc55555.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 14:05:52",
|
||||
"update_time": "2024-05-15 14:05:52",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 14,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 112,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 300,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 112,
|
||||
"name": "蛇皮果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"120"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "富含维生素C、B族维生素",
|
||||
"class": 120,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/20240515135546c2f251314.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:55:49",
|
||||
"update_time": "2024-05-15 13:55:49",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 13,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 111,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 200,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 111,
|
||||
"name": "红参果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"121"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "质地柔软丨口感清甜",
|
||||
"class": 121,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151353132038a8389.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:53:16",
|
||||
"update_time": "2024-05-15 13:53:16",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 12,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 110,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 100,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 110,
|
||||
"name": "仁面果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"122"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "口感丰富丨果汁丰富",
|
||||
"class": 122,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151349268542d3786.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:51:06",
|
||||
"update_time": "2024-05-15 13:51:06",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 15,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 113,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 400,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 113,
|
||||
"name": "火龙果花",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"497"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "富含维生素C、钙、磷、铁等营养成分",
|
||||
"class": 497,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151405465afc55555.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 14:05:52",
|
||||
"update_time": "2024-05-15 14:05:52",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 14,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 112,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 300,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 112,
|
||||
"name": "蛇皮果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"120"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "富含维生素C、B族维生素",
|
||||
"class": 120,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/20240515135546c2f251314.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:55:49",
|
||||
"update_time": "2024-05-15 13:55:49",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 13,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 111,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 200,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 111,
|
||||
"name": "红参果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"121"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "质地柔软丨口感清甜",
|
||||
"class": 121,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151353132038a8389.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:53:16",
|
||||
"update_time": "2024-05-15 13:53:16",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 12,
|
||||
"supplier_id": 9,
|
||||
"order_id": 2,
|
||||
"goods_id": 110,
|
||||
"price": "",
|
||||
"nums": '',
|
||||
"unit": null,
|
||||
"is_adopt": 0,
|
||||
"is_storage": 0,
|
||||
"create_time": 0,
|
||||
"update_time": 0,
|
||||
"delete_time": null,
|
||||
"need_num": 0,
|
||||
"notes": null,
|
||||
"before_nums": 100,
|
||||
"is_adopt_text": "待报价",
|
||||
"goods": {
|
||||
"id": 110,
|
||||
"name": "仁面果",
|
||||
"py": "",
|
||||
"sys_labels": [
|
||||
"122"
|
||||
],
|
||||
"number": "",
|
||||
"spec": "口感丰富丨果汁丰富",
|
||||
"class": 122,
|
||||
"brand": 0,
|
||||
"unit": 2,
|
||||
"buy": "0.02",
|
||||
"sell": "0.01",
|
||||
"retail": "0.00",
|
||||
"code": "",
|
||||
"warehouse": 1,
|
||||
"location": "",
|
||||
"stocktip": "100.00",
|
||||
"sales": 0,
|
||||
"tax_rate": null,
|
||||
"imgs": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240515/202405151349268542d3786.png",
|
||||
"details": [
|
||||
""
|
||||
],
|
||||
"data": "",
|
||||
"more": "",
|
||||
"create_time": "2024-05-15 13:51:06",
|
||||
"update_time": "2024-05-15 13:51:06",
|
||||
"delete_time": null,
|
||||
"sort": 0,
|
||||
"unit_name": "斤"
|
||||
}
|
||||
}
|
||||
lists: [],
|
||||
date: "",
|
||||
successPng: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/739c3202405071458553459.png',
|
||||
errPng: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/04c2c202405071501462462.png',
|
||||
waitPng: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/274ad202405111523222891.png'
|
||||
|
||||
|
||||
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
navgo(url) {
|
||||
uni.navigateTo({
|
||||
url
|
||||
})
|
||||
},
|
||||
getTabsPosi() {
|
||||
const {
|
||||
windowWidth
|
||||
@ -502,12 +107,22 @@
|
||||
this.tabsLeft = (((windowWidth / 2) - 26) / 2)
|
||||
this.tabsRight = (this.tabsLeft + (windowWidth / 2))
|
||||
},
|
||||
async getLists() {
|
||||
async getLists(type) {
|
||||
let that = this
|
||||
// that.loading = true
|
||||
// let res = await getLists({})
|
||||
// this.lists = res.lists
|
||||
// that.loading = false
|
||||
OpurchaseGoodsOfferListApi({
|
||||
type: type || this.tabIndex,
|
||||
date: this.date
|
||||
}).then(res => {
|
||||
this.lists = res.data.lists
|
||||
this.lists.forEach(item => {
|
||||
if (!(+item.nums)) {
|
||||
item.nums = ''
|
||||
}
|
||||
if (!(+item.price)) {
|
||||
item.price = ''
|
||||
}
|
||||
})
|
||||
})
|
||||
that.loading = true
|
||||
setTimeout(() => {
|
||||
that.loading = false
|
||||
@ -532,20 +147,19 @@
|
||||
price: item.price
|
||||
}
|
||||
})
|
||||
|
||||
if (!data.length) return
|
||||
this.getLists(2)
|
||||
return
|
||||
let res = await submitApi({
|
||||
...data
|
||||
console.log(data)
|
||||
let res = await OpurchaseGoodsOfferApi({
|
||||
data: data
|
||||
})
|
||||
this.getLists(2)
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
onLoad(option) {
|
||||
this.date = option.date
|
||||
this.getTabsPosi()
|
||||
this.getLists()
|
||||
OpurchaseGoodsOfferListApi()
|
||||
// OpurchaseGoodsOfferListApi()
|
||||
|
||||
}
|
||||
}
|
||||
@ -664,8 +278,8 @@
|
||||
background-color: #50C758;
|
||||
color: white;
|
||||
position: absolute;
|
||||
bottom: 30px;
|
||||
// right: 20rpx;
|
||||
bottom: 100px;
|
||||
right: 20rpx;
|
||||
}
|
||||
|
||||
.ellipsis {
|
||||
|
@ -1,7 +1,8 @@
|
||||
<template>
|
||||
<view class="box">
|
||||
<view class="top">
|
||||
<view class="title">
|
||||
|
||||
<!-- <view class="top">
|
||||
<view class="title" style='padding-top: 100rpx;'>
|
||||
<view>
|
||||
</view>
|
||||
报价订单
|
||||
@ -11,17 +12,20 @@
|
||||
<u-search :showAction="true" v-model="keyword" :actionStyle="{color:'#20B128'}" actionText="搜索"
|
||||
placeholder="输入商品分类" :animation="true" @search="getLists" @custom='getLists'></u-search>
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
<u-empty v-if="lists.length==0" mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</u-empty>
|
||||
<view class="content">
|
||||
<view class="li" v-for="(item,index) in lists" :key="index" @click="navgo('/pages/quote/index')">
|
||||
<view class="li" v-for="(item,index) in lists" :key="index"
|
||||
@click="navgo(`/pages/quote/index?date=${item.name.substring(0, 10)}`)">
|
||||
<view>
|
||||
PF171504442988969633
|
||||
{{item.name}}
|
||||
</view>
|
||||
<view style="display: flex;justify-content: space-between;margin: 20rpx 0;">
|
||||
<text>
|
||||
水果 | 共4件
|
||||
{{item.labels}} | 共{{item.nums}}种
|
||||
</text>
|
||||
<view style="display: flex;align-items: center;" v-if="false">
|
||||
<view style="display: flex;align-items: center;" v-if="item.status==0">
|
||||
<text style="margin-right: 10rpx;color: #20B128;">待报价</text>
|
||||
<u--image src="https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/fcc66202405171031441742.png"
|
||||
width="32rpx" height="32rpx"></u--image>
|
||||
@ -32,23 +36,26 @@
|
||||
width="32rpx" height="32rpx"></u--image>
|
||||
</view>
|
||||
</view>
|
||||
<view style="color: #777777;font-size: 24rpx;">
|
||||
|
||||
|
||||
<!-- <view style="color: #777777;font-size: 24rpx;">
|
||||
2024-05-16 18:00
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
OpurchaseGoodsOfferListApi
|
||||
OpurchaseGoodsOfferListApi,
|
||||
UserWithdrawListsdate_listsApi
|
||||
} from "@/api/supplier.js"
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
keyword: '',
|
||||
lists: 10
|
||||
lists: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@ -58,23 +65,25 @@
|
||||
})
|
||||
},
|
||||
async getLists() {
|
||||
let res = await OpurchaseGoodsOfferListApi({
|
||||
keyword: this.keyword
|
||||
let res = await UserWithdrawListsdate_listsApi({
|
||||
// keyword: this.keyword
|
||||
})
|
||||
this.lists = res.data.lists
|
||||
|
||||
}
|
||||
},
|
||||
onShow() {
|
||||
this.getLists()
|
||||
},
|
||||
onLoad() {
|
||||
uni.showTabBar()
|
||||
this.getLists()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.box {
|
||||
padding-top: 200rpx;
|
||||
// padding-top: 250rpx;
|
||||
|
||||
.top {
|
||||
position: fixed;
|
||||
|
@ -71,7 +71,8 @@
|
||||
|
||||
<script>
|
||||
import {
|
||||
hasBindAccount
|
||||
hasBindAccount,
|
||||
amountAccountApi
|
||||
} from "@/api/supplier.js"
|
||||
export default {
|
||||
data() {
|
||||
@ -82,51 +83,7 @@
|
||||
form: {
|
||||
money: ''
|
||||
},
|
||||
|
||||
hasBindAccount: [{
|
||||
"id": 297,
|
||||
"supplier_id": 0,
|
||||
"mer_id": 500,
|
||||
"bank_id": 1,
|
||||
"bank_code": "6213362109985515778",
|
||||
"bank_branch": "迎晖路支行",
|
||||
"name": "赵明军",
|
||||
"id_card": "513701200012105613",
|
||||
"phone": "19130550023",
|
||||
"financial_img": "",
|
||||
"is_own": 0,
|
||||
"is_check": 1,
|
||||
"fail_msg": null,
|
||||
"admin_id": 1,
|
||||
"create_time": "2024-05-14 16:49:31",
|
||||
"update_time": "2024-05-14 16:50:04",
|
||||
"delete_time": null,
|
||||
"bank_name": "中国银行",
|
||||
"bank_image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114142858ca3838.png"
|
||||
},
|
||||
{
|
||||
"id": 298,
|
||||
"supplier_id": 0,
|
||||
"mer_id": 500,
|
||||
"bank_id": 1,
|
||||
"bank_code": "6213362109985515778",
|
||||
"bank_branch": "迎晖路支行",
|
||||
"name": "赵明军",
|
||||
"id_card": "513701200012105613",
|
||||
"phone": "19130550023",
|
||||
"financial_img": "",
|
||||
"is_own": 1,
|
||||
"is_check": 1,
|
||||
"fail_msg": null,
|
||||
"admin_id": 1,
|
||||
"create_time": "2024-05-14 18:16:21",
|
||||
"update_time": "2024-05-14 18:17:21",
|
||||
"delete_time": null,
|
||||
"bank_name": "中国银行",
|
||||
"bank_image": "https://lihaiim.oss-cn-chengdu.aliyuncs.com/public/uploads/images/20240510/20240510114142858ca3838.png"
|
||||
}
|
||||
],
|
||||
|
||||
hasBindAccount: [],
|
||||
showPop1: false,
|
||||
}
|
||||
},
|
||||
@ -138,11 +95,12 @@
|
||||
},
|
||||
choseAccount(type) {
|
||||
this.target_bank = this.hasBindAccount[type] || {}
|
||||
this.target_bank.is_own = type
|
||||
this.showPop1 = false
|
||||
},
|
||||
async getHasBindBankList() {
|
||||
this.target_bank = this.hasBindAccount[0]
|
||||
return
|
||||
// this.target_bank = this.hasBindAccount[0]
|
||||
// return
|
||||
let res = await amountAccountApi({})
|
||||
this.balance = res.data.balance
|
||||
// this.hasBindAccount = res.data.hasBindAccount
|
||||
|
@ -484,7 +484,13 @@
|
||||
});
|
||||
that.$store.commit("SETUID", data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.user);
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
let method
|
||||
let indexPat = ['/pages/index/index', '/pages/order_addcart/order_addcart',
|
||||
'/pages/goods_cate/goods_cate',
|
||||
@ -604,7 +610,13 @@
|
||||
});
|
||||
that.$store.commit("SETUID", data.result.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.result.user);
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
let method
|
||||
let indexPat = ['/pages/index/index', '/pages/order_addcart/order_addcart',
|
||||
'/pages/goods_cate/goods_cate',
|
||||
@ -696,7 +708,13 @@
|
||||
'token': data.result.token,
|
||||
'time': data.result.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", data.result.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.result.user);
|
||||
let method
|
||||
@ -755,7 +773,13 @@
|
||||
'token': data.result.token,
|
||||
'time': data.result.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", data.result.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.result.user);
|
||||
let method
|
||||
@ -853,7 +877,13 @@
|
||||
'token': data.token,
|
||||
'time': data.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.user);
|
||||
|
||||
@ -931,7 +961,13 @@
|
||||
'token': res.data.token,
|
||||
'time': res.data.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", res.data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', res.data.user);
|
||||
const backUrl = that.$Cache.get('login_back_url_weixin') || that.$Cache.get(BACK_URL) ||
|
||||
@ -1015,7 +1051,13 @@
|
||||
'token': res.data.token,
|
||||
'time': res.data.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", res.data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', res.data.user);
|
||||
const backUrl = that.$Cache.get('login_back_url_weixin') || that.$Cache.get(BACK_URL) ||
|
||||
@ -1101,7 +1143,13 @@
|
||||
'token': res.data.token,
|
||||
'time': res.data.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", res.data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', res.data.user);
|
||||
const backUrl = that.$Cache.get('login_back_url_weixin') || that.$Cache.get(BACK_URL) ||
|
||||
@ -1256,7 +1304,13 @@
|
||||
'token': data.token,
|
||||
'time': data.exp
|
||||
});
|
||||
getSTokenApi()
|
||||
getSTokenApi({
|
||||
jg_register_id: uni.getStorageSync('jg_id') || ''
|
||||
}).then(res => {
|
||||
if (res.data.token) {
|
||||
uni.setStorageSync('LOGIN_STATUS_STOKEN', res.data.token)
|
||||
}
|
||||
})
|
||||
that.$store.commit("SETUID", data.user.uid);
|
||||
that.$store.commit('UPDATE_USERINFO', data.user);
|
||||
|
||||
@ -1354,6 +1408,7 @@
|
||||
phone: this.account,
|
||||
jg_register_id: result.registerID
|
||||
}).then(res => {
|
||||
uni.setStorageSync('jg_id', result.registerID)
|
||||
console.log("绑定成功", res);
|
||||
}).catch(err => {
|
||||
console.log("绑定失败", err);
|
||||
|
BIN
static/tabbar_icon/bjd.png
Normal file
BIN
static/tabbar_icon/bjd.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1023 B |
BIN
static/tabbar_icon/bjdact.png
Normal file
BIN
static/tabbar_icon/bjdact.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.7 KiB |
@ -83,7 +83,8 @@ function baseRequest(url, method, data, {
|
||||
HTTP_list.delete(URL);
|
||||
|
||||
if (tokenName) {
|
||||
if (store.state.app.token) header[TOKENNAME] = 'Bearer' + store.state.app.token;
|
||||
// if (store.state.app.token) header[TOKENNAME] = 'Bearer' + store.state.app.token;
|
||||
if (store.state.app.token) header[TOKENNAME] = 'Bearer ' + store.state.app.token;
|
||||
} else {
|
||||
if (store.state.app.s_token) header['Token'] = store.state.app.s_token;
|
||||
}
|
||||
@ -97,9 +98,7 @@ function baseRequest(url, method, data, {
|
||||
success: (res) => {
|
||||
if (res.data.code == 1) {
|
||||
reslove(res.data, res);
|
||||
}
|
||||
|
||||
if (res.data && res.data.encode) {
|
||||
} else if (res.data && res.data.encode) {
|
||||
try {
|
||||
res.data = JSON.parse(decompress(res.data.data));
|
||||
} catch (e) {
|
||||
@ -118,9 +117,12 @@ function baseRequest(url, method, data, {
|
||||
url: '/pages/error/index'
|
||||
})
|
||||
reject(res.data);
|
||||
} else if (res.data.code == 1) {
|
||||
reslove(res.data, res);
|
||||
} else {
|
||||
console.error("请求失败", res)
|
||||
reject(res.data.message || '系统错误');
|
||||
reslove(res.data, res);
|
||||
// console.error("请求失败", res)
|
||||
// reject(res.data.message || '系统错误');
|
||||
}
|
||||
},
|
||||
fail: (message) => {
|
||||
|
@ -12,8 +12,7 @@ const setTab = (index, visible) => {
|
||||
}
|
||||
|
||||
export const showTab = (data) => {
|
||||
setTab(4, Boolean(store.state.app.s_token))
|
||||
|
||||
setTab(4, Boolean(uni.getStorageSync('LOGIN_STATUS_STOKEN')))
|
||||
let user = data || store.state.app.userInfo;
|
||||
if (user.mer_info && user.mer_info.mer_settlement_agree_status) {
|
||||
setTab(1, true)
|
||||
|
Loading…
x
Reference in New Issue
Block a user