Merge branch '12.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts: htdocs/accountancy/bookkeeping/balance.php
This commit is contained in:
commit
70fc74008a
@ -298,11 +298,12 @@ if ($action != 'export_csv')
|
||||
|
||||
if (!empty($show_subgroup))
|
||||
{
|
||||
// Permet d'afficher le compte comptable
|
||||
// Show accounting account
|
||||
if (empty($displayed_account) || $root_account_description != $displayed_account) {
|
||||
// Affiche un Sous-Total par compte comptable
|
||||
// Show subtotal per accounting account
|
||||
if ($displayed_account != "") {
|
||||
print '<tr class="liste_total"><td class="right" colspan="3">'.$langs->trans("SubTotal").':</td>';
|
||||
print '<tr class="liste_total">';
|
||||
print '<td class="right" colspan="3">'.$langs->trans("SubTotal").':</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_debit).'</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_credit).'</td>';
|
||||
print '<td class="nowrap right">'.price(price2num($sous_total_credit - $sous_total_debit)).'</td>';
|
||||
|
||||
@ -620,11 +620,12 @@ class FormProjets
|
||||
* @param int $showallnone Add choice "All" and "None"
|
||||
* @param int $showpercent Show default probability for status
|
||||
* @param string $morecss Add more css
|
||||
* @param int $noadmininfo 0=Add admin info, 1=Disable admin info
|
||||
* @return int|string The HTML select list of element or '' if nothing or -1 if KO
|
||||
*/
|
||||
public function selectOpportunityStatus($htmlname, $preselected = '-1', $showempty = 1, $useshortlabel = 0, $showallnone = 0, $showpercent = 0, $morecss = '')
|
||||
public function selectOpportunityStatus($htmlname, $preselected = '-1', $showempty = 1, $useshortlabel = 0, $showallnone = 0, $showpercent = 0, $morecss = '', $noadmininfo = 0)
|
||||
{
|
||||
global $conf, $langs;
|
||||
global $conf, $langs, $user;
|
||||
|
||||
$sql = "SELECT rowid, code, label, percent";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX.'c_lead_status';
|
||||
@ -670,6 +671,7 @@ class FormProjets
|
||||
$i++;
|
||||
}
|
||||
$sellist .= '</select>';
|
||||
if ($user->admin && !$noadmininfo) $sellist .= info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
}
|
||||
/*else
|
||||
{
|
||||
|
||||
@ -3149,7 +3149,7 @@ function img_picto($titlealt, $picto, $moreatt = '', $pictoisfullpath = false, $
|
||||
if (empty($srconly) && in_array($pictowithouttext, array(
|
||||
'1downarrow', '1uparrow', '1leftarrow', '1rightarrow', '1uparrow_selected', '1downarrow_selected', '1leftarrow_selected', '1rightarrow_selected',
|
||||
'accountancy', 'address', 'bank_account', 'barcode', 'bank', 'bill', 'bookmark', 'bom', 'building',
|
||||
'cash-register', 'check', 'close_title', 'company', 'contact', 'contract', 'cubes',
|
||||
'cash-register', 'category', 'check', 'close_title', 'company', 'contact', 'contract', 'cubes',
|
||||
'delete', 'dolly', 'dollyrevert', 'edit', 'ellipsis-h', 'external-link-alt', 'external-link-square-alt',
|
||||
'filter', 'file-code', 'file-export', 'file-import', 'file-upload', 'folder', 'folder-open', 'globe', 'globe-americas', 'grip', 'grip_title', 'help',
|
||||
'intervention', 'label', 'language', 'list', 'listlight', 'lot',
|
||||
|
||||
@ -2226,10 +2226,10 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
print '<td>';
|
||||
print $projectstatic->getNomUrl(1);
|
||||
print $projectstatic->getNomUrl(1, '', 0, '', '-', 0 , -1, 'nowraponall');
|
||||
if (!in_array('projectlabel', $hiddenfields)) print '<br><span class="opacitymedium">'.dol_trunc($objp->title, 24).'</span>';
|
||||
print '</td>';
|
||||
print '<td>';
|
||||
print '<td class="nowraponall tdoverflowmax100">';
|
||||
if ($objp->fk_soc > 0)
|
||||
{
|
||||
$thirdpartystatic->id = $objp->fk_soc;
|
||||
|
||||
@ -234,6 +234,7 @@ ThirdpartyAccountNotDefinedOrThirdPartyUnknownSubledgerIgnored=Third-party unkno
|
||||
ThirdpartyAccountNotDefinedOrThirdPartyUnknownBlocking=Third-party account not defined or third party unknown. Blocking error.
|
||||
UnknownAccountForThirdpartyAndWaitingAccountNotDefinedBlocking=Unknown third-party account and waiting account not defined. Blocking error
|
||||
PaymentsNotLinkedToProduct=Payment not linked to any product / service
|
||||
OpeningBalance=Opening balance
|
||||
ShowOpeningBalance=Show opening balance
|
||||
HideOpeningBalance=Hide opening balance
|
||||
ShowSubtotalByGroup=Show subtotal by group
|
||||
|
||||
@ -255,7 +255,7 @@ ServiceToUseOnLines=Service to use on lines
|
||||
InvoiceGeneratedFromTimeSpent=Invoice %s has been generated from time spent on project
|
||||
ProjectBillTimeDescription=Check if you enter timesheet on tasks of project AND you plan to generate invoice(s) from the timesheet to bill the customer of the project (do not check if you plan to create invoice that is not based on entered timesheets). Note: To generate invoice, go on tab 'Time spent' of the project and select lines to include.
|
||||
ProjectFollowOpportunity=Follow opportunity
|
||||
ProjectFollowTasks=Follow tasks
|
||||
ProjectFollowTasks=Follow tasks or time spent
|
||||
Usage=Usage
|
||||
UsageOpportunity=Usage: Opportunity
|
||||
UsageTasks=Usage: Tasks
|
||||
|
||||
@ -558,6 +558,19 @@ if ($action == 'create' && $user->rights->projet->creer)
|
||||
print '<input type="checkbox" id="usage_opportunity" name="usage_opportunity"'.(GETPOSTISSET('usage_opportunity') ? (GETPOST('usage_opportunity', 'alpha') != '' ? ' checked="checked"' : '') : ' checked="checked"').'"> ';
|
||||
$htmltext = $langs->trans("ProjectFollowOpportunity");
|
||||
print $form->textwithpicto($langs->trans("ProjectFollowOpportunity"), $htmltext);
|
||||
print '<script>';
|
||||
print '$( document ).ready(function() {
|
||||
jQuery("#usage_opportunity").change(function() {
|
||||
if (jQuery("#usage_opportunity").prop("checked")) {
|
||||
console.log("Show opportunities fields");
|
||||
jQuery(".classuseopportunity").show();
|
||||
} else {
|
||||
console.log("Hide opportunities fields "+jQuery("#usage_opportunity").prop("checked"));
|
||||
jQuery(".classuseopportunity").hide();
|
||||
}
|
||||
});
|
||||
});';
|
||||
print '</script>';
|
||||
print '<br>';
|
||||
}
|
||||
if (empty($conf->global->PROJECT_HIDE_TASKS))
|
||||
@ -591,7 +604,7 @@ if ($action == 'create' && $user->rights->projet->creer)
|
||||
print '</td><td class="maxwidthonsmartphone">';
|
||||
$filteronlist = '';
|
||||
if (!empty($conf->global->PROJECT_FILTER_FOR_THIRDPARTY_LIST)) $filteronlist = $conf->global->PROJECT_FILTER_FOR_THIRDPARTY_LIST;
|
||||
$text = $form->select_company(GETPOST('socid', 'int'), 'socid', $filteronlist, 'SelectThirdParty', 1, 0, array(), 0, 'minwidth300');
|
||||
$text = img_picto('', 'company').$form->select_company(GETPOST('socid', 'int'), 'socid', $filteronlist, 'SelectThirdParty', 1, 0, array(), 0, 'minwidth300 widthcentpercentminusx');
|
||||
if (empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) && empty($conf->dol_use_jmobile))
|
||||
{
|
||||
$texthelp = $langs->trans("IfNeedToUseOtherObjectKeepEmpty");
|
||||
@ -632,27 +645,27 @@ if ($action == 'create' && $user->rights->projet->creer)
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES))
|
||||
{
|
||||
// Opportunity status
|
||||
print '<tr><td>'.$langs->trans("OpportunityStatus").'</td>';
|
||||
print '<tr class="classuseopportunity"><td>'.$langs->trans("OpportunityStatus").'</td>';
|
||||
print '<td class="maxwidthonsmartphone">';
|
||||
print $formproject->selectOpportunityStatus('opp_status', GETPOST('opp_status') ?GETPOST('opp_status') : $object->opp_status);
|
||||
print '</tr>';
|
||||
|
||||
// Opportunity probability
|
||||
print '<tr><td>'.$langs->trans("OpportunityProbability").'</td>';
|
||||
print '<td><input size="5" type="text" id="opp_percent" name="opp_percent" value="'.dol_escape_htmltag(GETPOST('opp_percent') != '' ?GETPOST('opp_percent') : '').'"><span class="hideonsmartphone"> %</span>';
|
||||
print '<input type="hidden" name="opp_percent_not_set" id="opp_percent_not_set" value="'.dol_escape_htmltag(GETPOST('opp_percent') != '' ? '0' : '1').'">';
|
||||
print '<tr class="classuseopportunity"><td>'.$langs->trans("OpportunityProbability").'</td>';
|
||||
print '<td><input size="5" type="text" id="opp_percent" name="opp_percent" value="'.dol_escape_htmltag(GETPOSTISSET('opp_percent') ? GETPOST('opp_percent') : '').'"><span class="hideonsmartphone"> %</span>';
|
||||
print '<input type="hidden" name="opp_percent_not_set" id="opp_percent_not_set" value="'.dol_escape_htmltag(GETPOSTISSET('opp_percent') ? '0' : '1').'">';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
|
||||
// Opportunity amount
|
||||
print '<tr><td>'.$langs->trans("OpportunityAmount").'</td>';
|
||||
print '<td><input size="5" type="text" name="opp_amount" value="'.dol_escape_htmltag(GETPOST('opp_amount') != '' ?GETPOST('opp_amount') : '').'"></td>';
|
||||
print '<tr class="classuseopportunity"><td>'.$langs->trans("OpportunityAmount").'</td>';
|
||||
print '<td><input size="5" type="text" name="opp_amount" value="'.dol_escape_htmltag(GETPOSTISSET('opp_amount') ? GETPOST('opp_amount') : '').'"></td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
// Budget
|
||||
print '<tr><td>'.$langs->trans("Budget").'</td>';
|
||||
print '<td><input size="5" type="text" name="budget_amount" value="'.dol_escape_htmltag(GETPOST('budget_amount') != '' ?GETPOST('budget_amount') : '').'"></td>';
|
||||
print '<td><input size="5" type="text" name="budget_amount" value="'.dol_escape_htmltag(GETPOSTISSET('budget_amount') ? GETPOST('budget_amount') : '').'"></td>';
|
||||
print '</tr>';
|
||||
|
||||
// Description
|
||||
@ -667,7 +680,7 @@ if ($action == 'create' && $user->rights->projet->creer)
|
||||
print '<tr><td>'.$langs->trans("Categories").'</td><td colspan="3">';
|
||||
$cate_arbo = $form->select_all_categories(Categorie::TYPE_PROJECT, '', 'parent', 64, 0, 1);
|
||||
$arrayselected = GETPOST('categories', 'array');
|
||||
print $form->multiselectarray('categories', $cate_arbo, $arrayselected, '', 0, '', 0, '100%');
|
||||
print img_picto('', 'category').$form->multiselectarray('categories', $cate_arbo, $arrayselected, '', 0, 'quatrevingtpercent widthcentpercentminusx', 0, 0);
|
||||
print "</td></tr>";
|
||||
}
|
||||
|
||||
@ -833,9 +846,22 @@ elseif ($object->id > 0)
|
||||
print '<td>';
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES))
|
||||
{
|
||||
print '<input type="checkbox" name="usage_opportunity"'.(GETPOSTISSET('usage_opportunity') ? (GETPOST('usage_opportunity', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_opportunity ? ' checked="checked"' : '')).'"> ';
|
||||
print '<input type="checkbox" id="usage_opportunity" name="usage_opportunity"'.(GETPOSTISSET('usage_opportunity') ? (GETPOST('usage_opportunity', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_opportunity ? ' checked="checked"' : '')).'"> ';
|
||||
$htmltext = $langs->trans("ProjectFollowOpportunity");
|
||||
print $form->textwithpicto($langs->trans("ProjectFollowOpportunity"), $htmltext);
|
||||
print '<script>';
|
||||
print '$( document ).ready(function() {
|
||||
jQuery("#usage_opportunity").change(function() {
|
||||
if (jQuery("#usage_opportunity").prop("checked")) {
|
||||
console.log("Show opportunities fields");
|
||||
jQuery(".classuseopportunity").show();
|
||||
} else {
|
||||
console.log("Hide opportunities fields "+jQuery("#usage_opportunity").prop("checked"));
|
||||
jQuery(".classuseopportunity").hide();
|
||||
}
|
||||
});
|
||||
});';
|
||||
print '</script>';
|
||||
print '<br>';
|
||||
}
|
||||
if (empty($conf->global->PROJECT_HIDE_TASKS))
|
||||
@ -884,8 +910,9 @@ elseif ($object->id > 0)
|
||||
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES))
|
||||
{
|
||||
$classfortr = ($object->usage_opportunity ? '' : ' hideobject');
|
||||
// Opportunity status
|
||||
print '<tr><td>'.$langs->trans("OpportunityStatus").'</td>';
|
||||
print '<tr class="classuseopportunity'.$classfortr.'"><td>'.$langs->trans("OpportunityStatus").'</td>';
|
||||
print '<td>';
|
||||
print $formproject->selectOpportunityStatus('opp_status', $object->opp_status, 1, 0, 0, 0, 'inline-block valignmiddle');
|
||||
print '<div id="divtocloseproject" class="inline-block valign" style="display: none;"> ';
|
||||
@ -896,15 +923,15 @@ elseif ($object->id > 0)
|
||||
print '</tr>';
|
||||
|
||||
// Opportunity probability
|
||||
print '<tr><td>'.$langs->trans("OpportunityProbability").'</td>';
|
||||
print '<td><input size="5" type="text" id="opp_percent" name="opp_percent" value="'.(isset($_POST['opp_percent']) ?GETPOST('opp_percent') : (strcmp($object->opp_percent, '') ?vatrate($object->opp_percent) : '')).'"> %';
|
||||
print '<tr class="classuseopportunity'.$classfortr.'"><td>'.$langs->trans("OpportunityProbability").'</td>';
|
||||
print '<td><input size="5" type="text" id="opp_percent" name="opp_percent" value="'.(GETPOSTISSET('opp_percent') ? GETPOST('opp_percent') : (strcmp($object->opp_percent, '') ?vatrate($object->opp_percent) : '')).'"> %';
|
||||
print '<span id="oldopppercent"></span>';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
|
||||
// Opportunity amount
|
||||
print '<tr><td>'.$langs->trans("OpportunityAmount").'</td>';
|
||||
print '<td><input size="5" type="text" name="opp_amount" value="'.(isset($_POST['opp_amount']) ?GETPOST('opp_amount') : (strcmp($object->opp_amount, '') ?price2num($object->opp_amount) : '')).'"></td>';
|
||||
print '<tr class="classuseopportunity'.$classfortr.'"><td>'.$langs->trans("OpportunityAmount").'</td>';
|
||||
print '<td><input size="5" type="text" name="opp_amount" value="'.(GETPOSTISSET('opp_amount') ? GETPOST('opp_amount') : (strcmp($object->opp_amount, '') ? price2num($object->opp_amount) : '')).'"></td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
@ -923,7 +950,7 @@ elseif ($object->id > 0)
|
||||
|
||||
// Budget
|
||||
print '<tr><td>'.$langs->trans("Budget").'</td>';
|
||||
print '<td><input size="5" type="text" name="budget_amount" value="'.(isset($_POST['budget_amount']) ?GETPOST('budget_amount') : (strcmp($object->budget_amount, '') ?price($object->budget_amount, 0, $langs, 1, 0) : '')).'"></td>';
|
||||
print '<td><input size="5" type="text" name="budget_amount" value="'.(GETPOSTISSET('budget_amount') ? GETPOST('budget_amount') : (strcmp($object->budget_amount, '') ? price2num($object->budget_amount) : '')).'"></td>';
|
||||
print '</tr>';
|
||||
|
||||
// Description
|
||||
@ -936,14 +963,14 @@ elseif ($object->id > 0)
|
||||
// Tags-Categories
|
||||
if ($conf->categorie->enabled)
|
||||
{
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Categories").'</td><td>';
|
||||
print '<tr><td>'.$langs->trans("Categories").'</td><td>';
|
||||
$cate_arbo = $form->select_all_categories(Categorie::TYPE_PROJECT, '', 'parent', 64, 0, 1);
|
||||
$c = new Categorie($db);
|
||||
$cats = $c->containing($object->id, Categorie::TYPE_PROJECT);
|
||||
foreach ($cats as $cat) {
|
||||
$arrayselected[] = $cat->id;
|
||||
}
|
||||
print $form->multiselectarray('categories', $cate_arbo, $arrayselected, '', 0, '', 0, '100%');
|
||||
print img_picto('', 'category').$form->multiselectarray('categories', $cate_arbo, $arrayselected, 0, 0, 'quatrevingtpercent widthcentpercentminusx', 0, '0');
|
||||
print "</td></tr>";
|
||||
}
|
||||
|
||||
|
||||
@ -1026,18 +1026,19 @@ class Project extends CommonObject
|
||||
}
|
||||
|
||||
/**
|
||||
* Return clicable name (with picto eventually)
|
||||
* Return clickable name (with picto eventually)
|
||||
*
|
||||
* @param int $withpicto 0=No picto, 1=Include picto into link, 2=Only picto
|
||||
* @param string $option Variant ('', 'nolink')
|
||||
* @param string $option Variant where the link point to ('', 'nolink')
|
||||
* @param int $addlabel 0=Default, 1=Add label into string, >1=Add first chars into string
|
||||
* @param string $moreinpopup Text to add into popup
|
||||
* @param string $sep Separator between ref and label if option addlabel is set
|
||||
* @param int $notooltip 1=Disable tooltip
|
||||
* @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking
|
||||
* @param string $morecss More css on a link
|
||||
* @return string String with URL
|
||||
*/
|
||||
public function getNomUrl($withpicto = 0, $option = '', $addlabel = 0, $moreinpopup = '', $sep = ' - ', $notooltip = 0, $save_lastsearch_value = -1)
|
||||
public function getNomUrl($withpicto = 0, $option = '', $addlabel = 0, $moreinpopup = '', $sep = ' - ', $notooltip = 0, $save_lastsearch_value = -1, $morecss = '')
|
||||
{
|
||||
global $conf, $langs, $user, $hookmanager;
|
||||
|
||||
@ -1115,6 +1116,7 @@ class Project extends CommonObject
|
||||
if (!$this->public) $picto = 'project';
|
||||
|
||||
$linkstart = '<a href="'.$url.'"';
|
||||
$linkstart .= ($morecss ? ' class="'.$morecss.'"' : '');
|
||||
$linkstart .= $linkclose.'>';
|
||||
$linkend = '</a>';
|
||||
|
||||
|
||||
@ -318,7 +318,7 @@ if ($resql)
|
||||
}
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall tdoverflowmax100">';
|
||||
if ($obj->socid)
|
||||
{
|
||||
$companystatic->id = $obj->socid;
|
||||
|
||||
@ -1331,7 +1331,7 @@ else
|
||||
// Country
|
||||
print '<tr><td>'.$form->editfieldkey('Country', 'selectcountry_id', '', $object, 0).'</td><td colspan="3" class="maxwidthonsmartphone">';
|
||||
print img_picto('', 'globe-americas', 'class="paddingrightonly"');
|
||||
print $form->select_country((GETPOST('country_id') != '' ?GETPOST('country_id') : $object->country_id));
|
||||
print $form->select_country((GETPOST('country_id') != '' ? GETPOST('country_id') : $object->country_id), 'country_id', '', 0, 'minwidth300 widthcentpercentminusx');
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
print '</td></tr>';
|
||||
|
||||
@ -1354,16 +1354,16 @@ else
|
||||
|
||||
// Phone / Fax
|
||||
print '<tr><td>'.$form->editfieldkey('Phone', 'phone', '', $object, 0).'</td>';
|
||||
print '<td'.($conf->browser->layout == 'phone' ? ' colspan="3"': '').'>'.img_picto('', 'object_phoning').' <input type="text" name="phone" id="phone" class="maxwidth200" value="'.(GETPOSTISSET('phone') ?GETPOST('phone', 'alpha') : $object->phone).'"></td>';
|
||||
print '<td'.($conf->browser->layout == 'phone' ? ' colspan="3"': '').'>'.img_picto('', 'object_phoning').' <input type="text" name="phone" id="phone" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('phone') ?GETPOST('phone', 'alpha') : $object->phone).'"></td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey('Fax', 'fax', '', $object, 0).'</td>';
|
||||
print '<td'.($conf->browser->layout == 'phone' ? ' colspan="3"': '').'>'.img_picto('', 'object_phoning_fax').' <input type="text" name="fax" id="fax" class="maxwidth200" value="'.(GETPOSTISSET('fax') ?GETPOST('fax', 'alpha') : $object->fax).'"></td></tr>';
|
||||
print '<td'.($conf->browser->layout == 'phone' ? ' colspan="3"': '').'>'.img_picto('', 'object_phoning_fax').' <input type="text" name="fax" id="fax" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('fax') ?GETPOST('fax', 'alpha') : $object->fax).'"></td></tr>';
|
||||
|
||||
// Email / Web
|
||||
print '<tr><td>'.$form->editfieldkey('EMail', 'email', '', $object, 0, 'string', '', $conf->global->SOCIETE_EMAIL_MANDATORY).'</td>';
|
||||
print '<td colspan="3">'.img_picto('', 'object_email').' <input type="text" name="email" id="email" value="'.$object->email.'"></td></tr>';
|
||||
print '<td colspan="3">'.img_picto('', 'object_email').' <input type="text" class="widthcentpercentminusx" name="email" id="email" value="'.$object->email.'"></td></tr>';
|
||||
print '<tr><td>'.$form->editfieldkey('Web', 'url', '', $object, 0).'</td>';
|
||||
print '<td colspan="3">'.img_picto('', 'globe').' <input type="text" name="url" id="url" value="'.$object->url.'"></td></tr>';
|
||||
print '<td colspan="3">'.img_picto('', 'globe').' <input type="text" class="widthcentpercentminusx" name="url" id="url" value="'.$object->url.'"></td></tr>';
|
||||
|
||||
if (!empty($conf->socialnetworks->enabled)) {
|
||||
foreach ($socialnetworks as $key => $value) {
|
||||
@ -1380,42 +1380,6 @@ else
|
||||
}
|
||||
}
|
||||
|
||||
// if (! empty($conf->socialnetworks->enabled))
|
||||
// {
|
||||
// // Skype
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_SKYPE))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Skype', 'skype', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3">';
|
||||
// print '<input type="text" name="skype" class="minwidth100" maxlength="80" id="skype" value="'.dol_escape_htmltag(GETPOSTISSET("skype")?GETPOST("skype", 'alpha'):$object->skype).'">';
|
||||
// print '</td></tr>';
|
||||
// }
|
||||
// // Twitter
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_TWITTER))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Twitter', 'twitter', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3">';
|
||||
// print '<input type="text" name="twitter" class="minwidth100" maxlength="80" id="twitter" value="'.dol_escape_htmltag(GETPOSTISSET("twitter")?GETPOST("twitter", 'alpha'):$object->twitter).'">';
|
||||
// print '</td></tr>';
|
||||
// }
|
||||
// // Facebook
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_FACEBOOK))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Facebook', 'facebook', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3">';
|
||||
// print '<input type="text" name="facebook" class="minwidth100" maxlength="80" id="facebook" value="'.dol_escape_htmltag(GETPOSTISSET("facebook")?GETPOST("facebook", 'alpha'):$object->facebook).'">';
|
||||
// print '</td></tr>';
|
||||
// }
|
||||
// // LinkedIn
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_LINKEDIN))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('LinkedIn', 'linkedin', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3">';
|
||||
// print '<input type="text" name="linkedin" class="minwidth100" maxlength="80" id="linkedin" value="'.dol_escape_htmltag(GETPOSTISSET("linkedin")?GETPOST("linkedin", 'alpha'):$object->linkedin).'">';
|
||||
// print '</td></tr>';
|
||||
// }
|
||||
// }
|
||||
|
||||
// Prof ids
|
||||
$i = 1; $j = 0; $NBCOLS = ($conf->browser->layout == 'phone' ? 1 : 2);
|
||||
while ($i <= 6)
|
||||
@ -1432,7 +1396,7 @@ else
|
||||
|
||||
print $formcompany->get_input_id_prof($i, $key, $object->$key, $object->country_code);
|
||||
print '</td>';
|
||||
if (($j % 2) == 1) print '</tr>';
|
||||
if (($j % $NBCOLS) == ($NBCOLS - 1)) print '</tr>';
|
||||
$j++;
|
||||
}
|
||||
$i++;
|
||||
@ -1481,9 +1445,11 @@ else
|
||||
//TODO: Place into a function to control showing by country or study better option
|
||||
if ($mysoc->localtax1_assuj == "1" && $mysoc->localtax2_assuj == "1")
|
||||
{
|
||||
print '<tr><td>'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).'</td><td>';
|
||||
print '<tr><td>'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).'</td><td colspan="3">';
|
||||
print $form->selectyesno('localtax1assuj_value', (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1) ? $conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1 : 0), 1);
|
||||
print '</td><td>'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).'</td><td>';
|
||||
print '</td></tr>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<tr><td>'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).'</td><td colspan="3">';
|
||||
print $form->selectyesno('localtax2assuj_value', (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2) ? $conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2 : 0), 1);
|
||||
print '</td></tr>';
|
||||
}
|
||||
@ -1883,6 +1849,7 @@ else
|
||||
print '<td class="maxwidthonsmartphone">';
|
||||
print $formcompany->selectProspectCustomerType($object->client);
|
||||
print '</td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey('CustomerCode', 'customer_code', '', $object, 0).'</td><td>';
|
||||
|
||||
print '<table class="nobordernopadding"><tr><td>';
|
||||
@ -1914,15 +1881,18 @@ else
|
||||
|| (!empty($conf->supplier_proposal->enabled) && !empty($user->rights->supplier_proposal->lire)))
|
||||
{
|
||||
print '<tr>';
|
||||
print '<td>'.$form->editfieldkey('Supplier', 'fournisseur', '', $object, 0, 'string', '', 1).'</td><td class="maxwidthonsmartphone">';
|
||||
print '<td>'.$form->editfieldkey('Supplier', 'fournisseur', '', $object, 0, 'string', '', 1).'</td>';
|
||||
print '<td class="maxwidthonsmartphone">';
|
||||
print $form->selectyesno("fournisseur", $object->fournisseur, 1);
|
||||
print '</td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>';
|
||||
if (!empty($conf->fournisseur->enabled) && !empty($user->rights->fournisseur->lire))
|
||||
{
|
||||
print $form->editfieldkey('SupplierCode', 'supplier_code', '', $object, 0);
|
||||
}
|
||||
print '</td><td>';
|
||||
print '</td>';
|
||||
print '<td>';
|
||||
print '<table class="nobordernopadding"><tr><td>';
|
||||
if ((!$object->code_fournisseur || $object->code_fournisseur == -1) && $modCodeFournisseur->code_auto)
|
||||
{
|
||||
@ -1971,7 +1941,9 @@ else
|
||||
// Zip / Town
|
||||
print '<tr><td>'.$form->editfieldkey('Zip', 'zipcode', '', $object, 0).'</td><td>';
|
||||
print $formcompany->select_ziptown($object->zip, 'zipcode', array('town', 'selectcountry_id', 'state_id'), 0, 0, '', 'maxwidth50onsmartphone');
|
||||
print '</td><td>'.$form->editfieldkey('Town', 'town', '', $object, 0).'</td><td>';
|
||||
print '</td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey('Town', 'town', '', $object, 0).'</td><td>';
|
||||
print $formcompany->select_ziptown($object->town, 'town', array('zipcode', 'selectcountry_id', 'state_id'));
|
||||
print $form->widgetForTranslation("town", $object, $permissiontoadd, 'string', 'alphanohtml', 'maxwidth100 quatrevingtpercent');
|
||||
print '</td></tr>';
|
||||
@ -1979,7 +1951,7 @@ else
|
||||
// Country
|
||||
print '<tr><td>'.$form->editfieldkey('Country', 'selectcounty_id', '', $object, 0).'</td><td colspan="3">';
|
||||
print img_picto('', 'globe-americas', 'class="paddingrightonly"');
|
||||
print $form->select_country((GETPOSTISSET('country_id') ? GETPOST('country_id') : $object->country_id), 'country_id');
|
||||
print $form->select_country((GETPOSTISSET('country_id') ? GETPOST('country_id') : $object->country_id), 'country_id', '', 0, 'minwidth300 widthcentpercentminusx');
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
print '</td></tr>';
|
||||
|
||||
@ -2001,15 +1973,16 @@ else
|
||||
|
||||
// Phone / Fax
|
||||
print '<tr><td>'.$form->editfieldkey('Phone', 'phone', GETPOST('phone', 'alpha'), $object, 0).'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone" id="phone" class="maxwidth200" value="'.(GETPOSTISSET('phone') ?GETPOST('phone', 'alpha') : $object->phone).'"></td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone" id="phone" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('phone') ?GETPOST('phone', 'alpha') : $object->phone).'"></td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey('Fax', 'fax', GETPOST('fax', 'alpha'), $object, 0).'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning_fax').' <input type="text" name="fax" id="fax" class="maxwidth200" value="'.(GETPOSTISSET('fax') ?GETPOST('fax', 'alpha') : $object->fax).'"></td></tr>';
|
||||
print '<td>'.img_picto('', 'object_phoning_fax').' <input type="text" name="fax" id="fax" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('fax') ?GETPOST('fax', 'alpha') : $object->fax).'"></td></tr>';
|
||||
|
||||
// EMail / Web
|
||||
print '<tr><td>'.$form->editfieldkey('EMail', 'email', GETPOST('email', 'alpha'), $object, 0, 'string', '', (!empty($conf->global->SOCIETE_EMAIL_MANDATORY))).'</td>';
|
||||
print '<td colspan="3">'.img_picto('', 'object_email').' <input type="text" name="email" id="email" class="maxwidth100onsmartphone quatrevingtpercent" value="'.(GETPOSTISSET('email') ?GETPOST('email', 'alpha') : $object->email).'"></td></tr>';
|
||||
print '<td colspan="3">'.img_picto('', 'object_email').' <input type="text" name="email" id="email" class="maxwidth200onsmartphone widthcentpercentminusx" value="'.(GETPOSTISSET('email') ?GETPOST('email', 'alpha') : $object->email).'"></td></tr>';
|
||||
print '<tr><td>'.$form->editfieldkey('Web', 'url', GETPOST('url', 'alpha'), $object, 0).'</td>';
|
||||
print '<td colspan="3">'.img_picto('', 'globe').' <input type="text" name="url" id="url" class="maxwidth100onsmartphone quatrevingtpercent" value="'.(GETPOSTISSET('url') ?GETPOST('url', 'alpha') : $object->url).'"></td></tr>';
|
||||
print '<td colspan="3">'.img_picto('', 'globe').' <input type="text" name="url" id="url" class="maxwidth200onsmartphone widthcentpercentminusx " value="'.(GETPOSTISSET('url') ?GETPOST('url', 'alpha') : $object->url).'"></td></tr>';
|
||||
|
||||
if (!empty($conf->socialnetworks->enabled)) {
|
||||
foreach ($socialnetworks as $key => $value) {
|
||||
@ -2025,36 +1998,9 @@ else
|
||||
}
|
||||
}
|
||||
}
|
||||
// if (! empty($conf->socialnetworks->enabled))
|
||||
// {
|
||||
// // Skype
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_SKYPE))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Skype', 'skype', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3"><input type="text" name="skype" id="skype" value="'.$object->skype.'"></td></tr>';
|
||||
// }
|
||||
// // Twitter
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_TWITTER))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Twitter', 'twitter', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3"><input type="text" name="twitter" id="twitter" value="'.$object->twitter.'"></td></tr>';
|
||||
// }
|
||||
// // Facebook
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_FACEBOOK))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('Facebook', 'facebook', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3"><input type="text" name="facebook" id="facebook" value="'.$object->facebook.'"></td></tr>';
|
||||
// }
|
||||
// // LinkedIn
|
||||
// if (! empty($conf->global->SOCIALNETWORKS_LINKEDIN))
|
||||
// {
|
||||
// print '<tr><td>'.$form->editfieldkey('LinkedIn', 'linkedin', '', $object, 0).'</td>';
|
||||
// print '<td colspan="3"><input type="text" name="linkedin" id="linkedin" value="'.$object->linkedin.'"></td></tr>';
|
||||
// }
|
||||
// }
|
||||
|
||||
// Prof ids
|
||||
$i = 1; $j = 0;
|
||||
$i = 1; $j = 0; $NBCOLS = ($conf->browser->layout == 'phone' ? 1 : 2);
|
||||
while ($i <= 6)
|
||||
{
|
||||
$idprof = $langs->transcountry('ProfId'.$i, $object->country_code);
|
||||
@ -2062,13 +2008,13 @@ else
|
||||
{
|
||||
$key = 'idprof'.$i;
|
||||
|
||||
if (($j % 2) == 0) print '<tr>';
|
||||
if (($j % $NBCOLS) == 0) print '<tr>';
|
||||
|
||||
$idprof_mandatory = 'SOCIETE_IDPROF'.($i).'_MANDATORY';
|
||||
print '<td>'.$form->editfieldkey($idprof, $key, '', $object, 0, 'string', '', !(empty($conf->global->$idprof_mandatory) || !$object->isACompany())).'</td><td>';
|
||||
print $formcompany->get_input_id_prof($i, $key, $object->$key, $object->country_code);
|
||||
print '</td>';
|
||||
if (($j % 2) == 1) print '</tr>';
|
||||
if (($j % $NBCOLS) == ($NBCOLS - 1)) print '</tr>';
|
||||
$j++;
|
||||
}
|
||||
$i++;
|
||||
@ -2093,7 +2039,7 @@ else
|
||||
print '</span>';
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey($langs->transcountry("LocalTax2IsUsed", $mysoc->country_code), 'localtax2assuj_value', '', $object, 0).'</td><td>';
|
||||
print $form->selectyesno('localtax2assuj_value', $object->localtax2_assuj, 1);
|
||||
if (!isOnlyOneLocalTax(2))
|
||||
@ -2167,6 +2113,7 @@ else
|
||||
print $form->selectarray("typent_id", $formcompany->typent_array(0), $object->typent_id, 0, 0, 0, '', 0, 0, 0, (empty($conf->global->SOCIETE_SORT_ON_TYPEENT) ? 'ASC' : $conf->global->SOCIETE_SORT_ON_TYPEENT));
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
print '</td>';
|
||||
if ($conf->browser->layout == 'phone') print '</tr><tr>';
|
||||
print '<td>'.$form->editfieldkey('Staff', 'effectif_id', '', $object, 0).'</td><td class="maxwidthonsmartphone">';
|
||||
print $form->selectarray("effectif_id", $formcompany->effectif_array(0), $object->effectif_id);
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
|
||||
@ -17,6 +17,7 @@
|
||||
--colorbacklinepair2: rgb(<?php print $colorbacklinepair2; ?>);
|
||||
--colorbacklinepairhover: rgb(<?php print $colorbacklinepairhover; ?>);
|
||||
--colorbacklinepairchecked: rgb(<?php print $colorbacklinepairchecked; ?>);
|
||||
--colorbacklinebreak: rgb(<?php print $colorbacklinebreak; ?>);
|
||||
--colorbackbody: rgb(<?php print $colorbackbody; ?>);
|
||||
--colortexttitlenotab: rgb(<?php print $colortexttitlenotab; ?>);
|
||||
--colortexttitle: rgb(<?php print $colortexttitle; ?>);
|
||||
@ -3289,7 +3290,7 @@ td.evenodd, tr.nohoverpair td, #trlinefordates td {
|
||||
.trforbreak td {
|
||||
font-weight: 500;
|
||||
border-bottom: 1pt solid black !important;
|
||||
/* background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinebreak)); ?> !important; */
|
||||
background-color: var(--colorbacklinebreak) !important; !important;
|
||||
}
|
||||
.trforbreak.nobold td a, .trforbreak.nobold span.secondary {
|
||||
font-weight: normal !important;
|
||||
|
||||
@ -65,7 +65,7 @@ $colorbacklinepair1 = '251,251,251'; // line pair
|
||||
$colorbacklinepair2 = '251,251,251'; // line pair
|
||||
$colorbacklinepairhover = '230,237,244'; // line hover
|
||||
$colorbacklinepairchecked = '230,237,244'; // line checked
|
||||
$colorbacklinebreak = '233,228,230'; // line break
|
||||
$colorbacklinebreak = '253,251,250'; // line break
|
||||
$colorbackbody = '255,255,255';
|
||||
$colortexttitlenotab = '0,113,120'; // 150,90,121 140,80,10 or 10,140,80 #875a7b green=0,113,120, violet: 0,50,120
|
||||
$colortexttitle = '0,0,0';
|
||||
|
||||
@ -242,6 +242,7 @@ print '*/'."\n";
|
||||
--colorbacklinepair2: rgb(<?php print $colorbacklinepair2; ?>);
|
||||
--colorbacklinepairhover: rgb(<?php print $colorbacklinepairhover; ?>);
|
||||
--colorbacklinepairchecked: rgb(<?php print $colorbacklinepairchecked; ?>);
|
||||
--colorbacklinebreak: rgb(<?php print $colorbacklinebreak; ?>);
|
||||
--colorbackbody: rgb(<?php print $colorbackbody; ?>);
|
||||
--colortexttitlenotab: rgb(<?php print $colortexttitlenotab; ?>);
|
||||
--colortexttitle: rgb(<?php print $colortexttitle; ?>);
|
||||
@ -3284,10 +3285,10 @@ ul.noborder li:nth-child(odd):not(.liste_titre) {
|
||||
}
|
||||
.impair, .nohover .impair:hover, tr.impair td.nohover
|
||||
{
|
||||
background: #<?php echo colorArrayToHex(colorStringToArray($colorbacklineimpair1)); ?>;
|
||||
background: var(--colorbacklineimpair1);
|
||||
}
|
||||
#GanttChartDIV {
|
||||
background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklineimpair1)); ?>;
|
||||
background-color: var(--colorbacklineimpair1);
|
||||
}
|
||||
|
||||
.oddeven, .evenodd, .pair, .nohover .pair:hover, tr.pair td.nohover, .tagtr.oddeven {
|
||||
@ -3296,25 +3297,26 @@ ul.noborder li:nth-child(odd):not(.liste_titre) {
|
||||
color: #202020;
|
||||
}
|
||||
.pair, .nohover .pair:hover, tr.pair td.nohover {
|
||||
background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinepair1)); ?>;
|
||||
background-color: var(--colorbacklinepair1);
|
||||
}
|
||||
|
||||
table.dataTable tr.oddeven {
|
||||
background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinepair1)); ?> !important;
|
||||
background-color: var(--colorbacklinepair1) !important;
|
||||
}
|
||||
|
||||
/* For no hover style */
|
||||
td.oddeven, table.nohover tr.impair, table.nohover tr.pair, table.nohover tr.impair td, table.nohover tr.pair td, tr.nohover td, form.nohover, form.nohover:hover {
|
||||
background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklineimpair1)); ?> !important;
|
||||
background: #<?php echo colorArrayToHex(colorStringToArray($colorbacklineimpair1)); ?> !important;
|
||||
background-color: var(--colorbacklineimpair1) !important; !important;
|
||||
background: var(--colorbacklineimpair1) !important; !important;
|
||||
}
|
||||
td.evenodd, tr.nohoverpair td, #trlinefordates td {
|
||||
background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinepair1)); ?> !important;
|
||||
background: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinepair1)); ?> !important;
|
||||
background-color: var(--colorbacklinepair1) !important; !important;
|
||||
background: var(--colorbacklinepair1) !important; !important;
|
||||
}
|
||||
.trforbreak td {
|
||||
font-weight: bold;
|
||||
border-bottom: 1pt solid black !important;
|
||||
/* background-color: #<?php echo colorArrayToHex(colorStringToArray($colorbacklinebreak)); ?> !important; */
|
||||
background-color: var(--colorbacklinebreak) !important;
|
||||
}
|
||||
|
||||
table.dataTable td {
|
||||
|
||||
@ -61,7 +61,7 @@ $colorbacklinepair1 = '248,248,248'; // line pair
|
||||
$colorbacklinepair2 = '246,246,246'; // line pair
|
||||
$colorbacklinepairhover = '230,237,244'; // line hover
|
||||
$colorbacklinepairchecked = '230,237,244'; // line checked
|
||||
$colorbacklinebreak = '214,218,220';
|
||||
$colorbacklinebreak = '250,246,251';
|
||||
$colorbackbody = '248,248,248';
|
||||
$colortexttitlenotab = '80,71,5';
|
||||
$colortexttitle = '20,20,20';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user