mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-05-03 17:40:13 +08:00
新增 修改站点计费模板状态方法
This commit is contained in:
@@ -88,6 +88,17 @@
|
||||
>
|
||||
<el-table-column label="模板编号" prop="templateCode" />
|
||||
<el-table-column label="名称" prop="templateName" />
|
||||
<el-table-column label="模板状态" prop="status" >
|
||||
<template slot-scope="scope">
|
||||
<el-switch
|
||||
v-model="scope.row.status"
|
||||
active-value="1"
|
||||
inactive-value="0"
|
||||
@change="changeStatus(scope.row)"
|
||||
>
|
||||
</el-switch>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- matchCars 使用车辆描述 -->
|
||||
<el-table-column label="描述" prop="remark" />
|
||||
<el-table-column label="设备类型" prop="deviceType">
|
||||
@@ -190,14 +201,15 @@
|
||||
import BondedDevice from "./bondedDevice.vue";
|
||||
import Expenses from "./expenses.vue";
|
||||
import {
|
||||
listTemplate,
|
||||
delTemplate,
|
||||
queryStationBillingTemplateList,
|
||||
queryPublicBillingTemplateList,
|
||||
stationImportBillingTemplate,
|
||||
publishBillingTemplate, getTemplate,
|
||||
listTemplate,
|
||||
delTemplate,
|
||||
queryStationBillingTemplateList,
|
||||
queryPublicBillingTemplateList,
|
||||
stationImportBillingTemplate,
|
||||
publishBillingTemplate, getTemplate, updateBillingTemplate, changeStationTemplate,
|
||||
} from "@/api/billing/template.js";
|
||||
import AddBilling from "../../../billing/template/components/addBilling.vue";
|
||||
import {updateStation} from "@/api/pile/station";
|
||||
|
||||
export default {
|
||||
components: { BondedDevice, Expenses, AddBilling },
|
||||
@@ -283,6 +295,17 @@ export default {
|
||||
this.publishTemplateId = "";
|
||||
});
|
||||
},
|
||||
changeStatus(info) {
|
||||
const param = {
|
||||
id: info.templateId,
|
||||
status: info.status,
|
||||
}
|
||||
console.log("param", param);
|
||||
changeStationTemplate(param).then((response) => {
|
||||
this.$modal.msgSuccess("修改成功");
|
||||
this.getStationBillingTemplateList();
|
||||
});
|
||||
},
|
||||
/** 打开导入表弹窗 */
|
||||
openImportTable() {
|
||||
console.log("111");
|
||||
@@ -333,7 +356,7 @@ export default {
|
||||
getStationBillingTemplateList() {
|
||||
// console.log("通过站点id查询计费模板", this.stationId)
|
||||
queryStationBillingTemplateList(this.stationId).then((response) => {
|
||||
// console.log("通过站点id查询计费模板 result: ", response.rows);
|
||||
console.log("通过站点id查询计费模板 result: ", response.rows);
|
||||
this.stationBillingTemplate = response.rows;
|
||||
});
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user