forked from Wavyzz/dolibarr
Look and feel v12
This commit is contained in:
@@ -488,6 +488,7 @@ function ajax_constantonoff($code, $input = array(), $entity = null, $revertonof
|
|||||||
global $conf, $langs, $user;
|
global $conf, $langs, $user;
|
||||||
|
|
||||||
$entity = ((isset($entity) && is_numeric($entity) && $entity >= 0) ? $entity : $conf->entity);
|
$entity = ((isset($entity) && is_numeric($entity) && $entity >= 0) ? $entity : $conf->entity);
|
||||||
|
if (! isset($input)) $input = array();
|
||||||
|
|
||||||
if (empty($conf->use_javascript_ajax))
|
if (empty($conf->use_javascript_ajax))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -51,17 +51,7 @@ $type = 'project';
|
|||||||
|
|
||||||
include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php';
|
include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php';
|
||||||
|
|
||||||
if ($action == 'setmainoptions')
|
if ($action == 'updateMask')
|
||||||
{
|
|
||||||
if (GETPOST('PROJECT_USE_OPPORTUNITIES')) dolibarr_set_const($db, "PROJECT_USE_OPPORTUNITIES", GETPOST('PROJECT_USE_OPPORTUNITIES'), 'chaine', 0, '', $conf->entity);
|
|
||||||
else dolibarr_del_const($db, "PROJECT_USE_OPPORTUNITIES", $conf->entity);
|
|
||||||
|
|
||||||
// Warning, the constant saved and used in code is PROJECT_HIDE_TASKS
|
|
||||||
if (GETPOST('PROJECT_USE_TASKS')) dolibarr_del_const($db, "PROJECT_HIDE_TASKS", $conf->entity);
|
|
||||||
else dolibarr_set_const($db, "PROJECT_HIDE_TASKS", 1, 'chaine', 0, '', $conf->entity);
|
|
||||||
}
|
|
||||||
|
|
||||||
elseif ($action == 'updateMask')
|
|
||||||
{
|
{
|
||||||
$maskconstproject = GETPOST('maskconstproject', 'alpha');
|
$maskconstproject = GETPOST('maskconstproject', 'alpha');
|
||||||
$maskproject = GETPOST('maskproject', 'alpha');
|
$maskproject = GETPOST('maskproject', 'alpha');
|
||||||
@@ -315,12 +305,8 @@ print '<td width="80"> </td></tr>'."\n";
|
|||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td width="80%">'.$langs->trans("ManageOpportunitiesStatus").'</td>';
|
print '<td width="80%">'.$langs->trans("ManageOpportunitiesStatus").'</td>';
|
||||||
print '<td width="60" class="right">';
|
print '<td width="60" class="right">';
|
||||||
$arrval = array('0'=>$langs->trans("No"),
|
print ajax_constantonoff("PROJECT_USE_OPPORTUNITIES");
|
||||||
'1'=>$langs->trans("Yes"),
|
|
||||||
);
|
|
||||||
print $form->selectyesno('PROJECT_USE_OPPORTUNITIES', $conf->global->PROJECT_USE_OPPORTUNITIES, 1);
|
|
||||||
print '</td><td class="right">';
|
print '</td><td class="right">';
|
||||||
print '<input type="submit" class="button" name="modifyPROJECT_USE_OPPORTUNITIES" value="'.$langs->trans("Modify").'">';
|
|
||||||
print "</td>";
|
print "</td>";
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
@@ -328,12 +314,8 @@ print '</tr>';
|
|||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td width="80%">'.$langs->trans("ManageTasks").'</td>';
|
print '<td width="80%">'.$langs->trans("ManageTasks").'</td>';
|
||||||
print '<td width="60" class="right">';
|
print '<td width="60" class="right">';
|
||||||
$arrval = array('0'=>$langs->trans("No"),
|
print ajax_constantonoff("PROJECT_HIDE_TASKS", array(), null, 1);
|
||||||
'1'=>$langs->trans("Yes"),
|
|
||||||
);
|
|
||||||
print $form->selectyesno('PROJECT_USE_TASKS', empty($conf->global->PROJECT_HIDE_TASKS) ? 1 : 0, 1);
|
|
||||||
print '</td><td class="right">';
|
print '</td><td class="right">';
|
||||||
print '<input type="submit" class="button" name="modifyPROJECT_USE_TASKS" value="'.$langs->trans("Modify").'">';
|
|
||||||
print "</td>";
|
print "</td>";
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user