<wxs src='/utils/wxmlUtil.wxs' module="wxmlUtil"></wxs>

<!-- 期初 入库 出库 期末 -->
<!-- 2024.06.04 刘尧 明细新增包装 -->
<view style="display: flex;padding:10rpx;  margin: 10px 22rpx 10px 22rpx;margin-top: 10px;border-radius: 15rpx;">
  <view style="background-color:#F4F9FF;width:25%;padding:10rpx;border-radius: 16rpx;">
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{$t["openingInventoryQty"]}}</view>
    <dk-cell left="0rpx" center="center" fontSize="13" contentFontSize="18" contentColor="#1B365D" spaceWidth="0" contentFontWeight="700" amount="{{false}}" content="{{item.openingIvtQty}}"></dk-cell>
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{item.packageBoxOpening}}</view>
  </view>
  <view style="background-color:#F4F9FF;width: 25%;padding:10rpx;border-radius: 16rpx;margin-left: 20rpx;">
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{$t["inventoryQty"]}}</view>
    <dk-cell left="0rpx" center="center" fontSize="15" contentFontSize="18" contentColor="#1B365D" spaceWidth="0" contentFontWeight="700" amount="{{false}}" content="{{item.currentIntoQty}}"></dk-cell>
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{item.packageBoxCurrent}}</view>
  </view>

  <view style="background-color:#F4F9FF;width:25%;padding:10rpx;border-radius: 16rpx;margin-left: 20rpx;">
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{$t["outQty"]}}</view>
    <dk-cell left="0rpx" center="center" fontSize="13" contentFontSize="18" contentColor="#1B365D" spaceWidth="0" contentFontWeight="700" amount="{{false}}" content="{{item.currentOutQty}}"></dk-cell>
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{item.packageBoxCurrentOut}}</view>
  </view>
  <view style="background-color:#F4F9FF;width: 25%;padding:10rpx;border-radius: 16rpx;margin-left: 20rpx;">
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{$t["lastQty"]}}</view>
    <dk-cell left="0rpx" center="center" fontSize="15" contentFontSize="18" contentColor="#1B365D" spaceWidth="0" contentFontWeight="700" amount="{{false}}" content="{{item.endingIvtQty}}"></dk-cell>
    <view style="font-size:13px;text-align: center;margin-top: 10rpx;">{{item.packageBoxEndingIvt}}</view>
  </view>
</view>


<view style="display: flex;">
  <!-- 商品信息 -->
  <view style="width: 100%;">
    <van-card data-item="{{item}}" data-index="{{index_}}">
      <view slot="thumb">
        <van-image radius="5px" width="80" height="80" src="{{item.imagesUrl }}" />
      </view>
      <view slot="title" style="display: flex;">
        <!-- 标题 -->
        <view>
          <dk-title  titleTag="{{item.brandName}}" title="{{item.skuModel}}"></dk-title>
        </view>
      </view>
      <!-- 描述 -->
      <view slot="desc">
        <view style="display:flex;width: 100%;">
          <dk-text value="{{item.skuName}}"></dk-text>
        </view>
        <view style="display:flex;width: 100%;">
          <dk-text value="{{item.nonStdCode}}"></dk-text>
        </view>
      </view>
      <view slot="desc" style="display: flex;justify-content: space-between;align-items: center;margin-top:10rpx;">
        <!-- 仓库-->
        <view>
          <dk-text fontSize="28rpx" value="{{item.skuSpec}}"></dk-text>
        </view>
        <view>
          <dk-text fontSize="28rpx" value="{{item.whName}}"></dk-text>
        </view>
      </view>

    </van-card>
  </view>
</view>

<dk-tabs active="{{active}}" list="{{tagList}}" bind:onChange="onChangeTabs"> </dk-tabs>


<view wx:for="{{tableData}}" data-item="{{item_}}"  wx:for-item="item_" wx:key="index" class="main-class">
  <!-- 上半部分 -->
  <view class="main-foot" style="border-radius: 15rpx;background-size: 100% 172rpx;">
    <view class="table-content" data-item="{{item_}}">
      <view class="table-content-row" style="padding: 30rpx" bindtap="toItem" data-value="{{item_}}">

        <view style="display: flex;padding-top: 10rpx;">
          <view style="font-size: 30rpx;width: 55%;color:#1B365D;">{{active==0?item_.intoNo:item_.outNo}}</view>
          <view style="width: 45%;font-size: 24rpx;color:#95A8CB;display: flex;justify-content: center;align-items: center;text-align: center;">
            <view>{{active==0?item_.intoTypeName:item_.outTypeName}}   {{active==0?item_.intoDate:item_.outDate }}</view>
          </view>
        </view>
      </view>

      <!-- 商品信息 -->
      <view style="background: #FFFFFF;">
        <view style="display: flex;justify-content: space-between;align-items: center;">
          <view style=" padding: 10px 32rpx 10px 32rpx;color: #1B365D;font-size: 30rpx;">{{$t['goodsQuantity']}}</view>
          <view style=" padding: 10px 32rpx 10px 32rpx;color: #1B365D;font-size: 30rpx;">{{active==0?item_.intoQty:item_.outQty }}{{item_.unitName}}</view>
        </view>
      </view>
    </view>
  </view>
</view>