Merge branch 'develop' into 'feature/yasi_delet_signup_check_login'

This commit is contained in:
AmirHossein Mahmoodi
2023-12-19 06:37:30 +00:00
6 changed files with 8 additions and 11 deletions

View File

@@ -39,14 +39,6 @@ const GlobalHead = () => {
/>
<link
rel="icon"
type="image/svg"
sizes="32x32"
href="/icons/favicon.png"
/>
<link
rel="icon"
type="image/svg"
sizes="16x16"
href="/icons/favicon.png"
/>
</Head>

View File

@@ -20,7 +20,7 @@ const sidebarMenu = [
route: "/dashboard/navgan/add-request-loan",
icon: <DataSaverOnIcon sx={{width: 'inherit', height: 'inherit'}}/>,
selected: false,
permission: "can_request_a_new_loan"
permission: "can_request_navgan_loan"
},
{
key: "sidebar.followUp-loan",

View File

@@ -3,16 +3,20 @@ import headerProfileItems from "@/core/data/headerProfileItems";
import sidebarMenu from "@/core/data/sidebarMenu";
import {GET_SIDEBAR_NOTIFICATION} from "@/core/data/apiRoutes";
import UserInfo from "@/middlewares/UserInfo";
import {useTranslations} from "next-intl";
import moment from "jalali-moment";
const DashboardLayout = (props) => {
const {user} = useUser()
const middlewaresProps = props.middlewaresProps || {}
const t = useTranslations()
return (
<>
<DashboardLayoutPure
middlewares={{list: [UserInfo], props: {...middlewaresProps,loginUrl:'/login'}}}
user_introduction={user.phone_number}
headerProfileItems={headerProfileItems}
headerSubtitle={`${t('today')} ${moment().locale('fa').format('LL')}`}
sidebarMenu={sidebarMenu}
urlNotification={GET_SIDEBAR_NOTIFICATION}
BC_segmentsToRemove={['navgan']}

View File

@@ -15,7 +15,7 @@ export async function getServerSideProps({req, locale}) {
title: "LoanRequest.loan_request_page",
isBot,
locale,
layout: {name: 'DashboardLayout'}
layout: {name: 'DashboardLayout', permissions: ["can_request_navgan_loan"]}
},
};
}