improvedWrehousing.vue 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. <template>
  2. <view class="wrap">
  3. <view class="dropdown content1">
  4. <view class="left" @click='show1=true'>
  5. <view>{{warehouseName}}</view>
  6. <u-icon name="arrow-right"></u-icon>
  7. <u-picker @confirm="warehousechange" range-key='warehouseName' mode="selector" v-model="show1"
  8. :range="warehouseList"></u-picker>
  9. </view>
  10. <view class="right" @click='show2=true'>
  11. <view>{{binNumber}}仓位</view>
  12. <u-icon name="arrow-right"></u-icon>
  13. <u-picker @confirm="warehouseCWchange" range-key='binNumber' mode="selector" v-model="show2"
  14. :range="warehouseCWList"></u-picker>
  15. </view>
  16. </view>
  17. <view class="content2">
  18. <view class="content2-item" v-for="(item,index) in dataList" @click="goDetail(item)">
  19. <view class="row">
  20. <view class="left">合同编号</view>
  21. <view>{{item.contractNo}}</view>
  22. </view>
  23. <view class="row">
  24. <view class="left">车牌号</view>
  25. <view>{{item.carNo}}</view>
  26. </view>
  27. <view class="row">
  28. <view class="left">暂存时间</view>
  29. <view>{{item.updateDate}}</view>
  30. </view>
  31. <view class="row no-boder">
  32. <view class="left">提交人</view>
  33. <view>{{item.backOffice}}</view>
  34. </view>
  35. </view>
  36. </view>
  37. </view>
  38. </template>
  39. <script>
  40. import helper from '@/common/helper.js';
  41. export default {
  42. data() {
  43. return {
  44. show1: false,
  45. show2: false,
  46. currentPage: 1,
  47. pageSize: 9999,
  48. positionId: "",
  49. binNumber: "",
  50. warehouseName: '',
  51. positionName: '',
  52. warehouseList: [],
  53. warehouseCWList: [],
  54. dataList: [],
  55. allWarehouse: [],
  56. showTime:''
  57. }
  58. },
  59. onLoad() {
  60. },
  61. onShow() {
  62. console.log("完善入库-仓库信息", helper.erpWarehouse)
  63. let _data = helper.erpWarehouse
  64. this.warehouseName = _data.warehouseName
  65. this.warehouseList = _data.allWarehouse
  66. this.warehouseCWList = _data.warehouseCWList
  67. this.binNumber = _data.binNumber
  68. this.positionId = _data.positionId
  69. this.warehouseId = _data.warehouseId
  70. this.getList()
  71. },
  72. methods: {
  73. getList() {
  74. this.$api.doRequest('get', '/warehouseInOutInfo/selectWarehouseInOutInfo', {
  75. positionId: this.positionId,
  76. baseId: this.warehouseId,
  77. currentPage: this.currentPage,
  78. pageSize: this.pageSize,
  79. inOutFlag: 2
  80. }).then(res => {
  81. if (res.data.code == 200) {
  82. this.dataList = res.data.data.records
  83. }
  84. })
  85. },
  86. warehousechange(e) {
  87. this.warehouseName = this.warehouseList[e[0]].warehouseName
  88. this.warehouseId = this.warehouseList[e[0]].id
  89. this.warehouseCWList = this.warehouseList[e[0]].positionInfos
  90. this.warehouseCWchange([0])
  91. this.currentPage = 1
  92. this.pageSize = 9999
  93. },
  94. warehouseCWchange(e) {
  95. this.binNumber = this.warehouseCWList[e[0]].binNumber
  96. this.warehouseId = this.warehouseCWList[e[0]].baseId
  97. this.positionId = this.warehouseCWList[e[0]].id
  98. this.binNumber = this.warehouseCWList[e[0]].binNumber
  99. helper.erpWarehouse.positionId = this.positionId
  100. helper.erpWarehouse.warehouseId = this.warehouseId
  101. helper.erpWarehouse.binNumber = this.binNumber
  102. this.currentPage = 1
  103. this.pageSize = 9999
  104. this.getList()
  105. },
  106. goDetail(val) {
  107. uni.navigateTo({
  108. url: '/pages/erp/improvedWrehousing/improvedWrehousingDetail?data=' + JSON.stringify(val),
  109. })
  110. }
  111. }
  112. }
  113. </script>
  114. <style scoped lang="scss">
  115. .dropdown {
  116. display: flex;
  117. margin: 20rpx 0;
  118. justify-content: space-between;
  119. .left,
  120. .right {
  121. display: flex;
  122. align-items: center;
  123. }
  124. }
  125. .content1 {
  126. padding: 40rpx 20rpx;
  127. margin: 20rpx;
  128. border-radius: 10rpx;
  129. background: #FFFFFF;
  130. }
  131. .content2 {
  132. .row {
  133. display: flex;
  134. justify-content: space-between;
  135. border-bottom: 1px solid #EEEEEE;
  136. padding: 21rpx 0;
  137. .right,
  138. input {
  139. font-size: 28rpx;
  140. color: #333333;
  141. }
  142. }
  143. .row-bottom {
  144. .right-bottom {
  145. width: 300rpx;
  146. text-align: right;
  147. }
  148. }
  149. }
  150. .content2-item {
  151. background: white;
  152. margin: 0 20rpx 20rpx 20rpx;
  153. padding: 10rpx;
  154. border-radius: 15rpx;
  155. }
  156. .no-boder {
  157. border-bottom: none !important;
  158. }
  159. </style>