Genel düzeltmeler
This commit is contained in:
parent
deaf714fe8
commit
dacb97d406
12 changed files with 41 additions and 32 deletions
|
|
@ -3139,7 +3139,7 @@ public class ListFormsSeeder : IDataSeedContributor, ITransientDependency
|
|||
Text ="Manage",
|
||||
UrlTarget="_blank",
|
||||
AuthName=AppCodes.Listforms.Listform + ".Update",
|
||||
Url="/saas/listform/edit/@ListFormCode"
|
||||
Url="/admin/listform/edit/@ListFormCode"
|
||||
},
|
||||
new() {
|
||||
Hint = "Göster",
|
||||
|
|
@ -4632,7 +4632,7 @@ public class ListFormsSeeder : IDataSeedContributor, ITransientDependency
|
|||
Text ="Manage",
|
||||
UrlTarget="_blank",
|
||||
AuthName=AppCodes.Listforms.Chart + ".Update",
|
||||
Url="/saas/chart/edit/@ChartCode"
|
||||
Url="/admin/chart/edit/@ChartCode"
|
||||
},
|
||||
new() {
|
||||
Hint = "Göster",
|
||||
|
|
|
|||
|
|
@ -6769,7 +6769,7 @@
|
|||
"Code": "App.Menus.Manager",
|
||||
"DisplayName": "App.Menus.Manager",
|
||||
"Order": 2,
|
||||
"Url": "/saas/menuManager",
|
||||
"Url": "/admin/menuManager",
|
||||
"Icon": "FaRegListAlt",
|
||||
"RequiredPermissionName": "App.Menus.Manager",
|
||||
"IsDisabled": false
|
||||
|
|
@ -6799,7 +6799,7 @@
|
|||
"Code": "App.Listforms.Wizard",
|
||||
"DisplayName": "App.Listforms.Wizard",
|
||||
"Order": 2,
|
||||
"Url": "/saas/listform/wizard",
|
||||
"Url": "/admin/listform/wizard",
|
||||
"Icon": "FcFlashAuto",
|
||||
"RequiredPermissionName": "App.Listforms.Wizard",
|
||||
"IsDisabled": false
|
||||
|
|
@ -6919,7 +6919,7 @@
|
|||
"Code": "App.ForumManagement",
|
||||
"DisplayName": "App.ForumManagement",
|
||||
"Order": 12,
|
||||
"Url": "/saas/forumManagement",
|
||||
"Url": "/admin/forumManagement",
|
||||
"Icon": "FcReading",
|
||||
"RequiredPermissionName": "App.ForumManagement",
|
||||
"IsDisabled": false
|
||||
|
|
@ -21552,36 +21552,36 @@
|
|||
"authority": []
|
||||
},
|
||||
{
|
||||
"key": "saas.menuManager",
|
||||
"path": "/saas/menuManager",
|
||||
"key": "admin.menuManager",
|
||||
"path": "/admin/menuManager",
|
||||
"componentPath": "@/views/menu/MenuManager",
|
||||
"routeType": "protected",
|
||||
"authority": []
|
||||
},
|
||||
{
|
||||
"key": "saas.listFormManagement.wizard",
|
||||
"path": "/saas/listform/wizard",
|
||||
"key": "admin.listFormManagement.wizard",
|
||||
"path": "/admin/listform/wizard",
|
||||
"componentPath": "@/views/admin/listForm/Wizard",
|
||||
"routeType": "protected",
|
||||
"authority": []
|
||||
},
|
||||
{
|
||||
"key": "saas.listFormManagement.edit",
|
||||
"path": "/saas/listform/edit/:listFormCode",
|
||||
"key": "admin.listFormManagement.edit",
|
||||
"path": "/admin/listform/edit/:listFormCode",
|
||||
"componentPath": "@/views/admin/listForm/edit/FormEdit",
|
||||
"routeType": "protected",
|
||||
"authority": []
|
||||
},
|
||||
{
|
||||
"key": "saas.chartManagement.edit",
|
||||
"path": "/saas/chart/edit/:chartCode",
|
||||
"key": "admin.chartManagement.edit",
|
||||
"path": "/admin/chart/edit/:chartCode",
|
||||
"componentPath": "@/views/admin/chart/ChartEdit",
|
||||
"routeType": "protected",
|
||||
"authority": []
|
||||
},
|
||||
{
|
||||
"key": "saas.forumManagement",
|
||||
"path": "/saas/forumManagement",
|
||||
"key": "admin.forumManagement",
|
||||
"path": "/admin/forumManagement",
|
||||
"componentPath": "@/views/forum/Management",
|
||||
"routeType": "protected",
|
||||
"authority": []
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ import { Frown } from 'lucide-react'; // Lucide-react kütüphanesinden Frown ik
|
|||
import { useLanguage } from '../context/LanguageContext';
|
||||
|
||||
const NotFound: React.FC = () => {
|
||||
const { t, language } = useLanguage();
|
||||
const { t } = useLanguage();
|
||||
|
||||
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import { APP_NAME } from '@/constants/app.constant'
|
|||
import type { CommonProps } from '@/@types/common'
|
||||
import { Mode } from '@/@types/theme'
|
||||
import { Link } from 'react-router-dom'
|
||||
import { ROUTES_ENUM } from '@/routes/route.constant'
|
||||
|
||||
interface LogoProps extends CommonProps {
|
||||
type?: 'full' | 'streamline'
|
||||
|
|
@ -24,7 +25,7 @@ const Logo = (props: LogoProps) => {
|
|||
...{ width: logoWidth },
|
||||
}}
|
||||
>
|
||||
<Link to="/">
|
||||
<Link to={ROUTES_ENUM.protected.home}>
|
||||
<img
|
||||
className={imgClass}
|
||||
src={`${LOGO_SRC_PATH}logo-${mode}-${type}.png`}
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ export type AppConfig = {
|
|||
const appConfig: AppConfig = {
|
||||
baseUrl: import.meta.env.VITE_API_URL,
|
||||
apiPrefix: '/api',
|
||||
authenticatedEntryPath: ROUTES_ENUM.protected.admin.home,
|
||||
authenticatedEntryPath: ROUTES_ENUM.protected.home,
|
||||
unAuthenticatedEntryPath: ROUTES_ENUM.public.login,
|
||||
tourPath: '/',
|
||||
locale: 'en',
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ export const DynamicRouter: React.FC = () => {
|
|||
)
|
||||
})}
|
||||
|
||||
<Route path="/" element={<Navigate to={ROUTES_ENUM.protected.admin.home} replace />} />
|
||||
<Route path={ROUTES_ENUM.protected.home} element={<Navigate to={ROUTES_ENUM.protected.home} replace />} />
|
||||
</Route>
|
||||
|
||||
{/* Public Routes */}
|
||||
|
|
|
|||
|
|
@ -9,21 +9,20 @@ export const ROUTES_ENUM = {
|
|||
verifyConfirmationCode: '/confirm/:userId/:token',
|
||||
},
|
||||
protected: {
|
||||
root: '/home',
|
||||
home: '/admin/home',
|
||||
saas: {
|
||||
menuManager: '/saas/menuManager',
|
||||
menuManager: '/admin/menuManager',
|
||||
listFormManagement: {
|
||||
wizard: '/saas/listform/wizard',
|
||||
edit: '/saas/listform/edit/:listFormCode',
|
||||
wizard: '/admin/listform/wizard',
|
||||
edit: '/admin/listform/edit/:listFormCode',
|
||||
},
|
||||
chartManagement: {
|
||||
edit: '/saas/chart/edit/:chartCode',
|
||||
edit: '/admin/chart/edit/:chartCode',
|
||||
},
|
||||
forumManagement: '/saas/forumManagement',
|
||||
forumManagement: '/admin/forumManagement',
|
||||
},
|
||||
|
||||
admin: {
|
||||
home: '/home',
|
||||
ai: '/admin/ai',
|
||||
profile: {
|
||||
general: '/admin/profile/general',
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import Container from '@/components/shared/Container'
|
||||
import DoubleSidedImage from '@/components/shared/DoubleSidedImage'
|
||||
import { Button } from '@/components/ui'
|
||||
import { ROUTES_ENUM } from '@/routes/route.constant'
|
||||
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||
import { MdArrowBack } from 'react-icons/md'
|
||||
import { useNavigate } from 'react-router-dom'
|
||||
|
|
@ -21,7 +22,7 @@ const AccessDenied = () => {
|
|||
<h3 className="mb-2">{ translate('::AccessDenied')}</h3>
|
||||
<p className="text-base">{ translate('::AccessDeniedMessage')}</p>
|
||||
</div>
|
||||
<Button size="xs" className="mt-2" variant="default" onClick={() => navigate(-2)}>
|
||||
<Button size="xs" className="mt-2" variant="default" onClick={() => navigate(ROUTES_ENUM.protected.home)}>
|
||||
<MdArrowBack />
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { store, useStoreState } from '@/store'
|
|||
import { Suspense, useEffect } from 'react'
|
||||
import { ErrorBoundary } from 'react-error-boundary'
|
||||
import { MdArrowBack } from 'react-icons/md'
|
||||
import { useLocation } from 'react-router-dom'
|
||||
import { Navigate, useLocation } from 'react-router-dom'
|
||||
import DialogProvider from './shared/DialogContext'
|
||||
import DialogShowComponent from './shared/DialogContext/DialogShowComponent'
|
||||
import UiDialog from './shared/UiDialog'
|
||||
|
|
@ -47,6 +47,9 @@ const Views = (props: ViewsProps) => {
|
|||
))}
|
||||
</Alert>
|
||||
)}
|
||||
{errors?.some((e) => e.statusCode === '403' || e.statusCode === '401') && (
|
||||
<Navigate to="/access-denied" replace />
|
||||
)}
|
||||
{errors?.map((e) => (
|
||||
<UiDialog
|
||||
key={e.id}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
import AdaptableCard from '@/components/shared/AdaptableCard'
|
||||
import Container from '@/components/shared/Container'
|
||||
import Tabs from '@/components/ui/Tabs'
|
||||
import { ROUTES_ENUM } from '@/routes/route.constant'
|
||||
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||
import { Suspense, lazy, useState } from 'react'
|
||||
import { useLocation, useNavigate } from 'react-router-dom'
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import {
|
|||
UpdatePermissionDto,
|
||||
} from '@/proxy/admin'
|
||||
import { getPermissions, updatePermissions } from '@/proxy/admin/identity.service'
|
||||
import { useStoreState } from '@/store'
|
||||
import { useStoreActions, useStoreState } from '@/store'
|
||||
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||
import { ChangeEvent, useEffect, useMemo, useState } from 'react'
|
||||
|
||||
|
|
@ -27,7 +27,8 @@ function RolesPermission({
|
|||
}) {
|
||||
const providerName = 'R'
|
||||
const { translate } = useLocalization()
|
||||
|
||||
const { getConfig } = useStoreActions((a) => a.abpConfig)
|
||||
|
||||
const [isLoading, setIsLoading] = useState(false)
|
||||
const [permissionList, setPermissionList] = useState<GetPermissionListResultDto>()
|
||||
const [selectedGroup, setSelectedGroup] = useState<PermissionGroupDto | undefined>()
|
||||
|
|
@ -97,6 +98,11 @@ function RolesPermission({
|
|||
onDialogClose()
|
||||
setIsLoading(false)
|
||||
}, 1000)
|
||||
|
||||
|
||||
setTimeout(async () => {
|
||||
getConfig(true)
|
||||
}, 2000)
|
||||
}
|
||||
|
||||
function getPermissionsWithGroupName(groups: PermissionGroupDto[]): PermissionWithGroupName[] {
|
||||
|
|
|
|||
|
|
@ -168,7 +168,7 @@ const useFilters = ({
|
|||
} else if (itemData.id === 'openPivotGrid') {
|
||||
navigate(`/pivot/${listFormCode}`)
|
||||
} else if (itemData.id === 'openManage') {
|
||||
window.open(`/saas/listform/edit/${listFormCode}`, isPwaMode ? '_self' : '_blank')
|
||||
window.open(`/admin/listform/edit/${listFormCode}`, isPwaMode ? '_self' : '_blank')
|
||||
} else if (itemData.id === 'clearFilter') {
|
||||
// gridin bütün filtrelerini temizle
|
||||
const grid = gridRef.current?.instance
|
||||
|
|
|
|||
Loading…
Reference in a new issue