add create activity on 4 modules: Provider, Conversion, Menu, Currency
This commit is contained in:
@ -33,6 +33,7 @@ import {
|
||||
SelectValue
|
||||
} from '@/components/ui/select';
|
||||
import { useManageCurrencyContext } from '../hooks/useManageCurrencyContext';
|
||||
import { doSaveLogActivity } from '@/actions/GlobalActions';
|
||||
interface CurrencyProps {
|
||||
ID: string;
|
||||
name: string;
|
||||
@ -81,6 +82,13 @@ const EditDialog = () => {
|
||||
resetForm();
|
||||
handleEditDialog(false, null);
|
||||
toast.success('Success Update Currency');
|
||||
const createActivity = {
|
||||
module: 'Manage Currency',
|
||||
description: `Update Currency=> ${selectedCurrency}`,
|
||||
action: 'U'
|
||||
};
|
||||
|
||||
doSaveLogActivity(createActivity);
|
||||
reload();
|
||||
} else {
|
||||
toast.error('Error Create Currency');
|
||||
@ -97,9 +105,9 @@ const EditDialog = () => {
|
||||
setFormField((prev) => ({
|
||||
...prev,
|
||||
status: response.data.status,
|
||||
code:response.data.code,
|
||||
name:response.data.name,
|
||||
prefix:response.data.prefix,
|
||||
code: response.data.code,
|
||||
name: response.data.name,
|
||||
prefix: response.data.prefix
|
||||
}));
|
||||
}
|
||||
// console.log('form fieldd Transaction Type: ', formField);
|
||||
|
||||
Reference in New Issue
Block a user