diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index eaf873f2aee..f286569e8cd 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -325,7 +325,7 @@ if ($action == 'add') reset($object->socpeopleassigned); $object->contactid = key($object->socpeopleassigned); } - + // Fill array 'array_options' with data from add form $ret = $extrafields->setOptionalsFromPost($extralabels,$object); if ($ret < 0) $error++; @@ -708,6 +708,62 @@ if ($action == 'create') else $form->select_date($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); print ''; + $userepeatevent=($conf->global->MAIN_FEATURES_LEVEL == 2 ? 1 : 0); // Dev in progress + if ($userepeatevent) + { + // Repeat + print '
| '.$langs->trans("ActionOnCompany").' | '; - if (GETPOST('socid','int') > 0) + if ($conf->societe->enabled) { - $societe = new Societe($db); - $societe->fetch(GETPOST('socid','int')); - print $societe->getNomUrl(1); - print ''; - } - else - { - $events=array(); - $events[]=array('method' => 'getContacts', 'url' => dol_buildpath('/core/ajax/contacts.php?showempty=1',1), 'htmlname' => 'contactid', 'params' => array('add-customer-contact' => 'disabled')); - //For external user force the company to user company - if (!empty($user->societe_id)) { - print $form->select_company($user->societe_id, 'socid', '', 1, 1, 0, $events, 0, 'minwidth300'); - } else { - print $form->select_company('', 'socid', '', 'SelectThirdParty', 1, 0, $events, 0, 'minwidth300'); + // Related company + print ' | ||
| '.$langs->trans("ActionOnCompany").' | '; + if (GETPOST('socid','int') > 0) + { + $societe = new Societe($db); + $societe->fetch(GETPOST('socid','int')); + print $societe->getNomUrl(1); + print ''; } + else + { + $events=array(); + $events[]=array('method' => 'getContacts', 'url' => dol_buildpath('/core/ajax/contacts.php?showempty=1',1), 'htmlname' => 'contactid', 'params' => array('add-customer-contact' => 'disabled')); + //For external user force the company to user company + if (!empty($user->societe_id)) { + print $form->select_company($user->societe_id, 'socid', '', 1, 1, 0, $events, 0, 'minwidth300'); + } else { + print $form->select_company('', 'socid', '', 'SelectThirdParty', 1, 0, $events, 0, 'minwidth300'); + } + } + print ' | ||
| '.$langs->trans("ActionOnContact").' | '; + print $form->selectcontacts(GETPOST('socid','int'), GETPOST('socpeopleassigned', 'array'), 'socpeopleassigned[]', 1, '', '', 0, 'quatrevingtpercent', false, 0, array(), false, 'multiple', 'contactid'); + print ' | ||
| '.$langs->trans("ActionOnContact").' | '; - echo $form->selectcontacts(GETPOST('socid','int'), GETPOST('socpeopleassigned', 'array'), 'socpeopleassigned[]', 1, '', '', 0, 'minwidth200',0, 0, array(), false, 'multiple', 'contactid'); - print ' | ||
| '.$langs->trans("Project").' | '; + print ' | ||
| '.$langs->trans("Project").' | '; $numproject=$formproject->select_projects((! empty($societe->id)?$societe->id:-1),GETPOST("projectid")?GETPOST("projectid"):'','projectid'); if ($numproject==0) @@ -816,7 +878,7 @@ if ($action == 'create') if (!empty($origin) && !empty($originid)) { include_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; - print ' | ||
| '.$langs->trans("LinkedObject").' | '; + print '|||
| '.$langs->trans("LinkedObject").' | '; print ''.dolGetElementUrl($originid,$origin,1).' | ||
| '.$langs->trans("Priority").' | '; + print ' | ||
| '.$langs->trans("Priority").' | '; print ''; print ' | ||
| global->AGENDA_USE_EVENT_TYPE)?' class="fieldrequired"':'').'>'.$langs->trans("Title").' | |||
| global->AGENDA_USE_EVENT_TYPE)?' class="fieldrequired"':'').'>'.$langs->trans("Title").' | |||
| '.$langs->trans("EventOnFullDay").' | fulldayevent?' checked':'').'> | ||