Skip to content

Add Massactions Validate/Cancel/RegeneratePDF/MergePDF/EditStartDate/EditeEndDate on Mo List #33548

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

Conversation

atm-GregM
Copy link
Contributor

Add Massactions to the standard OF list:

Validate
Cancel (Form Confirm and option also cancel consumed and produced lines )
Regenerate PDF
Merge PDF
Edit start date (Form Confirm & verification: start date < end date)
Edit end date (Form Confirm & verification: end date > start date)

@@ -207,6 +217,76 @@
$objectlabel = 'Mo';
$uploaddir = $conf->mrp->dir_output;
include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php';
$objMo = new Mo($db);

if($action == 'confirm_cancel') {
Copy link
Member

Choose a reason for hiding this comment

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

You should install the precommit github hook so this king of CI error are automatically fixed.

@eldy eldy added the PR to fix - Conflict or CI error to solve The PHP unit tests return something wrong. Check details to know what to fix or solve the conflicts. label Mar 20, 2025
@atm-GregM
Copy link
Contributor Author

@eldy 👍

@@ -207,6 +217,74 @@
$objectlabel = 'Mo';
$uploaddir = $conf->mrp->dir_output;
include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php';
$objMo = new Mo($db);

if ($action == 'confirm_cancel' && $confirm == 'yes') {
Copy link
Member

Choose a reason for hiding this comment

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

There is a CI error here becasue you executed an action without doing any test on permission.
Try to replace with

if ($action == 'confirm_cancel' && $confirm == 'yes' && $permissiontoadd

@eldy eldy merged commit a1c3131 into Dolibarr:develop Apr 1, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR to fix - Conflict or CI error to solve The PHP unit tests return something wrong. Check details to know what to fix or solve the conflicts.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants