| | |
| | | <template> |
| | | <view class="container"> |
| | | <!-- 标题栏 --> |
| | | <view class="status_bar"></view> |
| | | <uni-nav-bar background-color="#ffffff" title="物料详情" @clickLeft="back" :fixed="true" |
| | | :border="false" left-icon="left" :shadow="true"> |
| | | </uni-nav-bar> |
| | | |
| | | <!-- 物料信息卡片 --> |
| | | <view class="info-card"> |
| | |
| | | </view> |
| | | <view class="info-value"> |
| | | <text class="tag tag-info">{{mat.standby1 || '-'}}</text> |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="info-row"> |
| | | <view class="info-label"> |
| | | <uni-icons type="folder" size="16" color="#909399"></uni-icons> |
| | | <text>商品组织</text> |
| | | </view> |
| | | <view class="info-value"> |
| | | <text>{{mat.matOrigin || '-'}}</text> |
| | | </view> |
| | | </view> |
| | | |
| | |
| | | return { |
| | | mat: { |
| | | standby1: null, |
| | | matOrigin: null, |
| | | matnr: null, |
| | | maktx: null, |
| | | specs: null, |
| | |
| | | if (data.standby1) { |
| | | that.mat.standby1 = data.standby1 |
| | | } |
| | | if (data.batch) { |
| | | that.mat.batch = data.batch |
| | | } |
| | | }) |
| | | }, |
| | | methods: { |
| | |
| | | // 方法2:遍历每一段 |
| | | arr.forEach((item, index) => { |
| | | switch(index){ |
| | | case 0: that.matOrigin = item |
| | | break; |
| | | case 1: that.matOrder = item |
| | | break; |
| | | case 2: that.matnr = item |
| | | break; |
| | | case 3: that.batch = item |
| | | break; |
| | | default: |
| | | break; |
| | |
| | | success: function(res) { |
| | | res.eventChannel.emit('mat', { |
| | | data: result.data, |
| | | matOrigin: that.matOrigin, |
| | | batch: that.batch, |
| | | standby1: that.matOrder |
| | | }) |
| | | }, |