mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 04:40:32 +00:00
feat: add auto increment in vendor credit number.
This commit is contained in:
@@ -123,6 +123,27 @@ export function useSettingCashFlow(props) {
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve credit notes settings.
|
||||
*/
|
||||
export function useSettingsCreditNotes(props) {
|
||||
return useSettingsQuery(
|
||||
[t.SETTING, t.SETTING_CREDIT_NOTES],
|
||||
{ group: 'credit_note' },
|
||||
props,
|
||||
);
|
||||
}
|
||||
/**
|
||||
* Retrieve vendor credit settings.
|
||||
*/
|
||||
export function useSettingsVendorCredits(props) {
|
||||
return useSettingsQuery(
|
||||
[t.SETTING, t.SETTING_VENDOR_CREDITS],
|
||||
{ group: 'vendor_credit' },
|
||||
props,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve SMS Notifications settings.
|
||||
*/
|
||||
|
||||
@@ -130,6 +130,8 @@ const SETTING = {
|
||||
SETTING_SMS_NOTIFICATION: 'SETTING_SMS_NOTIFICATION',
|
||||
SETTING_SMS_NOTIFICATIONS: 'SETTING_SMS_NOTIFICATIONS',
|
||||
SETTING_EDIT_SMS_NOTIFICATION: 'SETTING_EDIT_SMS_NOTIFICATION',
|
||||
SETTING_CREDIT_NOTES: 'SETTING_CREDIT_NOTES',
|
||||
SETTING_VENDOR_CREDITS: 'SETTING_VENDOR_CREDITS',
|
||||
};
|
||||
|
||||
const ORGANIZATIONS = {
|
||||
|
||||
@@ -21,6 +21,9 @@ const commonInvalidateQueries = (queryClient) => {
|
||||
queryClient.invalidateQueries(t.ACCOUNTS);
|
||||
queryClient.invalidateQueries(t.ACCOUNT);
|
||||
|
||||
// Invalidate settings.
|
||||
queryClient.invalidateQueries([t.SETTING, t.SETTING_VENDOR_CREDITS]);
|
||||
|
||||
// Invalidate financial reports.
|
||||
queryClient.invalidateQueries(t.FINANCIAL_REPORT);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user