Merge branch 'develop' into 10.0_accountancy2
This commit is contained in:
commit
9210a39f6a
@ -31,7 +31,6 @@ addons:
|
||||
- pgloader
|
||||
|
||||
php:
|
||||
- '5.4'
|
||||
- '5.5'
|
||||
- '5.6'
|
||||
- '7.0'
|
||||
@ -62,8 +61,6 @@ matrix:
|
||||
- php: nightly
|
||||
# We exclude some combinations not usefull to save Travis CPU
|
||||
exclude:
|
||||
- php: '5.5'
|
||||
env: DB=mariadb
|
||||
- php: '5.6'
|
||||
env: DB=mariadb
|
||||
- php: '7.0'
|
||||
@ -72,8 +69,6 @@ matrix:
|
||||
env: DB=mariadb
|
||||
- php: '7.2'
|
||||
env: DB=mariadb
|
||||
- php: '5.5'
|
||||
env: DB=postgresql
|
||||
- php: '5.6'
|
||||
env: DB=postgresql
|
||||
- php: '7.0'
|
||||
|
||||
11
COPYRIGHT
11
COPYRIGHT
@ -14,9 +14,10 @@ Component Version License GPL Compatible
|
||||
PHP libraries:
|
||||
AdoDb-Date 0.36 Modified BSD License Yes Date convertion (not into rpm package)
|
||||
ChromePHP 4.1.0 Apache Software License 2.0 Yes Return server log to chrome browser console
|
||||
CKEditor 4.6.2 LGPL-2.1+ Yes Editor WYSIWYG
|
||||
CKEditor 4.11.4 LGPL-2.1+ Yes Editor WYSIWYG
|
||||
PHPDebugBar 1.15.0 MIT License Yes Used only by the module "debugbar" for developers
|
||||
EvalMath 1.0 BSD Yes Safe math expressions evaluation
|
||||
Escpos-php MIT License Yes Thermal receipt printer library, for use with ESC/POS compatible printers
|
||||
Escpos-php ? MIT License Yes Thermal receipt printer library, for use with ESC/POS compatible printers
|
||||
GeoIP 1.4 LGPL-2.1+ Yes Sample code to make geoip convert (not into deb package)
|
||||
Mobiledetect 2.8.17 MIT License Yes Detect mobile devices browsers
|
||||
NuSoap 0.9.5 LGPL 2.1+ Yes Library to develop SOAP Web services (not into rpm and deb package)
|
||||
@ -24,9 +25,12 @@ PEAR Mail_MIME 1.8.9 BSD Yes
|
||||
odtPHP 1.0.1 GPL-2+ Yes Library to build/edit ODT files
|
||||
ParseDown 1.6 MIT License Yes Markdown parser
|
||||
PHPExcel 1.8.1 LGPL-2.1+ Yes Read/Write XLS files, read ODS files
|
||||
PHPSpreadSheet ? LGPL-2.1+ Yes Read/Write XLS files, read ODS files
|
||||
php-iban 1.4.7 LGPL-3+ Yes Parse and validate IBAN (and IIBAN) bank account information in PHP
|
||||
PHPoAuthLib 0.8.2 MIT License Yes Library to provide oauth1 and oauth2 to different service
|
||||
PHPPrintIPP 1.3 GPL-2+ Yes Library to send print IPP requests
|
||||
PSR/Logs 1.0 Library for logs (used by DebugBar)
|
||||
PSR/simple-cache Library for cache (used by PHPSpreadSheet)
|
||||
Restler 3.0.0RC6 LGPL-3+ Yes Library to develop REST Web services (+ swagger-ui js lib into dir explorer)
|
||||
TCPDF 6.2.25 LGPL-3+ Yes PDF generation
|
||||
TCPDI 1.0.0 LGPL-3+ / Apache 2.0 Yes FPDI replacement
|
||||
@ -57,8 +61,7 @@ Image libraries:
|
||||
Octicons 8.1 MIT Yes
|
||||
|
||||
Font libraries:
|
||||
Fontawesome 4.7 ? Yes
|
||||
Fontawesome 5.0 ? Yes
|
||||
Fontawesome 5.7.2 Font Awesome Free licence Yes
|
||||
|
||||
|
||||
For licenses compatibility informations:
|
||||
|
||||
@ -47,7 +47,7 @@ You can use a Web server and a supported database (MariaDB, MySQL or PostgreSQL)
|
||||
|
||||
git clone https://github.com/dolibarr/dolibarr -b x.y (where x.y is main version like 3.6, 9.0, ...)
|
||||
|
||||
- Set up your web server to use "*dolibarr/htdocs*" as root if you'r web server does not have directory to point to already defined.
|
||||
- Set up your web server to use "*dolibarr/htdocs*" as root if your web server does not have an already defined directory to point to.
|
||||
|
||||
- Create an empty `htdocs/conf/conf.php` file and set *write* permissions for your web server user (*write* permission will be removed once install is finished)
|
||||
|
||||
|
||||
@ -8,6 +8,15 @@ ALL:
|
||||
Check "@CHANGE"
|
||||
|
||||
|
||||
PrestaShopWebservice:
|
||||
---------------------
|
||||
Replace
|
||||
$params = array('filter', 'display', 'sort', 'limit', 'id_shop', 'id_group_shop');
|
||||
With
|
||||
$params = array('filter', 'display', 'sort', 'limit', 'id_shop', 'id_group_shop', 'date');
|
||||
|
||||
|
||||
|
||||
CKEDITOR (4.6.2):
|
||||
-----------------
|
||||
* In ckeditor/ckeditor/contents.css
|
||||
|
||||
@ -56,6 +56,14 @@ $sqls=array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."user_rights WHERE fk_user IN (SELECT rowid FROM ".MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin') AND fk_user IN (select rowid FROM ".MAIN_DB_PREFIX."user where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin' AND datec < '__DATE__'",
|
||||
),
|
||||
'event'=>array(
|
||||
//"DELETE FROM ".MAIN_DB_PREFIX."actioncomm WHERE lineid IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."actioncomm WHERE datec < '__DATE__'",
|
||||
),
|
||||
'payment'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."paiement_facture where fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."paiement where rowid NOT IN (SELECT fk_paiement FROM ".MAIN_DB_PREFIX."paiement_facture)",
|
||||
),
|
||||
'bank'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_class WHERE lineid IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_url WHERE fk_bank IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
@ -64,22 +72,19 @@ $sqls=array(
|
||||
'bankaccount'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_account WHERE datec < '__DATE__'",
|
||||
),
|
||||
'contract'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where date < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where date < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat WHERE datec < '__DATE__'",
|
||||
),
|
||||
'invoice'=>array(
|
||||
'@payment',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture_source IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture_line IN (select rowid FROM ".MAIN_DB_PREFIX."facturedet as fd WHERE fd.fk_facture IN (select rowid from ".MAIN_DB_PREFIX."facture where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."paiement_facture where fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_rec where datec < '__DATE__'",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facturedet WHERE fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"UPDATE ".MAIN_DB_PREFIX."facture SET fk_facture_source = NULL WHERE fk_facture_source IN (select f2.rowid FROM (select * from ".MAIN_DB_PREFIX."facture) as f2 where f2.datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__'",
|
||||
),
|
||||
'accounting'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."accounting_bookkeeping where doc_date < '__DATE__'",
|
||||
),
|
||||
'proposal'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."propaldet WHERE fk_propal IN (select rowid FROM ".MAIN_DB_PREFIX."propal where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."propal WHERE datec < '__DATE__'",
|
||||
@ -88,7 +93,12 @@ $sqls=array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."supplier_proposaldet WHERE fk_supplier_proposal IN (select rowid FROM ".MAIN_DB_PREFIX."propal where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."supplier_proposal where datec < '__DATE__'",
|
||||
),
|
||||
'supplier_order'=>array(
|
||||
'order'=>array(
|
||||
'@shipment',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commandedet WHERE fk_commande IN (select rowid FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__'",
|
||||
),
|
||||
'supplier_order'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande_fournisseurdet WHERE fk_commande IN (select rowid FROM ".MAIN_DB_PREFIX."commande_fournisseur where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande_fournisseur where date_creation < '__DATE__'",
|
||||
),
|
||||
@ -96,10 +106,6 @@ $sqls=array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_fourn_det WHERE fk_facture_fourn IN (select rowid FROM ".MAIN_DB_PREFIX."facture_fourn where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_fourn where datec < '__DATE__'",
|
||||
),
|
||||
'delivery'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraisondet WHERE fk_livraison IN (select rowid FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__'",
|
||||
),
|
||||
'shipment'=>array(
|
||||
'@delivery',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expeditiondet_batch WHERE fk_expeditiondet IN (select rowid FROM ".MAIN_DB_PREFIX."expeditiondet WHERE fk_expedition IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__'))",
|
||||
@ -108,15 +114,23 @@ $sqls=array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expedition_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__'",
|
||||
),
|
||||
'order'=>array(
|
||||
'@shipment',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commandedet WHERE fk_commande IN (select rowid FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__'",
|
||||
'delivery'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraisondet WHERE fk_livraison IN (select rowid FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__'",
|
||||
),
|
||||
'contract'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat WHERE datec < '__DATE__'",
|
||||
),
|
||||
'intervention'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."fichinterdet WHERE fk_fichinter IN (select rowid FROM ".MAIN_DB_PREFIX."fichinter where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."fichinter where datec < '__DATE__'",
|
||||
),
|
||||
'stock'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."stock_mouvement WHERE datem < '__DATE__'",
|
||||
),
|
||||
'product'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."categorie_product WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_lang WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
@ -169,13 +183,26 @@ if (empty($mode) || ! in_array($mode, array('test','confirm'))) {
|
||||
print "option can be ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
if (empty($option) || ! in_array($option, array_merge(array('all'), array_keys($sqls))) ) {
|
||||
if (empty($option))
|
||||
{
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option can be ".implode(',', array_keys($sqls))."\n";
|
||||
print "option must be defined with a value in list ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
if ($option != 'all')
|
||||
{
|
||||
$listofoptions=explode(',', $option);
|
||||
foreach($listofoptions as $cursoroption)
|
||||
{
|
||||
if (! in_array($cursoroption, array_keys($sqls))) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option '".$cursoroption."' must be in list ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($date) || (! preg_match('/\d\d\d\d\-\d\d\-\d\d$/', $date) && $date != 'all')) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
@ -269,19 +296,23 @@ function processfamily($family, $date)
|
||||
|
||||
$db->begin();
|
||||
|
||||
$oldfamily='';
|
||||
foreach($sqls as $family => $familysql)
|
||||
$listofoptions=explode(',', $option);
|
||||
foreach($listofoptions as $cursoroption)
|
||||
{
|
||||
if ($option && $option != 'all' && $option != $family) continue;
|
||||
|
||||
if ($family != $oldfamily) print "Process action for family ".$family."\n";
|
||||
$oldfamily = $family;
|
||||
|
||||
$result=processfamily($family, $date);
|
||||
if ($result < 0)
|
||||
$oldfamily='';
|
||||
foreach($sqls as $family => $familysql)
|
||||
{
|
||||
$error++;
|
||||
break;
|
||||
if ($cursoroption && $cursoroption != 'all' && $cursoroption != $family) continue;
|
||||
|
||||
if ($family != $oldfamily) print "Process action for family ".$family."\n";
|
||||
$oldfamily = $family;
|
||||
|
||||
$result=processfamily($family, $date);
|
||||
if ($result < 0)
|
||||
{
|
||||
$error++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -7853,7 +7853,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@ -8260,7 +8260,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@ -8612,7 +8612,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@ -9181,7 +9181,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@ -6360,7 +6360,7 @@ CREATE TABLE `llx_emailcollector_emailcollector` (
|
||||
|
||||
LOCK TABLES `llx_emailcollector_emailcollector` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_emailcollector_emailcollector` DISABLE KEYS */;
|
||||
INSERT INTO `llx_emailcollector_emailcollector` VALUES (1,1,'MyEmailCollector1','My email collector 1','aaa','imap.gmail.com','testldr10@gmail.com','testldr10-10','INBOX','','','aftercollect','2018-11-19 15:21:07','1 emails analyzed, 1 emails successfuly processed (for 3 record/actions done) by collector',NULL,NULL,'2018-10-31 18:08:05','2018-10-31 17:08:05',12,12,NULL,1,'OK',0);
|
||||
INSERT INTO `llx_emailcollector_emailcollector` VALUES (1,1,'MyEmailCollector1','My email collector 1','aaa','imap.gmail.com','testldr10@example.com','testldr10-10','INBOX','','','aftercollect','2018-11-19 15:21:07','1 emails analyzed, 1 emails successfuly processed (for 3 record/actions done) by collector',NULL,NULL,'2018-10-31 18:08:05','2018-10-31 17:08:05',12,12,NULL,1,'OK',0);
|
||||
/*!40000 ALTER TABLE `llx_emailcollector_emailcollector` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
@ -12450,7 +12450,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@ -6275,7 +6275,7 @@ CREATE TABLE `llx_emailcollector_emailcollector` (
|
||||
|
||||
LOCK TABLES `llx_emailcollector_emailcollector` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_emailcollector_emailcollector` DISABLE KEYS */;
|
||||
INSERT INTO `llx_emailcollector_emailcollector` VALUES (1,1,'MyEmailCollector1','My email collector 1','aaa','imap.gmail.com','testldr10@gmail.com','testldr10-10','INBOX','','','aftercollect','2018-11-19 15:21:07','1 emails analyzed, 1 emails successfuly processed (for 3 record/actions done) by collector',NULL,NULL,'2018-10-31 18:08:05','2018-10-31 17:08:05',12,12,NULL,1,'OK',0);
|
||||
INSERT INTO `llx_emailcollector_emailcollector` VALUES (1,1,'MyEmailCollector1','My email collector 1','aaa','imap.gmail.com','testldr10@example.com','testldr10-10','INBOX','','','aftercollect','2018-11-19 15:21:07','1 emails analyzed, 1 emails successfuly processed (for 3 record/actions done) by collector',NULL,NULL,'2018-10-31 18:08:05','2018-10-31 17:08:05',12,12,NULL,1,'OK',0);
|
||||
/*!40000 ALTER TABLE `llx_emailcollector_emailcollector` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
@ -12388,7 +12388,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2012-07-08 14:26:14','2018-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2012-07-08','Project leader','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2012-07-08 22:44:50','2012-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2012-07-08 22:59:02','2018-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2012-07-09 00:16:58','2012-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2013-08-01 02:41:26','2018-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2018-07-30 16:11:06','2018-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2018-07-30 16:13:03','2018-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2018-07-30 16:14:41','2018-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2018-07-30 16:26:22','2018-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2012-07-08 14:26:14','2018-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2012-07-08','Project leader','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2012-07-08 22:44:50','2012-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2012-07-08 22:59:02','2018-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2012-07-09 00:16:58','2012-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2013-08-01 02:41:26','2018-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2018-07-30 16:11:06','2018-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2018-07-30 16:13:03','2018-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2018-07-30 16:14:41','2018-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2018-07-30 16:26:22','2018-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
BIN
dev/resources/iso-normes/Accountancy-format_Ebp_txt.pdf
Normal file
BIN
dev/resources/iso-normes/Accountancy-format_Ebp_txt.pdf
Normal file
Binary file not shown.
@ -8,9 +8,11 @@
|
||||
<exclude-pattern type="relative">documents</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/custom</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/includes</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/install/doctemplates/websites</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/conf.php</exclude-pattern>
|
||||
<exclude-pattern type="relative">*/nltechno*</exclude-pattern>
|
||||
<exclude-pattern type="relative">*/htdocs/includes</exclude-pattern>
|
||||
<exclude-pattern type="relative">*/htdocs/includes</exclude-pattern>
|
||||
|
||||
<!-- List of all tests -->
|
||||
|
||||
|
||||
@ -21,14 +21,14 @@
|
||||
|
||||
<div class="center">
|
||||
|
||||
<div class="login_table" align="center">
|
||||
<div class="login_table center">
|
||||
|
||||
<!-- <tr><td colspan="2" valign="middle"> -->
|
||||
<div id="login_line1" align="center">
|
||||
<div id="login_line1" class="center">
|
||||
|
||||
<div id="login_left" style="display: inline-block; min-width: 250px; margin: 0 auto;"><div class="center">
|
||||
|
||||
<table class="none" summary="Login pass" cellpadding="2" align="center">
|
||||
<table class="none center" summary="Login pass" cellpadding="2">
|
||||
|
||||
<!-- Login -->
|
||||
<tr>
|
||||
@ -50,7 +50,7 @@
|
||||
</div> <!-- end div left -->
|
||||
|
||||
<!-- </td>
|
||||
<td align="center" valign="middle">-->
|
||||
<td class="center" valign="middle">-->
|
||||
<div id="login_right" style="display: inline-block; min-width: 250px; margin: 0 auto;">
|
||||
|
||||
<img alt="Logo" title="" src="/dolibarrnew/theme/dolibarr_logo.png" id="img_logo" />
|
||||
|
||||
@ -247,7 +247,7 @@ if ($resql)
|
||||
print '<input type="hidden" name="page" value="'.$page.'">';
|
||||
print '<input type="hidden" name="contextpage" value="'.$contextpage.'">';
|
||||
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle">' . $langs->trans("Addanaccount").'</span>';
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle text-plus-circle">' . $langs->trans("Addanaccount").'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
|
||||
@ -258,7 +258,7 @@ if ($resql)
|
||||
print '<select class="flat" name="chartofaccounts" id="chartofaccounts">';
|
||||
$sql = "SELECT a.rowid, a.pcg_version, a.label, a.active, c.code as country_code";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "accounting_system as a";
|
||||
$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "c_country as c ON a.fk_country = c.rowid";
|
||||
$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "c_country as c ON a.fk_country = c.rowid AND c.active = 1";
|
||||
$sql .= " WHERE a.active = 1";
|
||||
dol_syslog('accountancy/admin/account.php $sql='.$sql);
|
||||
print $sql;
|
||||
|
||||
@ -60,7 +60,7 @@ $accountingcategory = new AccountancyCategory($db);
|
||||
|
||||
// si ajout de comptes
|
||||
if (! empty($selectcpt)) {
|
||||
$cpts = array ();
|
||||
$cpts = array();
|
||||
foreach ($selectcpt as $selectedoption) {
|
||||
if (! array_key_exists($selectedoption, $cpts))
|
||||
$cpts[$selectedoption] = "'" . $selectedoption . "'";
|
||||
@ -71,13 +71,13 @@ if (! empty($selectcpt)) {
|
||||
if ($return<0) {
|
||||
setEventMessages($langs->trans('errors'), $accountingcategory->errors, 'errors');
|
||||
} else {
|
||||
setEventMessages($langs->trans('SetupSaved'), null, 'mesgs');
|
||||
setEventMessages($langs->trans('RecordModifiedSuccessfully'), null, 'mesgs');
|
||||
}
|
||||
}
|
||||
if ($action == 'delete') {
|
||||
if ($cpt_id) {
|
||||
if ($accountingcategory->deleteCptCat($cpt_id)) {
|
||||
setEventMessages($langs->trans('CategoryDeleted'), null, 'mesgs');
|
||||
setEventMessages($langs->trans('AccountRemovedFromGroup'), null, 'mesgs');
|
||||
} else {
|
||||
setEventMessages($langs->trans('errors'), null, 'errors');
|
||||
}
|
||||
@ -173,8 +173,9 @@ if ($action == 'display' || $action == 'delete') {
|
||||
print '<td>' . $cpt->label . '</td>';
|
||||
print '<td class="right">';
|
||||
print "<a href= '".$_SERVER['PHP_SELF']."?action=delete&account_category=" . $cat_id . "&cptid=" . $cpt->rowid."'>";
|
||||
print img_delete($langs->trans("DeleteFromCat")).' ';
|
||||
print $langs->trans("DeleteFromCat")."</a>";
|
||||
print $langs->trans("DeleteFromCat");
|
||||
print img_picto($langs->trans("DeleteFromCat"), 'unlink');
|
||||
print "</a>";
|
||||
print "</td>";
|
||||
print "</tr>\n";
|
||||
}
|
||||
|
||||
@ -113,11 +113,11 @@ if ($result)
|
||||
|
||||
if (! empty($user->rights->accounting->fiscalyear))
|
||||
{
|
||||
$addbutton = '<a class="butActionNew" href="fiscalyear_card.php?action=create"><span class="valignmiddle">' . $langs->trans("NewFiscalYear") .'</span><span class="fa fa-plus-circle valignmiddle"></span></a>';
|
||||
$addbutton = '<a class="butActionNew" href="fiscalyear_card.php?action=create"><span class="valignmiddle text-plus-circle">' . $langs->trans("NewFiscalYear") .'</span><span class="fa fa-plus-circle valignmiddle"></span></a>';
|
||||
}
|
||||
else
|
||||
{
|
||||
$addbutton = '<a class="butActionRefused classfortooltip" href="#"><span class="valignmiddle" title="'.dol_escape_htmltag($langs->trans("NotAllowed")).'">' . $langs->trans("NewFiscalYear") .'</span><span class="fa fa-plus-circle valignmiddle"></span></a>';
|
||||
$addbutton = '<a class="butActionRefused classfortooltip" href="#" title="'.dol_escape_htmltag($langs->trans("NotAllowed")).'"><span class="valignmiddle text-plus-circle">' . $langs->trans("NewFiscalYear") .'</span><span class="fa fa-plus-circle valignmiddle"></span></a>';
|
||||
}
|
||||
|
||||
$title = $langs->trans('AccountingPeriods');
|
||||
@ -154,7 +154,7 @@ if ($result)
|
||||
$i++;
|
||||
}
|
||||
} else {
|
||||
print '<tr class="oddeven"><td colspan="5" class="opacitymedium">' . $langs->trans("None") . '</td></tr>';
|
||||
print '<tr class="oddeven"><td colspan="7" class="opacitymedium">' . $langs->trans("None") . '</td></tr>';
|
||||
}
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
@ -1,187 +0,0 @@
|
||||
<?php
|
||||
/* Copyright (C) 2013-2014 Olivier Geffroy <jeff@jeffinfo.com>
|
||||
* Copyright (C) 2013-2017 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/accountancy/admin/importaccounts.php
|
||||
* \ingroup Advanced accountancy
|
||||
* \brief Page import accounting account
|
||||
*/
|
||||
require '../../main.inc.php';
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT . '/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountingaccount.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/core/class/html.formaccounting.class.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("compta","bills","accountancy"));
|
||||
|
||||
// Security check
|
||||
if (! $user->admin)
|
||||
accessforbidden();
|
||||
|
||||
$limit = GETPOST('limit', 'int')?GETPOST('limit', 'int'):(empty($conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION)?$conf->liste_limit:$conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION);
|
||||
$sortfield = GETPOST("sortfield", 'alpha');
|
||||
$sortorder = GETPOST("sortorder", 'alpha');
|
||||
$page = GETPOST("page", 'int');
|
||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
||||
$offset = $limit * $page;
|
||||
$pageprev = $page - 1;
|
||||
$pagenext = $page + 1;
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
llxHeader('', $langs->trans("ImportAccount"));
|
||||
|
||||
$to_import = GETPOST("mesCasesCochees");
|
||||
|
||||
if ($_POST["action"] == 'import') {
|
||||
print '<div><font color="red">' . $langs->trans("Processing") . '...</font></div>';
|
||||
if (is_array($to_import) && count($to_import) > 0) {
|
||||
print '<div><font color="red">' . count($to_import) . ' ' . $langs->trans("SelectedLines") . '</font></div>';
|
||||
$sql = 'SELECT pcg_version FROM ' . MAIN_DB_PREFIX . 'accounting_system WHERE rowid=' . $conf->global->CHARTOFACCOUNTS;
|
||||
|
||||
$result = $db->query($sql);
|
||||
if ($result && ($db->num_rows($result) > 0)) {
|
||||
|
||||
$obj = $db->fetch_object($result);
|
||||
|
||||
$cpt = 0;
|
||||
foreach ($to_import as $maLigneCochee) {
|
||||
|
||||
$accounting = new AccountingAccount($db);
|
||||
|
||||
$monLabel = (string) GETPOST('label' . $maLigneCochee);
|
||||
$monParentAccount = (string) GETPOST('AccountParent' . $maLigneCochee);
|
||||
$monType = (string) GETPOST('pcgType' . $maLigneCochee);
|
||||
$monSubType = (string) GETPOST('pcgSubType' . $maLigneCochee);
|
||||
|
||||
$accounting->fk_pcg_version = $obj->pcg_version;
|
||||
$accounting->account_number = $maLigneCochee;
|
||||
$accounting->label = $monLabel;
|
||||
$accounting->account_parent = $monParentAccount;
|
||||
$accounting->pcg_type = $monType;
|
||||
$accounting->pcg_subtype = $monSubType;
|
||||
$accounting->active = 1;
|
||||
|
||||
$result = $accounting->create($user);
|
||||
if ($result > 0) {
|
||||
setEventMessages($langs->trans("AccountingAccountAdd"), null, 'mesgs');
|
||||
} else {
|
||||
setEventMessages($accounting->error, $accounting->errors, 'errors');
|
||||
}
|
||||
$cpt ++;
|
||||
}
|
||||
} else {
|
||||
setEventMessages($langs->trans('AccountPlanNotFoundCheckSetting'), null, 'errors');
|
||||
}
|
||||
} else {
|
||||
print '<div><font color="red">' . $langs->trans("AnyLineImport") . '</font></div>';
|
||||
}
|
||||
print '<div><font color="red">' . $langs->trans("EndProcessing") . '</font></div>';
|
||||
}
|
||||
|
||||
// list accounting account from product
|
||||
|
||||
$sql = "(SELECT p.rowid as product_id, p.accountancy_code_sell as accounting ";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "product as p ";
|
||||
$sql .= " WHERE p.accountancy_code_sell >=0";
|
||||
$sql .= " GROUP BY accounting ";
|
||||
$sql .= ")";
|
||||
$sql .= "UNION ALL(SELECT p.rowid as product_id, p.accountancy_code_buy as accounting ";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "product as p ";
|
||||
$sql .= " WHERE p.accountancy_code_buy >=0";
|
||||
$sql .= " GROUP BY accounting ";
|
||||
$sql .= ") ";
|
||||
$sql .= " ORDER BY accounting DESC " . $db->plimit($limit + 1, $offset);
|
||||
|
||||
dol_syslog('accountancy/admin/importaccounts.php:: $sql=' . $sql);
|
||||
$result = $db->query($sql);
|
||||
if ($result) {
|
||||
$num_lines = $db->num_rows($result);
|
||||
$i = 0;
|
||||
print_barre_liste($langs->trans("ImportAccount"), $page, $_SERVER["PHP_SELF"], "", $sortfield, $sortorder, '', $num_lines);
|
||||
|
||||
print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">' . "\n";
|
||||
print '<input type="hidden" name="action" value="import">';
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td>' . $langs->trans("AccountAccouting") . '</td>';
|
||||
print '<td>' . $langs->trans("label") . '</td>';
|
||||
print '<td>' . $langs->trans("Accountparent") . '</td>';
|
||||
print '<td>' . $langs->trans("Pcgtype") . '</td>';
|
||||
print '<td>' . $langs->trans("Pcgsubtype") . '</td>';
|
||||
print '<td class="center">' . $langs->trans("Import") . '</td>';
|
||||
print '</tr>';
|
||||
|
||||
$form = new Form($db);
|
||||
$formaccounting = new FormAccounting($db);
|
||||
|
||||
while ( $i < min($num_lines, $limit) ) {
|
||||
$objp = $db->fetch_object($result);
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
print '<td class="left">';
|
||||
print $objp->accounting;
|
||||
print '</td>';
|
||||
|
||||
print '<td class="left">';
|
||||
print '<input name="label" size="30" value="">';
|
||||
print '</td>';
|
||||
|
||||
// Colonne choix du compte
|
||||
print '<td>';
|
||||
print $formaccounting->select_account($accounting->account_parent, 'AccountParent');
|
||||
print '</td>';
|
||||
|
||||
print '<td>';
|
||||
print '<input type="text" name="pcgType" value="'.dol_escape_htmltag(isset($_POST['pcg_subtype'])?GETPOST('pcg_subtype', 'alpha'):$accounting->pcg_type).'">';
|
||||
print '</td>';
|
||||
|
||||
print '<td>';
|
||||
print '<input type="text" name="pcgSubType" value="'.dol_escape_htmltag(isset($_POST['pcg_subtype'])?GETPOST('pcg_subtype', 'alpha'):$accounting->pcg_subtype).'">';
|
||||
print '</td>';
|
||||
|
||||
// Colonne choix ligne a ventiler
|
||||
$checked = ('label' == 'O') ? ' checked' : '';
|
||||
|
||||
print '<td class="center">';
|
||||
print '<input type="checkbox" name="mesCasesCochees[]" ' . $checked . ' value="' . $objp->accounting . '"/>';
|
||||
print '</td>';
|
||||
|
||||
print '</tr>';
|
||||
$i ++;
|
||||
}
|
||||
|
||||
print '<tr><td colspan="8"> </td></tr><tr><td colspan="8" class="center"><input type="submit" class="butAction" value="' . $langs->trans("Import") . '"></td></tr>';
|
||||
|
||||
print '</table>';
|
||||
print '</form>';
|
||||
} else {
|
||||
print $db->error();
|
||||
}
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
@ -523,7 +523,7 @@ if ($id)
|
||||
print '<td class="liste_titre"></td>';
|
||||
print '<td class="liste_titre"></td>';
|
||||
print '<td class="liste_titre"></td>';
|
||||
print '<td class="liste_titre" align="center">';
|
||||
print '<td class="liste_titre center">';
|
||||
if ($filterfound)
|
||||
{
|
||||
$searchpicto=$form->showFilterAndCheckAddButtons(0);
|
||||
@ -590,7 +590,7 @@ if ($id)
|
||||
// Show fields
|
||||
if (empty($reshook)) fieldListJournal($fieldlist, $obj, $tabname[$id], 'edit');
|
||||
|
||||
print '<td align="center" colspan="4">';
|
||||
print '<td class="center" colspan="4">';
|
||||
print '<input type="hidden" name="page" value="'.$page.'">';
|
||||
print '<input type="hidden" name="rowid" value="'.$rowid.'">';
|
||||
print '<input type="submit" class="button" name="actionmodify" value="'.$langs->trans("Modify").'">';
|
||||
@ -654,19 +654,19 @@ if ($id)
|
||||
$url.='&';
|
||||
|
||||
// Active
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
if ($canbedisabled) print '<a href="'.$url.'action='.$acts[$obj->active].'">'.$actl[$obj->active].'</a>';
|
||||
else print $langs->trans("AlwaysActive");
|
||||
print "</td>";
|
||||
|
||||
// Modify link
|
||||
if ($canbemodified) print '<td align="center"><a class="reposition" href="'.$url.'action=edit">'.img_edit().'</a></td>';
|
||||
if ($canbemodified) print '<td class="center"><a class="reposition" href="'.$url.'action=edit">'.img_edit().'</a></td>';
|
||||
else print '<td> </td>';
|
||||
|
||||
// Delete link
|
||||
if ($iserasable)
|
||||
{
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($user->admin) print '<a href="'.$url.'action=delete">'.img_delete().'</a>';
|
||||
//else print '<a href="#">'.img_delete().'</a>'; // Some dictionary can be edited by other profile than admin
|
||||
print '</td>';
|
||||
|
||||
@ -65,6 +65,8 @@ $accounting_product_mode = GETPOST('accounting_product_mode', 'alpha');
|
||||
$btn_changeaccount = GETPOST('changeaccount', 'alpha');
|
||||
$btn_changetype = GETPOST('changetype', 'alpha');
|
||||
|
||||
if (empty($accounting_product_mode)) $accounting_product_mode='ACCOUNTANCY_SELL';
|
||||
|
||||
$limit = GETPOST('limit', 'int')?GETPOST('limit', 'int'):(empty($conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION)?$conf->liste_limit:$conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION);
|
||||
$sortfield = GETPOST("sortfield", 'alpha');
|
||||
$sortorder = GETPOST("sortorder", 'alpha');
|
||||
@ -112,8 +114,6 @@ if ($action == 'update') {
|
||||
'ACCOUNTANCY_BUY'
|
||||
);
|
||||
|
||||
$accounting_product_mode = GETPOST('accounting_product_mode', 'alpha');
|
||||
|
||||
if (in_array($accounting_product_mode, $accounting_product_modes)) {
|
||||
|
||||
if (! dolibarr_set_const($db, 'ACCOUNTING_PRODUCT_MODE', $accounting_product_mode, 'chaine', 0, '', $conf->entity)) {
|
||||
@ -279,7 +279,8 @@ if ($result)
|
||||
if ($search_desc > 0) $param.="&search_desc=".urlencode($search_desc);
|
||||
if ($search_current_account > 0) $param.="&search_current_account=".urlencode($search_current_account);
|
||||
if ($search_current_account_valid && $search_current_account_valid != '-1') $param.="&search_current_account_valid=".urlencode($search_current_account_valid);
|
||||
|
||||
if ($accounting_product_mode) $param.='&accounting_product_mode='.urlencode($accounting_product_mode);
|
||||
|
||||
print '<form action="' . $_SERVER["PHP_SELF"] . '" method="post">';
|
||||
if ($optioncss != '') print '<input type="hidden" name="optioncss" value="'.$optioncss.'">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
@ -317,8 +318,11 @@ if ($result)
|
||||
$varpage=empty($contextpage)?$_SERVER["PHP_SELF"]:$contextpage;
|
||||
$selectedfields=$form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields
|
||||
|
||||
$buttonsave = '<input type="submit" class="button" id="changeaccount" name="changeaccount" value="' . $langs->trans("Save") . '">';
|
||||
//print '<br><div class="center">'.$buttonsave.'</div>';
|
||||
|
||||
$texte=$langs->trans("ListOfProductsServices");
|
||||
print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, '', 0, '', '', $limit);
|
||||
print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $buttonsave, $num, $nbtotalofrecords, '', 0, '', '', $limit);
|
||||
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="liste '.($moreforfilter?"listwithfilterbefore":"").'">';
|
||||
@ -333,7 +337,7 @@ if ($result)
|
||||
if ($accounting_product_mode == 'ACCOUNTANCY_BUY') print '<td class="liste_titre"></td>';
|
||||
// Current account
|
||||
print '<td class="liste_titre">';
|
||||
print '<input type="text" class="flat" size="6" name="search_current_account" value="' . dol_escape_htmltag($search_current_account) . '">';
|
||||
print '<input type="text" class="flat" size="6" name="search_current_account" id="search_current_account" value="' . dol_escape_htmltag($search_current_account) . '">';
|
||||
$listofvals=array('withoutvalidaccount'=>$langs->trans("WithoutValidAccount"), 'withvalidaccount'=>$langs->trans("WithValidAccount"));
|
||||
print ' '.$langs->trans("or").' '.$form->selectarray('search_current_account_valid', $listofvals, $search_current_account_valid, 1);
|
||||
print '</td>';
|
||||
@ -473,20 +477,25 @@ if ($result)
|
||||
|
||||
if (atleastoneselected) jQuery("#changeaccount").removeAttr(\'disabled\');
|
||||
else jQuery("#changeaccount").attr(\'disabled\',\'disabled\');
|
||||
if (atleastoneselected) jQuery("#changeaccount").attr(\'class\',\'butAction\');
|
||||
else jQuery("#changeaccount").attr(\'class\',\'butActionRefused\');
|
||||
if (atleastoneselected) jQuery("#changeaccount").attr(\'class\',\'button\');
|
||||
else jQuery("#changeaccount").attr(\'class\',\'button\');
|
||||
}
|
||||
jQuery(".checkforselect, #checkallactions").click(function() {
|
||||
init_savebutton();
|
||||
});
|
||||
|
||||
init_savebutton();
|
||||
|
||||
jQuery("#search_current_account").keyup(function() {
|
||||
if (jQuery("#search_current_account").val() != \'\')
|
||||
{
|
||||
console.log("We set a value of account to search "+jQuery("#search_current_account").val()+", so we disable the other search criteria on account");
|
||||
jQuery("#search_current_account_valid").val(-1);
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>';
|
||||
|
||||
|
||||
print '<br><div class="center"><input type="submit" class="butAction" id="changeaccount" name="changeaccount" value="' . $langs->trans("Save") . '"></div>';
|
||||
|
||||
print '</form>';
|
||||
|
||||
$db->free($result);
|
||||
|
||||
@ -171,8 +171,8 @@ elseif ($action == "add") {
|
||||
$object->doc_ref = GETPOST('doc_ref', 'alpha');
|
||||
$object->code_journal = $journal_code;
|
||||
$object->journal_label = $journal_label;
|
||||
$object->fk_doc = GETPOST('fk_doc', 'int');
|
||||
$object->fk_docdet = GETPOST('fk_docdet', 'int');
|
||||
$object->fk_doc = (int) GETPOST('fk_doc', 'int');
|
||||
$object->fk_docdet = (int) GETPOST('fk_docdet', 'int');
|
||||
|
||||
if (floatval($debit) != 0.0) {
|
||||
$object->montant = $debit;
|
||||
@ -661,8 +661,8 @@ if ($action == 'create')
|
||||
print "</tr>\n";
|
||||
}
|
||||
|
||||
$total_debit = price2num($total_debit);
|
||||
$total_credit = price2num($total_credit);
|
||||
$total_debit = price2num($total_debit, 'MT');
|
||||
$total_credit = price2num($total_credit, 'MT');
|
||||
|
||||
if ($total_debit != $total_credit)
|
||||
{
|
||||
|
||||
@ -451,7 +451,7 @@ $button.= '</a>';
|
||||
|
||||
|
||||
$groupby = ' <a class="nohover marginrightonly" href="'.DOL_URL_ROOT.'/accountancy/bookkeeping/listbyaccount.php?'.$param.'">' . $langs->trans("GroupByAccountAccounting") . '</a>';
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle">' . $langs->trans("NewAccountingMvt").'</span>';
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle text-plus-circle">'.$langs->trans("NewAccountingMvt").'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
|
||||
@ -648,7 +648,7 @@ if ($num > 0)
|
||||
// Document date
|
||||
if (! empty($arrayfields['t.doc_date']['checked']))
|
||||
{
|
||||
print '<td align="center">' . dol_print_date($line->doc_date, 'day') . '</td>';
|
||||
print '<td class="center">' . dol_print_date($line->doc_date, 'day') . '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
@ -701,7 +701,7 @@ if ($num > 0)
|
||||
// Lettering code
|
||||
if (! empty($arrayfields['t.lettering_code']['checked']))
|
||||
{
|
||||
print '<td align="center">' . $line->lettering_code . '</td>';
|
||||
print '<td class="center">' . $line->lettering_code . '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
@ -711,26 +711,26 @@ if ($num > 0)
|
||||
$accountingjournal = new AccountingJournal($db);
|
||||
$result = $accountingjournal->fetch('', $line->code_journal);
|
||||
$journaltoshow = (($result > 0)?$accountingjournal->getNomUrl(0, 0, 0, '', 0) : $line->code_journal);
|
||||
print '<td align="center">' . $journaltoshow . '</td>';
|
||||
print '<td class="center">' . $journaltoshow . '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
// Creation operation date
|
||||
if (! empty($arrayfields['t.date_creation']['checked']))
|
||||
{
|
||||
print '<td align="center">' . dol_print_date($line->date_creation, 'dayhour') . '</td>';
|
||||
print '<td class="center">' . dol_print_date($line->date_creation, 'dayhour') . '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
// Modification operation date
|
||||
if (! empty($arrayfields['t.tms']['checked']))
|
||||
{
|
||||
print '<td align="center">' . dol_print_date($line->date_modification, 'dayhour') . '</td>';
|
||||
print '<td class="center">' . dol_print_date($line->date_modification, 'dayhour') . '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
// Action column
|
||||
print '<td align="center" class="nowraponall">';
|
||||
print '<td class="nowraponall center">';
|
||||
print '<a href="'.DOL_URL_ROOT.'/accountancy/bookkeeping/card.php?piece_num=' . $line->piece_num . $param . '&page=' . $page . ($sortfield ? '&sortfield='.$sortfield : '') . ($sortorder ? '&sortorder='.$sortorder : '') . '">' . img_edit() . '</a> ';
|
||||
print '<a href="' . $_SERVER['PHP_SELF'] . '?action=delmouv&mvt_num=' . $line->piece_num . $param . '&page=' . $page . ($sortfield ? '&sortfield='.$sortfield : '') . ($sortorder ? '&sortorder='.$sortorder : '') . '">' . img_delete() . '</a>';
|
||||
print '</td>';
|
||||
|
||||
@ -257,7 +257,7 @@ if ($action == 'delbookkeepingyear') {
|
||||
print '<form method="POST" id="searchFormList" action="' . $_SERVER["PHP_SELF"] . '">';
|
||||
|
||||
$viewflat = ' <a class="nohover marginrightonly" href="'.DOL_URL_ROOT.'/accountancy/bookkeeping/list.php?'.$param.'">' . $langs->trans("ViewFlatList") . '</a>';
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle">' . $langs->trans("NewAccountingMvt").'</span>';
|
||||
$newcardbutton = '<a class="butActionNew" href="./card.php?action=create"><span class="valignmiddle text-plus-circle">'.$langs->trans("NewAccountingMvt").'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
|
||||
|
||||
@ -150,6 +150,7 @@ if (dol_strlen($search_year)) {
|
||||
$sql .= " AND ( bk.doc_date BETWEEN '" . $db->idate($date_start) . "' AND '" . $db->idate($date_end) . "' )";
|
||||
}
|
||||
|
||||
$sql.= ' AND bk.entity IN ('.getEntity('accountingbookkeeping').')';
|
||||
$sql .= $db->order($sortfield, $sortorder);
|
||||
|
||||
$debit = 0;
|
||||
|
||||
@ -142,13 +142,12 @@ $sql .= " bk.subledger_account, bk.numero_compte , bk.label_compte, bk.debit, ";
|
||||
$sql .= " bk.credit, bk.montant , bk.sens , bk.code_journal , bk.piece_num, bk.lettering_code ";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "accounting_bookkeeping as bk";
|
||||
$sql .= " WHERE (bk.subledger_account = '" . $object->code_compta_fournisseur . "' AND bk.numero_compte = '" . $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER . "' )";
|
||||
|
||||
if (dol_strlen($search_year)) {
|
||||
$date_start = dol_mktime(0, 0, 0, 1, 1, $search_year);
|
||||
$date_end = dol_mktime(23, 59, 59, 12, 31, $search_year);
|
||||
$sql .= " AND ( bk.doc_date BETWEEN '".$db->idate($date_start)."' AND '".$db->idate($date_end)."' )";
|
||||
}
|
||||
|
||||
$sql.= ' AND bk.entity IN ('.getEntity('accountingbookkeeping').')';
|
||||
$sql.= $db->order($sortfield, $sortorder);
|
||||
|
||||
$debit = 0;
|
||||
|
||||
@ -38,7 +38,7 @@ class AccountancyCategory // extends CommonObject
|
||||
|
||||
/**
|
||||
* @var string Error string
|
||||
* @see errors
|
||||
* @see $errors
|
||||
*/
|
||||
public $error;
|
||||
|
||||
@ -63,7 +63,7 @@ class AccountancyCategory // extends CommonObject
|
||||
public $id;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var string Accountancy code
|
||||
*/
|
||||
public $code;
|
||||
|
||||
@ -73,7 +73,7 @@ class AccountancyCategory // extends CommonObject
|
||||
public $label;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var string Accountancy range account
|
||||
*/
|
||||
public $range_account;
|
||||
|
||||
@ -83,37 +83,37 @@ class AccountancyCategory // extends CommonObject
|
||||
public $sens;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var int Category type of accountancy
|
||||
*/
|
||||
public $category_type;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var string Formula
|
||||
*/
|
||||
public $formula;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var int Position
|
||||
*/
|
||||
public $position;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var int country id
|
||||
*/
|
||||
public $fk_country;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var int Is active
|
||||
*/
|
||||
public $active;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var array Lines cptbk
|
||||
*/
|
||||
public $lines_cptbk;
|
||||
|
||||
/**
|
||||
* @var mixed Sample property 1
|
||||
* @var array Lines display
|
||||
*/
|
||||
public $lines_display;
|
||||
|
||||
@ -151,12 +151,12 @@ class AccountancyCategory // extends CommonObject
|
||||
if (isset($this->code)) $this->code=trim($this->code);
|
||||
if (isset($this->label)) $this->label=trim($this->label);
|
||||
if (isset($this->range_account)) $this->range_account=trim($this->range_account);
|
||||
if (isset($this->sens)) $this->sens=trim($this->sens);
|
||||
if (isset($this->category_type)) $this->category_type=trim($this->category_type);
|
||||
if (isset($this->sens)) $this->sens = (int) $this->sens;
|
||||
if (isset($this->category_type)) $this->category_type = (int) $this->category_type;
|
||||
if (isset($this->formula)) $this->formula=trim($this->formula);
|
||||
if (isset($this->position)) $this->position=trim($this->position);
|
||||
if (isset($this->fk_country)) $this->fk_country=trim($this->fk_country);
|
||||
if (isset($this->active)) $this->active=trim($this->active);
|
||||
if (isset($this->position)) $this->position = (int) $this->position;
|
||||
if (isset($this->fk_country)) $this->fk_country = (int) $this->fk_country;
|
||||
if (isset($this->active)) $this->active = (int) $this->active;
|
||||
|
||||
// Check parameters
|
||||
// Put here code to add control on parameters values
|
||||
@ -308,12 +308,12 @@ class AccountancyCategory // extends CommonObject
|
||||
if (isset($this->code)) $this->code=trim($this->code);
|
||||
if (isset($this->label)) $this->label=trim($this->label);
|
||||
if (isset($this->range_account)) $this->range_account=trim($this->range_account);
|
||||
if (isset($this->sens)) $this->sens=trim($this->sens);
|
||||
if (isset($this->category_type)) $this->category_type=trim($this->category_type);
|
||||
if (isset($this->sens)) $this->sens = (int) $this->sens;
|
||||
if (isset($this->category_type)) $this->category_type = (int) $this->category_type;
|
||||
if (isset($this->formula)) $this->formula=trim($this->formula);
|
||||
if (isset($this->position)) $this->position=trim($this->position);
|
||||
if (isset($this->fk_country)) $this->fk_country=trim($this->fk_country);
|
||||
if (isset($this->active)) $this->active=trim($this->active);
|
||||
if (isset($this->position)) $this->position = (int) $this->position;
|
||||
if (isset($this->fk_country)) $this->fk_country = (int) $this->fk_country;
|
||||
if (isset($this->active)) $this->active = (int) $this->active;
|
||||
|
||||
|
||||
// Check parameters
|
||||
@ -338,8 +338,8 @@ class AccountancyCategory // extends CommonObject
|
||||
$resql = $this->db->query($sql);
|
||||
if (! $resql) { $error++; $this->errors[]="Error ".$this->db->lasterror(); }
|
||||
|
||||
if (! $error)
|
||||
{
|
||||
//if (! $error)
|
||||
//{
|
||||
// Uncomment this and change MYOBJECT to your own tag if you
|
||||
// want this action call a trigger.
|
||||
//if (! $notrigger)
|
||||
@ -351,7 +351,7 @@ class AccountancyCategory // extends CommonObject
|
||||
// if ($result < 0) { $error++; $this->errors=$interface->errors; }
|
||||
// // End call triggers
|
||||
//}
|
||||
}
|
||||
//}
|
||||
|
||||
// Commit or rollback
|
||||
if ($error)
|
||||
@ -393,8 +393,8 @@ class AccountancyCategory // extends CommonObject
|
||||
$resql = $this->db->query($sql);
|
||||
if (! $resql) { $error++; $this->errors[]="Error ".$this->db->lasterror(); }
|
||||
|
||||
if (! $error)
|
||||
{
|
||||
//if (! $error)
|
||||
//{
|
||||
// Uncomment this and change MYOBJECT to your own tag if you
|
||||
// want this action call a trigger.
|
||||
//if (! $notrigger)
|
||||
@ -406,7 +406,7 @@ class AccountancyCategory // extends CommonObject
|
||||
// if ($result < 0) { $error++; $this->errors=$interface->errors; }
|
||||
// // End call triggers
|
||||
//}
|
||||
}
|
||||
//}
|
||||
|
||||
// Commit or rollback
|
||||
if ($error)
|
||||
@ -514,7 +514,7 @@ class AccountancyCategory // extends CommonObject
|
||||
/**
|
||||
* Function to select accounting category of an accounting account present in chart of accounts
|
||||
*
|
||||
* @param int $id Id category
|
||||
* @param int $id Id of category to know which account to exclude
|
||||
*
|
||||
* @return int <0 if KO, 0 if not found, >0 if OK
|
||||
*/
|
||||
@ -569,12 +569,13 @@ class AccountancyCategory // extends CommonObject
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
|
||||
$sql = "SELECT aa.rowid,aa.account_number ";
|
||||
$sql = "SELECT aa.rowid, aa.account_number";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "accounting_account as aa";
|
||||
$sql .= " INNER JOIN " . MAIN_DB_PREFIX . "accounting_system as asy ON aa.fk_pcg_version = asy.pcg_version";
|
||||
$sql .= " AND asy.rowid = " . $conf->global->CHARTOFACCOUNTS;
|
||||
$sql .= " AND aa.active = 1";
|
||||
$sql .= " AND aa.entity = " . $conf->entity;
|
||||
$sql .= " ORDER BY LENGTH(aa.account_number) DESC;"; // LENGTH is ok with mysql and postgresql
|
||||
|
||||
$this->db->begin();
|
||||
|
||||
@ -587,10 +588,16 @@ class AccountancyCategory // extends CommonObject
|
||||
return -1;
|
||||
}
|
||||
|
||||
while ( $obj = $this->db->fetch_object($resql))
|
||||
$accountincptsadded=array();
|
||||
while ($obj = $this->db->fetch_object($resql))
|
||||
{
|
||||
if (array_key_exists(length_accountg($obj->account_number), $cpts))
|
||||
$account_number_formated=length_accountg($obj->account_number);
|
||||
if (! empty($accountincptsadded[$account_number_formated])) continue;
|
||||
|
||||
if (array_key_exists($account_number_formated, $cpts))
|
||||
{
|
||||
$accountincptsadded[$account_number_formated]=1;
|
||||
// We found an account number that is in list $cpts of account to add
|
||||
$sql = "UPDATE " . MAIN_DB_PREFIX . "accounting_account";
|
||||
$sql .= " SET fk_accounting_category=" . $id_cat;
|
||||
$sql .= " WHERE rowid=".$obj->rowid;
|
||||
|
||||
@ -31,20 +31,15 @@
|
||||
* \brief Class accountancy export
|
||||
*/
|
||||
|
||||
/**
|
||||
* Class AccountancyExport
|
||||
*
|
||||
* Manage the different format accountancy export
|
||||
*/
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT . '/core/lib/functions.lib.php';
|
||||
|
||||
/**
|
||||
* Manage the different format accountancy export
|
||||
*/
|
||||
class AccountancyExport
|
||||
{
|
||||
/**
|
||||
* @var Type of export. Defined by $conf->global->ACCOUNTING_EXPORT_MODELCSV
|
||||
*/
|
||||
public static $EXPORT_TYPE_NORMAL = 1; // CSV
|
||||
// Type of export. Used into $conf->global->ACCOUNTING_EXPORT_MODELCSV
|
||||
public static $EXPORT_TYPE_NORMAL = 1; // CSV
|
||||
public static $EXPORT_TYPE_CONFIGURABLE = 10; // CSV
|
||||
public static $EXPORT_TYPE_CEGID = 2;
|
||||
public static $EXPORT_TYPE_COALA = 3;
|
||||
@ -535,14 +530,18 @@ class AccountancyExport
|
||||
print $line->id . $separator;
|
||||
print $date . $separator;
|
||||
print $line->code_journal . $separator;
|
||||
print length_accountg($line->numero_compte) . $separator;
|
||||
print substr(length_accountg($line->numero_compte), 0, 2) . $separator;
|
||||
if (empty($line->subledger_account)) {
|
||||
print $line->numero_compte . $separator;
|
||||
} else {
|
||||
print $line->subledger_account . $separator;
|
||||
}
|
||||
//print substr(length_accountg($line->numero_compte), 0, 2) . $separator;
|
||||
print '"'.dol_trunc($line->label_operation, 40, 'right', 'UTF-8', 1).'"' . $separator;
|
||||
print '"'.dol_trunc($line->piece_num, 15, 'right', 'UTF-8', 1).'"'.$separator;
|
||||
print price2num($line->montant).$separator;
|
||||
print price2num(abs($line->montant)).$separator;
|
||||
print $line->sens.$separator;
|
||||
print $date . $separator;
|
||||
print 'EUR';
|
||||
//print 'EUR';
|
||||
print $end_line;
|
||||
}
|
||||
}
|
||||
|
||||
@ -142,12 +142,12 @@ class AccountancySystem
|
||||
$result = $this->rowid;
|
||||
} else {
|
||||
$result = - 2;
|
||||
$this->error = "AccountancySystem::Create Erreur $result";
|
||||
$this->error = "AccountancySystem::Create Error $result";
|
||||
dol_syslog($this->error, LOG_ERR);
|
||||
}
|
||||
} else {
|
||||
$result = - 1;
|
||||
$this->error = "AccountancySystem::Create Erreur $result";
|
||||
$this->error = "AccountancySystem::Create Error $result";
|
||||
dol_syslog($this->error, LOG_ERR);
|
||||
}
|
||||
|
||||
|
||||
@ -74,9 +74,11 @@ class AccountingAccount extends CommonObject
|
||||
public $rowid;
|
||||
|
||||
/**
|
||||
* @var string Creation date
|
||||
* Date creation record (datec)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datec;
|
||||
public $datec;
|
||||
|
||||
/**
|
||||
* @var string pcg version
|
||||
@ -231,16 +233,8 @@ class AccountingAccount extends CommonObject
|
||||
$this->pcg_subtype = trim($this->pcg_subtype);
|
||||
if (isset($this->account_number))
|
||||
$this->account_number = trim($this->account_number);
|
||||
if (isset($this->account_parent))
|
||||
$this->account_parent = trim($this->account_parent);
|
||||
if (isset($this->label))
|
||||
$this->label = trim($this->label);
|
||||
if (isset($this->account_category))
|
||||
$this->account_category = trim($this->account_category);
|
||||
if (isset($this->fk_user_author))
|
||||
$this->fk_user_author = trim($this->fk_user_author);
|
||||
if (isset($this->active))
|
||||
$this->active = trim($this->active);
|
||||
|
||||
if (empty($this->pcg_type) || $this->pcg_type == '-1')
|
||||
{
|
||||
|
||||
@ -341,7 +341,7 @@ if ($result) {
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
//if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('ventil', $arrayofmassactions, 1);
|
||||
|
||||
@ -421,6 +421,8 @@ if ($result) {
|
||||
$facture_static = new Facture($db);
|
||||
$product_static = new Product($db);
|
||||
|
||||
$isSellerInEEC = isInEEC($mysoc);
|
||||
|
||||
while ( $i < min($num_lines, $limit) ) {
|
||||
$objp = $db->fetch_object($result);
|
||||
|
||||
@ -440,7 +442,7 @@ if ($result) {
|
||||
$code_sell_p_notset = '';
|
||||
$objp->aarowid_suggest = $objp->aarowid;
|
||||
|
||||
$isinEEC = isInEEC($objp->country_code);
|
||||
$isBuyerInEEC = isInEEC($objp);
|
||||
|
||||
if ($objp->type_l == 1) {
|
||||
$objp->code_sell_l = (! empty($conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT) ? $conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT : '');
|
||||
@ -455,15 +457,17 @@ if ($result) {
|
||||
}
|
||||
if ($objp->code_sell_l == -1) $objp->code_sell_l='';
|
||||
|
||||
if ($objp->country_sell == '1') {
|
||||
if ($objp->country_code == $mysoc->country_code || empty($objp->country_code)) { // If buyer in same country than seller (if not defined, we assume it is same country)
|
||||
$objp->code_sell_p = $objp->code_sell;
|
||||
$objp->aarowid_suggest = $objp->aarowid;
|
||||
} elseif ($isinEEC === true) {
|
||||
$objp->code_sell_p = $objp->code_sell_intra;
|
||||
$objp->aarowid_suggest = $objp->aarowid_intra;
|
||||
} else {
|
||||
$objp->code_sell_p = $objp->code_sell_export;
|
||||
$objp->aarowid_suggest = $objp->aarowid_export;
|
||||
if ($isSellerInEEC && $isBuyerInEEC) { // European intravat sale
|
||||
$objp->code_sell_p = $objp->code_sell_intra;
|
||||
$objp->aarowid_suggest = $objp->aarowid_intra;
|
||||
} else { // Foreign sale
|
||||
$objp->code_sell_p = $objp->code_sell_export;
|
||||
$objp->aarowid_suggest = $objp->aarowid_export;
|
||||
}
|
||||
}
|
||||
|
||||
if (! empty($objp->code_sell)) {
|
||||
|
||||
@ -273,7 +273,7 @@ if ($result) {
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
//if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('ventil', $arrayofmassactions, 1);
|
||||
|
||||
|
||||
@ -64,13 +64,13 @@ if ($conf->accounting->enabled)
|
||||
|
||||
// STEPS
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescJournalSetup", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/journals_list.php?id=35">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("AccountingJournals").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescJournalSetup", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/journals_list.php?id=35">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("AccountingJournals").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescChartModel", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/accountmodel.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("Pcg_version").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescChartModel", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/accountmodel.php">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("Pcg_version").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescChart", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/account.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("Chartofaccounts").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescChart", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/account.php">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("Chartofaccounts").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
|
||||
print "<br>\n";
|
||||
@ -79,20 +79,20 @@ if ($conf->accounting->enabled)
|
||||
print "<br>\n";
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescDefault", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/defaultaccounts.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescDefault", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/defaultaccounts.php">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBank", $step, '<a href="'.DOL_URL_ROOT.'/compta/bank/list.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuBankAccounts").'</strong>'.'</a>')."\n";
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBank", $step, '<a href="'.DOL_URL_ROOT.'/compta/bank/list.php">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuBankAccounts").'</strong>'.'</a>')."\n";
|
||||
print "<br>\n";
|
||||
|
||||
$step++;
|
||||
$textlink = '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=10&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup").'-'.$langs->transnoentitiesnoconv("MenuVatAccounts").'</strong>'.'</a>';
|
||||
$textlink = '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=10&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuVatAccounts").'</strong>'.'</a>';
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescVat", $step, $textlink);
|
||||
print "<br>\n";
|
||||
if (! empty($conf->tax->enabled))
|
||||
{
|
||||
$textlink = '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=7&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup").'-'.$langs->transnoentitiesnoconv("MenuTaxAccounts").'</strong>'.'</a>';
|
||||
$textlink = '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=7&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuTaxAccounts").'</strong>'.'</a>';
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescContrib", $step, $textlink);
|
||||
print "<br>\n";
|
||||
@ -100,7 +100,7 @@ if ($conf->accounting->enabled)
|
||||
/*if (! empty($conf->salaries->enabled))
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescSal", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuFinancial").'-'.$langs->transnoentitiesnoconv("MenuAccountancy")."-".$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescSal", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuFinancial").'-'.$langs->transnoentitiesnoconv("MenuAccountancy").' - '.$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
// htdocs/admin/salaries.php
|
||||
print "<br>\n";
|
||||
print "<br>\n";
|
||||
@ -108,36 +108,37 @@ if ($conf->accounting->enabled)
|
||||
if (! empty($conf->expensereport->enabled)) // TODO Move this in the default account page because this is only one accounting account per purpose, not several.
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescExpenseReport", $step, '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=17&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuExpenseReportAccounts").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescExpenseReport", $step, '<a href="'.DOL_URL_ROOT.'/admin/dict.php?id=17&from=accountancy">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuExpenseReportAccounts").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
}
|
||||
/*
|
||||
if (! empty($conf->loan->enabled))
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescLoan", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuSpecialExpenses").'-'.$langs->transnoentitiesnoconv("Loans").'</strong> '.$langs->transnoentitiesnoconv("or").' <strong>'.$langs->transnoentitiesnoconv("MenuFinancial").'-'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescLoan", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuSpecialExpenses").' - '.$langs->transnoentitiesnoconv("Loans").'</strong> '.$langs->transnoentitiesnoconv("or").' <strong>'.$langs->transnoentitiesnoconv("MenuFinancial").'-'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print "<br>\n";
|
||||
}
|
||||
if (! empty($conf->don->enabled))
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescDonation", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescDonation", $step, '<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print "<br>\n";
|
||||
}
|
||||
if (! empty($conf->adherents->enabled))
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescSubscription", $step, '<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescSubscription", $step, '<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("MenuDefaultAccounts").'</strong>');
|
||||
print "<br>\n";
|
||||
}*/
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescProd", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/productaccount.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("ProductsBinding").'</strong>'.'</a>');
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescProd", $step, '<a href="'.DOL_URL_ROOT.'/accountancy/admin/productaccount.php">'.'<strong>'.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("ProductsBinding").'</strong>'.'</a>');
|
||||
print "<br>\n";
|
||||
|
||||
|
||||
print '<br>';
|
||||
|
||||
// Step A - E
|
||||
|
||||
print "<br>\n";
|
||||
print load_fiche_titre('<span class="fa fa-calendar"></span> '.$langs->trans("AccountancyAreaDescActionFreq"), '', '');
|
||||
@ -148,22 +149,22 @@ if ($conf->accounting->enabled)
|
||||
$langs->loadLangs(array('bills', 'trips'));
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("BillsCustomers"), '<a href="'.DOL_URL_ROOT.'/accountancy/customer/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy")."-".$langs->transnoentitiesnoconv("CustomersVentilation").'</strong>'.'</a>')."\n";
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("BillsCustomers"), '<a href="'.DOL_URL_ROOT.'/accountancy/customer/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("TransferInAccounting").' - '.$langs->transnoentitiesnoconv("CustomersVentilation").'</strong>'.'</a>')."\n";
|
||||
print "<br>\n";
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("BillsSuppliers"), '<a href="'.DOL_URL_ROOT.'/accountancy/supplier/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy")."-".$langs->transnoentitiesnoconv("SuppliersVentilation").'</strong>'.'</a>')."\n";
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("BillsSuppliers"), '<a href="'.DOL_URL_ROOT.'/accountancy/supplier/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("TransferInAccounting").' - '.$langs->transnoentitiesnoconv("SuppliersVentilation").'</strong>'.'</a>')."\n";
|
||||
print "<br>\n";
|
||||
|
||||
if (! empty($conf->expensereport->enabled) || ! empty($conf->deplacement->enabled))
|
||||
{
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("ExpenseReports"), '<a href="'.DOL_URL_ROOT.'/accountancy/expensereport/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("MenuAccountancy")."-".$langs->transnoentitiesnoconv("ExpenseReportsVentilation").'</strong>'.'</a>')."\n";
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescBind", chr(64+$step), $langs->transnoentitiesnoconv("ExpenseReports"), '<a href="'.DOL_URL_ROOT.'/accountancy/expensereport/index.php">'.'<strong>'.$langs->transnoentitiesnoconv("TransferInAccounting").' - '.$langs->transnoentitiesnoconv("ExpenseReportsVentilation").'</strong>'.'</a>')."\n";
|
||||
print "<br>\n";
|
||||
}
|
||||
|
||||
$step++;
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescWriteRecords", chr(64+$step), $langs->transnoentitiesnoconv("Journalization"), $langs->transnoentitiesnoconv("WriteBookKeeping"))."\n";
|
||||
print img_picto('', 'puce').' '.$langs->trans("AccountancyAreaDescWriteRecords", chr(64+$step), $langs->transnoentitiesnoconv("TransferInAccounting").' - '.$langs->transnoentitiesnoconv("RegistrationInAccounting"), $langs->transnoentitiesnoconv("WriteBookKeeping"))."\n";
|
||||
print "<br>\n";
|
||||
|
||||
$step++;
|
||||
|
||||
@ -340,7 +340,7 @@ if ($result) {
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
//if ($user->rights->mymodule->supprimer) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
//if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('ventil', $arrayofmassactions, 1);
|
||||
|
||||
|
||||
@ -161,7 +161,7 @@ $helptext.='__COMPANY__, __ADDRESS__, __ZIP__, __TOWN__, __COUNTRY__, __EMAIL__,
|
||||
|
||||
form_constantes($constantes, 0, $helptext);
|
||||
|
||||
//print '<div align="center"><input type="submit" class="button" value="'.$langs->trans("Update").'" name="update"></div>';
|
||||
//print '<div class="center"><input type="submit" class="button" value="'.$langs->trans("Update").'" name="update"></div>';
|
||||
//print '</form>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
@ -151,7 +151,7 @@ if ($object->id > 0)
|
||||
$newcardbutton = '';
|
||||
if (! empty($conf->agenda->enabled))
|
||||
{
|
||||
$newcardbutton.='<a class="butActionNew" href="'.DOL_URL_ROOT.'/comm/action/card.php?action=create&backtopage=1&origin=member&originid='.$id.'"><span class="valignmiddle">'.$langs->trans("AddAction").'</span>';
|
||||
$newcardbutton.='<a class="butActionNew" href="'.DOL_URL_ROOT.'/comm/action/card.php?action=create&backtopage=1&origin=member&originid='.$id.'"><span class="valignmiddle text-plus-circle">'.$langs->trans("AddAction").'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
}
|
||||
|
||||
@ -120,7 +120,7 @@ echo $this->control->tpl['ajax_selectcountry']; ?>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td align="center" colspan="4"><input type="submit" class="button" value="<?php echo $langs->trans("Add"); ?>"></td>
|
||||
<td class="center" colspan="4"><input type="submit" class="button" value="<?php echo $langs->trans("Add"); ?>"></td>
|
||||
</tr>
|
||||
|
||||
</table><br>
|
||||
|
||||
@ -134,7 +134,7 @@ echo $this->control->tpl['ajax_selectcountry'];
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="4" align="center">
|
||||
<td colspan="4" class="center">
|
||||
<input type="submit" class="button" name="save" value="<?php echo $langs->trans("Save"); ?>">
|
||||
<input type="submit" class="button" name="cancel" value="<?php echo $langs->trans("Cancel"); ?>">
|
||||
</td>
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2006-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -249,13 +249,14 @@ $form=new Form($db);
|
||||
llxHeader('', $langs->trans("MembersCards"));
|
||||
|
||||
print load_fiche_titre($langs->trans("LinkToGeneratedPages"));
|
||||
print '<br>';
|
||||
|
||||
print $langs->trans("LinkToGeneratedPagesDesc").'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("LinkToGeneratedPagesDesc").'</span><br>';
|
||||
print '<br>';
|
||||
|
||||
dol_htmloutput_errors($mesg);
|
||||
|
||||
print '<br>';
|
||||
|
||||
print img_picto('', 'puce').' '.$langs->trans("DocForAllMembersCards", ($conf->global->ADHERENT_CARD_TYPE?$conf->global->ADHERENT_CARD_TYPE:$langs->transnoentitiesnoconv("None"))).' ';
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
print '<input type="hidden" name="foruserid" value="all">';
|
||||
@ -272,7 +273,8 @@ asort($arrayoflabels);
|
||||
print $form->selectarray('model', $arrayoflabels, (GETPOST('model')?GETPOST('model'):$conf->global->ADHERENT_CARD_TYPE), 1, 0, 0, '', 0, 0, 0, '', '', 1);
|
||||
print '<br><input class="button" type="submit" value="'.$langs->trans("BuildDoc").'">';
|
||||
print '</form>';
|
||||
print '<br>';
|
||||
|
||||
print '<br><br>';
|
||||
|
||||
print img_picto('', 'puce').' '.$langs->trans("DocForOneMemberCards", ($conf->global->ADHERENT_CARD_TYPE?$conf->global->ADHERENT_CARD_TYPE:$langs->transnoentitiesnoconv("None"))).' ';
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
@ -290,7 +292,8 @@ print $form->selectarray('model', $arrayoflabels, (GETPOST('model')?GETPOST('mod
|
||||
print '<br>'.$langs->trans("Login").': <input size="10" type="text" name="foruserlogin" value="'.GETPOST('foruserlogin').'">';
|
||||
print '<br><input class="button" type="submit" value="'.$langs->trans("BuildDoc").'">';
|
||||
print '</form>';
|
||||
print '<br>';
|
||||
|
||||
print '<br><br>';
|
||||
|
||||
print img_picto('', 'puce').' '.$langs->trans("DocForLabels", $conf->global->ADHERENT_ETIQUETTE_TYPE).' ';
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
@ -307,7 +310,6 @@ asort($arrayoflabels);
|
||||
print $form->selectarray('modellabel', $arrayoflabels, (GETPOST('modellabel')?GETPOST('modellabel'):$conf->global->ADHERENT_ETIQUETTE_TYPE), 1, 0, 0, '', 0, 0, 0, '', '', 1);
|
||||
print '<br><input class="button" type="submit" value="'.$langs->trans("BuildDoc").'">';
|
||||
print '</form>';
|
||||
print '<br>';
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
|
||||
@ -176,8 +176,20 @@ class Adherent extends CommonObject
|
||||
|
||||
public $photo;
|
||||
|
||||
public $datec;
|
||||
public $datem;
|
||||
/**
|
||||
* Date creation record (datec)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datec;
|
||||
|
||||
/**
|
||||
* Date modification record (tms)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datem;
|
||||
|
||||
public $datevalid;
|
||||
|
||||
public $gender;
|
||||
@ -587,7 +599,7 @@ class Adherent extends CommonObject
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
dol_syslog(get_class($this)."::update update member", LOG_DEBUG);
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
@ -1866,7 +1878,7 @@ class Adherent extends CommonObject
|
||||
|
||||
$error=0;
|
||||
|
||||
// Check paramaters
|
||||
// Check parameters
|
||||
if ($this->statut == 0)
|
||||
{
|
||||
dol_syslog(get_class($this)."::resiliate statut of member does not allow this", LOG_WARNING);
|
||||
@ -2149,7 +2161,7 @@ class Adherent extends CommonObject
|
||||
* @param int $statut Id statut
|
||||
* @param int $need_subscription 1 if member type need subscription, 0 otherwise
|
||||
* @param int $date_end_subscription Date fin adhesion
|
||||
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto
|
||||
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label
|
||||
*/
|
||||
public function LibStatut($statut, $need_subscription, $date_end_subscription, $mode = 0)
|
||||
@ -2209,7 +2221,7 @@ class Adherent extends CommonObject
|
||||
}
|
||||
elseif ($mode == 5)
|
||||
{
|
||||
if ($statut == -1) return $langs->trans("MemberStatusDraft").' '.img_picto($langs->trans('MemberStatusDraft'), 'statut0');
|
||||
if ($statut == -1) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusDraftShort").'</span> '.img_picto($langs->trans('MemberStatusDraft'), 'statut0');
|
||||
elseif ($statut >= 1) {
|
||||
if (! $date_end_subscription) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusActiveShort").' </span>'.img_picto($langs->trans('MemberStatusActive'), 'statut1');
|
||||
elseif ($date_end_subscription < time()) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusActiveLateShort").' </span>'.img_picto($langs->trans('MemberStatusActiveLate'), 'statut3');
|
||||
@ -2219,13 +2231,13 @@ class Adherent extends CommonObject
|
||||
}
|
||||
elseif ($mode == 6)
|
||||
{
|
||||
if ($statut == -1) return $langs->trans("MemberStatusDraft").' '.img_picto($langs->trans('MemberStatusDraft'), 'statut0');
|
||||
if ($statut == -1) return $langs->trans("MemberStatusDraft").' '.img_picto($langs->trans('MemberStatusDraft'), 'statut0');
|
||||
if ($statut >= 1) {
|
||||
if (! $date_end_subscription) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusActive").' </span>'.img_picto($langs->trans('MemberStatusActive'), 'statut1');
|
||||
elseif ($date_end_subscription < time()) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusActiveLate").' </span>'.img_picto($langs->trans('MemberStatusActiveLate'), 'statut3');
|
||||
else return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusPaid").' </span>'.img_picto($langs->trans('MemberStatusPaid'), 'statut4');
|
||||
if (! $date_end_subscription) return $langs->trans("MemberStatusActive").' '.img_picto($langs->trans('MemberStatusActive'), 'statut1');
|
||||
elseif ($date_end_subscription < time()) return $langs->trans("MemberStatusActiveLate").' '.img_picto($langs->trans('MemberStatusActiveLate'), 'statut3');
|
||||
else return $langs->trans("MemberStatusPaid").' '.img_picto($langs->trans('MemberStatusPaid'), 'statut4');
|
||||
}
|
||||
if ($statut == 0) return '<span class="hideonsmartphone">'.$langs->trans("MemberStatusResiliated").' </span>'.img_picto($langs->trans('MemberStatusResiliated'), 'statut5');
|
||||
if ($statut == 0) return $langs->trans("MemberStatusResiliated").' '.img_picto($langs->trans('MemberStatusResiliated'), 'statut5');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -56,7 +56,7 @@ class AdherentType extends CommonObject
|
||||
/**
|
||||
* @var string
|
||||
* @deprecated Use label
|
||||
* @see label
|
||||
* @see $label
|
||||
*/
|
||||
public $libelle;
|
||||
|
||||
|
||||
@ -86,7 +86,8 @@ class Members extends DolibarrApi
|
||||
* @param int $limit Limit for list
|
||||
* @param int $page Page number
|
||||
* @param string $typeid ID of the type of member
|
||||
* @param string $sqlfilters Other criteria to filter answers separated by a comma. Syntax example "(t.ref:like:'SO-%') and (t.date_creation:<:'20160101')"
|
||||
* @param string $sqlfilters Other criteria to filter answers separated by a comma.
|
||||
* Example: "(t.ref:like:'SO-%') and ((t.date_creation:<:'20160101') or (t.nature:is:NULL))"
|
||||
* @return array Array of member objects
|
||||
*
|
||||
* @throws RestException
|
||||
|
||||
@ -47,10 +47,33 @@ class Subscription extends CommonObject
|
||||
*/
|
||||
public $picto='payment';
|
||||
|
||||
public $datec; // Date creation
|
||||
public $datem; // Date modification
|
||||
public $dateh; // Subscription start date (date subscription)
|
||||
public $datef; // Subscription end date
|
||||
/**
|
||||
* Date creation record (datec)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datec;
|
||||
|
||||
/**
|
||||
* Date modification record (tms)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datem;
|
||||
|
||||
/**
|
||||
* Subscription start date (date subscription)
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $dateh;
|
||||
|
||||
/**
|
||||
* Subscription end date
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
public $datef;
|
||||
|
||||
/**
|
||||
* @var int ID
|
||||
|
||||
@ -113,7 +113,7 @@ if ($id > 0)
|
||||
print '<div class="fichecenter">';
|
||||
|
||||
print '<div class="underbanner clearboth"></div>';
|
||||
print '<table class="border centpercent">';
|
||||
print '<table class="border tableforfield centpercent">';
|
||||
|
||||
$linkback = '<a href="'.DOL_URL_ROOT.'/adherents/list.php">'.$langs->trans("BackToList").'</a>';
|
||||
|
||||
@ -128,7 +128,7 @@ if ($id > 0)
|
||||
|
||||
// Morphy
|
||||
print '<tr><td class="titlefield">'.$langs->trans("Nature").'</td><td class="valeur" >'.$object->getmorphylib().'</td>';
|
||||
/*print '<td rowspan="'.$rowspan.'" align="center" valign="middle" width="25%">';
|
||||
/*print '<td rowspan="'.$rowspan.'" class="center" valign="middle" width="25%">';
|
||||
print $form->showphoto('memberphoto',$object);
|
||||
print '</td>';*/
|
||||
print '</tr>';
|
||||
@ -140,10 +140,10 @@ if ($id > 0)
|
||||
print '<tr><td>'.$langs->trans("UserTitle").'</td><td class="valeur">'.$object->getCivilityLabel().' </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Nbre fichiers
|
||||
// Number of Attached Files
|
||||
print '<tr><td>'.$langs->trans("NbOfAttachedFiles").'</td><td colspan="3">'.count($filearray).'</td></tr>';
|
||||
|
||||
//Total taille
|
||||
//Total Size Of Attached Files
|
||||
print '<tr><td>'.$langs->trans("TotalSizeOfAttachedFiles").'</td><td colspan="3">'.dol_print_size($totalsize, 1, 1).'</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
@ -162,7 +162,7 @@ if ($conf->use_javascript_ajax)
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder nohover" width="100%">';
|
||||
print '<tr class="liste_titre"><th colspan="2">'.$langs->trans("Statistics").'</th></tr>';
|
||||
print '<tr><td align="center" colspan="2">';
|
||||
print '<tr><td class="center" colspan="2">';
|
||||
|
||||
$SommeA=0;
|
||||
$SommeB=0;
|
||||
|
||||
@ -358,14 +358,14 @@ $arrayofmassactions = array(
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
if ($user->rights->adherent->supprimer) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
if ($user->rights->adherent->supprimer) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('', $arrayofmassactions);
|
||||
|
||||
$newcardbutton='';
|
||||
if ($user->rights->adherent->creer)
|
||||
{
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/card.php?action=create"><span class="valignmiddle">'.$langs->trans('NewMember').'</span>';
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/card.php?action=create"><span class="valignmiddle text-plus-circle">'.$langs->trans('NewMember').'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
}
|
||||
@ -436,23 +436,23 @@ if (! empty($conf->global->MAIN_SHOW_TECHNICAL_ID))
|
||||
if (! empty($arrayfields['d.ref']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_ref" value="'.dol_escape_htmltag($search_ref).'">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_ref" value="'.dol_escape_htmltag($search_ref).'">';
|
||||
print '</td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.civility']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth25" type="text" name="search_civility" value="'.dol_escape_htmltag($search_civility).'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth50imp" type="text" name="search_civility" value="'.dol_escape_htmltag($search_civility).'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.firstname']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_firstname" value="'.dol_escape_htmltag($search_firstname).'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_firstname" value="'.dol_escape_htmltag($search_firstname).'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.lastname']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_lastname" value="'.dol_escape_htmltag($search_lastname).'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_lastname" value="'.dol_escape_htmltag($search_lastname).'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.gender']['checked']))
|
||||
{
|
||||
@ -463,17 +463,17 @@ if (! empty($arrayfields['d.gender']['checked']))
|
||||
}
|
||||
if (! empty($arrayfields['d.company']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_company" value="'.dol_escape_htmltag($search_company).'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_company" value="'.dol_escape_htmltag($search_company).'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.login']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_login" value="'.dol_escape_htmltag($search_login).'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_login" value="'.dol_escape_htmltag($search_login).'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.morphy']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '</td>';
|
||||
}
|
||||
if (! empty($arrayfields['t.libelle']['checked']))
|
||||
@ -486,62 +486,62 @@ if (! empty($arrayfields['t.libelle']['checked']))
|
||||
|
||||
if (! empty($arrayfields['d.address']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_address" value="'.$search_address.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_address" value="'.$search_address.'"></td>';
|
||||
}
|
||||
|
||||
if (! empty($arrayfields['d.zip']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_zip" value="'.$search_zip.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth50imp" type="text" name="search_zip" value="'.$search_zip.'"></td>';
|
||||
}
|
||||
if (! empty($arrayfields['d.town']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_town" value="'.$search_town.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_town" value="'.$search_town.'"></td>';
|
||||
}
|
||||
// State
|
||||
if (! empty($arrayfields['state.nom']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre">';
|
||||
print '<input class="flat searchstring maxwidth50" type="text" name="search_state" value="'.dol_escape_htmltag($search_state).'">';
|
||||
print '<input class="flat searchstring maxwidth75imp" type="text" name="search_state" value="'.dol_escape_htmltag($search_state).'">';
|
||||
print '</td>';
|
||||
}
|
||||
// Country
|
||||
if (! empty($arrayfields['country.code_iso']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="center">';
|
||||
print '<td class="liste_titre center">';
|
||||
print $form->select_country($search_country, 'search_country', '', 0, 'minwidth100imp maxwidth100');
|
||||
print '</td>';
|
||||
}
|
||||
// Phone pro
|
||||
if (! empty($arrayfields['d.phone']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_phone" value="'.$search_phone.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_phone" value="'.$search_phone.'"></td>';
|
||||
}
|
||||
// Phone perso
|
||||
if (! empty($arrayfields['d.phone_perso']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_phone_perso" value="'.$search_phone_perso.'"></td>';
|
||||
}
|
||||
// Phone mobile
|
||||
if (! empty($arrayfields['d.phone_mobile']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_phone_mobile" value="'.$search_phone_mobile.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_phone_mobile" value="'.$search_phone_mobile.'"></td>';
|
||||
}
|
||||
// Email
|
||||
if (! empty($arrayfields['d.email']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<input class="flat maxwidth50" type="text" name="search_email" value="'.$search_email.'"></td>';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat maxwidth75imp" type="text" name="search_email" value="'.$search_email.'"></td>';
|
||||
}
|
||||
|
||||
if (! empty($arrayfields['d.datefin']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '</td>';
|
||||
}
|
||||
// Extra fields
|
||||
@ -576,7 +576,7 @@ if (! empty($arrayfields['d.statut']['checked']))
|
||||
print '</td>';
|
||||
}
|
||||
// Action column
|
||||
print '<td class="liste_titre" align="middle">';
|
||||
print '<td class="liste_titre middle">';
|
||||
$searchpicto=$form->showFilterButtons();
|
||||
print $searchpicto;
|
||||
print '</td>';
|
||||
@ -647,7 +647,7 @@ while ($i < min($num, $limit))
|
||||
|
||||
if (! empty($conf->global->MAIN_SHOW_TECHNICAL_ID))
|
||||
{
|
||||
print '<td align="center">'.$obj->rowid.'</td>';
|
||||
print '<td class="center">'.$obj->rowid.'</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
@ -753,7 +753,7 @@ while ($i < min($num, $limit))
|
||||
// Country
|
||||
if (! empty($arrayfields['country.code_iso']['checked']))
|
||||
{
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
$tmparray=getCountry($obj->country, 'all');
|
||||
print $tmparray['label'];
|
||||
print '</td>';
|
||||
@ -794,7 +794,7 @@ while ($i < min($num, $limit))
|
||||
{
|
||||
if ($datefin)
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
print dol_print_date($datefin, 'day');
|
||||
if ($memberstatic->hasDelay()) {
|
||||
$textlate .= ' ('.$langs->trans("DateReference").' > '.$langs->trans("DateToday").' '.(ceil($conf->adherent->subscription->warning_delay/60/60/24) >= 0 ? '+' : '').ceil($conf->adherent->subscription->warning_delay/60/60/24).' '.$langs->trans("days").')';
|
||||
@ -804,7 +804,7 @@ while ($i < min($num, $limit))
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="left" class="nowrap">';
|
||||
print '<td class="nowrap left">';
|
||||
if ($obj->subscription == 'yes')
|
||||
{
|
||||
print $langs->trans("SubscriptionNotReceived");
|
||||
@ -826,7 +826,7 @@ while ($i < min($num, $limit))
|
||||
// Date creation
|
||||
if (! empty($arrayfields['d.datec']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
print dol_print_date($db->jdate($obj->date_creation), 'dayhour', 'tzuser');
|
||||
print '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
@ -834,7 +834,7 @@ while ($i < min($num, $limit))
|
||||
// Date modification
|
||||
if (! empty($arrayfields['d.tms']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
print dol_print_date($db->jdate($obj->date_update), 'dayhour', 'tzuser');
|
||||
print '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
@ -848,7 +848,7 @@ while ($i < min($num, $limit))
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Action column
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($massactionbutton || $massaction) // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined
|
||||
{
|
||||
$selected=0;
|
||||
|
||||
@ -93,7 +93,7 @@ if ($id)
|
||||
|
||||
// Morphy
|
||||
print '<tr><td class="titlefield">'.$langs->trans("Nature").'</td><td class="valeur" >'.$object->getmorphylib().'</td>';
|
||||
/*print '<td rowspan="'.$rowspan.'" align="center" valign="middle" width="25%">';
|
||||
/*print '<td rowspan="'.$rowspan.'" class="center" valign="middle" width="25%">';
|
||||
print $form->showphoto('memberphoto',$member);
|
||||
print '</td>';*/
|
||||
print '</tr>';
|
||||
|
||||
@ -121,8 +121,8 @@ print '<table class="liste" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Nature").'</td>';
|
||||
print '<td class="right">'.$langs->trans("NbOfMembers").'</td>';
|
||||
print '<td align="center">'.$langs->trans("LastMemberDate").'</td>';
|
||||
print '<td align="center">'.$langs->trans("LatestSubscriptionDate").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LastMemberDate").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LatestSubscriptionDate").'</td>';
|
||||
print '</tr>';
|
||||
|
||||
if (! $foundphy) $data[]=array('label'=>'phy','nb'=>'0','lastdate'=>'', 'lastsubscriptiondate'=>'');
|
||||
@ -133,8 +133,8 @@ foreach ($data as $val)
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$memberstatic->getmorphylib($val['label']).'</td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
print '<td align="center">'.dol_print_date($val['lastdate'], 'dayhour').'</td>';
|
||||
print '<td align="center">'.dol_print_date($val['lastsubscriptiondate'], 'dayhour').'</td>';
|
||||
print '<td class="center">'.dol_print_date($val['lastdate'], 'dayhour').'</td>';
|
||||
print '<td class="center">'.dol_print_date($val['lastsubscriptiondate'], 'dayhour').'</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
|
||||
@ -244,7 +244,7 @@ else
|
||||
// Show graphics
|
||||
if (count($arrayjs) && $mode == 'memberbycountry')
|
||||
{
|
||||
$color_file = DOL_DOCUMENT_ROOT.'/theme/'.$conf->theme.'/graph-color.php';
|
||||
$color_file = DOL_DOCUMENT_ROOT.'/theme/'.$conf->theme.'/theme_vars.inc.php';
|
||||
if (is_readable($color_file)) include_once $color_file;
|
||||
|
||||
// Assume we've already included the proper headers so just call our script inline
|
||||
@ -287,7 +287,7 @@ if (count($arrayjs) && $mode == 'memberbycountry')
|
||||
print "</script>\n";
|
||||
|
||||
// print the div tag that will contain the map
|
||||
print '<div align="center" id="'.$mode.'"></div>'."\n";
|
||||
print '<div class="center" id="'.$mode.'"></div>'."\n";
|
||||
print '<br>';
|
||||
}
|
||||
|
||||
@ -297,10 +297,10 @@ if ($mode)
|
||||
print '<table class="liste" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$label.'</td>';
|
||||
if ($label2) print '<td align="center">'.$label2.'</td>';
|
||||
if ($label2) print '<td class="center">'.$label2.'</td>';
|
||||
print '<td class="right">'.$langs->trans("NbOfMembers").'</td>';
|
||||
print '<td align="center">'.$langs->trans("LastMemberDate").'</td>';
|
||||
print '<td align="center">'.$langs->trans("LatestSubscriptionDate").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LastMemberDate").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LatestSubscriptionDate").'</td>';
|
||||
print '</tr>';
|
||||
|
||||
foreach ($data as $val)
|
||||
@ -308,10 +308,10 @@ if ($mode)
|
||||
$year = $val['year'];
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$val['label'].'</td>';
|
||||
if ($label2) print '<td align="center">'.$val['label2'].'</td>';
|
||||
if ($label2) print '<td class="center">'.$val['label2'].'</td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
print '<td align="center">'.dol_print_date($val['lastdate'], 'dayhour').'</td>';
|
||||
print '<td align="center">'.dol_print_date($val['lastsubscriptiondate'], 'dayhour').'</td>';
|
||||
print '<td class="center">'.dol_print_date($val['lastdate'], 'dayhour').'</td>';
|
||||
print '<td class="center">'.dol_print_date($val['lastsubscriptiondate'], 'dayhour').'</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
|
||||
@ -157,7 +157,7 @@ print '</td></tr>';
|
||||
print '<tr><td>'.$langs->trans("User").'</td><td>';
|
||||
print $form->select_dolusers($userid, 'userid', 1, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth300');
|
||||
print '</td></tr>';
|
||||
print '<tr><td align="center" colspan="2"><input type="submit" name="submit" class="button" value="'.$langs->trans("Refresh").'"></td></tr>';
|
||||
print '<tr><td class="center" colspan="2"><input type="submit" name="submit" class="button" value="'.$langs->trans("Refresh").'"></td></tr>';
|
||||
print '</table>';
|
||||
print '</form>';
|
||||
print '<br><br>';
|
||||
@ -170,7 +170,7 @@ $data = $stats->getAllByYear();
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<tr class="liste_titre" height="24">';
|
||||
print '<td align="center">'.$langs->trans("Year").'</td>';
|
||||
print '<td class="center">'.$langs->trans("Year").'</td>';
|
||||
print '<td class="right">'.$langs->trans("NbOfSubscriptions").'</td>';
|
||||
print '<td class="right">'.$langs->trans("AmountTotal").'</td>';
|
||||
print '<td class="right">'.$langs->trans("AmountAverage").'</td>';
|
||||
@ -184,7 +184,7 @@ foreach ($data as $val)
|
||||
{ // If we have empty year
|
||||
$oldyear--;
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print '<a href="month.php?year='.$oldyear.'&mode='.$mode.'">';
|
||||
print $oldyear;
|
||||
print '</a>';
|
||||
@ -195,7 +195,7 @@ foreach ($data as $val)
|
||||
print '</tr>';
|
||||
}
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
//print '<a href="month.php?year='.$year.'">';
|
||||
print $year;
|
||||
//print '</a>';
|
||||
@ -215,7 +215,7 @@ print '</div><div class="fichetwothirdright"><div class="ficheaddleft">';
|
||||
|
||||
|
||||
// Show graphs
|
||||
print '<table class="border" width="100%"><tr class="pair nohover"><td align="center">';
|
||||
print '<table class="border" width="100%"><tr class="pair nohover"><td class="center">';
|
||||
if ($mesg) { print $mesg; }
|
||||
else {
|
||||
print $px1->show();
|
||||
|
||||
@ -692,9 +692,9 @@ if ($rowid > 0)
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre('Ref', $_SERVER["PHP_SELF"], 'c.rowid', '', $param, '', $sortfield, $sortorder);
|
||||
print '<td align="center">'.$langs->trans("DateCreation").'</td>';
|
||||
print '<td align="center">'.$langs->trans("DateStart").'</td>';
|
||||
print '<td align="center">'.$langs->trans("DateEnd").'</td>';
|
||||
print '<td class="center">'.$langs->trans("DateCreation").'</td>';
|
||||
print '<td class="center">'.$langs->trans("DateStart").'</td>';
|
||||
print '<td class="center">'.$langs->trans("DateEnd").'</td>';
|
||||
print '<td class="right">'.$langs->trans("Amount").'</td>';
|
||||
if (! empty($conf->banque->enabled))
|
||||
{
|
||||
@ -713,9 +713,9 @@ if ($rowid > 0)
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$subscriptionstatic->getNomUrl(1).'</td>';
|
||||
print '<td align="center">'.dol_print_date($db->jdate($objp->datec), 'dayhour')."</td>\n";
|
||||
print '<td align="center">'.dol_print_date($db->jdate($objp->dateh), 'day')."</td>\n";
|
||||
print '<td align="center">'.dol_print_date($db->jdate($objp->datef), 'day')."</td>\n";
|
||||
print '<td class="center">'.dol_print_date($db->jdate($objp->datec), 'dayhour')."</td>\n";
|
||||
print '<td class="center">'.dol_print_date($db->jdate($objp->dateh), 'day')."</td>\n";
|
||||
print '<td class="center">'.dol_print_date($db->jdate($objp->datef), 'day')."</td>\n";
|
||||
print '<td class="right">'.price($objp->subscription).'</td>';
|
||||
if (! empty($conf->banque->enabled))
|
||||
{
|
||||
|
||||
@ -240,14 +240,14 @@ $arrayofmassactions = array(
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
//if ($user->rights->adherent->supprimer) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
//if ($user->rights->adherent->supprimer) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('', $arrayofmassactions);
|
||||
|
||||
$newcardbutton='';
|
||||
if ($user->rights->adherent->cotisation->creer)
|
||||
{
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/list.php?status=-1,1"><span class="valignmiddle">'.$langs->trans('NewSubscription').'</span>';
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/list.php?status=-1,1"><span class="valignmiddle text-plus-circle">'.$langs->trans('NewSubscription').'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
}
|
||||
@ -284,7 +284,7 @@ $selectedfields=$form->multiSelectArrayWithCheckbox('selectedfields', $arrayfiel
|
||||
if ($massactionbutton) $selectedfields.=$form->showCheckAddButtons('checkforselect', 1);
|
||||
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="tagtable liste'.($moreforfilter?" listwithfilterbefore":"").'">'."\n";
|
||||
print '<table class="tagtable nobottomiftotal liste'.($moreforfilter?" listwithfilterbefore":"").'">'."\n";
|
||||
|
||||
|
||||
// Line for filters fields
|
||||
@ -299,33 +299,33 @@ if (! empty($conf->global->MAIN_SHOW_TECHNICAL_ID))
|
||||
// Ref
|
||||
if (! empty($arrayfields['d.ref']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_ref" value="'.dol_escape_htmltag($search_ref).'" size="4"></td>';
|
||||
}
|
||||
|
||||
// Type
|
||||
if (! empty($arrayfields['d.fk_type']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_type" value="'.dol_escape_htmltag($search_type).'" size="7">';
|
||||
print'</td>';
|
||||
}
|
||||
|
||||
if (! empty($arrayfields['d.lastname']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_lastname" value="'.dol_escape_htmltag($search_lastname).'" size="7"></td>';
|
||||
}
|
||||
|
||||
if (! empty($arrayfields['d.firstname']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_firstname" value="'.dol_escape_htmltag($search_firstname).'" size="12"></td>';
|
||||
}
|
||||
|
||||
if (! empty($arrayfields['d.login']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_login" value="'.dol_escape_htmltag($search_login).'" size="7"></td>';
|
||||
}
|
||||
|
||||
@ -339,7 +339,7 @@ if (! empty($arrayfields['t.libelle']['checked']))
|
||||
if (! empty($arrayfields['d.bank']['checked']))
|
||||
{
|
||||
print '<td class="liste_titre">';
|
||||
print $form->select_comptes($search_account, 'search_account', 0, '', 1);
|
||||
$form->select_comptes($search_account, 'search_account', 0, '', 1);
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
@ -529,13 +529,13 @@ while ($i < min($num, $limit))
|
||||
// Date start
|
||||
if (! empty($arrayfields['c.dateadh']['checked']))
|
||||
{
|
||||
print '<td align="center">'.dol_print_date($db->jdate($obj->dateadh), 'day')."</td>\n";
|
||||
print '<td class="center">'.dol_print_date($db->jdate($obj->dateadh), 'day')."</td>\n";
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Date end
|
||||
if (! empty($arrayfields['c.datef']['checked']))
|
||||
{
|
||||
print '<td align="center">'.dol_print_date($db->jdate($obj->datef), 'day')."</td>\n";
|
||||
print '<td class="center">'.dol_print_date($db->jdate($obj->datef), 'day')."</td>\n";
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Price
|
||||
@ -555,7 +555,7 @@ while ($i < min($num, $limit))
|
||||
// Date creation
|
||||
if (! empty($arrayfields['c.datec']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
print dol_print_date($db->jdate($obj->date_creation), 'dayhour', 'tzuser');
|
||||
print '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
@ -563,13 +563,13 @@ while ($i < min($num, $limit))
|
||||
// Date modification
|
||||
if (! empty($arrayfields['c.tms']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
print dol_print_date($db->jdate($obj->date_update), 'dayhour', 'tzuser');
|
||||
print '</td>';
|
||||
if (! $i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Action column
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($massactionbutton || $massaction) // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined
|
||||
{
|
||||
$selected=0;
|
||||
|
||||
@ -44,8 +44,8 @@ foreach($linkedObjectBlock as $key => $objectlink)
|
||||
<tr class="oddeven" >
|
||||
<td><?php echo $langs->trans("Subscription"); ?></td>
|
||||
<td><?php echo $objectlink->getNomUrl(1); ?></td>
|
||||
<td align="center"></td>
|
||||
<td align="center"><?php echo dol_print_date($objectlink->dateh, 'day'); ?></td>
|
||||
<td class="center"></td>
|
||||
<td class="center"><?php echo dol_print_date($objectlink->dateh, 'day'); ?></td>
|
||||
<td class="right"><?php
|
||||
if ($user->rights->adherent->lire) {
|
||||
$total = $total + $objectlink->amount;
|
||||
|
||||
@ -232,7 +232,7 @@ if (! $rowid && $action != 'create' && $action != 'edit')
|
||||
$newcardbutton='';
|
||||
if ($user->rights->adherent->configurer)
|
||||
{
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/type.php?action=create"><span class="valignmiddle">'.$langs->trans('NewMemberType').'</span>';
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/adherents/type.php?action=create"><span class="valignmiddle text-plus-circle">'.$langs->trans('NewMemberType').'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
}
|
||||
@ -256,9 +256,9 @@ if (! $rowid && $action != 'create' && $action != 'edit')
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th>'.$langs->trans("Ref").'</th>';
|
||||
print '<th>'.$langs->trans("Label").'</th>';
|
||||
print '<th align="center">'.$langs->trans("SubscriptionRequired").'</th>';
|
||||
print '<th align="center">'.$langs->trans("VoteAllowed").'</th>';
|
||||
print '<th align="center">'.$langs->trans("Status").'</th>';
|
||||
print '<th class="center">'.$langs->trans("SubscriptionRequired").'</th>';
|
||||
print '<th class="center">'.$langs->trans("VoteAllowed").'</th>';
|
||||
print '<th class="center">'.$langs->trans("Status").'</th>';
|
||||
print '<th> </th>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -277,9 +277,9 @@ if (! $rowid && $action != 'create' && $action != 'edit')
|
||||
//<a href="'.$_SERVER["PHP_SELF"].'?rowid='.$objp->rowid.'">'.img_object($langs->trans("ShowType"),'group').' '.$objp->rowid.'</a>
|
||||
print '</td>';
|
||||
print '<td>'.dol_escape_htmltag($objp->label).'</td>';
|
||||
print '<td align="center">'.yn($objp->subscription).'</td>';
|
||||
print '<td align="center">'.yn($objp->vote).'</td>';
|
||||
print '<td align="center">';
|
||||
print '<td class="center">'.yn($objp->subscription).'</td>';
|
||||
print '<td class="center">'.yn($objp->vote).'</td>';
|
||||
print '<td class="center">';
|
||||
if ( !empty($objp->statut) ) {
|
||||
print img_picto($langs->trans("InActivity"), 'statut4');
|
||||
} else {
|
||||
@ -586,15 +586,15 @@ if ($rowid > 0)
|
||||
// Lignes des champs de filtre
|
||||
print '<tr class="liste_titre_filter">';
|
||||
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_lastname" value="'.dol_escape_htmltag($search_lastname).'" size="12"></td>';
|
||||
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_login" value="'.dol_escape_htmltag($search_login).'" size="7"></td>';
|
||||
|
||||
print '<td class="liste_titre"> </td>';
|
||||
|
||||
print '<td class="liste_titre" align="left">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" name="search_email" value="'.dol_escape_htmltag($search_email).'" size="12"></td>';
|
||||
|
||||
print '<td class="liste_titre"> </td>';
|
||||
@ -663,7 +663,7 @@ if ($rowid > 0)
|
||||
// Date end subscription
|
||||
if ($datefin)
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
if ($datefin < dol_now() && $objp->statut > 0)
|
||||
{
|
||||
print dol_print_date($datefin, 'day')." ".img_warning($langs->trans("SubscriptionLate"));
|
||||
@ -676,7 +676,7 @@ if ($rowid > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="left" class="nowrap">';
|
||||
print '<td class="nowrap left">';
|
||||
if ($objp->subscription == 'yes')
|
||||
{
|
||||
print $langs->trans("SubscriptionNotReceived");
|
||||
@ -690,7 +690,7 @@ if ($rowid > 0)
|
||||
}
|
||||
|
||||
// Actions
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($user->rights->adherent->creer)
|
||||
{
|
||||
print '<a href="card.php?rowid='.$objp->rowid.'&action=edit&backtopage='.urlencode($_SERVER["PHP_SELF"].'?rowid='.$object->id).'">'.img_edit().'</a>';
|
||||
|
||||
@ -134,8 +134,7 @@ $head=agenda_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'autoactions', $langs->trans("Agenda"), -1, 'action');
|
||||
|
||||
print $langs->trans("AgendaAutoActionDesc")."<br>\n";
|
||||
print $langs->trans("OnlyActiveElementsAreShown", 'modules.php').'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("AgendaAutoActionDesc")." ".$langs->trans("OnlyActiveElementsAreShown", 'modules.php').'</span><br>';
|
||||
print "<br>\n";
|
||||
|
||||
print '<div class="div-table-responsive">'; // You can use div-table-responsive-no-min if you dont need reserved height for your table
|
||||
|
||||
@ -140,7 +140,7 @@ $head=agenda_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'extsites', $langs->trans("Agenda"), -1, 'action');
|
||||
|
||||
print $langs->trans("AgendaExtSitesDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("AgendaExtSitesDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
|
||||
|
||||
@ -84,7 +84,7 @@ $head=agenda_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'xcal', $langs->trans("Agenda"), -1, 'action');
|
||||
|
||||
print $langs->trans("AgendaSetupOtherDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("AgendaSetupOtherDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
@ -50,8 +50,8 @@ $type = 'bankaccount';
|
||||
|
||||
//Order display of bank account
|
||||
if ($action == 'setbankorder') {
|
||||
if (dolibarr_set_const($db, "BANK_SHOW_ORDER_OPTION",
|
||||
GETPOST('value', 'alpha'), 'chaine', 0, '', $conf->entity) > 0) {
|
||||
if (dolibarr_set_const($db, "BANK_SHOW_ORDER_OPTION", GETPOST('value', 'alpha'), 'chaine', 0, '', $conf->entity) > 0)
|
||||
{
|
||||
header("Location: " . $_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
@ -62,8 +62,8 @@ if ($action == 'setbankorder') {
|
||||
|
||||
//Auto report last num releve on conciliate
|
||||
if ($action == 'setreportlastnumreleve') {
|
||||
if (dolibarr_set_const($db, "BANK_REPORT_LAST_NUM_RELEVE", 1, 'chaine', 0,
|
||||
'', $conf->entity) > 0) {
|
||||
if (dolibarr_set_const($db, "BANK_REPORT_LAST_NUM_RELEVE", 1, 'chaine', 0, '', $conf->entity) > 0)
|
||||
{
|
||||
header("Location: " . $_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
@ -72,8 +72,8 @@ if ($action == 'setreportlastnumreleve') {
|
||||
}
|
||||
}
|
||||
elseif ($action == 'unsetreportlastnumreleve') {
|
||||
if (dolibarr_set_const($db, "BANK_REPORT_LAST_NUM_RELEVE", 0, 'chaine', 0,
|
||||
'', $conf->entity) > 0) {
|
||||
if (dolibarr_set_const($db, "BANK_REPORT_LAST_NUM_RELEVE", 0, 'chaine', 0, '', $conf->entity) > 0)
|
||||
{
|
||||
header("Location: " . $_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
@ -100,8 +100,7 @@ if ($action == 'specimen') {
|
||||
$filefound = 0;
|
||||
$dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']);
|
||||
foreach ($dirmodels as $reldir) {
|
||||
$file = dol_buildpath($reldir . "core/modules/bank/doc/pdf_" . $modele . ".modules.php",
|
||||
0);
|
||||
$file = dol_buildpath($reldir . "core/modules/bank/doc/pdf_" . $modele . ".modules.php", 0);
|
||||
if (file_exists($file)) {
|
||||
$filefound = 1;
|
||||
$classname = "pdf_" . $modele;
|
||||
@ -142,8 +141,7 @@ elseif ($action == 'del') {
|
||||
}
|
||||
// Set default model
|
||||
elseif ($action == 'setdoc') {
|
||||
if (dolibarr_set_const($db, "BANKADDON_PDF", $value, 'chaine', 0, '',
|
||||
$conf->entity)) {
|
||||
if (dolibarr_set_const($db, "BANKADDON_PDF", $value, 'chaine', 0, '', $conf->entity)) {
|
||||
// The constant that was read before the new set
|
||||
// We therefore requires a variable to have a coherent view
|
||||
$conf->global->BANKADDON_PDF = $value;
|
||||
@ -169,8 +167,7 @@ $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']);
|
||||
llxHeader("", $langs->trans("BankSetupModule"));
|
||||
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
print load_fiche_titre($langs->trans("BankSetupModule"), $linkback,
|
||||
'title_setup');
|
||||
print load_fiche_titre($langs->trans("BankSetupModule"), $linkback, 'title_setup');
|
||||
|
||||
$head = bank_admin_prepare_head(null);
|
||||
dol_fiche_head($head, 'general', $langs->trans("BankSetupModule"), -1, 'account');
|
||||
@ -252,7 +249,7 @@ if ($resql) {
|
||||
while ($i < $num_rows) {
|
||||
$array = $db->fetch_array($resql);
|
||||
array_push($def, $array[0]);
|
||||
$i ++;
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
else {
|
||||
@ -285,8 +282,7 @@ foreach ($dirmodels as $reldir) {
|
||||
arsort($filelist);
|
||||
|
||||
foreach ($filelist as $file) {
|
||||
if (preg_match('/\.modules\.php$/i', $file) && preg_match('/^(pdf_|doc_)/',
|
||||
$file)) {
|
||||
if (preg_match('/\.modules\.php$/i', $file) && preg_match('/^(pdf_|doc_)/', $file)) {
|
||||
|
||||
if (file_exists($dir . '/' . $file)) {
|
||||
$name = substr($file, 4, dol_strlen($file) - 16);
|
||||
@ -296,11 +292,9 @@ foreach ($dirmodels as $reldir) {
|
||||
$module = new $classname($db);
|
||||
|
||||
$modulequalified = 1;
|
||||
if ($module->version == 'development' && $conf->global->MAIN_FEATURES_LEVEL
|
||||
< 2)
|
||||
if ($module->version == 'development' && $conf->global->MAIN_FEATURES_LEVEL < 2)
|
||||
$modulequalified = 0;
|
||||
if ($module->version == 'experimental' && $conf->global->MAIN_FEATURES_LEVEL
|
||||
< 1)
|
||||
if ($module->version == 'experimental' && $conf->global->MAIN_FEATURES_LEVEL < 1)
|
||||
$modulequalified = 0;
|
||||
|
||||
if ($modulequalified) {
|
||||
@ -317,27 +311,23 @@ foreach ($dirmodels as $reldir) {
|
||||
if (in_array($name, $def)) {
|
||||
print '<td class="center">' . "\n";
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=del&value=' . $name . '">';
|
||||
print img_picto($langs->trans("Enabled"),
|
||||
'switch_on');
|
||||
print img_picto($langs->trans("Enabled"), 'switch_on');
|
||||
print '</a>';
|
||||
print '</td>';
|
||||
}
|
||||
else {
|
||||
print '<td class="center">' . "\n";
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=set&value=' . $name . '&scan_dir=' . $module->scandir . '&label=' . urlencode($module->name) . '">' . img_picto($langs->trans("Disabled"),
|
||||
'switch_off') . '</a>';
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=set&value=' . $name . '&scan_dir=' . $module->scandir . '&label=' . urlencode($module->name) . '">' . img_picto($langs->trans("Disabled"), 'switch_off') . '</a>';
|
||||
print "</td>";
|
||||
}
|
||||
|
||||
// Default
|
||||
print '<td class="center">';
|
||||
if ($conf->global->BANKADDON_PDF == $name) {
|
||||
print img_picto($langs->trans("Default"),
|
||||
'on');
|
||||
print img_picto($langs->trans("Default"), 'on');
|
||||
}
|
||||
else {
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=setdoc&value=' . $name . '&scan_dir=' . $module->scandir . '&label=' . urlencode($module->name) . '" alt="' . $langs->trans("Default") . '">' . img_picto($langs->trans("Disabled"),
|
||||
'off') . '</a>';
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=setdoc&value=' . $name . '&scan_dir=' . $module->scandir . '&label=' . urlencode($module->name) . '" alt="' . $langs->trans("Default") . '">' . img_picto($langs->trans("Disabled"), 'off') . '</a>';
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
@ -348,30 +338,25 @@ foreach ($dirmodels as $reldir) {
|
||||
$htmltooltip .= '<br>' . $langs->trans("Width") . '/' . $langs->trans("Height") . ': ' . $module->page_largeur . '/' . $module->page_hauteur;
|
||||
}
|
||||
$htmltooltip .= '<br><br><u>' . $langs->trans("FeaturesSupported") . ':</u>';
|
||||
$htmltooltip .= '<br>' . $langs->trans("Logo") . ': ' . yn($module->option_logo,
|
||||
1, 1);
|
||||
$htmltooltip .= '<br>' . $langs->trans("Logo") . ': ' . yn($module->option_logo, 1, 1);
|
||||
//$htmltooltip .= '<br>' . $langs->trans("PaymentMode") . ': ' . yn($module->option_modereg, 1, 1);
|
||||
//$htmltooltip .= '<br>' . $langs->trans("PaymentConditions") . ': ' . yn($module->option_condreg, 1, 1);
|
||||
$htmltooltip .= '<br>' . $langs->trans("MultiLanguage") . ': ' . yn($module->option_multilang,
|
||||
1, 1);
|
||||
$htmltooltip .= '<br>' . $langs->trans("MultiLanguage") . ': ' . yn($module->option_multilang, 1, 1);
|
||||
// $htmltooltip.='<br>'.$langs->trans("Discounts").': '.yn($module->option_escompte,1,1);
|
||||
// $htmltooltip.='<br>'.$langs->trans("CreditNote").': '.yn($module->option_credit_note,1,1);
|
||||
//$htmltooltip .= '<br>' . $langs->trans("WatermarkOnDraftOrders") . ': ' . yn($module->option_draft_watermark, 1, 1);
|
||||
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1,
|
||||
0);
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
print '</td>';
|
||||
|
||||
// Preview
|
||||
print '<td class="center">';
|
||||
if ($module->type == 'pdf') {
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=specimen&module=' . $name . '">' . img_object($langs->trans("Preview"),
|
||||
'bill') . '</a>';
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=specimen&module=' . $name . '">' . img_object($langs->trans("Preview"), 'bill') . '</a>';
|
||||
}
|
||||
else {
|
||||
print img_object($langs->trans("PreviewNotAvailable"),
|
||||
'generic');
|
||||
print img_object($langs->trans("PreviewNotAvailable"), 'generic');
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
@ -423,8 +408,7 @@ if ($conf->global->BANK_REPORT_LAST_NUM_RELEVE) {
|
||||
else
|
||||
{
|
||||
print '<td class="center">' . "\n";
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=setreportlastnumreleve">' . img_picto($langs->trans("Disabled"),
|
||||
'switch_off') . '</a>';
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=setreportlastnumreleve">' . img_picto($langs->trans("Disabled"), 'switch_off') . '</a>';
|
||||
print "</td>";
|
||||
}
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2008-2018 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2008-2019 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -36,7 +36,8 @@ $action = GETPOST('action', 'alpha');
|
||||
$backtopage = GETPOST('backtopage', 'alpha');
|
||||
|
||||
$arrayofparameters=array(
|
||||
'DAV_ALLOW_PUBLIC_DIR'=>array('css'=>'minwidth200', 'enabled'=>1),
|
||||
'DAV_ALLOW_PRIVATE_DIR'=>array('css'=>'minwidth200', 'enabled'=>2),
|
||||
'DAV_ALLOW_PUBLIC_DIR'=>array('css'=>'minwidth200', 'enabled'=>1),
|
||||
'DAV_ALLOW_ECM_DIR'=>array('css'=>'minwidth200', 'enabled'=>$conf->ecm->enabled)
|
||||
);
|
||||
|
||||
@ -84,7 +85,11 @@ if ($action == 'edit')
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $form->textwithpicto($langs->trans($key), $langs->trans($key.'Tooltip'));
|
||||
print '</td><td>';
|
||||
if ($key == 'DAV_ALLOW_PUBLIC_DIR' || $key == 'DAV_ALLOW_ECM_DIR')
|
||||
if ($key == 'DAV_ALLOW_PRIVATE_DIR')
|
||||
{
|
||||
print $langs->trans("AlwaysActive");
|
||||
}
|
||||
elseif ($key == 'DAV_ALLOW_PUBLIC_DIR' || $key == 'DAV_ALLOW_ECM_DIR')
|
||||
{
|
||||
print $form->selectyesno($key, $conf->global->$key, 1);
|
||||
}
|
||||
@ -114,7 +119,11 @@ else
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $form->textwithpicto($langs->trans($key), $langs->trans($key.'Tooltip'));
|
||||
print '</td><td>';
|
||||
if ($key == 'DAV_ALLOW_PUBLIC_DIR' || $key == 'DAV_ALLOW_ECM_DIR')
|
||||
if ($key == 'DAV_ALLOW_PRIVATE_DIR')
|
||||
{
|
||||
print $langs->trans("AlwaysActive");
|
||||
}
|
||||
elseif ($key == 'DAV_ALLOW_PUBLIC_DIR' || $key == 'DAV_ALLOW_ECM_DIR')
|
||||
{
|
||||
print yn($conf->global->$key);
|
||||
}
|
||||
|
||||
111
htdocs/admin/debugbar.php
Normal file
111
htdocs/admin/debugbar.php
Normal file
@ -0,0 +1,111 @@
|
||||
<?php
|
||||
/* Copyright (C) 2005-2019 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2013 Juanjo Menent <jmenent@2byte.es>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/admin/debugbar.php
|
||||
* \ingroup debugbar
|
||||
* \brief Setup page for debugbar module
|
||||
*/
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||
|
||||
global $conf;
|
||||
|
||||
if (!$user->admin) accessforbidden();
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("admin","other"));
|
||||
|
||||
$error=0;
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
|
||||
// Set modes
|
||||
if ($action == 'set')
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
$result1 = dolibarr_set_const($db, "DEBUGBAR_LOGS_LINES_NUMBER", GETPOST('DEBUGBAR_LOGS_LINES_NUMBER', 'int'), 'chaine', 0, '', 0);
|
||||
$result2 = dolibarr_set_const($db, "DEBUGBAR_USE_LOG_FILE", GETPOST('DEBUGBAR_USE_LOG_FILE', 'int'), 'chaine', 0, '', 0);
|
||||
if ($result1 < 0 || $result2 < 0)
|
||||
{
|
||||
$error++;
|
||||
}
|
||||
|
||||
if (! $error)
|
||||
{
|
||||
$db->commit();
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
}
|
||||
else
|
||||
{
|
||||
$db->rollback();
|
||||
setEventMessages($error, null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
llxHeader();
|
||||
|
||||
$form=new Form($db);
|
||||
|
||||
$linkback='<a href="'.DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans("BackToModuleList").'</a>';
|
||||
print load_fiche_titre($langs->trans("DebugBarSetup"), $linkback, 'title_setup');
|
||||
print '<br>';
|
||||
|
||||
//print load_fiche_titre($langs->trans("DebugBar"));
|
||||
|
||||
// Level
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="post">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<input type="hidden" name="action" value="set">';
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Parameter").'</td><td>'.$langs->trans("Value").'</td>';
|
||||
print '<td class="right"><input type="submit" class="button" '.$option.' value="'.$langs->trans("Modify").'"></td>';
|
||||
print "</tr>\n";
|
||||
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DEBUGBAR_LOGS_LINES_NUMBER").'</td>';
|
||||
print '<td colspan="2"><input type="text" class="flat" name="DEBUGBAR_LOGS_LINES_NUMBER" value="'.(empty($conf->global->DEBUGBAR_LOGS_LINES_NUMBER) ? 250 : $conf->global->DEBUGBAR_LOGS_LINES_NUMBER).'">'; // This slow seriously output
|
||||
print ' '.$langs->trans("WarningValueHigherSlowsDramaticalyOutput");
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DEBUGBAR_USE_LOG_FILE").'</td>';
|
||||
print '<td colspan="2">';
|
||||
print $form->selectyesno('DEBUGBAR_USE_LOG_FILE', $conf->global->DEBUGBAR_USE_LOG_FILE, 1);
|
||||
print ' '.$langs->trans("UsingLogFileShowAllRecordOfSubrequestButIsSlower");
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
print "</form>\n";
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
@ -207,7 +207,7 @@ else
|
||||
|
||||
print load_fiche_titre($langs->trans("DefaultValues"), $enabledisablehtml, 'title_setup');
|
||||
|
||||
print $langs->trans("DefaultValuesDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("DefaultValuesDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
||||
* Copyright (C) 2005-2017 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2010-2016 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2011-2015 Philippe Grand <philippe.grand@atoo-net.com>
|
||||
* Copyright (C) 2011-2019 Philippe Grand <philippe.grand@atoo-net.com>
|
||||
* Copyright (C) 2011 Remy Younes <ryounes@gmail.com>
|
||||
* Copyright (C) 2012-2015 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2012 Christophe Battarel <christophe.battarel@ltairis.fr>
|
||||
@ -370,7 +370,7 @@ $tabfieldinsert[35]= "label";
|
||||
$tabfieldinsert[36]= "range_ik,fk_c_exp_tax_cat";
|
||||
$tabfieldinsert[37]= "code,label,short_label,unit_type,scale";
|
||||
|
||||
// Nom du rowid si le champ n'est pas de type autoincrement
|
||||
// Rowid name if the field is not autoincrement type
|
||||
// Example: "" if id field is "rowid" and has autoincrement on
|
||||
// "nameoffield" if id field is not "rowid" or has not autoincrement on
|
||||
$tabrowid=array();
|
||||
@ -703,12 +703,12 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
$_POST["code"]=preg_replace('/\s/', '', $_POST["code"]);
|
||||
}
|
||||
|
||||
// Si verif ok et action add, on ajoute la ligne
|
||||
// If check ok and action add, add the line
|
||||
if ($ok && GETPOST('actionadd'))
|
||||
{
|
||||
if ($tabrowid[$id])
|
||||
{
|
||||
// Recupere id libre pour insertion
|
||||
// Get free id for insert
|
||||
$newid=0;
|
||||
$sql = "SELECT max(".$tabrowid[$id].") newid from ".$tabname[$id];
|
||||
$result = $db->query($sql);
|
||||
@ -771,7 +771,7 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
}
|
||||
}
|
||||
|
||||
// Si verif ok et action modify, on modifie la ligne
|
||||
// If verif ok and action modify, modify the line
|
||||
if ($ok && GETPOST('actionmodify'))
|
||||
{
|
||||
if ($tabrowid[$id]) { $rowidcol=$tabrowid[$id]; }
|
||||
@ -1382,7 +1382,7 @@ if ($id)
|
||||
$withentity = fieldList($fieldlist, $obj, $tabname[$id], 'edit');
|
||||
}
|
||||
|
||||
print '<td colspan="3" align="center">';
|
||||
print '<td colspan="3" class="center">';
|
||||
print '<div name="'.(! empty($obj->rowid)?$obj->rowid:$obj->code).'"></div>';
|
||||
print '<input type="hidden" name="page" value="'.dol_escape_htmltag($page).'">';
|
||||
print '<input type="hidden" name="rowid" value="'.dol_escape_htmltag($rowid).'">';
|
||||
@ -1549,7 +1549,7 @@ if ($id)
|
||||
$valuetoshow = ($obj->code && $key != 'SizeUnit'.strtolower($obj->unit) ? $key : $obj->{$fieldlist[$field]});
|
||||
}
|
||||
elseif ($fieldlist[$field]=='localtax1' || $fieldlist[$field]=='localtax2') {
|
||||
$align="center";
|
||||
$class="center";
|
||||
}
|
||||
elseif ($fieldlist[$field]=='localtax1_type') {
|
||||
if ($obj->localtax1 != 0)
|
||||
@ -1644,14 +1644,14 @@ if ($id)
|
||||
// Only activated on country dictionary
|
||||
if ($id == 4)
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
if ($iserasable) print '<a class="reposition" href="'.$url.'action='.$acts[$obj->favorite].'_favorite">'.$actl[$obj->favorite].'</a>';
|
||||
else print $langs->trans("AlwaysActive");
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
// Active
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td class="nowrap center">';
|
||||
if ($canbedisabled) print '<a class="reposition" href="'.$url.'action='.$acts[$obj->active].'">'.$actl[$obj->active].'</a>';
|
||||
else
|
||||
{
|
||||
@ -1669,7 +1669,7 @@ if ($id)
|
||||
// Delete link
|
||||
if ($iserasable)
|
||||
{
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($user->admin) print '<a href="'.$url.'action=delete">'.img_delete().'</a>';
|
||||
//else print '<a href="#">'.img_delete().'</a>'; // Some dictionary can be edited by other profile than admin
|
||||
print '</td>';
|
||||
@ -1872,7 +1872,7 @@ function fieldList($fieldlist, $obj = '', $tabname = '', $context = '')
|
||||
print '</td>';
|
||||
}
|
||||
elseif ($fieldlist[$field] == 'recuperableonly' || $fieldlist[$field] == 'type_cdr' || $fieldlist[$field] == 'deductible' || $fieldlist[$field] == 'category_type') {
|
||||
if ($fieldlist[$field] == 'type_cdr') print '<td align="center">';
|
||||
if ($fieldlist[$field] == 'type_cdr') print '<td class="center">';
|
||||
else print '<td>';
|
||||
if ($fieldlist[$field] == 'type_cdr') {
|
||||
print $form->selectarray($fieldlist[$field], array(0=>$langs->trans('None'), 1=>$langs->trans('AtEndOfMonth'), 2=>$langs->trans('CurrentNext')), (! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''));
|
||||
@ -1884,7 +1884,7 @@ function fieldList($fieldlist, $obj = '', $tabname = '', $context = '')
|
||||
elseif (in_array($fieldlist[$field], array('nbjour','decalage','taux','localtax1','localtax2'))) {
|
||||
$align="left";
|
||||
if (in_array($fieldlist[$field], array('taux','localtax1','localtax2'))) $align="center"; // Fields aligned on right
|
||||
print '<td align="'.$align.'">';
|
||||
print '<td class="'.$align.'">';
|
||||
print '<input type="text" class="flat" value="'.(isset($obj->{$fieldlist[$field]}) ? $obj->{$fieldlist[$field]} : '').'" size="3" name="'.$fieldlist[$field].'">';
|
||||
print '</td>';
|
||||
}
|
||||
@ -1928,7 +1928,7 @@ function fieldList($fieldlist, $obj = '', $tabname = '', $context = '')
|
||||
// Le type de taxe locale
|
||||
elseif ($fieldlist[$field] == 'localtax1_type' || $fieldlist[$field] == 'localtax2_type')
|
||||
{
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->selectarray($fieldlist[$field], $localtax_typeList, (! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''));
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
@ -46,7 +46,7 @@ class PrestaShopWebservice
|
||||
|
||||
/** @var array compatible versions of PrestaShop Webservice */
|
||||
const PSCOMPATIBLEVERSIONMIN = '1.4.0.0';
|
||||
const PSCOMPATIBLEVERSIONMAX = '1.6.99.99';
|
||||
const PSCOMPATIBLEVERSIONMAX = '1.7.99.99';
|
||||
|
||||
|
||||
/**
|
||||
@ -128,6 +128,7 @@ class PrestaShopWebservice
|
||||
CURLOPT_HTTPHEADER => array( 'Expect:' )
|
||||
);
|
||||
|
||||
dol_syslog("curl_init url=".$url);
|
||||
$session = curl_init($url);
|
||||
|
||||
$curl_options = array();
|
||||
@ -142,6 +143,7 @@ class PrestaShopWebservice
|
||||
if (!isset($curl_options[$defkey]))
|
||||
$curl_options[$defkey] = $curl_params[$defkey];
|
||||
|
||||
dol_syslog("curl curl_options = ".var_export($curl_options, true));
|
||||
curl_setopt_array($session, $curl_options);
|
||||
$response = curl_exec($session);
|
||||
|
||||
@ -309,7 +311,9 @@ class PrestaShopWebservice
|
||||
if (isset($options['id']))
|
||||
$url .= '/'.$options['id'];
|
||||
|
||||
$params = array('filter', 'display', 'sort', 'limit', 'id_shop', 'id_group_shop');
|
||||
// @CHANGE LDR
|
||||
//$params = array('filter', 'display', 'sort', 'limit', 'id_shop', 'id_group_shop');
|
||||
$params = array('filter', 'display', 'sort', 'limit', 'id_shop', 'id_group_shop', 'date');
|
||||
foreach ($params as $p)
|
||||
foreach ($options as $k => $o)
|
||||
if (strpos($k, $p) !== false)
|
||||
@ -388,6 +392,49 @@ class PrestaShopWebservice
|
||||
self::checkStatusCode($request['status_code']);// check the response validity
|
||||
return self::parseXML($request['response']);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete (DELETE) a resource.
|
||||
* Unique parameter must take : <br><br>
|
||||
* 'resource' => Resource name<br>
|
||||
* 'id' => ID or array which contains IDs of a resource(s) you want to delete<br><br>
|
||||
* <code>
|
||||
* <?php
|
||||
* require_once('./PrestaShopWebservice.php');
|
||||
* try
|
||||
* {
|
||||
* $ws = new PrestaShopWebservice('http://mystore.com/', 'ZQ88PRJX5VWQHCWE4EE7SQ7HPNX00RAJ', false);
|
||||
* $xml = $ws->delete(array('resource' => 'orders', 'id' => 1));
|
||||
* // Following code will not be executed if an exception is thrown.
|
||||
* echo 'Successfully deleted.';
|
||||
* }
|
||||
* catch (PrestaShopWebserviceException $ex)
|
||||
* {
|
||||
* echo 'Error : '.$ex->getMessage();
|
||||
* }
|
||||
* ?>
|
||||
* </code>
|
||||
*
|
||||
* @param array $options Array representing resource to delete.
|
||||
* @return boolean True
|
||||
*/
|
||||
public function delete($options)
|
||||
{
|
||||
if (isset($options['url']))
|
||||
$url = $options['url'];
|
||||
elseif (isset($options['resource']) && isset($options['id']))
|
||||
if (is_array($options['id']))
|
||||
$url = $this->url.'/api/'.$options['resource'].'/?id=['.implode(',', $options['id']).']';
|
||||
else
|
||||
$url = $this->url.'/api/'.$options['resource'].'/'.$options['id'];
|
||||
if (isset($options['id_shop']))
|
||||
$url .= '&id_shop='.$options['id_shop'];
|
||||
if (isset($options['id_group_shop']))
|
||||
$url .= '&id_group_shop='.$options['id_group_shop'];
|
||||
$request = self::executeRequest($url, array(CURLOPT_CUSTOMREQUEST => 'DELETE'));
|
||||
self::checkStatusCode($request['status_code']);// check the response validity
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -44,7 +44,6 @@ class Dolistore
|
||||
// setups
|
||||
public $url; // the url of this page
|
||||
public $shop_url; // the url of the shop
|
||||
public $vat_rate; // the vat rate used in the shop (prices are provided without vat)
|
||||
public $lang; // the integer representing the lang in the store
|
||||
public $debug_api; // usefull if no dialog
|
||||
|
||||
@ -60,12 +59,11 @@ class Dolistore
|
||||
|
||||
$this->url = DOL_URL_ROOT.'/admin/modules.php?mode=marketplace';
|
||||
$this->shop_url = 'https://www.dolistore.com/index.php?controller=product&id_product=';
|
||||
$this->vat_rate = 1.2; // 20% de TVA
|
||||
$this->debug_api = $debug;
|
||||
|
||||
$langtmp = explode('_', $langs->defaultlang);
|
||||
$lang = $langtmp[0];
|
||||
$lang_array = array('en'=>0, 'fr'=>1, 'es'=>2, 'it'=>3, 'de'=>4); // Into table ps_lang of Prestashop - 1
|
||||
$lang_array = array('en'=>1, 'fr'=>2, 'es'=>3, 'it'=>4, 'de'=>5); // Into table ps_lang of Prestashop - 1
|
||||
if (! in_array($lang, array_keys($lang_array))) $lang = 'en';
|
||||
$this->lang = $lang_array[$lang];
|
||||
}
|
||||
@ -74,12 +72,50 @@ class Dolistore
|
||||
* Load data from remote Dolistore market place.
|
||||
* This fills ->categories
|
||||
*
|
||||
* @param array $options Options
|
||||
* @return void
|
||||
*/
|
||||
public function getRemoteData($options = array('start' => 0, 'end' => 10, 'per_page' => 50, 'categorie' => 0))
|
||||
public function getRemoteCategories()
|
||||
{
|
||||
global $conf, $langs;
|
||||
global $conf;
|
||||
|
||||
try {
|
||||
$this->api = new PrestaShopWebservice($conf->global->MAIN_MODULE_DOLISTORE_API_SRV, $conf->global->MAIN_MODULE_DOLISTORE_API_KEY, $this->debug_api);
|
||||
dol_syslog("Call API with MAIN_MODULE_DOLISTORE_API_SRV = ".$conf->global->MAIN_MODULE_DOLISTORE_API_SRV);
|
||||
// $conf->global->MAIN_MODULE_DOLISTORE_API_KEY is for the login of basic auth. There is no password as it is public data.
|
||||
|
||||
// Here we set the option array for the Webservice : we want categories resources
|
||||
$opt = array();
|
||||
$opt['resource'] = 'categories';
|
||||
$opt['display'] = '[id,id_parent,nb_products_recursive,active,is_root_category,name,description]';
|
||||
$opt['sort'] = 'id_asc';
|
||||
|
||||
// Call
|
||||
dol_syslog("Call API with opt = ".var_export($opt, true));
|
||||
$xml = $this->api->get($opt);
|
||||
$this->categories = $xml->categories->children();
|
||||
} catch (PrestaShopWebserviceException $e) {
|
||||
// Here we are dealing with errors
|
||||
$trace = $e->getTrace();
|
||||
if ($trace[0]['args'][0] == 404) die('Bad ID');
|
||||
elseif ($trace[0]['args'][0] == 401) die('Bad auth key');
|
||||
else
|
||||
{
|
||||
print 'Can not access to '.$conf->global->MAIN_MODULE_DOLISTORE_API_SRV.'<br>';
|
||||
print $e->getMessage();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Load data from remote Dolistore market place.
|
||||
* This fills ->products
|
||||
*
|
||||
* @param array $options Options. If 'categorie' is defined, we filter products on this category id
|
||||
* @return void
|
||||
*/
|
||||
public function getRemoteProducts($options = array('start' => 0, 'end' => 10, 'per_page' => 50, 'categorie' => 0, 'search' => ''))
|
||||
{
|
||||
global $conf;
|
||||
|
||||
$this->start = $options['start'];
|
||||
$this->end = $options['end'];
|
||||
@ -103,25 +139,26 @@ class Dolistore
|
||||
|
||||
// make a search to limit the id returned.
|
||||
if ($this->search != '') {
|
||||
$opt2['url'] = $conf->global->MAIN_MODULE_DOLISTORE_API_SRV.'/api/search?query='.$this->search.'&language='.$this->lang;
|
||||
$opt2['url'] = $conf->global->MAIN_MODULE_DOLISTORE_API_SRV.'/api/search?query='.$this->search.'&language='.$this->lang; // It seems for search, key start with
|
||||
|
||||
// Call
|
||||
//var_dump($this->api);
|
||||
|
||||
dol_syslog("Call API with opt = ".var_export($opt, true));
|
||||
dol_syslog("Call API with opt2 = ".var_export($opt2, true));
|
||||
|
||||
$xml = $this->api->get($opt2);
|
||||
|
||||
$products = array();
|
||||
foreach ($xml->products->children() as $product) {
|
||||
$products[] = (int) $product['id'];
|
||||
}
|
||||
$opt['filter[id]'] = '['.implode('|', $products).']';
|
||||
} elseif ($this->categorie != 0) {
|
||||
} elseif ($this->categorie != 0) { // We filter on category, so we first get list of product id in this category
|
||||
// $opt2['url'] is set by default to $this->url.'/api/'.$options['resource'];
|
||||
$opt2['resource'] = 'categories';
|
||||
$opt2['id'] = $this->categorie;
|
||||
|
||||
// Call
|
||||
dol_syslog("Call API with opt2 = ".var_export($opt2, true));
|
||||
$xml = $this->api->get($opt2);
|
||||
|
||||
$products = array();
|
||||
foreach ($xml->category->associations->products->children() as $product) {
|
||||
$products[] = (int) $product->id;
|
||||
@ -134,22 +171,10 @@ class Dolistore
|
||||
$opt['limit'] = "$this->start,$this->end";
|
||||
// $opt['filter[id]'] contais list of product id that are result of search
|
||||
|
||||
|
||||
// Call API to get the detail
|
||||
dol_syslog("Call API with opt = ".var_export($opt, true));
|
||||
dol_syslog("Call API with opt2 = ".var_export($opt2, true));
|
||||
$xml = $this->api->get($opt);
|
||||
$this->products = $xml->products->children();
|
||||
|
||||
|
||||
// Here we set the option array for the Webservice : we want categories resources
|
||||
$opt = array();
|
||||
$opt['resource'] = 'categories';
|
||||
$opt['display'] = '[id,id_parent,nb_products_recursive,active,is_root_category,name,description]';
|
||||
$opt['sort'] = 'id_asc';
|
||||
// Call
|
||||
$xml = $this->api->get($opt);
|
||||
$this->categories = $xml->categories->children();
|
||||
} catch (PrestaShopWebserviceException $e) {
|
||||
// Here we are dealing with errors
|
||||
$trace = $e->getTrace();
|
||||
@ -186,15 +211,15 @@ class Dolistore
|
||||
$cat = $this->categories[$i];
|
||||
if ($cat->is_root_category == 1 && $parent == 0) {
|
||||
$html .= '<li class="root"><h3 class="nomargesupinf"><a class="nomargesupinf link2cat" href="?mode=marketplace&categorie='.$cat->id.'" '
|
||||
.'title="'.dol_escape_htmltag(strip_tags($cat->description->language[$this->lang])).'"'
|
||||
.'>'.$cat->name->language[$this->lang].' <sup>'.$cat->nb_products_recursive.'</sup></a></h3>';
|
||||
.'title="'.dol_escape_htmltag(strip_tags($cat->description->language[$this->lang - 1])).'"'
|
||||
.'>'.$cat->name->language[$this->lang - 1].' <sup>'.$cat->nb_products_recursive.'</sup></a></h3>';
|
||||
$html .= self::get_categories($cat->id);
|
||||
$html .= "</li>\n";
|
||||
} elseif (trim($cat->id_parent) == $parent && $cat->active == 1 && trim($cat->id_parent) != 0) { // si cat est de ce niveau
|
||||
$select = ($cat->id == $this->categorie) ? ' selected' : '';
|
||||
$html .= '<li><a class="link2cat'.$select.'" href="?mode=marketplace&categorie='.$cat->id.'"'
|
||||
.' title="'.dol_escape_htmltag(strip_tags($cat->description->language[$this->lang])).'" '
|
||||
.'>'.$cat->name->language[$this->lang].' <sup>'.$cat->nb_products_recursive.'</sup></a>';
|
||||
.' title="'.dol_escape_htmltag(strip_tags($cat->description->language[$this->lang - 1])).'" '
|
||||
.'>'.$cat->name->language[$this->lang - 1].' <sup>'.$cat->nb_products_recursive.'</sup></a>';
|
||||
$html .= self::get_categories($cat->id);
|
||||
$html .= "</li>\n";
|
||||
} else {
|
||||
@ -242,7 +267,7 @@ class Dolistore
|
||||
// add image or default ?
|
||||
if ($product->id_default_image != '') {
|
||||
$image_url = DOL_URL_ROOT.'/admin/dolistore/ajax/image.php?id_product='.$product->id.'&id_image='.$product->id_default_image;
|
||||
$images = '<a href="'.$image_url.'" class="fancybox" rel="gallery'.$product->id.'" title="'.$product->name->language[$this->lang].', '.$langs->trans('Version').' '.$product->module_version.'">'.
|
||||
$images = '<a href="'.$image_url.'" class="fancybox" rel="gallery'.$product->id.'" title="'.$product->name->language[$this->lang - 1].', '.$langs->trans('Version').' '.$product->module_version.'">'.
|
||||
'<img src="'.$image_url.'&quality=home_default" style="max-height:250px;max-width: 210px;" alt="" /></a>';
|
||||
} else {
|
||||
$images = '<img src="'.DOL_URL_ROOT.'/admin/dolistore/img/NoImageAvailable.png" />';
|
||||
@ -250,7 +275,7 @@ class Dolistore
|
||||
|
||||
// free or pay ?
|
||||
if ($product->price > 0) {
|
||||
$price = '<h3>'.price(round((float) $product->price * $this->vat_rate, 2)).' €</h3>';
|
||||
$price = '<h3>'.price(price2num($product->price, 'MT'), 0, $langs, 1, -1, -1, 'EUR').' '.$langs->trans("HT").'</h3>';
|
||||
$download_link = '<a target="_blank" href="'.$this->shop_url.$product->id.'"><img width="32" src="'.DOL_URL_ROOT.'/admin/dolistore/img/follow.png" /></a>';
|
||||
} else {
|
||||
$price = '<h3>'.$langs->trans('Free').'</h3>';
|
||||
@ -282,12 +307,12 @@ class Dolistore
|
||||
|
||||
//output template
|
||||
$html .= '<tr class="app '.$parity.' '.$compatible.'">
|
||||
<td align="center" width="210"><div class="newAppParent">'.$newapp.$images.'</div></td>
|
||||
<td class="margeCote"><h2 class="appTitle">'.$product->name->language[$this->lang]
|
||||
<td class="center" width="210"><div class="newAppParent">'.$newapp.$images.'</div></td>
|
||||
<td class="margeCote"><h2 class="appTitle">'.$product->name->language[$this->lang - 1]
|
||||
.'<br/><small>'.$version.'</small></h2>
|
||||
<small> '.dol_print_date(dol_stringtotime($product->date_upd), 'dayhour').' - '.$langs->trans('Ref').': '.$product->reference.' - '.$langs->trans('Id').': '.$product->id.'</small><br><br>'.$product->description_short->language[$this->lang].'</td>
|
||||
<td style="display:none;" class="long_description">'.$product->description->language[$this->lang].'</td>
|
||||
<td class="margeCote" align="center">'.$price.'
|
||||
<small> '.dol_print_date(dol_stringtotime($product->date_upd), 'dayhour').' - '.$langs->trans('Ref').': '.$product->reference.' - '.$langs->trans('Id').': '.$product->id.'</small><br><br>'.$product->description_short->language[$this->lang - 1].'</td>
|
||||
<td style="display:none;" class="long_description">'.$product->description->language[$this->lang - 1].'</td>
|
||||
<td class="margeCote center">'.$price.'
|
||||
</td>
|
||||
<td class="margeCote">'.$download_link.'</td>
|
||||
</tr>';
|
||||
|
||||
@ -67,7 +67,7 @@ foreach ($object->fields as $key => $val) {
|
||||
if (empty($action) && empty($id) && empty($ref)) $action='view';
|
||||
|
||||
// Load object
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once.
|
||||
|
||||
// Security check - Protection if external user
|
||||
//if ($user->societe_id > 0) access_forbidden();
|
||||
@ -75,6 +75,13 @@ include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be inclu
|
||||
//$isdraft = (($object->statut == MyObject::STATUS_DRAFT) ? 1 : 0);
|
||||
//$result = restrictedArea($user, 'mymodule', $object->id, '', '', 'fk_soc', 'rowid', $isdraft);
|
||||
|
||||
$permissionnote=$user->rights->emailcollector->write; // Used by the include of actions_setnotes.inc.php
|
||||
$permissiondellink=$user->rights->emailcollector->write; // Used by the include of actions_dellink.inc.php
|
||||
$permissionedit=$user->rights->emailcollector->write; // Used by the include of actions_lineupdown.inc.php
|
||||
$permissiontoadd=$user->rights->emailcollector->write; // Used by the include of actions_addupdatedelete.inc.php
|
||||
|
||||
$debuginfo='';
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
@ -97,7 +104,7 @@ if (empty($reshook))
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_addupdatedelete.inc.php';
|
||||
|
||||
// Actions when linking object each other
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_dellink.inc.php'; // Must be include, not include_once
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_dellink.inc.php';
|
||||
|
||||
// Actions when printing a doc from card
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_printing.inc.php';
|
||||
@ -178,14 +185,15 @@ if ($action == 'confirm_collect')
|
||||
dol_include_once('/emailcollector/class/emailcollector.class.php');
|
||||
|
||||
$res = $object->doCollectOneCollector();
|
||||
|
||||
if ($res > 0)
|
||||
{
|
||||
setEventMessages($object->output, null, 'mesgs');
|
||||
$debuginfo = $object->debuginfo;
|
||||
setEventMessages($object->lastresult, null, 'mesgs');
|
||||
}
|
||||
else
|
||||
{
|
||||
setEventMessages($object->error, null, 'errors');
|
||||
$debuginfo = $object->debuginfo;
|
||||
setEventMessages($object->error, null, 'errors');
|
||||
}
|
||||
|
||||
$action = '';
|
||||
@ -307,7 +315,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
if ($action == 'clone') {
|
||||
// Create an array for form
|
||||
$formquestion = array();
|
||||
$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('CloneMyObject'), $langs->trans('ConfirmCloneMyObject', $object->ref), 'confirm_clone', $formquestion, 'yes', 1);
|
||||
$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('ToClone'), $langs->trans('ConfirmCloneEmailCollector', $object->ref), 'confirm_clone', $formquestion, 'yes', 1);
|
||||
}
|
||||
|
||||
// Confirmation of action process
|
||||
@ -391,7 +399,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
$connectstringsource = $connectstringserver.imap_utf7_encode($sourcedir);
|
||||
$connectstringtarget = $connectstringserver.imap_utf7_encode($targetdir);
|
||||
|
||||
$connection = imap_open($connectstringsource, $object->user, $object->password);
|
||||
$connection = imap_open($connectstringsource, $object->login, $object->password);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -443,10 +451,46 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
// Add filter
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>';
|
||||
$arrayoftypes=array('from'=>'MailFrom', 'to'=>'MailTo', 'cc'=>'Cc', 'bcc'=>'Bcc', 'subject'=>'Subject', 'body'=>'Body', 'seen'=>'AlreadyRead', 'unseen'=>'NotRead', 'withtrackingid'=>'WithDolTrackingID', 'withouttrackingid'=>'WithoutDolTrackingID');
|
||||
print $form->selectarray('filtertype', $arrayoftypes, '', 1, 0, 0, '', 1);
|
||||
$arrayoftypes=array(
|
||||
'from'=>array('label'=>'MailFrom', 'data-placeholder'=>'SearchString'),
|
||||
'to'=>array('label'=>'MailTo', 'data-placeholder'=>'SearchString'),
|
||||
'cc'=>array('label'=>'Cc', 'data-placeholder'=>'SearchString'),
|
||||
'bcc'=>array('label'=>'Bcc', 'data-placeholder'=>'SearchString'),
|
||||
'subject'=>array('label'=>'Subject', 'data-placeholder'=>'SearchString'),
|
||||
'body'=>array('label'=>'Body', 'data-placeholder'=>'SearchString'),
|
||||
'header'=>array('label'=>'Header', 'data-placeholder'=>'HeaderKey SearchString'), // HEADER key value
|
||||
'X1'=>'---',
|
||||
'seen'=>array('label'=>'AlreadyRead', 'data-noparam'=>1),
|
||||
'unseen'=>array('label'=>'NotRead', 'data-noparam'=>1),
|
||||
'smaller'=>array('label'=>'SmallerThan', 'data-placeholder'=>'NumberOfBytes'),
|
||||
'larger'=>array('label'=>'LargerThan', 'data-placeholder'=>'NumberOfBytes'),
|
||||
'X2'=>'---',
|
||||
'withtrackingid'=>array('label'=>'WithDolTrackingID', 'data-noparam'=>1),
|
||||
'withouttrackingid'=>array('label'=>'WithoutDolTrackingID', 'data-noparam'=>1)
|
||||
);
|
||||
print $form->selectarray('filtertype', $arrayoftypes, '', 1, 0, 0, '', 1, 0, 0, '', '', 0, '', 2);
|
||||
|
||||
print "\n";
|
||||
print '<script>';
|
||||
print 'jQuery("#filtertype").change(function() {
|
||||
console.log("We change a filter");
|
||||
if (jQuery("#filtertype option:selected").attr("data-noparam")) {
|
||||
jQuery("#rulevalue").attr("placeholder", "");
|
||||
jQuery("#rulevalue").text(""); jQuery("#rulevalue").prop("disabled", true);
|
||||
}
|
||||
else { jQuery("#rulevalue").prop("disabled", false); }
|
||||
jQuery("#rulevalue").attr("placeholder", (jQuery("#filtertype option:selected").attr("data-placeholder")));
|
||||
';
|
||||
$noparam=array();
|
||||
foreach($arrayoftypes as $key => $value)
|
||||
{
|
||||
if ($value['noparam']) $noparam[]=$key;
|
||||
}
|
||||
print '})';
|
||||
print '</script>'."\n";
|
||||
|
||||
print '</td><td>';
|
||||
print '<input type="text" name="rulevalue">';
|
||||
print '<input type="text" name="rulevalue" id="rulevalue">';
|
||||
print '</td>';
|
||||
print '<td class="right"><input type="submit" name="addfilter" id="addfilter" class="flat button" value="'.$langs->trans("Add").'"></td>';
|
||||
print '</tr>';
|
||||
@ -458,11 +502,10 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>';
|
||||
print $langs->trans($arrayoftypes[$rulefilter['type']]);
|
||||
print $langs->trans($arrayoftypes[$rulefilter['type']]['label']);
|
||||
print '</td>';
|
||||
print '<td>'.$rulefilter['rulevalue'].'</td>';
|
||||
print '<td class="right">';
|
||||
//print $rulefilterobj->getLibStatut(3);
|
||||
print ' <a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=deletefilter&filterid='.$rulefilter['id'].'">'.img_delete().'</a>';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
@ -481,8 +524,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
// Add operation
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>';
|
||||
$arrayoftypes=array('loadthirdparty'=>'LoadThirdPartyFromName', 'loadandcreatethirdparty'=>'LoadThirdPartyFromNameOrCreate', 'recordevent'=>'RecordEvent');
|
||||
$arrayoftypes=array(
|
||||
'loadthirdparty'=>$langs->trans('LoadThirdPartyFromName', $langs->transnoentities("ThirdPartyName")),
|
||||
'loadandcreatethirdparty'=>$langs->trans('LoadThirdPartyFromNameOrCreate', $langs->transnoentities("ThirdPartyName")),
|
||||
'recordevent'=>'RecordEvent');
|
||||
if ($conf->projet->enabled) $arrayoftypes['project']='CreateLeadAndThirdParty';
|
||||
if ($conf->ticket->enabled) $arrayoftypes['ticket']='CreateTicketAndThirdParty';
|
||||
print $form->selectarray('operationtype', $arrayoftypes, '', 1, 0, 0, '', 1);
|
||||
print '</td><td>';
|
||||
print '<input type="text" name="operationparam">';
|
||||
@ -506,12 +553,13 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '<tr class="drag drop oddeven" id="row-'.$ruleaction['id'].'">';
|
||||
print '<td>';
|
||||
print $langs->trans($arrayoftypes[$ruleaction['type']]);
|
||||
if (in_array($ruleaction['type'], array('recordevent')))
|
||||
{
|
||||
print $form->textwithpicto('', $langs->transnoentitiesnoconv('IfTrackingIDFoundEventWillBeLinked'));
|
||||
}
|
||||
print '</td>';
|
||||
print '<td>'.$ruleaction['actionparam'].'</td>';
|
||||
print '<td class="right">';
|
||||
//print $ruleactionobj->getLibStatut(3);
|
||||
print ' <a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=deleteoperation&operationid='.$ruleaction['id'].'">'.img_delete().'</a>';
|
||||
print '</td>';
|
||||
// Move up/down
|
||||
print '<td class="center linecolmove tdlineupdown">';
|
||||
if ($i > 0)
|
||||
{
|
||||
@ -521,6 +569,10 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '<a class="lineupdown" href="'.$_SERVER['PHP_SELF'].'?action=down&rowid='.$ruleaction['id'].'">'.img_down('default', 0, 'imgdownforline').'</a>';
|
||||
}
|
||||
print '</td>';
|
||||
// Delete
|
||||
print '<td class="right">';
|
||||
print ' <a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=deleteoperation&operationid='.$ruleaction['id'].'">'.img_delete().'</a>';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
$i++;
|
||||
}
|
||||
@ -529,6 +581,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '</table>';
|
||||
|
||||
if (! empty($conf->use_javascript_ajax)) {
|
||||
$urltorefreshaftermove = DOL_URL_ROOT.'/admin/emailcollector_card.php?id='.$id;
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/ajaxrow.tpl.php';
|
||||
}
|
||||
|
||||
@ -560,6 +613,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '</div>' . "\n";
|
||||
}
|
||||
|
||||
if (! empty($debuginfo))
|
||||
{
|
||||
print info_admin($debuginfo);
|
||||
}
|
||||
|
||||
|
||||
// Select mail models is same action as presend
|
||||
if (GETPOST('modelselected')) {
|
||||
$action = 'presend';
|
||||
|
||||
@ -304,7 +304,7 @@ $arrayofmassactions = array(
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
if ($user->rights->emailcollector->delete) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
if ($user->rights->emailcollector->delete) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
if (GETPOST('nomassaction', 'int') || in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('', $arrayofmassactions);
|
||||
|
||||
@ -321,7 +321,7 @@ print '<input type="hidden" name="contextpage" value="'.$contextpage.'">';
|
||||
$newcardbutton='';
|
||||
//if ($user->rights->emailcollector->creer)
|
||||
//{
|
||||
$newcardbutton='<a class="butActionNew" href="emailcollector_card.php?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']).'"><span class="valignmiddle">'.$langs->trans('New').'</span>';
|
||||
$newcardbutton='<a class="butActionNew" href="emailcollector_card.php?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']).'"><span class="valignmiddle text-plus-circle">'.$langs->trans('New').'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
//}
|
||||
|
||||
@ -254,7 +254,7 @@ foreach ($dirmodels as $reldir)
|
||||
else print $tmp;
|
||||
print '</td>'."\n";
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($conf->global->EXPEDITION_ADDON_NUMBER == "$file")
|
||||
{
|
||||
print img_picto($langs->trans("Activated"), 'switch_on');
|
||||
@ -285,7 +285,7 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
}
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
print '</td>';
|
||||
|
||||
@ -336,10 +336,10 @@ print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td width="140">'.$langs->trans("Name").'</td>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Default").'</td>';
|
||||
print '<td align="center" width="80" class="nowrap">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td align="center" width="80" class="nowrap">'.$langs->trans("Preview").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Default").'</td>';
|
||||
print '<td class="nowrap center" width="80">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td class="nowrap center" width="80" >'.$langs->trans("Preview").'</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
clearstatcache();
|
||||
@ -391,7 +391,7 @@ foreach ($dirmodels as $reldir)
|
||||
// Active
|
||||
if (in_array($name, $def))
|
||||
{
|
||||
print '<td align="center">'."\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&value='.$name.'">';
|
||||
print img_picto($langs->trans("Enabled"), 'switch_on');
|
||||
print '</a>';
|
||||
@ -399,13 +399,13 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="center">'."\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&value='.$name.'&scan_dir='.$module->scandir.'&label='.urlencode($module->name).'">'.img_picto($langs->trans("Disabled"), 'switch_off').'</a>';
|
||||
print "</td>";
|
||||
}
|
||||
|
||||
// Defaut
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($conf->global->EXPEDITION_ADDON_PDF == $name)
|
||||
{
|
||||
print img_picto($langs->trans("Default"), 'on');
|
||||
@ -430,12 +430,12 @@ foreach ($dirmodels as $reldir)
|
||||
$htmltooltip.='<br>'.$langs->trans("MultiLanguage").': '.yn($module->option_multilang, 1, 1);
|
||||
$htmltooltip.='<br>'.$langs->trans("WatermarkOnDraftOrders").': '.yn($module->option_draft_watermark, 1, 1);
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
print '</td>';
|
||||
|
||||
// Preview
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($module->type == 'pdf')
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=specimen&module='.$name.'&scan_dir='.$module->scandir.'&label='.urlencode($module->name).'">'.img_object($langs->trans("Preview"), 'sending').'</a>';
|
||||
|
||||
@ -216,8 +216,8 @@ print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Name").'</td>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td class="nowrap">'.$langs->trans("Example").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td align="center" width="16">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td class="center" width="16">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '</tr>'."\n";
|
||||
|
||||
clearstatcache();
|
||||
@ -260,7 +260,7 @@ foreach ($dirmodels as $reldir)
|
||||
else print $tmp;
|
||||
print '</td>'."\n";
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($conf->global->EXPENSEREPORT_ADDON == $file)
|
||||
{
|
||||
print img_picto($langs->trans("Activated"), 'switch_on');
|
||||
@ -291,7 +291,7 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
}
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
print '</td>';
|
||||
|
||||
@ -339,10 +339,10 @@ print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Name").'</td>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Status")."</td>\n";
|
||||
print '<td align="center" width="60">'.$langs->trans("Default")."</td>\n";
|
||||
print '<td align="center" width="80">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td align="center" width="80">'.$langs->trans("Preview").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Status")."</td>\n";
|
||||
print '<td class="center" width="60">'.$langs->trans("Default")."</td>\n";
|
||||
print '<td class="center" width="80">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td class="center" width="80">'.$langs->trans("Preview").'</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
clearstatcache();
|
||||
@ -393,7 +393,7 @@ foreach ($dirmodels as $reldir)
|
||||
// Active
|
||||
if (in_array($name, $def))
|
||||
{
|
||||
print "<td align=\"center\">\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&value='.$name.'&scan_dir='.$module->scandir.'&label='.urlencode($module->name).'">';
|
||||
print img_picto($langs->trans("Enabled"), 'switch_on');
|
||||
print '</a>';
|
||||
@ -401,13 +401,13 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<td align=\"center\">\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&value='.$name.'&scan_dir='.$module->scandir.'&label='.urlencode($module->name).'">'.img_picto($langs->trans("Disabled"), 'switch_off').'</a>';
|
||||
print "</td>";
|
||||
}
|
||||
|
||||
// Default
|
||||
print "<td align=\"center\">";
|
||||
print '<td class="center">';
|
||||
if ($conf->global->EXPENSEREPORT_ADDON_PDF == "$name")
|
||||
{
|
||||
print img_picto($langs->trans("Default"), 'on');
|
||||
@ -428,12 +428,12 @@ foreach ($dirmodels as $reldir)
|
||||
$htmltooltip.='<br>'.$langs->trans("PaymentConditions").': '.yn($module->option_condreg, 1, 1);
|
||||
$htmltooltip.='<br>'.$langs->trans("MultiLanguage").': '.yn($module->option_multilang, 1, 1);
|
||||
$htmltooltip.='<br>'.$langs->trans("WatermarkOnDraftOrders").': '.yn($module->option_draft_watermark, 1, 1);
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, -1, 0);
|
||||
print '</td>';
|
||||
|
||||
// Preview
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($module->type == 'pdf')
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=specimen&module='.$name.'">'.img_object($langs->trans("Preview"), 'intervention').'</a>';
|
||||
@ -472,7 +472,7 @@ print load_fiche_titre($langs->trans("OtherOptions"), '', '');
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Parameter").'</td>';
|
||||
print '<td align="center" width="60"></td>';
|
||||
print '<td class="center" width="60"></td>';
|
||||
print "</tr>\n";
|
||||
|
||||
$substitutionarray=pdf_getSubstitutionArray($langs, null, null, 2);
|
||||
|
||||
@ -51,48 +51,52 @@ include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php';
|
||||
* View
|
||||
*/
|
||||
|
||||
$form=new Form($db);
|
||||
|
||||
$page_name = "ExportSetup";
|
||||
llxHeader('', $langs->trans($page_name));
|
||||
|
||||
// Subheader
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">'
|
||||
. $langs->trans("BackToModuleList") . '</a>';
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
|
||||
print load_fiche_titre($langs->trans($page_name), $linkback);
|
||||
|
||||
// Configuration header
|
||||
//$head = export_admin_prepare_head();
|
||||
$h=0;
|
||||
$head = array();
|
||||
$head[$h][0] = DOL_URL_ROOT.'/admin/export.php';
|
||||
$head[$h][1] = $langs->trans("Setup");
|
||||
$head[$h][2] = 'setup';
|
||||
$h++;
|
||||
|
||||
dol_fiche_head(
|
||||
$head,
|
||||
'settings',
|
||||
$langs->trans("ExportsArea"),
|
||||
0,
|
||||
"exports"
|
||||
);
|
||||
dol_fiche_head($head, 'setup', $langs->trans("ExportsArea"), -1, "exports");
|
||||
|
||||
// Setup page goes here
|
||||
$form=new Form($db);
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("ExportModel").'</td>'."\n";
|
||||
print '<td align="center" width="20"> </td>';
|
||||
print '<td align="center" width="100"></td>'."\n";
|
||||
print '<td>'.$langs->trans("Parameters").'</td>'."\n";
|
||||
print '<td class="center" width="20"> </td>';
|
||||
print '<td class="center" width="100"></td>'."\n";
|
||||
|
||||
|
||||
// Example with a yes / no select
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$langs->trans("set_EXPORTS_SHARE_MODELS").'</td>';
|
||||
print '<td align="center" width="20"> </td>';
|
||||
print '<td align="center" width="100">';
|
||||
print '<td>'.$langs->trans("EXPORTS_SHARE_MODELS").'</td>';
|
||||
print '<td class="center" width="20"> </td>';
|
||||
print '<td class="center" width="100">';
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<input type="hidden" name="action" value="set_EXPORTS_SHARE_MODELS">';
|
||||
echo ajax_constantonoff('EXPORTS_SHARE_MODELS');
|
||||
print '</form>';
|
||||
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
|
||||
@ -77,8 +77,7 @@ if ($action == 'updateMask')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'specimen')
|
||||
elseif ($action == 'specimen')
|
||||
{
|
||||
$modele=GETPOST('module', 'alpha');
|
||||
|
||||
@ -122,7 +121,6 @@ if ($action == 'specimen')
|
||||
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
|
||||
}
|
||||
}
|
||||
|
||||
// Activate a model
|
||||
elseif ($action == 'set')
|
||||
{
|
||||
@ -137,7 +135,6 @@ elseif ($action == 'del')
|
||||
if ($conf->global->FACTURE_ADDON_PDF == "$value") dolibarr_del_const($db, 'FACTURE_ADDON_PDF', $conf->entity);
|
||||
}
|
||||
}
|
||||
|
||||
// Set default model
|
||||
elseif ($action == 'setdoc')
|
||||
{
|
||||
@ -155,7 +152,6 @@ elseif ($action == 'setdoc')
|
||||
$ret = addDocumentModel($value, $type, $label, $scandir);
|
||||
}
|
||||
}
|
||||
|
||||
elseif ($action == 'setmod')
|
||||
{
|
||||
// TODO Verifier si module numerotation choisi peut etre active
|
||||
@ -163,8 +159,7 @@ elseif ($action == 'setmod')
|
||||
|
||||
dolibarr_set_const($db, "FACTURE_ADDON", $value, 'chaine', 0, '', $conf->entity);
|
||||
}
|
||||
|
||||
if ($action == 'setribchq')
|
||||
elseif ($action == 'setribchq')
|
||||
{
|
||||
$rib = GETPOST('rib', 'alpha');
|
||||
$chq = GETPOST('chq', 'alpha');
|
||||
@ -183,8 +178,7 @@ if ($action == 'setribchq')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'set_FACTURE_DRAFT_WATERMARK')
|
||||
elseif ($action == 'set_FACTURE_DRAFT_WATERMARK')
|
||||
{
|
||||
$draft = GETPOST('FACTURE_DRAFT_WATERMARK', 'alpha');
|
||||
|
||||
@ -202,7 +196,7 @@ if ($action == 'set_FACTURE_DRAFT_WATERMARK')
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'set_INVOICE_FREE_TEXT')
|
||||
elseif ($action == 'set_INVOICE_FREE_TEXT')
|
||||
{
|
||||
$freetext = GETPOST('INVOICE_FREE_TEXT', 'none'); // No alpha here, we want exact string
|
||||
|
||||
@ -219,8 +213,7 @@ if ($action == 'set_INVOICE_FREE_TEXT')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'setforcedate')
|
||||
elseif ($action == 'setforcedate')
|
||||
{
|
||||
$forcedate = GETPOST('forcedate', 'alpha');
|
||||
|
||||
@ -237,8 +230,7 @@ if ($action == 'setforcedate')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'setDefaultPDFModulesByType')
|
||||
elseif ($action == 'setDefaultPDFModulesByType')
|
||||
{
|
||||
$invoicetypemodels = GETPOST('invoicetypemodels');
|
||||
|
||||
@ -292,8 +284,8 @@ print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Name").'</td>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td class="nowrap">'.$langs->trans("Example").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td align="center" width="16">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td class="center" width="16">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '</tr>'."\n";
|
||||
|
||||
clearstatcache();
|
||||
@ -352,7 +344,7 @@ foreach ($dirmodels as $reldir)
|
||||
else print $tmp;
|
||||
print '</td>'."\n";
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
//print "> ".$conf->global->FACTURE_ADDON." - ".$file;
|
||||
if ($conf->global->FACTURE_ADDON == $file || $conf->global->FACTURE_ADDON.'.php' == $file)
|
||||
{
|
||||
@ -423,7 +415,7 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
}
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
|
||||
if ($conf->global->FACTURE_ADDON.'.php' == $file) // If module is the one used, we show existing errors
|
||||
@ -480,10 +472,10 @@ print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Name").'</td>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Default").'</td>';
|
||||
print '<td align="center" width="32">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td align="center" width="32">'.$langs->trans("Preview").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Status").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Default").'</td>';
|
||||
print '<td class="center" width="32">'.$langs->trans("ShortInfo").'</td>';
|
||||
print '<td class="center" width="32">'.$langs->trans("Preview").'</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
clearstatcache();
|
||||
@ -536,7 +528,7 @@ foreach ($dirmodels as $reldir)
|
||||
// Active
|
||||
if (in_array($name, $def))
|
||||
{
|
||||
print '<td align="center">'."\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&value='.$name.'">';
|
||||
print img_picto($langs->trans("Enabled"), 'switch_on');
|
||||
print '</a>';
|
||||
@ -544,13 +536,13 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<td align=\"center\">\n";
|
||||
print '<td class="center">'."\n";
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&value='.$name.'&scan_dir='.$module->scandir.'&label='.urlencode($module->name).'">'.img_picto($langs->trans("SetAsDefault"), 'switch_off').'</a>';
|
||||
print "</td>";
|
||||
}
|
||||
|
||||
// Defaut
|
||||
print "<td align=\"center\">";
|
||||
print '<td class="center">';
|
||||
if ($conf->global->FACTURE_ADDON_PDF == "$name")
|
||||
{
|
||||
print img_picto($langs->trans("Default"), 'on');
|
||||
@ -578,12 +570,12 @@ foreach ($dirmodels as $reldir)
|
||||
$htmltooltip.='<br>'.$langs->trans("WatermarkOnDraftInvoices").': '.yn($module->option_draft_watermark, 1, 1);
|
||||
|
||||
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
print $form->textwithpicto('', $htmltooltip, 1, 0);
|
||||
print '</td>';
|
||||
|
||||
// Preview
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if ($module->type == 'pdf')
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=specimen&module='.$name.'">'.img_object($langs->trans("Preview"), 'bill').'</a>';
|
||||
@ -750,7 +742,7 @@ print load_fiche_titre($langs->trans("OtherOptions"), '', '');
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Parameter").'</td>';
|
||||
print '<td align="center" width="60">'.$langs->trans("Value").'</td>';
|
||||
print '<td class="center" width="60">'.$langs->trans("Value").'</td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -760,7 +752,7 @@ print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'" />';
|
||||
print '<input type="hidden" name="action" value="setforcedate" />';
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $langs->trans("ForceInvoiceDate");
|
||||
print '</td><td width="60" align="center">';
|
||||
print '</td><td width="60" class="center">';
|
||||
print $form->selectyesno("forcedate", $conf->global->FAC_FORCE_DATE_VALIDATION, 1);
|
||||
print '</td><td class="right">';
|
||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'" />';
|
||||
@ -836,7 +828,7 @@ print load_fiche_titre($langs->trans("Notifications"), '', '');
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Parameter").'</td>';
|
||||
print '<td align="center" width="60"></td>';
|
||||
print '<td class="center" width="60"></td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
|
||||
@ -109,7 +109,7 @@ if (GETPOST('save', 'alpha'))
|
||||
} else {
|
||||
$error ++;
|
||||
}
|
||||
|
||||
|
||||
$fckeditor_test = GETPOST('formtestfield');
|
||||
if (! empty($fckeditor_test)) {
|
||||
if (! dolibarr_set_const($db, 'FCKEDITOR_TEST', $fckeditor_test, 'chaine', 0, '', $conf->entity)) {
|
||||
@ -148,7 +148,7 @@ else
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td colspan="2">'.$langs->trans("ActivateFCKeditor").'</td>';
|
||||
print '<td align="center" width="100">'.$langs->trans("Action").'</td>';
|
||||
print '<td class="center" width="100">'.$langs->trans("Action").'</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
// Modules
|
||||
@ -156,11 +156,11 @@ else
|
||||
{
|
||||
// Si condition non remplie, on ne propose pas l'option
|
||||
if (! $conditions[$const]) continue;
|
||||
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td width="16">'.img_object("", $picto[$const]).'</td>';
|
||||
print '<td>'.$langs->trans($desc).'</td>';
|
||||
print '<td align="center" width="100">';
|
||||
print '<td class="center" width="100">';
|
||||
$constante = 'FCKEDITOR_ENABLE_'.$const;
|
||||
$value = (isset($conf->global->$constante)?$conf->global->$constante:0);
|
||||
if ($value == 0)
|
||||
@ -181,12 +181,12 @@ else
|
||||
print '<br>'."\n";
|
||||
|
||||
print '<form name="formtest" method="POST" action="'.$_SERVER["PHP_SELF"].'">'."\n";
|
||||
|
||||
|
||||
// Skins
|
||||
show_skin(null, 1);
|
||||
print '<br>'."\n";
|
||||
|
||||
$listofmodes=array('dolibarr_mailings','dolibarr_notes','dolibarr_details','dolibarr_readonly','Full');
|
||||
|
||||
$listofmodes=array('dolibarr_mailings', 'dolibarr_notes', 'dolibarr_details', 'dolibarr_readonly', 'Full', 'Full_inline');
|
||||
$linkstomode='';
|
||||
foreach($listofmodes as $newmode)
|
||||
{
|
||||
@ -200,10 +200,19 @@ else
|
||||
$linkstomode.='';
|
||||
print load_fiche_titre($langs->trans("TestSubmitForm"), $linkstomode, '');
|
||||
print '<input type="hidden" name="mode" value="'.dol_escape_htmltag($mode).'">';
|
||||
$uselocalbrowser=true;
|
||||
$readonly=($mode=='dolibarr_readonly'?1:0);
|
||||
$editor=new DolEditor('formtestfield', isset($conf->global->FCKEDITOR_TEST)?$conf->global->FCKEDITOR_TEST:'Test', '', 200, $mode, 'In', true, $uselocalbrowser, 1, 120, 8, $readonly);
|
||||
$editor->Create();
|
||||
if ($mode != 'Full_inline')
|
||||
{
|
||||
$uselocalbrowser=true;
|
||||
$readonly=($mode=='dolibarr_readonly'?1:0);
|
||||
$editor=new DolEditor('formtestfield', isset($conf->global->FCKEDITOR_TEST)?$conf->global->FCKEDITOR_TEST:'Test', '', 200, $mode, 'In', true, $uselocalbrowser, 1, 120, 8, $readonly);
|
||||
$editor->Create();
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<div style="border: 1px solid #888;" contenteditable="true">';
|
||||
print $conf->global->FCKEDITOR_TEST;
|
||||
print '</div>';
|
||||
}
|
||||
print '<br><div class="center"><input class="button" type="submit" name="save" value="'.$langs->trans("Save").'"></div>'."\n";
|
||||
print '<div id="divforlog"></div>';
|
||||
print '</form>'."\n";
|
||||
|
||||
@ -131,15 +131,17 @@ if ($action == 'update')
|
||||
if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_TEXTLINK', $conf->entity);
|
||||
else dolibarr_set_const($db, 'THEME_ELDY_TEXTLINK', $val, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
if (GETPOST('THEME_ELDY_USE_HOVER') == '') dolibarr_set_const($db, "THEME_ELDY_USE_HOVER", '0', 'chaine', 0, '', $conf->entity); // If empty, we set to '0' ('000000' is for black)
|
||||
else dolibarr_set_const($db, "THEME_ELDY_USE_HOVER", $_POST["THEME_ELDY_USE_HOVER"], 'chaine', 0, '', $conf->entity);
|
||||
$val=(implode(',', (colorStringToArray(GETPOST('THEME_ELDY_USE_HOVER'), array()))));
|
||||
if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_USE_HOVER', $conf->entity);
|
||||
else dolibarr_set_const($db, "THEME_ELDY_USE_HOVER", $val, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
if (GETPOST('THEME_ELDY_USE_CHECKED') == '') dolibarr_set_const($db, "THEME_ELDY_USE_CHECKED", '0', 'chaine', 0, '', $conf->entity);
|
||||
else dolibarr_set_const($db, "THEME_ELDY_USE_CHECKED", $_POST["THEME_ELDY_USE_CHECKED"], 'chaine', 0, '', $conf->entity);
|
||||
$val=(implode(',', (colorStringToArray(GETPOST('THEME_ELDY_USE_CHECKED'), array()))));
|
||||
if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_USE_CHECKED', $conf->entity);
|
||||
else dolibarr_set_const($db, "THEME_ELDY_USE_CHECKED", $val, '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_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_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);
|
||||
dolibarr_set_const($db, "MAIN_DEFAULT_WORKING_DAYS", $_POST["MAIN_DEFAULT_WORKING_DAYS"], 'chaine', 0, '', $conf->entity);
|
||||
@ -217,7 +219,7 @@ $formadmin=new FormAdmin($db);
|
||||
|
||||
print load_fiche_titre($langs->trans("GUISetup"), '', 'title_setup');
|
||||
|
||||
print $langs->trans("DisplayDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("DisplayDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
|
||||
@ -239,14 +241,14 @@ if ($action == 'edit') // Edit
|
||||
print '</tr>';
|
||||
|
||||
// Default language
|
||||
print '<tr><td class="titlefield">'.$langs->trans("DefaultLanguage").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DefaultLanguage").'</td><td>';
|
||||
print $formadmin->select_language($conf->global->MAIN_LANG_DEFAULT, 'MAIN_LANG_DEFAULT', 1, 0, 0, 0, 0, 'minwidth300', 2);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Multilingual GUI
|
||||
print '<tr><td class="titlefield">'.$langs->trans("EnableMultilangInterface").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("EnableMultilangInterface").'</td><td>';
|
||||
print $form->selectyesno('MAIN_MULTILANGS', $conf->global->MAIN_MULTILANGS, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
@ -259,18 +261,25 @@ if ($action == 'edit') // Edit
|
||||
print '<br>';
|
||||
|
||||
// Other
|
||||
print '<table summary="edit" class="noborder" width="100%">';
|
||||
print '<table summary="otherparameters" class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td class="titlefield">'.$langs->trans("Parameters").'</td><td>'.$langs->trans("Value").'</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Disable javascript and ajax
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DisableJavascript").'</td><td>';
|
||||
print $form->selectyesno('MAIN_DISABLE_JAVASCRIPT', isset($conf->global->MAIN_DISABLE_JAVASCRIPT)?$conf->global->MAIN_DISABLE_JAVASCRIPT:0, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Max size of lists
|
||||
print '<tr><td>'.$langs->trans("DefaultMaxSizeList").'</td><td><input class="flat" name="main_size_liste_limit" size="4" value="' . $conf->global->MAIN_SIZE_LISTE_LIMIT . '"></td>';
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DefaultMaxSizeList").'</td><td><input class="flat" name="main_size_liste_limit" size="4" value="' . $conf->global->MAIN_SIZE_LISTE_LIMIT . '"></td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Max size of short lists on customer card
|
||||
print '<tr><td>'.$langs->trans("DefaultMaxSizeShortList").'</td><td><input class="flat" name="main_size_shortliste_limit" size="4" value="' . $conf->global->MAIN_SIZE_SHORTLIST_LIMIT . '"></td>';
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DefaultMaxSizeShortList").'</td><td><input class="flat" name="main_size_shortliste_limit" size="4" value="' . $conf->global->MAIN_SIZE_SHORTLIST_LIMIT . '"></td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
@ -283,36 +292,29 @@ if ($action == 'edit') // Edit
|
||||
print '</tr>';
|
||||
*/
|
||||
|
||||
// Disable javascript and ajax
|
||||
print '<tr><td>'.$langs->trans("DisableJavascript").'</td><td>';
|
||||
print $form->selectyesno('main_disable_javascript', isset($conf->global->MAIN_DISABLE_JAVASCRIPT)?$conf->global->MAIN_DISABLE_JAVASCRIPT:0, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// First day for weeks
|
||||
print '<tr><td class="titlefield">'.$langs->trans("WeekStartOnDay").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("WeekStartOnDay").'</td><td>';
|
||||
print $formother->select_dayofweek((isset($conf->global->MAIN_START_WEEK)?$conf->global->MAIN_START_WEEK:'1'), 'MAIN_START_WEEK', 0);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// DefaultWorkingDays
|
||||
print '<tr><td class="titlefield">'.$langs->trans("DefaultWorkingDays").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DefaultWorkingDays").'</td><td>';
|
||||
print '<input type="text" name="MAIN_DEFAULT_WORKING_DAYS" size="5" value="'.(isset($conf->global->MAIN_DEFAULT_WORKING_DAYS)?$conf->global->MAIN_DEFAULT_WORKING_DAYS:'1-5').'">';
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// DefaultWorkingHours
|
||||
print '<tr><td class="titlefield">'.$langs->trans("DefaultWorkingHours").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DefaultWorkingHours").'</td><td>';
|
||||
print '<input type="text" name="MAIN_DEFAULT_WORKING_HOURS" size="5" value="'.(isset($conf->global->MAIN_DEFAULT_WORKING_HOURS)?$conf->global->MAIN_DEFAULT_WORKING_HOURS:'9-18').'">';
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Firstname/Name
|
||||
print '<tr><td class="titlefield">'.$langs->trans("FirstnameNamePosition").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("FirstnameNamePosition").'</td><td>';
|
||||
$array=array(0=>$langs->trans("Firstname").' '.$langs->trans("Lastname"), 1=>$langs->trans("Lastname").' '.$langs->trans("Firstname"));
|
||||
print $form->selectarray('MAIN_FIRSTNAME_NAME_POSITION', $array, (isset($conf->global->MAIN_FIRSTNAME_NAME_POSITION)?$conf->global->MAIN_FIRSTNAME_NAME_POSITION:0));
|
||||
print '</td>';
|
||||
@ -320,14 +322,14 @@ if ($action == 'edit') // Edit
|
||||
print '</tr>';
|
||||
|
||||
// Hide unauthorized button
|
||||
print '<tr><td class="titlefield">'.$langs->trans("ButtonHideUnauthorized").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("ButtonHideUnauthorized").'</td><td>';
|
||||
print $form->selectyesno('MAIN_BUTTON_HIDE_UNAUTHORIZED', isset($conf->global->MAIN_BUTTON_HIDE_UNAUTHORIZED)?$conf->global->MAIN_BUTTON_HIDE_UNAUTHORIZED:0, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Show logo
|
||||
print '<tr><td class="titlefield">'.$langs->trans("EnableShowLogo").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("EnableShowLogo").'</td><td>';
|
||||
print $form->selectyesno('MAIN_SHOW_LOGO', $conf->global->MAIN_SHOW_LOGO, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
@ -344,7 +346,7 @@ if ($action == 'edit') // Edit
|
||||
*/
|
||||
|
||||
// Show bugtrack link
|
||||
print '<tr><td class="titlefield">'.$langs->trans("ShowBugTrackLink", $langs->transnoentitiesnoconv("FindBug")).'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("ShowBugTrackLink", $langs->transnoentitiesnoconv("FindBug")).'</td><td>';
|
||||
print $form->selectyesno('MAIN_BUGTRACK_ENABLELINK', $conf->global->MAIN_BUGTRACK_ENABLELINK, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
@ -352,7 +354,7 @@ if ($action == 'edit') // Edit
|
||||
|
||||
// Hide wiki link on login page
|
||||
$pictohelp='<span class="fa fa-question-circle"></span>';
|
||||
print '<tr><td class="titlefield">'.$langs->trans("DisableLinkToHelp", $pictohelp).'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DisableLinkToHelp", $pictohelp).'</td><td>';
|
||||
print $form->selectyesno('MAIN_HELP_DISABLELINK', isset($conf->global->MAIN_HELP_DISABLELINK)?$conf->global->MAIN_HELP_DISABLELINK:0, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
@ -362,7 +364,7 @@ if ($action == 'edit') // Edit
|
||||
$substitutionarray=getCommonSubstitutionArray($langs, 0, array('object','objectamount'));
|
||||
complete_substitutions_array($substitutionarray, $langs);
|
||||
|
||||
print '<tr><td class="titlefield">';
|
||||
print '<tr class="oddeven"><td class="titlefield">';
|
||||
$texthelp=$langs->trans("FollowingConstantsWillBeSubstituted").'<br>';
|
||||
foreach($substitutionarray as $key => $val)
|
||||
{
|
||||
@ -390,7 +392,7 @@ if ($action == 'edit') // Edit
|
||||
// Message on login page
|
||||
$substitutionarray=getCommonSubstitutionArray($langs, 0, array('object','objectamount','user'));
|
||||
complete_substitutions_array($substitutionarray, $langs);
|
||||
print '<tr><td>';
|
||||
print '<tr class="oddeven"><td>';
|
||||
$texthelp=$langs->trans("FollowingConstantsWillBeSubstituted").'<br>';
|
||||
foreach($substitutionarray as $key => $val)
|
||||
{
|
||||
@ -403,14 +405,14 @@ if ($action == 'edit') // Edit
|
||||
print '</td></tr>'."\n";
|
||||
|
||||
// Hide helpcenter link on login page
|
||||
print '<tr><td class="titlefield">'.$langs->trans("DisableLinkToHelpCenter").'</td><td>';
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DisableLinkToHelpCenter").'</td><td>';
|
||||
print $form->selectyesno('MAIN_HELPCENTER_DISABLELINK', isset($conf->global->MAIN_HELPCENTER_DISABLELINK)?$conf->global->MAIN_HELPCENTER_DISABLELINK:0, 1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
// Background
|
||||
print '<tr><td><label for="imagebackground">'.$langs->trans("BackgroundImageLogin").' (png,jpg)</label></td><td colspan="2">';
|
||||
print '<tr class="oddeven"><td><label for="imagebackground">'.$langs->trans("BackgroundImageLogin").' (png,jpg)</label></td><td colspan="2">';
|
||||
print '<div class="centpercent inline-block">';
|
||||
print '<input type="file" class="flat class=minwidth200" name="imagebackground" id="imagebackground">';
|
||||
if (! empty($conf->global->MAIN_LOGIN_BACKGROUND)) {
|
||||
@ -468,17 +470,21 @@ else // Show
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td class="titlefield">'.$langs->trans("Parameters").'</td><td>'.$langs->trans("Value").'</td></tr>';
|
||||
|
||||
// Disable javascript/ajax
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DisableJavascript").'</td><td>';
|
||||
print yn($conf->global->MAIN_DISABLE_JAVASCRIPT);
|
||||
print ' <span class="opacitymedium"> - '.$langs->trans("DisableJavascriptNote").'</span>';
|
||||
print "</td>";
|
||||
print "</tr>";
|
||||
|
||||
// Max size of lists
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DefaultMaxSizeList").'</td><td>' . $conf->global->MAIN_SIZE_LISTE_LIMIT . '</td>';
|
||||
print "</tr>";
|
||||
|
||||
// Max size of short lists
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DefaultMaxSizeShortList").'</td><td>' . $conf->global->MAIN_SIZE_SHORTLIST_LIMIT . '</td>';
|
||||
print "</tr>";
|
||||
|
||||
// Disable javascript/ajax
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("DisableJavascript").'</td><td>';
|
||||
print yn($conf->global->MAIN_DISABLE_JAVASCRIPT)."</td>";
|
||||
print "</tr>";
|
||||
|
||||
// First day for weeks
|
||||
print '<tr class="oddeven"><td class="titlefield">'.$langs->trans("WeekStartOnDay").'</td><td>';
|
||||
print $langs->trans("Day".(isset($conf->global->MAIN_START_WEEK)?$conf->global->MAIN_START_WEEK:'1'));
|
||||
|
||||
@ -37,11 +37,11 @@ $hookmanager->initHooks(array('homesetup'));
|
||||
* View
|
||||
*/
|
||||
|
||||
$form = new Form($db);
|
||||
|
||||
$wikihelp='EN:First_setup|FR:Premiers_paramétrages|ES:Primeras_configuraciones';
|
||||
llxHeader('', $langs->trans("Setup"), $wikihelp);
|
||||
|
||||
$form = new Form($db);
|
||||
|
||||
|
||||
print load_fiche_titre($langs->trans("SetupArea"), '', 'title_setup.png');
|
||||
|
||||
@ -68,7 +68,7 @@ if (! empty($conf->global->MAIN_MOTD_SETUPPAGE))
|
||||
}
|
||||
}
|
||||
|
||||
print $langs->trans("SetupDescription1").' ';
|
||||
print $langs->trans("SetupDescription1");
|
||||
print $langs->trans("AreaForAdminOnly").' ';
|
||||
print $langs->trans("SetupDescription2", $langs->transnoentities("MenuCompanySetup"), $langs->transnoentities("Modules"))."<br><br>";
|
||||
|
||||
@ -100,8 +100,8 @@ print '<br>'.$moreinfo;
|
||||
if (count($conf->modules) <= (empty($conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING)?1:$conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING)) // If only user module enabled
|
||||
{
|
||||
$langs->load("errors");
|
||||
$warnpicto=img_warning($langs->trans("WarningMandatorySetupNotComplete"), 'style="padding-right: 6px;"');
|
||||
print '<br><div class="warning"><a href="'.DOL_URL_ROOT.'/admin/modules.php?mainmenu=home">'.$warnpicto.$langs->trans("WarningMandatorySetupNotComplete").'</a></div>';
|
||||
$warnpicto=img_warning($langs->trans("WarningEnableYourModulesApplications"), 'style="padding-right: 6px;"');
|
||||
print '<br><div class="warning"><a href="'.DOL_URL_ROOT.'/admin/modules.php?mainmenu=home">'.$warnpicto.$langs->trans("WarningEnableYourModulesApplications").'</a></div>';
|
||||
}
|
||||
print '<br>';
|
||||
print '<br>';
|
||||
@ -115,7 +115,7 @@ print $hookmanager->resPrint;
|
||||
if (empty($reshook))
|
||||
{
|
||||
// Show into other
|
||||
print $langs->trans("SetupDescription5")."<br>";
|
||||
print '<span class="opacitymedium">'.$langs->trans("SetupDescription5")."</span><br>";
|
||||
print "<br>";
|
||||
|
||||
// Show logo
|
||||
|
||||
@ -291,7 +291,7 @@ $arrayofmassactions = array(
|
||||
//'presend'=>$langs->trans("SendByMail"),
|
||||
//'builddoc'=>$langs->trans("PDFMerge"),
|
||||
);
|
||||
if ($user->rights->monmodule->delete) $arrayofmassactions['predelete']=$langs->trans("Delete");
|
||||
if ($user->rights->monmodule->delete) $arrayofmassactions['predelete']='<span class="fa fa-trash paddingrightonly"></span>'.$langs->trans("Delete");
|
||||
if (in_array($massaction, array('presend','predelete'))) $arrayofmassactions=array();
|
||||
$massactionbutton=$form->selectMassAction('', $arrayofmassactions);
|
||||
|
||||
|
||||
@ -155,7 +155,7 @@ print '<input type="hidden" name="action" value="update">';
|
||||
|
||||
dol_fiche_head($head, 'handler', $langs->trans("Menus"), -1);
|
||||
|
||||
print $langs->trans("MenusDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("MenusDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
|
||||
|
||||
@ -237,7 +237,7 @@ $h++;
|
||||
|
||||
dol_fiche_head($head, 'editor', $langs->trans("Menus"), -1);
|
||||
|
||||
print $langs->trans("MenusEditorDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("MenusEditorDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
|
||||
@ -256,7 +256,7 @@ if ($action == 'delete')
|
||||
$newcardbutton='';
|
||||
if ($user->admin)
|
||||
{
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/admin/menus/edit.php?menuId=0&action=create&menu_handler='.urlencode($menu_handler).'&backtopage='.urlencode($_SERVER['PHP_SELF']).'"><span class="valignmiddle">'.$langs->trans('New').'</span>';
|
||||
$newcardbutton='<a class="butActionNew" href="'.DOL_URL_ROOT.'/admin/menus/edit.php?menuId=0&action=create&menu_handler='.urlencode($menu_handler).'&backtopage='.urlencode($_SERVER['PHP_SELF']).'"><span class="valignmiddle text-plus-circle">'.$langs->trans('New').'</span>';
|
||||
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton.= '</a>';
|
||||
}
|
||||
|
||||
@ -84,13 +84,13 @@ dol_fiche_head($head, 'misc', $langs->trans("Menus"), -1);
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td colspan="3">'.$langs->trans("Parameters").'</td>';
|
||||
print '<td align="center" width="80">'.$langs->trans("Status").'</td>';
|
||||
print '<td class="center" width="80">'.$langs->trans("Status").'</td>';
|
||||
print '</tr>';
|
||||
|
||||
// Hide unauthorized menu
|
||||
print '<tr class="oddeven">';
|
||||
print '<td colspan="3">'.$langs->trans("HideUnauthorizedMenu").'</td>';
|
||||
print '<td align="center">';
|
||||
print '<td class="center">';
|
||||
if (empty($conf->global->MAIN_MENU_HIDE_UNAUTHORIZED))
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=activate_hidemenu">'.img_picto($langs->trans("Disabled"), 'switch_off').'</a>';
|
||||
|
||||
@ -888,7 +888,8 @@ if ($mode == 'marketplace')
|
||||
{
|
||||
// $options is array with filter criterias
|
||||
//var_dump($options);
|
||||
$dolistore->getRemoteData($options);
|
||||
$dolistore->getRemoteCategories();
|
||||
$dolistore->getRemoteProducts($options);
|
||||
|
||||
print '<span class="opacitymedium">'.$langs->trans('DOLISTOREdescriptionLong').'</span><br><br>';
|
||||
|
||||
|
||||
@ -115,7 +115,7 @@ $arraydetailsforpdffoot = array(
|
||||
|
||||
print load_fiche_titre($langs->trans("PDF"), '', 'title_setup');
|
||||
|
||||
print $langs->trans("PDFDesc")."<br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("PDFDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
$noCountryCode = (empty($mysoc->country_code) ? true : false);
|
||||
|
||||
@ -173,7 +173,7 @@ if ($action == 'specimen')
|
||||
}
|
||||
|
||||
// Set default model
|
||||
else if ($action == 'setdoc')
|
||||
elseif ($action == 'setdoc')
|
||||
{
|
||||
if (dolibarr_set_const($db, "PAYMENTORDER_ADDON_PDF",$value,'chaine',0,'',$conf->entity))
|
||||
{
|
||||
|
||||
@ -69,8 +69,7 @@ if ($action == 'updateMask')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'specimen')
|
||||
elseif ($action == 'specimen')
|
||||
{
|
||||
$modele=GETPOST('module', 'alpha');
|
||||
|
||||
@ -114,8 +113,26 @@ if ($action == 'specimen')
|
||||
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
|
||||
}
|
||||
}
|
||||
elseif ($action == 'setribchq')
|
||||
{
|
||||
$rib = GETPOST('rib', 'alpha');
|
||||
$chq = GETPOST('chq', 'alpha');
|
||||
|
||||
if ($action == 'set_PROPALE_DRAFT_WATERMARK')
|
||||
$res = dolibarr_set_const($db, "FACTURE_RIB_NUMBER", $rib, 'chaine', 0, '', $conf->entity);
|
||||
$res = dolibarr_set_const($db, "FACTURE_CHQ_NUMBER", $chq, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
if (! $res > 0) $error++;
|
||||
|
||||
if (! $error)
|
||||
{
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
}
|
||||
else
|
||||
{
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
elseif ($action == 'set_PROPALE_DRAFT_WATERMARK')
|
||||
{
|
||||
$draft = GETPOST('PROPALE_DRAFT_WATERMARK', 'alpha');
|
||||
|
||||
@ -131,8 +148,7 @@ if ($action == 'set_PROPALE_DRAFT_WATERMARK')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'set_PROPOSAL_FREE_TEXT')
|
||||
elseif ($action == 'set_PROPOSAL_FREE_TEXT')
|
||||
{
|
||||
$freetext = GETPOST('PROPOSAL_FREE_TEXT', 'none'); // No alpha here, we want exact string
|
||||
|
||||
@ -149,8 +165,7 @@ if ($action == 'set_PROPOSAL_FREE_TEXT')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'setdefaultduration')
|
||||
elseif ($action == 'setdefaultduration')
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PROPALE_VALIDITY_DURATION", $value, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
@ -166,7 +181,7 @@ if ($action == 'setdefaultduration')
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'set_BANK_ASK_PAYMENT_BANK_DURING_PROPOSAL')
|
||||
elseif ($action == 'set_BANK_ASK_PAYMENT_BANK_DURING_PROPOSAL')
|
||||
{
|
||||
$res = dolibarr_set_const($db, "BANK_ASK_PAYMENT_BANK_DURING_PROPOSAL", $value, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
@ -181,13 +196,11 @@ if ($action == 'set_BANK_ASK_PAYMENT_BANK_DURING_PROPOSAL')
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
// Activate a model
|
||||
if ($action == 'set')
|
||||
elseif ($action == 'set')
|
||||
{
|
||||
$ret = addDocumentModel($value, $type, $label, $scandir);
|
||||
}
|
||||
|
||||
elseif ($action == 'del')
|
||||
{
|
||||
$ret = delDocumentModel($value, $type);
|
||||
@ -456,7 +469,7 @@ foreach ($dirmodels as $reldir)
|
||||
print '</td>';
|
||||
|
||||
// Info
|
||||
$htmltooltip = ''.$langs->trans("Name").': '.$module->name;
|
||||
$htmltooltip = $langs->trans("Name").': '.$module->name;
|
||||
$htmltooltip.='<br>'.$langs->trans("Type").': '.($module->type?$module->type:$langs->trans("Unknown"));
|
||||
if ($module->type == 'pdf')
|
||||
{
|
||||
@ -499,6 +512,106 @@ foreach ($dirmodels as $reldir)
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
|
||||
/*
|
||||
* Payment mode
|
||||
*/
|
||||
if (empty($conf->facture->enabled))
|
||||
{
|
||||
print '<br>';
|
||||
print load_fiche_titre($langs->trans("SuggestedPaymentModesIfNotDefinedInProposal"), '', '');
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'" />';
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>';
|
||||
print '<input type="hidden" name="action" value="setribchq">';
|
||||
print $langs->trans("PaymentMode").'</td>';
|
||||
print '<td align="right"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td>';
|
||||
print "</tr>\n";
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print "<td>".$langs->trans("SuggestPaymentByRIBOnAccount")."</td>";
|
||||
print "<td>";
|
||||
if (! empty($conf->banque->enabled))
|
||||
{
|
||||
$sql = "SELECT rowid, label";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account";
|
||||
$sql.= " WHERE clos = 0";
|
||||
$sql.= " AND courant = 1";
|
||||
$sql.= " AND entity IN (".getEntity('bank_account').")";
|
||||
$resql=$db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
if ($num > 0)
|
||||
{
|
||||
print '<select name="rib" class="flat" id="rib">';
|
||||
print '<option value="0">'.$langs->trans("DoNotSuggestPaymentMode").'</option>';
|
||||
while ($i < $num)
|
||||
{
|
||||
$row = $db->fetch_row($resql);
|
||||
|
||||
print '<option value="'.$row[0].'"';
|
||||
print $conf->global->FACTURE_RIB_NUMBER == $row[0] ? ' selected':'';
|
||||
print '>'.$row[1].'</option>';
|
||||
|
||||
$i++;
|
||||
}
|
||||
print "</select>";
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<i>".$langs->trans("NoActiveBankAccountDefined")."</i>";
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
print $langs->trans("BankModuleNotActive");
|
||||
}
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print "<td>".$langs->trans("SuggestPaymentByChequeToAddress")."</td>";
|
||||
print "<td>";
|
||||
print '<select class="flat" name="chq" id="chq">';
|
||||
print '<option value="0">'.$langs->trans("DoNotSuggestPaymentMode").'</option>';
|
||||
print '<option value="-1"'.($conf->global->FACTURE_CHQ_NUMBER?' selected':'').'>'.$langs->trans("MenuCompanySetup").' ('.($mysoc->name?$mysoc->name:$langs->trans("NotDefined")).')</option>';
|
||||
|
||||
$sql = "SELECT rowid, label";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account";
|
||||
$sql.= " WHERE clos = 0";
|
||||
$sql.= " AND courant = 1";
|
||||
$sql.= " AND entity IN (".getEntity('bank_account').")";
|
||||
|
||||
$resql=$db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num)
|
||||
{
|
||||
|
||||
$row = $db->fetch_row($resql);
|
||||
|
||||
print '<option value="'.$row[0].'"';
|
||||
print $conf->global->FACTURE_CHQ_NUMBER == $row[0] ? ' selected':'';
|
||||
print '>'.$langs->trans("OwnerOfBankAccount", $row[1]).'</option>';
|
||||
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
print "</select>";
|
||||
print "</td></tr>";
|
||||
print "</table>";
|
||||
print "</form>";
|
||||
}
|
||||
|
||||
print '<br>';
|
||||
|
||||
|
||||
|
||||
@ -269,7 +269,7 @@ print '<br>'."\n\n";
|
||||
print load_fiche_titre($langs->trans("SyslogLevel"));
|
||||
|
||||
// Level
|
||||
print '<form action="syslog.php" method="post">';
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="post">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<input type="hidden" name="action" value="setlevel">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
@ -286,7 +286,8 @@ $configfileparameters=array(
|
||||
'dolibarr_main_document_root'=> $langs->trans("DocumentRootServer"),
|
||||
'?dolibarr_main_document_root_alt' => $langs->trans("DocumentRootServer").' (alt)',
|
||||
'dolibarr_main_data_root' => $langs->trans("DataRootServer"),
|
||||
'separator1' => '',
|
||||
'dolibarr_main_instance_unique_id' => $langs->trans("InstanceUniqueID"),
|
||||
'separator1' => '',
|
||||
'dolibarr_main_db_host' => $langs->trans("DatabaseServer"),
|
||||
'dolibarr_main_db_port' => $langs->trans("DatabasePort"),
|
||||
'dolibarr_main_db_name' => $langs->trans("DatabaseName"),
|
||||
@ -391,7 +392,20 @@ foreach($configfileparameters as $key => $value)
|
||||
++$i;
|
||||
}
|
||||
}
|
||||
else print ${$newkey};
|
||||
elseif ($newkey == 'dolibarr_main_instance_unique_id')
|
||||
{
|
||||
//print $conf->file->instance_unique_id;
|
||||
global $dolibarr_main_cookie_cryptkey;
|
||||
$valuetoshow = ${$newkey} ? ${$newkey} : $dolibarr_main_cookie_cryptkey;
|
||||
print $valuetoshow;
|
||||
if (empty($valuetoshow)) {
|
||||
print img_warning("EditConfigFileToAddEntry", 'dolibarr_main_instance_unique_id');
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
print ${$newkey};
|
||||
}
|
||||
if ($newkey == 'dolibarr_main_url_root' && ${$newkey} != DOL_MAIN_URL_ROOT) print ' (currently overwritten by autodetected value: '.DOL_MAIN_URL_ROOT.')';
|
||||
print "</td>";
|
||||
}
|
||||
@ -446,7 +460,7 @@ if ($resql)
|
||||
print '<tr class="oddeven">';
|
||||
print '<td class="tdoverflowmax300">'.$obj->name.'</td>'."\n";
|
||||
print '<td class="tdoverflowmax300">'.dol_escape_htmltag($obj->value).'</td>'."\n";
|
||||
if (empty($conf->multicompany->enabled) || !$user->entity) print '<td align="center" width="80px">'.$obj->entity.'</td>'."\n"; // If superadmin or multicompany disabled
|
||||
if (empty($conf->multicompany->enabled) || !$user->entity) print '<td class="center" width="80px">'.$obj->entity.'</td>'."\n"; // If superadmin or multicompany disabled
|
||||
print "</tr>\n";
|
||||
|
||||
$i++;
|
||||
|
||||
@ -171,8 +171,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_titre">';
|
||||
$out.='<td>#</td>';
|
||||
$out.='<td>' . $langs->trans("Constant") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("ExpectedValue") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("Value") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("ExpectedValue") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("Value") . '</td>';
|
||||
$out.='</tr>'."\n";
|
||||
|
||||
$i = 0;
|
||||
@ -192,8 +192,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="oddeven">';
|
||||
$out.='<td>'.$i.'</td>' . "\n";
|
||||
$out.='<td>'.$constname.'</td>' . "\n";
|
||||
$out.='<td align="center">'.$constvalue.'</td>' . "\n";
|
||||
$out.='<td align="center">'.$valueforchecksum.'</td>' . "\n";
|
||||
$out.='<td class="center">'.$constvalue.'</td>' . "\n";
|
||||
$out.='<td class="center">'.$valueforchecksum.'</td>' . "\n";
|
||||
$out.="</tr>\n";
|
||||
}
|
||||
|
||||
@ -239,7 +239,7 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_titre">';
|
||||
$out.='<td>#</td>';
|
||||
$out.='<td>' . $langs->trans("Filename") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='</tr>'."\n";
|
||||
$tmpfilelist = dol_sort_array($file_list['missing'], 'filename');
|
||||
if (is_array($tmpfilelist) && count($tmpfilelist))
|
||||
@ -251,7 +251,7 @@ if (! $error && $xml)
|
||||
$out.='<tr class="oddeven">';
|
||||
$out.='<td>'.$i.'</td>' . "\n";
|
||||
$out.='<td>'.$file['filename'].'</td>' . "\n";
|
||||
$out.='<td align="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.='<td class="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.="</tr>\n";
|
||||
}
|
||||
}
|
||||
@ -273,8 +273,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_titre">';
|
||||
$out.='<td>#</td>';
|
||||
$out.='<td>' . $langs->trans("Filename") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("CurrentChecksum") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("CurrentChecksum") . '</td>';
|
||||
$out.='<td class="right">' . $langs->trans("Size") . '</td>';
|
||||
$out.='<td class="right">' . $langs->trans("DateModification") . '</td>';
|
||||
$out.='</tr>'."\n";
|
||||
@ -288,8 +288,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="oddeven">';
|
||||
$out.='<td>'.$i.'</td>' . "\n";
|
||||
$out.='<td>'.$file['filename'].'</td>' . "\n";
|
||||
$out.='<td align="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.='<td align="center">'.$file['md5'].'</td>' . "\n";
|
||||
$out.='<td class="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.='<td class="center">'.$file['md5'].'</td>' . "\n";
|
||||
$size = dol_filesize(DOL_DOCUMENT_ROOT.'/'.$file['filename']);
|
||||
$totalsize += $size;
|
||||
$out.='<td class="right">'.dol_print_size($size).'</td>' . "\n";
|
||||
@ -299,8 +299,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_total">';
|
||||
$out.='<td></td>' . "\n";
|
||||
$out.='<td>'.$langs->trans("Total").'</td>' . "\n";
|
||||
$out.='<td align="center"></td>' . "\n";
|
||||
$out.='<td align="center"></td>' . "\n";
|
||||
$out.='<td class="center"></td>' . "\n";
|
||||
$out.='<td class="center"></td>' . "\n";
|
||||
$out.='<td class="right">'.dol_print_size($totalsize).'</td>' . "\n";
|
||||
$out.='<td class="right"></td>' . "\n";
|
||||
$out.="</tr>\n";
|
||||
@ -323,8 +323,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_titre">';
|
||||
$out.='<td>#</td>';
|
||||
$out.='<td>' . $langs->trans("Filename") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='<td align="center">' . $langs->trans("CurrentChecksum") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("ExpectedChecksum") . '</td>';
|
||||
$out.='<td class="center">' . $langs->trans("CurrentChecksum") . '</td>';
|
||||
$out.='<td class="right">' . $langs->trans("Size") . '</td>';
|
||||
$out.='<td class="right">' . $langs->trans("DateModification") . '</td>';
|
||||
$out.='</tr>'."\n";
|
||||
@ -343,8 +343,8 @@ if (! $error && $xml)
|
||||
$out.=' '.$form->textwithpicto('', $htmltext, 1, 'help', '', 0, 2, 'helprm'.$i);
|
||||
}
|
||||
$out.='</td>' . "\n";
|
||||
$out.='<td align="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.='<td align="center">'.$file['md5'].'</td>' . "\n";
|
||||
$out.='<td class="center">'.$file['expectedmd5'].'</td>' . "\n";
|
||||
$out.='<td class="center">'.$file['md5'].'</td>' . "\n";
|
||||
$size = dol_filesize(DOL_DOCUMENT_ROOT.'/'.$file['filename']);
|
||||
$totalsize += $size;
|
||||
$out.='<td class="right">'.dol_print_size($size).'</td>' . "\n";
|
||||
@ -354,8 +354,8 @@ if (! $error && $xml)
|
||||
$out.='<tr class="liste_total">';
|
||||
$out.='<td></td>' . "\n";
|
||||
$out.='<td>'.$langs->trans("Total").'</td>' . "\n";
|
||||
$out.='<td align="center"></td>' . "\n";
|
||||
$out.='<td align="center"></td>' . "\n";
|
||||
$out.='<td class="center"></td>' . "\n";
|
||||
$out.='<td class="center"></td>' . "\n";
|
||||
$out.='<td class="right">'.dol_print_size($totalsize).'</td>' . "\n";
|
||||
$out.='<td class="right"></td>' . "\n";
|
||||
$out.="</tr>\n";
|
||||
|
||||
@ -107,7 +107,7 @@ print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Modules").'</td>';
|
||||
print '<td>'.$langs->trans("Version").'</td>';
|
||||
print '<td align="center">'.$langs->trans("IdModule").'</td>';
|
||||
print '<td class="center">'.$langs->trans("IdModule").'</td>';
|
||||
print '<td>'.$langs->trans("IdPermissions").'</td>';
|
||||
print '</tr>';
|
||||
$var=false;
|
||||
@ -134,7 +134,7 @@ foreach($sortorder as $numero=>$name)
|
||||
// Version
|
||||
print '<td>'.$modules[$numero]->getVersion().'</td>';
|
||||
// Id
|
||||
print '<td align="center">'.$numero.'</td>';
|
||||
print '<td class="center">'.$numero.'</td>';
|
||||
// Permissions
|
||||
if ($modules[$numero]->rights)
|
||||
{
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2013-2019 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -70,6 +70,18 @@ else
|
||||
}
|
||||
print '<br>';
|
||||
|
||||
// Module debugbar
|
||||
print '<br>';
|
||||
print '<strong>'.$langs->trans("DebugBar").'</strong>: ';
|
||||
$test=empty($conf->debugbar->enabled);
|
||||
if ($test) print img_picto('', 'tick.png').' '.$langs->trans("NotInstalled");
|
||||
else
|
||||
{
|
||||
print img_picto('', 'warning').' '.$langs->trans("DebugBarModuleActivated");
|
||||
//print ' '.$langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/system/xdebug.php'.'">XDebug admin page</a>';
|
||||
}
|
||||
print '<br>';
|
||||
|
||||
// Applicative cache
|
||||
print '<br>';
|
||||
print '<strong>'.$langs->trans("ApplicativeCache").'</strong>: ';
|
||||
|
||||
@ -66,7 +66,7 @@ if ($action == 'updateMask') {
|
||||
// TODO Verifier si module numerotation choisi peut etre active
|
||||
// par appel methode canBeActivated
|
||||
|
||||
dolibarr_set_const($db, "TICKETSUP_ADDON", $value, 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, "TICKET_ADDON", $value, 'chaine', 0, '', $conf->entity);
|
||||
} elseif ($action == 'setvar') {
|
||||
include_once DOL_DOCUMENT_ROOT . "/core/lib/files.lib.php";
|
||||
|
||||
@ -181,7 +181,7 @@ $page_name = "TicketSetup";
|
||||
llxHeader('', $langs->trans($page_name), $help_url);
|
||||
|
||||
// Subheader
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
|
||||
print load_fiche_titre($langs->trans($page_name), $linkback, 'title_setup');
|
||||
|
||||
@ -256,7 +256,7 @@ foreach ($dirmodels as $reldir) {
|
||||
print '</td>' . "\n";
|
||||
|
||||
print '<td align="center">';
|
||||
if ($conf->global->TICKETSUP_ADDON == 'mod_' . $classname) {
|
||||
if ($conf->global->TICKET_ADDON == 'mod_' . $classname) {
|
||||
print img_picto($langs->trans("Activated"), 'switch_on');
|
||||
} else {
|
||||
print '<a href="' . $_SERVER["PHP_SELF"] . '?action=setmod&value=mod_' . $classname . '" alt="' . $langs->trans("Default") . '">' . img_picto($langs->trans("Disabled"), 'switch_off') . '</a>';
|
||||
|
||||
@ -66,7 +66,7 @@ $help_url = "FR:Module_Ticket";
|
||||
$page_name = "TicketSetup";
|
||||
llxHeader('', $langs->trans($page_name), $help_url);
|
||||
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
print load_fiche_titre($langs->trans("TicketSetup"), $linkback, 'title_setup');
|
||||
|
||||
$head = ticketAdminPrepareHead();
|
||||
|
||||
@ -103,7 +103,7 @@ if ($action == 'setvar') {
|
||||
}
|
||||
|
||||
$url_interface = GETPOST('TICKET_URL_PUBLIC_INTERFACE', 'alpha');
|
||||
if (!empty($mail_signature)) {
|
||||
if (!empty($url_interface)) {
|
||||
$res = dolibarr_set_const($db, 'TICKET_URL_PUBLIC_INTERFACE', $url_interface, 'chaine', 0, '', $conf->entity);
|
||||
} else {
|
||||
$res = dolibarr_set_const($db, 'TICKET_URL_PUBLIC_INTERFACE', '', 'chaine', 0, '', $conf->entity);
|
||||
@ -113,7 +113,7 @@ if ($action == 'setvar') {
|
||||
}
|
||||
|
||||
$topic_interface = GETPOST('TICKET_PUBLIC_INTERFACE_TOPIC', 'alpha');
|
||||
if (!empty($mail_signature)) {
|
||||
if (!empty($topic_interface)) {
|
||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_INTERFACE_TOPIC', $topic_interface, 'chaine', 0, '', $conf->entity);
|
||||
} else {
|
||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_INTERFACE_TOPIC', '', 'chaine', 0, '', $conf->entity);
|
||||
@ -123,7 +123,7 @@ if ($action == 'setvar') {
|
||||
}
|
||||
|
||||
$text_home = GETPOST('TICKET_PUBLIC_TEXT_HOME', 'alpha');
|
||||
if (!empty($mail_signature)) {
|
||||
if (!empty($text_home)) {
|
||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $text_home, 'chaine', 0, '', $conf->entity);
|
||||
} else {
|
||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $langs->trans('TicketPublicInterfaceTextHome'), 'chaine', 0, '', $conf->entity);
|
||||
@ -208,7 +208,7 @@ $page_name = "TicketSetup";
|
||||
llxHeader('', $langs->trans($page_name), $help_url);
|
||||
|
||||
// Subheader
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1">' . $langs->trans("BackToModuleList") . '</a>';
|
||||
|
||||
print load_fiche_titre($langs->trans($page_name), $linkback, 'title_setup');
|
||||
|
||||
|
||||
@ -113,7 +113,7 @@ jQuery(document).ready(function() {
|
||||
print load_fiche_titre($langs->trans("Backup"), '', 'title_setup');
|
||||
//print_barre_liste($langs->trans("Backup"), '', '', '', '', '', $langs->trans("BackupDesc",DOL_DATA_ROOT), 0, 0, 'title_setup');
|
||||
|
||||
print '<div class="center">';
|
||||
print '<div class="center opacitymedium">';
|
||||
print $langs->trans("BackupDesc", DOL_DATA_ROOT);
|
||||
print '</div>';
|
||||
print '<br>';
|
||||
@ -446,7 +446,7 @@ print "\n";
|
||||
|
||||
|
||||
<br>
|
||||
<div align="center"><input type="submit" class="button"
|
||||
<div class="center"><input type="submit" class="button"
|
||||
value="<?php echo $langs->trans("GenerateBackup") ?>" id="buttonGo" /><br>
|
||||
<br>
|
||||
|
||||
@ -575,7 +575,7 @@ print "\n";
|
||||
|
||||
?>
|
||||
<br>
|
||||
<div align="center"><input type="submit" class="button"
|
||||
<div class="center"><input type="submit" class="button"
|
||||
value="<?php echo $langs->trans("GenerateBackup") ?>" id="buttonGo" /><br>
|
||||
<br>
|
||||
</div>
|
||||
|
||||
@ -67,7 +67,7 @@ jQuery(document).ready(function() {
|
||||
|
||||
print load_fiche_titre($langs->trans("Restore"), '', 'title_setup');
|
||||
|
||||
print '<div class="center">';
|
||||
print '<div class="center opacitymedium">';
|
||||
print $langs->trans("RestoreDesc", DOL_DATA_ROOT);
|
||||
print '</div>';
|
||||
print '<br>';
|
||||
|
||||
@ -173,10 +173,10 @@ function create_script_table($list)
|
||||
foreach($list as $script) {
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.dol_trunc($script['file'], 80, 'left').'</td>';
|
||||
print '<td align="center" class="nowrap">'.dol_print_date($script['mtime'], 'dayhour').'</td>';
|
||||
print '<td class="right" class="nowrap">'.number_format($script['size'] / 1024, 2).'KB</td>';
|
||||
print '<td class="right" class="nowrap">'.$script['reloads'].' ('.$script['usecount'].')</td>';
|
||||
print '<td class="right" class="nowrap">'.$script['hits'].'</td>';
|
||||
print '<td class="nowrap center">'.dol_print_date($script['mtime'], 'dayhour').'</td>';
|
||||
print '<td class="nowrap right">'.number_format($script['size'] / 1024, 2).'KB</td>';
|
||||
print '<td class="nowrap right">'.$script['reloads'].' ('.$script['usecount'].')</td>';
|
||||
print '<td class="nowrap right">'.$script['hits'].'</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
print '</table>';
|
||||
@ -203,9 +203,9 @@ function create_key_table($list)
|
||||
foreach($list as $key) {
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.dol_trunc($key['name'], 80, 'left').'</td>';
|
||||
print '<td align="center" class="nowrap">'.dol_print_date($key['created'], 'dayhour').'</td>';
|
||||
print '<td class="right" class="nowrap">'.number_format($key['size']/1024, 3).'KB</td>';
|
||||
print '<td class="right" class="nowrap">';
|
||||
print '<td class="nowrap center">'.dol_print_date($key['created'], 'dayhour').'</td>';
|
||||
print '<td class="nowrap right">'.number_format($key['size']/1024, 3).'KB</td>';
|
||||
print '<td class="nowrap right">';
|
||||
if ($key['ttl'] == -1) {
|
||||
print 'expired';
|
||||
} elseif ($key['ttl'] == 0) {
|
||||
|
||||
@ -238,20 +238,20 @@ if ($result)
|
||||
|
||||
print '<td class="liste_titre" width="15%">'.$form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0).'</td>';
|
||||
|
||||
print '<td align="left" class="liste_titre">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" size="10" name="search_code" value="'.$search_code.'">';
|
||||
print '</td>';
|
||||
|
||||
// IP
|
||||
print '<td align="left" class="liste_titre">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" size="10" name="search_ip" value="'.$search_ip.'">';
|
||||
print '</td>';
|
||||
|
||||
print '<td align="left" class="liste_titre">';
|
||||
print '<td class="liste_titre left">';
|
||||
print '<input class="flat" type="text" size="10" name="search_user" value="'.$search_user.'">';
|
||||
print '</td>';
|
||||
|
||||
print '<td align="left" class="liste_titre">';
|
||||
print '<td class="liste_titre left">';
|
||||
//print '<input class="flat" type="text" size="10" name="search_desc" value="'.$search_desc.'">';
|
||||
print '</td>';
|
||||
|
||||
@ -279,7 +279,7 @@ if ($result)
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
// Date
|
||||
print '<td align="left" class="nowrap">'.dol_print_date($db->jdate($obj->dateevent), '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
print '<td class="nowrap left">'.dol_print_date($db->jdate($obj->dateevent), '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
|
||||
// Code
|
||||
print '<td>'.$obj->type.'</td>';
|
||||
|
||||
@ -142,16 +142,16 @@ if ($savehandler == 'files')
|
||||
print '<td>'.$sessionentry['login'].'</td>';
|
||||
|
||||
// ID
|
||||
print '<td align="left" class="nowrap">';
|
||||
print '<td class="nowrap left">';
|
||||
if ("$key" == session_id()) print $form->textwithpicto($key, $langs->trans("YourSession"));
|
||||
else print $key;
|
||||
print '</td>';
|
||||
|
||||
// Date creation
|
||||
print '<td align="left" class="nowrap">'.dol_print_date($sessionentry['creation'], '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
print '<td class="nowrap left">'.dol_print_date($sessionentry['creation'], '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
|
||||
// Date modification
|
||||
print '<td align="left" class="nowrap">'.dol_print_date($sessionentry['modification'], '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
print '<td class="nowrap left">'.dol_print_date($sessionentry['modification'], '%Y-%m-%d %H:%M:%S').'</td>';
|
||||
|
||||
// Age
|
||||
print '<td>'.$sessionentry['age'].'</td>';
|
||||
|
||||
@ -224,14 +224,12 @@ else
|
||||
|
||||
print load_fiche_titre($langs->trans("Translation"), $enabledisablehtml, 'title_setup');
|
||||
|
||||
//print '<span class="opacitymedium">';
|
||||
print $langs->trans("TranslationDesc")."<br>\n";
|
||||
//print '</span>';
|
||||
print "<br>\n";
|
||||
//print '<span class="opacitymedium">'.$langs->trans("TranslationDesc")."</span><br>\n";
|
||||
//print "<br>\n";
|
||||
|
||||
$current_language_code=$langs->defaultlang;
|
||||
$s=picto_from_langcode($current_language_code);
|
||||
print $langs->trans("CurrentUserLanguage").': <strong>'.$s.' '.$current_language_code.'</strong><br>';
|
||||
print $form->textwithpicto($langs->trans("CurrentUserLanguage").': <strong>'.$s.' '.$current_language_code.'</strong>', $langs->trans("TranslationDesc")).'<br>';
|
||||
|
||||
print '<br>';
|
||||
|
||||
|
||||
@ -137,7 +137,7 @@ $form = new Form($db);
|
||||
$help_url='EN:Module_Users|FR:Module_Utilisateurs|ES:Módulo_Usuarios';
|
||||
llxHeader('', $langs->trans("UsersSetup"), $help_url);
|
||||
|
||||
$linkback='<a href="'.($backtopage?$backtopage:DOL_URL_ROOT.'/admin/modules.php').'">'.$langs->trans("BackToModuleList").'</a>';
|
||||
$linkback='<a href="'.DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans("BackToModuleList").'</a>';
|
||||
print load_fiche_titre($langs->trans("UsersSetup"), $linkback, 'title_setup');
|
||||
|
||||
|
||||
@ -183,8 +183,6 @@ print '<br>';
|
||||
|
||||
$dirmodels=array_merge(array('/'), (array) $conf->modules_parts['models']);
|
||||
|
||||
$form=new Form($db);
|
||||
|
||||
// Defini tableau def des modeles
|
||||
$def = array();
|
||||
$sql = "SELECT nom";
|
||||
|
||||
@ -63,7 +63,7 @@ llxHeader('', $langs->trans("WorkflowSetup"), '');
|
||||
$linkback='<a href="'.DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans("BackToModuleList").'</a>';
|
||||
print load_fiche_titre($langs->trans("WorkflowSetup"), $linkback, 'title_setup');
|
||||
|
||||
print $langs->trans("WorkflowDesc").'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("WorkflowDesc").'</span><br>';
|
||||
print "<br>";
|
||||
|
||||
// List of workflow we can enable
|
||||
|
||||
@ -279,7 +279,7 @@ class DolibarrApi
|
||||
/**
|
||||
* Function to forge a SQL criteria
|
||||
*
|
||||
* @param array $matches Array of found string by regex search
|
||||
* @param array $matches Array of found string by regex search. Example: "t.ref:like:'SO-%'" or "t.date_creation:<:'20160101'" or "t.nature:is:NULL"
|
||||
* @return string Forged criteria. Example: "t.field like 'abc%'"
|
||||
*/
|
||||
protected static function _forge_criteria_callback($matches)
|
||||
|
||||
@ -66,8 +66,12 @@ if (empty($action) && empty($id) && empty($ref)) $action='view';
|
||||
$extralabels = $extrafields->fetch_name_optionals_label($object->table_element);
|
||||
|
||||
// Load object
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once.
|
||||
|
||||
$permissionnote=$user->rights->asset->write; // Used by the include of actions_setnotes.inc.php
|
||||
$permissiondellink=$user->rights->asset->write; // Used by the include of actions_dellink.inc.php
|
||||
$permissionedit=$user->rights->asset->write; // Used by the include of actions_lineupdown.inc.php
|
||||
$permissiontoadd=$user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@ -117,7 +117,7 @@ if ($object->id)
|
||||
print '<div class="fichecenter">';
|
||||
|
||||
print '<div class="underbanner clearboth"></div>';
|
||||
print '<table class="border centpercent">';
|
||||
print '<table class="border tableforfield centpercent">';
|
||||
|
||||
// Number of files
|
||||
print '<tr><td class="titlefield">'.$langs->trans("NbOfAttachedFiles").'</td><td colspan="3">'.count($filearray).'</td></tr>';
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user