moodle-an-hochschulen / moodle-availability_password Goto Github PK
View Code? Open in Web Editor NEWMoodle availability plugin which lets users restrict resources and activities with password access
License: GNU General Public License v3.0
Moodle availability plugin which lets users restrict resources and activities with password access
License: GNU General Public License v3.0
In the password prompt popup, the buttons do not have Bootstrap styles currently:
To add these styles to the buttons, some refactoring of the existing YUI code would be necessary.
This can be done, but maybe this issue will simply be superseded by #15
Github actions started to complain recently about the naming of the existing PHPUnit tests:
FILE: ...r/work/moodle-availability_password/moodle-availability_password/moodle/availability/condition/password/tests/privacy_test.php
------------------------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------------------------------------
36 | WARNING | PHPUnit testcase name "availability_password_privacy_test" does not match file name "privacy_test"
| | (moodle.PHPUnit.TestCaseNames.NoMatch)
36 | WARNING | PHUnit class "availability_password_privacy_test" does not have any namespace. It is recommended to add it to the
| | "availability_password" namespace, using more levels if needed, in order to match the code being tested
| | (moodle.PHPUnit.TestCaseNames.MissingNS)
------------------------------------------------------------------------------------------------------------------------------------
This originates to a change in local_codechecker which was integrated there in moodlehq/moodle-local_codechecker#161
Course Section Protection would be greatly appreciated!
In ca6736e#diff-053982e787008e7875d9d0dae0b57af4d707e0b769532264f13bbb5eaf38af03R41, the Behat scenario "A student attempts to access the page activity with the activity link, but cancels the popup" had to be commented out as it broke on Moodle 4.0 and the reasons could not be detected.
This issue serves as a reminder to have another look if the reason can be found and the scenario can be fixed.
This issue serves as a reminder that this plugin still uses YUI in its JavaScript code.
Currently, I am not aware that you can build availability_* plugins without YUI.
But as soon as Moodle core supports this, this plugin should be adapted.
the module is not working after upgrade to moodle 3.4.1 and the option to restrict access to activity by password does not show up in the selection list
The new activity restriction information in Moodle 4.3 overreacts with this this plugin and adds a 'show more' link even though it would not be necessary:
This seems to happen because the availability description contains HTML code (see https://github.com/moodle-an-hochschulen/moodle-availability_password/blob/master/classes/condition.php#L152) and is, measured by its pure character length, quite long.
Changing this behaviour might be tricky and might involve a redesign where the link is added by JS in the browser and not by the PHP code anymore.
I have a problem with the "Restriction by password" (moodle-availability_password) plugin on Moodle 3.11.4 (Build: 20211108).
I can install and set restrictions properly in activities and resources settings, but there is a problem when I want to change the password or show the restriction configuration which was set in the lessons. I can't expand the restriction section in the lesson edit menu (in other activities and resources it works well).
Any idea how to fix it?
Dear developers,
is there any idea to read the password with a qr code or bar code? For some user groups as smaller kids the password could be easier to use with a qr code. Also for gamification it could be a nice add-on to scan the qr code instead of typing a password. Yes, for this idea the plugin should work with the mobile Moodle app.
Please look into the Moodle academy "Gamification".
https://moodle.academy/mod/forum/discuss.php?d=187#p800
If you like to see these features in a real gamification app then please look at the Actionbound app.
https://de.actionbound.com/blog/54c662dd49e5872731000005
https://de.actionbound.com/stepbystep#code_scannen
Best regards,
Ralf
Ralf Krause
moodleSCHULE e.V.
Hi would it be possible for the restriction to work with tiles format perhaps extending the popup view time on mouse over. The problem is you can not click the password link in the popup when you mouse over the restriction label as it disappears.
Also could it work on restriction to a section
Regards
Gordon
Dear @abias and @lucaboesch,
I hope this message finds you well. I'd like to share a suggestion for further enhancing the plugin in a more concrete manner:
I've noticed that there might be room for improvement in the authorization concept of the plugin. It would be great if we could enhance it to ensure better security. It's crucial to approach the design, description, and implementation of security-related features with utmost care since users tend to rely on them.
Currently, there seems to be an issue where teachers who don't have authorization can still remove the password for others, which ideally shouldn't be the case. Moreover, the lack of logging for these actions makes it difficult to trace any unauthorized changes.
Given our target audience, consisting of several thousand schools in Germany, these adjustments are vital for us to be able to fully utilize the plugin.
We genuinely appreciate your consideration of these suggestions. Thank you in advance for your attention and support.
Dear developers,
thank you very much for this wonderful plugin for gamification. The participants have to guess a password or build it from various clues to see more course topics, activities, and resources. I told about the password feature in the Moodle academy "Gamification" in February, 2022. The academy is currently still open.
https://moodle.academy/mod/forum/discuss.php?d=183#p847
https://moodle.academy/mod/forum/discuss.php?d=187#p800
Is there any idea to make it work in the mobile Moodle app? The Moodle app is able to store all course content temporarily on the mobile device so participants can "play" the course offline without internet and without mobile data connection.
Best regards,
Ralf
Ralf Krause
moodleSCHULE e.V.
Hi @ll,
the parameter type is missing in
https://github.com/moodleuulm/moodle-availability_password/blob/63d662bedf4d1e026917957127b0b8064415c1f3/classes/condition.php#L184
I created a small PR #10
Without this parameter backup/restore is broken, when this availability is used together with other access restrictions,
e.g. the relevant part of the json looks like:
"c":[{"password":"PROBE"},{"type":"completion","cm":470,"e":1},{"type":"completion","cm":472,"e":1},{"type":"completion","cm":472,"e":1}]
-> no type in first element
-> Moodle does not know how to handle this and complains with invalid availability structure error.
Cheers
Christian
This issue is still present in v3.9-r3 (actually every release but v3.11-r1). Would be cool if it could be fixed there as well.
As far as I can see, @christianwolters patch / pull request is applicable there as well.
Cheers
Originally posted by @krostas1983 in #11 (comment)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.