|
|
@@ -9,38 +9,22 @@
|
|
|
<block>
|
|
|
<t-table :headerBackgroundColor="'#F0F2F6'">
|
|
|
<t-tr header>
|
|
|
- <t-th>类型</t-th>
|
|
|
- <t-th>金额</t-th>
|
|
|
- <t-th>操作</t-th>
|
|
|
+ <t-th>名称</t-th>
|
|
|
+ <t-th>成本</t-th>
|
|
|
+ <t-th>销售</t-th>
|
|
|
+ <t-th>利润</t-th>
|
|
|
</t-tr>
|
|
|
- <t-tr v-for="(item, inIndex) in profit.income" :key="inIndex">
|
|
|
- <t-td><view style="color:black;font-size:30upx;">{{item.name}}</view></t-td>
|
|
|
- <t-td><view style="color:black;font-size:30upx;">{{item.amount}}</view></t-td>
|
|
|
- <t-td><view>-</view></t-td>
|
|
|
+ <t-tr v-for="(item, inIndex) in profit.list" :key="inIndex">
|
|
|
+ <t-td><view style="color:black;font-size:30upx;">{{item.className}}</view></t-td>
|
|
|
+ <t-td><view style="color:black;font-size:30upx;">{{item.expend}}</view></t-td>
|
|
|
+ <t-td><view>{{item.income}}</view></t-td>
|
|
|
+ <t-td><view>{{item.profit}}</view></t-td>
|
|
|
</t-tr>
|
|
|
- <!--同个节点v-for key重复会报错,所以再包一层-->
|
|
|
- <view>
|
|
|
- <t-tr v-for="(item, exIndex) in profit.expend" :key="exIndex">
|
|
|
- <t-td><view style="color:black;font-size:30upx;">{{item.name}}</view></t-td>
|
|
|
- <t-td v-if="item.amount==0"><view style="color:black;font-size:30upx;">0</view></t-td>
|
|
|
- <t-td v-else><view style="color:black;font-size:30upx;">-{{item.amount}}</view></t-td>
|
|
|
- <t-td><view>-</view></t-td>
|
|
|
- </t-tr>
|
|
|
- </view>
|
|
|
<t-tr>
|
|
|
<t-td align="center">
|
|
|
- <view style="font-weight:bold;color:black;font-size:32upx;">利润 ¥{{profit.balance||0}}</view>
|
|
|
+ <view style="font-weight:bold;color:black;font-size:32upx;"></view>
|
|
|
</t-td>
|
|
|
</t-tr>
|
|
|
- <block v-if="profit.wastagePrice && Number(profit.wastagePrice)>0">
|
|
|
- <t-tr>
|
|
|
- <t-td align="center">
|
|
|
- <view style="font-weight:bold;color:red;font-size:30upx;">
|
|
|
- 由于花材损耗,少赚了 ¥{{profit.wastagePrice||0}}
|
|
|
- </view>
|
|
|
- </t-td>
|
|
|
- </t-tr>
|
|
|
- </block>
|
|
|
</t-table>
|
|
|
</block>
|
|
|
</view>
|