diff --git a/api/mall.js b/api/mall.js
index aba5ec8..2d574c7 100644
--- a/api/mall.js
+++ b/api/mall.js
@@ -2,8 +2,12 @@ import {
http
} from "../util/api";
+const baseUrl = "http://192.168.0.26:3000"
+
export const mallAPI = {
- getMallList: (params) => http.get('/mall', params)
+ getMallList: (params) => http.get(baseUrl + '/api/products', params),
+ getCategory: () => http.get(baseUrl + '/api/category'),
+ getMallDetail: (id) => http.get(baseUrl + '/products/' + id)
}
export default {
diff --git a/api/message.js b/api/message.js
index 7dd4a45..f8e5e8d 100644
--- a/api/message.js
+++ b/api/message.js
@@ -2,7 +2,8 @@ import {
http
} from "../util/api"
-const baseURL = "http://192.168.0.12:3005/chat"
+// const baseURL = "http://192.168.0.12:3005/chat"
+const baseURL = "http://192.168.0.15:3007"
// 项目相关API
export const messageAPI = {
diff --git a/pages.json b/pages.json
index 674302b..a7ad9eb 100644
--- a/pages.json
+++ b/pages.json
@@ -58,41 +58,51 @@
}
},
{
- "path" : "pages/mall/mall",
- "style" :
- {
- "navigationBarTitleText" : "商城",
+ "path": "pages/mall/mall",
+ "style": {
+ "navigationBarTitleText": "商城",
"navigationStyle": "custom"
}
},
{
- "path" : "pages/message/chat",
- "style" :
- {
- "navigationBarTitleText" : "聊天页面",
+ "path": "pages/message/chat",
+ "style": {
+ "navigationBarTitleText": "聊天页面",
"navigationStyle": "custom",
"enablePullDownRefresh": true
}
},
{
- "path" : "pages/message/systemMessage",
- "style" :
- {
- "navigationBarTitleText" : "系统通知",
+ "path": "pages/message/systemMessage",
+ "style": {
+ "navigationBarTitleText": "系统通知",
"navigationBarBackgroundColor": "#F0F3FF",
"navigationBarTextStyle": "#000",
"app-plus": {
"titleNView": {
- "buttons": [
- {
+ "buttons": [{
"type": "menu",
"color": "#000"
}
-
+
]
}
}
}
+ },
+ {
+ "path": "pages/home/mallDetail",
+ "style": {
+ "navigationBarTitleText": "商品详情",
+ "navigationStyle": "custom"
+ }
+ },
+ {
+ "path": "pages/home/mallCategory",
+ "style": {
+ "navigationBarTitleText": "商品分类",
+ "navigationStyle": "custom"
+ }
}
],
"globalStyle": {
diff --git a/pages/home/index.vue b/pages/home/index.vue
index b0e2841..c28f8ab 100644
--- a/pages/home/index.vue
+++ b/pages/home/index.vue
@@ -1,174 +1,339 @@
-
-
-
-
-
-
-
+
+
+
\ No newline at end of file
diff --git a/pages/home/mallCategory.vue b/pages/home/mallCategory.vue
new file mode 100644
index 0000000..671d362
--- /dev/null
+++ b/pages/home/mallCategory.vue
@@ -0,0 +1,319 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{item.name}}
+
+ ¥{{item.price}}
+
+
+ {{item.rongdou_price}}
+
+
+
+ {{item.points_price}}
+
+
+
+ 融豆
+
+
+ 积分
+
+
+
+ {{item.category}}
+
+
+
+
+
+
+
+ {{item.name}}
+
+ ¥{{item.price}}
+
+
+ {{item.rongdou_price}}
+
+
+
+ {{item.points_price}}
+
+
+
+ 融豆
+
+
+ 积分
+
+
+
+ {{item.category}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/home/mallDetail.vue b/pages/home/mallDetail.vue
new file mode 100644
index 0000000..089efb4
--- /dev/null
+++ b/pages/home/mallDetail.vue
@@ -0,0 +1,146 @@
+
+
+
+
+
+
+
+
+ 111
+
+
+
+
+
+
+ 店铺
+
+
+
+ 客服
+
+
+
+ 收藏
+
+
+
+ 加入购物车
+ 领券购买
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/my/my.vue b/pages/my/my.vue
index a251876..d31e637 100644
--- a/pages/my/my.vue
+++ b/pages/my/my.vue
@@ -7,7 +7,7 @@
-
@@ -15,7 +15,7 @@
-
+
@@ -51,7 +51,89 @@
- 退出登录
+
+
+
+ vip专享
+
+
+ 立享价值1000元权益
+
+
+ 298元开通
+
+
+
+
+
+ 会员权益
+
+
+ 领取升级福利
+
+
+
+
+ 积分商城
+
+
+ 赚积分享福利
+
+
+
+
+
+
+ 退出登录
@@ -92,10 +174,11 @@
justify-content: flex-end;
.header-user {
- padding: 20rpx 10rpx;
flex: 1;
display: flex;
align-items: center;
+ height: 170rpx;
+ padding-left: 60rpx;
}
.header-setting {
@@ -103,17 +186,139 @@
height: 52rpx;
}
}
-
- .statistics{
+
+ .statistics {
display: flex;
-
- .item{
+
+ font-family: SF Pro;
+ font-weight: 510;
+ font-style: Medium;
+ font-size: 32rpx;
+ leading-trim: NONE;
+ line-height: 48rpx;
+ letter-spacing: 0%;
+
+ margin: 40rpx 0 20rpx;
+
+ .item {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 25%;
- border: 1rpx solid #000;
+
+ }
+ }
+
+ .open-vip {
+ display: flex;
+ justify-content: space-between;
+ background: #2B2B2B;
+ align-items: center;
+ padding: 24rpx 0;
+ border-top-left-radius: 24rpx;
+ border-top-right-radius: 24rpx;
+
+ .text-vip {
+ margin-left: 32rpx;
+ display: flex;
+ flex-direction: column;
+ color: #FFDD9E;
+ justify-content: flex-start;
+
+ .title {
+ font-family: SF Pro;
+ font-weight: 700;
+ font-style: Bold;
+ font-size: 32rpx;
+ leading-trim: NONE;
+ line-height: 48rpx;
+ letter-spacing: 0%;
+ }
+
+ .sub-title {
+ font-family: SF Pro;
+ font-weight: 274;
+ font-style: Light;
+ font-size: 32rpx;
+ leading-trim: NONE;
+ line-height: 48rpx;
+ letter-spacing: 0%;
+
+ }
+ }
+
+ .btn-vip {
+ margin-right: 42rpx;
+ width: 180rpx;
+ height: 56rpx;
+ border: none;
+ border-radius: 198rpx;
+ background: linear-gradient(90deg, #FFCC5E 0%, #FFE9BA 47.27%, #FFCC5E 100%);
+ }
+ }
+
+ .white-block {
+ margin-top: 44rpx;
+ display: flex;
+ justify-content: space-between;
+
+ .item {
+ width: 48%;
+ background: #F5F8FF;
+ display: flex;
+ flex-direction: column;
+ padding: 30rpx 32rpx;
+ border-radius: 24rpx;
+
+ .title {
+ font-family: SF Pro;
+ font-weight: 700;
+ font-style: Bold;
+ font-size: 32rpx;
+ leading-trim: NONE;
+ line-height: 48rpx;
+ letter-spacing: 0%;
+ }
+
+ .sub-title {
+ margin-top: 14rpx;
+ font-family: Work Sans;
+ font-weight: 400;
+ font-size: 26rpx;
+ leading-trim: NONE;
+ line-height: 100%;
+ letter-spacing: -2%;
+ color: #8C8C8C;
+ }
+ }
+
+ }
+
+ .menu-list{
+ background: #F5F8FF;
+ margin-top: 20rpx;
+ padding: 20rpx 0 0 0;
+ border-radius: 24rpx;
+ display: flex;
+ flex-wrap: wrap;
+
+ .menu-item{
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ width: 25%;
+ margin-bottom: 20rpx;
+
+ .menu-text{
+ font-family: Work Sans;
+ font-weight: 400;
+ font-style: Regular;
+ font-size: 20rpx;
+ leading-trim: NONE;
+ line-height: 100%;
+ letter-spacing: -2%;
+ }
}
}
}
diff --git a/static/mall/Home.png b/static/mall/Home.png
new file mode 100644
index 0000000..f00d666
Binary files /dev/null and b/static/mall/Home.png differ
diff --git a/static/mall/Star.png b/static/mall/Star.png
new file mode 100644
index 0000000..1313a88
Binary files /dev/null and b/static/mall/Star.png differ
diff --git a/static/mall/Twitch.png b/static/mall/Twitch.png
new file mode 100644
index 0000000..3704a99
Binary files /dev/null and b/static/mall/Twitch.png differ
diff --git a/static/my/01.png b/static/my/01.png
new file mode 100644
index 0000000..a005bff
Binary files /dev/null and b/static/my/01.png differ
diff --git a/static/my/02.png b/static/my/02.png
new file mode 100644
index 0000000..fd12ede
Binary files /dev/null and b/static/my/02.png differ
diff --git a/static/my/03.png b/static/my/03.png
new file mode 100644
index 0000000..518c2bb
Binary files /dev/null and b/static/my/03.png differ
diff --git a/static/my/04.png b/static/my/04.png
new file mode 100644
index 0000000..55ac782
Binary files /dev/null and b/static/my/04.png differ
diff --git a/static/my/05.png b/static/my/05.png
new file mode 100644
index 0000000..f2a1d67
Binary files /dev/null and b/static/my/05.png differ
diff --git a/static/my/06.png b/static/my/06.png
new file mode 100644
index 0000000..78cbde0
Binary files /dev/null and b/static/my/06.png differ
diff --git a/static/my/07.png b/static/my/07.png
new file mode 100644
index 0000000..adfac3e
Binary files /dev/null and b/static/my/07.png differ
diff --git a/static/my/08.png b/static/my/08.png
new file mode 100644
index 0000000..0deca28
Binary files /dev/null and b/static/my/08.png differ
diff --git a/static/shop/01.png b/static/shop/01.png
new file mode 100644
index 0000000..4abd4f6
Binary files /dev/null and b/static/shop/01.png differ
diff --git a/static/shop/02.png b/static/shop/02.png
new file mode 100644
index 0000000..78cf680
Binary files /dev/null and b/static/shop/02.png differ
diff --git a/static/shop/03.png b/static/shop/03.png
new file mode 100644
index 0000000..cef4bf1
Binary files /dev/null and b/static/shop/03.png differ
diff --git a/static/shop/04.png b/static/shop/04.png
new file mode 100644
index 0000000..4a28945
Binary files /dev/null and b/static/shop/04.png differ
diff --git a/static/shop/05.png b/static/shop/05.png
new file mode 100644
index 0000000..c4216be
Binary files /dev/null and b/static/shop/05.png differ
diff --git a/static/shop/06.png b/static/shop/06.png
new file mode 100644
index 0000000..850647a
Binary files /dev/null and b/static/shop/06.png differ
diff --git a/static/shop/07.png b/static/shop/07.png
new file mode 100644
index 0000000..126712a
Binary files /dev/null and b/static/shop/07.png differ
diff --git a/static/shop/08.png b/static/shop/08.png
new file mode 100644
index 0000000..48a535b
Binary files /dev/null and b/static/shop/08.png differ
diff --git a/static/shop/09.png b/static/shop/09.png
new file mode 100644
index 0000000..288ee1d
Binary files /dev/null and b/static/shop/09.png differ
diff --git a/static/shop/10.png b/static/shop/10.png
new file mode 100644
index 0000000..d6fb723
Binary files /dev/null and b/static/shop/10.png differ
diff --git a/util/common.js b/util/common.js
index 252d718..18054af 100644
--- a/util/common.js
+++ b/util/common.js
@@ -7,18 +7,18 @@ export const validatePhone = (phone) => {
export const getImageUrl = (imagePath) => {
if (!imagePath) return ''
+ // 如果图片路径以/uploads开头,直接返回原路径
+ const baseURL = "https://minio.zrbjr.com"
+ if (imagePath.startsWith('/uploads')) {
+ return `${baseURL}/jurongquan${imagePath}`
+ }
+
if (imagePath.startsWith('http')) return imagePath
// const baseURL = "http://192.168.1.43:3000"
// const baseURL = "https://www.zrbjr.com"
- const baseURL = "https://minio.zrbjr.com"
- // 如果图片路径以/uploads开头,直接返回原路径
- if (imagePath.startsWith('/uploads')) {
- return `${baseURL}/jurongquan${imagePath}`
- }
-
- return fullUrl
+ return baseURL + imagePath
}
export const getUserInfo = () => {