detail.vue 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355
  1. <template>
  2. <view class="deliver-page">
  3. <u-navbar height="40px" title="拣货任务详情" bgColor="#0256FF" :titleStyle="{color:'#fff'}" leftIconColor="#fff" autoBack
  4. placeholder>
  5. </u-navbar>
  6. <view class="container_main">
  7. <view class="info-box" :class="isUnfold ? '':'min-height'">
  8. <view class="info-line">
  9. <view class="info-line-label">
  10. <text>出库单号</text>
  11. </view>
  12. <view class="info-line-value">
  13. {{orderInfo.number}}
  14. </view>
  15. </view>
  16. <view class="info-line">
  17. <view class="info-line-label">
  18. <text>发出仓库</text>
  19. </view>
  20. <view class="info-line-value">
  21. 我的仓库-暂无
  22. </view>
  23. </view>
  24. <view class="info-line">
  25. <view class="info-line-label">
  26. <text>出库数量</text>
  27. </view>
  28. <view class="info-line-value">
  29. {{orderInfo.goodsQuantity}}
  30. </view>
  31. </view>
  32. <view class="info-line">
  33. <view class="info-line-label">
  34. <text>出库种类</text>
  35. </view>
  36. <view class="info-line-value">
  37. {{orderInfo.goodsTypeCount}}
  38. </view>
  39. </view>
  40. <view class="info-line">
  41. <view class="info-line-label">
  42. <text>制单日期</text>
  43. </view>
  44. <view class="info-line-value">
  45. {{orderInfo.createTime}}
  46. </view>
  47. </view>
  48. <view class="info-line">
  49. <view class="info-line-label">
  50. <text>制单人</text>
  51. </view>
  52. <view class="info-line-value">
  53. 刘双强-暂无
  54. </view>
  55. </view>
  56. <view class="info-line">
  57. <view class="info-line-label">
  58. <text>出库类型</text>
  59. </view>
  60. <view class="info-line-value">
  61. {{orderInfo.subType}}
  62. </view>
  63. </view>
  64. <view class="info-line">
  65. <view class="info-line-label">
  66. <text>出库人</text>
  67. </view>
  68. <view class="info-line-value">
  69. 刘双美-暂无
  70. </view>
  71. </view>
  72. <view class="info-line">
  73. <view class="info-line-label">
  74. <text>备注信息</text>
  75. </view>
  76. <view class="info-line-value">
  77. {{orderInfo.remark || '-'}}
  78. </view>
  79. </view>
  80. <view class="info-line">
  81. <view class="info-line-label">
  82. <text>出库时间</text>
  83. </view>
  84. <view class="info-line-value">
  85. {{orderInfo.operTime}}
  86. </view>
  87. </view>
  88. </view>
  89. <view class="btn-box">
  90. <view class="btn-cont" @click="isUnfold = !isUnfold">
  91. <text>{{isUnfold ? '收起' : '展开'}}</text>
  92. <u-icon :name="isUnfold?'arrow-up':'arrow-down'"></u-icon>
  93. </view>
  94. </view>
  95. <!-- 货物清单 -->
  96. <view class="cargo-list">
  97. <view class="cargo-list-title">
  98. <view>出库货物清单</view>
  99. <view class="cargo-list-title-tips">(轻触货物查看详情)</view>
  100. </view>
  101. <block v-for="(item,i) in goodsList" :key="i">
  102. <good-item :item="item" @toDetail="toDetail">
  103. <view class="num-box">
  104. <view class="num-box-text">已确认出库数量</view>
  105. <u-number-box v-model="item.actualQuantityInStorage" disabled>
  106. <view slot="minus" class="minus">
  107. <u-icon name="minus" color="#DADADA" size="12"></u-icon>
  108. </view>
  109. <text slot="input" class="input">{{item.actualQuantityInStorage || 0}}</text>
  110. <view slot="plus" class="plus">
  111. <u-icon name="plus" color="#FFFFFF" size="12"></u-icon>
  112. </view>
  113. </u-number-box>
  114. </view>
  115. </good-item>
  116. </block>
  117. </view>
  118. </view>
  119. </view>
  120. </template>
  121. <script>
  122. import goodItem from '@/components/good-item/good-item.vue'
  123. import {orderDetail, orderInfo} from '@/common/request/apis/purchase'
  124. export default {
  125. components: {
  126. goodItem,
  127. },
  128. data() {
  129. return {
  130. errorShow:false,
  131. successShow:false,
  132. isUnfold: true, //是否展开
  133. orderInfo: {},
  134. goodsList: []
  135. }
  136. },
  137. onLoad(e) {
  138. this.getOrderInfo(e.id)
  139. this.getOrderDetail(e.id)
  140. },
  141. methods:{
  142. getOrderInfo(id) {
  143. orderInfo(id)
  144. .then(res=>{
  145. if(res.code == 200) {
  146. this.orderInfo = res.data
  147. }
  148. })
  149. },
  150. getOrderDetail(id) {
  151. orderDetail(id)
  152. .then(res=>{
  153. if(res.code == 200) {
  154. this.goodsList = res.data.rows
  155. }
  156. })
  157. },
  158. submitClick() {
  159. },
  160. confirm() {
  161. console.log('确定')
  162. this.errorShow = false
  163. },
  164. backClick() {
  165. },
  166. // 扫码确认
  167. scanConfirm() {
  168. },
  169. manualClick() {
  170. this.goodsShow = true
  171. },
  172. toDetail() {
  173. uni.navigateTo({
  174. url:`/pages/goods/detail?id=${val.id}&name=${val.materialName}&materialId=${val.materialId}`
  175. })
  176. }
  177. }
  178. }
  179. </script>
  180. <style lang="scss" scoped>
  181. .deliver-page {
  182. min-height: 100vh;
  183. background-color: #F0F6FB;
  184. padding-bottom: 130rpx;
  185. .container_main {
  186. padding: 24rpx;
  187. .info-box {
  188. background-color: #fff;
  189. border-radius: 16rpx 16rpx 0 0;
  190. padding: 24rpx 24rpx 0 24rpx;
  191. .info-line {
  192. border-bottom: 1px solid #F4F4F4;
  193. min-height: 92rpx;
  194. color: #333;
  195. font-family: "PingFang SC";
  196. font-size: 28rpx;
  197. font-weight: 400;
  198. display: flex;
  199. align-items: center;
  200. &-label {
  201. width: 162rpx;
  202. }
  203. .must-box {
  204. color: #FF3B1D;
  205. }
  206. }
  207. }
  208. .min-height {
  209. height: 300rpx;
  210. overflow: hidden;
  211. }
  212. .btn-box {
  213. height: 112rpx;
  214. display: flex;
  215. align-items: center;
  216. justify-content: center;
  217. background-color: #fff;
  218. border-radius: 0 0 16rpx 16rpx;
  219. .btn-cont {
  220. display: flex;
  221. align-items: center;
  222. justify-content: center;
  223. width: 154rpx;
  224. height: 56rpx;
  225. border-radius: 120rpx;
  226. border: 1px solid #D9D9D9;
  227. color: #666;
  228. font-family: "PingFang SC";
  229. font-size: 28rpx;
  230. font-weight: 400;
  231. }
  232. }
  233. .cargo-list {
  234. padding: 24rpx 0;
  235. background-color: #fff;
  236. margin-top: 24rpx;
  237. border-radius: 16rpx;
  238. .cargo-list-title {
  239. font-family: "PingFang SC";
  240. font-size: 32rpx;
  241. font-style: normal;
  242. font-weight: bold;
  243. display: flex;
  244. align-items: center;
  245. position: relative;
  246. padding-left: 50rpx;
  247. &::after {
  248. content: '';
  249. display: block;
  250. width: 6rpx;
  251. height: 30rpx;
  252. border-radius: 100px;
  253. background: #0256FF;
  254. position: absolute;
  255. top: 50%;
  256. left: 24rpx;
  257. transform: translateY(-50%);
  258. }
  259. .cargo-list-title-tips {
  260. color: #0256FF;
  261. font-size: 24rpx;
  262. font-weight: 400;
  263. }
  264. }
  265. .num-box {
  266. display: flex;
  267. align-items: center;
  268. justify-content: space-between;
  269. padding: 0 48rpx 0 26rpx;
  270. .num-box-text {
  271. color: #666;
  272. font-family: "PingFang SC";
  273. font-size: 28rpx;
  274. font-weight: 400;
  275. }
  276. .input {
  277. width: 112rpx;
  278. text-align: center;
  279. border-bottom: 1px solid #DADADA;
  280. margin: 0 8rpx;
  281. }
  282. .minus {
  283. width: 40rpx;
  284. height: 40rpx;
  285. border-radius: 8rpx;
  286. border: 1px solid #DADADA;
  287. display: flex;
  288. align-items: center;
  289. justify-content: center;
  290. }
  291. .plus {
  292. width: 40rpx;
  293. height: 40rpx;
  294. border-radius: 8rpx;
  295. background-color: #DADADA;
  296. display: flex;
  297. align-items: center;
  298. justify-content: center;
  299. }
  300. }
  301. }
  302. }
  303. .footer-box {
  304. background-color: #fff;
  305. height: 126rpx;
  306. position: fixed;
  307. bottom: 0;
  308. left: 0;
  309. right: 0;
  310. display: flex;
  311. align-items: center;
  312. justify-content: space-between;
  313. padding: 0 40rpx 0 60rpx;
  314. .footer-box-l {
  315. color: #666;
  316. font-family: "PingFang SC";
  317. font-size: 28rpx;
  318. font-weight: 400;
  319. }
  320. .submitBtn {
  321. width: 362rpx;
  322. height: 76rpx;
  323. border-radius: 16rpx;
  324. background: #0256FF;
  325. color: #FFF;
  326. font-size: 28rpx;
  327. font-weight: 500;
  328. margin: 0;
  329. }
  330. }
  331. }
  332. </style>