order.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820
  1. <template>
  2. <app-layout>
  3. <view class="order">
  4. <view class="top dir-left-nowrap main-between cross-center">
  5. <view class="top-input cross-center" @click="go_search()" v-if="!search">
  6. <view class="input main-center cross-center">
  7. <image src="/static/image/icon/icon-search.png"></image>
  8. <text>搜索</text>
  9. </view>
  10. </view>
  11. <view class="to-top dir-left-nowrap main-center cross-center" v-if="!search" @click="active = true">
  12. <text>{{active_item}}</text>
  13. <image v-if="!active" class="icon" src="../image/open.png"></image>
  14. <image v-if="active" class="icon icon-active" src="../image/open.png"></image>
  15. </view>
  16. <view class="search dir-left-nowrap cross-center main-between" v-if="search">
  17. <input type="text" class="input" v-model="search_text" @blur="blur_request" @confirm="set_search">
  18. <image class="delete" v-show="search_text.length>0" @click="empyt_search" src="../image/delete.png"></image>
  19. <text style="color:#666666;font-size: 32rpx;" @click="set_search">搜索</text>
  20. </view>
  21. </view>
  22. <view class="do-top" v-if="active" @click.stop="active = false">
  23. <view class="do-top-item"
  24. v-for="(item, index) in select_list"
  25. :key="index"
  26. :class="{'active-item': item.active}"
  27. @click="set_active(item)"
  28. >
  29. {{item.text}}
  30. </view>
  31. </view>
  32. <view style="margin-top: 108rpx;"></view>
  33. <view class="item" v-for="(item, index) in order_list" :key="index">
  34. <view class="item-top dir-left-wrap main-between cross-center" >
  35. <text class="order-number" style="color: #999999;">订单号{{item.advance_no}}</text>
  36. <text v-if="item.status_num == 1">定金待支付</text>
  37. <text v-else-if="item.status_num == 2">尾款支付未开始</text>
  38. <text v-else-if="item.status_num == 3">尾款待支付</text>
  39. <text v-else-if="item.status_num == 4">购买成功</text>
  40. <text v-else-if="item.status_num == 5">订单已取消</text>
  41. <text v-else-if="item.status_num == 6">订单已售后</text>
  42. <text v-else-if="item.status_num == 7">购买失败 定金支付超时</text>
  43. <text v-else-if="item.status_num == 8">购买失败 定金已退款</text>
  44. <text v-else-if="item.status_num == 9">购买失败 尾款支付超时</text>
  45. </view>
  46. <view class="item-center dir-left-nowrap" @click="route_go(item)">
  47. <image class="image" :src="item.goods.goodsWarehouse.cover_pic"></image>
  48. <view class="content">
  49. <view class="name">{{item.goods.goodsWarehouse.name}}</view>
  50. <view class="attr">
  51. <text>{{item.attr_name}}</text>
  52. </view>
  53. <view class="num-price dir-left-nowrap main-between cross-center">
  54. <text>×{{item.goods_num}}</text>
  55. <text>¥{{item.goodsAttr.price}}</text>
  56. </view>
  57. <view class="des-price dir-left-wrap main-right cross-center">
  58. <text>定金</text>
  59. <text :style="{color: item.is_pay == 0 ? '#ff4544' : '#353535'}">¥{{item.deposit}}</text>
  60. <text>抵¥{{item.swell_deposit}}</text>
  61. <text style="color: #ff4544;" v-if="item.status_num == 9">(定金不退)</text>
  62. </view>
  63. </view>
  64. </view>
  65. <view class="item-bottom">
  66. <view class="swell-price main-right cross-center" v-if="item.status_num == 2 || item.status_num == 3 || item.status_num == 4 || item.status_num == 9 ">
  67. <text>尾款</text>
  68. <text style="color: #ff4544;">¥{{item.tail_money}}</text>
  69. </view>
  70. <view v-if="item.status_num == 1" class="text-time">
  71. <text>距截止</text>
  72. <text style="color: #ff4544">{{item.html}}</text>
  73. </view>
  74. <view v-if="item.status_num == 3 && item.pay_limit != -1" class="text-time">
  75. <text>距截止</text>
  76. <text style="color: #ff4544">{{item.html}}</text>
  77. </view>
  78. <view class="filal-payment-time" v-if="item.status_num == 2">
  79. 支付尾款时间:{{set_time(item.pay_limit, item.end_prepayment_at)}}
  80. </view>
  81. <view class="button" @click="payFinalPayment(item)" v-if="item.status_num == 3 && item.order_id == 0">
  82. <app-form-id>
  83. <text>
  84. 去支付尾款
  85. </text>
  86. </app-form-id>
  87. </view>
  88. <view class="button" @click="payPayment(item, index)" v-else-if="item.status_num == 3 && item.order_id != 0 && item.pay_type != 2">
  89. <app-form-id>
  90. <text>
  91. 付款
  92. </text>
  93. </app-form-id>
  94. </view>
  95. <view class="button" @click="payDeposit(item, index)" v-else-if="item.status_num == 1">
  96. <app-form-id>
  97. <text>
  98. 去支付定金
  99. </text>
  100. </app-form-id>
  101. </view>
  102. </view>
  103. </view>
  104. <view class="order-empty" v-if="order_list.length === 0">
  105. <image src="../image/order.png"></image>
  106. <text>没有任何订单哦~</text>
  107. </view>
  108. </view>
  109. </app-layout>
  110. </template>
  111. <script>
  112. export default {
  113. name: 'order',
  114. data() {
  115. return {
  116. active: false,
  117. active_item: '全部预定',
  118. select_list: [
  119. {
  120. id: -1,
  121. active: true,
  122. text: '全部预定',
  123. },
  124. {
  125. id: 1,
  126. active: false,
  127. text: '定金待支付',
  128. },
  129. {
  130. id: 2,
  131. active: false,
  132. text: '尾款支付未开始',
  133. },
  134. {
  135. id: 3,
  136. active: false,
  137. text: '尾款待支付',
  138. },
  139. {
  140. id: 4,
  141. active: false,
  142. text: '购买成功',
  143. },
  144. {
  145. id: 5,
  146. active: false,
  147. text: '购买失败',
  148. }
  149. ],
  150. order_list: [],
  151. page: 1,
  152. keyword: -1,
  153. over: false,
  154. interval: null,
  155. search: false,
  156. search_text: '',
  157. oldOrder: [],
  158. template_message: []
  159. }
  160. },
  161. onShow() {
  162. this.order_list = [];
  163. this.page = 1;
  164. this.request(this.keyword).then(() => {
  165. this.get_time();
  166. });
  167. },
  168. onHide() {
  169. clearInterval(this.interval);
  170. },
  171. onUnload() {
  172. clearInterval(this.interval);
  173. },
  174. methods: {
  175. empyt_search() {
  176. this.search = false;
  177. this.search_text = '';
  178. this.set_active({id: -1});
  179. this.active_item = '全部预定';
  180. },
  181. set_active(data) {
  182. clearInterval(this.interval);
  183. this.order_list = [];
  184. this.keyword = data.id;
  185. this.over = false;
  186. this.page = 1;
  187. this.request().then(() => {
  188. if (data.id === 1 || data.id === -1 || data.id === 3) this.get_time();
  189. });
  190. for (let i = 0; i < this.select_list.length; i++) {
  191. if (this.select_list[i].id === data.id) {
  192. this.select_list[i].active = true;
  193. } else {
  194. this.select_list[i].active = false;
  195. }
  196. }
  197. this.active = false;
  198. this.active_item = data.text;
  199. },
  200. route_go(data) {
  201. if (data.status_num == 4) {
  202. uni.navigateTo({
  203. url: `/pages/order/order-detail/order-detail?id=${data.order_id}&sign=advance`
  204. })
  205. }
  206. },
  207. // 支付尾款
  208. payFinalPayment(item) {
  209. let data = [
  210. {
  211. "mch_id": item.goods.mch_id,
  212. "goods_list": [
  213. {
  214. "id":item.goods_id,
  215. "attr": JSON.parse(item.goods_info).attr_list,
  216. "num":item.goods_num,
  217. "cat_id":0,
  218. "goods_attr_id":item.goodsAttr.id,
  219. "advance_id": item.id,
  220. }
  221. ]
  222. }
  223. ];
  224. this.$jump({
  225. open_type: 'navigate',
  226. url: `/pages/order-submit/order-submit?mch_list=${JSON.stringify(data)}&preview_url=${encodeURIComponent(this.$api.advance.order_preview)}&submit_url=${encodeURIComponent(this.$api.advance.order_sub)}&order_page_url=/plugins/advance/order/order&plugin=advance&total_title=尾款`
  227. });
  228. },
  229. payPayment(item, index) {
  230. this.$request({
  231. url: this.$api.order.list_pay_data,
  232. data: {
  233. id: item.order_id,
  234. },
  235. method: 'get'
  236. }).then(res => {
  237. if (res.code === 0) {
  238. this.$payment.pay(res.data.id).then(() => {
  239. // 支付成功
  240. if (this.keyword === -1) {
  241. this.order_list[index].status_num = '4';
  242. } else {
  243. this.$delete(this.order_list, index);
  244. }
  245. }).catch(() => {
  246. // 支付失败
  247. });
  248. }
  249. })
  250. },
  251. // 去支付定金
  252. payDeposit(data, index) {
  253. this.$subscribe(this.template_message).then(() => {
  254. this.submit(data, index);
  255. }).catch(() => {
  256. this.submit(data, index);
  257. });
  258. },
  259. submit(data, index) {
  260. let body = {
  261. id: data.id,
  262. goods_id: data.goods_id,
  263. goods_num: data.goods_num,
  264. goods_attr_id:data.goodsAttr.id,
  265. };
  266. this.get_submit(body).then(response => {
  267. this.$payment.pay(response.data.id).then((res) => {
  268. this.$request({
  269. url: this.$api.advance.order,
  270. method: 'get',
  271. data: {
  272. id: data.id,
  273. }
  274. }).then(response => {
  275. if (response.code === 0) {
  276. this.$set(this.order_list, index, response.data.list[0]);
  277. let attr_name = '';
  278. let attr_groups = JSON.parse(this.order_list[index].goods_info);
  279. for (let j = 0; j < attr_groups.attr_list.length; j++) {
  280. attr_name+= ` ${attr_groups.attr_list[j].attr_group_name}:${attr_groups.attr_list[j].attr_name}`
  281. }
  282. this.$set(this.order_list[index], 'attr_name', attr_name);
  283. } else if (response.code === 1) {
  284. uni.showModal({
  285. title: '提示',
  286. content: res.msg,
  287. success(res) {
  288. if (res.cancel) {
  289. uni.navigateBack();
  290. } else if (res.confirm) {
  291. uni.navigateBack();
  292. }
  293. }
  294. })
  295. }
  296. });
  297. }).catch(() => {
  298. });
  299. });
  300. },
  301. addDate(date, days) {
  302. if(days == undefined || days == '') {
  303. days = 1;
  304. }
  305. let newDate = new Date(date.replace(/-/g, '/'));
  306. newDate.setDate(newDate.getDate() + days);
  307. let month = newDate.getMonth() + 1;
  308. let day = newDate.getDate();
  309. let mm = "'" + month + "'";
  310. let dd = "'" + day + "'";
  311. if(mm.length == 3) {
  312. month = "0" + month;
  313. }
  314. if(dd.length == 3) {
  315. day = "0" + day;
  316. }
  317. let hour = newDate.getHours();//得到小时
  318. let minu = newDate.getMinutes();//得到分钟
  319. let sec = newDate.getSeconds();//得到秒
  320. if (sec === 0) {
  321. sec = 59;
  322. if (minu === 0) {
  323. minu = 59;
  324. if (hour === 0) {
  325. hour = 23;
  326. day = '0' + Number(day) -1;
  327. } else {
  328. hour = hour -1;
  329. }
  330. } else {
  331. minu = minu - 1;
  332. }
  333. } else {
  334. sec = sec -1;
  335. }
  336. sec = `${sec}`;
  337. minu = `${minu}`;
  338. hour = `${hour}`;
  339. if (hour.length === 1) {
  340. hour = `0${hour}`
  341. }
  342. if (minu.length === 1) {
  343. minu = `0${minu}`
  344. }
  345. if (sec.length === 1) {
  346. sec = `0${sec}`
  347. }
  348. return newDate.getFullYear() + "." + month + "." + day + ' ' + hour +':' + minu + ':' + sec;
  349. },
  350. getDate(end_prepayment_at) {
  351. let newDate = new Date(end_prepayment_at.replace(/-/g, '/'));
  352. newDate.setDate(newDate.getDate());
  353. let month = newDate.getMonth() + 1;
  354. let day = newDate.getDate();
  355. let mm = "'" + month + "'";
  356. let dd = "'" + day + "'";
  357. if(mm.length == 3) {
  358. month = "0" + month;
  359. }
  360. if(dd.length == 3) {
  361. day = "0" + day;
  362. }
  363. let hour = newDate.getHours();//得到小时
  364. let minu = newDate.getMinutes();//得到分钟
  365. let sec = newDate.getSeconds();//得到秒
  366. sec = `${sec}`;
  367. minu = `${minu}`;
  368. hour = `${hour}`;
  369. if (hour.length === 1) {
  370. hour = `0${hour}`
  371. }
  372. if (minu.length === 1) {
  373. minu = `0${minu}`
  374. }
  375. if (sec.length === 1) {
  376. sec = `0${sec}`
  377. }
  378. return newDate.getFullYear() + "." + month + "." + day + ' ' + hour +':' + minu + ':' + sec;
  379. },
  380. async request() {
  381. uni.showLoading({
  382. title: '加载中'
  383. });
  384. try {
  385. const response = await this.$request({
  386. url: this.$api.advance.order,
  387. method: 'get',
  388. data: {
  389. keyword: this.keyword,
  390. page: this.page,
  391. name: this.search_text,
  392. }
  393. });
  394. uni.hideLoading();
  395. if (response.code === 0) {
  396. this.order_list = [...this.order_list, ...response.data.list];
  397. this.template_message = response.data.template_message;
  398. for (let i = 0; i < this.order_list.length; i++) {
  399. let attr_name = '';
  400. let attr_groups = JSON.parse(this.order_list[i].goods_info);
  401. for (let j = 0; j < attr_groups.attr_list.length; j++) {
  402. attr_name+= ` ${attr_groups.attr_list[j].attr_group_name}:${attr_groups.attr_list[j].attr_name}`
  403. }
  404. this.$set(this.order_list[i], 'attr_name', attr_name);
  405. }
  406. }
  407. } catch (e) {
  408. uni.hideLoading();
  409. uni.navigateTo({
  410. url: `/plugins/advance/index/index`
  411. });
  412. }
  413. },
  414. set_time(pay_limit, end_prepayment_at) {
  415. if (pay_limit == -1) {
  416. return `${this.getDate(end_prepayment_at)} ~ 无期限`
  417. } else {
  418. return `${this.getDate(end_prepayment_at)} ~ ${this.addDate(end_prepayment_at, Number(pay_limit))}`
  419. }
  420. },
  421. async get_submit(body) {
  422. const response = await this.$request({
  423. url: this.$api.advance.order_submit,
  424. method: 'post',
  425. data: {
  426. ...body,
  427. }
  428. });
  429. if (response.code === 0) {
  430. return response;
  431. } else if (response.code === 1) {
  432. uni.showModal({
  433. title: '提示',
  434. content: response.msg,
  435. success(res) {
  436. if (res.cancel) {
  437. uni.navigateBack();
  438. } else if (res.confirm) {
  439. uni.navigateBack();
  440. }
  441. }
  442. })
  443. }
  444. },
  445. get_time() {
  446. clearInterval(this.interval);
  447. let now = new Date().getTime();
  448. for (let i = 0; i < this.order_list.length; i++) {
  449. if (this.order_list[i].status_num == 1) {
  450. let timelog = new Date(this.order_list[i].end_prepayment_at.replace(/-/g, '/')).getTime();
  451. let time = timelog - now;
  452. if (time > 0) {
  453. let day = parseInt((time/1000/60/60/24)%30);
  454. let hou = parseInt((time/1000/60/60)%24);
  455. let min = parseInt((time/1000/60)%60);
  456. let sec = parseInt((time/1000)%60);
  457. if (day > 0) {
  458. this.$set(this.order_list[i], 'html', day+"天"+hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  459. } else {
  460. this.$set(this.order_list[i], 'html', hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  461. }
  462. }
  463. } else if (this.order_list[i].status_num == 3) {
  464. if (this.order_list[i].pay_limit == -1) {
  465. this.$set(this.order_list[i], 'html', '不显示');
  466. } else {
  467. let newDate = new Date(this.order_list[i].end_prepayment_at.replace(/-/g, '/'));
  468. let timelog = newDate.setDate(newDate.getDate() + Number(this.order_list[i].pay_limit));
  469. let time = new Date(timelog).getTime() - now;
  470. if (time > 0) {
  471. let day = parseInt((time/1000/60/60/24)%30);
  472. let hou = parseInt((time/1000/60/60)%24);
  473. let min = parseInt((time/1000/60)%60);
  474. let sec = parseInt((time/1000)%60);
  475. if (day > 0) {
  476. this.$set(this.order_list[i], 'html', day+"天"+hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  477. } else {
  478. this.$set(this.order_list[i], 'html', hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  479. }
  480. }
  481. }
  482. }
  483. }
  484. this.interval = setInterval(() => {
  485. let now = new Date().getTime();
  486. if (this.order_list.length === 0) clearInterval(this.interval);
  487. for (let i = 0; i < this.order_list.length; i++) {
  488. if (this.order_list[i].status_num == 1) {
  489. let timelog = new Date(this.order_list[i].end_prepayment_at.replace(/-/g, '/')).getTime();
  490. let time = timelog - now;
  491. if (time > 0) {
  492. let day = parseInt((time/1000/60/60/24)%30);
  493. let hou = parseInt((time/1000/60/60)%24);
  494. let min = parseInt((time/1000/60)%60);
  495. let sec = parseInt((time/1000)%60);
  496. if (day > 0) {
  497. this.$set(this.order_list[i], 'html', day+"天"+hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  498. } else {
  499. this.$set(this.order_list[i], 'html', hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  500. }
  501. }
  502. } else if (this.order_list[i].status_num == 3) {
  503. if (this.order_list[i].pay_limit == -1) {
  504. this.$set(this.order_list[i], 'html', '不显示');
  505. } else {
  506. let newDate = new Date(this.order_list[i].end_prepayment_at.replace(/-/g, '/'));
  507. let timelog = newDate.setDate(newDate.getDate() + Number(this.order_list[i].pay_limit));
  508. let time = new Date(timelog).getTime() - now;
  509. if (time > 0) {
  510. let day = parseInt((time/1000/60/60/24)%30);
  511. let hou = parseInt((time/1000/60/60)%24);
  512. let min = parseInt((time/1000/60)%60);
  513. let sec = parseInt((time/1000)%60);
  514. if (day > 0) {
  515. this.$set(this.order_list[i], 'html', day+"天"+hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  516. } else {
  517. this.$set(this.order_list[i], 'html', hou+":"+(min<10?"0"+min:min) + ":"+(sec<10?"0"+sec:sec));
  518. }
  519. }
  520. }
  521. }
  522. }
  523. }, 1000);
  524. },
  525. async set_search() {
  526. this.page = 1;
  527. this.keyword = -1;
  528. uni.showLoading({
  529. title: '加载中'
  530. });
  531. const response = await this.$request({
  532. url: this.$api.advance.order,
  533. method: 'get',
  534. data: {
  535. keyword: this.keyword,
  536. page: this.page,
  537. name: this.search_text,
  538. }
  539. });
  540. if (response.code === 0) {
  541. this.order_list = response.data.list;
  542. for (let i = 0; i < this.order_list.length; i++) {
  543. let attr_name = '';
  544. let attr_groups = JSON.parse(this.order_list[i].goods_info);
  545. for (let j = 0; j < attr_groups.attr_list.length; j++) {
  546. attr_name+= ` ${attr_groups.attr_list[j].attr_group_name}:${attr_groups.attr_list[j].attr_name}`
  547. }
  548. this.$set(this.order_list[i], 'attr_name', attr_name);
  549. }
  550. }
  551. uni.hideLoading();
  552. this.get_time();
  553. },
  554. blur_request() {
  555. // this.order_list = this.oldOrder;
  556. },
  557. go_search() {
  558. this.search = true;
  559. this.active = false;
  560. this.oldOrder = this.order_list;
  561. this.order_list = [];
  562. }
  563. },
  564. onReachBottom() {
  565. if (!this.over) {
  566. this.page+=1;
  567. this.$request({
  568. url: this.$api.advance.order,
  569. method: 'get',
  570. data: {
  571. keyword: this.keyword,
  572. page: this.page,
  573. name: this.search_text,
  574. }
  575. }).then(res => {
  576. if (res.code === 0) {
  577. if (res.data.list.length > 0) {
  578. this.order_list = [...this.order_list, ...res.data.list];
  579. for (let i = 0; i < this.order_list.length; i++) {
  580. let attr_name = '';
  581. let attr_groups = JSON.parse(this.order_list[i].goods_info);
  582. for (let j = 0; j < attr_groups.attr_list.length; j++) {
  583. attr_name+= ` ${attr_groups.attr_list[j].attr_group_name}:${attr_groups.attr_list[j].attr_name}`
  584. }
  585. this.$set(this.order_list[i], 'attr_name', attr_name);
  586. }
  587. this.get_time();
  588. } else {
  589. this.over = true;
  590. }
  591. }
  592. })
  593. }
  594. },
  595. }
  596. </script>
  597. <style lang="scss" scoped>
  598. .order {
  599. position: absolute;
  600. width: #{750rpx};
  601. top: 0;
  602. left: 0;
  603. height: 100%;
  604. z-index: 1500;
  605. background-color: #f7f7f7;
  606. .top {
  607. position: fixed;
  608. top: 0;
  609. left: 0;
  610. background-color: #efeff4;
  611. font-size: #{32rpx};
  612. z-index: 1500;
  613. width: #{750upx};
  614. .to-top {
  615. width: #{280rpx};
  616. height: #{88rpx};
  617. .icon {
  618. width: #{22rpx};
  619. height: #{12rpx};
  620. margin-left: #{16rpx};
  621. }
  622. text {
  623. width: #{145rpx};
  624. text-align: center;
  625. word-break: break-all;
  626. text-overflow: ellipsis;
  627. display: -webkit-box;
  628. -webkit-box-orient: vertical;
  629. -webkit-line-clamp: 1;
  630. overflow: hidden;
  631. font-size: #{26rpx};
  632. color: #ff4544;
  633. }
  634. .icon-active {
  635. transform:rotate(180deg);
  636. }
  637. }
  638. .top-input {
  639. height: #{88rpx};
  640. width: #{750-280rpx};
  641. .input {
  642. width: #{570upx};
  643. height: #{56upx};
  644. background-color: white;
  645. border-radius: #{30upx};
  646. margin-left: #{28upx};
  647. >image {
  648. width: #{26upx};
  649. height: #{26upx};
  650. margin-right: #{13upx};
  651. }
  652. >text {
  653. font-size: #{26rpx};
  654. color: #b2b2b2;
  655. }
  656. }
  657. }
  658. }
  659. .do-top {
  660. position: fixed;
  661. top: #{88rpx};
  662. width: 100%;
  663. height: 100%;
  664. z-index: 1500;
  665. background-color: rgba(0,0,0,.3);
  666. .do-top-item {
  667. width: 100%;
  668. height: #{88rpx};
  669. background-color: #ffffff;
  670. font-size: #{32rpx};
  671. color: #353535;
  672. border-top: #{1rpx} solid #e2e2e2;
  673. text-align: center;
  674. line-height: #{88rpx};
  675. }
  676. .active-item {
  677. color: #ff4544;
  678. }
  679. }
  680. .item {
  681. width: #{750rpx};
  682. margin-bottom: #{20rpx};
  683. background-color: #ffffff;
  684. .item-top {
  685. width: 100%;
  686. line-height: #{80rpx};
  687. background-color: #ffffff;
  688. border-bottom: #{1rpx} solid #e2e2e2;
  689. font-size: #{26rpx};
  690. color: #ff4544;
  691. padding: 0 #{24rpx};
  692. }
  693. .item-center {
  694. width: 100%;
  695. padding: #{24rpx 24rpx 0 24rpx};
  696. .image {
  697. width: #{220rpx};
  698. height: #{220rpx};
  699. border-radius: #{16rpx};
  700. }
  701. .content {
  702. width: #{530-48rpx};
  703. min-height: #{220rpx};
  704. padding-left: #{24rpx};
  705. .name {
  706. margin-top: #{12rpx};
  707. word-break: break-all;
  708. text-overflow: ellipsis;
  709. display: -webkit-box;
  710. -webkit-box-orient: vertical;
  711. -webkit-line-clamp: 2;
  712. overflow: hidden;
  713. font-size: #{28rpx};
  714. color:#353535;
  715. }
  716. .attr {
  717. margin-top: #{16rpx};
  718. >text {
  719. font-size: #{26rpx};
  720. color:#999999;
  721. margin-right: #{16rpx};
  722. }
  723. }
  724. .num-price {
  725. font-size: #{28rpx};
  726. color: #353535;
  727. margin-top: #{24rpx};
  728. }
  729. .des-price {
  730. font-size: #{28rpx};
  731. color: #353535;
  732. margin-top: #{24rpx};
  733. }
  734. }
  735. }
  736. .item-bottom {
  737. width: #{750rpx};
  738. background-color: #ffffff;
  739. padding: #{0 24rpx 32rpx 24rpx};
  740. overflow: hidden;
  741. .swell-price {
  742. font-size: #{28rpx};
  743. color: #353535;
  744. margin-top: #{24rpx};
  745. }
  746. .button {
  747. // display: inline-block;
  748. float: right;
  749. height: #{56rpx};
  750. line-height: #{56rpx};
  751. font-size: #{28rpx};
  752. color: #ffffff;
  753. padding: 0 #{24rpx};
  754. border-radius: #{28rpx};
  755. background-color: #ff4544;
  756. margin-top: #{32rpx};
  757. }
  758. }
  759. }
  760. }
  761. .order-empty {
  762. position: absolute;
  763. top: #{555rpx};
  764. left: 50%;
  765. transform: translate(-50%, -50%);
  766. width: #{240rpx};
  767. text-align: center;
  768. >image {
  769. height: #{240rpx};
  770. width: #{240rpx};
  771. }
  772. >text {
  773. font-size: #{24rpx};
  774. color: #666666;
  775. }
  776. }
  777. .text-time {
  778. text-align: right;font-size: #{26upx};color: #999999;
  779. margin-top: #{16upx};
  780. }
  781. .search {
  782. height: #{104rpx};
  783. width: 100%;
  784. background-color: #efeff4;
  785. padding: #{20rpx 24rpx};
  786. position: relative;
  787. overflow: hidden;
  788. .delete {
  789. width: #{32rpx};
  790. height: #{32rpx};
  791. }
  792. .input {
  793. height: #{64rpx};
  794. width: #{620rpx};
  795. border-radius: #{50rpx};
  796. background-color: #ffffff;
  797. padding-left: #{32rpx};
  798. font-size: #{26rpx};
  799. color: #353535;
  800. }
  801. .delete {
  802. position: absolute;
  803. right: #{125rpx};
  804. z-index: 1600;
  805. }
  806. }
  807. .order-number {
  808. }
  809. .filal-payment-time {
  810. font-size:#{22upx};
  811. color: #ff4544;
  812. text-align: right;
  813. margin-top: #{14upx};
  814. }
  815. </style>