░▒▓████████████████████████████████▓▒░ ░▒▓█ ▓▒░ ░▒▓█ ~ S W A M P ~ ▓▒░ ░▒▓█ ▓▒░ ░▒▓████████████████████████████████▓▒░
pplmvsvm
LOCATION:
/var/www/canvas/ui/features/account_grading_settings/pages
☗ ROOT
↻ REFRESH
✎ CARVE FLESH
EDITING: AccountGradingPeriods.tsx
/* * Copyright (C) 2023 - present Instructure, Inc. * * This file is part of Canvas. * * Canvas is free software: you can redistribute it and/or modify it under * the terms of the GNU Affero General Public License as published by the Free * Software Foundation, version 3 of the License. * * Canvas is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR * A PARTICULAR PURPOSE. See the GNU Affero General Public License for more * details. * * You should have received a copy of the GNU Affero General Public License along * with this program. If not, see <http://www.gnu.org/licenses/>. */ import React, {useEffect} from 'react' import {useMatch} from 'react-router-dom' import GradingPeriodSetCollection from '../components/grading_period/GradingPeriodSetCollection' export const AccountGradingPeriods = () => { const pathMatch = useMatch('/accounts/:accountId/*') if (!pathMatch || !pathMatch.params || !pathMatch.params.accountId) { throw new Error('account id is not present on path') } const accountId = pathMatch.params.accountId // Note: these env vars are required downstream in api callers used by the grading periods management page, // in addition to being required to be passed in to this component itself as props ENV.ENROLLMENT_TERMS_URL = `/api/v1/accounts/${accountId}/terms` ENV.GRADING_PERIOD_SETS_URL = `/api/v1/accounts/${accountId}/grading_period_sets` ENV.GRADING_PERIOD_SET_UPDATE_URL = `/api/v1/accounts/${accountId}/grading_period_sets/{{id}}` ENV.GRADING_PERIODS_UPDATE_URL = `/api/v1/grading_period_sets/{{set_id}}/grading_periods/batch_update` const urls = { enrollmentTermsURL: ENV.ENROLLMENT_TERMS_URL, gradingPeriodsUpdateURL: ENV.GRADING_PERIODS_UPDATE_URL, gradingPeriodSetsURL: ENV.GRADING_PERIOD_SETS_URL, deleteGradingPeriodURL: `/api/v1/accounts/${accountId}/grading_periods/{{id}}`, } useEffect(() => { document.title = 'Account Grading Periods' }, []) return <GradingPeriodSetCollection readOnly={false} urls={urls} /> }
CANCEL
Name
Type
Size
Modified
Actions
↩ ..
DIR
—
—
📄 AccountGradingPeriods.tsx
TSX
2.1 KB
2023-09-24 03:39
EDIT
📄 AccountGradingSchemes.tsx
TSX
1.2 KB
2023-09-24 03:39
EDIT
📄 TabLayout.tsx
TSX
2.4 KB
2023-09-24 03:39
EDIT