diff --git a/.env.development b/.env.development index 0eeb323..58a088c 100644 --- a/.env.development +++ b/.env.development @@ -2,6 +2,6 @@ VITE_APP_NAME=tpay-dashboard-tl VITE_APP_VERSION=1=9.1.1 GENERATE_SOURCEMAP=false -VITE_APP_API_URL=https://tpay.shiblysolution.id/api/d +VITE_APP_API_URL=https://tpay.shiblysolution.id/api # VITE_APP_API_URL=http://127.0.0.1:4003/api VITE_ENV=development diff --git a/src/pages/master/municipios/blocks/AddDialog.tsx b/src/pages/master/municipios/blocks/AddDialog.tsx index 9a9a342..0db792b 100644 --- a/src/pages/master/municipios/blocks/AddDialog.tsx +++ b/src/pages/master/municipios/blocks/AddDialog.tsx @@ -49,8 +49,8 @@ const AddDialog = () => { if (response?.status) { handleAddDialog(false); resetForm(); - toast.success('Municipio created successfully!'); reload(); + toast.success('Municipio created successfully!'); // const createActivity = { // module: 'Manage Municipio', // description: `Create Municipio => ${selectedMunicipios}`, @@ -80,14 +80,15 @@ const AddDialog = () => { // created_at: formattedTime // }); - // doCreateMunicipio(e); + doCreateMunicipio(e); console.log(parsedUser.email); console.log(formField); setAlert({ show: false, message: '' }); }; const handleReset = () => { - setFormField(initialState); + resetForm(); + setAlert({ show: false, message: '' }); }; useEffect(() => { @@ -96,7 +97,7 @@ const AddDialog = () => { if (showAddDialog) { setFormField({ name: formField.name, - created_by: parsedUser.email, + created_by: parsedUser?.username, created_at: formattedTime }); }