diff --git a/yudao-ui-admin/src/views/system/tenant/commissionSetting.vue b/yudao-ui-admin/src/views/system/tenant/commissionSetting.vue index 3a240543f..4ce012d62 100644 --- a/yudao-ui-admin/src/views/system/tenant/commissionSetting.vue +++ b/yudao-ui-admin/src/views/system/tenant/commissionSetting.vue @@ -46,8 +46,8 @@ export default { callback(new Error('请输入值')); return false } - if (!/(^[0-9]\d*$)/.test(value)) { - callback(new Error('值只能为正整数')); + if (!/^([0-9]|[1-9]\d+)(\.\d{1,2})?$/.test(value)) { + callback(new Error('请输入有效数字,最多保留两位小数')); return false } if (value < 0 || value > 100) {