Commit 31dea37dac820ba4df6c0d427911262561714861
1 parent
0c6c0f3c42
Exists in
master
新增验光单和修改验光单
Showing
5 changed files
with
401 additions
and
49 deletions
Show diff stats
src/pages/addOpticsData/addOpticsData.vue
1 | <template> | 1 | <template> |
2 | <view class="wrap"> | 2 | <view class="wrap"> |
3 | <!-- 弹窗 --> | 3 | <!-- 弹窗 --> |
4 | <uni-popup ref="popup" type="center"> | 4 | <uni-popup ref="popup" type="center"> |
5 | <!-- 给一个左边弹窗的样式 --> | 5 | <!-- 给一个左边弹窗的样式 --> |
6 | <view class="popUpWrap" :class="{'popUpWrap1': whichTap == 0}"> | 6 | <view class="popUpWrap" :class="{'popUpWrap1': whichTap == 0}"> |
7 | <!-- 关闭弹窗按钮 --> | 7 | <!-- 关闭弹窗按钮 --> |
8 | <view class="closeBtn" @click="this.$refs.popup.close()"></view> | 8 | <view class="closeBtn" @click="this.$refs.popup.close()"></view> |
9 | <!-- 左 --> | 9 | <!-- 左 --> |
10 | <image class="glassInfo" src="../../static/img/myOpticsData/glassInfo.png" v-if="whichTap == 0" mode="aspectFit"></image> | 10 | <image class="glassInfo" src="../../static/img/myOpticsData/glassInfo.png" v-if="whichTap == 0" mode="aspectFit"></image> |
11 | <!-- 右 --> | 11 | <!-- 右 --> |
12 | <image class="dataInfo" src="../../static/img/myOpticsData/dataInfo.png" v-else mode="aspectFit"></image> | 12 | <image class="dataInfo" src="../../static/img/myOpticsData/dataInfo.png" v-else mode="aspectFit"></image> |
13 | </view> | 13 | </view> |
14 | </uni-popup> | 14 | </uni-popup> |
15 | <!-- 点击弹窗部分 --> | 15 | <!-- 点击弹窗部分 --> |
16 | <view class="header"> | 16 | <view class="header"> |
17 | <view class="headerLeft" @click=changeTap(0)> | 17 | <view class="headerLeft" @click=changeTap(0)> |
18 | <text>如何查看验光单?</text> | 18 | <text>如何查看验光单?</text> |
19 | <image src="../../static/dataLook.png" mode="aspectFit"></image> | 19 | <image src="../../static/dataLook.png" mode="aspectFit"></image> |
20 | </view> | 20 | </view> |
21 | <view class="headerRight" @click=changeTap(1)> | 21 | <view class="headerRight" @click=changeTap(1)> |
22 | <text>如何查看眼镜框架?</text> | 22 | <text>如何查看眼镜框架?</text> |
23 | <image src="../../static/glassLook.png" mode="aspectFit"></image> | 23 | <image src="../../static/glassLook.png" mode="aspectFit"></image> |
24 | </view> | 24 | </view> |
25 | </view> | 25 | </view> |
26 | <!-- 数据展示部分 --> | 26 | <!-- 数据展示部分 --> |
27 | <view class="dataMenu"> | 27 | <view class="dataMenu"> |
28 | <uni-collapse accordion="true"> | 28 | <uni-collapse accordion="true"> |
29 | <view class="item" v-for="(loveItem,index) in loveList" :key="index"> | 29 | <view class="item" v-for="(loveItem,index) in loveList" :key="index" > |
30 | <uni-collapse-item :title='loveItem.name' :time='getRightTime(loveItem.in_time)' :iconText='getFirstName(loveItem.name)' showAnimation='true'> | 30 | <uni-collapse-item :title='loveItem.name' :time='getRightTime(loveItem.in_time)' :iconText='getFirstName(loveItem.name)' showAnimation='true'> |
31 | <view class="loveDataInfo"> | 31 | <view class="loveDataInfo" @click="toNewData(2,index)"> |
32 | <view class="dataInfoItem"> | 32 | <view class="dataInfoItem"> |
33 | <text>度数(SPH):</text><text>左:{{loveItem.leftSph}}</text><text>右:{{loveItem.rightSph}}</text> | 33 | <text>度数(SPH):</text><text>左:{{loveItem.leftSph}}</text><text>右:{{loveItem.rightSph}}</text> |
34 | </view> | 34 | </view> |
35 | <view class="dataInfoItem"> | 35 | <view class="dataInfoItem"> |
36 | <text>散光(CYL):</text><text>左:{{loveItem.leftCyl}}</text><text>右:{{loveItem.rightCyl}}</text> | 36 | <text>散光(CYL):</text><text>左:{{loveItem.leftCyl}}</text><text>右:{{loveItem.rightCyl}}</text> |
37 | </view> | 37 | </view> |
38 | <view class="dataInfoItem"> | 38 | <view class="dataInfoItem"> |
39 | <text>轴位(AXI):</text><text>左:{{loveItem.leftAxi}}</text><text>右:{{loveItem.rightAxi}}</text> | 39 | <text>轴位(AXI):</text><text>左:{{loveItem.leftAxi}}</text><text>右:{{loveItem.rightAxi}}</text> |
40 | </view> | 40 | </view> |
41 | <view class="dataInfoItem"> | 41 | <view class="dataInfoItem"> |
42 | <text>瞳距(PD):</text><text>{{loveItem.pd}}</text> | 42 | <text>瞳距(PD):</text><text>{{loveItem.pd}}</text> |
43 | </view> | 43 | </view> |
44 | </view> | 44 | </view> |
45 | </uni-collapse-item> | 45 | </uni-collapse-item> |
46 | </view> | 46 | </view> |
47 | </uni-collapse> | 47 | </uni-collapse> |
48 | </view> | 48 | </view> |
49 | <view class="footer"> | 49 | <view class="footer"> |
50 | <button class="btn" type="default" @click="toNewData">新建验光单</button> | 50 | <button class="btn" type="default" @click="toNewData(1)">新建验光单</button> |
51 | </view> | 51 | </view> |
52 | </view> | 52 | </view> |
53 | </template> | 53 | </template> |
54 | 54 | ||
55 | <script> | 55 | <script> |
56 | import UniCollapse from '@/components/UniCollapse/UniCollapse.vue' | 56 | import UniCollapse from '@/components/UniCollapse/UniCollapse.vue' |
57 | import UniCollapseItem from '@/components/UniCollapseItem/UniCollapseItem.vue' | 57 | import UniCollapseItem from '@/components/UniCollapseItem/UniCollapseItem.vue' |
58 | import UniPopup from '@/components/UniPopup/uni-popup.vue' | 58 | import UniPopup from '@/components/UniPopup/uni-popup.vue' |
59 | import store from '@/store'; | 59 | import store from '@/store'; |
60 | export default { | 60 | export default { |
61 | components: {UniCollapse,UniCollapseItem,UniPopup}, | 61 | components: {UniCollapse,UniCollapseItem,UniPopup}, |
62 | data() { | 62 | data() { |
63 | return { | 63 | return { |
64 | whichTap:0 | 64 | whichTap:0 |
65 | }; | 65 | }; |
66 | }, | 66 | }, |
67 | onLoad: function(option) { | 67 | onLoad: function(option) { |
68 | //获取关心的人列表 | 68 | //获取关心的人列表 |
69 | store.dispatch('myLoveList/getLoveList', { | 69 | store.dispatch('myLoveList/getLoveList', { |
70 | uid: "1", | 70 | uid: this.$store.state.user.userInfo.uid, |
71 | }); | 71 | }); |
72 | }, | 72 | }, |
73 | computed:{ | 73 | computed:{ |
74 | loveList() { | 74 | loveList() { |
75 | console.log(this.$store.state.myLoveList.loveList) | 75 | console.log(this.$store.state.myLoveList.loveList) |
76 | return this.$store.state.myLoveList.loveList || [] | 76 | return this.$store.state.myLoveList.loveList || [] |
77 | }, | 77 | }, |
78 | }, | 78 | }, |
79 | methods:{ | 79 | methods:{ |
80 | changeTap(item){ | 80 | changeTap(item){ |
81 | this.whichTap = item | 81 | this.whichTap = item |
82 | this.$refs.popup.open() | 82 | this.$refs.popup.open() |
83 | }, | 83 | }, |
84 | //给时间搞一个nice的格式 | 84 | //给时间搞一个nice的格式 |
85 | getRightTime(time){ | 85 | getRightTime(time){ |
86 | //如果小于10 则返回'0'+m | 86 | //如果小于10 则返回'0'+m |
87 | // function add(m){return m<10?'0'+m:m} | 87 | // function add(m){return m<10?'0'+m:m} |
88 | //传给我的带有时分秒,想去除一下,但是完事IOS显示NaN,暂时不用吧 | 88 | //传给我的带有时分秒,想去除一下,但是完事IOS显示NaN,暂时不用吧 |
89 | // const oldTime = (new Date(time)).getTime() | 89 | // const oldTime = (new Date(time)).getTime() |
90 | // const year = new Date(oldTime).getFullYear() | 90 | // const year = new Date(oldTime).getFullYear() |
91 | // const month = new Date(oldTime).getMonth()+1 | 91 | // const month = new Date(oldTime).getMonth()+1 |
92 | // const day = new Date(oldTime).getDate() | 92 | // const day = new Date(oldTime).getDate() |
93 | // const newTime = add(year)+'-'+add(month)+'-'+add(day) | 93 | // const newTime = add(year)+'-'+add(month)+'-'+add(day) |
94 | 94 | ||
95 | // console.log(newTime) | 95 | // console.log(newTime) |
96 | // return newTime.replace(/-/g, '/') | 96 | // return newTime.replace(/-/g, '/') |
97 | return time | 97 | return time |
98 | }, | 98 | }, |
99 | getFirstName(name){ | 99 | getFirstName(name){ |
100 | return name.substring(0,1) | 100 | return name.substring(0,1) |
101 | }, | 101 | }, |
102 | toNewData(){ | 102 | toNewData(item,index){ |
103 | // const args={ | ||
104 | // name:loveItem.name, | ||
105 | // pd:loveItem.pd, | ||
106 | // leftSph:loveItem.leftSph, | ||
107 | // rightSph:loveItem.rightSph, | ||
108 | // leftCyl:loveItem.leftCyl, | ||
109 | // rightCyl:loveItem.rightCyl, | ||
110 | // leftAxi:loveItem.leftAxi, | ||
111 | // rightAxi:loveItem.rightAxi | ||
112 | // } | ||
103 | uni.navigateTo({ | 113 | uni.navigateTo({ |
104 | url:'../newOpticsData/newOpticsData' | 114 | // kinds 参数为 1 表示添加新的验光单, 2 表示更新验光单 |
115 | // name 表示修改的人名儿,pd瞳距 | ||
116 | url:'../newOpticsData/newOpticsData?kinds='+item+'&index='+index | ||
105 | }) | 117 | }) |
106 | } | 118 | } |
107 | } | 119 | } |
108 | } | 120 | } |
109 | </script> | 121 | </script> |
110 | 122 | ||
111 | <style lang="scss"> | 123 | <style lang="scss"> |
112 | .wrap{ | 124 | .wrap{ |
113 | min-height: 100vh; | 125 | min-height: 100vh; |
114 | width: 100%; | 126 | width: 100%; |
115 | background-color: #F2F2F2; | 127 | background-color: #F2F2F2; |
116 | .header{ | 128 | .header{ |
117 | height: 304rpx; | 129 | height: 304rpx; |
118 | width: 100%; | 130 | width: 100%; |
119 | background-color: #FFFFFF; | 131 | background-color: #FFFFFF; |
120 | display: flex; | 132 | display: flex; |
121 | justify-content: space-around; | 133 | justify-content: space-around; |
122 | align-items: center; | 134 | align-items: center; |
123 | view{ | 135 | view{ |
124 | height: 210rpx; | 136 | height: 210rpx; |
125 | width: 304rpx; | 137 | width: 304rpx; |
126 | background: #FDF7F5; | 138 | background: #FDF7F5; |
127 | border-radius: 4px; | 139 | border-radius: 4px; |
128 | border-radius: 4px; | 140 | border-radius: 4px; |
129 | display: flex; | 141 | display: flex; |
130 | flex-direction: column; | 142 | flex-direction: column; |
131 | align-items: center; | 143 | align-items: center; |
132 | justify-content: center; | 144 | justify-content: center; |
133 | text{ | 145 | text{ |
134 | font-size: 12px; | 146 | font-size: 12px; |
135 | color: #333333; | 147 | color: #333333; |
136 | } | 148 | } |
137 | image{ | 149 | image{ |
138 | height: 144rpx; | 150 | height: 144rpx; |
139 | width: 144rpx; | 151 | width: 144rpx; |
140 | } | 152 | } |
141 | } | 153 | } |
142 | } | 154 | } |
143 | .dataMenu{ | 155 | .dataMenu{ |
144 | margin-top: 20rpx; | 156 | margin-top: 20rpx; |
145 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); | 157 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); |
146 | width: 100%; | 158 | width: 100%; |
147 | background-color: #FFFFFF; | 159 | background-color: #FFFFFF; |
160 | margin-bottom: 120rpx; | ||
148 | .item{ | 161 | .item{ |
149 | padding: 0 40rpx; | 162 | padding: 0 40rpx; |
150 | .loveDataInfo{ | 163 | .loveDataInfo{ |
151 | padding: 0 44rpx 0 70rpx; | 164 | padding: 0 44rpx 0 70rpx; |
152 | display: flex; | 165 | display: flex; |
153 | justify-content: space-around; | 166 | justify-content: space-around; |
154 | flex-direction: column; | 167 | flex-direction: column; |
155 | align-items: flex-start; | 168 | align-items: flex-start; |
156 | .dataInfoItem{ | 169 | .dataInfoItem{ |
157 | font-size: 12px; | 170 | font-size: 12px; |
158 | color: #333333; | 171 | color: #333333; |
159 | margin-bottom: 34rpx; | 172 | margin-bottom: 34rpx; |
160 | text{ | 173 | text{ |
161 | font-size: 12px; | 174 | font-size: 12px; |
162 | color: #2A2A2A; | 175 | color: #2A2A2A; |
163 | margin-right: 20rpx; | 176 | margin-right: 20rpx; |
164 | } | 177 | } |
165 | } | 178 | } |
166 | } | 179 | } |
167 | } | 180 | } |
168 | } | 181 | } |
169 | .footer{ | 182 | .footer{ |
170 | width: 100%; | 183 | width: 100%; |
171 | position: fixed; | 184 | position: fixed; |
172 | bottom: 0; | 185 | bottom: 0; |
173 | left: 0; | 186 | left: 0; |
174 | .btn{ | 187 | .btn{ |
175 | width: 100%; | 188 | width: 100%; |
176 | height: 112rpx; | 189 | height: 112rpx; |
177 | line-height: 112rpx; | 190 | line-height: 112rpx; |
178 | background: #FF6B4A; | 191 | background: #FF6B4A; |
179 | font-size: 16px; | 192 | font-size: 16px; |
180 | color: #FFFFFF; | 193 | color: #FFFFFF; |
181 | } | 194 | } |
182 | } | 195 | } |
183 | } | 196 | } |
184 | .popUpWrap{ | 197 | .popUpWrap{ |
185 | height: 850rpx; | 198 | height: 850rpx; |
186 | width: 542rpx; | 199 | width: 542rpx; |
187 | background-color: #FFFFFF; | 200 | background-color: #FFFFFF; |
188 | border-radius: 4px; | 201 | border-radius: 4px; |
189 | border: 1px solid #979797; | 202 | border: 1px solid #979797; |
190 | .closeBtn{ | 203 | .closeBtn{ |
191 | height: 28rpx; | 204 | height: 28rpx; |
192 | width: 28rpx; | 205 | width: 28rpx; |
193 | // border: 1px solid red; | 206 | // border: 1px solid red; |
194 | position: absolute; | 207 | position: absolute; |
195 | top: 20rpx; | 208 | top: 20rpx; |
196 | right: 20rpx; | 209 | right: 20rpx; |
197 | } | 210 | } |
198 | .glassInfo{ | 211 | .glassInfo{ |
199 | height: 474rpx; | 212 | height: 474rpx; |
200 | width: 528rpx; | 213 | width: 528rpx; |
201 | } | 214 | } |
202 | .dataInfo{ | 215 | .dataInfo{ |
203 | height: 850rpx; | 216 | height: 850rpx; |
204 | width: 542rpx; | 217 | width: 542rpx; |
205 | } | 218 | } |
206 | } | 219 | } |
207 | .popUpWrap1{ | 220 | .popUpWrap1{ |
208 | height: 474rpx; | 221 | height: 474rpx; |
209 | width: 528rpx; | 222 | width: 528rpx; |
210 | border-radius: 4px; | 223 | border-radius: 4px; |
211 | border: 1px solid #979797; | 224 | border: 1px solid #979797; |
212 | } | 225 | } |
213 | 226 | ||
214 | </style> | 227 | </style> |
215 | 228 |
src/pages/newOpticsData/newOpticsData.vue
1 | <template> | 1 | <template> |
2 | <view class="wrap"> | 2 | <view class="wrap"> |
3 | <view class="body"> | 3 | <view class="body"> |
4 | <template > | 4 | <template > |
5 | <view class="goods-form"> | 5 | <view class="goods-form"> |
6 | <view class="p1"> | 6 | <view class="p1"> |
7 | <image src="../../static/img/myOpticsData/dataWrite.png" mode="aspectFit"></image> | 7 | <image src="../../static/img/myOpticsData/dataWrite.png" mode="aspectFit"></image> |
8 | 填写验光数据 | 8 | 填写验光数据 |
9 | </view> | 9 | </view> |
10 | <text class="p2">没有验光数据?请到线下眼镜店验光哦~</text> | 10 | <text class="p2">没有验光数据?请到线下眼镜店验光哦~</text> |
11 | <view class="use_name"> | ||
12 | <text>验光单取名:</text> | ||
13 | <input type="text" @change="handleInput" | ||
14 | placeholder="请输入名称" maxlength="30" :value="name" /> | ||
15 | </view> | ||
16 | <view class="use_pd"> | ||
17 | <text>瞳距:</text> | ||
18 | <input type="number" @change="handleInputPd" | ||
19 | placeholder="请输入瞳距,单位cm" maxlength="20" :value="pd" /> | ||
20 | </view> | ||
11 | <view class="picker" > | 21 | <view class="picker" > |
12 | <view class="picker-choice"> | 22 | <view class="picker-choice"> |
13 | <view class="choice-left"> | 23 | <view class="choice-left"> |
14 | <text class="p11">{{pickerInfoList[0].nameC}}</text> | 24 | <text class="p11">{{pickerInfoList[0].nameC}}</text> |
15 | <text class="p12">{{pickerInfoList[0].nameE}}</text> | 25 | <text class="p12">{{pickerInfoList[0].nameE}}</text> |
16 | </view> | 26 | </view> |
17 | <text class="p13">左 (OD)</text> | 27 | <text class="p13">左 (OD)</text> |
18 | <text class="p14">{{pickerInfoList[0].nameArray1[pickerInfoList[0].nameIndex1]}}</text> | 28 | <text class="p14">{{pickerInfoList[0].nameArray1[pickerInfoList[0].nameIndex1]}}</text> |
19 | <picker @change="bindPickerChange01" :value="pickerInfoList[0].nameIndex1" :range="pickerInfoList[0].nameArray1"> | 29 | <picker @change="bindPickerChange01" :value="pickerInfoList[0].nameIndex1" :range="pickerInfoList[0].nameArray1"> |
20 | <image src="../../static/detail-tabicon.png" ></image> | 30 | <image src="../../static/detail-tabicon.png" ></image> |
21 | </picker> | 31 | </picker> |
22 | <text class="p13">右 (OS)</text> | 32 | <text class="p13">右 (OS)</text> |
23 | <text class="p14">{{pickerInfoList[0].nameArray2[pickerInfoList[0].nameIndex2]}}</text> | 33 | <text class="p14">{{pickerInfoList[0].nameArray2[pickerInfoList[0].nameIndex2]}}</text> |
24 | <picker @change="bindPickerChange02" :value="pickerInfoList[0].nameIndex2" :range="pickerInfoList[0].nameArray2"> | 34 | <picker @change="bindPickerChange02" :value="pickerInfoList[0].nameIndex2" :range="pickerInfoList[0].nameArray2"> |
25 | <image src="../../static/detail-tabicon.png" ></image> | 35 | <image src="../../static/detail-tabicon.png" ></image> |
26 | </picker> | 36 | </picker> |
27 | </view> | 37 | </view> |
28 | </view> | 38 | </view> |
29 | <view class="picker" > | 39 | <view class="picker" > |
30 | <view class="picker-choice"> | 40 | <view class="picker-choice"> |
31 | <view class="choice-left"> | 41 | <view class="choice-left"> |
32 | <text class="p11">{{pickerInfoList[1].nameC}}</text> | 42 | <text class="p11">{{pickerInfoList[1].nameC}}</text> |
33 | <text class="p12">{{pickerInfoList[1].nameE}}</text> | 43 | <text class="p12">{{pickerInfoList[1].nameE}}</text> |
34 | </view> | 44 | </view> |
35 | <text class="p13">左 (OD)</text> | 45 | <text class="p13">左 (OD)</text> |
36 | <text class="p14">{{pickerInfoList[1].nameArray1[pickerInfoList[1].nameIndex1]}}</text> | 46 | <text class="p14">{{pickerInfoList[1].nameArray1[pickerInfoList[1].nameIndex1]}}</text> |
37 | <picker @change="bindPickerChange11" :value="pickerInfoList[1].nameIndex1" :range="pickerInfoList[1].nameArray1"> | 47 | <picker @change="bindPickerChange11" :value="pickerInfoList[1].nameIndex1" :range="pickerInfoList[1].nameArray1"> |
38 | <image src="../../static/detail-tabicon.png" ></image> | 48 | <image src="../../static/detail-tabicon.png" ></image> |
39 | </picker> | 49 | </picker> |
40 | <text class="p13">右 (OS)</text> | 50 | <text class="p13">右 (OS)</text> |
41 | <text class="p14">{{pickerInfoList[1].nameArray2[pickerInfoList[1].nameIndex2]}}</text> | 51 | <text class="p14">{{pickerInfoList[1].nameArray2[pickerInfoList[1].nameIndex2]}}</text> |
42 | <picker @change="bindPickerChange12" :value="pickerInfoList[1].nameIndex2" :range="pickerInfoList[1].nameArray2"> | 52 | <picker @change="bindPickerChange12" :value="pickerInfoList[1].nameIndex2" :range="pickerInfoList[1].nameArray2"> |
43 | <image src="../../static/detail-tabicon.png" ></image> | 53 | <image src="../../static/detail-tabicon.png" ></image> |
44 | </picker> | 54 | </picker> |
45 | </view> | 55 | </view> |
46 | </view> | 56 | </view> |
47 | <view class="picker" > | 57 | <view class="picker" > |
48 | <view class="picker-choice"> | 58 | <view class="picker-choice"> |
49 | <view class="choice-left"> | 59 | <view class="choice-left"> |
50 | <text class="p11">{{pickerInfoList[2].nameC}}</text> | 60 | <text class="p11">{{pickerInfoList[2].nameC}}</text> |
51 | <text class="p12">{{pickerInfoList[2].nameE}}</text> | 61 | <text class="p12">{{pickerInfoList[2].nameE}}</text> |
52 | </view> | 62 | </view> |
53 | <text class="p13">左 (OD)</text> | 63 | <text class="p13">左 (OD)</text> |
54 | <text class="p14">{{pickerInfoList[2].nameArray1[pickerInfoList[2].nameIndex1]}}</text> | 64 | <text class="p14">{{pickerInfoList[2].nameArray1[pickerInfoList[2].nameIndex1]}}</text> |
55 | <picker @change="bindPickerChange21" :value="pickerInfoList[2].nameIndex1" :range="pickerInfoList[2].nameArray1"> | 65 | <picker @change="bindPickerChange21" :value="pickerInfoList[2].nameIndex1" :range="pickerInfoList[2].nameArray1"> |
56 | <image src="../../static/detail-tabicon.png" ></image> | 66 | <image src="../../static/detail-tabicon.png" ></image> |
57 | </picker> | 67 | </picker> |
58 | <text class="p13">右 (OS)</text> | 68 | <text class="p13">右 (OS)</text> |
59 | <text class="p14">{{pickerInfoList[2].nameArray2[pickerInfoList[2].nameIndex2]}}</text> | 69 | <text class="p14">{{pickerInfoList[2].nameArray2[pickerInfoList[2].nameIndex2]}}</text> |
60 | <picker @change="bindPickerChange22" :value="pickerInfoList[2].nameIndex2" :range="pickerInfoList[2].nameArray2"> | 70 | <picker @change="bindPickerChange22" :value="pickerInfoList[2].nameIndex2" :range="pickerInfoList[2].nameArray2"> |
61 | <image src="../../static/detail-tabicon.png" ></image> | 71 | <image src="../../static/detail-tabicon.png" ></image> |
62 | </picker> | 72 | </picker> |
63 | </view> | 73 | </view> |
64 | </view> | 74 | </view> |
65 | <view class="picker" > | 75 | <!-- <view class="picker" > |
66 | <view class="picker-choice"> | 76 | <view class="picker-choice"> |
67 | <view class="choice-left"> | 77 | <view class="choice-left"> |
68 | <text class="p11">{{pickerInfoList[3].nameC}}</text> | 78 | <text class="p11">{{pickerInfoList[3].nameC}}</text> |
69 | <text class="p12">{{pickerInfoList[3].nameE}}</text> | 79 | <text class="p12">{{pickerInfoList[3].nameE}}</text> |
70 | </view> | 80 | </view> |
71 | <text class="p13">左 (OD)</text> | 81 | <text class="p13">左 (OD)</text> |
72 | <text class="p14">{{pickerInfoList[3].nameArray1[pickerInfoList[3].nameIndex1]}}</text> | 82 | <text class="p14">{{pickerInfoList[3].nameArray1[pickerInfoList[3].nameIndex1]}}</text> |
73 | <picker @change="bindPickerChange31" :value="pickerInfoList[3].nameIndex1" :range="pickerInfoList[3].nameArray1"> | 83 | <picker @change="bindPickerChange31" :value="pickerInfoList[3].nameIndex1" :range="pickerInfoList[3].nameArray1"> |
74 | <image src="../../static/detail-tabicon.png" ></image> | 84 | <image src="../../static/detail-tabicon.png" ></image> |
75 | </picker> | 85 | </picker> |
76 | <text class="p13">右 (OS)</text> | 86 | <text class="p13">右 (OS)</text> |
77 | <text class="p14">{{pickerInfoList[3].nameArray2[pickerInfoList[3].nameIndex2]}}</text> | 87 | <text class="p14">{{pickerInfoList[3].nameArray2[pickerInfoList[3].nameIndex2]}}</text> |
78 | <picker @change="bindPickerChange32" :value="pickerInfoList[3].nameIndex2" :range="pickerInfoList[3].nameArray2"> | 88 | <picker @change="bindPickerChange32" :value="pickerInfoList[3].nameIndex2" :range="pickerInfoList[3].nameArray2"> |
79 | <image src="../../static/detail-tabicon.png" ></image> | 89 | <image src="../../static/detail-tabicon.png" ></image> |
80 | </picker> | 90 | </picker> |
81 | </view> | 91 | </view> |
82 | </view> | 92 | </view> --> |
83 | <view class="picker" > | 93 | <view class="picker" > |
84 | <view class="picker-choice"> | 94 | <view class="picker-choice"> |
85 | <view class="choice-left"> | 95 | <view class="choice-left"> |
86 | <text class="p11">{{pickerInfoList[4].nameC}}</text> | 96 | <text class="p11">{{pickerInfoList[3].nameC}}</text> |
87 | </view> | 97 | </view> |
88 | <text class="p13-date">年 (Y)</text> | 98 | <text class="p13-date">年 (Y)</text> |
89 | <text class="p14" style="width: 34px;">{{pickerInfoList[4].nameArray1[pickerInfoList[4].nameIndex1]}}</text> | 99 | <text class="p14" style="width: 34px;">{{pickerInfoList[3].nameArray1[pickerInfoList[3].nameIndex1]}}</text> |
90 | <picker @change="bindPickerChange41" :value="pickerInfoList[4].nameIndex1" :range="pickerInfoList[4].nameArray1"> | 100 | <picker @change="bindPickerChange41" :value="pickerInfoList[3].nameIndex1" :range="pickerInfoList[3].nameArray1"> |
91 | <image src="../../static/detail-tabicon.png" ></image> | 101 | <image src="../../static/detail-tabicon.png" ></image> |
92 | </picker> | 102 | </picker> |
93 | <text class="p13-date">月 (M)</text> | 103 | <text class="p13-date">月 (M)</text> |
94 | <text class="p14" style="width: 30px;">{{pickerInfoList[4].nameArray2[pickerInfoList[4].nameIndex2]}}</text> | 104 | <text class="p14" style="width: 30px;">{{pickerInfoList[3].nameArray2[pickerInfoList[3].nameIndex2]}}</text> |
95 | <picker @change="bindPickerChange42" :value="pickerInfoList[4].nameIndex2" :range="pickerInfoList[4].nameArray2"> | 105 | <picker @change="bindPickerChange42" :value="pickerInfoList[3].nameIndex2" :range="pickerInfoList[3].nameArray2"> |
96 | <image src="../../static/detail-tabicon.png" ></image> | 106 | <image src="../../static/detail-tabicon.png" ></image> |
97 | </picker> | 107 | </picker> |
98 | <text class="p13-date">日 (D)</text> | 108 | <text class="p13-date">日 (D)</text> |
99 | <text class="p14" style="width: 30px;">{{pickerInfoList[4].nameArray3[pickerInfoList[4].nameIndex3]}}</text> | 109 | <text class="p14" style="width: 30px;">{{pickerInfoList[3].nameArray3[pickerInfoList[3].nameIndex3]}}</text> |
100 | <picker @change="bindPickerChange43" :value="pickerInfoList[4].nameIndex3" :range="pickerInfoList[4].nameArray3"> | 110 | <picker @change="bindPickerChange43" :value="pickerInfoList[3].nameIndex3" :range="pickerInfoList[3].nameArray3"> |
101 | <image src="../../static/detail-tabicon.png" ></image> | 111 | <image src="../../static/detail-tabicon.png" ></image> |
102 | </picker> | 112 | </picker> |
103 | </view> | 113 | </view> |
104 | </view> | 114 | </view> |
105 | <view class="confirm"> | 115 | <view class="confirm"> |
106 | <image :src="tablist.confirm ? tabicon[0] : tabicon[1]" @click="changeConfirm"></image> | 116 | <image :src="confirm ? tabicon[0] : tabicon[1]" @click="changeConfirm"></image> |
107 | <text>确认以上输入信息来源于我的验光数据!</text> | 117 | <text>确认以上输入信息来源于我的验光数据!</text> |
108 | </view> | 118 | </view> |
109 | </view> | 119 | </view> |
110 | 120 | ||
111 | </template> | 121 | </template> |
112 | </view> | 122 | </view> |
113 | 123 | ||
114 | 124 | ||
115 | <view class="footer"> | 125 | <view class="footer" @click="handleSubmit"> |
116 | <button class="btn" type="default">提 交</button> | 126 | <button class="btn" type="default">提 交</button> |
117 | </view> | 127 | </view> |
118 | </view> | 128 | </view> |
119 | </template> | 129 | </template> |
120 | 130 | ||
121 | <script> | 131 | <script> |
132 | import store from '@/store'; | ||
133 | |||
122 | export default { | 134 | export default { |
123 | data() { | 135 | data() { |
124 | return { | 136 | return { |
125 | pickerInfoList:[ | 137 | pickerInfoList:[ |
126 | {nameC:"度数",nameE:"(SPH)",nameArray1:[1.5,2.5,3.5,4.5],nameIndex1:0,nameArray2:[1.5,2.5,3.5,4.5],nameIndex2:0,key:0}, | 138 | {nameC:"度数",nameE:"(SPH)",nameArray1:[''],nameIndex1:0,nameArray2:[''],nameIndex2:0,key:0}, |
127 | {nameC:"散光",nameE:"(CYL)",nameArray1:[1.5,2.5,3.5,4.5],nameIndex1:0,nameArray2:[1.5,2.5,3.5,4.5],nameIndex2:0,key:1}, | 139 | {nameC:"散光",nameE:"(CYL)",nameArray1:[''],nameIndex1:0,nameArray2:[''],nameIndex2:0,key:1}, |
128 | {nameC:"散光轴位",nameE:"(AXI)",nameArray1:[1.5,2.5,3.5,4.5],nameIndex1:0,nameArray2:[1.5,2.5,3.5,4.5],nameIndex2:0,key:2}, | 140 | {nameC:"散光轴位",nameE:"(AXI)",nameArray1:[''],nameIndex1:0,nameArray2:[''],nameIndex2:0,key:2}, |
129 | {nameC:"双眼瞳距",nameE:"(PD)",nameArray1:[1.5,2.5,3.5,4.5],nameIndex1:0,nameArray2:[1.5,2.5,3.5,4.5],nameIndex2:0,key:3}, | 141 | {nameC:"验光日期",nameE:'',nameArray1:[''],nameIndex1:0,nameArray2:['',1,2,3,4,5,6,7,8,9,10,11,12],nameIndex2:0,nameArray3:[''],nameIndex3:0} |
130 | {nameC:"验光日期",nameE:'',nameArray1:[2017,2018,2019,2020,2021],nameIndex1:0,nameArray2:[1,2,3,4,5,6,7],nameIndex2:0,nameArray3:[1,2,3,4,5,6],nameIndex3:0} | ||
131 | ], | 142 | ], |
132 | tablist: { | 143 | confirm: false, // 用户是否确认 |
133 | // read: true, | 144 | tabicon:['/static/detail-button.png','/static/detail-button-unselected.png'], |
134 | // seeLong: false, | 145 | name: '夏小花', |
135 | confirm: false | 146 | pickerInfoChioce:{ |
147 | "leftSph": 0, | ||
148 | "rightSph": 0, | ||
149 | "leftCyl": 0, | ||
150 | "rightCyl": 0, | ||
151 | "leftAxi": 0, | ||
152 | "rightAxi": 0, | ||
153 | "time":{ | ||
154 | "year":0, | ||
155 | "month": 0, | ||
156 | "day":0 , | ||
157 | } | ||
136 | }, | 158 | }, |
137 | tabicon:['/static/detail-button.png','/static/detail-button-unselected.png'], | 159 | pd: '',// 瞳距 |
160 | kinds:Number, // kinds=1,提交为新增验光,2为修改 | ||
161 | mp_id: Number | ||
138 | }; | 162 | }; |
139 | }, | 163 | }, |
164 | onLoad: function (option) { | ||
165 | //option为object类型,会序列化上个页面传递的参数 | ||
166 | // 初始化SPL、CYL、AXI的值 | ||
167 | for (let j = 0; j < 3; j++) { | ||
168 | for(let i=-12;i<6;i++){ | ||
169 | this.pickerInfoList[j].nameArray1.push(i) | ||
170 | this.pickerInfoList[j].nameArray1.push(i+0.5) | ||
171 | this.pickerInfoList[j].nameArray2.push(i) | ||
172 | this.pickerInfoList[j].nameArray2.push(i+0.5) | ||
173 | if(i>=-6){ | ||
174 | this.pickerInfoList[j].nameArray1.push(i+0.25) | ||
175 | this.pickerInfoList[j].nameArray1.push(i+0.75) | ||
176 | this.pickerInfoList[j].nameArray2.push(i+0.25) | ||
177 | this.pickerInfoList[j].nameArray2.push(i+0.75) | ||
178 | } | ||
179 | if(i==5){ | ||
180 | this.pickerInfoList[j].nameArray1.push(i+1) | ||
181 | this.pickerInfoList[j].nameArray2.push(i+1) | ||
182 | } | ||
183 | } | ||
184 | } | ||
185 | // 初始化日期值 | ||
186 | for (let i = 1; i < 32; i++){ | ||
187 | this.pickerInfoList[3].nameArray3.push(i) | ||
188 | } | ||
189 | // 初始化年份前后五年 | ||
190 | let myDate = new Date(); | ||
191 | let nowYear = myDate.getFullYear(); | ||
192 | for(let i=0;i<5;i++){ | ||
193 | this.pickerInfoList[3].nameArray1.push(nowYear-i) | ||
194 | } | ||
195 | |||
196 | this.kinds=option.kinds | ||
197 | if(option.kinds==1){ | ||
198 | this.name= ''; | ||
199 | this.pd= ''; | ||
200 | } else{ | ||
201 | console.log('args===>',option.index) | ||
202 | const loveList=Object.assign({},this.$store.state.myLoveList.loveList) | ||
203 | console.log('args===>',loveList[option.index].in_time) | ||
204 | console.log('args===>',loveList[option.index].in_time.toString().slice(0,4)) | ||
205 | console.log('args===>',loveList[option.index].in_time.toString().slice(5,6)==0) | ||
206 | console.log('args===>',loveList[option.index].in_time.toString().slice(8,10)) | ||
207 | this.name=loveList[option.index].name | ||
208 | this.pd=loveList[option.index].pd | ||
209 | this.mp_id=loveList[option.index].mp_id | ||
210 | // 将kinds =2时的值传到该页面 | ||
211 | this.pickerInfoList[0].nameArray1.unshift(loveList[option.index].leftSph) | ||
212 | this.pickerInfoList[0].nameArray2.unshift(loveList[option.index].rightSph) | ||
213 | this.pickerInfoList[1].nameArray1.unshift(loveList[option.index].leftCyl) | ||
214 | this.pickerInfoList[1].nameArray2.unshift(loveList[option.index].rightCyl) | ||
215 | this.pickerInfoList[2].nameArray1.unshift(loveList[option.index].leftAxi) | ||
216 | this.pickerInfoList[2].nameArray2.unshift(loveList[option.index].rightAxi) | ||
217 | |||
218 | this.pickerInfoList[3].nameArray1.unshift(loveList[option.index].in_time.toString().slice(0,4)) | ||
219 | if(loveList[option.index].in_time.toString().slice(5,6)==0){ | ||
220 | this.pickerInfoList[3].nameArray2.unshift(loveList[option.index].in_time.toString().slice(6,7)) | ||
221 | } else{ | ||
222 | this.pickerInfoList[3].nameArray2.unshift(loveList[option.index].in_time.toString().slice(5,7)) | ||
223 | } | ||
224 | if(loveList[option.index].in_time.toString().slice(8,9)==0){ | ||
225 | this.pickerInfoList[3].nameArray3.unshift(loveList[option.index].in_time.toString().slice(9,10)) | ||
226 | } else{ | ||
227 | this.pickerInfoList[3].nameArray3.unshift(loveList[option.index].in_time.toString().slice(8,10)) | ||
228 | } | ||
229 | } | ||
230 | }, | ||
140 | methods:{ | 231 | methods:{ |
232 | handleInput(e){ | ||
233 | this.name=e.target.value | ||
234 | }, | ||
235 | handleInputPd(e){ | ||
236 | // 只能输入正浮点数或正数 | ||
237 | if(/^\d+(\.\d+)?$/.test(e.target.value)){ | ||
238 | this.pd=e.target.value | ||
239 | } else { | ||
240 | uni.showToast({ | ||
241 | title:"请输入有效数据;示例:89", | ||
242 | icon: "none", | ||
243 | duration: 3000, | ||
244 | }) | ||
245 | this.pd = '' | ||
246 | } | ||
247 | |||
248 | }, | ||
249 | // 用户提交 | ||
250 | handleSubmit(){ | ||
251 | if(this.name==''){ | ||
252 | uni.showToast({ | ||
253 | title:"请输入验光单取名", | ||
254 | icon: "none", | ||
255 | duration: 3000, | ||
256 | }) | ||
257 | } | ||
258 | if(this.pd==''){ | ||
259 | uni.showToast({ | ||
260 | title:"请输入瞳距", | ||
261 | icon: "none", | ||
262 | duration: 3000, | ||
263 | }) | ||
264 | } | ||
265 | if(this.confirm){ | ||
266 | if(this.kinds==1){ | ||
267 | // 添加用户验光单 | ||
268 | console.log('kinds====>',this.kinds) | ||
269 | store.dispatch('myLoveList/addMylove', { | ||
270 | |||
271 | uid: this.$store.state.user.userInfo.uid, | ||
272 | openid: this.$store.state.user.userInfo.openid, | ||
273 | // mp_name: this.$store.state.user.userInfo.mp_name, | ||
274 | leftSph: this.pickerInfoChioce.leftSph, | ||
275 | rightSph: this.pickerInfoChioce.rightSph, | ||
276 | leftCyl: this.pickerInfoChioce.leftCyl, | ||
277 | rightCyl: this.pickerInfoChioce.rightCyl, | ||
278 | leftAxi: this.pickerInfoChioce.leftAxi, | ||
279 | rightAxi: this.pickerInfoChioce.rightAxi, | ||
280 | pd: this.pd,// 瞳距 | ||
281 | mp_name:this.name, | ||
282 | // time: this.pickerInfoChioce.time, | ||
283 | // img_url2: "http://localhost:8087/images/shop_1/1/", | ||
284 | }); | ||
285 | store.dispatch('myLoveList/getLoveList', { | ||
286 | uid: this.$store.state.user.userInfo.uid, | ||
287 | }); | ||
288 | uni.navigateBack({ | ||
289 | delta:1, | ||
290 | animationDuration:2000 | ||
291 | }) | ||
292 | } | ||
293 | if(this.kinds==2){ | ||
294 | // console.log('kinds====>',this.kinds) | ||
295 | // console.log('pickerindex=====>',this.pickerInfoList[0].nameIndex1) | ||
296 | // console.log('this.pickerInfoChioce====>',type(this.pickerInfoChioce)) | ||
297 | const leftList = ["leftSph","leftCyl","leftAxi"]; | ||
298 | const rightList = ["rightSph", "rightCyl", "rigthAxi"]; | ||
299 | for (let j=0; j<3; j++) { | ||
300 | if(this.pickerInfoList[j].nameIndex1!=0){ | ||
301 | |||
302 | store.dispatch('myLoveList/updateMylove', { | ||
303 | uid: this.$store.state.user.userInfo.uid, | ||
304 | openid: this.$store.state.user.userInfo.openid, | ||
305 | mp_id: this.mp_id, | ||
306 | keyname: leftList[j], | ||
307 | keyvalue: this.pickerInfoList[j].nameArray1[this.pickerInfoList[j].nameIndex1], | ||
308 | }); | ||
309 | } | ||
310 | if(this.pickerInfoList[j].nameIndex2 !=0) { | ||
311 | store.dispatch('myLoveList/updateMylove', { | ||
312 | uid: this.$store.state.user.userInfo.uid, | ||
313 | openid: this.$store.state.user.userInfo.openid, | ||
314 | mp_id: this.mp_id, | ||
315 | keyname: rightList[j], | ||
316 | keyvalue: this.pickerInfoList[j].nameArray2[this.pickerInfoList[j].nameIndex2] | ||
317 | }); | ||
318 | } | ||
319 | } | ||
320 | store.dispatch('myLoveList/getLoveList', { | ||
321 | uid: this.$store.state.user.userInfo.uid, | ||
322 | }); | ||
323 | uni.navigateBack({ | ||
324 | delta:1, | ||
325 | animationDuration:2000 | ||
326 | }) | ||
327 | |||
328 | } | ||
329 | |||
330 | } else{ | ||
331 | uni.showToast({ | ||
332 | title:"请确认你的验光数据", | ||
333 | icon: "none", | ||
334 | duration: 3000, | ||
335 | }) | ||
336 | } | ||
337 | }, | ||
141 | changeConfirm() { | 338 | changeConfirm() { |
142 | this.tablist.confirm = !this.tablist.confirm | 339 | this.confirm = !this.confirm |
143 | }, | 340 | }, |
144 | 341 | ||
145 | bindPickerChange01: function(e) { | 342 | bindPickerChange01: function(e) { |
146 | this.pickerInfoList[0].nameIndex1 = e.target.value | 343 | this.pickerInfoList[0].nameIndex1 = e.target.value |
344 | this.pickerInfoChioce.leftSph=this.pickerInfoList[0].nameArray1[e.target.value] | ||
147 | }, | 345 | }, |
148 | bindPickerChange02: function(e) { | 346 | bindPickerChange02: function(e) { |
149 | this.pickerInfoList[0].nameIndex2 = e.target.value | 347 | this.pickerInfoList[0].nameIndex2 = e.target.value |
348 | this.pickerInfoChioce.rightSph=this.pickerInfoList[0].nameArray2[e.target.value] | ||
150 | }, | 349 | }, |
151 | 350 | ||
152 | bindPickerChange11: function(e) { | 351 | bindPickerChange11: function(e) { |
153 | this.pickerInfoList[1].nameIndex1 = e.target.value | 352 | this.pickerInfoList[1].nameIndex1 = e.target.value |
353 | this.pickerInfoChioce.leftCyl=this.pickerInfoList[1].nameArray1[e.target.value] | ||
154 | }, | 354 | }, |
155 | bindPickerChange12: function(e) { | 355 | bindPickerChange12: function(e) { |
156 | this.pickerInfoList[1].nameIndex2 = e.target.value | 356 | this.pickerInfoList[1].nameIndex2 = e.target.value |
357 | this.pickerInfoChioce.rightCyl=this.pickerInfoList[1].nameArray2[e.target.value] | ||
157 | }, | 358 | }, |
158 | 359 | ||
159 | bindPickerChange21: function(e) { | 360 | bindPickerChange21: function(e) { |
160 | this.pickerInfoList[2].nameIndex1 = e.target.value | 361 | this.pickerInfoList[2].nameIndex1 = e.target.value |
362 | this.pickerInfoChioce.leftAxi=this.pickerInfoList[2].nameArray1[e.target.value] | ||
161 | }, | 363 | }, |
162 | bindPickerChange22: function(e) { | 364 | bindPickerChange22: function(e) { |
163 | this.pickerInfoList[2].nameIndex2 = e.target.value | 365 | this.pickerInfoList[2].nameIndex2 = e.target.value |
366 | this.pickerInfoChioce.rightAxi=this.pickerInfoList[2].nameArray2[e.target.value] | ||
164 | }, | 367 | }, |
165 | 368 | ||
166 | bindPickerChange31: function(e) { | ||
167 | this.pickerInfoList[3].nameIndex1 = e.target.value | ||
168 | }, | ||
169 | bindPickerChange32: function(e) { | ||
170 | this.pickerInfoList[3].nameIndex2 = e.target.value | ||
171 | }, | ||
172 | |||
173 | bindPickerChange41: function(e) { | 369 | bindPickerChange41: function(e) { |
174 | this.pickerInfoList[4].nameIndex1 = e.target.value | 370 | this.pickerInfoList[3].nameIndex1 = e.target.value |
371 | this.pickerInfoChioce.time.year=this.pickerInfoList[3].nameArray1[e.target.value] | ||
175 | }, | 372 | }, |
176 | bindPickerChange42: function(e) { | 373 | bindPickerChange42: function(e) { |
177 | this.pickerInfoList[4].nameIndex2 = e.target.value | 374 | this.pickerInfoList[3].nameIndex2 = e.target.value |
375 | this.pickerInfoChioce.time.month=this.pickerInfoList[3].nameArray2[e.target.value] | ||
178 | }, | 376 | }, |
179 | bindPickerChange43: function(e) { | 377 | bindPickerChange43: function(e) { |
180 | this.pickerInfoList[4].nameIndex3 = e.target.value | 378 | this.pickerInfoList[3].nameIndex3 = e.target.value |
379 | this.pickerInfoChioce.time.day=this.pickerInfoList[3].nameArray3[e.target.value] | ||
181 | }, | 380 | }, |
182 | } | 381 | } |
183 | } | 382 | } |
184 | </script> | 383 | </script> |
185 | 384 | ||
186 | <style lang="scss"> | 385 | <style lang="scss"> |
187 | .wrap{ | 386 | .wrap{ |
188 | min-height: 100vh; | 387 | min-height: 100vh; |
189 | background-color: #F2F2F2; | 388 | background-color: #F2F2F2; |
190 | .body{ | 389 | .body{ |
191 | // font-family: PingFangSC-Regular; | 390 | // font-family: PingFangSC-Regular; |
192 | font-size: 12px; | 391 | font-size: 12px; |
193 | color: #666666; | 392 | color: #666666; |
194 | letter-spacing: 0; | 393 | letter-spacing: 0; |
195 | .bodyBox{ | 394 | .bodyBox{ |
196 | margin-top: 15px; | 395 | margin-top: 15px; |
197 | .names{ | 396 | .names{ |
198 | // font-family: PingFangSC-Regular; | 397 | // font-family: PingFangSC-Regular; |
199 | font-size: 12px; | 398 | font-size: 12px; |
200 | color: #151515; | 399 | color: #151515; |
201 | letter-spacing: 0; | 400 | letter-spacing: 0; |
202 | text-align: justify; | 401 | text-align: justify; |
203 | line-height: 17px; | 402 | line-height: 17px; |
204 | margin-left: 5px; | 403 | margin-left: 5px; |
205 | margin-right: 10px; | 404 | margin-right: 10px; |
206 | } | 405 | } |
207 | text{ | 406 | text{ |
208 | // font-family: PingFangSC-Regular; | 407 | // font-family: PingFangSC-Regular; |
209 | font-size: 12px; | 408 | font-size: 12px; |
210 | color: #666666; | 409 | color: #666666; |
211 | letter-spacing: 0; | 410 | letter-spacing: 0; |
212 | text-align: justify; | 411 | text-align: justify; |
213 | } | 412 | } |
214 | } | 413 | } |
215 | 414 | ||
216 | } | 415 | } |
217 | .goods-form { | 416 | .goods-form { |
218 | display: flex; | 417 | display: flex; |
219 | flex-direction: column; | 418 | flex-direction: column; |
220 | align-items: center; | 419 | align-items: center; |
221 | justify-content: center; | 420 | justify-content: center; |
222 | background-color: #fff; | 421 | background-color: #fff; |
223 | width: 100%; | 422 | width: 100%; |
224 | padding: 40rpx 0; | 423 | padding: 40rpx 0; |
225 | .p1 { | 424 | .p1 { |
226 | font-size: 16px; | 425 | font-size: 16px; |
227 | color: #333333; | 426 | color: #333333; |
228 | letter-spacing: -0.3px; | 427 | letter-spacing: -0.3px; |
229 | text-align: justify; | 428 | text-align: justify; |
230 | line-height: 24px; | 429 | line-height: 24px; |
231 | margin: 4px 0; | 430 | margin: 4px 0; |
232 | 431 | ||
233 | } | 432 | } |
234 | .p2 { | 433 | .p2 { |
235 | font-size: 12px; | 434 | font-size: 12px; |
236 | color: #999999; | 435 | color: #999999; |
237 | letter-spacing: -0.23px; | 436 | letter-spacing: -0.23px; |
238 | margin-bottom: 18rpx; | 437 | margin-bottom: 18rpx; |
239 | } | 438 | } |
439 | .use_pd{ | ||
440 | display: flex; | ||
441 | height: 48rpx; | ||
442 | line-height: 48rpx; | ||
443 | margin-left: -298rpx; | ||
444 | margin-top: 30rpx; | ||
445 | margin-bottom: 40rpx; | ||
446 | align-items: center; | ||
447 | justify-content: center; | ||
448 | text{ | ||
449 | font-size: 14px; | ||
450 | color: #333333; | ||
451 | margin-right: 44rpx; | ||
452 | } | ||
453 | } | ||
454 | .use_name{ | ||
455 | display: flex; | ||
456 | height: 48rpx; | ||
457 | line-height: 48rpx; | ||
458 | margin-left: -220rpx; | ||
459 | margin-top: 20rpx; | ||
460 | align-items: center; | ||
461 | justify-content: center; | ||
462 | // text-align: center; | ||
463 | text{ | ||
464 | font-size: 14px; | ||
465 | color: #333333; | ||
466 | margin-right: 44rpx; | ||
467 | } | ||
468 | } | ||
240 | image{ | 469 | image{ |
241 | width: 28rpx; | 470 | width: 28rpx; |
242 | height: 26rpx; | 471 | height: 26rpx; |
243 | } | 472 | } |
244 | .confirm { | 473 | .confirm { |
245 | display: flex; | 474 | display: flex; |
246 | align-items: center; | 475 | align-items: center; |
247 | font-size: 12px; | 476 | font-size: 12px; |
248 | color: #666666; | 477 | color: #666666; |
249 | letter-spacing: -0.23px; | 478 | letter-spacing: -0.23px; |
250 | width: 684rpx; | 479 | width: 684rpx; |
251 | image{ | 480 | image{ |
252 | margin-right:25rpx; | 481 | margin-right:25rpx; |
253 | } | 482 | } |
254 | } | 483 | } |
255 | .picker{ | 484 | .picker{ |
256 | display: flex; | 485 | display: flex; |
257 | flex-direction: column; | 486 | flex-direction: column; |
258 | justify-content: center; | 487 | justify-content: center; |
259 | align-items: center; | 488 | align-items: center; |
260 | width: 100%; | 489 | width: 100%; |
261 | image{ | 490 | image{ |
262 | width: 10px; | 491 | width: 10px; |
263 | height: 10px; | 492 | height: 10px; |
264 | margin-right: 5px; | 493 | margin-right: 5px; |
265 | } | 494 | } |
266 | .picker-choice{ | 495 | .picker-choice{ |
267 | display: flex; | 496 | display: flex; |
268 | width: 684rpx; | 497 | width: 684rpx; |
269 | align-items: center; | 498 | align-items: center; |
270 | margin-bottom: 40rpx; | 499 | margin-bottom: 40rpx; |
271 | .choice-left{ | 500 | .choice-left{ |
272 | width: 210rpx; | 501 | width: 210rpx; |
273 | .p11 { | 502 | .p11 { |
274 | font-size: 14px; | 503 | font-size: 14px; |
275 | color: #333333; | 504 | color: #333333; |
276 | letter-spacing: -0.26px; | 505 | letter-spacing: -0.26px; |
277 | text-align: justify; | 506 | text-align: justify; |
278 | line-height: 24px; | 507 | line-height: 24px; |
279 | // margin-right: 10px; | 508 | // margin-right: 10px; |
280 | } | 509 | } |
281 | .p12 { | 510 | .p12 { |
282 | font-size: 10px; | 511 | font-size: 10px; |
283 | color: #3F3F3F; | 512 | color: #3F3F3F; |
284 | letter-spacing: -0.19px; | 513 | letter-spacing: -0.19px; |
285 | text-align: justify; | 514 | text-align: justify; |
286 | line-height: 24px; | 515 | line-height: 24px; |
287 | } | 516 | } |
288 | 517 | ||
289 | 518 | ||
290 | } | 519 | } |
291 | .p13 { | 520 | .p13 { |
292 | font-size: 10px; | 521 | font-size: 10px; |
293 | color: #999999; | 522 | color: #999999; |
294 | letter-spacing: -0.19px; | 523 | letter-spacing: -0.19px; |
295 | margin-right: 10px; | 524 | margin-right: 10px; |
296 | } | 525 | } |
297 | .p13-date { | 526 | .p13-date { |
298 | font-size: 10px; | 527 | font-size: 10px; |
299 | color: #999999; | 528 | color: #999999; |
300 | letter-spacing: -0.19px; | 529 | letter-spacing: -0.19px; |
301 | margin-right: 5px; | 530 | margin-right: 5px; |
302 | } | 531 | } |
303 | .p14 { | 532 | .p14 { |
304 | font-size: 14px; | 533 | font-size: 14px; |
305 | color: #666666; | 534 | color: #666666; |
306 | letter-spacing: -0.26px; | 535 | letter-spacing: -0.26px; |
307 | text-align: center; | 536 | text-align: center; |
308 | width: 124rpx; | 537 | width: 124rpx; |
309 | border-bottom: 1px solid #CFCFCF; | 538 | border-bottom: 1px solid #CFCFCF; |
539 | height: 40rpx; | ||
540 | |||
310 | } | 541 | } |
311 | 542 | ||
312 | } | 543 | } |
313 | } | 544 | } |
314 | } | 545 | } |
315 | 546 | ||
316 | .footer{ | 547 | .footer{ |
317 | width: 100%; | 548 | width: 100%; |
318 | position: fixed; | 549 | position: fixed; |
319 | bottom: 0; | 550 | bottom: 0; |
320 | left: 0; | 551 | left: 0; |
321 | .btn{ | 552 | .btn{ |
322 | width: 100%; | 553 | width: 100%; |
323 | height: 112rpx; | 554 | height: 112rpx; |
324 | line-height: 112rpx; | 555 | line-height: 112rpx; |
src/pages/user/user.vue
1 | <template> | 1 | <template> |
2 | <view class="wrap"> | 2 | <view class="wrap"> |
3 | <!-- 弹窗 --> | ||
4 | <uni-popup ref="popup" type="center"> | ||
5 | <!-- 给一个左边弹窗的样式 --> | ||
6 | <!-- 关闭弹窗按钮 --> | ||
7 | <view class="closeBtn" @click="this.$refs.popup.close()">x</view> | ||
8 | <view class="popUpWrap" v-if="whichTap==0"> | ||
9 | <text>这是一款眼镜及周边产品的销售平台,我们将帮您进行建立全球销售网络,欢迎入驻。</text> | ||
10 | |||
11 | <!-- 左 --> | ||
12 | <!-- <image class="glassInfo" src="../../static/img/myOpticsData/glassInfo.png" v-if="whichTap == 0" mode="aspectFit"></image> --> | ||
13 | <!-- 右 --> | ||
14 | <!-- <image class="dataInfo" src="../../static/img/myOpticsData/dataInfo.png" v-else mode="aspectFit"></image> --> | ||
15 | </view> | ||
16 | <view class="popUpWrap" v-if="whichTap==1"> | ||
17 | <text>本平台欢迎全国各地的眼镜工厂、品牌、眼镜店加入。请联系我们申请注册账号。</text> | ||
18 | </view> | ||
19 | <view class="popUpWrap" v-if="whichTap==2"> | ||
20 | <button @click="chatOur(1)">客服1</button> | ||
21 | <button @click="chatOur(2)">客服2</button> | ||
22 | </view> | ||
23 | </uni-popup> | ||
3 | <view v-if="isAuth" class="content"> | 24 | <view v-if="isAuth" class="content"> |
4 | <view class="userInfo"> | 25 | <view class="userInfo"> |
5 | <view class="info"> | 26 | <view class="info"> |
6 | <image :src="headerphoto" mode="aspectFill"></image> | 27 | <image :src="headerphoto" mode="aspectFill"></image> |
7 | <view class="infoText"> | 28 | <view class="infoText"> |
8 | <text class="userName">{{nickName}}</text> | 29 | <text class="userName">{{nickName}}</text> |
9 | </view> | 30 | </view> |
10 | </view> | 31 | </view> |
11 | <!-- <view class="service"> | 32 | <!-- <view class="service"> |
12 | <image src="../../static/serviceLogo.png" mode="aspectFill"></image> | 33 | <image src="../../static/serviceLogo.png" mode="aspectFill"></image> |
13 | </view> --> | 34 | </view> --> |
14 | </view> | 35 | </view> |
15 | <view class="myOpticsData" @click="toOpticsData"> | 36 | <view class="myOpticsData" @click="toOpticsData"> |
16 | <view class="left"> | 37 | <view class="left"> |
17 | <image src="../../static/img/user/dataWrite.png" mode="aspectFit"></image> | 38 | <image src="../../static/img/user/dataWrite.png" mode="aspectFit"></image> |
18 | <text>验光数据</text> | 39 | <text>验光数据</text> |
19 | </view> | 40 | </view> |
20 | <image src="../../static/right.png" mode="aspectFit"></image> | 41 | <image src="../../static/right.png" mode="aspectFit"></image> |
21 | </view> | 42 | </view> |
22 | <view class="myOrder"> | 43 | <view class="myOrder"> |
23 | <view class="orderHeader"> | 44 | <view class="orderHeader"> |
24 | <text>全部订单</text> | 45 | <text>全部订单</text> |
25 | <view class="btn" @click="toMyOrder('10')"> | 46 | <view class="btn" @click="toMyOrder('10')"> |
26 | 全部 | 47 | 全部 |
27 | <image src="../../static/right.png" mode="aspectFit"></image> | 48 | <image src="../../static/right.png" mode="aspectFit"></image> |
28 | </view> | 49 | </view> |
29 | </view> | 50 | </view> |
30 | <view class="orderBody"> | 51 | <view class="orderBody"> |
31 | <view class="item waitPay" @click="toMyOrder('0')"> | 52 | <view class="item waitPay" @click="toMyOrder('0')"> |
32 | <image src="../../static/img/user/waitDeliver.png" mode="aspectFit"></image> | 53 | <image src="../../static/img/user/waitDeliver.png" mode="aspectFit"></image> |
33 | <text>待付款</text> | 54 | <text>待付款</text> |
34 | </view> | 55 | </view> |
35 | <view class="item waitDeliver" @click="toMyOrder('1')" > | 56 | <view class="item waitDeliver" @click="toMyOrder('1')" > |
36 | <image src="../../static/img/user/waitPay.png" mode="aspectFit"></image> | 57 | <image src="../../static/img/user/waitPay.png" mode="aspectFit"></image> |
37 | <text>待收货</text> | 58 | <text>待收货</text> |
38 | </view> | 59 | </view> |
39 | <view class="item waitReceive" @click="toMyOrder('2')"> | 60 | <view class="item waitReceive" @click="toMyOrder('2')"> |
40 | <image src="../../static/img/user/waitReceive.png" mode="aspectFit"></image> | 61 | <image src="../../static/img/user/waitReceive.png" mode="aspectFit"></image> |
41 | <text>已完成</text> | 62 | <text>已完成</text> |
42 | </view> | 63 | </view> |
43 | <!-- <view class="item service" @click="toMyOrder('3')"> | 64 | <!-- <view class="item service" @click="toMyOrder('3')"> |
44 | <image src="../../static/img/user/refound.png" mode="aspectFit"></image> | 65 | <image src="../../static/img/user/refound.png" mode="aspectFit"></image> |
45 | <text>已评价</text> | 66 | <text>已评价</text> |
46 | </view> --> | 67 | </view> --> |
47 | </view> | 68 | </view> |
48 | </view> | 69 | </view> |
49 | <view class="someItem"> | 70 | <view class="someItem"> |
50 | <!-- <view class="item"> | 71 | <!-- <view class="item"> |
51 | <view class="left"> | 72 | <view class="left"> |
52 | <image src="../../static/img/user/shouyi.png" mode="aspectFit"></image> | 73 | <image src="../../static/img/user/shouyi.png" mode="aspectFit"></image> |
53 | <text>推广记录与收益</text> | 74 | <text>推广记录与收益</text> |
54 | </view> | 75 | </view> |
55 | <image src="../../static/right.png" mode="aspectFit"></image> | 76 | <image src="../../static/right.png" mode="aspectFit"></image> |
56 | </view> --> | 77 | </view> --> |
57 | <view class="item"> | 78 | <view class="item" @click="changeTap(0)"> |
58 | <view class="left"> | 79 | <view class="left"> |
59 | <image src="../../static/img/user/introduce.png" mode="aspectFit"></image> | 80 | <image src="../../static/img/user/introduce.png" mode="aspectFit"></image> |
60 | <text>系统介绍</text> | 81 | <text>系统介绍</text> |
61 | </view> | 82 | </view> |
62 | <image src="../../static/right.png" mode="aspectFit"></image> | 83 | <image src="../../static/right.png" mode="aspectFit"></image> |
63 | </view> | 84 | </view> |
64 | <view class="item"> | 85 | <view class="item" @click="changeTap(1)"> |
65 | <view class="left"> | 86 | <view class="left"> |
66 | <image src="../../static/img/user/joinUs.png" mode="aspectFit"></image> | 87 | <image src="../../static/img/user/joinUs.png" mode="aspectFit"></image> |
67 | <text>加入我们</text> | 88 | <text>加入我们</text> |
68 | </view> | 89 | </view> |
69 | <image src="../../static/right.png" mode="aspectFit"></image> | 90 | <image src="../../static/right.png" mode="aspectFit"></image> |
70 | </view> | 91 | </view> |
71 | <view class="item"> | 92 | <view class="item" @click="changeTap(2)"> |
72 | <view class="left"> | 93 | <view class="left"> |
73 | <image src="../../static/img/user/service.png" mode="aspectFit"></image> | 94 | <image src="../../static/img/user/service.png" mode="aspectFit"></image> |
74 | <text>联系客服</text> | 95 | <text>联系客服</text> |
75 | </view> | 96 | </view> |
76 | <image src="../../static/right.png" mode="aspectFit"></image> | 97 | <image src="../../static/right.png" mode="aspectFit"></image> |
77 | </view> | 98 | </view> |
78 | </view> | 99 | </view> |
79 | <view class="recommend"> | 100 | <view class="recommend"> |
80 | <view class="title"> | 101 | <view class="title"> |
81 | <view class="line"></view> | 102 | <view class="line"></view> |
82 | <view class="text">精选推荐</view> | 103 | <view class="text">精选推荐</view> |
83 | <view class="line"></view> | 104 | <view class="line"></view> |
84 | </view> | 105 | </view> |
85 | <!-- 商品列表 --> | 106 | <!-- 商品列表 --> |
86 | <view class="goods-list"> | 107 | <view class="goods-list"> |
87 | <scroll-view enable-flex @scrolltolower="handleScrolltolower" scroll-y class="product-list"> | 108 | <scroll-view enable-flex @scrolltolower="handleScrolltolower" scroll-y class="product-list"> |
88 | <block v-for="(goods) in userRecommandList " :key="goods.list.sk_id"> | 109 | <block v-for="(goods) in userRecommandList " :key="goods.list.sk_id"> |
89 | <view class="product" v-for="(item) in goods.list" :key="item.sk_id"> | 110 | <view class="product" v-for="(item) in goods.list" :key="item.sk_id"> |
90 | <Card :goods="item" ></Card> | 111 | <Card :goods="item" ></Card> |
91 | </view> | 112 | </view> |
92 | </block> | 113 | </block> |
93 | </scroll-view> | 114 | </scroll-view> |
94 | <view class="loading-text">{{loadingText}}</view> | 115 | <view class="loading-text">{{loadingText}}</view> |
95 | </view> | 116 | </view> |
96 | </view> | 117 | </view> |
97 | </view> | 118 | </view> |
98 | <view v-else class="auth"> | 119 | <view v-else class="auth"> |
99 | <view class="icon"></view> | 120 | <view class="icon"></view> |
100 | <view class="divider"></view> | 121 | <view class="divider"></view> |
101 | <view class="title">申请获取以下权限</view> | 122 | <view class="title">申请获取以下权限</view> |
102 | <view class="text">获得您的公开信息(昵称、头像等)</view> | 123 | <view class="text">获得您的公开信息(昵称、头像等)</view> |
103 | <button | 124 | <button |
104 | type="primary" | 125 | type="primary" |
105 | open-type="getUserInfo" | 126 | open-type="getUserInfo" |
106 | @getuserinfo="onGotUserInfo" | 127 | @getuserinfo="onGotUserInfo" |
107 | >授权登陆</button> | 128 | >授权登陆</button> |
108 | </view> | 129 | </view> |
109 | </view> | 130 | </view> |
110 | </template> | 131 | </template> |
111 | 132 | ||
112 | <script> | 133 | <script> |
113 | import Card from "@/components/CommodityCard/CommodityCard.vue"; | 134 | import Card from "@/components/CommodityCard/CommodityCard.vue"; |
114 | import store from '@/store'; | 135 | import store from '@/store'; |
136 | import UniPopup from '@/components/UniPopup/uni-popup.vue' | ||
115 | 137 | ||
116 | export default { | 138 | export default { |
117 | components: { | 139 | components: { |
118 | 'Card':Card | 140 | 'Card':Card, |
141 | UniPopup | ||
119 | }, | 142 | }, |
120 | data() { | 143 | data() { |
121 | return { | 144 | return { |
122 | isAuth: true, // 是否显示授权页面, | 145 | isAuth: true, // 是否显示授权页面, |
123 | pagesnum:1 // 分页请求初始值 | 146 | pagesnum:1, // 分页请求初始值 |
147 | whichTap:0, // 弹窗渲染选择条件 | ||
124 | } | 148 | } |
125 | }, | 149 | }, |
126 | onLoad() { | 150 | onLoad() { |
127 | // 判断是否授权 | 151 | // 判断是否授权 |
128 | uni.getSetting({ | 152 | uni.getSetting({ |
129 | success(res) { | 153 | success(res) { |
130 | console.log('authSetting',res.authSetting) | 154 | console.log('authSetting',res.authSetting) |
131 | if(res.authSetting['scope.userInfo'] === true) { | 155 | if(res.authSetting['scope.userInfo'] === true) { |
132 | this.isAuth = true | 156 | this.isAuth = true |
133 | } else { | 157 | } else { |
134 | this.isAuth = false | 158 | this.isAuth = false |
135 | } | 159 | } |
136 | } | 160 | } |
137 | }) | 161 | }) |
138 | 162 | ||
139 | }, | 163 | }, |
140 | computed: { | 164 | computed: { |
141 | nickName() { | 165 | nickName() { |
142 | console.log('nickName', this.$store.state.user.userInfo) | 166 | console.log('nickName', this.$store.state.user.userInfo) |
143 | return this.$store.state.user.userInfo.nickName; | 167 | return this.$store.state.user.userInfo.nickName; |
144 | }, | 168 | }, |
145 | headerphoto() { | 169 | headerphoto() { |
146 | return this.$store.state.user.userInfo.headerphoto; | 170 | return this.$store.state.user.userInfo.headerphoto; |
147 | }, | 171 | }, |
148 | userRecommandList() { | 172 | userRecommandList() { |
149 | console.log('recommandList', this.$store.state.userRecommand.recommandList); | 173 | console.log('recommandList', this.$store.state.userRecommand.recommandList); |
150 | return this.$store.state.userRecommand.recommandList; | 174 | return this.$store.state.userRecommand.recommandList; |
151 | } | 175 | } |
152 | }, | 176 | }, |
153 | onLoad:function(){ | 177 | onLoad:function(){ |
154 | console.log('usr-my',this.$store.state.user.userInfo) | 178 | console.log('usr-my',this.$store.state.user.userInfo) |
155 | 179 | ||
156 | store.dispatch('userRecommand/getRecommandList', { | 180 | store.dispatch('userRecommand/getRecommandList', { |
157 | // uid:468, | 181 | // uid:468, |
158 | uid: this.$store.state.user.userInfo.uid, | 182 | uid: this.$store.state.user.userInfo.uid, |
159 | // openid:"oc8cg0d-0mFIInO4LyrCFtInPWr4", | 183 | // openid:"oc8cg0d-0mFIInO4LyrCFtInPWr4", |
160 | openid:this.$store.state.user.userInfo.openid, | 184 | openid:this.$store.state.user.userInfo.openid, |
161 | page: this.pagesnum | 185 | page: this.pagesnum |
162 | }); | 186 | }); |
163 | }, | 187 | }, |
164 | 188 | ||
165 | methods: { | 189 | methods: { |
190 | // 弹窗 | ||
191 | changeTap(item){ | ||
192 | this.whichTap = item | ||
193 | this.$refs.popup.open() | ||
194 | }, | ||
195 | chatOur(item){ | ||
196 | if(item==1){ | ||
197 | uni.makePhoneCall({ | ||
198 | phoneNumber:13376189297, // 客服1 电话 | ||
199 | }) | ||
200 | } else{ | ||
201 | uni.makePhoneCall({ | ||
202 | phoneNumber:18014995101 // 客服2 电话 | ||
203 | }) | ||
204 | } | ||
205 | }, | ||
166 | // 授权 | 206 | // 授权 |
167 | onGotUserInfo(e) { | 207 | onGotUserInfo(e) { |
168 | console.log('anthInfo', e); | 208 | console.log('anthInfo', e); |
169 | if(e.detail.errMsg == 'getUserInfo:ok') { | 209 | if(e.detail.errMsg == 'getUserInfo:ok') { |
170 | const { fromInfo } = this.$store.state.user; | 210 | const { fromInfo } = this.$store.state.user; |
171 | console.log('=====la', fromInfo) | 211 | console.log('=====la', fromInfo) |
172 | // 用户授权成功 | 212 | // 用户授权成功 |
173 | store.dispatch('user/getUserInfo', fromInfo); | 213 | store.dispatch('user/getUserInfo', fromInfo); |
174 | this.isAuth = true | 214 | this.isAuth = true |
175 | } | 215 | } |
176 | }, | 216 | }, |
177 | toMyOrder(status){ | 217 | toMyOrder(status){ |
178 | uni.navigateTo({ | 218 | uni.navigateTo({ |
179 | url: `../myOrder/myOrder?status=`+status, | 219 | url: `../myOrder/myOrder?status=`+status, |
180 | success: res => {}, | 220 | success: res => {}, |
181 | fail: () => {}, | 221 | fail: () => {}, |
182 | complete: () => {} | 222 | complete: () => {} |
183 | }); | 223 | }); |
184 | }, | 224 | }, |
185 | toOpticsData(){ | 225 | toOpticsData(){ |
186 | uni.navigateTo({ | 226 | uni.navigateTo({ |
187 | url: `../addOpticsData/addOpticsData`, | 227 | url: `../addOpticsData/addOpticsData`, |
188 | }); | 228 | }); |
189 | }, | 229 | }, |
190 | handleScrolltolower(){ | 230 | handleScrolltolower(){ |
191 | // console.log('usr-my',this.$store.state.user.userInfo) | 231 | // console.log('usr-my',this.$store.state.user.userInfo) |
192 | this.pagesnum++; | 232 | this.pagesnum++; |
193 | store.dispatch('userRecommand/getRecommandList', { | 233 | store.dispatch('userRecommand/getRecommandList', { |
194 | uid: this.$store.state.user.userInfo.uid, | 234 | uid: this.$store.state.user.userInfo.uid, |
195 | openid:this.$store.state.user.userInfo.openid, | 235 | openid:this.$store.state.user.userInfo.openid, |
196 | page: this.pagesnum | 236 | page: this.pagesnum |
197 | }); | 237 | }); |
198 | } | 238 | } |
199 | } | 239 | } |
200 | } | 240 | } |
201 | </script> | 241 | </script> |
202 | 242 | ||
203 | <style lang="scss"> | 243 | <style lang="scss"> |
204 | .warp{ | 244 | .warp{ |
205 | font-size: 24rpx; | 245 | font-size: 24rpx; |
206 | background-color: #f2f2f2; | 246 | background-color: #f2f2f2; |
207 | height: 100vh; | 247 | height: 100vh; |
208 | } | 248 | } |
209 | .content { | 249 | .content { |
210 | display: flex; | 250 | display: flex; |
211 | flex-direction: column; | 251 | flex-direction: column; |
212 | align-items: center; | 252 | align-items: center; |
213 | justify-content: center; | 253 | justify-content: center; |
214 | background-color: #F2F2F2; | 254 | background-color: #F2F2F2; |
215 | } | 255 | } |
216 | .userInfo{ | 256 | .userInfo{ |
217 | background-image: linear-gradient(270deg, #FFA481 0%, #FF6B4A 66%); | 257 | background-image: linear-gradient(270deg, #FFA481 0%, #FF6B4A 66%); |
218 | width: 100%; | 258 | width: 100%; |
219 | height: 240rpx; | 259 | height: 240rpx; |
220 | color: #FFFFFF; | 260 | color: #FFFFFF; |
221 | padding: 60rpx 82rpx 80rpx 44rpx; | 261 | padding: 60rpx 82rpx 80rpx 44rpx; |
222 | box-sizing: border-box; | 262 | box-sizing: border-box; |
223 | display: flex; | 263 | display: flex; |
224 | flex-direction: row; | 264 | flex-direction: row; |
225 | justify-content: space-between; | 265 | justify-content: space-between; |
226 | align-items: flex-start; | 266 | align-items: flex-start; |
227 | .info{ | 267 | .info{ |
228 | display: flex; | 268 | display: flex; |
229 | flex-direction: row; | 269 | flex-direction: row; |
230 | justify-content: space-between; | 270 | justify-content: space-between; |
231 | align-items: center; | 271 | align-items: center; |
232 | image{ | 272 | image{ |
233 | border-radius: 50rpx; | 273 | border-radius: 50rpx; |
234 | height: 100rpx ; | 274 | height: 100rpx ; |
235 | width: 100rpx; | 275 | width: 100rpx; |
236 | margin-right: 40rpx; | 276 | margin-right: 40rpx; |
237 | } | 277 | } |
238 | .infoText{ | 278 | .infoText{ |
239 | display: flex; | 279 | display: flex; |
240 | flex-direction: column; | 280 | flex-direction: column; |
241 | justify-content: space-between; | 281 | justify-content: space-between; |
242 | align-items: flex-scetart; | 282 | align-items: flex-scetart; |
243 | .userName{ | 283 | .userName{ |
244 | font-size: 18px; | 284 | font-size: 18px; |
245 | color: #FFFFFF; | 285 | color: #FFFFFF; |
246 | margin-bottom: 8rpx; | 286 | margin-bottom: 8rpx; |
247 | } | 287 | } |
248 | .nickName{ | 288 | .nickName{ |
249 | font-size: 12px; | 289 | font-size: 12px; |
250 | color: #FFFFFF; | 290 | color: #FFFFFF; |
251 | } | 291 | } |
252 | } | 292 | } |
253 | } | 293 | } |
254 | // .service{ | 294 | // .service{ |
255 | // margin-top: 20rpx; | 295 | // margin-top: 20rpx; |
256 | // image{ | 296 | // image{ |
257 | // height: 36rpx; | 297 | // height: 36rpx; |
258 | // width: 36rpx; | 298 | // width: 36rpx; |
259 | // } | 299 | // } |
260 | // } | 300 | // } |
261 | } | 301 | } |
262 | .myOpticsData{ | 302 | .myOpticsData{ |
263 | width: 670rpx; | 303 | width: 670rpx; |
264 | height: 120rpx; | 304 | height: 120rpx; |
265 | background-color: #FFFFFF; | 305 | background-color: #FFFFFF; |
266 | border-radius: 6px; | 306 | border-radius: 6px; |
267 | box-shadow: 1px 1px 7px 0 rgba(133,107,107,0.10); | 307 | box-shadow: 1px 1px 7px 0 rgba(133,107,107,0.10); |
268 | position: relative; | 308 | position: relative; |
269 | bottom: 44rpx; | 309 | bottom: 44rpx; |
270 | padding: 40rpx; | 310 | padding: 40rpx; |
271 | box-sizing: border-box; | 311 | box-sizing: border-box; |
272 | display: flex; | 312 | display: flex; |
273 | justify-content: space-between; | 313 | justify-content: space-between; |
274 | align-items: center; | 314 | align-items: center; |
275 | .left{ | 315 | .left{ |
276 | font-size: 14px; | 316 | font-size: 14px; |
277 | color: #333333; | 317 | color: #333333; |
278 | display: flex; | 318 | display: flex; |
279 | align-items: center; | 319 | align-items: center; |
280 | image{ | 320 | image{ |
281 | margin-right: 32rpx; | 321 | margin-right: 32rpx; |
282 | width: 30rpx; | 322 | width: 30rpx; |
283 | height: 34rpx; | 323 | height: 34rpx; |
284 | } | 324 | } |
285 | } | 325 | } |
286 | image{ | 326 | image{ |
287 | height: 16px; | 327 | height: 16px; |
288 | width: 8px; | 328 | width: 8px; |
289 | } | 329 | } |
290 | } | 330 | } |
291 | .myOrder{ | 331 | .myOrder{ |
292 | width: 100%; | 332 | width: 100%; |
293 | height: 296rpx; | 333 | height: 296rpx; |
294 | // margin-top: 116rpx; | 334 | // margin-top: 116rpx; |
295 | margin-bottom: 20rpx; | 335 | margin-bottom: 20rpx; |
296 | padding: 0 40rpx; | 336 | padding: 0 40rpx; |
297 | box-sizing: border-box; | 337 | box-sizing: border-box; |
298 | background: #FFFFFF; | 338 | background: #FFFFFF; |
299 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); | 339 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); |
300 | border-radius: 6px; | 340 | border-radius: 6px; |
301 | border-radius: 6px; | 341 | border-radius: 6px; |
302 | display: flex; | 342 | display: flex; |
303 | flex-direction: column; | 343 | flex-direction: column; |
304 | justify-content: space-around; | 344 | justify-content: space-around; |
305 | align-items: center; | 345 | align-items: center; |
306 | .orderHeader{ | 346 | .orderHeader{ |
307 | width: 100%; | 347 | width: 100%; |
308 | height: 100rpx; | 348 | height: 100rpx; |
309 | display: flex; | 349 | display: flex; |
310 | flex-direction: row; | 350 | flex-direction: row; |
311 | justify-content: space-between; | 351 | justify-content: space-between; |
312 | align-items: center; | 352 | align-items: center; |
313 | border-bottom: 1px solid #E9E9E9;; | 353 | border-bottom: 1px solid #E9E9E9;; |
314 | font-weight: bold; | 354 | font-weight: bold; |
315 | font-size: 18px; | 355 | font-size: 18px; |
316 | color: #333333; | 356 | color: #333333; |
317 | .btn{ | 357 | .btn{ |
318 | font-size: 12px; | 358 | font-size: 12px; |
319 | color: #999999; | 359 | color: #999999; |
320 | display: flex; | 360 | display: flex; |
321 | align-items: center; | 361 | align-items: center; |
322 | image{ | 362 | image{ |
323 | margin-left: 20rpx; | 363 | margin-left: 20rpx; |
324 | height: 32rpx; | 364 | height: 32rpx; |
325 | width: 16rpx; | 365 | width: 16rpx; |
326 | } | 366 | } |
327 | } | 367 | } |
328 | } | 368 | } |
329 | .orderBody{ | 369 | .orderBody{ |
330 | width: 100%; | 370 | width: 100%; |
331 | display: flex; | 371 | display: flex; |
332 | flex-direction: row; | 372 | flex-direction: row; |
333 | justify-content: space-around; | 373 | justify-content: space-around; |
334 | align-items: center; | 374 | align-items: center; |
335 | .item{ | 375 | .item{ |
336 | display: flex; | 376 | display: flex; |
337 | flex-direction: column; | 377 | flex-direction: column; |
338 | align-items: center; | 378 | align-items: center; |
339 | image{ | 379 | image{ |
340 | width: 62rpx; | 380 | width: 62rpx; |
341 | height: 46rpx; | 381 | height: 46rpx; |
342 | } | 382 | } |
343 | text{ | 383 | text{ |
344 | margin-top: 24rpx; | 384 | margin-top: 24rpx; |
345 | font-size: 12px; | 385 | font-size: 12px; |
346 | color: #333333; | 386 | color: #333333; |
347 | } | 387 | } |
348 | } | 388 | } |
349 | } | 389 | } |
350 | } | 390 | } |
351 | .someItem{ | 391 | .someItem{ |
352 | width: 100%; | 392 | width: 100%; |
353 | height: 336rpx; | 393 | height: 336rpx; |
354 | background: #FFFFFF; | 394 | background: #FFFFFF; |
355 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); | 395 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); |
356 | border-radius: 6px; | 396 | border-radius: 6px; |
357 | border-radius: 6px; | 397 | border-radius: 6px; |
358 | margin-bottom: 18rpx; | 398 | margin-bottom: 18rpx; |
359 | box-sizing: border-box; | 399 | box-sizing: border-box; |
360 | padding: 21rpx 48rpx 21rpx 42rpx; | 400 | padding: 21rpx 48rpx 21rpx 42rpx; |
361 | box-sizing: border-box; | 401 | box-sizing: border-box; |
362 | display: flex; | 402 | display: flex; |
363 | flex-direction: column; | 403 | flex-direction: column; |
364 | justify-content: space-between; | 404 | justify-content: space-between; |
365 | align-items: center; | 405 | align-items: center; |
366 | .item{ | 406 | .item{ |
367 | display: flex; | 407 | display: flex; |
368 | justify-content: space-between; | 408 | justify-content: space-between; |
369 | border-bottom: 1px solid #F2F2F2;; | 409 | border-bottom: 1px solid #F2F2F2;; |
370 | align-items: center; | 410 | align-items: center; |
371 | height: 72rpx; | 411 | height: 72rpx; |
372 | width: 100%; | 412 | width: 100%; |
373 | .left{ | 413 | .left{ |
374 | font-size: 14px; | 414 | font-size: 14px; |
375 | color: #333333; | 415 | color: #333333; |
376 | display: flex; | 416 | display: flex; |
377 | align-items: center; | 417 | align-items: center; |
378 | image{ | 418 | image{ |
379 | margin-right: 32rpx; | 419 | margin-right: 32rpx; |
380 | width: 30rpx; | 420 | width: 30rpx; |
381 | height: 34rpx; | 421 | height: 34rpx; |
382 | } | 422 | } |
383 | } | 423 | } |
384 | image{ | 424 | image{ |
385 | height: 16px; | 425 | height: 16px; |
386 | width: 8px; | 426 | width: 8px; |
387 | } | 427 | } |
388 | } | 428 | } |
389 | 429 | ||
390 | } | 430 | } |
391 | .recommend{ | 431 | .recommend{ |
392 | background: #FFFFFF; | 432 | background: #FFFFFF; |
393 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); | 433 | box-shadow: 0 0 4px 0 rgba(133,107,107,0.10); |
394 | border-radius: 6px; | 434 | border-radius: 6px; |
395 | border-radius: 6px; | 435 | border-radius: 6px; |
396 | width: 100%; | 436 | width: 100%; |
397 | .title{ | 437 | .title{ |
398 | display: flex; | 438 | display: flex; |
399 | flex-direction: row; | 439 | flex-direction: row; |
400 | align-items: center; | 440 | align-items: center; |
401 | justify-content: space-between; | 441 | justify-content: space-between; |
402 | padding: 20rpx 40rpx; | 442 | padding: 20rpx 40rpx; |
403 | .line{ | 443 | .line{ |
404 | width: 264rpx; | 444 | width: 264rpx; |
405 | height: 1rpx; | 445 | height: 1rpx; |
406 | border-bottom: 1px solid #EAEAEA; | 446 | border-bottom: 1px solid #EAEAEA; |
407 | } | 447 | } |
408 | .text{ | 448 | .text{ |
409 | font-family: PingFangSC-Medium; | 449 | font-family: PingFangSC-Medium; |
410 | font-size: 14px; | 450 | font-size: 14px; |
411 | color: #333333; | 451 | color: #333333; |
412 | letter-spacing: -0.26px; | 452 | letter-spacing: -0.26px; |
413 | text-align: justify; | 453 | text-align: justify; |
414 | line-height: 24px; | 454 | line-height: 24px; |
415 | } | 455 | } |
416 | } | 456 | } |
417 | .goods-list{ | 457 | .goods-list{ |
418 | .loading-text{ | 458 | .loading-text{ |
419 | width: 100%; | 459 | width: 100%; |
420 | display: flex; | 460 | display: flex; |
421 | justify-content: center; | 461 | justify-content: center; |
422 | align-items: center; | 462 | align-items: center; |
423 | height: 30px; | 463 | height: 30px; |
424 | color: #979797; | 464 | color: #979797; |
425 | font-size: 12px; | 465 | font-size: 12px; |
426 | } | 466 | } |
427 | .product-list{ | 467 | .product-list{ |
428 | width: 92%; | 468 | width: 92%; |
429 | padding: 0 4% 3vw 4%; | 469 | padding: 0 4% 3vw 4%; |
430 | display: flex; | 470 | display: flex; |
431 | height: 200px; | 471 | height: 200px; |
432 | justify-content: space-between; | 472 | justify-content: space-between; |
433 | flex-wrap: wrap; | 473 | flex-wrap: wrap; |
434 | .product{ | 474 | .product{ |
435 | width: 48%; | 475 | width: 48%; |
436 | margin: 0 0 20rpx 0; | 476 | margin: 0 0 20rpx 0; |
437 | background: #FFFFFF; | 477 | background: #FFFFFF; |
438 | border: 1px solid #F2F2F2; | 478 | border: 1px solid #F2F2F2; |
439 | } | 479 | } |
440 | } | 480 | } |
441 | } | 481 | } |
442 | } | 482 | } |
443 | .auth { | 483 | .auth { |
444 | height: 100vh; | 484 | height: 100vh; |
445 | display: flex; | 485 | display: flex; |
446 | flex-direction: column; | 486 | flex-direction: column; |
447 | align-items: center; | 487 | align-items: center; |
448 | .icon { | 488 | .icon { |
449 | width: 140rpx; | 489 | width: 140rpx; |
450 | height: 140rpx; | 490 | height: 140rpx; |
451 | border-radius: 50%; | 491 | border-radius: 50%; |
452 | margin-top: 100rpx; | 492 | margin-top: 100rpx; |
453 | background-color: grey; | 493 | background-color: grey; |
454 | } | 494 | } |
455 | .divider { | 495 | .divider { |
456 | height: 1rpx; | 496 | height: 1rpx; |
457 | width: 600rpx; | 497 | width: 600rpx; |
458 | margin-top: 80rpx; | 498 | margin-top: 80rpx; |
459 | background-color: #E6E3E3; | 499 | background-color: #E6E3E3; |
460 | } | 500 | } |
461 | .title { | 501 | .title { |
462 | width: 600rpx; | 502 | width: 600rpx; |
463 | margin-top: 50rpx; | 503 | margin-top: 50rpx; |
464 | text-align: left; | 504 | text-align: left; |
465 | } | 505 | } |
466 | .text { | 506 | .text { |
467 | width: 600rpx; | 507 | width: 600rpx; |
468 | margin-top: 30rpx; | 508 | margin-top: 30rpx; |
469 | text-align: left; | 509 | text-align: left; |
470 | color: #E6E3E3; | 510 | color: #E6E3E3; |
471 | } | 511 | } |
472 | button { | 512 | button { |
473 | width: 450rpx; | 513 | width: 450rpx; |
474 | height: 80rpx; | 514 | height: 80rpx; |
475 | line-height: 80rpx; | 515 | line-height: 80rpx; |
476 | margin-top: 80rpx; | 516 | margin-top: 80rpx; |
477 | border-radius: 30rpx; | 517 | border-radius: 30rpx; |
478 | } | 518 | } |
479 | } | 519 | } |
520 | |||
521 | .popUpWrap{ | ||
522 | height: 200rpx; | ||
523 | width: 542rpx; | ||
524 | background-color: #FFFFFF; | ||
525 | border-radius: 4px; | ||
526 | border: 1px solid #979797; | ||
527 | display: flex; | ||
528 | align-items: center; | ||
529 | justify-items: center; | ||
530 | box-sizing: border-box; | ||
531 | padding: 0 20rpx; | ||
532 | text{ | ||
533 | font-size: 12px; | ||
534 | color: #333333; | ||
535 | } | ||
536 | button{ | ||
537 | width: 150rpx; | ||
538 | height: 80rpx; | ||
539 | border-radius: 4px; | ||
540 | text-align: center; | ||
541 | line-height: 80rpx; | ||
542 | font-size: 14px; | ||
543 | |||
544 | } | ||
545 | } | ||
546 | .closeBtn{ | ||
547 | height: 28rpx; | ||
548 | width: 28rpx; | ||
549 | // border: 1px solid red; | ||
550 | position: absolute; | ||
551 | top: 20rpx; | ||
552 | right: 10rpx; | ||
553 | } | ||
554 | |||
480 | 555 | ||
481 | </style> | 556 | </style> |
482 | 557 |
src/store/modules/myLoveList.js
1 | import urlAlias from '../url'; | 1 | import urlAlias from '../url'; |
2 | import request from '../request'; | 2 | import request from '../request'; |
3 | 3 | ||
4 | const { | 4 | const { |
5 | mylovelist | 5 | mylovelist, |
6 | myloveadd, | ||
7 | myloveupdate | ||
6 | } = urlAlias; | 8 | } = urlAlias; |
7 | 9 | ||
8 | const state = { | 10 | const state = { |
9 | loveList: [], | 11 | loveList: [], |
10 | }; | 12 | }; |
11 | 13 | ||
12 | const mutations = { | 14 | const mutations = { |
13 | INIT: (state, data) => { | 15 | INIT: (state, data) => { |
14 | state.loveList = data; | 16 | state.loveList = data; |
15 | }, | 17 | }, |
18 | // 更新关心人验光单 | ||
19 | UPDATE:(state, data) => { | ||
20 | // state.loveList.push(data) | ||
21 | // console.log('UPDATA=====>',data) | ||
22 | } | ||
16 | }; | 23 | }; |
17 | 24 | ||
18 | const actions = { | 25 | const actions = { |
19 | getLoveList({ commit }, param) { | 26 | getLoveList({ commit }, param) { |
20 | request({ | 27 | request({ |
21 | url: mylovelist, | 28 | url: mylovelist, |
22 | data: param, | 29 | data: param, |
23 | success: (res) => { | 30 | success: (res) => { |
24 | // console.log(res.data); | 31 | // console.log(res.data); |
25 | commit("INIT", res.data.data); | 32 | commit("INIT", res.data.data); |
26 | }, | 33 | }, |
27 | }) | 34 | }) |
28 | } | 35 | }, |
36 | addMylove({ commit }, param) { | ||
37 | |||
38 | console.log('myloveupdate-parm====>',param) | ||
39 | request({ | ||
40 | url: myloveadd, | ||
41 | data: param, | ||
42 | success: (res) => { | ||
43 | console.log('addMylove-parm====>',param) | ||
44 | console.log(res.data); | ||
45 | // commit("ADD", args); | ||
46 | }, | ||
47 | }) | ||
48 | }, | ||
49 | updateMylove({ commit }, param) { | ||
50 | request({ | ||
51 | url: myloveupdate, | ||
52 | data: param, | ||
53 | success: (res) => { | ||
54 | console.log('myloveupdate-parm====>',param) | ||
55 | console.log(res); | ||
56 | // commit("UPDATE", param); | ||
57 | }, | ||
58 | }) | ||
59 | }, | ||
60 | |||
29 | } | 61 | } |
30 | 62 | ||
31 | export default { | 63 | export default { |
32 | namespaced: true, | 64 | namespaced: true, |
33 | state, | 65 | state, |
34 | mutations, | 66 | mutations, |
35 | actions, | 67 | actions, |
36 | } | 68 | } |
src/store/url.js
1 | const urlAlias = { | 1 | const urlAlias = { |
2 | // 详情 | 2 | // 详情 |
3 | read: '/app/prod/read', // 获取商品信息 | 3 | read: '/app/prod/read', // 获取商品信息 |
4 | 4 | ||
5 | // 首页 | 5 | // 首页 |
6 | shopList: '/app/prod/list', // 获取首页商品列表 | 6 | shopList: '/app/prod/list', // 获取首页商品列表 |
7 | category: '/app/prod/category2', // 获取首页商品分类 | 7 | category: '/app/prod/category2', // 获取首页商品分类 |
8 | search: '/app/prod/search', // 首页搜索商品 | 8 | search: '/app/prod/search', // 首页搜索商品 |
9 | 9 | ||
10 | // 登陆 | 10 | // 登陆 |
11 | login: '/app/glass/getOpenId', // 登陆 | 11 | login: '/app/glass/getOpenId', // 登陆 |
12 | getUserInfo: '/app/glass/userinfo', // 获取用户信息 | 12 | getUserInfo: '/app/glass/userinfo', // 获取用户信息 |
13 | 13 | ||
14 | // 我的订单 | 14 | // 我的订单 |
15 | orderList: '/app/order/list', // 获取订单列表 | 15 | orderList: '/app/order/list', // 获取订单列表 |
16 | myOrderList: '/app/order/list3', // 获取订单列表 | 16 | myOrderList: '/app/order/list3', // 获取订单列表 |
17 | orderRead: '/app/order/read', // 获取订单详情 | 17 | orderRead: '/app/order/read', // 获取订单详情 |
18 | cancelOrder: '/app/order/wait/del', // 取消订单 | 18 | cancelOrder: '/app/order/wait/del', // 取消订单 |
19 | statusConfirm: '/app/order/statusConfirm', // 订单操作 | 19 | statusConfirm: '/app/order/statusConfirm', // 订单操作 |
20 | payLog: '/app/pay/log', // 调起支付 | 20 | payLog: '/app/pay/log', // 调起支付 |
21 | 21 | ||
22 | // 购物车 | 22 | // 购物车 |
23 | cartList: '/app/cart/list', // 获取购物车列表 | 23 | cartList: '/app/cart/list', // 获取购物车列表 |
24 | cartModi: '/app/cart/modi', // 修改购物车 | 24 | cartModi: '/app/cart/modi', // 修改购物车 |
25 | cartDel: '/app/cart/del', // 删除购物车 | 25 | cartDel: '/app/cart/del', // 删除购物车 |
26 | cartAdd: '/app/cart/add', // 添加购物车 | 26 | cartAdd: '/app/cart/add', // 添加购物车 |
27 | 27 | ||
28 | // 我的 | 28 | // 我的 |
29 | recommandList: '/app/prod/recommand', // 获取用户个性化推荐商品 | 29 | recommandList: '/app/prod/recommand', // 获取用户个性化推荐商品 |
30 | 30 | ||
31 | // 镜框选购页 | 31 | // 镜框选购页 |
32 | detailStandardList: '/app/prod/read', // 获取商品的详细信息 | 32 | detailStandardList: '/app/prod/read', // 获取商品的详细信息 |
33 | // 选购页 | 33 | // 选购页 |
34 | detailStandardUrl: '/app/prod/read', // 获取商品的详细信息 | 34 | detailStandardUrl: '/app/prod/read', // 获取商品的详细信息 |
35 | 35 | ||
36 | // 地址管理 | 36 | // 地址管理 |
37 | editAddress: '/app/address/edit_address', // 编辑地址 | 37 | editAddress: '/app/address/edit_address', // 编辑地址 |
38 | addressList: '/app/address/get_address_list', // 获取用户地址列表 | 38 | addressList: '/app/address/get_address_list', // 获取用户地址列表 |
39 | getAddress: '/app/address/get_address_by_id', // 获取用户某一地址信息 | 39 | getAddress: '/app/address/get_address_by_id', // 获取用户某一地址信息 |
40 | 40 | ||
41 | // 用户数据 | 41 | // 用户数据 |
42 | mylovelist: '/app/user/mylovelist', // 关心的人的数据 | 42 | mylovelist: '/app/user/mylovelist', // 关心的人的数据 |
43 | myloveadd: '/app/user/myloveadd' // 添加关心的人 | 43 | myloveadd: '/app/user/myloveadd', // 添加关心的人 |
44 | myloveupdate: '/app/user/myloveupdate' // 更新关心人的数据 | ||
44 | } | 45 | } |
45 | 46 | ||
46 | export default urlAlias | 47 | export default urlAlias |
47 | 48 |