Commit 7a487e7e authored by dcy's avatar dcy

Merge remote-tracking branch 'origin/dev' into dev

parents 6ef158aa d935979a
...@@ -18,6 +18,16 @@ export function updateCurrencyEcash(data) { ...@@ -18,6 +18,16 @@ export function updateCurrencyEcash(data) {
}) })
} }
// 更新E-Cash汇率单位
export function updateCurrencyEcashAll(data) {
console.log(data);
return request({
url: '/ecw/currency-ecash/updateAll',
method: 'put',
data: data
})
}
// 删除E-Cash汇率单位 // 删除E-Cash汇率单位
export function deleteCurrencyEcash(id) { export function deleteCurrencyEcash(id) {
return request({ return request({
......
...@@ -34,36 +34,37 @@ ...@@ -34,36 +34,37 @@
<el-form ref="retForm" :model="retForm"> <el-form ref="retForm" :model="retForm">
<el-form-item label="有效时间(尼日利亚)"> <el-form-item label="有效时间(尼日利亚)">
<el-col :span="3"> <el-col :span="3">
<el-date-picker type="datetime" disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss" <el-date-picker type="datetime" value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss"
v-model="this.ecashDatas.find(item=>item.value == 1).label" v-model="retForm.nrlyStartTime"
style="width: 100%;"></el-date-picker> style="width: 100%;" @change="changeDictData1"></el-date-picker>
</el-col> </el-col>
<el-col :span="1" align="center">-</el-col> <el-col :span="1" align="center">-</el-col>
<el-col :span="3"> <el-col :span="3">
<el-time-picker type="datetime" disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss" <el-date-picker type="datetime" value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss"
v-model="this.ecashDatas.find(item=>item.value == 2).label" v-model="retForm.nrlyEndTime" @change="changeDictData2"
style="width: 100%;"></el-time-picker> style="width: 100%;"></el-date-picker>
</el-col> </el-col>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-form> <el-form>
<el-form-item label="有效时间(北京)"> <el-form-item label="有效时间(北京)">
<el-col :span="3"> <el-col :span="3">
<el-date-picker type="datetime" disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss" <el-date-picker type="datetime" :disable="showFlag" value-format="yyyy-MM-dd HH:mm:ss"
v-model="this.ecashDatas.find(item=>item.value == 3).label" format="yyyy-MM-dd HH:mm:ss" @change="changeDictData3"
v-model="retForm.bjStartTime"
style="width: 100%;"></el-date-picker> style="width: 100%;"></el-date-picker>
</el-col> </el-col>
<el-col align="center" :span="1">-</el-col> <el-col align="center" :span="1">-</el-col>
<el-col :span="3"> <el-col :span="3">
<el-time-picker type="datetime" disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss" <el-date-picker type="datetime" value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd HH:mm:ss"
v-model="this.ecashDatas.find(item=>item.value == 4).label" v-model="retForm.bjEndTime" @change="changeDictData4"
style="width: 100%;"></el-time-picker> style="width: 100%;"></el-date-picker>
</el-col> </el-col>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-form :inline="true"> <el-form :inline="true">
<el-form-item label="过期提示语:" prop="remark"> <el-form-item label="过期提示语:" prop="remark">
<span>{{ 5 | ecashDataFilter(ecashDatas) }}</span> <el-input v-model="retForm.remark" type="textarea" @change="changeDictData5"></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
</el-card> </el-card>
...@@ -134,13 +135,14 @@ ...@@ -134,13 +135,14 @@
createCurrencyEcash, createCurrencyEcash,
updateCurrencyEcash, updateCurrencyEcash,
deleteCurrencyEcash, deleteCurrencyEcash,
updateCurrencyEcashAll,
getCurrencyEcash, getCurrencyEcash,
getCurrencyEcashPage, getCurrencyEcashPage,
exportCurrencyEcashExcel exportCurrencyEcashExcel
} from "@/api/ecw/currencyEcash"; } from "@/api/ecw/currencyEcash";
import {CommonStatusEnum} from "@/utils/constants"; import {CommonStatusEnum} from "@/utils/constants";
import {changeUserStatus} from "@/api/system/user"; import {changeUserStatus} from "@/api/system/user";
import {DICT_TYPE, getDictDatas} from "@/utils/dict"; import {DICT_TYPE, getDictDatas, getDictData} from "@/utils/dict";
export default { export default {
name: "CurrencyEcash", name: "CurrencyEcash",
...@@ -171,6 +173,11 @@ ...@@ -171,6 +173,11 @@
open: false, open: false,
dateRangeCreateTime: [], dateRangeCreateTime: [],
showFlag: false, showFlag: false,
nrlyStartTime: getDictData(DICT_TYPE.ECASH_INIT, 1).label,
nrlyEndTime: getDictData(DICT_TYPE.ECASH_INIT, 2).label,
bjStartTime: getDictData(DICT_TYPE.ECASH_INIT, 3).label,
bjEndTime: getDictData(DICT_TYPE.ECASH_INIT, 4).label,
remark: getDictData(DICT_TYPE.ECASH_INIT, 5).label,
startTime: "", startTime: "",
// 查询参数 // 查询参数
queryParams: { queryParams: {
...@@ -184,6 +191,7 @@ ...@@ -184,6 +191,7 @@
aorder: null, aorder: null,
}, },
retForm: {}, retForm: {},
updForm: {},
// 表单参数 // 表单参数
form: {}, form: {},
// 表单校验 // 表单校验
...@@ -264,6 +272,46 @@ ...@@ -264,6 +272,46 @@
this.showFlag = false; this.showFlag = false;
}); });
}, },
changeDictData1(value) {
this.updForm.nrlyStartTime = value;
updateCurrencyEcashAll(this.updForm).then(response => {
this.$modal.msgSuccess("修改成功");
this.getList();
this.showFlag = false;
});
},
changeDictData2(value) {
this.updForm.nrlyEndTime = value;
updateCurrencyEcashAll(this.updForm).then(response => {
this.$modal.msgSuccess("修改成功");
this.getList();
this.showFlag = false;
});
},
changeDictData3(value) {
this.updForm.bjStartTime = value;
updateCurrencyEcashAll(this.updForm).then(response => {
this.$modal.msgSuccess("修改成功");
this.getList();
this.showFlag = false;
});
},
changeDictData4(value) {
this.updForm.bjEndTime = value;
updateCurrencyEcashAll(this.updForm).then(response => {
this.$modal.msgSuccess("修改成功");
this.getList();
this.showFlag = false;
});
},
changeDictData5(value) {
this.updForm.remark = value;
updateCurrencyEcashAll(this.updForm).then(response => {
this.$modal.msgSuccess("修改成功");
this.getList();
this.showFlag = false;
});
},
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment