index.vue 25 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040
  1. <!-- 货源 -->
  2. <template>
  3. <view class="content">
  4. <!-- <view v-if="!isSearch"> -->
  5. <!-- <view class="fixed">
  6. <view class='title flex flex-center'>
  7. <view>订单</view>
  8. <u-icon class="search" name="search" color="" size="28" @click="search"></u-icon>
  9. </view>
  10. <u-tabs :list="tabList" @click="clickTab" lineColor='#2772FB' :current='tabIndex' :activeStyle="{
  11. color: '#2772FB',
  12. fontWeight: 'bold',
  13. transform: 'scale(1.05)'
  14. }"></u-tabs>
  15. </view> -->
  16. <view class="top-content">
  17. <view class="fixed1"></view>
  18. <view class="fix-content">
  19. <u-search placeholder="搜索订单" v-model="searchKeyWord" bgColor='white' :actionStyle='searchStyle'
  20. @custom="getSearch" @search="getSearch" :clearabled="true"></u-search>
  21. <view class="tab-content">
  22. <u-tabs :list="tabList" @click="clickTab" lineColor='transparent' :current='tabIndex'
  23. :inactiveStyle="{color:'white'}" :activeStyle="{
  24. color: '#2772FB',
  25. fontWeight: 'bold',
  26. transform: 'scale(1.05)',
  27. background:'white',
  28. padding:'10rpx 20rpx',
  29. 'border-radius':'40rpx'
  30. }" class="tabs"></u-tabs>
  31. <view class="right-btn" @click="showMenu=true">
  32. <u-icon name="grid-fill" color="white" size="28"></u-icon>
  33. <view class="">
  34. 全部
  35. </view>
  36. </view>
  37. </view>
  38. </view>
  39. </view>
  40. <view class="all-menu">
  41. <u-transition :show="showMenu" mode="fade">
  42. <view class="transition">
  43. <view v-for="(item,index) in tabList" :key='index' class="transition-item-style"
  44. :class="tabIndex==index?'menu-active':''" @click="clickTab({index:index})">
  45. {{item.name}}
  46. </view>
  47. </view>
  48. </u-transition>
  49. <view class="modal-black" v-show="showMenu" @click="closeMenu"></view>
  50. </view>
  51. <mescroll-body ref="mescrollRef" :up="upOption" @init="mescrollInit" @down="downCallback" @up="upCallback" class="mescroll">
  52. <view class="evaluatePage flex flex-space-between" v-show="tabIndex == 10" @click="evaluationRecord">
  53. <view class="left flex flex-space-between">
  54. <u-icon size="20" name="edit-pen"></u-icon>
  55. <view style="margin-left: 20prx;">我的评价</view>
  56. </view>
  57. <view class="right">
  58. <u-icon size="20" name="arrow-right"></u-icon>
  59. </view>
  60. </view>
  61. <view :id="'good'+good.id" class="good-list" v-for="good in goods" :key="good.id"
  62. @click="toDetail(good.id)">
  63. <view style="padding: 0 35rpx 20rpx 35rpx;">
  64. <view class="flex flex-space-between row1">
  65. <view class="item1">
  66. {{good.orderNo}}
  67. <!-- {{good.goodsName}} -->
  68. </view>
  69. <view class="item2">
  70. {{good.cargoOwnerStatus}}
  71. </view>
  72. </view>
  73. <view class="flex row2">
  74. <view class="left">
  75. <view class="top">
  76. <view class="ssx">{{$helper.getProvinceAbbreviation(good.sendPrivate?good.sendPrivate:good.sendCity)}}</view>
  77. <view class="level2-title">{{$helper.filterUrban(good.sendCity)}}</view>
  78. </view>
  79. <view class="bottom">{{$helper.filterArea(good.sendArea)}}</view>
  80. </view>
  81. <view class="jt-image">
  82. <image class="jt-icon" src="@/static/images/order/jt.png" mode='widthFix'>
  83. </image>
  84. </view>
  85. <view class="right">
  86. <view class="top">
  87. <view class="ssx">
  88. {{$helper.getProvinceAbbreviation(good.unloadPrivate?good.unloadPrivate:good.unloadCity)}}
  89. </view>
  90. <view class="level2-title">{{$helper.filterUrban(good.unloadCity)}}</view>
  91. </view>
  92. <view class="bottom">
  93. {{$helper.filterArea(good.unloadArea)}}
  94. </view>
  95. </view>
  96. </view>
  97. <view class="flex row3 s-row">
  98. <view class="flex align-center">
  99. <image class="hz" src="@/static/images/news/sj.png"></image>
  100. <view style="margin-right: 20rpx;" @click.stop="goTodriverDetail(good)">{{good.driverName}}</view>
  101. <!-- <view style="margin-right: 20rpx;">{{good.driverCall}}</view> -->
  102. <image class="hz-good" src="@/static/images/order/good-img.png"></image>
  103. <view>{{good.goodsName}}</view>
  104. </view>
  105. <view class="flex align-center">
  106. <view style="margin-right: 20rpx;">运距 {{good.distance}}km</view>
  107. <view v-if="good.cargoOwnerStatus!='已完结'" class="car">{{good.freight?good.freight:good.freightInfo.freight}}{{good.billingMethod==0?'元/吨':'元/车'}}</view>
  108. <view v-else class="car">{{good.freight?good.freight:good.freightInfo.freight}}{{good.billingMethod==0?'元/吨':'元/车'}}</view>
  109. </view>
  110. <!-- <view class="right">
  111. <view class="flex fontsize-26 row">
  112. <view>{{good.compName}}</view>
  113. <view class="sline"></view>
  114. <view>{{good.cargoOwner}}</view>
  115. </view>
  116. <view class="flex align-center">
  117. <view class="fontsize-26 ">运距 {{good.distance}}km</view>
  118. </view>
  119. </view> -->
  120. </view>
  121. <view class="row4 flex align-center">
  122. <view class="time">{{good.updateDate}}</view>
  123. </view>
  124. <view class="row5 flex flex-end">
  125. <!-- <image class="jt-icon" src="@/static/images/order/position.png" mode='widthFix'
  126. @click.stop="toMap(good)">
  127. </image> -->
  128. <view v-if="good.cargoOwnerStatus=='运输中'||good.cargoOwnerStatus=='已完结'" class="start normal look-map" @click.stop="toMap(good)">
  129. 查看轨迹</view>
  130. <view class="stop" @click.stop="accept(good,1)" v-if="good.cargoOwnerStatus=='待接单'">接受
  131. </view>
  132. <!-- <view class="stop active" @click.stop="accept(good,1)">接受</view> -->
  133. <view class="normal" @click.stop="accept(good,2)" v-if="good.cargoOwnerStatus=='待接单'">拒绝
  134. </view>
  135. <view class="normal" @click.stop="stop(good)" v-if="good.cargoOwnerStatus=='未装车'">终止</view>
  136. <!-- <view class="stop active" @click.stop="stop(good)">终止</view> -->
  137. <!-- confirmLoading(good,3) -->
  138. <view v-if="good.cargoOwnerStatus=='待确认装车'" class="start normal" @click.stop="toDetail(good.id)"
  139. >确认装车</view>
  140. <!-- <view class="start normal" @click.stop="confirmLoading(good,1)">确认装车</view> -->
  141. <view class="start normal" v-if="good.cargoOwnerStatus!='待接单'&&good.cargoOwnerStatus!='未装车'" @click.stop="$helper.contactCustomerService()">
  142. 联系客服</view>
  143. <view class="start normal" @click.stop="toDetail(good.id)"
  144. v-if="good.cargoOwnerStatus=='待收货'">确认卸车</view>
  145. <!-- <view class="start normal" @click.stop="confirmLoading(good,4)"
  146. v-if="good.cargoOwnerStatus=='待收货'">确认卸车</view> -->
  147. <!-- <view class="start normal" @click.stop="confirmLoading(good,2)">确认卸车</view> -->
  148. <!-- <view class="normal" @click.stop="stop(good)" v-if="good.cargoOwnerStatus=='已结算'">付款</view> -->
  149. <!-- <view class="normal" @click.stop="stop(good)"
  150. v-if="good.cargoOwnerStatus=='待还款'||good.cargoOwnerStatus=='已还款'">还款</view> -->
  151. <!-- <view class="start normal" @click.stop="addevaluation(good)" v-if="good.cargoOwnerStatus=='已完结'">评价</view> --><!-- driverEvaluated 为1是已评价过-->
  152. <view class="start normal" @click.stop="addevaluation(good)" v-if="good.cargoOwnerStatus=='已完结' && good.ownerEvaluated != 1" >评价</view>
  153. </view>
  154. </view>
  155. </view>
  156. </mescroll-body>
  157. <!-- </view> -->
  158. <!-- <view v-else class="search-view">
  159. <view class="flex">
  160. <u-icon name="arrow-left" color="" size="20" class="back-icon" @click="back()"></u-icon>
  161. <u-search placeholder="可按编号、货主、收发地查找" placeholderColor="#AFB3BF" :actionStyle="textColor"
  162. bgColor="#F5F6FA" v-model="searchKeyWord" actionText='取消' @custom="cancel" @search="getSearch">
  163. </u-search>
  164. </view>
  165. <view class="near-search">
  166. <view class="flex flex-space-between">
  167. <view class="near-search-text">最近搜索</view>
  168. <u-icon name="trash-fill" color="#AFB3BF" size="20" class="back-icon" @click="del"></u-icon>
  169. </view>
  170. <view class="">
  171. <view v-for="(item,index) in useSearchList" :key="index" class="item-style inline-block">
  172. {{item}}
  173. </view>
  174. </view>
  175. </view>
  176. </view> -->
  177. <u-modal :show="isShowAlert" :title="alertTitle" :content='alertContent' :confirmText='confirmText'
  178. :closeOnClickOverlay='true' :showCancelButton='showCancelButton' @confirm="confirmClick"
  179. @close="cancelClick" @cancel="cancelClick" class="modal">
  180. <view style="margin: 0 auto;">
  181. <u-radio-group v-model="radiovalue1" placement="" v-if='isShowTerminationReason'>
  182. <u-radio :customStyle="{marginBottom: '8px'}" v-for="(item, index) in radiolist1" :key="index"
  183. :label="item.name" :name="item.name" @change="radioChange">
  184. </u-radio>
  185. </u-radio-group>
  186. </view>
  187. <u--textarea class="row" v-model="value2" placeholder="终止原因描述" count maxlength='50'
  188. v-if='isShowTerminationReason'>
  189. </u--textarea>
  190. </u-modal>
  191. <u-toast ref="uToast"></u-toast>
  192. </view>
  193. </template>
  194. <script>
  195. var that
  196. import {
  197. mapState
  198. } from 'vuex';
  199. import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
  200. import {
  201. apiGoods
  202. } from "@/api/mock.js"
  203. export default {
  204. mixins: [MescrollMixin], // 使用mixin
  205. data() {
  206. return {
  207. confirmText: '',
  208. showCancelButton: true,
  209. type: null,
  210. objData: {},
  211. showMenu: false,
  212. searchStyle: {
  213. background: "#317AFE",
  214. color: 'white',
  215. position: "absolute",
  216. right: "30rpx",
  217. padding: "6rpx 20rpx",
  218. margin:'0 20rpx 0 0',
  219. "border-radius": '30rpx'
  220. },
  221. upOption: {
  222. page: {
  223. size: 10 // 每页数据的数量,默认10
  224. },
  225. noMoreSize: 0, // 配置列表的总数量要大于等于5条才显示'-- END --'的提示
  226. empty: {
  227. tip: '暂无相关数据'
  228. }
  229. },
  230. searchKeyWord: '',
  231. useSearchList: [],
  232. mescroll: null,
  233. isShowTerminationReason: false,
  234. id: '',
  235. value2: '',
  236. radiolist1: [{
  237. name: '已与货主协商',
  238. disabled: false
  239. },
  240. {
  241. name: '货主原因终止',
  242. disabled: false
  243. },
  244. {
  245. name: '司机个人原因终止',
  246. disabled: false
  247. }, {
  248. name: '其他',
  249. disabled: false
  250. }
  251. ],
  252. radiovalue1: '已与货主协商',
  253. confirmText: '终止',
  254. alertTitle: '确定终止订单?',
  255. alertContent: "",
  256. isShowAlert: false,
  257. textColor: {
  258. "color": "#AFB3BF"
  259. },
  260. isSearch: false,
  261. startPlace: '齐齐哈尔齐齐哈尔',
  262. endPlace: '全国',
  263. goods: [], // 数据列表
  264. src: 'https://cdn.uviewui.com/uview/album/1.jpg',
  265. height: "", // 需要固定swiper的高度
  266. tabList: [{
  267. name: '全部'
  268. }, {
  269. name: '待接单'
  270. }, {
  271. name: '未发运'
  272. }, {
  273. name: '运输中'
  274. }, {
  275. name: '待收货'
  276. },
  277. {
  278. name: '待结算'
  279. },
  280. {
  281. name: '已结算'
  282. },
  283. {
  284. name: '待还款'
  285. },
  286. {
  287. name: '已还款'
  288. },
  289. {
  290. name: '已完结'
  291. },
  292. {
  293. name: '评价'
  294. },
  295. ],
  296. tabIndex: 0,
  297. scrollTop: 0
  298. }
  299. },
  300. computed: {
  301. ...mapState(['hasLogin', 'userInfo', 'firstAuthentication'])
  302. },
  303. onTabItemTap(e) {
  304. // tab 点击时执行,此处直接接收单击事件
  305. uni.pageScrollTo({
  306. scrollTop: 0,
  307. duration: 300
  308. });
  309. },
  310. created() {
  311. //#ifdef APP-PLUS
  312. // this.getLngLat();
  313. //#endif
  314. },
  315. // async onLoad() {
  316. // that = this
  317. // // #ifdef APP-PLUS
  318. // let _status = await that.$request.baseRequest('get', '/cargoOwnerInfo/firstAuthentication', {
  319. // phone: this.userInfo.phone,
  320. // }).then(res => {
  321. // if(res.data){
  322. // return res.data.authenticationStatus
  323. // }
  324. // })
  325. // if (_status == '已禁用') {
  326. // this.isShowAlert = true
  327. // this.alertTitle = '账号审核中'
  328. // this.confirmText = '退出APP'
  329. // this.showCancelButton = false
  330. // } else {
  331. // console.log(1231233212332312312213)
  332. // }
  333. // // #endif
  334. // },
  335. onShow() {
  336. this.upCallback({
  337. size: 10,
  338. num: 1
  339. })
  340. that.$request.baseRequest('get', '/newsInfo/unreadMessage', {
  341. reCommonId: this.userInfo.id,
  342. }).then(res3 => {
  343. if (res3.data||res3.data==0) {
  344. let name = 'myTip';
  345. let value = res3.data
  346. if (value == 0) {
  347. uni.removeTabBarBadge({
  348. index: 2
  349. })
  350. }
  351. that.$store.commit('$uStore', {
  352. name,
  353. value
  354. });
  355. if (value != 0 && value) {
  356. uni.setTabBarBadge({
  357. index: 2,
  358. text: value + ""
  359. })
  360. }
  361. }
  362. })
  363. },
  364. // onPageScroll(res) {
  365. // this.scrollTop = res.scrollTop
  366. // console.log("页面滚动了", res.scrollTop)
  367. // if (this.scrollTop > 1200) {
  368. // uni.setTabBarItem({
  369. // index: 1,
  370. // text: '返回顶部',
  371. // iconPath: 'static/images/common/top@2x.png',
  372. // selectedIconPath: 'static/images/common/top@2x.png'
  373. // })
  374. // } else {
  375. // uni.setTabBarItem({
  376. // index: 1,
  377. // text: '订单',
  378. // iconPath: 'static/images/common/dingdan@2x(1).png',
  379. // selectedIconPath: 'static/images/common/dingdan@2x.png'
  380. // })
  381. // }
  382. // },
  383. methods: {
  384. goTodriverDetail(val){
  385. uni.$u.route('/pages/order/driverDetail',{
  386. driver:JSON.stringify(val)
  387. });
  388. },
  389. addevaluation(val){
  390. uni.$u.route('/pages/order/addEvaluation',{val:JSON.stringify(val)});
  391. },
  392. evaluationRecord(){
  393. uni.$u.route('/pages/order/evaluationRecord');
  394. },
  395. toMap(val) {
  396. uni.$u.route('/pages/order/map', val);
  397. },
  398. closeMenu() {
  399. this.showMenu = false
  400. },
  401. accept(item, type) {
  402. this.objData = item
  403. this.type = type
  404. if (type == 1) {
  405. this.alertTitle = '确定接受订单?'
  406. this.confirmText = '确定'
  407. } else if (type == 2) {
  408. this.alertTitle = '确定拒绝订单?'
  409. this.confirmText = '确定'
  410. } else {
  411. this.alertTitle = '确定终止订单?'
  412. this.confirmText = '终止'
  413. }
  414. this.isShowAlert = true
  415. },
  416. // 完结
  417. closed(item) {
  418. let that = this
  419. this.$request.baseRequest('post', '/orderInfo/api/editEnd', {
  420. id: item.id,
  421. }).then(res => {
  422. if (res.code == 200) {
  423. this.$refs.uToast.show({
  424. type: 'success',
  425. message: "提交成功",
  426. complete() {
  427. that.upCallback({
  428. size: 10,
  429. num: 1
  430. })
  431. }
  432. })
  433. }
  434. })
  435. .catch(res => {
  436. uni.$u.toast(res.message);
  437. });
  438. },
  439. confirmLoading(item, type) {
  440. this.objData = item
  441. this.type = type
  442. if (type == 3) {
  443. this.alertTitle = '确认装车?'
  444. this.confirmText = '确定'
  445. } else if (type == 4) {
  446. this.alertTitle = '确认卸车?'
  447. this.confirmText = '确定'
  448. }
  449. this.isShowAlert = true
  450. // uni.$u.route('/pages/order/confirmLoading', item);
  451. },
  452. // confirmUnLoading(item) {
  453. // uni.$u.route('/pages/order/confirmUnloading', item);
  454. // },
  455. back() {
  456. uni.navigateBack(-1)
  457. },
  458. mescrollInit(mescroll) {
  459. this.mescroll = mescroll;
  460. },
  461. radioChange(n) {
  462. console.log('radioChange', n);
  463. },
  464. stop(item) {
  465. // // 货主接单
  466. // if (item.orderStatusKey == 1) {
  467. // this.isShowTerminationReason = false
  468. // } else {
  469. // this.isShowTerminationReason = true
  470. // }
  471. this.alertTitle = '确定终止订单?'
  472. this.id = item.id
  473. this.isShowAlert = true
  474. },
  475. init() {
  476. },
  477. del() {
  478. this.isShowAlert = true
  479. },
  480. confirmClick() {
  481. var that =this
  482. // // #ifdef APP-PLUS
  483. // if (this.alertTitle == '账号审核中') {
  484. // if (uni.getSystemInfoSync().platform == 'ios') {
  485. // plus.ios.import("UIApplication").sharedApplication().performSelector("exit")
  486. // } else if (uni.getSystemInfoSync().platform == 'android') {
  487. // plus.runtime.quit();
  488. // }
  489. // return
  490. // }
  491. // // #endif
  492. that.isShowAlert = false
  493. if (this.type == 1 || this.type == 2) {
  494. let _title = ''
  495. this.$request.baseRequest('post', '/orderInfo/api/orderReceiving', {
  496. id: this.objData.id,
  497. flag: this.type
  498. }).then(res => {
  499. if (res.code == 200) {
  500. if (this.type == 1) {
  501. _title = '接单成功!'
  502. } else {
  503. _title = '拒绝订单成功!'
  504. }
  505. this.$refs.uToast.show({
  506. type: 'success',
  507. message: _title,
  508. complete() {
  509. that.mescroll.resetUpScroll()
  510. }
  511. })
  512. } else {
  513. if (this.type == 1) {
  514. _title = '接单失败'
  515. } else {
  516. _title = '拒绝订单失败'
  517. }
  518. this.$refs.uToast.show({
  519. type: 'success',
  520. message: _title,
  521. complete() {
  522. that.mescroll.resetUpScroll()
  523. }
  524. })
  525. }
  526. })
  527. .catch(res => {
  528. uni.$u.toast(res.message);
  529. });
  530. } else if (this.type == 3 || this.type == 4) {
  531. let _flag = ''
  532. if (this.type == 3) _flag = 1
  533. if (this.type == 4) _flag = 2
  534. this.$request.baseRequest('post', '/carrierInfo/cargoOwnerLoadingAdd', {
  535. id: this.objData.id,
  536. loadingFlag: _flag,
  537. flag: 1
  538. }).then(res => {
  539. if (res.code == 200) {
  540. this.$refs.uToast.show({
  541. type: 'success',
  542. message: "提交成功",
  543. complete() {
  544. that.upCallback({
  545. size: 10,
  546. num: 1
  547. })
  548. }
  549. })
  550. }
  551. })
  552. .catch(res => {
  553. uni.$u.toast(res.message);
  554. });
  555. } else {
  556. this.$request.baseRequest('post', '/orderInfo/api/end', {
  557. id: this.id,
  558. terminator: 2,
  559. }).then(res => {
  560. if (res.code == 200) {
  561. this.$refs.uToast.show({
  562. type: 'success',
  563. message: '终止订单成功',
  564. })
  565. } else {
  566. this.$refs.uToast.show({
  567. type: 'success',
  568. message: '终止订单失败',
  569. })
  570. }
  571. that.mescroll.resetUpScroll()
  572. })
  573. .catch(res => {
  574. uni.$u.toast(res.message);
  575. });
  576. }
  577. },
  578. cancelClick() {
  579. this.isShowAlert = false
  580. },
  581. getSearch(e) {
  582. console.log("点击搜索", e)
  583. this.upCallback({
  584. size: 10,
  585. num: 1
  586. })
  587. },
  588. cancel() {
  589. this.isSearch = false
  590. },
  591. toDetail(id) {
  592. uni.$u.route('/pages/order/orderDetails', {
  593. id: id,
  594. });
  595. },
  596. upCallback(page) {
  597. if (!this.searchType) {
  598. this.searchType = 0
  599. }
  600. this.$request.baseRequest('get', '/orderInfo/selectCargoOwnerOrder', {
  601. cargoCommonId: this.userInfo.id,
  602. searchKeyWord: this.searchKeyWord,
  603. searchType: this.searchType,
  604. pageSize: page.size,
  605. currentPage: page.num
  606. }).then(res => {
  607. this.isSearch = false
  608. if (page.num == 1) this.goods = [];
  609. this.goods = this.goods.concat(res.data.records); //追加新数据
  610. this.mescroll.endBySize(res.data.records.length, res.data.total);
  611. uni.hideLoading()
  612. })
  613. .catch(res => {
  614. uni.$u.toast(res.message);
  615. });
  616. },
  617. clickTab(val) {
  618. uni.showLoading({
  619. mask: true
  620. })
  621. console.log(val)
  622. this.searchType = val.index
  623. this.tabIndex = val.index
  624. this.upCallback({
  625. size: 10,
  626. num: 1
  627. })
  628. this.showMenu = false
  629. },
  630. search() {
  631. this.isSearch = true
  632. //获取缓存搜索数据
  633. this.useSearchList = uni.getStorageSync('useSearchList')
  634. if (!this.useSearchList) this.useSearchList = [];
  635. }
  636. }
  637. }
  638. </script>
  639. <style scoped lang="scss">
  640. .content{
  641. padding-bottom: 160px;
  642. }
  643. .ssx{
  644. position:relative;top:3rpx;
  645. }
  646. .top-content {
  647. background: url(../../static/images/order/bg.png) no-repeat;
  648. background-size: cover;
  649. padding: 20rpx;
  650. position: fixed;
  651. z-index: 99;
  652. width: 100%;
  653. // margin-top: var(--status-bar-height);
  654. // padding-bottom: 320rpx;
  655. }
  656. .fix-content{
  657. // width: 96%;
  658. margin-right: 20rpx;
  659. }
  660. // .banner {
  661. // width: 100%;
  662. // position: relative;
  663. // }
  664. // .fixed,
  665. // .fixed1 {
  666. // background: #2772FB;
  667. // position: fixed;
  668. // top: var(--status-bar-height);
  669. // z-index: 999;
  670. // width: 100%;
  671. // }
  672. // .fixed {
  673. // .title {
  674. // background: white;
  675. // position: relative;
  676. // font-size: 36rpx;
  677. // font-weight: 500;
  678. // color: rgba(0, 0, 0, 0.85);
  679. // .search {
  680. // position: absolute;
  681. // right: 20rpx;
  682. // }
  683. // }
  684. // }
  685. .fixed1 {
  686. top: 0;
  687. height: var(--status-bar-height);
  688. background: #317AFE;
  689. // position: fixed;
  690. // z-index: 9999;
  691. }
  692. // .banner-img {
  693. // width: 100%;
  694. // }
  695. // .head {
  696. // position: absolute;
  697. // width: calc(100% - 108rpx);
  698. // bottom: 0;
  699. // background: white;
  700. // margin: 0 20rpx;
  701. // border-radius: 20rpx;
  702. // .item1,
  703. // .item3 {
  704. // width: 40%;
  705. // .text {
  706. // text-overflow: ellipsis;
  707. // overflow: hidden;
  708. // white-space: nowrap;
  709. // }
  710. // }
  711. // .item1 .text {
  712. // text-align: left;
  713. // }
  714. // .item3 .text {
  715. // text-align: right;
  716. // }
  717. // }
  718. .change-btn {
  719. width: 86rpx;
  720. height: 86rpx;
  721. }
  722. .good-list {
  723. background-color: white;
  724. margin: 20rpx;
  725. padding: 20rpx 0rpx 0 0;
  726. border-radius: 20rpx;
  727. .row1 {
  728. .item1 {
  729. color: #333333;
  730. }
  731. .item2 {
  732. color: #FE6300;
  733. }
  734. }
  735. .row2 {
  736. margin: 30rpx 0;
  737. display: flex;
  738. justify-content: center;
  739. .left {
  740. float: left;
  741. width: 40%;
  742. display: flex;
  743. flex-direction: column;
  744. align-items: center;
  745. .top {
  746. display: flex;
  747. justify-content: flex-start;
  748. }
  749. .bottom {
  750. display: flex;
  751. justify-content: flex-start;
  752. font-size: 24rpx;
  753. color: #878787;
  754. margin-top: 10rpx;
  755. }
  756. }
  757. .right {
  758. float: right;
  759. display: flex;
  760. flex-direction: column;
  761. align-items: center;
  762. width: 40%;
  763. .top {
  764. display: flex;
  765. justify-content: flex-end;
  766. }
  767. .bottom {
  768. display: flex;
  769. justify-content: flex-end;
  770. font-size: 24rpx;
  771. color: #878787;
  772. margin-top: 10rpx;
  773. }
  774. }
  775. }
  776. .row3 {
  777. background: #F5F6FA;
  778. padding: 20rpx;
  779. border-radius: 10rpx;
  780. color: #333333;
  781. .hz {
  782. width: 74rpx;
  783. height: 74rpx;
  784. margin-right: 30rpx;
  785. }
  786. .hz-good {
  787. width: 44rpx;
  788. height: 44rpx;
  789. margin: 0 30rpx;
  790. }
  791. }
  792. .row4 {
  793. margin: 20rpx 0;
  794. .time {
  795. color: #999999;
  796. margin-right: 20rpx;
  797. }
  798. .car {
  799. font-size: 28rpx;
  800. color: #000000;
  801. }
  802. }
  803. .row5 {
  804. margin: 20rpx 0;
  805. font-size: 28rpx;
  806. .stop {
  807. border-radius: 33px;
  808. border: 1px solid #FE6300;
  809. padding: 13rpx 31rpx;
  810. margin-right: 20rpx;
  811. color: #FE6300;
  812. }
  813. .normal {
  814. border-radius: 33px;
  815. border: 1px solid #CDCDCD;
  816. padding: 6px 15px;
  817. margin-right: 10px;
  818. }
  819. }
  820. }
  821. .jt-icon {
  822. position: relative;
  823. top: 6rpx;
  824. width: 60rpx;
  825. margin: 0 20rpx;
  826. }
  827. .row {
  828. margin: 10rpx 0;
  829. align-items: center;
  830. }
  831. // .item-bottom {
  832. // background: #F0F5FF;
  833. // padding: 0 30rpx;
  834. // .name {
  835. // font-size: 26rpx;
  836. // font-weight: 700;
  837. // color: #000000;
  838. // margin-left: 30rpx;
  839. // }
  840. // .hp {
  841. // margin: 30rpx;
  842. // }
  843. // .number-color {
  844. // margin: 0 10rpx;
  845. // }
  846. // .qd {
  847. // background: linear-gradient(97deg, #4FABFD 0%, #2772FB 100%);
  848. // border-radius: 13px;
  849. // font-size: 29rpx;
  850. // font-weight: 400;
  851. // color: #FFFFFF;
  852. // padding: 10rpx 35rpx;
  853. // }
  854. // }
  855. .dw {
  856. align-items: center;
  857. }
  858. .mescroll {
  859. // margin-top: calc(var(--status-bar-height) + 140rpx);
  860. top: 280rpx;
  861. }
  862. .sline {
  863. height: 28rpx;
  864. width: 1px;
  865. background: black;
  866. margin: 0 20rpx;
  867. }
  868. .search-view {
  869. margin-top: var(--status-bar-height);
  870. background: white;
  871. padding: 0 20rpx;
  872. }
  873. .back-icon {
  874. margin-right: 20rpx;
  875. }
  876. .near-search-text {
  877. margin: 20rpx 0;
  878. }
  879. .item-style {
  880. background: #F5F6FA;
  881. padding: 11rpx 24rpx;
  882. margin-right: 20rpx;
  883. border-radius: 10px;
  884. font-size: 26rpx;
  885. color: #333333;
  886. }
  887. /deep/.u-modal__content {
  888. flex-direction: column;
  889. }
  890. .tab-content {
  891. position: relative;
  892. padding-right: 100rpx;
  893. }
  894. .right-btn {
  895. position: absolute;
  896. width: 88rpx;
  897. height: 88rpx;
  898. background: #317AFE;
  899. box-shadow: -14px 0px 8px -8px rgba(0, 53, 149, 0.21);
  900. display: flex;
  901. flex-direction: column;
  902. right: 0;
  903. top: 0;
  904. bottom: 0;
  905. margin: auto;
  906. color: white;
  907. align-items: center;
  908. justify-content: center;
  909. }
  910. .tabs {
  911. // background: red;
  912. margin-top: 20rpx;
  913. overflow-x: scroll;
  914. }
  915. /deep/.u-transition {
  916. border-radius: 0 0 50rpx 50rpx;
  917. }
  918. .transition {
  919. background: white;
  920. padding-bottom: 40rpx;
  921. .transition-item-style {
  922. display: inline-block;
  923. width: calc(25% - 40rpx);
  924. text-align: center;
  925. box-sizing: border-box;
  926. background: #F7F8FA;
  927. border-radius: 40px;
  928. margin: 20rpx 20rpx 0 20rpx;
  929. padding: 16rpx 0;
  930. }
  931. .menu-active {
  932. background: #2772FB;
  933. color: white;
  934. }
  935. }
  936. .modal-black {
  937. background: black;
  938. height: 100vh;
  939. width: 100vw;
  940. position: absolute;
  941. z-index: 999;
  942. opacity: 0.3;
  943. }
  944. .all-menu {
  945. position: absolute;
  946. z-index: 99;
  947. top: 260rpx;
  948. }
  949. .look-map {
  950. background: #2772FB;
  951. border:1px solid #2772FB;
  952. color: white;
  953. }
  954. .evaluatePage{
  955. background: white;
  956. margin: 20rpx;
  957. padding: 20rpx;
  958. border-radius: 20rpx;
  959. }
  960. </style>