Library reference and css reference update

This commit is contained in:
PMKuipers 2023-09-08 09:03:30 +02:00
parent d043d3c465
commit 919ec571c8
4 changed files with 16 additions and 6 deletions

View File

@ -18,7 +18,7 @@ import {load_strings} from 'local_treestudyplan/util/string-helper';
import {ProcessStudyplans} from 'local_treestudyplan/studyplan-processor'; import {ProcessStudyplans} from 'local_treestudyplan/studyplan-processor';
import PortalVue from 'local_treestudyplan/portal-vue/portal-vue.esm'; import PortalVue from 'local_treestudyplan/portal-vue/portal-vue.esm';
import BootstrapVue from 'local_treestudyplan/bootstrap-vue/bootstrap-vue.esm'; import BootstrapVue from 'local_treestudyplan/bootstrap-vue/bootstrap-vue';
Vue.use(TSComponents); Vue.use(TSComponents);
Vue.use(RVComponents); Vue.use(RVComponents);
Vue.use(PortalVue); Vue.use(PortalVue);

View File

@ -46,8 +46,11 @@ class block_mytreestudyplan extends \block_base {
// Load CSS files from treestudyplan. // Load CSS files from treestudyplan.
try { try {
$this->page->requires->css(new \moodle_url($CFG->wwwroot.'/local/treestudyplan/css/bootstrap-vue.min.css')); $this->page->requires->css(new \moodle_url($CFG->wwwroot.'/local/treestudyplan/css/bootstrap-vue/bootstrap-vue.min.css'));
$this->page->requires->css(new \moodle_url($CFG->wwwroot.'/local/treestudyplan/css/devstyles.css')); if($CFG->debugdeveloper){
$this->page->requires->css(new moodle_url($CFG->wwwroot.'/local/treestudyplan/css/devstyles.css'));
}
$this->page->add_body_class("features-treestudyplan"); // Mark body as containing treestudyplan content.
// Include javascript and run studyplan renderer when page loading is complete. // Include javascript and run studyplan renderer when page loading is complete.
$this->page->requires->js_call_amd('block_mytreestudyplan/block_mytreestudyplan', $this->page->requires->js_call_amd('block_mytreestudyplan/block_mytreestudyplan',
'init', 'init',
@ -125,4 +128,11 @@ class block_mytreestudyplan extends \block_base {
public function has_config() { public function has_config() {
return false; return false;
} }
/**
* Return true to avoid broken self-test message
*/
function _self_test() {
return true;
}
} }

View File

@ -33,7 +33,7 @@
} }
}} }}
<div id='block_mytreestudyplan' class='features-treestudyplan'> <div id='block_mytreestudyplan'>
<div class='vue-loader' v-show='false'> <div class='vue-loader' v-show='false'>
<div class='spinner-border text-primary' role='status'> <div class='spinner-border text-primary' role='status'>
<span class='sr-only'>Loading...</span> <span class='sr-only'>Loading...</span>

View File

@ -22,7 +22,7 @@
defined('MOODLE_INTERNAL') || die(); defined('MOODLE_INTERNAL') || die();
$plugin->component = 'block_mytreestudyplan'; // Recommended since 2.0.2 (MDL-26035). Required since 3.0 (MDL-48494). $plugin->component = 'block_mytreestudyplan'; // Recommended since 2.0.2 (MDL-26035). Required since 3.0 (MDL-48494).
$plugin->version = 2023081800; // YYYYMMDDHH (year, month, day, iteration). $plugin->version = 2023090800; // YYYYMMDDHH (year, month, day, iteration).
$plugin->requires = 2021051700; // YYYYMMDDHH (This is the release version for Moodle 3.11). $plugin->requires = 2021051700; // YYYYMMDDHH (This is the release version for Moodle 3.11).
$plugin->release = "1.0.0"; $plugin->release = "1.0.0";
@ -31,5 +31,5 @@ $plugin->maturity = MATURITY_RC;
$plugin->supported = [ 311, 401 ]; $plugin->supported = [ 311, 401 ];
$plugin->dependencies = [ $plugin->dependencies = [
'local_treestudyplan' => 2023082101, 'local_treestudyplan' => 2023090700,
]; ];