Blame view

src/components/BottomSheet/BottomSheet.vue 46.9 KB
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
1
  <template>
22e1420fa   BigBoss   弹窗组件修改
2
  	<view class="BottomSheetContent">
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
3
4
  		<view class="sheet" :class="{sheetShow:isShowBottom,sheeHide:!isShowBottom}"    @touchmove.stop.prevent="moveHandle"  @click="closeSheet()">
  			<scroll-view scroll-y="true"  class="sheetView"   :class="{sheetView_active:isShowBottom}"   @click.stop="stopEvent()" >
22e1420fa   BigBoss   弹窗组件修改
5
  				<view class="BottomSheetContent">
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
6
7
8
  				  <view class="goodInfo">
  				    <view class="imageWrap">
  				      <image
22e1420fa   BigBoss   弹窗组件修改
9
  				        :src="skuItem.pic"
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
10
11
  				        mode="aspectFill"
  				        style="width: 188rpx;height: 168rpx;"
22e1420fa   BigBoss   弹窗组件修改
12
  						
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
13
  				      ></image>
22e1420fa   BigBoss   弹窗组件修改
14
  					 
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
15
16
17
18
19
  				    </view>
  				    <view class="infoRight">
  				      <text class="goodName">{{goodInfo.p_name}}</text>
  				      <text class="remarks">支持7天无理由退货  顺丰发货</text>
  				      <view class="priceBox">
22e1420fa   BigBoss   弹窗组件修改
20
  				        <view class="price">¥{{skuItem.real_price || '暂无'}}</view>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
  				        <text>(限购{{maxCount}}副)</text>
  				        <view class="counter">
  				          <view
  				            class="btn"
  				            disabled="this.addDisabled"
  				            type="default"
  				            @click="counter(false)"
  				          >-</view>
  				          <text>{{count}}</text>
  				          <view
  				            class="btn"
  				            disabled="this.desDisabled"
  				            type="default"
  				            @click="counter(true)"
  				          >+</view>
  				        </view>
  				      </view>
  				    </view>
  				  </view>
  				  <view class="peopleChoose">
  					  <view class="title">选择使用人</view>
  					  <view class="loveList">
  					  	<view class="peopleName" v-for="(item,index) in loveList" :key='index' :class="{ active2: loveCurrent === index }"
  				                @click="onClickLoveItem(index,item.name)">
  					  		{{item.name}}
  					  	</view>
  					  </view>
  				  </view>
22e1420fa   BigBoss   弹窗组件修改
49
  				  <view class="goods-data" v-if="isCart !== 3">
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
50
51
52
53
54
  				    <view class="opCollapse">
  				      <view class="body">
  				        <template v-if="opIsOpen">
  				    <view class="goods-form">
  				      <view class="p1">
22e1420fa   BigBoss   弹窗组件修改
55
  				        <image class="image2" src="../../static/img/myOpticsData/dataWrite.png" mode="aspectFit"></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
  				        填写验光数据
  				      </view>
  				      <text class="p2">没有验光数据?请到线下眼镜店验光哦~</text>
  				      <view class="picker">
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="pd">验光单取名:</text>
  				          </view>
  				          <input type="text" @blur="handleInput" class="input"
  				          placeholder="请输入名称" maxlength="20" :value="name" />
  				        </view>
  				      </view>
  				      <view class="picker" >
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="p11">{{pickerInfoList[0].nameC}}</text>
  				            <text class="p12">{{pickerInfoList[0].nameE}}</text>
  				          </view>
  				          <text class="p13">左&nbsp;&nbsp;&nbsp;(OD)</text>
  				          <!-- <text class="p14">{{pickerInfoList[0].nameArray1[pickerInfoList[0].nameIndex1]}}</text> -->
  				          <picker  @change="bindPickerChange01" :value="pickerInfoList[0].nameIndex1" :range="pickerInfoList[0].nameArray1">
  				            <view class="p14">
  				            {{pickerInfoList[0].nameArray1[pickerInfoList[0].nameIndex1]}}
22e1420fa   BigBoss   弹窗组件修改
79
  				            <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
80
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
81
  				            <!-- <image src="../../static/detail-tabicon.png" ></image> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
82
83
84
85
86
87
  				          </picker>
  				          <text class="p13">右&nbsp;&nbsp;&nbsp;(OS)</text>
  				          <!-- <text class="p14">{{pickerInfoList[0].nameArray2[pickerInfoList[0].nameIndex2]}}</text> -->
  				          <picker @change="bindPickerChange02" :value="pickerInfoList[0].nameIndex2" :range="pickerInfoList[0].nameArray2">
  				            <view class="p14">
  				            {{pickerInfoList[0].nameArray2[pickerInfoList[0].nameIndex2]}}
22e1420fa   BigBoss   弹窗组件修改
88
  				            <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
89
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
90
  				            <!-- <image src="../../static/detail-tabicon.png" ></image> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
91
92
93
94
95
96
97
98
99
100
101
102
103
104
  				          </picker>
  				        </view>
  				      </view>
  				      <view class="picker" >
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="p11">{{pickerInfoList[1].nameC}}</text>
  				            <text class="p12">{{pickerInfoList[1].nameE}}</text>
  				          </view>
  				          <text class="p13">左&nbsp;&nbsp;&nbsp;(OD)</text>
  				          <!-- <text class="p14">{{pickerInfoList[1].nameArray1[pickerInfoList[1].nameIndex1]}}</text> -->
  				          <picker @change="bindPickerChange11" :value="pickerInfoList[1].nameIndex1" :range="pickerInfoList[1].nameArray1">
  				            <view class="p14">
  				              {{pickerInfoList[1].nameArray1[pickerInfoList[1].nameIndex1]}}
22e1420fa   BigBoss   弹窗组件修改
105
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
106
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
107
  				            <!-- <image src="../../static/detail-tabicon.png" ></image> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
108
109
110
111
112
113
  				          </picker>
  				          <text class="p13">右&nbsp;&nbsp;&nbsp;(OS)</text>
  				          <!-- <text class="p14">{{pickerInfoList[1].nameArray2[pickerInfoList[1].nameIndex2]}}</text> -->
  				          <picker @change="bindPickerChange12" :value="pickerInfoList[1].nameIndex2" :range="pickerInfoList[1].nameArray2">
  				            <view class="p14">
  				              {{pickerInfoList[1].nameArray2[pickerInfoList[1].nameIndex2]}}
22e1420fa   BigBoss   弹窗组件修改
114
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
115
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
116
  				            <!-- <image src="../../static/detail-tabicon.png" ></image> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
117
118
119
120
121
122
123
124
125
126
127
128
129
  				          </picker>
  				        </view>
  				      </view>
  				      <view class="picker" >
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="p11">{{pickerInfoList[2].nameC}}</text>
  				            <text class="p12">{{pickerInfoList[2].nameE}}</text>
  				          </view>
  				          <text class="p13">左&nbsp;&nbsp;&nbsp;(OD)</text>
  				          <picker @change="bindPickerChange21" :value="pickerInfoList[2].nameIndex1" :range="pickerInfoList[2].nameArray1">
  				            <view class="p14">
  				              {{pickerInfoList[2].nameArray1[pickerInfoList[2].nameIndex1]}}
