-
-
Notifications
You must be signed in to change notification settings - Fork 145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New module presentation #4266
New module presentation #4266
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should use modern usage of PHP and of Jelix 1.8 ;-)
@@ -0,0 +1,21 @@ | |||
<?php | |||
|
|||
class lizmapModuleUpgrader_userfields extends jInstallerModule |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should use the new classes of Jelix 1.8 \Jelix\Installer\Module\Installer
(install.php should use it too, but it can be done into an other patch)
class lizmapModuleUpgrader_userfields extends jInstallerModule | ||
{ | ||
public $targetVersions = array( | ||
'3.8pre', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You must indicate here only versions of other branches if it is backported in previous branches, and the next version of the current branch . so here only ['3.8.0-alpha.1']
or ['3.8.0-pre.20240308']
, so you must put at the same time this version into module.xml.
{ | ||
public function ongetMapAdditions($event) | ||
{ | ||
$basePath = jApp::config()->urlengine['basePath']; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is a method for that on jApp.
$css = array(); | ||
|
||
// Check config | ||
jClasses::inc('presentation~presentationConfig'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
store you presentationConfig class into a lib directory, with a namespace, and declare the namespace into the module.xml sot the class will be autoloadable, and you won't need to do jClasses::inc()
. jClasses is deprecated.
), | ||
); | ||
|
||
$jsCode = array( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please stop embedding JS or CSS directly into the HTML, it is not anymore a good practice, and it avoid us to have good secured CSP. For dynamic JS, create an action that will forge the JS, and declare the address of the action here.
* | ||
* @license Mozilla Public License | ||
*/ | ||
class serviceCtrl extends jController |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is already a bunch of serviceCtrl class into the project (!!). You should use an other name.
* | ||
* @license Mozilla Public License | ||
*/ | ||
class presentationModuleInstaller extends jInstallerModule |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should use the new classes of Jelix 1.8 \Jelix\Installer\Module\Installer
* | ||
* @license Mozilla Public License : http://www.mozilla.org/MPL/ | ||
*/ | ||
class presentationModuleUpgrader extends jInstallerModule |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should use the new classes of Jelix 1.8 \Jelix\Installer\Module\Installer
@@ -0,0 +1,5 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<suburls xmlns="http://jelix.org/ns/suburls/1.0"> | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should declare url of each action here, and create a install/configurator.php
to declare the url (see example into some external modules, like wps)
This is a nice feature, is there any demo/screenshot about how a presentation could look like? Would/could slides be linked to a certain state/scale/extent of the map? |
@laurentj This PR is at a very, very early stage. It was not supposed to be reviewed before end of april 🤣 . This is why I did not add reviewers and why it is marked as draft. Anyway, OK for all comments on the usage of the new Jelix ways, I will update the code. @gioman I can provide a full description if needed. This is a funded work, which should land of 3.8.
Not yet
Yep ! |
nice ! |
35c92e1
to
a353d06
Compare
…presentation display
…e state accordingly
…e the presentation pages container into its dock
1fda78e
to
494bbae
Compare
We worked instead on a separate module to be able to release it for 3.7 and 3.8. and spend more time testing and polishing it. |
TODO
Funded by QAIR International https://www.qair.energy/