update: 更新所有input clear事件

This commit is contained in:
admin 2024-04-26 15:39:40 +08:00
parent 06fb6cf294
commit 8eaf921cf4
19 changed files with 19 additions and 57 deletions

View File

@ -69,9 +69,7 @@ import { DeviceType, ImagesType, OrderType, StockCardType } from "@/utils/enum";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -109,9 +109,7 @@ import _ from "underscore";
import SupplierDialog from "./SupplierDialog.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <

View File

@ -117,9 +117,7 @@ import _ from "underscore";
import SupplierDialog from "./SupplierDialog.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <

View File

@ -71,9 +71,7 @@ import valid from "@/utils/validate";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
//
const handleInput = (e: any, item: any) => {

View File

@ -67,9 +67,7 @@ import { DeviceType, ImagesType, OrderType, StockCardType } from "@/utils/enum";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -94,9 +94,7 @@ import { DeviceType, ImagesType, OrderType, StockCardType } from "@/utils/enum";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -86,9 +86,7 @@ import { DeviceType, ImagesType, OrderType } from "@/utils/enum";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const { proxy }: any = getCurrentInstance();
const model1 = reactive<any>({

View File

@ -67,9 +67,7 @@ import { GoodsApi } from "@/services";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -69,9 +69,7 @@ import { DeviceType, ImagesType, OrderType, StockCardType } from "@/utils/enum";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -71,9 +71,7 @@ import valid from "@/utils/validate";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const handleInput = (e: any, item: any) => {
if (item.key === "phone" || item.key === 'bankNumber') {

View File

@ -65,9 +65,7 @@ import { SupplierApi } from "@/services";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const model1 = reactive<any>({
formData: {},

View File

@ -73,9 +73,7 @@ import valid from "@/utils/validate";
import { onLoad } from "@dcloudio/uni-app";
import _ from "underscore";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.formData as any)[item.key] = '';
}, 100);
(model1.formData as any)[item.key] = '';
}
const handleInput = (e: any, item: any) => {
if (item.key === "phone") {

View File

@ -132,9 +132,7 @@ import ProductDialog from "./components/ProductDialog.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <

View File

@ -130,9 +130,7 @@ import SupplierDialog from "./components/SupplierDialog.vue";
import ProductDialog from "./components/ProductDialog.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <

View File

@ -97,9 +97,7 @@ import { ProfileApi } from "@/services/index";
import LoginLayout from "./components/loginLayout.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.userInfo as any)[item.modelName] = '';
}, 100);
(model1.userInfo as any)[item.modelName] = '';
}
const loginForm = ref(null);
const model1 = <any>reactive({

View File

@ -70,9 +70,7 @@ const handleInput = (e: any, key: string) => {
};
const handleClear = (item:any) => {
setTimeout(() => {
(model1.userInfo as any)[item.key] = '';
}, 100);
(model1.userInfo as any)[item.key] = '';
}
//

View File

@ -133,9 +133,7 @@ import ProductDialog from "../components/ProductDialog.vue";
import valid from "@/utils/validate";
import { countDots } from "@/utils";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <

View File

@ -109,9 +109,7 @@ import {
import valid from "@/utils/validate";
import { onLoad } from "@dcloudio/uni-app";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
const isShowFormItem = (item: any) => {
if (model1.scaleStatusBtnType === ScaleStatusBtnType.ShipmentPay) {

View File

@ -112,9 +112,7 @@ import _ from "underscore";
import ProductDialog from "../components/ProductDialog.vue";
import valid from "@/utils/validate";
const handleClear = (item:any) => {
setTimeout(() => {
(model1.order as any)[item.key] = '';
}, 100);
(model1.order as any)[item.key] = '';
}
//
const showDialog = <