integral_order.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990
  1. <template>
  2. <view :style="colorStyle">
  3. <view class='order-submission'>
  4. <view class="allAddress" :style="store_self_mention ? '':'padding-top:10rpx'" v-if="!product_type">
  5. <view class='address acea-row row-between-wrapper' @tap='onAddress' v-if='shippingType == 0'>
  6. <view class='addressCon' v-if="addressInfo.real_name">
  7. <view class='name'>{{addressInfo.real_name}}
  8. <text class='phone'>{{addressInfo.phone}}</text>
  9. </view>
  10. <view class="line1">
  11. <text class='default font-num'
  12. v-if="addressInfo.is_default">[默认]</text>{{addressInfo.province}}{{addressInfo.city}}{{addressInfo.district}}{{addressInfo.detail}}
  13. </view>
  14. <!-- <view class='setaddress'>设置收货地址</view> -->
  15. </view>
  16. <view class='addressCon' v-else>
  17. <view class='setaddress'>设置收货地址</view>
  18. </view>
  19. <view class='iconfont icon-jiantou'></view>
  20. </view>
  21. <view class='line'>
  22. <image src='/static/images/line.jpg'></image>
  23. </view>
  24. </view>
  25. <view class="orderGoods" :class="product_type?'on':''">
  26. <view class='total'>共{{resData.num}}件商品</view>
  27. <view class='goodWrapper'>
  28. <view class='item acea-row row-between-wrapper' @click="jumpCon(cartInfo.product_id)">
  29. <view class='pictrue'>
  30. <image :src='cartInfo.image'></image>
  31. </view>
  32. <view class='text'>
  33. <view class='acea-row row-between-wrapper'>
  34. <view class='name line1'>{{cartInfo.store_name}}</view>
  35. <view class='num'>x {{resData.num}}</view>
  36. </view>
  37. <view class='attr line1' v-if="cartInfo.attrInfo">{{cartInfo.attrInfo.suk}}
  38. </view>
  39. <view class='money font-color'>
  40. {{cartInfo.price}}积分
  41. </view>
  42. </view>
  43. </view>
  44. </view>
  45. </view>
  46. <view class='wrapper' v-if="confirm.length">
  47. <view class='item acea-row row-between-wrapper' v-for="(item,index) in confirm" :key="index">
  48. <view class="name">
  49. <span class="asterisk" v-if="item.status">*</span>
  50. {{ item.title }}</view>
  51. <!-- text -->
  52. <view v-if="item.label=='text'" class="discount">
  53. <input type="text" :placeholder="'请填写'+item.title" placeholder-class="placeholder" v-model="item.value" />
  54. </view>
  55. <!-- number -->
  56. <view v-if="item.label=='number'" class="discount">
  57. <input type="number" :placeholder="'请填写'+item.title" placeholder-class="placeholder" v-model="item.value" />
  58. </view>
  59. <!-- email -->
  60. <view v-if="item.label=='email'" class="discount">
  61. <input type="text" :placeholder="'请填写'+item.title" placeholder-class="placeholder" v-model="item.value" />
  62. </view>
  63. <!-- data -->
  64. <view v-if="item.label=='data'" class="discount">
  65. <picker mode="date" :value="item.value" @change="bindDateChange($event,index)">
  66. <view class="acea-row row-between-wrapper">
  67. <view v-if="item.value == ''">请选择{{item.title}}</view>
  68. <view v-else>{{item.value}}</view>
  69. <text class='iconfont icon-jiantou'></text>
  70. </view>
  71. </picker>
  72. </view>
  73. <!-- time -->
  74. <view v-if="item.label=='time'" class="discount">
  75. <picker mode="time" :value="item.value"
  76. @change="bindTimeChange($event,index)" :placeholder="'请填写'+item.title" >
  77. <view class="acea-row row-between-wrapper">
  78. <view v-if="item.value == ''">请选择{{item.title}}</view>
  79. <view v-else>{{item.value}}</view>
  80. <text class='iconfont icon-jiantou'></text>
  81. </view>
  82. </picker>
  83. </view>
  84. <!-- id -->
  85. <view v-if="item.label=='id'" class="discount">
  86. <input type="idcard" :placeholder="'请填写'+item.title" placeholder-class="placeholder" v-model="item.value" />
  87. </view>
  88. <!-- phone -->
  89. <view v-if="item.label=='phone'" class="discount">
  90. <input type="tel" :placeholder="'请填写'+item.title" placeholder-class="placeholder" v-model="item.value" />
  91. </view>
  92. <!-- img -->
  93. <view v-if="item.label=='img'" class="confirmImg">
  94. <view class='upload acea-row row-middle'>
  95. <view class='pictrue' v-for="(items,indexs) in item.value" :key="indexs">
  96. <image :src='items' mode="aspectFill"></image>
  97. <view class='iconfont icon-guanbi1 font-num' @tap='DelPic(index,indexs)'></view>
  98. </view>
  99. <view class='pictrue acea-row row-center-wrapper row-column' @tap='uploadpic(index)'
  100. v-if="item.value.length < 8">
  101. <text class='iconfont icon-icon25201'></text>
  102. <view>上传图片</view>
  103. </view>
  104. </view>
  105. </view>
  106. </view>
  107. </view>
  108. <view class='wrapper'>
  109. <view class='item acea-row row-between-wrapper'>
  110. <view>可用积分</view>
  111. <view class='discount'>{{resData.integral}}
  112. </view>
  113. </view>
  114. <view class='item acea-row row-between-wrapper'>
  115. <view>快递费用</view>
  116. <view class='discount'>免运费
  117. </view>
  118. </view>
  119. <view class='item' v-if="textareaStatus">
  120. <view>备注信息</view>
  121. <textarea placeholder-class='placeholder' placeholder="请添加备注(150字以内)" v-if="!coupon.coupon"
  122. @input='bindHideKeyboard' :value="mark" :maxlength="150" name="mark">
  123. </textarea>
  124. </view>
  125. </view>
  126. <view style='height:120rpx;'></view>
  127. <view class='footer acea-row row-between-wrapper'>
  128. <view>合计:
  129. <text class='font-color'>{{resData.total_price || 0}}积分</text>
  130. </view>
  131. <view class='settlement' style='z-index:100' @tap="goPay">立即兑换</view>
  132. </view>
  133. </view>
  134. <view class="alipaysubmit" v-html="formContent"></view>
  135. <couponListWindow :coupon='coupon' @ChangCouponsClone="ChangCouponsClone" :openType='openType' :cartId='cartId'
  136. @ChangCoupons="ChangCoupons"></couponListWindow>
  137. <addressWindow ref="addressWindow" @changeTextareaStatus="changeTextareaStatus" :news='news' :address='address'
  138. :pagesUrl="pagesUrl" @OnChangeAddress="OnChangeAddress" @changeClose="changeClose"></addressWindow>
  139. <home v-show="!invShow && navigation"></home>
  140. <!-- #ifdef MP -->
  141. <authorize v-if="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
  142. <!-- #endif -->
  143. </view>
  144. </template>
  145. <script>
  146. import {
  147. integralOrderConfirm,
  148. integralOrderCreate,
  149. } from '@/api/activity.js';
  150. import {
  151. getAddressDefault,
  152. getAddressDetail,
  153. invoiceList,
  154. invoiceOrder
  155. } from '@/api/user.js';
  156. import {
  157. storeListApi
  158. } from '@/api/store.js';
  159. import {
  160. CACHE_LONGITUDE,
  161. CACHE_LATITUDE
  162. } from '@/config/cache.js';
  163. import couponListWindow from '@/components/couponListWindow';
  164. import addressWindow from '@/components/addressWindow';
  165. import orderGoods from '@/components/orderGoods';
  166. import home from '@/components/home';
  167. import {
  168. toLogin
  169. } from '@/libs/login.js';
  170. import {
  171. mapGetters
  172. } from "vuex";
  173. import colors from "@/mixins/color";
  174. export default {
  175. components: {
  176. couponListWindow,
  177. addressWindow,
  178. orderGoods,
  179. home
  180. },
  181. mixins: [colors],
  182. data() {
  183. return {
  184. confirm:[],
  185. textareaStatus: true,
  186. //支付方式
  187. cartArr: [{
  188. "name": "微信支付",
  189. "icon": "icon-weixin2",
  190. value: 'weixin',
  191. title: '使用微信快捷支付',
  192. payStatus: 1,
  193. },
  194. {
  195. "name": "支付宝支付",
  196. "icon": "icon-zhifubao",
  197. value: 'alipay',
  198. title: '使用线上支付宝支付',
  199. payStatus: 1,
  200. },
  201. {
  202. "name": "余额支付",
  203. "icon": "icon-yuezhifu",
  204. value: 'yue',
  205. title: '可用余额:',
  206. payStatus: 1,
  207. },
  208. {
  209. "name": "线下支付",
  210. "icon": "icon-yuezhifu1",
  211. value: 'offline',
  212. title: '选择线下付款方式',
  213. payStatus: 2,
  214. }
  215. ],
  216. formContent: '',
  217. payType: 'weixin', //支付方式
  218. openType: 1, //优惠券打开方式 1=使用
  219. active: 0, //支付方式切换
  220. coupon: {
  221. coupon: false,
  222. list: [],
  223. statusTile: '立即使用'
  224. }, //优惠券组件
  225. address: {
  226. address: false
  227. }, //地址组件
  228. addressInfo: {}, //地址信息
  229. pinkId: 0, //拼团id
  230. addressId: 0, //地址id
  231. couponId: 0, //优惠券id
  232. cartId: '', //购物车id
  233. BargainId: 0,
  234. combinationId: 0,
  235. seckillId: 0,
  236. userInfo: {}, //用户信息
  237. mark: '', //备注信息
  238. couponTitle: '请选择', //优惠券
  239. coupon_price: 0, //优惠券抵扣金额
  240. useIntegral: false, //是否使用积分
  241. integral_price: 0, //积分抵扣金额
  242. integral: 0,
  243. ChangePrice: 0, //使用积分抵扣变动后的金额
  244. formIds: [], //收集formid
  245. status: 0,
  246. is_address: false,
  247. toPay: false, //修复进入支付时页面隐藏从新刷新页面
  248. shippingType: 0,
  249. system_store: {},
  250. storePostage: 0,
  251. contacts: '',
  252. contactsTel: '',
  253. mydata: {},
  254. storeList: [],
  255. store_self_mention: 0,
  256. cartInfo: {},
  257. priceGroup: {},
  258. animated: false,
  259. totalPrice: 0,
  260. integralRatio: "0",
  261. pagesUrl: "",
  262. orderKey: "",
  263. // usableCoupon: {},
  264. offlinePostage: "",
  265. isAuto: false, //没有授权的不会自动授权
  266. isShowAuth: false, //是否隐藏授权
  267. from: '',
  268. news: 1,
  269. invTitle: '不开发票',
  270. special_invoice: false,
  271. invoice_func: false,
  272. header_type: '',
  273. invShow: false,
  274. invList: [],
  275. invChecked: '',
  276. urlQuery: '',
  277. pay_close: false,
  278. resData: {},
  279. product_type:1,
  280. newImg: []
  281. };
  282. },
  283. computed: mapGetters(['isLogin']),
  284. onLoad: function(options) {
  285. // #ifdef H5
  286. this.from = this.$wechat.isWeixin() ? 'weixin' : 'weixinh5'
  287. // #endif
  288. // #ifdef MP
  289. this.from = 'routine'
  290. // #endif
  291. if (!options.unique) return this.$util.Tips({
  292. title: '请选择要购买的商品'
  293. }, {
  294. tab: 3,
  295. url: 1
  296. });
  297. this.unique = options.unique
  298. this.num = options.num
  299. this.couponId = options.couponId || 0;
  300. this.pinkId = options.pinkId ? parseInt(options.pinkId) : 0;
  301. this.addressId = options.addressId || 0;
  302. this.cartId = options.cartId;
  303. this.is_address = options.is_address ? true : false;
  304. this.news = !options.new || options.new === '0' ? 0 : 1;
  305. this.invChecked = options.invoice_id || '';
  306. this.header_type = options.header_type || '1';
  307. this.couponTitle = options.couponTitle || '请选择'
  308. // #ifndef APP-PLUS
  309. this.textareaStatus = true;
  310. // #endif
  311. if (this.isLogin && this.toPay == false) {
  312. this.getFun();
  313. } else {
  314. //#ifndef MP
  315. toLogin();
  316. //#endif
  317. //#ifdef MP
  318. this.isShowAuth = true;
  319. //#endif
  320. }
  321. },
  322. /**
  323. * 生命周期函数--监听页面显示
  324. */
  325. onShow: function() {
  326. uni.removeStorageSync('form_type_cart');
  327. let _this = this
  328. uni.$on("handClick", res => {
  329. if (res) {
  330. _this.system_store = res.address
  331. }
  332. // 清除监听
  333. uni.$off('handClick');
  334. })
  335. },
  336. methods: {
  337. getFun(){
  338. this.getaddressInfo();
  339. this.getConfirm();
  340. this.$nextTick(function() {
  341. this.$refs.addressWindow.getAddressList();
  342. })
  343. },
  344. onLoadFun(){
  345. this.getFun();
  346. this.isShowAuth = false
  347. },
  348. // 授权关闭
  349. authColse: function(e) {
  350. this.isShowAuth = e
  351. },
  352. jumpCon: function(id) {
  353. uni.navigateTo({
  354. url: `/pages/goods_details/index?id=${id}`
  355. })
  356. },
  357. /**
  358. * 删除图片
  359. *
  360. */
  361. DelPic: function(index, indexs) {
  362. let that = this,
  363. pic = this.confirm[index].value;
  364. that.confirm[index].value.splice(indexs, 1);
  365. that.$set(that.confirm[index], 'value', that.confirm[index].value);
  366. },
  367. /**
  368. * 上传文件
  369. *
  370. */
  371. uploadpic: function(index) {
  372. let that = this;
  373. this.$util.uploadImageOne('upload/image', function(res) {
  374. that.newImg.push(res.data.url);
  375. that.$set(that.confirm[index], 'value', that.newImg);
  376. });
  377. },
  378. getInvoiceList() {
  379. uni.showLoading({
  380. title: '正在加载…'
  381. })
  382. invoiceList().then(res => {
  383. uni.hideLoading();
  384. this.invList = res.data.map(item => {
  385. item.id = item.id.toString();
  386. return item;
  387. });
  388. const result = this.invList.find(item => item.id == this.invChecked);
  389. if (result) {
  390. let name = '';
  391. name += result.header_type === 1 ? '个人' : '企业';
  392. name += result.type === 1 ? '普通' : '专用';
  393. name += '发票';
  394. this.invTitle = name;
  395. }
  396. }).catch(err => {
  397. uni.showToast({
  398. title: err,
  399. icon: 'none'
  400. });
  401. });
  402. },
  403. /**
  404. * 事件回调
  405. *
  406. */
  407. onChangeFun: function(e) {
  408. let opt = e;
  409. let action = opt.action || null;
  410. let value = opt.value != undefined ? opt.value : null;
  411. action && this[action] && this[action](value);
  412. },
  413. payClose: function() {
  414. this.pay_close = false;
  415. },
  416. goPay() {
  417. let that = this
  418. if (!that.addressId && !that.product_type) {
  419. return that.$util.Tips({
  420. title: '请选择收货地址'
  421. });
  422. }
  423. if (parseFloat(that.resData.integral) < parseFloat(that.cartInfo.price))
  424. return that.$util.Tips({
  425. title: '积分不足!'
  426. });
  427. for (var i = 0; i < that.confirm.length; i++) {
  428. let data = that.confirm[i]
  429. if (data.status) {
  430. if (data.label === 'text' || data.label === 'data' || data.label === 'time') {
  431. if (!data.value.trim()) {
  432. return that.$util.Tips({
  433. title: `请填写${data.title}`
  434. });
  435. }
  436. }
  437. if (data.label === 'number') {
  438. if (data.value <= 0) {
  439. return that.$util.Tips({
  440. title: `请填写${data.title}`
  441. });
  442. }
  443. }
  444. if (data.label === 'email') {
  445. if (!/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/.test(data.value)) {
  446. return that.$util.Tips({
  447. title: `请填写正确的${data.title}`
  448. });
  449. }
  450. }
  451. if (data.label === 'phone') {
  452. if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(data.value)) {
  453. return that.$util.Tips({
  454. title: `请填写正确的${data.title}`
  455. });
  456. }
  457. }
  458. if (data.label === 'id') {
  459. if (!/^[1-9]\d{7}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}$|^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X)$/i.test(data.value)) {
  460. return that.$util.Tips({
  461. title: `请填写正确的${data.title}`
  462. });
  463. }
  464. }
  465. if (data.label === 'img') {
  466. if (!data.value.length) {
  467. return that.$util.Tips({
  468. title: `请上传${data.title}`
  469. });
  470. }
  471. }
  472. }
  473. }
  474. let data = {
  475. custom_form: that.confirm,
  476. addressId: that.addressId,
  477. mark: that.mark,
  478. unique: this.cartInfo.unique,
  479. num: this.resData.num
  480. }
  481. integralOrderCreate(data).then(res => {
  482. uni.redirectTo({
  483. url: `/pages/points_mall/integral_order_status?order_id=${res.data.result.orderId}`
  484. })
  485. }).catch(err => {
  486. uni.hideLoading();
  487. return that.$util.Tips({
  488. title: err
  489. });
  490. });
  491. },
  492. // 关闭地址弹窗;
  493. changeClose: function() {
  494. this.$set(this.address, 'address', false);
  495. },
  496. computedPrice: function() {
  497. let shippingType = this.shippingType;
  498. postOrderComputed(this.orderKey, {
  499. addressId: this.addressId,
  500. useIntegral: this.useIntegral ? 1 : 0,
  501. couponId: this.couponId,
  502. shipping_type: parseInt(shippingType) + 1,
  503. payType: this.payType
  504. }).then(res => {
  505. let result = res.data.result;
  506. if (result) {
  507. this.totalPrice = result.pay_price;
  508. this.integral_price = result.deduction_price;
  509. this.coupon_price = result.coupon_price;
  510. this.integral = this.useIntegral ? result.SurplusIntegral : this.userInfo.integral;
  511. this.$set(this.priceGroup, 'storePostage', shippingType == 1 ? 0 : result.pay_postage);
  512. this.$set(this.priceGroup, 'storePostageDiscount', result.storePostageDiscount);
  513. }
  514. })
  515. },
  516. ChangCouponsClone: function() {
  517. this.$set(this.coupon, 'coupon', false);
  518. },
  519. changeTextareaStatus: function() {
  520. for (let i = 0, len = this.coupon.list.length; i < len; i++) {
  521. this.coupon.list[i].use_title = '';
  522. this.coupon.list[i].is_use = 0;
  523. }
  524. this.textareaStatus = true;
  525. this.status = 0;
  526. this.$set(this.coupon, 'list', this.coupon.list);
  527. },
  528. /**
  529. * 选择地址后改变事件
  530. * @param object e
  531. */
  532. OnChangeAddress: function(e) {
  533. this.textareaStatus = true;
  534. this.addressId = e;
  535. this.address.address = false;
  536. this.getaddressInfo();
  537. },
  538. bindHideKeyboard: function(e) {
  539. this.mark = e.detail.value;
  540. },
  541. /**
  542. * 获取当前订单详细信息
  543. *
  544. */
  545. getConfirm: function() {
  546. let that = this;
  547. // return;
  548. integralOrderConfirm({
  549. unique: this.unique,
  550. num: this.num
  551. }).then(res => {
  552. that.$set(that, 'confirm', res.data.custom_form);
  553. that.$set(that, 'product_type', parseInt(res.data.productInfo.product_type));
  554. that.$set(that, 'resData', res.data);
  555. that.$set(that, 'cartInfo', res.data.productInfo);
  556. }).catch(err => {
  557. return this.$util.Tips({
  558. title: err
  559. });
  560. });
  561. },
  562. bindDateChange: function(e, index) {
  563. this.confirm[index].value = e.target.value
  564. },
  565. bindTimeChange: function(e, index) {
  566. this.confirm[index].value = e.target.value
  567. },
  568. /*
  569. * 提取砍价和拼团id
  570. */
  571. getBargainId: function() {
  572. let that = this;
  573. let cartINfo = that.cartInfo;
  574. let BargainId = 0;
  575. let combinationId = 0;
  576. cartINfo.forEach(function(value, index, cartINfo) {
  577. BargainId = cartINfo[index].bargain_id,
  578. combinationId = cartINfo[index].combination_id
  579. })
  580. that.$set(that, 'BargainId', parseInt(BargainId));
  581. that.$set(that, 'combinationId', parseInt(combinationId));
  582. if (that.cartArr.length == 3 && (BargainId || combinationId || that.seckillId)) {
  583. that.cartArr[2].payStatus = 0;
  584. that.$set(that, 'cartArr', that.cartArr);
  585. }
  586. },
  587. /*
  588. * 获取默认收货地址或者获取某条地址信息
  589. */
  590. getaddressInfo: function() {
  591. let that = this;
  592. if (that.addressId) {
  593. getAddressDetail(that.addressId).then(res => {
  594. res.data.is_default = parseInt(res.data.is_default);
  595. that.addressInfo = res.data || {};
  596. that.addressId = res.data.id || 0;
  597. that.address.addressId = res.data.id || 0;
  598. })
  599. } else {
  600. getAddressDefault().then(res => {
  601. res.data.is_default = parseInt(res.data.is_default);
  602. that.addressInfo = res.data || {};
  603. that.addressId = res.data.id || 0;
  604. that.address.addressId = res.data.id || 0;
  605. })
  606. }
  607. },
  608. couponTap: function() {
  609. this.coupon.coupon = true;
  610. this.coupon.list.forEach((item, index) => {
  611. if (item.id == this.couponId) {
  612. item.is_use = 1
  613. } else {
  614. item.is_use = 0
  615. }
  616. })
  617. this.$set(this.coupon, 'list', this.coupon.list);
  618. },
  619. car: function() {
  620. let that = this;
  621. that.animated = false;
  622. },
  623. onAddress: function() {
  624. let that = this;
  625. that.textareaStatus = false;
  626. that.address.address = true;
  627. that.pagesUrl = `/pages/points_mall/user_address?unique=${this.unique}&num=${this.num}`
  628. },
  629. clickTextArea() {
  630. this.$nextTick(() => {
  631. this.$refs.getFocus.focus()
  632. })
  633. },
  634. }
  635. }
  636. </script>
  637. <style lang="scss" scoped>
  638. /deep/uni-checkbox[disabled] .uni-checkbox-input {
  639. background-color: #eee;
  640. }
  641. .confirmImg{
  642. width: 100%;
  643. }
  644. .confirmImg .upload {
  645. padding-bottom: 36rpx;
  646. }
  647. .confirmImg .upload .pictrue {
  648. margin: 22rpx 23rpx 0 0;
  649. width: 156rpx;
  650. height: 156rpx;
  651. position: relative;
  652. font-size: 24rpx;
  653. color: #bbb;
  654. }
  655. .confirmImg .upload .pictrue:nth-of-type(4n) {
  656. margin-right: 0;
  657. }
  658. .confirmImg .upload .pictrue image {
  659. width: 100%;
  660. height: 100%;
  661. border-radius: 3rpx;
  662. }
  663. .confirmImg .upload .pictrue .icon-guanbi1 {
  664. position: absolute;
  665. font-size: 45rpx;
  666. top: -10rpx;
  667. right: -10rpx;
  668. }
  669. .confirmImg .upload .pictrue .icon-icon25201 {
  670. color: #bfbfbf;
  671. font-size: 50rpx;
  672. }
  673. .confirmImg .upload .pictrue:nth-last-child(1) {
  674. border: 1rpx solid #ddd;
  675. box-sizing: border-box;
  676. }
  677. .goodWrapper{
  678. padding: 0 30rpx;
  679. }
  680. .alipaysubmit {
  681. display: none;
  682. }
  683. .order-submission .line {
  684. width: 100%;
  685. height: 3rpx;
  686. }
  687. .order-submission .line image {
  688. width: 100%;
  689. height: 100%;
  690. display: block;
  691. }
  692. .order-submission .address {
  693. padding: 28rpx 30rpx;
  694. background-color: #fff;
  695. box-sizing: border-box;
  696. }
  697. .order-submission .address .addressCon {
  698. width: 610rpx;
  699. font-size: 26rpx;
  700. color: #666;
  701. }
  702. .order-submission .address .addressCon .name {
  703. font-size: 30rpx;
  704. color: #282828;
  705. font-weight: bold;
  706. margin-bottom: 10rpx;
  707. }
  708. .order-submission .address .addressCon .name .phone {
  709. margin-left: 50rpx;
  710. }
  711. .order-submission .address .addressCon .default {
  712. margin-right: 12rpx;
  713. }
  714. .order-submission .address .addressCon .setaddress {
  715. color: #333;
  716. font-size: 28rpx;
  717. }
  718. .order-submission .address .iconfont {
  719. font-size: 35rpx;
  720. color: #707070;
  721. }
  722. .order-submission .allAddress {
  723. width: 100%;
  724. background: linear-gradient(to bottom, var(--view-theme) 0%, #f5f5f5 100%);
  725. padding-top: 100rpx;
  726. }
  727. .order-submission .allAddress .nav {
  728. width: 710rpx;
  729. margin: 0 auto;
  730. }
  731. .order-submission .allAddress .nav .item {
  732. width: 355rpx;
  733. }
  734. .order-submission .allAddress .nav .item.on {
  735. position: relative;
  736. width: 250rpx;
  737. }
  738. .order-submission .allAddress .nav .item.on::before {
  739. position: absolute;
  740. bottom: 0;
  741. content: "快递配送";
  742. font-size: 28rpx;
  743. display: block;
  744. height: 0;
  745. width: 336rpx;
  746. border-width: 0 20rpx 80rpx 0;
  747. border-style: none solid solid;
  748. border-color: transparent transparent #fff;
  749. z-index: 2;
  750. border-radius: 7rpx 30rpx 0 0;
  751. text-align: center;
  752. line-height: 80rpx;
  753. }
  754. .order-submission .allAddress .nav .item:nth-of-type(2).on::before {
  755. content: "到店自提";
  756. border-width: 0 0 80rpx 20rpx;
  757. border-radius: 30rpx 7rpx 0 0;
  758. }
  759. .order-submission .allAddress .nav .item.on2 {
  760. position: relative;
  761. }
  762. .order-submission .allAddress .nav .item.on2::before {
  763. position: absolute;
  764. bottom: 0;
  765. content: "到店自提";
  766. font-size: 28rpx;
  767. display: block;
  768. height: 0;
  769. width: 400rpx;
  770. border-width: 0 0 60rpx 60rpx;
  771. border-style: none solid solid;
  772. border-color: transparent transparent #f7c1bd;
  773. border-radius: 40rpx 6rpx 0 0;
  774. text-align: center;
  775. line-height: 60rpx;
  776. }
  777. .order-submission .allAddress .nav .item:nth-of-type(1).on2::before {
  778. content: "快递配送";
  779. border-width: 0 60rpx 60rpx 0;
  780. border-radius: 6rpx 40rpx 0 0;
  781. }
  782. .order-submission .allAddress .address {
  783. width: 710rpx;
  784. height: 150rpx;
  785. margin: 0 auto;
  786. }
  787. .order-submission .allAddress .line {
  788. width: 710rpx;
  789. margin: 0 auto;
  790. }
  791. .order-submission .wrapper .item .discount .placeholder {
  792. color: #ccc;
  793. }
  794. .placeholder-textarea {
  795. position: relative;
  796. .placeholder {
  797. position: absolute;
  798. color: #ccc;
  799. top: 26rpx;
  800. left: 30rpx;
  801. }
  802. }
  803. .order-submission .wrapper {
  804. background-color: #fff;
  805. margin-top: 13rpx;
  806. }
  807. .order-submission .wrapper .item .name{
  808. position: relative;
  809. }
  810. .order-submission .wrapper .item .asterisk{
  811. position: absolute;
  812. color:red;
  813. left:-15rpx
  814. }
  815. .order-submission .wrapper .item {
  816. padding: 27rpx 30rpx;
  817. font-size: 30rpx;
  818. color: #282828;
  819. border-bottom: 1px solid #f0f0f0;
  820. }
  821. .order-submission .wrapper .item .discount {
  822. font-size: 30rpx;
  823. color: #999;
  824. }
  825. .order-submission .wrapper .item .discount input {
  826. text-align: end;
  827. }
  828. .order-submission .wrapper .item .discount .iconfont {
  829. color: #515151;
  830. font-size: 30rpx;
  831. margin-left: 15rpx;
  832. }
  833. .order-submission .wrapper .item .discount .num {
  834. font-size: 32rpx;
  835. margin-right: 20rpx;
  836. }
  837. .order-submission .wrapper .item .shipping {
  838. font-size: 30rpx;
  839. color: #999;
  840. position: relative;
  841. padding-right: 58rpx;
  842. }
  843. .order-submission .wrapper .item .shipping .iconfont {
  844. font-size: 35rpx;
  845. color: #707070;
  846. position: absolute;
  847. right: 0;
  848. top: 50%;
  849. transform: translateY(-50%);
  850. margin-left: 30rpx;
  851. }
  852. .order-submission .wrapper .item textarea {
  853. background-color: #f9f9f9;
  854. width: 690rpx;
  855. height: 140rpx;
  856. border-radius: 3rpx;
  857. margin-top: 30rpx;
  858. padding: 25rpx 28rpx;
  859. box-sizing: border-box;
  860. }
  861. .order-submission .wrapper .item .placeholder {
  862. color: #ccc;
  863. }
  864. .order-submission .wrapper .item .list {
  865. margin-top: 35rpx;
  866. }
  867. .order-submission .moneyList {
  868. margin-top: 12rpx;
  869. background-color: #fff;
  870. padding: 30rpx;
  871. }
  872. .order-submission .moneyList .item {
  873. font-size: 28rpx;
  874. color: #282828;
  875. }
  876. .order-submission .moneyList .item~.item {
  877. margin-top: 20rpx;
  878. }
  879. .order-submission .moneyList .item .money {
  880. color: #868686;
  881. }
  882. .order-submission .footer {
  883. width: 100%;
  884. height: 100rpx;
  885. background-color: #fff;
  886. padding: 0 30rpx;
  887. font-size: 28rpx;
  888. color: #333;
  889. box-sizing: border-box;
  890. position: fixed;
  891. bottom: 0;
  892. left: 0;
  893. }
  894. .order-submission .footer .settlement {
  895. font-size: 30rpx;
  896. color: #fff;
  897. width: 240rpx;
  898. height: 70rpx;
  899. background-color: var(--view-theme);
  900. border-radius: 50rpx;
  901. text-align: center;
  902. line-height: 70rpx;
  903. }
  904. .footer .transparent {
  905. opacity: 0
  906. }
  907. .orderGoods {
  908. background-color: #fff;
  909. margin-top: 12rpx;
  910. &.on{
  911. margin-top: 0;
  912. }
  913. }
  914. .orderGoods .total {
  915. width: 100%;
  916. height: 86rpx;
  917. padding: 0 30rpx;
  918. border-bottom: 2rpx solid #f0f0f0;
  919. font-size: 30rpx;
  920. color: #282828;
  921. line-height: 86rpx;
  922. box-sizing: border-box;
  923. }
  924. .pictrue image {
  925. width: 130rpx;
  926. height: 130rpx;
  927. }
  928. </style>