Skip to content

Commit

Permalink
fix(admin-ui): fix edit and view pages issue
Browse files Browse the repository at this point in the history
  • Loading branch information
mjatin-dev committed Mar 6, 2023
1 parent d85ded4 commit 90f396a
Show file tree
Hide file tree
Showing 12 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ function ScriptListTable() {
function handleGoToCustomScriptEditPage(row, edition) {
dispatch(viewOnly(edition))
dispatch(setCurrentItem(row))
return navigate(`/adm/script/edit:` + row.inum)
return navigate(`/adm/script/edit/:` + row.inum)
}
function handleCustomScriptDelete(row) {
setItem(row)
Expand Down
2 changes: 1 addition & 1 deletion admin-ui/plugins/admin/plugin-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ const pluginMetadata = {
},
{
component: CustomScriptEditPage,
path: PLUGIN_BASE_APTH + '/script/edit:id',
path: PLUGIN_BASE_APTH + '/script/edit/:id',
permission: SCRIPT_READ,
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ function ClientListPage() {
function handleGoToClientEditPage(row, edition) {
dispatch(viewOnly(edition))
dispatch(setCurrentItem(row))
return navigate(`/auth-server/client/edit:` + row.inum.substring(0, 4))
return navigate(`/auth-server/client/edit/:` + row.inum.substring(0, 4))
}
function handleGoToClientAddPage() {
return navigate('/auth-server/client/new')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ function ScopeListPage() {
}
function handleGoToScopeEditPage(row) {
dispatch(setCurrentItem(row))
return navigate(`/auth-server/scope/edit:` + row.inum)
return navigate(`/auth-server/scope/edit/:` + row.inum)
}

function handleScopeDelete(row) {
Expand Down
4 changes: 2 additions & 2 deletions admin-ui/plugins/auth-server/plugin-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ const pluginMetadata = {
},
{
component: ClientEditPage,
path: PLUGIN_BASE_APTH + '/client/edit:id',
path: PLUGIN_BASE_APTH + '/client/edit/:id',
permission: CLIENT_WRITE,
},
{
Expand All @@ -123,7 +123,7 @@ const pluginMetadata = {
},
{
component: ScopeEditPage,
path: PLUGIN_BASE_APTH + '/scope/edit:id',
path: PLUGIN_BASE_APTH + '/scope/edit/:id',
permission: SCOPE_WRITE,
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,11 @@ function AttributeListPage() {
}
function handleGoToAttributeEditPage(row) {
dispatch(setCurrentItem(row))
return navigate(`/attribute/edit:` + row.inum)
return navigate(`/attribute/edit/:` + row.inum)
}
function handleGoToAttributeViewPage(row) {
dispatch(setCurrentItem(row))
return navigate(`/attribute/view:` + row.inum)
return navigate(`/attribute/view/:` + row.inum)
}
function handleAttribueDelete(row) {
setItem(row)
Expand Down
4 changes: 2 additions & 2 deletions admin-ui/plugins/schema/plugin-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ const pluginMetadata = {
routes: [
{
component: AttributeEditPage,
path: '/attribute/edit:gid',
path: '/attribute/edit/:gid',
permission: ATTRIBUTE_WRITE,
},
{
component: AttributeViewPage,
path: '/attribute/view:gid',
path: '/attribute/view/:gid',
permission: ATTRIBUTE_READ,
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ function LdapListPage({

function handleGoToLdapEditPage(row) {
dispatch(setCurrentItem(row))
return navigate(`/config/ldap/edit:` + row.configId)
return navigate(`/config/ldap/edit/:` + row.configId)
}

function handleLdapDelete(row) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ function SqlListPage({

function handleGoToSqlEditPage(row) {
dispatch(setCurrentItem(row))
return navigate(`/config/sql/edit:` + row.configId)
return navigate(`/config/sql/edit/:` + row.configId)
}

function handleSqlDelete(row) {
Expand Down
4 changes: 2 additions & 2 deletions admin-ui/plugins/services/plugin-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const pluginMetadata = {
},
{
component: LdapEditPage,
path: '/config/ldap/edit:configId',
path: '/config/ldap/edit/:configId',
permission: CACHE_WRITE,
},
{
Expand All @@ -85,7 +85,7 @@ const pluginMetadata = {
},
{
component: SqlEditPage,
path: '/config/sql/edit:configId',
path: '/config/sql/edit/:configId',
permission: SQL_WRITE,
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ function UserList(props) {
}
function handleGoToUserEditPage(row) {
dispatch(setSelectedUserData(row))
return navigate(`/user/usermanagement/edit:` + row.tableData.uuid)
return navigate(`/user/usermanagement/edit/:` + row.tableData.uuid)
}
const [limit, setLimit] = useState(10)
const [pattern, setPattern] = useState(null)
Expand Down
2 changes: 1 addition & 1 deletion admin-ui/plugins/user-management/plugin-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const pluginMetadata = {
},
{
component: UserEditPage,
path: PLUGIN_BASE_APTH + '/usermanagement/edit:id',
path: PLUGIN_BASE_APTH + '/usermanagement/edit/:id',
permission: USER_WRITE,
},
],
Expand Down

0 comments on commit 90f396a

Please sign in to comment.