Issueandreceipt_task_details.vue 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476
  1. <template>
  2. <view class="warp">
  3. <view class="topInfo" v-if='retreatList.inOutType!="退库"'>
  4. <view class="topInfo-item">
  5. <view class="flex info">
  6. <view class="logo">
  7. <image src="../../../static/img/reject.png" mode=""
  8. v-if="OutList.taskStatus == '已驳回'||EnterList.taskStatus == '已驳回'" style="height: 40rpx;">
  9. </image><!-- 驳回 -->
  10. <image src="../../../static/img/tongguo.png" mode=""
  11. v-else-if="OutList.taskStatus == '已通过'||EnterList.taskStatus == '已通过'||OutList.taskStatus == '执行中'"
  12. style="height: 40rpx;"></image><!-- 通过 -->
  13. <image src="../../../static/img/daishenhe.png" mode=""
  14. v-else-if="OutList.taskStatus == '审核中'||OutList.taskStatus == '待审核'||EnterList.taskStatus == '待审核'"
  15. style="height: 40rpx;"></image><!-- 待审核 -->
  16. </view>
  17. <view class="infoText" v-if="OutList.taskStatus">{{OutList.taskStatus}}</view>
  18. <view class="infoText" v-else>{{EnterList.taskStatus}}</view>
  19. </view>
  20. <view class="infoData" v-if="OutList.updateDate">{{OutList.updateDate}}</view>
  21. <view class="infoData" v-else>{{EnterList.updateDate}}</view>
  22. </view>
  23. </view>
  24. <view class="content1">
  25. <u-form :model="OutList" ref="uForm">
  26. <u-form-item label="任务类型" prop="inOutType" label-width="140" class="uForm_item">
  27. <u-input v-model="OutList.inOutType" input-align="right" disabled v-if="OutList.inOutType" />
  28. <u-input v-model="EnterList.inOutType" input-align="right" disabled v-else />
  29. </u-form-item>
  30. <view v-if="retreatList.judge == 3 && retreatList">
  31. <!-- 退库 -->
  32. <view class="uForm_item">
  33. <view class="title part2">{{retreatList.inOutType}}</view>
  34. <view class='row'>
  35. <view class="left">编号</view>
  36. <text selectable="true" class="right">退库({{retreatList.inOutTaskNo}})</text>
  37. </view>
  38. <view class='row'>
  39. <view class="left">仓库</view>
  40. <view class="right">{{retreatList.warehouseName}}</view>
  41. </view>
  42. <view class='row'>
  43. <view class="left">出库类型</view>
  44. <view class="right">{{retreatList.inOutType}}</view>
  45. </view>
  46. <view class='row' v-if="retreatList.inOutType == '移库出库'">
  47. <view class="left" style="width: 180rpx;">移库任务编号</view>
  48. <text selectable="true" class="right">{{retreatList.moveTaskNo}}</text>
  49. </view>
  50. <view class='row' v-if="retreatList.inOutType != '移库出库'">
  51. <view class="left">合同编号</view>
  52. <text selectable="true" class="right">退库({{retreatList.contractNo}}}</text>
  53. </view>
  54. <view class='row'>
  55. <view class="left">货名</view>
  56. <view class="right">{{retreatList.goodsName}}</view>
  57. </view>
  58. <view class='row'>
  59. <view class="left">重量(吨)</view>
  60. <view class="right">{{retreatList.weight}}</view>
  61. </view>
  62. <view class='row'>
  63. <view class="left">预计出库日期</view>
  64. <view class="right">{{retreatList.predictDate}}</view>
  65. </view>
  66. <!-- <view class='row'>
  67. <view class="left">预估运费(元/吨)</view>
  68. <view class="right">{{retreatList.estimatedFreight}}</view>
  69. </view> -->
  70. <view class='row'>
  71. <view class="left">收货人</view>
  72. <view class="right">{{retreatList.agent}}</view>
  73. </view>
  74. </view>
  75. <view class="uForm_item">
  76. <u-form-item label="品级" prop="grade" label-width="150" disabled>
  77. <u-input v-model="retreatList.grade" input-align="right" placeholder="" @click='show=true'
  78. disabled />
  79. </u-picker>
  80. </u-form-item>
  81. <u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190">
  82. <u-input v-model="retreatList.bulkDensity" input-align="right" placeholder="" disabled />
  83. </u-form-item>
  84. <u-form-item label="水分(%)<=" prop="waterContent" label-width="160">
  85. <u-input v-model="retreatList.waterContent" input-align="right" placeholder="" disabled />
  86. </u-form-item>
  87. <u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
  88. <u-input v-model="retreatList.unitPrice" input-align="right" placeholder="" disabled />
  89. </u-form-item>
  90. </view>
  91. </view>
  92. <view v-if="OutList.judge == 1">
  93. <view class="uForm_item">
  94. <!-- 出库 -->
  95. <view class="title part2">{{OutList.inOutType}}</view>
  96. <view class='row'>
  97. <view class="left">编号</view>
  98. <text selectable="true" class="right">出库({{OutList.inOutTaskNo}})</text>
  99. </view>
  100. <view class='row'>
  101. <view class="left">仓库</view>
  102. <view class="right">{{OutList.warehouseName}}</view>
  103. </view>
  104. <view class='row'>
  105. <view class="left">出库类型</view>
  106. <view class="right">{{OutList.inOutType}}</view>
  107. </view>
  108. <view class='row' v-if="OutList.inOutType == '移库出库'">
  109. <view class="left" style="width: 180rpx;">移库任务编号</view>
  110. <text selectable="true" class="right">{{OutList.moveTaskNo}}</text>
  111. </view>
  112. <view class='row' v-if="OutList.inOutType != '移库出库'">
  113. <view class="left">合同编号</view>
  114. <text selectable="true" class="right">{{OutList.contractNo}}</text>
  115. </view>
  116. <view class='row'>
  117. <view class="left">货名</view>
  118. <view class="right">{{OutList.goodsName}}</view>
  119. </view>
  120. <view class='row'>
  121. <view class="left">重量(吨)</view>
  122. <view class="right">{{OutList.weight}}</view>
  123. </view>
  124. <view class='row'>
  125. <view class="left">预计出库日期</view>
  126. <view class="right">{{OutList.predictDate}}</view>
  127. </view>
  128. <!-- <view class='row'>
  129. <view class="left">预估运费(元/吨)</view>
  130. <view class="right">{{OutList.estimatedFreight}}</view>
  131. </view> -->
  132. <view class='row'>
  133. <view class="left">发货人</view>
  134. <view class="right">{{OutList.agent}}</view>
  135. </view>
  136. </view>
  137. <view class="uForm_item">
  138. <u-form-item label="品级" prop="grade" label-width="150" v-if="retreatList.inOutType != '退库'">
  139. <u-input v-model="OutList.grade" input-align="right" placeholder="" disabled />
  140. </u-form-item>
  141. <u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190"
  142. v-if="retreatList.inOutType != '退库'">
  143. <u-input v-model="OutList.bulkDensity" input-align="right" placeholder="" disabled />
  144. </u-form-item>
  145. <u-form-item label="水分(%)<=" prop="waterContent" label-width="160"
  146. v-if="retreatList.inOutType != '退库'">
  147. <u-input v-model="OutList.waterContent" input-align="right" placeholder="" disabled />
  148. </u-form-item>
  149. <u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160"
  150. v-if="retreatList.inOutType != '退库'">
  151. <u-input v-model="OutList.unitPrice" input-align="right" placeholder="" disabled />
  152. </u-form-item>
  153. <u-form-item label="业务描述" prop="businessDescribe" label-width="160" label-position="top"
  154. v-if="OutList.inOutType != '移库出库'">
  155. <u-input v-model="OutList.businessDescribe" input-align="left" placeholder="请输入业务描述"
  156. type="textarea" class="textarea" maxlength="150" disabled />
  157. </u-form-item>
  158. <u-form-item v-if="retreatList.inOutType!='退库'" label="仓位号(选填)" prop="binNumber"
  159. label-width="170">
  160. <u-input v-model="OutList.binNumber" input-align="right" placeholder="未指定" disabled />
  161. </u-form-item>
  162. </view>
  163. </view>
  164. <view v-if="EnterList.judge == 2 && EnterList">
  165. <view class="uForm_item">
  166. <!-- 入库 -->
  167. <view class="title part2">{{EnterList.inOutType}}</view>
  168. <view class='row'>
  169. <view class="left">编号</view>
  170. <text selectable="true" class="right">入库({{EnterList.inOutTaskNo}})</text>
  171. </view>
  172. <view class='row'>
  173. <view class="left">仓库</view>
  174. <view class="right">{{EnterList.warehouseName}}</view>
  175. </view>
  176. <view class='row'>
  177. <view class="left">入库类型</view>
  178. <view class="right">{{EnterList.inOutType}}</view>
  179. </view>
  180. <view class='row' v-if="EnterList.inOutType == '移库入库'">
  181. <view class="left" style="width: 180rpx;">移库任务编号</view>
  182. <text selectable="true" class="right">{{EnterList.moveTaskNo}}</text>
  183. </view>
  184. <view class='row' v-if="EnterList.inOutType != '移库入库'">
  185. <view class="left">合同编号</view>
  186. <text selectable="true" class="right">{{EnterList.contractNo}}</text>
  187. </view>
  188. <view class='row'>
  189. <view class="left">货名</view>
  190. <view class="right">{{EnterList.goodsName}}</view>
  191. </view>
  192. <view class='row'>
  193. <view class="left">重量(吨)</view>
  194. <view class="right">{{EnterList.weight}}</view>
  195. </view>
  196. <view class='row'>
  197. <view class="left">预计入库日期</view>
  198. <view class="right">{{EnterList.predictDate}}</view>
  199. </view>
  200. <!-- <view class='row'>
  201. <view class="left">预估运费(元/吨)</view>
  202. <view class="right">{{EnterList.estimatedFreight}}</view>
  203. </view> -->
  204. <view class='row'>
  205. <view class="left">收货人</view>
  206. <view class="right">{{EnterList.agent}}</view>
  207. </view>
  208. </view>
  209. <view class="uForm_item">
  210. <u-form-item label="品级" prop="grade" label-width="150" v-if="EnterList.inOutType != '移库入库' ">
  211. <u-input v-model="EnterList.grade" input-align="right" placeholder="请选择品级"
  212. @click='show=true' disabled />
  213. </u-picker>
  214. </u-form-item>
  215. <u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190"
  216. v-if="EnterList.inOutType != '移库入库'">
  217. <u-input v-model="EnterList.bulkDensity" input-align="right" placeholder="请输入容重占比"
  218. disabled />
  219. </u-form-item>
  220. <u-form-item label="水分(%)<=" prop="waterContent" label-width="160"
  221. v-if="EnterList.inOutType != '移库入库'">
  222. <u-input v-model="EnterList.waterContent" input-align="right" placeholder="请输入水分占比"
  223. disabled />
  224. </u-form-item>
  225. <u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160"
  226. v-if="EnterList.inOutType != '移库入库'">
  227. <u-input v-model="EnterList.unitPrice" input-align="right" placeholder="请输入单价" disabled />
  228. </u-form-item>
  229. <u-form-item label="业务描述" prop="businessDescribe" label-width="160" label-position="top">
  230. <u-input v-model="EnterList.businessDescribe" input-align="left" placeholder="请输入业务描述"
  231. type="textarea" class="textarea" maxlength="150" disabled />
  232. </u-form-item>
  233. <u-form-item v-if="OutList.inOutType!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
  234. <u-input v-model="EnterList.binNumber" input-align="right" placeholder="未指定" disabled />
  235. </u-form-item>
  236. </view>
  237. </view>
  238. <view class="uForm_item" v-if="OutList.taskTypeKey == 3 && !EnterList.judge">
  239. <view class="deleteText">移库入库(已删除)</view>
  240. </view>
  241. </u-form>
  242. </view>
  243. <view style='padding:10px;' class='flex bottom-btn'>
  244. <u-button @click='fanHui' type="success" class="btn1" hover-class='none'>返回</u-button>
  245. </view>
  246. </view>
  247. </template>
  248. <script>
  249. import {
  250. mapState
  251. } from 'vuex';
  252. export default {
  253. data() {
  254. return {
  255. id: "",
  256. OutList: {}, //出
  257. EnterList: {}, //入
  258. retreatList: {}, //退
  259. type: '移库',
  260. show: false,
  261. show1: false,
  262. border: false,
  263. rejectInfo: "", //驳回原因
  264. pjList: [{
  265. type: '一等品'
  266. },
  267. {
  268. type: '二等品'
  269. },
  270. {
  271. type: '三等品'
  272. },
  273. {
  274. type: '等外'
  275. }
  276. ],
  277. }
  278. },
  279. // onReady() {
  280. // this.$refs.uForm.setRules(this.rules);
  281. // },
  282. onLoad(options) {
  283. this.id = options.id
  284. this.getList()
  285. },
  286. computed: {
  287. ...mapState(['hasLogin', 'userInfo']),
  288. },
  289. methods: {
  290. getList() {
  291. this.$api.doRequest('get', '/inOutWarehouseTask/getTask', {
  292. id: this.id
  293. }).then(res => {
  294. if (res.data.code == 200) {
  295. this.$api.doRequest('get', '/inOutWarehouseTask/getInOutWarehouseTask', {
  296. relevanceId: res.data.data.relevanceId
  297. }).then(res => {
  298. if (res.data.code == 200) {
  299. for (let i = 0; i < res.data.data.length; i++) {
  300. if (res.data.data[i].inOutType == "移库出库" || res.data.data[i]
  301. .inOutType == "贸易服务出库" || res.data.data[i].inOutType == "销售出库" ||
  302. res.data.data[i].inOutType == "暂存出库") {
  303. this.OutList = res.data.data[i]
  304. this.OutList.judge = 1
  305. } else if (res.data.data[i].inOutType == "移库入库" || res.data.data[i]
  306. .inOutType == "暂存入库" || res
  307. .data.data[i].inOutType == "采购入库" || res.data.data[i].inOutType ==
  308. "贸易服务入库") {
  309. this.EnterList = res.data.data[i]
  310. this.EnterList.judge = 2
  311. } else if (res.data.data[i].inOutType == "退库") {
  312. this.retreatList = res.data.data[i]
  313. this.retreatList.judge = 3
  314. }
  315. }
  316. }
  317. })
  318. }
  319. })
  320. },
  321. // pjPicker(e) {
  322. // this.OutList.grade = this.pjList[e[0]].type
  323. // this.OutList.gradeKey = e[0] + 1
  324. // },
  325. // pjPicker1(e) {
  326. // this.EnterList.grade = this.pjList[e[0]].type
  327. // this.EnterList.gradeKey = e[0] + 1
  328. // },
  329. fanHui() {
  330. uni.navigateBack()
  331. }
  332. }
  333. }
  334. </script>
  335. <style scoped lang="scss">
  336. .content1 {
  337. margin: 10rpx;
  338. padding-bottom: 120rpx;
  339. .title {
  340. height: 70rpx;
  341. line-height: 60rpx;
  342. font-size: 32rpx;
  343. font-weight: 600;
  344. color: #333333;
  345. border-bottom: 2rpx solid #EEEEEE;
  346. }
  347. }
  348. .uForm {
  349. padding: 0 40rpx;
  350. }
  351. .u-form-item {
  352. padding: 0;
  353. }
  354. .bottom-btn {
  355. width: 100%;
  356. position: fixed;
  357. bottom: 0;
  358. display: flex;
  359. z-index: 2;
  360. left: 0;
  361. background-color: #f8f8f8;
  362. flex-direction: column;
  363. .btn1,
  364. .btn2 {
  365. width: 100%;
  366. margin-bottom: 26rpx;
  367. border-radius: 90rpx;
  368. }
  369. .btn1 {
  370. background: white;
  371. color: #00C265;
  372. }
  373. }
  374. .submit {
  375. width: 50%;
  376. background: #22C572;
  377. border-radius: 10rpx;
  378. }
  379. .part2 {
  380. margin-top: 20rpx;
  381. }
  382. .textarea {
  383. border: 1px solid #ccc;
  384. border-radius: 10rpx;
  385. background-color: #F9F9FA;
  386. height: 100px;
  387. }
  388. .row {
  389. display: flex;
  390. justify-content: space-between;
  391. // border-bottom: 1px solid #EEEEEE;
  392. padding: 21rpx 0;
  393. .right,
  394. input {
  395. font-size: 28rpx;
  396. color: #333333;
  397. }
  398. }
  399. //弹出框
  400. // .popup {
  401. // padding: 30rpx;
  402. // border-radius: 20rpx;
  403. // }
  404. .rejectInfoCss {
  405. border: 1px solid #ccc;
  406. border-radius: 10rpx;
  407. background-color: #F9F9FA;
  408. height: 100px;
  409. margin: 30rpx;
  410. }
  411. .uForm_item {
  412. padding: 20rpx;
  413. background-color: #FFFFFF;
  414. margin: 20rpx;
  415. border-radius: 20rpx;
  416. }
  417. .rejectText {
  418. text-align: center;
  419. }
  420. .topInfo {
  421. height: 210rpx;
  422. background: linear-gradient(270deg, #22C572 0%, #34DE8A 100%);
  423. padding: 30rpx;
  424. .topInfo-item {
  425. height: 150rpx;
  426. background-color: #FFFFFF;
  427. border-radius: 20rpx;
  428. padding: 40rpx;
  429. .logo {
  430. width: 40rpx;
  431. height: 40rpx;
  432. margin-top: 8rpx;
  433. }
  434. .infoText {
  435. font-size: 36rpx;
  436. font-weight: 600;
  437. margin-left: 20rpx;
  438. }
  439. .infoData {
  440. color: #878C9C;
  441. font-size: 26rpx;
  442. margin-top: 10rpx;
  443. }
  444. }
  445. }
  446. .deleteText {
  447. text-align: center;
  448. color: #AFB3BF;
  449. }
  450. </style>