Compare commits

..

No commits in common. "b6102d0b318699364fe4d6279b739a3c3f88515a" and "682c390220c89d9b009e125e59fa4de9f75686dc" have entirely different histories.

4 changed files with 15 additions and 16 deletions

View File

@ -66,6 +66,7 @@ export const NewDepartmentModal = ({
},
});
const statusValue = watch("is_active");
const parentIdValue = watch("parent_id");
useEffect(() => {
@ -165,14 +166,14 @@ export const NewDepartmentModal = ({
/>
</div>
{/* <FormSelect
<FormSelect
label="Status"
required
options={statusOptions}
value={String(statusValue)}
onValueChange={(value) => setValue("is_active", value === "true")}
error={errors.is_active?.message}
/> */}
/>
</form>
</Modal>
);

View File

@ -48,6 +48,8 @@ export const NewDesignationModal = ({
const {
register,
handleSubmit,
setValue,
watch,
reset,
clearErrors,
formState: { errors },
@ -60,6 +62,8 @@ export const NewDesignationModal = ({
},
});
const statusValue = watch("is_active");
useEffect(() => {
if (!isOpen) {
reset();
@ -137,14 +141,14 @@ export const NewDesignationModal = ({
/>
</div>
{/* <FormSelect
<FormSelect
label="Status"
required
options={statusOptions}
value={String(statusValue)}
onValueChange={(value) => setValue("is_active", value === "true")}
error={errors.is_active?.message}
/> */}
/>
</form>
</Modal>
);

View File

@ -30,13 +30,7 @@ const newModuleSchema = z.object({
.min(1, 'runtime_language is required')
.max(50, 'runtime_language must be at most 50 characters'),
framework: z.string().max(50, 'framework must be at most 50 characters').optional().nullable(),
webhookurl: z
.union([
z.string().url("Invalid URL format").max(500, "webhookurl must be at most 500 characters"),
z.literal("").transform(() => null),
z.null(),
])
.optional(),
webhookurl: z.string().max(500, "webhookurl must be at most 500 characters").url("Invalid URL format").nullable(),
frontend_base_url: z
.string()
.min(1, 'frontend_base_url is required')

View File

@ -437,11 +437,11 @@ const Users = (): ReactElement => {
label="Status"
options={[
{ value: "active", label: "Active" },
// {
// value: "pending_verification",
// label: "Pending Verification",
// },
// { value: "inactive", label: "Inactive" },
{
value: "pending_verification",
label: "Pending Verification",
},
{ value: "inactive", label: "Inactive" },
{ value: "suspended", label: "Suspended" },
{ value: "deleted", label: "Deleted" },
]}