From 5398b4234da1d118910d2a7d62def76ab0265cd3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A7=A6=E5=BD=A6=E7=A5=96?= <605893810@qq.com> Date: Sun, 17 Aug 2025 07:30:15 +0800 Subject: [PATCH] =?UTF-8?q?fixbug:=20=E4=BF=AE=E5=A4=8D=E9=83=A8=E5=88=86b?= =?UTF-8?q?ug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- manifest.json | 4 +- pages.json | 47 +++--- pages/home/home.vue | 2 +- pages/index/index.vue | 151 ------------------ pages/mine/mine.vue | 2 +- .../mine_address_add/mine_address_add.vue | 4 +- .../order_submit/order_submit.vue | 110 ++++++------- pages/rwa_package/dongjian/jia.vue | 12 +- .../merchant_settlement.vue | 0 9 files changed, 95 insertions(+), 237 deletions(-) delete mode 100644 pages/index/index.vue rename pages/{ => rwa_package}/merchant_settlement/merchant_settlement.vue (100%) diff --git a/manifest.json b/manifest.json index c0843d7..e20cc85 100644 --- a/manifest.json +++ b/manifest.json @@ -2,8 +2,8 @@ "name" : "信任桥", "appid" : "__UNI__4910728", "description" : "信任桥优品是一款集线上商城、线下联盟商家的DAO聚合商城;通过“有趣”“有利”“有希望”的卖货玩法,吸引消费者、推广者、商家、投资人参与生态,共同打造共创共享的全球产业生态。", - "versionName" : "1.0.0", - "versionCode" : 125, + "versionName" : "1.0.2", + "versionCode" : 127, "transformPx" : false, /* 5+App特有相关 */ "app-plus" : { diff --git a/pages.json b/pages.json index c8f157e..2c2f7e8 100644 --- a/pages.json +++ b/pages.json @@ -15,13 +15,13 @@ "navigationStyle": "custom" } }, - { - "path": "pages/index/index", - "style": { - "navigationBarTitleText": "%index.title%", - "navigationStyle": "custom" - } - }, + // { + // "path": "pages/index/index", + // "style": { + // "navigationBarTitleText": "%index.title%", + // "navigationStyle": "custom" + // } + // }, { "path": "pages/sort/sort", @@ -35,22 +35,13 @@ "navigationStyle": "custom" } }, - { - "path": "pages/LuckyWheel/LuckyWheel", - "style": { - "navigationBarTitleText": "" - } - }, - { - "path": "pages/merchant_settlement/merchant_settlement", - "style": { - "navigationBarTitleText": "%mine.merchant.settlement.title%", - "navigationBarBackgroundColor": "#FFFFFF", - "navigationBarTextStyle": "black", - "enablePullDownRefresh": false, - "navigationStyle": "default" // 默认样式,会显示返回图标 - } - }, + // { + // "path": "pages/LuckyWheel/LuckyWheel", + // "style": { + // "navigationBarTitleText": "" + // } + // }, + { "path": "pages/supply_chain/supply_chain", "style": { @@ -257,6 +248,16 @@ "navigationStyle": "custom" } }, + { + "path": "merchant_settlement/merchant_settlement", + "style": { + "navigationBarTitleText": "%mine.merchant.settlement.title%", + "navigationBarBackgroundColor": "#FFFFFF", + "navigationBarTextStyle": "black", + "enablePullDownRefresh": false, + "navigationStyle": "default" // 默认样式,会显示返回图标 + } + }, { "path": "dongjian/index", "style": { diff --git a/pages/home/home.vue b/pages/home/home.vue index c450185..4db0a7c 100644 --- a/pages/home/home.vue +++ b/pages/home/home.vue @@ -88,7 +88,7 @@ radius='15'> {{ item.title }} - 优选价{{ item.adPrice }}元 + 优选价{{ item.price }}元 diff --git a/pages/index/index.vue b/pages/index/index.vue deleted file mode 100644 index 48fa673..0000000 --- a/pages/index/index.vue +++ /dev/null @@ -1,151 +0,0 @@ - - - - - diff --git a/pages/mine/mine.vue b/pages/mine/mine.vue index 56dbd0d..efa2885 100644 --- a/pages/mine/mine.vue +++ b/pages/mine/mine.vue @@ -121,7 +121,7 @@ 企业入驻 请联系负责人 - {{CUSTOMER_SERVICE_PHONE_NUMBER}} + {{ CUSTOMER_SERVICE_PHONE_NUMBER }} 复制号码 diff --git a/pages/mine_package/mine_address_add/mine_address_add.vue b/pages/mine_package/mine_address_add/mine_address_add.vue index e922149..24fe951 100644 --- a/pages/mine_package/mine_address_add/mine_address_add.vue +++ b/pages/mine_package/mine_address_add/mine_address_add.vue @@ -82,7 +82,7 @@ export default { } const ids = option.ids; if (ids && ids !== 0) { - this.leftPath = "/pages/order_package/order_submit/order_submit?ids=" + ids + "&addressShow = true"; + this.leftPath = "/pages/order_package/order_submit/order_submit?ids=" + ids + "&addressShow=true"; } }, methods: { @@ -246,6 +246,8 @@ export default { message: params.id && params.id !== 0 ? '修改成功' : "添加成功", }); const leftPath = this.leftPath; + console.log("参数--111-", leftPath) + setTimeout(() => { uni.navigateTo({ url: leftPath, diff --git a/pages/order_package/order_submit/order_submit.vue b/pages/order_package/order_submit/order_submit.vue index 23f11bb..2820257 100644 --- a/pages/order_package/order_submit/order_submit.vue +++ b/pages/order_package/order_submit/order_submit.vue @@ -180,7 +180,7 @@ import Address from '@/components/address.vue'; import { getGoodsDetail } from '@/api/product.js'; import { PAYMENT_WAY, PAYMENT_WAY_, PRODUCT_DELIVERY_TIME, getValue, WAY_LIST } from '@/utils/enumUtils.js'; -import { getSettleList, settle,settlementOrder, updateGoodsNum } from '@/api/cart.js'; +import { getSettleList, settle, settlementOrder, updateGoodsNum } from '@/api/cart.js'; import { getSupportPay } from '@/api/order.js'; import { feedback } from '@/api/payment.js'; import { assembleAddress } from '@/utils/index.js' @@ -216,14 +216,14 @@ export default { selectAddress: {},// 收件地址选择 wayOption: [], isShowBalance: false, - ji:0, - sed:null, - curPay:null + ji: 0, + sed: null, + curPay: null }; }, onLoad(option) { // const ids = option.ids; - if(option.sed){ + if (option.sed) { this.ji = 1; this.sed = JSON.parse(option.sed) this.getOrderTwo(); @@ -232,9 +232,11 @@ export default { this.ids = option.ids; this.getOrder(); } - const addressShow = option.addressShow; - if (addressShow && addressShow !== "null") { - this.addressShow = addressShow; + console.log("参数---", option) + + const addressShowPop = option.addressShow; + if (addressShowPop && addressShowPop !== "null") { + this.addressShow = addressShowPop; } // 支付弹框 const payOpen = option.payOpen; @@ -266,12 +268,12 @@ export default { async getWayOption() { let parmas = { } - if(this.ji){ + if (this.ji) { parmas['types'] = '4'; - }else{ + } else { parmas['types'] = '2,3'; } - console.log('this.ji',parmas) + console.log('this.ji', parmas) const result = await getSupportPay(parmas); if (result && result.bizcode === 100) { const data = result.data || []; @@ -285,7 +287,7 @@ export default { this.isShowBalance = balanceFlag; } this.wayOption = data; - console.log('getWayOption',this.wayOption) + console.log('getWayOption', this.wayOption) } }, async getOrder() { @@ -330,42 +332,42 @@ export default { const data = resp.data; this.ji = data.type == 3 ? 1 : 0; this.orderInfo = { - address:null, - amount:this.sed.goodsNum * this.sed.specsId.price, - shops:[{ - addrTimes:[ + address: null, + amount: this.sed.goodsNum * this.sed.specsId.price, + shops: [{ + addrTimes: [ { - address:null, - deliveryTime:data.deliveryTime, - postagesId:data.postagesId, - postagesType:1, - goods:[ + address: null, + deliveryTime: data.deliveryTime, + postagesId: data.postagesId, + postagesType: 1, + goods: [ { - adress:null, - addressId:null, - areaName:null, - cityName:null, - goodsId:this.sed.id, - id:this.sed.specsId.id, - img:data.goodsGraph, - name:null, - num:this.sed.goodsNum, - phone:null, - provinceName:null, - specs:this.sed.specsId.combNames, - title:data.name, - totalPrice:this.sed.goodsNum * this.sed.specsId.price, - unitPrice:this.sed.specsId.price - + adress: null, + addressId: null, + areaName: null, + cityName: null, + goodsId: this.sed.id, + id: this.sed.specsId.id, + img: data.goodsGraph, + name: null, + num: this.sed.goodsNum, + phone: null, + provinceName: null, + specs: this.sed.specsId.combNames, + title: data.name, + totalPrice: this.sed.goodsNum * this.sed.specsId.price, + unitPrice: this.sed.specsId.price + } ] - + } - ],id:data.shop.id,logo:data.shop.logo,name:data.shop.name + ], id: data.shop.id, logo: data.shop.logo, name: data.shop.name }] }; this.orderInfo.paymentMethod = null; - + } // const params = { // cartIds: ids, @@ -453,8 +455,8 @@ export default { * 去支付 */ async goPay() { - - console.log('getWayOption',this.wayOption,this.orderInfo) + + console.log('getWayOption', this.wayOption, this.orderInfo) const orderInfo = this.orderInfo; if (!orderInfo.address || Object.keys(orderInfo.address).length === 0) { @@ -473,10 +475,10 @@ export default { }); return; } - let arr = this.wayOption.filter(i=>i.type == orderInfo.paymentMethod); - if(arr.length){ - if(arr[0].type == 'balance' || arr[0].type == 'redpacket'){ - if(arr[0].balance < orderInfo.amount){ + let arr = this.wayOption.filter(i => i.type == orderInfo.paymentMethod); + if (arr.length) { + if (arr[0].type == 'balance' || arr[0].type == 'redpacket') { + if (arr[0].balance < orderInfo.amount) { this.$refs.uToastRef.show({ type: 'error', message: "余额不足", @@ -484,14 +486,14 @@ export default { return; } } - }else{ + } else { this.$refs.uToastRef.show({ type: 'error', message: "请先选择支付方式", }); return; } - + const params = { addrId: orderInfo.address.id,// 收货地址ID //结算的购物车ID,多个以逗号分割,ALL表示全选 @@ -499,19 +501,19 @@ export default { remark: JSON.stringify(this.getRemark()),//备注信息'[{"sid":"店铺ID","rmk":"备注内容"},{"sid":"店铺ID","rmk":"备注内容"}]' } let resp = null; - if(this.sed){ + if (this.sed) { params['goodsId'] = this.sed.id; params['specsId'] = this.sed.specsId.id; params['goodsNum'] = this.orderInfo.shops[0].addrTimes[0].goods[0].num; resp = await settlementOrder(params); - }else{ + } else { params['cartIds'] = this.ids; resp = await settle(params); } - - console.log('getWayOption',resp) - - + + console.log('getWayOption', resp) + + // 提交订单成功,就唤起支付 if (resp && resp.bizcode === 100) { const item = resp.data; diff --git a/pages/rwa_package/dongjian/jia.vue b/pages/rwa_package/dongjian/jia.vue index dcb8521..2eaddef 100644 --- a/pages/rwa_package/dongjian/jia.vue +++ b/pages/rwa_package/dongjian/jia.vue @@ -27,7 +27,8 @@ @@ -63,6 +64,7 @@ import Header from '@/components/common/header.vue'; import TopSafe from '@/components/common/top-safe.nvue' import DownPopup from '@/components/common/down-popup.vue'; import { quickens } from '@/api/contract.js' +import Decimal from 'decimal.js'; import func from '@/utils/func.js'; @@ -104,8 +106,9 @@ export default { this.topList[2].value = res.data.quickenBalance; this.tableList = res.data.quickenDetail; this.tableList.forEach(item => { - item.one = item.quickenRate * 100 + '%'; - item.two = item.quickenValue; + const ratio = new Decimal(item.quickenRate); + item.one = ratio.times(100).toNumber() + '%'; + item.two = new Decimal(item.quickenValue); item.three = func.formatDate(new Date(item.ctdate), 3) }) } else { @@ -127,7 +130,8 @@ export default { //去签署 } - } + }, + } } diff --git a/pages/merchant_settlement/merchant_settlement.vue b/pages/rwa_package/merchant_settlement/merchant_settlement.vue similarity index 100% rename from pages/merchant_settlement/merchant_settlement.vue rename to pages/rwa_package/merchant_settlement/merchant_settlement.vue