|
@@ -1,6 +1,91 @@
|
|
<template>
|
|
<template>
|
|
<div class="app-container">
|
|
<div class="app-container">
|
|
<el-row :gutter="10" class="mb8">
|
|
<el-row :gutter="10" class="mb8">
|
|
|
|
+ <el-col :span="1.5">电价策略</el-col>
|
|
|
|
+ </el-row>
|
|
|
|
+ <el-row :gutter="10" class="mb8">
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button
|
|
|
|
+ type="primary"
|
|
|
|
+ plain
|
|
|
|
+ icon="el-icon-plus"
|
|
|
|
+ size="mini"
|
|
|
|
+ @click="handleAttrAdd"
|
|
|
|
+ v-hasPermi="['basecfg:price:add']"
|
|
|
|
+ >新增</el-button>
|
|
|
|
+ </el-col>
|
|
|
|
+ <right-toolbar :showSearch.sync="showSearch" @queryTable="getAttrList"></right-toolbar>
|
|
|
|
+ </el-row>
|
|
|
|
+
|
|
|
|
+ <el-table v-loading="loading" :data="attrList" >
|
|
|
|
+ <el-table-column label="服务区" align="center" prop="areaName" />
|
|
|
|
+ <el-table-column label="用电分类" align="center" prop="elecTypeName" />
|
|
|
|
+ <el-table-column label="电压等级" align="center" prop="voltageLevel" />
|
|
|
|
+ <el-table-column label="容(需)量策略" align="center">
|
|
|
|
+ <el-table-column label="容(需)量类型" align="center" prop="reqCapacityFlag" :formatter="matchReqCapacityFlag" />
|
|
|
|
+ <el-table-column label="变压器容量(千伏·安)" align="center" prop="transCapacity" />
|
|
|
|
+ <el-table-column label="最大需量(千瓦)" align="center" prop="reqQuantity" />
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ <el-button
|
|
|
|
+ size="mini"
|
|
|
|
+ type="text"
|
|
|
|
+ icon="el-icon-edit"
|
|
|
|
+ @click="handleAttrUpdate(scope.row)"
|
|
|
|
+ v-hasPermi="['basecfg:price:edit']"
|
|
|
|
+ >修改</el-button>
|
|
|
|
+ <el-button
|
|
|
|
+ size="mini"
|
|
|
|
+ type="text"
|
|
|
|
+ icon="el-icon-delete"
|
|
|
|
+ @click="handleAttrDelete(scope.row)"
|
|
|
|
+ v-hasPermi="['basecfg:price:remove']"
|
|
|
|
+ >删除</el-button>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ </el-table>
|
|
|
|
+
|
|
|
|
+ <pagination
|
|
|
|
+ v-show="total>0"
|
|
|
|
+ :total="total"
|
|
|
|
+ :page.sync="queryAttrParams.pageNum"
|
|
|
|
+ :limit.sync="queryAttrParams.pageSize"
|
|
|
|
+ @pagination="getAttrList"
|
|
|
|
+ />
|
|
|
|
+ <!-- 添加或修改服务区用电属性对话框 -->
|
|
|
|
+ <el-dialog :title="title" :visible.sync="attrOpen" width="500px" append-to-body>
|
|
|
|
+ <el-form ref="attrForm" :model="attrForm" :rules="attrRules" label-width="150px">
|
|
|
|
+ <el-form-item label="园区" prop="areaCode">
|
|
|
|
+ <el-select v-model="attrForm.areaCode">
|
|
|
|
+ <el-option v-for="item in areaOptions" :label="item.label" :value="item.id" :key="item.id" />
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="价格策略" prop="priceCode" >
|
|
|
|
+ <el-select v-model="attrForm.priceCode">
|
|
|
|
+ <el-option v-for="item in valencyOptions" :label="`${item.elecTypeName}<${item.voltageLevel}>`" :value="item.cfgCode" :key="item.cfgCode" />
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="容(需)量类型" prop="reqCapacityFlag">
|
|
|
|
+ <el-select v-model="attrForm.reqCapacityFlag">
|
|
|
|
+ <el-option v-for="item in reqCapacityOptions" :label="item.name" :value="item.code" :key="item.code" />
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="变压器容量(kVA/月)" prop="transCapacity" v-if="attrForm.reqCapacityFlag === 1">
|
|
|
|
+ <el-input v-model="attrForm.transCapacity" placeholder="请输入变压器容量" />
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="最大需量(kW·h/月)" prop="reqQuantity" v-if="attrForm.reqCapacityFlag === 2">
|
|
|
|
+ <el-input v-model="attrForm.reqQuantity" placeholder="请输入最大需量" />
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
|
+ <el-button type="primary" @click="submitAttrForm">确 定</el-button>
|
|
|
|
+ <el-button @click="attrCancel">取 消</el-button>
|
|
|
|
+ </div>
|
|
|
|
+ </el-dialog>
|
|
|
|
+
|
|
|
|
+ <!-- 国网电价配置 -->
|
|
|
|
+ <el-row :gutter="10" class="mb8">
|
|
<el-col :span="1.5">国网电价</el-col>
|
|
<el-col :span="1.5">国网电价</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row :gutter="10" class="mb8">
|
|
<el-row :gutter="10" class="mb8">
|
|
@@ -11,7 +96,7 @@
|
|
icon="el-icon-plus"
|
|
icon="el-icon-plus"
|
|
size="mini"
|
|
size="mini"
|
|
@click="handleValencyAdd"
|
|
@click="handleValencyAdd"
|
|
- v-hasPermi="['basecfg:electricity:add']"
|
|
|
|
|
|
+ v-hasPermi="['basecfg:price:add']"
|
|
>新增</el-button>
|
|
>新增</el-button>
|
|
</el-col>
|
|
</el-col>
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getValencyList"></right-toolbar>
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getValencyList"></right-toolbar>
|
|
@@ -38,14 +123,14 @@
|
|
type="text"
|
|
type="text"
|
|
icon="el-icon-edit"
|
|
icon="el-icon-edit"
|
|
@click="handleValencyUpdate(scope.row)"
|
|
@click="handleValencyUpdate(scope.row)"
|
|
- v-hasPermi="['basecfg:electricity:edit']"
|
|
|
|
|
|
+ v-hasPermi="['basecfg:price:edit']"
|
|
>修改</el-button>
|
|
>修改</el-button>
|
|
<el-button
|
|
<el-button
|
|
size="mini"
|
|
size="mini"
|
|
type="text"
|
|
type="text"
|
|
icon="el-icon-delete"
|
|
icon="el-icon-delete"
|
|
@click="handleValencyDelete(scope.row)"
|
|
@click="handleValencyDelete(scope.row)"
|
|
- v-hasPermi="['basecfg:electricity:remove']"
|
|
|
|
|
|
+ v-hasPermi="['basecfg:price:remove']"
|
|
>删除</el-button>
|
|
>删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
@@ -54,8 +139,8 @@
|
|
<pagination
|
|
<pagination
|
|
v-show="total>0"
|
|
v-show="total>0"
|
|
:total="total"
|
|
:total="total"
|
|
- :page.sync="queryParams.pageNum"
|
|
|
|
- :limit.sync="queryParams.pageSize"
|
|
|
|
|
|
+ :page.sync="queryValencyParams.pageNum"
|
|
|
|
+ :limit.sync="queryValencyParams.pageSize"
|
|
@pagination="getValencyList"
|
|
@pagination="getValencyList"
|
|
/>
|
|
/>
|
|
|
|
|
|
@@ -101,8 +186,9 @@
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
|
|
|
|
+ <!-- 光伏电价配置 -->
|
|
<el-row :gutter="10" class="mb8">
|
|
<el-row :gutter="10" class="mb8">
|
|
- <el-col :span="1.5">价格策略</el-col>
|
|
|
|
|
|
+ <el-col :span="1.5">光伏电价</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row :gutter="10" class="mb8">
|
|
<el-row :gutter="10" class="mb8">
|
|
<el-col :span="1.5">
|
|
<el-col :span="1.5">
|
|
@@ -111,75 +197,53 @@
|
|
plain
|
|
plain
|
|
icon="el-icon-plus"
|
|
icon="el-icon-plus"
|
|
size="mini"
|
|
size="mini"
|
|
- @click="handleAttrAdd"
|
|
|
|
- v-hasPermi="['basecfg:electricity:add']"
|
|
|
|
|
|
+ @click="handlePvPriceAdd"
|
|
|
|
+ v-hasPermi="['basecfg:price:add']"
|
|
>新增</el-button>
|
|
>新增</el-button>
|
|
</el-col>
|
|
</el-col>
|
|
- <right-toolbar :showSearch.sync="showSearch" @queryTable="getAttrList"></right-toolbar>
|
|
|
|
|
|
+ <right-toolbar :showSearch.sync="showSearch" @queryTable="getPvPriceList"></right-toolbar>
|
|
</el-row>
|
|
</el-row>
|
|
-
|
|
|
|
- <el-table v-loading="loading" :data="attrList" >
|
|
|
|
- <el-table-column label="服务区" align="center" prop="areaName" />
|
|
|
|
- <el-table-column label="用电分类" align="center" prop="elecTypeName" />
|
|
|
|
- <el-table-column label="电压等级" align="center" prop="voltageLevel" />
|
|
|
|
- <el-table-column label="容(需)量类型" align="center" prop="reqCapacityFlag" :formatter="matchReqCapacityFlag" />
|
|
|
|
- <el-table-column label="变压器容量(千伏·安)" align="center" prop="transCapacity" />
|
|
|
|
- <el-table-column label="最大需量(千瓦)" align="center" prop="reqQuantity" />
|
|
|
|
|
|
+ <el-table v-loading="loading" :data="pvPriceList" >
|
|
|
|
+ <el-table-column label="价格名称" align="center" prop="priceName" />
|
|
|
|
+ <el-table-column label="用户电价/脱硫煤电价" align="center" prop="objPrice" />
|
|
|
|
+ <el-table-column label="国家补贴" align="center" prop="stateSubsidy" />
|
|
|
|
+ <el-table-column label="地方补贴" align="center" prop="localSubsidy" />
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button
|
|
<el-button
|
|
size="mini"
|
|
size="mini"
|
|
type="text"
|
|
type="text"
|
|
icon="el-icon-edit"
|
|
icon="el-icon-edit"
|
|
- @click="handleAttrUpdate(scope.row)"
|
|
|
|
- v-hasPermi="['basecfg:electricity:edit']"
|
|
|
|
|
|
+ @click="handlePvPriceUpdate(scope.row)"
|
|
|
|
+ v-hasPermi="['basecfg:price:edit']"
|
|
>修改</el-button>
|
|
>修改</el-button>
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- type="text"
|
|
|
|
- icon="el-icon-delete"
|
|
|
|
- @click="handleAttrDelete(scope.row)"
|
|
|
|
- v-hasPermi="['basecfg:electricity:remove']"
|
|
|
|
- >删除</el-button>
|
|
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
|
|
|
|
- <pagination
|
|
|
|
- v-show="total>0"
|
|
|
|
- :total="total"
|
|
|
|
- :page.sync="queryParams.pageNum"
|
|
|
|
- :limit.sync="queryParams.pageSize"
|
|
|
|
- @pagination="getAttrList"
|
|
|
|
- />
|
|
|
|
- <!-- 添加或修改服务区用电属性对话框 -->
|
|
|
|
- <el-dialog :title="title" :visible.sync="attrOpen" width="500px" append-to-body>
|
|
|
|
- <el-form ref="attrForm" :model="attrForm" :rules="attrRules" label-width="150px">
|
|
|
|
- <el-form-item label="园区" prop="areaCode">
|
|
|
|
- <el-select v-model="attrForm.areaCode">
|
|
|
|
- <el-option v-for="item in areaOptions" :label="item.label" :value="item.id" :key="item.id" />
|
|
|
|
- </el-select>
|
|
|
|
|
|
+ <!-- 添加或修改电价配置对话框 -->
|
|
|
|
+ <el-dialog :title="title" :visible.sync="pvPriceOpen" width="500px" append-to-body>
|
|
|
|
+ <el-form ref="pvPriceFrom" :model="pvPriceFrom" :rules="pvPriceRules" label-width="150px">
|
|
|
|
+ <el-form-item label="配置代码" prop="cfgCode">
|
|
|
|
+ <el-input v-model="pvPriceFrom.cfgCode" placeholder="请输入配置代码" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="价格策略" prop="priceCode" >
|
|
|
|
- <el-select v-model="attrForm.priceCode">
|
|
|
|
- <el-option v-for="item in valencyOptions" :label="`${item.elecTypeName}<${item.voltageLevel}>`" :value="item.cfgCode" :key="item.cfgCode" />
|
|
|
|
- </el-select>
|
|
|
|
|
|
+ <el-form-item label="价格名称" prop="priceName">
|
|
|
|
+ <el-input v-model="pvPriceFrom.priceName" placeholder="请输入价格名称" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="容(需)量类型" prop="reqCapacityFlag">
|
|
|
|
- <el-select v-model="attrForm.reqCapacityFlag">
|
|
|
|
- <el-option v-for="item in reqCapacityOptions" :label="item.name" :value="item.code" :key="item.code" />
|
|
|
|
- </el-select>
|
|
|
|
|
|
+ <el-form-item label="用户/脱硫煤电价" prop="objPrice">
|
|
|
|
+ <el-input v-model="pvPriceFrom.objPrice" placeholder="请输入价格" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="变压器容量(kVA/月)" prop="transCapacity" v-if="attrForm.reqCapacityFlag === 1">
|
|
|
|
- <el-input v-model="attrForm.transCapacity" placeholder="请输入变压器容量" />
|
|
|
|
|
|
+ <el-form-item label="国家补贴" prop="stateSubsidy">
|
|
|
|
+ <el-input v-model="pvPriceFrom.stateSubsidy" placeholder="请输入国家补贴" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="最大需量(kW·h/月)" prop="reqQuantity" v-if="attrForm.reqCapacityFlag === 2">
|
|
|
|
- <el-input v-model="attrForm.reqQuantity" placeholder="请输入最大需量" />
|
|
|
|
|
|
+ <el-form-item label="地方补贴" prop="localSubsidy">
|
|
|
|
+ <el-input v-model="pvPriceFrom.localSubsidy" placeholder="请输入国家补贴" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
|
+
|
|
</el-form>
|
|
</el-form>
|
|
<div slot="footer" class="dialog-footer">
|
|
<div slot="footer" class="dialog-footer">
|
|
- <el-button type="primary" @click="submitAttrForm">确 定</el-button>
|
|
|
|
- <el-button @click="attrCancel">取 消</el-button>
|
|
|
|
|
|
+ <el-button type="primary" @click="submitPvPriceForm">确 定</el-button>
|
|
|
|
+ <el-button @click="pvPriceCancel">取 消</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
</div>
|
|
</div>
|
|
@@ -188,6 +252,13 @@
|
|
<script>
|
|
<script>
|
|
import { listAttr, getAttr, delAttr, addAttr, updateAttr } from "@/api/basecfg/electricity";
|
|
import { listAttr, getAttr, delAttr, addAttr, updateAttr } from "@/api/basecfg/electricity";
|
|
import { listValency, listValencyAll, getValency, addValency, delValency, updateValency } from '@/api/basecfg/elecvalency'
|
|
import { listValency, listValencyAll, getValency, addValency, delValency, updateValency } from '@/api/basecfg/elecvalency'
|
|
|
|
+import {
|
|
|
|
+ addPvPriceConfig,
|
|
|
|
+ delPvPriceConfig,
|
|
|
|
+ getPvPriceConfig,
|
|
|
|
+ listPvPriceConfig,
|
|
|
|
+ updatePvPriceConfig
|
|
|
|
+} from '@/api/basecfg/pvprice'
|
|
import { getElecValencyType } from '@/api/commonApi'
|
|
import { getElecValencyType } from '@/api/commonApi'
|
|
import { areaTreeSelect } from "@/api/basecfg/area"
|
|
import { areaTreeSelect } from "@/api/basecfg/area"
|
|
|
|
|
|
@@ -211,29 +282,35 @@ export default {
|
|
attrList: [],
|
|
attrList: [],
|
|
// 电价表格
|
|
// 电价表格
|
|
valencyList: [],
|
|
valencyList: [],
|
|
|
|
+ // 光伏电价
|
|
|
|
+ pvPriceList: [],
|
|
// 弹出层标题
|
|
// 弹出层标题
|
|
title: "",
|
|
title: "",
|
|
// 是否显示弹出层
|
|
// 是否显示弹出层
|
|
attrOpen: false,
|
|
attrOpen: false,
|
|
valencyOpen: false,
|
|
valencyOpen: false,
|
|
|
|
+ pvPriceOpen: false,
|
|
// 选项定义
|
|
// 选项定义
|
|
valencyTypeOptions: undefined,
|
|
valencyTypeOptions: undefined,
|
|
areaOptions: undefined,
|
|
areaOptions: undefined,
|
|
valencyOptions: undefined,
|
|
valencyOptions: undefined,
|
|
// 查询参数
|
|
// 查询参数
|
|
- queryParams: {
|
|
|
|
|
|
+ queryValencyParams: {
|
|
pageNum: 1,
|
|
pageNum: 1,
|
|
- pageSize: 10,
|
|
|
|
- areaCode: null,
|
|
|
|
- elecType: null,
|
|
|
|
- priceCode: null,
|
|
|
|
- reqCapacityFlag: null,
|
|
|
|
- transCapacity: null,
|
|
|
|
- reqQuantity: null,
|
|
|
|
|
|
+ pageSize: 10
|
|
|
|
+ },
|
|
|
|
+ queryAttrParams: {
|
|
|
|
+ pageNum: 1,
|
|
|
|
+ pageSize: 10
|
|
|
|
+ },
|
|
|
|
+ queryPvPriceParams: {
|
|
|
|
+ pageNum: 1,
|
|
|
|
+ pageSize: 10
|
|
},
|
|
},
|
|
// 表单参数
|
|
// 表单参数
|
|
attrForm: {},
|
|
attrForm: {},
|
|
- valencyFrom:{},
|
|
|
|
|
|
+ valencyFrom: {},
|
|
|
|
+ pvPriceFrom: {},
|
|
// 表单校验
|
|
// 表单校验
|
|
valencyRules: {
|
|
valencyRules: {
|
|
cfgCode: [
|
|
cfgCode: [
|
|
@@ -246,7 +323,6 @@ export default {
|
|
{ required: true, message: "电压等级不为空", trigger: "blur" }
|
|
{ required: true, message: "电压等级不为空", trigger: "blur" }
|
|
]
|
|
]
|
|
},
|
|
},
|
|
-
|
|
|
|
// 表单校验
|
|
// 表单校验
|
|
attrRules: {
|
|
attrRules: {
|
|
areaCode: [
|
|
areaCode: [
|
|
@@ -259,6 +335,15 @@ export default {
|
|
{ required: true, message: "价格编码不能为空", trigger: "blur" }
|
|
{ required: true, message: "价格编码不能为空", trigger: "blur" }
|
|
],
|
|
],
|
|
},
|
|
},
|
|
|
|
+ // 表单校验
|
|
|
|
+ pvPriceRules: {
|
|
|
|
+ cfgCode: [
|
|
|
|
+ { required: true, message: "配置代码不为空", trigger: "blur" }
|
|
|
|
+ ],
|
|
|
|
+ priceName: [
|
|
|
|
+ { required: true, message: "价格名称不为空", trigger: "blur" }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
reqCapacityOptions: [
|
|
reqCapacityOptions: [
|
|
{ code: 0, name: "不涉及"},
|
|
{ code: 0, name: "不涉及"},
|
|
{ code: 1, name: "容量电价"},
|
|
{ code: 1, name: "容量电价"},
|
|
@@ -269,12 +354,13 @@ export default {
|
|
created() {
|
|
created() {
|
|
this.getAttrList();
|
|
this.getAttrList();
|
|
this.getValencyList();
|
|
this.getValencyList();
|
|
|
|
+ this.getPvPriceList();
|
|
this.getValencyType();
|
|
this.getValencyType();
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
getValencyList() {
|
|
getValencyList() {
|
|
this.loading = true;
|
|
this.loading = true;
|
|
- listValency(this.queryParams).then(response => {
|
|
|
|
|
|
+ listValency(this.queryValencyParams).then(response => {
|
|
this.valencyList = response.rows;
|
|
this.valencyList = response.rows;
|
|
this.total = response.total;
|
|
this.total = response.total;
|
|
this.loading = false;
|
|
this.loading = false;
|
|
@@ -351,7 +437,7 @@ export default {
|
|
/** 查询服务区用电属性列表 */
|
|
/** 查询服务区用电属性列表 */
|
|
getAttrList() {
|
|
getAttrList() {
|
|
this.loading = true;
|
|
this.loading = true;
|
|
- listAttr(this.queryParams).then(response => {
|
|
|
|
|
|
+ listAttr(this.queryAttrParams).then(response => {
|
|
this.attrList = response.rows;
|
|
this.attrList = response.rows;
|
|
this.total = response.total;
|
|
this.total = response.total;
|
|
this.loading = false;
|
|
this.loading = false;
|
|
@@ -379,11 +465,11 @@ export default {
|
|
},
|
|
},
|
|
/** 搜索按钮操作 */
|
|
/** 搜索按钮操作 */
|
|
handleAttrQuery() {
|
|
handleAttrQuery() {
|
|
- this.queryParams.pageNum = 1;
|
|
|
|
|
|
+ this.queryAttrParams.pageNum = 1;
|
|
this.getAttrList();
|
|
this.getAttrList();
|
|
},
|
|
},
|
|
handleValencyQuery() {
|
|
handleValencyQuery() {
|
|
- this.queryParams.pageNum = 1;
|
|
|
|
|
|
+ this.queryValencyParams.pageNum = 1;
|
|
this.getValencyList();
|
|
this.getValencyList();
|
|
},
|
|
},
|
|
/** 重置按钮操作 */
|
|
/** 重置按钮操作 */
|
|
@@ -441,6 +527,77 @@ export default {
|
|
this.$modal.msgSuccess("删除成功");
|
|
this.$modal.msgSuccess("删除成功");
|
|
}).catch(() => {});
|
|
}).catch(() => {});
|
|
},
|
|
},
|
|
|
|
+ getPvPriceList() {
|
|
|
|
+ this.loading = true;
|
|
|
|
+ listPvPriceConfig(this.queryPvPriceParams).then(response => {
|
|
|
|
+ this.pvPriceList = response.rows;
|
|
|
|
+ this.total = response.total;
|
|
|
|
+ this.loading = false;
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ // 取消按钮
|
|
|
|
+ pvPriceCancel() {
|
|
|
|
+ this.pvPriceOpen = false;
|
|
|
|
+ this.pvPriceReset();
|
|
|
|
+ },
|
|
|
|
+ // 表单重置
|
|
|
|
+ pvPriceReset() {
|
|
|
|
+ this.pvPriceFrom = {
|
|
|
|
+ id: null,
|
|
|
|
+ cfgCode: null,
|
|
|
|
+ priceName: null,
|
|
|
|
+ objPrice: null,
|
|
|
|
+ stateSubsidy: null,
|
|
|
|
+ localSubsidy: null
|
|
|
|
+ };
|
|
|
|
+ this.resetForm("pvPriceFrom");
|
|
|
|
+ },
|
|
|
|
+ /** 新增按钮操作 */
|
|
|
|
+ handlePvPriceAdd() {
|
|
|
|
+ this.pvPriceReset();
|
|
|
|
+ this.pvPriceOpen = true;
|
|
|
|
+ this.title = "添加光伏电价配置";
|
|
|
|
+ },
|
|
|
|
+ /** 修改按钮操作 */
|
|
|
|
+ handlePvPriceUpdate(row) {
|
|
|
|
+ this.pvPriceReset();
|
|
|
|
+ const id = row.id || this.ids
|
|
|
|
+ getPvPriceConfig(id).then(response => {
|
|
|
|
+ this.pvPriceFrom = response.data;
|
|
|
|
+ this.pvPriceOpen = true;
|
|
|
|
+ this.title = "修改光伏电价配置";
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ /** 提交按钮 */
|
|
|
|
+ submitPvPriceForm() {
|
|
|
|
+ this.$refs["pvPriceFrom"].validate(valid => {
|
|
|
|
+ if (valid) {
|
|
|
|
+ if (this.pvPriceFrom.id != null) {
|
|
|
|
+ updatePvPriceConfig(this.pvPriceFrom).then(response => {
|
|
|
|
+ this.$modal.msgSuccess("修改成功");
|
|
|
|
+ this.pvPriceOpen = false;
|
|
|
|
+ this.getPvPriceList();
|
|
|
|
+ });
|
|
|
|
+ } else {
|
|
|
|
+ addPvPriceConfig(this.pvPriceFrom).then(response => {
|
|
|
|
+ this.$modal.msgSuccess("新增成功");
|
|
|
|
+ this.pvPriceOpen = false;
|
|
|
|
+ this.getPvPriceList();
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ /** 删除按钮操作 */
|
|
|
|
+ handlePvPriceDelete(row) {
|
|
|
|
+ const ids = row.id || this.ids;
|
|
|
|
+ this.$modal.confirm('是否确认删除电价配置编号为"' + ids + '"的数据项?').then(function() {
|
|
|
|
+ return delPvPriceConfig(ids);
|
|
|
|
+ }).then(() => {
|
|
|
|
+ this.getPvPriceList();
|
|
|
|
+ this.$modal.msgSuccess("删除成功");
|
|
|
|
+ }).catch(() => {});
|
|
|
|
+ },
|
|
matchReqCapacityFlag(row, column, cellValue, index) {
|
|
matchReqCapacityFlag(row, column, cellValue, index) {
|
|
const reqCapacityFlagMap = {
|
|
const reqCapacityFlagMap = {
|
|
0: '不涉及',
|
|
0: '不涉及',
|