diff --git a/api/api.js b/api/api.js
index caa54c6..349142f 100644
--- a/api/api.js
+++ b/api/api.js
@@ -46,13 +46,13 @@ export function api(key, data, callback, loadingTitle) {
}
//必须登录
- // if (req.auth) {
- // if (!uni.getStorageSync('token')) {
- // utils.toLogin()
- // console.error('需要登录')
- // return
- // }
- // }
+ if (req.auth) {
+ if (!uni.getStorageSync('token')) {
+ utils.toLogin()
+ console.error('需要登录')
+ return
+ }
+ }
// 接口防抖
if(req.debounce){
diff --git a/api/http.js b/api/http.js
index 1d37fa6..8f2e8b8 100644
--- a/api/http.js
+++ b/api/http.js
@@ -25,13 +25,13 @@ function http(uri, data, callback, method = 'GET', showLoading, title) {
uni.hideLoading();
}
- // if(res.statusCode == 401 ||
- // res.data.message == '操作失败,token非法无效!' ||
- // res.data.message == '操作失败,用户不存在!'){
- // uni.removeStorageSync('token')
- // console.error('登录过期');
- // utils.toLogin()
- // }
+ if(res.statusCode == 401 ||
+ res.data.message == '操作失败,token非法无效!' ||
+ res.data.message == '操作失败,用户不存在!'){
+ uni.removeStorageSync('token')
+ console.error('登录过期');
+ utils.toLogin()
+ }
if(res.statusCode == 200 && res.data.code != 200
&& res.data.code != 902){
diff --git a/api/model/index.js b/api/model/index.js
index 784fdaa..72092e0 100644
--- a/api/model/index.js
+++ b/api/model/index.js
@@ -1,12 +1,10 @@
-
-
// 首页相关接口
const api = {
// 获取首页轮播图
getRiceBanner: {
url: '/index_common/getRiceBanner',
- method: 'GET',
+ method: 'GET',
},
// 获取首页常规产品【废弃】
// getRiceCommonProductList: {
@@ -16,32 +14,32 @@ const api = {
// 获取首页跳转图标
getRiceIconList: {
url: '/index_common/getRiceIconList',
- method: 'GET',
+ method: 'GET',
},
// 获取首页新闻详情
getRiceNewsDetail: {
url: '/index_common/getCommonNewsDetail',
- method: 'GET',
+ method: 'GET',
},
// 获取首页新闻列表
getRiceNewsList: {
url: '/index_common/getRiceNewsList',
- method: 'GET',
+ method: 'GET',
},
// 获取首页公告列表
getRiceNoticeList: {
url: '/index_common/getRiceNoticeList',
- method: 'GET',
+ method: 'GET',
},
// 获取首页商品详情
getRiceProductDetail: {
url: '/index_common/getRiceProductDetail',
- method: 'GET',
+ method: 'GET',
},
// 获取首页体验产品
getRiceProductList: {
url: '/index_common/getRiceProductList',
- method: 'GET',
+ method: 'GET',
},
// 查询分类接口
getCategoryList: {
@@ -57,62 +55,67 @@ const api = {
addCart: {
url: '/index_common/addCart',
method: 'GET',
- auth : true,
- showLoading : true,
+ auth: true,
+ showLoading: true,
},
// 删除购物车信息
deleteCart: {
url: '/index_common/deleteCart',
method: 'DELETE',
- auth : true,
- showLoading : true,
+ auth: true,
+ showLoading: true,
},
// 修改购物车信息数量
updateCartNum: {
url: '/index_common/updateCartNum',
method: 'POST',
- auth : true,
- debounce : 300,
+ auth: true,
+ debounce: 300,
},
// 创建订单
createOrder: {
url: '/index_common/createOrder',
method: 'GET',
- auth : true,
- limit : 1000,
- showLoading : true,
+ auth: true,
+ limit: 1000,
+ showLoading: true,
},
// 创建订单-再次支付
createOrderTwo: {
url: '/index_common/createOrderTwo',
method: 'GET',
- auth : true,
- limit : 1000,
- showLoading : true,
+ auth: true,
+ limit: 1000,
+ showLoading: true,
},
// 多商品创建订单
createSumOrder: {
url: '/index_common/createSumOrder',
method: 'POST',
- auth : true,
- limit : 1000,
- showLoading : true,
+ auth: true,
+ limit: 1000,
+ showLoading: true,
},
// 多商品订单再次支付
createSumOrderAgain: {
url: '/index_common/createSumOrderAgain',
method: 'POST',
- auth : true,
- limit : 1000,
- showLoading : true,
+ auth: true,
+ limit: 1000,
+ showLoading: true,
},
// 确认收货
confirmOrder: {
url: '/index_common/confirmOrder',
method: 'GET',
- auth : true,
- limit : 1000,
- showLoading : true,
+ auth: true,
+ limit: 1000,
+ showLoading: true,
+ },
+ // 获取首页广告列表
+ getRiceProductList: {
+ url: '/index_common/getRiceAdList',
+ method: 'GET',
},
}
diff --git a/components/product/productItem.vue b/components/product/productItem.vue
index 0008a76..b9a0d22 100644
--- a/components/product/productItem.vue
+++ b/components/product/productItem.vue
@@ -20,11 +20,10 @@
¥{{ item.vipPrice }}/元每件
-
-
-
+
+
+
+
diff --git a/config.js b/config.js
index 8180659..1660015 100644
--- a/config.js
+++ b/config.js
@@ -1,4 +1,3 @@
-
import Vue from 'vue'
import api from '@/api/api.js'
import utils from './utils/utils.js'
@@ -12,30 +11,30 @@ const type = 'dev'
// 环境配置
const config = {
- dev : {
- baseUrl : 'http://h5.xzaiyp.top/jewelry-admin',
+ dev: {
+ baseUrl: 'http://h5.xzaiyp.top/jewelry-admin',
},
- prod : {
- baseUrl : 'https://jewelry-admin.hhlm1688.com/jewelry-admin',
+ prod: {
+ baseUrl: 'https://jewelry-admin.hhlm1688.com/jewelry-admin',
}
}
// 默认配置
const defaultConfig = {
- mapKey : 'XMBBZ-BCPCV-SXPPQ-5Y7MY-PHZXK-YFFVU',
- aliOss : {
- url : 'https://tennis-oss.xzaiyp.top/',
- config : {
+ mapKey: 'XMBBZ-BCPCV-SXPPQ-5Y7MY-PHZXK-YFFVU',
+ aliOss: {
+ url: 'https://image.hhlm1688.com/',
+ config: {
//桶的地址
region: 'oss-cn-guangzhou',
//id
- accessKeyId:'LTAI5tNycA46YTwm383dRvMV',
+ accessKeyId: 'LTAI5tQSs47izVy8DLVdwUU9',
//密钥
- accessKeySecret:'tAdbYQCmdur6jbZ8hjvgB7T1Z52mIG',
+ accessKeySecret: 'qHI7C3PaXYZySr84HTToviC71AYlFq',
//桶的名字
- bucket: 'zhuoqiu-image',
- endpoint:'oss-cn-guangzhou.aliyuncs.com',
+ bucket: 'hanhaiimage',
+ endpoint: 'oss-cn-shenzhen.aliyuncs.com',
}
},
}
diff --git a/manifest.json b/manifest.json
index 99308e9..4c34af0 100644
--- a/manifest.json
+++ b/manifest.json
@@ -52,7 +52,7 @@
"quickapp" : {},
/* 小程序特有相关 */
"mp-weixin" : {
- "appid" : "wx0839bc52e7849c13",
+ "appid" : "wx28679cb649907e7e",
"setting" : {
"urlCheck" : false
},
diff --git a/pages.json b/pages.json
index ce99883..6d9d8de 100644
--- a/pages.json
+++ b/pages.json
@@ -48,9 +48,7 @@
},
"subPackages": [{
"root": "pages_order",
- "pages": [{
- "path": "mine/card"
- },
+ "pages": [
{
"path": "mine/partner"
},
diff --git a/pages/index/category.vue b/pages/index/category.vue
index 6be8330..af32428 100644
--- a/pages/index/category.vue
+++ b/pages/index/category.vue
@@ -15,7 +15,7 @@
+ @click="$utils.navigateTo(`/pages_order/product/productDetail?id=${item.id}`)" />
@@ -23,7 +23,6 @@
-
diff --git a/pages/index/center.vue b/pages/index/center.vue
index 007d31d..9d39a06 100644
--- a/pages/index/center.vue
+++ b/pages/index/center.vue
@@ -12,7 +12,7 @@
- 倾心.临时决定离开军队费时费力士大夫
+ {{ userInfo.nickName}}
@@ -62,7 +62,7 @@
-
+
我的佣金
@@ -71,7 +71,7 @@
-
+
我的余额
@@ -99,7 +99,7 @@
联系客服
-
+
邀请好友
@@ -118,7 +118,7 @@
优惠券
-
+
帮助与反馈
@@ -155,13 +155,14 @@
mapState
} from 'vuex'
import customerServicePopup from '@/components/config/customerServicePopup.vue'
+
export default {
components: {
tabber,
customerServicePopup,
},
computed: {
- ...mapState(['userInfo', 'riceInfo']),
+ ...mapState(['userInfo', 'riceInfo','configList']),
},
data() {
return {
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 1661725..8debda1 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -46,8 +46,8 @@
-
-
+
+
¥100
@@ -63,7 +63,7 @@
-
+
@@ -89,7 +89,7 @@
-
+
@@ -126,7 +126,8 @@
riceProductList: [], //体验产品
newList: [], //新闻列表
mixinsListApi: 'getClassShophomeList',
- showCouponPopup : true
+ showCouponPopup: true,
+ adList : []
}
},
computed: {},
@@ -139,6 +140,7 @@
this.getBanner()
this.getRiceNoticeList()
this.getRiceIconList()
+ this.getRiceAdList()
// this.getRiceCommonProductList()
},
onPullDownRefresh() {
@@ -204,7 +206,16 @@
getRiceIconList() {
this.$api('getRiceIconList', res => {
if (res.code == 200) {
- this.baseList = res.result.slice(0, 5)
+ this.baseList = res.result
+ }
+ })
+ },
+
+ //获取首页广告
+ getRiceAdList() {
+ this.$api('getRiceProductList', res => {
+ if (res.code == 200) {
+ this.adList = res.result.records
}
})
},
@@ -240,11 +251,11 @@
scroll: function(e) {
},
-
+
//跳转优惠券页面
toCoupon() {
uni.navigateTo({
- url: "/pages_order/mine/withdraw"
+ url: "/pages_order/mine/coupon"
})
}
},
@@ -374,6 +385,7 @@
padding: 20rpx;
background: white;
font-size: 34rpx;
+
.line {
height: 40rpx;
width: 10rpx;
@@ -382,7 +394,7 @@
margin-right: 10rpx;
}
}
-
+
.video-list {
.scroll-view_H {
white-space: nowrap;
@@ -409,11 +421,11 @@
background: white;
margin: 20rpx 0rpx;
padding: 20rpx;
-
+
.recommend-title {
font-size: 36rpx;
}
-
+
.recommend-more {
color: $uni-color;
}
diff --git a/pages_order/mine/balance.vue b/pages_order/mine/balance.vue
index 0e55e56..728f725 100644
--- a/pages_order/mine/balance.vue
+++ b/pages_order/mine/balance.vue
@@ -8,15 +8,6 @@
-
-
收支明细
+
+ 导航栏
-
+ 会员列表
@@ -22,7 +22,7 @@
-
+ 小会员列表
@@ -138,4 +138,4 @@
}
}
}
-
\ No newline at end of file
+ -->
\ No newline at end of file
diff --git a/pages_order/mine/memberCenter.vue b/pages_order/mine/memberCenter.vue
index 66562eb..2e7e7c4 100644
--- a/pages_order/mine/memberCenter.vue
+++ b/pages_order/mine/memberCenter.vue
@@ -47,7 +47,7 @@
-
+
diff --git a/pages_order/mine/promotion.vue b/pages_order/mine/promotion.vue
index d3fcfc5..7593b77 100644
--- a/pages_order/mine/promotion.vue
+++ b/pages_order/mine/promotion.vue
@@ -1,24 +1,12 @@
-
-
-
-
-
-
-
-
@@ -44,8 +32,8 @@
data() {
return {
url: '',
- title: '123123',
- baseUrl: 'https://dianpin-img.xzaiyp.top/',
+ title: '',
+ baseUrl: 'https://image.hhlm1688.com/',
canvas: {},
imagePath: '',
}
diff --git a/pages_order/mine/withdraw.vue b/pages_order/mine/withdraw.vue
index 7c4d575..644d7c1 100644
--- a/pages_order/mine/withdraw.vue
+++ b/pages_order/mine/withdraw.vue
@@ -5,7 +5,7 @@
-
+
总佣金
@@ -29,20 +29,17 @@
- 我要提现
+ 我要提现
-
-
-
-
-
+
-
-
+
+
+
+
+ 提现说明
+
@@ -67,9 +64,7 @@
type: ['+', '-'],
state: ['未到账', '已到账'],
form: {
- money: '',
- bankNo: '',
- bankName: '',
+ money: ''
},
}
},
@@ -78,7 +73,6 @@
},
data() {
return {
- withdrawalStatement: '', //充值说明
form: {
type: 1,
price: undefined,
@@ -237,18 +231,24 @@
text-align: left;
color: #333333;
}
+
+ .from-body .title{
+ font-size: 36rpx;
+ }
.money {
margin: 20rpx 0rpx;
}
-
- .money .van-cell-group--inset {
- margin: 0;
- }
-
- .money .van-field {
- padding: auto 0rpx;
- margin-bottom: 30rpx !important;
+
+ // 提现说明
+ .withdrawal-statement {
+ padding: 0rpx 20rpx;
+ box-sizing: border-box;
+
+ .title {
+ font-size: 36rpx;
+ margin-bottom: 20rpx;
+ }
}
.recharge {
diff --git a/pages_order/order/createOrder.vue b/pages_order/order/createOrder.vue
index dc11270..9080ad4 100644
--- a/pages_order/order/createOrder.vue
+++ b/pages_order/order/createOrder.vue
@@ -33,8 +33,8 @@
- 李满和
- 城南故事C3栋2802数据都是佛山佛挡杀佛
+ {{ address.name }}
+ {{ address.address}}
@@ -48,7 +48,7 @@
账户余额
- (余额: 300)
+ (余额: {{ userInfo.money}})
@@ -64,7 +64,7 @@
-
+
@@ -77,7 +77,7 @@
$20
-
+
@@ -117,7 +117,7 @@