outInstanceBom.vue 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <template>
  2. <view>
  3. <view class="material rx-ss" v-for="(mate, idx) in list">
  4. <view class="content_table">
  5. <view class="item">
  6. <view class="lable rx-cc">编码</view>
  7. <view class="content">
  8. {{mate.categoryId}}
  9. </view>
  10. </view>
  11. <view class="item">
  12. <view class="lable rx-cc">名称</view>
  13. <view class="content" style="color: rgb(255 170 42)">{{mate.name}}</view>
  14. </view>
  15. <view class="item" v-for="(itm, index) in tableH(mate.rootCategoryLevelId)" :key="index"
  16. v-if="!itm.formatter">
  17. <view class="lable rx-cc">{{ itm.label }}</view>
  18. <view class="content"> {{ mate[itm.prop] }}</view>
  19. </view>
  20. <view v-for="(itm, index) in tableH(mate.rootCategoryLevelId)" :key="index" class="item"
  21. v-if="itm.formatter">
  22. <view class="lable rx-cc">{{ itm.label }}</view>
  23. <view class="content">{{ itm.formatter(mate) }}</view>
  24. </view>
  25. <view class="item" v-if='mate.rootCategoryLevelId == 1 && mate.isConsumable == 0'>
  26. <view class="lable rx-cc">重量</view>
  27. <view class="content ">
  28. {{mate.extInfo.weight || 0}} {{ mate.extInfo.weightUnit}}
  29. </view>
  30. </view>
  31. <view class="item" v-if='mate.rootCategoryLevelId == 1 && mate.isConsumable == 0'>
  32. <view class="lable rx-cc">刻码</view>
  33. <view class="content">{{mate.extInfo.engrave}}</view>
  34. </view>
  35. <view class="item" v-if='mate.rootCategoryLevelId == 1 && mate.isConsumable == 0'>
  36. <view class="lable rx-cc">物料代号</view>
  37. <view class="content">{{mate.extInfo.materielCode}}</view>
  38. </view>
  39. <view class="item" v-if='mate.rootCategoryLevelId == 1 && mate.isConsumable == 0'>
  40. <view class="lable rx-cc">客户代号</view>
  41. <view class="content">{{mate.extInfo.clientCode}}</view>
  42. </view>
  43. <view class="item">
  44. <view class="lable rx-cc">数量</view>
  45. <view class="content content_num">
  46. <input class="uni-input" v-model="mate.quantity" type="digit"></input>
  47. <view class="unit" v-if='mate.unit'>/{{mate.unit}}</view>
  48. </view>
  49. </view>
  50. <view class="item">
  51. <view class="lable rx-cc">领料仓库</view>
  52. <view class="content ">
  53. {{ mate.pathName }}
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. </view>
  59. </template>
  60. <script>
  61. import {
  62. tableHeader
  63. } from './outCommon.js'
  64. export default {
  65. props: ['list'],
  66. data() {
  67. return {
  68. }
  69. },
  70. methods: {
  71. tableH(type) {
  72. return tableHeader(type)
  73. },
  74. }
  75. }
  76. </script>
  77. <style lang="scss" scoped>
  78. .material {
  79. margin-top: 10rpx;
  80. .content_table {
  81. width: 702rpx;
  82. border: 2rpx solid $border-color;
  83. .item {
  84. display: flex;
  85. border-bottom: 2rpx solid $border-color;
  86. .lable {
  87. width: 162rpx;
  88. text-align: center;
  89. background-color: #F7F9FA;
  90. font-size: 26rpx;
  91. border-right: 2rpx solid $border-color;
  92. flex-shrink: 0;
  93. }
  94. .ww80 {
  95. width: 80rpx;
  96. }
  97. .content {
  98. width: 518rpx;
  99. min-height: 64rpx;
  100. font-size: 28rpx;
  101. line-height: 28rpx;
  102. font-style: normal;
  103. font-weight: 400;
  104. padding: 18rpx 8rpx;
  105. box-sizing: border-box;
  106. word-wrap: break-word;
  107. flex-grow: 1 !important;
  108. }
  109. .content_num {
  110. display: flex;
  111. align-items: center;
  112. padding: 0 4rpx;
  113. /deep/ .uni-input-input {
  114. width: 200rpx;
  115. border: 2rpx solid #F0F8F2;
  116. background: #F0F8F2;
  117. color: $theme-color;
  118. }
  119. .unit {
  120. padding: 0 4rpx;
  121. font-size: 24rpx;
  122. color: #404446;
  123. }
  124. }
  125. .pd4 {
  126. padding: 4rpx 8rpx;
  127. }
  128. &:last-child {
  129. border-bottom: none;
  130. }
  131. }
  132. .ww55 {
  133. width: 55%;
  134. }
  135. .ww45 {
  136. width: 45%;
  137. }
  138. }
  139. }
  140. </style>