publishSource.vue 42 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650
  1. <template>
  2. <view class="content">
  3. <view class="content2">
  4. <view class="row1">
  5. <view class="left">
  6. <view class="top" @click="selectAddress(0)">
  7. <view class="send">装</view>
  8. <view class="title">
  9. {{dataObj.sendArea?(dataObj.sendPrivate + dataObj.sendCity+dataObj.sendArea):'选择装货地区'}}
  10. </view>
  11. </view>
  12. <view class="bottom">
  13. <input type="text" value="" placeholder="输入详细地址" v-model="dataObj.sendDetailedAddress" />
  14. </view>
  15. </view>
  16. <view class="right" @click="selectAddress(0)" v-if="!dataObj.sendArea">
  17. <view v-if='dataObj.sendArea' class="right"></view>
  18. <view class="right" v-else>
  19. <image src="../../static/right.png" style="width: 22rpx;height: 22rpx;margin-top:14rpx;">
  20. </image>
  21. </view>
  22. </view>
  23. </view>
  24. <view class="row2">
  25. <view class="left">
  26. <view class="top" @click="selectAddress(1)">
  27. <view class="collect">卸</view>
  28. <view class="title">
  29. {{dataObj.unloadArea?(dataObj.unloadPrivate + dataObj.unloadCity+dataObj.unloadArea):'选择卸货地区'}}
  30. </view>
  31. </view>
  32. <view class="bottom">
  33. <input type="text" value="" placeholder="输入详细地址" v-model="dataObj.unloadDetailedAddress" />
  34. </view>
  35. </view>
  36. <view class="right" @click="selectAddress(1)" v-if="!dataObj.unloadArea">
  37. <view v-if='dataObj.unloadArea' class="right">{{(dataObj.unloadCity+dataObj.unloadArea)}}</view>
  38. <view class="right" v-else>
  39. <image src="../../static/right.png" style="width: 22rpx;height: 22rpx;margin-top:14rpx;">
  40. </image>
  41. </view>
  42. </view>
  43. </view>
  44. </view>
  45. <view class="content3">
  46. <view class="row">
  47. <view class="left">预估总里程</view>
  48. {{dataObj.cargoDistance }}
  49. km
  50. </view>
  51. </view>
  52. <view class="content3">
  53. <view class="row" @click="isShowPopup1=true">
  54. <view class="left">货物信息</view>
  55. <view class="right flex">
  56. {{dataObj.goodsName?dataObj.goodsName+'、'+dataObj.packageType+'、'+dataObj.weight:"完善货物信息"}}
  57. <u-icon name="arrow-right" size="20"></u-icon>
  58. </view>
  59. </view>
  60. <view class="row" @click="isShowPopup2=true">
  61. <view class="left">车型车长</view>
  62. <view class="right flex">{{dataObj.carModel?dataObj.carModel+'、'+dataObj.carLength:"选择车型车长"}}<u-icon
  63. name="arrow-right" size="20"></u-icon></view>
  64. </view>
  65. </view>
  66. <view class="content3">
  67. <view class="row">
  68. <view class="left">运价单位</view>
  69. <view class="btn flex">
  70. <view class="price-item" :class="index==priceIndex?'active':''" v-for="(item,index) in priceBtnList"
  71. @click="selectPriceType(item,index)">
  72. <view class="">
  73. {{item.name}}
  74. </view>
  75. </view>
  76. </view>
  77. </view>
  78. <view class="row y-price flex">
  79. <view class="left">运价</view>
  80. <view class="right" v-if="priceBtnType==0">
  81. <input type="number" value="" placeholder="输入运费单价" class="input" v-model="dataObj.freightPrice" />
  82. </view>
  83. <view class="right" v-if="priceBtnType==1">
  84. <input type="number" value="" placeholder="输入车数" class="input" v-model="dataObj.freightPrice" />
  85. </view>
  86. <view class="right" v-if="priceBtnType==2">
  87. <input type="number" value="" placeholder="输入方数" class="input" v-model="dataObj.freightPrice" />
  88. </view>
  89. </view>
  90. </view>
  91. <view class="content3">
  92. <view class="row" @click="isShowPopup3=true">
  93. <view class="left">货站信息</view>
  94. <view class="right flex row-ellipsis">
  95. {{dataObj.contacts?dataObj.contacts+'、'+dataObj.contactsPhone+'、'+dataObj.freightStationName:"完善货站信息"}}
  96. <u-icon name="arrow-right" size="20"></u-icon>
  97. </view>
  98. </view>
  99. </view>
  100. <view class="content5">
  101. <view class="flex row" @click="selectValidityPeriod(0)">
  102. <view class="left">装车日期</view>
  103. <view class="right flex">
  104. {{dataObj.loadingDate?dataObj.loadingDate:"选择装车日期"}}
  105. <u-icon name="arrow-right" size="20"></u-icon>
  106. </view>
  107. </view>
  108. <view class="flex row" @click="selectValidityPeriod(1)">
  109. <view class="left-text">时段</view>
  110. <view class="right flex">
  111. {{dataObj.periodOfTime?dataObj.periodOfTime:'选择装时段'}}
  112. <u-icon name="arrow-right" size="20"></u-icon>
  113. </view>
  114. </view>
  115. </view>
  116. <view class="content5">
  117. <view class="row">
  118. <view class="left">备注(选填)</view>
  119. </view>
  120. <view class="row">
  121. <u--textarea v-model="dataObj.remark" placeholder="请输入内容" :count='true' maxlength='500'>
  122. </u--textarea>
  123. </view>
  124. <view class="cartype-item" style="font-size: 24rpx;" :class="item.checked?'active':''"
  125. v-for="(item,index) in remarkList" @click="selectRemarkType(item,index)">
  126. <view class="">
  127. {{item.name}}
  128. </view>
  129. </view>
  130. </view>
  131. <view class="content5">
  132. <view class="row">
  133. <view class="left">货站信息费</view>
  134. <view class="right flex"><input type="number" value="" placeholder="输入信息费金额" class="input"
  135. v-model="dataObj.stationFee" /><text style="width: 100rpx;">元/吨</text></view>
  136. </view>
  137. </view>
  138. <view class="">
  139. <view class="submit" @click="goodsSubmit">发布货源</view>
  140. </view>
  141. <u-popup :show="isShowPopup1" :round="10" closeable safeAreaInsetBottom @close="isShowPopup1=false">
  142. <view style="padding: 60rpx 40rpx;" class="popup">
  143. <view class="title">
  144. 货物信息
  145. </view>
  146. <u--form labelPosition="left" :model="dataObj" ref="uForm">
  147. <u-form-item label="货名" prop="contacts" borderBottom labelWidth="140rpx">
  148. <u--input v-model="dataObj.goodsName" border="none" placeholder="输入货名"
  149. inputAlign='right'></u--input>
  150. </u-form-item>
  151. <u-form-item label="包装类型" prop="contacts" borderBottom labelWidth="140rpx">
  152. <view style="display: flex;justify-content: flex-end;width: 100%;">
  153. <view class="price-item" :class="index==bzIndex?'active':''"
  154. v-for="(item,index) in packageTypePickerColumns" @click="selectBzType(item,index)">
  155. <view class="">
  156. {{item}}
  157. </view>
  158. </view>
  159. </view>
  160. </u-form-item>
  161. <u-form-item label="计量方式" borderBottom labelWidth="140rpx">
  162. <view style="display: flex;justify-content: flex-end;width: 100%;">
  163. <view class="price-item" :class="item.checked?'active':''"
  164. v-for="(item,index) in measuringMethodList" @click="selectJlType(item,index)">
  165. <view class="">
  166. {{item.name}}
  167. </view>
  168. </view>
  169. </view>
  170. </u-form-item>
  171. <u-form-item label="货物重量" borderBottom labelWidth="140rpx" v-if="measuringMethodList[0].checked">
  172. <u--input v-model="dataObj.weight" border="none" placeholder="输入重量"
  173. inputAlign='right'></u--input><text style="margin-left: 10rpx;">吨</text>
  174. </u-form-item>
  175. <u-form-item label="货物体积" borderBottom labelWidth="140rpx" v-if="measuringMethodList[1].checked">
  176. <u--input v-model="dataObj.volume" border="none" placeholder="输入体积"
  177. inputAlign='right'></u--input><text style="margin-left: 10rpx;">方</text>
  178. </u-form-item>
  179. <u-form-item label="预计用车数量" labelWidth="200rpx">
  180. <u--input v-model="dataObj.expectedNum" border="none" placeholder="输入用车数量"
  181. inputAlign='right'></u--input><text style="margin-left: 10rpx;">辆</text>
  182. </u-form-item>
  183. <!-- <u-form-item label="货站名称" prop="contacts" borderBottom labelWidth="140rpx">
  184. <u--input v-model="dataObj.freightStationName" border="none" placeholder="输入货站名称,不超过10个字"
  185. inputAlign='right'></u--input>
  186. </u-form-item> -->
  187. </u--form>
  188. <view class="submit" @click="goodsInfoSubmit">完成</view>
  189. </view>
  190. </u-popup>
  191. <u-popup :show="isShowPopup2" :round="10" closeable safeAreaInsetBottom @close="isShowPopup2=false">
  192. <view style="padding: 60rpx 40rpx;" class="popup">
  193. <view class="title">
  194. 车型车长
  195. </view>
  196. <view class="">
  197. 选择车型 <text style="color:rgb(170, 170, 170);margin-left: 20rpx;">(1-3个)</text>
  198. </view>
  199. <view class="cartype-item" :class="item.checked?'active':''" v-for="(item,index) in carTypeList"
  200. @click="selectCarType(item,index)">
  201. <view class="">
  202. {{item.name}}
  203. </view>
  204. </view>
  205. <view class="" style="margin: 40rp 0;">
  206. 选择车长 <text style="color:rgb(170, 170, 170);margin-left: 20rpx;">(1-3个)</text>
  207. </view>
  208. <view class="cartype-item" :class="item.checked?'active':''" v-for="(item,index) in carLengthList"
  209. @click="selectCarLength(item,index)">
  210. <view class="">
  211. {{item.name}}
  212. </view>
  213. </view>
  214. <view class="submit" @click="carInfoSubmit">完成</view>
  215. </view>
  216. </u-popup>
  217. <u-popup :show="isShowPopup3" :round="10" closeable safeAreaInsetBottom @close="isShowPopup3=false">
  218. <view style="padding: 60rpx 40rpx;" class="popup">
  219. <view class="title">
  220. 货站信息
  221. </view>
  222. <u--form labelPosition="left" :model="dataObj" ref="uForm">
  223. <u-form-item label="联系人" borderBottom labelWidth="140rpx">
  224. <u--input v-model="dataObj.contacts" border="none" placeholder="输入联系人姓名"
  225. inputAlign='right'></u--input>
  226. </u-form-item>
  227. <u-form-item label="联系人电话" borderBottom labelWidth="160rpx">
  228. <u--input v-model="dataObj.contactsPhone" border="none" placeholder="输入联系人姓名"
  229. inputAlign='right'></u--input>
  230. </u-form-item>
  231. <u-form-item label="货站名称" labelWidth="140rpx">
  232. <u--input v-model="dataObj.freightStationName" border="none" placeholder="输入货站名称,不超过10个字"
  233. inputAlign='right'></u--input>
  234. </u-form-item>
  235. </u--form>
  236. <view class="submit" @click="isShowPopup3=false">完成</view>
  237. </view>
  238. </u-popup>
  239. <u-popup :show="isShowPopup4" :round="10" closeable safeAreaInsetBottom @close="isShowPopup4=false">
  240. <view style="padding: 60rpx 40rpx;" class="popup">
  241. <view class="title">
  242. 装车时间
  243. </view>
  244. <u-line></u-line>
  245. <view class="select-date">
  246. <view class="title-two">
  247. 选择日期
  248. </view>
  249. <view class="date-list">
  250. <view class="date-list-item" :class="item.checked?'active':''" v-for="(item,index) in dateList"
  251. @click="selectDate(item,index)">
  252. {{index==0?"今天"+item.date:item.date}}
  253. </view>
  254. </view>
  255. <view class="title-two">
  256. 选择时段
  257. </view>
  258. <view class="row flex" style="margin-bottom: 20rpx;">
  259. <view class="" style="flex: 1;text-align: center;">
  260. 开始时间
  261. </view>
  262. <view class="" style="flex: 1;text-align: center;">
  263. 结束时间
  264. </view>
  265. </view>
  266. <picker-view class="picker" :value="value" @change="getime">
  267. <picker-view-column>
  268. <view class="hours" style="line-height:30px; text-align: center;"
  269. v-for="(item,index) in hoursList" :key="index">{{item}}</view>
  270. </picker-view-column>
  271. <picker-view-column>
  272. <view class="hours" style="line-height:30px; text-align: center;"
  273. v-for="(item,index) in hoursList" :key="index">{{item}}</view>
  274. </picker-view-column>
  275. </picker-view>
  276. </view>
  277. <view class="submit" @click="dateInfoSubmit" v-if="isCanBeSubmit">完成</view>
  278. <view class="fa-submit" v-if="!isCanBeSubmit">
  279. 完成
  280. </view>
  281. </view>
  282. </u-popup>
  283. <!-- <u-modal :show="isShowAlert" :title="alertTitle" :content='alertContent' :closeOnClickOverlay='false'
  284. :showCancelButton='showCancelButton' confirmColor='#F5BA3C' @confirm="$u.throttle(confirmClick(), 1000)"
  285. @close="cancelClick" @cancel="cancelClick"></u-modal>
  286. <u-modal :show="isShowAlert1" :title="alertTitle" :confirmText='confirmText' :content='alertContent'
  287. :closeOnClickOverlay='false' :showCancelButton='showCancelButton' confirmColor='#F5BA3C'
  288. @confirm="$u.throttle(confirmClick(), 1000)" @close="cancelClick" @cancel="cancelClick"></u-modal> -->
  289. <u-toast ref="uToast"></u-toast>
  290. </view>
  291. </template>
  292. <script>
  293. var _this;
  294. import {
  295. mapState
  296. } from 'vuex';
  297. export default {
  298. data() {
  299. return {
  300. isCanBeSubmit: true,
  301. isEdit: false,
  302. isCopy: false,
  303. hoursList: [
  304. '00:00',
  305. '00:30',
  306. '01:00',
  307. '01:30',
  308. '02:00',
  309. '02:30',
  310. '03:00',
  311. '03:30',
  312. '04:00',
  313. '04:30',
  314. '05:00',
  315. '05:30',
  316. '06:00',
  317. '06:30',
  318. '07:00',
  319. '07:30',
  320. '08:00',
  321. '08:30',
  322. '09:00',
  323. '09:30',
  324. '10:00',
  325. '10:00',
  326. '11:00',
  327. '11:30',
  328. '12:00',
  329. '12:30',
  330. '13:00',
  331. '13:30',
  332. '14:00',
  333. '14:30',
  334. '15:00',
  335. '15:30',
  336. '16:00',
  337. '16:30',
  338. '17:00',
  339. '17:30',
  340. '18:00',
  341. '18:30',
  342. '19:00',
  343. '19:30',
  344. '20:00',
  345. '20:30',
  346. '21:00',
  347. '21:30',
  348. '22:00',
  349. '22:30',
  350. '23:00',
  351. '23:30'
  352. ],
  353. value: ["18", "34"],
  354. checkTime: ["09:00", "17:00"],
  355. dateCheckList: [],
  356. dateList: [],
  357. jlLindex: 0,
  358. bzIndex: 0,
  359. priceIndex: 0,
  360. measuringMethodList: [{
  361. name: '重量(吨)',
  362. checked: true,
  363. },
  364. {
  365. name: '体积(方)',
  366. checked: false,
  367. }
  368. ],
  369. jlCheckList: ['重量(吨)'],
  370. carLengthCheckList: ['不限'],
  371. carTypeCheckList: [],
  372. carLengthList: [{
  373. name: '不限',
  374. checked: false
  375. },
  376. {
  377. name: '2',
  378. checked: false
  379. },
  380. {
  381. name: '3',
  382. checked: false
  383. },
  384. {
  385. name: '4',
  386. checked: false
  387. },
  388. {
  389. name: '5',
  390. checked: false
  391. },
  392. {
  393. name: '6',
  394. checked: false
  395. },
  396. {
  397. name: '7',
  398. checked: false
  399. },
  400. {
  401. name: '8',
  402. checked: false
  403. },
  404. {
  405. name: '9',
  406. checked: false
  407. },
  408. {
  409. name: '10',
  410. checked: false
  411. },
  412. {
  413. name: '11',
  414. checked: false
  415. },
  416. {
  417. name: '12',
  418. checked: false
  419. },
  420. {
  421. name: '13',
  422. checked: false
  423. },
  424. {
  425. name: '14',
  426. checked: false
  427. },
  428. {
  429. name: '15',
  430. checked: false
  431. },
  432. {
  433. name: '16',
  434. checked: false
  435. },
  436. {
  437. name: '17',
  438. checked: false
  439. },
  440. {
  441. name: '18',
  442. checked: false
  443. }
  444. ],
  445. carTypeList: [{
  446. name: '高栏',
  447. checked: false
  448. },
  449. {
  450. name: '集装箱',
  451. checked: false
  452. },
  453. {
  454. name: '平板',
  455. checked: false
  456. },
  457. {
  458. name: '厢式',
  459. checked: false
  460. },
  461. {
  462. name: '自卸',
  463. checked: false
  464. },
  465. {
  466. name: '冷藏车',
  467. checked: false
  468. },
  469. {
  470. name: '保温车',
  471. checked: false
  472. },
  473. {
  474. name: '轻型',
  475. checked: false
  476. }
  477. ],
  478. packageTypePickerColumns: ['散装', '袋装', '其他'],
  479. packageTypePicker: false,
  480. isShowPopup1: false,
  481. isShowPopup2: false,
  482. isShowPopup3: false,
  483. isShowPopup4: false,
  484. remarkCheckList: [],
  485. remarkList: [{
  486. name: "到付",
  487. checked: false,
  488. },
  489. {
  490. name: "需防雨",
  491. checked: false,
  492. },
  493. {
  494. name: "不压车",
  495. checked: false,
  496. }, {
  497. name: "合规运输",
  498. checked: false,
  499. }
  500. ],
  501. priceBtnType: '0',
  502. priceBtnList: [{
  503. name: '吨',
  504. index: 0
  505. },
  506. {
  507. name: '车',
  508. index: 1
  509. },
  510. {
  511. name: '方',
  512. index: 2
  513. }
  514. ],
  515. showCancelButton: true,
  516. qyList: [],
  517. isShowAlert: false,
  518. alertTitle: '确定发布运输任务?',
  519. alertContent: null,
  520. radioCustomStyle: {
  521. margin: '0 0 0 20rpx'
  522. },
  523. freightAdvance: false,
  524. dataObj: {
  525. commonId: '',
  526. sendPrivate: '',
  527. sendCity: '',
  528. sendArea: '',
  529. sendDetailedAddress: '',
  530. unloadPrivate: '',
  531. unloadCity: '',
  532. unloadArea: '',
  533. unloadDetailedAddress: '',
  534. cargoDistance: '',
  535. goodsName: '',
  536. packageType: '散装',
  537. measuringMethod: '重量(吨)',
  538. weight: '',
  539. volume: '',
  540. expectedNum: '',
  541. carModel: '',
  542. carLength: '',
  543. billingMethod: '0',
  544. freightPrice: '',
  545. contacts: '',
  546. contactsPhone: '',
  547. freightStationName: '',
  548. loadingDate: '',
  549. periodOfTime: '',
  550. remark: '',
  551. stationFee: '',
  552. sendLongitude: '',
  553. sendLatitude: '',
  554. unsendLongitude: '',
  555. unsendLatitude: ''
  556. },
  557. confirmText: '',
  558. isShowAlert1: false,
  559. ValidityPeriodType: '',
  560. }
  561. },
  562. onShow() {
  563. if (!this.hasLogin) {
  564. uni.$u.route('/pages/public/login');
  565. return
  566. }
  567. this.$request.baseRequest('get', '/cargoOwnerInfo/firstAuthentication', {
  568. phone: this.userInfo.phone
  569. }).then(res => {
  570. uni.setStorageSync("firstAuthentication", res.data)
  571. let _obj = res.data
  572. if (_obj.authenticationStatus == '已认证') {
  573. uni.$u.route('/pages/components/empty/index');
  574. } else if (_obj.authenticationStatus == '审核中') {
  575. uni.showToast({
  576. title: '身份信息审核中',
  577. icon: 'none'
  578. })
  579. } else if (_obj.authenticationStatus == '已过期') {
  580. this.alertTitle = '身份信息已过期!'
  581. this.showCancelButton = false
  582. this.confirmText = '立即修改'
  583. this.isShowAlert1 = true
  584. } else {
  585. this.alertTitle = '身份信息未认证,去认证?'
  586. this.confirmText = '确认'
  587. this.showCancelButton = false
  588. this.isShowAlert = true
  589. }
  590. })
  591. if (!this.isEdit || !this.isCopy) {
  592. let _faddress = uni.getStorageSync('storage_faddress');
  593. let _saddress = uni.getStorageSync('storage_saddress');
  594. if (_faddress) {
  595. this.dataObj.sendCity = this.$helper.filterUrban(_faddress.city)
  596. this.dataObj.sendArea = this.$helper.filterArea(_faddress.area)
  597. this.dataObj.sendAdCode = _faddress.adCode
  598. this.dataObj.sendPrivate = _faddress.province
  599. this.dataObj.sendDetailedAddress = _faddress.detailedAddress
  600. this.dataObj.sendLongitude = _faddress.longitude
  601. this.dataObj.sendLatitude = _faddress.latitude
  602. if (_faddress.contactPhone) {
  603. this.dataObj.senderPhone = _faddress.contactPhone
  604. }
  605. if (_faddress.contacts) {
  606. this.dataObj.sender = _faddress.contacts
  607. }
  608. } else {
  609. this.getDefaultPlace(0)
  610. }
  611. if (_saddress) {
  612. this.dataObj.unloadDetailedAddress = _saddress.detailedAddress
  613. this.dataObj.unloadCity = this.$helper.filterUrban(_saddress.city)
  614. this.dataObj.unloadArea = this.$helper.filterArea(_saddress.area)
  615. this.dataObj.unsendAdCode = _faddress.adCode
  616. this.dataObj.unloadPrivate = _saddress.province
  617. this.dataObj.unsendLongitude = _saddress.longitude
  618. this.dataObj.unsendLatitude = _saddress.latitude
  619. if (_saddress.contacts) {
  620. this.dataObj.receiver = _saddress.contacts
  621. }
  622. if (_saddress.contactPhone) {
  623. this.dataObj.receiverPhone = _saddress.contactPhone
  624. }
  625. } else {
  626. this.getDefaultPlace(1)
  627. }
  628. if (this.dataObj.sendLatitude && this.dataObj.sendLongitude && this.dataObj.unsendLatitude && this.dataObj
  629. .unsendLongitude) {
  630. this.dataObj.cargoDistance = this.$helper.getDistance(this.dataObj.unsendLatitude, this.dataObj
  631. .unsendLongitude,
  632. this.dataObj.sendLatitude, this.dataObj.sendLongitude)
  633. }
  634. }
  635. },
  636. onLoad(options) {
  637. if (options.type == 1) {
  638. this.isCopy = true
  639. }
  640. if (options.type == 2) {
  641. this.isEdit = true
  642. }
  643. if (options.type == 1 || options.type == 2) {
  644. this.dataObj = uni.getStorageSync("selectGoodObj")
  645. if (this.dataObj.packageType == '散装') {
  646. this.bzIndex = 0
  647. } else if (this.dataObj.packageType == '袋装') {
  648. this.bzIndex = 1
  649. } else {
  650. this.bzIndex = 2
  651. }
  652. let _carModel = this.dataObj.carModel.split(',')
  653. for (let i = 0; i < this.carTypeList.length; i++) {
  654. for (let k = 0; k < _carModel.length; k++) {
  655. if (this.carTypeList[i].name == _carModel[k]) {
  656. this.carTypeList[i].checked = true
  657. this.carTypeCheckList.push(this.carTypeList[i])
  658. }
  659. }
  660. }
  661. let _carLength = this.dataObj.carLength.split(',')
  662. for (let i = 0; i < this.carLengthList.length; i++) {
  663. for (let k = 0; k < _carLength.length; k++) {
  664. if (this.carLengthList[i].name == _carLength[k]) {
  665. this.carLengthList[i].checked = true
  666. this.carLengthCheckList.push(this.carLengthList[i].name)
  667. }
  668. }
  669. }
  670. let _measuringMethod = this.dataObj.measuringMethod.split(',')
  671. this.jlCheckList = []
  672. for (let i = 0; i < this.measuringMethodList.length; i++) {
  673. this.measuringMethodList[i].checked = false
  674. for (let k = 0; k < _measuringMethod.length; k++) {
  675. if (this.measuringMethodList[i].name == _measuringMethod[k]) {
  676. this.measuringMethodList[i].checked = true
  677. this.jlCheckList.push(this.measuringMethodList[i].name)
  678. }
  679. }
  680. }
  681. this.priceIndex = this.dataObj.billingMethod
  682. let _loadingDate = this.dataObj.loadingDate.split(',')
  683. }
  684. _this = this
  685. },
  686. computed: {
  687. ...mapState(['hasLogin', 'userInfo']),
  688. },
  689. methods: {
  690. goodsSubmit() {
  691. this.dataObj.commonId = this.userInfo.id
  692. if (this.validate()) return
  693. uni.showLoading({
  694. mask: true,
  695. title: '加载中'
  696. })
  697. console.log("this.dataObj", this.dataObj)
  698. this.dataObj.headSculpture = this.userInfo.avatarUrl
  699. if (this.isEdit) {
  700. this.$request.baseRequest('post', '/hyReleaseGoodsInfo/api/editTask', this.dataObj).then(res => {
  701. uni.hideLoading()
  702. uni.navigateBack()
  703. })
  704. .catch(res => {});
  705. } else {
  706. this.$request.baseRequest('post', '/hyReleaseGoodsInfo/api/addTask', this.dataObj).then(res => {
  707. uni.hideLoading()
  708. uni.navigateBack()
  709. })
  710. .catch(res => {});
  711. }
  712. },
  713. getime(e) {
  714. let val = e.detail.value
  715. console.log(val)
  716. this.checkTime[0] = this.hoursList[val[0]]
  717. this.checkTime[1] = this.hoursList[val[1]]
  718. if (val[0] > val[1]) {
  719. uni.showToast({
  720. icon: 'none',
  721. title: "开始时间不能大于结束时间!"
  722. })
  723. this.isCanBeSubmit = false
  724. return
  725. } else {
  726. this.isCanBeSubmit = true
  727. }
  728. console.log(this.checkTime)
  729. },
  730. selectDate(val, index) {
  731. console.log("val--index", val, index)
  732. let _startCheckIndex = ''
  733. let _endCheckIndex = ''
  734. if (this.dateCheckList.length != 0) {
  735. _startCheckIndex = this.dateCheckList[0].index
  736. _endCheckIndex = this.dateCheckList[this.dateCheckList.length - 1].index
  737. console.log("选中开始", _startCheckIndex)
  738. console.log("选中结束", _endCheckIndex)
  739. }
  740. if (this.dateCheckList.length == 0) {
  741. val.checked = !val.checked
  742. if (val.checked) {
  743. this.dateCheckList.push(val)
  744. }
  745. } else if (this.dateCheckList.length == 1) {
  746. val.checked = !val.checked
  747. if (!val.checked) {
  748. this.dateCheckList = []
  749. } else {
  750. this.dateCheckList = []
  751. if (val.index < _startCheckIndex) {
  752. for (let i = val.index; i <= _startCheckIndex; i++) {
  753. this.dateList[i].checked = true
  754. this.dateCheckList.push(this.dateList[i])
  755. }
  756. } else if (val.index > _startCheckIndex) {
  757. for (let i = _startCheckIndex; i <= val.index; i++) {
  758. console.log(i)
  759. this.dateList[i].checked = true
  760. this.dateCheckList.push(this.dateList[i])
  761. }
  762. }
  763. }
  764. } else if (this.dateCheckList.length == 2) {
  765. //点开始或点结束
  766. val.checked = !val.checked
  767. if (val.index == _startCheckIndex) {
  768. this.dateCheckList.splice(0, 1)
  769. }
  770. if (val.index == _endCheckIndex) {
  771. this.dateCheckList.splice(1, 1)
  772. }
  773. if (val.index < _startCheckIndex) {
  774. this.dateCheckList = []
  775. for (let i = val.index; i <= _endCheckIndex; i++) {
  776. this.dateList[i].checked = true
  777. this.dateCheckList.push(this.dateList[i])
  778. }
  779. }
  780. if (val.index > _endCheckIndex) {
  781. this.dateCheckList = []
  782. for (let i = _startCheckIndex; i <= val.index; i++) {
  783. this.dateList[i].checked = true
  784. this.dateCheckList.push(this.dateList[i])
  785. }
  786. }
  787. } else {
  788. let _dateCheckList = JSON.parse(JSON.stringify(this.dateCheckList))
  789. if (val.index == _startCheckIndex || val.index == _endCheckIndex) {
  790. val.checked = !val.checked
  791. for (let i = 0; i < _dateCheckList.length; i++) {
  792. if (val.index == _dateCheckList[i].index) {
  793. this.dateCheckList.splice(i, 1)
  794. }
  795. }
  796. } else if (_startCheckIndex < val.index && val.index < _endCheckIndex) {
  797. for (let i = 0; i < this.dateList.length; i++) {
  798. this.dateList[i].checked = false
  799. }
  800. this.dateCheckList = []
  801. } else if (val.index < _startCheckIndex) {
  802. this.dateCheckList = []
  803. for (let i = val.index; i <= _endCheckIndex; i++) {
  804. this.dateList[i].checked = true
  805. this.dateCheckList.push(this.dateList[i])
  806. }
  807. } else if (val.index > _endCheckIndex) {
  808. this.dateCheckList = []
  809. for (let i = _startCheckIndex; i <= val.index; i++) {
  810. console.log(i)
  811. this.dateList[i].checked = true
  812. this.dateCheckList.push(this.dateList[i])
  813. }
  814. }
  815. }
  816. console.log("this.dateCheckList", this.dateCheckList)
  817. },
  818. selectJlType(val, index) {
  819. val.checked = !val.checked
  820. if (val.checked) {
  821. this.jlCheckList.push(val.name)
  822. } else {
  823. let _jlCheckList = JSON.parse(JSON.stringify(this.jlCheckList))
  824. for (let i = 0; i < _jlCheckList.length; i++) {
  825. if (_jlCheckList[i] == val.name) {
  826. this.jlCheckList.splice(i, 1)
  827. if (this.jlCheckList.length == 0 && val.name == '重量(吨)') {
  828. this.jlCheckList.push('体积(方)')
  829. this.measuringMethodList[1].checked = true
  830. this.measuringMethodList[0].checked = false
  831. }
  832. if (this.jlCheckList.length == 0 && val.name == '体积(方)') {
  833. this.jlCheckList.push('重量(吨)')
  834. this.measuringMethodList[0].checked = true
  835. this.measuringMethodList[1].checked = false
  836. }
  837. }
  838. }
  839. }
  840. console.log('this.jlCheckList', this.jlCheckList)
  841. },
  842. selectBzType(val, index) {
  843. this.bzIndex = index
  844. this.dataObj.packageType = val
  845. },
  846. selectPriceType(val, index) {
  847. this.priceIndex = index
  848. this.priceBtnType = index
  849. this.dataObj.billingMethod = index
  850. },
  851. carInfoSubmit() {
  852. if (this.carTypeCheckList.length == 0) {
  853. uni.showToast({
  854. icon: 'none',
  855. title: "至少选择1个车型!"
  856. })
  857. return
  858. }
  859. if (this.carLengthCheckList.length == 0) {
  860. uni.showToast({
  861. icon: 'none',
  862. title: "至少选择1个车长!"
  863. })
  864. return
  865. }
  866. this.dataObj.carLength = this.carLengthCheckList.toString()
  867. this.dataObj.carModel = this.carTypeCheckList.toString()
  868. this.isShowPopup2 = false
  869. },
  870. selectRemarkType(val, index) {
  871. this.dataObj.remark += val.name + ','
  872. },
  873. selectCarType(val, index) {
  874. if (this.carTypeCheckList.length > 2 && !val.checked) {
  875. uni.showToast({
  876. icon: 'none',
  877. title: "最多选择3个车型!"
  878. })
  879. return
  880. }
  881. val.checked = !val.checked
  882. if (val.checked) {
  883. this.carTypeCheckList.push(val.name)
  884. } else {
  885. let _carTypeCheckList = JSON.parse(JSON.stringify(this.carTypeCheckList))
  886. for (let i = 0; i < _carTypeCheckList.length; i++) {
  887. if (_carTypeCheckList[i] == val.name) {
  888. this.carTypeCheckList.splice(i, 1)
  889. }
  890. }
  891. }
  892. console.log("carTypeCheckList", this.carTypeCheckList)
  893. },
  894. selectCarLength(val, index) {
  895. if (this.carLengthCheckList.length > 2 && !val.checked && index != 0) {
  896. uni.showToast({
  897. icon: 'none',
  898. title: "最多选择3个车长!"
  899. })
  900. return
  901. }
  902. this.carLengthCheckList = []
  903. val.checked = !val.checked
  904. // this.carLengthList[0].checked = false
  905. console.log(val)
  906. if (index == 0 && val.checked) {
  907. this.carLengthCheckList = ['不限']
  908. for (let i = 1; i < this.carLengthList.length; i++) {
  909. this.carLengthList[i].checked = false
  910. }
  911. console.log("this.carLengthCheckList", this.carLengthCheckList)
  912. return
  913. } else {
  914. this.carLengthList[0].checked = false
  915. }
  916. for (let i = 0; i < this.carLengthList.length; i++) {
  917. if (this.carLengthList[i].checked) {
  918. this.carLengthCheckList.push(this.carLengthList[i].name)
  919. }
  920. }
  921. },
  922. packageTypeConfirm(val) {
  923. console.log(val)
  924. this.dataObj.packageType = val.value[0]
  925. this.packageTypePicker = false
  926. },
  927. goodsInfoSubmit() {
  928. this.dataObj.measuringMethod = this.jlCheckList.toString()
  929. this.isShowPopup1 = false
  930. },
  931. dateInfoSubmit() {
  932. let _dateList = []
  933. for (let i = 0; i < this.dateCheckList.length; i++) {
  934. _dateList.push(this.dateCheckList[i].date)
  935. }
  936. this.dataObj.loadingDate = _dateList.toString()
  937. this.dataObj.periodOfTime = this.checkTime.toString()
  938. this.isShowPopup4 = false
  939. },
  940. funDate() {
  941. let timestamp = new Date(new Date().toLocaleDateString()).getTime();
  942. let basetime = 24 * 60 * 60 * 1000;
  943. for (let i = 0; i < 8; i++) {
  944. let _date = timestamp + basetime * i
  945. let _obj = {
  946. date: new Date(_date).toLocaleDateString().substring(5).replace("/", "."),
  947. index: i,
  948. checked: false,
  949. }
  950. this.dateList.push(_obj)
  951. console.log("this.dateList", this.dateList)
  952. }
  953. console.log(this.dateList)
  954. },
  955. validate() {
  956. if (uni.$u.test.isEmpty(this.dataObj.commonId)) {
  957. this.$refs.uToast.show({
  958. type: 'error',
  959. message: "货主不能为空!",
  960. })
  961. return true
  962. }
  963. if (uni.$u.test.isEmpty(this.dataObj.sendArea)) {
  964. this.$refs.uToast.show({
  965. type: 'error',
  966. message: "请选择装货地区!",
  967. })
  968. return true
  969. }
  970. if (uni.$u.test.isEmpty(this.dataObj.sendDetailedAddress)) {
  971. this.$refs.uToast.show({
  972. type: 'error',
  973. message: "装货详细地址不能为空!",
  974. })
  975. return true
  976. }
  977. if (uni.$u.test.isEmpty(this.dataObj.unloadArea)) {
  978. this.$refs.uToast.show({
  979. type: 'error',
  980. message: "请选择卸货地区!",
  981. })
  982. return true
  983. }
  984. if (uni.$u.test.isEmpty(this.dataObj.unloadDetailedAddress)) {
  985. this.$refs.uToast.show({
  986. type: 'error',
  987. message: "卸货详细地址不能为空!",
  988. })
  989. return true
  990. }
  991. if (uni.$u.test.isEmpty(this.dataObj.packageType)) {
  992. this.$refs.uToast.show({
  993. type: 'error',
  994. message: "包装类型不能为空!",
  995. })
  996. return true
  997. }
  998. if (uni.$u.test.isEmpty(this.dataObj.goodsName)) {
  999. this.$refs.uToast.show({
  1000. type: 'error',
  1001. message: "货名不能为空!",
  1002. })
  1003. return true
  1004. }
  1005. if (uni.$u.test.isEmpty(this.dataObj.measuringMethod)) {
  1006. this.$refs.uToast.show({
  1007. type: 'error',
  1008. message: "计量方式不能为空!",
  1009. })
  1010. return true
  1011. }
  1012. if (this.dataObj.measuringMethod == '重量(吨)') {
  1013. if (uni.$u.test.isEmpty(this.dataObj.weight)) {
  1014. this.$refs.uToast.show({
  1015. type: 'error',
  1016. message: "货物重量不能为空!",
  1017. })
  1018. return true
  1019. }
  1020. } else if (this.dataObj.measuringMethod == '体积(方)') {
  1021. if (uni.$u.test.isEmpty(this.dataObj.volume)) {
  1022. this.$refs.uToast.show({
  1023. type: 'error',
  1024. message: "货物体积不能为空!",
  1025. })
  1026. return true
  1027. }
  1028. } else {
  1029. if (uni.$u.test.isEmpty(this.dataObj.volume) || uni.$u.test.isEmpty(this.dataObj.weight)) {
  1030. this.$refs.uToast.show({
  1031. type: 'error',
  1032. message: "货物体积、货物重量不能为空!",
  1033. })
  1034. return true
  1035. }
  1036. }
  1037. if (uni.$u.test.isEmpty(this.dataObj.expectedNum)) {
  1038. this.$refs.uToast.show({
  1039. type: 'error',
  1040. message: "预计用车数量不能为空!",
  1041. })
  1042. return true
  1043. }
  1044. if (uni.$u.test.isEmpty(this.dataObj.carModel)) {
  1045. this.$refs.uToast.show({
  1046. type: 'error',
  1047. message: "车型不能为空!",
  1048. })
  1049. return true
  1050. }
  1051. if (uni.$u.test.isEmpty(this.dataObj.carLength)) {
  1052. this.$refs.uToast.show({
  1053. type: 'error',
  1054. message: "车长不能为空!",
  1055. })
  1056. return true
  1057. }
  1058. if (uni.$u.test.isEmpty(this.dataObj.billingMethod)) {
  1059. this.$refs.uToast.show({
  1060. type: 'error',
  1061. message: "运价单位不能为空!",
  1062. })
  1063. return true
  1064. }
  1065. if (uni.$u.test.isEmpty(this.dataObj.freightPrice)) {
  1066. this.$refs.uToast.show({
  1067. type: 'error',
  1068. message: "运价不能为空!",
  1069. })
  1070. return true
  1071. }
  1072. if (
  1073. this.dataObj.freightPrice < 0 || this.dataObj.freightPrice > 100000 || (
  1074. String(this.dataObj.freightPrice).indexOf('.') != -1 && String(this.dataObj.freightPrice).length -
  1075. (String(this.dataObj.freightPrice).indexOf(
  1076. '.') + 1) > 2)
  1077. ) {
  1078. uni.showToast({
  1079. title: '运价输入错误!',
  1080. duration: 2000,
  1081. icon: "none",
  1082. });
  1083. return true
  1084. }
  1085. if (uni.$u.test.isEmpty(this.dataObj.contacts)) {
  1086. this.$refs.uToast.show({
  1087. type: 'error',
  1088. message: "联系人不能为空!",
  1089. })
  1090. return true
  1091. }
  1092. if (uni.$u.test.isEmpty(this.dataObj.contactsPhone)) {
  1093. this.$refs.uToast.show({
  1094. type: 'error',
  1095. message: "联系人电话不能为空!",
  1096. })
  1097. return true
  1098. }
  1099. if (uni.$u.test.isEmpty(this.dataObj.freightStationName)) {
  1100. this.$refs.uToast.show({
  1101. type: 'error',
  1102. message: "货站名称不能为空!",
  1103. })
  1104. return true
  1105. }
  1106. if (uni.$u.test.isEmpty(this.dataObj.loadingDate)) {
  1107. this.$refs.uToast.show({
  1108. type: 'error',
  1109. message: "装车日期不能为空!",
  1110. })
  1111. return true
  1112. }
  1113. if (uni.$u.test.isEmpty(this.dataObj.periodOfTime)) {
  1114. this.$refs.uToast.show({
  1115. type: 'error',
  1116. message: "时段不能为空!",
  1117. })
  1118. return true
  1119. }
  1120. // if (uni.$u.test.isEmpty(this.dataObj.stationFee)) {
  1121. // this.$refs.uToast.show({
  1122. // type: 'error',
  1123. // message: "货站信息费不能为空!",
  1124. // })
  1125. // return true
  1126. // }
  1127. },
  1128. confirmClick() {
  1129. uni.$u.throttle(this.requestdata, 500)
  1130. },
  1131. requestdata() {
  1132. if (this.dataDetails.type == '元/吨') {
  1133. this.dataObj.billingMethod = 0
  1134. } else {
  1135. this.dataObj.billingMethod = 1
  1136. }
  1137. if (this.dataObj.freightAdvance) {
  1138. this.dataObj.freightAdvance = 1
  1139. } else {
  1140. this.dataObj.freightAdvance = 0
  1141. }
  1142. if (!this.dataObj.receiverIdcard) {
  1143. this.dataObj.receiverIdcard = ''
  1144. }
  1145. if (!this.dataObj.receiverCreditCode) {
  1146. this.dataObj.receiverCreditCode = ''
  1147. }
  1148. this.dataObj.carModel = this.carTypeCheckList.toString()
  1149. this.dataObj.commonId = this.userInfo.id
  1150. uni.$u.route('/pages/order/signContract', {
  1151. obj: JSON.stringify(this.dataObj),
  1152. type: 1
  1153. });
  1154. },
  1155. cancelClick() {
  1156. this.isShowAlert = false
  1157. },
  1158. //获取默认装货地、卸货地
  1159. getDefaultPlace(type) {
  1160. // 0时获取默认装货地址,1时获取默认卸货地址 通过选择获取的地址无需获取默认地址
  1161. uni.showLoading({
  1162. mask: true,
  1163. title: '加载中...'
  1164. })
  1165. this.$request.baseRequest('get', '/cargoOwnerAddressInfo/addressList', {
  1166. commonId: this.userInfo.id
  1167. }).then(res => {
  1168. uni.hideLoading()
  1169. for (let i = 0; i < res.data.length; i++) {
  1170. if (res.data[i].defaultShipment == 1 && type == 0) {
  1171. this.dataObj.sendCity = res.data[i].city
  1172. this.dataObj.sendArea = res.data[i].area
  1173. this.dataObj.sendPrivate = res.data[i].province
  1174. this.dataObj.sendDetailedAddress = res.data[i].detailedAddress
  1175. this.dataObj.sendLongitude = res.data[i].longitude
  1176. this.dataObj.sendLatitude = res.data[i].latitude
  1177. this.dataObj.sender = res.data[i].contacts
  1178. this.dataObj.senderPhone = res.data[i].contactPhone
  1179. }
  1180. if (res.data[i].defaultReceipt == 1 && type == 1) {
  1181. this.dataObj.unloadDetailedAddress = res.data[i].detailedAddress
  1182. this.dataObj.unloadCity = res.data[i].city
  1183. this.dataObj.unloadArea = res.data[i].area
  1184. this.dataObj.unloadPrivate = res.data[i].province
  1185. this.dataObj.unsendLongitude = res.data[i].longitude
  1186. this.dataObj.unsendLatitude = res.data[i].latitude
  1187. this.dataObj.receiver = res.data[i].contacts
  1188. this.dataObj.receiverPhone = res.data[i].contactPhone
  1189. }
  1190. }
  1191. if (this.dataObj.sendLatitude && this.dataObj.sendLongitude && this.dataObj.unsendLatitude &&
  1192. this.dataObj.unsendLongitude) {
  1193. this.dataObj.cargoDistance = this.$helper.getDistance(this.dataObj.unsendLatitude, this
  1194. .dataObj
  1195. .unsendLongitude, this.dataObj.sendLatitude, this.dataObj.sendLongitude)
  1196. }
  1197. })
  1198. .catch(res => {
  1199. uni.hideLoading()
  1200. uni.showToast({
  1201. title: res.message,
  1202. icon: 'none',
  1203. duration: 2000
  1204. })
  1205. });
  1206. },
  1207. changeHandler(e) {
  1208. const {
  1209. columnIndex,
  1210. value,
  1211. values,
  1212. index,
  1213. picker = this.$refs.uPicker
  1214. } = e
  1215. },
  1216. selectAddress(type) {
  1217. uni.$u.route('/pages/release/selectAddress', {
  1218. type: type,
  1219. });
  1220. },
  1221. selectValidityPeriod(type) {
  1222. this.funDate()
  1223. if (this.isEdit || this.isCopy) {
  1224. let _loadingDate = this.dataObj.loadingDate.split(',')
  1225. for (let i = 0; i < this.dateList.length; i++) {
  1226. this.dateList[i].checked = false
  1227. for (let k = 0; k < _loadingDate.length; k++) {
  1228. if (this.dateList[i].date == _loadingDate[k]) {
  1229. this.dateList[i].checked = true
  1230. this.dateCheckList.push(this.dateList[i])
  1231. }
  1232. }
  1233. }
  1234. }
  1235. this.isShowPopup4 = true
  1236. },
  1237. }
  1238. }
  1239. </script>
  1240. <style scoped lang="scss">
  1241. .input {
  1242. text-align: right;
  1243. width: 100%;
  1244. }
  1245. .content {
  1246. height: 100vh;
  1247. overflow: scroll;
  1248. }
  1249. .title {
  1250. padding: 0 20rpx;
  1251. display: flex;
  1252. justify-content: center;
  1253. position: relative;
  1254. .nav-title {
  1255. font-size: 32rpx;
  1256. }
  1257. .back {
  1258. position: absolute;
  1259. left: 20rpx;
  1260. }
  1261. .search {
  1262. display: flex;
  1263. align-items: center;
  1264. position: absolute;
  1265. right: 20rpx;
  1266. }
  1267. }
  1268. .fixed1 {
  1269. height: var(--status-bar-height);
  1270. }
  1271. .row {
  1272. display: flex;
  1273. justify-content: space-between;
  1274. }
  1275. .content1 {
  1276. background: white;
  1277. margin: 40rpx 20rpx 0 20rpx;
  1278. border-radius: 20rpx;
  1279. padding: 40rpx;
  1280. .select-sf {
  1281. color: #171717;
  1282. font-size: 34rpx;
  1283. font-weight: 600;
  1284. }
  1285. .select-sf1 {
  1286. color: #999999;
  1287. }
  1288. .right {
  1289. color: #CBCBCB
  1290. }
  1291. }
  1292. .content2,
  1293. .content3,
  1294. .content5 {
  1295. box-sizing: border-box;
  1296. background: white;
  1297. border-radius: 20rpx;
  1298. padding: 20rpx;
  1299. margin: 20rpx;
  1300. .row {
  1301. margin: 30rpx;
  1302. }
  1303. .row1,
  1304. .row2 {
  1305. display: flex;
  1306. justify-content: space-between;
  1307. align-items: center;
  1308. .left .top {
  1309. display: flex;
  1310. }
  1311. }
  1312. }
  1313. .content5{
  1314. .left{
  1315. width: 100px;
  1316. }
  1317. .right{
  1318. overflow-x: auto;
  1319. }
  1320. }
  1321. .select-type {
  1322. display: flex;
  1323. justify-content: flex-end;
  1324. }
  1325. .top-title {
  1326. background: #fff;
  1327. padding: 20rpx;
  1328. position: fixed;
  1329. z-index: 100;
  1330. top: 0;
  1331. box-sizing: border-box;
  1332. width: 100%;
  1333. }
  1334. .content2 {
  1335. padding: 40rpx;
  1336. .row1,
  1337. .row2 {
  1338. .left {
  1339. width: 100%;
  1340. }
  1341. .right {
  1342. color: #CBCBCB
  1343. }
  1344. }
  1345. .row2 {
  1346. margin-top: 40rpx;
  1347. }
  1348. .top {
  1349. display: flex;
  1350. align-items: center;
  1351. }
  1352. .bottom {
  1353. margin-top: 10rpx;
  1354. padding-left: 72rpx;
  1355. }
  1356. .title {
  1357. font-size: 36rpx;
  1358. font-weight: 700;
  1359. color: #171717;
  1360. width: 90%;
  1361. justify-content: flex-start;
  1362. // text-align:left;
  1363. }
  1364. .collect {
  1365. width: 40rpx;
  1366. height: 40rpx;
  1367. line-height: 40rpx;
  1368. background: #F5BA3C;
  1369. color: white;
  1370. // font-size:1px;
  1371. padding: 6rpx;
  1372. border-radius: 50%;
  1373. text-align: center;
  1374. }
  1375. .send {
  1376. width: 40rpx;
  1377. height: 40rpx;
  1378. line-height: 40rpx;
  1379. background: #101010;
  1380. color: white;
  1381. padding: 6rpx;
  1382. border-radius: 50%;
  1383. text-align: center;
  1384. }
  1385. }
  1386. .content3 {
  1387. .left {
  1388. width: 160rpx;
  1389. }
  1390. }
  1391. .content4 {
  1392. margin: 20rpx;
  1393. padding-left: 20rpx;
  1394. .title {
  1395. color: #999999;
  1396. }
  1397. .btn-text {
  1398. color: #F5BA3C;
  1399. border: 1px solid #F5BA3C;
  1400. border-radius: 40rpx;
  1401. padding: 0rpx 10rpx;
  1402. box-sizing: border-box;
  1403. }
  1404. }
  1405. .submit {
  1406. width: 90%;
  1407. margin: 50rpx auto;
  1408. font-size: 36rpx;
  1409. font-weight: 500;
  1410. color: #FFFFFF;
  1411. background: #F5BA3C;
  1412. text-align: center;
  1413. padding: 20rpx 0;
  1414. border-radius: 50rpx;
  1415. }
  1416. .fa-submit {
  1417. width: 90%;
  1418. margin: 50rpx auto;
  1419. font-size: 36rpx;
  1420. font-weight: 500;
  1421. color: #FFFFFF;
  1422. background: rgb(153, 153, 153);
  1423. text-align: center;
  1424. padding: 20rpx 0;
  1425. border-radius: 50rpx;
  1426. }
  1427. .select-data {
  1428. color: #999999;
  1429. }
  1430. .row-bgc {
  1431. background: #F7F8FA;
  1432. padding: 20rpx 30rpx;
  1433. box-sizing: border-box;
  1434. border-radius: 10rpx;
  1435. }
  1436. .car-input {
  1437. // padding:20rpx;
  1438. // box-sizing: border-box;
  1439. // border-radius: 10px;
  1440. }
  1441. .car-line {
  1442. margin: 0 20rpx;
  1443. }
  1444. .car-row {
  1445. display: flex;
  1446. background: white;
  1447. padding: 20rpx;
  1448. box-sizing: border-box;
  1449. border-radius: 10rpx;
  1450. }
  1451. uni-navigator {
  1452. display: inline-block;
  1453. color: #F5BA3C;
  1454. }
  1455. .popup .title {
  1456. position: relative;
  1457. top: -30rpx;
  1458. font-size: 36rpx;
  1459. font-weight: 700;
  1460. }
  1461. .price-item {
  1462. display: inline-block;
  1463. background: rgb(243, 243, 243);
  1464. border: 1px solid rgb(243, 243, 243);
  1465. text-align: center;
  1466. margin-left: 20rpx;
  1467. padding: 14rpx 30rpx;
  1468. box-sizing: border-box;
  1469. font-size: 28rpx;
  1470. border-radius: 10rpx;
  1471. }
  1472. .cartype-item {
  1473. display: inline-block;
  1474. width: calc(25% - 40rpx);
  1475. background: rgb(243, 243, 243);
  1476. border: 1px solid rgb(243, 243, 243);
  1477. text-align: center;
  1478. margin: 20rpx;
  1479. padding: 14rpx 10rpx;
  1480. box-sizing: border-box;
  1481. font-size: 28rpx;
  1482. border-radius: 10rpx;
  1483. }
  1484. .active {
  1485. background: rgb(251, 240, 229) !important;
  1486. border: 1px solid rgb(255, 134, 0) !important;
  1487. color: rgb(255, 134, 0);
  1488. }
  1489. .y-price {
  1490. justify-content: space-between;
  1491. .left {
  1492. width: 320rpx;
  1493. }
  1494. .right {
  1495. width: 100%;
  1496. }
  1497. }
  1498. .date-list-item {
  1499. display: inline-block;
  1500. background: rgb(243, 243, 243);
  1501. border: 1px solid rgb(243, 243, 243);
  1502. box-sizing: border-box;
  1503. width: calc(25% - 20rpx);
  1504. text-align: center;
  1505. margin: 10rpx;
  1506. padding: 10rpx 0;
  1507. border-radius: 10rpx;
  1508. }
  1509. .title-two {
  1510. margin: 20rpx 0;
  1511. }
  1512. .time1 {
  1513. width: 100%;
  1514. margin: 0 auto;
  1515. background-color: #FFFFFF;
  1516. color: #000;
  1517. height: 450rpx;
  1518. .top {
  1519. width: 690rpx;
  1520. margin: 0 auto;
  1521. height: 100rpx;
  1522. line-height: 100rpx;
  1523. text {
  1524. font-weight: bold;
  1525. &:nth-child(1) {
  1526. font-size: 28rpx;
  1527. color: #999;
  1528. }
  1529. &:nth-child(2) {
  1530. font-size: 28rpx;
  1531. color: #0A84FF;
  1532. }
  1533. }
  1534. }
  1535. .tip12 {
  1536. width: 100%;
  1537. height: 100rpx;
  1538. view {
  1539. width: 50%;
  1540. text-align: center;
  1541. line-height: 100rpx;
  1542. font-size: 40rpx;
  1543. color: #000000;
  1544. }
  1545. }
  1546. .hours {
  1547. font-size: 30rpx;
  1548. font-weight: bold;
  1549. color: #000;
  1550. }
  1551. .minutes {
  1552. font-size: 30rpx;
  1553. font-weight: bold;
  1554. color: #000;
  1555. }
  1556. }
  1557. .picker {
  1558. width: 100%;
  1559. height: 300rpx;
  1560. }
  1561. .row-ellipsis {
  1562. text-overflow: ellipsis;
  1563. white-space: nowrap;
  1564. overflow: hidden;
  1565. }
  1566. </style>