22e1420fa   BigBoss   弹窗组件修改
130
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
131
132
133
134
135
136
137
  				            </view>
  				          </picker>
  				          <text class="p13">右&nbsp;&nbsp;&nbsp;(OS)</text>
  				          <!-- <text class="p14">{{pickerInfoList[2].nameArray2[pickerInfoList[2].nameIndex2]}}</text> -->
  				          <picker @change="bindPickerChange22" :value="pickerInfoList[2].nameIndex2" :range="pickerInfoList[2].nameArray2">
  				            <view class="p14">
  				              {{pickerInfoList[2].nameArray2[pickerInfoList[2].nameIndex2]}}
22e1420fa   BigBoss   弹窗组件修改
138
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
139
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
140
  				            <!-- <image src="../../static/detail-tabicon.png" ></image> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
  				          </picker>
  				        </view>
  				      </view>
  				      <view class="picker">
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="pd">瞳距:</text>
  				          </view>
  				          <input type="digit" @change="handleInputPd" class="input"
  				          placeholder="请输入瞳距,单位cm" maxlength="20" :value="pd" />
  				        </view>
  				      </view>
  				      <view class="picker" >
  				        <view class="picker-choice">
  				          <view class="choice-left">
  				            <text class="p11">{{pickerInfoList[3].nameC}}</text>
  				          </view>
  				          <text class="p13-date">年&nbsp;&nbsp;&nbsp;(Y)</text>
  				          <picker @change="bindPickerChange41" :value="pickerInfoList[3].nameIndex1" :range="pickerInfoList[3].nameArray1">
  				            <view class="p14" style="width: 30px;">
  				              {{pickerInfoList[3].nameArray1[pickerInfoList[3].nameIndex1]}}
22e1420fa   BigBoss   弹窗组件修改
162
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
163
164
165
166
167
168
  				            </view>
  				          </picker>
  				          <text class="p13-date">月&nbsp;&nbsp;&nbsp;(M)</text>
  				          <picker @change="bindPickerChange42" :value="pickerInfoList[3].nameIndex2" :range="pickerInfoList[3].nameArray2">
  				            <view class="p14" style="width: 30px;">
  				              {{pickerInfoList[3].nameArray2[pickerInfoList[3].nameIndex2]}}
22e1420fa   BigBoss   弹窗组件修改
169
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
170
171
172
173
174
175
  				            </view>
  				          </picker>
  				          <text class="p13-date">日&nbsp;&nbsp;&nbsp;(D)</text>
  				          <picker @change="bindPickerChange43" :value="pickerInfoList[3].nameIndex3" :range="pickerInfoList[3].nameArray3">
  				            <view class="p14" style="width: 30px;">
  				              {{pickerInfoList[3].nameArray3[pickerInfoList[3].nameIndex3]}}
22e1420fa   BigBoss   弹窗组件修改
176
  				              <image src="../../static/detail-tabicon.png" ></image>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
177
178
179
180
  				            </view>
  				          </picker>
  				        </view>
  				      </view>
fed83ad11   BigBoss   新增数据
181
182
183
  					  <view class="ipts">
  					  	<view class="inputItem">
  					  		<text class="text">镜片宽度</text>
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
184
  					  		<input class="input" @input="glassInfoInput($event,0)" type="text" :value="glassInfo.glassWidth!=='0'?glassInfo.glassWidth:''" placeholder="请输入镜片宽度"/>
fed83ad11   BigBoss   新增数据
185
186
187
  					  	</view>
  					  	<view class="inputItem">
  					  		<text class="text">鼻梁宽度</text>
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
188
  					  		<input class="input" @input="glassInfoInput($event,1)" type="text" :value="glassInfo.norseWidth!=='0'?glassInfo.norseWidth:''" placeholder="请输入鼻梁宽度"/>
fed83ad11   BigBoss   新增数据
189
190
191
  					  	</view>
  					  	<view class="inputItem">
  					  		<text class="text">镜腿长度</text>
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
192
  					  		<input class="input" @input="glassInfoInput($event,2)" type="text" :value="glassInfo.legWidth!=='0'?glassInfo.legWidth:''" placeholder="请输入镜腿长度"/>
fed83ad11   BigBoss   新增数据
193
194
195
  					  	</view>
  					  	
  					  </view>
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
196
  				    <!--  <view class="confirm">
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
197
198
  				        <image class="image1" :src="confirm ? tabicon[0] : tabicon[1]" @tap="changeConfirm"></image>
  				        <text>确认以上输入信息来源于我的验光数据!</text>
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
199
  				      </view> -->
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
  				    </view>
  				        </template>
  				        <template v-else>
  				          <view
  				            v-for="item in pickerInfoList"
  				            :key="item.key"
  				            class="bodyBox"
  				          >
  				            <template v-if="item.nameC==='验光日期'">
  				              <text class="names">{{item.nameC}}</text>
  				              <text style="margin-right: 5px;">{{item.nameArray1[item.nameIndex1]}}年</text>
  				              <text style="margin-right: 5px;">{{item.nameArray2[item.nameIndex2]}}月</text>
  				              <text>{{item.nameArray3[item.nameIndex2]}}日</text>
  				            </template>
  				            <template v-else>
  				              <template v-if="item.nameC==='度数'">
  				                <text style="display: inline;">*</text>
  				              </template>
  				
  				              <text class="names">{{item.nameC}}</text>
  				              <text style="margin-right: 10px;">左&nbsp;{{item.nameArray1[item.nameIndex1]}}</text>
  				              <text>右&nbsp;{{item.nameArray2[item.nameIndex2]}}</text>
  				            </template>
  				          </view>
  				        </template>
  				      </view>
  				    </view>
  				  </view>
  				  <view class="choose">
  				    <view
  				      class="chooseItem_1_content"
  				      v-for="(item,index) in attrList"
  				      :key="index"
  				    >
  				      <UniCollapse @change="changeShow(index)">
  				        <UniCollapseItem
  				          :open="show[index]"
  				          :title="item.meta_name"
  				          showAnimation=false
  				        >
  				          <view class="chooseItem_1_content">
22e1420fa   BigBoss   弹窗组件修改
241
  				            <view class="itemsWrap" 	v-if="isCart ==3">
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
242
243
244
245
  				              <view
  				                class="item2"
  				                v-for="(one,i) in item.attr"
  				                :key="i"
22e1420fa   BigBoss   弹窗组件修改
246
247
  				                :class="{ active2: current[index] === i}"
  				                @click="cartOnClickItem(index, i,one.aid)"
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
248
249
  				              >{{one.name}}</view>
  				            </view>
22e1420fa   BigBoss   弹窗组件修改
250
251
252
253
254
255
256
257
258
  							<view class="itemsWrap" 	v-else>
  							  <view
  							    class="item2"
  							    v-for="(one,i) in item.attr"
  							    :key="i"
  							    :class="{ active2: current[index] === i }"
  							    @click="cartOnClickItem(index, i,one.aid)"
  							  >{{one.name}}</view>
  							</view>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
259
260
261
262
263
264
265
266
  				          </view>
  				        </UniCollapseItem>
  				      </UniCollapse>
  				      <view
  				        class="chooseRes"
  				        v-show="!show[index]"
  				      >* {{attrList[index].attr[current[index]].name}}</view>
  				    </view>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
