import { reactive, ref, UnwrapRef } from "vue";
/**
 * 表单
 * @returns 
 */
export function handleForm() {
    interface FormState {
        payType: number 
        Amount: number | null
        Remark:String
    }
    const formRef = ref();
    const formState: UnwrapRef<FormState> = reactive({
        payType: 1,
        Amount: null,
        Remark:''
    })
    const rules = {
        Amount: [{ required: true, message: '请输入登记价格', trigger: 'blur', type: 'number' }],
    }
    return { rules, formState, formRef }
}