diff --git a/config.js b/config.js
index 244a289..fce1384 100644
--- a/config.js
+++ b/config.js
@@ -6,11 +6,14 @@ import uvUI from '@/uni_modules/uv-ui-tools'
Vue.use(uvUI);
// 当前环境
-const type = 'prod'
+const type = 'local'
// 环境配置
const config = {
+ local : {
+ baseUrl: 'http://127.0.0.1:8001/jewelry-admin',
+ },
dev: {
baseUrl: 'http://h5.xzaiyp.top/jewelry-admin',
},
diff --git a/pages/index/center.vue b/pages/index/center.vue
index 60af95d..7b0d2e3 100644
--- a/pages/index/center.vue
+++ b/pages/index/center.vue
@@ -354,7 +354,7 @@
.earnings {
padding: 0rpx 20rpx;
box-sizing: border-box;
- margin-top: -18%;
+ margin-top: -80rpx;
.member-item {
position: relative;
diff --git a/pages_order/mine/promotion.vue b/pages_order/mine/promotion.vue
index 9a35658..3b0853d 100644
--- a/pages_order/mine/promotion.vue
+++ b/pages_order/mine/promotion.vue
@@ -9,7 +9,7 @@
+ :src="promotionUrl" mode="aspectFill">
@@ -36,7 +36,8 @@ import index from '../../uni_modules/uv-ui-tools'
title: '',
baseUrl: 'https://image.hhlm1688.com/',
canvas: {},
- imagePath: 'https://image.hhlm1688.com/2025-03-06/32fbb8e2-160b-4cbf-9a49-a72de231de20.png',
+ imagePath : '',
+ // imagePath: 'https://image.hhlm1688.com/2025-03-06/32fbb8e2-160b-4cbf-9a49-a72de231de20.png',
// imagePath: 'https://image.hhlm1688.com/2025-02-27/2fe7e417-54ad-4911-b9ba-84ac7d48e66d.png',
// imagePath: 'https://image.hhlm1688.com/2025-02-26/6539d2fa-558d-47db-9681-ecffec5b6c5d.png',
index : 0,
@@ -45,30 +46,47 @@ import index from '../../uni_modules/uv-ui-tools'
onShow() {
let that = this;
// that.draw()
- // if(!that.promotionUrl){
+ if(!that.promotionUrl){
// that.getQrCode()
- // uni.showLoading({
- // title: "拼命绘画中..."
- // })
- // }
+ this.getImageInfo()
+ }
// that.$store.commit('getUserInfo')
},
methods: {
+ getImageInfo(){
+ let that = this;
+ uni.showLoading({
+ title: "拼命绘画中..."
+ })
+ uni.getImageInfo({
+ src: `${this.$config.baseUrl}/info_common/getInviteCode?token=${uni.getStorageSync('token')}`,
+ success : res => {
+ uni.hideLoading()
+ that.$store.commit('setPromotionUrl', res.path)
+ },
+ fail : err => {
+ uni.showToast({
+ icon: 'none',
+ title: '绘画失败',
+ })
+ }
+ })
+ },
getQrCode() {
- // uni.showLoading({
- // title: "拼命绘画中..."
- // })
+ uni.showLoading({
+ title: "拼命绘画中..."
+ })
let that = this;
that.$api('getInviteCode', res => {
if (res.code == 200) {
that.url = res.result.url
that.title = res.result.name
- // that.imagePath = that.$config.aliOss.url + res.result.url
+ that.imagePath = that.$config.aliOss.url + res.result.url
- // that.$store.commit('setPromotionUrl', that.imagePath)
+ that.$store.commit('setPromotionUrl', that.imagePath)
- that.draw()
+ // that.draw()
uni.hideLoading()
}
})
diff --git a/pages_order/product/productDetail.vue b/pages_order/product/productDetail.vue
index 953307a..68b704e 100644
--- a/pages_order/product/productDetail.vue
+++ b/pages_order/product/productDetail.vue
@@ -2,6 +2,14 @@
+
+
+
+
.page {
padding-bottom: 120rpx;
+
+ .leftClick{
+ position: absolute;
+ top: calc(var(--status-bar-height) + 20rpx);
+ left: 20rpx;
+ background-color: #00000073;
+ padding: 20rpx;
+ border-radius: 50%;
+ z-index: 99;
+ }
+
.swipe {}
// 商品标题
diff --git a/store/store.js b/store/store.js
index a167558..9222839 100644
--- a/store/store.js
+++ b/store/store.js
@@ -145,11 +145,17 @@ const store = new Vuex.Store({
},
getQrCode(state) {
- api('getInviteCode', res => {
- if (res.code == 200) {
- state.promotionUrl = Vue.prototype.$config.aliOss.url + res.result.url
+ let that = this;
+ if(!uni.getStorageSync('token')){
+ return
+ }
+ uni.getImageInfo({
+ src: `${Vue.prototype.$config.baseUrl}/info_common/getInviteCode?token=${uni.getStorageSync('token')}`,
+ success : res => {
+ that.commit('setPromotionUrl', res.path)
+ },
+ fail : err => {
}
- uni.hideLoading()
})
},
// 查询分类接口