Skip to content

Commit 27f2b19

Browse files
authored
[Grid] hide tag search if permission not there (#3465)
* hide tag search if permission not there * Automatic frontend build * tag filter clean up * Automatic frontend build
1 parent e84c4e0 commit 27f2b19

748 files changed

Lines changed: 30054 additions & 1 deletion

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

assets/js/src/core/modules/asset/listing/decorator/tag-filter/view-layer/components/sidebar/hooks/with-tab-tag-filter-entry.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import { Icon } from '@Pimcore/components/icon/icon'
1515
import { TagFiltersContainer } from '../tabs/tag-filters/tag-filters-container'
1616
import { useTagFilter } from '../../../../context-layer/provider/tag-filter/use-tag-filter'
1717
import { isAllowed } from '@Pimcore/modules/auth/permission-helper'
18+
import { UserPermission } from '@Pimcore/modules/auth/enums/user-permission'
1819

1920
export const withTabTagFilterEntry = (useBaseHook: AbstractDecoratorProps['useSidebarOptions']): AbstractDecoratorProps['useSidebarOptions'] => {
2021
const useTabTagFilterEntry: typeof useBaseHook = () => {
@@ -25,7 +26,7 @@ export const withTabTagFilterEntry = (useBaseHook: AbstractDecoratorProps['useSi
2526
const getProps: typeof baseGetProps = () => {
2627
const baseProps = baseGetProps()
2728

28-
if (!isAllowed('tags_search')) {
29+
if (!isAllowed(UserPermission.TagsSearch)) {
2930
return baseProps
3031
}
3132

assets/js/src/core/modules/auth/enums/user-permission.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ export enum UserPermission {
1818
Assets = 'assets',
1919
Thumbnails = 'thumbnails',
2020
TagsConfiguration = 'tags_configuration',
21+
TagsSearch = 'tags_search',
2122
PredefinedProperties = 'predefined_properties',
2223
WebsiteSettings = 'website_settings',
2324
Users = 'users',

public/build/19f6f145-2b25-41c5-a5a2-faaa24586e28/entrypoints.json

Lines changed: 23 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/build/19f6f145-2b25-41c5-a5a2-faaa24586e28/exposeRemote.js

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/build/19f6f145-2b25-41c5-a5a2-faaa24586e28/index.html

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/build/19f6f145-2b25-41c5-a5a2-faaa24586e28/manifest.json

Lines changed: 811 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)