267
268
269
  				  </view>
  				  <view
  				    class="button"
0bda9efec   BigBoss   购物车功能修改
270
  				    @click.native="addCart"
22e1420fa   BigBoss   弹窗组件修改
271
  					v-if="isCart == 1"
0bda9efec   BigBoss   购物车功能修改
272
273
274
275
276
  				  >
  				    加入购物车
  				  </view>
  				  <view
  				    class="button"
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
277
  				    @click="toComfirmOrder"
22e1420fa   BigBoss   弹窗组件修改
278
  					v-if="isCart == 2"
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
279
280
281
  				  >
  				    立即结算
  				  </view>
22e1420fa   BigBoss   弹窗组件修改
282
283
284
285
286
287
288
  				  <view
  				    class="button"
  				    @click="comfirmChoose"
  				  	v-if="isCart == 3"
  				  >
  				    确定
  				  </view>
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
  				</view>
  			</scroll-view>
  		</view>
  	</view>
  </template>
  <script>
  import UniCollapse from '@/components/UniCollapse/UniCollapse.vue'
  import UniCollapseItem from '@/components/UniCollapseItem/UniCollapseItem.vue'
  import store from '@/store'
  	export default {
  		components: {
  			UniCollapse,
  			UniCollapseItem,
  		},
  		props: {
  			isShowBottom : Boolean,
  			pid: Number,
22e1420fa   BigBoss   弹窗组件修改
306
307
  			sk_id:String,
  			propMpId:String,
0bda9efec   BigBoss   购物车功能修改
308
  			goodInfo:Object,
22e1420fa   BigBoss   弹窗组件修改
309
310
311
  			isCart:Number,
  			cart_id:Number,
  			index:Number
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
312
313
314
315
316
317
318
319
320
321
322
323
324
  		},
  		data() {
  		  return {
  			loveCurrent:Number,
  		    count: 1,
  		    // pid: 0,
  		    maxCount: 20,
  		    dataName: '', // 验光数据人员名称
  		    isDataName: false, // 是否是已存在的人员数据
  		    dataConfirm: false, // 已确认所输入验光数据
  		    opIsOpen: true,
  		    addDisabled: false,
  		    desDisabled: false,
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
325
  		    current: [],
22e1420fa   BigBoss   弹窗组件修改
326
  		    show: [true,true],
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
327
  		    checkedData: {},
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
328
329
330
331
332
333
334
  		    // 度数相关数据
  		    pickerInfoList: [
  		      { nameC: '度数', nameE: '(SPH)', nameArray1: [''], nameIndex1: 0, nameArray2: [''], nameIndex2: 0, key: 0 },
  		      { nameC: '散光', nameE: '(CYL)', nameArray1: [''], nameIndex1: 0, nameArray2: [''], nameIndex2: 0, key: 1 },
  		      { nameC: '散光轴位', nameE: '(AXI)', nameArray1: [''], nameIndex1: 0, nameArray2: [''], nameIndex2: 0, key: 2 },
  		      { nameC: '验光日期', nameE: '', nameArray1: [''], nameIndex1: 0, nameArray2: ['', 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12], nameIndex2: 0, nameArray3: [''], nameIndex3: 0 },
  		    ],
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
335
336
  		    // confirm: false, // 用户是否确认
  		    // tabicon: ['/static/detail-button.png', '/static/detail-button-unselected.png'],
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
  		    name: '',
  		    oldname: '', // 用于判读用户是否改变名字
  		    pickerInfoChioce: {
  		      leftSph: '',
  		      rightSph: '',
  		      leftCyl: '',
  		      rightCyl: '',
  		      leftAxi: '',
  		      rightAxi: '',
  		      time: {
  		        year: 0,
  		        month: 0,
  		        day: 0,
  		      },
  		    },
fed83ad11   BigBoss   新增数据
352
  			glassInfo:{
fed83ad11   BigBoss   新增数据
353
  				glassWidth:Number,//镜片宽度
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
354
  				norseWidth:Number,//鼻宽
fed83ad11   BigBoss   新增数据
355
356
  				legWidth:Number//镜腿长度
  			},
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
357
358
359
360
  		    pd: '', // 瞳距
  		    oldpd: '', // 用于判断用户是否改变瞳距
  		    kinds: 1, // kinds=1,提交为新增验光,2为修改
  		    mp_id: Number,
22e1420fa   BigBoss   弹窗组件修改
361
362
  			skuValueArray:[],
  			skId:String
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
363
364
365
  		  }
  		},
  		computed: {
22e1420fa   BigBoss   弹窗组件修改
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
  			//进购物车选择的人的index
  			p_current(){
  					const getLoveItemIndex = (item) => item.mp_id == this.propMpId
  					const p_current = this.$store.state.myLoveList.loveList.findIndex(getLoveItemIndex )
  					if(this.isCart == 3){
  						this.loveCurrent = p_current
  					}
  					return p_current
  			},
  			arr_current(){
  				if(this.isCart == 3){
  					const skId = this.sk_id
  					const skuValue = this.skuItem.sku_value
  					const skuValueArray = skuValue.split('_')
  					this.skuValueArray = skuValueArray
  					const attrList = this.$store.state.read.goodInfo.attrList
  					for (let i = 0;i<attrList.length;i++) {
  						const getArrIndex = (item) => item.aid == skuValueArray[i]
  						const arr_current = this.$store.state.read.goodInfo.attrList[i].attr.findIndex(getArrIndex )
  						// console.log('arr_current',arr_current)
  						this.current.push(arr_current) 
  					}
  				}else{
  					return null
  				}
  			},
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
392
  			loveList() {
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
393
394
395
  				return this.$store.state.myLoveList.loveList || []
  			},
  		  attrList() {
22e1420fa   BigBoss   弹窗组件修改
396
  			  // console.log('attrList',this.$store.state.read.goodInfo.attrList)
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
397
398
399
400
401
402
403
404
  			  let attrList =  this.$store.state.read.goodInfo.attrList
  			  if(attrList !== undefined){
  				return attrList
  			  }else{
  				  return []
  			  }
  		  },
  		  skuList() {
22e1420fa   BigBoss   弹窗组件修改
405
  			  // console.log('skuList',this.$store.state.read.goodInfo.skuList)
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
406
407
  		    return this.$store.state.read.goodInfo.skuList
  		  },
22e1420fa   BigBoss   弹窗组件修改
408
409
410
411
412
413
414
415
416
417
418
  		  skuItem(){
  			  // if(this.isCart == 3){
  				  const skuList =  this.$store.state.read.goodInfo.skuList
  				  const skuItem = skuList.filter(item => item.sk_id === this.skId)[0]
  				  return skuItem	
  			  // }else{  
  				 //  const skuList =  this.$store.state.read.goodInfo.skuList
  				 //  const skuItem = skuList[0]
  				 //  return skuItem	
  			  // }
  		  },
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
419
  		  mpList() {
22e1420fa   BigBoss   弹窗组件修改
420
  			
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
421
422
  		    return this.$store.state.myLoveList.loveList
  		  },
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
423
424
425
426
427
  		  glassInfoRight(){
  			const glassInfoArr = Object.values(this.glassInfo)
  			// console.log('glassInfoArr',glassInfoArr.find(item => item == '0'))
  			return glassInfoArr.find(item => item == '0') ==undefined
  		  }
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
428
429
  		},
  		created() {
22e1420fa   BigBoss   弹窗组件修改
430
431
432
  			this.skuValueArray = this.skuList[0].sku_value.split("_")
  			// console.log(this.sk_id)
  			this.mp_id = this.propMpId
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
433
  		  const pid = this.pid
22e1420fa   BigBoss   弹窗组件修改
434
435
436
437
438
439
440
441
442
443
444
445
446
  		  if(this.isCart!==3){
  			this.skId = this.skuList[0].sk_id
  			const current = []
  			const show = []
  			for (let index = 0; index < this.attrList.length; index++) {
  			  current.push(0)
  			  show.push(true)
  			}
  			this.current = current
  			this.show = show
  		  }else{
  			this.skId = this.sk_id
  		  }
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
447
448
449
450
  		  	//获取关心的人列表
  		  	store.dispatch('myLoveList/getLoveList', {
  		  		uid: this.$store.state.user.userInfo.uid,
  		  	}); 
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
  		  // 初始化SPL、CYL、AXI的值
  		  for (let j = 0; j < 3; j++) {
  		    for (let i = -12; i < 6; i++) {
  		      this.pickerInfoList[j].nameArray1.push(i)
  		      this.pickerInfoList[j].nameArray1.push(i + 0.5)
  		      this.pickerInfoList[j].nameArray2.push(i)
  		      this.pickerInfoList[j].nameArray2.push(i + 0.5)
  		      if (i >= -6) {
  		        this.pickerInfoList[j].nameArray1.push(i + 0.25)
  		        this.pickerInfoList[j].nameArray1.push(i + 0.75)
  		        this.pickerInfoList[j].nameArray2.push(i + 0.25)
  		        this.pickerInfoList[j].nameArray2.push(i + 0.75)
  		      }
  		      if (i === 5) {
  		        this.pickerInfoList[j].nameArray1.push(i + 1)
  		        this.pickerInfoList[j].nameArray2.push(i + 1)
  		      }
  		    }
  		  }
  		  // 初始化日期值
  		  for (let i = 1; i < 32; i++) {
  		    this.pickerInfoList[3].nameArray3.push(i)
  		  }
  		  // 初始化年份前后五年
  		  const myDate = new Date()
  		  const nowYear = myDate.getFullYear()
  		  for (let i = 0; i < 5; i++) {
  		    this.pickerInfoList[3].nameArray1.push(nowYear - i)
  		  }
  		},
  		name : "bottomSheet",
  		methods: {
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
483
  			//判断眼镜数据是否为0
fed83ad11   BigBoss   新增数据
484
  			checkGlassInfo(){
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
485
486
487
488
489
490
  				// const glassInfoArr = Object.values(this.glassInfo)
  				// console.log(this.glassInfoRight)
  				if(!this.glassInfoRight){
  					uni.showToast({
  						title:'请完善镜框数据~',
  						icon:'none'
fed83ad11   BigBoss   新增数据
491
492
493
494
495
  					})
  				}
  			},
  			updateMylove(){
  				const loveItem = this.loveList[this.loveCurrent]
a2ff24f94   BigBoss   修改未选择使用人不提示的问题
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
  				// console.log(this.loveList)
  				// console.log(this.loveCurrent)
  				// console.log(loveItem)
  				if(loveItem != undefined){
  					const glassWidth = this.glassInfo.glassWidth
  					const norseWidth = this.glassInfo.norseWidth
  					const legWidth = this.glassInfo.legWidth
  					if(loveItem.glassWidth !== glassWidth){
  						store.dispatch('myLoveList/updateMylove', {
  							uid: this.$store.state.user.userInfo.uid,
  							openid: this.$store.state.user.userInfo.openid,
  							mp_id: this.mp_id,
  							keyname: 'glassWidth',
  							keyvalue: glassWidth
  						}); 
  					}
  					if(loveItem.norseWidth !== norseWidth){
  						store.dispatch('myLoveList/updateMylove', {
  							uid: this.$store.state.user.userInfo.uid,
  							openid: this.$store.state.user.userInfo.openid,
  							mp_id: this.mp_id,
  							keyname: 'norseWidth',
  							keyvalue: norseWidth
  						}); 
  					}
  					if(loveItem.legWidth !== legWidth){
  						store.dispatch('myLoveList/updateMylove', {
  							uid: this.$store.state.user.userInfo.uid,
  							openid: this.$store.state.user.userInfo.openid,
  							mp_id: this.mp_id,
  							keyname: 'legWidth',
  							keyvalue: legWidth
  						}); 
  					}
  				}else{
  					uni.showToast({
  						title:'请选择使用人',
  						icon:'none'
  					})
fed83ad11   BigBoss   新增数据
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
  				}
  			},
  			glassInfoInput(e,type){
  				switch(type){
  					case 0:
  						this.glassInfo.glassWidth = e.detail.value
  					break;
  					case 1:
  						this.glassInfo.norseWidth = e.detail.value
  					break;
  					case 2:
  						this.glassInfo.legWidth = e.detail.value
  					break;
  					default:
  					break;
  				}
  			},
22e1420fa   BigBoss   弹窗组件修改
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
  			//参数点击事件==》改变对应图片
  			cartOnClickItem(index, i,aid) {
  				//根据aid拼接skuValue
  				this.skuValueArray[index] = aid
  				const sku_value = this.skuValueArray.join('_')
  				//根据sku_value获取对应的sk_id
  				const itemSk_id =  this.skuList.filter(item=>item.sku_value == sku_value)[0].sk_id
  				//修改sk_id
  				this.skId = itemSk_id
  			  if (this.current[index] !== i) {
  			    this.current[index] = i
  			  }
  			  this.$forceUpdate()
  			},
  			comfirmChoose(){
fed83ad11   BigBoss   新增数据
567
  				this.checkGlassInfo()
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
568
569
570
571
572
573
  				if(this.glassInfoRight){
  					this.updateMylove()
  					const price = this.skuList.filter(item=>item.sk_id == this.skId)[0].real_price
  					this.$emit("chooseCartModi",this.mp_id,this.skId,price,this.pid,this.count,this.cart_id,this.index)//添加购物车
  					this.$emit("closeBottom")
  				}
22e1420fa   BigBoss   弹窗组件修改
574
  			},
0bda9efec   BigBoss   购物车功能修改
575
  			addCart(){
fed83ad11   BigBoss   新增数据
576
  				this.checkGlassInfo()
a2ff24f94   BigBoss   修改未选择使用人不提示的问题
577
578
579
  				// console.log(this.glassInfoRight)
  				this.updateMylove()
  				if(this.glassInfoRight&&this.mp_id!==''){
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
  					const that = this
  					const checkedSKUName = [that.goodInfo.attrList[0].meta_name,that.goodInfo.attrList[1].meta_name]
  					const checkedSKU = []
  					let j;
  					for (let i = 0;i<that.current.length;i++) {
  						checkedSKU.push(that.goodInfo.attrList[i].attr[that.current[i]])
  						// console.log('i', i, j, i !== this.current.length - 1)
  						  if (i !== this.current.length - 1) {
  						    // 后续需修改算法:目前暂定只有两个参数选择,后续若有多个参数需要修改实现自适应
  						    j = this.current[i] * this.attrList[1].attr.length
  						  } else {
  						    j += this.current[i]
  						  }
  					}
  					const price = this.skuList.filter(item=>item.sk_id == this.skuList[j].sk_id)[0].real_price
  					let sk_id = this.skuList[j].sk_id
  					// console.log('选择的商品sk_id',sk_id,'选择的商品参数',checkedSKU)
  					// console.log('mp_id',this.mp_id,'数量',this.count)
  					this.$emit("addCart",this.mp_id,this.count,checkedSKU,sk_id,price)//添加购物车
  					this.$emit("closeBottom")//关闭弹窗
0bda9efec   BigBoss   购物车功能修改
600
  				}
0bda9efec   BigBoss   购物车功能修改
601
  			},
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
602
603
  			onClickLoveItem(index,name){
  				const loveList = this.loveList
fed83ad11   BigBoss   新增数据
604
605
606
  				this.glassInfo.glassWidth = loveList[index].glassWidth
  				this.glassInfo.norseWidth = loveList[index].norseWidth
  				this.glassInfo.legWidth = loveList[index].legWidth
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
607
608
609
  				for (let index = 0; index < loveList.length; index++) {
  				  if (name === loveList[index].name && name!==this.name) {
  				    this.isDataName = true
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
  				          this.kinds = 2
  				          this.name = loveList[index].name
  				          this.pd = loveList[index].pd
  				          this.mp_id = loveList[index].mp_id
  				          this.oldname = loveList[index].name
  				          this.oldpd = loveList[index].pd
  				          this.pickerInfoList[0].nameArray1.unshift(loveList[index].leftSph)
  				          this.pickerInfoList[0].nameArray2.unshift(loveList[index].rightSph)
  				          this.pickerInfoList[1].nameArray1.unshift(loveList[index].leftCyl)
  				          this.pickerInfoList[1].nameArray2.unshift(loveList[index].rightCyl)
  				          this.pickerInfoList[2].nameArray1.unshift(loveList[index].leftAxi)
  				          this.pickerInfoList[2].nameArray2.unshift(loveList[index].rightAxi)
  				          this.pickerInfoList[3].nameArray1.unshift(loveList[index].in_time.toString().slice(0, 4))
  				          if (loveList[index].in_time.toString().slice(5, 6) === 0) {
  				            this.pickerInfoList[3].nameArray2.unshift(loveList[index].in_time.toString().slice(6, 7))
  				          } else {
  				            this.pickerInfoList[3].nameArray2.unshift(loveList[index].in_time.toString().slice(5, 7))
  				          }
  				          if (loveList[index].in_time.toString().slice(8, 9) === 0) {
  				            this.pickerInfoList[3].nameArray3.unshift(loveList[index].in_time.toString().slice(9, 10))
  				          } else {
  				            this.pickerInfoList[3].nameArray3.unshift(loveList[index].in_time.toString().slice(8, 10))
  				          }
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
  				  }
  				}
  					this.name = name;
  					this.loveCurrent = index;
  			},
  			closeSheet(){					
  				this.$emit('closeBottom');
  			},
  			stopEvent(){						//@click.stop防止事件冒泡
  				
  			},
  			moveHandle(){						//不让页面滚动
  				
  			},
  			// picker相关功能
  			handleInput(e) {
  			  this.name = e.target.value
  			  this.isDataName = false
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
651
652
653
654
655
656
657
658
659
660
661
  			  const mpList = this.mpList
  			  // console.log('mpList===>', mpList)
  			  for (let index = 0; index < mpList.length; index++) {
  			    if (e.detail.value === mpList[index].name) {
  			      this.isDataName = true
  			      uni.showModal({
  			        title: '提示',
  			        content: `是否填充已有的"${e.detail.value}"的数据`,
  			        success: (res) => {
  			          if (res.confirm) {
  			            this.kinds = 2
22e1420fa   BigBoss   弹窗组件修改
662
  			            // console.log('args===>', index)
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
663
  			            // const mpList=Object.assign({},this.$store.state.mympList.mpList)
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
  			            this.name = mpList[index].name
  			            this.pd = mpList[index].pd
  			            this.mp_id = mpList[index].mp_id
  			            this.oldname = mpList[index].name
  			            this.oldpd = mpList[index].pd
  			            // 将kinds =2时的值传到该页面
  			            this.pickerInfoList[0].nameArray1.unshift(mpList[index].leftSph)
  			            this.pickerInfoList[0].nameArray2.unshift(mpList[index].rightSph)
  			            this.pickerInfoList[1].nameArray1.unshift(mpList[index].leftCyl)
  			            this.pickerInfoList[1].nameArray2.unshift(mpList[index].rightCyl)
  			            this.pickerInfoList[2].nameArray1.unshift(mpList[index].leftAxi)
  			            this.pickerInfoList[2].nameArray2.unshift(mpList[index].rightAxi)
  			            this.pickerInfoList[3].nameArray1.unshift(mpList[index].in_time.toString().slice(0, 4))
  			            if (mpList[index].in_time.toString().slice(5, 6) === 0) {
  			              this.pickerInfoList[3].nameArray2.unshift(mpList[index].in_time.toString().slice(6, 7))
  			            } else {
  			              this.pickerInfoList[3].nameArray2.unshift(mpList[index].in_time.toString().slice(5, 7))
  			            }
  			            if (mpList[index].in_time.toString().slice(8, 9) === 0) {
  			              this.pickerInfoList[3].nameArray3.unshift(mpList[index].in_time.toString().slice(9, 10))
  			            } else {
  			              this.pickerInfoList[3].nameArray3.unshift(mpList[index].in_time.toString().slice(8, 10))
  			            }
  			          // this.checkedData = mpList[index]
  			          // console.log('checkedData', this.checkedData)
  			          } else if (res.cancel) {
  			            this.kinds = 2
  			          }
  			        },
  			      })
  			    }
  			  }
  			},
  			handleInputPd(e) {
  			  // 只能输入正浮点数或正数
  			  if (/^\d+(\.\d+)?$/.test(e.target.value)) {
  			    this.pd = e.target.value
  			  } else {
  			    uni.showToast({
  			      title: '请输入有效数据;示例:89',
  			      icon: 'none',
  			      duration: 2000,
  			    })
  			    this.pd = ''
  			  }
  			},
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
710
711
712
  			// changeConfirm() {
  			//   this.confirm = !this.confirm
  			// },
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
  			bindPickerChange01: function(e) {
  			  this.pickerInfoList[0].nameIndex1 = e.target.value
  			  this.pickerInfoChioce.leftSph = this.pickerInfoList[0].nameArray1[e.target.value]
  			},
  			bindPickerChange02: function(e) {
  			  this.pickerInfoList[0].nameIndex2 = e.target.value
  			  this.pickerInfoChioce.rightSph = this.pickerInfoList[0].nameArray2[e.target.value]
  			},
  			
  			bindPickerChange11: function(e) {
  			  this.pickerInfoList[1].nameIndex1 = e.target.value
  			  this.pickerInfoChioce.leftCyl = this.pickerInfoList[1].nameArray1[e.target.value]
  			},
  			bindPickerChange12: function(e) {
  			  this.pickerInfoList[1].nameIndex2 = e.target.value
  			  this.pickerInfoChioce.rightCyl = this.pickerInfoList[1].nameArray2[e.target.value]
  			},
  			
  			bindPickerChange21: function(e) {
  			  this.pickerInfoList[2].nameIndex1 = e.target.value
  			  this.pickerInfoChioce.leftAxi = this.pickerInfoList[2].nameArray1[e.target.value]
  			},
  			bindPickerChange22: function(e) {
  			  this.pickerInfoList[2].nameIndex2 = e.target.value
  			  this.pickerInfoChioce.rightAxi = this.pickerInfoList[2].nameArray2[e.target.value]
  			},
  			
  			bindPickerChange41: function(e) {
  			  this.pickerInfoList[3].nameIndex1 = e.target.value
  			  this.pickerInfoChioce.time.year = this.pickerInfoList[3].nameArray1[e.target.value]
  			},
  			bindPickerChange42: function(e) {
  			  this.pickerInfoList[3].nameIndex2 = e.target.value
  			  this.pickerInfoChioce.time.month = this.pickerInfoList[3].nameArray2[e.target.value]
  			},
  			bindPickerChange43: function(e) {
  			  this.pickerInfoList[3].nameIndex3 = e.target.value
  			  this.pickerInfoChioce.time.day = this.pickerInfoList[3].nameArray3[e.target.value]
  			},
  			changeShow(num) {
  			  this.show[num] = !this.show[num]
  			  this.$forceUpdate()
  			},
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
756
757
758
759
760
761
762
763
  			counter(isadd) {
  			  if (isadd) {
  			    this.count >= this.maxCount ? this.addDisabled = true : this.count++
  			  } else {
  			    this.count <= 1 ? this.desDisabled = true : this.count--
  			  }
  			},
  			toComfirmOrder() {
78ed60987   BigBoss   build下单修改
764
  				this.checkGlassInfo()
fed83ad11   BigBoss   新增数据
765
  				this.updateMylove()
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
  			  // 先处理验光部分的逻辑,如果ok在跳转
  			  let flag = 0
  			  if (this.name === '') {
  			    uni.showToast({
  			      title: '请输入验光单取名',
  			      icon: 'none',
  			      duration: 2000,
  			    })
  			  } else {
  			    if (this.pd === '') {
  			      uni.showToast({
  			        title: '请输入瞳距',
  			        icon: 'none',
  			        duration: 2000,
  			      })
  			    } else {
  			      if (this.kinds === 1) {
  			        // 添加用户验光单
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
784
785
786
787
788
789
790
791
792
793
  			        if (this.pickerInfoChioce.rightSph === '' || this.pickerInfoChioce.leftSph === '' ||
  			        this.pickerInfoChioce.leftCyl === '' || this.pickerInfoChioce.rightCyl === '' ||
  			        this.pickerInfoChioce.leftAxi === '' || this.pickerInfoChioce.rightAxi === ''
  			        ) {
  			          uni.showToast({
  			            title: '请输入您的验光数据',
  			            icon: 'none',
  			            duration: 2000,
  			          })
  			        } else {
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
794
  			          // if (this.confirm) {
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
  			            store.dispatch('myLoveList/addMylove', {
  			              uid: this.$store.state.user.userInfo.uid,
  			              openid: this.$store.state.user.userInfo.openid,
  			              // mp_name: this.$store.state.user.userInfo.mp_name,
  			              leftSph: this.pickerInfoChioce.leftSph,
  			              rightSph: this.pickerInfoChioce.rightSph,
  			              leftCyl: this.pickerInfoChioce.leftCyl,
  			              rightCyl: this.pickerInfoChioce.rightCyl,
  			              leftAxi: this.pickerInfoChioce.leftAxi,
  			              rightAxi: this.pickerInfoChioce.rightAxi,
  			              pd: this.pd, // 瞳距
  			              mp_name: this.name,
  			            // time: this.pickerInfoChioce.time,
  			            // img_url2: "http://localhost:8087/images/shop_1/1/",
  			            }).then(({ mp_id: mpId }) => {
  			              this.mp_id = mpId
  			            })
  			            flag = 1
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
813
814
815
  			        }
  			      }
  			      if (this.kinds === 2) {
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
816
  			        // if (this.confirm) {
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
  			          const leftList = ['leftSph', 'leftCyl', 'leftAxi']
  			          const rightList = ['rightSph', 'rightCyl', 'rightAxi']
  			          // let flag=0;
  			          if (this.name !== this.oldname) {
  			            store.dispatch('myLoveList/updateMylove', {
  			              uid: this.$store.state.user.userInfo.uid,
  			              openid: this.$store.state.user.userInfo.openid,
  			              mp_id: this.mp_id,
  			              keyname: 'name',
  			              keyvalue: this.name,
  			            })
  			            flag = 1
  			          }
  			          if (this.pd !== this.oldpd) {
  			            store.dispatch('myLoveList/updateMylove', {
  			              uid: this.$store.state.user.userInfo.uid,
  			              openid: this.$store.state.user.userInfo.openid,
  			              mp_id: this.mp_id,
  			              keyname: 'pd',
  			              keyvalue: this.pd,
  			            })
  			            flag = 1
  			          }
  			          //  先验证是否输入有无空
  			          let q = true
  			          for (let k = 0; k < 3; k++) {
  			            q = q && (this.pickerInfoList[k].nameArray1[this.pickerInfoList[k].nameIndex1] !== '' &&
  			            this.pickerInfoList[k].nameArray2[this.pickerInfoList[k].nameIndex2] !== '')
  			          }
  			          if (q) {
  			            for (let j = 0; j < 3; j++) {
  			              if (this.pickerInfoList[j].nameIndex1 !== 0) {
  			                store.dispatch('myLoveList/updateMylove', {
  			                  uid: this.$store.state.user.userInfo.uid,
  			                  openid: this.$store.state.user.userInfo.openid,
  			                  mp_id: this.mp_id,
  			                  keyname: leftList[j],
  			                  keyvalue: this.pickerInfoList[j].nameArray1[this.pickerInfoList[j].nameIndex1],
  			                })
  			              }
  			              if (this.pickerInfoList[j].nameIndex2 !== 0) {
  			                store.dispatch('myLoveList/updateMylove', {
  			                  uid: this.$store.state.user.userInfo.uid,
  			                  openid: this.$store.state.user.userInfo.openid,
  			                  mp_id: this.mp_id,
  			                  keyname: rightList[j],
  			                  keyvalue: this.pickerInfoList[j].nameArray2[this.pickerInfoList[j].nameIndex2],
  			                })
  			              }
  			              flag = 1
  			            }
  			          } else {
  			            flag = 0
  			            uni.showToast({
  			              title: '请输入您的验光数据',
  			              icon: 'none',
  			              duration: 2000,
  			            })
  			          }
0df2ead74   BigBoss   确认订单传参修改&新增眼镜数据的录入功能
876
877
878
879
880
881
882
883
  			      
  			        // } else {
  			        //   uni.showToast({
  			        //     title: '请确认您的验光数据',
  			        //     icon: 'none',
  			        //     duration: 3000,
  			        //   })
  			        // }
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
884
885
886
887
888
889
890
891
892
893
894
  			      }
  			    }
  			  }
  			  if (flag !== 0) {
  			    // 如果数据验证无误,那么更新验光单的数据
  			    store.dispatch('myLoveList/getLoveList', {
  			      uid: this.$store.state.user.userInfo.uid,
  			    })
  			    let i = 0
  			    // 判断出是哪一个sku被选中
  			    for (let index = 0; index < this.current.length; index++) {
22e1420fa   BigBoss   弹窗组件修改
895
  			      // console.log('index', index, i, index !== this.current.length - 1)
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
896
897
898
899
900
901
902
903
904
905
906
907
908
909
  			      if (index !== this.current.length - 1) {
  			        // 后续需修改算法:目前暂定只有两个参数选择,后续若有多个参数需要修改实现自适应
  			        i = this.current[index] * this.attrList[1].attr.length
  			      } else {
  			        i += this.current[index]
  			      }
  			    }
  			    // 判断是否其输入的人员数据是否已存在
  			    store.dispatch('order/saveParams', {
  			      sk_id_arr: this.skuList[i],
  			      current: this.current,
  			      mp_id: this.mp_id,
  			      attrList: this.attrList,
  			    })
61d825263   BigBoss   确认订单修改
910
  				this.$store.state.cart.buyItem = this.skuItem
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
911
912
  			    // 跳转到确认订单页面
  			    uni.navigateTo({
61d825263   BigBoss   确认订单修改
913
  			      url: `../confirmOrder/confirmOrder?pid=${this.pid}&count=${this.count}&name=${this.name}&isCart=false`,
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
914
915
916
917
918
919
920
921
  			    })
  			  }
  			},
  		}
  	}
  </script>
  
  <style lang="scss">
