Add validations
This commit is contained in:
+5
@@ -169,6 +169,7 @@ export function RegionManageEntrySheet({ open, onClose, onSuccess, initial }: Re
|
|||||||
control={form.control}
|
control={form.control}
|
||||||
name="period"
|
name="period"
|
||||||
label="Period"
|
label="Period"
|
||||||
|
required
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Input
|
<Input
|
||||||
type="month"
|
type="month"
|
||||||
@@ -185,6 +186,7 @@ export function RegionManageEntrySheet({ open, onClose, onSuccess, initial }: Re
|
|||||||
control={form.control}
|
control={form.control}
|
||||||
name="targetValue"
|
name="targetValue"
|
||||||
label="Regional Target"
|
label="Regional Target"
|
||||||
|
required
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Input
|
<Input
|
||||||
type="number"
|
type="number"
|
||||||
@@ -199,6 +201,7 @@ export function RegionManageEntrySheet({ open, onClose, onSuccess, initial }: Re
|
|||||||
control={form.control}
|
control={form.control}
|
||||||
name="budgetAmount"
|
name="budgetAmount"
|
||||||
label="Regional Budget"
|
label="Regional Budget"
|
||||||
|
required
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Input
|
<Input
|
||||||
type="number"
|
type="number"
|
||||||
@@ -215,6 +218,7 @@ export function RegionManageEntrySheet({ open, onClose, onSuccess, initial }: Re
|
|||||||
control={form.control}
|
control={form.control}
|
||||||
name="ruleConfig"
|
name="ruleConfig"
|
||||||
label="Regional Rule Config"
|
label="Regional Rule Config"
|
||||||
|
required
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Input
|
<Input
|
||||||
value={field.value as string}
|
value={field.value as string}
|
||||||
@@ -230,6 +234,7 @@ export function RegionManageEntrySheet({ open, onClose, onSuccess, initial }: Re
|
|||||||
control={form.control}
|
control={form.control}
|
||||||
name="agencyUserId"
|
name="agencyUserId"
|
||||||
label="Map Regional Agency"
|
label="Map Regional Agency"
|
||||||
|
required
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Select value={field.value as string} onValueChange={field.onChange}>
|
<Select value={field.value as string} onValueChange={field.onChange}>
|
||||||
<SelectTrigger>
|
<SelectTrigger>
|
||||||
|
|||||||
Reference in New Issue
Block a user