|
|
@@ -48,39 +48,44 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
- <template slot="sysmSearch">
|
|
|
- <div style="display: flex; align-items: center;">
|
|
|
- <span>使用寿命:</span>
|
|
|
- <avue-input-number v-model="params.sysmMin" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
- <span style="width: 20px; text-align: center;">至</span>
|
|
|
- <avue-input-number v-model="params.sysmMax" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
- </div>
|
|
|
+ <template slot="txksrqSearch">
|
|
|
+ <span>摊销开始时间:</span>
|
|
|
+ <el-date-picker
|
|
|
+ v-model="params.txksrq"
|
|
|
+ type="daterange"
|
|
|
+ range-separator="至"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ style="width: 220px !important;"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
</template>
|
|
|
|
|
|
<template slot="zcyzSearch">
|
|
|
<div style="display: flex; align-items: center;">
|
|
|
<span>资产原值:</span>
|
|
|
- <avue-input-number v-model="params.zcyzMin" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.zcyzStart" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
<span style="width: 20px; text-align: center;">至</span>
|
|
|
- <avue-input-number v-model="params.zcyzMax" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.zcyzEnd" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
- <template slot="ysysmSearch">
|
|
|
+ <template slot="ysyysSearch">
|
|
|
<div style="display: flex; align-items: center;">
|
|
|
<span>已使用月数:</span>
|
|
|
- <avue-input-number v-model="params.ysysmMin" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.ysyysStart" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
<span style="width: 20px; text-align: center;">至</span>
|
|
|
- <avue-input-number v-model="params.ysysmMax" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.ysyysEnd" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<template slot="ytxeSearch">
|
|
|
<div style="display: flex; align-items: center;">
|
|
|
<span>月摊销额(每节点/套):</span>
|
|
|
- <avue-input-number v-model="params.yzjeMin" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.ytxeStart" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
<span style="width: 20px; text-align: center;">至</span>
|
|
|
- <avue-input-number v-model="params.yzjeMax" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
+ <avue-input-number v-model="params.ytxeEnd" :min="0" style="width: 90px !important;"></avue-input-number>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -104,7 +109,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { fetchDeviceData } from "@/api/yfCostManage/basicDataSetting/houseDetailList"
|
|
|
+import { fetchLastMonthData } from "@/api/yfCostManage/basicDataSetting/dtCostAllocationList"
|
|
|
import YearMonthSelect from "@/components/year-month-select";
|
|
|
import UploadExcelDialog from "@/components/upload-excel-dialog";
|
|
|
import projectSelect from "@/components/project-select";
|
|
|
@@ -136,7 +141,18 @@ export default window.$crudCommon({
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- loadData() {},
|
|
|
+ getSearchParams() {
|
|
|
+ const newParams = { ...this.params };
|
|
|
+ if (newParams.txksrq && newParams.txksrq.length) {
|
|
|
+ newParams.txksrqStart = newParams.txksrq[0];
|
|
|
+ newParams.txksrqEnd = newParams.txksrq[1];
|
|
|
+ }
|
|
|
+ delete newParams.txksrq;
|
|
|
+ return newParams;
|
|
|
+ },
|
|
|
+ getFormData() {
|
|
|
+ return { ...this.form, yearAndMonth: this.params.yearAndMonth }
|
|
|
+ },
|
|
|
validCustom() {
|
|
|
if (this.form.cqdtfybh && !isAlphanumericCombination(this.form.cgbh)) {
|
|
|
this.$message.warning("长期待摊费用编号必须是英文字母加数字组合!");
|
|
|
@@ -153,14 +169,14 @@ export default window.$crudCommon({
|
|
|
},
|
|
|
handleImport() {
|
|
|
let excelParams = { yearAndMonth: this.params.yearAndMonth };
|
|
|
- this.$refs.uploadExcelDialog.open('/api/kd-scientific/asset/fangwujianzhuwu/import', excelParams);
|
|
|
+ this.$refs.uploadExcelDialog.open('/api/kd-scientific/xm/cqdtfy/import', excelParams);
|
|
|
},
|
|
|
uploadAfter() {
|
|
|
this.page.currentPage = 1;
|
|
|
this.getList(this.page);
|
|
|
},
|
|
|
handleExport() {
|
|
|
- exportBloByPost(`/api/kd-scientific/asset/fangwujianzhuwu/export?${this.website.tokenHeader}=${getToken()}`, this.params).then(res => {
|
|
|
+ exportBloByPost(`/api/kd-scientific/xm/cqdtfy/export-xmCqdtfy?${this.website.tokenHeader}=${getToken()}`, this.params).then(res => {
|
|
|
downloadXls(res.data, `${this.params.yearAndMonth}长期待摊费用分配表.xlsx`);
|
|
|
});
|
|
|
},
|
|
|
@@ -176,15 +192,15 @@ export default window.$crudCommon({
|
|
|
})
|
|
|
},
|
|
|
handleReadyLastData() {
|
|
|
- // fetchDeviceData({ yearAndMonth: this.params.yearAndMonth}).then(res => {
|
|
|
- // let data = res.data;
|
|
|
- // if (data.success) {
|
|
|
+ fetchLastMonthData({ yearAndMonth: this.params.yearAndMonth}).then(res => {
|
|
|
+ let data = res.data;
|
|
|
+ if (data.success) {
|
|
|
|
|
|
- // this.$message.success('读取成功!');
|
|
|
- // this.page.currentPage = 1;
|
|
|
- // this.getList(this.page);
|
|
|
- // }
|
|
|
- // });
|
|
|
+ this.$message.success('读取成功!');
|
|
|
+ this.page.currentPage = 1;
|
|
|
+ this.getList(this.page);
|
|
|
+ }
|
|
|
+ });
|
|
|
},
|
|
|
},
|
|
|
}, {
|