Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/main/java/com/health/HealthNutrition.java
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ public void run(String... args) throws Exception {
try {

taskProcessingService.createOutlineFile();
taskProcessingService.addTokenInTrainingResource();
taskProcessingService.addAllBrochureToQueue();
taskProcessingService.addAllResearchPapertoQueue();
taskProcessingService.addAllTuttorialsToQueue();
Expand Down
70 changes: 36 additions & 34 deletions src/main/java/com/health/config/SecurityConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,35 +46,32 @@ public static BCryptPasswordEncoder passwordEncoder() {
"/tutorial_view/**", "/getConsultantDetails/**", "/reset/**", "/resetPassword/**", "/getCatAndLan/**",
"/getTopicOnCatAndLan/**", "/getRolesOnCatLanUser/**", "/getTutorial/**", "/statistics", "/statistics/**",
"/tutCountOnCat/**", "/tutCountOnLan/**", "/cdContentInfo/**", "/getContributorByTutLanUser/**",
"/showConsultant/**", "/showLanguages/**", "/unpublishTutorial/**", "/loadTopicByCategory/**",
"/loadLanguageByCategoryTopic/**", "/loadTopicAndLanguageByCategory/**",
"/loadCategoryAndLanguageByTopic/**", "/loadCategoryAndTopicByLanguage/**", "/tutorialsSearch/**",
"/tutorialsSearch1/**", "/checkTutorial/**", "/Slide/**", "/TimeScript/**", "/OriginalScript/**",
"/Brochure-English/**", "/Brochure/**", "/ResearchPaper/**", "/downloads",
"/loadLanguageByCategoryResource", "/autosuggest/**", "/loadLanguageAndTopicByCategoryResource",
"/loadTutorialCountByTopicAndLanguage", "/loadTutorialCountByTopics", "/downloadResources", "/citations",
"/api/scriptPublished/**", "/loadLanguageByPackage/**", "/promoVideoView/**", "/trainingModules/**",
"/downloadTrainingModules", "/loadMessageByPackageAndLan/**", "/loadLanguageByWeek/**",
"/loadWeekByLanguage/**", "/trainingTutorials/**", "/hstTrainingModuleView/**", "/downloadManager/**",
"/downloadManagerforhst/**", "/downloadHealthTutorials/**", "/Training-Resource/**",
"/Training-Resources/**", "/loadLanAndFileTypeByTopic/**", "/loadTopicAndFileTypeByLan/**",
"/loadTopicAndLanByFileType/**", "/downloadTrainingResource/**", "/shared-Training-Resource/**",
"/shared-training-resource-file/**", "/check-deployment" };

"/showConsultant/**", "/showLanguages/**", "/loadTopicByCategory/**", "/loadLanguageByCategoryTopic/**",
"/loadTopicAndLanguageByCategory/**", "/loadCategoryAndLanguageByTopic/**",
"/loadCategoryAndTopicByLanguage/**", "/tutorialsSearch/**", "/tutorialsSearch1/**", "/checkTutorial/**",
"/Slide/**", "/TimeScript/**", "/OriginalScript/**", "/Brochure-English/**", "/Brochure/**",
"/ResearchPaper/**", "/downloads", "/loadLanguageByCategoryResource", "/autosuggest/**",
"/loadLanguageAndTopicByCategoryResource", "/loadTutorialCountByTopicAndLanguage",
"/loadTutorialCountByTopics", "/downloadResources", "/citations", "/api/scriptPublished/**",
"/loadLanguageByPackage/**", "/promoVideoView/**", "/trainingModules/**", "/downloadTrainingModules",
"/loadMessageByPackageAndLan/**", "/loadLanguageByWeek/**", "/loadWeekByLanguage/**",
"/trainingTutorials/**", "/hstTrainingModuleView/**", "/downloadManager/**", "/downloadManagerforhst/**",
"/downloadHealthTutorials/**", "/Training-Resource/**", "/Training-Resources/**",
"/loadLanAndFileTypeByTopic/**", "/loadTopicAndFileTypeByLan/**", "/loadTopicAndLanByFileType/**",
"/downloadTrainingResource/**", "/shared-Training-Resource/**", "/shared-training-resource-file/**",
"/check-deployment", "/training-resources/view-share/**" };

/**
* url matcher for SUPERADMIN
*/
public static final String[] SUPERUSER_URL = { "/addCategory/**", "/updateCategory/**", "/category/edit/**",
"/addOrganizationRole/**", "/organization_role/edit/**", "/update_organization_role/**", "/addLanguage/**",
"/language/edit/**", "/updateLanguage/**", "/addRole/**", "/addTopic/**", "/topic/edit/**",
"/updateTopic/**", "/uploadQuestion/**", "/question/edit/**", "/updateQuestion/**", "/addBrochure/**",
"/addCarousel/**", "/approveRole/**", "/assignTutorialToContributor/**", "/assignContributor/edit/**",
"/enableRoleById/**", "/deleteMasterRole/**", "/viewTrainee/**", "/details/**", "/tutorialStatus/**",
"/users/**", "/unpublishTopic/**", "/clearAllCaches/**", "/addConsultant/**",
"/enableDisableCourseCatTopic", "/delete-category-topic-from-course", "/createCourse",
"/courseName/edit/**", "/updateCourseName",

// "/unpublishTutorial/**"
"/updateTopic/**", "/uploadQuestion/**", "/question/edit/**", "/updateQuestion/**", "/approveRole/**",
"/assignTutorialToContributor/**", "/assignContributor/edit/**", "/enableRoleById/**",
"/deleteMasterRole/**", "/viewTrainee/**", "/details/**", "/tutorialStatus/**", "/users/**",
"/unpublishTopic/**", "/clearAllCaches/**",

};

Expand All @@ -95,13 +92,6 @@ public static BCryptPasswordEncoder passwordEncoder() {
public static final String[] CONTRIBUTOR_URL = { "/uploadTutorial/**", "/addOutline/**", "/addKeyword**",
"/addPreRequisticWhenNotRequired/**", "/addPreRequistic/**", "/addVideo/**", "/addSlide/**",
"/addScript/**", "/listTutorialForContributorReview/**", "/Contributor/review/**", "/uploadTimescript/**",
"/addLiveTutorial", "/updateLiveTutorial", "/addSpokenVideo", "/spokenVideo/edit/**", "/addVideoResource",
"/createPackage", "/packageName/edit/**", "/updatePackageName", "/weekTitleVideo/editTitle/**",

"/updateTitle", "/weekTitleVideo/editWeek/**", "/updateWeek", "/enableDisableCourseCatTopic",
"/delete-category-topic-from-course", "/createCourse", "/courseName/edit/**", "/updateCourseName",
"/addTrainingResource", "/trainingReource/view/**", "/trainingReourceAdminView/**",
"/trainingReource/edit/**", "/enableDisableTrainingResource", "/delete-trainingResource",

};

Expand Down Expand Up @@ -160,13 +150,25 @@ protected void configure(HttpSecurity http) throws Exception {
.antMatchers("/addBrochure/**", "/addCarousel/**", "/addConsultant/**", "/addEvent/**",
"/addTestimonial/**", "/addPromoVideo/**", "/addResearchPaper/**", "/brochure/edit/**",
"/promoVideo/edit/**", "/carousel/edit/**", "/event/edit/**", "/testimonial/edit/**",
"/createPackage", "/packageName/edit/**", "/updatePackageName", "/weekTitleVideo/editTitle/**",
"/createPackage/**", "/packageName/edit/**", "/updatePackageName/**",
"/weekTitleVideo/editTitle/**",

"/updateTitle", "/weekTitleVideo/editWeek/**", "/updateWeek", "/researchPaper/edit/**",
"/updateTitle/**", "/weekTitleVideo/editWeek/**", "/updateWeek/**", "/researchPaper/edit/**",
"/enableDisableBrouchure/**", "/enableDisableConsultant/**", "/enableDisableTestimonial/**",
"/addCitation/**", "/citation/edit/**", "/enableDisableCourseCatTopic",
"/delete-category-topic-from-course", "/createCourse", "/courseName/edit/**",
"/updateCourseName", "/addTrainingResource")
"/addCitation/**", "/citation/edit/**", "/enableDisableCourseCatTopic/**",
"/delete-category-topic-from-course/**", "/createCourse/**", "/courseName/edit/**",
"/enableDisablePromoVideo/**", "/enableDisablePacakgeLanguage/**",
"/enableDisableResearchPaper/**", "/enableDisableEvent/**", "/enableDisableCarousel/**",
"/updateCourseName/**", "/addTrainingResource/**", "/updateCitation/**", "/updateConsultant/**",
"/updateSpokenVideo/**", "/updateTrainingResource/**", "/updateEvent/**",
"/updatePromoVideo/**", "/updateBrochure/**", "/updateResearchPaper/**", "/updateCarousel/**",
"/updateTestimonial/**", "/addLiveTutorial/**", "/updateLiveTutorial/**", "/addSpokenVideo/**",
"/spokenVideo/edit/**", "/addVideoResource/**", "/trainingReource/view/**",
"/trainingReourceAdminView/**", "/trainingReource/edit/**", "/enableDisableTrainingResource/**",
"/delete-trainingResource/**", "/addProjectReport/**", "/projectReportAdminView/**",
"/projectReport/edit/**", "/enableDisableProjectReport/**", "/delete-projectReport/**"

)

.hasAnyAuthority("SUPER_USER", "CONTRIBUTOR").antMatchers(PUBLIC_MATCHERS).permitAll().anyRequest()
.authenticated().and().exceptionHandling().accessDeniedPage("/access-denied");
Expand Down
Loading
Loading