File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
apps/web/src/services/dashboard-shared/core/helpers Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,8 @@ import type { MenuItem } from '@cloudforet/mirinae/types/controls/context-menu/t
22
33import type { DashboardModel } from '@/api-clients/dashboard/_types/dashboard-type' ;
44import type { FolderModel } from '@/api-clients/dashboard/_types/folder-type' ;
5+ import type { PublicDashboardModel } from '@/api-clients/dashboard/public-dashboard/schema/model' ;
6+ import type { PublicFolderModel } from '@/api-clients/dashboard/public-folder/schema/model' ;
57import { i18n } from '@/translations' ;
68
79const _getShareMenuItems = ( isShared : boolean ) : MenuItem [ ] => [
@@ -21,7 +23,7 @@ export const getControlDashboardMenuItems = (
2123) : MenuItem [ ] => {
2224 const _isPrivate = dashboardId . startsWith ( 'private' ) ;
2325 const _isDeprecated = dashboard . version === '1.0' ;
24- const _isShared = ! ! dashboard ?. shared ;
26+ const _isShared = ! ! ( dashboard as PublicDashboardModel ) ?. shared ;
2527 if ( ! manageable ) {
2628 if ( _isDeprecated ) return [ ] ;
2729 return [
@@ -69,7 +71,7 @@ export const getControlDashboardMenuItems = (
6971
7072export const getControlFolderMenuItems = ( folderId : string , manageable : boolean , folder : FolderModel ) : MenuItem [ ] => {
7173 const _isPrivate = folderId . startsWith ( 'private' ) ;
72- const _isShared = ! ! folder ?. shared ;
74+ const _isShared = ! ! ( folder as PublicFolderModel ) ?. shared ;
7375 if ( ! manageable ) {
7476 return [
7577 {
You can’t perform that action at this time.
0 commit comments