基础工程
Showing
94 changed files
with
1065 additions
and
292 deletions
| 1 | { | 1 | { |
| 2 | "pages": [ | 2 | "pages": [ |
| 3 | "pages/authorize/authorize", | ||
| 4 | "pages/index/index", | 3 | "pages/index/index", |
| 4 | "pages/authorize/authorize", | ||
| 5 | "pages/register/register", | ||
| 6 | "pages/scan-result/scan-result", | ||
| 7 | "pages/integral-detail/integral-detail", | ||
| 8 | "pages/gift-shop/gift-shop", | ||
| 9 | "pages/gift-detail/gift-detail", | ||
| 10 | "pages/address-management/address-management", | ||
| 11 | "pages/address-edit/address-edit", | ||
| 12 | "pages/my-qrcode/my-qrcode", | ||
| 13 | "pages/my-order/my-order", | ||
| 14 | "pages/my-message/my-message", | ||
| 15 | "pages/contact/contact", | ||
| 16 | "pages/contact-table/contact-table", | ||
| 17 | "pages/vip-login/vip-login", | ||
| 18 | "pages/vip-verify/vip-verify", | ||
| 19 | "pages/user-center/user-center", | ||
| 20 | "pages/sign-in-record/sign-in-record", | ||
| 21 | "pages/rank/rank", | ||
| 22 | "pages/rank-gift/rank-gift", | ||
| 5 | "pages/example/example", | 23 | "pages/example/example", |
| 6 | "pages/more/more" | 24 | "pages/more/more" |
| 7 | ], | 25 | ], |
| 8 | "window": { | 26 | "window": { |
| 9 | "backgroundTextStyle": "light", | 27 | "backgroundTextStyle": "light", |
| 10 | "navigationBarBackgroundColor": "#fff", | 28 | "navigationBarBackgroundColor": "#3680EB", |
| 11 | "navigationBarTitleText": "mp-gulp-framework", | 29 | "navigationBarTitleText": "志亮照明", |
| 12 | "navigationBarTextStyle": "black" | 30 | "navigationBarTextStyle": "white" |
| 13 | }, | 31 | }, |
| 14 | "tabBar": { | 32 | "tabBar": { |
| 15 | "color": "#7A7E83", | 33 | "color": "#999999", |
| 16 | "selectedColor": "#CF4646", | 34 | "selectedColor": "#3680EB", |
| 17 | "borderStyle": "black", | 35 | "borderStyle": "black", |
| 18 | "backgroundColor": "#ffffff", | 36 | "backgroundColor": "#ffffff", |
| 19 | "list": [{ | 37 | "list": [{ |
| 20 | "pagePath": "pages/index/index", | 38 | "pagePath": "pages/index/index", |
| 21 | "iconPath": "image/tabbar/home_D.png", | 39 | "iconPath": "image/tabbar/scan_bar.png", |
| 22 | "selectedIconPath": "image/tabbar/home.png", | 40 | "selectedIconPath": "image/tabbar/scan_bar_selected.png", |
| 23 | "text": "介绍" | 41 | "text": "扫码积分" |
| 42 | }, | ||
| 43 | { | ||
| 44 | "pagePath": "pages/gift-shop/gift-shop", | ||
| 45 | "iconPath": "image/tabbar/gift_bar.png", | ||
| 46 | "selectedIconPath": "image/tabbar/gift_bar_selected.png", | ||
| 47 | "text": "礼物兑换" | ||
| 24 | }, | 48 | }, |
| 25 | { | 49 | { |
| 26 | "pagePath": "pages/more/more", | 50 | "pagePath": "pages/user-center/user-center", |
| 27 | "iconPath": "image/tabbar/set_D.png", | 51 | "iconPath": "image/tabbar/user_bar.png", |
| 28 | "selectedIconPath": "image/tabbar/set.png", | 52 | "selectedIconPath": "image/tabbar/user_bar_selected.png", |
| 29 | "text": "更多" | 53 | "text": "个人中心" |
| 30 | } | 54 | } |
| 31 | ] | 55 | ] |
| 32 | } | 56 | } | ... | ... |
| ... | @@ -5,200 +5,235 @@ | ... | @@ -5,200 +5,235 @@ |
| 5 | * ------------------------------------------------------------------ | 5 | * ------------------------------------------------------------------ |
| 6 | * | 6 | * |
| 7 | */ | 7 | */ |
| 8 | @import "support"; | 8 | @import "support"; |
| 9 | 9 | ||
| 10 | // Margin | 10 | // Margin |
| 11 | .u-mt-smaller { | 11 | .u-mt-smaller { |
| 12 | margin-top: $marginTopSmaller; | 12 | margin-top: $marginTopSmaller; |
| 13 | } | 13 | } |
| 14 | 14 | ||
| 15 | .u-mt-small { | 15 | .u-mt-small { |
| 16 | margin-top: $marginTopSmall; | 16 | margin-top: $marginTopSmall; |
| 17 | } | 17 | } |
| 18 | 18 | ||
| 19 | .u-mt-medium { | 19 | .u-mt-medium { |
| 20 | margin-top: $marginTopMedium; | 20 | margin-top: $marginTopMedium; |
| 21 | } | 21 | } |
| 22 | 22 | ||
| 23 | .u-mt-large { | 23 | .u-mt-large { |
| 24 | margin-top: $marginTopLarge; | 24 | margin-top: $marginTopLarge; |
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | .u-mt-larger { | 27 | .u-mt-larger { |
| 28 | margin-top: $marginTopLarger; | 28 | margin-top: $marginTopLarger; |
| 29 | } | 29 | } |
| 30 | 30 | ||
| 31 | .u-mb-smaller { | 31 | .u-mb-smaller { |
| 32 | margin-bottom: $marginTopSmaller; | 32 | margin-bottom: $marginTopSmaller; |
| 33 | } | 33 | } |
| 34 | 34 | ||
| 35 | .u-mb-small { | 35 | .u-mb-small { |
| 36 | margin-bottom: $marginTopSmall; | 36 | margin-bottom: $marginTopSmall; |
| 37 | } | 37 | } |
| 38 | 38 | ||
| 39 | .u-mb-medium { | 39 | .u-mb-medium { |
| 40 | margin-bottom: $marginTopMedium; | 40 | margin-bottom: $marginTopMedium; |
| 41 | } | 41 | } |
| 42 | 42 | ||
| 43 | .u-mb-large { | 43 | .u-mb-large { |
| 44 | margin-bottom: $marginTopLarge; | 44 | margin-bottom: $marginTopLarge; |
| 45 | } | 45 | } |
| 46 | 46 | ||
| 47 | .u-mb-larger { | 47 | .u-mb-larger { |
| 48 | margin-bottom: $marginTopLarger; | 48 | margin-bottom: $marginTopLarger; |
| 49 | } | 49 | } |
| 50 | |||
| 51 | // Padding | ||
| 52 | .u-pt-smaller { | ||
| 53 | padding-top: $paddingTopSmaller; | ||
| 54 | } | ||
| 55 | |||
| 56 | .u-pt-small { | ||
| 57 | padding-top: $paddingTopSmall; | ||
| 58 | } | ||
| 59 | |||
| 60 | .u-pt-medium { | ||
| 61 | padding-top: $paddingTopMedium; | ||
| 62 | } | ||
| 63 | |||
| 64 | .u-pt-large { | ||
| 65 | padding-top: $paddingTopLarge; | ||
| 66 | } | ||
| 67 | |||
| 68 | .u-pt-larger { | ||
| 69 | padding-top: $paddingTopLarger; | ||
| 70 | } | ||
| 71 | |||
| 72 | .u-pb-smaller { | ||
| 73 | padding-bottom: $paddingTopSmaller; | ||
| 74 | } | ||
| 75 | |||
| 76 | .u-pb-small { | ||
| 77 | padding-bottom: $paddingTopSmall; | ||
| 78 | } | ||
| 79 | |||
| 80 | .u-pb-medium { | ||
| 81 | padding-bottom: $paddingTopMedium; | ||
| 82 | } | ||
| 83 | |||
| 84 | .u-pb-large { | ||
| 85 | padding-bottom: $paddingTopLarge; | ||
| 86 | } | ||
| 87 | |||
| 88 | .u-pb-larger { | ||
| 89 | padding-bottom: $paddingTopLarger; | ||
| 90 | } | ||
| 91 | |||
| 92 | // 布局方位 | ||
| 93 | .u-ta-c { | ||
| 94 | text-align: center !important; | ||
| 95 | } | ||
| 96 | |||
| 97 | .u-ta-l { | ||
| 98 | text-align: left !important; | ||
| 99 | } | ||
| 100 | |||
| 101 | .u-ta-r { | ||
| 102 | text-align: right !important; | ||
| 103 | } | ||
| 104 | |||
| 105 | .u-fl-l { | ||
| 106 | float: left; | ||
| 107 | } | ||
| 108 | |||
| 109 | .u-fl-n { | ||
| 110 | float: none; | ||
| 111 | } | ||
| 112 | |||
| 113 | .u-fl-r { | ||
| 114 | float: right; | ||
| 115 | } | ||
| 116 | |||
| 117 | .u-d-b { | ||
| 118 | display: block; | ||
| 119 | } | ||
| 120 | |||
| 121 | .u-d-i { | ||
| 122 | display: inline !important; | ||
| 123 | } | ||
| 124 | |||
| 125 | .u-d-ib { | ||
| 126 | display: inline-block !important; | ||
| 127 | } | ||
| 128 | |||
| 129 | .u-d-n { | ||
| 130 | display: none !important; | ||
| 131 | } | ||
| 132 | |||
| 133 | .u-d-t { | ||
| 134 | display: table; | ||
| 135 | table-layout: fixed; | ||
| 136 | } | ||
| 137 | |||
| 138 | .u-d-tc { | ||
| 139 | display: table-cell; | ||
| 140 | } | ||
| 141 | |||
| 142 | .u-va-b { | ||
| 143 | vertical-align: bottom; | ||
| 144 | } | ||
| 145 | |||
| 146 | .u-va-m { | ||
| 147 | vertical-align: middle; | ||
| 148 | } | ||
| 149 | |||
| 150 | .u-va-t { | ||
| 151 | vertical-align: top; | ||
| 152 | } | ||
| 153 | |||
| 154 | // clearfix | ||
| 155 | .u-clearfix { | ||
| 156 | @include clearfix; | ||
| 157 | } | ||
| 158 | |||
| 159 | // 虚拟格式 | ||
| 160 | .u-cur-d { | ||
| 161 | cursor: default; | ||
| 162 | } | ||
| 163 | |||
| 164 | .u-cur-p { | ||
| 165 | cursor: pointer; | ||
| 166 | } | ||
| 167 | |||
| 168 | // flex | ||
| 169 | .u-flex { | ||
| 170 | display: -webkit-box; | ||
| 171 | display: -webkit-flex; | ||
| 172 | display: flex; | ||
| 173 | } | ||
| 174 | |||
| 175 | .u-flex-item { | ||
| 176 | -webkit-box-flex: 1; | ||
| 177 | -webkit-flex: 1; | ||
| 178 | flex: 1; | ||
| 179 | } | ||
| 180 | |||
| 181 | // 小程序中模拟ul、li | ||
| 182 | .u-ul { | ||
| 183 | padding-left: 30px; | ||
| 184 | text-align: left; | ||
| 185 | display: block; | ||
| 186 | } | ||
| 187 | |||
| 188 | .u-li { | ||
| 189 | position: relative; | ||
| 190 | font-size: $fontSizeSmall; | ||
| 191 | line-height: $fontSizeSmall + 4px; | ||
| 192 | margin-bottom: $marginTopSmall; | ||
| 193 | &:before { | ||
| 194 | position: absolute; | ||
| 195 | content: " "; | ||
| 196 | top: 14px; | ||
| 197 | left: -20px; | ||
| 198 | width: 8px; | ||
| 199 | height: 8px; | ||
| 200 | border-radius: 8px; | ||
| 201 | background-color: $colorBlack; | ||
| 202 | } | ||
| 203 | } | ||
| 204 | 50 | ||
| 51 | // Padding | ||
| 52 | .u-pt-smaller { | ||
| 53 | padding-top: $paddingTopSmaller; | ||
| 54 | } | ||
| 55 | |||
| 56 | .u-pt-small { | ||
| 57 | padding-top: $paddingTopSmall; | ||
| 58 | } | ||
| 59 | |||
| 60 | .u-pt-medium { | ||
| 61 | padding-top: $paddingTopMedium; | ||
| 62 | } | ||
| 63 | |||
| 64 | .u-pt-large { | ||
| 65 | padding-top: $paddingTopLarge; | ||
| 66 | } | ||
| 67 | |||
| 68 | .u-pt-larger { | ||
| 69 | padding-top: $paddingTopLarger; | ||
| 70 | } | ||
| 71 | |||
| 72 | .u-pb-smaller { | ||
| 73 | padding-bottom: $paddingTopSmaller; | ||
| 74 | } | ||
| 75 | |||
| 76 | .u-pb-small { | ||
| 77 | padding-bottom: $paddingTopSmall; | ||
| 78 | } | ||
| 79 | |||
| 80 | .u-pb-medium { | ||
| 81 | padding-bottom: $paddingTopMedium; | ||
| 82 | } | ||
| 83 | |||
| 84 | .u-pb-large { | ||
| 85 | padding-bottom: $paddingTopLarge; | ||
| 86 | } | ||
| 87 | |||
| 88 | .u-pb-larger { | ||
| 89 | padding-bottom: $paddingTopLarger; | ||
| 90 | } | ||
| 91 | |||
| 92 | // 布局方位 | ||
| 93 | .u-ta-c { | ||
| 94 | text-align: center !important; | ||
| 95 | } | ||
| 96 | |||
| 97 | .u-ta-l { | ||
| 98 | text-align: left !important; | ||
| 99 | } | ||
| 100 | |||
| 101 | .u-ta-r { | ||
| 102 | text-align: right !important; | ||
| 103 | } | ||
| 104 | |||
| 105 | .u-fl-l { | ||
| 106 | float: left; | ||
| 107 | } | ||
| 108 | |||
| 109 | .u-fl-n { | ||
| 110 | float: none; | ||
| 111 | } | ||
| 112 | |||
| 113 | .u-fl-r { | ||
| 114 | float: right; | ||
| 115 | } | ||
| 116 | |||
| 117 | .u-d-b { | ||
| 118 | display: block; | ||
| 119 | } | ||
| 120 | |||
| 121 | .u-d-i { | ||
| 122 | display: inline !important; | ||
| 123 | } | ||
| 124 | |||
| 125 | .u-d-ib { | ||
| 126 | display: inline-block !important; | ||
| 127 | } | ||
| 128 | |||
| 129 | .u-d-n { | ||
| 130 | display: none !important; | ||
| 131 | } | ||
| 132 | |||
| 133 | .u-d-t { | ||
| 134 | display: table; | ||
| 135 | table-layout: fixed; | ||
| 136 | } | ||
| 137 | |||
| 138 | .u-d-tc { | ||
| 139 | display: table-cell; | ||
| 140 | } | ||
| 141 | |||
| 142 | .u-va-b { | ||
| 143 | vertical-align: bottom; | ||
| 144 | } | ||
| 145 | |||
| 146 | .u-va-m { | ||
| 147 | vertical-align: middle; | ||
| 148 | } | ||
| 149 | |||
| 150 | .u-va-t { | ||
| 151 | vertical-align: top; | ||
| 152 | } | ||
| 153 | |||
| 154 | // clearfix | ||
| 155 | .u-clearfix { | ||
| 156 | @include clearfix; | ||
| 157 | } | ||
| 158 | |||
| 159 | // 虚拟格式 | ||
| 160 | .u-cur-d { | ||
| 161 | cursor: default; | ||
| 162 | } | ||
| 163 | |||
| 164 | .u-cur-p { | ||
| 165 | cursor: pointer; | ||
| 166 | } | ||
| 167 | |||
| 168 | // flex | ||
| 169 | .u-flex { | ||
| 170 | display: -webkit-box; | ||
| 171 | display: -webkit-flex; | ||
| 172 | display: flex; | ||
| 173 | } | ||
| 174 | |||
| 175 | .u-flex-item { | ||
| 176 | -webkit-box-flex: 1; | ||
| 177 | -webkit-flex: 1; | ||
| 178 | flex: 1; | ||
| 179 | } | ||
| 180 | |||
| 181 | // 小程序中模拟ul、li | ||
| 182 | .u-ul { | ||
| 183 | padding-left: 30px; | ||
| 184 | text-align: left; | ||
| 185 | display: block; | ||
| 186 | } | ||
| 187 | |||
| 188 | .u-li { | ||
| 189 | position: relative; | ||
| 190 | font-size: $fontSizeSmall; | ||
| 191 | line-height: $fontSizeSmall + 4px; | ||
| 192 | margin-bottom: $marginTopSmall; | ||
| 193 | &:before { | ||
| 194 | position: absolute; | ||
| 195 | content: " "; | ||
| 196 | top: 14px; | ||
| 197 | left: -20px; | ||
| 198 | width: 8px; | ||
| 199 | height: 8px; | ||
| 200 | border-radius: 8px; | ||
| 201 | background-color: $colorBlack; | ||
| 202 | } | ||
| 203 | } | ||
| 204 | |||
| 205 | |||
| 206 | |||
| 207 | .bis { | ||
| 208 | background-repeat: no-repeat; | ||
| 209 | background-size: 100% 100%; | ||
| 210 | } | ||
| 211 | |||
| 212 | |||
| 213 | //flex 布局和 子元素 对其方式 | ||
| 214 | .fl { | ||
| 215 | display: flex; | ||
| 216 | } | ||
| 217 | |||
| 218 | .fj { | ||
| 219 | display: flex; | ||
| 220 | justify-content: space-between; | ||
| 221 | } | ||
| 222 | |||
| 223 | //水平和垂直居中 | ||
| 224 | .fcc { | ||
| 225 | display: flex; | ||
| 226 | justify-content: center; | ||
| 227 | align-items: center; | ||
| 228 | } | ||
| 229 | |||
| 230 | // 为元素设定的宽度和高度决定了元素的边框盒。 | ||
| 231 | .bb { | ||
| 232 | box-sizing: border-box; | ||
| 233 | } | ||
| 234 | |||
| 235 | // 满屏 | ||
| 236 | .fullp { | ||
| 237 | width: 100%; | ||
| 238 | height: 100%; | ||
| 239 | } | ... | ... |
| ... | @@ -39,3 +39,9 @@ $fontSizeSmall: 28px; | ... | @@ -39,3 +39,9 @@ $fontSizeSmall: 28px; |
| 39 | $fontSizeSmaller: 24px; | 39 | $fontSizeSmaller: 24px; |
| 40 | $fontSizeLarge: 36px; | 40 | $fontSizeLarge: 36px; |
| 41 | $fontSizeLarger: 44px; | 41 | $fontSizeLarger: 44px; |
| 42 | |||
| 43 | |||
| 44 | // 主题颜色 | ||
| 45 | $colorMain:#3680EB; | ||
| 46 | |||
| 47 | $pageBottom:80px; | ... | ... |
src/image/icon/icon_scan.png
0 → 100644
841 Bytes
src/image/index/index_c1.png
0 → 100644
40.5 KB
src/image/tabbar/gift_bar.png
0 → 100644
333 Bytes
src/image/tabbar/gift_bar_selected.png
0 → 100644
363 Bytes
src/image/tabbar/home.png
deleted
100755 → 0
2.19 KB
src/image/tabbar/home_D.png
deleted
100755 → 0
3.02 KB
src/image/tabbar/scan_bar.png
0 → 100644
247 Bytes
src/image/tabbar/scan_bar_selected.png
0 → 100644
340 Bytes
src/image/tabbar/set.png
deleted
100755 → 0
3.97 KB
src/image/tabbar/set_D.png
deleted
100755 → 0
7.4 KB
src/image/tabbar/user_bar.png
0 → 100644
479 Bytes
src/image/tabbar/user_bar_selected.png
0 → 100644
542 Bytes
src/pages/address-edit/address-edit.js
0 → 100755
src/pages/address-edit/address-edit.json
0 → 100755
src/pages/address-edit/address-edit.scss
0 → 100755
src/pages/address-edit/address-edit.wxml
0 → 100755
src/pages/contact-table/contact-table.js
0 → 100755
src/pages/contact-table/contact-table.json
0 → 100755
src/pages/contact-table/contact-table.scss
0 → 100755
src/pages/contact-table/contact-table.wxml
0 → 100755
src/pages/contact/contact.js
0 → 100755
src/pages/contact/contact.json
0 → 100755
src/pages/contact/contact.scss
0 → 100755
src/pages/contact/contact.wxml
0 → 100755
src/pages/gift-detail/gift-detail.js
0 → 100755
src/pages/gift-detail/gift-detail.json
0 → 100755
src/pages/gift-detail/gift-detail.scss
0 → 100755
src/pages/gift-detail/gift-detail.wxml
0 → 100755
src/pages/gift-shop/gift-shop.js
0 → 100755
src/pages/gift-shop/gift-shop.json
0 → 100755
src/pages/gift-shop/gift-shop.scss
0 → 100755
src/pages/gift-shop/gift-shop.wxml
0 → 100755
| 1 | @import '../../assets/scss/mixins'; | 1 | @import '../../assets/scss/mixins'; |
| 2 | @import '../../assets/scss/utils'; | 2 | @import '../../assets/scss/utils'; |
| 3 | 3 | ||
| 4 | |||
| 5 | $contentWidth:670px; | ||
| 6 | |||
| 4 | .page { | 7 | .page { |
| 5 | .bgc {} | 8 | padding-bottom: $pageBottom; |
| 9 | |||
| 10 | .bgc {} | ||
| 11 | |||
| 12 | .bg {} | ||
| 13 | |||
| 14 | .main { | ||
| 15 | |||
| 16 | .top { | ||
| 17 | position: absolute; | ||
| 18 | width: 750px; | ||
| 6 | 19 | ||
| 7 | .bg {} | 20 | &-bg { |
| 21 | position: absolute; | ||
| 22 | width: 750px; | ||
| 23 | height: 300px; | ||
| 24 | } | ||
| 8 | 25 | ||
| 9 | .main { | 26 | .search { |
| 10 | .top-space { | 27 | position: relative; |
| 11 | height: 0px; | 28 | width: $contentWidth; |
| 29 | height: 100px; | ||
| 30 | background: #FFFFFF; | ||
| 31 | box-shadow: 0 6px 18px 0 rgba(0, 0, 0, 0.10); | ||
| 32 | border-radius: 8px; | ||
| 33 | margin: 222px auto 0; | ||
| 34 | display: flex; | ||
| 35 | justify-content: space-between; | ||
| 36 | align-items: center; | ||
| 37 | |||
| 38 | &-ipt-wrap { | ||
| 39 | @extend .bb; | ||
| 40 | padding: 0 30px; | ||
| 41 | width: 568px; | ||
| 42 | flex: 1; | ||
| 43 | |||
| 44 | .ipt { | ||
| 45 | font-size: 28px; | ||
| 46 | color: #999999; | ||
| 47 | } | ||
| 48 | } | ||
| 49 | |||
| 50 | &-line { | ||
| 51 | width: 2px; | ||
| 52 | height: 40px; | ||
| 53 | background-color: #d8d8d8; | ||
| 12 | } | 54 | } |
| 13 | 55 | ||
| 14 | .content { | 56 | &-scan { |
| 15 | position: relative; | 57 | @extend .fcc; |
| 58 | width: 100px; | ||
| 59 | |||
| 60 | .icon { | ||
| 61 | width: 40px; | ||
| 62 | height: 40px; | ||
| 63 | } | ||
| 64 | } | ||
| 65 | } | ||
| 66 | } | ||
| 67 | |||
| 68 | .top-space { | ||
| 69 | height: 362px; | ||
| 70 | } | ||
| 71 | |||
| 72 | .content { | ||
| 73 | position: relative; | ||
| 74 | width: $contentWidth; | ||
| 75 | margin: 0 auto; | ||
| 76 | |||
| 77 | // banner | ||
| 78 | .banner { | ||
| 79 | width: $contentWidth; | ||
| 80 | height: 250px; | ||
| 81 | background-color: wheat; | ||
| 82 | margin: 0 auto; | ||
| 83 | } | ||
| 84 | |||
| 85 | // 产品 | ||
| 86 | .product { | ||
| 87 | width: $contentWidth; | ||
| 88 | margin: 0 auto; | ||
| 89 | margin-top: 62px; | ||
| 90 | |||
| 91 | // 产品标题 | ||
| 92 | &-title { | ||
| 93 | font-size: 36px; | ||
| 94 | color: #333333; | ||
| 95 | |||
| 96 | } | ||
| 97 | |||
| 98 | // 产品列表 | ||
| 99 | &-list { | ||
| 100 | margin-top: 20px; | ||
| 101 | display: flex; | ||
| 102 | flex-wrap: wrap; | ||
| 103 | justify-content: space-between; | ||
| 104 | |||
| 105 | .item { | ||
| 106 | width: 322px; | ||
| 107 | height: 440px; | ||
| 108 | background: #F8F8F8; | ||
| 109 | border-radius: 4px; | ||
| 110 | margin-bottom: 20px; | ||
| 111 | } | ||
| 16 | } | 112 | } |
| 113 | } | ||
| 17 | } | 114 | } |
| 115 | } | ||
| 18 | } | 116 | } | ... | ... |
| 1 | <view class="page"> | 1 | <view class="page"> |
| 2 | <view class="app__bgc bgc"></view> | 2 | <view class="app__bgc bgc"></view> |
| 3 | <view class="app__bg bg"></view> | 3 | <view class="app__bg bg"></view> |
| 4 | <!-- <view class="app__top-shadow"></view> --> | 4 | <view class="app__content main"> |
| 5 | <view class="app__content main"> | 5 | <!-- Title及搜索框 --> |
| 6 | <view class="top-space"></view> | 6 | <view class="top"> |
| 7 | <view class="content"></view> | 7 | <image class="top-bg" mode="widthFix" src="../../image/index/index_c1.png" /> |
| 8 | </view> | 8 | <view class="search"> |
| 9 | <view class="search-ipt-wrap"> | ||
| 10 | <input class="ipt" placeholder="请输入串码" /> | ||
| 11 | </view> | ||
| 12 | <view class="search-line"></view> | ||
| 13 | <view class="search-scan"> | ||
| 14 | <image class="icon" mode="aspectFit" src="../../image/icon/icon_scan.png" /> | ||
| 15 | </view> | ||
| 16 | </view> | ||
| 17 | </view> | ||
| 18 | <view class="top-space"></view> | ||
| 19 | <view class="content"> | ||
| 20 | <!-- 轮播 banner --> | ||
| 21 | <!-- <swiper indicator-dots="{{true}}" autoplay="{{true}}" interval="{{5000}}" duration="{{500}}"> | ||
| 22 | <block wx:for="{{imgUrls}}"> | ||
| 23 | <swiper-item> | ||
| 24 | <image class="swiper-image" src="{{item}}" /> | ||
| 25 | </swiper-item> | ||
| 26 | </block> | ||
| 27 | </swiper> --> | ||
| 28 | <view class="banner"></view> | ||
| 29 | <view class="product"> | ||
| 30 | <view class="product-title">产品推荐</view> | ||
| 31 | <view class="product-list"> | ||
| 32 | <!-- for循环 --> | ||
| 33 | <view class="item">1</view> | ||
| 34 | <view class="item">2</view> | ||
| 35 | <view class="item">3</view> | ||
| 36 | <view class="item">4</view> | ||
| 37 | </view> | ||
| 38 | </view> | ||
| 39 | </view> | ||
| 40 | </view> | ||
| 9 | </view> | 41 | </view> | ... | ... |
src/pages/integral-detail/integral-detail.js
0 → 100755
src/pages/my-message/my-message.js
0 → 100755
src/pages/my-message/my-message.json
0 → 100755
src/pages/my-message/my-message.scss
0 → 100755
src/pages/my-message/my-message.wxml
0 → 100755
src/pages/my-order/my-order.js
0 → 100755
src/pages/my-order/my-order.json
0 → 100755
src/pages/my-order/my-order.scss
0 → 100755
src/pages/my-order/my-order.wxml
0 → 100755
src/pages/my-qrcode/my-qrcode.js
0 → 100755
src/pages/my-qrcode/my-qrcode.json
0 → 100755
src/pages/my-qrcode/my-qrcode.scss
0 → 100755
src/pages/my-qrcode/my-qrcode.wxml
0 → 100755
src/pages/rank-gift/rank-gift.js
0 → 100755
src/pages/rank-gift/rank-gift.json
0 → 100755
src/pages/rank-gift/rank-gift.scss
0 → 100755
src/pages/rank-gift/rank-gift.wxml
0 → 100755
src/pages/rank/rank.js
0 → 100755
src/pages/rank/rank.json
0 → 100755
src/pages/rank/rank.scss
0 → 100755
src/pages/rank/rank.wxml
0 → 100755
src/pages/register/register.js
0 → 100755
src/pages/register/register.json
0 → 100755
src/pages/register/register.scss
0 → 100755
File mode changed
src/pages/register/register.wxml
0 → 100755
File mode changed
src/pages/scan-result/scan-result.js
0 → 100755
src/pages/scan-result/scan-result.json
0 → 100755
src/pages/scan-result/scan-result.scss
0 → 100755
src/pages/scan-result/scan-result.wxml
0 → 100755
src/pages/sign-in-record/sign-in-record.js
0 → 100755
src/pages/sign-in-record/sign-in-record.json
0 → 100755
src/pages/sign-in-record/sign-in-record.scss
0 → 100755
src/pages/sign-in-record/sign-in-record.wxml
0 → 100755
src/pages/user-center/user-center.js
0 → 100755
src/pages/user-center/user-center.json
0 → 100755
src/pages/user-center/user-center.scss
0 → 100755
src/pages/user-center/user-center.wxml
0 → 100755
src/pages/vip-login/vip-login.js
0 → 100755
src/pages/vip-login/vip-login.json
0 → 100755
src/pages/vip-login/vip-login.scss
0 → 100755
src/pages/vip-login/vip-login.wxml
0 → 100755
src/pages/vip-verify/vip-verify.js
0 → 100755
src/pages/vip-verify/vip-verify.json
0 → 100755
src/pages/vip-verify/vip-verify.scss
0 → 100755
src/pages/vip-verify/vip-verify.wxml
0 → 100755
| 1 | const routerPath = { | 1 | const routerPath = { |
| 2 | index: '/pages/index/index', // 首页 | 2 | index: '/pages/index/index', // 首页 |
| 3 | register: '/pages/register/register', // 注册 | ||
| 4 | authorize: '/pages/authorize/authorize', // 授权 | 3 | authorize: '/pages/authorize/authorize', // 授权 |
| 5 | example: '/pages/example/example', | 4 | register: '/pages/register/register', // 注册 |
| 6 | more: '/pages/more/more', | 5 | scanResult: '/pages/scan-result/scan-result', // 扫码结果 (含扫码成功和扫码失败) |
| 6 | integralDetail: '/pages/integral-detail/integral-detail', // 积分明细 | ||
| 7 | giftShop: '/pages/gift-shop/gift-shop', // 礼品商场 | ||
| 8 | giftDetail: '/pages/gift-detail/gift-detail', // 礼品详情 (含购物卡和实物) | ||
| 9 | addressManagement: '/pages/address-management/address-management', // 地址管理 | ||
| 10 | addressEdit: '/pages/address-edit/address-edit', // 地址编辑 | ||
| 11 | myQrcode: '/pages/my-qrcode/my-qrcode', // 我的二维码 | ||
| 12 | myOrder: '/pages/my-order/my-order', // 我的订单 | ||
| 13 | myMessage: '/pages/my-message/my-message', // 我的消息 | ||
| 14 | contact: '/pages/contact/contact', // 联系我们 | ||
| 15 | contactTable: '/pages/contact-table/contact-table', // 联系我们-提交表单 | ||
| 16 | vipLogin: '/pages/vip-login/vip-login', // 会员信息验证(填表单) | ||
| 17 | vipVerify: '/pages/vip-verify/vip-verify', // 会员信息审核 | ||
| 18 | userCenter: '/pages/user-center/user-center', // 个人中心 (合并签到页,很提示页) | ||
| 19 | signInRecord: '/pages/sign-in-record/sign-in-record', // 签到记录 | ||
| 20 | rank: '/pages/rank/rank', // 排行榜 | ||
| 21 | rankGift: '/pages/rank-gift/rank-gift', // 排行榜奖励 | ||
| 22 | example: '/pages/example/example', | ||
| 23 | more: '/pages/more/more', | ||
| 7 | } | 24 | } |
| 8 | 25 | ||
| 9 | function parse(data) { | 26 | function parse(data) { |
| 10 | let tempArr = []; | 27 | let tempArr = []; |
| 11 | for (let key in data) { | 28 | for (let key in data) { |
| 12 | tempArr.push(key + '=' + encodeURIComponent(data[key])); | 29 | tempArr.push(key + '=' + encodeURIComponent(data[key])); |
| 13 | } | 30 | } |
| 14 | return tempArr.join('&'); | 31 | return tempArr.join('&'); |
| 15 | } | 32 | } |
| 16 | 33 | ||
| 17 | function push(path, option = {}) { | 34 | function push(path, option = {}) { |
| 18 | if (typeof path == 'string') { | 35 | if (typeof path == 'string') { |
| 19 | option.path = path; //兼容无参数路径 | 36 | option.path = path; //兼容无参数路径 |
| 20 | } else { | 37 | } else { |
| 21 | option = path; | 38 | option = path; |
| 22 | } | 39 | } |
| 23 | // console.log("option:", option); | 40 | // console.log("option:", option); |
| 24 | // 配置key值找到对应path | 41 | // 配置key值找到对应path |
| 25 | let url = routerPath[option.path] || routerPath['index']; | 42 | let url = routerPath[option.path] || routerPath['index']; |
| 26 | // console.log("url:", url); | 43 | // console.log("url:", url); |
| 27 | // 读取传入的配置参数 | 44 | // 读取传入的配置参数 |
| 28 | let { | 45 | let { |
| 29 | query = {}, openType = 'navigate', duration = 0 | 46 | query = {}, openType = 'navigate', duration = 0 |
| 30 | } = option; | 47 | } = option; |
| 31 | // json 转换为 字符串拼接参数 | 48 | // json 转换为 字符串拼接参数 |
| 32 | let params = parse(query) | 49 | let params = parse(query) |
| 33 | // console.log("params:", params); | 50 | // console.log("params:", params); |
| 34 | if (params) { | 51 | if (params) { |
| 35 | url = url + '?' + params; | 52 | url = url + '?' + params; |
| 36 | } | 53 | } |
| 37 | // 是否需要延时跳转 | 54 | // 是否需要延时跳转 |
| 38 | duration ? setTimeout(() => { | 55 | duration ? setTimeout(() => { |
| 39 | to(openType, url); | 56 | to(openType, url); |
| 40 | }, duration) : to(openType, url); | 57 | }, duration) : to(openType, url); |
| 41 | } | 58 | } |
| 42 | 59 | ||
| 43 | function to(openType, url) { | 60 | function to(openType, url) { |
| 44 | let obj = { | 61 | let obj = { |
| 45 | url | 62 | url |
| 46 | }; | 63 | }; |
| 47 | 64 | ||
| 48 | if (openType == 'redirect') { | 65 | if (openType == 'redirect') { |
| 49 | wx.redirectTo(obj); | 66 | wx.redirectTo(obj); |
| 50 | } else if (openType == 'reLaunch') { | 67 | } else if (openType == 'reLaunch') { |
| 51 | wx.reLaunch(obj); | 68 | wx.reLaunch(obj); |
| 52 | } else if (openType == 'switchTab') { | 69 | } else if (openType == 'switchTab') { |
| 53 | wx.switchTab(obj); | 70 | wx.switchTab(obj); |
| 54 | } else if (openType == 'back') { | 71 | } else if (openType == 'back') { |
| 55 | wx.navigateBack({ | 72 | wx.navigateBack({ |
| 56 | delta: 1 | 73 | delta: 1 |
| 57 | }); | 74 | }); |
| 58 | } else { | 75 | } else { |
| 59 | wx.navigateTo(obj); | 76 | wx.navigateTo(obj); |
| 60 | } | 77 | } |
| 61 | } | 78 | } |
| 62 | 79 | ||
| 63 | module.exports = { | 80 | module.exports = { |
| 64 | parse, | 81 | parse, |
| 65 | push, | 82 | push, |
| 66 | to | 83 | to |
| 67 | } | 84 | } | ... | ... |
-
Please register or sign in to post a comment