This commit is contained in:
Theluyuan 2022-12-12 09:29:59 +08:00
parent 8e4f8dd45f
commit 5a0d86e2e9
4 changed files with 4 additions and 4 deletions

View File

@ -141,7 +141,7 @@ const _sfc_main = defineComponent({
} }
if (props.qfw) { if (props.qfw) {
try { try {
let reg = /\d{1,3}(?=(\d{3})+$)/g; let reg = /\B(?=(\d{3})+$)/g;
console.log("\u6DFB\u52A0\uFF0C", new String(props.modelValue).replace(reg, "$&,")); console.log("\u6DFB\u52A0\uFF0C", new String(props.modelValue).replace(reg, "$&,"));
currentValue.value = new String(props.modelValue).replace(reg, "$&,"); currentValue.value = new String(props.modelValue).replace(reg, "$&,");
} catch { } catch {

View File

@ -11237,7 +11237,7 @@ const _sfc_main$1v = defineComponent({
} }
if (props.qfw) { if (props.qfw) {
try { try {
let reg = /\d{1,3}(?=(\d{3})+$)/g; let reg = /\B(?=(\d{3})+$)/g;
console.log("\u6DFB\u52A0\uFF0C", new String(props.modelValue).replace(reg, "$&,")); console.log("\u6DFB\u52A0\uFF0C", new String(props.modelValue).replace(reg, "$&,"));
currentValue.value = new String(props.modelValue).replace(reg, "$&,"); currentValue.value = new String(props.modelValue).replace(reg, "$&,");
} catch { } catch {

View File

@ -115,7 +115,7 @@ const onBlur = (event: Event) => {
} }
if(props.qfw){ if(props.qfw){
try{ try{
let reg = /\d{1,3}(?=(\d{3})+$)/g; let reg = /\B(?=(\d{3})+$)/g;
// new String(props.modelValue).replace(reg, '$&,'); // new String(props.modelValue).replace(reg, '$&,');
console.log("添加,", new String(props.modelValue).replace(reg, '$&,')) console.log("添加,", new String(props.modelValue).replace(reg, '$&,'))
currentValue.value = new String(props.modelValue).replace(reg, '$&,'); currentValue.value = new String(props.modelValue).replace(reg, '$&,');

File diff suppressed because one or more lines are too long