1404/12/24-add alert text close deals

This commit is contained in:
2026-03-15 15:02:46 +03:30
parent 73ec52941d
commit 36db45df33
3 changed files with 12 additions and 0 deletions
+7
View File
@@ -25,6 +25,12 @@ export const useUserStore = defineStore('user', () => {
console.log(e)
}
}
function getValueByKey(keyName) {
const item = userInfo.value.settings.find(obj => obj.key === keyName);
// اگر آیتم پیدا شد، فیلد value را برگردان، در غیر این صورت null
return item ? item.value : null;
}
function removeInformation() {
userInfo.value = undefined
@@ -55,6 +61,7 @@ export const useUserStore = defineStore('user', () => {
removeInformation,
isSingle,
isFirst,
getValueByKey,
productWallet/* permissions, canAccess, isAdmin*/
}
})