setting notification
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
import Tabs from '@/components/Tabs'
|
||||
import { Money2, Setting4 } from 'iconsax-react'
|
||||
import { Money2, NotificationStatus, Setting4 } from 'iconsax-react'
|
||||
import { useState, type FC } from 'react'
|
||||
import { SettingTabEnum } from './enum/Enum'
|
||||
import GeneralSettings from './GeneralSettings'
|
||||
import ScoreSetting from './components/ScoreSetting'
|
||||
import NotificationsList from '../notifications/List'
|
||||
|
||||
const Setting: FC = () => {
|
||||
|
||||
@@ -26,6 +27,11 @@ const Setting: FC = () => {
|
||||
label: 'تنظیمات امتیاز',
|
||||
value: SettingTabEnum.FINANCIAL,
|
||||
},
|
||||
{
|
||||
icon: <NotificationStatus color={activeTab === SettingTabEnum.NOTIFICATION ? 'black' : '#8C90A3'} size={24} />,
|
||||
label: 'تنظیمات اعلان',
|
||||
value: SettingTabEnum.NOTIFICATION,
|
||||
},
|
||||
]}
|
||||
onChange={(value: string) => setActiveTab(value as SettingTabEnum)}
|
||||
active={activeTab}
|
||||
@@ -39,6 +45,9 @@ const Setting: FC = () => {
|
||||
{
|
||||
activeTab === SettingTabEnum.FINANCIAL && <ScoreSetting />
|
||||
}
|
||||
{
|
||||
activeTab === SettingTabEnum.NOTIFICATION && <NotificationsList />
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
|
||||
@@ -3,4 +3,5 @@ export const enum SettingTabEnum {
|
||||
PASSWORD = "password",
|
||||
FINANCIAL = "financial",
|
||||
DELIVERY = "delivery",
|
||||
NOTIFICATION = "notification",
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@ import { type FC, useEffect } from 'react'
|
||||
import LogoImage from '../assets/images/logo.png'
|
||||
import LogoSmall from '../assets/images/logo-small.png'
|
||||
import { useTranslation } from 'react-i18next'
|
||||
import { DocumentText, Home2, Logout, NotificationStatus, People, Setting2, TicketDiscount, Calendar, Security, Card, SecurityUser, TruckFast, Element3, Star1, NotificationBing, SmsEdit } from 'iconsax-react'
|
||||
import { DocumentText, Home2, Logout, People, Setting2, TicketDiscount, Calendar, Security, Card, SecurityUser, TruckFast, Element3, Star1, NotificationBing, SmsEdit } from 'iconsax-react'
|
||||
import SideBarItem from './SideBarItem'
|
||||
import { useLocation } from 'react-router-dom'
|
||||
import { Pages } from '../config/Pages'
|
||||
@@ -222,7 +222,7 @@ const SideBar: FC = () => {
|
||||
/>
|
||||
)}
|
||||
|
||||
{
|
||||
{/* {
|
||||
checkPermission(PermissionEnum.MANAGE_SETTINGS) && (
|
||||
<SideBarItem
|
||||
icon={<NotificationStatus variant={isActive('notifications') ? 'Bold' : 'Outline'} color={isActive('notifications') ? 'black' : '#8C90A3'} size={iconSizeSideBar} />}
|
||||
@@ -233,7 +233,7 @@ const SideBar: FC = () => {
|
||||
activeName='notifications'
|
||||
/>
|
||||
)
|
||||
}
|
||||
} */}
|
||||
</div>
|
||||
)}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user