├── db ├── seeds.rb └── migrate │ ├── 20140714093636_add_event_id_to_calendar_queue.rb │ ├── 20170307233607_add_splash_to_service_alerts.rb │ ├── 20140815155903_add_latest_term_enrollment_csv_set.rb │ ├── 20161026183144_add_canvas_site_name_to_canvas_site_mailing_lists.rb │ ├── 20140722172233_create_canvas_synchronization_table.rb │ ├── 20130222213829_change_oauth2_data.rb │ ├── 20131107182850_remove_yhl_auth.rb │ ├── 20200417192341_remove_app_id_from_oauth2_data.rb │ ├── 20140715141414_add_transaction_type_to_calendar_tables.rb │ ├── 20140916213448_drop_is_test_user_auth.rb │ ├── 20130221235900_update_eli_uid.rb │ ├── 20130130144600_drop_widget_data.rb │ ├── 20131206145401_remove_canvas_oauth_data.rb │ ├── 20140502135009_drop_user_whitelist.rb │ ├── 20150521163404_add_list_details_to_canvas_site_mailing_lists.rb │ ├── 20130701162699_create_user_whitelist.rb │ ├── 20130809164403_darlene_super_user.rb │ ├── 20130124104800_create_notifications.rb │ ├── 20130517231512_add_doug_au_to_user_auths.rb │ ├── 20131219130504_add_mike_blake_to_user_auths.rb │ └── 20150212155014_create_stored_uid_tables.rb ├── log └── .gitkeep ├── tmp └── .gitkeep ├── .nvmrc ├── public ├── favicon.ico ├── dummy │ ├── json │ │ ├── has_exam_results.json │ │ ├── campus_solutions_link_empty.json │ │ ├── holds_errored.json │ │ ├── holds_empty.json │ │ ├── canvas_site_mailing_list_bad_site.json │ │ ├── canvas_course_grade_export_prepare_egrades_cache.json │ │ ├── lsadvising3.json │ │ ├── canvas_course_provision_job_response_success.json │ │ ├── canvas_official_sections_job_response_success.json │ │ ├── canvas_course_provision_job_response_error.json │ │ ├── canvas_official_sections_update_status_completed.json │ │ ├── canvas_official_sections_update_status_processing.json │ │ ├── canvas_course_provision_status_not_found.json │ │ ├── status_loggedout.json │ │ ├── canvas_official_sections_update_status_error.json │ │ └── textbooks_error.json │ └── images │ │ └── sample_student_72x96.jpg ├── canvas │ └── images │ │ ├── favicon.ico │ │ ├── bcourses_ios_icon.png │ │ ├── bcourses_lefthand.png │ │ ├── ucberkeley_footer.png │ │ ├── bcourses_windows_wide.png │ │ └── bcourses_windows_square.png ├── maintenance │ └── maintenance_images.png ├── oauth │ ├── calcentral_authlogo_120x120.png │ └── README.md ├── junction-maintenance │ └── maintenance_images.png └── robots.txt ├── app ├── assets │ ├── images │ │ └── .keep │ ├── javascripts │ │ └── .keep │ └── config │ │ └── manifest.js ├── models │ ├── user │ │ ├── academics │ │ │ ├── degree_progress │ │ │ │ └── graduate │ │ │ │ │ └── feed.rb │ │ │ ├── status │ │ │ │ ├── law.rb │ │ │ │ ├── graduate.rb │ │ │ │ └── severity.rb │ │ │ └── status_and_holds.rb │ │ ├── owned.rb │ │ ├── finances │ │ │ ├── cache_expiry.rb │ │ │ └── transactions.rb │ │ ├── webcasts │ │ │ └── concern.rb │ │ ├── photo.rb │ │ ├── financial_aid │ │ │ └── aid_years.rb │ │ ├── saved_uid.rb │ │ ├── b_courses │ │ │ └── concern.rb │ │ └── notifications │ │ │ └── cached_feed.rb │ ├── campus_solutions.rb │ ├── application_record.rb │ ├── financial_aid │ │ └── shared.rb │ ├── my_groups │ │ └── groups_module.rb │ ├── campus_solutions │ │ ├── campus_solutions_id_required.rb │ │ ├── holds_feature_flagged.rb │ │ ├── finaid_feature_flagged.rb │ │ ├── committees_feature_flagged.rb │ │ ├── delegate_students_expiry.rb │ │ ├── enrollment_card_feature_flagged.rb │ │ ├── student_lookup_feature_flagged.rb │ │ ├── student_success_feature_flagged.rb │ │ ├── emergency_contacts_feature_flagged.rb │ │ ├── advising_expiry.rb │ │ ├── financial_aid_compare_awards_feature_flagged.rb │ │ ├── billing │ │ │ └── billing_feature_flagged.rb │ │ ├── profile_feature_flagged.rb │ │ ├── delegated_access_feature_flagged.rb │ │ ├── checklist_data_expiry.rb │ │ ├── section_grades_expiry.rb │ │ ├── user_api_updating_model.rb │ │ ├── person_data_updating_model.rb │ │ ├── checklist_data_updating_model.rb │ │ ├── grading.rb │ │ ├── sir │ │ │ ├── my_sir_response.rb │ │ │ └── my_deposit.rb │ │ ├── work_experience_updating_model.rb │ │ ├── cs_official_transcript.rb │ │ ├── my_language.rb │ │ ├── my_person_name.rb │ │ ├── my_ethnicity.rb │ │ ├── advisor_student_relationship.rb │ │ ├── financial_aid_summary_link.rb │ │ ├── advisor_student_action_items.rb │ │ ├── emergency_loan_link.rb │ │ ├── my_checklist.rb │ │ ├── student_term_gpa.rb │ │ └── summer_estimator_link.rb │ ├── my_academics │ │ ├── advising_academic_planner_feature_flagged.rb │ │ ├── my_transfer_credit.rb │ │ ├── law │ │ │ ├── awards.rb │ │ │ └── transcript_notes.rb │ │ └── messages.rb │ ├── financials │ │ └── loan_history │ │ │ ├── messaging_inactive.rb │ │ │ ├── messaging_general.rb │ │ │ ├── messaging_prior_enrollment.rb │ │ │ ├── glossary_aid_years.rb │ │ │ ├── glossary_cumulative.rb │ │ │ └── merged_inactive.rb │ ├── links │ │ ├── link_category.rb │ │ └── user_role.rb │ ├── notifications │ │ └── educ_level_translator.rb │ ├── berkeley │ │ └── course.rb │ ├── my_badges │ │ └── badges_module.rb │ ├── calnet_crosswalk │ │ ├── by_cs_id.rb │ │ └── by_uid.rb │ ├── enf │ │ └── handler.rb │ ├── api │ │ └── service_alerts.rb │ ├── google_apps │ │ ├── events_get.rb │ │ ├── events_update.rb │ │ └── revoke.rb │ ├── my_activities │ │ └── dashboard_sites.rb │ ├── concerns │ │ ├── careers.rb │ │ └── query_helper.rb │ ├── edo_oracle │ │ └── career.rb │ ├── canvas │ │ └── todo.rb │ └── hub_edos │ │ └── cached_proxy.rb └── controllers │ ├── covid_response_controller.rb │ ├── server_runtime_controller.rb │ ├── concerns │ ├── disallow_advisor_view_as.rb │ ├── disallow_classic_view_as.rb │ └── current_user_concern.rb │ ├── campus_solutions │ ├── country_controller.rb │ ├── currency_code_controller.rb │ ├── language_code_controller.rb │ ├── ethnicity_setup_controller.rb │ ├── state_controller.rb │ ├── translate_controller.rb │ ├── address_label_controller.rb │ ├── confidential_student_controller.rb │ ├── emergency_contacts_controller.rb │ ├── faculty_resources_controller.rb │ ├── student_resources_controller.rb │ ├── link_controller.rb │ ├── slr_deeplink_controller.rb │ ├── fpp_enrollment_controller.rb │ ├── sir_response_controller.rb │ ├── ethnicity_controller.rb │ ├── language_controller.rb │ ├── exam_results_controller.rb │ └── work_experience_controller.rb │ ├── my_badges_controller.rb │ ├── stats_controller.rb │ ├── my_groups_controller.rb │ ├── my_advising_controller.rb │ ├── my_classes_controller.rb │ ├── my_academic_records_controller.rb │ ├── enrollment_verification_controller.rb │ ├── sir_statuses_controller.rb │ ├── new_admit_resources_controller.rb │ ├── my_standings_controller.rb │ ├── my_registrations_controller.rb │ ├── my_eft_enrollment_controller.rb │ ├── my_up_next_controller.rb │ ├── my_activities_controller.rb │ ├── my_financials_controller.rb │ ├── user │ ├── tasks │ │ ├── agreements_controller.rb │ │ ├── web_messages_controller.rb │ │ ├── canvas_messages_controller.rb │ │ ├── checklist_items_controller.rb │ │ └── b_courses_todos_controller.rb │ └── academics │ │ ├── status_and_holds_controller.rb │ │ └── diploma_controller.rb │ ├── my_aid_years_controller.rb │ ├── transfer_credit_controller.rb │ ├── my_financial_aid_summary_controller.rb │ ├── my_awards_by_term_controller.rb │ ├── my_law_awards_controller.rb │ ├── my_textbooks_controller.rb │ ├── my_awards_controller.rb │ ├── my_housing_controller.rb │ ├── api │ └── base_controller.rb │ └── my_finaid_profile_controller.rb ├── src ├── test │ └── style-mock.js ├── assets │ ├── javascripts │ │ ├── angular │ │ │ ├── filters │ │ │ │ ├── .gitkeep │ │ │ │ └── dateUnlessNoonFilter.js │ │ │ ├── controllers │ │ │ │ ├── pages │ │ │ │ │ ├── reactController.js │ │ │ │ │ ├── billingDetailsController.js │ │ │ │ │ ├── errorController.js │ │ │ │ │ ├── uidErrorController.js │ │ │ │ │ ├── delegateWelcomeController.js │ │ │ │ │ ├── splashController.js │ │ │ │ │ ├── myToolboxController.js │ │ │ │ │ └── academicSummaryController.js │ │ │ │ └── widgets │ │ │ │ │ └── alertsController.js │ │ │ ├── configuration │ │ │ │ ├── qConfiguration.js │ │ │ │ ├── locationConfiguration.js │ │ │ │ ├── sceConfiguration.js │ │ │ │ └── httpConfiguration.js │ │ │ ├── directives │ │ │ │ ├── academicCareersDirective.js │ │ │ │ ├── profileImageDirective.js │ │ │ │ ├── academicPlansDirective.js │ │ │ │ ├── selectOnClickDirective.js │ │ │ │ ├── finaidTableDirective.js │ │ │ │ ├── expectedGraduationTermsDirective.js │ │ │ │ └── bcIframeResizeDirective.js │ │ │ └── factories │ │ │ │ ├── webcastFactory.js │ │ │ │ ├── badgesFactory.js │ │ │ │ ├── myGroupsFactory.js │ │ │ │ ├── serverInfoFactory.js │ │ │ │ └── googleFactory.js │ │ └── fonts.scss │ ├── templates │ │ ├── widgets │ │ │ ├── profile │ │ │ │ ├── finaid_awards.html │ │ │ │ ├── recordaccess.html │ │ │ │ ├── unavailable.html │ │ │ │ ├── basic_name.html │ │ │ │ └── basic_user_id.html │ │ │ ├── enrollment │ │ │ │ └── enrollment_hide_links.html │ │ │ ├── delegate_student_img.html │ │ │ ├── finaid_errored.html │ │ │ ├── profile_img.html │ │ │ ├── finances_links.html │ │ │ ├── transfer_credit_type_units.html │ │ │ └── loan_history │ │ │ │ ├── loan_resources_card.html │ │ │ │ └── resources.html │ │ ├── react.html │ │ ├── academic_summary_page.html │ │ ├── academics_status_holds_blocks.html │ │ ├── accessibility.html │ │ ├── academics_higher_degree_committees.html │ │ ├── academics_higher_degree_faculty_committees.html │ │ ├── loan_resources_page.html │ │ ├── cumulative_loan_debt_page.html │ │ ├── loan_summary_by_aid_year_page.html │ │ ├── directives │ │ │ ├── sortable_column.html │ │ │ └── finaid_summary_item.html │ │ ├── advisor_acting_as.html │ │ └── delegate_acting_as.html │ ├── stylesheets │ │ ├── _advising_resources.scss │ │ ├── _containers.scss │ │ ├── _finaid_coa.scss │ │ ├── _finaid_permissions.scss │ │ ├── _row_collapse_bug.scss │ │ ├── _disabled_links.scss │ │ ├── _alerts.scss │ │ ├── _campus.scss │ │ ├── _oldie.scss │ │ ├── _logo.scss │ │ ├── _loan_history_summary.scss │ │ ├── _profile_image.scss │ │ ├── _finaid.scss │ │ ├── _finaid_housing.scss │ │ ├── _degrees_conferred.scss │ │ ├── _finaid_profile.scss │ │ ├── _academic_plan.scss │ │ ├── _datepicker.scss │ │ └── _calcentral_update.scss │ └── images │ │ ├── favicon.ico │ │ ├── favicon.png │ │ ├── app_icons │ │ ├── 192.png │ │ ├── 768.png │ │ ├── artwork.png │ │ ├── icon-72.png │ │ ├── icon-76.png │ │ ├── icon-60@2x.png │ │ ├── icon-60@3x.png │ │ ├── icon-72@2x.png │ │ ├── icon-76@2x.png │ │ └── icon-small@2x.png │ │ ├── favicon_16x16.png │ │ ├── favicon_32x32.png │ │ ├── alum_landing_bg.png │ │ ├── bear-with-mask.png │ │ ├── icon_oskicat_16x16.png │ │ ├── icon_slate_64x64.png │ │ ├── splash_cfv_625x415.png │ │ ├── uc_berkeley_bay_view.jpg │ │ ├── icon_googlebook_32x32.png │ │ ├── sir │ │ ├── banner_haas_326x96.jpg │ │ ├── banner_law_326x96.jpg │ │ ├── banner_berkeley_326x96.jpg │ │ ├── grad_fiona_doyle_100x140.jpg │ │ ├── ugrad_amy_jarich_100x140.jpg │ │ ├── haas_ann_harrison_100x140.jpg │ │ ├── haas_richard_lyons_100x140.jpg │ │ ├── grad_lisa_g_bedolla_100x140.jpg │ │ └── ugrad_olufemio_ogundele_100x140.jpg │ │ ├── splash_waitlist_625x415.png │ │ ├── glass_magnifying_200x175.jpg │ │ ├── splash_bconnected_625x415.png │ │ ├── splash_telebears_625x415.png │ │ ├── icon_campussolutions_64x64.png │ │ ├── canvas │ │ └── select-menu-arrow-down.svg │ │ └── svg │ │ ├── select_arrow_20x28.svg │ │ └── icon_drive_256x256.svg ├── react │ ├── components │ │ ├── _academics │ │ │ ├── StudentProfile │ │ │ │ ├── ProfilePicture.scss │ │ │ │ ├── MissingPhoto.js │ │ │ │ ├── Degrees.scss │ │ │ │ └── MissingPhoto.scss │ │ │ ├── AcademicSummary │ │ │ │ ├── SectionIncompleteGradingStatus.scss │ │ │ │ ├── AcademicSummary.scss │ │ │ │ └── SemestersSummary.scss │ │ │ └── ClassInformationCard │ │ │ │ ├── ClassInformationCard.module.scss │ │ │ │ ├── CrossListings.module.scss │ │ │ │ └── ClassAttributesTable.module.scss │ │ ├── _dashboard │ │ │ ├── TasksCard │ │ │ │ ├── CompletedTasks │ │ │ │ │ ├── CompletedAgreement.js │ │ │ │ │ ├── CategoryTitle.module.scss │ │ │ │ │ └── CategoryTitle.js │ │ │ │ ├── index.js │ │ │ │ ├── Icons │ │ │ │ │ ├── iconWrapper.module.scss │ │ │ │ │ ├── CanvasIcon.js │ │ │ │ │ └── CampusSolutionsIcon.js │ │ │ │ ├── IncompleteFinancialAidTasks │ │ │ │ │ └── AidYearTasks.module.scss │ │ │ │ ├── IncompleteTasks │ │ │ │ │ ├── ByCategory.module.scss │ │ │ │ │ ├── IncompleteDueSoonBadges.module.scss │ │ │ │ │ └── CategoryHeader.module.scss │ │ │ │ ├── Category.module.scss │ │ │ │ ├── TasksContext.js │ │ │ │ ├── TaskDetail.module.scss │ │ │ │ ├── TaskHeader.module.scss │ │ │ │ ├── Tasks.js │ │ │ │ ├── TaskTitle.module.scss │ │ │ │ ├── Switcher.module.scss │ │ │ │ ├── TasksCard.module.scss │ │ │ │ └── TaskHeader.js │ │ │ ├── NotificationsCard │ │ │ │ ├── index.js │ │ │ │ ├── MessageHeader.module.scss │ │ │ │ ├── University │ │ │ │ │ └── Unread.module.scss │ │ │ │ └── useShowMore.js │ │ │ ├── index.js │ │ │ ├── bConnected │ │ │ │ └── NoBconnected.scss │ │ │ ├── AlumniHomepage │ │ │ │ └── AlumniHomepage.module.scss │ │ │ └── UpNext │ │ │ │ └── UpNextCard.scss │ │ ├── _finances │ │ │ ├── TransactionsCard │ │ │ │ ├── LegacyDataLink.scss │ │ │ │ ├── BillingItem │ │ │ │ │ ├── ItemUpdated.scss │ │ │ │ │ ├── MoreDetails.scss │ │ │ │ │ ├── ChargeItem.scss │ │ │ │ │ ├── dueLabel.js │ │ │ │ │ ├── ItemAmount.scss │ │ │ │ │ └── ItemPayment.scss │ │ │ │ ├── types.js │ │ │ │ ├── billingItemViews.js │ │ │ │ ├── chargeStatuses.js │ │ │ │ ├── BillingItemsTable │ │ │ │ │ ├── BillingItemsTable.scss │ │ │ │ │ └── ShowMore.scss │ │ │ │ └── DownloadButton.scss │ │ │ └── AwardComparison │ │ │ │ ├── SelectedDateContext.js │ │ │ │ └── aidYearShape.js │ │ ├── APILink.scss │ │ ├── VerticalSpacer.js │ │ ├── ErrorMessage.module.scss │ │ ├── Icon │ │ │ ├── GreenCheckIcon.js │ │ │ ├── GreenCheckCircle.js │ │ │ └── RedExclamationIcon.js │ │ ├── angularWrappers │ │ │ └── degreeProgressNotice.js │ │ ├── SortArrows.scss │ │ ├── _user_overview │ │ │ └── EmploymentAppointments │ │ │ │ └── EmploymentAppointments.scss │ │ └── VisuallyHidden.js │ ├── colors.js │ ├── stylesheets │ │ ├── student_resources.scss │ │ ├── useful.scss │ │ └── lists.scss │ ├── angularWrappers │ │ └── index.js │ ├── types.js │ ├── helpers │ │ ├── gpa.js │ │ ├── filters.js │ │ ├── roles.js │ │ └── state.js │ └── .eslintrc.json ├── index.js ├── components │ ├── FieldError.module.scss │ ├── VerticalSpacers.js │ ├── FormActions.module.scss │ ├── SplashContainer.module.scss │ ├── Pagination.module.scss │ ├── .eslintrc.json │ ├── Table.js │ ├── Form.module.scss │ ├── FormActions.js │ ├── SplashContainer.js │ ├── Form.js │ └── ReduxProvider.js ├── icons │ ├── blue-bullet.svg │ ├── white-bullet.svg │ ├── disc-active.svg │ ├── disc-inactive.svg │ ├── triangle-up.svg │ ├── triangle-down.svg │ ├── timeline-top-cap.svg │ ├── timeline-bottom-cap.svg │ ├── not-yet-due.svg │ ├── due-now.svg │ ├── chevron-down.svg │ ├── chevron-up.svg │ ├── chevron-down-large.svg │ ├── timeline-center.svg │ ├── timeline-center-blue.svg │ └── timeline-empty.svg ├── redux │ ├── actions │ │ ├── configActions.js │ │ ├── routeActions.js │ │ └── linksActions.js │ └── reducers │ │ ├── currentUID.js │ │ ├── ConfigReducer.js │ │ ├── FinancialAidReducer.js │ │ └── RouteReducer.js └── functions │ ├── isPresent.js │ └── formatCurrency.js ├── versions ├── api.txt └── application.txt ├── .node-version ├── .ruby-version ├── config ├── autoprefixer.yml ├── initializers │ ├── webmock_allow_net_connect.rb │ ├── mime_types.rb │ ├── filter_parameter_logging.rb │ ├── in_memory_database.rb │ ├── session_store.rb │ ├── disable_webmock_default.rb │ └── secure_headers.rb ├── environment.rb ├── boot.rb ├── warble.rb └── settings │ ├── server_config.sample.yml │ └── server_config.rb ├── spec ├── models │ ├── user │ │ ├── user_attributes_spec.rb │ │ └── academics │ │ │ └── student_groups_cached_spec.rb │ ├── hub_edos │ │ └── student_api │ │ │ └── v2 │ │ │ ├── student │ │ │ ├── award_honor_spec.rb │ │ │ └── student_plans_spec.rb │ │ │ └── student_record │ │ │ └── gpa_spec.rb │ ├── berkeley │ │ └── course_spec.rb │ └── student_success │ │ └── oustanding_balance_spec.rb ├── support │ └── factory_bot.rb ├── lib │ └── errors │ │ └── client_error_spec.rb ├── controllers │ ├── my_campus_links_controller_spec.rb │ └── campus_solutions │ │ ├── state_controller_spec.rb │ │ ├── country_controller_spec.rb │ │ ├── translate_controller_spec.rb │ │ ├── address_label_controller_spec.rb │ │ ├── language_code_controller_spec.rb │ │ ├── currency_code_controller_spec.rb │ │ ├── ethnicity_setup_controller_spec.rb │ │ └── student_resources_controller_spec.rb ├── factories │ ├── service_alerts.rb │ └── user_auths.rb └── ui_selenium │ └── pages │ ├── delegate_welcome_card.rb │ ├── api_my_badges_page.rb │ ├── my_academics_book_list_page.rb │ ├── my_profile_demographic_card.rb │ └── my_profile_info_disclosure_card.rb ├── fixtures ├── json │ ├── google_events_delete.json │ ├── canvas_external_tools_129069.json │ ├── eft_enrollment.json │ ├── google_userinfo.json │ ├── canvas_put_login_sis_user_id.json │ ├── canvas_start_provisioning_report_users.json │ ├── hub_v2_not_found.json │ ├── canvas_course_settings.json │ ├── google_events_delete_nonexistent.json │ ├── canvas_start_provisioning_report_courses.json │ ├── canvas_start_provisioning_report_sections.json │ ├── canvas_sis_import_enrollments.json │ ├── financials_not_found.json │ ├── canvas_section.json │ ├── canvas_course_create_section.json │ ├── canvas_account.json │ ├── canvas_check_provisioning_report_users.json │ ├── canvas_admins_87483_page_1.json │ ├── canvas_admins_90242_page_2.json │ ├── canvas_check_provisioning_report_courses.json │ ├── canvas_user_logins.json │ ├── canvas_add_admin.json │ ├── canvas_sis_import_users.json │ ├── hub_generic.json │ ├── canvas_groups.json │ └── canvas_check_provisioning_report_sections.json ├── xml │ └── campus_solutions │ │ ├── link_api_empty.xml │ │ ├── student_outstanding_balance.xml │ │ ├── emergency_contacts_empty.xml │ │ ├── language_post.xml │ │ ├── work_experience.xml │ │ ├── delegate_access_create.xml │ │ ├── ethnicity_post.xml │ │ ├── sir_response.xml │ │ ├── language_delete.xml │ │ ├── person_name.xml │ │ ├── prior_work_delete.xml │ │ ├── name_delete.xml │ │ ├── ethnicity_delete.xml │ │ ├── college_scheduler_url.xml │ │ ├── higher_one_url.xml │ │ ├── delegate_management_url.xml │ │ ├── deposit.xml │ │ ├── dashboard_url.xml │ │ ├── fpp_enrollment.xml │ │ ├── ce_diploma_sso.xml │ │ ├── ferpa_deeplink_url.xml │ │ ├── financial_aid_compare_awards_list.xml │ │ ├── link_api_error.xml │ │ └── message_catalog.xml ├── ui_selenium │ └── uids.json ├── oec │ └── overrides_instructors.csv ├── jms_recordings │ └── ist_jms.txt └── csv │ └── Canvas_provisioning_report_courses_csv.csv ├── .rspec ├── .csslintrc ├── .prettierignore ├── .prettierrc ├── Capfile ├── .gitattributes ├── lib ├── errors │ ├── api_contract_error.rb │ ├── bad_request_error.rb │ └── client_error.rb ├── proxies │ └── tls12.rb └── tasks │ └── superuser.rake ├── bin ├── rake ├── bundle └── rails ├── .markdownlint.json ├── config.ru ├── .eslintignore ├── script ├── logrotate.conf ├── upgrade.sh └── monitor.sh ├── .editorconfig ├── .vscode └── extensions.json ├── .babelrc.js ├── jest.config.js ├── Guardfile └── Rakefile /db/seeds.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /log/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tmp/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 10.15.3 2 | -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/assets/images/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/test/style-mock.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /versions/api.txt: -------------------------------------------------------------------------------- 1 | 1 2 | -------------------------------------------------------------------------------- /.node-version: -------------------------------------------------------------------------------- 1 | 10.15.3 2 | -------------------------------------------------------------------------------- /app/assets/javascripts/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.ruby-version: -------------------------------------------------------------------------------- 1 | jruby-9.2.13.0 2 | -------------------------------------------------------------------------------- /versions/application.txt: -------------------------------------------------------------------------------- 1 | 111 2 | -------------------------------------------------------------------------------- /config/autoprefixer.yml: -------------------------------------------------------------------------------- 1 | cascade: false 2 | -------------------------------------------------------------------------------- /spec/models/user/user_attributes_spec.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /fixtures/json/google_events_delete.json: -------------------------------------------------------------------------------- 1 | {} 2 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/filters/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.rspec: -------------------------------------------------------------------------------- 1 | --color 2 | --require spec_helper 3 | 4 | -------------------------------------------------------------------------------- /app/models/user/academics/degree_progress/graduate/feed.rb: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /fixtures/json/canvas_external_tools_129069.json: -------------------------------------------------------------------------------- 1 | [] 2 | -------------------------------------------------------------------------------- /.csslintrc: -------------------------------------------------------------------------------- 1 | --exclude-list=public/canvas/canvas-skin.css 2 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile/finaid_awards.html: -------------------------------------------------------------------------------- 1 | TBD 2 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile/recordaccess.html: -------------------------------------------------------------------------------- 1 | TBD 2 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | coverage 3 | public 4 | dist 5 | -------------------------------------------------------------------------------- /app/models/campus_solutions.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | end 3 | -------------------------------------------------------------------------------- /src/assets/templates/react.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /src/react/components/_academics/StudentProfile/ProfilePicture.scss: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /public/dummy/json/has_exam_results.json: -------------------------------------------------------------------------------- 1 | { 2 | "hasTestHistory": true 3 | } -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/CompletedTasks/CompletedAgreement.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/index.js: -------------------------------------------------------------------------------- 1 | import './TasksCard'; 2 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "singleQuote": true, 3 | "trailingComma": "es5" 4 | } 5 | -------------------------------------------------------------------------------- /public/dummy/json/campus_solutions_link_empty.json: -------------------------------------------------------------------------------- 1 | {"status":null,"link":null} 2 | -------------------------------------------------------------------------------- /Capfile: -------------------------------------------------------------------------------- 1 | load 'config/deploy' # remove this line to skip loading any of the default tasks 2 | -------------------------------------------------------------------------------- /src/assets/templates/academic_summary_page.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/NotificationsCard/index.js: -------------------------------------------------------------------------------- 1 | import './NotificationsCard'; 2 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Automatically normalize line endings for all text-based files 2 | * text=auto 3 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/link_api_empty.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /src/react/colors.js: -------------------------------------------------------------------------------- 1 | const colors = { 2 | dustyGray: `#999`, 3 | }; 4 | 5 | export default colors; 6 | -------------------------------------------------------------------------------- /lib/errors/api_contract_error.rb: -------------------------------------------------------------------------------- 1 | module Errors 2 | class ApiContractError < StandardError 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /lib/errors/bad_request_error.rb: -------------------------------------------------------------------------------- 1 | module Errors 2 | class BadRequestError < ClientError 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /bin/rake: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require_relative '../config/boot' 3 | require 'rake' 4 | Rake.application.run 5 | -------------------------------------------------------------------------------- /spec/support/factory_bot.rb: -------------------------------------------------------------------------------- 1 | RSpec.configure do |config| 2 | config.include FactoryBot::Syntax::Methods 3 | end 4 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_advising_resources.scss: -------------------------------------------------------------------------------- 1 | .cc-widget-advising-resources { 2 | padding-bottom: 10px; 3 | } 4 | -------------------------------------------------------------------------------- /app/models/application_record.rb: -------------------------------------------------------------------------------- 1 | class ApplicationRecord < ActiveRecord::Base 2 | self.abstract_class = true 3 | end 4 | -------------------------------------------------------------------------------- /src/assets/images/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/favicon.ico -------------------------------------------------------------------------------- /src/assets/images/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/favicon.png -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/LegacyDataLink.scss: -------------------------------------------------------------------------------- 1 | .LegacyTransactions { 2 | margin-top: 10px; 3 | } 4 | -------------------------------------------------------------------------------- /public/canvas/images/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/favicon.ico -------------------------------------------------------------------------------- /.markdownlint.json: -------------------------------------------------------------------------------- 1 | { 2 | "MD036": false, 3 | "MD013": { 4 | "code_blocks": false, 5 | "tables": false 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /spec/models/hub_edos/student_api/v2/student/award_honor_spec.rb: -------------------------------------------------------------------------------- 1 | describe HubEdos::StudentApi::V2::Student::AwardHonor do 2 | end 3 | -------------------------------------------------------------------------------- /src/assets/images/app_icons/192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/192.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/768.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/768.png -------------------------------------------------------------------------------- /src/assets/images/favicon_16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/favicon_16x16.png -------------------------------------------------------------------------------- /src/assets/images/favicon_32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/favicon_32x32.png -------------------------------------------------------------------------------- /src/assets/stylesheets/_containers.scss: -------------------------------------------------------------------------------- 1 | // Container 2 | .cc-container-main { 3 | background-color: $color-wild-sand; 4 | } 5 | -------------------------------------------------------------------------------- /src/index.js: -------------------------------------------------------------------------------- 1 | import './assets/javascripts/index.js'; 2 | import './react/components/index'; 3 | import './react/angularWrappers'; 4 | -------------------------------------------------------------------------------- /fixtures/ui_selenium/uids.json: -------------------------------------------------------------------------------- 1 | { 2 | "users": [ 3 | { 4 | "uid": 61889, 5 | "finances": true 6 | } 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /src/assets/images/alum_landing_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/alum_landing_bg.png -------------------------------------------------------------------------------- /src/assets/images/bear-with-mask.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/bear-with-mask.png -------------------------------------------------------------------------------- /src/assets/templates/widgets/enrollment/enrollment_hide_links.html: -------------------------------------------------------------------------------- 1 | While viewing someone's information, you can't see these links. 2 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Icons/iconWrapper.module.scss: -------------------------------------------------------------------------------- 1 | .iconWrapper { 2 | width: 30px; 3 | font-size: 19px; 4 | } 5 | -------------------------------------------------------------------------------- /app/assets/config/manifest.js: -------------------------------------------------------------------------------- 1 | //= link_tree ../images 2 | //= link_directory ../javascripts .js 3 | //= link_directory ../stylesheets .css 4 | -------------------------------------------------------------------------------- /public/dummy/json/holds_errored.json: -------------------------------------------------------------------------------- 1 | { 2 | "feed": { 3 | "holds": [] 4 | }, 5 | "errored": true, 6 | "statusCode": 503 7 | } 8 | -------------------------------------------------------------------------------- /src/assets/images/app_icons/artwork.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/artwork.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-72.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-76.png -------------------------------------------------------------------------------- /src/assets/images/icon_oskicat_16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/icon_oskicat_16x16.png -------------------------------------------------------------------------------- /src/assets/images/icon_slate_64x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/icon_slate_64x64.png -------------------------------------------------------------------------------- /src/assets/images/splash_cfv_625x415.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/splash_cfv_625x415.png -------------------------------------------------------------------------------- /app/models/financial_aid/shared.rb: -------------------------------------------------------------------------------- 1 | module FinancialAid 2 | module Shared 3 | ADMIN_FUNCTION = %w(FINA FINT ISIR LOAN) 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /public/canvas/images/bcourses_ios_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/bcourses_ios_icon.png -------------------------------------------------------------------------------- /public/canvas/images/bcourses_lefthand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/bcourses_lefthand.png -------------------------------------------------------------------------------- /public/canvas/images/ucberkeley_footer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/ucberkeley_footer.png -------------------------------------------------------------------------------- /public/dummy/json/holds_empty.json: -------------------------------------------------------------------------------- 1 | { 2 | "feed": { 3 | "holds": [ 4 | ] 5 | }, 6 | "errored": null, 7 | "statusCode": 200 8 | } 9 | -------------------------------------------------------------------------------- /public/maintenance/maintenance_images.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/maintenance/maintenance_images.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-60@2x.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-60@3x.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-72@2x.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-76@2x.png -------------------------------------------------------------------------------- /src/assets/images/uc_berkeley_bay_view.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/uc_berkeley_bay_view.jpg -------------------------------------------------------------------------------- /src/assets/javascripts/fonts.scss: -------------------------------------------------------------------------------- 1 | $fa-font-path: '/assets/fonts'; 2 | 3 | @import '../../../node_modules/font-awesome/scss/font-awesome.scss'; 4 | -------------------------------------------------------------------------------- /src/components/FieldError.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .FieldError { 4 | color: $color-thunderbird; 5 | } 6 | -------------------------------------------------------------------------------- /bin/bundle: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 3 | load Gem.bin_path('bundler', 'bundle') 4 | -------------------------------------------------------------------------------- /public/dummy/images/sample_student_72x96.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/dummy/images/sample_student_72x96.jpg -------------------------------------------------------------------------------- /public/oauth/calcentral_authlogo_120x120.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/oauth/calcentral_authlogo_120x120.png -------------------------------------------------------------------------------- /src/assets/images/app_icons/icon-small@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/app_icons/icon-small@2x.png -------------------------------------------------------------------------------- /src/assets/images/icon_googlebook_32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/icon_googlebook_32x32.png -------------------------------------------------------------------------------- /src/assets/images/sir/banner_haas_326x96.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/banner_haas_326x96.jpg -------------------------------------------------------------------------------- /src/assets/images/sir/banner_law_326x96.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/banner_law_326x96.jpg -------------------------------------------------------------------------------- /src/assets/images/splash_waitlist_625x415.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/splash_waitlist_625x415.png -------------------------------------------------------------------------------- /src/assets/stylesheets/_finaid_coa.scss: -------------------------------------------------------------------------------- 1 | .cc-widget-finaid-coa { 2 | .cc-widget-finaid-coa-text-padding { 3 | padding: 10px 0; 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /src/components/VerticalSpacers.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | export const LargeSpacer = () =>
; 4 | -------------------------------------------------------------------------------- /src/react/components/APILink.scss: -------------------------------------------------------------------------------- 1 | @import '../../assets/stylesheets/colors.scss'; 2 | 3 | .APILink--disabled { 4 | color: $color-dusty-gray; 5 | } 6 | -------------------------------------------------------------------------------- /public/canvas/images/bcourses_windows_wide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/bcourses_windows_wide.png -------------------------------------------------------------------------------- /src/assets/images/glass_magnifying_200x175.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/glass_magnifying_200x175.jpg -------------------------------------------------------------------------------- /src/assets/images/splash_bconnected_625x415.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/splash_bconnected_625x415.png -------------------------------------------------------------------------------- /src/assets/images/splash_telebears_625x415.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/splash_telebears_625x415.png -------------------------------------------------------------------------------- /src/components/FormActions.module.scss: -------------------------------------------------------------------------------- 1 | .FormActions { 2 | margin-top: 15px; 3 | display: flex; 4 | 5 | a { 6 | margin-left: 10px; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /app/models/my_groups/groups_module.rb: -------------------------------------------------------------------------------- 1 | module MyGroups::GroupsModule 2 | extend self 3 | 4 | def initialize(uid) 5 | @uid = uid 6 | end 7 | 8 | end 9 | -------------------------------------------------------------------------------- /fixtures/json/eft_enrollment.json: -------------------------------------------------------------------------------- 1 | { 2 | "statusCode":200, 3 | "data":{ 4 | "eftStatus": "active", 5 | "accountNumber": "6456" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /fixtures/oec/overrides_instructors.csv: -------------------------------------------------------------------------------- 1 | LDAP_UID,SIS_ID,FIRST_NAME,LAST_NAME,EMAIL_ADDRESS,BLUE_ROLE 2 | 10316,UID:10316,Lady,Gaga,born-this-way@berkeley.edu,23 3 | -------------------------------------------------------------------------------- /public/canvas/images/bcourses_windows_square.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/canvas/images/bcourses_windows_square.png -------------------------------------------------------------------------------- /public/junction-maintenance/maintenance_images.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/public/junction-maintenance/maintenance_images.png -------------------------------------------------------------------------------- /src/assets/images/icon_campussolutions_64x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/icon_campussolutions_64x64.png -------------------------------------------------------------------------------- /src/assets/images/sir/banner_berkeley_326x96.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/banner_berkeley_326x96.jpg -------------------------------------------------------------------------------- /src/assets/images/sir/grad_fiona_doyle_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/grad_fiona_doyle_100x140.jpg -------------------------------------------------------------------------------- /src/assets/images/sir/ugrad_amy_jarich_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/ugrad_amy_jarich_100x140.jpg -------------------------------------------------------------------------------- /src/react/components/_dashboard/index.js: -------------------------------------------------------------------------------- 1 | import './StudentResources/StudentResourcesContainer'; 2 | import './TasksCard'; 3 | import './NotificationsCard'; 4 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_site_mailing_list_bad_site.json: -------------------------------------------------------------------------------- 1 | { 2 | "errorMessages": [ 3 | "No bCourses site with ID \"9999999999999\" was found." 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /src/assets/images/canvas/select-menu-arrow-down.svg: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /src/assets/images/sir/haas_ann_harrison_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/haas_ann_harrison_100x140.jpg -------------------------------------------------------------------------------- /src/assets/images/sir/haas_richard_lyons_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/haas_richard_lyons_100x140.jpg -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/student_outstanding_balance.xml: -------------------------------------------------------------------------------- 1 | 2 | $153.00 3 | 4 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_course_grade_export_prepare_egrades_cache.json: -------------------------------------------------------------------------------- 1 | { 2 | "jobId": "canvas.egrades.12345.1383330151058", 3 | "jobRequestStatus": "Success" 4 | } 5 | -------------------------------------------------------------------------------- /public/dummy/json/lsadvising3.json: -------------------------------------------------------------------------------- 1 | { 2 | "sid": "44442222", 3 | "name": "Sam Smith", 4 | "urlToMakeAppointment": "http://bhive.berkeley.edu/appointments/new" 5 | } 6 | -------------------------------------------------------------------------------- /src/assets/images/sir/grad_lisa_g_bedolla_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/grad_lisa_g_bedolla_100x140.jpg -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/reactController.js: -------------------------------------------------------------------------------- 1 | angular 2 | .module('calcentral.controllers') 3 | .controller('ReactController', function() {}); 4 | -------------------------------------------------------------------------------- /app/controllers/covid_response_controller.rb: -------------------------------------------------------------------------------- 1 | class CovidResponseController < ApplicationController 2 | def index 3 | render json: COVIDUpdates.new 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /config/initializers/webmock_allow_net_connect.rb: -------------------------------------------------------------------------------- 1 | Rails.application.config.after_initialize do 2 | if defined? WebMock 3 | WebMock.allow_net_connect! 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /fixtures/json/google_userinfo.json: -------------------------------------------------------------------------------- 1 | { 2 | "emailAddresses": [ 3 | { 4 | "value": "tammi.chang.clc@gmail.com", 5 | "type": "account" 6 | } 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /spec/lib/errors/client_error_spec.rb: -------------------------------------------------------------------------------- 1 | describe Errors::ClientError do 2 | it 'should exist' do 3 | expect(defined?(Errors::ClientError)).to be_truthy 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /src/assets/images/sir/ugrad_olufemio_ogundele_100x140.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sis-berkeley-edu/calcentral/HEAD/src/assets/images/sir/ugrad_olufemio_ogundele_100x140.jpg -------------------------------------------------------------------------------- /public/dummy/json/canvas_course_provision_job_response_success.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_request_status": "Success", 3 | "job_id": "canvas.courseprovision.12345.1383330151057" 4 | } 5 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_official_sections_job_response_success.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_request_status": "Success", 3 | "job_id": "canvas.officialsections.12345.1383330151057" 4 | } 5 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/delegate_student_img.html: -------------------------------------------------------------------------------- 1 |
2 | -------------------------------------------------------------------------------- /src/icons/blue-bullet.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/icons/white-bullet.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/react/components/VerticalSpacer.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | export default function VerticalSpacer() { 4 | return
; 5 | } 6 | -------------------------------------------------------------------------------- /config.ru: -------------------------------------------------------------------------------- 1 | # This file is used by Rack-based servers to start the application. 2 | 3 | require ::File.expand_path('../config/environment', __FILE__) 4 | run Calcentral::Application 5 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/emergency_contacts_empty.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_course_provision_job_response_error.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_request_status": "Error", 3 | "job_id": null, 4 | "error": "Unable to create background job" 5 | } 6 | -------------------------------------------------------------------------------- /src/icons/disc-active.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/ItemUpdated.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | .ItemUpdated { 4 | color: $color-dove-gray; 5 | } 6 | -------------------------------------------------------------------------------- /src/react/stylesheets/student_resources.scss: -------------------------------------------------------------------------------- 1 | // Blocks 2 | .cc-react-student-resources-list { 3 | margin-bottom: 8px; 4 | &:last-child { 5 | margin-bottom: 0; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /src/redux/actions/configActions.js: -------------------------------------------------------------------------------- 1 | import { SET_CONFIG } from '../action-types'; 2 | 3 | export const setConfig = config => ({ 4 | type: SET_CONFIG, 5 | value: config, 6 | }); 7 | -------------------------------------------------------------------------------- /src/icons/disc-inactive.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/icons/triangle-up.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/react/angularWrappers/index.js: -------------------------------------------------------------------------------- 1 | import './NgActiveServiceAlerts'; 2 | import './NgAlertBar'; 3 | import './NgFindUserAuth'; 4 | import './NgMainContent'; 5 | import './NgServiceAlert'; 6 | -------------------------------------------------------------------------------- /src/react/components/_academics/AcademicSummary/SectionIncompleteGradingStatus.scss: -------------------------------------------------------------------------------- 1 | td.SectionIncompleteGradingStatus__table_cell { 2 | padding-bottom: 10px; 3 | padding-top: 0; 4 | } 5 | -------------------------------------------------------------------------------- /fixtures/json/canvas_put_login_sis_user_id.json: -------------------------------------------------------------------------------- 1 | { 2 | "account_id": 90242, 3 | "id": 2963066, 4 | "sis_user_id": "UID:211159", 5 | "unique_id": "211159", 6 | "user_id": 3057506 7 | } 8 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/language_post.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Language Succesfully Posted for emplid 25753380 for Language code EN 4 | 5 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_finaid_permissions.scss: -------------------------------------------------------------------------------- 1 | .cc-widget-permissions { 2 | .cc-button-finaid-permissions { 3 | display: inline-block; 4 | margin-top: 10px; 5 | } 6 | } 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_row_collapse_bug.scss: -------------------------------------------------------------------------------- 1 | // Row collapse bug by foundation 2 | .row.collapse { 3 | .column, .columns { 4 | padding-left: 0; 5 | padding-right: 0; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /src/react/types.js: -------------------------------------------------------------------------------- 1 | import PropTypes from 'prop-types'; 2 | 3 | const apiLink = PropTypes.shape({ 4 | name: PropTypes.string, 5 | }); 6 | 7 | export default { 8 | apiLink, 9 | }; 10 | -------------------------------------------------------------------------------- /app/models/campus_solutions/campus_solutions_id_required.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module CampusSolutionsIdRequired 3 | def is_cs_id_required? 4 | true 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /src/assets/templates/academics_status_holds_blocks.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 | -------------------------------------------------------------------------------- /app/controllers/server_runtime_controller.rb: -------------------------------------------------------------------------------- 1 | class ServerRuntimeController < ApplicationController 2 | 3 | def get_info 4 | render :json => ServerRuntime.get_settings.to_json 5 | end 6 | 7 | end 8 | -------------------------------------------------------------------------------- /src/components/SplashContainer.module.scss: -------------------------------------------------------------------------------- 1 | .SplashContainer { 2 | margin: 0 auto; 3 | background-color: white; 4 | max-width: 450px; 5 | padding: 20px 20px 30px; 6 | border-radius: 5px; 7 | } 8 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/CompletedTasks/CategoryTitle.module.scss: -------------------------------------------------------------------------------- 1 | .title { 2 | font-size: 15px; 3 | padding: 25px 10px 0; 4 | 5 | span { 6 | font-weight: normal; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /app/models/campus_solutions/holds_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module HoldsFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_holds 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_official_sections_update_status_completed.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_id": "canvas.officialsections.12345.1383330151057", 3 | "jobStatus": "Completed", 4 | "percent_complete": 1.00 5 | } 6 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_official_sections_update_status_processing.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_id": "canvas.officialsections.12345.1383330151057", 3 | "jobStatus": "Processing", 4 | "percent_complete": 0.55 5 | } 6 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/IncompleteFinancialAidTasks/AidYearTasks.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .aidYear { 4 | border-bottom: 1px solid $color-silver; 5 | } 6 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/MoreDetails.scss: -------------------------------------------------------------------------------- 1 | .MoreDetails { 2 | li { 3 | margin-top: 20px; 4 | } 5 | 6 | li + li { 7 | margin-top: 5px; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /app/models/campus_solutions/finaid_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module FinaidFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_fin_aid 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/work_experience.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully posted the Work Experience for emplid 13320458 for employer 9000000008 4 | 5 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/finaid_errored.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | An error occurred while trying to retrieve your data. 4 |
5 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/types.js: -------------------------------------------------------------------------------- 1 | export const chargeTypes = new Set(['Charge', 'Refund']); 2 | export const paymentTypes = new Set(['Financial Aid', 'Payment', 'Adjustment', 'Deposit']); 3 | -------------------------------------------------------------------------------- /src/react/helpers/gpa.js: -------------------------------------------------------------------------------- 1 | export const formatGpaCumulative = (gpa) => { 2 | if (gpa.role === 'law') { 3 | return 'N/A'; 4 | } else { 5 | return parseFloat(gpa.cumulativeGpa).toFixed(3); 6 | } 7 | }; 8 | -------------------------------------------------------------------------------- /bin/rails: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # Generated by "rails new ProjectName" 3 | 4 | APP_PATH = File.expand_path('../../config/application', __FILE__) 5 | require_relative '../config/boot' 6 | require 'rails/commands' 7 | -------------------------------------------------------------------------------- /config/environment.rb: -------------------------------------------------------------------------------- 1 | # Load the rails application 2 | require File.expand_path('../application', __FILE__) 3 | 4 | require 'openssl' 5 | 6 | # Initialize the rails application 7 | Calcentral::Application.initialize! 8 | -------------------------------------------------------------------------------- /lib/proxies/tls12.rb: -------------------------------------------------------------------------------- 1 | module Proxies 2 | module Tls12 3 | def request_options(opts = {}) 4 | { 5 | ssl_version: 'TLSv1_2' 6 | }.deep_merge super(opts) 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_course_provision_status_not_found.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_id": "canvas.courseprovision.12345.1383330151057", 3 | "jobStatus": "Error", 4 | "error": "Unable to find course provisioning job" 5 | } 6 | -------------------------------------------------------------------------------- /spec/controllers/my_campus_links_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe MyCampusLinksController do 2 | it_should_behave_like 'a user authenticated api endpoint' do 3 | let(:make_request) { get :get_feed } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /src/icons/triangle-down.svg: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/bConnected/NoBconnected.scss: -------------------------------------------------------------------------------- 1 | .NoBconnected { 2 | p { 3 | margin-bottom: 10px; 4 | } 5 | 6 | .NoBconnected__revealed-text { 7 | margin-top: 10px; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /app/models/campus_solutions/committees_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module CommitteesFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_committees 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /config/boot.rb: -------------------------------------------------------------------------------- 1 | require 'rubygems' 2 | 3 | # Set up gems listed in the Gemfile. 4 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 5 | 6 | require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE']) 7 | -------------------------------------------------------------------------------- /db/migrate/20140714093636_add_event_id_to_calendar_queue.rb: -------------------------------------------------------------------------------- 1 | class AddEventIdToCalendarQueue < ActiveRecord::Migration 2 | 3 | def change 4 | add_column(:class_calendar_queue, :event_id, :string) 5 | end 6 | 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/delegate_access_create.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | SUCCESS. USERID 12346 Created Successfully and Assigned Security 4 | 5 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/ethnicity_post.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully posted the Ethnicity for emplid 25738808 4 | 5 | -------------------------------------------------------------------------------- /public/dummy/json/status_loggedout.json: -------------------------------------------------------------------------------- 1 | { 2 | "isBasicAuthEnabled": true, 3 | "isLoggedIn": false, 4 | "features": { 5 | "myFinAid": true, 6 | "textbooks": true, 7 | "videos": true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/react/stylesheets/useful.scss: -------------------------------------------------------------------------------- 1 | .clearfix-container { 2 | &::before { 3 | content: " "; 4 | display: table; 5 | } 6 | &::after { 7 | content: " "; 8 | display: table; 9 | clear: both; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /app/controllers/concerns/disallow_advisor_view_as.rb: -------------------------------------------------------------------------------- 1 | module DisallowAdvisorViewAs 2 | # Indicates that controller endpoints are unavailable to advisors. 3 | def allow_if_advisor_view_as? 4 | false 5 | end 6 | 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/sir_response.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Application program data successfully posted for 9000006545 4 | 5 | -------------------------------------------------------------------------------- /spec/models/berkeley/course_spec.rb: -------------------------------------------------------------------------------- 1 | describe Berkeley::Course do 2 | let(:course_id) { "compsci-9a-2014-D" } 3 | subject { Berkeley::Course.new(:course_id => course_id) } 4 | its(:course_id) { should eq course_id } 5 | end 6 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_disabled_links.scss: -------------------------------------------------------------------------------- 1 | a[disabled] { 2 | color: $body-font-color; 3 | pointer-events: none; 4 | 5 | &:hover, &:focus { 6 | cursor: default; 7 | text-decoration: none; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile_img.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /src/react/helpers/filters.js: -------------------------------------------------------------------------------- 1 | export function usdFilter(value) { 2 | return '$ ' + value.toLocaleString('en-US', { 3 | style: 'currency', 4 | currency: 'USD', 5 | minimumFractionDigits: 2 6 | }).slice(1); 7 | } 8 | -------------------------------------------------------------------------------- /src/redux/actions/routeActions.js: -------------------------------------------------------------------------------- 1 | import { SET_CURRENT_ROUTE_PROPERTIES } from '../action-types'; 2 | 3 | export const setCurrentRouteProperties = props => ({ 4 | type: SET_CURRENT_ROUTE_PROPERTIES, 5 | value: props, 6 | }); 7 | -------------------------------------------------------------------------------- /app/models/campus_solutions/delegate_students_expiry.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module DelegateStudentsExpiry 3 | def self.expire(uid=nil) 4 | CampusSolutions::DelegateStudents.expire uid 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/user/owned.rb: -------------------------------------------------------------------------------- 1 | module User 2 | class Owned 3 | attr_reader :user 4 | 5 | def initialize(user) 6 | @user = user 7 | end 8 | 9 | def uid 10 | user.uid 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /db/migrate/20170307233607_add_splash_to_service_alerts.rb: -------------------------------------------------------------------------------- 1 | class AddSplashToServiceAlerts < ActiveRecord::Migration 2 | def change 3 | add_column :service_alerts, :splash, :boolean, null: false, default: false 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_alerts.scss: -------------------------------------------------------------------------------- 1 | .cc-alerts-law { 2 | background: $color-gallery; 3 | border: 1px $color-silver solid; 4 | margin-bottom: 20px; 5 | padding: 15px; 6 | h3 { 7 | margin-bottom: 0; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_campus.scss: -------------------------------------------------------------------------------- 1 | .cc-page-campus { 2 | overflow: hidden; 3 | .cc-widget { 4 | width: 60%; 5 | } 6 | @media #{$small-only} { 7 | .cc-widget { 8 | width: 100%; 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/finances_links.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |

Financial Resources

4 |
5 | 6 |
7 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/AlumniHomepage/AlumniHomepage.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .messageText { 4 | font-size: 13px; 5 | } 6 | 7 | .buttonDiv { 8 | text-align: center; 9 | } 10 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/billingItemViews.js: -------------------------------------------------------------------------------- 1 | export const BILLING_VIEW_ALL = 'Show All'; 2 | export const BILLING_VIEW_UNPAID = 'Unpaid Balance'; 3 | export const BILLING_VIEW_PAYMENTS_AID = 'Payments and Aid'; 4 | -------------------------------------------------------------------------------- /src/react/helpers/roles.js: -------------------------------------------------------------------------------- 1 | export const hasRoleInList = (role, list) => list.find(name => name === role); 2 | 3 | export const activeRoles = (rolesObject) => Object.keys(rolesObject).filter(name => rolesObject[name] ? name : null); 4 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | # Ignore all non-JS files 2 | !**/*.js 3 | 4 | # Ignore non-relevant directories 5 | src/assets/javascripts/angularlib/** 6 | src/assets/javascripts/lib/** 7 | public/** 8 | coverage/** 9 | node_modules/** 10 | vendor/** -------------------------------------------------------------------------------- /app/models/campus_solutions/enrollment_card_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module EnrollmentCardFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_enrollment_card 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/language_delete.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Language Successfully deleted for individual 25753380 for Language code LEN 4 | 5 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/person_name.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully posted the name for emplid 05649055 with the name type LEG 4 | 5 | -------------------------------------------------------------------------------- /public/dummy/json/canvas_official_sections_update_status_error.json: -------------------------------------------------------------------------------- 1 | { 2 | "job_id": "canvas.officialsections.12345.1383330151057", 3 | "jobStatus": "Error", 4 | "percent_complete": 0.64, 5 | "error": "Something went wrong" 6 | } 7 | -------------------------------------------------------------------------------- /public/robots.txt: -------------------------------------------------------------------------------- 1 | # See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file 2 | # 3 | # To ban all spiders from the entire site uncomment the next two lines: 4 | # User-Agent: * 5 | # Disallow: / 6 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/widgets/alertsController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Alerts controller 5 | */ 6 | angular 7 | .module('calcentral.controllers') 8 | .controller('AlertsController', function() {}); 9 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/chargeStatuses.js: -------------------------------------------------------------------------------- 1 | export const CHARGE_OVERDUE = 'Overdue'; 2 | export const CHARGE_DUE = 'Due Now'; 3 | export const CHARGE_NOT_DUE = 'Not Yet Due'; 4 | export const CHARGE_PAID = 'Paid'; 5 | -------------------------------------------------------------------------------- /app/models/campus_solutions/student_lookup_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module StudentLookupFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_advisor_student_lookup 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/campus_solutions/student_success_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module StudentSuccessFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.advising_student_success 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /config/initializers/mime_types.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new mime types for use in respond_to blocks: 4 | Mime::Type.register 'text/plain', :txt 5 | Mime::Type.register 'image/jpeg', :jpeg 6 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/IncompleteTasks/ByCategory.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .container { 4 | margin-top: 10px; 5 | 6 | & + .container { 7 | margin-top: 0; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/react/helpers/state.js: -------------------------------------------------------------------------------- 1 | import update from 'immutability-helper'; 2 | 3 | export function updateStateProperty(component, stateChanges) { 4 | const newState = update(component.state, stateChanges); 5 | component.setState(newState); 6 | } 7 | -------------------------------------------------------------------------------- /db/migrate/20140815155903_add_latest_term_enrollment_csv_set.rb: -------------------------------------------------------------------------------- 1 | class AddLatestTermEnrollmentCsvSet < ActiveRecord::Migration 2 | def change 3 | add_column(:canvas_synchronization, :latest_term_enrollment_csv_set, :datetime) 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /src/assets/images/svg/select_arrow_20x28.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Category.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .category { 4 | display: block; 5 | } 6 | 7 | .categoryWithBorder { 8 | border-bottom: 1px solid $color-silver; 9 | } 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/country_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class CountryController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::Country 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/my_badges_controller.rb: -------------------------------------------------------------------------------- 1 | class MyBadgesController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render :json => MyBadges::Merged.from_session(session).get_feed_as_json 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/campus_solutions/emergency_contacts_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module EmergencyContactsFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_profile_emergency_contacts 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/my_academics/advising_academic_planner_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module MyAcademics 2 | module AdvisingAcademicPlannerFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.advising_academic_planner 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /config/initializers/filter_parameter_logging.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Configure sensitive parameters which will be filtered from the log file. 4 | Rails.application.config.filter_parameters += [:password] 5 | -------------------------------------------------------------------------------- /fixtures/json/canvas_start_provisioning_report_users.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 9, 3 | "parameters": { 4 | "users": "1" 5 | }, 6 | "progress": 0, 7 | "status": "running", 8 | "report": "provisioning_csv", 9 | "file_url": null 10 | } 11 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/transfer_credit_type_units.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 |
5 | -------------------------------------------------------------------------------- /app/controllers/concerns/disallow_classic_view_as.rb: -------------------------------------------------------------------------------- 1 | module DisallowClassicViewAs 2 | # Indicates that controller endpoints are unavailable to classic View-As for service support staff. 3 | def allow_if_classic_view_as? 4 | false 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/controllers/stats_controller.rb: -------------------------------------------------------------------------------- 1 | class StatsController < ApplicationController 2 | 3 | def get_stats 4 | render :json => { 5 | :threads => Thread.list.size, 6 | :jms_worker => JmsWorker.ping 7 | } 8 | end 9 | 10 | end 11 | -------------------------------------------------------------------------------- /config/initializers/in_memory_database.rb: -------------------------------------------------------------------------------- 1 | def in_memory_database? 2 | Rails.env == "test" and Rails.configuration.database_configuration['test']['adapter'] == 'sqlite3' 3 | end 4 | 5 | if in_memory_database? 6 | load "#{Rails.root}/db/schema.rb" 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/json/hub_v2_not_found.json: -------------------------------------------------------------------------------- 1 | { 2 | "apiResponse": { 3 | "httpStatus": { 4 | "code": "404", 5 | "description": "Not Found", 6 | "formalDescription": "No data found for id = 1234" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/prior_work_delete.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully deleted the Work Experience for individual 3030825097 for sequence number 7 4 | 5 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/billingDetailsController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.controllers').controller('BillingDetailsController', function(apiService) { 4 | apiService.util.setTitle('My Finances'); 5 | }); 6 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/IncompleteTasks/IncompleteDueSoonBadges.module.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../../assets/stylesheets/colors.scss'; 2 | .badge { 3 | color: $color-san-juan; 4 | background-color: $color-mystic; 5 | padding: 3px; 6 | } 7 | -------------------------------------------------------------------------------- /app/models/campus_solutions/advising_expiry.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module AdvisingExpiry 3 | def self.expire(uid=nil) 4 | [Advising::MyAdvising].each do |klass| 5 | klass.expire uid 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /db/migrate/20161026183144_add_canvas_site_name_to_canvas_site_mailing_lists.rb: -------------------------------------------------------------------------------- 1 | class AddCanvasSiteNameToCanvasSiteMailingLists < ActiveRecord::Migration 2 | def change 3 | add_column :canvas_site_mailing_lists, :canvas_site_name, :string 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /fixtures/json/canvas_course_settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "allow_student_discussion_topics": true, 3 | "allow_student_forum_attachments": false, 4 | "allow_student_discussion_editing": true, 5 | "grading_standard_enabled": true, 6 | "grading_standard_id": 0 7 | } 8 | -------------------------------------------------------------------------------- /src/assets/templates/accessibility.html: -------------------------------------------------------------------------------- 1 | 5 | -------------------------------------------------------------------------------- /src/components/Pagination.module.scss: -------------------------------------------------------------------------------- 1 | @import '../react/stylesheets/variables'; 2 | 3 | .Pagination { 4 | display: flex; 5 | justify-content: center; 6 | align-items: center; 7 | } 8 | 9 | .currentState { 10 | margin: 0 $large-spacing; 11 | } 12 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItemsTable/BillingItemsTable.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | @media only screen and (min-width: $small-breakpoint) { 4 | .BillingItemsTable { 5 | margin-top: 20px; 6 | } 7 | } -------------------------------------------------------------------------------- /app/controllers/campus_solutions/currency_code_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class CurrencyCodeController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::CurrencyCode 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/language_code_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class LanguageCodeController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::LanguageCode 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/my_groups_controller.rb: -------------------------------------------------------------------------------- 1 | class MyGroupsController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render :json => MyGroups::Merged.from_session(session).get_feed_as_json 7 | end 8 | 9 | end 10 | -------------------------------------------------------------------------------- /app/models/campus_solutions/financial_aid_compare_awards_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module FinancialAidCompareAwardsFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_fin_aid_award_compare 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /config/initializers/session_store.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | Calcentral::Application.config.session_store :cookie_store, 4 | :key => '_calcentral_session', 5 | :expire_after => Settings.application.session_expiration 6 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/name_delete.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully made the name for individual 25738808 with the name type LEG inactive 4 | 5 | -------------------------------------------------------------------------------- /public/dummy/json/textbooks_error.json: -------------------------------------------------------------------------------- 1 | { 2 | "body":"Currently, we can't reach the bookstore. Check again later for updates, or contact the ASUC book store.", 3 | "statusCode":503 4 | } 5 | -------------------------------------------------------------------------------- /app/controllers/concerns/current_user_concern.rb: -------------------------------------------------------------------------------- 1 | module CurrentUserConcern 2 | extend ActiveSupport::Concern 3 | 4 | included do 5 | private 6 | 7 | def user 8 | @user ||= User::Current.new(session['user_id']) 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/controllers/my_advising_controller.rb: -------------------------------------------------------------------------------- 1 | class MyAdvisingController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render json: Advising::MyAdvising.from_session(session).get_feed_as_json 7 | end 8 | 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/my_classes_controller.rb: -------------------------------------------------------------------------------- 1 | class MyClassesController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render :json => MyClasses::Merged.from_session(session).get_feed_as_json 7 | end 8 | 9 | end 10 | -------------------------------------------------------------------------------- /app/models/campus_solutions/billing/billing_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module Billing 3 | module BillingFeatureFlagged 4 | def is_feature_enabled 5 | Settings.features.cs_billing 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /db/migrate/20140722172233_create_canvas_synchronization_table.rb: -------------------------------------------------------------------------------- 1 | class CreateCanvasSynchronizationTable < ActiveRecord::Migration 2 | def change 3 | create_table :canvas_synchronization do |t| 4 | t.datetime :last_guest_user_sync 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/errorController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Error controller 5 | */ 6 | angular.module('calcentral.controllers').controller('ErrorController', function(apiService) { 7 | apiService.util.setTitle('Error'); 8 | }); 9 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile/unavailable.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | Your information is currently unavailable. Please try again later. 4 |
5 | -------------------------------------------------------------------------------- /src/react/components/_academics/ClassInformationCard/ClassInformationCard.module.scss: -------------------------------------------------------------------------------- 1 | @mixin title2 { 2 | font-size: 15px; 3 | line-height: 17px; 4 | } 5 | 6 | .title { 7 | @include title2; 8 | } 9 | 10 | .catalogNumber { 11 | font-weight: normal; 12 | } 13 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/ethnicity_setup_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class EthnicitySetupController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::EthnicitySetup 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/state_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class StateController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough(CampusSolutions::State, {country: params['country']}) 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /lib/errors/client_error.rb: -------------------------------------------------------------------------------- 1 | module Errors 2 | # Use to raise errors caused by invalid client interactions. 3 | # Examples include requests with invalid parameters, or requests that are unauthenticated or unauthorized. 4 | class ClientError < StandardError 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TasksContext.js: -------------------------------------------------------------------------------- 1 | import { createContext } from 'react'; 2 | 3 | const TasksContext = createContext({ 4 | hasFocus: true, 5 | selectedItem: '', 6 | setSelectedItem: () => {}, 7 | }); 8 | 9 | export default TasksContext; 10 | -------------------------------------------------------------------------------- /app/controllers/my_academic_records_controller.rb: -------------------------------------------------------------------------------- 1 | class MyAcademicRecordsController < ApplicationController 2 | before_action :api_authenticate 3 | 4 | def get_feed 5 | render json: MyAcademics::AcademicRecords.from_session(session).get_feed_as_json 6 | end 7 | end 8 | 9 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/messaging_inactive.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class MessagingInactive < Messaging 4 | 5 | def self.MESSAGE_IDS 6 | { inactiveLoanHistory: 'INAC' } 7 | end 8 | 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/ethnicity_delete.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Successfully deleted the ethnic code for Individual 25753380 for ethnic code ASIANIND 4 | 5 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_oldie.scss: -------------------------------------------------------------------------------- 1 | // Message for oldIE 2 | .cc-old-ie { 3 | margin-bottom: 20px !important; 4 | a { 5 | color: $color-white; 6 | text-decoration: underline; 7 | &:hover, &:focus { 8 | text-decoration: none; 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/templates/academics_higher_degree_committees.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 | -------------------------------------------------------------------------------- /src/icons/timeline-top-cap.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/models/campus_solutions/profile_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module ProfileFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_profile 5 | end 6 | alias_method(:is_cs_profile_feature_enabled, :is_feature_enabled) 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/messaging_general.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class MessagingGeneral < Messaging 4 | 5 | def self.MESSAGE_IDS 6 | { estimatedPaymentDisclaimer: 'DSCL' } 7 | end 8 | 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/user/academics/status/law.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | module Status 4 | class Law < Postgraduate 5 | def enrolled? 6 | registration_records.find(&:law?).enrolled? 7 | end 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/college_scheduler_url.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | College Scheduler 4 | HTTPS://BERKELEYDEV.COLLEGESCHEDULER.COM/INDEX.ASPX?TICKET=C0EC99DE53574F78906FB21169B2045C_SSO 5 | 6 | -------------------------------------------------------------------------------- /public/oauth/README.md: -------------------------------------------------------------------------------- 1 | # OAuth images 2 | 3 | for 3rd party OAuth pages 4 | 5 | ## URL references 6 | 7 | - https://calcentral.berkeley.edu/oauth/calcentral_authlogo_120x120.png 8 | 9 | Can also be referenced on the dev and qa servers for dev, qa, and localhost environments. 10 | -------------------------------------------------------------------------------- /src/functions/isPresent.js: -------------------------------------------------------------------------------- 1 | // Used as a filter function isPresent removes items that are falsy 2 | // 3 | // const result = [0, 1, 2, 3, 4, null, false].filter(isPresent) 4 | // console.log(result) // => [1, 2, 3, 4] 5 | export default function isPresent(item) { 6 | return item; 7 | } 8 | -------------------------------------------------------------------------------- /src/icons/timeline-bottom-cap.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /src/react/components/_academics/AcademicSummary/AcademicSummary.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../assets/stylesheets/colors.scss'; 2 | 3 | .AcademicSummary__body { 4 | padding: 15px; 5 | padding-top: 0; 6 | 7 | h3 { 8 | padding: 0; 9 | padding-top: 15px; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/ChargeItem.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | .TableColumn__due.ChargeItem__due { 4 | flex-direction: column; 5 | align-items: flex-end; 6 | color: $color-tundora; 7 | padding-right: 12px; 8 | } 9 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/dueLabel.js: -------------------------------------------------------------------------------- 1 | import formatDate from 'functions/formatDate'; 2 | 3 | const dueLabel = (date) => { 4 | if (date !== null) { 5 | return `Due ${ formatDate(date) }`; 6 | } 7 | }; 8 | 9 | export default dueLabel; 10 | -------------------------------------------------------------------------------- /app/controllers/enrollment_verification_controller.rb: -------------------------------------------------------------------------------- 1 | class EnrollmentVerificationController < ApplicationController 2 | before_action :api_authenticate 3 | 4 | def get_feed 5 | render json: MyAcademics::EnrollmentVerification.from_session(session).get_feed_as_json 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /db/migrate/20130222213829_change_oauth2_data.rb: -------------------------------------------------------------------------------- 1 | class ChangeOauth2Data < ActiveRecord::Migration 2 | def up 3 | add_column "oauth2_data", :app_data, :text 4 | end 5 | 6 | def down 7 | rename_column "oauth2_data", :app_data, :app_data_201322221382900 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/higher_one_url.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | https://commerce.cashnet.com/UCBpaytest?eusername=8062064084e9a8dff7a181266a3ed11e28b80eb30ab4fd84b9bc4de92394d884 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /script/logrotate.conf: -------------------------------------------------------------------------------- 1 | # Backup of the log rotatation policy on IST servers. 2 | 3 | /home/app_calcentral/calcentral/log/*.log { 4 | daily 5 | rotate 60 6 | missingok 7 | compress 8 | create 600 app_calcentral app_calcentral 9 | delaycompress 10 | copytruncate 11 | } 12 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/translate_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class TranslateController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough(CampusSolutions::Translate, {field_name: params['field_name']}) 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/sir_statuses_controller.rb: -------------------------------------------------------------------------------- 1 | class SirStatusesController < ApplicationController 2 | before_action :api_authenticate, :require_released_admit_role 3 | 4 | def get_feed 5 | render json: CampusSolutions::Sir::SirStatuses.from_session(session).get_feed 6 | end 7 | 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/service_alerts.rb: -------------------------------------------------------------------------------- 1 | FactoryBot.define do 2 | factory :service_alert, class: "ServiceAlert" do 3 | title { "CalCentral is the Bees Knees" } 4 | body { "

Also, we'll have to be down for an upgrade on Sunday

" } 5 | publication_date { "2020-10-04" } 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/uidErrorController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * UID Error controller 5 | */ 6 | angular.module('calcentral.controllers').controller('uidErrorController', function(apiService) { 7 | apiService.util.setTitle('Unrecognized Log-in'); 8 | }); 9 | -------------------------------------------------------------------------------- /src/react/components/ErrorMessage.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .errorMessage { 4 | display: flex; 5 | align-items: flex-start; 6 | margin-top: $medium-spacing; 7 | 8 | img { 9 | margin-right: 5px; 10 | padding-top: 3px; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/react/components/_finances/AwardComparison/SelectedDateContext.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | const SelectedDateContext = React.createContext({ 4 | selectedDate: String, 5 | }); 6 | SelectedDateContext.displayName = 'SelectedDateContext'; 7 | 8 | export default SelectedDateContext; 9 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/address_label_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class AddressLabelController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough(CampusSolutions::AddressLabel, {country: params['country']}) 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/messaging_prior_enrollment.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class MessagingPriorEnrollment < Messaging 4 | 5 | def self.MESSAGE_IDS 6 | { enrolledPriorToFall2016: '2168' } 7 | end 8 | 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/user/academics/status/graduate.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | module Status 4 | class Graduate < Postgraduate 5 | def enrolled? 6 | registration_records.find(&:graduate?).enrolled? 7 | end 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TaskDetail.module.scss: -------------------------------------------------------------------------------- 1 | .wrapper { 2 | padding: 10px 20px 25px 40px; 3 | } 4 | 5 | .description { 6 | color: #474747; 7 | } 8 | 9 | .actionLink { 10 | width: 100%; 11 | display: block; 12 | text-align: center; 13 | margin-top: 10px; 14 | } 15 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | ; editorconfig.org 2 | root = true 3 | 4 | [*] 5 | charset = utf-8 6 | end_of_line = lf 7 | insert_final_newline = true 8 | indent_style = space 9 | indent_size = 2 10 | trim_trailing_whitespace = true 11 | 12 | [*.md] 13 | max_line_length = 80 14 | trim_trailing_whitespace = false 15 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/confidential_student_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class ConfidentialStudentController < CampusSolutionsController 3 | 4 | def get_message 5 | json_passthrough CampusSolutions::ConfidentialStudentMessage 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/new_admit_resources_controller.rb: -------------------------------------------------------------------------------- 1 | class NewAdmitResourcesController < ApplicationController 2 | before_action :api_authenticate, :require_released_admit_role 3 | 4 | def get_feed 5 | render json: CampusSolutions::NewAdmitResources.from_session(session).get_feed 6 | end 7 | 8 | end 9 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/glossary_aid_years.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class GlossaryAidYears < Glossary 4 | 5 | def query 6 | EdoOracle::FinancialAid::Queries.get_loan_history_glossary_aid_years 7 | end 8 | 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /fixtures/json/google_events_delete_nonexistent.json: -------------------------------------------------------------------------------- 1 | { 2 | "error": { 3 | "errors": [ 4 | { 5 | "domain": "global", 6 | "reason": "notFound", 7 | "message": "Not Found" 8 | } 9 | ], 10 | "code": 404, 11 | "message": "Not Found" 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/configuration/qConfiguration.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Configure $qProvider to suppress errors on unhandled promise rejections 5 | */ 6 | angular.module('calcentral.config').config(function($qProvider) { 7 | $qProvider.errorOnUnhandledRejections(false); 8 | }); 9 | -------------------------------------------------------------------------------- /src/react/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": ["plugin:react/recommended"], 3 | "parserOptions": { 4 | "ecmaFeatures": { 5 | "jsx": true 6 | }, 7 | "sourceType": "module" 8 | }, 9 | "settings": { 10 | "react": { 11 | "version": "detect" 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TaskHeader.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | @import 'src/react/stylesheets/mixins'; 3 | 4 | .taskHeader { 5 | padding: $medium-spacing; 6 | padding-right: 20px; 7 | display: flex; 8 | justify-content: space-between; 9 | } 10 | -------------------------------------------------------------------------------- /src/redux/reducers/currentUID.js: -------------------------------------------------------------------------------- 1 | import { SET_CONFIG } from '../action-types'; 2 | 3 | export default function CurrentUIDReducer(state = '', action) { 4 | if (action.type === SET_CONFIG && action.value.uid !== undefined) { 5 | return action.value.uid; 6 | } 7 | 8 | return state; 9 | } 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/emergency_contacts_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class EmergencyContactsController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::EmergencyContacts, user_id: session['user_id'] 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/faculty_resources_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class FacultyResourcesController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::FacultyResources, user_id: session['user_id'] 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/student_resources_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class StudentResourcesController < CampusSolutionsController 3 | 4 | def get 5 | json_passthrough CampusSolutions::StudentResources, user_id: session['user_id'] 6 | end 7 | 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/my_standings_controller.rb: -------------------------------------------------------------------------------- 1 | class MyStandingsController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | 5 | def get_feed 6 | render json: MyAcademics::MyStandings.from_session(session).get_feed_as_json 7 | end 8 | 9 | end 10 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/glossary_cumulative.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class GlossaryCumulative < Glossary 4 | 5 | def query 6 | EdoOracle::FinancialAid::Queries.get_loan_history_glossary_cumulative 7 | end 8 | 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/links/link_category.rb: -------------------------------------------------------------------------------- 1 | module Links 2 | class LinkCategory < ApplicationRecord 3 | 4 | has_and_belongs_to_many :link_sections 5 | 6 | validates :name, :presence => true 7 | validates :slug, :presence => true 8 | validates_uniqueness_of :name, :slug 9 | 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/notifications/educ_level_translator.rb: -------------------------------------------------------------------------------- 1 | module Notifications 2 | class EducLevelTranslator 3 | 4 | def translate(educ_level) 5 | if (educ_level.eql? "Adv Doc") 6 | educ_level = "Advanced Doctoral" 7 | end 8 | educ_level 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /fixtures/json/canvas_start_provisioning_report_courses.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 39050, 3 | "parameters": { 4 | "courses": "1", 5 | "enrollment_term": "sis_term_id:TERM:2015-B" 6 | }, 7 | "progress": 0, 8 | "status": "running", 9 | "report": "provisioning_csv", 10 | "file_url": null 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/delegateWelcomeController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Welcome newly assigned delegates 5 | */ 6 | angular.module('calcentral.controllers').controller('DelegateWelcomeController', function(apiService) { 7 | apiService.util.setTitle('Welcome'); 8 | }); 9 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/splashController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | const SplashController = function(apiService) { 4 | apiService.util.setTitle('Home'); 5 | }; 6 | 7 | angular 8 | .module('calcentral.controllers') 9 | .controller('SplashController', SplashController); 10 | -------------------------------------------------------------------------------- /src/components/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": ["plugin:react/recommended"], 3 | "parserOptions": { 4 | "ecmaFeatures": { 5 | "jsx": true 6 | }, 7 | "sourceType": "module" 8 | }, 9 | "settings": { 10 | "react": { 11 | "version": "detect" 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/react/components/_academics/StudentProfile/MissingPhoto.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import './MissingPhoto.scss'; 4 | 5 | const MissingPhoto = () => ( 6 |
7 | 8 |
9 | ); 10 | 11 | export default MissingPhoto; 12 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/NotificationsCard/MessageHeader.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | .messageHeader { 4 | display: flex; 5 | font-size: 12px; 6 | 7 | .icon { 8 | font-size: 20px; 9 | min-width: 30px; 10 | color: $color-casper; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/IncompleteTasks/CategoryHeader.module.scss: -------------------------------------------------------------------------------- 1 | .categoryHeader { 2 | display: flex; 3 | justify-content: space-between; 4 | align-items: center; 5 | padding: 10px; 6 | padding-right: 15px; 7 | } 8 | 9 | .aidYearLabel { 10 | font-weight: normal; 11 | } 12 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "EditorConfig.editorconfig", 4 | "esbenp.prettier-vscode", 5 | "formulahendry.auto-rename-tag", 6 | "wayou.vscode-todo-highlight", 7 | "shd101wyy.markdown-preview-enhanced", 8 | "DavidAnson.vscode-markdownlint", 9 | ] 10 | } 11 | -------------------------------------------------------------------------------- /app/controllers/my_registrations_controller.rb: -------------------------------------------------------------------------------- 1 | class MyRegistrationsController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render json: MyRegistrations::Statuses.from_session(session).get_feed_as_json 7 | end 8 | 9 | end 10 | -------------------------------------------------------------------------------- /app/models/links/user_role.rb: -------------------------------------------------------------------------------- 1 | module Links 2 | # TODO rename this class to LinkRole, it has nothing to do with users. It's used only as part of the Links::MyCampusLinks feature. 3 | # Renaming will require a db migration. 4 | class UserRole < ApplicationRecord 5 | has_and_belongs_to_many :links 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/json/canvas_start_provisioning_report_sections.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 11938, 3 | "parameters": { 4 | "enrollment_term": "sis_term_id:TERM:2013-D", 5 | "sections": "1" 6 | }, 7 | "progress": 0, 8 | "status": "running", 9 | "report": "provisioning_csv", 10 | "file_url": null 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_logo.scss: -------------------------------------------------------------------------------- 1 | .cc-svg-calcentral-logo-gold { 2 | fill: $color-buttercup; 3 | } 4 | .cc-svg-calcentral-logo-white { 5 | fill: $color-white; 6 | } 7 | 8 | @media print { 9 | .cc-svg-calcentral-logo-gold, .cc-svg-calcentral-logo-white { 10 | fill: $color-black; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/icons/not-yet-due.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /src/react/components/_academics/ClassInformationCard/CrossListings.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | @mixin title2 { 4 | font-size: 15px; 5 | line-height: 17px; 6 | } 7 | 8 | .crossListings { 9 | margin-bottom: 20px; 10 | } 11 | .title { 12 | @include title2; 13 | } 14 | -------------------------------------------------------------------------------- /app/controllers/my_eft_enrollment_controller.rb: -------------------------------------------------------------------------------- 1 | class MyEftEnrollmentController < ApplicationController 2 | include AllowDelegateViewAs 3 | 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: Eft::MyEftEnrollment.from_session(session).get_feed_as_json 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/berkeley/course.rb: -------------------------------------------------------------------------------- 1 | module Berkeley 2 | # Represents campus course for Pundit authorization performed by Berkeley::CoursePolicy 3 | class Course 4 | 5 | attr_accessor :course_id 6 | 7 | def initialize(options = {}) 8 | @course_id = options[:course_id] 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/campus_solutions/delegated_access_feature_flagged.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module DelegatedAccessFeatureFlagged 3 | def is_feature_enabled 4 | Settings.features.cs_delegated_access 5 | end 6 | alias_method(:is_cs_delegated_access_feature_enabled, :is_feature_enabled) 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/ui_selenium/pages/delegate_welcome_card.rb: -------------------------------------------------------------------------------- 1 | module CalCentralPages 2 | 3 | class DelegateWelcomeCard 4 | 5 | include PageObject 6 | include CalCentralPages 7 | 8 | def load_page 9 | navigate_to "#{WebDriverUtils.base_url}/delegate_welcome" 10 | end 11 | 12 | end 13 | 14 | end 15 | -------------------------------------------------------------------------------- /app/models/financials/loan_history/merged_inactive.rb: -------------------------------------------------------------------------------- 1 | module Financials 2 | module LoanHistory 3 | class MergedInactive < Merged 4 | 5 | def globally_cached_providers 6 | [ 7 | MessagingInactive, 8 | Resources 9 | ] 10 | end 11 | 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/user/finances/cache_expiry.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Finances 3 | module CacheExpiry 4 | def self.expire(uid=nil) 5 | CampusSolutions::Billing::MyActivity.expire(uid) 6 | Transactions.expire(uid) 7 | CachedPayments.expire(uid) 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /fixtures/jms_recordings/ist_jms.txt: -------------------------------------------------------------------------------- 1 | --- 2 | :timestamp: 2013-06-01 07:15:12.000000000 -0700 3 | :text: ! '{"eventNotification":{"event":{"payload":{"student":{"ChangeSourceEvent":"SCC_FERPA_DATA_MSG","ChangeSourceType":"MESSAGE","StudentId":17154428}},"timestamp":"2013-06-01T07:15:01.000-07:00","topic":"sis:student:ferpa"}}}' 4 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/NotificationsCard/University/Unread.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | $height: 22px; 4 | 5 | .banner { 6 | margin-top: 15px; 7 | background: $color-colonial-white; 8 | height: $height; 9 | line-height: $height; 10 | text-align: center; 11 | } 12 | -------------------------------------------------------------------------------- /src/redux/reducers/ConfigReducer.js: -------------------------------------------------------------------------------- 1 | import { SET_CONFIG } from '../action-types'; 2 | 3 | const ConfigReducer = (state = {}, action) => { 4 | if (action.type === SET_CONFIG) { 5 | return { ...state, ...action.value }; 6 | } else { 7 | return state; 8 | } 9 | }; 10 | 11 | export default ConfigReducer; 12 | -------------------------------------------------------------------------------- /app/controllers/my_up_next_controller.rb: -------------------------------------------------------------------------------- 1 | class MyUpNextController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | rescue_from StandardError, with: :handle_api_exception 5 | 6 | def get_feed 7 | render :json => UpNext::MyUpNext.from_session(session).get_feed_as_json 8 | end 9 | 10 | end 11 | -------------------------------------------------------------------------------- /app/models/campus_solutions/checklist_data_expiry.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module ChecklistDataExpiry 3 | def self.expire(uid=nil) 4 | [CampusSolutions::MyChecklist, MyTasks::Merged, CampusSolutions::Sir::SirStatuses].each do |klass| 5 | klass.expire uid 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/my_badges/badges_module.rb: -------------------------------------------------------------------------------- 1 | module MyBadges 2 | module BadgesModule 3 | def self.included(klass) 4 | klass.extend Cache::Cacheable 5 | end 6 | 7 | def fetch_counts 8 | 0 9 | end 10 | 11 | def expire_cache(uid) 12 | self.class.expire uid 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /config/warble.rb: -------------------------------------------------------------------------------- 1 | Warbler::Config.new do |config| 2 | config.override_gem_home = false 3 | config.dirs = %w(app bin config db lib log public script vendor versions tmp) 4 | config.init_contents << StringIO.new("\nGem.clear_paths\nGem.path\n") 5 | config.jrubyc_options = "--javac" 6 | config.war_name = "calcentral" 7 | end 8 | -------------------------------------------------------------------------------- /fixtures/json/canvas_sis_import_enrollments.json: -------------------------------------------------------------------------------- 1 | { 2 | "created_at": "2013-06-10T16:18:16-07:00", 3 | "ended_at": null, 4 | "updated_at": "2013-06-10T16:18:16-07:00", 5 | "progress": 0, 6 | "id": 5842632, 7 | "workflow_state": "created", 8 | "data": { 9 | "import_type": "instructure_csv" 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_loan_history_summary.scss: -------------------------------------------------------------------------------- 1 | .cc-loan-history-summary { 2 | .cc-summary-amount { 3 | font-size: 16px; 4 | margin-bottom: 15px; 5 | } 6 | .cc-summary-header { 7 | margin-bottom: 2px; 8 | } 9 | .cc-summary-link { 10 | display: block; 11 | margin-bottom: 2px; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Tasks.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | 4 | const Tasks = ({ children }) => { 5 | return
{children}
; 6 | }; 7 | 8 | Tasks.propTypes = { 9 | children: PropTypes.node, 10 | }; 11 | 12 | export default Tasks; 13 | -------------------------------------------------------------------------------- /src/react/stylesheets/lists.scss: -------------------------------------------------------------------------------- 1 | @import 'colors'; 2 | 3 | //Blocks 4 | .cc-react-list-bullets { 5 | margin: 4px 4px 0 15px; 6 | li::before { 7 | color: $color-hoki; 8 | content: '\25A0'; 9 | float: left; 10 | margin-left: -16px; 11 | margin-top: -2px; 12 | padding-right: 8px; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/redux/reducers/FinancialAidReducer.js: -------------------------------------------------------------------------------- 1 | import { combineReducers } from 'redux'; 2 | 3 | import FinancialAidProfileReducer from './FinancialAidProfileReducer'; 4 | 5 | export const FinancialAidReducer = combineReducers({ 6 | profile: FinancialAidProfileReducer, 7 | }); 8 | 9 | export default FinancialAidReducer; 10 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/link_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class LinkController < CampusSolutionsController 3 | include LinkFetcher 4 | include AllowDelegateViewAs 5 | 6 | def get 7 | render json: link_feed(params['urlId'], params['placeholders']) 8 | end 9 | 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/user/academics/status/severity.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | module Status 4 | module Severity 5 | SEVERITY_NONE = nil 6 | SEVERITY_NORMAL = 'normal' 7 | SEVERITY_NOTICE = 'notice' 8 | SEVERITY_WARNING = 'warning' 9 | end 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/delegate_management_url.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | https://bcs-web-dev-03.is.berkeley.edu:8443/psc/bcsdev/EMPLOYEE/HRMS/c/SA_LEARNER_SERVICES.SS_CC_DA_SHAREINFO.GBL?Page=SS_CC_DA_HDR&Action=A&ForceSearch=Y&TargetFrameName=None 4 | 5 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/deposit.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 24188949 5 | 00000087 6 | 2015-09-01 7 | 100 8 | 9 | 10 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/academicCareersDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.directives').directive('ccAcademicCareersDirective', [function() { 4 | return { 5 | templateUrl: 'directives/academic_careers.html', 6 | scope: { 7 | careers: '=' 8 | } 9 | }; 10 | }]); 11 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/profileImageDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.directives').directive('ccProfileImageDirective', function() { 4 | return { 5 | scope: { 6 | name: '=', 7 | uid: '=' 8 | }, 9 | templateUrl: 'widgets/profile_img.html' 10 | }; 11 | }); 12 | -------------------------------------------------------------------------------- /src/react/components/Icon/GreenCheckIcon.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import FontAwesomeIcon from './FontAwesomeIcon'; 4 | import { ICON_CHECKMARK } from './IconTypes'; 5 | 6 | const GreenCheckIcon = () => ( 7 | 8 | ); 9 | 10 | export default GreenCheckIcon; 11 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/UpNext/UpNextCard.scss: -------------------------------------------------------------------------------- 1 | @import '../../../stylesheets/variables'; 2 | 3 | .UpNextCard { 4 | user-select: none; 5 | 6 | .list { 7 | font-size: 12px; 8 | margin: 0; 9 | overflow-x: hidden; 10 | } 11 | 12 | .top-spacing { 13 | margin-top: $medium-spacing; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /db/migrate/20131107182850_remove_yhl_auth.rb: -------------------------------------------------------------------------------- 1 | class RemoveYhlAuth < ActiveRecord::Migration 2 | def up 3 | Rails.logger.info "Removing (#{uid}) as a superuser" 4 | User::Auth.where(:uid => uid).delete_all 5 | end 6 | 7 | def down 8 | end 9 | 10 | private 11 | 12 | def uid 13 | '192517' 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /db/migrate/20200417192341_remove_app_id_from_oauth2_data.rb: -------------------------------------------------------------------------------- 1 | class RemoveAppIdFromOauth2Data < ActiveRecord::Migration[6.0] 2 | def up 3 | remove_column :ps_uc_clc_oauth, :uc_clc_app_id 4 | end 5 | 6 | def down 7 | add_column :ps_uc_clc_oauth, :uc_clc_app_id, :string, default: 'Google', limit: 255 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /fixtures/json/financials_not_found.json: -------------------------------------------------------------------------------- 1 | { 2 | "ErrorResponse": { 3 | "code": "Not Found", 4 | "message": "CFV No Search Result Found - [ Student ID :::STUDENT_ID:::]", 5 | "moreInfo": "https://integration.berkeley.edu/cfv/errors.html", 6 | "status": "Not Found", 7 | "studentId": :::STUDENT_ID::: 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/react/components/angularWrappers/degreeProgressNotice.js: -------------------------------------------------------------------------------- 1 | import { react2angular } from 'react2angular'; 2 | import DegreeProgressNotice from 'react/components/_academics/DegreeProgress/DegreeProgressNotice'; 3 | 4 | angular 5 | .module('calcentral.react') 6 | .component('degreeProgressNotice', react2angular(DegreeProgressNotice)); 7 | -------------------------------------------------------------------------------- /app/controllers/my_activities_controller.rb: -------------------------------------------------------------------------------- 1 | class MyActivitiesController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render :json => MyActivities::Merged.from_session(session).get_feed_as_json 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/my_financials_controller.rb: -------------------------------------------------------------------------------- 1 | class MyFinancialsController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: Financials::MyFinancials.from_session(session).get_feed 8 | end 9 | 10 | end 11 | -------------------------------------------------------------------------------- /app/controllers/user/tasks/agreements_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Tasks 3 | class AgreementsController < ApplicationController 4 | include AllowDelegateViewAs 5 | include CurrentUserConcern 6 | 7 | def index 8 | render json: user.agreements.get_feed 9 | end 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/campus_solutions/section_grades_expiry.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module SectionGradesExpiry 3 | def self.expire(uids=[]) 4 | uids.each do |uid| 5 | [MyAcademics::Merged, CampusSolutions::Grading].each do |klass| 6 | klass.expire uid 7 | end 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/campus_solutions/user_api_updating_model.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module UserApiUpdatingModel 3 | def passthrough(model_name, params) 4 | proxy = model_name.new({user_id: @uid, params: params}) 5 | result = proxy.post 6 | UserApiExpiry.expire @uid 7 | result 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /spec/models/user/academics/student_groups_cached_spec.rb: -------------------------------------------------------------------------------- 1 | describe User::Academics::StudentGroupsCached do 2 | let(:uid) { random_id } 3 | let(:user) { User::Current.new(uid) } 4 | subject { described_class.new(user) } 5 | 6 | it 'returns uid as instance key' do 7 | expect(subject.instance_key).to eq uid 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/myToolboxController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Controller for page containing view-as widget and other admin-related tools 5 | */ 6 | angular.module('calcentral.controllers').controller('MyToolboxController', function(apiService) { 7 | apiService.util.setTitle('My Toolbox'); 8 | }); 9 | -------------------------------------------------------------------------------- /src/react/components/Icon/GreenCheckCircle.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import FontAwesomeIcon from './FontAwesomeIcon'; 4 | import { ICON_CHECK_CIRCLE } from './IconTypes'; 5 | 6 | const GreenCheckIcon = () => ( 7 | 8 | ); 9 | 10 | export default GreenCheckIcon; 11 | -------------------------------------------------------------------------------- /src/react/components/_academics/AcademicSummary/SemestersSummary.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../assets/stylesheets/colors.scss'; 2 | 3 | .SemestersSummary { 4 | margin-top: 15px; 5 | padding: 15px; 6 | border: 1px solid $color-silver; 7 | 8 | .cc-academic-summary-table-units { 9 | padding-right: 15px !important; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/slr_deeplink_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class SlrDeeplinkController < CampusSolutionsController 3 | 4 | include DisallowAdvisorViewAs 5 | include DisallowClassicViewAs 6 | 7 | def get 8 | json_passthrough CampusSolutions::SlrDeeplink 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/calnet_crosswalk/by_cs_id.rb: -------------------------------------------------------------------------------- 1 | module CalnetCrosswalk 2 | class ByCsId < Proxy 3 | 4 | def url 5 | "#{@settings.base_url}/CAMPUS_SOLUTIONS_ID/#{@uid}" 6 | end 7 | 8 | def mock_request 9 | super.merge(uri_matching: "#{@settings.base_url}/CAMPUS_SOLUTIONS_ID/#{@uid}") 10 | end 11 | 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/campus_solutions/person_data_updating_model.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module PersonDataUpdatingModel 3 | def passthrough(model_name, params) 4 | proxy = model_name.new({user_id: @uid, params: params}) 5 | result = proxy.post 6 | UserApiExpiry.expire @uid 7 | result 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /db/migrate/20140715141414_add_transaction_type_to_calendar_tables.rb: -------------------------------------------------------------------------------- 1 | class AddTransactionTypeToCalendarTables < ActiveRecord::Migration 2 | 3 | def change 4 | add_column(:class_calendar_queue, :transaction_type, :string, :default => 'C') 5 | add_column(:class_calendar_log, :transaction_type, :string, :default => 'C') 6 | end 7 | 8 | end 9 | -------------------------------------------------------------------------------- /fixtures/json/canvas_section.json: -------------------------------------------------------------------------------- 1 | { 2 | "encoding": "US-ASCII", 3 | "string": "", 4 | "debug_json": { 5 | "course_id": 1121, 6 | "end_at": null, 7 | "id": 1593, 8 | "name": "STAT 5432 LEC 001", 9 | "nonxlist_course_id": null, 10 | "start_at": null, 11 | "sis_section_id": "SEC:2013-D-757999" 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/icons/due-now.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /src/react/components/Icon/RedExclamationIcon.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import FontAwesomeIcon from './FontAwesomeIcon'; 4 | import { ICON_EXCLAMATION } from './IconTypes'; 5 | 6 | const RedExclamationIcon = () => ( 7 | 8 | ); 9 | 10 | export default RedExclamationIcon; 11 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/fpp_enrollment_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class FppEnrollmentController < CampusSolutionsController 3 | 4 | include DisallowAdvisorViewAs 5 | include DisallowClassicViewAs 6 | 7 | def get 8 | json_passthrough CampusSolutions::FppEnrollment 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/controllers/my_aid_years_controller.rb: -------------------------------------------------------------------------------- 1 | class MyAidYearsController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: FinancialAid::MyAidYears.from_session(session).get_feed_as_json 8 | end 9 | 10 | end 11 | -------------------------------------------------------------------------------- /app/controllers/user/tasks/web_messages_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Tasks 3 | class WebMessagesController < ApplicationController 4 | include AllowDelegateViewAs 5 | include CurrentUserConcern 6 | 7 | def index 8 | render json: user.notifications_feed.get_feed 9 | end 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/calnet_crosswalk/by_uid.rb: -------------------------------------------------------------------------------- 1 | module CalnetCrosswalk 2 | class ByUid < Proxy 3 | include Cache::UserCacheExpiry 4 | 5 | def url 6 | "#{@settings.base_url}/UID/#{@uid}" 7 | end 8 | 9 | def mock_request 10 | super.merge(uri_matching: "#{@settings.base_url}/UID/#{@uid}") 11 | end 12 | 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /db/migrate/20140916213448_drop_is_test_user_auth.rb: -------------------------------------------------------------------------------- 1 | class DropIsTestUserAuth < ActiveRecord::Migration 2 | 3 | def up 4 | remove_column "user_auths", :is_test_user 5 | end 6 | 7 | def down 8 | change_table :user_auths do |t| 9 | t.boolean :is_test_user, :null => false, :default => false 10 | end 11 | end 12 | 13 | end 14 | -------------------------------------------------------------------------------- /fixtures/json/canvas_course_create_section.json: -------------------------------------------------------------------------------- 1 | { 2 | "course_id": 5, 3 | "end_at": null, 4 | "id": 160, 5 | "name": "Data Structures", 6 | "nonxlist_course_id": null, 7 | "start_at": null, 8 | "sis_section_id": null, 9 | "sis_course_id": "CRS:COMPSCI-61B-2014-D", 10 | "integration_id": null, 11 | "sis_import_id": null 12 | } 13 | -------------------------------------------------------------------------------- /src/assets/templates/academics_higher_degree_faculty_committees.html: -------------------------------------------------------------------------------- 1 |
2 |
4 |
5 | -------------------------------------------------------------------------------- /src/assets/templates/loan_resources_page.html: -------------------------------------------------------------------------------- 1 |
2 |

3 | My Finances » Loan Resources 4 |

5 |
6 |
7 |
8 |
-------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItemsTable/ShowMore.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | .ShowMore { 4 | padding: 10px 10px 0; 5 | color: $color-denim; 6 | display: flex; 7 | justify-content: center; 8 | cursor: pointer; 9 | } 10 | 11 | .ShowMore__message { 12 | margin-right: 5px; 13 | } 14 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/DownloadButton.scss: -------------------------------------------------------------------------------- 1 | @import '../../../stylesheets/variables'; 2 | 3 | .DownloadButton { 4 | color: $color-dove-gray; 5 | background: $color-wild-sand; 6 | border: 1px solid $color-silver; 7 | border-radius: 5px; 8 | padding: 5px 15px; 9 | cursor: pointer; 10 | font-weight: bold; 11 | } 12 | -------------------------------------------------------------------------------- /src/redux/actions/linksActions.js: -------------------------------------------------------------------------------- 1 | import { FETCH_LINK_START, FETCH_LINK_SUCCESS } from '../action-types'; 2 | 3 | export const fetchLinkStart = key => ({ 4 | type: FETCH_LINK_START, 5 | key: key, 6 | }); 7 | 8 | export const fetchLinkSuccess = (key, value) => ({ 9 | type: FETCH_LINK_SUCCESS, 10 | key: key, 11 | value: value, 12 | }); 13 | -------------------------------------------------------------------------------- /app/controllers/transfer_credit_controller.rb: -------------------------------------------------------------------------------- 1 | class TransferCreditController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate 4 | before_action :authorize_for_enrollments 5 | 6 | def get_feed 7 | render json: MyAcademics::MyTransferCredit.from_session(session).get_feed_as_json 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/controllers/user/tasks/canvas_messages_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Tasks 3 | class CanvasMessagesController < ApplicationController 4 | include AllowDelegateViewAs 5 | include CurrentUserConcern 6 | 7 | def index 8 | render json: user.b_courses.activities_feed 9 | end 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/controllers/user/tasks/checklist_items_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Tasks 3 | class ChecklistItemsController < ApplicationController 4 | include AllowDelegateViewAs 5 | include CurrentUserConcern 6 | 7 | def index 8 | render json: user.checklist_items.get_feed 9 | end 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/campus_solutions/checklist_data_updating_model.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module ChecklistDataUpdatingModel 3 | def passthrough(model_name, params) 4 | proxy = model_name.new({user_id: @uid, params: params}) 5 | result = proxy.post 6 | ChecklistDataExpiry.expire @uid 7 | result 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /db/migrate/20130221235900_update_eli_uid.rb: -------------------------------------------------------------------------------- 1 | class UpdateEliUid < ActiveRecord::Migration 2 | def up 3 | eli = User::Auth.find(:first, :conditions => {:uid => "3222279"}) 4 | if eli 5 | eli.update_attributes!(:uid => 322279) 6 | end 7 | end 8 | 9 | def down 10 | # We never want to revert the bad uid error 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /spec/models/hub_edos/student_api/v2/student/student_plans_spec.rb: -------------------------------------------------------------------------------- 1 | describe HubEdos::StudentApi::V2::Student::StudentPlans do 2 | let(:attributes) { [{}] } 3 | subject { described_class.new(attributes) } 4 | its(:all) { should be_an_instance_of Array } 5 | its('all.first') { should be_an_instance_of HubEdos::StudentApi::V2::Student::StudentPlan } 6 | end 7 | -------------------------------------------------------------------------------- /spec/models/hub_edos/student_api/v2/student_record/gpa_spec.rb: -------------------------------------------------------------------------------- 1 | describe HubEdos::StudentApi::V2::StudentRecord::Gpa do 2 | let(:attributes) do 3 | { 4 | 'type' => { 5 | 'code' => 'CGPA', 6 | 'description' => 'Cumulative GPA' 7 | }, 8 | 'average' => 2.43, 9 | 'source' => 'UCB' 10 | } 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_profile_image.scss: -------------------------------------------------------------------------------- 1 | // _profile_image.scss 2 | .cc-widget-profile-img { 3 | border: 1px solid $color-dusty-gray; 4 | height: 96px; 5 | width: 72px; 6 | } 7 | 8 | .cc-widget-delegate-student-img { 9 | background-image: url('../images/svg/photo_unavailable_bear_72x96.svg'); 10 | height: 96px; 11 | width: 72px; 12 | } 13 | -------------------------------------------------------------------------------- /src/assets/templates/cumulative_loan_debt_page.html: -------------------------------------------------------------------------------- 1 |
2 |

3 | My Finances » Cumulative Loan Debt 4 |

5 |
6 |
7 |
8 |
-------------------------------------------------------------------------------- /src/components/Table.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | 4 | import styles from './Table.module.scss'; 5 | 6 | const Table = ({ children }) => ( 7 | {children}
8 | ); 9 | 10 | Table.propTypes = { 11 | children: PropTypes.node, 12 | }; 13 | 14 | export default Table; 15 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TaskTitle.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | @import 'src/react/stylesheets/mixins'; 3 | 4 | $danger-color: $color-thunderbird; 5 | 6 | .taskTitle { 7 | flex: 1; 8 | 9 | &.overdue { 10 | color: $danger-color; 11 | } 12 | } 13 | 14 | .title { 15 | font-weight: bold; 16 | } 17 | -------------------------------------------------------------------------------- /app/models/campus_solutions/grading.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class Grading < CachedProxy 3 | 4 | include CampusSolutionsIdRequired 5 | 6 | def url 7 | "#{@settings.base_url}/UC_SR_FACULTY_GRADING.v1/Get?EMPLID=#{@campus_solutions_id}" 8 | end 9 | 10 | def xml_filename 11 | 'grading.xml' 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/user/webcasts/concern.rb: -------------------------------------------------------------------------------- 1 | require 'active_support/concern' 2 | 3 | module User 4 | module Webcasts 5 | module Concern 6 | extend ActiveSupport::Concern 7 | 8 | included do 9 | def webcasts 10 | @webcasts ||= ::User::Webcasts::Webcasts.new(self) 11 | end 12 | end 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /fixtures/json/canvas_account.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 1845, 3 | "name": "L & S", 4 | "parent_account_id": 90242, 5 | "root_account_id": 90242, 6 | "default_storage_quota_mb": 1024, 7 | "default_user_storage_quota_mb": 50, 8 | "default_group_storage_quota_mb": 50, 9 | "default_time_zone": "America/Denver", 10 | "sis_account_id": "ACCT:L & S" 11 | } 12 | -------------------------------------------------------------------------------- /fixtures/json/canvas_check_provisioning_report_users.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 9, 3 | "parameters": { 4 | "users": "1", 5 | "extra_text": "Term: All Terms; Reports: users " 6 | }, 7 | "progress": 100, 8 | "status": "complete", 9 | "report": "provisioning_csv", 10 | "file_url": "https://localhost:3100/accounts/90242/files/14/download" 11 | } 12 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/dashboard_url.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | https://bcs-web-dev-03.is.berkeley.edu:8443/psc/bcsdev/EMPLOYEE/HRMS/c/CCI_COMMUNICATION_CENTER_SS.CCI_COMM_CENTER_FL.GBL 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/fpp_enrollment.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Activate Fee Payment Plan 4 | https://bcs-web-dev-02.is.berkeley.edu:8443/psc/bcscfg/EMPLOYEE/HRMS/c/SA_LEARNER_SERVICES.SSF_SS_PPL_ENRL.GBL 5 | true 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/assets/images/svg/icon_drive_256x256.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_finaid.scss: -------------------------------------------------------------------------------- 1 | .cc-page-finaid { 2 | .cc-page-finaid-header { 3 | font-size: 14px; 4 | margin: 0; 5 | } 6 | .cc-page-finaid-header-container { 7 | padding: 0 15px; 8 | h3 { 9 | margin: 0; 10 | } 11 | } 12 | .cc-page-finaid-header-container-dark { 13 | background: $color-gallery; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/components/Form.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | form.Form { 4 | padding: 0; 5 | background: none; 6 | border: none; 7 | 8 | input, 9 | textarea { 10 | margin: 0; 11 | } 12 | 13 | .field + .field { 14 | margin-top: 15px; 15 | } 16 | 17 | .actions { 18 | margin-top: 15px; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/react/components/_academics/ClassInformationCard/ClassAttributesTable.module.scss: -------------------------------------------------------------------------------- 1 | @import 'src/react/stylesheets/variables'; 2 | 3 | table.classAttributesTable { 4 | width: 100%; 5 | 6 | thead, 7 | tbody { 8 | tr { 9 | th { 10 | color: $color-dove-gray; 11 | font-weight: normal; 12 | } 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/sir/my_sir_response.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module Sir 3 | class MySirResponse < UserSpecificModel 4 | 5 | include CampusSolutions::ChecklistDataUpdatingModel 6 | 7 | def update(params = {}) 8 | passthrough(CampusSolutions::Sir::SirResponse, params) 9 | end 10 | 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/enf/handler.rb: -------------------------------------------------------------------------------- 1 | module ENF 2 | class Handler 3 | attr_accessor :message 4 | 5 | def self.call(message) 6 | raise "Override self.call in your subclass" 7 | end 8 | 9 | def initialize(message) 10 | self.message = message 11 | end 12 | 13 | def uids 14 | message.student_uids 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /app/models/my_academics/my_transfer_credit.rb: -------------------------------------------------------------------------------- 1 | module MyAcademics 2 | class MyTransferCredit < UserSpecificModel 3 | include Cache::CachedFeed 4 | include Cache::JsonifiedFeed 5 | include Cache::UserCacheExpiry 6 | 7 | def get_feed_internal 8 | EdoOracle::TransferCredit.new(user_id: @uid).get_feed 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /db/migrate/20130130144600_drop_widget_data.rb: -------------------------------------------------------------------------------- 1 | class DropWidgetData < ActiveRecord::Migration 2 | 3 | def up 4 | drop_table :widget_data 5 | end 6 | 7 | def down 8 | create_table :widget_data do |t| 9 | t.string :uid 10 | t.string :widget_id 11 | t.text :data 12 | t.timestamps 13 | end 14 | 15 | end 16 | 17 | end 18 | -------------------------------------------------------------------------------- /db/migrate/20131206145401_remove_canvas_oauth_data.rb: -------------------------------------------------------------------------------- 1 | class RemoveCanvasOauthData < ActiveRecord::Migration 2 | 3 | def up 4 | Rails.logger.warn "Removing Canvas OAuth2 rows" 5 | User::Oauth2Data.where(:app_id => "Canvas").delete_all 6 | end 7 | 8 | def down 9 | Rails.logger.warn "This migration is not reversible" 10 | end 11 | 12 | end 13 | -------------------------------------------------------------------------------- /fixtures/json/canvas_admins_87483_page_1.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": 12345, 4 | "role": "AccountAdmin", 5 | "user": { 6 | "id": 3218765, 7 | "name": "Purple Hays", 8 | "sortable_name": "Hays, Purple", 9 | "short_name": "Purple Hays", 10 | "sis_user_id": "321654", 11 | "login_id": "321654" 12 | } 13 | } 14 | ] 15 | -------------------------------------------------------------------------------- /fixtures/json/canvas_admins_90242_page_2.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": 14874, 4 | "role": "Developer Admin", 5 | "user": { 6 | "id": 3057507, 7 | "name": "Eli Cochran", 8 | "sortable_name": "Cochran, Eli", 9 | "short_name": "Eli Cochran", 10 | "sis_user_id": "322279", 11 | "login_id": "322279" 12 | } 13 | } 14 | ] 15 | -------------------------------------------------------------------------------- /spec/ui_selenium/pages/api_my_badges_page.rb: -------------------------------------------------------------------------------- 1 | class ApiMyBadgesPage 2 | 3 | include PageObject 4 | include ClassLogger 5 | 6 | def get_json(driver) 7 | logger.info 'Parsing JSON from /api/my/badges' 8 | navigate_to "#{WebDriverUtils.base_url}/api/my/badges" 9 | @parsed = JSON.parse driver.find_element(:xpath, '//pre').text 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/configuration/locationConfiguration.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Set the location configuration for CalCentral 5 | */ 6 | angular.module('calcentral.config').config(function($locationProvider) { 7 | // We set it to html5 mode so we don't have hash bang URLs 8 | $locationProvider.html5Mode(true).hashPrefix('!'); 9 | }); 10 | -------------------------------------------------------------------------------- /src/react/components/SortArrows.scss: -------------------------------------------------------------------------------- 1 | .SortArrows { 2 | display: flex; 3 | flex-direction: row; 4 | align-items: center; 5 | cursor: pointer; 6 | } 7 | 8 | .SortArrows__arrow-group { 9 | display: flex; 10 | flex-direction: column; 11 | margin-left: 5px; 12 | } 13 | 14 | .SortArrows__arrow-group img:first-child { 15 | margin-bottom: 2px; 16 | } 17 | -------------------------------------------------------------------------------- /.babelrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | ['@babel/preset-env', { useBuiltIns: 'usage' }], 4 | ['@babel/preset-react'], 5 | ], 6 | 7 | plugins: [ 8 | [ 9 | require.resolve('babel-plugin-module-resolver'), 10 | { 11 | alias: { 12 | React: './src/react', 13 | }, 14 | }, 15 | ], 16 | ], 17 | }; 18 | -------------------------------------------------------------------------------- /app/models/api/service_alerts.rb: -------------------------------------------------------------------------------- 1 | class Api::ServiceAlerts 2 | include Cache::CachedFeed 3 | include Cache::JsonifiedFeed 4 | 5 | def get_feed_internal 6 | ServiceAlert.public_feed 7 | end 8 | 9 | # Instance key needs to be defined, but return nil for single "class instance" 10 | # cache to expire properly. 11 | def instance_key 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /fixtures/json/canvas_check_provisioning_report_courses.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 39050, 3 | "parameters": { 4 | "courses": "1", 5 | "enrollment_term": "sis_term_id:TERM:2015-B" 6 | }, 7 | "progress": 100, 8 | "status": "complete", 9 | "report": "provisioning_csv", 10 | "file_url": "http://localhost:12345/accounts/129440/files/57734545/download" 11 | } 12 | -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | modulePaths: ['/src/'], 3 | moduleNameMapper: { 4 | '\\.scss$': require.resolve('./src/test/style-mock.js'), 5 | '\\.css$': require.resolve('./src/test/style-mock.js'), 6 | '\\.svg$': require.resolve('./src/test/style-mock.js'), 7 | }, 8 | testPathIgnorePatterns: ['/node_modules/', '/vendor/'], 9 | }; 10 | -------------------------------------------------------------------------------- /spec/ui_selenium/pages/my_academics_book_list_page.rb: -------------------------------------------------------------------------------- 1 | module CalCentralPages 2 | 3 | class MyAcademicsBookListPage < MyAcademicsPage 4 | 5 | include PageObject 6 | include CalCentralPages 7 | 8 | def load_page(semester_slug) 9 | navigate_to "#{WebDriverUtils.base_url}/academics/booklist/#{semester_slug}" 10 | end 11 | 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/academicPlansDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.directives').directive('ccAcademicPlansDirective', [function() { 4 | return { 5 | templateUrl: 'directives/academic_plans.html', 6 | scope: { 7 | plans: '=', 8 | options: '=', 9 | type: '@' 10 | } 11 | }; 12 | }]); 13 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/selectOnClickDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.directives').directive('ccSelectOnClickDirective', function() { 4 | return { 5 | restrict: 'A', 6 | link: function(scope, elm) { 7 | elm.on('click', function() { 8 | this.select(); 9 | }); 10 | } 11 | }; 12 | }); 13 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_finaid_housing.scss: -------------------------------------------------------------------------------- 1 | .cc-widget-finaid-housing { 2 | .cc-widget-finaid-housing-fall-pathway-link { 3 | margin-top: 15px; 4 | } 5 | .cc-widget-finaid-table thead > tr > th { 6 | &:nth-child(1) { 7 | width: 30%; 8 | } 9 | &:nth-child(2) { 10 | padding-right: 0; 11 | width: 70%; 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/icons/chevron-down.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Icons/CanvasIcon.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import styles from './iconWrapper.module.scss'; 4 | 5 | function CanvasIcon() { 6 | return ( 7 |
8 |
9 |
10 | ); 11 | } 12 | 13 | export default CanvasIcon; 14 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/ItemAmount.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | .ItemAmount { 4 | white-space: nowrap; 5 | } 6 | 7 | @media only screen and (min-width: $small-breakpoint) { 8 | .ItemAmount { 9 | padding-right: 12px; 10 | } 11 | } 12 | 13 | .ItemAmount--payment { 14 | color: green; 15 | } 16 | -------------------------------------------------------------------------------- /fixtures/json/canvas_user_logins.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "account_id": 90242, 4 | "id": 2963066, 5 | "sis_user_id": "211159", 6 | "unique_id": "211159", 7 | "user_id": 3057506 8 | }, 9 | { 10 | "account_id": 90242, 11 | "id": 4647947, 12 | "sis_user_id": null, 13 | "unique_id": "raydavis-test", 14 | "user_id": 3057506 15 | } 16 | ] 17 | -------------------------------------------------------------------------------- /src/icons/chevron-up.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/react/components/_academics/StudentProfile/Degrees.scss: -------------------------------------------------------------------------------- 1 | .Degree { 2 | display: flex; 3 | flex-direction: row; 4 | } 5 | 6 | .Degree + .Degree { 7 | margin-top: 15px; 8 | } 9 | 10 | .Degree__icon-container { 11 | width: 20px; 12 | } 13 | 14 | .Degree__description { 15 | font-weight: bold; 16 | 17 | span { 18 | font-weight: normal; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/react/components/_user_overview/EmploymentAppointments/EmploymentAppointments.scss: -------------------------------------------------------------------------------- 1 | @import '../../../stylesheets/mixins'; 2 | @import '../../../stylesheets/variables'; 3 | 4 | .EmploymentAppointments { 5 | @include card; 6 | @include card-in-column; 7 | } 8 | 9 | .EmploymentAppointments--body { 10 | @include card-body; 11 | padding: $large-spacing; 12 | } 13 | -------------------------------------------------------------------------------- /src/redux/reducers/RouteReducer.js: -------------------------------------------------------------------------------- 1 | import { SET_CURRENT_ROUTE_PROPERTIES } from '../action-types'; 2 | 3 | const RouteReducer = (state = {}, action) => { 4 | switch (action.type) { 5 | case SET_CURRENT_ROUTE_PROPERTIES: 6 | return { ...state, ...action.value }; 7 | default: 8 | return state; 9 | } 10 | }; 11 | 12 | export default RouteReducer; 13 | -------------------------------------------------------------------------------- /app/controllers/my_financial_aid_summary_controller.rb: -------------------------------------------------------------------------------- 1 | class MyFinancialAidSummaryController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: FinancialAid::MyFinancialAidSummary.from_session(session).get_feed_as_json 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /src/assets/templates/loan_summary_by_aid_year_page.html: -------------------------------------------------------------------------------- 1 |
2 |

3 | My Finances » Loan Summary by Aid Year 4 |

5 |
6 |
7 |
8 |
-------------------------------------------------------------------------------- /src/components/FormActions.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | import styles from './FormActions.module.scss'; 4 | 5 | const FormActions = ({ children }) => ( 6 |
{children}
7 | ); 8 | 9 | FormActions.propTypes = { 10 | children: PropTypes.node, 11 | }; 12 | 13 | export default FormActions; 14 | -------------------------------------------------------------------------------- /src/components/SplashContainer.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | import styles from './SplashContainer.module.scss'; 4 | 5 | export default function SplashContainer({ children }) { 6 | return
{children}
; 7 | } 8 | 9 | SplashContainer.propTypes = { 10 | children: PropTypes.node, 11 | }; 12 | -------------------------------------------------------------------------------- /src/icons/chevron-down-large.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /app/models/campus_solutions/work_experience_updating_model.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module WorkExperienceUpdatingModel 3 | def passthrough(model_name, params) 4 | proxy = model_name.new({user_id: @uid, params: params}) 5 | result = proxy.get 6 | HubEdos::StudentApi::V2::Feeds::WorkExperiences.expire @uid 7 | result 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /app/models/my_academics/law/awards.rb: -------------------------------------------------------------------------------- 1 | module MyAcademics 2 | module Law 3 | class Awards < UserSpecificModel 4 | include Cache::CachedFeed 5 | include Cache::JsonifiedFeed 6 | include Cache::UserCacheExpiry 7 | 8 | def awards 9 | @awards ||= HashConverter.camelize(Queries.awards_for_user(@uid)) 10 | end 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_degrees_conferred.scss: -------------------------------------------------------------------------------- 1 | .cc-degrees-conferred { 2 | .cc-degrees-conferred-container { 3 | position: relative; 4 | .cc-degrees-conferred-data { 5 | padding-left: 20px; 6 | } 7 | .cc-degrees-conferred-icon { 8 | position: absolute; 9 | top: 0; 10 | i { 11 | display: block; 12 | } 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_finaid_profile.scss: -------------------------------------------------------------------------------- 1 | .cc-widget-finaid-profile { 2 | .cc-widget-finaid-profile-message { 3 | padding-bottom: 10px; 4 | } 5 | .cc-widget-finaid-profile-button-toggle { 6 | margin-left: 10px; 7 | span { 8 | vertical-align: middle; 9 | } 10 | } 11 | .cc-widget-finaid-profile-itemgroup { 12 | margin-top: 15px; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/assets/templates/directives/sortable_column.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 |
5 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/sir_response_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class SirResponseController < CampusSolutionsController 3 | rescue_from Errors::ClientError, with: :handle_client_error 4 | 5 | before_action :exclude_acting_as_users 6 | 7 | def post 8 | post_passthrough CampusSolutions::Sir::MySirResponse 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/ce_diploma_sso.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | https://test.secure.cecredentialtrust.com/Account/ERLSSO/1234ABCD-91AB-4567-ABCD-12341234432143213e5676722447433e5a776e783723384962627975705855416a6f66464f674d657373304f6a34706d377251533467365a447158716b5a7370733d%7CJ/1042 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/factories/webcastFactory.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Webcast Factory 5 | */ 6 | angular.module('calcentral.factories').factory('webcastFactory', function(apiService) { 7 | var getWebcasts = function(options) { 8 | return apiService.http.request(options); 9 | }; 10 | 11 | return { 12 | getWebcasts: getWebcasts 13 | }; 14 | }); 15 | -------------------------------------------------------------------------------- /src/icons/timeline-center.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/NotificationsCard/useShowMore.js: -------------------------------------------------------------------------------- 1 | import { useState } from 'react'; 2 | 3 | function useShowMore(incrementBy) { 4 | const [shownCount, setShownCount] = useState(incrementBy); 5 | const showMore = () => { 6 | setShownCount(shownCount + incrementBy); 7 | }; 8 | 9 | return [shownCount, showMore]; 10 | } 11 | 12 | export default useShowMore; 13 | -------------------------------------------------------------------------------- /app/models/campus_solutions/cs_official_transcript.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class CsOfficialTranscript < Proxy 3 | 4 | include CampusSolutionsIdRequired 5 | 6 | def url 7 | "#{@settings.base_url}/UC_SR_TRNSCPT_DATA.v1/Get?EMPLID=#{@campus_solutions_id}" 8 | end 9 | 10 | def xml_filename 11 | 'cs_official_transcript.xml' 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/google_apps/events_get.rb: -------------------------------------------------------------------------------- 1 | module GoogleApps 2 | class EventsGet < Proxy 3 | require 'google/apis/calendar_v3' 4 | 5 | def get_event(event_id) 6 | request( 7 | service_class: Google::Apis::CalendarV3::CalendarService, 8 | method_name: 'delete_event', 9 | method_args: ['primary', event_id], 10 | ).first 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/ferpa_deeplink_url.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Manage FERPA Restrictions 5 | true 6 | https://bcs-web-dev-03.is.berkeley.edu:8443/psc/bcsdev/EMPLOYEE/HRMS/c/CC_PORTFOLIO.SS_CC_FERPA_SETUP.GBL?Page=SS_CC_FERPA 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/loan_history/loan_resources_card.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |

Loan Resources

4 |
5 |
6 |
7 |
8 |
9 |
-------------------------------------------------------------------------------- /src/icons/timeline-center-blue.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/react/components/_academics/StudentProfile/MissingPhoto.scss: -------------------------------------------------------------------------------- 1 | @import '../../../stylesheets/_colors.scss'; 2 | 3 | .MissingPhoto { 4 | background: $color-silver; 5 | display: block; 6 | font-size: 80px; 7 | height: 96px; 8 | padding-top: 10px; 9 | text-align: center; 10 | width: 72px; 11 | line-height: 1.5; 12 | 13 | i { 14 | color: $color-white; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /app/controllers/user/tasks/b_courses_todos_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Tasks 3 | class BCoursesTodosController < ApplicationController 4 | include AllowDelegateViewAs 5 | include CurrentUserConcern 6 | 7 | def index 8 | render json: { 9 | bCoursesTodos: user.b_courses.filtered_tasks 10 | } 11 | end 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/user/academics/status_and_holds.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | class StatusAndHolds 4 | attr_reader :user 5 | 6 | def initialize(user) 7 | @user = user 8 | end 9 | 10 | def as_json(options={}) 11 | { 12 | termRegistrations: user.term_registrations.active 13 | } 14 | end 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /fixtures/json/canvas_add_admin.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 18835, 3 | "role": "AccountAdmin", 4 | "role_id": 1770, 5 | "user": { 6 | "id": 3323890, 7 | "name": "Stu Testb", 8 | "short_name": "Stu Testb", 9 | "sortable_name": "Testb, Stu", 10 | "sis_user_id": "300846", 11 | "login_id": "300846", 12 | "integration_id": null, 13 | "sis_import_id": null 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /lib/tasks/superuser.rake: -------------------------------------------------------------------------------- 1 | namespace :superuser do 2 | 3 | desc "Create a CalCentral superuser" 4 | task :create => :environment do 5 | uid = ENV['UID'] 6 | if uid 7 | User::Auth.new_or_update_superuser! uid 8 | Rails.logger.warn "Created #{uid} as a superuser" 9 | else 10 | Rails.logger.error "No UID passed, nothing to do!" 11 | end 12 | end 13 | 14 | end 15 | -------------------------------------------------------------------------------- /src/functions/formatCurrency.js: -------------------------------------------------------------------------------- 1 | const formatCurrency = (amount) => { 2 | const sign = Math.abs(amount) === amount ? '$' : '- $'; 3 | 4 | const formatted = Math.abs(amount).toLocaleString('en-US', { 5 | style: 'currency', 6 | currency: 'USD', 7 | minimumFractionDigits: 2 8 | }).slice(1); 9 | 10 | return `${sign} ${formatted}`; 11 | }; 12 | 13 | export default formatCurrency; 14 | -------------------------------------------------------------------------------- /src/icons/timeline-empty.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/ethnicity_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class EthnicityController < CampusSolutionsController 3 | 4 | before_action :exclude_acting_as_users 5 | 6 | def post 7 | post_passthrough CampusSolutions::MyEthnicity 8 | end 9 | 10 | def delete 11 | delete_passthrough CampusSolutions::MyEthnicity 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/language_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class LanguageController < CampusSolutionsController 3 | 4 | before_action :exclude_acting_as_users 5 | 6 | def post 7 | post_passthrough CampusSolutions::MyLanguage 8 | end 9 | 10 | def delete 11 | delete_passthrough CampusSolutions::MyLanguage 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/my_language.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class MyLanguage < UserSpecificModel 3 | 4 | include PersonDataUpdatingModel 5 | 6 | def update(params = {}) 7 | passthrough(CampusSolutions::LanguagePost, params) 8 | end 9 | 10 | def delete(params = {}) 11 | passthrough(CampusSolutions::LanguageDelete, params) 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/my_person_name.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class MyPersonName < UserSpecificModel 3 | 4 | include UserApiUpdatingModel 5 | 6 | def update(params = {}) 7 | passthrough(CampusSolutions::PersonName, params) 8 | end 9 | 10 | def delete(params = {}) 11 | passthrough(CampusSolutions::NameDelete, params) 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/my_activities/dashboard_sites.rb: -------------------------------------------------------------------------------- 1 | module MyActivities 2 | class DashboardSites 3 | def self.fetch(uid, options={}) 4 | classes_feed = MyClasses::Merged.new(uid, options).get_feed 5 | groups_feed = MyGroups::Merged.new(uid, options).get_feed 6 | classes_feed[:classes] + classes_feed[:gradingInProgressClasses].to_a + groups_feed[:groups] 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/user/photo.rb: -------------------------------------------------------------------------------- 1 | module User 2 | class Photo 3 | 4 | def self.fetch(uid, opts={}) 5 | # Delegate user is not allowed to see his/her student's photo due to privacy concern. 6 | return nil if opts[SessionKey.original_delegate_user_id] 7 | photo_feed = Cal1card::Photo.new(uid).get_feed 8 | photo_feed[:photo] ? photo_feed : nil 9 | end 10 | 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /db/migrate/20140502135009_drop_user_whitelist.rb: -------------------------------------------------------------------------------- 1 | class DropUserWhitelist < ActiveRecord::Migration 2 | def up 3 | drop_table :user_whitelists 4 | end 5 | 6 | def down 7 | create_table :user_whitelists do |t| 8 | t.string :uid 9 | t.timestamps 10 | end 11 | change_table :user_whitelists do |t| 12 | t.index [:uid], :unique => true 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /db/migrate/20150521163404_add_list_details_to_canvas_site_mailing_lists.rb: -------------------------------------------------------------------------------- 1 | class AddListDetailsToCanvasSiteMailingLists < ActiveRecord::Migration 2 | def change 3 | add_column :canvas_site_mailing_lists, :members_count, :integer 4 | add_column :canvas_site_mailing_lists, :populate_add_errors, :integer 5 | add_column :canvas_site_mailing_lists, :populate_remove_errors, :integer 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /src/react/components/VisuallyHidden.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | 4 | const propTypes = { 5 | children: PropTypes.node, 6 | }; 7 | 8 | const VisuallyHidden = ({ children }) => { 9 | return {children}; 10 | }; 11 | 12 | VisuallyHidden.propTypes = propTypes; 13 | 14 | export default VisuallyHidden; 15 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Icons/CampusSolutionsIcon.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import styles from './iconWrapper.module.scss'; 4 | 5 | function CampusSolutionsIcon() { 6 | return ( 7 |
8 |
9 |
10 | ); 11 | } 12 | 13 | export default CampusSolutionsIcon; 14 | -------------------------------------------------------------------------------- /app/controllers/my_awards_by_term_controller.rb: -------------------------------------------------------------------------------- 1 | class MyAwardsByTermController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | options = params.permit :aid_year 8 | render json: FinancialAid::MyAwardsByTerm.from_session(session, options).get_feed_as_json 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /app/controllers/user/academics/status_and_holds_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | class StatusAndHoldsController < ApplicationController 4 | include AllowDelegateViewAs 5 | 6 | def index 7 | render json: user.status_and_holds 8 | end 9 | 10 | def user 11 | User::Current.new(session['user_id']) 12 | end 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/my_ethnicity.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class MyEthnicity < UserSpecificModel 3 | 4 | include PersonDataUpdatingModel 5 | 6 | def update(params = {}) 7 | passthrough(CampusSolutions::EthnicityPost, params) 8 | end 9 | 10 | def delete(params = {}) 11 | passthrough(CampusSolutions::EthnicityDelete, params) 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/concerns/careers.rb: -------------------------------------------------------------------------------- 1 | module Concerns 2 | module Careers 3 | extend self 4 | 5 | def active?(career) 6 | :AC == career.try(:[], 'program_status').try(:intern) 7 | end 8 | 9 | def active_or_all(careers) 10 | active_careers = careers.try(:select){|career| active? career} 11 | active_careers.present? ? active_careers : careers 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/google_apps/events_update.rb: -------------------------------------------------------------------------------- 1 | module GoogleApps 2 | class EventsUpdate < Proxy 3 | 4 | def update_event(event_id, event_body) 5 | request( 6 | service_class: Google::Apis::CalendarV3::CalendarService, 7 | method_name: 'update_event', 8 | method_args: ['primary', event_id, event_body, nil, nil, nil, false], 9 | ).first 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/my_academics/law/transcript_notes.rb: -------------------------------------------------------------------------------- 1 | module MyAcademics 2 | module Law 3 | class TranscriptNotes < UserSpecificModel 4 | include Cache::CachedFeed 5 | include Cache::JsonifiedFeed 6 | include Cache::UserCacheExpiry 7 | 8 | def notes 9 | @notes ||= HashConverter.camelize(Queries.transcript_notes_for_user(@uid)) 10 | end 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/user/financial_aid/aid_years.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module FinancialAid 3 | class AidYears 4 | attr_reader :user 5 | 6 | def initialize(user) 7 | @user = user 8 | end 9 | 10 | def get_feed 11 | { 12 | aidYears: ::FinancialAid::MyAidYears.new(user.uid).get_feed.try(:[], :aidYears) 13 | } 14 | end 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /db/migrate/20130701162699_create_user_whitelist.rb: -------------------------------------------------------------------------------- 1 | class CreateUserWhitelist < ActiveRecord::Migration 2 | def up 3 | create_table :user_whitelists do |t| 4 | t.string :uid 5 | t.timestamps 6 | end 7 | change_table :user_whitelists do |t| 8 | t.index [:uid], :unique => true 9 | end 10 | end 11 | 12 | def down 13 | drop_table :user_whitelists 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /db/migrate/20130809164403_darlene_super_user.rb: -------------------------------------------------------------------------------- 1 | class DarleneSuperUser < ActiveRecord::Migration 2 | def up 3 | Rails.logger.info "Flagging Darlene Kawase (#{uid}) as a superuser" 4 | User::Auth.new_or_update_superuser! uid 5 | end 6 | 7 | def down 8 | User::Auth.where(:uid => uid).delete_all 9 | end 10 | 11 | private 12 | 13 | def uid 14 | '53791' 15 | end 16 | 17 | end 18 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/configuration/sceConfiguration.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Set the SCE configuration for CalCentral 5 | */ 6 | angular.module('calcentral.config').config(function($sceDelegateProvider) { 7 | $sceDelegateProvider.resourceUrlWhitelist([ 8 | 'self', 9 | // Youtube 10 | 'http://www.youtube.com/**', 11 | 'https://www.youtube.com/**' 12 | ]); 13 | }); 14 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/controllers/pages/academicSummaryController.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.controllers').controller('AcademicSummaryController', function(academicsFactory, academicsService, apiService, linkService, profileFactory, transferCreditFactory, $route, $scope) { 4 | apiService.util.setTitle('Academic Summary'); 5 | linkService.addCurrentRouteSettings($scope); 6 | }); 7 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/loan_history/resources.html: -------------------------------------------------------------------------------- 1 |
2 |

Resources

3 |
    4 |
  • 5 | 6 |

    7 |
  • 8 |
9 |
-------------------------------------------------------------------------------- /src/components/Form.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { Form as FormikForm } from 'formik'; 3 | import PropTypes from 'prop-types'; 4 | 5 | import styles from './Form.module.scss'; 6 | 7 | const Form = ({ children }) => ( 8 | {children} 9 | ); 10 | 11 | Form.propTypes = { 12 | children: PropTypes.node, 13 | }; 14 | 15 | export default Form; 16 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/exam_results_controller.rb: -------------------------------------------------------------------------------- 1 | class ExamResultsController < ApplicationController 2 | before_action :api_authenticate 3 | 4 | def get_exam_results 5 | render json: CampusSolutions::ExamResults.from_session(session).get_feed 6 | end 7 | 8 | def has_exam_results 9 | render json: CampusSolutions::HasExamResults.from_session(session).get_feed 10 | end 11 | 12 | end 13 | -------------------------------------------------------------------------------- /app/models/campus_solutions/advisor_student_relationship.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class AdvisorStudentRelationship < Proxy 3 | 4 | include CampusSolutionsIdRequired 5 | 6 | def xml_filename 7 | 'advisor_student_relationship.xml' 8 | end 9 | 10 | def url 11 | "#{@settings.base_url}/UC_AA_ADV_STDNT_REL.v1/?EMPLID=#{@campus_solutions_id}" 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/my_academics/messages.rb: -------------------------------------------------------------------------------- 1 | module MyAcademics 2 | class Messages 3 | 4 | def initialize(uid) 5 | @uid = uid 6 | end 7 | 8 | def merge(data) 9 | data[:messages] = get_messages 10 | end 11 | 12 | def get_messages 13 | CampusSolutions::MessageCatalog.get_message_collection([ 14 | :waitlisted_units_warning 15 | ]) 16 | end 17 | end 18 | end 19 | -------------------------------------------------------------------------------- /db/migrate/20130124104800_create_notifications.rb: -------------------------------------------------------------------------------- 1 | class CreateNotifications < ActiveRecord::Migration 2 | def up 3 | create_table :notifications do |t| 4 | t.string :uid 5 | t.text :data 6 | t.timestamps 7 | end 8 | 9 | change_table :notifications do |t| 10 | t.index :uid 11 | end 12 | end 13 | 14 | def down 15 | drop_table :notifications 16 | end 17 | 18 | end -------------------------------------------------------------------------------- /db/migrate/20130517231512_add_doug_au_to_user_auths.rb: -------------------------------------------------------------------------------- 1 | class AddDougAuToUserAuths < ActiveRecord::Migration 2 | def up 3 | Rails.logger.info "Flagging Doug Au(#{uid}) as a superuser" 4 | User::Auth.new_or_update_superuser! uid 5 | end 6 | 7 | def down 8 | User::Auth.where(:uid => uid).delete_all 9 | end 10 | 11 | private 12 | 13 | def uid 14 | '12492' 15 | end 16 | 17 | end 18 | -------------------------------------------------------------------------------- /src/assets/templates/directives/finaid_summary_item.html: -------------------------------------------------------------------------------- 1 |
2 |
3 | 4 | 5 |
6 |
11 |
12 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile/basic_name.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 |
7 | -------------------------------------------------------------------------------- /app/controllers/my_law_awards_controller.rb: -------------------------------------------------------------------------------- 1 | class MyLawAwardsController < ApplicationController 2 | def get_feed 3 | render json: HashConverter.camelize({ 4 | awards: MyAcademics::Law::Awards.new(user_id).awards, 5 | transcript_notes: MyAcademics::Law::TranscriptNotes.new(user_id).notes, 6 | }) 7 | end 8 | 9 | private 10 | 11 | def user_id 12 | session['user_id'] 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/campus_solutions/financial_aid_summary_link.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class FinancialAidSummaryLink 3 | 4 | def get_feed 5 | get_financial_aid_summary_link 6 | end 7 | 8 | def get_financial_aid_summary_link 9 | link = LinkFetcher.fetch_link('UC_FA_FINRES_FA_SUMMARY', {INSTITUTION: 'UCB01'}) 10 | { financialAidSummaryLink: link } 11 | end 12 | 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/campus_solutions/sir/my_deposit.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | module Sir 3 | class MyDeposit < UserSpecificModel 4 | 5 | include ClassLogger 6 | 7 | def get_feed 8 | logger.debug "User #{@uid}; aid adm_appl_nbr #{@options[:adm_appl_nbr]}" 9 | Deposit.new({user_id: @uid, adm_appl_nbr: @options[:adm_appl_nbr]}).get 10 | end 11 | 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/edo_oracle/career.rb: -------------------------------------------------------------------------------- 1 | module EdoOracle 2 | class Career < BaseProxy 3 | include ClassLogger 4 | 5 | def initialize(options = {}) 6 | super(Settings.edodb, options) 7 | end 8 | 9 | def fetch 10 | EdoOracle::Queries.get_careers(@uid) 11 | end 12 | 13 | def get_cumulative_units 14 | EdoOracle::Queries.get_cumulative_units(@uid) 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /fixtures/json/canvas_sis_import_users.json: -------------------------------------------------------------------------------- 1 | { 2 | "encoding": "US-ASCII", 3 | "string": "", 4 | "debug_json": { 5 | "created_at": "2013-06-11T09:55:07-07:00", 6 | "ended_at": null, 7 | "updated_at": "2013-06-11T09:55:08-07:00", 8 | "progress": 0, 9 | "id": 5842657, 10 | "workflow_state": "created", 11 | "data": { 12 | "import_type": "instructure_csv" 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /fixtures/json/hub_generic.json: -------------------------------------------------------------------------------- 1 | { 2 | "apiResponse": { 3 | "source": "UCB-SIS-STUDENT", 4 | "correlationId": "abcdef12-1234-4321-1234-abcdabcdabcd", 5 | "responseType": "http://bmeta.berkeley.edu/foo/barV0.xsd/foobar", 6 | "response": { 7 | "any": { 8 | "foobars": [ 9 | { 10 | "foo": "bar" 11 | } 12 | ] 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /spec/controllers/campus_solutions/state_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe CampusSolutions::StateController do 2 | context 'state feed' do 3 | let(:feed) { :get } 4 | it_behaves_like 'an unauthenticated user' 5 | context 'authenticated user' do 6 | let(:user_id) { random_id } 7 | let(:feed_path) { ['feed','states'] } 8 | it_behaves_like 'a successful feed' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/finaidTableDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Directive for finaid tables 5 | */ 6 | angular.module('calcentral.directives').directive('ccFinaidTableDirective', function() { 7 | return { 8 | templateUrl: 'directives/finaid_table.html', 9 | scope: { 10 | data: '=', 11 | toggle: '=', 12 | changeTags: '=' 13 | } 14 | }; 15 | }); 16 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_academic_plan.scss: -------------------------------------------------------------------------------- 1 | .cc-academic-plan-card { 2 | .cc-academic-plan-card-oldest-terms-note { 3 | margin: 0 15px 15px; 4 | } 5 | .cc-academic-plan-card-sub-title { 6 | font-size: 11px; 7 | } 8 | .cc-academic-plan-card-units { 9 | padding-right: 12px; 10 | } 11 | .cc-academic-plan-incomplete-notice { 12 | padding-bottom: 10px; 13 | padding-top: 0; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/components/ReduxProvider.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | import { Provider } from 'react-redux'; 4 | 5 | import store from 'Redux/store'; 6 | 7 | const ReduxProvider = ({ children }) => ( 8 | {children} 9 | ); 10 | 11 | ReduxProvider.propTypes = { 12 | children: PropTypes.node, 13 | }; 14 | 15 | export default ReduxProvider; 16 | -------------------------------------------------------------------------------- /Guardfile: -------------------------------------------------------------------------------- 1 | # A sample Guardfile 2 | # More info at https://github.com/guard/guard#readme 3 | 4 | guard 'livereload' do 5 | watch(%r{app/views/.+\.(erb|haml|slim)$}) 6 | watch(%r{app/helpers/.+\.rb}) 7 | watch(%r{public/.+\.(css|js|html)}) 8 | watch(%r{config/locales/.+\.yml}) 9 | # Rails Assets Pipeline 10 | watch(%r{(app|vendor)(/assets/\w+/(.+\.(css|js|html|png|jpg))).*}) { |m| "/assets/#{m[3]}" } 11 | end 12 | -------------------------------------------------------------------------------- /app/models/google_apps/revoke.rb: -------------------------------------------------------------------------------- 1 | module GoogleApps 2 | class Revoke < Proxy 3 | 4 | include ClassLogger 5 | 6 | def revoke 7 | unless (access_token = @authorization.access_token) 8 | logger.error "Nil access_token for #{@uid}; revoking Google OAuth privileges is not possible." 9 | return false 10 | end 11 | @authorization.revoke! 12 | end 13 | 14 | end 15 | end 16 | 17 | -------------------------------------------------------------------------------- /config/initializers/disable_webmock_default.rb: -------------------------------------------------------------------------------- 1 | # Webmock is enabled by default upon load, which causes issues with test utilities, 2 | # like Selenium. It's therefore disabled here and then enabled when 3 | # the backend rspec tests run, and when fake proxies are instantiated in the development 4 | # environment. 5 | 6 | if Settings.application.fake_proxies_enabled 7 | require 'webmock' 8 | WebMock.disable! 9 | end 10 | -------------------------------------------------------------------------------- /db/migrate/20131219130504_add_mike_blake_to_user_auths.rb: -------------------------------------------------------------------------------- 1 | class AddMikeBlakeToUserAuths < ActiveRecord::Migration 2 | def up 3 | Rails.logger.info "Flagging Mike Blake(#{uid}) as a superuser" 4 | User::Auth.new_or_update_superuser! uid 5 | end 6 | 7 | def down 8 | User::Auth.where(:uid => uid).delete_all 9 | end 10 | 11 | private 12 | 13 | def uid 14 | '1051203' 15 | end 16 | 17 | end 18 | -------------------------------------------------------------------------------- /fixtures/csv/Canvas_provisioning_report_courses_csv.csv: -------------------------------------------------------------------------------- 1 | canvas_course_id,course_id,short_name,long_name,canvas_account_id,account_id,canvas_term_id,term_id,status,start_date,end_date 2 | 1234001,CRS:MEC_ENG-124A-2015-B,MEC ENG 124A - LEC 001,Introduction to Patent Applications,129440,,5343,TERM:2015-B,active,, 3 | 999999,CRS:CLASSICS-45C-2015-B,CLASSICS 45C - LEC 002,Hellenism and Its Discontents,129440,,5343,TERM:2015-B,active,, 4 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/financial_aid_compare_awards_list.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 2015-2016 5 | Fall and Spring 6 | 7 | 2016-01-02-01.34.24 8 | 2016-01-06-02.49.12 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /spec/controllers/campus_solutions/country_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe CampusSolutions::CountryController do 2 | context 'country feed' do 3 | let(:feed) { :get } 4 | it_behaves_like 'an unauthenticated user' 5 | context 'authenticated user' do 6 | let(:user_id) { random_id } 7 | let(:feed_path) { ['feed','countries'] } 8 | it_behaves_like 'a successful feed' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /spec/ui_selenium/pages/my_profile_demographic_card.rb: -------------------------------------------------------------------------------- 1 | module CalCentralPages 2 | 3 | class MyProfileDemographicCard < MyProfilePage 4 | 5 | include PageObject 6 | include CalCentralPages 7 | include ClassLogger 8 | 9 | def load_page 10 | logger.debug 'Loading profile demographics page' 11 | navigate_to "#{WebDriverUtils.base_url}/profile/demographic" 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/factories/badgesFactory.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Badges Factory 5 | */ 6 | angular.module('calcentral.factories').factory('badgesFactory', function(apiService) { 7 | var url = '/api/my/badges'; 8 | 9 | var getBadges = function(options) { 10 | return apiService.http.request(options, url); 11 | }; 12 | 13 | return { 14 | getBadges: getBadges 15 | }; 16 | }); 17 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_datepicker.scss: -------------------------------------------------------------------------------- 1 | // CalCentral Date Picker Theme 2 | .cc-datepicker-theme { 3 | position: absolute; 4 | width: 260px; 5 | z-index: 100; 6 | .pika-next, .pika-prev { 7 | padding: 15px; 8 | text-indent: 40px; 9 | } 10 | table { 11 | thead { 12 | background: none; 13 | } 14 | thead tr th, table tbody tr td, tr td { 15 | padding: 0; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/assets/templates/advisor_acting_as.html: -------------------------------------------------------------------------------- 1 |
2 |

3 | You are viewing 's information. 4 | 5 |

6 |
7 | -------------------------------------------------------------------------------- /app/controllers/campus_solutions/work_experience_controller.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class WorkExperienceController < CampusSolutionsController 3 | 4 | before_action :exclude_acting_as_users 5 | 6 | def post 7 | post_passthrough CampusSolutions::MyWorkExperience 8 | end 9 | 10 | def delete 11 | delete_passthrough CampusSolutions::MyWorkExperience 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/controllers/my_textbooks_controller.rb: -------------------------------------------------------------------------------- 1 | class MyTextbooksController < ApplicationController 2 | 3 | before_action :api_authenticate 4 | 5 | def get_feed 6 | render json: Textbooks::Proxy.new({ 7 | course_catalog: params['courseCatalog'], 8 | slug: params['slug'], 9 | dept: params['department'], 10 | section_numbers: params['sectionNumbers'] 11 | }).get_as_json 12 | end 13 | 14 | end 15 | -------------------------------------------------------------------------------- /app/models/campus_solutions/advisor_student_action_items.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class AdvisorStudentActionItems < Proxy 3 | include CampusSolutionsIdRequired 4 | 5 | def xml_filename 6 | 'advisor_student_action_items.xml' 7 | end 8 | 9 | def url 10 | "#{@settings.base_url}/UC_AA_ADV_ACTION_ITEM.v1/?EMPLID=#{@campus_solutions_id}&CALLER_TYPE=ADVISOR" 11 | end 12 | 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /app/models/campus_solutions/emergency_loan_link.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class EmergencyLoanLink 3 | 4 | def get_feed 5 | get_emergency_loan_link 6 | end 7 | 8 | def get_emergency_loan_link 9 | link_config = { cs_link_key: 'UC_CX_EMERGENCY_LOAN_FORM' } 10 | link = LinkFetcher.fetch_link(link_config[:cs_link_key]) 11 | { emergencyLoan: link } 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/my_checklist.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class MyChecklist < UserSpecificModel 3 | 4 | include Cache::CachedFeed 5 | include Cache::UserCacheExpiry 6 | 7 | def get_feed_internal 8 | return {} unless HubEdos::UserAttributes.new(user_id: @uid).has_role?(:applicant, :student) 9 | CampusSolutions::Checklist.new({user_id: @uid}).get 10 | end 11 | 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/campus_solutions/student_term_gpa.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class StudentTermGpa < CachedProxy 3 | 4 | include StudentSuccessFeatureFlagged 5 | include CampusSolutionsIdRequired 6 | 7 | def url 8 | "#{@settings.base_url}/UC_AA_STDNT_GPA_TERMS.v1/get?EMPLID=#{@campus_solutions_id}" 9 | end 10 | 11 | def xml_filename 12 | 'student_term_gpa.xml' 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/canvas/todo.rb: -------------------------------------------------------------------------------- 1 | module Canvas 2 | class Todo < Proxy 3 | 4 | include Cache::UserCacheExpiry 5 | 6 | def todo 7 | wrapped_get request_path 8 | end 9 | 10 | private 11 | 12 | def mock_json 13 | read_file('fixtures', 'json', 'canvas_todo.json') 14 | end 15 | 16 | def request_path 17 | "users/self/todo?as_user_id=sis_login_id:#{@uid}" 18 | end 19 | end 20 | end 21 | -------------------------------------------------------------------------------- /config/initializers/secure_headers.rb: -------------------------------------------------------------------------------- 1 | # Configuration for the secure_headers gem, which sets X-Frame and CSP headers. 2 | module Calcentral 3 | class Application < Rails::Application 4 | config.before_initialize do 5 | ::SecureHeaders::Configuration.default do |config| 6 | config.x_frame_options = "DENY" 7 | config.x_xss_protection = "1; mode=block" 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /db/migrate/20150212155014_create_stored_uid_tables.rb: -------------------------------------------------------------------------------- 1 | class CreateStoredUidTables < ActiveRecord::Migration 2 | def change 3 | create_table :saved_uids do |t| 4 | t.string :owner_uid 5 | t.string :stored_uid 6 | t.timestamps 7 | end 8 | 9 | create_table :recent_uids do |t| 10 | t.string :owner_uid 11 | t.string :stored_uid 12 | t.timestamps 13 | end 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /fixtures/json/canvas_groups.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "avatar_url": null, 4 | "group_category_id": 18335, 5 | "name": "Canvas hackshop", 6 | "join_level": "invitation_only", 7 | "description": null, 8 | "is_public": false, 9 | "members_count": 2, 10 | "role": null, 11 | "context_type": "Account", 12 | "id": 73864, 13 | "followed_by_user": true, 14 | "account_id": 90242 15 | } 16 | ] 17 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/link_api_error.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Y 4 | 5 |
6 | 7 | 8 | 1000 9 | Invalid PROPNAME GROUPX 10 | E 11 | 12 | 13 |
14 |
15 |
16 | -------------------------------------------------------------------------------- /spec/factories/user_auths.rb: -------------------------------------------------------------------------------- 1 | FactoryBot.define do 2 | factory :user_auth, class: "User::Auth" do 3 | sequence(:uid) { |n| n } 4 | 5 | active { true } 6 | 7 | factory :viewer_auth do 8 | is_viewer { true } 9 | end 10 | 11 | factory :author_auth do 12 | is_author { true } 13 | end 14 | 15 | factory :superuser_auth do 16 | is_superuser { true } 17 | end 18 | end 19 | end 20 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/factories/myGroupsFactory.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * My Groups Factory 5 | */ 6 | angular.module('calcentral.factories').factory('myGroupsFactory', function(apiService) { 7 | var url = '/api/my/groups'; 8 | 9 | var getGroups = function(options) { 10 | return apiService.http.request(options, url); 11 | }; 12 | 13 | return { 14 | getGroups: getGroups 15 | }; 16 | }); 17 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/filters/dateUnlessNoonFilter.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.filters').filter('dateUnlessNoonFilter', function($filter) { 4 | return function(millisecondsEpoch, format) { 5 | var date = $filter('date')(millisecondsEpoch, format); 6 | date = date.replace('12:00 PM', 'Noon'); 7 | date = date.replace('12:00 AM', 'Midnight'); 8 | return date; 9 | }; 10 | }); 11 | -------------------------------------------------------------------------------- /src/assets/templates/delegate_acting_as.html: -------------------------------------------------------------------------------- 1 |
2 |

3 | You are viewing 's information. 4 | 5 |

6 |
7 | -------------------------------------------------------------------------------- /src/assets/templates/widgets/profile/basic_user_id.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 |
7 |
8 |
9 | -------------------------------------------------------------------------------- /src/react/components/_finances/TransactionsCard/BillingItem/ItemPayment.scss: -------------------------------------------------------------------------------- 1 | @import '../../../../stylesheets/variables'; 2 | 3 | .ItemPayment .flex { 4 | display: flex; 5 | justify-content: space-between; 6 | } 7 | 8 | .ItemPayment + .ItemPayment { 9 | margin-top: 10px; 10 | } 11 | 12 | .ItemPayment__paid-on { 13 | color: $color-dove-gray; 14 | } 15 | 16 | .ItemPayment__amount { 17 | padding-right: 12px; 18 | } 19 | -------------------------------------------------------------------------------- /app/controllers/my_awards_controller.rb: -------------------------------------------------------------------------------- 1 | class MyAwardsController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: FinancialAid::MyAwards.from_session(session, options).get_feed_as_json 8 | end 9 | 10 | private 11 | 12 | def options 13 | params.permit(:aid_year) 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/campus_solutions/summer_estimator_link.rb: -------------------------------------------------------------------------------- 1 | module CampusSolutions 2 | class SummerEstimatorLink 3 | 4 | def get_feed 5 | get_summer_estimator_link 6 | end 7 | 8 | def get_summer_estimator_link 9 | link_config = { cs_link_key: 'UC_FA_SUMMR_EST_FLU' } 10 | link = LinkFetcher.fetch_link(link_config[:cs_link_key]) 11 | { summerEstimator: link } 12 | end 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/hub_edos/cached_proxy.rb: -------------------------------------------------------------------------------- 1 | module HubEdos 2 | # Intended to override #get in classes inheriting from HubEdos::Proxy 3 | module CachedProxy 4 | def get(opts = {}) 5 | return {} unless is_feature_enabled 6 | response = self.class.smart_fetch_from_cache(opts.merge(id: instance_key)) do 7 | get_internal 8 | end 9 | process_response_after_caching response 10 | end 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /fixtures/xml/campus_solutions/message_catalog.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 26500 5 | 112 6 | Reduce/Cancel: Max Cancelable Amount is Zero 7 | M 8 | YOU CANNOT REDUCE OR CANCEL THIS LOAN. 9 | 10 | 11 | -------------------------------------------------------------------------------- /script/upgrade.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ###################################################### 4 | # 5 | # Upgrade CalCentral: get code, build, db migration, and restart. 6 | # 7 | ###################################################### 8 | 9 | cd $( dirname "${BASH_SOURCE[0]}" )/.. 10 | 11 | ./script/init.d/calcentral maint 12 | 13 | ./script/update-build.sh || { echo "ERROR: update-build failed"; exit 1; } 14 | 15 | exit 0 16 | -------------------------------------------------------------------------------- /spec/controllers/campus_solutions/translate_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe CampusSolutions::TranslateController do 2 | context 'translate feed' do 3 | let(:feed) { :get } 4 | it_behaves_like 'an unauthenticated user' 5 | context 'authenticated user' do 6 | let(:user_id) { random_id } 7 | let(:feed_path) { ['feed','xlatvalues'] } 8 | it_behaves_like 'a successful feed' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/expectedGraduationTermsDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.module('calcentral.directives').directive('ccExpectedGraduationTermsDirective', [function() { 4 | return { 5 | templateUrl: 'directives/expected_graduation_terms.html', 6 | scope: { 7 | termsInAttendance: '=', 8 | graduation: '=', 9 | isAdvisingStudentLookup: '=' 10 | } 11 | }; 12 | }]); 13 | -------------------------------------------------------------------------------- /src/assets/stylesheets/_calcentral_update.scss: -------------------------------------------------------------------------------- 1 | .cc-page-calcentral-update { 2 | 3 | .cc-page-calcentral-update-body { 4 | margin-top: 10px; 5 | p { 6 | margin: 10px 0; 7 | } 8 | } 9 | 10 | .cc-page-calcentral-update-container { 11 | margin: 15px; 12 | } 13 | 14 | .cc-page-calcentral-update-date { 15 | color: $color-orient; 16 | font-size: 15px; 17 | font-weight: bold; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/Switcher.module.scss: -------------------------------------------------------------------------------- 1 | .tasksCard { 2 | margin-right: 15px; 3 | } 4 | 5 | .fullWidthContainer { 6 | margin: 0 -15px -15px; 7 | } 8 | 9 | .textContainer { 10 | padding: 15px; 11 | 12 | p:last-child { 13 | margin-bottom: 0; 14 | } 15 | } 16 | 17 | .buttonContainer { 18 | overflow: hidden; 19 | margin-left: auto; 20 | margin-right: auto; 21 | margin-top: 15px; 22 | } 23 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TasksCard.module.scss: -------------------------------------------------------------------------------- 1 | .tasksCard { 2 | margin-right: 15px; 3 | } 4 | 5 | .fullWidthContainer { 6 | margin: 0 -15px -15px; 7 | } 8 | 9 | .textContainer { 10 | padding: 15px; 11 | 12 | p:last-child { 13 | margin-bottom: 0; 14 | } 15 | } 16 | 17 | .buttonContainer { 18 | overflow: hidden; 19 | margin-left: auto; 20 | margin-right: auto; 21 | margin-top: 15px; 22 | } 23 | -------------------------------------------------------------------------------- /app/controllers/my_housing_controller.rb: -------------------------------------------------------------------------------- 1 | class MyHousingController < ApplicationController 2 | include AllowDelegateViewAs 3 | before_action :api_authenticate_401 4 | before_action :authorize_for_financial 5 | 6 | def get_feed 7 | render json: FinancialAid::MyHousing.from_session(session, options).get_feed_as_json 8 | end 9 | 10 | private 11 | 12 | def options 13 | params.permit(:aid_year) 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /app/models/user/saved_uid.rb: -------------------------------------------------------------------------------- 1 | module User 2 | class SavedUid < ApplicationRecord 3 | include ActiveRecordHelper, OraclePrimaryHelper 4 | 5 | self.table_name = 'PS_UC_SAVED_UIDS' 6 | self.primary_key = 'uc_clc_id' 7 | 8 | belongs_to :data, :class_name => 'User::Data', :foreign_key => 'uc_clc_oid' 9 | 10 | alias_attribute :stored_uid, :uc_clc_stor_id 11 | 12 | before_create :set_id 13 | 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /spec/controllers/campus_solutions/address_label_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe CampusSolutions::AddressLabelController do 2 | context 'address label feed' do 3 | let(:feed) { :get } 4 | it_behaves_like 'an unauthenticated user' 5 | context 'authenticated user' do 6 | let(:user_id) { '12345' } 7 | let(:feed_path) { ['feed', 'labels'] } 8 | it_behaves_like 'a successful feed' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/CompletedTasks/CategoryTitle.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | 4 | import styles from './CategoryTitle.module.scss'; 5 | 6 | const CategoryTitle = ({ children }) => { 7 | return

{children}

; 8 | }; 9 | 10 | CategoryTitle.propTypes = { 11 | children: PropTypes.node, 12 | }; 13 | 14 | export default CategoryTitle; 15 | -------------------------------------------------------------------------------- /src/react/components/_finances/AwardComparison/aidYearShape.js: -------------------------------------------------------------------------------- 1 | import PropTypes from 'prop-types'; 2 | 3 | const aidYearShape = PropTypes.shape({ 4 | cost: PropTypes.shape({ 5 | total: PropTypes.number, 6 | items: PropTypes.arrayOf( 7 | PropTypes.shape({ 8 | description: PropTypes.string, 9 | value: PropTypes.number, 10 | }) 11 | ), 12 | }), 13 | }); 14 | 15 | export default aidYearShape; 16 | -------------------------------------------------------------------------------- /app/models/concerns/query_helper.rb: -------------------------------------------------------------------------------- 1 | module Concerns 2 | module QueryHelper 3 | 4 | UC_BERKELEY = 'UCB01' 5 | 6 | def self.included(target) 7 | target.extend ClassMethods 8 | end 9 | 10 | module ClassMethods 11 | 12 | def and_institution(object_alias) 13 | <<-SQL 14 | AND #{object_alias}.INSTITUTION = '#{UC_BERKELEY}' 15 | SQL 16 | end 17 | end 18 | 19 | end 20 | end 21 | -------------------------------------------------------------------------------- /config/settings/server_config.sample.yml: -------------------------------------------------------------------------------- 1 | # This should be moved to wherever deploy.rb references (~/.calcentral_config/) 2 | common: 3 | user: "some user" 4 | branch: "a branch" 5 | root: "remote root project directory" 6 | dev: 7 | servers: 8 | - "server 1" 9 | - "server 2" 10 | - "server 3" 11 | 12 | sandbox: 13 | servers: 14 | - "server 1" 15 | branch: "a branch" 16 | root: "remote root project directory" 17 | -------------------------------------------------------------------------------- /fixtures/json/canvas_check_provisioning_report_sections.json: -------------------------------------------------------------------------------- 1 | { 2 | "id": 11938, 3 | "parameters": { 4 | "enrollment_term": "sis_term_id:TERM:2013-D", 5 | "sections": "1", 6 | "extra_text": "Term: Fall 2013; Reports: sections " 7 | }, 8 | "progress": 100, 9 | "status": "complete", 10 | "report": "provisioning_csv", 11 | "file_url": "https://ucberkeley.instructure.com/accounts/90242/files/35810460/download" 12 | } 13 | -------------------------------------------------------------------------------- /spec/ui_selenium/pages/my_profile_info_disclosure_card.rb: -------------------------------------------------------------------------------- 1 | module CalCentralPages 2 | 3 | class MyProfileInfoDisclosureCard 4 | 5 | include PageObject 6 | include CalCentralPages 7 | include ClassLogger 8 | 9 | def load_page 10 | logger.debug 'Loading profile information disclosure page' 11 | navigate_to "#{WebDriverUtils.base_url}/profile/information-disclosure" 12 | end 13 | 14 | end 15 | 16 | end 17 | -------------------------------------------------------------------------------- /Rakefile: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env rake 2 | # Add your own tasks in files placed in lib/tasks ending in .rake, 3 | # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. 4 | 5 | require File.expand_path('../config/application', __FILE__) 6 | 7 | Calcentral::Application.load_tasks 8 | 9 | # Rails.logger might not be initialized for certain rake tasks, see calcentral_config.rb 10 | Rails.logger ||= Logger.new(STDOUT) 11 | -------------------------------------------------------------------------------- /app/models/user/b_courses/concern.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module BCourses 3 | module Concern 4 | extend ActiveSupport::Concern 5 | 6 | included do 7 | def b_courses 8 | @b_courses ||= ::User::BCourses::BCourses.new(self) 9 | end 10 | 11 | def has_canvas_access? 12 | @has_canvas_access ||= Canvas::Proxy.access_granted?(uid) 13 | end 14 | end 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /app/models/user/finances/transactions.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Finances 3 | class Transactions 4 | include Cache::CachedFeed 5 | include Cache::UserCacheExpiry 6 | 7 | def initialize(uid) 8 | @uid = uid 9 | end 10 | 11 | def instance_key 12 | @uid 13 | end 14 | 15 | def get_feed_internal 16 | Queries.transactions_for(@uid) 17 | end 18 | end 19 | end 20 | end 21 | -------------------------------------------------------------------------------- /app/models/user/notifications/cached_feed.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Notifications 3 | class CachedFeed < UserSpecificModel 4 | include Cache::CachedFeed 5 | include Cache::JsonifiedFeed 6 | include Cache::UserCacheExpiry 7 | 8 | def get_feed_internal 9 | user.notifications 10 | end 11 | 12 | def user 13 | @user ||= User::Current.new(@uid) 14 | end 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /config/settings/server_config.rb: -------------------------------------------------------------------------------- 1 | require_relative '../../lib/calcentral_config' 2 | require 'yaml' 3 | 4 | module ServerConfig 5 | extend self 6 | 7 | def get_settings(source_file) 8 | 9 | if File.exists?(source_file) 10 | source = YAML.load(ERB.new(IO.read(source_file.to_s)).result) 11 | end 12 | source ||= false 13 | 14 | settings = CalcentralConfig.deep_open_struct(source) 15 | settings 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /spec/controllers/campus_solutions/language_code_controller_spec.rb: -------------------------------------------------------------------------------- 1 | describe CampusSolutions::LanguageCodeController do 2 | context 'language codes feed' do 3 | let(:feed) { :get } 4 | it_behaves_like 'an unauthenticated user' 5 | context 'authenticated user' do 6 | let(:user_id) { '12345' } 7 | let(:feed_path) { ['feed','accomplishments'] } 8 | it_behaves_like 'a successful feed' 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /spec/models/student_success/oustanding_balance_spec.rb: -------------------------------------------------------------------------------- 1 | describe StudentSuccess::OutstandingBalance do 2 | 3 | context 'a mock proxy' do 4 | before do 5 | allow(Settings.campus_solutions_proxy).to receive(:fake).and_return true 6 | end 7 | it 'correctly parses the feed' do 8 | result = StudentSuccess::OutstandingBalance.new(user_id: 61889).merge 9 | expect(result).to eq 153.0 10 | end 11 | end 12 | 13 | end 14 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/directives/bcIframeResizeDirective.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Used to resize the iframe for bCourses embedded applications based on the DIV wrapper 5 | */ 6 | angular.module('calcentral.directives').directive('bcIframeResize', function(apiService) { 7 | return { 8 | restrict: 'A', 9 | link: function(scope, elm) { 10 | apiService.util.iframeUpdateHeight(elm); 11 | } 12 | }; 13 | }); 14 | -------------------------------------------------------------------------------- /src/assets/javascripts/angular/factories/serverInfoFactory.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Server Info Factory 5 | */ 6 | angular.module('calcentral.factories').factory('serverInfoFactory', function(apiService) { 7 | var url = '/api/server_info'; 8 | 9 | var getServerInfo = function(options) { 10 | return apiService.http.request(options, url); 11 | }; 12 | 13 | return { 14 | getServerInfo: getServerInfo 15 | }; 16 | }); 17 | -------------------------------------------------------------------------------- /src/react/components/_dashboard/TasksCard/TaskHeader.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PropTypes from 'prop-types'; 3 | 4 | import styles from './TaskHeader.module.scss'; 5 | 6 | const TaskHeader = ({ children }) => { 7 | return
{children}
; 8 | }; 9 | 10 | TaskHeader.propTypes = { 11 | children: PropTypes.node, 12 | isOverdue: PropTypes.bool, 13 | }; 14 | 15 | export default TaskHeader; 16 | -------------------------------------------------------------------------------- /app/controllers/user/academics/diploma_controller.rb: -------------------------------------------------------------------------------- 1 | module User 2 | module Academics 3 | class DiplomaController < ApplicationController 4 | include AllowDelegateViewAs 5 | 6 | # GET /api/my/academics/diploma(.:format) 7 | def index 8 | render json: user.diploma.get_feed.to_json 9 | end 10 | 11 | def user 12 | User::Current.new(session['user_id']) 13 | end 14 | end 15 | end 16 | end 17 | -------------------------------------------------------------------------------- /script/monitor.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | DELAY=$1 4 | if [ -z "$1" ]; then 5 | DELAY=30 6 | fi 7 | 8 | while true; do 9 | STATS=`(sleep 1 ; echo "stats"; sleep 1; echo "quit") | telnet $HOSTNAME 11211` 10 | echo "===========================================" 11 | echo `date` 12 | jmap -heap `jps -mlv|grep 'torquebox-server'|head -1|awk '{print $1}'` 13 | echo $STATS | awk -F"STAT" '{for(i=2;i