23include_once DOL_DOCUMENT_ROOT.
'/societe/canvas/actions_card_common.class.php';
42 public function __construct($db, $dirmodule, $targetmodule, $canvas, $card)
45 $this->dirmodule = $dirmodule;
46 $this->targetmodule = $targetmodule;
47 $this->canvas = $canvas;
64 if ($action ==
'view') {
65 $out .= $langs->trans(
"Individual");
67 if ($action ==
'edit') {
68 $out .= $langs->trans(
"EditCompany");
70 if ($action ==
'create') {
71 $out .= $langs->trans(
"NewCompany");
90 $return = parent::doActions($action);
107 global $conf, $langs;
108 global $form, $formcompany;
112 parent::assign_values($action);
116 if ($action ==
'create' || $action ==
'edit') {
117 $this->tpl[
'select_civility'] = $formcompany->select_civility(
GETPOST(
'civility_id'));
120 if ($action ==
'delete' || $conf->use_javascript_ajax) {
121 $this->tpl[
'action_delete'] = $form->formconfirm($_SERVER[
"PHP_SELF"].
"?socid=".$this->object->id, $langs->trans(
"DeleteAnIndividual"), $langs->trans(
"ConfirmDeleteIndividual"),
"confirm_delete",
'', 0,
"1,action-delete");
139 public function restrictedArea($user, $features =
'societe', $objectid = 0, $dbtablename =
'', $feature2 =
'', $dbt_keyfield =
'fk_soc', $dbt_select =
'rowid')
141 return restrictedArea($user, $features, $objectid, $dbtablename, $feature2, $dbt_keyfield, $dbt_select);
Classe permettant la gestion des tiers par defaut.
getObject($id, $ref='')
Get object from id or ref and save it into this->object.
restrictedArea($user, $features='societe', $objectid=0, $dbtablename='', $feature2='', $dbt_keyfield='fk_soc', $dbt_select='rowid')
Check permissions of a user to show a page and an object.
assign_values(&$action, $id=0, $ref='')
Assign custom values for canvas (for example into this->tpl to be used by templates)
__construct($db, $dirmodule, $targetmodule, $canvas, $card)
Constructor.
getTitle($action)
Return the title of card.
doActions(&$action, $id)
Execute actions.
load_fiche_titre($titre, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.