|
@@ -13,7 +13,7 @@
|
|
|
<div :id="`hc_table_card_${uuid}`" class="flex-1">
|
|
|
<hc-new-card>
|
|
|
<template #header>
|
|
|
- <div class="text-orange font-400">收方总金额:0元</div>
|
|
|
+ <div class="text-orange font-400">收方总金额:{{ meterMoney }}元</div>
|
|
|
</template>
|
|
|
<template #extra>
|
|
|
<el-button hc-btn type="primary" @click="addModalClick">新增</el-button>
|
|
@@ -85,6 +85,7 @@ const uuid = getRandom(4)
|
|
|
onMounted(() => {
|
|
|
setSplitRef()
|
|
|
getKey1Data()
|
|
|
+ getCurrentMeterMoney()
|
|
|
})
|
|
|
|
|
|
//初始化设置拖动分割线
|
|
@@ -122,6 +123,21 @@ const getKey1Data = async ()=>{
|
|
|
const searchKey1Click = () => {
|
|
|
searchForm.value.current = 1
|
|
|
getTableData()
|
|
|
+ getCurrentMeterMoney()
|
|
|
+}
|
|
|
+
|
|
|
+//获取本期计量总金额
|
|
|
+const meterMoney = ref(0)
|
|
|
+const getCurrentMeterMoney = async () => {
|
|
|
+ const { error, code, data } = await mainApi.getCurrentMeterMoney({
|
|
|
+ contractId: contractId.value,
|
|
|
+ contractPeriodId: searchForm.value.contractPeriodId,
|
|
|
+ })
|
|
|
+ if (!error && code === 200) {
|
|
|
+ meterMoney.value = data
|
|
|
+ } else {
|
|
|
+ meterMoney.value = 0
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
//数据格式
|