@@ -46,17 +46,16 @@ export const DashboardPageTypes = {
4646
4747export const useDashboardPageStore = defineComponentStore (
4848 'dashboard' ,
49- ( pageInitConfig ) => {
49+ ( props ) => {
5050 const appStore = useAppStore ( ) ;
51- const extender = useExtender ( { context : { props : pageInitConfig } } ) ;
51+ const extender = useExtender ( ) ;
5252
53- const dashboardPage = pageInitConfig . dashboardPage ;
53+ const dashboardPage = props . dashboardPage ;
5454
5555 /**
5656 * Minimal reviews count feature
5757 */
58- const contextMinReviewsPerSubmission =
59- pageInitConfig . contextMinReviewsPerSubmission ;
58+ const contextMinReviewsPerSubmission = props . contextMinReviewsPerSubmission ;
6059
6160 /**
6261 * ModalStore
@@ -96,7 +95,7 @@ export const useDashboardPageStore = defineComponentStore(
9695 /**
9796 * Views
9897 */
99- const views = ref ( pageInitConfig . views ) ;
98+ const views = ref ( props . views ) ;
10099 const currentViewId = computed ( ( ) => {
101100 // does it exist
102101 const view = views . value . find (
@@ -164,7 +163,7 @@ export const useDashboardPageStore = defineComponentStore(
164163 /**
165164 * Filters form
166165 */
167- const filtersForm = ref ( pageInitConfig . filtersForm ) ;
166+ const filtersForm = ref ( props . filtersForm ) ;
168167
169168 const {
170169 filtersFormList,
@@ -227,7 +226,7 @@ export const useDashboardPageStore = defineComponentStore(
227226 function setCurrentPage ( _currentPage ) {
228227 currentPage . value = _currentPage ;
229228 }
230- const countPerPage = ref ( pageInitConfig . countPerPage ) ;
229+ const countPerPage = ref ( props . countPerPage ) ;
231230 const { apiUrl} = useUrl ( '_submissions' ) ;
232231
233232 const submissionsUrl = computed ( ( ) => {
@@ -283,9 +282,8 @@ export const useDashboardPageStore = defineComponentStore(
283282 // already trigger by SideNav to get initial values for all dashboards
284283 fetchSubmissions ( false ) ;
285284
286- const reviewerManagerActions = useReviewerManagerActions ( pageInitConfig ) ;
287- const participantManagerActions =
288- useParticipantManagerActions ( pageInitConfig ) ;
285+ const reviewerManagerActions = useReviewerManagerActions ( props ) ;
286+ const participantManagerActions = useParticipantManagerActions ( props ) ;
289287 const fileManagerActions = useFileManagerActions ( ) ;
290288 const { getCurrentPublication} = useSubmission ( ) ;
291289
@@ -430,7 +428,7 @@ export const useDashboardPageStore = defineComponentStore(
430428 'WorkflowPage' ,
431429 {
432430 submissionId,
433- pageInitConfig,
431+ pageInitConfig : props ,
434432 } ,
435433 {
436434 onClose : async ( ) => {
@@ -612,10 +610,11 @@ export const useDashboardPageStore = defineComponentStore(
612610 contextMinReviewsPerSubmission,
613611
614612 // Expose component forms, so managers and other dashboard/workflow component can access them
615- componentForms : pageInitConfig . componentForms ,
613+ componentForms : props . componentForms ,
616614
617615 // Extender
618616 extender,
617+ props,
619618 } ;
620619 } ,
621620) ;
0 commit comments