update design and request pages dashboards & doctors & doctor item & clinics & clinic item and layout
This commit is contained in:
@@ -185,3 +185,12 @@ export function getCleanNumberValue(value, defaultValue = 0) {
|
||||
}
|
||||
|
||||
export const changeNumToDefault = (num) => `09${num.replace(/\D/g, "")}`;
|
||||
|
||||
export function hasDataChanged(previousData, newData) {
|
||||
const oldDataString = JSON.stringify(
|
||||
previousData,
|
||||
Object.keys(previousData).sort()
|
||||
);
|
||||
const newDataString = JSON.stringify(newData, Object.keys(newData).sort());
|
||||
return oldDataString !== newDataString;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user