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

FIX: when create intervention from propal (or other object), element link is mising after creation #32035

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions htdocs/fichinter/card.php
Original file line number Diff line number Diff line change
Expand Up @@ -844,7 +844,7 @@
$res = $soc->fetch($socid);
}

if (GETPOSTINT('origin') && GETPOSTINT('originid')) {
if (GETPOST('origin', 'alphanohtml') && GETPOSTINT('originid')) {
// Parse element/subelement (ex: project_task)
$regs = array();
$element = $subelement = GETPOST('origin', 'alphanohtml');
Expand Down Expand Up @@ -1011,6 +1011,7 @@
if (!empty($origin) && !empty($originid) && is_object($objectsrc)) {
$newclassname = $classname;
if ($newclassname == 'Propal') {
$langs->load('propal');
$newclassname = 'CommercialProposal';
}
print '<tr><td>'.$langs->trans($newclassname).'</td><td colspan="2">'.$objectsrc->getNomUrl(1).'</td></tr>';
Expand Down Expand Up @@ -1054,7 +1055,7 @@
print $form->buttonsSaveCancel("CreateDraftIntervention");

// Show origin lines
if (!empty($origin) && !empty($originid) && is_object($objectsrc)) {
if (!empty($origin) && !empty($originid) && is_object($objectsrc) && !getDolGlobalInt('FICHINTER_DISABLE_DETAILS')) {
$title = $langs->trans('Services');
print load_fiche_titre($title);

Expand Down
Loading