diff --git a/.meteor/packages b/.meteor/packages index c866ba8..4af5ec1 100644 --- a/.meteor/packages +++ b/.meteor/packages @@ -4,29 +4,27 @@ # 'meteor add' and 'meteor remove' will edit this file for you, # but you can also edit it by hand. -meteor-base@1.5.1 # Packages every Meteor app needs to have -mobile-experience@1.1.1 # Packages for a great mobile UX -mongo@1.16.10 # The database Meteor supports right now +meteor-base@1.5.2 # Packages every Meteor app needs to have +mobile-experience@1.1.2 # Packages for a great mobile UX +mongo@2.1.2 # The database Meteor supports right now blaze-html-templates # Compile .html files into Meteor Blaze views jquery # Wrapper package for npm-installed jquery -reactive-var@1.0.12 # Reactive variable for tracker -tracker@1.3.3 # Meteor's client-side reactive programming library +reactive-var@1.0.13 # Reactive variable for tracker +tracker@1.3.4 # Meteor's client-side reactive programming library -standard-minifier-css@1.9.2 # CSS minifier run for production mode -standard-minifier-js@2.8.1 # JS minifier run for production mode -es5-shim@4.8.0 # ECMAScript 5 compatibility for older browsers -ecmascript@0.16.8 # Enable ECMAScript2015+ syntax in app code -typescript@4.9.5 # Enable TypeScript syntax in .ts and .tsx modules -shell-server@0.5.0 # Server-side component of the `meteor shell` command +standard-minifier-css@1.9.3 # CSS minifier run for production mode +standard-minifier-js@3.1.0 # JS minifier run for production mode +es5-shim@4.8.1 # ECMAScript 5 compatibility for older browsers +ecmascript@0.16.11 # Enable ECMAScript2015+ syntax in app code +typescript@5.6.4 # Enable TypeScript syntax in .ts and .tsx modules +shell-server@0.6.1 # Server-side component of the `meteor shell` command -hot-module-replacement@0.5.3 # Update code in development without reloading the page +hot-module-replacement@0.5.4 # Update code in development without reloading the page blaze-hot # Update files using Blaze's API with HMR -alanning:roles@2.2.0 -email@2.2.6 -session@1.2.1 - -raix:handlebar-helpers -kadira:flow-router -kadira:blaze-layout -accounts-password@2.4.0 +roles@1.0.1 +session@1.2.2 +email@3.1.2 +arianjahiri:meteor-handlebars-helpers +ostrio:flow-router-extra +accounts-password@3.2.0 diff --git a/.meteor/release b/.meteor/release index 5152abe..d515fb7 100644 --- a/.meteor/release +++ b/.meteor/release @@ -1 +1 @@ -METEOR@2.16 +METEOR@3.3 diff --git a/.meteor/versions b/.meteor/versions index 6007c47..17cd573 100644 --- a/.meteor/versions +++ b/.meteor/versions @@ -1,94 +1,94 @@ -accounts-base@2.2.11 -accounts-password@2.4.0 -alanning:roles@2.2.0 -allow-deny@1.1.1 -autoupdate@1.8.0 -babel-compiler@7.10.5 -babel-runtime@1.5.1 -base64@1.0.12 -binary-heap@1.0.11 -blaze@2.9.0 -blaze-hot@1.1.2 -blaze-html-templates@1.2.1 -blaze-tools@1.1.4 -boilerplate-generator@1.7.2 -caching-compiler@1.2.2 -caching-html-compiler@1.2.2 -callback-hook@1.5.1 -check@1.4.1 -ddp@1.4.1 -ddp-client@2.6.2 -ddp-common@1.4.1 -ddp-rate-limiter@1.2.1 -ddp-server@2.7.1 -deps@1.0.12 -diff-sequence@1.1.2 -dynamic-import@0.7.3 -ecmascript@0.16.8 -ecmascript-runtime@0.8.1 -ecmascript-runtime-client@0.12.1 -ecmascript-runtime-server@0.11.0 -ejson@1.1.3 -email@2.2.6 -es5-shim@4.8.0 -fetch@0.1.4 -geojson-utils@1.0.11 -hot-code-push@1.0.4 -hot-module-replacement@0.5.3 -html-tools@1.1.4 -htmljs@1.2.1 -id-map@1.1.1 -inter-process-messaging@0.1.1 -jquery@3.0.0 -kadira:blaze-layout@2.0.1 -kadira:flow-router@2.12.1 -launch-screen@2.0.0 -localstorage@1.2.0 -logging@1.3.4 -meteor@1.11.5 -meteor-base@1.5.1 -minifier-css@1.6.4 -minifier-js@2.8.0 -minimongo@1.9.4 -mobile-experience@1.1.1 -mobile-status-bar@1.1.0 -modern-browsers@0.1.10 -modules@0.20.0 -modules-runtime@0.13.1 -modules-runtime-hot@0.14.2 -mongo@1.16.10 -mongo-decimal@0.1.3 -mongo-dev-server@1.1.0 -mongo-id@1.0.8 -npm-mongo@4.17.2 -observe-sequence@1.0.22 -ordered-dict@1.1.0 -promise@0.12.2 -raix:handlebar-helpers@0.2.5 -random@1.2.1 -rate-limit@1.1.1 -react-fast-refresh@0.2.8 -reactive-dict@1.3.1 -reactive-var@1.0.12 -reload@1.3.1 -retry@1.1.0 -routepolicy@1.1.1 -session@1.2.1 -sha@1.0.9 -shell-server@0.5.0 -socket-stream-client@0.5.2 -spacebars@1.6.0 -spacebars-compiler@1.3.2 -standard-minifier-css@1.9.2 -standard-minifier-js@2.8.1 -templating@1.4.3 -templating-compiler@1.4.2 -templating-runtime@1.6.4 -templating-tools@1.2.3 -tracker@1.3.3 -typescript@4.9.5 -ui@1.0.13 -underscore@1.6.2 -url@1.3.2 -webapp@1.13.8 -webapp-hashing@1.1.1 +accounts-base@3.1.1 +accounts-password@3.2.0 +allow-deny@2.1.0 +arianjahiri:meteor-handlebars-helpers@0.0.1 +autoupdate@2.0.1 +babel-compiler@7.12.0 +babel-runtime@1.5.2 +base64@1.0.13 +binary-heap@1.0.12 +blaze@3.0.2 +blaze-hot@2.0.0 +blaze-html-templates@3.0.0 +blaze-tools@2.0.0 +boilerplate-generator@2.0.1 +caching-compiler@2.0.1 +caching-html-compiler@2.0.0 +callback-hook@1.6.0 +check@1.4.4 +core-runtime@1.0.0 +ddp@1.4.2 +ddp-client@3.1.1 +ddp-common@1.4.4 +ddp-rate-limiter@1.2.2 +ddp-server@3.1.2 +deps@1.0.5-pre.1 +diff-sequence@1.1.3 +dynamic-import@0.7.4 +ecmascript@0.16.11 +ecmascript-runtime@0.8.3 +ecmascript-runtime-client@0.12.3 +ecmascript-runtime-server@0.11.1 +ejson@1.1.5 +email@3.1.2 +es5-shim@4.8.1 +facts-base@1.0.2 +fetch@0.1.6 +geojson-utils@1.0.12 +hot-code-push@1.0.5 +hot-module-replacement@0.5.4 +html-tools@2.0.0 +htmljs@2.0.1 +id-map@1.2.0 +inter-process-messaging@0.1.2 +jquery@3.0.2 +launch-screen@2.0.1 +localstorage@1.2.1 +logging@1.3.6 +meteor@2.1.1 +meteor-base@1.5.2 +minifier-css@2.0.1 +minifier-js@3.0.2 +minimongo@2.0.2 +mobile-experience@1.1.2 +mobile-status-bar@1.1.1 +modern-browsers@0.2.2 +modules@0.20.3 +modules-runtime@0.13.2 +modules-runtime-hot@0.14.3 +mongo@2.1.2 +mongo-decimal@0.2.0 +mongo-dev-server@1.1.1 +mongo-id@1.0.9 +npm-mongo@6.10.2 +observe-sequence@2.0.0 +ordered-dict@1.2.0 +ostrio:flow-router-extra@3.12.0 +promise@1.0.0 +random@1.2.2 +rate-limit@1.1.2 +react-fast-refresh@0.2.9 +reactive-dict@1.3.2 +reactive-var@1.0.13 +reload@1.3.2 +retry@1.1.1 +roles@1.0.1 +routepolicy@1.1.2 +session@1.2.2 +sha@1.0.10 +shell-server@0.6.1 +socket-stream-client@0.6.1 +spacebars@2.0.0 +spacebars-compiler@2.0.0 +standard-minifier-css@1.9.3 +standard-minifier-js@3.1.0 +templating@1.4.4 +templating-compiler@2.0.0 +templating-runtime@2.0.1 +templating-tools@2.0.0 +tracker@1.3.4 +typescript@5.6.4 +underscore@1.6.4 +url@1.3.5 +webapp@2.0.7 +webapp-hashing@1.1.2 diff --git a/client/Accounts/Login/login.js b/client/Accounts/Login/login.js index 7f3c38a..d251060 100644 --- a/client/Accounts/Login/login.js +++ b/client/Accounts/Login/login.js @@ -1,4 +1,5 @@ import { SysConfig } from '../../../imports/api/systemConfig.js'; +import { FlowRouter } from 'meteor/ostrio:flow-router-extra'; Template.login.onCreated(function() { this.subscribe("SystemConfig"); diff --git a/client/Accounts/Login/reg.js b/client/Accounts/Login/reg.js index c2ddbe2..8bf158e 100644 --- a/client/Accounts/Login/reg.js +++ b/client/Accounts/Login/reg.js @@ -1,4 +1,5 @@ import { SysConfig } from "../../../imports/api/systemConfig.js"; +import { FlowRouter } from 'meteor/ostrio:flow-router-extra'; Template.reg.onCreated(function() { this.subscribe("SystemConfig"); @@ -29,12 +30,15 @@ Template.reg.helpers({ return Session.get("missingReq"); }, allowReg: function() { - let conf = SysConfig.findOne(); - if (typeof conf != 'undefined') { - return conf.allowReg; - } else { - return true + const sysConf = async() => { + let conf = await SysConfig.findOneAsync(); + if (!conf) { + return true; + } else { + return conf.allowReg; + } } + sysConf(); } }); @@ -84,14 +88,16 @@ Template.reg.events({ let userId = Meteor.userId(); console.log("User ID: " + userId); - Meteor.call("addToRole", "user", function(err, result) { - if (err) { - console.log(" ERROR: ROLES - Error adding user to role: " + err); + const addRole = async() => { + let result = await Meteor.callAsync("addToRole", "user"); + if (!result) { + console.log(" ERROR: ROLES - Error adding user to role: "); } else { // console.log("User should be added to role - teacher."); FlowRouter.go('/dashboard'); } - }); + } + addRole(); } } }, diff --git a/client/Accounts/UserMgmt/userInfoModal.html b/client/Accounts/UserMgmt/userInfoModal.html index e25fda3..156a66a 100644 --- a/client/Accounts/UserMgmt/userInfoModal.html +++ b/client/Accounts/UserMgmt/userInfoModal.html @@ -15,7 +15,7 @@ {{#if $eq passMatch false}}

Passwords do not match!

{{/if}} -
+