22e1420fa   BigBoss   弹窗组件修改
922
  	.BottomSheetContent {
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
923
924
925
926
927
928
929
930
931
932
933
934
935
  	  min-height: 100vh;
  	  background-color: #f2f2f2;
  	  // padding-top: 20rpx;
  	  .goodInfo {
  	    width: 100%;
  	    height: 272rpx;
  	    border-radius: 16rpx;
  	    background-color: #ffffff;
  	    box-sizing: border-box;
  	    padding: 36rpx;
  	    display: flex;
  	    flex-direction: row;
  	    justify-content: flex-start;
22e1420fa   BigBoss   弹窗组件修改
936
937
938
939
  		position: sticky;
  		top: 0rpx;
  		left: 0rpx;
  		z-index: 99999;
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
940
941
942
943
944
945
946
947
948
949
950
951
952
953
  	    .imageWrap {
  	      height: 188rpx;
  	      width: 188rpx;
  	      margin-right: 28rpx;
  	      image {
  	        height: 188rpx;
  	        width: 188rpx;
  	      }
  	    }
  	    .infoRight {
  	      display: flex;
  	      flex-direction: column;
  	      align-items: flex-start;
  	      justify-content: space-between;
22e1420fa   BigBoss   弹窗组件修改
954
  		  width: 100%;
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
  	      .goodName {
  	        font-size: 28rpx;
  	        color: #333333;
  	      }
  	      .remarks {
  	        font-size: 20rpx;
  	        color: #999999;
  	      }
  	      .priceBox {
  	        display: flex;
  	        justify-content: space-between;
  	        align-items: center;
  	        width: 100%;
  	        font-size: 14px;
  	        color: #999999;
  	        .price {
  	          color: #ff6b4a;
  	          font-size: 28rpx;
  	        }
  	        .counter {
  	          display: flex;
  	          flex-direction: row;
  	          justify-content: space-between;
  	          align-items: center;
  	          font-size: 28rpx;
  	          color: #333333;
  	          width: 122rpx;
  	          .btn {
  	            display: flex;
  	            justify-content: center;
  	            line-height: 32rpx;
  	            height: 32rpx;
  	            width: 32rpx;
  	            background-color: #f2f2f2;
  	            color: #cfcfcf;
  	          }
  	        }
  	      }
  	    }
  	  }
  	  .peopleChoose{
  		    width: 100%;
  		    min-height: 200rpx;
  		    border-radius: 16rpx;
  		    background-color: #ffffff;
  		    box-sizing: border-box;
  		    padding: 36rpx;
  			margin: 10px 0;
  		    display: flex;
  		    flex-direction: column;
  		    justify-content: flex-start;
  			align-items: center;
  			.title{
  				font-size: 16px;
  				color: #333333;
  				letter-spacing: -0.3px;
  				text-align: justify;
  				line-height: 24px;
  				margin: 4px 0;
  			}
  			.loveList{
  				display: flex;
  				flex-direction: row;
  				flex-wrap: wrap;
  				justify-content: flex-start;
  				align-items: center;
  				padding-top: 24rpx;
  				width: 100%;
  				.peopleName {
  				  padding: 0 30rpx;
  				  height: 60rpx;
  				  margin: 0 20rpx 20rpx 0;
  				  transition: all 0.3s;
  				  background: #f2f2f2;
  				  border-radius: 2px;
  				  border-radius: 2px;
  				  line-height: 60rpx;
  				  text-align: center;
  				  color: #666666;
  				  font-size: 12px;
  				}
  				.active2 {
  				  background: rgba(255, 107, 74, 0.15);
  				  color: #ff6b4a;
  				}
  			}
  	  }
  	  .goods-data {
  	    width: 100%;
  	    box-sizing: border-box;
  	    padding: 37rpx 40rpx 0 40rpx;
  	    background: #ffffff;
  	    border-radius: 12rpx;
  	    .opCollapse {
  	      width: 100%;
  	      padding-bottom: 28rpx;
  	      margin-top: 7px;
  	      border-bottom: 1px solid #e9e9e9;
  	      .head {
  	        display: flex;
  	        justify-content: space-between;
  	        height: 24px;
  	        // font-family: PingFangSC-Medium;
  	        font-size: 16px;
  	        color: #333333;
  	        letter-spacing: -0.3px;
  	        text-align: justify;
  	        line-height: 24px;
  	        margin-bottom: 18rpx;
  	        .headRighted {
  	          width: 0;
  	          height: 0;
  	          border-left: 4px solid transparent;
  	          border-right: 4px solid transparent;
  	          border-bottom: 4px solid #cfcfcf;
  	          transform: scaleY(-1);
  	          margin-top: 10px;
  	        }
  	        .headMid {
  	          font-size: 10px;
  	          color: #999999;
  	          letter-spacing: -0.19px;
  	          margin-left: -120rpx;
  	        }
  	        .headRight {
  	          width: 0;
  	          height: 0;
  	          border-left: 4px solid transparent;
  	          border-right: 4px solid transparent;
  	          border-bottom: 4px solid #cfcfcf;
  	          margin-top: 10px;
  	        }
  	      }
  	      .body {
  	        font-size: 12px;
  	        color: #666666;
  	        letter-spacing: 0;
  	        .bodyBox {
  	          margin-top: 15px;
  	          .names {
  	            font-size: 12px;
  	            color: #151515;
  	            letter-spacing: 0;
  	            text-align: justify;
  	            line-height: 17px;
  	            margin-left: 5px;
  	            margin-right: 10px;
  	          }
  	          text {
  	            font-size: 12px;
  	            color: #666666;
  	            letter-spacing: 0;
  	            text-align: justify;
  	          }
  	        }
  	      }
  	    .goods-form {
  	      display: flex;
  	      flex-direction: column;
  	      align-items: center;
  	      justify-content: center;
  	      background-color: #fff;
  	        width: 100%;
  	        padding: 40rpx 0;
  	      .p1 {
  	            font-size: 16px;
  	            color: #333333;
  	            letter-spacing: -0.3px;
  	            text-align: justify;
  	            line-height: 24px;
  	            margin: 4px 0;
  	
  	        }
  	        .p2 {
  	            font-size: 12px;
  	            color: #999999;
  	            letter-spacing: -0.23px;
  	            margin-bottom: 32rpx;
  	        }
  	        .image2{
  	            width: 42rpx;
  	            height: 34rpx;
  	        margin-right: 12rpx;
  	        }
  	        .confirm {
  	            display: flex;
  	            align-items: center;
  	            font-size: 12px;
  	            color: #666666;
  	            letter-spacing: -0.23px;
  	            width: 684rpx;
  	            .image1{
  	                margin-right:25rpx;
  	          width: 42rpx;
  	          height: 38rpx;
  	            }
  	        }
  	        .picker{
  	      display: flex;
  	      flex-direction: column;
  	      justify-content: center;
  	      align-items: center;
  	      width: 100%;
  	
  	      .picker-choice{
  	        display: flex;
  	        width: 684rpx;
  	        align-items: center;
  	            margin-bottom: 40rpx;
  	        .input{
  	          border-bottom: 1px solid #CFCFCF;
  	          height: 40rpx;
  	        }
  	        .choice-left{
  	          width: 210rpx;
  	          .pd{
  	            font-size: 14px;
  	            color: #333333;
  	            letter-spacing: -0.26px;
  	            text-align: justify;
  	            line-height: 24px;
  	            margin-right: 44rpx;
  	          }
  	          .p11 {
  	            font-size: 14px;
  	            color: #333333;
  	            letter-spacing: -0.26px;
  	            text-align: justify;
  	            line-height: 24px;
  	            // margin-right: 10px;
  	          }
  	          .p12 {
  	            font-size: 10px;
  	            color: #3F3F3F;
  	            letter-spacing: -0.19px;
  	            text-align: justify;
  	            line-height: 24px;
  	          }
  	
  	        }
  	        .p13 {
  	          font-size: 10px;
  	          color: #999999;
  	          letter-spacing: -0.19px;
  	          margin-right: 10px;
  	        }
  	            .p13-date {
  	                font-size: 10px;
  	          color: #999999;
  	          letter-spacing: -0.19px;
  	          margin-right: 5px;
  	            }
  	        picker{
  	          width: 144rpx;
  	          height: 40rpx;
  	          display: flex;
  	          position: relative;
  	          .p14 {
  	            font-size: 14px;
  	            color: #666666;
  	            letter-spacing: -0.26px;
  	            text-align: center;
  	            width: 124rpx;
  	            border-bottom: 1px solid #CFCFCF;
  	            height: 38rpx;
  	          }
  	          image{
  	            width: 20rpx;
  	            height: 20rpx;
  	            position: absolute;
  	            right: 20rpx;
  	            top: 8rpx;
  	          }
  	        }
  	
  	      }
  	    }
fed83ad11   BigBoss   新增数据
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
  		
  		.ipts{
  			width: 100%;
  			display: flex;
  			flex-direction: column;
  			justify-content: center;
  			align-items: flex-start;
  			// padding: 20rpx 36rpx;
  			box-sizing: border-box;
  			.inputItem{
  				display: flex;
  				flex-direction: row;
  				justify-content: center;
  				align-items: center;
  				margin-bottom: 36rpx;
  				.text{
  					margin-right: 100rpx;
  				}
  				.input{
  					border-bottom: 1px solid #CFCFCF;
  				}
  			}
  			
  		}
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
  	    }
  	    }
  	  }
  	  .choose {
  	    width: 100%;
  	    background: #ffffff;
  	    border-radius: 12rpx;
  	    margin-top: 20rpx;
  	    padding: 40rpx 40rpx 112rpx 40rpx;
  	    box-sizing: border-box;
  	    .chooseItem {
  	      width: 100%;
  	      padding-bottom: 32rpx;
  	      border-bottom: 1px solid #e9e9e9;
  	      margin-bottom: 28rpx;
  	    }
  	    .chooseRes {
  	      font-size: 12px;
  	      color: #666666;
  	    }
  	    .itemsWrap {
  	      display: flex;
  	      flex-direction: row;
  	      flex-wrap: wrap;
  	      justify-content: flex-start;
  	      align-items: center;
  	      padding-top: 24rpx;
  	      .item1 {
  	        width: 64rpx;
  	        height: 64rpx;
  	        border-radius: 32rpx;
  	        margin: 0 36rpx 24rpx 0;
  	        transition: all 0.3s;
  	        border: 1px solid #ffffff;
  	      }
  	      .item2 {
  	        // width: 100rpx;
  	        padding: 0 30rpx;
  	        height: 60rpx;
  	        margin: 0 20rpx 20rpx 0;
  	        transition: all 0.3s;
  	        background: #f2f2f2;
  	        border-radius: 2px;
  	        border-radius: 2px;
  	        line-height: 60rpx;
  	        text-align: center;
  	        color: #666666;
  	        font-size: 12px;
  	      }
  	      .active1 {
  	        opacity: 0.7;
  	        border: 1px solid #ff6b4a;
  	      }
  	      .active2 {
  	        background: rgba(255, 107, 74, 0.15);
  	        color: #ff6b4a;
  	      }
  	    }
  	  }
  	  .button {
  	    width: 100%;
  	    height: 112rpx;
  	    background-color: #ff6b4a;
  	    font-size: 16px;
  	    color: #ffffff;
  	    line-height: 112rpx;
  	    text-align: center;
22e1420fa   BigBoss   弹窗组件修改
1323
1324
1325
  	    position: sticky;
  	    bottom: 0rpx;
  	    left: 0rpx;
fed83ad11   BigBoss   新增数据
1326
  		z-index: 9999;
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
  	  }
  	}
  	/* sheet弹窗 */
  	.sheet{
  		width: 100%;
  		height: 100%;
  		position: fixed;
  		top: 150%;
  		left: 0upx;
  		bottom: 0upx;
  		right: 0upx;
  		background:rgba(0,0,0,0.3); 
  		z-index: 10000;
  	}
  	
  	/* 显示时候的动画默认0.5s */
  	.sheetView{
  		width: 100%;
  		height: 0upx;
  		position: absolute;
  		bottom: 0upx;
  		background: white;
  		z-index: 10001;
  		transition: all 0.5s;
  	}
  	.sheetShow{
  		top:0upx !important;
  	}
  	/* 关闭时的动画,时间自己可以设置0.5s*/
  	.sheeHide{
  		top:120% !important;
  		transition: all 0.5s;		
  	}
  	
  	/* 项目需求根据设计稿要展示的高度,超出这个高度就自动滚动*/
  	.sheetView_active{
22e1420fa   BigBoss   弹窗组件修改
1363
  		height: 1042upx;
607bc3a4d   BigBoss   修改了直接购买的流程,添加弹窗,选...
1364
1365
1366
  	}
  	
  </style>