Skip to content

Commit

Permalink
MDL-72154 calendar: Remove unnecessary strings/link from import page
Browse files Browse the repository at this point in the history
  • Loading branch information
mickhawkins committed Jul 21, 2021
1 parent 8453fe0 commit 45fc997
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 7 deletions.
1 change: 0 additions & 1 deletion calendar/classes/local/event/forms/managesubscriptions.php
Expand Up @@ -53,7 +53,6 @@ public function definition() {
$mform->setType('name', PARAM_TEXT);

// Import from (url | importfile).
$mform->addElement('html', get_string('importfrominstructions', 'calendar'));
$choices = array(CALENDAR_IMPORT_FROM_FILE => get_string('importfromfile', 'calendar'),
CALENDAR_IMPORT_FROM_URL => get_string('importfromurl', 'calendar'));
$mform->addElement('select', 'importfrom', get_string('importcalendarfrom', 'calendar'), $choices);
Expand Down
4 changes: 0 additions & 4 deletions calendar/import.php
Expand Up @@ -117,15 +117,11 @@
redirect($managesubscriptionsurl, $importresults);
}

$calendarsubscriptions = get_string('calendarsubscriptions', 'calendar');

$renderer = $PAGE->get_renderer('core_calendar');

echo $OUTPUT->header();
echo $renderer->start_layout();
echo $OUTPUT->heading($heading);
$form->display();
echo $OUTPUT->spacer(null, true);
echo $OUTPUT->action_link($managesubscriptionsurl, $OUTPUT->larrow() . ' ' . $calendarsubscriptions);
echo $renderer->complete_layout();
echo $OUTPUT->footer();
3 changes: 1 addition & 2 deletions lang/en/calendar.php
Expand Up @@ -32,7 +32,6 @@
$string['calendarheading'] = '{$a} Calendar';
$string['calendarpreferences'] = 'Calendar preferences';
$string['calendartypes'] = 'Calendar types';
$string['calendarsubscriptions'] = 'Calendar subscriptions';
$string['calendarurlcopiedtoclipboard'] = 'Calendar URL copied to clipboard';
$string['category'] = 'Category';
$string['categoryevent'] = 'Category event';
Expand Down Expand Up @@ -172,7 +171,6 @@
$string['importcalendarfrom'] = 'Import from';
$string['importfromfile'] = 'Calendar file (.ics)';
$string['importfromurl'] = 'Calendar URL';
$string['importfrominstructions'] = 'Please provide either a URL to a remote calendar, or upload a file.';
$string['invalidtimedurationminutes'] = 'The duration in minutes you have entered is invalid. Please enter the duration in minutes greater than 0 or select no duration.';
$string['invalidtimedurationuntil'] = 'The date and time you selected for duration until is before the start time of the event. Please correct this before proceeding.';
$string['invalideventtype'] = 'The event type you have selected is invalid.';
Expand Down Expand Up @@ -284,6 +282,7 @@

// Deprecated since Moodle 4.0.
$string['calendarurl'] = 'Calendar URL: {$a}';
$string['importfrominstructions'] = 'Please provide either a URL to a remote calendar, or upload a file.';

// Deprecated since Moodle 3.8.
$string['global'] = 'Global';
Expand Down
1 change: 1 addition & 0 deletions lang/en/deprecated.txt
Expand Up @@ -155,3 +155,4 @@ configenableactivitychooser,core_admin
enableactivitychooser,core_admin
coursepreferences,core
yourprogress,core_completion
importfrominstructions,core_calendar

0 comments on commit 45fc997

Please sign in to comment.