AssetsCard2.vue 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187
  1. <template>
  2. <view class="listBox">
  3. <view class="listBox-con">
  4. <view class="listBox-top">
  5. <view class="listBox-name">
  6. <u-tag @click="open(item.planDetailVOList)" :text="item.info.categoryName"></u-tag>
  7. </view>
  8. </view>
  9. <view class="listBox-top">
  10. <view class="listBox-name">
  11. {{ item.info.categoryCode }}
  12. </view>
  13. </view>
  14. <view class="listBox-bottom">
  15. <view>批次号:{{ item.info.batchNo }}</view>
  16. <view>牌号:{{ item.info.brandNum }}</view>
  17. <view>型号:{{ item.info.categoryModel }}</view>
  18. <view>规格:{{ item.info.specification }}</view>
  19. <view>计量数量:{{ item.info.packingCountBase }}</view>
  20. <view>计量单位:{{ item.info.packingUnit }}</view>
  21. <view>重量:{{ item.info.weight }}</view>
  22. <view>重量单位:{{ item.info.weightUnit }}</view>
  23. </view>
  24. </view>
  25. <u-popup mode="right" :show="show" @close="close">
  26. <u-list>
  27. <u-list-item v-for="(item, index) in list" :key="index">
  28. <view class="listBox-item">
  29. <view class="w100">序号:{{ index + 1 }}</view>
  30. <view>包装数量:{{ item.info.packingCountBase }}</view>
  31. <view>包装单位:{{ item.info.packingUnit }}</view>
  32. <view class="w100">包装编码:{{ item.info.packageNo }}</view>
  33. <view class="w100">生产日期:</view>
  34. </view>
  35. </u-list-item>
  36. </u-list>
  37. </u-popup>
  38. </view>
  39. </template>
  40. <script>
  41. export default {
  42. props: {
  43. item: {
  44. type: Object,
  45. default: () => ({
  46. info: {}
  47. })
  48. }
  49. },
  50. data() {
  51. return {
  52. list: [],
  53. show: false,
  54. statusOption: [
  55. {
  56. label: '盘盈',
  57. value: '2',
  58. numKey: 'surplusQuantity'
  59. },
  60. {
  61. label: '丢失',
  62. value: '3',
  63. numKey: 'loseQuantity'
  64. },
  65. {
  66. label: '破损',
  67. value: '4',
  68. numKey: 'wornQuantity'
  69. }
  70. ],
  71. statusInfo: {
  72. 2: '盘盈',
  73. 3: '丢失',
  74. 4: '破损'
  75. },
  76. countInfo: {
  77. 2: 'surplusQuantity',
  78. 3: 'loseQuantity',
  79. 4: 'wornQuantity'
  80. }
  81. }
  82. },
  83. methods: {
  84. close() {
  85. this.show = false
  86. },
  87. open(list) {
  88. console.log(list)
  89. this.list = list
  90. this.show = true
  91. }
  92. }
  93. }
  94. </script>
  95. <style lang="scss" scoped>
  96. .listBox {
  97. display: flex;
  98. // height: 180rpx;
  99. padding: 20rpx;
  100. border-bottom: 2rpx solid #e5e5e5;
  101. .listBox-sel {
  102. height: 90rpx;
  103. width: 80rpx;
  104. // line-height: 90rpx;
  105. text-align: center;
  106. checkbox {
  107. transform: scale(1.2);
  108. }
  109. }
  110. .listBox-con {
  111. width: 100%;
  112. // display: flex;
  113. // flex-wrap: wrap;
  114. // justify-content: space-between;
  115. align-items: center;
  116. padding: 0 18rpx 0 0;
  117. .listBox-top {
  118. width: 100%;
  119. display: flex;
  120. justify-content: space-between;
  121. padding-bottom: 10rpx;
  122. .listBox-name,
  123. .listBox-code {
  124. display: inline-block;
  125. font-size: $uni-font-size-sm;
  126. font-weight: bold;
  127. }
  128. }
  129. .listBox-bottom {
  130. width: 100%;
  131. display: flex;
  132. justify-content: space-between;
  133. font-size: $uni-font-size-sm;
  134. flex-wrap: wrap;
  135. > view {
  136. width: 50%;
  137. overflow: hidden;
  138. white-space: nowrap;
  139. text-overflow: ellipsis;
  140. }
  141. .input_view {
  142. display: flex;
  143. align-items: center;
  144. justify-content: center;
  145. .u-input {
  146. height: 36rpx;
  147. padding: 0 !important;
  148. margin-right: 10rpx;
  149. border: 1px solid #ddd;
  150. }
  151. }
  152. .w100 {
  153. width: 100%;
  154. }
  155. }
  156. }
  157. .listBox-item {
  158. width: 70vw;
  159. padding: 20rpx;
  160. display: flex;
  161. justify-content: space-between;
  162. font-size: $uni-font-size-sm;
  163. flex-wrap: wrap;
  164. border-bottom: 1px solid #ddd;
  165. > view {
  166. width: 50%;
  167. overflow: hidden;
  168. white-space: nowrap;
  169. text-overflow: ellipsis;
  170. }
  171. .w100 {
  172. width: 100%;
  173. }
  174. }
  175. }
  176. .noDate {
  177. height: 100%;
  178. }
  179. </style>