优化按量收费不能创建的问题

This commit is contained in:
wuxw 2025-07-23 21:58:24 +08:00
parent a92b74f59f
commit 0c52f32a33
5 changed files with 36 additions and 13 deletions

View File

@ -27,11 +27,7 @@ export function listFeeConfigs(params) {
params
}).then(response => {
const res = response.data
if (res.code === 0) {
resolve(res)
} else {
reject(new Error(res.msg || 'Failed to list fee configs'))
}
}).catch(error => {
reject(error)
})

View File

@ -153,7 +153,7 @@ export default {
computingFormula: '6006',
valid: '1'
}).then(response => {
this.feeConfigOptions = response.data.feeConfigs
this.feeConfigOptions = response.feeConfigs
})
},
@ -235,8 +235,8 @@ export default {
saveProxyFee(params).then(() => {
this.$message.success(this.$t('addProxyFee.successMessage'))
this.$emit('success')
this.$message.success(this.$t('addProxyFee.successMessage'))
this.$emit('success')
this.handleClose()
}).catch(error => {
this.$message.error(error.message)
@ -246,7 +246,7 @@ export default {
resetForm() {
if (this.$refs.form) {
this.$refs.form.resetFields()
//this.$refs.form.resetFields()
}
this.formData = {
remark: '',

View File

@ -24,6 +24,32 @@ export function getDateYYYYMMDDHHMISS (){
return year + "" + month + "" + day + "" + hour + "" + minute + "" + second;
}
export function getDateStr() {
let date = new Date();
let year = date.getFullYear();
let month = date.getMonth() + 1;
let day = date.getDate();
let hour = date.getHours();
let minute = date.getMinutes();
let second = date.getSeconds();
if (month < 10) {
month = '0' + month;
}
if (day < 10) {
day = '0' + day;
}
if (hour < 10) {
hour = '0' + hour;
}
if (minute < 10) {
minute = '0' + minute;
}
if (second < 10) {
second = '0' + second;
}
return year + "-" + month + "-" + day + " " + hour + ":" + minute + ":" + second;
}
export function getDateYYYYMMDD() {
let date = new Date();
let year = date.getFullYear();

View File

@ -105,7 +105,7 @@
<el-form label-width="100px">
<el-form-item :label="$t('payFeeOrder.paymentTime')">
<el-date-picker v-model="payFeeOrderInfo.createTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
:placeholder="$t('payFeeOrder.paymentTimePlaceholder')" style="width: 100%;" readonly>
:placeholder="$t('payFeeOrder.paymentTimePlaceholder')" style="width: 100%;">
</el-date-picker>
</el-form-item>
@ -213,9 +213,10 @@ import ViewRoomData from '@/components/fee/viewRoomData'
import ViewFeeData from '@/components/fee/viewFeeData'
import ViewFeeConfigData from '@/components/fee/viewFeeConfigData'
import { listFeeObj } from '@/api/fee/payFeeOrderApi'
import { dateAdd, dateSub, addMonth } from '@/utils/dateUtil'
import { dateAdd, dateSub, addMonth,getDateStr } from '@/utils/dateUtil'
import { copyObject } from '@/utils/vc'
export default {
name: 'PayFeeOrderList',
components: {
@ -266,7 +267,7 @@ export default {
scale: 1,
decimalPlace: 2,
receivedAmountSwitch: '1',
createTime: new Date().toISOString().slice(0, 19).replace('T', ' '),
createTime: getDateStr(),
accountAmount: 0.0,
viewAccountAmount: 0.0,
deductionAmount: 0.0,

View File

@ -44,8 +44,8 @@ export default {
logo: '',
companyName:'',
loginForm: {
username: 'wuxw',
passwd: 'admin',
username: '',
passwd: '',
validateCode: ''
},
captchaUrl: '',