diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index 989aa001131..42b5fc4056a 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -104,7 +104,7 @@ if ($action == 'update') else dolibarr_set_const($db, 'THEME_ELDY_TEXTLINK', implode(',',colorStringToArray(GETPOST('THEME_ELDY_TEXTLINK'),array())),'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_SIZE_LISTE_LIMIT", $_POST["main_size_liste_limit"],'chaine',0,'',$conf->entity); - dolibarr_set_const($db, "MAIN_SIZE_SHORTLISTE_LIMIT", $_POST["main_size_shortliste_limit"],'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "MAIN_SIZE_SHORTLIST_LIMIT", $_POST["main_size_shortliste_limit"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_DISABLE_JAVASCRIPT", $_POST["main_disable_javascript"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_BUTTON_HIDE_UNAUTHORIZED", $_POST["MAIN_BUTTON_HIDE_UNAUTHORIZED"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_START_WEEK", $_POST["MAIN_START_WEEK"],'chaine',0,'',$conf->entity); @@ -225,7 +225,7 @@ if ($action == 'edit') // Edit // Max size of short lists on customer card $var=!$var; - print ''.$langs->trans("DefaultMaxSizeShortList").''; + print ''.$langs->trans("DefaultMaxSizeShortList").''; print ' '; print ''; @@ -408,7 +408,7 @@ else // Show print ""; $var=!$var; - print ''.$langs->trans("DefaultMaxSizeShortList").'' . $conf->global->MAIN_SIZE_SHORTLISTE_LIMIT . ''; + print ''.$langs->trans("DefaultMaxSizeShortList").'' . $conf->global->MAIN_SIZE_SHORTLIST_LIMIT . ''; print ' '; print ""; diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php index cc4b7719069..cebe1b60c80 100644 --- a/htdocs/comm/card.php +++ b/htdocs/comm/card.php @@ -217,14 +217,14 @@ if ($id > 0) print ''; // Prospect/Customer - print ''; // Prefix if (! empty($conf->global->SOCIETE_USEPREFIX)) // Old not used prefix field { - print ''; } @@ -234,7 +234,7 @@ if ($id > 0) $langs->load("compta"); print ''; @@ -242,7 +242,7 @@ if ($id > 0) print ''; print ''; print ''; @@ -251,12 +251,12 @@ if ($id > 0) // Skype if (! empty($conf->skype->enabled)) { - print ''; + print ''; } // Assujeti a TVA ou pas print ''; - print ''; print ''; @@ -264,20 +264,20 @@ if ($id > 0) // Local Taxes if ($mysoc->useLocalTax(1)) { - print ''; } if ($mysoc->useLocalTax(2)) { - print ''; } // TVA Intra - print ''; @@ -289,7 +289,7 @@ if ($id > 0) print ''; print '
'.$langs->trans('ProspectCustomer').''; + print '
'.$langs->trans('ProspectCustomer').''; print $object->getLibCustProspStatut(); print '
'.$langs->trans("Prefix").''; + print '
'.$langs->trans("Prefix").''; print ($object->prefix_comm?$object->prefix_comm:' '); print '
'; - print $langs->trans('CustomerCode').''; + print $langs->trans('CustomerCode').''; print $object->code_client; if ($object->check_codeclient() <> 0) print ' ('.$langs->trans("WrongCustomerCode").')'; print '
'; print $form->editfieldkey("CustomerAccountancyCode",'customeraccountancycode',$object->code_compta,$object,$user->rights->societe->creer); - print ''; + print ''; print $form->editfieldval("CustomerAccountancyCode",'customeraccountancycode',$object->code_compta,$object,$user->rights->societe->creer); print '
'.$langs->trans('Skype').''.dol_print_skype($object->skype,0,$object->id,'AC_SKYPE').'
'.$langs->trans('Skype').''.dol_print_skype($object->skype,0,$object->id,'AC_SKYPE').'
'.$langs->trans('VATIsUsed').''; + print ''.$langs->trans('VATIsUsed').''; print yn($object->tva_assuj); print '
'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).''; + print '
'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).''; print yn($object->localtax1_assuj); print '
'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).''; + print '
'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).''; print yn($object->localtax2_assuj); print '
'.$langs->trans('VATIntra').''; + print '
'.$langs->trans('VATIntra').''; print $object->tva_intra; print '
'; if (($action != 'editconditions') && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('SetConditions'),1).'
'; - print ''; + print ''; if ($action == 'editconditions') { $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id, $object->cond_reglement_id, 'cond_reglement_id',1); @@ -308,7 +308,7 @@ if ($id > 0) print ''; if (($action != 'editmode') && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('SetMode'),1).''; print ''; - print ''; + print ''; if ($action == 'editmode') { $form->form_modes_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->mode_reglement_id,'mode_reglement_id'); @@ -323,11 +323,11 @@ if ($id > 0) // Compte bancaire par défaut print ''; print ''; print '
'; - print $langs->trans('BankAccount'); + print $langs->trans('PaymentBankAccount'); print ''; if (($action != 'editbankaccount') && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('SetBankAccount'),1).'
'; - print ''; + print ''; if ($action == 'editbankaccount') { $form->formSelectAccount($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->fk_account,'fk_account',1); @@ -350,7 +350,7 @@ if ($id > 0) print ''.img_edit($langs->trans("Modify")).''; } print ''; - print ''.($object->remise_percent?''.$object->remise_percent.'%':'').''; + print ''.($object->remise_percent?''.$object->remise_percent.'%':'').''; print ''; // Absolute discounts (Discounts-Drawbacks-Rebates) @@ -365,7 +365,7 @@ if ($id > 0) } print ''; print ''; - print ''; + print ''; $amount_discount=$object->getAvailableDiscounts(); if ($amount_discount < 0) dol_print_error($db,$object->error); if ($amount_discount > 0) print ''.price($amount_discount,1,$langs,1,-1,-1,$conf->currency).''; @@ -373,20 +373,6 @@ if ($id > 0) print ''; print ''; - if ($object->client) - { - print ''; - print ''; - print $form->editfieldkey("OutstandingBill",'outstanding_limit',$object->outstanding_limit,$object,$user->rights->societe->creer); - print ''; - $limit_field_type = (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE)) ? 'numeric' : 'amount'; - print $form->editfieldval("OutstandingBill",'outstanding_limit',$object->outstanding_limit,$object,$user->rights->societe->creer,$limit_field_type,($object->outstanding_limit != '' ? price($object->outstanding_limit) : '')); - //if (empty($object->outstanding_limit)) print $langs->trans("NoLimit"); - - print ''; - print ''; - } - // Multiprice level if (! empty($conf->global->PRODUIT_MULTIPRICES)) { @@ -399,7 +385,7 @@ if ($id > 0) print ''.img_edit($langs->trans("Modify")).''; } print ''; - print ''; + print ''; print $object->price_level; $keyforlabel='PRODUIT_MULTIPRICES_LABEL'.$object->price_level; if (! empty($conf->global->$keyforlabel)) print ' - '.$langs->trans($conf->global->$keyforlabel); @@ -407,36 +393,6 @@ if ($id > 0) print ''; } - if ($object->client == 2 || $object->client == 3) - { - // Level of prospect - print ''; - print ''; - print '
'; - print $langs->trans('ProspectLevel'); - print ''; - if ($action != 'editlevel' && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('Modify'),1).'
'; - print ''; - if ($action == 'editlevel') - $formcompany->form_prospect_level($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->fk_prospectlevel,'prospect_level_id',1); - else - print $object->getLibProspLevel(); - print ""; - print ''; - - // Status - $object->loadCacheOfProspStatus(); - print ''.$langs->trans("StatusProsp").''.$object->getLibProspCommStatut(4, $object->cacheprospectstatus[$object->stcomm_id]['label']); - print '    
'; - foreach($object->cacheprospectstatus as $key => $val) - { - $titlealt='default'; - if (! empty($val['code']) && ! in_array($val['code'], array('ST_NO', 'ST_NEVER', 'ST_TODO', 'ST_PEND', 'ST_DONE'))) $titlealt=$val['label']; - if ($object->stcomm_id != $val['id']) print ''.img_action($titlealt,$val['code']).''; - } - print '
'; - } - // Preferred shipping Method if (! empty($conf->global->SOCIETE_ASK_FOR_SHIPPING_METHOD)) { print ''; @@ -445,7 +401,7 @@ if ($id > 0) print ''; if (($action != 'editshipping') && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('SetMode'),1).''; print ''; - print ''; + print ''; if ($action == 'editshipping') { $form->formSelectShippingMethod($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->shipping_method_id,'shipping_method_id'); @@ -462,7 +418,7 @@ if ($id > 0) if (!empty($conf->categorie->enabled) && !empty($user->rights->categorie->lire)) { $langs->load("categories"); print '' . $langs->trans("CustomersCategoriesShort") . ''; - print ''; + print ''; print $form->showCategories( $object->id, 'customer', 1 ); print ""; } @@ -484,8 +440,8 @@ if ($id > 0) { $langs->load("members"); $langs->load("users"); - print ''.$langs->trans("LinkedToDolibarrMember").''; - print ''; + print ''.$langs->trans("LinkedToDolibarrMember").''; + print ''; $adh=new Adherent($db); $result=$adh->fetch('','',$object->id); if ($result > 0) @@ -503,12 +459,47 @@ if ($id > 0) print ""; + print '
'; + print '
'; + print ''; + + if ($object->client == 2 || $object->client == 3) + { + // Level of prospect + print '"; + print ''; + + // Status + $object->loadCacheOfProspStatus(); + print ''; + } + print "
'; + print ''; + print '
'; + print $langs->trans('ProspectLevel'); + print ''; + if ($action != 'editlevel' && $user->rights->societe->creer) print 'id.'">'.img_edit($langs->trans('Modify'),1).'
'; + print '
'; + if ($action == 'editlevel') + $formcompany->form_prospect_level($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->fk_prospectlevel,'prospect_level_id',1); + else + print $object->getLibProspLevel(); + print "
'.$langs->trans("StatusProsp").''.$object->getLibProspCommStatut(4, $object->cacheprospectstatus[$object->stcomm_id]['label']); + print '    
'; + foreach($object->cacheprospectstatus as $key => $val) + { + $titlealt='default'; + if (! empty($val['code']) && ! in_array($val['code'], array('ST_NO', 'ST_NEVER', 'ST_TODO', 'ST_PEND', 'ST_DONE'))) $titlealt=$val['label']; + if ($object->stcomm_id != $val['id']) print ''.img_action($titlealt,$val['code']).''; + } + print '
"; + print '
'; // Nbre max d'elements des petites listes - $MAXLIST=$conf->global->MAIN_SIZE_SHORTLISTE_LIMIT; + $MAXLIST=$conf->global->MAIN_SIZE_SHORTLIST_LIMIT; // Lien recap $outstandingBills = $object->get_OutstandingBill(); @@ -519,14 +510,33 @@ if ($id > 0) } print ''; + print ''; print ''; print ''; print ''; - print ''; + + // Max outstanding bill + if ($object->client) + { + print ''; + print ''; + print ''; + } + + // Outstanding bill + print ''; print ''; - print ''; + print ''; print ''; + print '
'.$langs->trans("Summary").''.$langs->trans("ShowCustomerPreview").'
'; + print $form->editfieldkey("OutstandingBill",'outstanding_limit',$object->outstanding_limit,$object,$user->rights->societe->creer); + print ''; + $limit_field_type = (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE)) ? 'numeric' : 'amount'; + print $form->editfieldval("OutstandingBill",'outstanding_limit',$object->outstanding_limit,$object,$user->rights->societe->creer,$limit_field_type,($object->outstanding_limit != '' ? price($object->outstanding_limit) : '')); + //if (empty($object->outstanding_limit)) print $langs->trans("NoLimit"); + + print '
'.$langs->trans("CurrentOutstandingBill").''.price($outstandingBills).$warn.''.price($outstandingBills).$warn.'
'; print '
'; diff --git a/htdocs/fourn/card.php b/htdocs/fourn/card.php index 6f17d7825bb..5faf915f329 100644 --- a/htdocs/fourn/card.php +++ b/htdocs/fourn/card.php @@ -280,7 +280,7 @@ if ($object->id > 0) $var=true; - $MAXLIST=5; + $MAXLIST=$conf->global->MAIN_SIZE_SHORTLIST_LIMIT; // Lien recap print ''; diff --git a/htdocs/fourn/facture/list.php b/htdocs/fourn/facture/list.php index b8e90dbce10..ebe65f62122 100644 --- a/htdocs/fourn/facture/list.php +++ b/htdocs/fourn/facture/list.php @@ -435,7 +435,7 @@ if ($resql) print ''; print ''; - print_barre_liste($langs->trans("BillsSuppliers").($socid?" $soc->name.":""),$page,$_SERVER["PHP_SELF"],$param,$sortfield,$sortorder,'',$num,$nbtotalofrecords,'title_accountancy',0,'','',$limit); + print_barre_liste($langs->trans("BillsSuppliers").($socid?" - $soc->name":""),$page,$_SERVER["PHP_SELF"],$param,$sortfield,$sortorder,'',$num,$nbtotalofrecords,'title_accountancy',0,'','',$limit); if ($search_all) { diff --git a/htdocs/install/mysql/data/llx_const.sql b/htdocs/install/mysql/data/llx_const.sql index d6286c8e120..0a31d3c3159 100644 --- a/htdocs/install/mysql/data/llx_const.sql +++ b/htdocs/install/mysql/data/llx_const.sql @@ -55,7 +55,7 @@ insert into llx_const (name, value, type, note, visible, entity) values ('MAIN_M -- IHM -- insert into llx_const (name, value, type, note, visible, entity) values ('MAIN_SIZE_LISTE_LIMIT','25','chaine','Longueur maximum des listes',0,0); -insert into llx_const (name, value, type, note, visible, entity) values ('MAIN_SIZE_SHORTLISTE_LIMIT','4','chaine','Longueur maximum des listes courtes (fiche client)',0,0); +insert into llx_const (name, value, type, note, visible, entity) values ('MAIN_SIZE_SHORTLIST_LIMIT','3','chaine','Longueur maximum des listes courtes (fiche client)',0,0); insert into llx_const (name, value, type, note, visible, entity) values ('MAIN_SHOW_WORKBOARD','1','yesno','Affichage tableau de bord de travail Dolibarr',0,0); insert into llx_const (name, value, type, note, visible) values ('MAIN_MENU_STANDARD','eldy_menu.php','chaine','Menu manager for internal users',0); diff --git a/htdocs/install/mysql/migration/3.8.0-3.9.0.sql b/htdocs/install/mysql/migration/3.8.0-3.9.0.sql index 1a776c27e66..d5f7f636946 100644 --- a/htdocs/install/mysql/migration/3.8.0-3.9.0.sql +++ b/htdocs/install/mysql/migration/3.8.0-3.9.0.sql @@ -61,7 +61,7 @@ update llx_opensurvey_sondage set format = 'D' where format = 'D+'; update llx_opensurvey_sondage set format = 'A' where format = 'A+'; INSERT INTO llx_const (name, value, type, note, visible) values (__ENCRYPT('MAIN_DELAY_EXPENSEREPORTS_TO_PAY')__,__ENCRYPT('31')__,'chaine','Tolérance de retard avant alerte (en jours) sur les notes de frais impayées',0); -INSERT INTO llx_const (name, value, type, note, visible) values ('MAIN_SIZE_SHORTLISTE_LIMIT','4','chaine','Longueur maximum des listes courtes (fiche client)',0); +INSERT INTO llx_const (name, value, type, note, visible) values ('MAIN_SIZE_SHORTLIST_LIMIT','3','chaine','Max length for small lists (tabs)',0); ALTER TABLE llx_accounting_system MODIFY COLUMN pcg_version varchar(32); ALTER TABLE llx_accountingaccount MODIFY COLUMN fk_pcg_version varchar(32); diff --git a/htdocs/install/mysql/migration/4.0.0-5.0.0.sql b/htdocs/install/mysql/migration/4.0.0-5.0.0.sql index 8b1c554ee1a..74527f33aa1 100644 --- a/htdocs/install/mysql/migration/4.0.0-5.0.0.sql +++ b/htdocs/install/mysql/migration/4.0.0-5.0.0.sql @@ -164,3 +164,5 @@ create table llx_resource_extrafields ) ENGINE=innodb; ALTER TABLE llx_resource_extrafields ADD INDEX idx_resource_extrafields (fk_object); + +INSERT INTO llx_const (name, value, type, note, visible) values ('MAIN_SIZE_SHORTLIST_LIMIT','3','chaine','Max length for small lists (tabs)',0); diff --git a/htdocs/langs/en_US/companies.lang b/htdocs/langs/en_US/companies.lang index e77b53db26f..73e9dab189c 100644 --- a/htdocs/langs/en_US/companies.lang +++ b/htdocs/langs/en_US/companies.lang @@ -76,7 +76,8 @@ DefaultLang=Language by default VATIsUsed=VAT is used VATIsNotUsed=VAT is not used CopyAddressFromSoc=Fill address with third party address -ThirdpartyNotCustomerNotSupplierSoNoRef=Thirdparty neither customer nor supplier, no available refering objects +ThirdpartyNotCustomerNotSupplierSoNoRef=Thirdparty neither customer nor supplier, no available refering objects +PaymentBankAccount=Payment bank account ##### Local Taxes ##### LocalTax1IsUsed=Use second tax LocalTax1IsUsedES= RE is used diff --git a/htdocs/langs/en_US/supplier_proposal.lang b/htdocs/langs/en_US/supplier_proposal.lang index 6bb28be6a7a..94c0ef2e039 100644 --- a/htdocs/langs/en_US/supplier_proposal.lang +++ b/htdocs/langs/en_US/supplier_proposal.lang @@ -50,5 +50,5 @@ ListOfSupplierProposal=List of supplier proposal requests ListSupplierProposalsAssociatedProject=List of supplier proposals associated with project SupplierProposalsToClose=Supplier proposals to close SupplierProposalsToProcess=Supplier proposals to process -LastSupplierProposals=Last price requests +LastSupplierProposals=Latest %s price requests AllPriceRequests=All requests