diff --git a/App.vue b/App.vue
index 1f3bbeb..4996cd9 100644
--- a/App.vue
+++ b/App.vue
@@ -76,8 +76,15 @@
onLaunch: function(option) {
this.globalData.statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
this.globalData.uid = this.$store.state.app.uid;
-
- this.$store.dispatch('INIT_CONFIG');
+ let appkey = uni.getStorage({
+ key: 'launchFlag'
+ })
+ if (appkey) {
+ setTimeout(() => {
+ this.$store.dispatch('INIT_CONFIG');
+ }, 6000)
+ }
+
// #ifdef APP-PLUS
//监听uni小程序发送的事件
@@ -204,10 +211,11 @@
- this.checknetwork()
+
},
onShow() {
+
let that = this
// 记录H5和公众号
if (this.$store.state.app.token) {
diff --git a/api/user.js b/api/user.js
index 7b806ed..1f1fce7 100644
--- a/api/user.js
+++ b/api/user.js
@@ -9,6 +9,14 @@
// +----------------------------------------------------------------------
import request from "@/utils/request.js";
import Cache from '@/utils/cache'
+/**
+ * 获取版本信息
+ */
+export function Appversion(data) {
+ return request.get(`app/version`, data, {
+ noAuth: true
+ });
+}
/**
* 提交提现
*/
diff --git a/config/app.js b/config/app.js
index f6c51a7..f083eab 100644
--- a/config/app.js
+++ b/config/app.js
@@ -24,8 +24,8 @@ if (process.env.NODE_ENV === "development") {
// httpApiThree = 'baseUrlTest' // h5跨域配置
// #endif
} else if (process.env.NODE_ENV === 'production') {
- httpApi = 'https://shop.lihaink.cn' // 生产
- //httpApi = "https://crmeb-test.shop.lihaink.cn"
+ // httpApi = 'https://shop.lihaink.cn' // 生产
+ httpApi = "https://crmeb-test.shop.lihaink.cn"
httpApiTwo = 'https://nk.lihaink.cn' // 生产
httpApiThree = 'http://ceshi-oa.lihaink.cn' //生产
}
diff --git a/pages/commissionedSales/addDelegation/index.vue b/pages/commissionedSales/addDelegation/index.vue
index 03783f3..86619ff 100644
--- a/pages/commissionedSales/addDelegation/index.vue
+++ b/pages/commissionedSales/addDelegation/index.vue
@@ -1,25 +1,29 @@
-
-
+
+
+
+
+
+
+
+
@@ -74,7 +85,9 @@
import eselect from '@/components/e-select/e-select.vue';
import {
supplychain,
- entrustchain
+ entrustchain,
+ editentrust,
+ entrustdetail
} from '@/api/sale.js'
export default {
components: {
@@ -85,8 +98,20 @@
return {
value1: 1,
value2: "",
- options1: [],
+ options1: [{
+ text: "Shenzhen1",
+ value: 1
+ }, {
+ text: "Shenzhen2",
+ value: 2
+ }, {
+
+
+ text: "Shenzhen3",
+ value: 3
+ }],
+ date: 1,
productList: [],
info: {
startDate: '',
@@ -97,14 +122,6 @@
selected: [],
showMonth: false
},
- formData: {
- entrust_mer_id: '',
- entrust_day: 0,
- is_type: "4",
- product_info: [],
- content: ''
- },
- type: ''
};
},
computed: {
@@ -114,39 +131,46 @@
onLoad(e) {
-
this.id = e.id;
this.type = e.type
if (this.type) {
-
uni.setNavigationBarTitle({
title: '编辑打折'
})
- } else {
-
+ this.editlist(e.id)
}
},
mounted() {
- this.list()
+ this.list()
},
methods: {
+ change1(item) {
+ console.log(item);
+ },
list() {
supplychain({
page: 1
}).then((res => {
-
+
for (let i in res.data.list) {
this.options1.push({
text: res.data.list[i].mer_name,
value: res.data.list[i].mer_id
})
}
-
// console.log(res)
}))
},
+ editlist(id) {
+ entrustdetail(id).then((res) => {
+ this.formData.entrust_mer_id = res.data.entrust_mer_id
+ this.formData.entrust_day = res.data.entrust_day
+ this.productList = res.data.product_list
+ this.getProduct(res.data.product_list)
+ })
+ },
calendar() {
@@ -162,11 +186,11 @@
},
//获取商品信息
getProduct(data) {
- console.log(data)
+ this.formData.product_info=[]
if (data.length > 0) {
-
+
for (let i in data) {
- this.formData.content+=data[i].store_name+','
+ this.formData.content += data[i].store_name + ','
this.formData.product_info.push({
product_attr_unique: data[i].product_attr_unique,
number: Number(data[i].number),
@@ -191,6 +215,38 @@
if (!value.entrust_mer_id) return that.$util.Tips({
title: '请添加商家'
});
+ this.type?
+ editentrust(this.id,value).then(res => {
+ if (res.status == '200') {
+ uni.hideLoading()
+ that.$util.Tips({
+ title: '编辑成功',
+ icon: 'success'
+ });
+ that.formData = {
+ entrust_mer_id: '',
+ entrust_day: 0,
+ is_type: "4",
+ product_info: []
+ }
+ uni.redirectTo({
+ url: '/pages/commissionedSales/initiateDelegation/index'
+ })
+
+ } else {
+ that.$util.Tips({
+ title: res.messge,
+ icon: 'success'
+ });
+ }
+ }).catch(err => {
+
+ return that.$util.Tips({
+ title: err
+ });
+ })
+
+ :
entrustchain(value).then(res => {
if (res.status == '200') {
uni.hideLoading()
@@ -207,7 +263,7 @@
uni.redirectTo({
url: '/pages/commissionedSales/initiateDelegation/index'
})
-
+
} else {
that.$util.Tips({
title: res.messge,
@@ -231,10 +287,6 @@
background: #F5F5F5;
}
- .content {
- height: 100vh;
- position: relative;
- }
.release_content {
@@ -479,10 +531,6 @@
}
.release_btn {
-
- position: absolute;
- bottom: 150rpx;
- left: 50%;
- margin-left: -347rpx;
+ margin-top: 100rpx;
}
\ No newline at end of file
diff --git a/pages/commissionedSales/delegation_details/index.vue b/pages/commissionedSales/delegation_details/index.vue
index 3be7fef..05b293a 100644
--- a/pages/commissionedSales/delegation_details/index.vue
+++ b/pages/commissionedSales/delegation_details/index.vue
@@ -6,7 +6,8 @@
- 待处理
+
+ {{objinfo.mer_status==0?"待处理":""||objinfo.mer_status==2?"已拒绝":""||objinfo.mer_status==1?"已接受":""}}
2020-07-07 14:14:14
@@ -14,55 +15,35 @@
-
+
-
+
- 良品铺子肉松饼1000g/箱 面...
+ {{item.store_name}}
- 委托价:¥34.90
+ 委托价:¥{{item.price}}
- 数量:100个
+ 数量:{{item.number}}个
-
-
-
-
-
-
-
- 良品铺子肉松饼1000g/箱 面...
-
-
-
- 委托价:¥34.90
-
-
- 数量:100个
-
-
-
-
-
委托方:
- 通滩镇镇街店铺
+ {{objinfo.mer_info.mer_name}}
@@ -70,7 +51,7 @@
被委托方:
- 通滩镇镇街店铺
+ {{objinfo.entrust_mer_info.mer_name}}
@@ -78,7 +59,7 @@
委托周期:
- 通滩镇镇街店铺
+ {{objinfo.entrust_day}}
@@ -86,7 +67,7 @@
结算周期:
- 通滩镇镇街店铺
+ {{objinfo.mer_info.settle_cycle}}
@@ -94,7 +75,7 @@
结算利息:
- 通滩镇镇街店铺
+ {{objinfo.mer_info.interest_rate}}%
@@ -102,7 +83,8 @@
状态:
- 通滩镇镇街店铺
+
+ {{objinfo.mer_status==0?"待处理":""||objinfo.mer_status==2?"已拒绝":""||objinfo.mer_status==1?"已接受":""}}
@@ -110,15 +92,15 @@
是否结束委托:
- 通滩镇镇街店铺
+ {{objinfo.entrust_finish==0?'未结束':""||objinfo.entrust_finish==1?'已结束':""||objinfo.entrust_finish==2?'商家拒绝':""||objinfo.entrust_finish==3?'申请':""}}
-
+
拒绝原因:
- 通滩镇镇街店铺通滩镇镇街店铺通滩镇镇街店铺通滩镇镇街店铺通滩镇镇街店铺通滩镇镇街店铺
+ {{objinfo.entrust_finish_refusal}}
@@ -130,36 +112,89 @@
-
+
-
+
- 良品铺子肉松饼1000g/箱 面包糕...
-
-
-
-
-
-
-
- 良品铺子肉松饼1000g/箱 面包糕...
+ {{item.store_name}}
+
-
+
+
+
\ No newline at end of file
diff --git a/pages/commissionedSales/initiateDelegation/index.vue b/pages/commissionedSales/initiateDelegation/index.vue
index bbc03ad..4615473 100644
--- a/pages/commissionedSales/initiateDelegation/index.vue
+++ b/pages/commissionedSales/initiateDelegation/index.vue
@@ -6,7 +6,7 @@
-
+
@@ -14,10 +14,10 @@
- {{item.title}}
+ {{item.content}}
- 委托周期:{{item.credit_buy}}
+ 委托周期:{{item.day}}
@@ -25,79 +25,84 @@
-
+
待处理
+
-
+
+
+ 编辑
删除
-
+
详情
-
+
+
+
已接受
+
结束委托
-
+
详情
-
+
+
+
已拒绝
-
+
删除
-
+
详情
+
+
已完成
-
+
删除
-
+
详情
-
-
-
-
-
- 新增委托
-
-
-
+
+
-
+
@@ -109,16 +114,19 @@
委托申请处理
- 结算周期: {{obj.settle_cycle}}天
+ 结算周期: 30天
+
+
- 利息比例: {{obj.interest_rate}}%
+ 利息比例: 0.05%
+
-
+
拒绝
-
+
接受
@@ -128,6 +136,7 @@
+
@@ -147,11 +156,15 @@
+
+
+
+
@@ -164,10 +177,13 @@
结算周期: 30天
+
+
利息比例: 0.05%
+
拒绝
@@ -195,15 +211,20 @@
结算周期: 30天
+
+
利息比例: 0.05%
+
拒绝原因:
+
+
@@ -221,43 +242,34 @@
\ No newline at end of file
diff --git a/pages/gather/gather.vue b/pages/gather/gather.vue
index d7a80d2..e8fbae7 100644
--- a/pages/gather/gather.vue
+++ b/pages/gather/gather.vue
@@ -74,9 +74,6 @@
-
- 发布
-
-->
@@ -223,7 +220,6 @@
this.backColor = 'rgba(252, 252, 252, 1)'
this.isFshow = true
-
}
},
@@ -309,7 +305,7 @@
},
// 编辑完成
editComfirm() {
- this.editFlag = false;
+this.editFlag = false;
uni.setStorageSync('gatherNowMenuList', JSON.stringify(this.nowMenuList));
},
getUniMp(appid) {
@@ -360,8 +356,10 @@
},
confirm(e) {
this.street = e.value[1].name
+
this.$nextTick(() => {
this.$bus.$emit('value-updated', e.value[1].name + ',' + e.value[1].code);
+
})
this.showPicker = false
},
@@ -371,7 +369,7 @@
timeout: '10',
success: (res) => {
// console.log(res)
-
+ this.isshow = false
let latitude, longitude;
latitude = res.latitude.toString();
longitude = res.longitude.toString();
@@ -385,9 +383,11 @@
this.$nextTick(() => {
this.$bus.$emit('value-updated', this.street + ',' +
street_id);
+
})
}).catch(err => {
+ this.isshow = false
uni.showToast({
title: err,
icon: 'none'
@@ -395,12 +395,8 @@
})
},
fail: (err) => {
-
- uni.showToast({
- title: "获取定位超时",
- icon: 'none',
- duration: 2000
- });
+ this.isshow = false
+
}
});
},
diff --git a/pages/guide/guide.vue b/pages/guide/guide.vue
index fd35312..24e0323 100644
--- a/pages/guide/guide.vue
+++ b/pages/guide/guide.vue
@@ -1,13 +1,13 @@
-
-
-
+
+
+
-
+
@@ -16,16 +16,16 @@
-
+
- 跳过
+ {{num}}跳过
-
-
+
+
@@ -35,12 +35,11 @@
data() {
return {
//修改图片,文字描述
- imageList: [
- {
-
+ imageList: [{
+
src: '/static/images/guide.png'
}
-
+
],
indicatorDots: false,
autoplay: false,
@@ -49,7 +48,8 @@
iStatusBarHeight: '0px',
hpx: '100%',
cur: 0,
- dotsStyles: ''
+ dotsStyles: '',
+ num: 3
};
},
onLoad() {
@@ -64,29 +64,52 @@
onReady() {
// this.move(0, 1);
},
+ mounted() {
+
+this.countDown()
+
+ },
methods: {
+ countDown() {
+ let {
+ num
+ } = this;
+ if (num === 3) this.nums = true;
+ num = num > 0 ? num - 1 : "GO";
+ setTimeout(() => {
+ this.num = num;
+ if (num == 'GO') {
+ this.launchApp()
+ return
+ }
+ this.countDown();
+ }, 1000);
+
+
+ },
+
stopTouchMove: function() {
return false;
},
-
+
launchApp() {
-
+
//跳过引导页,储存本地值,下次进入直接跳过
uni.setStorage({
key: 'launchFlag',
data: true,
success() {
-
+
uni.switchTab({
- url:'/pages/index/index'
+ url: '/pages/index/index'
})
}
});
},
guideAction(event) {
- let that = this,
+ let that = this,
index = event.detail.current;
- that.cur = index;
+ that.cur = index;
// if (index == 0) {
// that.move(0, 1);
// that.moveTwo(150, 0.1);
@@ -216,7 +239,7 @@
+
\ No newline at end of file
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 0eb5fe3..1b44c87 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -42,7 +42,7 @@
-
+
-
-
-
- 入库管理
-
-
-
- 商户设置
-
-
-
-
- 商品管理
-
-
-
-
- 提现管理
-
-
-
-
- 订单核销
-
-
-
-
-
-
-
-
-
-
-
- 我的店铺
-
-
-
- 供货采购
-
-
-
- 进货管理
-
-
-
-
- 扫码出库
-
-
+ @click="navigator(`/pages/nongKe/gather/select_warehouse?mer_id=${mer_id}&stype=1`)">
入库管理
+
+
+ 商户设置
+
+
+
+
+ 商品管理
+
提现管理
-
-
-
-
- 客服记录
-
订单核销
-
-
-
- 订单管理
-
-
-
-
- 商品管理
-
-
-
-
- 商户设置
-
-
-
-
- 交易大厅
-
-
委托销售
-
-
-
- 发布管理
-
-
-
-
+
+
委托订单
-
+ -->
+
+
+
+
+
+
+
+
+
+ 我的店铺
+
+
+
+
+ 供货采购
+
+
+
+ 进货管理
+
+
+
+
+ 扫码出库
+
+
+
+
+ 入库管理
+
+
+
+
+ 提现管理
+
+
+
+
+
+ 客服记录
+
+
+
+
+ 订单核销
+
+
+
+
+ 订单管理
+
+
+
+
+ 商品管理
+
+
+
+
+ 商户设置
+
+
+
+
+
+
+
-
-
-
-
-
-
- 里海云仓
-
-
-
- 供货采购
-
-
-
- 进货管理
-
-
-
-
- 扫码出库
-
-
-
-
- 入库管理
-
-
-
-
- 提现管理
-
+
+
+
+ 里海云仓
+
+
+
+ 供货采购
+
+
+
+ 进货管理
+
+
+
+
+ 扫码出库
+
+
+
+
+ 入库管理
+
+
+
+
+ 提现管理
+
-
-
-
- 客服记录
-
-
-
-
- 订单核销
-
-
-
-
- 订单管理
-
-
-
-
- 商品管理
-
-
-
-
- 商户设置
-
-
+
+
+
+
+
+ 我的店铺
+
+
+
+
+
+ 提现管理
+
+
+
+
+
+ 客服记录
+
+
+
+
+ 订单核销
+
+
+
+
+ 订单管理
+
+
+
+
+ 商品管理
+
+
+
+
+ 商户设置
+
+
+
+
+
+
+
+
-
-
+
+
我的店铺
-
-
-
- 提现管理
-
-
-
-
-
- 客服记录
-
-
-
-
- 订单核销
-
-
-
-
- 订单管理
-
-
-
-
- 商品管理
-
@@ -290,7 +328,6 @@
-
-
-
-
-
-
-
-
-
-
- 线下入库
- 线上入库
-
-
-
-
-
-
-
-
-
-
-
- 数量:
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+ 线下入库
+ 线上入库
+
+
+
+
+
+
+
+
+
+
+
+ 数量:
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/store/modules/app.js b/store/modules/app.js
index b0b862e..18284f4 100644
--- a/store/modules/app.js
+++ b/store/modules/app.js
@@ -1,5 +1,6 @@
import {
- getUserInfo
+ getUserInfo,
+ Appversion
} from "../../api/user.js";
import {
LOGIN_STATUS,
@@ -103,68 +104,72 @@ const actions = {
});
},
- async INIT_CONFIG({ state, commit }, data = false) {
- // let res = await getConfig();
- let res = {
- data: {
- version: '1.2.1',
- version_info: {
- "id": 4,
- "title": "正式IOS测试",
- "content": "IOS正式",
- "type": 1,
- "version": "1.2.1",
- "dow_url": "https://worker-task.lihaink.cn/uploads/files/20230908/20230908174409996e65763.wgt",
- "force": 0,
- "quiet": 0,
- "create_time": "2023-09-04 15:28:29",
- "update_time": "2023-09-04 15:28:29",
- "delete_time": null
- }
- }
- }
- const wgt_v = uni.getStorageSync('wgt_version')||'1.0.0';
- // #ifdef APP-PLUS
- let os = uni.getSystemInfoSync();
- if(data) uni.showLoading({
- title: '检查更新中'
- })
- // 版本更新
- if(compareVersions(res.data.version, os.appVersion||wgt_v)==1&&compareVersions(res.data.version, wgt_v)==1){
- try{
- let info = res.data.version_info||{};
- let version = {
- title: info.title||'发现新版本',
- content: info.content||'修复了部分BUG',
- versionName: info.version||'1.0.1',
- downUrl: info.dow_url||'',
- force: info.force==1?true:false, // 是否强制更新
- quiet: info.quiet==1?true:false // 是否静默更新
- }
- Updater.update(version);
- }catch(e){
- console.log(e);
- }
- if(data) uni.hideLoading();
- }
- // #endif
- }
+ async INIT_CONFIG({
+ state,
+ commit
+ }, data = false) {
+ const wgt_v = uni.getStorageSync('wgt_version') || '1.0.0';
+ // #ifdef APP-PLUS
+ let os = uni.getSystemInfoSync();
+ let apptype;
+ if (os.osName == 'ios') {
+ apptype = 2
+ } else {
+ apptype = 1
+ }
+ console.log(apptype, '11111')
+ Appversion({
+ version: os.appWgtVersion,
+ type: apptype
+ }).then((res) => {
+ if (data) uni.showLoading({
+ title: '检查更新中'
+ })
+
+ // 版本更新
+ if (compareVersions(res.data.appInfo.version, os.appWgtVersion || wgt_v) == 1 &&
+ compareVersions(res.data.appInfo.version,
+ wgt_v) == 1) {
+ try {
+ let info = res.data.appInfo || {};
+ let version = {
+ title: info.title || '发现新版本',
+ content: info.content || '修复了部分BUG',
+ versionName: info.version || '1.0.1',
+ downUrl: info.dow_url || '',
+ force: info.force == 1 ? true : false, // 是否强制更新
+ quiet: info.quiet == 1 ? true : false // 是否静默更新
+ }
+ Updater.update(version);
+ } catch (e) {
+ console.log(e);
+ }
+ if (data) uni.hideLoading();
+ }
+
+ }).catch((err) => {
+ console.log(err)
+ })
+
+
+ // #endif
+ }
};
function compareVersions(version1, version2) {
- const arr1 = version1.split('.').map(Number);
- const arr2 = version2.split('.').map(Number);
- for (let i = 0; i < Math.max(arr1.length, arr2.length); i++) {
- const num1 = i < arr1.length ? arr1[i] : 0;
- const num2 = i < arr2.length ? arr2[i] : 0;
+ const arr1 = version1.split('.').map(Number);
+ const arr2 = version2.split('.').map(Number);
+ for (let i = 0; i < Math.max(arr1.length, arr2.length); i++) {
+ const num1 = i < arr1.length ? arr1[i] : 0;
+ const num2 = i < arr2.length ? arr2[i] : 0;
- if (num1 > num2) {
- return 1;
- } else if (num1 < num2) {
- return -1;
- }
- }
- return 0;
+ if (num1 > num2) {
+ return 1;
+ } else if (num1 < num2) {
+ return -1;
+ }
+ }
+ return 0;
}
export default {