Fix registration of attendee
This commit is contained in:
parent
ceb368abd4
commit
5fa62f25fa
@ -1724,6 +1724,18 @@ abstract class CommonObject
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
|
/**
|
||||||
|
* Load the project with id $this->fk_project into this->project
|
||||||
|
*
|
||||||
|
* @return int <0 if KO, >=0 if OK
|
||||||
|
*/
|
||||||
|
public function fetch_project()
|
||||||
|
{
|
||||||
|
// phpcs:enable
|
||||||
|
return $this->fetch_projet();
|
||||||
|
}
|
||||||
|
|
||||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
/**
|
/**
|
||||||
* Load the project with id $this->fk_project into this->project
|
* Load the project with id $this->fk_project into this->project
|
||||||
|
|||||||
@ -634,6 +634,31 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
|
/**
|
||||||
|
* Load the project with id $this->fk_project into this->project
|
||||||
|
*
|
||||||
|
* @return int <0 if KO, >=0 if OK
|
||||||
|
*/
|
||||||
|
public function fetch_projet()
|
||||||
|
{
|
||||||
|
// phpcs:enable
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||||
|
|
||||||
|
if (empty($this->fk_project) && !empty($this->fk_projet)) {
|
||||||
|
$this->fk_project = $this->fk_projet; // For backward compatibility
|
||||||
|
}
|
||||||
|
if (empty($this->fk_project)) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
$project = new Project($this->db);
|
||||||
|
$result = $project->fetch($this->fk_project);
|
||||||
|
|
||||||
|
$this->projet = $project; // deprecated
|
||||||
|
$this->project = $project;
|
||||||
|
return $result;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set draft status
|
* Set draft status
|
||||||
|
|||||||
@ -1840,7 +1840,7 @@ if ($source == 'organizedeventregistration') {
|
|||||||
print '</td></tr>'."\n";
|
print '</td></tr>'."\n";
|
||||||
|
|
||||||
if (! is_object($attendee->project)) {
|
if (! is_object($attendee->project)) {
|
||||||
$text = 'ErrorProjectotFound';
|
$text = 'ErrorProjectNotFound';
|
||||||
} else {
|
} else {
|
||||||
$text = $langs->trans("PaymentEvent").' - '.$attendee->project->title;
|
$text = $langs->trans("PaymentEvent").' - '.$attendee->project->title;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user