Skip to content
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 : Add option position['find'] to DolEditor #29546

Merged
merged 8 commits into from
May 1, 2024

Conversation

Vaadasch
Copy link
Contributor

By adding the possibility to find a word inside a content opened by DolEditor, it allow to go to the first line matching the word.

It is usefull for long and diverses files, like the descriptor file of a module.
The module builder was adapted to use this parameter and open the descriptor file directly to the flagged line.

By "word", it allow the possibility to use textual flags inside a document.

@@ -301,12 +305,14 @@ public function __construct($db)
$this->rights[$r][5] = 'delete'; // In php code, permission will be checked by test if ($user->hasRight('mymodule', 'myobject', 'delete'))
$r++;
*/
// Add here entries to declare new permissions
/* BEGIN MODULEBUILDER PERMISSIONS */
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The BEGIN MODULEBUILDER PERMISSINS must be before the example, because when we add apermission, 1 by 1, it is the content inside the block that is used to copy and generated a new block.

@@ -179,8 +182,7 @@ public function __construct($db)
$conf->mymodule->enabled = 0;
}

// Array to add new pages in new tabs
$this->tabs = array();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing this is required ?

Copy link
Contributor Author

@Vaadasch Vaadasch May 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like for Permissions, I've moved it after the examples, because i thought seeing some pattern but it seems i've only seen it for Dictionnaries.
(Currently reverting it to what it was)

@eldy eldy added the Discussion Some questions or discussions are opened and wait answers of author or other people to be processed label May 1, 2024
@Vaadasch
Copy link
Contributor Author

Vaadasch commented May 1, 2024

I've manually "revert" the template descriptor file to what it was before my PR, only adding some new flags (HOOKSCONTEXTS, DESCRIPTION_FLAG and TABS).

@eldy eldy merged commit 5865151 into Dolibarr:develop May 1, 2024
3 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Discussion Some questions or discussions are opened and wait answers of author or other people to be processed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants