|
@@ -1,10 +1,17 @@
|
|
|
<template>
|
|
|
<div class="contrl">
|
|
|
- <el-divider content-position="left"><span style="color:#ff6154;">完善测算表信息</span></el-divider>
|
|
|
+ <el-divider content-position="left"><span style="color:#ff6154;">测算表作价</span></el-divider>
|
|
|
<div class="uploadDiv">
|
|
|
- <el-upload ref="importEqptExcel" drag action="#" multiple style="width:100%;" accept=".xls,.xlsx" :limit="1"
|
|
|
- :file-list="fileList" :on-exceed="handleExceed" :before-remove="beforeRemove" :auto-upload="false"
|
|
|
- :http-request="importEqptExcelData">
|
|
|
+ <el-descriptions title="基础信息" :column="1" border>
|
|
|
+ <el-descriptions-item label="评估基准日">{{ calculateBaseInfo.valuationBasisDate }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="工期">{{ calculateBaseInfo.constructionPeriod }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="利息">{{ calculateBaseInfo.interest }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="前期费用率">{{ calculateBaseInfo.preConstructionCostRatio }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="建设单位管理费率">{{ calculateBaseInfo.managementExpenseRatio }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ <el-upload ref="importEqptExcel" drag action="#" multiple style="width:100%;margin-top: 20px;"
|
|
|
+ accept=".xls,.xlsx" :limit="1" :file-list="fileList" :on-exceed="handleExceed" :before-remove="beforeRemove"
|
|
|
+ :auto-upload="false" :http-request="importEqptExcelData">
|
|
|
<el-icon class="el-icon--upload"><upload-filled /></el-icon>
|
|
|
<div class="el-upload__text">
|
|
|
拖拽文件 <em>或点击上传</em>
|
|
@@ -20,12 +27,27 @@
|
|
|
</el-button>
|
|
|
</div>
|
|
|
<div class="evaluateDiv">
|
|
|
+ <div class="search">
|
|
|
+ <el-input type="number" v-model="eqptDataQuery.sortId" placeholder="请输入序号" clearable
|
|
|
+ style="width: 200px;" />
|
|
|
+ <el-input v-model="eqptDataQuery.equipmentName" placeholder="请输入设备名称" clearable
|
|
|
+ style="width: 200px;margin-left: 10px;" />
|
|
|
+ <el-select v-model="eqptDataQuery.equipmentType" filterable placeholder="请选择设备类型" clearable
|
|
|
+ style="width: 200px;margin-left: 10px;">
|
|
|
+ <el-option label="国产设备" value="国产设备"></el-option>
|
|
|
+ <el-option label="非标设备" value="非标设备"></el-option>
|
|
|
+ <el-option label="进口设备" value="进口设备"></el-option>
|
|
|
+ </el-select>
|
|
|
+ <el-button type="danger" @click="getEqptDataPage()" style="margin-left: 10px;">
|
|
|
+ 搜索
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
<el-table :data="eqptPageData" border stripe>
|
|
|
- <el-table-column prop="sortId" label="序号" width="100">
|
|
|
+ <el-table-column prop="sortId" label="序号" width="80">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="sortId">
|
|
|
- <el-form :model="row">
|
|
|
- <el-input v-model="row.sortId" placeholder="请输入序号" />
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.sortId" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
|
</template>
|
|
@@ -33,7 +55,7 @@
|
|
|
<el-table-column prop="equipmentName" label="设备名称" width="250">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="equipmentName">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.equipmentName" placeholder="请输入设备名称" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -42,7 +64,7 @@
|
|
|
<el-table-column prop="manufacturer" label="生产厂家" width="250">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="manufacturer">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.manufacturer" placeholder="请输入生产厂家" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -51,7 +73,7 @@
|
|
|
<el-table-column prop="model" label="型号规格" width="250">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="model">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.model" placeholder="请输入型号规格" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -60,7 +82,7 @@
|
|
|
<el-table-column prop="purchaseDate" label="购买日期" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="purchaseDate">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.purchaseDate" placeholder="请输入购买日期" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -69,7 +91,7 @@
|
|
|
<el-table-column prop="activationDate" label="启用日期" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="activationDate">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.activationDate" placeholder="请输入启用日期" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -78,7 +100,7 @@
|
|
|
<el-table-column prop="storageLocation" label="存放地点" width="250">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="storageLocation">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.storageLocation" placeholder="请输入存放地点" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -87,7 +109,7 @@
|
|
|
<el-table-column prop="quantity" label="数量" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="quantity">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.quantity" placeholder="请输入数量" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -96,7 +118,7 @@
|
|
|
<el-table-column prop="unitOfMeasurement" label="计量单位" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="unitOfMeasurement">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.unitOfMeasurement" placeholder="请输入计量单位" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -105,7 +127,7 @@
|
|
|
<el-table-column prop="originalValue" label="账面原值" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="originalValue">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.originalValue" placeholder="请输入账面原值" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
@@ -114,44 +136,267 @@
|
|
|
<el-table-column prop="netValue" label="账面净值" width="150">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="netValue">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.netValue" placeholder="请输入账面净值" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="equipmentType" label="设备类型" width="150">
|
|
|
+ <el-table-column prop="taxedUnitPrice" label="含税单价" width="150">
|
|
|
<template #default="{ row }">
|
|
|
- <el-form-item prop="equipmentType">
|
|
|
- <el-form :model="row">
|
|
|
- <el-input v-model="row.equipmentType" placeholder="请输入设备类型" />
|
|
|
+ <el-form-item prop="taxedUnitPrice">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.taxedUnitPrice" placeholder="请输入含税单价" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
+ <el-table-column prop="taxRate" label="税率" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="taxRate">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.taxRate" placeholder="请输入税率" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="unTaxedUnitPrice" label="不含税单价" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <!-- 计算不含税单价 -->
|
|
|
+ <span>{{ row.unTaxedUnitPrice = (row.taxedUnitPrice / (1 + row.taxRate / 100)).toFixed(2) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column prop="remark" label="备注" width="250">
|
|
|
<template #default="{ row }">
|
|
|
<el-form-item prop="remark">
|
|
|
- <el-form :model="row">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
<el-input v-model="row.remark" placeholder="请输入备注" />
|
|
|
</el-form>
|
|
|
</el-form-item>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
+ <el-table-column label="评估价值" width="300">
|
|
|
+ <el-table-column prop="originalValue" label="原值" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.originalValue }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="depreciationRate" label="成新率%" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.depreciationRate }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="netValue" label="净值" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.netValue }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="年限成新率" width="300">
|
|
|
+ <el-table-column prop="economicServiceLife" label="经济使用年数" width="120">
|
|
|
+ <template #default="{ $index, row }">
|
|
|
+ <el-form-item prop="economicServiceLife">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.economicServiceLife" placeholder="请输入经济使用年数" @change="countDepreciationRate(row.depreciationRateByAge, $index)"/>
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="yearsInUse" label="已使用年数" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <!-- 计算已使用年数 -->
|
|
|
+ <span>{{ row.yearsInUse = (getDaysBetween(row.activationDate,
|
|
|
+ calculateBaseInfo.valuationBasisDate) /
|
|
|
+ 365).toFixed(2) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="年限成新率" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.depreciationRateByAge =
|
|
|
+ ((row.economicServiceLife - row.yearsInUse) / row.economicServiceLife < 0.15) ? 15 :
|
|
|
+ ((row.economicServiceLife - row.yearsInUse) / row.economicServiceLife).toFixed(2) * 100
|
|
|
+ }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="weight01" label="权重" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.weight01 }}%</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="directObservationDepreciationRate" label="直接观察成新率" width="150">
|
|
|
+ <template #default="{ $index, row }">
|
|
|
+ <el-form-item prop="directObservationDepreciationRate">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.directObservationDepreciationRate" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="weight02" label="权重" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.weight02 }}%</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="综合成新率" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.comprehensiveDepreciationRate =
|
|
|
+ ((row.depreciationRateByAge * row.weight01 + row.directObservationDepreciationRate *
|
|
|
+ row.weight02) /
|
|
|
+ 100).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="equipmentType" label="设备类型" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="equipmentType">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-select v-model="row.equipmentType" filterable placeholder="请选择设备类型" clearable
|
|
|
+ style="width: 130px;">
|
|
|
+ <el-option label="国产设备" value="国产设备"></el-option>
|
|
|
+ <el-option label="非标设备" value="非标设备"></el-option>
|
|
|
+ <el-option label="进口设备" value="进口设备"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="valuationMethod" label="作价方法" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="valuationMethod">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-select v-model="row.valuationMethod" filterable placeholder="请选择作价方法" clearable
|
|
|
+ style="width: 130px;">
|
|
|
+ <el-option label="询价" value="询价"></el-option>
|
|
|
+ <el-option label="物价指数调整法" value="物价指数调整法"></el-option>
|
|
|
+ <el-option label="二手价" value="二手价"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="inquiryBasis" label="询价依据" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="inquiryBasis">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.inquiryBasis" placeholder="询价依据" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="inquiryLocation" label="询价地点" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="inquiryLocation">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.inquiryLocation" placeholder="询价地点" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="price" label="单价" width="150">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="price">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.price" placeholder="单价" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="quotation" label="报价(含税不含运费不含安装调试费)" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.quotation = row.price * row.quantity }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="freightAndMiscellaneousFeeRate" label="运杂费率" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="freightAndMiscellaneousFeeRate">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.freightAndMiscellaneousFeeRate" placeholder="运杂费率" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="运杂费" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.freightAndMiscellaneousFee = (row.quotation * row.freightAndMiscellaneousFeeRate /
|
|
|
+ 100).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="baseRate" label="基础费率" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="baseRate">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.baseRate" placeholder="基础费率" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="基础费" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.baseFee = (row.quotation * row.baseRate / 100).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="installationRate" label="安装费率" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-form-item prop="installationRate">
|
|
|
+ <el-form :model="row" @submit.native.prevent>
|
|
|
+ <el-input v-model="row.installationRate" placeholder="安装费率" />
|
|
|
+ </el-form>
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="installationFee" label="安装费" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.installationFee = (row.quotation * row.installationRate / 100).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="设备工程费" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.equipmentEngineeringCosts = (row.quotation * 1 + row.freightAndMiscellaneousFee * 1 +
|
|
|
+ row.baseFee * 1 + row.installationFee * 1).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="前期费" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.initialFee = (row.equipmentEngineeringCosts *
|
|
|
+ calculateBaseInfo.preConstructionCostRatio / 100).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="资金成本" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.costOfCapital = countCostOfCapital(row) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="可抵扣增值税" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.deductibleVAT = countDeductibleVAT(row) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="重置全价(不含税)" width="100">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ row.excludeTaxPrice = (row.equipmentEngineeringCosts * 1 + row.initialFee * 1 +
|
|
|
+ row.costOfCapital * 1 - row.deductibleVAT * 1).toFixed(0) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column fixed="right" label="操作" min-width="55">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-button link type="primary" size="small" @click="save(row)">保存</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
<el-pagination background layout="prev, pager, next"
|
|
|
style="--el-color-primary: #ff6154;margin-top: 20px; float: right;" v-model:page-count="eqptDataQuery.pages"
|
|
|
v-model:current-page="eqptDataQuery.current" @current-change="getEqptDataPage" />
|
|
|
-
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import { mapStores } from 'pinia';
|
|
|
import { assetsProjectInfo } from '@/stores/assetsProjectStore';
|
|
|
-import { importEqptExcelData } from '@/api/assetsCalculate';
|
|
|
+import { importEqptExcelData, getCalculateBaseInfo, getValuationBasisDate } from '@/api/assetsCalculate';
|
|
|
import { getDataPage } from '@/api/assetsCalculateEqptData';
|
|
|
+import { getDaysBetween } from '@/utils/date';
|
|
|
+import { eqptLifeIfrRefsList } from '@/api/eqptLifeIfrRefs';
|
|
|
|
|
|
export default {
|
|
|
data() {
|
|
@@ -161,18 +406,25 @@ export default {
|
|
|
current: 1,
|
|
|
size: 10,
|
|
|
pages: 1,
|
|
|
- projectId: null
|
|
|
+ calculateId: null,
|
|
|
+ sortId: null,
|
|
|
+ equipmentName: null,
|
|
|
+ equipmentType: null
|
|
|
},
|
|
|
- eqptPageData: []
|
|
|
+ eqptPageData: [],
|
|
|
+ calculateBaseInfo: {},
|
|
|
+ eqptLifeIfrRefs: []
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
...mapStores(assetsProjectInfo),
|
|
|
},
|
|
|
created() {
|
|
|
+ this.getBaseInfo();
|
|
|
this.getEqptDataPage();
|
|
|
},
|
|
|
methods: {
|
|
|
+ getDaysBetween,
|
|
|
uploadEqptExcel() {
|
|
|
if (this.eqptPageData && this.eqptPageData.length > 0) {
|
|
|
ElMessageBox.confirm('上传新的申报信息将会覆盖旧数据', '确认上传', {
|
|
@@ -229,9 +481,139 @@ export default {
|
|
|
getDataPage(this.eqptDataQuery).then(res => {
|
|
|
this.eqptDataQuery.pages = res.data.pages
|
|
|
this.eqptPageData = res.data.records;
|
|
|
+ this.getEqptLifeIfrRefs();
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 获取测算表基础信息
|
|
|
+ getBaseInfo() {
|
|
|
+ getCalculateBaseInfo(this.projectStore.calculateProgress.id).then(res => {
|
|
|
+ if (res.data) {
|
|
|
+ this.calculateBaseInfo = JSON.parse(res.data);
|
|
|
+ this.getBasisDate();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 根据测算表id获取评估基准日
|
|
|
+ getBasisDate() {
|
|
|
+ getValuationBasisDate(this.projectStore.calculateProgress.id).then(res => {
|
|
|
+ if (res.data) {
|
|
|
+ this.calculateBaseInfo.valuationBasisDate = res.data;
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 计算直接观察成新率
|
|
|
+ countDepreciationRate(value, index) {
|
|
|
+ /**
|
|
|
+ * 年限成新率个位<=2成新率个位为0不进位
|
|
|
+ * 年限成新率个位>=8个位为0进一位
|
|
|
+ * 8>年限成新率个位>2个位为5不进位
|
|
|
+ */
|
|
|
+ if (value) {
|
|
|
+ // 获取个位
|
|
|
+ let unitsDigit = value % 10;
|
|
|
+ if (unitsDigit < 3) {
|
|
|
+ value = value - unitsDigit;
|
|
|
+ }
|
|
|
+ if (unitsDigit > 7) {
|
|
|
+ value = value - unitsDigit + 10;
|
|
|
+ }
|
|
|
+ if (unitsDigit < 8 && unitsDigit > 2 && unitsDigit !== 5) {
|
|
|
+ value = value - unitsDigit;
|
|
|
+ unitsDigit = 5
|
|
|
+ value = value + unitsDigit;
|
|
|
+ }
|
|
|
+ this.eqptPageData[index].directObservationDepreciationRate = value;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 计算资金成本
|
|
|
+ countCostOfCapital(row) {
|
|
|
+ // 原Excel公式:=ROUND((AM5*((1+$AS$4)^($AS$2)-1)+AL5*((1+$AS$4)^($AS$2/2)-1)),0)
|
|
|
+
|
|
|
+ // 前期费
|
|
|
+ const AM5 = row.initialFee;
|
|
|
+ // 前期费用率,除一百是因为数据库存的整数
|
|
|
+ const AS4 = this.calculateBaseInfo.preConstructionCostRatio / 100;
|
|
|
+ // 工期
|
|
|
+ const AS2 = this.calculateBaseInfo.constructionPeriod;
|
|
|
+ // 设备工程费
|
|
|
+ const AL5 = row.equipmentEngineeringCosts;
|
|
|
+
|
|
|
+ // 计算 指数 部分
|
|
|
+ const rate = (1 + AS4) ** (AS2);
|
|
|
+ const rateHalf = (1 + AS4) ** (AS2 / 2);
|
|
|
+
|
|
|
+ // 计算 前期费 部分
|
|
|
+ const AM5Part = AM5 * (rate - 1);
|
|
|
+
|
|
|
+ // 计算 设备工程费 部分
|
|
|
+ const AL5Part = AL5 * (rateHalf - 1);
|
|
|
+
|
|
|
+ // 将两部分相加并四舍五入到最接近的整数
|
|
|
+ const result = Math.round(AM5Part + AL5Part);
|
|
|
+ return result;
|
|
|
+ },
|
|
|
+ // 可抵扣增值税
|
|
|
+ countDeductibleVAT(row) {
|
|
|
+ // 报价(含税不含运费不含安装调试费)
|
|
|
+ const AE5 = row.quotation * 1;
|
|
|
+ // 运杂费
|
|
|
+ const AG5 = row.freightAndMiscellaneousFee * 1;
|
|
|
+ // 基础费
|
|
|
+ const AI5 = row.baseFee * 1;
|
|
|
+ // 安装费
|
|
|
+ const AK5 = row.installationFee * 1;
|
|
|
+ // 设备工程费
|
|
|
+ const AL5 = row.equipmentEngineeringCosts * 1;
|
|
|
+ // 前期费用率,除一百是因为数据库存的整数
|
|
|
+ const AS4 = this.calculateBaseInfo.preConstructionCostRatio / 100;
|
|
|
+ // 建设单位管理费率,除一百是因为数据库存的整数
|
|
|
+ const AS5 = this.calculateBaseInfo.preConstructionCostRatio / 100;
|
|
|
+
|
|
|
+ // 计算 报价 部分
|
|
|
+ const partAE5 = AE5 / (1 + 0.13) * 0.13;
|
|
|
+
|
|
|
+ // 计算 运杂费, 基础费, 安装费 部分
|
|
|
+ const sumAG5AI5AK5 = AG5 + AI5 + AK5;
|
|
|
+ const partAG5AI5AK5 = sumAG5AI5AK5 / (1 + 0.09) * 0.09;
|
|
|
+
|
|
|
+ // 计算 设备工程费 部分
|
|
|
+ const partAL5 = AL5 * (AS4 - AS5) / 1.06 * 0.06;
|
|
|
+
|
|
|
+ // 将三部分相加并四舍五入到最接近的整数
|
|
|
+ const result = Math.round(partAE5 + partAG5AI5AK5 + partAL5);
|
|
|
+
|
|
|
+ return result;
|
|
|
+ },
|
|
|
+ save(row) {
|
|
|
+ console.log(row);
|
|
|
+ },
|
|
|
+ // 通过设备名称判断参考数据中是否有符合的参考信息
|
|
|
+ mostSimilar() {
|
|
|
+ for (let index = 0; index < this.eqptPageData.length; index++) {
|
|
|
+ for (const item of this.eqptLifeIfrRefs) {
|
|
|
+ if (this.eqptPageData[index].equipmentName.includes(item.type)) {
|
|
|
+ this.eqptPageData[index].economicServiceLife = item.lifeRecommendedValue;
|
|
|
+ // 计算年限成新率
|
|
|
+ this.eqptPageData[index].depreciationRateByAge = ((this.eqptPageData[index].economicServiceLife - this.eqptPageData[index].yearsInUse) / this.eqptPageData[index].economicServiceLife < 0.15) ? 15 :
|
|
|
+ ((this.eqptPageData[index].economicServiceLife - this.eqptPageData[index].yearsInUse) / this.eqptPageData[index].economicServiceLife).toFixed(2) * 100
|
|
|
+ this.countDepreciationRate(this.eqptPageData[index].depreciationRateByAge, index)
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ },
|
|
|
+ // 获取设备参考年限、安装费率
|
|
|
+ getEqptLifeIfrRefs() {
|
|
|
+ eqptLifeIfrRefsList().then(res => {
|
|
|
+ if (res.data) {
|
|
|
+ this.eqptLifeIfrRefs = res.data;
|
|
|
+ this.mostSimilar();
|
|
|
+ }
|
|
|
})
|
|
|
}
|
|
|
- }
|
|
|
+ },
|
|
|
+
|
|
|
}
|
|
|
</script>
|
|
|
|
|
@@ -279,16 +661,25 @@ export default {
|
|
|
}
|
|
|
|
|
|
.uploadDiv {
|
|
|
- width: 15%;
|
|
|
+ width: 16%;
|
|
|
display: inline-block;
|
|
|
vertical-align: top;
|
|
|
}
|
|
|
|
|
|
.evaluateDiv {
|
|
|
margin-left: 1%;
|
|
|
- width: 84%;
|
|
|
+ width: 83%;
|
|
|
display: inline-block;
|
|
|
vertical-align: top;
|
|
|
min-height: 650px;
|
|
|
}
|
|
|
+
|
|
|
+.search {
|
|
|
+ margin-bottom: 8px;
|
|
|
+ float: right;
|
|
|
+}
|
|
|
+
|
|
|
+.el-form-item {
|
|
|
+ margin-bottom: 0
|
|
|
+}
|
|
|
</style>
|