-- Dumping data for table `llx_reception`
--

INSERT INTO `llx_reception` VALUES
(1,'2021-04-15 11:41:05','RCP2104-0001',1,1,10,NULL,NULL,NULL,'2021-04-15 08:40:04',12,NULL,'2021-04-15 08:40:18',12,'2021-04-23 00:00:00',NULL,NULL,'',1,0,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,0,'',NULL,NULL);

--
-- Table structure for table `llx_reception_extrafields`
--

CREATE TABLE `llx_reception_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_reception_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_reception_extrafields`
--


--
-- Table structure for table `llx_receptiondet_batch`
--

CREATE TABLE `llx_receptiondet_batch` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_element` int(11) DEFAULT NULL,
  `fk_product` int(11) DEFAULT NULL,
  `description` text DEFAULT NULL,
  `fk_elementdet` int(11) DEFAULT NULL,
  `qty` float DEFAULT NULL,
  `fk_unit` int(11) DEFAULT NULL,
  `fk_entrepot` int(11) DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `comment` varchar(255) DEFAULT NULL,
  `status` int(11) DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `batch` varchar(128) DEFAULT NULL,
  `eatby` date DEFAULT NULL,
  `sellby` date DEFAULT NULL,
  `fk_projet` int(11) DEFAULT NULL,
  `fk_reception` int(11) DEFAULT NULL,
  `cost_price` double(24,8) DEFAULT 0.00000000,
  `rang` int(11) DEFAULT 0,
  `element_type` varchar(50) NOT NULL DEFAULT 'supplier_order',
  `extraparams` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_commande_fournisseur_dispatch_fk_commande` (`fk_element`),
  KEY `idx_commande_fournisseur_dispatch_fk_product` (`fk_product`),
  KEY `idx_commande_fournisseur_dispatch_fk_commandefourndet` (`fk_elementdet`),
  KEY `idx_receptiondet_batch_fk_element` (`fk_element`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_receptiondet_batch`
--

INSERT INTO `llx_receptiondet_batch` VALUES
(1,2,4,NULL,2,1,NULL,20,12,'2021-04-15 08:40:04','',1,'2021-04-15 11:40:04','Lot 2021-02',NULL,NULL,NULL,1,0.00000000,0,'supplier_order',NULL);

--
-- Table structure for table `llx_receptiondet_batch_extrafields`
--

CREATE TABLE `llx_receptiondet_batch_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_commande_fournisseur_dispatch_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_receptiondet_batch_extrafields`
--


--
-- Table structure for table `llx_recruitment_recruitmentcandidature`
--

CREATE TABLE `llx_recruitment_recruitmentcandidature` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_recruitmentjobposition` int(11) DEFAULT NULL,
  `ref` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '(PROV)',
  `description` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `note_public` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `note_private` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `date_creation` datetime NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `import_key` varchar(14) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `model_pdf` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `status` smallint(6) NOT NULL,
  `firstname` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `lastname` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `phone` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `remuneration_requested` int(11) DEFAULT NULL,
  `remuneration_proposed` int(11) DEFAULT NULL,
  `fk_recruitment_origin` int(11) DEFAULT NULL,
  `email_msgid` varchar(175) DEFAULT NULL,
  `email_date` datetime DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `date_birth` date DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  `ip` varchar(250) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_recruitmentcandidature_email_msgid` (`email_msgid`),
  KEY `idx_recruitment_recruitmentcandidature_rowid` (`rowid`),
  KEY `idx_recruitment_recruitmentcandidature_ref` (`ref`),
  KEY `llx_recruitment_recruitmentcandidature_fk_user_creat` (`fk_user_creat`),
  KEY `idx_recruitment_recruitmentcandidature_status` (`status`),
  CONSTRAINT `llx_recruitment_recruitmentcandidature_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=120 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_recruitment_recruitmentcandidature`
--

INSERT INTO `llx_recruitment_recruitmentcandidature` VALUES
(118,3,'(PROV118)','',NULL,NULL,'2021-04-15 07:28:32','2021-04-15 10:28:32',12,NULL,NULL,NULL,0,'Stud','Studson','student1@myschool.com','',20000,NULL,NULL,NULL,NULL,1,'2005-04-15',NULL,NULL),
(119,4,'(PROV119)','',NULL,NULL,'2021-04-15 07:29:26','2021-04-15 10:29:26',12,NULL,NULL,NULL,3,'Garfield','Erika','egarfield@example.com','',40000,NULL,NULL,NULL,NULL,1,'1990-04-15',NULL,NULL);

--
-- Table structure for table `llx_recruitment_recruitmentcandidature_extrafields`
--

CREATE TABLE `llx_recruitment_recruitmentcandidature_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `aa` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_recruitmentcandidature_fk_object` (`fk_object`),
  KEY `idx_fk_object` (`fk_object`)
) ENGINE=InnoDB AUTO_INCREMENT=22 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_recruitment_recruitmentcandidature_extrafields`
--

INSERT INTO `llx_recruitment_recruitmentcandidature_extrafields` VALUES
(16,'2020-08-25 10:40:58',95,NULL,NULL),
(17,'2020-08-25 10:52:58',72,NULL,NULL),
(18,'2020-09-06 09:44:55',65,NULL,'fdsfsd'),
(19,'2020-09-15 22:45:41',67,NULL,NULL),
(20,'2020-11-04 10:14:10',112,NULL,NULL),
(21,'2020-11-04 12:02:32',68,NULL,'aaaa');

--
-- Table structure for table `llx_recruitment_recruitmentjobposition`
--

CREATE TABLE `llx_recruitment_recruitmentjobposition` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `ref` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '(PROV)',
  `label` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
  `qty` int(11) NOT NULL DEFAULT 1,
  `fk_soc` int(11) DEFAULT NULL,
  `fk_project` int(11) DEFAULT NULL,
  `fk_user_recruiter` int(11) DEFAULT NULL,
  `fk_user_supervisor` int(11) DEFAULT NULL,
  `fk_establishment` int(11) DEFAULT NULL,
  `date_planned` date DEFAULT NULL,
  `description` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `note_public` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `note_private` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `date_creation` datetime NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) NOT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `import_key` varchar(14) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `model_pdf` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `status` smallint(6) NOT NULL,
  `last_main_doc` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `email_recruiter` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `remuneration` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `remuneration_suggested` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_recruitment_recruitmentjobposition_rowid` (`rowid`),
  KEY `idx_recruitment_recruitmentjobposition_ref` (`ref`),
  KEY `idx_recruitment_recruitmentjobposition_fk_soc` (`fk_soc`),
  KEY `idx_recruitment_recruitmentjobposition_fk_project` (`fk_project`),
  KEY `llx_recruitment_recruitmentjobposition_fk_user_recruiter` (`fk_user_recruiter`),
  KEY `llx_recruitment_recruitmentjobposition_fk_user_supervisor` (`fk_user_supervisor`),
  KEY `llx_recruitment_recruitmentjobposition_fk_establishment` (`fk_establishment`),
  KEY `llx_recruitment_recruitmentjobposition_fk_user_creat` (`fk_user_creat`),
  KEY `idx_recruitment_recruitmentjobposition_status` (`status`),
  CONSTRAINT `llx_recruitment_recruitmentjobposition_fk_establishment` FOREIGN KEY (`fk_establishment`) REFERENCES `llx_establishment` (`rowid`),
  CONSTRAINT `llx_recruitment_recruitmentjobposition_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`),
  CONSTRAINT `llx_recruitment_recruitmentjobposition_fk_user_recruiter` FOREIGN KEY (`fk_user_recruiter`) REFERENCES `llx_user` (`rowid`),
  CONSTRAINT `llx_recruitment_recruitmentjobposition_fk_user_supervisor` FOREIGN KEY (`fk_user_supervisor`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_recruitment_recruitmentjobposition`
--

INSERT INTO `llx_recruitment_recruitmentjobposition` VALUES
(2,'JOB2008-0001','Web designer',1,NULL,NULL,12,NULL,9,NULL,'Knowing HTML + CSS',NULL,'','2020-08-06 13:25:00','2020-09-02 17:17:47',12,12,NULL,'standard_recruitmentjobposition',3,'recruitment/recruitmentjobposition/JOB2008-0001/JOB2008-0001.pdf','',1,NULL,'To negociate'),
(3,'JOB2009-0002','PHP Developer Senior',1,NULL,NULL,12,NULL,NULL,NULL,'5 years of experience required<br />\r\n<br />\r\nLocation: Berlin<br />\r\n&nbsp;',NULL,'','2020-09-02 17:23:00','2023-01-10 21:14:30',12,12,NULL,NULL,1,'recruitment/recruitmentjobposition/JOB2009-0002/JOB2009-0002.pdf','',1,NULL,'40000 - 50000'),
(4,'JOB2009-0003','PHP Developer Junior',1,NULL,NULL,12,NULL,NULL,NULL,'Location: Madrid<br />\r\nWe are looking for a curious developer to work in our Web division.',NULL,NULL,'2020-11-11 17:24:00','2020-11-03 13:58:06',12,12,NULL,NULL,1,'recruitment/recruitmentjobposition/JOB2009-0003/JOB2009-0003.pdf','4444',1,NULL,'');

--
-- Table structure for table `llx_recruitment_recruitmentjobposition_extrafields`
--

CREATE TABLE `llx_recruitment_recruitmentjobposition_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `bbb` double(24,8) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_recruitmentjobposition_fk_object` (`fk_object`),
  KEY `idx_fk_object` (`fk_object`)
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_recruitment_recruitmentjobposition_extrafields`
--

INSERT INTO `llx_recruitment_recruitmentjobposition_extrafields` VALUES
(6,'2020-09-06 18:39:58',2,NULL,NULL),
(7,'2020-11-03 13:54:53',3,NULL,5.00000000),
(18,'2020-11-09 08:51:51',4,NULL,NULL);

--
-- Table structure for table `llx_resource`
--

CREATE TABLE `llx_resource` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref` varchar(255) DEFAULT NULL,
  `asset_number` varchar(255) DEFAULT NULL,
  `description` text DEFAULT NULL,
  `fk_code_type_resource` varchar(32) DEFAULT NULL,
  `address` varchar(255) DEFAULT NULL,
  `zip` varchar(25) DEFAULT NULL,
  `town` varchar(50) DEFAULT NULL,
  `photo_filename` varchar(255) DEFAULT NULL,
  `max_users` int(11) DEFAULT NULL,
  `phone` varchar(30) DEFAULT NULL,
  `email` varchar(255) DEFAULT NULL,
  `url` varchar(255) DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `date_valid` datetime DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `fk_user_valid` int(11) DEFAULT NULL,
  `fk_statut` smallint(6) NOT NULL DEFAULT 0,
  `import_key` varchar(14) DEFAULT NULL,
  `extraparams` varchar(255) DEFAULT NULL,
  `fk_country` int(11) DEFAULT NULL,
  `fk_state` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_resource_ref` (`ref`,`entity`),
  KEY `fk_code_type_resource_idx` (`fk_code_type_resource`),
  KEY `idx_resource_fk_country` (`fk_country`),
  KEY `idx_resource_fk_state` (`fk_state`),
  CONSTRAINT `fk_resource_fk_country` FOREIGN KEY (`fk_country`) REFERENCES `llx_c_country` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_resource`
--

INSERT INTO `llx_resource` VALUES
(1,1,'Car Kangoo 1',NULL,'Car number 1 - Num XDF-45-GH','RES_CARS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2017-02-20 16:44:12',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(2,1,'Car Kangoo 2',NULL,'Car number 2 - Num GHY-78-JJ','RES_CARS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2017-02-20 16:44:01',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(3,1,'Meeting room - 14p',NULL,'Meeting room<br />\r\n14 places','RES_ROOMS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2017-02-20 16:44:38',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(4,1,'Meeting room - 8p',NULL,'Meeting room 8 places','RES_ROOMS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2020-06-12 17:14:48',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(5,1,'SALLE-1',NULL,'Salle 1','RES_ROOMS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2024-11-28 15:11:53',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(6,1,'SALLE-2',NULL,'Salle 2','RES_ROOMS',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2024-11-28 15:11:53',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(7,1,'MAT-1',NULL,'Matériel 1','RES_HARDWARE',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2024-11-28 15:11:53',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL),
(8,1,'MAT-2',NULL,'Matériel 2','RES_HARDWARE',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2024-11-28 15:11:53',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL);

--
-- Table structure for table `llx_resource_extrafields`
--

CREATE TABLE `llx_resource_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_resource_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_resource_extrafields`
--


--
-- Table structure for table `llx_rights_def`
--

CREATE TABLE `llx_rights_def` (
  `id` int(11) NOT NULL DEFAULT 0,
  `libelle` varchar(255) DEFAULT NULL,
  `module` varchar(64) DEFAULT NULL,
  `module_origin` varchar(64) DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `perms` varchar(50) DEFAULT NULL,
  `subperms` varchar(50) DEFAULT NULL,
  `type` varchar(1) DEFAULT NULL,
  `bydefault` tinyint(4) DEFAULT 0,
  `enabled` text DEFAULT NULL,
  `module_position` int(11) NOT NULL DEFAULT 0,
  `family` varchar(64) DEFAULT NULL,
  `family_position` int(11) NOT NULL DEFAULT 0,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`id`,`entity`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_rights_def`
--



--
-- Table structure for table `llx_salary`
--

CREATE TABLE `llx_salary` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `ref` varchar(30) DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `fk_user` int(11) NOT NULL,
  `datep` date DEFAULT NULL,
  `datev` date DEFAULT NULL,
  `salary` double(24,8) DEFAULT NULL,
  `amount` double(24,8) NOT NULL DEFAULT 0.00000000,
  `fk_projet` int(11) DEFAULT NULL,
  `fk_typepayment` int(11) NOT NULL,
  `num_payment` varchar(50) DEFAULT NULL,
  `label` varchar(255) DEFAULT NULL,
  `datesp` date DEFAULT NULL,
  `dateep` date DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `note` text DEFAULT NULL,
  `fk_bank` int(11) DEFAULT NULL,
  `paye` smallint(6) NOT NULL DEFAULT 0,
  `fk_account` int(11) DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `ref_ext` varchar(255) DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_salary`
--

INSERT INTO `llx_salary` VALUES
(1,'1','2023-08-15 10:42:28',NULL,19,NULL,NULL,NULL,1000.00000000,0,2,NULL,'Salary payment','2019-09-01','2019-09-30',1,'',42,1,NULL,0,12,NULL,NULL),
(4,NULL,'2023-08-15 10:42:34','2023-01-06 12:36:21',4,NULL,NULL,NULL,100.00000000,0,6,NULL,'Salary payment','2022-12-01','2022-12-31',1,'',NULL,1,4,12,12,NULL,NULL),
(5,NULL,'2024-12-30 15:55:25','2024-12-30 16:55:09',12,NULL,NULL,2700.00000000,10.00000000,0,3,NULL,'Salary','2024-11-01','2024-11-30',1,NULL,NULL,0,NULL,12,NULL,NULL,NULL);

--
-- Table structure for table `llx_salary_extrafields`
--

CREATE TABLE `llx_salary_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_salary_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_salary_extrafields`
--


--
-- Table structure for table `llx_session`
--

CREATE TABLE `llx_session` (
  `session_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
  `session_variable` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `date_creation` datetime NOT NULL,
  `last_accessed` datetime NOT NULL,
  `fk_user` int(11) NOT NULL,
  `remote_ip` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
  `user_agent` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`session_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_session`
--


--
-- Table structure for table `llx_societe`
--

CREATE TABLE `llx_societe` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `statut` tinyint(4) DEFAULT 0,
  `parent` int(11) DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `nom` varchar(128) DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref_ext` varchar(255) DEFAULT NULL,
  `ref_int` varchar(60) DEFAULT NULL,
  `code_client` varchar(24) DEFAULT NULL,
  `code_fournisseur` varchar(24) DEFAULT NULL,
  `tp_payment_reference` varchar(25) DEFAULT NULL,
  `accountancy_code_customer_general` varchar(32) DEFAULT NULL,
  `code_compta` varchar(32) DEFAULT NULL,
  `accountancy_code_supplier_general` varchar(32) DEFAULT NULL,
  `code_compta_fournisseur` varchar(32) DEFAULT NULL,
  `address` varchar(255) DEFAULT NULL,
  `zip` varchar(25) DEFAULT NULL,
  `town` varchar(50) DEFAULT NULL,
  `fk_departement` int(11) DEFAULT 0,
  `fk_pays` int(11) DEFAULT 0,
  `phone` varchar(30) DEFAULT NULL,
  `phone_mobile` varchar(30) DEFAULT NULL,
  `fax` varchar(30) DEFAULT NULL,
  `url` varchar(255) DEFAULT NULL,
  `email` varchar(128) DEFAULT NULL,
  `socialnetworks` text DEFAULT NULL,
  `fk_effectif` int(11) DEFAULT 0,
  `fk_typent` int(11) DEFAULT NULL,
  `fk_forme_juridique` int(11) DEFAULT 0,
  `birth` date DEFAULT NULL,
  `fk_currency` varchar(3) DEFAULT NULL,
  `siren` varchar(128) DEFAULT NULL,
  `siret` varchar(128) DEFAULT NULL,
  `ape` varchar(128) DEFAULT NULL,
  `idprof4` varchar(128) DEFAULT NULL,
  `tva_intra` varchar(20) DEFAULT NULL,
  `capital` double(24,8) DEFAULT NULL,
  `fk_stcomm` int(11) NOT NULL DEFAULT 0,
  `note_private` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `prefix_comm` varchar(5) DEFAULT NULL,
  `client` tinyint(4) DEFAULT 0,
  `fournisseur` tinyint(4) DEFAULT 0,
  `supplier_account` varchar(32) DEFAULT NULL,
  `fk_prospectlevel` varchar(12) DEFAULT NULL,
  `customer_bad` tinyint(4) DEFAULT 0,
  `customer_rate` double DEFAULT 0,
  `supplier_rate` double DEFAULT 0,
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `remise_client` double DEFAULT 0,
  `remise_supplier` double DEFAULT 0,
  `mode_reglement` int(11) DEFAULT NULL,
  `cond_reglement` tinyint(4) DEFAULT NULL,
  `deposit_percent` varchar(63) DEFAULT NULL,
  `transport_mode` tinyint(4) DEFAULT NULL,
  `mode_reglement_supplier` int(11) DEFAULT NULL,
  `outstanding_limit` double(24,8) DEFAULT NULL,
  `order_min_amount` double(24,8) DEFAULT NULL,
  `supplier_order_min_amount` double(24,8) DEFAULT NULL,
  `cond_reglement_supplier` int(11) DEFAULT NULL,
  `transport_mode_supplier` tinyint(4) DEFAULT NULL,
  `fk_shipping_method` int(11) DEFAULT NULL,
  `tva_assuj` tinyint(4) DEFAULT 1,
  `vat_reverse_charge` tinyint(4) DEFAULT 0,
  `localtax1_assuj` tinyint(4) DEFAULT 0,
  `localtax1_value` double(6,3) DEFAULT NULL,
  `localtax2_assuj` tinyint(4) DEFAULT 0,
  `localtax2_value` double(6,3) DEFAULT NULL,
  `barcode` varchar(255) DEFAULT NULL,
  `price_level` int(11) DEFAULT NULL,
  `default_lang` varchar(6) DEFAULT NULL,
  `canvas` varchar(32) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `status` tinyint(4) DEFAULT 1,
  `logo` varchar(255) DEFAULT NULL,
  `idprof5` varchar(128) DEFAULT NULL,
  `idprof6` varchar(128) DEFAULT NULL,
  `fk_barcode_type` int(11) DEFAULT 0,
  `webservices_url` varchar(255) DEFAULT NULL,
  `webservices_key` varchar(128) DEFAULT NULL,
  `accountancy_code_sell` varchar(32) DEFAULT NULL,
  `accountancy_code_buy` varchar(32) DEFAULT NULL,
  `name_alias` varchar(128) DEFAULT NULL,
  `fk_incoterms` int(11) DEFAULT NULL,
  `location_incoterms` varchar(255) DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  `last_main_doc` varchar(255) DEFAULT NULL,
  `fk_multicurrency` int(11) DEFAULT NULL,
  `multicurrency_code` varchar(3) DEFAULT NULL,
  `fk_account` int(11) DEFAULT NULL,
  `fk_warehouse` int(11) DEFAULT NULL,
  `logo_squarred` varchar(255) DEFAULT NULL,
  `geolat` double(24,8) DEFAULT NULL,
  `geolong` double(24,8) DEFAULT NULL,
  `geopoint` point DEFAULT NULL,
  `georesultcode` varchar(16) DEFAULT NULL,
  `ip` varchar(250) DEFAULT NULL,
  `vatexemptcode` varchar(24) DEFAULT NULL,
  `euid` varchar(64) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_societe_prefix_comm` (`prefix_comm`,`entity`),
  UNIQUE KEY `uk_societe_code_client` (`code_client`,`entity`),
  UNIQUE KEY `uk_societe_barcode` (`barcode`,`fk_barcode_type`,`entity`),
  UNIQUE KEY `uk_societe_code_fournisseur` (`code_fournisseur`,`entity`),
  KEY `idx_societe_user_creat` (`fk_user_creat`),
  KEY `idx_societe_user_modif` (`fk_user_modif`),
  KEY `idx_societe_barcode` (`barcode`),
  KEY `idx_societe_warehouse` (`fk_warehouse`),
  KEY `idx_societe_nom` (`nom`)
) ENGINE=InnoDB AUTO_INCREMENT=65 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe`
--

INSERT INTO `llx_societe` VALUES
(1,0,NULL,'2023-03-01 22:02:40','2012-07-08 14:21:44','Indian SAS',1,NULL,NULL,'CU1212-0007','SU1212-0005',NULL,NULL,'7050',NULL,'6050','1 alalah road',NULL,'Delhi',NULL,117,NULL,NULL,NULL,NULL,NULL,'[]',NULL,4,NULL,NULL,'0','','','','','',5000.00000000,2,NULL,NULL,NULL,1,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,'fr_FR',NULL,NULL,1,'indiancompany.png','','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(2,0,NULL,'2023-02-25 02:32:36','2012-07-08 14:23:48','Teclib',1,NULL,NULL,'CU1108-0001','SU1108-0001',NULL,NULL,'411CU11080001',NULL,'401SU11080001','',NULL,'Paris',0,1,NULL,NULL,NULL,'www.teclib.com',NULL,NULL,4,3,57,NULL,'0','123456789','','ACE14','','',400000.00000000,2,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,NULL,0.000,NULL,NULL,'fr_FR',NULL,NULL,1,'teclibcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,0,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(3,0,NULL,'2023-02-25 02:32:36','2012-07-08 22:42:12','Spanish Comp',1,NULL,NULL,'SPANISHCOMP','SU1601-0009',NULL,NULL,NULL,NULL,NULL,'1 via mallere',NULL,'Madrid',123,4,NULL,NULL,NULL,NULL,NULL,NULL,3,4,408,NULL,'0','','','','','',10000.00000000,2,NULL,NULL,NULL,1,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,'es_AR',NULL,NULL,1,'spanishcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(4,0,NULL,'2022-12-16 11:20:27','2012-07-08 22:48:18','Prospector Vaalen',1,NULL,NULL,'CU1303-0014',NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,'Bruxelles',103,2,NULL,NULL,NULL,NULL,NULL,'[]',3,4,201,NULL,'0','12345678','','','','',0.00000000,2,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'valeencompany.png','','',0,NULL,NULL,'','','',0,NULL,'',NULL,0,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(5,0,NULL,'2017-02-21 11:01:17','2012-07-08 23:22:57','NoCountry GmBh',1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'nocountrycomp.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(6,0,NULL,'2018-01-16 15:35:56','2012-07-09 00:15:09','Swiss Touch',1,NULL,NULL,'CU1601-0018','SU1601-0010',NULL,NULL,NULL,NULL,NULL,'',NULL,'Genevia',0,6,NULL,NULL,NULL,NULL,'swisstouch@example.ch',NULL,2,2,601,NULL,'0','','','','','',56000.00000000,0,NULL,NULL,NULL,3,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'swisstouch.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(7,0,NULL,'2018-01-16 15:38:32','2012-07-09 01:24:26','Generic customer',1,NULL,NULL,'CU1302-0011',NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,0,7,NULL,NULL,NULL,NULL,'ttt@ttt.com',NULL,NULL,8,NULL,NULL,'0','','','','','',0.00000000,0,'Generic customer to use for Point Of Sale module.<br />',NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'genericcustomer.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(10,0,NULL,'2025-04-08 08:55:23','2012-07-10 15:13:08','NLTechno',1,NULL,NULL,'CU1212-0005','SU1601-0011',NULL,NULL,'411CU12120005',NULL,'401SU16010011','',NULL,NULL,NULL,102,NULL,NULL,NULL,NULL,'vsmith@email.com','[]',1,4,NULL,NULL,'0','493861496','49386149600039','6209Z','22-01-2007','',10000.00000000,0,NULL,'aa < aa<br />\r\nd<strong>dd</strong>d',NULL,1,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,'123456789012',NULL,'fr_FR',NULL,NULL,1,'logo_nltechno_94x100.png','','',0,NULL,NULL,'','','The OpenSource company',0,NULL,'sepamandate',NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(11,0,NULL,'2019-11-28 11:52:58','2012-07-10 18:35:57','Company Corp 1',1,NULL,NULL,'CU1510-0017',NULL,NULL,NULL,'7051',NULL,NULL,'21 Green Hill street','75500','Los Angeles',0,11,'444123456',NULL,NULL,'companycorp1.com','companycorp1@example.com','{\"skype\":\"corp1\"}',1,1,NULL,NULL,'0','AB1234567','','','','USABS123',10000.00000000,0,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'comapnycorp1company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(12,0,NULL,'2023-01-14 10:46:33','2012-07-11 16:18:08','Dupont Alain',1,NULL,NULL,'CU1601-0019',NULL,NULL,NULL,'411CU16010019',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'pcurie@example.com','[]',NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'pierrecurie.jpg','','',0,NULL,NULL,'','','',0,NULL,'',NULL,0,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(13,0,NULL,'2019-10-08 09:57:51','2012-07-11 17:13:20','Company Corp 2',1,NULL,NULL,'CU1910-00021','SU1510-0008',NULL,NULL,'411CU191000021',NULL,'401SU15100008','',NULL,NULL,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'companycorp2company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(17,0,NULL,'2024-06-22 10:44:35','2013-08-01 02:41:26','Book Keeping Company',1,NULL,NULL,'CU1108-0004','SU1108-0004',NULL,NULL,'411CU11080004',NULL,'401SU11080004','The French Company',NULL,'Paris',NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',1,0,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(19,0,NULL,'2019-09-26 12:03:13','2015-01-12 12:23:05','Magic Food Store',1,NULL,NULL,'CU1301-0008',NULL,NULL,NULL,NULL,NULL,NULL,'65 holdywood boulevard','123456','BigTown',0,4,NULL,NULL,'0101',NULL,'myemail@domain.com',NULL,NULL,NULL,NULL,NULL,'0','','','10/10/2010','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,NULL,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'magicfoodstore.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,'sepamandate',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(25,0,32,'2025-05-05 11:25:27','2015-03-10 15:47:37','Print Company',1,NULL,NULL,'CU1303-0016','SU1303-0007',NULL,NULL,'411CU13030016',NULL,'401SU13030007','21 Gutenberg street','45600','Berlin',NULL,5,NULL,NULL,NULL,NULL,'printcompany@example.com','[]',NULL,0,NULL,NULL,'0','','','','','',NULL,0,NULL,NULL,NULL,1,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,'de_DE',NULL,NULL,1,'printcompany.png','','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(26,0,NULL,'2019-09-26 12:06:05','2017-02-12 23:17:04','Calculation Power',1,NULL,NULL,'CU1702-0020',NULL,NULL,NULL,'411CU17020020',NULL,NULL,'',NULL,'Calgary',0,14,NULL,NULL,NULL,NULL,'calculationpower@example.com',NULL,NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0.000,0,0.000,NULL,NULL,'en_US',NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(29,0,NULL,'2020-01-13 12:56:22','2020-01-06 00:39:58','Patient',1,NULL,NULL,'CU2001-00022',NULL,NULL,NULL,'411CU200100022',NULL,NULL,'',NULL,NULL,0,117,'01',NULL,'02',NULL,NULL,'null',NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,'aa < ddd',NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,'patient@cabinetmed',NULL,1,NULL,'','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,0,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(30,0,NULL,'2022-12-28 00:56:01','2020-01-13 17:19:24','Italo',1,NULL,NULL,'CU2001-00023',NULL,NULL,NULL,'411CU200100023',NULL,NULL,'12 Alagio','123','Milano',777,3,NULL,NULL,NULL,NULL,'aaa@it.com','[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,4,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(31,0,NULL,'2025-04-11 15:31:18','2022-12-26 12:12:11','aaa',1,NULL,NULL,'CU2212-00024',NULL,NULL,NULL,'411CU221200024',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,2,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,0,'1.JPG','','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(32,0,NULL,'2025-05-26 15:18:27','2022-12-26 12:12:43','aaa',1,NULL,NULL,'CU2212-00025',NULL,NULL,NULL,'411CU221200025',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'generic_odt:/home/ldestailleur/git/dolibarr_dev/documents/doctemplates/thirdparties/template_thirdparty.odt',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(33,0,NULL,'2023-02-09 18:09:16','2022-12-26 12:14:10','aaainlux',1,NULL,NULL,'CU2212-00026',NULL,NULL,NULL,'411CU221200026',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(34,0,NULL,'2023-02-15 23:08:31','2022-12-26 12:15:09','aaaincash',1,NULL,NULL,'CU2212-00027',NULL,NULL,NULL,'411CU221200027',NULL,NULL,'Direction des systèmes d\'information\r\n98-102 rue de Richelieu 75002 Paris.\r\nSiège: 1, place du Palais Royal, 75001','75001','Paris',77,1,'060606060606',NULL,'0705050505','https://aaa.com','aaa@aaa.com','[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(35,0,NULL,'2022-12-28 00:21:00','2022-12-26 12:18:03','bbb',1,NULL,NULL,'CU2212-00028',NULL,NULL,NULL,'411CU221200028',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,'aaa@aa.com','[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(36,0,NULL,'2022-12-26 12:21:55','2022-12-26 12:21:55','bbb',1,NULL,NULL,'CU2212-00029',NULL,NULL,NULL,'411CU221200029',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(37,0,NULL,'2024-12-27 15:00:09','2024-12-27 15:00:09','ppppp',1,NULL,NULL,'CU2412-00030',NULL,NULL,NULL,'411CU241200030',NULL,NULL,'',NULL,NULL,NULL,117,NULL,NULL,NULL,NULL,NULL,'[]',NULL,101,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0.000,0,0.000,NULL,NULL,NULL,'patient@cabinetmed',NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,0,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(39,0,NULL,'2025-01-30 21:52:20','2025-01-03 14:59:56','Testldr1',1,NULL,NULL,'CU2501-00031',NULL,NULL,NULL,'411CU250100031',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,'testldr1@dolicloud.com','null',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,'g<br>\nmm',NULL,3,0,NULL,'',0,0,0,29,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,'fr_FR',NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,0,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(58,0,NULL,'2025-06-25 10:13:15','2025-06-25 10:13:15','aaa',1,NULL,NULL,'CU2506-00032',NULL,NULL,NULL,'411CU250600032',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(59,0,NULL,'2025-06-25 10:13:36','2025-06-25 10:13:36','fff',1,NULL,NULL,'CU2506-00033',NULL,NULL,NULL,'411CU250600033',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(60,0,NULL,'2025-06-25 10:14:43','2025-06-25 10:14:43','bbb',1,NULL,NULL,'CU2506-00034',NULL,NULL,NULL,'411CU250600034',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(61,0,NULL,'2025-06-25 10:22:06','2025-06-25 10:22:06','ccc',1,NULL,NULL,'CU2506-00035',NULL,NULL,NULL,'411CU250600035',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(62,0,NULL,'2025-06-25 10:27:57','2025-06-25 10:27:57','ddd',1,NULL,NULL,'CU2506-00036',NULL,NULL,NULL,'411CU250600036',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'[]',NULL,0,NULL,NULL,NULL,'','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0,0.000,0,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,1,'EUR',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL),
(64,0,NULL,'2025-01-16 08:53:37','2025-01-16 09:53:37','test test',1,NULL,NULL,'CU2501-00037',NULL,NULL,NULL,'411CU250100037',NULL,NULL,'',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,'test@test.com','[]',NULL,0,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,'','','',0,NULL,'',NULL,0,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);

--
-- Table structure for table `llx_societe_address`
--

CREATE TABLE `llx_societe_address` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `datec` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `label` varchar(30) DEFAULT NULL,
  `fk_soc` int(11) DEFAULT 0,
  `name` varchar(60) DEFAULT NULL,
  `address` varchar(255) DEFAULT NULL,
  `zip` varchar(10) DEFAULT NULL,
  `town` varchar(50) DEFAULT NULL,
  `fk_pays` int(11) DEFAULT 0,
  `phone` varchar(20) DEFAULT NULL,
  `fax` varchar(20) DEFAULT NULL,
  `note` mediumtext DEFAULT NULL,
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;

--
-- Dumping data for table `llx_societe_address`
--


--
-- Table structure for table `llx_societe_commerciaux`
--

CREATE TABLE `llx_societe_commerciaux` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_soc` int(11) DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `fk_c_type_contact_code` varchar(32) NOT NULL DEFAULT 'SALESREPTHIRD',
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_societe_commerciaux_c_type_contact` (`fk_soc`,`fk_user`,`fk_c_type_contact_code`),
  KEY `fk_societe_commerciaux_fk_c_type_contact_code` (`fk_c_type_contact_code`),
  KEY `fk_societe_commerciaux_fk_user` (`fk_user`),
  CONSTRAINT `fk_societe_commerciaux_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`),
  CONSTRAINT `fk_societe_commerciaux_fk_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=22 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_commerciaux`
--

INSERT INTO `llx_societe_commerciaux` VALUES
(1,2,2,NULL,'SALESREPTHIRD'),
(2,3,2,NULL,'SALESREPTHIRD'),
(5,17,1,NULL,'SALESREPTHIRD'),
(6,19,1,NULL,'SALESREPTHIRD'),
(8,19,3,NULL,'SALESREPTHIRD'),
(9,11,16,NULL,'SALESREPTHIRD'),
(10,13,17,NULL,'SALESREPTHIRD'),
(11,26,12,NULL,'SALESREPTHIRD'),
(12,29,12,NULL,'SALESREPTHIRD'),
(13,37,12,NULL,'SALESREPTHIRD'),
(15,39,29,NULL,'SALESREPTHIRD'),
(16,58,12,NULL,'SALESREPTHIRD'),
(17,59,12,NULL,'SALESREPTHIRD'),
(18,60,12,NULL,'SALESREPTHIRD'),
(19,61,12,NULL,'SALESREPTHIRD'),
(20,62,12,NULL,'SALESREPTHIRD'),
(21,1,12,NULL,'SALESREPTHIRD');

--
-- Table structure for table `llx_societe_contacts`
--

CREATE TABLE `llx_societe_contacts` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `date_creation` datetime NOT NULL,
  `fk_soc` int(11) NOT NULL,
  `fk_c_type_contact` int(11) NOT NULL,
  `fk_socpeople` int(11) NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `idx_societe_contacts_idx1` (`entity`,`fk_soc`,`fk_c_type_contact`,`fk_socpeople`),
  KEY `fk_societe_contacts_fk_c_type_contact` (`fk_c_type_contact`),
  KEY `fk_societe_contacts_fk_soc` (`fk_soc`),
  KEY `fk_societe_contacts_fk_socpeople` (`fk_socpeople`),
  CONSTRAINT `fk_societe_contacts_fk_c_type_contact` FOREIGN KEY (`fk_c_type_contact`) REFERENCES `llx_c_type_contact` (`rowid`),
  CONSTRAINT `fk_societe_contacts_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`),
  CONSTRAINT `fk_societe_contacts_fk_socpeople` FOREIGN KEY (`fk_socpeople`) REFERENCES `llx_socpeople` (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_contacts`
--


--
-- Table structure for table `llx_societe_log`
--

CREATE TABLE `llx_societe_log` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `datel` datetime DEFAULT NULL,
  `fk_soc` int(11) DEFAULT NULL,
  `fk_statut` int(11) DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  `author` varchar(30) DEFAULT NULL,
  `label` varchar(128) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;

--
-- Dumping data for table `llx_societe_log`
--


--
-- Table structure for table `llx_societe_perentity`
--

CREATE TABLE `llx_societe_perentity` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_soc` int(11) DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `accountancy_code_customer_general` varchar(32) DEFAULT NULL,
  `accountancy_code_customer` varchar(32) DEFAULT NULL,
  `accountancy_code_supplier_general` varchar(32) DEFAULT NULL,
  `accountancy_code_supplier` varchar(32) DEFAULT NULL,
  `accountancy_code_sell` varchar(32) DEFAULT NULL,
  `accountancy_code_buy` varchar(32) DEFAULT NULL,
  `vat_reverse_charge` tinyint(4) DEFAULT 0,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_societe_perentity` (`fk_soc`,`entity`),
  KEY `idx_societe_perentity_fk_soc` (`fk_soc`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_perentity`
--


--
-- Table structure for table `llx_societe_prices`
--

CREATE TABLE `llx_societe_prices` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_soc` int(11) DEFAULT 0,
  `tms` timestamp NULL DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `price_level` tinyint(4) DEFAULT 1,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_prices`
--

INSERT INTO `llx_societe_prices` VALUES
(1,30,NULL,'2020-01-17 14:54:44',12,4),
(2,30,NULL,'2020-01-17 15:19:28',12,1),
(3,30,NULL,'2020-01-17 15:21:26',12,4);

--
-- Table structure for table `llx_societe_remise`
--

CREATE TABLE `llx_societe_remise` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_soc` int(11) NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `remise_client` double(6,3) NOT NULL DEFAULT 0.000,
  `note` text DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_remise`
--


--
-- Table structure for table `llx_societe_remise_except`
--

CREATE TABLE `llx_societe_remise_except` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_soc` int(11) NOT NULL,
  `discount_type` int(11) NOT NULL DEFAULT 0,
  `datec` datetime DEFAULT NULL,
  `amount_ht` double(24,8) NOT NULL,
  `amount_tva` double(24,8) NOT NULL DEFAULT 0.00000000,
  `amount_ttc` double(24,8) NOT NULL DEFAULT 0.00000000,
  `tva_tx` double(6,3) NOT NULL DEFAULT 0.000,
  `fk_user` int(11) NOT NULL,
  `fk_facture_line` int(11) DEFAULT NULL,
  `fk_facture` int(11) DEFAULT NULL,
  `fk_facture_source` int(11) DEFAULT NULL,
  `description` text NOT NULL,
  `multicurrency_amount_ht` double(24,8) NOT NULL DEFAULT 0.00000000,
  `multicurrency_amount_tva` double(24,8) NOT NULL DEFAULT 0.00000000,
  `multicurrency_amount_ttc` double(24,8) NOT NULL DEFAULT 0.00000000,
  `fk_invoice_supplier_line` int(11) DEFAULT NULL,
  `fk_invoice_supplier` int(11) DEFAULT NULL,
  `fk_invoice_supplier_source` int(11) DEFAULT NULL,
  `vat_src_code` varchar(10) DEFAULT '',
  `multicurrency_code` varchar(3) DEFAULT NULL,
  `multicurrency_tx` double(24,8) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_societe_remise_except_fk_user` (`fk_user`),
  KEY `idx_societe_remise_except_fk_soc` (`fk_soc`),
  KEY `idx_societe_remise_except_fk_facture_line` (`fk_facture_line`),
  KEY `idx_societe_remise_except_fk_facture` (`fk_facture`),
  KEY `idx_societe_remise_except_fk_facture_source` (`fk_facture_source`),
  KEY `fk_soc_remise_fk_invoice_supplier_line` (`fk_invoice_supplier_line`),
  KEY `fk_societe_remise_fk_invoice_supplier_source` (`fk_invoice_supplier`),
  KEY `idx_societe_remise_except_discount_type` (`discount_type`),
  CONSTRAINT `fk_soc_remise_fk_facture_line` FOREIGN KEY (`fk_facture_line`) REFERENCES `llx_facturedet` (`rowid`),
  CONSTRAINT `fk_soc_remise_fk_invoice_supplier_line` FOREIGN KEY (`fk_invoice_supplier_line`) REFERENCES `llx_facture_fourn_det` (`rowid`),
  CONSTRAINT `fk_soc_remise_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_facture` FOREIGN KEY (`fk_facture`) REFERENCES `llx_facture` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_facture_line` FOREIGN KEY (`fk_facture_line`) REFERENCES `llx_facturedet` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_facture_source` FOREIGN KEY (`fk_facture_source`) REFERENCES `llx_facture` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_invoice_supplier` FOREIGN KEY (`fk_invoice_supplier`) REFERENCES `llx_facture_fourn` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_invoice_supplier_source` FOREIGN KEY (`fk_invoice_supplier`) REFERENCES `llx_facture_fourn` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`),
  CONSTRAINT `fk_societe_remise_fk_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_remise_except`
--

INSERT INTO `llx_societe_remise_except` VALUES
(2,1,19,0,'2015-03-19 09:36:15',10.00000000,1.25000000,11.25000000,12.500,1,NULL,NULL,NULL,'hfghgf',0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,'',NULL,NULL),
(14,1,17,1,'2020-01-01 22:06:30',79.16444000,9.89556000,89.06000000,12.500,12,NULL,NULL,NULL,'(CREDIT_NOTE)',0.00000000,0.00000000,0.00000000,NULL,NULL,27,'',NULL,NULL),
(15,1,19,0,'2020-01-16 02:34:47',20.50000000,0.00000000,20.50000000,0.000,12,1065,NULL,224,'(DEPOSIT)',20.50000000,0.00000000,20.50000000,NULL,NULL,NULL,'',NULL,NULL),
(16,1,1,0,'2020-01-19 14:49:41',10.00000000,1.96000000,11.96000000,19.600,12,NULL,NULL,NULL,'111',10.00000000,1.96000000,11.96000000,NULL,NULL,NULL,'',NULL,NULL),
(19,1,1,0,'2020-01-19 15:16:27',48.60000000,1.94000000,50.54000000,4.000,12,NULL,NULL,228,'(DEPOSIT)',48.60000000,1.94000000,50.54000000,NULL,NULL,NULL,'',NULL,NULL),
(21,1,10,0,'2024-12-18 14:53:53',10.00000000,0.00000000,10.00000000,0.000,12,1133,NULL,243,'(DEPOSIT)',10.00000000,0.00000000,10.00000000,NULL,NULL,NULL,'',NULL,NULL),
(22,1,33,0,'2024-12-18 15:21:37',10.00000000,0.40000000,10.40000000,4.000,12,1136,NULL,246,'(DEPOSIT)',10.00000000,0.40000000,10.40000000,NULL,NULL,NULL,'',NULL,NULL),
(23,1,1,1,'2024-12-30 19:27:16',10.00000000,0.00000000,10.00000000,0.000,12,NULL,NULL,NULL,'fsdfsd',10.00000000,0.00000000,10.00000000,NULL,NULL,NULL,'',NULL,NULL),
(27,1,2,0,'2025-04-09 17:40:46',80.00000000,0.00000000,80.00000000,0.000,12,NULL,NULL,2,'(EXCESS RECEIVED)',0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,'',NULL,NULL),
(28,1,7,0,'2025-03-05 09:40:29',0.01000000,0.00000000,0.01000000,0.000,12,NULL,472,473,'(CREDIT_NOTE)',0.01000000,0.00000000,0.01000000,NULL,NULL,NULL,'',NULL,NULL);

--
-- Table structure for table `llx_societe_remise_supplier`
--

CREATE TABLE `llx_societe_remise_supplier` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_soc` int(11) NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `remise_supplier` double(6,3) NOT NULL DEFAULT 0.000,
  `note` mediumtext DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_societe_remise_supplier`
--

INSERT INTO `llx_societe_remise_supplier` VALUES
(1,1,1,'2018-04-06 18:21:00','2018-04-06 20:21:00',12,6.000,'llll');

--
-- Table structure for table `llx_socpeople`
--

CREATE TABLE `llx_socpeople` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `datec` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_soc` int(11) DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref_ext` varchar(255) DEFAULT NULL,
  `civility` varchar(6) DEFAULT NULL,
  `lastname` varchar(50) DEFAULT NULL,
  `firstname` varchar(50) DEFAULT NULL,
  `address` varchar(255) DEFAULT NULL,
  `zip` varchar(25) DEFAULT NULL,
  `town` text DEFAULT NULL,
  `fk_departement` int(11) DEFAULT NULL,
  `fk_pays` int(11) DEFAULT 0,
  `birthday` date DEFAULT NULL,
  `poste` varchar(255) DEFAULT NULL,
  `phone` varchar(30) DEFAULT NULL,
  `phone_perso` varchar(30) DEFAULT NULL,
  `phone_mobile` varchar(30) DEFAULT NULL,
  `fax` varchar(30) DEFAULT NULL,
  `email` varchar(255) DEFAULT NULL,
  `socialnetworks` text DEFAULT NULL,
  `photo` varchar(255) DEFAULT NULL,
  `priv` smallint(6) NOT NULL DEFAULT 0,
  `fk_prospectlevel` varchar(12) DEFAULT NULL,
  `fk_stcommcontact` int(11) NOT NULL DEFAULT 0,
  `no_email` smallint(6) NOT NULL DEFAULT 0,
  `fk_user_creat` int(11) DEFAULT 0,
  `fk_user_modif` int(11) DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `default_lang` varchar(6) DEFAULT NULL,
  `canvas` varchar(32) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `statut` tinyint(4) NOT NULL DEFAULT 1,
  `role_list` varchar(255) DEFAULT NULL,
  `geolat` double(24,8) DEFAULT NULL,
  `geolong` double(24,8) DEFAULT NULL,
  `geopoint` point DEFAULT NULL,
  `georesultcode` varchar(16) DEFAULT NULL,
  `name_alias` varchar(255) DEFAULT NULL,
  `fk_parent` int(11) DEFAULT NULL,
  `url` varchar(255) DEFAULT NULL,
  `ip` varchar(250) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_socpeople_fk_soc` (`fk_soc`),
  KEY `idx_socpeople_fk_user_creat` (`fk_user_creat`),
  KEY `idx_socpeople_lastname` (`lastname`),
  CONSTRAINT `fk_socpeople_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`),
  CONSTRAINT `fk_socpeople_user_creat_user_rowid` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_socpeople`
--

INSERT INTO `llx_socpeople` VALUES
(1,'2012-07-08 14:26:14','2025-03-24 20:41:09',1,1,NULL,'MR','Indra','UpdatedFirstName','','','',297,117,'2012-07-08','Project leader','','','','','','[]','',0,'',0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(2,'2012-07-08 22:44:50','2019-11-28 11:52:58',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','[]',NULL,0,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(3,'2012-07-08 22:59:02','2019-11-28 11:52:58',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','[]',NULL,1,NULL,0,0,1,12,'This is a private contact','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(4,'2012-07-09 00:16:58','2019-11-28 11:52:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','[]',NULL,0,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(6,'2013-08-01 02:41:26','2025-05-05 14:48:18',17,1,NULL,'','Bookkeeper','Bob','','','',NULL,NULL,NULL,'book keeper','','','','','bbookkeeper@example.com','{\"skype\":\"skypebbookkeeper\"}','',0,'',0,0,1,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(7,'2018-07-30 16:11:06','2019-11-28 11:52:58',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','[]','',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(8,'2018-07-30 16:13:03','2019-11-28 11:52:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','[]','',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(9,'2018-07-30 16:14:41','2019-11-28 11:52:58',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','[]','',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(10,'2018-07-30 16:26:22','2025-02-10 19:26:55',10,1,NULL,'','Destailleur','Laurent','','','',NULL,NULL,'1972-10-10','Dolibarr project leader','','','','','ldestailleur@example.com','[]','ldestailleur_200x200.jpg',0,'',0,0,NULL,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(11,'2017-05-12 13:16:36','2019-11-28 11:52:58',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','[]','ldestailleur_200x200.png',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(12,'2017-05-12 13:19:31','2019-11-28 11:52:58',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','[]','Einstein.jpg',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(14,'2025-03-24 20:41:09','2025-03-24 20:41:09',NULL,1,NULL,'','testRestContact','testRestContact261466044','','','',NULL,NULL,NULL,'','','','','','','null',NULL,0,'',0,0,12,12,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(15,'2025-03-24 20:42:07','2025-03-24 20:42:07',NULL,1,NULL,'','testRestContact','testRestContact1651950284','','','',NULL,NULL,NULL,'','','','','','','null',NULL,0,'',0,0,12,12,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(16,'2025-03-25 19:02:11','2025-03-25 19:02:11',3,1,NULL,'','Contact span1','','','','',NULL,4,NULL,'','','','','','','[]',NULL,0,'',0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL),
(17,'2025-03-25 19:02:19','2025-03-25 19:02:19',3,1,NULL,'','Contact span2','','','','',NULL,4,NULL,'','','','','','','[]',NULL,0,'',0,0,12,12,'','',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,NULL);

--
-- Table structure for table `llx_socpeople_extrafields`
--

CREATE TABLE `llx_socpeople_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `ccc` varchar(255) DEFAULT NULL,
  `ddd` datetime DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_socpeople_extrafields` (`fk_object`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_socpeople_extrafields`
--

INSERT INTO `llx_socpeople_extrafields` VALUES
(1,'2025-03-25 22:37:24',6,NULL,'aazz','2025-03-03 23:00:00');

--
-- Table structure for table `llx_stock_mouvement`
--

CREATE TABLE `llx_stock_mouvement` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datem` datetime DEFAULT NULL,
  `fk_product` int(11) NOT NULL,
  `fk_entrepot` int(11) NOT NULL,
  `value` double DEFAULT NULL,
  `price` double(24,8) DEFAULT 0.00000000,
  `type_mouvement` smallint(6) DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `label` varchar(255) DEFAULT NULL,
  `fk_origin` int(11) DEFAULT NULL,
  `origintype` varchar(64) DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  `fk_projet` int(11) NOT NULL DEFAULT 0,
  `inventorycode` varchar(128) DEFAULT NULL,
  `batch` varchar(30) DEFAULT NULL,
  `eatby` date DEFAULT NULL,
  `sellby` date DEFAULT NULL,
  `fk_project` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_stock_mouvement_fk_product` (`fk_product`),
  KEY `idx_stock_mouvement_fk_entrepot` (`fk_entrepot`)
) ENGINE=InnoDB AUTO_INCREMENT=114 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_stock_mouvement`
--

INSERT INTO `llx_stock_mouvement` VALUES
(1,'2012-07-08 22:43:51','2012-07-09 00:43:51',2,2,1000,0.00000000,0,1,'Correct stock',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(3,'2012-07-10 22:56:18','2012-07-11 00:56:18',4,2,500,0.00000000,0,1,'Init',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(4,'2012-07-10 23:02:20','2012-07-11 01:02:20',4,2,500,0.00000000,0,1,'',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(5,'2012-07-11 16:49:44','2012-07-11 18:49:44',4,1,2,10.00000000,3,1,'',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(6,'2012-07-11 16:49:44','2012-07-11 18:49:44',1,1,4,0.00000000,3,1,'',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(7,'2015-01-19 17:22:48','2015-01-19 18:22:48',11,1,-1,0.00000000,2,1,'Facture cr&eacute;&eacute;e dans DoliPOS',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(8,'2015-01-19 17:22:48','2015-01-19 18:22:48',4,1,-1,5.00000000,2,1,'Facture cr&eacute;&eacute;e dans DoliPOS',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(9,'2015-01-19 17:22:48','2015-01-19 18:22:48',1,1,-2,0.00000000,2,1,'Facture cr&eacute;&eacute;e dans DoliPOS',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(10,'2015-01-19 17:31:10','2015-01-19 18:31:10',2,1,-1,0.00000000,2,1,'Facture cr&eacute;&eacute;e dans DoliPOS',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(11,'2015-01-19 17:31:58','2015-01-19 18:31:58',2,1,-1,0.00000000,2,1,'Facture cr&eacute;&eacute;e dans DoliPOS',NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL),
(12,'2018-07-30 13:39:31','2018-07-30 17:39:31',10,2,50,0.00000000,0,12,'Stock correction for product COMP-XP4523',0,'',NULL,0,NULL,'5599887766452',NULL,NULL,NULL),
(13,'2018-07-30 13:40:12','2018-07-30 17:40:12',10,2,60,0.00000000,0,12,'Stock correction for product COMP-XP4523',0,'',NULL,0,NULL,'4494487766452',NULL,NULL,NULL),
(14,'2018-07-30 13:40:39','2018-07-30 17:40:39',10,2,-35,0.00000000,1,12,'Stock transfer of product COMP-XP4523 into another warehouse',0,'',NULL,0,'160730174015','5599887766452',NULL,NULL,NULL),
(15,'2018-07-30 13:40:39','2018-07-30 17:40:39',10,1,35,0.00000000,0,12,'Stock transfer of product COMP-XP4523 into another warehouse',0,'',NULL,0,'160730174015','5599887766452',NULL,NULL,NULL),
(16,'2017-02-15 23:58:08','2017-02-16 03:58:08',10,1,-1,100.00000000,2,12,'Exp&eacute;dition SH1702-0002 valid&eacute;e',3,'shipping',NULL,0,NULL,'5599887766452',NULL,NULL,NULL),
(17,'2017-02-16 00:12:09','2017-02-16 04:12:09',10,1,1,0.00000000,3,12,'Exp&eacute;dition SH1702-0002 supprim&eacute;e',0,'',NULL,0,NULL,'5599887766452',NULL,NULL,NULL),
(18,'2020-01-02 20:57:29','2020-01-03 00:57:29',25,1,50,0.00000000,0,12,'Stock correction for product POS-APPLE',0,'',NULL,0,'200103005654',NULL,NULL,NULL,NULL),
(23,'2020-01-06 01:44:30','2020-01-06 05:44:30',25,1,-12,0.00000000,2,12,'Production MO1912-0002 - 2020-01-06 05:26:49',0,'',NULL,0,'MO1912-0002_20200106052649',NULL,NULL,NULL,NULL),
(24,'2020-01-06 01:44:30','2020-01-06 05:44:30',4,2,3,0.00000000,3,12,'Production MO1912-0002 - 2020-01-06 05:26:49',0,'',NULL,0,'MO1912-0002_20200106052649',NULL,'2020-01-06',NULL,NULL),
(25,'2020-01-06 01:54:05','2020-01-06 05:54:05',25,1,-2,0.00000000,2,12,'Production MO1912-0002 - 2020-01-06 05:53:52',0,'',NULL,0,'MO1912-0002_20200106055352',NULL,NULL,NULL,NULL),
(26,'2020-01-06 01:54:05','2020-01-06 05:54:05',4,2,3,0.00000000,3,12,'Production MO1912-0002 - 2020-01-06 05:53:52',0,'',NULL,0,'MO1912-0002_20200106055352',NULL,'2020-01-06',NULL,NULL),
(27,'2020-01-06 02:44:49','2020-01-06 06:44:49',25,1,-1,0.00000000,2,12,'Production MO2001-0003 - 2020-01-06 06:44:37',0,'',NULL,0,'MO2001-0003',NULL,NULL,NULL,NULL),
(28,'2020-01-06 02:44:49','2020-01-06 06:44:49',4,1,1,0.00000000,3,12,'Production MO2001-0003 - 2020-01-06 06:44:37',0,'',NULL,0,'MO2001-0003',NULL,'2020-01-06',NULL,NULL),
(29,'2020-01-06 02:46:03','2020-01-06 06:46:03',25,1,-1,0.00000000,2,12,'Production MO2001-0003 - 2020-01-06 06:45:53',0,'',NULL,0,'MO2001-0003',NULL,NULL,NULL,NULL),
(30,'2020-01-06 02:46:03','2020-01-06 06:46:03',4,1,1,0.00000000,3,12,'Production MO2001-0003 - 2020-01-06 06:45:53',0,'',NULL,0,'MO2001-0003',NULL,'2020-01-06',NULL,NULL),
(31,'2020-01-06 02:48:22','2020-01-06 06:48:22',25,1,-1,0.00000000,2,12,'Production MO2001-0003 - 2020-01-06 06:48:11',0,'',NULL,0,'MO2001-0003',NULL,NULL,NULL,NULL),
(32,'2020-01-06 02:48:22','2020-01-06 06:48:22',4,1,1,0.00000000,3,12,'Production MO2001-0003 - 2020-01-06 06:48:11',0,'',NULL,0,'MO2001-0003',NULL,'2020-01-06',NULL,NULL),
(33,'2020-01-06 02:50:05','2020-01-06 06:50:05',25,1,-1,0.00000000,2,12,'Production MO2001-0003 - 2020-01-06 06:49:57',0,'',NULL,0,'MO2001-0003',NULL,NULL,NULL,NULL),
(34,'2020-01-06 02:50:05','2020-01-06 06:50:05',4,1,1,0.00000000,3,12,'Production MO2001-0003 - 2020-01-06 06:49:57',0,'',NULL,0,'MO2001-0003',NULL,'2020-01-06',NULL,NULL),
(35,'2020-01-07 16:25:02','2020-01-07 20:25:02',25,1,-2,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 20:24:49',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(36,'2020-01-07 16:25:02','2020-01-07 20:25:02',4,2,1,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 20:24:49',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(37,'2020-01-07 17:12:37','2020-01-07 21:12:37',25,1,0,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 21:12:26',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(38,'2020-01-07 17:12:37','2020-01-07 21:12:37',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:12:26',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(39,'2020-01-07 17:13:00','2020-01-07 21:13:00',25,1,0,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 21:12:58',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(40,'2020-01-07 17:13:00','2020-01-07 21:13:00',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:12:58',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(41,'2020-01-07 17:13:49','2020-01-07 21:13:49',25,1,0,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 21:12:58',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(42,'2020-01-07 17:13:49','2020-01-07 21:13:49',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:12:58',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(43,'2020-01-07 17:46:58','2020-01-07 21:46:58',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:46:55',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(44,'2020-01-07 17:52:34','2020-01-07 21:52:34',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:52:28',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(45,'2020-01-07 17:53:44','2020-01-07 21:53:44',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:52:37',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(46,'2020-01-07 17:53:58','2020-01-07 21:53:58',25,1,-1,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 21:53:46',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(47,'2020-01-07 17:53:58','2020-01-07 21:53:58',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:53:46',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(48,'2020-01-07 17:54:11','2020-01-07 21:54:11',25,1,-1,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 21:54:00',0,'',NULL,0,'MO1912-0002',NULL,NULL,NULL,NULL),
(49,'2020-01-07 17:54:12','2020-01-07 21:54:12',4,2,0,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 21:54:00',0,'',NULL,0,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(51,'2020-01-07 18:00:55','2020-01-07 22:00:55',25,1,-1,0.00000000,2,12,'Production MO1912-0002 - 2020-01-07 22:00:40',5,'mo',NULL,7,'MO1912-0002',NULL,NULL,NULL,NULL),
(52,'2020-01-07 18:00:55','2020-01-07 22:00:55',4,1,1,0.00000000,3,12,'Production MO1912-0002 - 2020-01-07 22:00:40',5,'mo',NULL,7,'MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(53,'2020-01-07 18:39:52','2020-01-07 22:39:52',25,1,-1,0.00000000,2,12,'Production MO2001-0003 - 2020-01-07 22:39:38',14,'mo',NULL,0,'MO2001-0003',NULL,NULL,NULL,NULL),
(54,'2020-01-07 18:39:52','2020-01-07 22:39:52',4,1,2,0.00000000,3,12,'Production MO2001-0003 - 2020-01-07 22:39:38',14,'mo',NULL,0,'MO2001-0003',NULL,'2020-01-07',NULL,NULL),
(55,'2020-01-07 19:09:04','2020-01-07 23:09:04',25,1,-2,0.00000000,2,12,'Production of MO2001-0003',14,'mo',NULL,0,'Production of MO2001-0003',NULL,NULL,NULL,NULL),
(56,'2020-01-07 19:09:04','2020-01-07 23:09:04',4,1,4,0.00000000,3,12,'Production of MO2001-0003',14,'mo',NULL,0,'Production of MO2001-0003',NULL,'2020-01-07',NULL,NULL),
(57,'2020-01-07 19:50:40','2020-01-07 23:50:40',25,1,-1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(58,'2020-01-07 19:50:40','2020-01-07 23:50:40',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(59,'2020-01-07 19:51:27','2020-01-07 23:51:27',25,1,-1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(60,'2020-01-07 19:51:27','2020-01-07 23:51:27',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-07',NULL,NULL),
(61,'2020-01-07 20:25:23','2020-01-08 00:25:23',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-08',NULL,NULL),
(62,'2020-01-07 20:25:43','2020-01-08 00:25:43',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-08',NULL,NULL),
(63,'2020-01-07 20:29:24','2020-01-08 00:29:24',25,1,-1.1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(64,'2020-01-07 20:29:24','2020-01-08 00:29:24',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-08',NULL,NULL),
(65,'2020-01-07 20:29:43','2020-01-08 00:29:43',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-08',NULL,NULL),
(66,'2020-01-07 21:09:15','2020-01-08 01:09:15',25,1,-1.1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(67,'2020-01-07 21:09:15','2020-01-08 01:09:15',4,2,0,0.00000000,3,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,'2020-01-08',NULL,NULL),
(68,'2020-01-07 21:15:02','2020-01-08 01:15:02',25,1,-1.1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(69,'2020-01-07 21:17:16','2020-01-08 01:17:16',25,1,-1.1,0.00000000,2,12,'Production of MO1912-0002',5,'mo',NULL,7,'Production of MO1912-0002',NULL,NULL,NULL,NULL),
(70,'2020-01-08 16:21:22','2020-01-08 20:21:22',25,1,-1,0.00000000,2,12,'Production of MO2001-0005',28,'mo',NULL,0,'Production of MO2001-0005',NULL,NULL,NULL,NULL),
(73,'2020-01-08 16:41:18','2020-01-08 20:41:18',1,1,-1.1,0.00000000,2,12,'Production of MO2001-0005',28,'mo',NULL,0,'Production of MO2001-0005','000000',NULL,NULL,NULL),
(74,'2020-01-08 16:41:18','2020-01-08 20:41:18',4,1,1.2,0.00000000,3,12,'Production of MO2001-0005',28,'mo',NULL,0,'Production of MO2001-0005','aaa',NULL,NULL,NULL),
(75,'2020-01-13 11:13:19','2020-01-13 15:13:19',25,1,-1,0.00000000,2,12,'Production of MO2001-0006',24,'mo',NULL,6,'Production of MO2001-0006',NULL,NULL,NULL,NULL),
(76,'2020-01-13 11:14:15','2020-01-13 15:14:15',1,1,-0.1,0.00000000,2,12,'Production of MO2001-0006',24,'mo',NULL,6,'Production of MO2001-0006','000000',NULL,NULL,NULL),
(77,'2020-01-18 19:16:58','2020-01-18 20:16:58',1,1,1,0.00000000,3,12,'string',0,'',NULL,0,'string','string',NULL,NULL,NULL),
(78,'2020-01-18 19:17:03','2020-01-18 20:17:03',1,1,1,0.00000000,3,12,'string',0,'',NULL,0,'string','string',NULL,NULL,NULL),
(79,'2021-04-15 11:40:18','2021-04-15 08:40:18',4,20,1,10.00000000,3,12,'Reception RCP2104-0001 validated',1,'reception',NULL,0,NULL,'Lot 2021-02',NULL,NULL,NULL),
(80,'2025-03-19 11:34:38','2025-03-19 11:34:38',1,1,-24,0.00000000,1,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(81,'2025-03-19 11:34:38','2025-03-19 11:34:38',1,1,24,0.00000000,0,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(82,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,2,-2014,0.00000000,1,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(83,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,2,2014,0.00000000,0,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(84,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,1,-2.4,0.00000000,1,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(85,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,1,2.4,0.00000000,0,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(86,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,20,-2,0.00000000,1,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(87,'2025-03-19 11:34:39','2025-03-19 11:34:39',1,20,2,0.00000000,0,12,'Le stock par lots est transf&eacute;r&eacute; vers le stock global (le produit n\'utilise plus de lots)',0,'',NULL,0,'20250319113438',NULL,NULL,NULL,NULL),
(88,'2025-01-17 08:36:03','2025-01-17 09:36:03',25,1,-1,0.00000000,2,12,'TakePOS - Facture TC2-2501-0001',461,'facture',NULL,0,'20250117093603','',NULL,NULL,NULL),
(89,'2025-01-17 08:36:03','2025-01-17 09:36:03',26,1,-1,0.00000000,2,12,'TakePOS - Facture TC2-2501-0001',461,'facture',NULL,0,'20250117093603','',NULL,NULL,NULL),
(90,'2025-02-05 14:37:58','2025-02-05 15:37:58',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0010',463,'facture',NULL,0,'20250205153758','',NULL,NULL,NULL),
(91,'2025-02-05 14:37:58','2025-02-05 15:37:58',25,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0010',463,'facture',NULL,0,'20250205153758','',NULL,NULL,NULL),
(92,'2025-02-05 14:38:19','2025-02-05 15:38:19',24,2,-5,0.00000000,2,12,'TakePOS - Facture TC1-2502-0011',464,'facture',NULL,0,'20250205153819','',NULL,NULL,NULL),
(93,'2025-02-05 14:39:09','2025-02-05 15:39:09',25,2,-6,0.00000000,2,12,'TakePOS - Facture TC1-2502-0012',465,'facture',NULL,0,'20250205153909','',NULL,NULL,NULL),
(94,'2025-02-05 14:39:09','2025-02-05 15:39:09',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0012',465,'facture',NULL,0,'20250205153909','',NULL,NULL,NULL),
(95,'2025-02-05 14:39:50','2025-02-05 15:39:50',27,2,-3,0.00000000,2,12,'TakePOS - Facture TC1-2502-0013',466,'facture',NULL,0,'20250205153950','',NULL,NULL,NULL),
(96,'2025-02-05 14:39:50','2025-02-05 15:39:50',28,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0013',466,'facture',NULL,0,'20250205153950','',NULL,NULL,NULL),
(97,'2025-02-05 14:40:02','2025-02-05 15:40:02',27,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0014',467,'facture',NULL,0,'20250205154002','',NULL,NULL,NULL),
(98,'2025-02-05 14:40:02','2025-02-05 15:40:02',28,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0014',467,'facture',NULL,0,'20250205154002','',NULL,NULL,NULL),
(99,'2025-02-05 14:40:15','2025-02-05 15:40:15',25,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(100,'2025-02-05 14:40:15','2025-02-05 15:40:15',25,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(101,'2025-02-05 14:40:15','2025-02-05 15:40:15',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(102,'2025-02-05 14:40:15','2025-02-05 15:40:15',27,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(103,'2025-02-05 14:40:15','2025-02-05 15:40:15',28,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(104,'2025-02-05 14:40:15','2025-02-05 15:40:15',27,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0015',468,'facture',NULL,0,'20250205154015','',NULL,NULL,NULL),
(105,'2025-02-15 08:31:13','2025-02-15 09:31:13',25,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0016',469,'facture',NULL,0,'20250215093113','',NULL,NULL,NULL),
(106,'2025-02-15 08:31:13','2025-02-15 09:31:13',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0016',469,'facture',NULL,0,'20250215093113','',NULL,NULL,NULL),
(107,'2025-02-15 08:31:19','2025-02-15 09:31:19',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0017',470,'facture',NULL,0,'20250215093119','',NULL,NULL,NULL),
(108,'2025-02-15 08:31:19','2025-02-15 09:31:19',26,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0017',470,'facture',NULL,0,'20250215093119','',NULL,NULL,NULL),
(109,'2025-02-15 08:31:26','2025-02-15 09:31:26',30,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2502-0018',471,'facture',NULL,0,'20250215093126','',NULL,NULL,NULL),
(110,'2025-03-05 08:32:24','2025-03-05 09:32:24',28,2,-10,0.00000000,2,12,'TakePOS - Facture TC1-2503-0019',472,'facture',NULL,0,'20250305093224','',NULL,NULL,NULL),
(111,'2025-03-05 08:33:00','2025-03-05 09:33:00',28,2,-10,0.00000000,2,12,'TakePOS - Facture TC1-2503-0019',472,'facture',NULL,0,'20250305093300','',NULL,NULL,NULL),
(112,'2025-03-05 08:33:07','2025-03-05 09:33:07',28,2,-10,0.00000000,2,12,'TakePOS - Facture TC1-2503-0019',472,'facture',NULL,0,'20250305093307','',NULL,NULL,NULL),
(113,'2025-03-15 09:59:40','2025-03-15 10:59:40',28,2,-1,0.00000000,2,12,'TakePOS - Facture TC1-2503-0020',475,'facture',NULL,0,'20250315105940','',NULL,NULL,NULL);

--
-- Table structure for table `llx_stock_mouvement_extrafields`
--

CREATE TABLE `llx_stock_mouvement_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_stock_mouvement_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_stock_mouvement_extrafields`
--


--
-- Table structure for table `llx_stocktransfer_stocktransfer`
--

CREATE TABLE `llx_stocktransfer_stocktransfer` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref` varchar(128) NOT NULL DEFAULT '(PROV)',
  `label` varchar(255) DEFAULT NULL,
  `fk_soc` int(11) DEFAULT NULL,
  `fk_project` int(11) DEFAULT NULL,
  `fk_warehouse_source` int(11) DEFAULT NULL,
  `fk_warehouse_destination` int(11) DEFAULT NULL,
  `description` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `tms` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `date_creation` datetime NOT NULL,
  `date_prevue_depart` date DEFAULT NULL,
  `date_reelle_depart` date DEFAULT NULL,
  `date_prevue_arrivee` date DEFAULT NULL,
  `date_reelle_arrivee` date DEFAULT NULL,
  `lead_time_for_warning` int(11) DEFAULT NULL,
  `fk_user_creat` int(11) NOT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  `last_main_doc` varchar(255) DEFAULT NULL,
  `status` smallint(6) NOT NULL,
  `fk_incoterms` int(11) DEFAULT NULL,
  `location_incoterms` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_stocktransfer_stocktransfer_rowid` (`rowid`),
  KEY `idx_stocktransfer_stocktransfer_ref` (`ref`),
  KEY `idx_stocktransfer_stocktransfer_fk_soc` (`fk_soc`),
  KEY `idx_stocktransfer_stocktransfer_fk_project` (`fk_project`),
  KEY `llx_stocktransfer_stocktransfer_fk_user_creat` (`fk_user_creat`),
  KEY `idx_stocktransfer_stocktransfer_status` (`status`),
  CONSTRAINT `llx_stocktransfer_stocktransfer_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_stocktransfer_stocktransfer`
--


--
-- Table structure for table `llx_stocktransfer_stocktransfer_extrafields`
--

CREATE TABLE `llx_stocktransfer_stocktransfer_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_fk_object` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_stocktransfer_stocktransfer_extrafields`
--


--
-- Table structure for table `llx_stocktransfer_stocktransferline`
--

CREATE TABLE `llx_stocktransfer_stocktransferline` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `amount` double DEFAULT NULL,
  `qty` double DEFAULT NULL,
  `fk_warehouse_source` int(11) NOT NULL,
  `fk_warehouse_destination` int(11) NOT NULL,
  `fk_stocktransfer` int(11) NOT NULL,
  `fk_product` int(11) NOT NULL,
  `batch` varchar(128) DEFAULT NULL,
  `pmp` double DEFAULT NULL,
  `rang` int(11) DEFAULT 0,
  `fk_parent_line` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_stocktransfer_stocktransferline_rowid` (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_stocktransfer_stocktransferline`
--


--
-- Table structure for table `llx_stocktransfer_stocktransferline_extrafields`
--

CREATE TABLE `llx_stocktransfer_stocktransferline_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_fk_object` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_stocktransfer_stocktransferline_extrafields`
--


--
-- Table structure for table `llx_subscription`
--

CREATE TABLE `llx_subscription` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `fk_adherent` int(11) DEFAULT NULL,
  `dateadh` datetime DEFAULT NULL,
  `datef` datetime DEFAULT NULL,
  `subscription` double(24,8) DEFAULT NULL,
  `fk_bank` int(11) DEFAULT NULL,
  `note` text DEFAULT NULL,
  `fk_type` int(11) DEFAULT NULL,
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_valid` int(11) DEFAULT NULL,
  `ref_ext` varchar(128) DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_subscription` (`fk_adherent`,`dateadh`),
  KEY `idx_subscription_fk_adherent` (`fk_adherent`),
  KEY `idx_subscription_fk_bank` (`fk_bank`),
  KEY `idx_subscription_dateadh` (`dateadh`)
) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_subscription`
--

INSERT INTO `llx_subscription` VALUES
(2,'2020-01-21 00:02:14','2020-01-21 01:02:14',3,'2013-07-18 00:00:00','2014-07-17 00:00:00',50.00000000,51,'Subscription 2013',2,NULL,NULL,NULL,NULL,NULL),
(3,'2020-01-21 09:22:37','2020-01-21 10:22:37',4,'2017-07-18 00:00:00','2018-07-17 00:00:00',50.00000000,52,'Subscription 2017',2,NULL,NULL,NULL,NULL,NULL),
(4,'2020-01-21 09:23:17','2020-01-21 10:23:17',2,'2017-07-18 00:00:00','2018-07-17 00:00:00',50.00000000,53,'Subscription 2017',2,NULL,NULL,NULL,NULL,NULL),
(5,'2020-01-21 09:23:28','2020-01-21 10:23:28',2,'2018-07-18 00:00:00','2019-07-17 00:00:00',50.00000000,54,'Subscription 2018',2,NULL,NULL,NULL,NULL,NULL),
(6,'2020-01-21 09:23:49','2020-01-21 10:23:49',2,'2019-07-18 00:00:00','2020-07-17 00:00:00',50.00000000,55,'Subscription 2019',2,NULL,NULL,NULL,NULL,NULL),
(11,'2025-01-16 09:07:13','2025-01-16 10:07:13',15,'2025-01-16 00:00:00','2026-01-15 00:00:00',11.00000000,98,'Adhésion / cotisation 2025',1,12,NULL,NULL,'',NULL);

--
-- Table structure for table `llx_supplier_proposal`
--

CREATE TABLE `llx_supplier_proposal` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `ref` varchar(30) NOT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref_ext` varchar(255) DEFAULT NULL,
  `ref_int` varchar(255) DEFAULT NULL,
  `fk_soc` int(11) DEFAULT NULL,
  `fk_projet` int(11) DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` datetime DEFAULT NULL,
  `date_valid` datetime DEFAULT NULL,
  `date_cloture` datetime DEFAULT NULL,
  `fk_user_author` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `fk_user_valid` int(11) DEFAULT NULL,
  `fk_user_cloture` int(11) DEFAULT NULL,
  `fk_statut` smallint(6) NOT NULL DEFAULT 0,
  `price` double DEFAULT 0,
  `remise_percent` double DEFAULT 0,
  `remise_absolue` double DEFAULT 0,
  `remise` double DEFAULT 0,
  `total_ht` double(24,8) DEFAULT 0.00000000,
  `total_tva` double(24,8) DEFAULT 0.00000000,
  `localtax1` double(24,8) DEFAULT 0.00000000,
  `localtax2` double(24,8) DEFAULT 0.00000000,
  `total_ttc` double(24,8) DEFAULT 0.00000000,
  `fk_account` int(11) DEFAULT NULL,
  `fk_currency` varchar(3) DEFAULT NULL,
  `fk_cond_reglement` int(11) DEFAULT NULL,
  `deposit_percent` varchar(63) DEFAULT NULL,
  `fk_mode_reglement` int(11) DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  `date_livraison` date DEFAULT NULL,
  `fk_shipping_method` int(11) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `extraparams` varchar(255) DEFAULT NULL,
  `fk_multicurrency` int(11) DEFAULT NULL,
  `multicurrency_code` varchar(3) DEFAULT NULL,
  `multicurrency_tx` double(24,8) DEFAULT 1.00000000,
  `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000,
  `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000,
  `multicurrency_total_ttc` double(24,8) DEFAULT 0.00000000,
  `last_main_doc` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_supplier_proposal_ref` (`ref`,`entity`),
  KEY `idx_supplier_proposal_fk_soc` (`fk_soc`),
  KEY `idx_supplier_proposal_fk_user_author` (`fk_user_author`),
  KEY `idx_supplier_proposal_fk_user_valid` (`fk_user_valid`),
  KEY `idx_supplier_proposal_fk_projet` (`fk_projet`),
  KEY `idx_supplier_proposal_fk_account` (`fk_account`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_supplier_proposal`
--

INSERT INTO `llx_supplier_proposal` VALUES
(2,'(PROV2)',1,NULL,NULL,10,NULL,'2026-02-15 18:44:54','2024-02-17 04:40:14',NULL,NULL,12,12,NULL,NULL,0,0,NULL,NULL,0,285.00000000,0.00000000,0.00000000,0.00000000,285.00000000,NULL,NULL,2,NULL,7,'Private note','Public note','aurore','2017-02-17',1,NULL,NULL,1,'EUR',1.00000000,285.00000000,0.00000000,285.00000000,'supplier_proposal/(PROV2)/(PROV2).pdf'),
(3,'(PROV3)',1,NULL,NULL,1,NULL,'2026-02-15 18:44:54','2024-01-20 12:06:39',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL),
(4,'(PROV4)',1,NULL,NULL,17,NULL,'2026-02-15 18:44:54','2024-01-20 12:23:22',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,198.00000000,0.17000000,0.00000000,0.00000000,198.17000000,NULL,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,198.00000000,0.17000000,198.17000000,'supplier_proposal/(PROV4)/(PROV4).pdf');

--
-- Table structure for table `llx_supplier_proposal_extrafields`
--

CREATE TABLE `llx_supplier_proposal_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_supplier_proposal_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_supplier_proposal_extrafields`
--


--
-- Table structure for table `llx_supplier_proposaldet`
--

CREATE TABLE `llx_supplier_proposaldet` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_supplier_proposal` int(11) NOT NULL,
  `fk_parent_line` int(11) DEFAULT NULL,
  `fk_product` int(11) DEFAULT NULL,
  `label` varchar(255) DEFAULT NULL,
  `description` text DEFAULT NULL,
  `fk_remise_except` int(11) DEFAULT NULL,
  `tva_tx` double(6,3) DEFAULT 0.000,
  `vat_src_code` varchar(10) DEFAULT '',
  `localtax1_tx` double(6,3) DEFAULT 0.000,
  `localtax1_type` varchar(10) DEFAULT NULL,
  `localtax2_tx` double(6,3) DEFAULT 0.000,
  `localtax2_type` varchar(10) DEFAULT NULL,
  `qty` double DEFAULT NULL,
  `remise_percent` double DEFAULT 0,
  `remise` double DEFAULT 0,
  `price` double DEFAULT NULL,
  `subprice` double(24,8) DEFAULT 0.00000000,
  `subprice_ttc` double(24,8) DEFAULT 0.00000000,
  `total_ht` double(24,8) DEFAULT 0.00000000,
  `total_tva` double(24,8) DEFAULT 0.00000000,
  `total_localtax1` double(24,8) DEFAULT 0.00000000,
  `total_localtax2` double(24,8) DEFAULT 0.00000000,
  `total_ttc` double(24,8) DEFAULT 0.00000000,
  `product_type` int(11) DEFAULT 0,
  `info_bits` int(11) DEFAULT 0,
  `buy_price_ht` double(24,8) DEFAULT 0.00000000,
  `fk_product_fournisseur_price` int(11) DEFAULT NULL,
  `special_code` int(11) DEFAULT 0,
  `rang` int(11) DEFAULT 0,
  `ref_fourn` varchar(128) DEFAULT NULL,
  `fk_multicurrency` int(11) DEFAULT NULL,
  `multicurrency_code` varchar(3) DEFAULT NULL,
  `multicurrency_subprice` double(24,8) DEFAULT 0.00000000,
  `multicurrency_subprice_ttc` double(24,8) DEFAULT 0.00000000,
  `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000,
  `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000,
  `multicurrency_total_ttc` double(24,8) DEFAULT 0.00000000,
  `fk_unit` int(11) DEFAULT NULL,
  `date_start` datetime DEFAULT NULL,
  `date_end` datetime DEFAULT NULL,
  `extraparams` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_supplier_proposaldet_fk_supplier_proposal` (`fk_supplier_proposal`),
  KEY `idx_supplier_proposaldet_fk_product` (`fk_product`),
  KEY `fk_supplier_proposaldet_fk_unit` (`fk_unit`),
  CONSTRAINT `fk_supplier_proposaldet_fk_supplier_proposal` FOREIGN KEY (`fk_supplier_proposal`) REFERENCES `llx_supplier_proposal` (`rowid`),
  CONSTRAINT `fk_supplier_proposaldet_fk_unit` FOREIGN KEY (`fk_unit`) REFERENCES `llx_c_units` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_supplier_proposaldet`
--

INSERT INTO `llx_supplier_proposaldet` VALUES
(2,2,NULL,NULL,NULL,'A powerfull computer with 8Gb memory.',NULL,0.000,'',0.000,'0',0.000,'0',1,0,0,NULL,200.00000000,0.00000000,200.00000000,0.00000000,0.00000000,0.00000000,200.00000000,0,0,0.00000000,NULL,0,1,'',1,'EUR',200.00000000,0.00000000,200.00000000,0.00000000,200.00000000,NULL,NULL,NULL,NULL),
(7,3,NULL,1,NULL,'A beatifull pink dress 2',NULL,12.500,'',0.000,'0',0.000,'0',1,0,0,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0,0,0.00000000,NULL,0,1,NULL,1,'EUR',0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),
(9,2,NULL,1,'Pink dress','A beatifull pink dress',NULL,0.000,'',0.000,'0',0.000,'0',1,10,0,NULL,100.00000000,0.00000000,90.00000000,0.00000000,0.00000000,0.00000000,90.00000000,0,0,79.16667000,3,0,2,'aaa',1,'EUR',100.00000000,0.00000000,90.00000000,0.00000000,90.00000000,NULL,NULL,NULL,NULL),
(10,4,NULL,1,NULL,'A beatifull pink dress. 2',NULL,0.000,'',0.000,'0',0.000,'0',1,0,0,NULL,95.00000000,0.00000000,95.00000000,0.00000000,0.00000000,0.00000000,95.00000000,0,0,0.00000000,NULL,0,1,'BK01',1,'EUR',95.00000000,0.00000000,95.00000000,0.00000000,95.00000000,NULL,NULL,NULL,NULL),
(11,4,NULL,1,'Pink dress','A beatifull pink dress',NULL,0.000,'',0.000,'0',0.000,'0',1,0,0,NULL,100.00000000,0.00000000,100.00000000,0.00000000,0.00000000,0.00000000,100.00000000,0,0,79.16667000,7,0,2,'bbb',1,'EUR',100.00000000,0.00000000,100.00000000,0.00000000,100.00000000,NULL,NULL,NULL,NULL),
(17,4,NULL,NULL,NULL,'a',NULL,5.500,'bbb',0.000,'0',0.000,'0',1,0,0,NULL,1.00000000,0.00000000,1.00000000,0.06000000,0.00000000,0.00000000,1.06000000,0,0,0.00000000,NULL,0,3,'',1,'EUR',1.00000000,0.00000000,1.00000000,0.06000000,1.06000000,NULL,NULL,NULL,NULL),
(18,4,NULL,NULL,NULL,'a',NULL,5.500,'bbb',0.000,'0',0.000,'0',1,0,0,NULL,2.00000000,0.00000000,2.00000000,0.11000000,0.00000000,0.00000000,2.11000000,0,0,0.00000000,NULL,0,4,NULL,1,'EUR',2.00000000,0.00000000,2.00000000,0.11000000,2.11000000,NULL,NULL,NULL,NULL),
(19,2,NULL,NULL,NULL,'aaa',NULL,0.000,'',0.000,'',0.000,'',1,0,0,NULL,-5.00000000,0.00000000,-5.00000000,0.00000000,0.00000000,0.00000000,-5.00000000,0,0,0.00000000,NULL,0,3,'',1,'EUR',-5.00000000,0.00000000,-5.00000000,0.00000000,-5.00000000,1,NULL,NULL,NULL);

--
-- Table structure for table `llx_supplier_proposaldet_extrafields`
--

CREATE TABLE `llx_supplier_proposaldet_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_supplier_proposaldet_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_supplier_proposaldet_extrafields`
--


--
-- Table structure for table `llx_takepos_floor_tables`
--

CREATE TABLE `llx_takepos_floor_tables` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `label` varchar(255) DEFAULT NULL,
  `leftpos` float DEFAULT NULL,
  `toppos` float DEFAULT NULL,
  `floor` int(3) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `entity` (`entity`,`label`),
  UNIQUE KEY `entity_2` (`entity`,`label`),
  UNIQUE KEY `entity_3` (`entity`,`label`),
  UNIQUE KEY `entity_4` (`entity`,`label`),
  UNIQUE KEY `uk_takepos_floor_tables` (`entity`,`label`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_takepos_floor_tables`
--


--
-- Table structure for table `llx_ticket`
--

CREATE TABLE `llx_ticket` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) DEFAULT 1,
  `ref` varchar(128) NOT NULL,
  `track_id` varchar(128) NOT NULL,
  `fk_soc` int(11) DEFAULT 0,
  `fk_project` int(11) DEFAULT 0,
  `fk_contract` int(11) DEFAULT 0,
  `origin_email` varchar(128) DEFAULT NULL,
  `fk_user_create` int(11) DEFAULT NULL,
  `fk_user_assign` int(11) DEFAULT NULL,
  `subject` varchar(255) DEFAULT NULL,
  `message` mediumtext DEFAULT NULL,
  `fk_statut` int(11) DEFAULT NULL,
  `resolution` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `progress` int(11) DEFAULT NULL,
  `timing` varchar(20) DEFAULT NULL,
  `type_code` varchar(32) DEFAULT NULL,
  `category_code` varchar(32) DEFAULT NULL,
  `severity_code` varchar(32) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `date_read` datetime DEFAULT NULL,
  `date_last_msg_sent` datetime DEFAULT NULL,
  `date_close` datetime DEFAULT NULL,
  `notify_tiers_at_create` tinyint(4) DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `import_key` varchar(14) DEFAULT NULL,
  `email_msgid` varchar(255) DEFAULT NULL,
  `email_date` datetime DEFAULT NULL,
  `ip` varchar(250) DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  `last_main_doc` varchar(255) DEFAULT NULL,
  `extraparams` varchar(255) DEFAULT NULL,
  `barcode` varchar(255) DEFAULT NULL,
  `fk_barcode_type` int(11) DEFAULT NULL,
  `origin_replyto` varchar(128) DEFAULT NULL,
  `origin_references` text DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_ticket_track_id` (`track_id`),
  UNIQUE KEY `uk_ticket_ref` (`ref`,`entity`),
  UNIQUE KEY `uk_ticket_barcode_barcode_type` (`barcode`,`fk_barcode_type`,`entity`),
  KEY `idx_ticket_entity` (`entity`),
  KEY `idx_ticket_fk_soc` (`fk_soc`),
  KEY `idx_ticket_fk_user_assign` (`fk_user_assign`),
  KEY `idx_ticket_fk_project` (`fk_project`),
  KEY `idx_ticket_fk_statut` (`fk_statut`),
  KEY `llx_ticket_fk_product_barcode_type` (`fk_barcode_type`),
  CONSTRAINT `llx_ticket_fk_product_barcode_type` FOREIGN KEY (`fk_barcode_type`) REFERENCES `llx_c_barcode_type` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_ticket`
--

INSERT INTO `llx_ticket` VALUES
(2,1,'TS1909-0001','15ff11cay39skiaa',NULL,6,0,NULL,12,12,'Increase memory on server','Pleae increase the memory of server to 164GB',3,NULL,NULL,NULL,NULL,0,NULL,'REQUEST','OTHER','NORMAL','2024-09-26 14:08:46',NULL,NULL,NULL,0,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(3,1,'TS1909-0002','r5ya6gdi9f39dcjt',1,NULL,0,NULL,12,14,'Problem with customer','Please recontact customer.<br />\r\nNeed someone speaking chinese...',0,NULL,NULL,NULL,NULL,100,'NORMAL','ISSUE','OTHER','NORMAL','2024-09-26 14:10:31',NULL,NULL,'2024-10-04 13:05:55',0,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(4,1,'TS1910-0003','fdv9wrzcte7b3c8b',NULL,NULL,0,NULL,12,NULL,'test','test',2,NULL,NULL,NULL,NULL,0,NULL,'COM','OTHER','NORMAL','2024-10-04 12:58:04',NULL,NULL,NULL,0,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(6,1,'TS1911-0004','5gvo9bsjri55zef9',32,4,0,NULL,12,3,'What is the price for Dolibarr ERP CRM ?','I need to use it for 10 users.',2,NULL,NULL,NULL,NULL,0,NULL,'COM','OTHER','NORMAL','2024-11-29 12:46:29','2024-11-29 12:46:34',NULL,NULL,0,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(7,1,'TS1911-0005','d51wjy4nym7wltg7',NULL,NULL,0,'customer@customercompany.com',NULL,16,'What is the price for Dolibarr ERP CRM ?','I need it for 10 people...',8,NULL,NULL,NULL,NULL,100,NULL,'COM','OTHER','NORMAL','2024-11-29 12:50:45','2024-11-29 12:52:32',NULL,'2025-03-13 06:17:35',1,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(9,1,'TS2505-0006','7l6k1qo8qif1fzca',NULL,NULL,NULL,NULL,12,12,'aaaa','aaaa',2,NULL,NULL,NULL,NULL,0,'NORMAL','COM','OTHER','NORMAL','2024-05-27 11:09:44',NULL,NULL,NULL,0,'2026-02-15 18:44:54',NULL,NULL,NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL);

--
-- Table structure for table `llx_ticket_extrafields`
--

CREATE TABLE `llx_ticket_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `aaa` int(10) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_ticket_extrafields` (`fk_object`),
  KEY `idx_ticket_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_ticket_extrafields`
--


--
-- Table structure for table `llx_ticketsup_extrafields`
--

CREATE TABLE `llx_ticketsup_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;

--
-- Dumping data for table `llx_ticketsup_extrafields`
--


--
-- Table structure for table `llx_ticketsup_logs`
--

CREATE TABLE `llx_ticketsup_logs` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) DEFAULT 1,
  `fk_track_id` varchar(128) DEFAULT NULL,
  `fk_user_create` int(11) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `message` text DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `fk_ticketsup_logs_fk_track_id` (`fk_track_id`),
  CONSTRAINT `fk_ticketsup_logs_fk_track_id` FOREIGN KEY (`fk_track_id`) REFERENCES `llx_ticketsup` (`track_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci ROW_FORMAT=DYNAMIC;

--
-- Dumping data for table `llx_ticketsup_logs`
--


--
-- Table structure for table `llx_ticketsup_msg`
--

CREATE TABLE `llx_ticketsup_msg` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) DEFAULT 1,
  `fk_track_id` varchar(128) DEFAULT NULL,
  `fk_user_action` int(11) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `message` text DEFAULT NULL,
  `private` int(11) DEFAULT 0,
  PRIMARY KEY (`rowid`),
  KEY `fk_ticketsup_msg_fk_track_id` (`fk_track_id`),
  CONSTRAINT `fk_ticketsup_msg_fk_track_id` FOREIGN KEY (`fk_track_id`) REFERENCES `llx_ticketsup` (`track_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci ROW_FORMAT=DYNAMIC;

--
-- Dumping data for table `llx_ticketsup_msg`
--


--
-- Table structure for table `llx_tmptesttabletoremove`
--

CREATE TABLE `llx_tmptesttabletoremove` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `code` varchar(255) NOT NULL,
  `label` varchar(255) NOT NULL,
  `position` int(11) DEFAULT NULL,
  `use_default` varchar(1) DEFAULT '1',
  `active` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_tmptesttabletoremove`
--


--
-- Table structure for table `llx_tva`
--

CREATE TABLE `llx_tva` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `datec` date DEFAULT NULL,
  `datep` date DEFAULT NULL,
  `datev` date DEFAULT NULL,
  `amount` double(24,8) DEFAULT NULL,
  `label` varchar(255) DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `note` text DEFAULT NULL,
  `fk_bank` int(11) DEFAULT NULL,
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `fk_typepayment` int(11) DEFAULT NULL,
  `num_payment` varchar(50) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `paye` smallint(6) NOT NULL DEFAULT 0,
  `fk_account` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_tva`
--


--
-- Table structure for table `llx_user_alert`
--

CREATE TABLE `llx_user_alert` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `type` int(11) DEFAULT NULL,
  `fk_contact` int(11) DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_alert`
--

INSERT INTO `llx_user_alert` VALUES
(1,1,1,1),
(2,1,10,12);

--
-- Table structure for table `llx_user_clicktodial`
--

CREATE TABLE `llx_user_clicktodial` (
  `fk_user` int(11) NOT NULL,
  `url` varchar(255) DEFAULT NULL,
  `login` varchar(32) DEFAULT NULL,
  `pass` varchar(64) DEFAULT NULL,
  `poste` varchar(20) DEFAULT NULL,
  PRIMARY KEY (`fk_user`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_clicktodial`
--


--
-- Table structure for table `llx_user_employment`
--

CREATE TABLE `llx_user_employment` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref` varchar(50) DEFAULT NULL,
  `ref_ext` varchar(50) DEFAULT NULL,
  `fk_user` int(11) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `job` varchar(128) DEFAULT NULL,
  `status` int(11) NOT NULL,
  `salary` double(24,8) DEFAULT NULL,
  `salaryextra` double(24,8) DEFAULT NULL,
  `weeklyhours` double(16,8) DEFAULT NULL,
  `dateemployment` date DEFAULT NULL,
  `dateemploymentend` date DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_user_employment` (`ref`,`entity`),
  KEY `fk_user_employment_fk_user` (`fk_user`),
  CONSTRAINT `fk_user_employment_fk_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_employment`
--


--
-- Table structure for table `llx_user_extrafields`
--

CREATE TABLE `llx_user_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `rsapublicmain` text DEFAULT NULL,
  `ippublicmain` varchar(255) DEFAULT NULL,
  `aaa` varchar(255) DEFAULT NULL,
  `news_viewed` int(1) DEFAULT NULL,
  `eee` int(11) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_user_extrafields` (`fk_object`)
) ENGINE=InnoDB AUTO_INCREMENT=59 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_extrafields`
--

INSERT INTO `llx_user_extrafields` VALUES
(2,'2023-02-25 15:00:16',22,NULL,NULL,NULL,NULL,NULL,NULL),
(6,'2023-02-28 08:49:59',19,NULL,NULL,NULL,NULL,0,NULL),
(8,'2025-05-05 14:48:05',17,NULL,NULL,NULL,NULL,0,2),
(9,'2025-05-05 14:48:18',4,NULL,NULL,NULL,NULL,0,1),
(11,'2023-02-28 08:49:59',16,NULL,NULL,NULL,NULL,0,NULL),
(12,'2025-05-05 12:09:05',2,NULL,NULL,NULL,NULL,0,5),
(14,'2023-02-28 08:49:59',10,NULL,NULL,NULL,NULL,0,NULL),
(15,'2025-05-05 14:48:17',3,NULL,NULL,NULL,NULL,0,2),
(16,'2023-02-28 08:49:59',14,NULL,NULL,NULL,NULL,0,NULL),
(17,'2023-02-28 08:49:59',11,NULL,NULL,NULL,NULL,0,NULL),
(31,'2025-05-05 14:48:09',1,NULL,NULL,NULL,NULL,0,3),
(33,'2025-02-10 19:27:07',18,NULL,NULL,NULL,NULL,0,NULL),
(41,'2025-03-25 22:02:19',29,NULL,NULL,NULL,NULL,NULL,NULL),
(57,'2025-04-09 17:23:11',12,NULL,NULL,NULL,NULL,NULL,4),
(58,'2025-04-15 13:30:44',13,NULL,NULL,NULL,NULL,0,3);

--
-- Table structure for table `llx_user_param`
--

CREATE TABLE `llx_user_param` (
  `fk_user` int(11) NOT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `param` varchar(255) NOT NULL,
  `value` text NOT NULL,
  UNIQUE KEY `uk_user_param` (`fk_user`,`param`,`entity`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_param`
--

INSERT INTO `llx_user_param` VALUES
(1,1,'MAIN_BOXES_0','1'),
(1,1,'MAIN_THEME','eldy'),
(1,3,'THEME_ELDY_ENABLE_PERSONALIZED','1'),
(1,1,'THEME_ELDY_RGB','ded0ed'),
(1,3,'THEME_ELDY_RGB','d0ddc3'),
(2,1,'MAIN_BOXES_0','1'),
(11,1,'MAIN_BOXES_0','1'),
(12,1,'MAIN_BOXES_0','1'),
(12,1,'MAIN_BOXES_11','1'),
(12,1,'MAIN_BOXES_2','1'),
(12,1,'MAIN_BOXES_27','1'),
(12,1,'MAIN_LANG_DEFAULT','auto'),
(12,1,'MAIN_SELECTEDFIELDS_/dolibarr_4.0/htdocs/adherents/list.php','d.zip,d.ref,d.lastname,d.firstname,d.company,d.login,d.morphy,t.libelle,d.email,d.datefin,d.statut,'),
(12,1,'MAIN_SELECTEDFIELDS_accountancycustomerlist','l.rowid,f.ref,f.datef,p.ref,l.total_ht,l.tva_tx,s.nom,co.label,s.tva_intra,aa.data_suggest,aa.account_number,'),
(12,1,'MAIN_SELECTEDFIELDS_accountancysupplierlines','l.rowid,f.ref,f.datef,p.ref,l.description,l.total_ht,l.tva_tx,s.nom,co.label,s.tva_intra,aa.account_number,'),
(12,1,'MAIN_SELECTEDFIELDS_accountingaccountlist','categories,aa.account_number,aa.label,aa.labelshort,aa.account_parent,aa.pcg_type,aa.active,aa.import_key,'),
(12,1,'MAIN_SELECTEDFIELDS_cashcontrol','t.ref,t.posmodule,t.posnumber,t.opening,t.cash,t.cheque,t.card,t.year_close,t.month_close,t.day_close,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_conferenceorboothlist','t.fk_project,t.ref,t.label,t.fk_soc,t.fk_action,t.datep,t.datep2,t.num_vote,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_contractlist','ef.hostname_db,c.ref,c.ref_customer,c.ref_supplier,s.nom,s.zip,c.date_contrat,ef.plan,ef.deployment_status,ef.deployment_date_start,ef.deployment_date_end,ef.date_softalert_endfreeperiod,ef.date_hardalert_endfreeperiod,ef.date_endfreeperiod,ef.undeployment_date,ef.discountcode,lower_planned_end_date,status,'),
(12,1,'MAIN_SELECTEDFIELDS_customerlist','s.email,s.nom,s.name_alias,s.barcode,s.code_client,s.code_compta,s.zip,s.phone,typent.code,customerorsupplier,s.status,'),
(12,1,'MAIN_SELECTEDFIELDS_directdebitcredittransferlist','ref,label,datep,type,project,bank,entry,account,subledger,debit,credit,'),
(12,1,'MAIN_SELECTEDFIELDS_emailsenderprofilelist','t.tms,t.label,t.email,t.private,t.position,t.date_creation,t.active,'),
(12,1,'MAIN_SELECTEDFIELDS_inventorylist','t.fk_user_creat,t.ref,t.title,t.fk_warehouse,t.fk_product,t.date_inventory,t.fk_user_modif,t.fk_user_valid,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_invoicelist','f.module_source,f.pos_source,f.ref,f.datef,f.date_lim_reglement,p.ref,s.nom,f.total_ht,f.total_ttc,rtp,f.multicurrency_code,u.login,f.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_jobpositionlist','t.fk_user_creat,t.rowid,t.date_start,t.date_end,t.fk_user,t.fk_job,'),
(12,1,'MAIN_SELECTEDFIELDS_knowledgerecordlist','t.fk_c_ticket_category,t.ref,t.question,t.lang,t.tms,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_molist','t.ref,t.fk_bom,t.mrptype,t.fk_product,t.qty,t.label,t.fk_warehouse,t.date_start_planned,t.date_end_planned,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_orderlist','c.pos_source,c.module_source,c.ref,s.nom,c.date_commande,c.total_ht,ef.custom1,ef.aaa,c.note_public,c.note_private,shippable,c.facture,c.import_key,c.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_orderlistdet','rowid,pr.ref,cdet.qty,c.ref,s.nom,c.date_commande,c.delivery_date,cdet.total_ht,ef.custom1,ef.aaa,u.login,shippable,c.facture,c.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_partnershippartnershiplist','t.import_key,t.ip,t.reason_decline_or_cancel,t.last_check_backlink,t.count_last_url_check_error,t.entity,t.url_to_check,t.ref,t.fk_type,t.fk_soc,t.date_partnership_start,t.date_partnership_end,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_poslist','f.date_closing,f.ref,f.ref_client,f.type,f.date_lim_reglement,p.ref,s.nom,s.town,f.total_ht,f.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_productlist','p.stockable_product,p.ref,p.label,p.barcode,p.sellprice,p.minbuyprice,p.desiredstock,p.stock,stock_virtual,p.tosell,p.tobuy,'),
(12,1,'MAIN_SELECTEDFIELDS_projectlist','ef.priority,p.ref,p.title,s.nom,s.name_alias,co.country_code,p.datee,p.fk_opp_status,p.opp_percent,p.opp_amount,c.assigned,p.date_start_event,p.date_end_event,p.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_sellyoursaasresellers','ef.date_apply_for_reseller,s.nom,s.name_alias,s.barcode,sales.representative,s.zip,s.phone,typent.code,customerorsupplier,ef.sss,ef.dolicloud,ef.date_registration,ef.domain_registration_page,ef.source,ef.source_utm,ef.firstname,ef.lastname,ef.password,ef.manualcollection,ef.commission,s.status,'),
(12,1,'MAIN_SELECTEDFIELDS_servicelist','ef.aaa,p.ref,p.label,p.duration,p.sellprice,p.minbuyprice,ef.package,p.tosell,p.tobuy,'),
(12,1,'MAIN_SELECTEDFIELDS_supplierorderlist','cf.tms,cf.ref,cf.ref_supplier,cf.fk_soc,s.town,s.zip,cf.date_commande,cf.date_livraison,cf.total_ht,cf.total_tva,cf.fk_statut,cf.billed,'),
(12,1,'MAIN_SELECTEDFIELDS_targetlist','t.trigger_codes,t.ref,t.label,t.url,t.status,'),
(12,1,'MAIN_SELECTEDFIELDS_tasklist','t.tobill,t.billed,t.ref,t.label,t.dateo,t.datee,p.ref,s.nom,p.fk_statut,t.planned_workload,t.duration_effective,t.progress_calculated,t.progress,t.progress_summary,'),
(12,1,'MAIN_SELECTEDFIELDS_thirdpartylist','s.tms,s.nom,s.name_alias,s.barcode,s.code_client,sales.representative,s.zip,s.phone,typent.code,customerorsupplier,ef.sss,s.status,'),
(12,1,'MAIN_SELECTEDFIELDS_ticketlist','t.origin_email,t.ref,t.fk_user_create,t.subject,t.type_code,t.severity_code,t.fk_soc,t.datec,t.date_read,t.fk_user_assign,t.fk_statut,'),
(12,1,'MAIN_SELECTEDFIELDS_userlist','u.api_key,u.login,u.lastname,u.firstname,u.employee,u.fk_user,u.email,u.fk_soc,u.job,u.datelastlogin,u.statut,'),
(12,1,'MAIN_THEME','eldy'),
(12,1,'SOCIETE_PUBLIC_HIDE_OFFICE_FAX','1'),
(12,1,'SOCIETE_PUBLIC_HIDE_OFFICE_PHONE','1'),
(12,1,'SOCIETE_PUBLIC_HIDE_SOCIALNETWORKS_FACEBOOK','1'),
(12,1,'SOCIETE_PUBLIC_HIDE_SOCIALNETWORKS_GITHUB','1'),
(12,1,'SOCIETE_PUBLIC_HIDE_SOCIALNETWORKS_INSTAGRAM','1'),
(12,1,'SOCIETE_PUBLIC_HIDE_SOCIALNETWORKS_TWITTER','1'),
(12,1,'USER_ENABLE_PUBLIC','1'),
(12,1,'USER_PUBLIC_HIDE_OFFICE_FAX','1'),
(12,1,'USER_PUBLIC_HIDE_OFFICE_PHONE','1'),
(12,1,'USER_PUBLIC_HIDE_USER_MOBILE','1'),
(12,1,'USER_PUBLIC_MORE','Rencontré sur salon abc');

--
-- Table structure for table `llx_user_rib`
--

CREATE TABLE `llx_user_rib` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_user` int(11) NOT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `datec` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `label` varchar(30) DEFAULT NULL,
  `bank` varchar(255) DEFAULT NULL,
  `code_banque` varchar(128) DEFAULT NULL,
  `code_guichet` varchar(6) DEFAULT NULL,
  `number` varchar(255) DEFAULT NULL,
  `cle_rib` varchar(5) DEFAULT NULL,
  `bic` varchar(11) DEFAULT NULL,
  `bic_intermediate` varchar(11) DEFAULT NULL,
  `iban_prefix` varchar(80) DEFAULT NULL,
  `domiciliation` varchar(255) DEFAULT NULL,
  `proprio` varchar(60) DEFAULT NULL,
  `owner_address` varchar(255) DEFAULT NULL,
  `state_id` int(11) DEFAULT NULL,
  `fk_country` int(11) DEFAULT NULL,
  `currency_code` varchar(3) DEFAULT NULL,
  `default_rib` smallint(6) NOT NULL DEFAULT 0,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_rib`
--


--
-- Table structure for table `llx_user_rights`
--

CREATE TABLE `llx_user_rights` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_user` int(11) NOT NULL,
  `fk_id` int(11) NOT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_user_rights` (`entity`,`fk_user`,`fk_id`),
  KEY `fk_user_rights_fk_user_user` (`fk_user`),
  CONSTRAINT `fk_user_rights_fk_user_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=39753 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_user_rights`
--

INSERT INTO `llx_user_rights` VALUES
(12402,1,1,11),
(12380,1,1,12),
(12385,1,1,13),
(12389,1,1,14),
(12393,1,1,15),
(12398,1,1,16),
(12404,1,1,19),
(9726,1,1,21),
(9700,1,1,22),
(9706,1,1,24),
(9711,1,1,25),
(9716,1,1,26),
(9722,1,1,27),
(9728,1,1,28),
(9978,1,1,31),
(9968,1,1,32),
(9974,1,1,34),
(9980,1,1,38),
(11573,1,1,41),
(11574,1,1,42),
(11575,1,1,44),
(11576,1,1,45),
(7184,1,1,61),
(7181,1,1,62),
(7183,1,1,64),
(7185,1,1,67),
(7186,1,1,68),
(1678,1,1,71),
(1673,1,1,72),
(1675,1,1,74),
(1679,1,1,75),
(1677,1,1,76),
(1681,1,1,78),
(1682,1,1,79),
(12322,1,1,81),
(12309,1,1,82),
(12312,1,1,84),
(12314,1,1,86),
(12317,1,1,87),
(12320,1,1,88),
(12323,1,1,89),
(11580,1,1,91),
(11581,1,1,92),
(11582,1,1,93),
(11583,1,1,94),
(7139,1,1,101),
(7134,1,1,102),
(7136,1,1,104),
(7137,1,1,105),
(7138,1,1,106),
(7140,1,1,109),
(10229,1,1,111),
(10201,1,1,112),
(10207,1,1,113),
(10213,1,1,114),
(10219,1,1,115),
(10225,1,1,116),
(10231,1,1,117),
(12518,1,1,121),
(12508,1,1,122),
(12514,1,1,125),
(12520,1,1,126),
(11577,1,1,141),
(11578,1,1,142),
(11579,1,1,144),
(2307,1,1,151),
(2304,1,1,152),
(2306,1,1,153),
(2308,1,1,154),
(10092,1,1,161),
(10093,1,1,162),
(10094,1,1,163),
(10095,1,1,164),
(10096,1,1,165),
(10000,1,1,221),
(9990,1,1,222),
(9996,1,1,223),
(10002,1,1,229),
(10007,1,1,237),
(10011,1,1,238),
(10015,1,1,239),
(1686,1,1,241),
(1685,1,1,242),
(1687,1,1,243),
(12604,1,1,251),
(12566,1,1,252),
(12569,1,1,253),
(12572,1,1,254),
(12575,1,1,255),
(12579,1,1,256),
(12525,1,1,262),
(12544,1,1,281),
(12534,1,1,282),
(12540,1,1,283),
(12546,1,1,286),
(12290,1,1,301),
(1763,1,1,331),
(1762,1,1,332),
(1764,1,1,333),
(12582,1,1,341),
(12584,1,1,342),
(12586,1,1,343),
(12588,1,1,344),
(12600,1,1,351),
(12593,1,1,352),
(12597,1,1,353),
(12601,1,1,354),
(12605,1,1,358),
(12560,1,1,531),
(12553,1,1,532),
(12557,1,1,534),
(12561,1,1,538),
(12348,1,1,701),
(12354,1,1,702),
(12360,1,1,703),
(1755,1,1,1001),
(1754,1,1,1002),
(1756,1,1,1003),
(1758,1,1,1004),
(1759,1,1,1005),
(7146,1,1,1101),
(7143,1,1,1102),
(7145,1,1,1104),
(7147,1,1,1109),
(12412,1,1,1181),
(12458,1,1,1182),
(12417,1,1,1183),
(12420,1,1,1184),
(12423,1,1,1185),
(12427,1,1,1186),
(12431,1,1,1187),
(12437,1,1,1188),
(12434,1,1,1189),
(1578,1,1,1201),
(1579,1,1,1202),
(12454,1,1,1231),
(12443,1,1,1232),
(12446,1,1,1233),
(12449,1,1,1234),
(12452,1,1,1235),
(12455,1,1,1236),
(1736,1,1,1251),
(12409,1,1,1321),
(12326,1,1,1421),
(12264,1,1,2401),
(12260,1,1,2402),
(12266,1,1,2403),
(12280,1,1,2411),
(12276,1,1,2412),
(12282,1,1,2413),
(12286,1,1,2414),
(12370,1,1,2501),
(12367,1,1,2503),
(12371,1,1,2515),
(12490,1,1,20001),
(12474,1,1,20003),
(12480,1,1,20004),
(12486,1,1,20005),
(12492,1,1,20006),
(12302,1,1,23001),
(12295,1,1,23002),
(12299,1,1,23003),
(12303,1,1,23004),
(4984,1,1,50401),
(4987,1,1,50411),
(4988,1,1,50412),
(4989,1,1,50415),
(12498,1,1,55001),
(12499,1,1,55002),
(9596,1,1,101051),
(9604,1,1,101060),
(9605,1,1,101061),
(10353,1,1,101250),
(10355,1,1,101251),
(132,1,2,11),
(133,1,2,12),
(134,1,2,13),
(135,1,2,14),
(136,1,2,16),
(137,1,2,19),
(138,1,2,21),
(139,1,2,22),
(140,1,2,24),
(141,1,2,25),
(142,1,2,26),
(143,1,2,27),
(10359,1,2,31),
(145,1,2,32),
(10361,1,2,34),
(147,1,2,41),
(148,1,2,42),
(149,1,2,44),
(150,1,2,61),
(151,1,2,62),
(152,1,2,64),
(153,1,2,71),
(154,1,2,72),
(155,1,2,74),
(156,1,2,75),
(157,1,2,78),
(158,1,2,79),
(159,1,2,81),
(160,1,2,82),
(161,1,2,84),
(162,1,2,86),
(163,1,2,87),
(164,1,2,88),
(165,1,2,89),
(166,1,2,91),
(167,1,2,92),
(168,1,2,93),
(169,1,2,101),
(170,1,2,102),
(171,1,2,104),
(172,1,2,109),
(173,1,2,111),
(174,1,2,112),
(175,1,2,113),
(176,1,2,114),
(177,1,2,116),
(178,1,2,117),
(179,1,2,121),
(180,1,2,122),
(181,1,2,125),
(182,1,2,141),
(183,1,2,142),
(184,1,2,144),
(2479,1,2,151),
(2480,1,2,152),
(2481,1,2,153),
(2482,1,2,154),
(185,1,2,161),
(186,1,2,162),
(187,1,2,163),
(188,1,2,164),
(189,1,2,165),
(193,1,2,221),
(194,1,2,222),
(195,1,2,229),
(196,1,2,241),
(197,1,2,242),
(198,1,2,243),
(199,1,2,251),
(201,1,2,262),
(202,1,2,281),
(203,1,2,282),
(204,1,2,283),
(205,1,2,331),
(2483,1,2,531),
(207,1,2,532),
(2484,1,2,534),
(210,1,2,701),
(211,1,2,702),
(2474,1,2,703),
(15064,1,2,771),
(15057,1,2,772),
(15059,1,2,773),
(15063,1,2,775),
(15065,1,2,776),
(212,1,2,1001),
(213,1,2,1002),
(214,1,2,1003),
(215,1,2,1004),
(216,1,2,1005),
(217,1,2,1101),
(218,1,2,1102),
(219,1,2,1104),
(220,1,2,1109),
(15073,1,2,1121),
(15074,1,2,1122),
(15075,1,2,1123),
(15076,1,2,1124),
(15077,1,2,1125),
(15078,1,2,1126),
(221,1,2,1181),
(222,1,2,1182),
(223,1,2,1183),
(224,1,2,1184),
(225,1,2,1185),
(226,1,2,1186),
(227,1,2,1187),
(228,1,2,1188),
(229,1,2,1201),
(230,1,2,1202),
(231,1,2,1231),
(232,1,2,1232),
(233,1,2,1233),
(234,1,2,1234),
(235,1,2,1421),
(236,1,2,2401),
(237,1,2,2402),
(238,1,2,2403),
(239,1,2,2411),
(240,1,2,2412),
(241,1,2,2413),
(2470,1,2,2501),
(243,1,2,2515),
(10363,1,2,20001),
(10365,1,2,20003),
(10366,1,2,20004),
(10367,1,2,20005),
(10368,1,2,20006),
(15054,1,2,23001),
(15067,1,2,55001),
(15066,1,2,59001),
(15068,1,2,63001),
(15069,1,2,63002),
(15070,1,2,63003),
(15071,1,2,63004),
(10372,1,2,101250),
(1807,1,3,11),
(1808,1,3,31),
(1810,1,3,41),
(1811,1,3,61),
(1812,1,3,71),
(1813,1,3,72),
(1814,1,3,74),
(1815,1,3,75),
(1816,1,3,78),
(1817,1,3,79),
(1818,1,3,91),
(1821,1,3,111),
(1822,1,3,121),
(1823,1,3,122),
(1824,1,3,125),
(1825,1,3,161),
(1829,1,3,221),
(1830,1,3,222),
(1831,1,3,229),
(1832,1,3,241),
(1833,1,3,242),
(1834,1,3,243),
(1835,1,3,251),
(1836,1,3,255),
(1837,1,3,256),
(1838,1,3,262),
(1839,1,3,281),
(1840,1,3,282),
(1841,1,3,283),
(1842,1,3,331),
(1843,1,3,531),
(1846,1,3,1001),
(1847,1,3,1002),
(1848,1,3,1003),
(1849,1,3,1004),
(1850,1,3,1005),
(1851,1,3,1181),
(1852,1,3,1182),
(1853,1,3,1201),
(1854,1,3,1202),
(1855,1,3,1231),
(1856,1,3,2401),
(1857,1,3,2402),
(1858,1,3,2403),
(1859,1,3,2411),
(1860,1,3,2412),
(1861,1,3,2413),
(1863,1,3,2515),
(8026,1,4,11),
(8027,1,4,21),
(8028,1,4,31),
(8029,1,4,41),
(8030,1,4,61),
(8031,1,4,71),
(8032,1,4,72),
(8033,1,4,74),
(8034,1,4,75),
(8035,1,4,78),
(8036,1,4,79),
(8037,1,4,81),
(8038,1,4,91),
(8041,1,4,101),
(8042,1,4,111),
(8043,1,4,121),
(8044,1,4,151),
(8045,1,4,161),
(8047,1,4,221),
(8048,1,4,222),
(8049,1,4,229),
(8050,1,4,241),
(8051,1,4,242),
(8052,1,4,243),
(8146,1,4,251),
(8147,1,4,253),
(8053,1,4,262),
(8054,1,4,281),
(8055,1,4,331),
(8056,1,4,341),
(8057,1,4,342),
(8058,1,4,343),
(8059,1,4,344),
(8060,1,4,531),
(8062,1,4,1001),
(8063,1,4,1002),
(8064,1,4,1003),
(8065,1,4,1004),
(8066,1,4,1005),
(8067,1,4,1101),
(8068,1,4,1181),
(8069,1,4,1182),
(8070,1,4,1201),
(8071,1,4,1202),
(8072,1,4,1231),
(8073,1,4,2401),
(8074,1,4,2501),
(8075,1,4,2503),
(8076,1,4,2515),
(8077,1,4,20001),
(12608,1,10,11),
(12609,1,10,21),
(12610,1,10,31),
(12611,1,10,41),
(12612,1,10,61),
(12613,1,10,71),
(12614,1,10,72),
(12615,1,10,74),
(12616,1,10,75),
(12617,1,10,78),
(12618,1,10,79),
(12619,1,10,81),
(12620,1,10,91),
(12623,1,10,101),
(12624,1,10,111),
(12625,1,10,121),
(12626,1,10,151),
(12627,1,10,161),
(12629,1,10,221),
(12630,1,10,222),
(12631,1,10,229),
(12632,1,10,241),
(12633,1,10,242),
(12634,1,10,243),
(12635,1,10,262),
(12636,1,10,281),
(12638,1,10,331),
(12639,1,10,341),
(12640,1,10,342),
(12641,1,10,343),
(12642,1,10,344),
(12643,1,10,531),
(12645,1,10,1001),
(12646,1,10,1002),
(12647,1,10,1003),
(12648,1,10,1004),
(12649,1,10,1005),
(12650,1,10,1101),
(12651,1,10,1181),
(12652,1,10,1182),
(12653,1,10,1201),
(12654,1,10,1202),
(12655,1,10,1231),
(12656,1,10,2401),
(12657,1,10,2501),
(12658,1,10,2503),
(12659,1,10,2515),
(12660,1,10,20001),
(12662,1,10,23001),
(12664,1,11,11),
(12665,1,11,21),
(12666,1,11,31),
(12667,1,11,41),
(12668,1,11,61),
(12669,1,11,71),
(12670,1,11,72),
(12671,1,11,74),
(12672,1,11,75),
(12673,1,11,78),
(12674,1,11,79),
(12675,1,11,81),
(12676,1,11,91),
(12679,1,11,101),
(12680,1,11,111),
(12681,1,11,121),
(12682,1,11,151),
(12683,1,11,161),
(12685,1,11,221),
(12686,1,11,222),
(12687,1,11,229),
(12688,1,11,241),
(12689,1,11,242),
(12690,1,11,243),
(12691,1,11,262),
(12692,1,11,281),
(12694,1,11,331),
(12695,1,11,341),
(12696,1,11,342),
(12697,1,11,343),
(12698,1,11,344),
(12699,1,11,531),
(12701,1,11,1001),
(12702,1,11,1002),
(12703,1,11,1003),
(12704,1,11,1004),
(12705,1,11,1005),
(12706,1,11,1101),
(12707,1,11,1181),
(12708,1,11,1182),
(12709,1,11,1201),
(12710,1,11,1202),
(12711,1,11,1231),
(12712,1,11,2401),
(12713,1,11,2501),
(12714,1,11,2503),
(12715,1,11,2515),
(12716,1,11,20001),
(12718,1,11,23001),
(39589,1,12,11),
(39583,1,12,12),
(39584,1,12,13),
(39585,1,12,14),
(39586,1,12,15),
(39588,1,12,16),
(39590,1,12,19),
(36400,1,12,21),
(36394,1,12,22),
(36395,1,12,24),
(36396,1,12,25),
(36397,1,12,26),
(36399,1,12,27),
(36401,1,12,28),
(36402,1,12,29),
(36376,1,12,31),
(36369,1,12,32),
(36370,1,12,33),
(36373,1,12,34),
(36371,1,12,35),
(36375,1,12,38),
(36377,1,12,39),
(36390,1,12,41),
(36380,1,12,42),
(36382,1,12,44),
(36384,1,12,45),
(39623,1,12,61),
(39620,1,12,62),
(39622,1,12,64),
(39624,1,12,67),
(39625,1,12,68),
(39626,1,12,69),
(39627,1,12,70),
(36317,1,12,71),
(36312,1,12,72),
(36314,1,12,74),
(36318,1,12,75),
(36316,1,12,76),
(36320,1,12,78),
(36321,1,12,79),
(39553,1,12,81),
(39547,1,12,82),
(39548,1,12,84),
(39549,1,12,85),
(39550,1,12,86),
(39551,1,12,87),
(39552,1,12,88),
(39554,1,12,89),
(36495,1,12,91),
(36492,1,12,92),
(36494,1,12,93),
(36496,1,12,94),
(38351,1,12,95),
(36139,1,12,101),
(36135,1,12,102),
(36136,1,12,104),
(36137,1,12,105),
(36138,1,12,106),
(36140,1,12,109),
(39531,1,12,111),
(39522,1,12,112),
(39524,1,12,113),
(39526,1,12,114),
(39528,1,12,115),
(39530,1,12,116),
(39532,1,12,117),
(39703,1,12,121),
(39700,1,12,122),
(39702,1,12,125),
(39704,1,12,126),
(39705,1,12,130),
(36388,1,12,141),
(36387,1,12,142),
(36389,1,12,144),
(36391,1,12,145),
(36364,1,12,151),
(36361,1,12,152),
(36363,1,12,153),
(36365,1,12,154),
(36123,1,12,161),
(36116,1,12,162),
(36118,1,12,163),
(36120,1,12,164),
(36122,1,12,165),
(36124,1,12,167),
(37866,1,12,171),
(37861,1,12,172),
(37863,1,12,173),
(37865,1,12,174),
(37867,1,12,178),
(36302,1,12,221),
(36299,1,12,222),
(36301,1,12,223),
(36303,1,12,229),
(36304,1,12,237),
(36305,1,12,238),
(36306,1,12,239),
(36111,1,12,241),
(36110,1,12,242),
(36112,1,12,243),
(39746,1,12,251),
(39727,1,12,252),
(39729,1,12,253),
(39730,1,12,254),
(39732,1,12,255),
(39734,1,12,256),
(39706,1,12,262),
(39712,1,12,281),
(39709,1,12,282),
(39711,1,12,283),
(39713,1,12,286),
(39536,1,12,301),
(39535,1,12,304),
(39537,1,12,305),
(36106,1,12,331),
(36105,1,12,332),
(36107,1,12,333),
(39735,1,12,341),
(39736,1,12,342),
(39737,1,12,343),
(39738,1,12,344),
(39744,1,12,351),
(39741,1,12,352),
(39743,1,12,353),
(39745,1,12,354),
(39747,1,12,358),
(36132,1,12,431),
(39687,1,12,511),
(39680,1,12,512),
(39682,1,12,513),
(39684,1,12,514),
(39686,1,12,517),
(39688,1,12,519),
(23700,1,12,520),
(39648,1,12,521),
(39643,1,12,522),
(39645,1,12,524),
(39647,1,12,525),
(39649,1,12,527),
(39696,1,12,531),
(39691,1,12,532),
(39692,1,12,533),
(39695,1,12,534),
(39693,1,12,535),
(39697,1,12,538),
(36357,1,12,561),
(36354,1,12,562),
(36356,1,12,563),
(36358,1,12,564),
(36286,1,12,601),
(36285,1,12,602),
(36287,1,12,609),
(25481,1,12,610),
(39751,1,12,611),
(39750,1,12,612),
(39752,1,12,613),
(39518,1,12,651),
(39517,1,12,652),
(39519,1,12,653),
(39656,1,12,661),
(39655,1,12,662),
(39657,1,12,663),
(36551,1,12,691),
(36550,1,12,692),
(36552,1,12,693),
(39559,1,12,701),
(39558,1,12,702),
(39560,1,12,703),
(36474,1,12,711),
(36473,1,12,712),
(36475,1,12,713),
(39669,1,12,750),
(39668,1,12,751),
(39670,1,12,752),
(39579,1,12,771),
(39568,1,12,772),
(39570,1,12,773),
(39572,1,12,775),
(39574,1,12,776),
(39576,1,12,777),
(39578,1,12,778),
(39580,1,12,779),
(36461,1,12,1001),
(36460,1,12,1002),
(36462,1,12,1003),
(36464,1,12,1004),
(36465,1,12,1005),
(29959,1,12,1008),
(36469,1,12,1011),
(36468,1,12,1012),
(36470,1,12,1013),
(29963,1,12,1014),
(29964,1,12,1015),
(23747,1,12,1016),
(36145,1,12,1101),
(36143,1,12,1102),
(36144,1,12,1104),
(36146,1,12,1109),
(36485,1,12,1121),
(36478,1,12,1122),
(36480,1,12,1123),
(36482,1,12,1124),
(36484,1,12,1125),
(36486,1,12,1126),
(39593,1,12,1181),
(39607,1,12,1182),
(39596,1,12,1183),
(39597,1,12,1184),
(39599,1,12,1185),
(39601,1,12,1186),
(39603,1,12,1187),
(39606,1,12,1188),
(39604,1,12,1189),
(39608,1,12,1191),
(38071,1,12,1201),
(38072,1,12,1202),
(39616,1,12,1231),
(39611,1,12,1232),
(39612,1,12,1233),
(39614,1,12,1234),
(39615,1,12,1235),
(39617,1,12,1236),
(38069,1,12,1251),
(39591,1,12,1321),
(39592,1,12,1322),
(39555,1,12,1421),
(36157,1,12,1521),
(36158,1,12,1522),
(39507,1,12,2401),
(39506,1,12,2402),
(39508,1,12,2403),
(39512,1,12,2411),
(39511,1,12,2412),
(39513,1,12,2413),
(39514,1,12,2414),
(39564,1,12,2501),
(39563,1,12,2503),
(39565,1,12,2515),
(36058,1,12,2610),
(36218,1,12,2801),
(36219,1,12,2802),
(39219,1,12,3201),
(36322,1,12,3301),
(37478,1,12,4001),
(37477,1,12,4002),
(37479,1,12,4003),
(37487,1,12,4021),
(37482,1,12,4022),
(37483,1,12,4023),
(37485,1,12,4025),
(37486,1,12,4028),
(37488,1,12,4029),
(37489,1,12,4031),
(37490,1,12,4032),
(30024,1,12,4033),
(39489,1,12,10001),
(39484,1,12,10002),
(39486,1,12,10003),
(39488,1,12,10005),
(39490,1,12,10008),
(39639,1,12,20001),
(39630,1,12,20002),
(39632,1,12,20003),
(39636,1,12,20004),
(39638,1,12,20005),
(39640,1,12,20006),
(39634,1,12,20007),
(39543,1,12,23001),
(39540,1,12,23002),
(39542,1,12,23003),
(39544,1,12,23004),
(38670,1,12,40001),
(38669,1,12,40002),
(38671,1,12,40003),
(39723,1,12,50151),
(39724,1,12,50152),
(39725,1,12,50153),
(36556,1,12,50331),
(36555,1,12,50332),
(36557,1,12,50333),
(39492,1,12,50401),
(39500,1,12,50411),
(39495,1,12,50412),
(39497,1,12,50414),
(39499,1,12,50415),
(39501,1,12,50418),
(39502,1,12,50420),
(39503,1,12,50430),
(39491,1,12,50440),
(38079,1,12,51001),
(38078,1,12,51002),
(38080,1,12,51003),
(38084,1,12,51004),
(38083,1,12,51005),
(38085,1,12,51006),
(39659,1,12,55001),
(39660,1,12,55002),
(39721,1,12,56001),
(39716,1,12,56002),
(39718,1,12,56003),
(39720,1,12,56004),
(39722,1,12,56006),
(36281,1,12,57001),
(36279,1,12,57002),
(36280,1,12,57003),
(36282,1,12,57004),
(39664,1,12,58000),
(39663,1,12,58001),
(39665,1,12,58002),
(39650,1,12,59001),
(39651,1,12,59002),
(39652,1,12,59003),
(39676,1,12,63001),
(39673,1,12,63002),
(39675,1,12,63003),
(39677,1,12,63004),
(39114,1,12,64001),
(36403,1,12,67001),
(36263,1,12,68001),
(36262,1,12,68002),
(36264,1,12,68004),
(38646,1,12,101051),
(38651,1,12,101060),
(38649,1,12,101061),
(38650,1,12,101062),
(38652,1,12,101068),
(30090,1,12,101331),
(30091,1,12,101332),
(30092,1,12,101333),
(36600,1,12,101410),
(36599,1,12,101411),
(36601,1,12,101412),
(25876,1,12,101701),
(25877,1,12,101702),
(36096,1,12,243001),
(36095,1,12,243002),
(36097,1,12,243003),
(36101,1,12,243011),
(36100,1,12,243012),
(36102,1,12,243013),
(30077,1,12,436150),
(30078,1,12,436151),
(30079,1,12,436152),
(36410,1,12,941601),
(36406,1,12,941602),
(36407,1,12,941603),
(36408,1,12,941604),
(36409,1,12,941605),
(36411,1,12,941606),
(36538,1,12,1100001),
(30084,1,12,10117001),
(30085,1,12,10117002),
(30086,1,12,10117003),
(30087,1,12,50000001),
(30088,1,12,50000002),
(30089,1,12,50000003),
(12776,1,13,11),
(12777,1,13,21),
(12778,1,13,31),
(12779,1,13,41),
(12780,1,13,61),
(12781,1,13,71),
(12782,1,13,72),
(12783,1,13,74),
(12784,1,13,75),
(12785,1,13,78),
(12786,1,13,79),
(12787,1,13,81),
(12788,1,13,91),
(12791,1,13,101),
(12792,1,13,111),
(12793,1,13,121),
(12794,1,13,151),
(12795,1,13,161),
(12797,1,13,221),
(12798,1,13,222),
(12799,1,13,229),
(12800,1,13,241),
(12801,1,13,242),
(12802,1,13,243),
(12803,1,13,262),
(12804,1,13,281),
(12806,1,13,331),
(12807,1,13,341),
(12808,1,13,342),
(12809,1,13,343),
(12810,1,13,344),
(12811,1,13,531),
(12813,1,13,1001),
(12814,1,13,1002),
(12815,1,13,1003),
(12816,1,13,1004),
(12817,1,13,1005),
(12818,1,13,1101),
(12819,1,13,1181),
(12820,1,13,1182),
(12821,1,13,1201),
(12822,1,13,1202),
(12823,1,13,1231),
(12824,1,13,2401),
(12825,1,13,2501),
(12826,1,13,2503),
(12827,1,13,2515),
(12828,1,13,20001),
(12830,1,13,23001),
(12832,1,14,11),
(12833,1,14,21),
(12834,1,14,31),
(12835,1,14,41),
(12836,1,14,61),
(12837,1,14,71),
(12838,1,14,72),
(12839,1,14,74),
(12840,1,14,75),
(12841,1,14,78),
(12842,1,14,79),
(12843,1,14,81),
(12844,1,14,91),
(12847,1,14,101),
(12848,1,14,111),
(12849,1,14,121),
(12850,1,14,151),
(12851,1,14,161),
(12853,1,14,221),
(12854,1,14,222),
(12855,1,14,229),
(12856,1,14,241),
(12857,1,14,242),
(12858,1,14,243),
(12859,1,14,262),
(12860,1,14,281),
(12862,1,14,331),
(12863,1,14,341),
(12864,1,14,342),
(12865,1,14,343),
(12866,1,14,344),
(12867,1,14,531),
(12869,1,14,1001),
(12870,1,14,1002),
(12871,1,14,1003),
(12872,1,14,1004),
(12873,1,14,1005),
(12874,1,14,1101),
(12875,1,14,1181),
(12876,1,14,1182),
(12877,1,14,1201),
(12878,1,14,1202),
(12879,1,14,1231),
(12880,1,14,2401),
(12881,1,14,2501),
(12882,1,14,2503),
(12883,1,14,2515),
(12884,1,14,20001),
(12886,1,14,23001),
(12944,1,16,11),
(12945,1,16,21),
(12946,1,16,31),
(13056,1,16,41),
(13057,1,16,42),
(13058,1,16,44),
(13059,1,16,45),
(12948,1,16,61),
(12949,1,16,71),
(12950,1,16,72),
(12951,1,16,74),
(12952,1,16,75),
(12953,1,16,78),
(12954,1,16,79),
(12955,1,16,81),
(12956,1,16,91),
(12959,1,16,101),
(12960,1,16,111),
(12961,1,16,121),
(13060,1,16,141),
(13061,1,16,142),
(13062,1,16,144),
(12962,1,16,151),
(12963,1,16,161),
(12965,1,16,221),
(12966,1,16,222),
(12967,1,16,229),
(12968,1,16,241),
(12969,1,16,242),
(12970,1,16,243),
(13128,1,16,251),
(13064,1,16,262),
(12972,1,16,281),
(12974,1,16,331),
(12975,1,16,341),
(12976,1,16,342),
(12977,1,16,343),
(12978,1,16,344),
(12979,1,16,531),
(12981,1,16,1001),
(12982,1,16,1002),
(12983,1,16,1003),
(12984,1,16,1004),
(12985,1,16,1005),
(12986,1,16,1101),
(12987,1,16,1181),
(12988,1,16,1182),
(12989,1,16,1201),
(12990,1,16,1202),
(12991,1,16,1231),
(12992,1,16,2401),
(12993,1,16,2501),
(12994,1,16,2503),
(12995,1,16,2515),
(12996,1,16,20001),
(12998,1,16,23001),
(13000,1,17,11),
(13001,1,17,21),
(13002,1,17,31),
(13065,1,17,41),
(13066,1,17,42),
(13067,1,17,44),
(13068,1,17,45),
(13004,1,17,61),
(13005,1,17,71),
(13006,1,17,72),
(13007,1,17,74),
(13008,1,17,75),
(13009,1,17,78),
(13010,1,17,79),
(13011,1,17,81),
(13012,1,17,91),
(13015,1,17,101),
(13016,1,17,111),
(13017,1,17,121),
(13069,1,17,141),
(13070,1,17,142),
(13071,1,17,144),
(13018,1,17,151),
(13019,1,17,161),
(13021,1,17,221),
(13022,1,17,222),
(13023,1,17,229),
(13024,1,17,241),
(13025,1,17,242),
(13026,1,17,243),
(13028,1,17,281),
(13030,1,17,331),
(13031,1,17,341),
(13032,1,17,342),
(13033,1,17,343),
(13034,1,17,344),
(13035,1,17,531),
(13037,1,17,1001),
(13038,1,17,1002),
(13039,1,17,1003),
(13040,1,17,1004),
(13041,1,17,1005),
(13042,1,17,1101),
(13043,1,17,1181),
(13044,1,17,1182),
(13045,1,17,1201),
(13046,1,17,1202),
(13047,1,17,1231),
(13048,1,17,2401),
(13049,1,17,2501),
(13050,1,17,2503),
(13051,1,17,2515),
(13052,1,17,20001),
(13054,1,17,23001),
(14504,1,18,11),
(14505,1,18,21),
(14506,1,18,31),
(14507,1,18,41),
(14508,1,18,61),
(14509,1,18,71),
(14510,1,18,78),
(14511,1,18,81),
(14512,1,18,91),
(14514,1,18,101),
(14515,1,18,111),
(14516,1,18,121),
(14517,1,18,151),
(14518,1,18,161),
(14519,1,18,221),
(14520,1,18,241),
(14521,1,18,262),
(14522,1,18,281),
(14524,1,18,331),
(14525,1,18,332),
(14526,1,18,333),
(14527,1,18,341),
(14528,1,18,342),
(14529,1,18,343),
(14530,1,18,344),
(14531,1,18,531),
(14532,1,18,701),
(14533,1,18,771),
(14535,1,18,1001),
(14536,1,18,1004),
(14537,1,18,1101),
(14538,1,18,1181),
(14539,1,18,1182),
(14540,1,18,1201),
(14541,1,18,1231),
(14542,1,18,2401),
(14543,1,18,2501),
(14544,1,18,2503),
(14545,1,18,2515),
(14546,1,18,20001),
(14549,1,18,59001),
(15242,1,19,21),
(15243,1,19,31),
(15244,1,19,41),
(15245,1,19,61),
(15246,1,19,71),
(15247,1,19,78),
(15248,1,19,81),
(15249,1,19,101),
(15250,1,19,121),
(15251,1,19,151),
(15252,1,19,161),
(15253,1,19,221),
(15254,1,19,241),
(15255,1,19,262),
(15256,1,19,281),
(15258,1,19,331),
(15259,1,19,332),
(15260,1,19,341),
(15261,1,19,342),
(15262,1,19,343),
(15263,1,19,344),
(15264,1,19,531),
(15265,1,19,701),
(15266,1,19,771),
(15268,1,19,777),
(15269,1,19,1001),
(15270,1,19,1004),
(15271,1,19,1101),
(15272,1,19,1121),
(15273,1,19,1181),
(15274,1,19,1182),
(15275,1,19,1201),
(15276,1,19,1231),
(15277,1,19,2401),
(15278,1,19,2501),
(15279,1,19,20001),
(15282,1,19,59001),
(15283,1,19,63001),
(22910,1,22,701),
(23925,1,29,21),
(23926,1,29,31),
(23927,1,29,41),
(23928,1,29,61),
(23929,1,29,151),
(23930,1,29,161),
(23931,1,29,241),
(23940,1,29,251),
(23932,1,29,301),
(23933,1,29,304),
(23939,1,29,342),
(23941,1,29,358),
(23935,1,29,701),
(23936,1,29,1001),
(23937,1,29,1004),
(23938,1,29,1201),
(36560,1,29,101051),
(36559,1,29,101060),
(36558,1,29,101062),
(30467,1,31,31),
(30468,1,31,41),
(30469,1,31,151),
(30470,1,31,161),
(30471,1,31,241),
(30472,1,31,1201),
(30473,1,31,40001),
(30474,1,32,31),
(30475,1,32,41),
(30476,1,32,151),
(30477,1,32,161),
(30478,1,32,241),
(30479,1,32,1201),
(30480,1,32,40001),
(30481,1,33,31),
(30482,1,33,41),
(30483,1,33,151),
(30484,1,33,161),
(30485,1,33,241),
(30486,1,33,1201),
(30487,1,33,40001),
(30488,1,34,31),
(30489,1,34,41),
(30490,1,34,151),
(30491,1,34,161),
(30492,1,34,241),
(30493,1,34,1201),
(30494,1,34,40001),
(30495,1,35,31),
(30496,1,35,41),
(30497,1,35,151),
(30498,1,35,161),
(30499,1,35,241),
(30500,1,35,1201),
(30501,1,35,40001),
(30502,1,36,31),
(30503,1,36,41),
(30504,1,36,151),
(30505,1,36,161),
(30506,1,36,241),
(30507,1,36,1201),
(30508,1,36,40001),
(30509,1,37,31),
(30510,1,37,41),
(30511,1,37,151),
(30512,1,37,161),
(30513,1,37,241),
(30514,1,37,1201),
(30515,1,37,40001),
(30516,1,38,31),
(30517,1,38,41),
(30518,1,38,151),
(30519,1,38,161),
(30520,1,38,241),
(30521,1,38,1201),
(30522,1,38,40001),
(30787,1,39,31),
(30788,1,39,41),
(30789,1,39,151),
(30790,1,39,161),
(30791,1,39,241),
(30792,1,39,1201),
(30793,1,39,40001);

--
-- Table structure for table `llx_usergroup`
--

CREATE TABLE `llx_usergroup` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `nom` varchar(255) NOT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_parent` int(11) DEFAULT NULL,
  `datec` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `color` varchar(6) DEFAULT NULL,
  `note` text DEFAULT NULL,
  `model_pdf` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_usergroup_name` (`nom`,`entity`),
  KEY `idx_usergroup_fk_parent` (`fk_parent`),
  CONSTRAINT `fk_usergroup_parent` FOREIGN KEY (`fk_parent`) REFERENCES `llx_usergroup` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_usergroup`
--

INSERT INTO `llx_usergroup` VALUES
(1,'Sale representatives',1,NULL,'2015-01-16 20:48:08','2017-10-03 09:44:44',NULL,'All sales representative users',NULL),
(2,'Management',1,NULL,'2017-10-03 11:46:25','2017-10-03 09:46:25',NULL,'',NULL),
(3,'Scientists',1,NULL,'2017-10-03 11:46:46','2017-10-03 09:46:46',NULL,'',NULL),
(4,'Commercial',1,NULL,'2017-10-05 21:30:13','2017-10-05 19:30:13',NULL,'',NULL);

--
-- Table structure for table `llx_usergroup_extrafields`
--

CREATE TABLE `llx_usergroup_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_usergroup_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_usergroup_extrafields`
--


--
-- Table structure for table `llx_usergroup_rights`
--

CREATE TABLE `llx_usergroup_rights` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_usergroup` int(11) NOT NULL,
  `fk_id` int(11) NOT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_usergroup_rights` (`entity`,`fk_usergroup`,`fk_id`),
  KEY `fk_usergroup_rights_fk_usergroup` (`fk_usergroup`),
  CONSTRAINT `fk_usergroup_rights_fk_usergroup` FOREIGN KEY (`fk_usergroup`) REFERENCES `llx_usergroup` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=200 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_usergroup_rights`
--

INSERT INTO `llx_usergroup_rights` VALUES
(1,1,1,2401),
(2,1,1,2402),
(3,1,1,2403),
(4,1,1,2411),
(5,1,1,2412),
(6,1,1,2413),
(78,1,2,11),
(79,1,2,12),
(80,1,2,13),
(81,1,2,14),
(82,1,2,15),
(83,1,2,16),
(84,1,2,19),
(144,1,2,21),
(145,1,2,22),
(146,1,2,24),
(147,1,2,25),
(148,1,2,26),
(149,1,2,27),
(150,1,2,28),
(133,1,2,31),
(134,1,2,32),
(135,1,2,34),
(136,1,2,38),
(137,1,2,41),
(138,1,2,42),
(139,1,2,44),
(140,1,2,45),
(86,1,2,61),
(87,1,2,62),
(88,1,2,64),
(89,1,2,67),
(90,1,2,68),
(7,1,2,71),
(8,1,2,72),
(9,1,2,74),
(10,1,2,75),
(11,1,2,76),
(12,1,2,78),
(13,1,2,79),
(32,1,2,81),
(33,1,2,82),
(34,1,2,84),
(35,1,2,86),
(36,1,2,87),
(37,1,2,88),
(38,1,2,89),
(173,1,2,91),
(174,1,2,92),
(175,1,2,93),
(176,1,2,94),
(66,1,2,101),
(67,1,2,102),
(68,1,2,104),
(69,1,2,105),
(70,1,2,106),
(71,1,2,109),
(21,1,2,111),
(22,1,2,112),
(23,1,2,113),
(24,1,2,114),
(25,1,2,115),
(26,1,2,116),
(27,1,2,117),
(164,1,2,121),
(165,1,2,122),
(166,1,2,125),
(167,1,2,126),
(141,1,2,141),
(142,1,2,142),
(143,1,2,144),
(129,1,2,151),
(130,1,2,152),
(131,1,2,153),
(132,1,2,154),
(44,1,2,161),
(45,1,2,162),
(46,1,2,163),
(47,1,2,164),
(48,1,2,165),
(49,1,2,167),
(120,1,2,221),
(121,1,2,222),
(122,1,2,223),
(123,1,2,229),
(124,1,2,237),
(125,1,2,238),
(126,1,2,239),
(29,1,2,241),
(30,1,2,242),
(31,1,2,243),
(182,1,2,251),
(183,1,2,252),
(184,1,2,253),
(185,1,2,254),
(186,1,2,255),
(187,1,2,256),
(168,1,2,262),
(169,1,2,281),
(170,1,2,282),
(171,1,2,283),
(172,1,2,286),
(197,1,2,331),
(198,1,2,332),
(199,1,2,333),
(188,1,2,341),
(189,1,2,342),
(190,1,2,343),
(191,1,2,344),
(192,1,2,351),
(193,1,2,352),
(194,1,2,353),
(195,1,2,354),
(196,1,2,358),
(151,1,2,531),
(152,1,2,532),
(153,1,2,534),
(154,1,2,538),
(60,1,2,701),
(61,1,2,702),
(62,1,2,703),
(177,1,2,1001),
(178,1,2,1002),
(179,1,2,1003),
(180,1,2,1004),
(181,1,2,1005),
(72,1,2,1101),
(73,1,2,1102),
(74,1,2,1104),
(75,1,2,1109),
(91,1,2,1181),
(92,1,2,1182),
(93,1,2,1183),
(94,1,2,1184),
(95,1,2,1185),
(96,1,2,1186),
(97,1,2,1187),
(98,1,2,1188),
(99,1,2,1189),
(76,1,2,1201),
(77,1,2,1202),
(100,1,2,1231),
(101,1,2,1232),
(102,1,2,1233),
(103,1,2,1234),
(104,1,2,1235),
(105,1,2,1236),
(113,1,2,1251),
(85,1,2,1321),
(39,1,2,1421),
(14,1,2,2401),
(15,1,2,2402),
(16,1,2,2403),
(17,1,2,2411),
(18,1,2,2412),
(19,1,2,2413),
(20,1,2,2414),
(63,1,2,2501),
(64,1,2,2503),
(65,1,2,2515),
(114,1,2,20001),
(115,1,2,20002),
(116,1,2,20003),
(117,1,2,20004),
(118,1,2,20005),
(119,1,2,20006),
(50,1,2,23001),
(51,1,2,23002),
(52,1,2,23003),
(53,1,2,23004),
(127,1,2,55001),
(128,1,2,55002);

--
-- Table structure for table `llx_usergroup_user`
--

CREATE TABLE `llx_usergroup_user` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `fk_user` int(11) NOT NULL,
  `fk_usergroup` int(11) NOT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_usergroup_user` (`entity`,`fk_user`,`fk_usergroup`),
  KEY `fk_usergroup_user_fk_user` (`fk_user`),
  KEY `fk_usergroup_user_fk_usergroup` (`fk_usergroup`),
  CONSTRAINT `fk_usergroup_user_fk_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`),
  CONSTRAINT `fk_usergroup_user_fk_usergroup` FOREIGN KEY (`fk_usergroup`) REFERENCES `llx_usergroup` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=15 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_usergroup_user`
--

INSERT INTO `llx_usergroup_user` VALUES
(2,1,1,3),
(12,1,2,4),
(14,1,3,2),
(3,1,3,3),
(4,1,11,2),
(5,1,13,4),
(6,1,16,1),
(7,1,17,1),
(11,1,18,1);

--
-- Table structure for table `llx_webhook_history`
--

CREATE TABLE `llx_webhook_history` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `trigger_data` text NOT NULL,
  `fk_target` int(11) NOT NULL,
  `url` int(11) NOT NULL,
  `note_private` text DEFAULT NULL,
  `date_creation` datetime NOT NULL,
  `tms` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `status` int(11) NOT NULL DEFAULT 1,
  `trigger_code` varchar(128) NOT NULL DEFAULT 'UNKOWN',
  `error_message` text DEFAULT NULL,
  PRIMARY KEY (`rowid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `llx_webhook_history`
--


--
-- Table structure for table `llx_webhook_target`
--

CREATE TABLE `llx_webhook_target` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `ref` varchar(128) NOT NULL,
  `label` varchar(255) DEFAULT NULL,
  `type` int(11) NOT NULL DEFAULT 0,
  `description` text DEFAULT NULL,
  `note_public` text DEFAULT NULL,
  `note_private` text DEFAULT NULL,
  `date_creation` datetime NOT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) NOT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `status` int(11) NOT NULL DEFAULT 0,
  `url` varchar(255) NOT NULL,
  `connection_method` varchar(255) DEFAULT NULL,
  `connection_data` varchar(255) DEFAULT NULL,
  `trigger_codes` text DEFAULT NULL,
  `trigger_stack` text DEFAULT NULL,
  `entity` int(11) NOT NULL DEFAULT 1,
  PRIMARY KEY (`rowid`),
  KEY `idx_webhook_target_rowid` (`rowid`),
  KEY `idx_webhook_target_ref` (`ref`),
  KEY `llx_webhook_target_fk_user_creat` (`fk_user_creat`),
  KEY `idx_webhook_target_status` (`status`)
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_webhook_target`
--

INSERT INTO `llx_webhook_target` VALUES
(16,'16','dd',0,'',NULL,NULL,'2023-02-19 22:05:14','2023-02-20 01:05:14',12,12,NULL,1,'ddd',NULL,NULL,'fdfd,gdfgfd,KNOWLEDGERECORD_DELETE,PARTNERSHIP_CREATE',NULL,1);

--
-- Table structure for table `llx_website`
--

CREATE TABLE `llx_website` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `entity` int(11) NOT NULL DEFAULT 1,
  `ref` varchar(128) DEFAULT NULL,
  `description` varchar(255) DEFAULT NULL,
  `status` int(11) DEFAULT NULL,
  `fk_default_home` int(11) DEFAULT NULL,
  `virtualhost` varchar(255) DEFAULT NULL,
  `date_creation` datetime DEFAULT NULL,
  `date_modification` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `maincolor` varchar(16) DEFAULT NULL,
  `maincolorbis` varchar(16) DEFAULT NULL,
  `use_manifest` int(11) DEFAULT NULL,
  `lang` varchar(8) DEFAULT NULL,
  `otherlang` varchar(255) DEFAULT NULL,
  `position` int(11) DEFAULT 0,
  `lastaccess` datetime DEFAULT NULL,
  `pageviews_month` bigint(20) unsigned DEFAULT 0,
  `pageviews_total` bigint(20) unsigned DEFAULT 0,
  `pageviews_previous_month` bigint(20) unsigned DEFAULT 0,
  `name_template` varchar(255) DEFAULT NULL,
  `lastpageid` int(11) DEFAULT 0,
  `paymentframemode` int(11) DEFAULT 0,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_website_ref` (`ref`,`entity`)
) ENGINE=InnoDB AUTO_INCREMENT=48 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_website`
--

INSERT INTO `llx_website` VALUES
(12,1,'mytestwebsite','',1,92,NULL,'2024-06-20 11:33:08',NULL,'2025-06-25 17:10:19',12,12,NULL,NULL,NULL,0,'en','fr',0,'2025-06-25 17:10:19',158,158,147,NULL,92,0),
(13,1,'aaa','',1,93,'','2024-12-29 19:47:22',NULL,'2025-05-16 08:23:01',12,NULL,NULL,NULL,NULL,NULL,'en','',0,'2025-05-16 08:23:01',10,10,8,'website_template-restaurant',93,0),
(14,1,'bbb','',1,94,'','2024-12-29 19:49:56',NULL,'2025-03-27 10:15:22',12,NULL,NULL,NULL,NULL,NULL,'en','',0,'2025-03-27 10:15:22',33,33,32,'website_template-noimg',94,0),
(35,1,'ccc','',1,222,NULL,'2024-12-31 13:35:29',NULL,'2025-04-16 22:23:24',12,12,NULL,NULL,NULL,0,'en','',0,'2025-04-16 22:23:24',16,16,8,'website_template-corporate',225,0),
(37,1,'marketplace','Welcome to the Marketplace of MyBigCompany Company',1,115,NULL,'2024-12-31 14:03:08',NULL,'2025-04-16 22:22:16',12,NULL,NULL,NULL,NULL,NULL,'en','fr,de,it,es',0,'2025-04-16 22:22:16',26,26,25,'website_template-dolistore',115,0),
(38,1,'test','',1,173,'','2025-03-27 09:56:27',NULL,'2025-05-06 10:40:51',12,NULL,NULL,NULL,NULL,NULL,'en','fr,de,it,es',0,'2025-05-06 10:40:51',5,5,3,'website_template-dolistore',169,0),
(39,1,'test2','',1,211,'','2025-03-27 10:01:42',NULL,'2025-05-06 11:45:37',12,NULL,NULL,NULL,NULL,NULL,'en','',0,'2025-05-06 11:45:37',25,25,18,'website_asso02-20250326175312-V22',211,0),
(40,1,'test3','',1,236,'','2025-05-06 12:41:51',NULL,'2025-05-16 08:23:05',12,NULL,NULL,NULL,NULL,NULL,'en','en,fr,de,it,es',0,'2025-05-16 08:23:05',63,63,0,'website_asso3-20250505174005-V22',236,0),
(41,1,'test4','',1,258,NULL,'2025-05-16 10:23:12',NULL,'2025-05-16 10:10:11',12,12,NULL,NULL,NULL,0,'en','en,fr',0,'2025-05-16 10:10:11',22,22,0,'website_template-association_exp',267,0),
(42,1,'test5','',1,280,'','2025-05-16 12:09:58',NULL,'2025-06-02 17:28:47',12,NULL,NULL,NULL,NULL,NULL,'en','en,fr,de,it,es',0,'2025-06-02 17:28:47',1,1,0,'website_template-association_exp',289,0),
(43,1,'test6','',1,302,NULL,'2025-06-02 17:36:35',NULL,'2025-06-02 19:14:24',12,12,NULL,NULL,NULL,0,'en','en,fr,de,it,es',0,'2025-06-02 19:14:24',1,1,0,'website_template-association_exp',310,0),
(44,1,'test7','',1,NULL,'','2025-06-16 19:46:50',NULL,'2025-06-16 19:47:14',12,NULL,NULL,NULL,NULL,NULL,'fr','',0,NULL,0,0,0,NULL,0,0),
(46,1,'ddd','',1,NULL,'','2025-06-16 19:53:34',NULL,'2025-06-16 17:53:34',12,NULL,NULL,NULL,NULL,NULL,'fr','',0,NULL,0,0,0,NULL,0,0),
(47,1,'eee','',1,NULL,'','2025-06-16 19:57:47',NULL,'2025-06-16 17:57:47',12,NULL,NULL,NULL,NULL,NULL,'fr','',0,NULL,0,0,0,NULL,0,0);

--
-- Table structure for table `llx_website_extrafields`
--

CREATE TABLE `llx_website_extrafields` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_object` int(11) NOT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  KEY `idx_website_extrafields` (`fk_object`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_website_extrafields`
--


--
-- Table structure for table `llx_website_page`
--

CREATE TABLE `llx_website_page` (
  `rowid` int(11) NOT NULL AUTO_INCREMENT,
  `fk_website` int(11) NOT NULL,
  `pageurl` varchar(255) DEFAULT NULL,
  `aliasalt` varchar(255) DEFAULT NULL,
  `title` varchar(255) DEFAULT NULL,
  `description` varchar(255) DEFAULT NULL,
  `keywords` varchar(255) DEFAULT NULL,
  `content` mediumtext DEFAULT NULL,
  `status` int(11) DEFAULT 1,
  `date_creation` datetime DEFAULT NULL,
  `date_modification` datetime DEFAULT NULL,
  `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `fk_user_creat` int(11) DEFAULT NULL,
  `fk_user_modif` int(11) DEFAULT NULL,
  `type_container` varchar(16) NOT NULL DEFAULT 'page',
  `lang` varchar(6) DEFAULT NULL,
  `fk_page` int(11) DEFAULT NULL,
  `grabbed_from` varchar(255) DEFAULT NULL,
  `htmlheader` mediumtext DEFAULT NULL,
  `import_key` varchar(14) DEFAULT NULL,
  `image` varchar(255) DEFAULT NULL,
  `author_alias` varchar(64) DEFAULT NULL,
  `allowed_in_frames` int(11) DEFAULT 0,
  `object_type` varchar(255) DEFAULT NULL,
  `fk_object` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`rowid`),
  UNIQUE KEY `uk_website_page_url` (`fk_website`,`pageurl`),
  CONSTRAINT `fk_website_page_website` FOREIGN KEY (`fk_website`) REFERENCES `llx_website` (`rowid`)
) ENGINE=InnoDB AUTO_INCREMENT=315 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci;

--
-- Dumping data for table `llx_website_page`
--


INSERT INTO `llx_website_page` VALUES
(186,38,'order-details','','order details','','','<?php // BEGIN PHP\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\n//error_reporting(E_ALL);\n//ini_set(\'display_errors\', 1);\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\ninclude_once DOL_DOCUMENT_ROOT.\'/ecm/class/ecmfiles.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/security2.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/core/lib/date.lib.php\';\n\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n$order_ref = GETPOST(\'ref\', \'alpha\');\n\n// If not login redirect to login.\nif(empty($_SESSION[\'user\'][\'id_user\'])){\n    redirectToContainer(\'login-register\');\n}\n\n// Check if all necessary parameters are passed.\nif (empty($order_ref)) {\n	redirectToContainer(\'404\');\n    exit;\n}\n\n// Get Account ID.\n$user_id = $_SESSION[\'user\'][\'id_user\'];\n$customer_account = new SocieteAccount($db);\n$result = $customer_account->fetch($user_id);\n$customer_id = $customer_account->fk_soc;\n\n// Get customer ID.\n$customer = new Societe($db);\n$result = $customer->fetch($customer_id);\n\n// To render view of another user\nif (!empty(GETPOST(\'id_customer\'))) {\n    // Only for members with a specific role\n    require_once DOL_DOCUMENT_ROOT.\"/adherents/class/adherent.class.php\";\n    $membre = new Adherent($db);\n    $result = $membre->fetch(\'\', 0, $customer_id);\n    \n    $adminsCat = new Categorie($db);\n	$adminsCat->fetch(1);\n	\n	$result = $adminsCat->containsObject(\'member\', $membre->id);\n	if ($result > 0) {\n	    \n        $customer_id = GETPOST(\'id_customer\');\n	}\n}\n\n// Check if there is a paid order for this customer with the sent information.\n$sql_find_order = \"SELECT c.rowid, c.ref, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n$sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n$sql_find_order .= \"WHERE c.fk_soc = \" . $customer_id . \" and c.ref = \'\" . $order_ref . \"\' and ( c.fk_statut= 1 or c.fk_statut= -1 ) and (c.facture = 1 || c.ref_ext IS NOT NULL) and c.module_source = \'Marketplace\' \";\n$sql_find_order .= \"limit 1\";\n$find_order = $db->query($sql_find_order);\n$obj_order = $db->fetch_object($find_order);\n\nif (empty($obj_order)) {\n    redirectToContainer(\'404\');\n} else {\n    // Get order object\n    $order_ref = $obj_order->ref;\n    $order_object = new Commande($db);\n    $result = $order_object->fetch(\'\', $order_ref);\n    if ($result < 0) {\n    	redirectToContainer(\'404\');\n    }\n    \n    // Get invoice object\n    $order_object->fetchObjectLinked();\n    \n    if (!empty($order_object->linkedObjects[\'facture\'])) {\n        $linked_invoices = $order_object->linkedObjects[\'facture\'];\n        /*$last_invoice_object = $linked_invoices[reset(array_keys($linked_invoices))];\n        if ($last_invoice_object instanceof Facture) {\n            $invoice_object = $last_invoice_object;\n        }*/\n        \n        // Extract only regular invoices \n        $regular_invoices = array_filter($linked_invoices, function ($invoice) {\n            return ($invoice instanceof Facture) && ($invoice->type == 0);\n        });\n    \n        // Get first regular invoice if exist\n        if (!empty($regular_invoices)) {\n            $first_regular_invoice = reset($regular_invoices);\n            $invoice_object = $first_regular_invoice;\n        }\n        \n        // Get payment details\n        $sql_payment_details = \"SELECT c.libelle AS payment_method \";\n        $sql_payment_details .= \"FROM \";\n        $sql_payment_details .= \"\".MAIN_DB_PREFIX.\"paiement_facture AS pf \";\n        $sql_payment_details .= \"JOIN \".MAIN_DB_PREFIX.\"paiement AS p ON pf.fk_paiement = p.rowid \";\n        $sql_payment_details .= \"LEFT JOIN \".MAIN_DB_PREFIX.\"c_paiement AS c ON p.fk_paiement = c.id \";\n        $sql_payment_details .= \"WHERE \";\n        $sql_payment_details .= \"pf.fk_facture = \" . $invoice_object->id ;\n        \n        $invoice_ref = $invoice_object->ref;\n        \n        $find_payment_details = $db->query($sql_payment_details);\n        $obj_payment = $db->fetch_object($find_payment_details);\n        $payment_method = $obj_payment->payment_method;\n        \n        \n        // Generate invoice PDF (share it)\n        $sql_invoice_pdf = \"select lef.rowid as invoice_pdf_id \";\n        $sql_invoice_pdf .= \"from \".MAIN_DB_PREFIX.\"ecm_files lef \";\n        $sql_invoice_pdf .= \"where lef.src_object_type = \'facture\' and lef.src_object_id = \" . $invoice_object->id ;\n\n        $find_invoice_pdf = $db->query($sql_invoice_pdf);\n        $obj_invoice_pdf = $db->fetch_object($find_invoice_pdf);\n        $invoice_pdf_id = $obj_invoice_pdf->invoice_pdf_id;\n\n        $ecmfile = new EcmFiles($db);\n    	$result = $ecmfile->fetch($invoice_pdf_id);\n    	if ($result > 0 && empty($ecmfile->share)) {\n    		$ecmfile->share = getRandomPassword(true);\n    		$result = $ecmfile->update($user);\n    		if ($result < 0) {\n    			setEventMessages($ecmfile->error, $ecmfile->errors, \'warnings\');\n    		}\n    	}\n    	$invoice_pdf_link = DOL_URL_ROOT . \"/document.php?hashp=\" . $ecmfile->share;\n    	\n    	// Looking for credit notes for the main invoice. It can be more then one\n		$linked_credits = array();\n		foreach ($linked_invoices as $linked_invoice) {\n		    if ($linked_invoice instanceof Facture && $linked_invoice->fk_facture_source == $invoice_object->id && $linked_invoice->type == Facture::TYPE_CREDIT_NOTE && $linked_invoice->paye == 1) {\n		        $linked_credits[$linked_invoice->id][\'ref\'] = $linked_invoice->ref;\n		        \n		        // Get credit note PDF\n				$sql_credit_pdf = \"select lef.rowid, lef.share \";\n				$sql_credit_pdf .= \"from \".MAIN_DB_PREFIX.\"ecm_files lef \";\n				$sql_credit_pdf .= \"where lef.src_object_type = \'facture\' and lef.src_object_id = \" . $linked_invoice->id ;\n\n				$find_credit_pdf = $db->query($sql_credit_pdf);\n				$obj_credit_pdf = $db->fetch_object($find_credit_pdf);\n				$linked_credits[$linked_invoice->id][\'pdf_link\'] = DOL_URL_ROOT . \"/document.php?hashp=\" . $obj_credit_pdf->share;\n		    }\n		}\n\n    } else {\n        $payment_method = \"\";\n        $invoice_object = null;\n    }\n}\n\n\n// END PHP \n?>\n<div id=\"page\">\n  <div class=\"header-container\">\n    <?php\n        includeContainer(\'header\'); \n        $__PAGE__TITLE__ = $weblangs->trans(\"orderDetailsPageTitle\");\n    ?>\n  </div>\n\n  <div class=\"columns-container\">\n    <div id=\"columns\" class=\"container\">\n        <!--  Breadcrumb  -->\n        <div class=\"breadcrumb clearfix\">\n        	<a class=\"home\" href=\"index.php\" title=\"<?php print $weblangs->trans(\"backHome\"); ?>\"><i class=\"icon-home\"></i></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <a href=\"order-history.php\" title=\"<?php print $weblangs->trans(\"orderHistory\"); ?>\" data-gg=\"\"><?php print $weblangs->trans(\"orderHistory\"); ?></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"orderDetails\"); ?>\n        </div>\n        <!--  Breadcrumb  -->\n      <div id=\"slider_row\" class=\"row\">\n        <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n      </div>\n      <div class=\"row\">\n        <!-- include lefet sidebar container -->\n        <?php includeContainer(\'sidebar\'); ?>\n        <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n          <div class=\"clearfix\">\n                <h1 class=\"page-heading\"><?php print $weblangs->trans(\"orderDetails\"); ?></h1>\n                <div id=\"block-history\" class=\"block-center\">\n                    <div id=\"block-order-detail\" class=\"unvisible\" style=\"display: block;\">\n                    	<div class=\"info-order box\">\n                    	    <p class=\"dark\">\n                				<?php print $weblangs->trans(\"orderReference\"); ?> <strong><?php print $order_object->ref; ?></strong> - <?php print $weblangs->trans(\"placedOn\"); ?> <strong><?php print dol_print_date($order_object->date, \'day\'); ?></strong>\n                				<span style=\"background-color:#DDEEFF; border-color:#DDEEFF;padding: 4px 10px;float:right;\" class=\"label dark\"><?php print $weblangs->trans(\"paymentAccepted\"); ?></span>\n                			</p>\n                			<?php if (!empty($invoice_ref)): ?>\n                    			<p class=\"dark\">\n                    				<?php print $weblangs->trans(\"invoiceRef\"); ?> <strong><?php print $invoice_ref; ?></strong>\n                    			</p>\n                			<?php endif ?>\n                    		<p><strong class=\"dark\"><?php print $weblangs->trans(\"paymentMethod\"); ?> : </strong> <span class=\"color-myaccount\"><?php print $payment_method; ?></span></p>\n                    		<p class=\"download_invoice\">\n                    			<i class=\"icon-file-text\"></i>\n                    			<?php\n                    			    if ($invoice_object === null) {\n                    			        print $weblangs->trans(\"ifYouNeedAnInvoice\", \"https://wwwold.dolistore.com\", \"wwwold.dolistore.com\");\n                    			    } else{ ?>\n                    			        <a target=\"_blank\" href=\"<?php print $invoice_pdf_link; ?>\"><?php print $weblangs->trans(\"downloadInvoicePDF\"); ?></a>\n                    			    <?php } \n                    			?>\n                    			<?php if (!empty ($linked_credits) && count($linked_credits) > 0): ?>\n                    			    <hr>\n                    			    <?php\n                    			        // Prepare list of credit notes to be used after\n                    			        $credit_note_refs = array();\n                                        foreach ($linked_credits as $key => $linked_credit) {\n                                            $credit_note_refs[] = $linked_credit[\'ref\'];\n                                        }\n                                        $credit_note_refs_placeholder = implode(\',\', array_map(function($ref) use ($db) {\n                                            return \"\'\" . $db->escape($ref) . \"\'\";\n                                        }, $credit_note_refs));\n                    			    ?>\n                        		    <?php foreach ($linked_credits as $linked_credit): ?>\n        			                    <p class=\"invoice-pdf-link\">\n                                			<i class=\"icon-file-text\"></i>\n                                			<a target=\"_blank\" href=\"<?php print $linked_credit[\'pdf_link\']; ?>\"> <?php print $linked_credit[\'ref\']; ?></a>\n                                		</p>\n									<?php endforeach ?>\n                        		<?php endif ?>\n                    		</p>\n                    	</div>\n                    \n                        <!--\n                    	<div class=\"adresses_bloc\">\n                    		<div class=\"row\">\n                    			<div class=\"col-xs-12 col-sm-6\">\n                    				<ul class=\"address item full_width box\">\n                    					<li>\n                    						<h3 class=\"page-subheading\"><?php print $weblangs->trans(\"invoiceAddress\"); ?></h3>\n                    					</li>\n                    					<li><span class=\"address_firstname\"><?php print $customer->name; ?></span></li>\n                    					<li><span class=\"address_address1\"><?php print $customer->address; ?></span></li>\n                    					<li><span class=\"address_Country:name\"><?php print $customer->country; ?></span></li>\n                    					<li><span class=\"address_phone\"></span></li>\n                    				</ul>\n                    			</div>\n                    		</div>\n                    	</div>\n                        -->\n                        \n                    	<form action=\"\" method=\"post\">\n                    		<div id=\"order-detail-content\" class=\"table_block table-responsive\">\n                    			<table class=\"table table-bordered table-bordered-block-order-detail\">\n                    				<thead>\n                    					<tr>\n                    						<th class=\"first_item\"><?php print $weblangs->trans(\"product\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"download\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"Quantity\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"unitPrice\"); ?></th>\n                    						<th class=\"last_item\"><?php print $weblangs->trans(\"totalPrice\"); ?></th>\n                    					</tr>\n                    				</thead>\n                    				<tfoot>\n                    					<tr class=\"item\">\n                    						<td colspan=\"1\">\n                    							<strong> <?php print $weblangs->trans(\"TotalHT\"); ?> </strong>\n                    						</td>\n                    						<td colspan=\"4\">\n                    							<span class=\"price\"><?php print price($order_object->total_ht); ?> €</span></span>\n                    						</td>\n                    					</tr>\n                    					<tr class=\"totalprice item\">\n                    						<td colspan=\"1\">\n                    							<strong><?php print $weblangs->trans(\"TotalTTC\"); ?></strong>\n                    						</td>\n                    						<td colspan=\"4\">\n                    							<span class=\"price\"><?php print price($order_object->total_ttc); ?> €</span></span>\n                    						</td>\n                    					</tr>\n                    				</tfoot>\n                    				<tbody>\n                    					<!-- Customized products -->\n                    					<!-- Classic products -->\n                    					<?php $lines = $order_object->lines; ?>\n                    					<?php foreach ($lines as $line): ?>\n                    					    <?php\n                                                $product = new Product($db);\n                                                $ret = $product->fetch($line->fk_product);\n                                            ?>\n                        					<tr class=\"item\">\n                        						<td class=\"cart_description\">\n    												<p class=\"product-name\"><a target=\"_blank\" href=\"product.php?id=<?php print $product->id; ?>\"><?php print $line->desc; ?> <i class=\"icon-external-link\"></i></a></p>\n    												<small class=\"cart_ref\"><?php print $weblangs->trans(\"Ref\"); ?> : <?php print $product->ref; ?></small>\n    											</td>\n    											<td class=\"download_icon\">\n                        						    <?php \n                        						        // Get attached file\n        												$files = getPublicFilesOfObject($product);\n        												\n        												$url_attached_file = \'\';\n        												foreach ($files as $file) {\n                                                            if ($file[\'position\'] == 100) {     // TODO If we change position, this detection is broken. We should take the last file.\n                                                                $url_attached_file = $file[\'url\'];\n                                                            }\n                                                        }\n\n                                                        // Check Link Validity\n                                                        $now = dol_now();\n                                                        $one_year_ago = dol_time_plus_duree($now, -1, \'y\');\n                                                        $isValidLink = 1;\n                                                        if ($order_object->date < $one_year_ago) {\n                                                            $isValidLink = 0;\n                                                            $unvalidlinkmessage= $weblangs->trans(\"invalidLink\");\n                                                        }\n\n                                                        // Check refund qty\n                                            		    if (!empty($credit_note_refs) && is_array($credit_note_refs) && count($credit_note_refs) > 0) {\n                                        		            $sum_qty_returned = \"SELECT SUM(fd.qty) AS return_qty \";\n                                                            $sum_qty_returned .= \"FROM \" . MAIN_DB_PREFIX . \"facture AS f, \" . MAIN_DB_PREFIX . \"facturedet AS fd \";\n                                                            $sum_qty_returned .= \"WHERE f.rowid = fd.fk_facture \";\n                                                            $sum_qty_returned .= \"AND fd.fk_product = \" . ((int) $line->fk_product) . \" \";\n                                                            $sum_qty_returned .= \"AND f.ref IN (\" . $credit_note_refs_placeholder . \")\";\n                                                            //print $sum_qty_returned;exit;\n                                                            \n                                                            $resql = $db->query($sum_qty_returned);\n                                                            if ($resql) {\n                                                                $row = $db->fetch_object($resql);\n                                                                $total_return_qty = $row->return_qty ?? 0;\n                                                            }\n                                                            \n                                                            if (($line->qty - $total_return_qty) < 1) {\n                                                                $isValidLink = 0;\n                                                                $unvalidlinkmessage= \"-\";\n                                                            }\n                                                        }\n                                                        \n    												?>\n    												<?php if ($isValidLink == 1) { ?>\n    												    <p><a target=\"_blank\" href=\"_service_download.php?t=paied&r=<?php print $order_object->ref; ?>&p=<?php print $line->fk_product; ?>&u=<?php print $user_id; ?>\">\n    												        <i class=\"icon-cloud-download small\"></i> <?php echo $weblangs->trans(\"Download\"); ?>\n    												    </a></p>\n    												    <!--<p><a target=\"_blank\" href=\"<?php //print $url_attached_file; ?>\"><i class=\"icon-cloud-download\"></i></a></p>-->\n    												<?php } else { ?>\n    												    <p><?php print $unvalidlinkmessage; ?> </p>\n    												<?php } ?>\n    											</td>\n                        						<td class=\"return_quantity right\">\n                        							<span class=\"order_qte_span\"><?php print $line->qty; ?></span>\n                                            		    \n                                            		<?php if (!empty($total_return_qty)) { ?>\n                                            		    <span class=\"order_qte_span\" style=\"color:red;\">(<?php print $total_return_qty . \" \" . $weblangs->trans(\"Refunded\"); ?>)</span>\n                                            		<?php } ?>\n                        						</td>\n                        						<td class=\"right\">\n                        						    <?php print price($line->price); ?> €</span>\n                        						</td>\n                        						<td class=\"right\">\n                        							<?php print price($line->total_ttc); ?> €</span>\n                        						</td>\n                        					</tr>\n                    					<?php endforeach ?>\n                    					\n                    				</tbody>\n                    			</table>\n                    		</div>\n                    	</form>\n                    </div>\n                </div>\n                <ul class=\"footer_links clearfix\">\n                	<li>\n                		<a class=\"btn btn-default button button-small\" href=\"myaccount.php\">\n                			<span>\n                				<i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"backToYourAccount\"); ?>\n                			</span>\n                		</a>\n                	</li>\n                	<li>\n                		<a class=\"btn btn-default button button-small\" href=\"index.php\">\n                			<span><i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"Home\"); ?></span>\n                		</a>\n                	</li>\n                </ul>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div>\n  <!-- .columns-container -->\n  <div class=\"footer-container\">\n    <?php includeContainer(\'footer\'); ?>\n  </div>\n</div>',1,'2024-04-24 10:40:25',NULL,'2025-01-24 11:14:02',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(187,38,'order-history','','order history','','','<?php // BEGIN PHP\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT . \'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT . \'/core/lib/categories.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOSTINT(\'cat\');\n$search = GETPOST(\'search_query\', \'alpha\');\n\n// If not login redirect to login.\nif(empty($_SESSION[\'user\'][\'id_user\'])){\n    redirectToContainer(\'login-register\');\n}\n\n$weblangs->load(\"bills\");\n\n// Get Account ID.\n$user_id = $_SESSION[\'user\'][\'id_user\'];\n$customer_account = new SocieteAccount($db);\n$result = $customer_account->fetch($user_id);\n$customer_id = $customer_account->fk_soc;\n\n// Get customer ID.\n$customer = new Societe($db);\n$result = $customer->fetch($customer_id);\n\n$isAdmin = false;\n\n// To render view of another user\nif (!empty(GETPOST(\'id_customer\'))) {\n    // Only for members with a specific role\n    require_once DOL_DOCUMENT_ROOT.\"/adherents/class/adherent.class.php\";\n    $membre = new Adherent($db);\n    $result = $membre->fetch(\'\', 0, $customer_id);\n    \n    $adminsCat = new Categorie($db);\n	$adminsCat->fetch(1);\n	\n	$result = $adminsCat->containsObject(\'member\', $membre->id);\n	if ($result > 0) {\n	    $isAdmin = true;\n\n        $customer_id = GETPOST(\'id_customer\');\n        // Get soc info.\n        $socInfo = new Societe($db);\n        $socInfo->fetch($customer_id);\n        \n        // Get soc acount email\n        $sql = \"select rowid from \".MAIN_DB_PREFIX.\"societe_account where fk_soc = \".((int) $customer_id).\" AND fk_website = \".((int) $website->id).\" limit 1\";\n        $result = $db->query($sql);\n        $objsql = $db->fetch_object($result);\n        \n        // Get account info\n        $cContacts = $socInfo->contact_array_objects();\n        foreach ($cContacts as $cContact) {\n            if ($cContact->ref_ext == $objsql->rowid) {\n                $customer_firstname = $cContact->firstname;\n                $customer_lastname = $cContact->lastname;\n                $customer_email = $cContact->email;\n                $customer_address = $cContact->address;\n            }\n        }\n	}\n}\n\n// Get all paid orders for this customer when module_source is Marketplace.\n$sql_find_orders = \"SELECT c.rowid, c.ref, c.fk_statut, c.fk_soc, c.date_creation, c.date_commande, c.date_valid, c.module_source \";\n$sql_find_orders .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n$sql_find_orders .= \"WHERE c.fk_soc = \" . ((int) $customer_id) . \" and ( c.fk_statut= 1 or c.fk_statut= -1 ) and (c.facture = 1 || c.ref_ext IS NOT NULL) and c.module_source = \'Marketplace\' \";\n$sql_find_orders .= \"ORDER BY c.date_commande desc \";\n$resql = $db->query($sql_find_orders);\nif ($resql) {\n    $orders_id = array();\n	while ($obj = $db->fetch_object($resql)) {\n	    $orders_id[] = $obj->rowid;\n	}\n}/* else {\n	print $weblangs->trans(\"noOrderFounded\");\n	exit();\n}*/\n\n// END PHP \n?>\n<div id=\"page\">\n  <div class=\"header-container\">\n    <?php \n        includeContainer(\'header\');\n        $__PAGE__TITLE__ = $weblangs->trans(\"orderHistoryPageTitle\");\n    ?>\n  </div>\n\n  <div class=\"columns-container\">\n    <div id=\"columns\" class=\"container\">\n        <!--  Breadcrumb  -->\n        <div class=\"breadcrumb clearfix\">\n        	<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <a href=\"myaccount.php\" title=\"<?php print $weblangs->trans(\"myAccount\"); ?>\" data-gg=\"\"><?php print $weblangs->trans(\"myAccount\"); ?></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"orderHistory\"); ?>\n        </div>\n        <!--  Breadcrumb  -->\n      <div id=\"slider_row\" class=\"row\">\n        <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n      </div>\n      <div class=\"row\">\n        <!-- include lefet sidebar container -->\n        <?php includeContainer(\'sidebar\'); ?>\n        <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n            <?php if (empty($orders_id)): ?>\n                <h1 class=\"page-heading\"><?php print $weblangs->trans(\"orderHistory\"); ?></h1>\n                <p class=\"alert alert-warning\"><?php print $weblangs->trans(\"noOrderFounded\"); ?> </p>\n            <?php else: ?>\n              <div class=\"clearfix\">\n                    <h1 class=\"page-heading\"><?php print $weblangs->trans(\"orderHistory\"); ?></h1>\n                    <div id=\"block-history\" class=\"block-center\">\n                        <div id=\"block-order-detail\" class=\"unvisible\" style=\"display: block;\">\n                    		<div id=\"order-detail-content\" class=\"table_block table-responsive\">\n                    			<table class=\"table table-bordered table-bordered-block-order-detail order-history\">\n                    				<thead>\n                    					<tr>\n                    						<th class=\"first_item\"><?php print $weblangs->trans(\"orderRef\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"products\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"Date\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"totalPrice\"); ?></th>\n                    						<th class=\"item\" width=\"80\"><?php print $weblangs->trans(\"paymentMethod\"); ?></th>\n                    						<th class=\"item\"><?php print $weblangs->trans(\"Invoice\"); ?></th>\n                    						<th class=\"last_item\"><?php print $weblangs->trans(\"details\"); ?></th>\n                    					</tr>\n                    				</thead>\n                    				<tbody>\n                    					<!-- Customized products -->\n                    					<!-- Classic products -->\n                    					<?php foreach ($orders_id as $order_id): ?>\n                    					    <?php\n                                                // Get order object\n                                                $order_object = new Commande($db);\n                                                $result = $order_object->fetch($order_id);\n                                                \n                                                // Get invoice object\n                                                $order_object->fetchObjectLinked();\n                                                if (!empty($order_object->linkedObjects[\'facture\'])) {\n    												$linked_invoices = $order_object->linkedObjects[\'facture\'];\n                                                    /*$last_invoice_object = $linked_invoices[reset(array_keys($linked_invoices))];\n    \n                                                    if ($last_invoice_object instanceof Facture) {\n                                                        $invoice_object = $last_invoice_object;\n                                                        print $invoice_object->ref;\n                                                    }*/\n                                                    \n                                                    // Extract only regular invoices \n                                                    $regular_invoices = array_filter($linked_invoices, function ($invoice) {\n                                                        return ($invoice instanceof Facture) && ($invoice->type == 0);\n                                                    });\n                                                \n                                                    // Get first regular invoice if exist\n                                                    if (!empty($regular_invoices)) {\n                                                        $first_regular_invoice = reset($regular_invoices);\n                                                        $invoice_object = $first_regular_invoice;\n                                                    }\n    \n    												// Get payment details\n    												$sql_payment_details = \"SELECT c.libelle AS payment_method \";\n    												$sql_payment_details .= \"FROM \";\n    												$sql_payment_details .= \"\".MAIN_DB_PREFIX.\"paiement_facture AS pf \";\n    												$sql_payment_details .= \"JOIN \".MAIN_DB_PREFIX.\"paiement AS p ON pf.fk_paiement = p.rowid \";\n    												$sql_payment_details .= \"LEFT JOIN \".MAIN_DB_PREFIX.\"c_paiement AS c ON p.fk_paiement = c.id \";\n    												$sql_payment_details .= \"WHERE \";\n    												$sql_payment_details .= \"pf.fk_facture = \" . ((int) $invoice_object->id);\n    												\n    												$invoice_ref = $invoice_object->ref;\n    												\n    												$find_payment_details = $db->query($sql_payment_details);\n    												$obj_payment = $db->fetch_object($find_payment_details);\n    												$payment_method = $obj_payment->payment_method;\n    \n    												// Get invoice PDF\n    												$sql_invoice_pdf = \"select lef.rowid, lef.share \";\n    												$sql_invoice_pdf .= \"from \".MAIN_DB_PREFIX.\"ecm_files lef \";\n    												$sql_invoice_pdf .= \"where lef.src_object_type = \'facture\' and lef.src_object_id = \" . ((int) $invoice_object->id);\n    \n    												$find_invoice_pdf = $db->query($sql_invoice_pdf);\n    												$obj_invoice_pdf = $db->fetch_object($find_invoice_pdf);\n    												$invoice_pdf_link = DOL_URL_ROOT . \"/document.php?hashp=\" . urlencode($obj_invoice_pdf->share);\n    												\n    												// Looking for credit notes for the main invoice. It can be more then one\n    												$linked_credits = array();\n    												foreach ($linked_invoices as $linked_invoice) {\n    												    if ($linked_invoice instanceof Facture && $linked_invoice->fk_facture_source == $invoice_object->id && $linked_invoice->type == Facture::TYPE_CREDIT_NOTE && $linked_invoice->paye == 1) {\n    												        $linked_credits[$linked_invoice->id][\'ref\'] = $linked_invoice->ref;\n    												        $linked_credits[$linked_invoice->id][\'total_ttc\'] = $linked_invoice->total_ttc;\n    												        \n    												        // Get credit note PDF\n            												$sql_credit_pdf = \"select lef.rowid, lef.share \";\n            												$sql_credit_pdf .= \"from \".MAIN_DB_PREFIX.\"ecm_files lef \";\n            												$sql_credit_pdf .= \"where lef.src_object_type = \'facture\' and lef.src_object_id = \" . $linked_invoice->id ;\n            \n            												$find_credit_pdf = $db->query($sql_credit_pdf);\n            												$obj_credit_pdf = $db->fetch_object($find_credit_pdf);\n            												$linked_credits[$linked_invoice->id][\'pdf_link\'] = DOL_URL_ROOT . \"/document.php?hashp=\" . $obj_credit_pdf->share;\n    												    }\n    												}\n    \n                                                } else {\n    												$payment_method = \"\";\n    												$invoice_pdf_link = \"#\";\n    												$invoice_ref = \"/\";\n                                                }\n                                            ?>\n                        					<tr class=\"item\">\n                        					    <td class=\"nowraponall center\">\n                        						    <span class=\"cart_ref\"><?php print dolPrintHTML($order_object->ref); ?></span>\n                        						</td>\n                        						<td class=\"order-history\">\n                        						    <?php $order_lines = $order_object->lines; ?>\n                        						    <ul class=\"order-history-products-list\">\n                        						    <?php foreach ($order_lines as $order_line): ?>\n                        			                    <li><?php print $order_line->desc; ?></li>\n    												<?php endforeach ?>\n    												</ul>\n    											</td>\n                        						<td>\n    												<p title=\"<?php print dol_print_date($order_object->date_commande, \'dayhour\'); ?>\"><?php print dol_print_date($order_object->date_commande, \'day\'); ?></p>\n    											</td>\n                        						<td>\n                        							<p><span class=\"price\"><?php print price($order_object->total_ttc); ?> €</span></p>\n                        						</td>\n                        						<td>\n                        						    <p><?php print $payment_method; ?></p>\n                        						</td>\n                        						<td class=\"nowraponall\">\n                        						    <?php if ($invoice_pdf_link != \"#\"): ?>\n                            						    <p class=\"invoice-pdf-link\">\n                                                			<i class=\"icon-file-text\"></i>\n                                                			<a target=\"_blank\" href=\"<?php print $invoice_pdf_link; ?>\"> <?php print $invoice_ref; ?></a>\n                                                		</p>\n                                                		<?php if (count($linked_credits) > 0): ?>\n                                                		    <?php foreach ($linked_credits as $linked_credit): ?>\n                                			                    <p class=\"invoice-pdf-link\">\n                                                        			<i class=\"icon-file-text\"></i>\n                                                        			<a target=\"_blank\" href=\"<?php print $linked_credit[\'pdf_link\']; ?>\"> <?php print $linked_credit[\'ref\']; ?></a>\n                                                        			<span style=\"font-size: 12px;\">(<?php print price($linked_credit[\'total_ttc\']); ?> €)</span>\n                                                        		</p>\n            												<?php endforeach ?>\n                                                		<?php endif ?>\n                                                	<?php endif ?>\n                        						</td>\n                        						<td class=\"btn-table\">\n                        						    <a href=\"order-details.php?ref=<?php print $order_object->ref; ?>\" class=\"btn btn-default button button-small\"><span><?php print $weblangs->trans(\"details\"); ?> <i class=\"icon-chevron-right right\"></i></span></a>\n                        						</td>\n                        					</tr>\n                    					<?php endforeach ?>\n                    				</tbody>\n                    			</table>\n                    		</div>\n                        </div>\n                    </div>\n                    <ul class=\"footer_links clearfix\">\n                    	<li>\n                    		<a class=\"btn btn-default button button-small\" href=\"myaccount.php\">\n                    			<span>\n                    				<i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"backToYourAccount\"); ?>\n                    			</span>\n                    		</a>\n                    	</li>\n                    	<li>\n                    		<a class=\"btn btn-default button button-small\" href=\"index.php\">\n                    			<span><i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"Home\"); ?></span>\n                    		</a>\n                    	</li>\n                    </ul>\n              </div>\n          \n            <?php endif ?>\n        </div>\n      </div>\n    </div>\n  </div>\n  <!-- .columns-container -->\n  <div class=\"footer-container\">\n    <?php includeContainer(\'footer\'); ?>\n  </div>\n</div>',1,'2024-04-26 08:50:17',NULL,'2025-01-24 11:55:49',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(188,38,'pagamenti-e-sicurezza','','Pagamenti e sicurezza','Pagamenti e sicurezza','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<script src=\"/document.php?modulepart=medias&file=js/tools.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/treeManagement.js\"></script>\n<?php // BEGIN PHP\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n        <!--  Breadcrumb  -->\n		<div class=\"breadcrumb clearfix\">\n			<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n			<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n		</div>\n		<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n            \n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"about_payement_section\" contenteditable=\"true\">\n				<div class=\"rte\">\n                  <h2>Pagamenti sicuri</h2>\n                  <p>&nbsp;</p>\n                  <h3>Perché dovrei pagare se il software è rilasciato sotto licenza Open Source &nbsp;(GPL, ...) ?</h3>\n                  <p>La maggior parte dei prodotti disponibili sulla piattaforma sono gratuiti e possono essere scaricati liberamente. In tali casi non è previsto alcun pagamento.</p>\n                  <p>In alcuni casi gli autori decidono di richiedere un pagamento a fronte del loro lavoro. I due approcci non sono in conflitto (Vendita e distribuzione libera sotto licenza OpenSource): La <strong>&nbsp;Free Software Foundationche ha creato la celebre</strong>&nbsp;licenza GPL, una delle licenze più usate per il software&nbsp;OpenSource, permette ed incoraggia questa ciò e fornisce qualche spiegazione sulla seguente pagina: <br>\n                    <a href=\"http://www.gnu.org/philosophy/selling.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.html</a>\n                  </p>\n                  <p>&nbsp;</p>\n                  <h3>Pagamento sicuro</h3>\n                  <p>Tutti i pagamenti sono protetti con&nbsp;SSL.</p>\n                  <p>&nbsp;</p>\n                  <h3>Usare Visa/Mastercard/Paypal</h3>\n                  <p>I pagamenti effettuati tramite carta di credito vengono processati tramite Stripe.</p>\n                  <p>Per i pagamenti tramite Paypal vengono usati i servizi online forniti da Paypal&nbsp;stessa.</p>\n                </div>\n				</section>\n\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 22:13:17',NULL,'2025-01-14 01:26:59',NULL,NULL,'page','it',153,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(189,38,'paiements-et-securisation','','Paiements et sécurisation','Paiements et sécurisation','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<script src=\"/document.php?modulepart=medias&file=js/tools.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/treeManagement.js\"></script>\n<?php // BEGIN PHP\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n        <!--  Breadcrumb  -->\n		<div class=\"breadcrumb clearfix\">\n			<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n			<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n		</div>\n		<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n            \n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"about_payement_section\" contenteditable=\"true\">\n				<div class=\"rte\">\n                  <h2>Paiement sécurisé</h2>\n                  <p>&nbsp;</p>\n                  <h3>Quand et pourquoi un paiement si le logiciel est en OpenSource (GPL, ...) ?</h3>\n                  <p>La plupart des produits disponibles sur cette place de marché sont gratuit et peuvent être téléchargés directement depuis leur fiche. Aucun paiement dans ce cas n\'est requis.</p>\n                  <p>Toutefois, certains auteurs decident de faire payer quelquechose en échange de la distribution de leur travail. Il n\'y a aucun problème à conciler les 2 approches (Prix pour distribuer du code face à&nbsp; licence OpenSource): La <strong>Free Software Foundation</strong>, qui a créé la licence GNU GPL, une des licence pour les logiciels libre les plus utilisées, autorise et même encourage cela et en donne les explications, sur cette page : <br>\n                    <a href=\"http://www.gnu.org/philosophy/selling.fr.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.fr.html</a>\n                  </p>\n                  <p>&nbsp;</p>\n                  <h3>Notre offre de paiement sécurisé</h3>\n                  <p>Les paiements sont sécurisé avec SSL</p>\n                  <p>&nbsp;</p>\n                  <h3>Utilisation de Visa/Mastercard/Paypal</h3>\n                  <p>Les paiements par carte bancaire sont assurés par un service de Stripe.</p>\n                  <p>Les paiement par porte monnaie électronique sont assurés via le service de paiement en ligne de Paypal.</p>\n                </div>\n				</section>\n\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 22:10:45',NULL,'2025-01-16 00:36:38',NULL,NULL,'page','fr',153,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(190,38,'payment','','payment','','','<?php\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT . \'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT . \'/core/lib/categories.lib.php\';\n\nif (empty($_SESSION[\'user\'][\'id_user\'])) {\n    $login_page_url = \"index.php?website=\".$website->ref.\"&pageref=login-register&back=payement\";\n    header(\"Location:\".$login_page_url);\n    exit;\n}\n                        \n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n?>\n\n<div id=\"page\">\n	<div class=\"header-container\">\n		<?php\n		    includeContainer(\'header\');\n		    $__PAGE__TITLE__ = $weblangs->trans(\"paymentPageTitle\");\n		?>\n	</div>\n	<div class=\"columns-container\">\n		<div id=\"columns\" class=\"container\">\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"yourShoppingCart\"); ?>\n			</div>\n			<!--  Breadcrumb  -->\n			<div id=\"slider_row\" class=\"row\">\n				<div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n			</div>\n			<div class=\"row\">\n				<!-- include lefet sidebar container -->\n				<?php includeContainer(\'sidebar\'); ?>\n				\n				<div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n					<div class=\"clearfix\">\n\n                        <?php\n                            if(!empty($_SESSION[\'products\'])){\n                                \n                                include_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\n                                require_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n\n                                // Load user and its permissions\n                                $result = $user->fetch(\'\', \'admin\');	// Load user for login \'admin\'. Comment line to run as anonymous user.\n                                if (!$result > 0) {\n                                	dol_print_error(null, $user->error);\n                                	exit;\n                                }\n                                $user->getrights();\n                                \n                                $user_id = $_SESSION[\'user\'][\'id_user\'];\n                                $customer = new SocieteAccount($db);\n                                $result = $customer->fetch($user_id);\n                                $customer_id = $customer->fk_soc;\n                                if (empty($customer_id)) {\n                                	dol_print_error(null, $customer->error);\n                                	exit;\n                                }\n                                \n                                $com = new Commande($db);\n                            \n                                $com->socid          = $customer_id;\n                                $com->date           = dol_now();\n                                $com->note_private   = \'Order from the marketplace\';\n                                $com->module_source  = \'marketplace\';\n                                $com->pos_source	 = dol_getmypid() . \"@\" . $website->id;\n                                $com->remise_percent = 0;\n                                \n                                $db->begin();\n                                \n                                // Check if there is an existing open order for this thirdparty.\n                                $sql_find_order = \"SELECT c.rowid, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n                                $sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n                                $sql_find_order .= \"WHERE c.fk_soc = \" . ((int) $customer_id) . \" and c.fk_statut= 1 and c.facture = 0 and c.ref_ext is null \"; // ignore billed orders and imported orders\n                                $sql_find_order .= \"AND c.date_commande >= DATE_SUB(NOW(), INTERVAL 30 DAY) and c.module_source = \'marketplace\' \";  // ignore too old open orders\n                                $sql_find_order .= \"ORDER BY c.date_creation DESC \";\n                                $sql_find_order .= \"LIMIT 1\";\n                                \n                                $find_order = $db->query($sql_find_order);\n                                $obj_order = $db->fetch_object($find_order);\n                                \n                                // If there is an order, update the current unpaid order lines by SESSION articles.\n                                if (!empty($obj_order)) {\n                                    $com->fetch($obj_order->rowid);\n                                    \n                                    //$com->fetch_lines();      // the fetch_lines is already included into the fetch\n                                    \n                                    $lines = $com->lines;\n                                    \n                                    $com->setDraft($user);      // ensure order is set back to draft status\n                                    \n                                    // remove current order lines \n                                    foreach ($lines as $line){\n                                        $ree = $com->deleteLine($user, $line->id);\n                                        //print $com->error . \'<br>\';\n                                    }\n\n                                    $result = $com->id;\n                                } else {\n                                    $result = $com->create($user);\n                                }\n                                \n                                if ($result >= 0) {\n                                    // Loop on each product into session and add it into the order\n                                    foreach ($_SESSION[\'products\'] as $session_product) {\n                                        // Get  product\n                                        $product = new Product($db);\n                                        $result = $product->fetch($session_product[\'product_id\']);\n                                        if (!$result > 0) {\n                                        	dol_print_error($db, $product->error);\n                                        	exit;\n                                        }\n                                        \n                                		// Get buyer\n                                	    $thirdparty_buyer = new Societe($db);\n                                        $result = $thirdparty_buyer->fetch($customer_id);\n                                        if (!$result > 0) {\n                                        	dol_print_error($db, $thirdparty_buyer->error);\n                                        	exit;\n                                        }\n\n                                        // Get seller\n                                        $sql_get_seller_id = \"select lpfp.rowid, lpfp.fk_soc \n                                            from \".MAIN_DB_PREFIX.\"product_fournisseur_price lpfp \n                                            where lpfp.fk_product = \" .((int) $session_product[\'product_id\']) . \" LIMIT 1\"; // we hope to have only one supplier for each product\n                                        $resql = $db->query($sql_get_seller_id);\n                                		$objsql = $db->fetch_object($resql);\n                                		\n                                		if (!empty($objsql->fk_soc)) {\n                                		    $thirdparty_seller = new Societe($db);\n                                            $thirdparty_seller->fetch($objsql->fk_soc);\n\n                                            //$tva_tx = get_default_tva($thirdparty_seller, $thirdparty_buyer, $product->id, $objsql->rowid);   // it seems tha vat rate of supplier price not always correctly defined, so we redo the generic code\n                                            $tva_tx = get_default_tva($thirdparty_seller, $thirdparty_buyer, $product->id);\n                                		} else {\n                                		    // To complete with default third party if no price/no seller was found for product ?\n\n                                            $tva_tx = get_default_tva($thirdparty_seller, $thirdparty_buyer, $product->id);\n                                		}\n                                        \n                                        // Check discount\n                            			$discount = marketplace_check_discount($product->id);\n                            			$discount_percent = ($discount[\'mode\'] === \'percent\') ? $discount[\'value\'] : 0;\n                                        \n                                        $result = $com->addline($product->label, $product->price, $session_product[\'product_qty\'], $tva_tx, 0, 0, $product->id, $discount_percent, 0, 0, $product->price_base_type, $product->price_ttc, \'\', \'\', $product->type);\n                            			if ($result <= 0) {\n                            				dol_print_error($db, $product->error);\n                            				exit;\n                            			}\n                            			\n                            			// TODO\n                    					if ($discount[\'mode\'] === \'amount\' && $discount[\'value\'] > 0) {\n                                            // Add amount discount\n                    					}\n\n                                    } \n                                    \n                                    $com->set_date($user, dol_now(), 1);\n                                    \n                                    $result = $com->valid($user);\n                                    \n                            		if ($result > 0) {\n                            			$db->commit();\n                                        $order_is_created = \'1\';\n                                        $order_id = $com->id;\n                            		} else {\n                            			$db->rollback();\n                            			dol_print_error($db, $com->error);\n                            		}\n                            	} else {\n                            		$db->rollback();\n                            		dol_print_error($db, $com->error);\n                            	}\n                            }\n                            \n        \n                            if (isset($order_is_created)){\n                                $commande = new Commande($db);\n                                $ret = $commande->fetch($order_id);\n                                \n                                //$commande->fetch_lines();     // already included into the fetch()\n                                \n                                $lines = $commande->lines;\n                            }\n                        ?>\n\n						<h1 class=\"page-heading\"><?php print $weblangs->trans(\"cartSummary\"); ?>\n    						<span class=\"heading-counter\"><?php print $weblangs->trans(\"yourCartContains\"); ?>:\n        						<?php if (isset($lines)): ?>\n                                    <span class=\"ajax_cart_no_product\"><?php print count($lines); ?></span> <?php if(count($lines) > 1){ print $weblangs->trans(\"products\");}else{ print $weblangs->trans(\"product\");} ?>\n                                <?php else: ?>\n                                    <span id=\"ajax_cart_no_product\">0</span> <?php print $weblangs->trans(\"product\"); ?>\n                                <?php endif ?>\n    						</span>\n						</h1>\n						<?php if (!$_SESSION[\'products\'] || !isset($order_is_created)): ?>\n                            <?php if (!$_SESSION[\'products\']): ?>\n                                <p class=\"alert alert-warning\"><?php print $weblangs->trans(\"cartIsEmpty\"); ?></p>\n                            <?php endif ?>\n                            <?php if (!isset($order_is_created)): ?>\n                                <p class=\"alert alert-warning\"><?php print $weblangs->trans(\"errorOccurred\"); ?> </p>\n                            <?php endif ?>\n                        <?php else: ?>\n							<div id=\"order-detail-content\" class=\"table_block table-responsive\">\n								<table id=\"cart_summary\" class=\"table table-bordered stock-management-off\">\n									<thead>\n										<tr>\n											<th class=\"cart_product first_item\"><?php print $weblangs->trans(\"product\"); ?></th>\n											<th class=\"cart_description item\"><?php print $weblangs->trans(\"Description\"); ?></th>\n											<th class=\"cart_unit item text-center\"><?php print $weblangs->trans(\"UnitPriceHT\"); ?></th>\n											<th class=\"cart_quantity item text-center\"><?php print $weblangs->trans(\"Quantity\"); ?></th>\n											<th class=\"cart_total item cart_total_payment\"><?php print $weblangs->trans(\"TotalTTC\"); ?></th>\n										</tr>\n									</thead>\n									\n									<tbody>\n                                        <?php $total = 0; ?>\n                                        \n                                        <?php foreach ($lines as $line): ?>\n                                            <?php\n                                                $product = new Product($db);\n                                                $ret = $product->fetch($line->fk_product);\n                                            ?>\n                                            <tr id=\"product_<?php print $product->id; ?>\" class=\"cart_item\">\n    											<td class=\"cart_product\">\n    												<a href=\"product.php?id=<?php print $product->id; ?>\"><img src=\"<?php print getImagePublicURLOfObject($product,1);; ?>\" id=\"product_img_<?php print $product->id; ?>\" alt=\"<?php print $product->name; ?>\" width=\"98\" height=\"98\"></a>\n    											</td>\n    											<td class=\"cart_description\">\n    												<p class=\"product-name\"><a href=\"product.php?id=<?php print $product->id; ?>\"><?php print $line->desc; ?></a></p>\n    												<small class=\"cart_ref\"><?php print $weblangs->trans(\"sku\"); ?> : <?php print $product->ref; ?></small>\n    											</td>\n    											<td class=\"cart_unit\" data-title=\"Unit price\">\n    												<span class=\"price\" id=\"product_price\"><span class=\"price\" id=\"product_price_<?php print $product->id; ?>\"><?php print price($line->price); ?></span> €</span>\n    											</td>\n    \n    											<td class=\"cart_quantity text-center\">\n                                                    <span class=\"text-center\"><?php print $line->qty; ?></span>\n    											</td>\n    											<td class=\"cart_total cart_total_payment\" data-title=\"Total\">\n    												<span class=\"price\"><span class=\"total_line\" id=\"total_product_price_<?php print $product->id; ?>\"><?php print price($line->total_ttc); ?></span> €</span>\n    											</td>\n    										</tr>\n                                        <?php endforeach ?>\n                                    </tbody>\n                                    \n                                    <tfoot>\n										<tr class=\"cart_total_price\">\n											<td rowspan=\"5\" colspan=\"2\" id=\"cart_voucher\" class=\"cart_voucher\">\n											</td>\n											<td colspan=\"2\" class=\"text-right\"><?php print $weblangs->trans(\"totalProductsTaxIncl\"); ?></td>\n											<td colspan=\"2\" class=\"price\" ><span id=\"total_product\"><?php print price($commande->total_ttc); ?></span> €</td>\n										</tr>\n										<tr class=\"cart_total_delivery\">\n											<td colspan=\"2\" class=\"text-right\"><?php print $weblangs->trans(\"Shipping\"); ?></td>\n											<td colspan=\"2\" class=\"price\" id=\"total_shipping\"><?php print $weblangs->trans(\"freeShipping\"); ?></td>\n										</tr>\n\n										<tr class=\"cart_total_price\">\n											<td colspan=\"2\" class=\"total_price_container text-right\">\n												<span><?php print $weblangs->trans(\"total\"); ?></span>\n											</td>\n											<td colspan=\"2\" class=\"price\" id=\"total_price_container\">\n												<span><span id=\"total_price\"><?php print price($commande->total_ttc); ?></span> €</span>\n											</td>\n										</tr>\n									    </tfoot>\n								</table>\n							</div>\n    						\n    						<?php if (!getDolGlobalInt(\"MARKETPLACE_BLOCK_SALES\") || in_array($_SESSION[\'user\'][\'id_user\'], array_map(\'trim\', explode(\',\', getDolGlobalString(\"MARKETPLACE_ADMIN_USER_IDS\"))))): ?>\n    							<div id=\"HOOK_PAYMENT\">\n    							    <?php $current_lang = $_SESSION[\'lang\'][\'code\']; ?>\n    							    <?php \n        							    require_once DOL_DOCUMENT_ROOT.\'/core/lib/payments.lib.php\';\n        							    $urlforframe = getOnlinePaymentUrl(0, \'order\', $commande->ref, 0, \'\', $website->virtualhost);\n    							    ?>\n        				            <iframe frameborder=\"0\" style=\"overflow:hidden;height:100%;width:100%\" height=\"100%\" width=\"100%\" src=\"<?php print $urlforframe ?>&ws=<?php print $website->ref; ?>&lang=<?php print $current_lang; ?>&paymentmethod=stripe\"></iframe>\n    							</div>\n    							\n    							<br>\n    							\n    							<a href=\"/\" class=\"button-exclusive btn btn-default\" title=\"<?php print $weblangs->trans(\"continueShopping\"); ?>\">\n									<i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"continueShopping\"); ?>\n								</a>\n    						<?php else: ?>\n    						    <div class=\"block-sells-notification\">\n                                    <?php print $weblangs->trans(\"marketplacePurchasesDisabled\"); ?>\n                                </div>\n    						<?php endif ?>\n    						\n						<?php endif ?>\n					</div>\n				</div>\n			</div>\n		</div>\n	</div>\n	<!-- .columns-container -->\n	<div class=\"footer-container\">\n		<?php includeContainer(\'footer\'); ?>\n	</div>\n</div>\n\n',1,'2024-03-29 15:29:50',NULL,'2025-01-19 17:40:09',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(191,38,'paymentok','','paymentok','','','<?php // BEGIN PHP\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n$fulltag = GETPOST(\'fulltag\', \'alpha\');\n$param_order_id = preg_match(\'/ORD=([^\\.]+)/\', $fulltag, $reg_order) ? $reg_order[1] : 0;\n$param_customer_id = preg_match(\'/CUS=([^\\.]+)/\', $fulltag, $reg_customer) ? $reg_customer[1] : 0;\n\ndol_syslog(\"The page paymentok.php is called with tag=\".$tag.\" fulltag=\".$fulltag);\n\n// If not login redirect to login\nif (empty($_SESSION[\'user\'][\'id_user\'])) {\n    redirectToContainer(\'login-register\');\n}\n\n// Check if all necessary parameters are passed.\nif (empty($fulltag) || empty($param_order_id) || empty($param_customer_id)) {\n	print \'An error has occurred. Bad value for some parameters.\';\n	exit;\n}\n\n// Check if the customer_id passed via GET is the same as the one stored in the session.\n$user_id = $_SESSION[\'user\'][\'id_user\'];\n$customer = new SocieteAccount($db);\n$result = $customer->fetch($user_id);\n$customer_id = $customer->fk_soc;\nif ($customer_id != $param_customer_id) {\n	print \'An error has occurred. Id of login account in session is not of the same thirdparty than the thirdparty ID received in parameter CUS.\';\n	exit;\n}\n\n// Check if there is a paid order for this customer with the sent information.\n$sql_find_order = \"SELECT c.rowid, c.ref, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n$sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n$sql_find_order .= \"WHERE c.fk_soc = \" . $customer_id . \" and c.rowid = \" . $param_order_id . \" and c.fk_statut= 1 and c.facture = 1 and c.module_source = \'marketplace\' \";\n$sql_find_order .= \"limit 1\";\n$find_order = $db->query($sql_find_order);\n$obj_order = $db->fetch_object($find_order);\n\nif (empty($obj_order)) {\n    print \'An error has occurred. Order with ID received \'.$param_order_id.\' and thirdparty found from session \'.$customer_id.\' was not found in database.\';\n    print $sql_find_order;\n	exit;\n} else {\n    $order_ref = $obj_order->ref;\n    $order_id = $obj_order->rowid;\n    if(isset($_SESSION[\'products\'])){\n        unset($_SESSION[\'products\']);\n    }\n}\n// END PHP \n?>\n<div id=\"page\">\n	<div class=\"header-container\">\n		<?php \n		    includeContainer(\'header\');\n		    $__PAGE__TITLE__ = $weblangs->trans(\"paymentOkPageTitle\");\n		?>\n		<?php\n            marketplaceNotifySellersBuyerByEmail($order_id);\n		?>\n	</div>\n	<div class=\"columns-container\">\n		<div id=\"columns\" class=\"container\">\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> Payment Success \n			</div>\n			<!--  Breadcrumb  -->\n			<div id=\"slider_row\" class=\"row\">\n				<div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n			</div>\n			<div class=\"row\">\n				<!-- include lefet sidebar container -->\n				<?php includeContainer(\'sidebar\'); ?>\n				<div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n					<div class=\"clearfix payment_accepted\">\n					    <h1><?php print $weblangs->trans(\"paymentAccepted\"); ?></h1>\n                        <p><?php print $weblangs->trans(\"paymentSuccessProcessed\"); ?></p>\n                        <p><?php print $weblangs->trans(\"youWillBeRedirectedToOrderPage\"); ?></p>\n                        <div class=\"countdown-container\">\n                            <div id=\"countdown\">5</div>\n                        </div>\n					</div>\n				</div>\n			</div>\n		</div>\n	</div>\n	<!-- .columns-container -->\n	<div class=\"footer-container\">\n		<?php includeContainer(\'footer\'); ?>\n	</div>\n</div>\n\n<?php\nif (!defined(\'USEDOLIBARRSERVER\') && $website->virtualhost) {\n	$url_order_details = $website->virtualhost . \'/order-details.php?ref=\'.urlencode($order_ref);\n} else {\n	$url_order_details = DOL_URL_ROOT.\'/public/website/index.php?website=\'.urlencode($website->ref).\'&pageref=order-details&ref=\'.urlencode($order_ref);\n}\n?>\n\n<script>\n$(document).ready(function() {\n  var urlOrderDetails = \"<?php echo $url_order_details; ?>\";\n  var count = 5;\n\n  var countdownInterval = setInterval(function() {\n    count--;\n    $(\"#countdown\").text(count);\n    \n    if (count <= 0) {\n      clearInterval(countdownInterval);\n      window.location.href = urlOrderDetails;\n    }\n  }, 1000);\n});\n</script>\n\n',1,'2024-04-22 12:33:58',NULL,'2025-01-23 18:58:23',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(192,38,'product','','product','product','','<?php // BEGIN PHP\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n\n// END PHP ?> \n<html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"bodywebsite\" class=\"bodywebsite bodywebpage-\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->\n            <?php includeContainer(\'sidebar\'); ?>\n            \n            <?php\n                $current_lang = $_SESSION[\'lang\'][\'code\'];\n                $product_id = GETPOST(\'id\', \'alpha\');\n                $product_extid = GETPOST(\'extid\', \'alpha\');\n                \n                $product = new Product($db);\n                if (!empty($product_id)) {\n                    $result = $product->fetch($product_id);\n                } else {\n                    $result = $product->fetch(\'\', \'\', $product_extid);\n                }\n                \n                if ($result <= 0 || $product->status != 1) {\n                    // No product to display\n                    print $weblangs->trans(\"noProductToDisplay\");\n                } else {\n                    \n                    $__PAGE__TITLE__ = $product->label;\n                    $__PAGE__KEYWORDS__ = $product->array_options[\'options_marketplace_module_keywords\'];\n                    $__PAGE__DESC__ = $product->description;\n\n                    // check discount and calculate discounted price\n        		    $discount = marketplace_check_discount($product->id);\n        		    $discounted_price = marketplace_calculate_discounted_price($product->price_ttc, $discount);\n            ?>\n                <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n\n				\n              <div itemscope itemtype=\"http://schema.org/Product\">\n                <div class=\"primary_block row\">\n                  <div class=\"container hideonsmartphone\">\n                    <div class=\"top-hr\"></div>\n                  </div>\n                  <!-- left infos-->\n                  <div class=\"pb-left-column col-xs-12 col-sm-4 col-md-5\">\n                    <!-- product img-->\n                    <div id=\"image-block\" class=\"clearfix\">\n                    \n            		    <?php\n            		    $date_creation = $product->date_creation;\n            		    if ($date_creation >= strtotime(\'-\'.getDolGlobalString(\'MARKETPLACE_DELAY_FOR_NEW\', 30).\' days\')) { ?>\n            		    <!-- for ban New -->\n            		    <a class=\"new-box\" href=\"/\">\n    								<span class=\"new-label\"><?php print $langs->trans(\"New\"); ?></span>\n    					</a>\n            		    <?php } ?>\n\n                      <span id=\"view_full_size\">\n                        <img id=\"bigpic\" itemprop=\"image\" src=\"<?php print(getImagePublicURLOfObject($product,1)); ?>\" title=\"<?php print $product->label; ?>\" alt=\"<?php print $product->label; ?>\" width=\"458\" height=\"458\" />\n                        <a href=\"<?php print(getImagePublicURLOfObject($product,1)); ?>\" src=\"<?php print(getImagePublicURLOfObject($product,1)); ?>\" class=\"span_link no-print lightbox_trigger\" id=\"view_large_button\"><?php print $weblangs->trans(\"PhotoViewLarger\"); ?></a>\n                      </span>\n                    </div>\n                  </div>\n                  <!-- end pb-left-column -->\n                  <!-- end left infos-->\n                  <!-- center infos -->\n                  <div class=\"pb-center-column col-xs-12 col-sm-5 col-md-5 productlabel\">\n                    <h1 itemprop=\"name\"><?php print $product->label; ?></h1>\n                      <p id=\"product_reference\">\n                        <label><?php print $weblangs->trans(\"model\"); ?> </label>\n                        <span class=\"editable\"><?php print $product->ref; ?></span>\n                      </p>\n                    <?php if ($product->date_creation > strtotime(\'-\'.getDolGlobalString(\'MARKETPLACE_DELAY_FOR_NEW\', 30).\' days\')) { ?>\n                      <p id=\"product_condition\">\n                        <label><?php print $weblangs->trans(\"condition\"); ?> </label>\n                        <link itemprop=\"itemCondition\" href=\"https://schema.org/NewCondition\" />\n                        <span class=\"editable\"><?php print $weblangs->trans(\"New\"); ?></span>\n                      </p>\n                    <?php }?>\n                    <div id=\"short_description_block\">\n                      <div id=\"short_description_content\" class=\"rte align_justify\" itemprop=\"description\">\n                        <p>\n                        <?php \n                          if (isset($product->description)){\n                            print $product->description;\n                          }\n                        ?>\n                      </div>\n\n                      <!---->\n                    </div>\n                    <!-- end short_description_block -->\n\n                    <!-- Out of stock hook -->\n                    <div id=\"oosHook\" style=\"display: none;\"></div>\n                    <!-- usefull links-->\n                    <br>\n                    <ul id=\"usefull_link_block\" class=\"clearfix no-print\">\n                      <li class=\"print\">\n                        <a href=\"javascript:print();\"> <?php print $weblangs->trans(\"print\"); ?> </a>\n                      </li>\n                    </ul>\n                  </div>\n                  <!-- end center infos-->\n                  <!-- pb-right-column-->\n                  <div class=\"pb-right-column col-xs-12 col-sm-3 col-md-2\">\n                      \n                      \n                    <!-- add to cart form-->\n                    <?php if ($product->price_ttc > 0): ?>\n                        <form class=\"addtocart\" method=\"post\">\n                    <?php endif ?>\n                      <!-- hidden datas -->\n                      <p class=\"hidden\">\n                        <input type=\"hidden\" name=\"product_id\" value=\"<?php print $product->id; ?>\">\n                        <input type=\"hidden\" name=\"product_thumb\" value=\"<?php print getImagePublicURLOfObject($product,1); ?>\">\n                      </p>\n                      <div class=\"box-info-product\">\n                        <div class=\"content_prices clearfix\">\n                          <!-- prices -->\n                          <div class=\"price\">\n                            <p class=\"our_price_display\" itemprop=\"offers\" itemscope itemtype=\"http://schema.org/Offer\">\n                              <link itemprop=\"availability\" href=\"https://schema.org/InStock\" />\n                                <?php if ($product->price_ttc > 0): ?>\n                                    <?php if ($discounted_price != $product->price_ttc): ?>\n                                    	<span class=\"price product-price original-price-product-view\"> <?php print price($product->price_ttc); ?> € </span>\n                                    	<span class=\"price product-price\" id=\"our_price_display\"><?php print price($discounted_price); ?> €</span>\n                                    <?php else: ?>\n                					    <span id=\"our_price_display\"><?php print price($product->price_ttc); ?> €</span>\n                					<?php endif ?>\n                				<?php else: ?>\n                    			    <span class=\"our_price_display\"> FREE </span>\n                    			<?php endif ?>\n					\n                              \n                              <!-- tax incl. -->\n                              <meta itemprop=\"price\" content=\"<?php print price($product->price_ttc); ?>\" />\n                              <meta itemprop=\"priceCurrency\" content=\"EUR\" />\n                            </p>\n                            <p id=\"reduction_percent\" style=\"display:none;\">\n                              <span id=\"reduction_percent_display\"></span>\n                            </p>\n                            <p id=\"reduction_amount\" style=\"display:none\">\n                              <span id=\"reduction_amount_display\"></span>\n                            </p>\n                            <p id=\"old_price\" class=\"hidden\">\n                              <span id=\"old_price_display\"></span>\n                              <!-- tax incl. -->\n                            </p>\n                          </div>\n                          <!-- end prices -->\n                          <div class=\"clear\"></div>\n                        </div>\n                        <!-- end content_prices -->\n                        <?php if ($product->price_ttc > 0): ?>\n                            <div class=\"product_attributes clearfix\">\n                              <!-- quantity wanted -->\n                              <p id=\"quantity_wanted_p\">\n                                <label><?php print $weblangs->trans(\"Quantity\"); ?></label>\n                                <input type=\"text\" name=\"product_quantity\" id=\"quantity_wanted\" class=\"text\" value=\"1\" />\n                                <a href=\"#\" data-field-qty=\"product_quantity\" class=\"btn btn-default button-minus product_quantity_down\">\n                                  <span>\n                                    <i class=\"icon-minus\"></i>\n                                  </span>\n                                </a>\n                                <a href=\"#\" data-field-qty=\"product_quantity\" class=\"btn btn-default button-plus product_quantity_up\">\n                                  <span>\n                                    <i class=\"icon-plus\"></i>\n                                  </span>\n                                </a>\n                                <span class=\"clearfix\"></span>\n                              </p>\n                            </div>\n                        <?php endif ?>\n                        <!-- end product_attributes -->\n                        <div class=\"box-cart-bottom\">\n                          <div>\n\n                            <?php if ($product->price_ttc > 0): ?>\n                                <p id=\"add_to_cart\" class=\"buttons_bottom_block no-print\">\n                                  <button class=\"btn btn-default btn-lg btn-add-to-cart-product\">\n                                    <i class=\"icon-cart-plus\"></i> <p><?php print $weblangs->trans(\"addToCart\"); ?></p>\n                                  </button>\n                                </p>\n                			<?php else: ?>\n                			    <?php \n    						        // Get attached file\n									$files = getPublicFilesOfObject($product);\n									$url_attached_file = \'\';\n									foreach ($files as $file) {\n                                        if ($file[\'position\'] == 100) {\n                                            $url_attached_file = $file[\'url\'];\n                                        }\n                                    }\n								?>\n								<?php if (!empty($url_attached_file)) : ?>\n                    			    <a href=\"_service_download.php?t=free&p=<?php print $product->id; ?>\" target=\"new\">\n                    			         <p id=\"add_to_cart\" class=\"buttons_bottom_block no-print\">\n                                            <button class=\"btn btn-default btn-lg btn-add-to-cart-product\">\n                                                <i class=\"icon-cloud-download\"></i> <p><?php print $weblangs->trans(\"download\"); ?></p>\n                                            </button>\n                                        </p>\n                                    </a>\n                                <?php else : ?>\n                                    <!-- Disabled button with message -->\n                                    <p id=\"add_to_cart\" class=\"buttons_bottom_block no-print\">\n                                        <button class=\"btn btn-default btn-lg btn-add-to-cart-product\" disabled style=\"opacity: 0.5;\" title=\"<?php print $weblangs->trans(\"NoAttachedFileFound\"); ?>\">\n                                            <i class=\"icon-cloud-download\"></i>\n                                            <p><?php print $weblangs->trans(\"download\"); ?></p>\n                                        </button>\n                                        <p style=\"\n                                            color: #721c24;\n                                            font-size: 11.5px;\n                                            max-width: 90%;\n                                            margin: 0px auto;\n                                        \">\n                                            <?php print $weblangs->trans(\"NoAttachedFileFound\"); ?>\n                                        </p>\n                                    </p>\n                                <?php endif; ?>\n                			<?php endif ?>\n                          </div>\n                        </div>\n                        <!-- end box-cart-bottom -->\n                      </div>\n                      <!-- end box-info-product -->\n                    </form>\n                  </div>\n                  <!-- end pb-right-column-->\n                  \n                  <!-- thumbnails -->\n                  <div id=\"views_block\" class=\"clearfix \">\n                      <?php if (getNbOfImagePublicURLOfObject($product) > 4): ?>\n                        <span class=\"view_scroll_spacer\">\n                        	<a id=\"view_scroll_left\" class=\"\" title=\"<?php print $weblangs->trans(\"otherViews\"); ?>\" href=\"javascript:{}\"> Previous </a>\n                        </span>\n                      <?php endif ?>\n                    <div id=\"thumbs_list\">\n                      <ul id=\"thumbs_list_frame\">\n                        <?php for ($i=1; $i <= getNbOfImagePublicURLOfObject($product) ; $i++): ?>\n                          <li id=\"thumbnail_<?php print $i; ?>\">\n                            <a href=\"<?php print getImagePublicURLOfObject($product,$i); ?>\" src=\"<?php print getImagePublicURLOfObject($product,$i); ?>\" class=\"lightbox_trigger\" title=\"<?php print $product->label; ?>\">\n                              <img class=\"img-responsive\" id=\"thumb_9597\" src=\"<?php print getImagePublicURLOfObject($product,$i); ?>\" alt=\"<?php print $product->label; ?>\" title=\"<?php print $product->label; ?>\" height=\"80\" width=\"80\" itemprop=\"image\" />\n                            </a>\n                          </li>\n                        <?php endfor ?>\n                      </ul>\n                    </div>\n                    <!-- end thumbs_list -->\n                    <?php if (getNbOfImagePublicURLOfObject($product) > 4): ?>\n                        <a id=\"view_scroll_right\" title=\"<?php print $weblangs->trans(\"otherViews\"); ?>\" href=\"javascript:{}\"> Next </a>\n                    <?php endif ?>\n                  </div>\n                  <!-- end thumbnails -->\n                </div>\n                <!-- end primary_block -->\n                <!-- More info -->\n                <section class=\"page-product-box\">\n                  <div>\n                  <table class=\"info-table-box\">\n                    <tbody>\n                        <tr>\n                            <td>\n                                <ul class=\"info-list-box\">\n                                    <?php\n                                    include_once DOL_DOCUMENT_ROOT.\'/fourn/class/fournisseur.product.class.php\';\n                                    $tmpproductfourn = new ProductFournisseur($db);\n                                    $tmpproductfourn->find_min_price_product_fournisseur($product->id);\n                                    $supplier = new Societe($db);\n                                    $supplier->fetch($tmpproductfourn->fourn_id);\n                                    ?>\n                                    <li><b><?php print $weblangs->trans(\"Author\"); ?></b> <span class=\"infos-module\"><?php print $supplier->name; ?></span> </li>\n                                  <?php if (isset($product->array_options[\'options_marketplace_module_version\'])): ?>\n                                    <li><b><?php print $weblangs->trans(\"moduleVersion\"); ?></b> <span class=\"infos-module\"><?php print $product->array_options[\'options_marketplace_module_version\']; ?></span> </li>\n                                  <?php endif ?>\n                                  <?php if (isset($product->array_options[\'options_marketplace_min_version\']) && $product->array_options[\'options_marketplace_max_version\']): ?>\n                                    <li><b><?php print $weblangs->trans(\"compatibility\"); ?></b> Dolibarr <span class=\"infos-module\"><?php print $product->array_options[\'options_marketplace_min_version\']; ?> - <?php print $product->array_options[\'options_marketplace_max_version\']; ?></span> </li>\n                                  <?php endif ?>\n                                  <?php if (isset($product->date_creation)): ?>\n                                    <li><b><?php print $weblangs->trans(\"releaseDate\"); ?></b> <span class=\"infos-module\"><?php print dol_print_date($product->date_creation, \'day\'); ?></span> </li>\n                                  <?php endif ?>\n                                </ul>\n                            </td>\n                            <td>\n                                <ul class=\"info-list-box\">\n                                  <?php if (isset($product->date_modification)): ?>\n                                    <li><b><?php print $weblangs->trans(\"lastUpdate\"); ?></b> <span class=\"infos-module\"><?php print dol_print_date($product->date_modification, \'dayhour\'); ?></span> </li>\n                                  <?php endif ?>\n                                  <?php if (isset($product->array_options[\'options_marketplace_contact_support\'])): ?>\n                                    <li><b><?php print $weblangs->trans(\"contactSupport\"); ?></b> <span class=\"infos-module\"><?php print $product->array_options[\'options_marketplace_contact_support\']; ?></span> </li>\n                                  <?php endif ?>\n                                </ul>\n                            </td>\n                        </tr>\n                    </tbody>\n                  </table>\n                  </div>\n                  <h3 class=\"page-product-heading\"><?php print $weblangs->trans(\"moreInfo\"); ?></h3>\n                  <!-- full description -->\n                  <div class=\"rte\">\n                    <?php\n                        if (isset($product->multilangs[$current_lang][\"other\"])){\n                            print $product->multilangs[$current_lang][\"other\"];\n                        }\n                    ?>\n                  </div>\n                  <br>\n                  <br>\n                  <!--<ul id=\"usefull_link_block\" class=\"clearfix no-print\">\n                    <br>\n                    <b>This module has not been sold enough or has been on sale for a too short to have statistics</b>\n                    <li id=\"left_share_fb\">\n                      <a href=\"#\" class=\"_blank\">Share on Facebook!</a>\n                    </li>\n                  </ul>-->\n                </section>\n                <!--end  More info -->\n                <!--HOOK_PRODUCT_TAB -->\n                <section class=\"page-product-box\"></section>\n                <!--end HOOK_PRODUCT_TAB -->\n                <!-- description & features -->\n              </div>\n              <!-- itemscope product wrapper -->\n              </div>\n            </div>\n            <?php } ?>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n    \n    <!-- Disabled, file does not exists\n    <script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n    -->\n    \n  </body>\n</html>',1,'2024-02-02 16:48:47',NULL,'2025-01-23 23:49:25',NULL,NULL,'page','',NULL,'','<script type=\"text/javascript\">\n$(document).ready(function() {\n    let scrollContainer = document.querySelector(\"#thumbs_list_frame\");\n    let backBtn = document.getElementById(\"view_scroll_left\");\n    let nextBtn = document.getElementById(\"view_scroll_right\");\n    \n    nextBtn.addEventListener(\"click\", (evt) => {\n    	scrollContainer.style.scrollBehavior = \"smooth\";\n    	scrollContainer.scrollLeft += 300;\n    });\n    \n    backBtn.addEventListener(\"click\", (evt) => {\n    	scrollContainer.style.scrollBehavior = \"smooth\";\n    	scrollContainer.scrollLeft -= 300;\n    });\n});\n</script>',NULL,'','',0,NULL,NULL),
(193,38,'product-statistics','','product statistics','','','<?php // BEGIN PHP\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT . \'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT . \'/core/lib/categories.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n$product_id = GETPOST(\'id\');\n$current_lang = $_SESSION[\'lang\'][\'code\'];\n$weblangs->load(\"companies\");\n\n\n// If not login redirect to login.\nif(empty($_SESSION[\'user\'][\'id_user\'])){\n    redirectToContainer(\'login-register\');\n}\n\n\n// Get Account ID.\n$user_id = $_SESSION[\'user\'][\'id_user\'];\n$customer_account = new SocieteAccount($db);\n$result = $customer_account->fetch($user_id);\n$customer_id = $customer_account->fk_soc;\n\n// Get customer ID.\n$customer = new Societe($db);\n$result = $customer->fetch($customer_id);\n\n// Check if this product is owned by this customer\n$product = new Product($db);\n$result = $product->fetch($product_id);\n$sql = \'SELECT count(rowid) as prices FROM \'.MAIN_DB_PREFIX.\'product_fournisseur_price WHERE fk_product = \'.((int) $product_id).\' and fk_soc = \'.((int) $customer_id);\n$resql = $db->query($sql);\n$is_owner = $db->fetch_object($resql);\nif ($is_owner->prices == 0) {\n    // To render view of another user\n    if (!empty(GETPOST(\'id_customer\'))) {\n        // Only for members with a specific role\n        require_once DOL_DOCUMENT_ROOT.\"/adherents/class/adherent.class.php\";\n        $membre = new Adherent($db);\n        $result = $membre->fetch(\'\', 0, $customer_id);\n        \n        $adminsCat = new Categorie($db);\n    	$adminsCat->fetch(1);\n    	\n    	$result = $adminsCat->containsObject(\'member\', $membre->id);\n    	if ($result <= 0) {\n            redirectToContainer(\'manage-products\');\n    	}\n    } else {\n        redirectToContainer(\'manage-products\');\n    }\n}\n// END PHP \n?>\n<div id=\"page\">\n  <div class=\"header-container\">\n    <?php \n        includeContainer(\'header\');\n        $__PAGE__TITLE__ = $weblangs->trans(\"productStatisticsPageTitle\");\n    ?>\n  </div>\n\n  <div class=\"columns-container\">\n    <div id=\"columns\" class=\"container\">\n        <!--  Breadcrumb  -->\n        <div class=\"breadcrumb clearfix\">\n        	<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <a href=\"myaccount.php\" title=\"<?php print $weblangs->trans(\"myAccount\"); ?>\" data-gg=\"\"><?php print $weblangs->trans(\"manageProducts\"); ?></a>\n        	<span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"orderHistory\"); ?>\n        </div>\n        <!--  Breadcrumb  -->\n      <div id=\"slider_row\" class=\"row\">\n        <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n      </div>\n      <div class=\"row\">\n        <!-- include lefet sidebar container -->\n        <?php includeContainer(\'sidebar\'); ?>\n        <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n          <div class=\"clearfix\">\n                <?php\n                    // Get product object\n                    $product = new Product($db);\n                    $result = $product->fetch($product_id);\n                ?>\n                <h1 class=\"page-heading\"><?php print $weblangs->trans(\"product\"); ?> : <?php print $product->label; ?></h1>\n                <div id=\"block-history\" class=\"block-center\">\n                    <div id=\"block-order-detail\" class=\"unvisible\" style=\"display: block;\">\n                		<div id=\"order-detail-content\" class=\"table_block table-responsive\">\n                			<table class=\"table table-bordered table-bordered-block-order-detail order-history\">\n                				<thead>\n                					<tr>\n                						<th class=\"item\" width=\"50\">#</th>\n                						<th class=\"item\" width=\"150\"><?php print $weblangs->trans(\"orderRef\"); ?></th>\n                						<th class=\"item\"><?php print $weblangs->trans(\"ThirdPartyName\"); ?></th>\n                						<th class=\"item\" width=\"120\"><?php print $weblangs->trans(\"date\"); ?></th>\n                						<th class=\"last_item\"><?php print $weblangs->trans(\"amountEarned\"); ?></th>\n                					</tr>\n                				</thead>\n                				<tbody>\n                				    <?php\n                				    // Get list of orders for this product After 01/01/2025 (from invoices)\n                					$orders_for_product = \"SELECT f.rowid, f.type, f.ref, f.fk_statut, f.fk_soc, f.datec as date_commande, f.module_source , fd.total_ht, fk_facture_source \";\n                                    $orders_for_product .= \"FROM \".MAIN_DB_PREFIX.\"facture as f, \".MAIN_DB_PREFIX.\"facturedet as fd \";\n                                    $orders_for_product .= \"WHERE f.rowid = fd.fk_facture and fd.fk_product = \" . ((int) $product->id) . \" and f.paye = 1 and f.datef > \'2025-01-01\' \";\n                                    $orders_for_product .= $db->order(\"datef\", \"DESC\");\n                                    \n                                    if ($result_orders = $db->query($orders_for_product)) {\n                                        $i = 1;\n                                    	while ($order_details = $result_orders->fetch_object()) {\n                                    	    if (!empty($conf->cache[\'thirdparty\'][$order_details->fk_soc])) {\n                                    	        $customer = $conf->cache[\'thirdparty\'][$order_details->fk_soc];\n                                    	    } else {\n                                    	        $customer = new Societe($db);\n                                    	        $customer->fetch($order_details->fk_soc);\n                                    	    \n                                    	        $conf->cache[\'thirdparty\'][$order_details->fk_soc] = $customer;\n                                    	    }\n                                    	    \n                                    	    // Calculate discount for this order line\n                                            // TODO\n                                    ?>\n                    					<tr class=\"item <?php if ($order_details->type == 2) { print \"refundLine\"; } ?>\">\n                    					    <td>\n                    					        <p><?php print $i; ?></p>\n                    					    </td>\n                    					    <td>\n                    					        <p><?php print $order_details->ref; ?></p>\n                    					        <?php if (!empty($order_details->fk_facture_source)): ?>\n                    					            <?php\n                    					                $refund_source = \"SELECT f.ref \";\n                                                        $refund_source .= \"FROM \".MAIN_DB_PREFIX.\"facture as f \";\n                                                        $refund_source .= \"WHERE f.rowid = \" . $order_details->fk_facture_source;\n                                                        $resql_refund_source = $db->query($refund_source);\n                                                        $sourceOfRefund = $db->fetch_object($resql_refund_source);\n                    					            ?>\n                    					            <p><s><?php print $sourceOfRefund->ref; ?></s></p>\n                    					        <?php endif ?>\n                    					    </td>\n                    					    <td>\n                    						        <b><?php print $customer->name; ?></b><br>\n\n                    						        <small class=\"cart_ref\">\n                                                        <?php print $weblangs->trans(\"Email\"); ?>: <?php print $customer->email; ?><br>\n                                                        <?php print $weblangs->trans(\"registredOn\"); ?>: <?php print dol_print_date($customer->date_creation, \'day\'); ?>\n                    						        </small>\n\n                    						</td>\n                    						<td>\n                    						    <p><?php print dol_print_date($order_details->date_commande, \'day\'); ?></p>\n											</td>\n                    						<td width=\"160\">\n                    							<p><span class=\"price\"><?php print price($order_details->total_ht); ?> €</span> </p>\n                    						</td>\n                    					</tr>\n                					    <?php\n                					    $i++;\n                                    	}\n                                    }\n                                    ?>\n                                    \n                                    \n                                    \n                				    \n                				    \n                				    \n                				    \n                				    \n                				    \n                				    <?php\n                				    // Get list of orders for this product before 01/01/2025\n                					$orders_for_product = \"SELECT c.rowid, c.ref, c.fk_statut, c.fk_soc, c.date_commande, c.module_source , d.total_ht \";\n                                    $orders_for_product .= \"FROM \".MAIN_DB_PREFIX.\"commande as c, \".MAIN_DB_PREFIX.\"commandedet as d \";\n                                    $orders_for_product .= \"WHERE c.rowid = d.fk_commande and d.fk_product = \" . ((int) $product->id) . \" and c.fk_statut IN (1,3) and (c.facture = 1 || c.ref_ext IS NOT NULL) and c.module_source = \'Marketplace\' and c.date_commande < \'2025-01-01\'\";\n                                    $orders_for_product .= $db->order(\"date_commande\", \"DESC\");\n                                    \n                                    if ($result_orders = $db->query($orders_for_product)) {\n                                        $i = 1;\n                                    	while ($order_details = $result_orders->fetch_object()) {\n                                    	    if (!empty($conf->cache[\'thirdparty\'][$order_details->fk_soc])) {\n                                    	        $customer = $conf->cache[\'thirdparty\'][$order_details->fk_soc];\n                                    	    } else {\n                                    	        $customer = new Societe($db);\n                                    	        $customer->fetch($order_details->fk_soc);\n                                    	    \n                                    	        $conf->cache[\'thirdparty\'][$order_details->fk_soc] = $customer;\n                                    	    }\n                                    	    \n                                    	    // Calculate discount for this order line\n                                            $TOTAL_DISCOUNTS = 0;\n                                            $sum_all_discounts = \"SELECT SUM(d.total_ht) as total \";\n                                            $sum_all_discounts .= \"FROM \".MAIN_DB_PREFIX.\"commande as c, \".MAIN_DB_PREFIX.\"commandedet as d \";\n                                            $sum_all_discounts .= \"WHERE c.rowid = d.fk_commande \";\n                                            $sum_all_discounts .= \"AND c.rowid = \".$order_details->rowid.\" \";\n                                            $sum_all_discounts .= \"AND d.description LIKE \'\" . ((int) $product->id) . \"# %\' \";\n                                            $sum_all_discounts .= \"AND (c.facture = 1 OR c.note_private LIKE \'%Order imported%\' OR c.ref_ext IS NOT NULL) \";\n                                            $sum_all_discounts .= \"AND c.module_source = \'Marketplace\' \";\n                                            $resql = $db->query($sum_all_discounts);\n                                            $sells_discounts = $db->fetch_object($resql);\n                                            $TOTAL_DISCOUNTS = $sells_discounts->total;\n                                    ?>\n                    					<tr class=\"item\">\n                    					    <td>\n                    					        <p><?php print $i; ?></p>\n                    					    </td>\n                    					    <td>\n                    					        <p><?php print $order_details->ref; ?></p>\n                    					    </td>\n                    					    <td>\n                    						        <b><?php print $customer->name; ?></b><br>\n\n                    						        <small class=\"cart_ref\">\n                                                        <?php print $weblangs->trans(\"Email\"); ?>: <?php print $customer->email; ?><br>\n                                                        <?php print $weblangs->trans(\"registredOn\"); ?>: <?php print dol_print_date($customer->date_creation, \'day\'); ?>\n                    						        </small>\n\n                    						</td>\n                    						<td>\n                    						    <p><?php print dol_print_date($order_details->date_commande, \'day\'); ?></p>\n											</td>\n                    						<td width=\"160\">\n                    							<p><span class=\"price\"><?php print price($order_details->total_ht); ?> €</span> <?php if ($TOTAL_DISCOUNTS) { print \"(\" . price($TOTAL_DISCOUNTS) . \")\"; } ?> </p>\n                    						</td>\n                    					</tr>\n                					    <?php\n                					    $i++;\n                                    	}\n                                    }\n                                    ?>\n                				</tbody>\n                			</table>\n                		</div>\n                    </div>\n                </div>\n                <ul class=\"footer_links clearfix\">\n                	<li>\n                		<a class=\"btn btn-default button button-small\" href=\"myaccount.php\">\n                			<span>\n                				<i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"backToYourAccount\"); ?>\n                			</span>\n                		</a>\n                	</li>\n                	<li>\n                		<a class=\"btn btn-default button button-small\" href=\"index.php\">\n                			<span><i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"Home\"); ?></span>\n                		</a>\n                	</li>\n                </ul>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div>\n  <!-- .columns-container -->\n  <div class=\"footer-container\">\n    <?php includeContainer(\'footer\'); ?>\n  </div>\n</div>',1,'2024-07-10 09:54:18',NULL,'2025-01-24 11:38:23',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(194,38,'products-list-grid','','product list grid','product list grid','','<script type=\"text/javascript\">\n  var displayList = false;\n  var page_name = \'tt\';\n  var quickView = false;\n  var request = window.location.href;\n  var display = \"grid\";\n</script>\n\n<?php // BEGIN PHP\nincludeContainer(\'_library_page_lib.php\', 1);\n$current_lang = $_SESSION[\'lang\'][\'code\'];\n$current_lang_short_code = $_SESSION[\'lang\'][\'shortcode\'];\n\n\n$root_cat_object = new Categorie($db);\n\nif (GETPOST(\'cat\', \'alpha\')) {\n	$root_category_id = GETPOST(\'cat\', \'alpha\');\n}\nif (GETPOST(\'extcat\', \'alpha\')) {\n	$root_category_extid = GETPOST(\'extcat\', \'alpha\');\n}\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$list = GETPOST(\'list\', \'alpha\');\n$search_words = GETPOST(\'search_query\', \'alpha\');\n$cat = GETPOST(\'cat\', \'alpha\');\n$extcat = GETPOST(\'extcat\', \'alpha\');\n\n$isHomePage = !GETPOST(\'tag\', \'alpha\') && !GETPOST(\'cat\', \'alpha\') && !GETPOST(\'list\', \'alpha\') && !GETPOST(\'search_query\', \'alpha\') && !GETPOST(\'extcat\', \'alpha\');\n\nif (!empty($search_words)) {\n    $keywords = explode(\" \", $search_words);\n    $request = \'\';\n    $order = \'ORDER BY CASE \';\n\n    foreach ($keywords as $key => $value) {\n        if ($key != 0) {\n            $request .= \" AND \";\n        }\n        $value = $db->escape($db->escapeforlike($value));\n\n        // Build the search conditions for labels, notes, and vendor names\n        $request .= \"(ol.label LIKE \'%\" . $value . \"%\' OR \n                    ol.note LIKE \'\" . $value . \" %\'  OR \n                    ol.note LIKE \'% \" . $value . \" %\'  OR \n                    ol.note LIKE \'% \" . $value . \"\' OR\n                    ol.note LIKE \'%>\" . $value . \" %\' OR\n                    ol.note LIKE \'% \" . $value . \"<%\' OR\n                    s.nom LIKE \'%\" . $value . \"%\')\";\n\n        // Define the order of results based on matching criteria\n        // Level 1: Full match in the label\n        $order .= \"WHEN ol.label LIKE \'\" . $value . \" %\' THEN 1 \";\n        $order .= \"WHEN ol.label LIKE \'% \" . $value . \" %\' THEN 1 \";\n        $order .= \"WHEN ol.label LIKE \'% \" . $value . \"\' THEN 1 \";\n\n        // Level 2: Partial match in the label or vendor name\n        $order .= \"WHEN ol.label LIKE \'%\" . $value . \"%\' THEN 2 \";\n        $order .= \"WHEN s.nom LIKE \'%\" . $value . \"%\' THEN 2 \";\n\n        // Level 3: Full Match in the notes(Long description) field\n        $order .= \"WHEN ol.note LIKE \'\" . $value . \" %\' THEN 3 \";\n        $order .= \"WHEN ol.note LIKE \'% \" . $value . \" %\' THEN 3 \";\n        $order .= \"WHEN ol.note LIKE \'% \" . $value . \"\' THEN 3 \";\n        $order .= \"WHEN ol.note LIKE \'%>\" . $value . \" %\' THEN 3 \";\n        $order .= \"WHEN ol.note LIKE \'% \" . $value . \"<%\' THEN 3 \";\n\n        //$order .= \"WHEN ol.description LIKE \'%\" . $value . \"%\' THEN 4 \";\n    }\n    \n    // Finalize filter and order\n    $filter = \"($request) AND (o.tosell = 1) \";\n    $order .= \" END, o.datec DESC\";  // Complete the order clause\n} else {\n    $filter = \'o.tosell = 1\';\n}\n\n$page_no = GETPOST(\'p\', \'alpha\');\nif(empty($page_no)) {\n	$page_no = 1;\n}\n\n$limit = GETPOST(\'n\', \'alpha\');\nif(empty($limit)) {\n	$limit = 11;\n}else{\n	$limit = $limit -1;\n}\n\n$orderby = GETPOST(\'orderby\', \'alpha\');\nswitch ($orderby) {\n	case \'price\':\n		$sortfield = \'price_ttc\';\n		break;\n	case \'name\':\n		$sortfield = \'label\';\n		break;\n	case \'reference\':\n		$sortfield = \'ref\';\n		break;\n	default:\n		$sortfield = \'datec\';\n		break;\n}\n\n$orderway = GETPOST(\'orderway\', \'alpha\');\nswitch ($orderway) {\n	case \'asc\':\n		$sortorder = \"ASC\";\n		break;\n	case \'desc\':\n		$sortorder = \"DESC\";\n		break;\n	default:\n		$sortorder = \"DESC\";\n		break;\n}\n\nif ($page_no == 1) {\n	$offset = 0;\n}else{\n	$offset = ( $limit * ($page_no-1) )+($page_no - 1);\n}\n\n$id = null;\n$type  = Categorie::TYPE_PRODUCT;\n$is_for_sell = 1;\n\nif (empty($tag)) {\n	if (isset($root_category_id) || isset($root_category_extid)) {\n	    if (isset($root_category_id)) {\n	        $result = $root_cat_object->fetch($root_category_id,\"\");\n	    } else {\n	        $result = $root_cat_object->fetch(\'\', \'\', Categorie::TYPE_PRODUCT, $root_category_extid);\n	    }\n		\n		if ($result <= 0) {\n			redirectToContainer(\'404\');\n		}\n		$root_category_id = $root_cat_object->id;\n		$root_category_label = $root_cat_object->label;\n	} else {\n	    if ($isHomePage && getDolGlobalInt(\'MARKETPLACE_ROOT_CATEGORY_ID_BIS\')) {\n    	    // To force ID of category for v20 products only on Home page\n    		$result = $root_cat_object->fetch(getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID_BIS\"));\n	    } else {\n    		$result = $root_cat_object->fetch(getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\"));\n	    }\n		if ($result <= 0) {\n			redirectToContainer(\'404\');\n		}\n		$root_category_label = $root_cat_object->label;\n		$root_category_id = $root_cat_object->id;\n	}\n} else {\n    if ($tag == \"Specials\") {\n        $result = $root_cat_object->fetch(getDolGlobalInt(\"MARKETPLACE_SPECIAL_CATEGORY_ID\"));\n    } else {\n        $result = $root_cat_object->fetch(\"\", $tag);\n    }\n	\n	if ($result <= 0) {\n		dol_print_error($db, $root_cat_object->error); exit;\n	}\n	$root_category_label = $root_cat_object->label;\n	$root_category_id = $root_cat_object->id;\n}\n$root_category_type = $root_cat_object->type;\n\n// If Goodies category, redirect to specific page\nif ($root_category_label == \'Goodies\') {\n    redirectToContainer(\'goodies\');\n}\n\n\nif($root_category_id == getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\") && empty($tag) && empty($search_words) && $list == \"new\") {\n    $delay_for_new = (int) getDolGlobalInt(\'MARKETPLACE_DELAY_FOR_NEW\', 30);\n    $dateTime = new \\DateTime();\n    $interval = new \\DateInterval(\'P\'.$delay_for_new.\'D\');\n    $dateTime->sub($interval);\n    $request = \"o.datec > \'\" . $dateTime->format(\'Y-m-d H:i:s\') . \"\'\";\n    $filter = \"(\".$request . \") AND (o.tosell=1)\";\n}\n\n// END PHP ?>\n\n<?php\n// Count SQL\n/*$countSql = \"SELECT c.fk_product \";\n$countSql .= \"FROM llx_categorie_product as c, \";\n$countSql .= \"llx_product as o, \";\n$countSql .= \"llx_product_lang as ol \";\n$countSql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \".$root_category_id.\" AND c.fk_product = o.rowid AND ol.fk_product = o.rowid \";\n$countSql .= \"AND ol.lang = \'\".$db->escape($current_lang).\"\' AND \";\n$countSql .= $filter;\n\n$resql = $db->query($countSql);\n$count_prods = $resql->num_rows;\n\n// PRODUCT SQL\n$sql = \"SELECT c.fk_product as id, o.ref, o.ref_ext, ol.label, ol.description, o.datec, o.price_ttc \";\n$sql .= \"FROM llx_categorie_product as c, \";\n$sql .= \"llx_product as o, \";\n$sql .= \"llx_product_lang as ol \";\n$sql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \".$root_category_id.\" AND c.fk_product = o.rowid AND ol.fk_product = o.rowid \";\n$sql .= \"AND ol.lang = \'\".$db->escape($current_lang).\"\' AND \";\n$sql .= $filter;*/\n\n// Count SQL\n$countSql = \"SELECT c.fk_product \";\n$countSql .= \"FROM llx_categorie_product as c \";\n$countSql .= \"INNER JOIN llx_product as o ON c.fk_product = o.rowid \";\n$countSql .= \"INNER JOIN llx_product_lang as ol ON ol.fk_product = o.rowid \";\n$countSql .= \"LEFT JOIN llx_product_fournisseur_price as pfp ON pfp.fk_product = o.rowid \";\n$countSql .= \"LEFT JOIN llx_societe as s ON pfp.fk_soc = s.rowid \";\n$countSql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \" . ((int) $root_category_id) . \" AND \";\n$countSql .= \"ol.lang = \'\" . $db->escape($current_lang) . \"\' AND \";\n$countSql .= $filter;\n$sql .= \" GROUP BY c.fk_product \"; // Added GROUP BY clause to handle multiple supplier prices\n\n$resql = $db->query($countSql);\n$count_prods = $resql->num_rows;\n\n// PRODUCT SQL\n$sql = \"SELECT c.fk_product as id, o.ref, o.ref_ext, ol.label, ol.description, o.datec, o.price_ttc \";\n$sql .= \"FROM llx_categorie_product as c \";\n$sql .= \"INNER JOIN llx_product as o ON c.fk_product = o.rowid \";\n$sql .= \"INNER JOIN llx_product_lang as ol ON ol.fk_product = o.rowid \";\n$sql .= \"LEFT JOIN llx_product_fournisseur_price as pfp ON pfp.fk_product = o.rowid \";\n$sql .= \"LEFT JOIN llx_societe as s ON pfp.fk_soc = s.rowid \";\n$sql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \" . ((int) $root_category_id) . \" AND \";\n$sql .= \"ol.lang = \'\" . $db->escape($current_lang) . \"\' AND \";\n$sql .= $filter;\n$sql .= \" GROUP BY c.fk_product, o.ref, o.ref_ext, ol.label, ol.description, o.datec, o.price_ttc, s.nom\"; // Added GROUP BY clause to handle multiple supplier prices\n\nif ($sortfield == \'datec\' && $sortorder == \'DESC\' && !empty($search_words)) {\n    $sql .= \" \" . $order;\n} else {\n    // Home page: random order\n    if ($isHomePage) {\n        $sql .= \" ORDER BY RAND() \";\n    } else {\n        $sql .= $db->order($sortfield, $sortorder);\n    }\n}\n\nif ($limit > 0 || $offset > 0) {\n	$sql .= $db->plimit($limit + 1, $offset);\n}\n\n$total_no_of_pages = ceil($count_prods / ($limit + 1));\n$second_last = $total_no_of_pages - 1; // total pages minus 1\n$previous_page = $page_no - 1;\n$next_page = $page_no + 1;\n$test = \"\";\n?>\n<?php if ($count_prods > 0 && (strlen($search_words) == 0 || strlen($search_words) > 1)): ?>\n	<?php if (GETPOST(\'cat\', \'alpha\') != \'\' || GETPOST(\'extcat\', \'alpha\') != \'\'): ?>\n	    <section id=\"category_info_section\" contenteditable=\"true\">\n    		<div class=\"content_scene_cat\">\n    		    <?php\n        		    $__PAGE__TITLE__ = dol_string_nohtmltag($root_cat_object->label);\n                    $__PAGE__DESC__ = dol_string_nohtmltag($root_cat_object->description);\n    		    ?>\n    			<!-- Category image -->\n    			\n    			<div class=\"content_scene_cat_bg\">\n    				<div class=\"cat_desc\">\n    					<?php\n    					    if ($root_cat_object->id == getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\")) {\n                                print \'<span class=\"category-name\">\' . dol_string_nohtmltag($weblangs->trans(\"newProducts\")) . \'</span>\';\n                            } else {\n                                print \'<span class=\"category-name\">\' . dol_string_nohtmltag($root_cat_object->label) . \'</span>\';\n                            }\n                        ?>\n    					<div class=\"rte\">\n    						<p>\n    						<?php \n    						    if ($root_cat_object->id != getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\")) {\n    						        print dol_string_nohtmltag($root_cat_object->description);\n    						    }\n    						?>\n						    </p>\n    					</div>\n    				</div>\n    			</div>\n    			\n    		</div>\n		</section>\n	<?php endif ?>\n\n	<?php if (GETPOST(\'tag\', \'alpha\') != \"\" || GETPOST(\'cat\', \'alpha\') != \"\" || GETPOST(\'search_query\', \'alpha\') != \"\" || GETPOST(\'extcat\', \'alpha\') != \'\'): ?>\n	<section id=\"search_info_section\" contenteditable=\"true\">\n		<h1 class=\"page-heading product-listing\">\n			<?php if (GETPOST(\'cat\', \'alpha\') != \'\' || GETPOST(\'extcat\', \'alpha\') != \'\'): ?>\n				<span class=\"cat-name\"><?php if ($root_cat_object->id != getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\")) {print $root_cat_object->label;} ?></span>\n			<?php else: ?>\n				<span class=\"cat-name\"><?php print $weblangs->trans(\"Search\"); ?>\n				<?php if (!empty($tag)): ?>\n					\"<?php print $tag; ?>\"</span>\n				<?php endif ?>\n				<?php if (!empty($keywords)): ?>\n					<?php foreach ($keywords as $key => $value): ?>\n						\"<?php print $value; ?>\"</span>\n					<?php endforeach ?>\n				<?php endif ?>\n			<?php endif ?>\n			<span class=\"heading-counter\"><?php print $weblangs->trans(\"nbrOfProducts\", $count_prods); ?></span>\n			\n		</h1>\n	</section>\n	<?php endif ?>\n\n	<?php if (GETPOST(\'tag\', \'alpha\') != \"\" || GETPOST(\'cat\', \'alpha\') != \"\" || GETPOST(\'search_query\', \'alpha\') != \"\" || GETPOST(\'extcat\', \'alpha\') != \'\'): ?>\n		<div class=\"content_sortPagiBar clearfix\">\n		<div class=\"sortPagiBar clearfix\">\n		    \n			<ul class=\"display hidden-xs\">\n    			<li id=\"grid\" class=\"selected\">\n    				<a rel=\"nofollow\" href=\"#\" title=\"Grid\">\n    				<i class=\"icon-th-large\"></i><?php print $weblangs->trans(\"grid\"); ?> </a>\n    			</li>\n    			<li id=\"list\">\n    				<a rel=\"nofollow\" href=\"#\" title=\"List\">\n    				<i class=\"icon-th-list\"></i><?php print $weblangs->trans(\"list\"); ?> </a>\n    			</li>\n			</ul>\n			<form id=\"productsSortForm\" action=\"\" class=\"productsSortForm\">\n			<div class=\"select selector1\">\n				<div class=\"\" id=\"uniform-selectProductSort\">\n				<!--<span style=\"width: 180.4px; user-select: none;\">Price: Lowest first</span>-->\n				<select id=\"selectProductSort\" class=\"selectProductSort form-control\" style=\"width: 220px;\">\n					<!--<option value=\"\">--</option>-->\n					<option value=\"date:desc\" <?php (($orderway == \"desc\" && $orderby == \"date\") || empty($orderway)) ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"dateNewestFirst\"); ?></option>\n					<option value=\"price:asc\" <?php ($orderway == \"asc\" && $orderby == \"price\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"priceLowestFirst\"); ?></option>\n					<option value=\"price:desc\" <?php ($orderway == \"desc\" && $orderby == \"price\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"priceHighestFirst\"); ?></option>\n					<option value=\"name:asc\" <?php ($orderway == \"asc\" && $orderby == \"name\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"productNameAToZ\"); ?></option>\n					<option value=\"name:desc\" <?php ($orderway == \"desc\" && $orderby == \"name\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"productNameZToA\"); ?></option>\n					<option value=\"reference:asc\" <?php ($orderway == \"asc\" && $orderby == \"reference\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"referenceLowestFirst\"); ?></option>\n					<option value=\"reference:desc\" <?php ($orderway == \"desc\" && $orderby == \"reference\") ? print \'selected=\"selected\"\' : \'\' ; ?>><?php print $weblangs->trans(\"referenceHighestFirst\"); ?></option>\n				</select>\n				</div>\n			</div>\n			</form>\n			<!-- /Sort products -->\n			<!-- nbr product/page -->\n			<form action=\"\" method=\"get\" class=\"nbrItemPage\">\n			<div class=\"clearfix selector1\">\n				&nbsp; \n				<div class=\"\" id=\"uniform-nb_item\" style=\"width: 57.4px;\">\n				<!--<span style=\"width: 47.4px; user-select: none;\">12</span>-->\n				<select name=\"n\" id=\"nb_item\" class=\"form-control\">\n					<option value=\"12\" <?php (($limit + 1) == 12) ? print \'selected=\"selected\"\' : \'\' ; ?>>12</option>\n					<option value=\"24\" <?php (($limit + 1) == 24) ? print \'selected=\"selected\"\' : \'\' ; ?>>24</option>\n					<option value=\"60\" <?php (($limit + 1) == 60) ? print \'selected=\"selected\"\' : \'\' ; ?>>60</option>\n				</select>\n				</div>\n				<span class=\"opacitymedium\"><?php print $weblangs->trans(\"productPerPage\"); ?></span>\n			</div>\n			</form>\n			<!-- /nbr product/page -->\n		</div>\n		\n\n		<div class=\"top-pagination-content clearfix\">\n            <?php if ($total_no_of_pages > 1): ?>\n                <!-- show all -->\n                <div id=\"pagination\" class=\"pagination clearfix\">\n                    <form class=\"showall\" action=\"\" method=\"get\">\n                        <div>\n                            <button type=\"submit\" class=\"btn btn-default button exclusive-medium\">\n                                <span><?php print $weblangs->trans(\"showAll\"); ?></span>\n                            </button>\n                            <input name=\"n\" id=\"nb_item\" class=\"hidden\" value=\"<?php print $count_prods; ?>\">\n                        </div>\n                    </form>\n        \n                    <!-- show all -->\n                    <ul class=\"pagination\">\n                        <li id=\"pagination_previous\" class=\"pagination_previous\" <?php if($page_no <= 1){ echo \"disabled\"; } ?>>\n                            <a <?php if($page_no > 1){ echo \"href=\'?p=$previous_page\'\"; } ?>>\n                                <i class=\"icon-chevron-left\"></i>\n                                <b><?php print $weblangs->trans(\"previous\"); ?></b>\n                            </a>\n                        </li>\n        \n                        <?php\n                        $start_page = max(1, $page_no - 2);\n                        $end_page = min($total_no_of_pages, $page_no + 2);\n        \n                        if ($total_no_of_pages <= 10) {\n                            // Affiche toutes les pages si <= 10\n                            for ($counter = 1; $counter <= $total_no_of_pages; $counter++) {\n                                if ($counter == $page_no) {\n                                    echo \"<li class=\'active current\'><span><span>$counter</span></span></li>\";  \n                                } else {\n                                    echo \"<li><a href=\'?p=$counter\'><span>$counter</span></a></li>\";\n                                }\n                            }\n                        } else {\n                            if ($start_page > 1) {\n                                echo \"<li><a href=\'?p=1\'><span>1</span></a></li>\";\n                                if ($start_page > 2) {\n                                    echo \"<li><span><span><a>...</a></span></span></li>\";\n                                }\n                            }\n                            for ($counter = $start_page; $counter <= $end_page; $counter++) {\n                                if ($counter == $page_no) {\n                                    echo \"<li class=\'active\'><span><span>$counter</span></span></li>\";\n                                } else {\n                                    echo \"<li><a href=\'?p=$counter\'><span>$counter</span></a></li>\";\n                                }\n                            }\n                            if ($end_page < $total_no_of_pages) {\n                                if ($end_page < $total_no_of_pages - 1) {\n                                    echo \"<li><span><span><a>...</a></span></span></li>\";\n                                }\n                                echo \"<li><a href=\'?p=$total_no_of_pages\'><span>$total_no_of_pages</span></a></li>\";\n                            }\n                        }\n                        ?>\n        \n                        <li class=\"pagination_next <?php if($page_no >= $total_no_of_pages){ echo \'disabled\'; } ?>\">\n                            <a <?php if($page_no < $total_no_of_pages) { echo \"href=\'?p=$next_page\'\"; } ?>>\n                                <b><?php print $weblangs->trans(\"next\"); ?></b>\n                                <i class=\"icon-chevron-right\"></i>\n                            </a>\n                        </li>\n                    </ul>\n                </div>\n            <?php endif ?>\n        \n            <div class=\"product-count\">\n                <?php print $weblangs->trans(\"showing\"); ?> \n                <?php print $offset + 1; ?> - \n                <?php if(($offset + $limit +1) > $count_prods) { print $count_prods; } else { print $offset + $limit +1; } ?> \n                <?php print $weblangs->trans(\"of\"); ?> \n                <?php print $count_prods; ?> \n                <?php print $weblangs->trans(\"items\"); ?>\n            </div>\n        </div>\n\n		\n		</div>\n	<?php endif ?>\n\n	<ul id=\"homefeatured\" class=\"product_list grid row homefeatured tab-pane\">\n		<?php\n\n		//$prods = $root_cat_object->getObjectsInCateg(Categorie::TYPE_PRODUCT, 0,$limit, $offset,$sortfield,$sortorder,$filter,\'\',$current_lang);\n		//foreach ($prods as $key => $product){\n		\n		if ($resql = $db->query($sql)) {\n		    $key = 0;\n			while ($product = $resql->fetch_object()) {\n			    $product->element = \"product\";\n    		    // check discount and calculate discounted price\n    		    $discount = marketplace_check_discount($product->id);\n    		    $discounted_price = marketplace_calculate_discounted_price($product->price_ttc, $discount);\n    		    //$discount = function_exists(\'marketplace_check_discount\') ? marketplace_check_discount($product->id) : 0;\n    		    //$discounted_price = function_exists(\'marketplace_calculate_discounted_price\') ? marketplace_calculate_discounted_price($product->price_ttc, $discount) : $product->price_ttc;\n    \n    			$thumb = getImagePublicURLOfObject($product, 1, \'_small\');\n    			// Add some css class for each position\n    			switch ($key) {\n        			case \'0\':\n        				$position_class = \"first-in-line first-item-of-tablet-line first-item-of-mobile-line\";\n        				break;\n        			case \'1\':\n        				$position_class = \"last-item-of-mobile-line\";\n        				break;\n        			case \'2\':\n        				$position_class = \"last-item-of-tablet-line first-item-of-mobile-line\";\n        				break;\n        			case \'3\':\n        				$position_class = \"last-in-line first-item-of-tablet-line last-item-of-mobile-line\";\n        				break;\n        			case \'4\':\n        				$position_class = \"first-in-line first-item-of-mobile-line\";\n        				break;\n        			case \'5\':\n        				$position_class = \"last-item-of-tablet-line last-item-of-mobile-line\";\n        				break;\n        			case \'6\':\n        				$position_class = \"first-item-of-tablet-line first-item-of-mobile-line\";\n        				break;\n        			case \'7\':\n        				$position_class = \"last-in-line last-item-of-mobile-line\";\n        				break;\n        			case \'8\':\n        				$position_class = \"first-in-line last-item-of-tablet-line first-item-of-mobile-line\";\n        				break;\n        			case \'9\':\n        				$position_class = \"first-item-of-tablet-line last-item-of-mobile-line\";\n        				break;\n        			case \'10\':\n        				$position_class = \"first-item-of-mobile-line\";\n        				break;\n        			case \'11\':\n        				$position_class = \"last-in-line last-item-of-tablet-line last-item-of-mobile-line\";\n        				break;\n        			case \'12\':\n        				$position_class = \"first-in-line last-line first-item-of-tablet-line first-item-of-mobile-line\";\n        				break;\n        			case \'13\':\n        				$position_class = \"last-line last-item-of-mobile-line\";\n        				break;\n        			case \'14\':\n        				$position_class = \"last-line last-item-of-tablet-line first-item-of-mobile-line last-mobile-line\";\n        				break;\n        			case \'15\':\n        				$position_class = \"last-in-line last-line first-item-of-tablet-line last-item-of-mobile-line last-mobile-line\";\n        				break;\n    			}\n        		?>\n        		<li class=\"ajax_block_product col-xs-12 col-sm-4 col-md-3 <?php print $position_class; ?>\">\n        		<div class=\"product-container\">\n        		    \n        			<div class=\"left-block\">\n        			<div class=\"product-image-container\">\n            		    <?php\n            		    $date_creation = $db->jdate($product->datec);\n            		    if ($date_creation >= strtotime(\'-\'.getDolGlobalString(\'MARKETPLACE_DELAY_FOR_NEW\', 30).\' days\')) { ?>\n            		    <!-- for ban New -->\n            		    <a class=\"new-box\" href=\"/\">\n    								<span class=\"new-label\"><?php print $langs->trans(\"New\"); ?></span>\n    					</a>\n            		    <?php } ?>\n\n        			    \n        				<a class=\"product_img_link\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"<?php print $product->label; ?>\">\n        					<img class=\"replace-2x img-responsive\" src=\"<?php print $thumb; ?>\" alt=\"\" title=\"<?php print $product->label; ?>\" width=\"250\" height=\"250\" />\n        				</a>\n        				<div class=\"content_price\">\n            				<?php if ($product->price_ttc > 0): ?>\n            				    <?php if ($discounted_price != $product->price_ttc): ?>\n                                	<span class=\"price product-price original-price\"> <?php print price($product->price_ttc); ?> € </span>\n                                	<span class=\"price product-price\"> <?php print price($discounted_price); ?> € </span>\n                                <?php else: ?>\n            					    <span class=\"price product-price\"> <?php print price($product->price_ttc); ?> € </span>\n            					<?php endif ?>\n            				<?php else: ?>\n                			    <span class=\"price product-price\"> FREE </span>\n                			<?php endif ?>\n        				</div>\n        			</div>\n        			</div>\n        			<div class=\"right-block\">\n        			<h5 class=\"list-grid-product-title\">\n        				<a class=\"product-name truncate2\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"<?php print $product->label; ?>\"> <?php print $product->label; ?> </a>\n        			</h5>\n        			<p class=\"product-desc truncate2\"> \n        				<?php \n        				if (!empty($product->description)){\n        					print dol_string_nohtmltag($product->description); \n        				}\n        				?> \n        			</p>\n        			<div class=\"content_price\">\n        			    <?php if ($product->price_ttc > 0): ?>\n            			    <?php if ($discounted_price != $product->price_ttc): ?>\n                            	<span class=\"price product-price original-price\"> <?php print price($product->price_ttc); ?> € </span>\n                            	<span class=\"price product-price\"> <?php print price($discounted_price); ?> € </span>\n                            <?php else: ?>\n            				    <span class=\"price product-price\"> <?php print price($product->price_ttc); ?> € </span>\n            				<?php endif ?>\n            			<?php else: ?>\n            			    <span class=\"price product-price\"> FREE </span>\n            			<?php endif ?>\n        			</div>\n        			<div class=\"button-container\">\n        			    <form class=\"addtocart\" method=\"post\">\n        			        <input type=\"hidden\" name=\"product_id\" value=\"<?php print $product->id; ?>\">\n        			        <input type=\"hidden\" name=\"product_thumb\" value=\"<?php print getImagePublicURLOfObject($product,1); ?>\">\n        			        <input type=\"hidden\" name=\"product_quantity\" value=\"1\">\n        			        <?php if ($product->price_ttc > 0): ?>\n        			            <button type=\"submit\" class=\"button ajax_add_to_cart_button\"><span><?php print $weblangs->trans(\"addToCart\"); ?></span></button>\n        			        <?php endif ?>\n            				<a class=\"button lnk_view btn btn-default\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"View\">\n            				    <span><?php print $weblangs->trans(\"More\"); ?></span>\n            				</a>\n        				</form>\n        			</div>\n        			<div class=\"product-flags\"></div>\n        			<div class=\"functional-buttons clearfix\"></div>\n        			</div>\n        		</div>\n        		<!-- .product-container> -->\n        		</li>\n		<?php \n			    $key++;\n			} \n		}\n		?>\n	</ul>\n\n\n	<?php if (GETPOST(\'tag\', \'alpha\') != \"\" || GETPOST(\'cat\', \'alpha\') != \"\" || GETPOST(\'search_query\', \'alpha\') != \"\" || GETPOST(\'extcat\', \'alpha\') != \'\'): ?>\n		<div class=\"content_sortPagiBar\">\n		    <div class=\"bottom-pagination-content clearfix\">\n                <?php if ($total_no_of_pages > 1): ?>\n                    <!-- show all -->\n                    <div id=\"pagination\" class=\"pagination clearfix\">\n                        <form class=\"showall\" action=\"\" method=\"get\">\n                            <div>\n                                <button type=\"submit\" class=\"btn btn-default button exclusive-medium\">\n                                    <span><?php print $weblangs->trans(\"showAll\"); ?></span>\n                                </button>\n                                <input name=\"n\" id=\"nb_item\" class=\"hidden\" value=\"<?php print $count_prods; ?>\">\n                            </div>\n                        </form>\n            \n                        <!-- show all -->\n                        <ul class=\"pagination\">\n                            <li id=\"pagination_previous\" class=\"pagination_previous\" <?php if($page_no <= 1){ echo \"disabled\"; } ?>>\n                                <a <?php if($page_no > 1){ echo \"href=\'?p=$previous_page\'\"; } ?>>\n                                    <i class=\"icon-chevron-left\"></i>\n                                    <b><?php print $weblangs->trans(\"previous\"); ?></b>\n                                </a>\n                            </li>\n            \n                            <?php\n                            $start_page = max(1, $page_no - 2);  // Deux pages avant la page actuelle\n                            $end_page = min($total_no_of_pages, $page_no + 2);  // Deux pages après la page actuelle\n            \n                            if ($total_no_of_pages <= 10) {\n                                // Affiche toutes les pages si <= 10\n                                for ($counter = 1; $counter <= $total_no_of_pages; $counter++) {\n                                    if ($counter == $page_no) {\n                                        echo \"<li class=\'active current\'><span><span>$counter</span></span></li>\";  \n                                    } else {\n                                        echo \"<li><a href=\'?p=$counter\'><span>$counter</span></a></li>\";\n                                    }\n                                }\n                            } else {\n                                // Affiche deux pages avant et après la page actuelle\n                                if ($start_page > 1) {\n                                    echo \"<li><a href=\'?p=1\'><span>1</span></a></li>\";\n                                    if ($start_page > 2) {\n                                        echo \"<li><span><span><a>...</a></span></span></li>\";\n                                    }\n                                }\n                                for ($counter = $start_page; $counter <= $end_page; $counter++) {\n                                    if ($counter == $page_no) {\n                                        echo \"<li class=\'active\'><span><span>$counter</span></span></li>\";\n                                    } else {\n                                        echo \"<li><a href=\'?p=$counter\'><span>$counter</span></a></li>\";\n                                    }\n                                }\n                                if ($end_page < $total_no_of_pages) {\n                                    if ($end_page < $total_no_of_pages - 1) {\n                                        echo \"<li><span><span><a>...</a></span></span></li>\";\n                                    }\n                                    echo \"<li><a href=\'?p=$total_no_of_pages\'><span>$total_no_of_pages</span></a></li>\";\n                                }\n                            }\n                            ?>\n            \n                            <li class=\"pagination_next <?php if($page_no >= $total_no_of_pages){ echo \'disabled\'; } ?>\">\n                                <a <?php if($page_no < $total_no_of_pages) { echo \"href=\'?p=$next_page\'\"; } ?>>\n                                    <b><?php print $weblangs->trans(\"next\"); ?></b>\n                                    <i class=\"icon-chevron-right\"></i>\n                                </a>\n                            </li>\n                        </ul>\n                    </div>\n                <?php endif ?>\n            \n                <div class=\"product-count\">\n                    <?php print $weblangs->trans(\"showing\"); ?> \n                    <?php print $offset + 1; ?> - \n                    <?php if(($offset + $limit +1) > $count_prods) { print $count_prods; } else { print $offset + $limit +1; } ?> \n                    <?php print $weblangs->trans(\"of\"); ?> \n                    <?php print $count_prods; ?> \n                    <?php print $weblangs->trans(\"items\"); ?>\n                </div>\n            </div>\n        \n		</div>\n	<?php endif ?>\n<?php endif ?>\n\n<?php if ($count_prods == 0 || strlen($search_words) == 1): ?>\n		<h1 class=\"page-heading  product-listing\">\n			<?php print $weblangs->trans(\"search\"); ?> <span class=\"heading-counter\"><?php print $weblangs->trans(\"noResultsHaveBeenFound\"); ?></span>\n		</h1>\n		<p class=\"alert alert-warning\"><?php print $weblangs->trans(\"noResultsWereFound\"); ?> </p>\n<?php endif ?>',1,'2024-02-02 16:48:47',NULL,'2025-01-23 23:49:45',NULL,NULL,'other','',NULL,'','',NULL,'','',0,NULL,NULL),
(195,38,'rechtlicher-hinweise-ber-uns','','Rechtlicher Hinweise - Über uns','','','<script src=\"/document.php?modulepart=medias&file=js/tools.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/treeManagement.js\"></script>\n<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n		\n		<!--  Breadcrumb  -->\n		<div class=\"breadcrumb clearfix\">\n			<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n			<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n		</div>\n        <!--  Breadcrumb  -->\n        \n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Legal_notice_section\" contenteditable=\"true\">\n                    \n                    \n<div class=\"rte\">\n		<h3>Präsentation</h3>\n<p>Der Verein Dolibarr bietet die Plattform DoliStore.com an, um Verkäufer und Käufer zusammenzubringen. Nur der Sichtbarkeitsdienst für die verkauften Produkte wird von der Stiftung angeboten. Die Stiftung garantiert nichts bezüglich der Qualität der vom Kunden gekauften Produkte.</p>\n<p>Der Verein Dolibarr sammelt über den DoliStore im Namen der Autoren/Herausgeber Zahlungen für verkaufte Waren und verwaltet die Weiterleitung der ihnen zustehenden Gelder. In dieser Eigenschaft handelt der Verein unter der Befreiung von der Genehmigung als Zahlungsinstitut gemäß Artikel L521-3 I 2° des Währungs- und Finanzkodex.</p>\n<p>Der Verein Dolibarr ist ein französischer Verein (Gesetz 1901), der zur Förderung und Entwicklung der Open Source ERP- und CRM-Software Dolibarr gegründet wurde.</p>\n<p><strong>Rechtliche Informationen über die Stiftung:</strong></p>\n<ul>\n<li>WALDEC: W452006878</li>\n<li>SIRÈNE: 52033993800018</li>\n<li>NAF: 9499Z</li>\n</ul>\n<p>Weitere Informationen auf der Seite <a href=\"https://asso.dolibarr.org/index.php/Dolibarr_foundation\">https://asso.dolibarr.org/index.php/Dolibarr_foundation</a>.</p>\n<h3>Datenschutzgrundsätze</h3>\n<p>Durch die Nutzung der Website DoliStore.com stimmen Sie der Verarbeitung Ihrer persönlichen Daten zu, wie in dieser Datenschutzerklärung beschrieben.</p>\n<p><strong>Unsere Verpflichtungen zu den Datenschutzgrundsätzen sind wie folgt:</strong></p>\n<ul>\n<li><strong>Legale, faire und transparente Verarbeitung:</strong> Unsere Datenverarbeitungsaktivitäten haben legitime Gründe. Wir berücksichtigen immer Ihre Rechte, bevor wir persönliche Daten verarbeiten.</li>\n<li><strong>Zweckbindung:</strong> Die Datenverarbeitung ist auf den Zweck beschränkt, für den die persönlichen Daten erhoben wurden.</li>\n<li><strong>Datenminimierung:</strong> Wir erheben und verarbeiten nur die minimal erforderliche Menge an persönlichen Daten für jeden Zweck.</li>\n<li><strong>Speicherdauer:</strong> Die Verarbeitung ist auf einen bestimmten Zeitraum beschränkt. Wir werden Ihre persönlichen Daten nicht länger aufbewahren, als es nötig ist.</li>\n<li><strong>Integrität:</strong> Wir tun unser Bestes, um die Genauigkeit, Integrität und Vertraulichkeit der Daten zu gewährleisten.</li>\n</ul>\n<h3>Definition der Rechte an persönlichen Daten</h3>\n<ul>\n<li><strong>Recht auf Information:</strong> Sie müssen wissen, ob Ihre persönlichen Daten verarbeitet werden; welche Daten erhoben werden, woher sie stammen und warum und von wem sie verarbeitet werden.</li>\n<li><strong>Zugriffsrecht:</strong> Sie haben das Recht, auf die über Sie erhobenen Daten zuzugreifen. Dies schließt das Recht ein, eine Kopie Ihrer gesammelten persönlichen Daten anzufordern und zu erhalten.</li>\n<li><strong>Recht auf Berichtigung:</strong> Sie haben das Recht, die Berichtigung oder Löschung Ihrer ungenauen oder unvollständigen persönlichen Daten zu verlangen.</li>\n<li><strong>Recht auf Löschung:</strong> Unter bestimmten Umständen können Sie verlangen, dass Ihre persönlichen Daten aus unseren Aufzeichnungen gelöscht werden.</li>\n<li><strong>Recht auf Einschränkung oder Widerspruch gegen die Verarbeitung:</strong> Unter bestimmten Bedingungen haben Sie das Recht, die Verarbeitung Ihrer persönlichen Daten einzuschränken oder zu widersprechen.</li>\n<li><strong>Recht auf Datenübertragbarkeit:</strong> Sie haben das Recht, Ihre persönlichen Daten in einem maschinenlesbaren Format zu erhalten.</li>\n<li><strong>Recht auf Widerruf der Einwilligung:</strong> Sie haben das Recht, jede gegebene Einwilligung zur Verarbeitung Ihrer persönlichen Daten zu widerrufen.</li>\n</ul>\n<h3>Die von uns gesammelten Daten</h3>\n<p><strong>Von Verkäufern bereitgestellte Informationen:</strong></p>\n<ul>\n<li>E-Mail-Adresse, Vorname, Nachname, Firmenname, Unternehmens- oder Steueridentifikationsnummer (Umsatzsteuer-Identifikationsnummer), Rechnungsinformationen.</li>\n</ul>\n<p><strong>Von Käufern bereitgestellte Informationen:</strong></p>\n<ul>\n<li>E-Mail-Adresse, Vorname, Nachname, Firmenname, Unternehmens- oder Steueridentifikationsnummer (Umsatzsteuer-Identifikationsnummer), Rechnungsinformationen, Mitgliedsstatus im Verein.</li>\n</ul>\n<p><strong>Hinweis:</strong> Zahlungsinformationen (Kreditkarte oder Partner-Zahlungs-ID) werden nicht von DoliStore gesammelt oder gespeichert, sondern direkt an den Zahlungsanbieter übermittelt.</p>\n<p><strong>Automatisch gesammelte Informationen:</strong></p>\n<ul>\n<li>Dazu gehören Informationen, die automatisch durch Sitzungs-Cookies oder statistische Analysecookies (basierend auf Google und Matomo) gespeichert werden.</li>\n<li>Dazu gehört auch die Kaufhistorie.</li>\n</ul>\n<p><strong>Informationen von Partnern:</strong></p>\n<ul>\n<li>Wir sammeln keine Informationen von Partnern.</li>\n</ul>\n<p><strong>Links zu anderen Websites:</strong></p>\n<ul>\n<li>Die Seiten der Website können eingebettete Inhalte (z.B. Videos, Bilder, Artikel, Links) enthalten. Eingebettete Inhalte von anderen Websites verhalten sich genauso, als ob der Besucher die andere Website besucht hätte. Diese Websites können Daten über Sie sammeln (IP-Adresse, Verwendung von Cookies, Einbettung von Drittanbieter-Tracking-Tools) oder Ihre Interaktionen mit diesen eingebetteten Inhalten verfolgen, wenn Sie ein Konto auf deren Website haben und eingeloggt sind.</li>\n</ul>\n<h3>Verwendung Ihrer persönlichen Daten</h3>\n<p>Wir verwenden Ihre persönlichen Daten für die folgenden Zwecke:</p>\n<ul>\n<li>Um Sie zu identifizieren (Login-E-Mail und gehashte Passwort)</li>\n<li>Um mit Ihnen bezüglich verkaufter Produkte für Verkäufer oder gekaufter Produkte für Käufer zu kommunizieren (E-Mail)</li>\n<li>Um Ihre Verkäufer- oder Kundenerfahrung zu verbessern und Ihre Fragen zu beantworten (Kauf- oder Verkaufshistorie)</li>\n<li>Zur Erfüllung einer gesetzlichen oder vertraglichen Verpflichtung (Rechnungsdaten)</li>\n<li>Zur Durchführung von Analysen und Recherchen, um unsere Dienste zu verbessern (anonymisierte Statistikdaten über die Nutzung und Navigation der Website).</li>\n</ul>\n<p>Wir verarbeiten Ihre persönlichen Daten, um die sich aus dem Gesetz ergebenden Verpflichtungen zu erfüllen und/oder um Ihre persönlichen Daten für die gesetzlich vorgesehenen Optionen zu verwenden. Wir behalten uns das Recht vor, die gesammelten persönlichen Daten zu anonymisieren und diese anonymisierten Daten langfristig zu verwenden. Wir verwenden Daten außerhalb des Anwendungsbereichs dieser Richtlinie nur, wenn sie anonymisiert sind.</p>\n<p>Wir können Ihre persönlichen Daten für andere Zwecke verarbeiten, die hier nicht erwähnt sind. In diesem Fall wird dieses Dokument aktualisiert.</p>\n<h3>Speicherdauer Ihrer Daten</h3>\n<p>Für Benutzer, die sich auf unserer Website registrieren, speichern wir die persönlichen Daten, die in ihrem Profil angegeben sind. Alle Benutzer können ihre persönlichen Informationen jederzeit einsehen, ändern oder löschen.</p>\n<p>Wir speichern auch die Rechnungsinformationen so lange wie nötig aus buchhalterischen Gründen oder anderen gesetzlichen Verpflichtungen, bis zu Ihrer Aufforderung zur Löschung Ihrer persönlichen Daten oder für die gesetzliche Aufbewahrungsdauer der Rechnungsdaten.</p>\n<h3>Mit wem Ihre persönlichen Daten geteilt werden</h3>\n<p><strong>Verkäufer:</strong> Die folgenden persönlichen Daten der Käufer werden den Verkäufern zur Verfügung gestellt, um den Service bereitzustellen oder die Kundenerfahrung zu verbessern: E-Mail, Vorname und Nachname, Name des gekauften Moduls, Preis und Kaufdatum.</p>\n<p><strong>Käufer:</strong> Die folgenden persönlichen Daten der Verkäufer werden den Käufern zur Verfügung gestellt, um den Service bereitzustellen oder die Kundenerfahrung zu verbessern: E-Mail oder Kontakt-URL des Modulsupports (wenn der Verkäufer Support anbietet).</p>\n<p><strong>Zahlungsanbieter:</strong> Um die Rolle des Drittzahlungsdienstes zu gewährleisten, verwenden wir die Dienste von Stripe und Paypal. Wir übermitteln ihnen die E-Mail-Adresse und die Adresse des Käufers. Zahlungsinformationen werden nicht von DoliStore gespeichert, sondern direkt von Stripe oder Paypal gesammelt und gespeichert, die uns über den Erfolg oder Misserfolg der Zahlungen informieren.</p>\n<p><strong>Dritte und gesetzliche Stellen:</strong> Wir geben Ihre persönlichen Daten an Dritte oder an Beamte weiter, wenn wir gesetzlich dazu verpflichtet sind.</p>\n<p><strong>Andere Dritte außerhalb des Europäischen Wirtschaftsraums:</strong> Wir übermitteln keine Daten an andere Dritte als die oben genannten. Wenn wir persönliche Informationen an Länder außerhalb des Europäischen Wirtschaftsraums übertragen (für die oben genannten Fälle für Verkäufer außerhalb Europas oder für Zahlungsanbieter), stellen wir sicher, dass diese Informationen in Übereinstimmung mit dieser Datenschutzerklärung und den geltenden Datenschutzgesetzen übertragen werden. Wir verlassen uns auf Angemessenheitsentscheidungen der Europäischen Kommission oder verwenden Verträge mit Standardgarantien, die von der Europäischen Kommission veröffentlicht wurden.</p>\n<p><strong>Administratoren und Moderatoren:</strong> Die Plattform DoliStore wird von den Mitgliedern des Verwaltungsrats des Vereins Dolibarr verwaltet und moderiert. Jedes Vorstandsmitglied hat Zugriffs- und Änderungsrechte auf die Informationen im Profil der Verkäufer, Käufer und auf die Verkaufs-/Kauflisten.</p>\n<p></p>\n<p>Die Dolibarr Association kann nicht für die Nutzung dieser Daten durch Verkäufer oder andere Dritte mit autorisiertem Zugriff verantwortlich gemacht werden.</p>\n<p></p>\n<h3>Wie wir Ihre Daten sichern</h3>\n<p>Wir tun unser Bestes, um Ihre persönlichen Daten zu schützen.</p>\n<p><strong>Verschlüsselung der Kommunikation:</strong> Wir verwenden sichere Protokolle für die Kommunikation und den Datentransfer (wie HTTPS). Wir verwenden Anonymisierung und Pseudonymisierung, wenn dies angemessen ist.</p>\n<p><strong>Überwachung:</strong> Wir überwachen unsere Systeme, um mögliche Schwachstellen und Angriffe zu erkennen.</p>\n<p><strong>Backups:</strong> Regelmäßige Backups sind automatisiert.</p>\n<p>Obwohl wir unser Bestes tun, können wir die vollständige Sicherheit der Informationen nicht garantieren. Wir verpflichten uns jedoch, die zuständigen Behörden über Datenschutzverletzungen zu informieren. Wir werden Sie auch benachrichtigen, wenn eine Bedrohung für Ihre Rechte oder Interessen besteht. Wir werden alles in unserer Macht Stehende tun, um Sicherheitsverletzungen zu verhindern und den Behörden im Falle einer Verletzung zu helfen.</p>\n<p><strong>Passwort:</strong> Ihr Passwort wird in verschlüsselter Form durch irreversible Verschlüsselung (Hash) gespeichert. Wenn Sie ein Konto bei uns haben, müssen Sie Ihren Benutzernamen und Ihr Passwort geheim halten.</p>\n<h3>Cookies und andere Technologien, die wir verwenden</h3>\n<p>Wir verwenden Cookies und/oder ähnliche Technologien, um die Benutzer-Sitzungsfunktionalität zu ermöglichen und anonyme Navigationsstatistiken auf der Website zu erhalten.</p>\n<p>Ein Cookie ist eine kleine Textdatei, die auf Ihrem Computer (im Speicher oder auf der Festplatte) gespeichert wird. Cookies speichern Informationen, die zur Unterstützung der Funktion von Websites verwendet werden. Wir können nur auf die Cookies zugreifen, die von unserer Website erstellt wurden. Sie können Ihre Cookies auf Browserebene steuern. Das Deaktivieren von Cookies kann die Nutzung einiger Funktionen verhindern.</p>\n<p><strong>Wir verwenden Cookies für folgende Zwecke:</strong></p>\n<ul>\n<li><strong>Notwendige Cookies:</strong> Diese Cookies sind erforderlich, um wichtige Funktionen auf unserer Website zu nutzen, wie das Einloggen und die Persistenz der Sitzung. Diese Cookies sammeln keine persönlichen Informationen.</li>\n<li><strong>Funktions-Cookies:</strong> Diese Cookies bieten Funktionen, die die Nutzung unseres Dienstes bequemer machen und personalisierte Funktionen ermöglichen. Beispielsweise können sie sich Ihren Namen und Ihre E-Mail-Adresse in Kommentarformularen merken, sodass Sie diese Informationen nicht erneut eingeben müssen.</li>\n<li><strong>Analytische Cookies:</strong> Diese Cookies werden verwendet, um die Nutzung und Leistung unserer Website und Dienste anonym zu verfolgen.</li>\n</ul>\n<p>Sie können die auf Ihrem Computer gespeicherten Cookies über die Einstellungen Ihres Browsers löschen. Sie können auch einige Cookies von Drittanbietern über eine Datenschutzverbesserungsplattform wie optout.aboutads.info oder youronlinechoices.com kontrollieren. Weitere Informationen zu Cookies finden Sie auf allaboutcookies.org.</p>\n<h3>Kontaktinformationen - DPO</h3>\n<p>Der Datenschutzbeauftragte (DPO) ist der Präsident des Vereins Dolibarr. Sein Name ist auf dieser Seite angegeben: <a href=\"https://wiki.dolibarr.org/index.php/Office_and_Board_Members\">https://wiki.dolibarr.org/index.php/Office_and_Board_Members</a>.</p>\n<p>Anfragen bezüglich Ihrer persönlichen Daten können per E-Mail an <a>dolistore@dolibarr.org</a> gestellt werden.</p>\n<h3>Änderungen dieser Datenschutzerklärung</h3>\n<p>Wir behalten uns das Recht vor, Änderungen an dieser Datenschutzerklärung vorzunehmen. Letzte Änderung am 14.05.2024.</p>\n	</div>                    \n\n\n\n				</section>\n\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 19:20:58',NULL,'2025-01-14 00:05:41',NULL,NULL,'page','de',154,'','',NULL,'','',0,NULL,NULL),
(196,38,'register','','register','','','<?php\n\n//session_set_cookie_params([\'lifetime\' => 0, \'path\' => \'/\', \'domain\' => \'\', \'secure\' => true, \'httponly\' => true, \'samesite\' => \'Lax\');\nsession_start(); // start session\n\nrequire_once DOL_DOCUMENT_ROOT.\'/core/class/html.formcompany.class.php\';\n$form = new Form($db);\n$weblangs->loadLangs(array(\"main\", \"companies\"));\n?>\n<?php\n    if(!empty(GETPOST(\'action\')) && GETPOST(\'action\') == \"register\") {\n        include_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\n        include_once DOL_DOCUMENT_ROOT.\'/core/lib/admin.lib.php\';\n        include_once DOL_DOCUMENT_ROOT.\'/core/modules/security/generate/modGeneratePassStandard.class.php\';\n        $id_website = $website->id;\n        $marketplace_third_parties_category = getDolGlobalInt(\"MARKETPLACE_PROSPECTCUSTOMER_ID\");\n        \n\n        $customer_firstname = GETPOST(\'firstname\');\n        $customer_lastname = GETPOST(\'lastname\');\n        $customer_email = GETPOST(\'email\');\n        $customer_passwd = GETPOST(\'passwd\');\n        $customer_address = GETPOST(\'address\');\n        $customer_city = GETPOST(\'city\');\n        $customer_postalcode = GETPOST(\'postalcode\');\n        $customer_country = GETPOSTINT(\'country_id\');\n        $customer_company = GETPOST(\'company\');\n        $customer_siret = GETPOST(\'siret\');\n        $customer_tin = GETPOST(\'tin\');\n        $back = GETPOST(\'back\');\n        \n        $error = 0;\n        $error_messages = array();\n        \n        // Check Captcha return if captcha is activated\n        if (!empty(getDolGlobalInt(\"MARKETPLACE_GOOGLE_RECAPTCHA_REGISTER_FORM\"))) {\n            include_once DOL_DOCUMENT_ROOT.\'/core/lib/geturl.lib.php\';\n            \n            $recaptchaSecretKey = getDolGlobalString(\"MARKETPLACE_GOOGLE_RECAPTCHA_SECRET_KEY\");\n            $recaptchaResponse = GETPOST(\'g-recaptcha-response\');\n        \n            $responseDataRecaptcha = getURLContent(\"https://www.google.com/recaptcha/api/siteverify?secret=$recaptchaSecretKey&response=$recaptchaResponse\");\n            $responseDataRecaptcha = json_decode($responseDataRecaptcha[\'content\']);\n            \n            if (!$responseDataRecaptcha->success || $responseDataRecaptcha->score < 0.5) {\n                $error++;\n                $error_messages[] = $weblangs->trans(\"captchaFail\", ($responseDataRecaptcha->score ?? \'N/A\'));\n            }\n        }\n        \n        if (!isValidEmail($customer_email)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"emailInvalid\");\n    	}\n    	\n    	\n    	$sql  = \"select lsa.rowid \";\n        $sql .= \"from \".MAIN_DB_PREFIX.\"societe_account lsa \";\n        $sql .= \"where lsa.login = \'\". $db->escape($customer_email) .\"\' \";\n        $sql .= \"and lsa.fk_website = \". ((int) $id_website) . \" \";\n        $sql .= \"limit 1\";\n        \n        $result = $db->query($sql);\n		$objsql = $db->fetch_object($result);\n		\n		if (!empty($objsql)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"emailAlreadyRegistered\");\n        }\n    	\n    	if (empty($customer_firstname)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Firstname\"));\n    	}\n    	\n    	//if (ctype_alpha(str_replace(array(\"\\n\", \"\\t\", \' \'), \'\', $customer_firstname)) === false) {\n    	if (!preg_match(\'/^[a-zA-ZÀ-ÖØ-öø-ÿ\\- ]+$/u\', $customer_firstname)) {\n    	    $error++;\n            $error_messages[] = $weblangs->trans(\"firstnameContainsLettersOnly\");\n        }\n    	\n    	if (empty($customer_lastname)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Lastname\"));\n    	}\n    	\n    	//if (ctype_alpha(str_replace(array(\"\\n\", \"\\t\", \' \'), \'\', $customer_lastname)) === false) {\n    	if (!preg_match(\'/^[a-zA-ZÀ-ÖØ-öø-ÿ\\- ]+$/u\', $customer_lastname)) {\n    	    $error++;\n            $error_messages[] = $weblangs->trans(\"lastnameContainsLettersOnly\");\n        }\n    	\n    	$check_pass = new modGeneratePassStandard($db, $conf, $langs, $user);\n    	$is_valid = $check_pass->validatePassword($customer_passwd);\n    	if(!$is_valid){\n    	    $error++;\n    	    $weblangs->load(\"other\");\n    		$error_messages[] = $weblangs->trans(\"YourPasswordMustHaveAtLeastXChars\", (string) $check_pass->length2);\n    	}\n    	\n    	if (empty($customer_address)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Address\"));\n    	}\n    	\n    	if (empty($customer_city)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Town\"));\n        } elseif (!preg_match(\'/^[a-zA-ZÀ-ÖØ-öø-ÿ\\- ]+$/u\', $customer_city)) {\n            $error++;\n            $error_messages[] = $weblangs->trans(\"cityContainsLettersOnly\");\n        }\n        \n        if (empty($customer_postalcode)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Zip\"));\n        } elseif (!preg_match(\'/^[a-z0-9\\.\\- ]+$/i\', $customer_postalcode)) {\n            $error++;\n            $error_messages[] = $weblangs->trans(\"postalCodeContainsDigitsOnly\");\n        }\n    	\n    	if (empty($customer_country)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Country\"));\n    	}\n        \n        if($error == 0){\n            // Start of transaction\n            $db->begin();\n            \n            $customer = new Societe($db);\n        \n        	if (!empty($customer_company)) {\n        		$customer->name = $customer_company;\n        	} else {\n        		$customer->name = dolGetFirstLastname($customer_firstname, $customer_lastname);\n        	}\n        	$customer->name_alias = \'\';\n\n        	$customer->address = $customer_address;\n        	$customer->town = $customer_city;\n        	$customer->zip = $customer_postalcode;\n        	$customer->country_id = $customer_country;\n        \n        	$customer->idprof2 = $customer_siret;\n        	$customer->tva_intra = $customer_tin;\n\n        	$customer->client = \'2\';    // Set as prospect by default.\n        	$customer->code_client = \'auto\';\n\n        	$customer->fournisseur = \'0\';\n        	$customer->code_fournisseur = \'auto\';\n        \n        	//$customer->default_lang = $obj->dol_lang_code;\n        	\n        	$customer->ip = getUserRemoteIP();\n        	\n        	$result = $customer->create($user);\n        	if ($result < 0) {\n    			$error++;\n    			$error_messages[] = $weblangs->trans(\"errorOccurred\");\n    		}\n        	$rowid_soc = $result;\n        \n            if ($error == 0) {\n    			// Add  groups\n    			$ret_cat = $customer->setCategories($marketplace_third_parties_category, \'customer\');\n    			if ($ret_cat < 0) {\n    				$error++;\n    				$error_messages[] = $weblangs->trans(\"errorOccurred\");\n    			}\n    \n    \n    			// Add default contact\n    			$customer->name_bis = $customer_lastname;\n    			$customer->email = $customer_email;\n    			$customer->firstname = $customer_firstname;\n    			$customer->address = $customer_address;\n    			$customer->town = $customer_city;\n        	    $customer->zip = $customer_postalcode;\n    			$customer->country_id = $customer_country;\n    \n            	$customer->ip = getUserRemoteIP();\n\n    			$ret_contact = $customer->create_individual($user);\n    			if ($ret_contact < 0) {\n    				$error++;\n    				$error_messages[] = $weblangs->trans(\"errorOccurred\");\n    			} else {\n    			    $currentContactId = $ret_contact;\n    			}\n    \n    \n    			// Add connection credentials for a specific website	\n    			if(!empty($id_website)) {\n    				$societeaccount = new SocieteAccount($db);\n    				$societeaccount->login = $customer_email;\n    				$societeaccount->pass_encoding = \"dolibarr\";\n    				$societeaccount->pass = $customer_passwd;\n    				$societeaccount->fk_soc = $rowid_soc;\n    				$societeaccount->fk_website = $id_website;\n    				$societeaccount->site = \"dolibarr_website\";\n    				$societeaccount->status = \"1\";\n		        	$societeaccount->ip = getUserRemoteIP();\n\n    				$ret_account = $societeaccount->create($user);\n    				if ($ret_account < 0) {\n    					$error++;\n    					$error_messages[] = $weblangs->trans(\"errorOccurred\");\n    				} else {\n    					$id_user = $ret_account;\n    					\n    					// Link contact to account\n						$sql = \'UPDATE \' . MAIN_DB_PREFIX . \"socpeople  SET ref_ext = \'\" . $db->escape($id_user) . \"\', note_private = \'Marketplace contact for website account ID : \" . $id_user . \"\' WHERE rowid = \" . ((int) $currentContactId);\n						$db->query($sql);\n    				}\n    			}\n    		}\n    		\n    		if ($error == 0) {\n    		    $db->commit();\n            	\n            	// Send welcome email\n    		    $substitutionarray = array(\n		            \'__USER_NAME__\' => $customer->name\n		        );\n            	marketplace_send_email(getDolGlobalInt(\"MARKETPLACE_WELCOME_EMAIL_TEMPLATE\"), \'thirdparty\', $societeaccount, $societeaccount->login, $substitutionarray);\n            	\n\n                // Set session after having created the thirdparty            	\n            	if(isset($_SESSION[\'user\'])){  //if session var already exist\n                    unset($_SESSION[\'user\']);\n                }\n\n                $_SESSION[\'user\'][\'id_user\'] = $id_user;\n                $_SESSION[\'user\'][\'socid\'] = $rowid_soc;\n                $_SESSION[\'user\'][\'email\'] = $customer_email;\n                $_SESSION[\'user\'][\'pseudo\'] = $customer->name;\n                \n                if ($back == \'payement\') {\n                    redirectToContainer(\'payment\');\n                }\n                redirectToContainer(\'myaccount\');\n            } else {\n            	$db->rollback();\n            }\n        }\n    		\n    }\n?>\n\n<?php\n    $back = GETPOST(\'back\');\n?>\n<div class=\"col-xs-12 col-sm-7\">\n    <?php if (!empty(getDolGlobalInt(\"MARKETPLACE_GOOGLE_RECAPTCHA_REGISTER_FORM\"))): ?>\n        <script src=\"https://www.google.com/recaptcha/api.js?render=<?php print getDolGlobalString(\"MARKETPLACE_GOOGLE_RECAPTCHA_SITE_KEY\"); ?>\"></script>\n    <?php endif ?>\n	<form action=\"login-register.php\" method=\"post\" id=\"account-creation_form\" class=\"std box\">\n		<div class=\"account_creation\">\n			<h3 class=\"page-subheading\"><?php print $weblangs->trans(\"accountCreation\"); ?></h3>\n			\n			<?php if (isset($error) && $error != 0): ?>\n        		<div class=\'alert alert-danger\'>\n            		<?php $add_s = ($error > 1) ? \"s\" : \"\"; ?>\n            		<p><?php print $weblangs->trans(\"errorsOccurred\", $error, $add_s); ?></p>\n            		<ol>\n            		    <?php foreach ($error_messages as $key => $value): ?>\n                    		<li><?php print $value; ?></li>\n                    	<?php endforeach ?>\n            		</ol>\n            	</div>\n        	<?php endif ?>\n        	\n			<div class=\"required form-group\">\n				<label for=\"customer_firstname\"><?php print $weblangs->trans(\"Firstname\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"is_required validate form-control\"id=\"firstname\" name=\"firstname\" value=\"<?php if (isset($customer_firstname)){print $customer_firstname;} ?>\">\n			</div>\n			<div class=\"required form-group\">\n				<label for=\"customer_lastname\"><?php print $weblangs->trans(\"Lastname\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"is_required validate form-control\" id=\"lastname\" name=\"lastname\" value=\"<?php if (isset($customer_lastname)){print $customer_lastname;} ?>\">\n			</div>\n			<div class=\"required form-group\">\n				<label for=\"email\"><?php print $weblangs->trans(\"Email\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"is_required validate form-control\" id=\"email\" name=\"email\" value=\"<?php if (isset($customer_email)){print $customer_email;} ?>\">\n			</div>\n			<div class=\"required password form-group\">\n				<label for=\"passwd\"><?php print $weblangs->trans(\"Password\"); ?> <sup>*</sup></label>\n				<input type=\"password\" class=\"is_required validate form-control\" name=\"passwd\" id=\"passwd\" autocomplete=\"new-password\" value=\"<?php if (isset($customer_passwd)){print $customer_passwd;} ?>\">\n			</div>\n		</div>\n		<div class=\"account_creation\">\n			<h3 class=\"page-subheading page-subheading-login\"><?php print $weblangs->trans(\"yourBillingInformation\"); ?></h3>\n			\n			<div class=\"required form-group\">\n				<label for=\"customer_lastname\"><?php print $weblangs->trans(\"Address\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"is_required validate form-control\" id=\"Address\" name=\"address\" value=\"<?php if (isset($customer_address)){print $customer_address;} ?>\">\n			</div>\n			<div class=\"required form-group\">\n				<label for=\"customer_lastname\"><?php print $weblangs->trans(\"Town\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"validate form-control\" id=\"City\" name=\"city\" value=\"<?php if (isset($customer_city)){print $customer_city;} ?>\">\n			</div>\n			<div class=\"required form-group\">\n				<label for=\"customer_lastname\"><?php print $weblangs->trans(\"Zip\"); ?> <sup>*</sup></label>\n				<input type=\"text\" class=\"validate form-control\" id=\"Postalcode\" name=\"postalcode\" value=\"<?php if (isset($customer_postalcode)){print $customer_postalcode;} ?>\">\n			</div>\n			<div class=\"required form-group\">\n    			<label for=\"email\"><?php print $weblangs->trans(\"Country\"); ?> <sup>*</sup></label>\n			    <?php print $form->select_country(GETPOSTISSET(\'country_id\') ? GETPOST(\'country_id\') : \'\', \'country_id\', \'\', 0, \'form-control\'); ?>\n			</div>\n			\n			<p class=\"form-group\">\n				<label for=\"\"><?php print $weblangs->trans(\"Company\"); ?></label>\n				<input type=\"text\" class=\"form-control\" id=\"company\" name=\"company\" value=\"<?php if (isset($customer_company)){print $customer_company;} ?>\">\n			</p>\n			<p class=\"form-group\">\n				<label for=\"siret\"><?php print $weblangs->trans(\"MarketPlaceBusinessNumber\"); ?></label>\n				<input type=\"text\" class=\"form-control\" id=\"siret\" name=\"siret\" value=\"<?php if (isset($customer_siret)){print $customer_siret;} ?>\">\n			</p>\n			<p class=\"form-group\">\n				<label for=\"tin\"><?php print $weblangs->trans(\"MarketPlaceTIN\"); ?></label>\n				<input type=\"text\" class=\"form-control\" id=\"tin\" name=\"tin\" value=\"<?php if (isset($customer_tin)){print $customer_tin;} ?>\">\n			</p>\n			\n		</div>\n		<input type=\"hidden\" name=\"action\" value=\"register\">\n		<input type=\"hidden\" name=\"back\" value=\"<?php print $back; ?>\">\n		\n		<?php if (!empty(getDolGlobalInt(\"MARKETPLACE_GOOGLE_RECAPTCHA_REGISTER_FORM\"))): ?>\n            <input type=\"hidden\" name=\"g-recaptcha-response\" id=\"g-recaptcha-response\">\n        <?php endif ?>\n        \n		<div class=\"submit clearfix\">\n			<hr>\n			<button type=\"submit\" name=\"submitAccount\" id=\"submitAccount\" class=\"btn btn-default button button-medium\">\n				<span><?php print $weblangs->trans(\"register\"); ?> <i class=\"icon-chevron-right right\"></i></span>\n			</button>\n			<p class=\"pull-right\"><span><sup>*</sup> <?php print $weblangs->trans(\"requiredField\"); ?></span></p>\n		</div>\n	</form>\n	\n	<?php if (!empty(getDolGlobalInt(\"MARKETPLACE_GOOGLE_RECAPTCHA_REGISTER_FORM\"))): ?>\n        <script>\n            grecaptcha.ready(function () {\n                grecaptcha.execute(\'<?php print getDolGlobalString(\"MARKETPLACE_GOOGLE_RECAPTCHA_SITE_KEY\"); ?>\', { action: \'submit\' }).then(function (token) {\n                    document.getElementById(\'g-recaptcha-response\').value = token;\n                });\n            });\n        </script>\n    <?php endif ?>\n</div>',1,'2024-03-14 13:51:50',NULL,'2025-01-19 18:13:36',NULL,NULL,'other','',NULL,'','',NULL,'','',0,NULL,NULL),
(197,38,'sicheres-bezahlen','','Sicheres Bezahlen','Sicheres Bezahlen','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<script src=\"/document.php?modulepart=medias&file=js/tools.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/treeManagement.js\"></script>\n<?php // BEGIN PHP\n\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n        <!--  Breadcrumb  -->\n		<div class=\"breadcrumb clearfix\">\n			<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n			<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n		</div>\n		<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n            \n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"about_payement_section\" contenteditable=\"true\">\n				<div class=\"rte\">\n                  <h2>Sicherheit beim Bezahlen</h2>\n                  <p>Wann und weshalb eine Zahlung, wenn die Software eine OpenSource Lizenz (GPL, ...) ist?</p>\n                  <p>Die meisten Produkte auf dem Markt sind kostenlos und können direkt aus ihrem Profil heruntergeladen werden. Deshalb ist in diesen Fällen keine Zahlung erforderlich.</p>\n                  <p>Einige Autoren beschließen jedoch, etwas zu berechnen, für ihre Arbeit. Es gibt kein Problem, die beiden Ansätze bei freier Software widersprechen sich nicht (Preis für die Autoren für den Quellcode einer OpenSource Lizenz):</p>\n                  <p>Der Begriff \"freie Software\" kann sich laut&nbsp;Definition entweder auf die Freiheit oder auf den Preis beziehen. Auf der&nbsp;folgenden Seite der&nbsp;Free Software&nbsp;Foundation können Sie dies gerne nachlesen: <br>\n                    <a href=\"http://www.gnu.org/philosophy/selling.de.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.de.html</a>\n                    <br>\n                    <br>\n                  </p>\n                  <h3>Unsere Angebote für Ihre sichere Zahlung</h3>\n                  <p>\n                    <span lang=\"de\" xml:lang=\"de\">Die Zahlungsdaten werden&nbsp;mit SSL verschlüsselt gesichert <br>\n                    </span>\n                  </p>\n                  <h3>Verwendung von Visa/Mastercard/Paypal</h3>\n                  <p>Die Kreditkartenzahlungen werden von unserer Stripe garantiert.</p>\n                  <p>Die Zahlung durch elektronische Geldbörse sind über den Online-Zahlungsservice Paypal versichert.</p>\n                </div>\n				</section>\n\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 22:14:26',NULL,'2025-01-14 01:27:27',NULL,NULL,'page','de',153,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(198,38,'sidebar','','sidebar','sidebar','','<?php // BEGIN PHP\n\nincludeContainer(\"_library_page_lib.php\", 1);\n\n$current_lang = $_SESSION[\'lang\'][\'code\'];\n$current_lang_short_code = $_SESSION[\'lang\'][\'shortcode\'];\n\n$mcid = getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\");\nif (empty($mcid)) {\n  print $weblangs->trans(\"variableNotDefined\", \'MARKETPLACE_ROOT_CATEGORY_ID\');\n  exit;\n}\n$root_cat_object = new Categorie($db);\n$result = $root_cat_object->fetch($mcid);\n$root_category_id = $root_cat_object->id;\n$root_category_type = $root_cat_object->type;\n\n$current_category_id = GETPOST(\'cat\', \'alpha\');\n// END PHP \n?>\n<!-- BEGIN LEFT SIDEBAR -->\n<div id=\"left_column\" class=\"column col-xs-12 col-sm-3\">\n  <section id=\"left_column_1\">\n    <div id=\"categories_block_left\" class=\"block\">\n      <h2 class=\"title_block\"> <?php print $weblangs->trans(\"sidebarCategories\"); ?> </h2>\n      <div class=\"block_content\">\n        <?php\n        $organized_tree = getOrganizedTree($mcid);\n        if (count($organized_tree) < 1) {\n            print \'<tr class=\"oddeven nobottom\">\';\n            print \'<td colspan=\"3\"><span class=\"opacitymedium\">\' . $weblangs->trans(\"NoSubCat\") . \'</span></td>\';\n            print \'</tr>\';\n        }\n        ?>\n        <ul class=\"tree dhtml\">\n          <?php foreach ($organized_tree as $key => $value) : ?>\n            <?php if ($value[\'label\'] != \"Versions\" && $value[\'label\'] != \"Specials\") : ?>\n              <li>\n                <a href=\"index.php?cat=<?php print $value[\'rowid\']; ?>&title=<?php print dolSlugify($value[\'label\']); ?>&l=<?php print $current_lang_short_code; ?>\" <?php ($current_category_id == $value[\'rowid\']) ? print \'class=\"selected\"\' : \'\'; ?> title=\"\"> <?php print $value[\'label\']; ?> </a>\n                <?php if (isset($value[\'children\'])) : ?>\n                  <ul>\n                    <?php usort($value[\'children\'], build_sorter(\'position\')); ?>\n                    <?php foreach ($value[\'children\'] as $key_children => $value_children) : ?>\n                      <li>\n                        <a href=\"index.php?cat=<?php print $value_children[\'rowid\']; ?>&title=<?php print dolSlugify($value_children[\'label\']); ?>&l=<?php print $current_lang_short_code; ?>\" <?php ($current_category_id == $value_children[\'rowid\']) ? print \'class=\"selected\"\' : \'\'; ?> title=\"<?php print dol_escape_htmltag(strip_tags($value_children[\'description\'])); ?>\"> <?php print $value_children[\'label\']; ?> </a>\n                      </li>\n                    <?php endforeach ?>\n                  </ul>\n                <?php endif ?>\n              </li>\n            <?php endif ?>\n          <?php endforeach ?>\n        </ul>\n      </div>\n    </div>\n  </section>\n          \n  <div id=\"tags_block_left\" class=\"block tags_block\">\n    <p class=\"title_block\"> <?php print $weblangs->trans(\"versions\"); ?> </p>\n    <div class=\"block_content\">\n      <?php\n        $mvcid = getDolGlobalInt(\"MARKETPLACE_VERSIONS_CATEGORY_ID\");\n        if (empty($mvcid)) {\n            print $weblangs->trans(\"variableNotDefined\", \'MARKETPLACE_VERSIONS_CATEGORY_ID\');\n        } else {\n            $full_version_tree = getOrganizedTree($mvcid, \'label\');\n            if (count($full_version_tree) < 1) {\n                print \'<tr class=\"oddeven nobottom\">\';\n                print \'<td colspan=\"3\"><span class=\"opacitymedium\">\' . $langs->trans(\"NoSubCat\") . \'</span></td>\';\n                print \'</tr>\';\n            }\n        }\n      ?>\n\n      <?php foreach (array_reverse($full_version_tree) as $key => $value) : ?>\n        <?php if ($value[\'rowid\'] != $mvcid) : ?>\n          <a class=\"tag_version\" href=\"index.php?tag=<?php print $value[\'label\']; ?>\" title=\"<?php print $value[\'description\']; ?>\"> <?php print $value[\'label\']; ?> </a>\n        <?php endif ?>\n      <?php endforeach ?>\n    </div>\n  </div>\n\n\n  <div id=\"special_block_right\" class=\"block hideonsmartphone\">\n    <p class=\"title_block\">\n      <a href=\"#\" title=\"Specials\"> <?php print $weblangs->trans(\"specialPromo\"); ?> </a>\n    </p>\n    <div class=\"block_content products-block\">\n      <ul>\n        <?php\n        $mcsid = getDolGlobalInt(\"MARKETPLACE_SPECIAL_CATEGORY_ID\");\n        if (empty($mcsid)) {\n          print $weblangs->trans(\"variableNotDefined\", \'MARKETPLACE_SPECIAL_CATEGORY_ID\');\n          exit;\n        }\n        $root_cat_object = new Categorie($db);\n        $result = $root_cat_object->fetch($mcsid);\n        $limit = 2;\n        \n        $sql = \"SELECT c.fk_product as id, o.ref, o.ref_ext, ol.label, ol.description, o.datec, o.price_ttc \";\n        $sql .= \"FROM llx_categorie_product as c, \";\n        $sql .= \"llx_product as o, \";\n        $sql .= \"llx_product_lang as ol \";\n        $sql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \".$root_cat_object->id.\" AND c.fk_product = o.rowid AND ol.fk_product = o.rowid \";\n        $sql .= \"AND ol.lang = \'\".$db->escape($current_lang).\"\' AND o.tosell = 1 \";\n        $sql .= \" ORDER BY RAND() \";\n        //$sql .= $db->order(\'datec\', \'DESC\');\n        $sql .= $db->plimit($limit);\n\n        if ($resql = $db->query($sql)) {\n		    $key = 0;\n			while ($product = $resql->fetch_object()) {\n			    $product->element = \"product\";\n			    \n			    $discount = marketplace_check_discount($product->id);\n		        $discounted_price = marketplace_calculate_discounted_price($product->price_ttc, $discount);\n\n                $thumb = getImagePublicURLOfObject($product, 1, \'_small\');\n                ?>\n                <li class=\"clearfix\">\n                    <a class=\"products-block-image\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\">\n                      <img class=\"replace-2x img-responsive width98\" src=\"<?php print $thumb; ?>\" alt=\"\" title=\"<?php print $product->label; ?>\" />\n                    </a>\n                    <div class=\"product-content\">\n                      <h5>\n                        <a class=\"product-name truncate2\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"<?php print $product->label; ?>\"> <?php print $product->label; ?> </a>\n                      </h5>\n                      <p class=\"product-description truncate2\">\n                        <?php\n                        if (isset($product->description)) {\n                          print dolPrintHTML(dol_string_nohtmltag($product->description));\n                        }\n                        ?>\n                      </p>\n                      <div class=\"price-box\">\n                            <?php if ($discounted_price != $product->price_ttc): ?>\n                            	<span class=\"price special-price\"> <?php print price($discounted_price); ?> € </span>\n                                <span class=\"old-price\"> <?php print price($product->price_ttc); ?> € </span>\n                            <?php else: ?>\n                                <span class=\"price\"> <?php print price($product->price_ttc); ?> € </span>\n                            <?php endif ?>\n                        <!--<span class=\"price-percent-reduction\">-50%</span>\n        				<span class=\"old-price\"> 300,00 € </span>-->\n                      </div>\n                    </div>\n                </li>\n        <?php \n			}\n		}\n        ?>\n      </ul>\n      <div>\n        <a class=\"btn btn-default button button-small\" href=\"index.php?tag=Specials\" title=\"<?php print $weblangs->trans(\"allSpecials\"); ?>\">\n          <span><?php print $weblangs->trans(\"allSpecials\"); ?> <i class=\"icon-chevron-right right\"></i>\n          </span>\n        </a>\n      </div>\n    </div>\n  </div>\n\n  <div id=\"new-products_block_right\" class=\"block products_block hideonsmartphone\" contenteditable=\"true\">\n    <h4 class=\"title_block\">\n      <a href=\"#\" title=\"New products\"><?php print $weblangs->trans(\"newProducts\"); ?></a>\n    </h4>\n    <div class=\"block_content products-block\">\n      <ul class=\"products\">\n        <?php\n        $result = $root_cat_object->fetch($root_category_id, \"\");\n        if ($result <= 0) {\n          dol_print_error($db, $root_cat_object->error);\n          exit;\n        }\n        $limit = 2;\n        \n        $sql = \"SELECT c.fk_product as id, o.ref, o.ref_ext, ol.label, ol.description, o.datec, o.price_ttc \";\n        $sql .= \"FROM llx_categorie_product as c, \";\n        $sql .= \"llx_product as o, \";\n        $sql .= \"llx_product_lang as ol \";\n        $sql .= \"WHERE o.entity IN (1) AND c.fk_categorie = \".$root_cat_object->id.\" AND c.fk_product = o.rowid AND ol.fk_product = o.rowid \";\n        $sql .= \"AND ol.lang = \'\".$db->escape($current_lang).\"\' AND o.tosell = 1\";\n\n        $delay_for_new = (int) getDolGlobalInt(\'MARKETPLACE_DELAY_FOR_NEW\', 30);\n        $dateTime = new \\DateTime();\n        $interval = new \\DateInterval(\'P\'.$delay_for_new.\'D\');\n        $dateTime->sub($interval);\n        $sql .= \" AND o.datec > \'\" . $dateTime->format(\'Y-m-d H:i:s\') . \"\'\";\n\n        //$sql .= $db->order(\'datec\', \'DESC\');\n        $sql .= \" ORDER BY RAND() \";\n        $sql .= $db->plimit($limit);\n\n        if ($resql = $db->query($sql)) {\n		    $key = 0;\n			while ($product = $resql->fetch_object()) {\n			    $product->element = \"product\";\n			    \n			    $discount = marketplace_check_discount($product->id);\n		        $discounted_price = marketplace_calculate_discounted_price($product->price_ttc, $discount);\n\n                $thumb = getImagePublicURLOfObject($product, 1, \'_small\');\n                ?>\n                <li class=\"clearfix\">\n\n                    <a class=\"products-block-image\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"<?php print $product->label; ?>\">\n                      <img class=\"replace-2x img-responsive width98\" src=\"<?php print $thumb; ?>\" alt=\"\" title=\"<?php print $product->label; ?>\" />\n                    </a>\n                    <div class=\"product-content\">\n                      <h5>\n                        <a class=\"product-name truncate2\" href=\"product.php?id=<?php print $product->id; ?>&title=<?php print dolSlugify($product->label); ?>&l=<?php print $current_lang_short_code; ?>\" title=\"<?php print $product->label; ?>\"> <?php print $product->label; ?> </a>\n                      </h5>\n                      <p class=\"product-description truncate2\">\n                        <?php\n                        if (isset($product->description)) {\n                          print dolPrintHTML(dol_string_nohtmltag($product->description));\n                        }\n                        ?>\n                      </p>\n                      <div class=\"price-box\">\n        				<?php if ($discounted_price != $product->price_ttc): ?>\n                        	<span class=\"price special-price\"> <?php print price($discounted_price); ?> € </span>\n                            <span class=\"old-price\"> <?php print price($product->price_ttc); ?> € </span>\n                        <?php else: ?>\n                            <span class=\"price\"> <?php print price($product->price_ttc); ?> € </span>\n                        <?php endif ?>\n                      </div>\n                    </div>\n                </li>\n        <?php \n			} \n        }\n        ?>\n      </ul>\n      <div>\n        <a href=\"index.php?cat=<?php print $root_category_id; ?>&list=new\" title=\"<?php print $weblangs->trans(\"allNewProducts\"); ?>\" class=\"btn btn-default button button-small\">\n          <span><?php print $weblangs->trans(\"allNewProducts\"); ?> <i class=\"icon-chevron-right right\"></i>\n          </span>\n        </a>\n      </div>\n    </div>\n  </div>\n</div>\n<!-- END LEFT SIDEBAR -->',1,'2024-02-02 16:48:47',NULL,'2025-01-24 14:14:36',NULL,NULL,'other','',NULL,'','',NULL,'','',0,NULL,NULL),
(199,38,'terminos-y-condiciones-de-uso_vendedores-de-modulos','','Términos y condiciones de uso - Vendedores de módulos','Términos y condiciones de uso - Vendedores de módulos','','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                    	<h2>Términos y condiciones de uso para&nbsp;vendedores de módulos</h2>\n                    	<p>&nbsp;</p>\n                    	<h3>Artículo S1</h3>\n                    	<p>Los productos y módulos proporcionados en DoliStore son enviados por cualquier proveedor con una cuenta en la\n                    		plataforma, sin ningún vínculo con la asociación Dolibarr.</p>\n                    	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">Sólo pueden\n                    		ser publicados los módulos/extensiones liberados bajo una&nbsp;<a\n                    			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"\n                    			href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">approved OSI licence</a>, y compatible\n                    		con la licencia GPL v3+ Dolibarr si el módulo es una obra derivada (por el uso de componentes o API) de\n                    		Dolibarr.</p>\n                    	<h3></h3>\n                    	<h3>Artículo&nbsp;S2</h3>\n                    	<p>El vendedor, previa presentación de una factura a la asociación Dolibarr, podrá recibir los pagos de las compras.\n                    		Recibirá el 80% de las ganancias obtenidas por la asociación. No se pueden reclamar pagos de las compras antes\n                    		de 1 mes de la misma, y si el total a recibir de todas las ventas no supera los 50 euros.</p>\n                    	<p>El pago se puede realizar :</p>\n                    	<p>- O por transferencia SEPA a una cuenta bancaria en EURO.</p>\n                    	<p>- Ya sea mediante pago con tarjeta (el vendedor debe proporcionar la interfaz para permitir el pago)</p>\n                    	<p>- Ya sea mediante pago a través de Paypal (el vendedor debe proporcionar su cuenta de paypal).</p>\n                    	<p></p>\n                    	<h3>Artículo S3</h3>\n                    	<p>El vendedor debe informar en la descripción del producto toda la información requerida, a saber:<br><br>* Una\n                    		descripción breve y significativa sobre el aporte del módulo.<br>* La versión del módulo<br>* El nombre del\n                    		autor, la licencia.<br>* Si se ofrece soporte y si es así, por qué canal. S<span\n                    			style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">i no se\n                    			ofrece soporte, debe indicarse.</span><br>* Versión de Dolibarr con la que es compatible (versión mínima y\n                    		máxima).<br><br>Se puden añadir enlaces para información complementaria, pero sólo en el campo descripción\n                    		larga.<br><br>Si uno de estos puntos no se cumple, o si la versión de Dolibarr es demasiado antigua, la\n                    		asociación se reserva el derecho de eliminar el producto, sin ningún tipo de justificación.</p>\n                    	<p><br> Si el módulo es de pago, el vendedor está obligado a indicar la información de contacto para soporte vía un\n                    		canal válido (e-mail activo, página de soporte en la web del vendedor, etc) así como una descripción en los\n                    		idiomas disponibles (aunque sea un copiar-pegar de la descripción inglesa para los idiomas no soportados). Es\n                    		posible indicar que el soporte solo se ofrece en un solo idioma. No es obligatorio un enlace hacia una demo del\n                    		módulo, aunque es muy recomendable</p>\n                    	<h3 style=\"font-size:12px;font-style:normal;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"></h3>\n                    	<h3 style=\"font-size:12px;font-style:normal;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">Artículo S4\n                    	</h3>\n                    	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">Cuando varios\n                    		módulos sean muy similares y compatibles con la misma versión de Dolibarr, la asociación se reserva el derecho\n                    		de no validar los módulos presentados después del primero, con el fin de evitar el pegado y copiado del módulo\n                    		(posible gracias a la licencia GPL). Si un módulo no se actualiza en el plazo de cuatro meses desde el\n                    		lanzamiento de una nueva versión de Dolibarr, la asociación aceptará que el módulo sea publicado por otro\n                    		vendedor (no siendo el autor original) que lo haya actualizado para poder ser usado en la última versión de\n                    		Dolibarr, a fin de evitar que algunos módulos se encuentren abandonados. Además, la asociación puede desactivar\n                    		sin previo aviso módulos que solo funcionen en versiones antiguas de Dolibarr.</p>\n                    	<p>&nbsp;</p>\n                    	<h3>¿Por qué un pago si el software tiene una licencia de código abierto (GPL, ...)?</h3>\n                    	<p>La mayoría de los productos disponibles en esta tienda son gratuitos y se pueden descargar directamente. Sin\n                    		necesidad de pagar.</p>\n                    	<p>Sin embargo, algunos autores deciden cobrar algo para distribuir sus trabajos. No hay ningún problema para\n                    		conciliar los dos enfoques (Precio por distribuir el código versus licencia Open Source): La Free Software\n                    		Foundation, que ha creado la licencia GNU GPL, una de las licencias más utilizadas para el software de código\n                    		abierto, permite y fomenta esto. Ofrece algunas explicaciones en esta página:<a\n                    			href=\"http://www.gnu.org/philosophy/selling.html\" target=\"_blank\">\n                    			http://www.gnu.org/philosophy/selling.html</a></p>\n                    	<p>&nbsp;</p>\n                    </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 21:55:38',NULL,'2024-05-06 21:56:23',NULL,NULL,'page','es',202,'','',NULL,'','',0,NULL,NULL),
(200,38,'terminos-y-condicones-de-uso','','Términos y condicones de uso','Términos y condicones de uso','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                    	<h2>Términos y condiciones de uso</h2>\n                    	<p>&nbsp;</p>\n                    	<h3>Artículo 1</h3>\n                    	<p>Los productos y módulos proporcionados en DoliStore son enviados por cualquier proveedor con una cuenta en la\n                    		plataforma, sin ningún vínculo con la asociación Dolibarr.</p>\n                    	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">Sólo pueden\n                    		ser publicados los módulos/extensiones liberados bajo una&nbsp;<a\n                    			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"\n                    			href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">approved OSI licence</a>, y compatible\n                    		con la licencia GPL v3+ Dolibarr si el módulo es una obra derivada (por el uso de componentes o API) de\n                    		Dolibarr.</p>\n                    	<h3>Artículo 2</h3>\n                    	<p>El precio de venta e impuestos son fijados por el vendedor. La venta (y su comisión), sin embargo, será validada\n                    		después de un período de un mes después de la compra (con el fin de permitir al comprador interactuar con el\n                    		editor del módulo en caso de problemas). Durante este tiempo, la asociación podrá cancelar cualquier venta por\n                    		cualquier razón y sin necesidad de prevenir al vendedor (si ese fuera el caso, aparecería en las estadísticas de\n                    		la cónsola de administración del vendedor). La asociación Dolibarr se queda con el 20% de la venta para\n                    		garantizar los gastos de gestión, gastos de cancelación, o transferencia bancaria. Las cantidades sobrantes se\n                    		utilizarán para financiar el desarrollo de Dolibarr ERP/CRM.</p>\n                    	<h3>Artículo 3</h3>\n                    	<p>El comprador no puede reclamar nada a la asociación Dolibarr, incluso si el producto adquirido no funciona\n                    		correctamente. La asociación Dolibarr no realiza pruebas de calidad de los productos disponibles en la tienda.\n                    		Toda ayuda debe ser solicitada por el comprador a través del canal de ayuda indicada en la descripción del\n                    		producto, si el proveedor la ofrece (información obligatoria en la descripción del producto). La Asociación se\n                    		reserva el derecho de inhabilitar un módulo si causa demasiadas quejas.</p>\n                    	<h3>Artículo 4</h3>\n                    	<p>Una vez se reciba el pago, el comprador puede descargar los archivos de los módulos/productos pedidos desde su\n                    		cuenta, a través de \"Mis pedidos\" o desde un enlace disponible en el correo electrónico recibido por el\n                    		comprador una vez que su pago sea validado.<br><br> El producto puede ser descargado desde el sitio web\n                    		DoliStore durante una duración de 1 año.</p>\n                    	<h3>¿Por qué un pago si el software tiene una licencia de código abierto (GPL, ...)?</h3>\n                    	<p>La mayoría de los productos disponibles en esta tienda son gratuitos y se pueden descargar directamente. Sin\n                    		necesidad de pagar.</p>\n                    	<p>Sin embargo, algunos autores deciden cobrar algo para distribuir sus trabajos. No hay ningún problema para\n                    		conciliar los dos enfoques (Precio por distribuir el código versus licencia Open Source): La Free Software\n                    		Foundation, que ha creado la licencia GNU GPL, una de las licencias más utilizadas para el software de código\n                    		abierto, permite y fomenta esto. Ofrece algunas explicaciones en esta página:<a\n                    			href=\"http://www.gnu.org/philosophy/selling.html\" target=\"_blank\">\n                    			http://www.gnu.org/philosophy/selling.html</a></p>\n                    	<p>&nbsp;</p>\n                    </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 21:46:00',NULL,'2024-05-06 21:46:49',NULL,NULL,'page','es',201,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(201,38,'terms-and-conditions','','Terms and conditions of use','Terms and conditions','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                	<h2>Terms and conditions of use</h2>\n                	<p></p>\n                	<p>&nbsp;</p>\n                	<h3>Rule 1</h3>\n                	<p>Products and modules provided on DoliStore are submitted by any supplier with an account on platform, with no\n                		need to be affiliated to the Dolibarr foundation (this may change in future).</p>\n                	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">Only\n                			modules published under an&nbsp;</span><a\n                			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"\n                			href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">approved OSI licence</a>&nbsp;can be\n                		published. Also if your module is a derivative work of Dolibarr&nbsp;(use Dolibarr components, files or API,\n                		this is the case for 99% of modules)&nbsp;your licence must be c<span\n                			style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\"><span\n                				style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">ompatible\n                				with the GPL v3+ license of Dolibarr</span>. If license is not provided, you accept to have your module\n                			being distributed under the GPL v3+ licence.</span></p>\n                	<p></p>\n                	<h3>Rule 2</h3>\n                	<p><span>The reference selling price is set by the seller.</span>&nbsp; Any sell is however completely validated\n                		only after a delay of 1 month, after the buying date. During this delay, the foundation can cancel transaction\n                		for any reason and without notifying the seller (if this occurs, seller will see it into its statistics panel\n                		into its seller dashboard area).&nbsp;</p>\n                	<p>The selling price is a reference price without VAT and not the final sale price. At this price, a VAT is added\n                		(that the Dolibarr foundation pays to government). In addition, when selling on DoliStore, vendors agree that\n                		sales made to members of the Dolibarr foundation are done through a reduction defined by the foundation (20%).\n                		The real final purchase price of each sale, appears, excluding VAT, in the detailed sales statistics.</p>\n                	<p>The foundation keep 20% of amount to pay bank charges, resiliation cost and management fees. Remain money will be\n                		used to help the promotion of Dolibarr ERP &amp; CRM.</p>\n                	<p>&nbsp;</p>\n                	<h3>Rule 3</h3>\n                	<p>Once payment is received, the buyer can download ordered modules/products files, from its account are \"My\n                		orders\", or from a link available in email received by buyer once its payment is validated.</p>\n                	<p>The product can be downloaded from DoliStore web site during a duration of 1 year after payment.</p>\n                	<p>&nbsp;</p>\n                	<h3>Rule 4</h3>\n                	<p>The buyer cannot in any case hold responsible the association Dolibarr as for the good functioning or not of the\n                		acquired product, the quality of the documentation which accompanies it or not, nor with the requirement of the\n                		prerequisites necessary to use the product . The association does not ensure quality control of the modules\n                		(except on the form of the package). The association reserves the right to de-validate a module if it causes too\n                		many complaints.</p>\n                	<p>In the event of a problem installing or using the module purchased, any assistance must be sought by the buyer\n                		from the module editor directly, via the support channel described in the product description, if the supplier\n                		provides, information mandatory in the product description (if this information is not available, please alert\n                		the association).</p>\n                	<p>The buyer may possibly obtain a refund under the following conditions:</p>\n                	<p>- The buyer must appear within 1 month after the date of purchase</p>\n                	<p>- The buyer must have first tried to resolve the problem via discussions with the module editor. The emails\n                		exchanged with this money can be sent to the association for proof (to dolistore@dolibarr.org). A period\n                		necessary to allow these exchanges between the buyer and the publisher will be required by the association in\n                		order to maximize the chances of amicable resolutions before the initiation of the cancellation of the sale and\n                		the refund.</p>\n                	<p>&nbsp;&nbsp;</p>\n                	<h3>When and why a payment if software has an Open-Source Licence (GPL, ...) ?</h3>\n                	<p>Most products available on this market place are free of charge and can be downloaded directly from this market\n                		place. No payment is required in this case.</p>\n                	<p>However, some authors decide to charge something to distribute their works. There is no problem to conciliate\n                		both approaches (Price to distribute code versus OpenSource licence): The<strong> Free Software\n                			Foundation</strong>, that has created the GNU GPL Licence, one of the most used licence for OpenSource\n                		software, allows and encourages this, and provides some explanations on this page :<br><a\n                			href=\"http://www.gnu.org/philosophy/selling.html\"\n                			target=\"_blank\">http://www.gnu.org/philosophy/selling.html</a></p>\n                </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-02-02 16:48:47',NULL,'2024-05-06 21:14:02',NULL,NULL,'page','en',NULL,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(202,38,'terms-and-conditions-of-use-module-providers','','Terms and conditions of use - Module providers','','','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                	<h2>Terms and conditions of use for module&nbsp;providers</h2>\n                	<p></p>\n                	<p>&nbsp;</p>\n                	<h3>Rule S1</h3>\n                	<p>Products and modules provided on DoliStore are submitted by any supplier with an account on platform, with no\n                		need to be affiliated to the Dolibarr foundation (this may change in future).</p>\n                	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">Only\n                			modules published under an&nbsp;</span><a\n                			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"\n                			href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">approved OSI licence</a>&nbsp;can be\n                		published. Also if your module is a derivative work of Dolibarr&nbsp;(use Dolibarr components, files or API,\n                		this is the case for 99% of modules)&nbsp;your licence must be c<span\n                			style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\"><span\n                				style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">ompatible\n                				with the GPL v3+ license of Dolibarr</span>. If license is not provided, you accept to have your module\n                			being distributed under the GPL v3+ licence.</span></p>\n                	<p></p>\n                	<h3>Rule S2</h3>\n                	<p>The seller can send an invoice to the Dolibarr foundation, to received payments of its purchased module/products,\n                		1 month after the purchase (this laps of time is used to cancel the payment at the buyer request). The seller\n                		will receive 80% of gains made by the foundation.</p>\n                	<p>A seller can claim money only if total amount is more or equals to 50 euros (for Europe), or 100 euros (for non\n                		euro countries). Requests are limited to 1 per month maximum.</p>\n                	<p>Payment can be made:</p>\n                	<p>- by SEPA transfer to a bank account in EURO.</p>\n                	<p>- Either via card payment (the seller must then provide the interface to allow payment)</p>\n                	<p>- Either by payment via Paypal (the seller must then provide his Paypal account).</p>\n                	<p>&nbsp;</p>\n                	<h3>Rule S3</h3>\n                	<p>A) The seller must provide into product description, all mandatory information, this means at least:</p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">* a short\n                		description.</p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">* module\n                		version</p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"><span\n                			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">* name of\n                			author and licence.</span></p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"><span\n                			style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">* one\n                			photo (one required, but several recommended)</span></p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">* if help\n                		support is available or not, if yes, how. I<span\n                			style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">f no\n                			support is provided, this must appears.</span></p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"></p>\n                	<p>If the module is not free, a valid support link is mandatory. A description of the module is required for all\n                		langues available even if it\'s a copy past of English description for all languages. In the support message, the\n                		seller can say that the support language is only English for exemple. A link to a demo version is not mandatory\n                		but fairly welcome.</p>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\"></p>\n                	<p>* the Dolibarr version the module is compatible with (both minimum and maximum version must be provided. Must be\n                		values with format x.y.z, \"dev\" is not allowed as a value since it is not a version and * is allowed only for\n                		third part of version, like x.y.*).</p>\n                	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">B) Rules\n                			on links or mention of other web sites</span></p>\n                	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">Additional\n                			information links can be included, but only in the long description field. The number of external links is\n                			limited to 10. Links can refer to an external web site that provide one of the following service\n                			(and&nbsp;exclusively services into this list):<strong> demo, documentation, contact, forums, issue tracker,\n                				code sources or social networks</strong> (so links to another downloadable file or to another market\n                			place is not allowed for example. A link to a not found or 404 error page are also not allowed). </span></p>\n                	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">In\n                			addition, these links must not point to a url or an url leading after redirection to a site whose domain\n                			name does not respect the rules for using the name \"Dolibarr\" or \"Dolistore\" defined&nbsp;<a\n                				href=\"https://wiki.dolibarr.org/index.php/Rules_to_use_the_brand_name_%22Dolibarr%22\">on this\n                				page</a>.&nbsp;If the site or page to which the link points has sub-sections where the same module is\n                			also for sale, the price must not be lower then the one on Dolistore.</span></p>\n                	<p>You can sell your module from any other platform at any price, but it is not allowed to put<strong> on the\n                			dolistore product descriptions or notes</strong>, some links or mentions to other \"selling\" platforms where\n                		your product can also be available. If such links are found somewhere in module\'s description card, the\n                		foundation can remove it from description or completely disable the module or the seller account.</p>\n                	<p>C) Rules on packaging</p>\n                	<p>All module that do not respect conditions explain here : <a\n                			href=\"http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Rules\">https://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Rules</a>\n                		will not be validated and remove from DoliStore</p>\n                	<p>D) Disabling modules</p>\n                	<p>If something is wrong, or if Dolibarr compatible version is too old, the Dolibarr foundation can&nbsp;suspend the\n                		entry without any other reason.&nbsp;If the same module is found to be deactivated 3 times following a violation\n                		of the previous rules, the module will either be permanently deactivated, or kept but the price will be forced\n                		to zero (in accordance with the right to distribute the module for free, attributed by its GPL\n                		license).&nbsp;Likewise if the author of a module does not respect the rules of use of the Dolibarr or DoliStore\n                		brand (See <a\n                			href=\"Likewise%20if%20the%20author%20of%20a%20module%20does%20not%20respect%20the%20rules%20of%20use%20of%20the%20Dolibarr%20or%20DoliStore%20brand%20(See%20https%3A//wiki.dolibarr.org/index.php?title=R%C3%A8gles_d%27utilisation_du_nom_ou_de_la_marque_%25%2022Dolibarr%22_(ou_%22DoliStore%22),%20its%20modules%20may%20also%20be%20withdrawn%20from%20sale%20or%20kept%20but%20with%20a%20price%20forced%20to%20zero%20(in%20accordance%20with%20the%20right%20to%20distribute%20the%20module%20for%20free,%20granted%20by%20its%20GPL%20license).\">here</a>),\n                		its modules may also be withdrawn from sale or kept but with a price forced to zero (in accordance with the\n                		right to distribute the module for free, granted by its GPL license).&nbsp;</p>\n                	<p></p>\n                	<h3>Rule S4</h3>\n                	<p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">When several\n                		modules, compatible with same version of Dolibarr, are too similar, the foundation reserves the right not to\n                		validate the modules submitted after the first, in order to avoid copying and pasting module (possible by the\n                		GPL). If a module is not updated within 4 months after the release of a new version of Dolibarr, the foundation\n                		will accept the module is published by another vendor (than o<span\n                			style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">riginal\n                			author) that had ported the module in the recent version of Dolibarr, in order to avoid that some modules\n                			are abandoned. Furthermore, the association may, without warning, disable modules on too old version of\n                			Dolibarr.</span></p>\n                	<p></p>\n                	\n                	<!--\n                	<h3>Rule S5 - How to appear on home page</h3>\n                	<p>There is some conditions to appear on home page. Modules must match all this rules:</p>\n                	<p>- with a link to documentation</p>\n                	<p>- editor of module must be a Dolibarr Preferred Partner</p>\n                	<p>- maximum 10 modules by partner</p>\n                	<p>- only the one compatible with last stable Dolibarr version</p>\n                	<p>- only one version per module (the first one that has suggested the first module)</p>\n                	<p>- an exception can be done for free modules that are really interesting</p>\n                	<p>Note: rules will be modified to be more strict in the future, to reduce the number of modules on the home page.\n                	</p>\n                	<p>If your modules match all this conditions, you can send a list of your module name/id to dolistore@dolibarr.org\n                		to ask to be on home page.</p>\n                	<p></p>\n                	-->\n                	\n                	\n                	<h3>When and why a payment if software has an Open-Source Licence (GPL, ...) ?</h3>\n                	<p>A lot of products available on this market place are free of charge and can be downloaded directly from this market\n                		place. No payment is required in this case.</p>\n                	<p>However, some authors decide to charge something to distribute their works. There is no problem to conciliate\n                		both approaches (Price to distribute code versus OpenSource licence): The<strong> Free Software\n                			Foundation</strong>, that has created the GNU GPL Licence, one of the most used licence for OpenSource\n                		software, allows and encourages this, and provides some explanations on this page :<br><a\n                			href=\"http://www.gnu.org/philosophy/selling.html\"\n                			target=\"_blank\">http://www.gnu.org/philosophy/selling.html</a></p>\n                </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-04-19 10:28:36',NULL,'2025-01-23 17:10:57',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),
(203,38,'unser-kontakt','','Unser Kontakt','Unser Kontakt','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<script src=\"/document.php?modulepart=medias&file=js/tools.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n<script src=\"/document.php?modulepart=medias&file=js/treeManagement.js\"></script>\n<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n        <!--  Breadcrumb  -->\n		<div class=\"breadcrumb clearfix\">\n			<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n			<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n		</div>\n		<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n            \n            <section id=\"contact_us_section\" contenteditable=\"true\">\n			<div class=\"rte\">\n              <h2>Kontaktiere uns</h2>\n              <p>Die Dolibarr Foundation bietet diese DoliStore Plattform an, um Anbietern und Anwendern zu helfen, Module oder Erweiterungen für die <a href=\"https://www.dolibarr.de\" target=\"_blank\">Dolibarr ERP/CRM</a>&nbsp;Softwarelösung zu finden. Es wird nur dieser Service angeboten, für die gekauften Produkte wird keine Garantie von der Foundation zur Verfügung gestellt. Die ordnungsgemäße Funktionalität der Produkte gewährleistet der \"jeweilige Softwareentwickler\" (#1). </p>\n              <p></p>\n              <p>Falls Probleme mit einem der Module auftreten sollten, gehen Sie bitte auf die Modulseite und kontaktieren Sie den Autoren wie in der Modulbeschreibung vorgesehen. <br>Es können nur die Autoren des Moduls helfen. Sie sollten immer wenn Sie Fragen oder Probleme haben, diese zuerst kontaktieren. </p>\n              <p>Wenn nach dem Kontakt mit dem Autoren Ihr Problem noch nicht gelöst wurde, bitten wir Sie die Dolibarr Foundation mit den folgenden Informationen (E-Mail: dolistore@dolibarr.org) zu informieren:</p>\n              <p>- die Art des Problems (Modulnamen, Modul-Version, Ihre Version von Dolibarr und eine Beschreibung des Problems)</p>\n              <p>- Eine Zusammenfassung des Austauschs den&nbsp;Sie mit dem Autor hatten (Kopie der gesendeten/empfangen E-Mails)</p>\n              <p>- wenn keine Antwort, das Datum Ihrer&nbsp;letzten Anfrage ( <span class=\"short_text\" id=\"result_box\" lang=\"de\" xml:lang=\"de\">\n                  <span>muss&nbsp;länger als </span>\n                  <span>7 Tage her sein</span>\n                </span>\n                <span class=\"trans-verified-button goog-toolbar-button\" id=\"t-served-community-button\">\n                  <span class=\"jfk-button-img\"></span>\n                </span>)\n              </p>\n              <p>\n                <span lang=\"de\" xml:lang=\"de\">\n                  <span>So</span>\n                  <span>werden wir</span>\n                  <span>die Schritte wie in den&nbsp; <a href=\"/de/content/3-nutzungs_bedingungen_dolistore\">Nutzungsbedingungen</a> beschrieben&nbsp; </span>\n                  <span>durchführen: Modul Deaktivierung, Rückabwicklung ...</span>\n                </span>\n              </p>\n              <p>\n                <span lang=\"de\" xml:lang=\"de\">\n                  <span>\n                    <span>Bedeutet ein Dritter, der Erweiterungen für Benutzer entwickelt</span>\n                  </span>\n                </span>\n              </p>\n              <p>\n                <span lang=\"de\" xml:lang=\"de\">\n                  <span>\n                    <span></span>\n                  </span>\n                </span>\n              </p>\n              <p>\n                <span lang=\"de\" xml:lang=\"de\">\n                  <span>\n                    <span>#1 <strong>\"jeweilige Softwareentwickler\"</strong> bedeutet eine Drittanbieter der&nbsp;für Benutzer Erweiterungen entwickelt </span>\n                  </span>\n                </span>\n              </p>\n            </div>\n			</section>\n\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 22:08:30',NULL,'2024-05-06 22:09:15',NULL,NULL,'page','de',164,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(204,38,'unsere-nutzungsbedingungen','','Unsere Nutzungsbedingungen','Unsere Nutzungsbedingungen','shop, plugins, modules, addons, erp, crm, market, store, sell, product, dolibarr','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                    	<h2><span xml:lang=\"de\" lang=\"de\">Unsere Nutzungsbedingungen</span></h2>\n                    	<p>&nbsp;</p>\n                    	<h3>Regel Nr. 1</h3>\n                    	<p>Die auf der Dolistore Plattform verfügbaren Artikel, wurden mit dem Konto des jeweiligen Anbieters, ohne eine\n                    		Verbindung zur Dolibarr Foundation,&nbsp;selbstständig auf diese Plattform übertragen (Änderungen vorbehalten).\n                    		<span>Der Käufer&nbsp;verpflichtet sich dem Vertrauensverhältnis von Lieferanten-Kunden <span>gegenüber dem\n                    				Verkäufer.</span><br class=\"Apple-interchange-newline\"></span></p>\n                    	<p>Es können nur Module veröffentlicht werden, die unter einer <a\n                    			href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">anerkannten OSI-Lizenz\n                    		</a>veröffentlicht wurden. Darüber hinaus gilt, wenn das Modul eine Abwandlung(durch verwendete Komponenten oder\n                    		API) von Dolibarr ist, muss es mit der GPL Lizenz von Dolibarr kompatibel sein.</p>\n                    	<h3>Regel Nr. 2</h3>\n                    	<p>Der Verkaufspreis wird vom Verkäufer festgelegt. Der Verkauf (und die Provision) sind jedoch noch wirklich\n                    		bestätigt, erst &nbsp;nach einem Zeitraum von 1 Monat nach dem Kauf (um den Käufer zu ermöglichen, mit dem\n                    		Modul-Hersteller bei Schwierigkeiten zu interagieren) ist der Verkauf bestätigt. Während dieser Zeit kann die\n                    		Foundation&nbsp;jeden Verkauf aus irgendeinem Grunde kündigen ohne den Verkäufer zu kontaktieren&nbsp;(wenn dies\n                    		der Fall wäre, würde dies in der Statistik der Verkäufer-Management-Konsole erscheinen).</p>\n                    	<p>Der Verkaufspreis ist ein Referenzpreis ohne Mehrwertsteuer und nicht der endgültige Verkaufspreis. Zu diesem\n                    		Preis wird eine Mehrwertsteuer hinzugefügt (welche die Dolibarr-Foundation an die Staatskasse\n                    		zahlt).&nbsp;<span>Der reale Nettopreis erscheint in der Detail Verkaufs-Statistik.</span></p>\n                    	<p>Die Foundation erhält 20% des&nbsp;Verkaufspreises, um Bankgebühren, Entschädigungskosten und Verwaltungsgebühren\n                    		zu zahlen. Das verbleibendes Geld wird verwendet, um die Weiterentwicklung von Dolibarr ERP &amp; CRM zu\n                    		unterstützen.</p>\n                    	<h3>Regel Nr. 3</h3>\n                    	<p>Sobald die Zahlung eingegangen ist, kann der Käufer sofort die bestellten Artikel laden, entweder von ihren\n                    		Konten Raum „Meine Bestellungen“ oder über einen Link per E-Mail nach der Validierung der Zahlung empfangen.</p>\n                    	<p>L\'acheteur ne peut en aucun cas tenir pour responsable l\'association Dolibarr quant au bon fonctionnement ou non\n                    		du produit aquis, à la qualité de la documentation qui l\'accompagne ou non, ni à l\'exigence des prérequis\n                    		nécessaires pour utiliser le produit. L\'association n\'assure pas de contrôle qualité des modules (si ce n\'est\n                    		sur la forme du package). Toute aide doit être sollicitée par l\'acheteur via le canal d\'assistance décrit dans\n                    		la description du produit, si le fournisseur en fournit (information obligatoire dans la description du\n                    		produit). L\'association se réserve le droit de dévalider un module si celui-ci occasionne trop de réclamations.\n                    	</p>\n                    	<p>Le fichier uploadé pour téléchargement doit avoir un packaging soumis aux règles définies sur la page&nbsp;<a\n                    			style=\"font-size:12px;\"\n                    			href=\"http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles\">http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles</a>\n                    	</p>\n                    	<h3>Regel Nr. 4</h3>\n                    	<p>Sobald die Zahlung eingegangen ist, kann der Käufer die bestellten Module/Produkte herunterladen, entweder in\n                    		seinem Kontobereich „Meine Bestellungen“ oder über einen Link, den er nach Bestätigung seiner Zahlung per E-Mail\n                    		erhält.</p>\n                    	<p>Das Produkt kann für einen Zeitraum von 1 Jahr ab Zahlungsdatum auf der DoliStore-Plattform heruntergeladen\n                    		werden.</p>\n                    	<h3>Wann und weshalb bezahlen, wenn die Software eine Open Source (GPL, ...) ist?</h3>\n                    	<p><span xml:lang=\"de\" lang=\"de\"><span><span id=\"noHighlight_0.5541014785804147\">Einige Produkte die auf dem\n                    					Marktplatz verfügbar sind, sind kostenlos und können direkt von Ihrem Profil heruntergeladen werden.\n                    					In diesem Fall ist keine Bezahlung erforderlich.</span></span><span></span></span></p>\n                    	<p>Einige Autoren beschließen jedoch, etwas zu berechnen, für ihre Arbeit. Es gibt kein Problem, die beiden Ansätze\n                    		bei freier Software widersprechen sich nicht (Preis für die Autoren für den Quellcode einer OpenSource Lizenz):\n                    	</p>\n                    	<p>Der Begriff \"freie Software\" kann sich laut&nbsp;Definition entweder auf die Freiheit oder auf den Preis\n                    		beziehen. Auf der&nbsp;folgenden Seite der&nbsp;Free Software&nbsp;Foundation können Sie dies gerne\n                    		nachlesen:<br><a href=\"http://www.gnu.org/philosophy/selling.de.html\"\n                    			target=\"_blank\">http://www.gnu.org/philosophy/selling.de.html</a></p>\n                    </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 21:49:13',NULL,'2024-05-06 21:49:57',NULL,NULL,'page','de',201,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(205,38,'unsere-nutzungsbedingungen_modulverkaufer','','Unsere Nutzungsbedingungen - Modulverkäufer','Unsere Nutzungsbedingungen - Modulverkäufer','','<?php // BEGIN PHP\nrequire_once DOL_DOCUMENT_ROOT.\'/categories/class/categorie.class.php\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/lib/categories.lib.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP ?> <html lang=\"en\">\n  \n  <!-- File generated by Dolibarr website module editor -->\n  <body id=\"cms\" class=\"bodywebsite cms cms-2 cms-legal-notice-about-us hide-right-column lang_en\">\n    <div id=\"page\">\n      <div class=\"header-container\">\n        <?php includeContainer(\'header\'); ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\n\n			<!--  Breadcrumb  -->\n			<div class=\"breadcrumb clearfix\">\n				<a class=\"home\" href=\"index.php\" title=\"Return to Home\"><i class=\"icon-home\"></i></a>\n				<span class=\"navigation-pipe\">&gt;</span> <?php print $websitepage->title; ?>\n			</div>\n			<!--  Breadcrumb  -->\n        \n\n\n\n\n          <div id=\"slider_row\" class=\"row\">\n            <div id=\"top_column\" class=\"center_column col-xs-12 col-sm-12\"></div>\n          </div>\n          <div class=\"row\">\n            <!-- include lefet sidebar container -->           \n            <?php includeContainer(\'sidebar\'); ?>\n\n            <div id=\"center_column\" class=\"center_column col-xs-12 col-sm-9\">\n              <div class=\"clearfix\">\n                <section id=\"Terms_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                      <h2>Unsere Nutzungsbedingungen - Modulverkäufer</h2>\n                      <p>&nbsp;</p>\n                      <h3>Regel Nr. S1</h3>\n                      <p>Die auf der Dolistore Plattform verfügbaren Artikel, wurden mit dem Konto des jeweiligen Anbieters, ohne eine Verbindung zur Dolibarr Foundation,&nbsp;selbstständig auf diese Plattform übertragen (Änderungen vorbehalten). <span>Der Käufer&nbsp;verpflichtet sich dem Vertrauensverhältnis von Lieferanten-Kunden <span>gegenüber dem Verkäufer.</span>\n                          <br class=\"Apple-interchange-newline\">\n                        </span>\n                      </p>\n                      <p>Es können nur Module veröffentlicht werden, die unter einer <a href=\"https://opensource.org/licenses/alphabetical\" target=\"_blank\">anerkannten OSI-Lizenz </a>veröffentlicht wurden. Darüber hinaus gilt, wenn das Modul eine Abwandlung(durch verwendete Komponenten oder API) von Dolibarr ist, muss es mit der GPL Lizenz von Dolibarr kompatibel sein. </p>\n                      <h3></h3>\n                      <h3>Regel Nr. S2</h3>\n                      <p>Der Autor kann eine Rechnung an die Dolibarr Foundation senden, um die Zahlungen der verkauften Module/Produkte auf der Grundlage von 80% der Einnahmen zu erhalten.&nbsp; Der Anspruch auf eine Auszahlung beginnt einen Monat nach dem Verkauf, ist 1 Mal pro Monat möglich, sofern der Gesamtbetrag 50 Euro (für Länder mit dem Euro), 100 Euro für andere Währungen übersteigt.</p>\n                      <p>Die Zahlung kann erfolgen:</p>\n                      <p>- Oder per SEPA-Überweisung auf ein Bankkonto in EURO. <br>- Entweder per Kartenzahlung (der Verkäufer muss dann die Schnittstelle bereitstellen, um die Zahlung zu ermöglichen) <br>- Entweder per Zahlung per Paypal (der Verkäufer muss dann sein Paypal-Konto angeben). </p>\n                      <p></p>\n                      <h3>Regel Nr. S3</h3>\n                      <p>\n                        <span id=\"result_box\" xml:lang=\"de\" lang=\"de\">\n                          <span>Der Verkäufer muss</span>\n                          <span>in</span>\n                          <span>der Beschreibung</span>\n                          <span>des Produkts</span> folgende <span> erforderlichen Informationen </span>\n                          <span></span>angeben <span>:</span>\n                        </span>\n                      </p>\n                      <p>* <span xml:lang=\"de\" lang=\"de\">kurze aussagekräftige Beschreibung des Moduls</span>\n                      </p>\n                      <p>* <span xml:lang=\"de\" lang=\"de\">die Modulversion</span>\n                      </p>\n                      <p>* <span xml:lang=\"de\" lang=\"de\">Name des Autors und der Lizenz</span>. </p>\n                      <p>* Art des angebotenen <span xml:lang=\"de\" lang=\"de\">Support der zur Verfügung steht. Wenn keine Unterstützung vorgesehen ist, sollte dies auch angegeben werden.</span>\n                      </p>\n                      <p>* <span xml:lang=\"de\" lang=\"de\">die Dolibarr Version, für die es kompatibel ist (die minimale und maximale Version muss zur Verfügung angegeben werden)</span>\n                      </p>\n                      <p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">\n                        <span xml:lang=\"de\" lang=\"de\">\n                          <span>Weitere</span>\n                          <span>Informationen</span> ( <span>Links)</span>\n                          <span>können</span>\n                          <span>integriert werden (nu</span>\n                          <span>r</span>\n                          <span>in dem langen</span>\n                          <span>Beschreibungsfeld)</span>\n                          <span>.</span>\n                        </span>\n                      </p>\n                      <p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">\n                        <span xml:lang=\"de\" lang=\"de\"> Wenn einer dieser Punkte nicht erfüllt ist, oder wenn die Version von Dolibarr zu alt ist, behält sich die Foundation das Recht vor, das Produkt ohne weitere Begründung zu entfernen</span>\n                      </p>\n                      <p style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">\n                        <span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">Si le module est payant, le vendeur doit obligatoirement mettre les informations de contact de support via un canal valide (mail fonctionnel, page de support sur le site du vendeur,...) ainsi qu\'une description dans les langues disponibles (même si c\'est un copier-coller de la description anglaise pour les langues non supportées par exemple). Il est possible de préciser que le support n\'est valable que dans une seule langue. Un lien vers un site de démonstration n\'est pas obligatoire mais vivement conseillé. <br>\n                        </span>\n                      </p>\n                      <p>\n                        <span id=\"noHighlight_0.74518527252596\">Wenn die hier beschriebenen Bedingungen:</span>\n                        <a href=\"http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles\">http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles</a>\n                        <span id=\"noHighlight_0.5030463990995454\">nicht gültig <span>sind</span> wird das Modul nicht bestätigt oder es wird aus dem Verkauf genommen. </span>\n                      </p>\n                      <p></p>\n                      <h3>Regel Nr. S4</h3>\n                      <p>\n                        <span id=\"noHighlight_0.11652391912715276\">Wenn mehrere Module (die mit derselben Version von Dolibarr kompatibel sind) zu identisch sind, behält sich die Foundation das Recht vor, die nach dem ersten eingereichten Module nicht anzuerkennen, um zu vermeiden das Module kopiert und eingefügt (möglich durch das GPL-Lizenz) werden. </span>\n                        <span>\n                          <span xml:lang=\"de\" lang=\"de\">\n                            <span>Wenn ein Modul</span>\n                            <span>innerhalb von 4 Monaten</span>\n                            <span>nach der Veröffentlichung</span>\n                            <span>einer neuen Dolibarr-Version</span>\n                            <span>nicht aktualisiert wird,</span>\n                            <span>wird die Foundation</span>\n                            <span>das Modul</span>\n                            <span>von dem anderen</span>\n                            <span>Autoren</span>\n                            <span>(nicht dem </span>\n                            <span>ursprüngliche Autor</span>\n                            <span>)</span>\n                            <span>\n                              <span xml:lang=\"de\" lang=\"de\">\n                                <span>akzeptieren</span>\n                              </span>\n                            </span>\n                            <span>\n                              <span>\n                                <span xml:lang=\"de\" lang=\"de\">\n                                  <span>\n                                    <span id=\"noHighlight_0.43782977414815116\">um zu vermeiden, dass einige Module aufgegeben werden.&nbsp; <span xml:lang=\"de\" lang=\"de\">\n                                        <span>\n                                          <span id=\"noHighlight_0.47251528887691496\">Außerdem kann die Foundation ohne Vorwarnung Module die auf eine zu alten Dolibarr Version basieren deaktivieren.</span>\n                                        </span>\n                                      </span>\n                                    </span>\n                                  </span>\n                                </span>\n                              </span>\n                            </span>\n                          </span>\n                        </span>\n                      </p>\n                      <h3>Wann und weshalb bezahlen, wenn die Software eine Open Source (GPL, ...) ist?</h3>\n                      <p>\n                        <span xml:lang=\"de\" lang=\"de\">\n                          <span>\n                            <span id=\"noHighlight_0.5541014785804147\">Einige Produkte die auf dem Marktplatz verfügbar sind, sind kostenlos und können direkt von Ihrem Profil heruntergeladen werden. In diesem Fall ist keine Bezahlung erforderlich.</span>\n                          </span>\n                          <span></span>\n                        </span>\n                      </p>\n                      <p>Einige Autoren beschließen jedoch, etwas zu berechnen, für ihre Arbeit. Es gibt kein Problem, die beiden Ansätze bei freier Software widersprechen sich nicht (Preis für die Autoren für den Quellcode einer OpenSource Lizenz):</p>\n                      <p>Der Begriff \"freie Software\" kann sich laut&nbsp;Definition entweder auf die Freiheit oder auf den Preis beziehen. Auf der&nbsp;folgenden Seite der&nbsp;Free Software&nbsp;Foundation können Sie dies gerne nachlesen: <br>\n                        <a href=\"http://www.gnu.org/philosophy/selling.de.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.de.html</a>\n                      </p>\n                    </div>\n                </section>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n      <!-- .columns-container -->\n      <div class=\"footer-container\">\n        <?php includeContainer(\'footer\'); ?>\n      </div>\n    </div>\n  </body>\n</html>',1,'2024-05-06 21:58:22',NULL,'2024-05-06 22:04:35',NULL,NULL,'page','de',202,'','',NULL,'','',0,NULL,NULL),
(206,38,'welcome-message','','welcome message','welcome message','','<section id=\"welcome_section\" contenteditable=\"true\">\n  <div id=\"editorial_block_center\" class=\"editorial_block\">\n    <a href=\"https://www.dolibarr.org\" title=\"\">\n      <img class=\"img-responsive\"\n        src=\"viewimage.php?modulepart=medias&entity=1&file=image/test/img/dolibarr_logo.png\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\">\n      <br>\n      <p>This web site is the official market place to find addons and plugins for the <a\n          href=\"https://www.dolibarr.org\" target=\"_blank\">Dolibarr ERP CRM</a> project. </p>\n      <ul>\n        <li>\n          <span style=\"color: #a45931;\">\n            <strong>If you are a Dolibarr user</strong>: </span>\n        </li>\n      </ul>\n      <p>You can search for additional features and find different modules or extensions. Browse the categories to find\n        your extension or use the search form at the top of the page ...</p>\n      <p>Some extensions/modules are free, some are paid (Members of the <a href=\"https://asso.dolibarr.org\">Dolibarr\n          foundation</a> benefits a 20% discount if the request is made to the association once account has been created\n        on DoliStore. Buying product must be done after the request has been processed to see the 20% discounts on all\n        prices) </p>\n      <ul>\n        <li>\n          <span style=\"color: #a45931;\">\n            <strong>If you are a developer :</strong>\n          </span>\n        </li>\n      </ul>\n      <p>You can submit your own modules, you choose the price (free is better). For this, just create an account and\n        submit your module from left menu.</p>\n      <p></p>\n    </div>\n  </div>\n</section>',1,'2024-02-02 16:48:47',NULL,'2025-01-14 00:38:49',NULL,NULL,'banner','en',NULL,'','',NULL,'','',0,NULL,NULL),
(207,38,'willkommensnachricht','','Willkommensnachricht','Willkommensnachricht','','<section id=\"welcome_section\" contenteditable=\"true\">\n  <div id=\"editorial_block_center\" class=\"editorial_block\">\n    <a href=\"https://www.dolibarr.org\" title=\"\">\n      <img class=\"img-responsive\"\n        src=\"viewimage.php?modulepart=medias&entity=1&file=image/test/img/dolibarr_logo.png\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\">\n        <br>\n        <p>Diese Seite ist der offizielle Marktplatz für Module und PlugIns für das&nbsp;<a href=\"https://www.dolibarr.org\" target=\"_blank\">Dolibarr ERP/CRM</a> Projekt.</p>\n        <ul>\n            <li><span style=\"color: #a45931;\"><strong>Wenn Sie Dolibarr Benutzer sind</strong></span> :</li>\n        </ul>\n        <p>Können Sie für zusätzliche Funktionen suchen und hier verschiedene Module oder PlugIns für ihr Dolibarr finden. Bei Ihrer Suche nach Ihren Erweiterungen, helfen Ihnen die Kategorien in der linken Navigation oder nutzen Sie das Suchformular in der Mitte des Kopfbereiches dieser Webseite ...</p>\n        <p>Manche Erweiterungen/Module sind kostenlos, manche müssen bezahlt werden (Mitglieder der&nbsp;<a title=\"Dolibarr foundation\" href=\"https://asso.dolibarr.org\" target=\"_blank\">Dolibarr Stiftung</a> profitieren mit 20 % Rabatt wenn ein Antrag an den Verband gestellt wurde und bereits ein Konto im dolistore erstellt wurde.)</p>\n        <ul>\n            <li><strong><span style=\"color: #a45931;\">Wenn Sie Dolibarr Software Entwickler sind:</span></strong></li>\n        </ul>\n        <p>Sie können Ihre eigenen Module einreichen und Sie zu Ihrem Preis(oder kostenlos) anbieten. Dazu müssen Sie nur ein Benutzerkonto erstellen und in Ihrem Kundenbereich im linken Menü das Modul einreichen.</p>\n        <p></p>\n    </div>\n  </div>\n</section>',1,'2024-05-12 11:57:17',NULL,'2025-01-14 00:38:54',NULL,NULL,'banner','de',206,'','',NULL,'','',0,NULL,NULL),
(208,38,'_library_page_lib','','lib','','','<?php\n/**\n * Set session language based on:\n * - Cookie \'lang\' (if exists)\n * - Browser language (if not present among website languages, use website main language)\n * - Form field \'language\' (if present)\n *\n * The function also updates the product labels of the products in the session\n * to match the current language.\n *\n * @return bool\n */\nfunction setSessionLang() {\n   global $langs, $website, $weblangs, $db;\n    // Get available langs for the website\n    $website_langs = getAvailableLangs();\n    $available_langs = $website_langs[\'langs\'];\n    $langs_code_shortcode = $website_langs[\'langs_code_shortcode\'];\n\n    // If no language is set or if a new language is selected (via form field)\n    if (!isset($_COOKIE[\'lang\']) || GETPOST(\'l\', \'alpha\')) {\n        // Get browser language\n        $browser_lang = $weblangs->getDefaultLang(1);\n\n        // Change used lang\n        $new_lang = GETPOST(\'l\', \'alpha\');\n        if ($new_lang && array_key_exists ($new_lang, $available_langs)) {\n            setcookie(\'lang\', $new_lang, time() + (86400 * 30), \'/\');\n            $session_lang = $new_lang;\n        }\n\n        // If no language is set in cookie and browser language is not present among available languages\n        // use website main language as default\n        if (!isset($_COOKIE[\'lang\'])) {\n            if (array_key_exists ($browser_lang, $available_langs)){\n                // The browser language is present among the available languages\n                setcookie(\'lang\', $browser_lang, time() + (86400 * 30), \'/\');\n                $session_lang = $browser_lang;\n            } else {\n                // The browser language is not present among the available languages\n                setcookie(\'lang\', $website->lang, time() + (86400 * 30), \'/\');\n                $session_lang = $website->lang;\n            }\n        }\n\n        // Set session lang\n        if (!empty($session_lang)) {\n            $_SESSION[\'lang\'][\'shortcode\'] = $session_lang;\n            $_SESSION[\'lang\'][\'code\'] = $langs_code_shortcode[$session_lang];\n\n            // Update product labels in session to match current language\n            if (isset($_SESSION[\'products\'])) {\n                $langs->setDefaultLang($_SESSION[\'lang\'][\'code\']);\n                // Loop over products in session and update label\n                foreach ($_SESSION[\'products\'] as $key => $value) {\n                    $object = new Product($db);\n                    $get_product = $object->fetch($key);\n                    $_SESSION[\'products\'][$key][\'product_name\'] = $object->label;\n                }\n            }\n        }\n\n    }\n\n    // If session language is not set, use cookie language\n    if (empty($_SESSION[\'lang\'][\'shortcode\']) || empty($_SESSION[\'lang\'][\'code\'])) {\n        $_SESSION[\'lang\'][\'shortcode\'] = $_COOKIE[\'lang\'];\n        $_SESSION[\'lang\'][\'code\'] = $langs_code_shortcode[$_COOKIE[\'lang\']];\n    }\n\n    // Set Dolibarr default language\n    $langs->setDefaultLang($_SESSION[\'lang\'][\'code\']);\n    $weblangs->setDefaultLang($_SESSION[\'lang\'][\'code\']);\n    $langs->loadLangs(array(\"main\", \"website\"));\n    $weblangs->loadLangs(array(\"main\", \"website\", \"marketplace@marketplace\"));\n\n    return true;\n}\n\n/**\n * The function loops through the languages of the website configuration and\n * checks if they exist in the list of supported languages. If they do, they\n * are added to the $available_langs array, along with their corresponding\n * shortcode in the $langs_code_shortcode array.\n *\n * The function returns an array with two keys: \'langs\' containing the list\n * of available languages and \'langs_code_shortcode\' containing the list\n * of corresponding shortcodes.\n *\n * @return array\n */\nfunction getAvailableLangs() {\n    global $website, $weblangs;\n\n    $available_langs = array();\n    $langs_code_shortcode = array();\n    $ws_langs_list = explode(\',\', $website->lang.\',\'.$website->otherlang);\n    $dol_available_langs = $weblangs->get_available_languages(DOL_DOCUMENT_ROOT, 1, 2, 1);\n    foreach ($ws_langs_list as $lang) {\n        foreach ($dol_available_langs as $key => $value) {\n            if (strpos($key, $lang) === 0) {\n                $available_langs[$lang] = $value;\n                $langs_code_shortcode[$lang] = $key;\n                break;\n            }\n        }\n    }\n    \n    return array(\'langs\' => $available_langs, \'langs_code_shortcode\' => $langs_code_shortcode);\n}\n\nfunction getOrganizedTree($id,$sort = \'position\')\n{\n    global $db;\n    $root_cat_object = new Categorie($db);\n    $result = $root_cat_object->fetch($id);\n    $root_category_id = $root_cat_object->id;\n    $root_category_type = $root_cat_object->type;\n    $cats = $root_cat_object->get_filles();\n    if (count($cats) < 1) {\n        return array();\n    } else {\n        $categstatic = new Categorie($db);\n        $fulltree = $categstatic->get_full_arbo($root_category_type, $root_category_id, 1);\n        $organized_tree = buildTree($fulltree, $root_category_id);\n        usort($organized_tree, build_sorter($sort));\n        return $organized_tree;\n    }\n}\n\nfunction buildTree(array &$elements, $parentId = 0)\n{\n  $branch = array();\n  foreach ($elements as $element) {\n    if ($element[\'fk_parent\'] == $parentId) {\n      $children = buildTree($elements, $element[\'id\']);\n      if ($children) {\n        $element[\'children\'] = $children;\n      }\n      $branch[$element[\'rowid\']] = $element;\n    }\n  }\n  return $branch;\n}\n\nfunction build_sorter($key)\n{\n  return function ($a, $b) use ($key) {\n    return strnatcmp($a[$key], $b[$key]);\n  };\n}\n\n\nfunction ws_login($customer_email, $customer_passwd) {\n    global $db, $website;\n\n    $sql  = \"select lsa.rowid, lsa.pass_encoding, lsa.pass_crypted, ls.nom, fk_soc, lsa.login \";\n    $sql .= \"from \".MAIN_DB_PREFIX.\"societe_account lsa \";\n    $sql .= \"left join \".MAIN_DB_PREFIX.\"societe ls on ls.rowid = lsa.fk_soc \";\n    $sql .= \"where lsa.login = \'\" . $db->escape($customer_email) . \"\' \";\n    $sql .= \"and lsa.fk_website = \" . (int) $website->id . \" \";\n    $sql .= \"limit 1\";\n\n    $result = $db->query($sql);\n    $objsql = $db->fetch_object($result);\n\n    $is_logged = 0;\n    $check_accaount = 0;\n    $check_password = 0;\n    $is_preferred_member = 0;\n    if (!empty($objsql)) {\n        $check_accaount = 1;\n        if ($objsql->pass_encoding == \'dolibarr\') {\n            $check_password = dol_verifyHash ($customer_passwd, $objsql->pass_crypted);\n        }\n        if ($objsql->pass_encoding == \'dolistore\') {\n            $dolistore_key = getDolGlobalString(\"MARKETPLACE_SECRET_KEY\");\n            $to_check = md5($dolistore_key.$customer_passwd);\n            if ($objsql->pass_crypted === $to_check){\n                $check_password = 1;\n            }\n        }\n        if ($objsql->pass_encoding != \'dolibarr\' && $objsql->pass_encoding != \'dolistore\' ) {\n            $check_password = dol_verifyHash ($customer_passwd, $objsql->pass_crypted, $objsql->pass_encoding);\n        }\n        $is_logged = $check_accaount && $check_password;\n    }\n    \n    if ($is_logged > 0) {\n        $preferredCustomersCatId = getDolGlobalInt(\"MARKETPLACE_PROSPECTCUSTOMER_PREFERRED_ID\");\n        if (!empty($preferredCustomersCatId)) {\n            $category = new Categorie($db);\n            $user_categories = $category->getListForItem($objsql->fk_soc);\n\n            foreach ($user_categories as $user_categorie) {\n                if (!empty($user_categorie[\'id\']) && $user_categorie[\'id\'] == $preferredCustomersCatId) {\n                    $is_preferred_member = 1;\n                    break;\n                }\n            }\n        }\n    }\n\n    return array(\n        \'status\' => $is_logged,\n        \'userid\' => $objsql->rowid,\n        \'pseudo\' => $objsql->nom,\n        \'email\' => $objsql->login,\n        \'socid\' => $objsql->fk_soc,\n        \'is_preferred_member\' => $is_preferred_member\n    );\n}\n\n\nfunction ws_refreshCart($fk_soc) {\n    global $db;\n    // Find last validated, unpaid order of this user\n    /*$sql_find_order = \"SELECT c.rowid, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n    $sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n    $sql_find_order .= \"WHERE c.fk_soc = \" . $fk_soc . \" and c.fk_statut= 1 and c.facture = 0 and c.module_source = \'Marketplace\' \";\n    $sql_find_order .= \"order by c.date_creation desc \";\n    $sql_find_order .= \"limit 1\";*/\n    \n    // Find last validated, unpaid order of this user\n    $sql_find_order = \"SELECT c.rowid, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n    $sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n    $sql_find_order .= \"WHERE c.fk_soc = \" . $fk_soc . \" and c.fk_statut= 1 and c.facture = 0 and c.ref_ext is null and c.date_commande >= DATE_SUB(NOW(), INTERVAL 30 DAY) and c.module_source = \'Marketplace\' \";\n    $sql_find_order .= \"order by c.date_creation desc \";\n    $sql_find_order .= \"limit 1\";\n\n    $find_order = $db->query($sql_find_order);\n    $obj_order = $db->fetch_object($find_order);\n\n    // If there is an order, replace the current cart articles (fetched from SESSION) with the last validated, unpaid order.\n    if (!empty($obj_order)) {\n        $order_id = $obj_order->rowid;\n        require_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n        $commande = new Commande($db);\n        $ret = $commande->fetch($order_id);\n\n        $commande->fetch_lines();\n        $lines = $commande->lines;\n\n        foreach ($lines as $line){\n            $product = new Product($db);\n            $ret = $product->fetch($line->fk_product);\n            \n            // check discount and calculate discounted price\n		    $discount = marketplace_check_discount($product->id);\n		    $discounted_price = marketplace_calculate_discounted_price($product->price_ttc, $discount);\n		    \n		    if ($discounted_price != $product->price_ttc) {\n		        $price_to_display = $discounted_price;\n		    } else {\n		        $price_to_display = $product->price_ttc;\n		    }\n            \n            $session_product[\'product_id\'] = $product->id;\n            $session_product[\'product_thumb\'] = getImagePublicURLOfObject($product,1);\n            $session_product[\'product_name\'] = $product->label;\n            $session_product[\'product_ref\'] = $product->ref;\n            $session_product[\'product_price\'] = $price_to_display;\n            $session_product[\'product_qty\'] = $line->qty;\n\n            if(isset($_SESSION[\'products\'])){\n                if(isset($_SESSION[\'products\'][$session_product[\'product_id\']]))\n                {\n                    unset($_SESSION[\'products\'][$session_product[\'product_id\']]);\n                }\n            }\n            $_SESSION[\'products\'][$session_product[\'product_id\']] = $session_product;\n        }\n    }\n\n    return 1;\n}\n\nfunction ws_refreshOrder () {\n    global $db, $website, $user;\n    \n    require_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n    include_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\n    \n    // Load user and its permissions\n    $result = $user->fetch(\'\', \'admin\');	// Load user for login \'admin\'. Comment line to run as anonymous user.\n    if (!$result > 0) {\n    	dol_print_error(null, $user->error);\n    	exit;\n    }\n    $user->getrights();\n    \n    \n    // User is logged\n    if (!empty($_SESSION[\'user\'][\'id_user\'])) {\n        $user_id = $_SESSION[\'user\'][\'id_user\'];\n        $customer = new SocieteAccount($db);\n        $result = $customer->fetch($user_id);\n        $customer_id = $customer->fk_soc;\n        if (empty($customer_id)) {\n        	dol_print_error(null, $customer->error);\n        	return 0;\n        }\n    } else {\n        return 1;\n    }\n\n    \n    $com = new Commande($db);\n    $com->socid          = $customer_id;\n    $com->date           = dol_now();\n    $com->note_private   = \'Order from the marketplace\';\n    $com->module_source  = \'marketplace\';\n    $com->pos_source	 = dol_getmypid() . \"@\" . $website->id;\n    $com->remise_percent = 0;\n\n    $db->begin();\n    \n    // Check if there is an order for this user.\n    $sql_find_order = \"SELECT c.rowid, c.fk_statut, c.fk_soc, c.date_creation, c.module_source \";\n    $sql_find_order .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n    $sql_find_order .= \"WHERE c.fk_soc = \" . $customer_id . \" and c.fk_statut= 1 and c.facture = 0 and c.ref_ext is null and c.date_commande >= DATE_SUB(NOW(), INTERVAL 30 DAY) and c.module_source = \'Marketplace\' \";\n    $sql_find_order .= \"order by c.date_creation desc \";\n    $sql_find_order .= \"limit 1\";\n    \n    $find_order = $db->query($sql_find_order);\n    $obj_order = $db->fetch_object($find_order);\n    \n    // If there is an order, update the current unpaid order lines by SESSION articles.\n    if (!empty($obj_order)) {\n        $com->fetch($obj_order->rowid);\n        $com->fetch_lines();\n        $lines = $com->lines;\n        $com->setDraft($user);\n        \n        // remove current order lines \n        foreach ($lines as $line){\n            $ree = $com->deleteLine($user,$line->id);\n            //print $com->error . \'<br>\';\n        }\n        //exit();\n    } else {\n        $result = $com->create($user);\n    }\n    \n    if ($result >= 0 || $com) {\n        foreach ($_SESSION[\'products\'] as $session_product) {\n            // Get  product\n            $product = new Product($db);\n            $result = $product->fetch($session_product[\'product_id\']);\n            if (!$result > 0) {\n                $db->rollback();\n            	dol_print_error($db, $product->error);\n            	return 0;\n            }\n            \n            // Get seller\n            $sql_get_seller_id = \"select lpfp.fk_soc \n                from \".MAIN_DB_PREFIX.\"product_fournisseur_price lpfp \n                where lpfp.fk_product =\" .$session_product[\'product_id\'] . \" LIMIT 1\";\n            $resql = $db->query($sql_get_seller_id);\n    		$objsql = $db->fetch_object($resql);\n    		\n    		if(!empty($objsql->fk_soc)){\n    		    $thirdparty_seller = new Societe($db);\n                $thirdparty_seller->fetch($objsql->fk_soc);\n    		}else{\n    		    // To complete with default third party \n    		}\n    		\n    		// Get buyer\n    	    $thirdparty_buyer = new Societe($db);\n            $result = $thirdparty_buyer->fetch($customer_id);\n            if (!$result > 0) {\n                $db->rollback();\n            	dol_print_error($db, $thirdparty_buyer->error);\n            	return 0;\n            }\n            \n            $tva_tx = get_default_tva($thirdparty_seller, $thirdparty_buyer, $product->id);\n            \n            // Check discount\n			$discount = marketplace_check_discount($product->id);\n			$discount_percent = ($discount[\'mode\'] === \'percent\') ? $discount[\'value\'] : 0;\n\n            $result = $com->addline($product->label, $product->price, $session_product[\'product_qty\'], $tva_tx, 0, 0, $product->id, $discount_percent, 0, 0, $product->price_base_type, $product->price_ttc, \'\', \'\', $product->type);\n			if ($result <= 0) {\n			    $db->rollback();\n				dol_print_error($db, $product->error);\n				return 0;\n			}\n			\n			// TODO\n			if ($discount[\'mode\'] === \'amount\' && $discount[\'value\'] > 0) {\n                // Add amount discount\n			}\n        } \n        \n        $result = $com->valid($user);\n		if ($result > 0) {\n			$db->commit();\n            return 1;\n		} else {\n			$db->rollback();\n			dol_print_error($db, $com->error);\n			return 0;\n		}\n	} else {\n		$db->rollback();\n		dol_print_error($db, $com->error);\n		return 0;\n	}\n}\n\n/**\n * Check the validity of a module (rules must match the one in htdocs/admin/modules\n *\n * @return  array   Array of results\n */\nfunction checkZipFile()\n{\n	global $weblangs;\n\n	$error=0;\n	$return = array(\n		\'product_file_path\' => null,\n		\'upload\' => 1,\n		\'errormsg\' => null\n	);\n\n	$originalfilename=$_FILES[\'virtual_product_file\'][\'name\'];\n\n	if (strlen($originalfilename) > 48)\n	{\n		$error++;\n		$return[\'errormsg\'] = $weblangs->trans(\"fileNameLengthError\");\n		///$return[\'errormsg\'] = $this->l(\'Name of file must not be longer than 48 characters,  including the prefix (\"module_\", \"theme_\" or \"website_\"), the version suffix and the extension (\".zip\" for example) !\');\n	}\n\n	dol_syslog(\"Upload or reupload file \" . $originalfilename);\n\n	if ($_FILES[\'virtual_product_file\'][\'error\'])\n	{\n		switch ($_FILES[\'virtual_product_file\'][\'error\'])\n		{\n			case 1: // UPLOAD_ERR_INI_SIZE\n				$return[\'errormsg\'] = $weblangs->trans(\"fileSizeHigherServerLimit\");\n				///$return[\'errormsg\'] = $this->l(\'File size is higher than server limit !\');\n				break;\n			case 2: // UPLOAD_ERR_FORM_SIZE\n				$return[\'errormsg\'] = $weblangs->trans(\"fileSizeHigherHtmlFormLimit\");\n				///$return[\'errormsg\'] = $this->l(\'File size if higher than limit in HTML form !\');\n				break;\n			case 3: // UPLOAD_ERR_PARTIAL\n				$return[\'errormsg\'] = $weblangs->trans(\"uploadAborted\");\n				///$return[\'errormsg\'] = $this->l(\'File transfert was aborted !\');\n				break;\n			case 4: // UPLOAD_ERR_NO_FILE\n				$return[\'errormsg\'] = $weblangs->trans(\"noFileOrSizeZero\");\n				///$return[\'errormsg\'] = $this->l(\'File name was not defined or file size is null !\');\n				break;\n		}\n		$return[\'upload\'] = -1;\n		$error++;\n	}\n\n	if (! $error && ! preg_match(\'/(\\.apk|\\.odt|\\.pdf|\\.svg|\\.zip|\\.txt)$/i\',$originalfilename))\n	{\n		$return[\'errormsg\'] = $weblangs->trans(\"packageRuleViolation\") . \'<br>\';\n		$return[\'errormsg\'].= $weblangs->trans(\"packageFileNameExtension\");\n		///$return[\'errormsg\'] = $this->l(\'Package seems to not respect some rules:\').\'<br>\';\n		///$return[\'errormsg\'].= $this->l(\'Package file name must end with extension .odt, .pdf, .svg, .zip, .txt or .apk\');\n		$return[\'upload\'] = -1;\n		$error++;\n	}\n\n	if (! $error && preg_match(\'/(\\.txt)$/i\',$originalfilename) && ! preg_match(\'/(README)\\.txt$/i\',$originalfilename))\n	{\n		$return[\'errormsg\'] = $weblangs->trans(\"packageRuleViolation\") . \'<br>\';\n		$return[\'errormsg\'].= $weblangs->trans(\"packageReadmeTxt\");\n		$return[\'upload\'] = -1;\n		$error++;\n	}\n\n	if (! $error && preg_match(\'/(\\.zip)$/i\',$originalfilename))\n	{\n		if (! preg_match(\'/^(module[a-zA-Z0-9]*|theme|website)_/\', $originalfilename))\n		{\n			$return[\'errormsg\'] = $weblangs->trans(\"packageRuleViolation\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageFileNamePrefix\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageBuildTool\");\n			$return[\'upload\'] = -1;\n			$error++;\n		}\n\n		if (! preg_match(\'/\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename))\n		{\n			$return[\'errormsg\'] = $weblangs->trans(\"packageRuleViolation\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageFileNameVersion\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageBuildTool\");\n			$return[\'upload\'] = -1;\n			$error++;\n		}\n\n		// Example of allowed values:\n		// module_mymodule-x.y.zip, moduleprestashop_mymodule-x.y.zip\n		// theme_mytheme-x.y.zip\n		// website_mytemplate-123456.zip\n		if (! preg_match(\'/^module([a-zA-Z0-9]*)_([-a-zA-Z0-9_]+)\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename)\n			&& ! preg_match(\'/^theme_([a-zA-Z0-9_]+)\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename)\n			&& ! preg_match(\'/^website_([a-zA-Z0-9_]+)\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename)\n			)\n		{\n			$return[\'errormsg\'] = $weblangs->trans(\"packageRuleViolation\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageFileNameRules\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"packageBuildTool\");\n			$return[\'upload\'] = -1;\n			$error++;\n		}\n	}\n\n	if (! $error && preg_match(\'/(\\.zip)$/i\',$originalfilename))\n	{\n		$zip = new ZipArchive();\n		$res = $zip->open($_FILES[\'virtual_product_file\'][\'tmp_name\']);\n		if ($res === TRUE)\n		{\n			$resarray = validateZipFile($zip,$originalfilename,$_FILES[\'virtual_product_file\'][\'tmp_name\']);\n			//$zip->close();        // already close by validateZipFile\n			$error=$resarray[\'error\'];\n			$return[\'upload\']=$resarray[\'upload\'];\n			$return[\'errormsg\'] = $resarray[\'errormsg\'];\n		}\n		else\n		{\n			$return[\'errormsg\'] = $weblangs->trans(\"fileNotAnalyzed\") . \'<br>\';\n			$return[\'errormsg\'].= $weblangs->trans(\"emailIfError\");\n			$return[\'upload\'] = -1;\n			$error++;\n		}\n	}\n\n	if (! $error)\n	{\n		$return[\'errormsg\'] = \'\';\n		$return[\'upload\'] = 1;\n	}\n\n	return $return;\n}\n\n/**\n * Check that a zip file is Dolibarr rule compliant\n */\nfunction validateZipFile(&$zip,$originalfilename,$zipfile)\n{\n	global $count, $results, $weblangs;\n\n	$error=0;\n	$return = array(\n		\'error\' => 0,\n		\'errormsg\'=> null,\n		\'upload\' => 0\n	);\n\n	dol_syslog(\"Validate zip file \" . $originalfilename);\n	$subdir=basename($zipfile);\n	//$dir=\'/home/dolibarr/dolistore.com/tmp/\'.$subdir;\n	$dir=sys_get_temp_dir().\'/unzip-dir-\'.$subdir;\n	mkdir($dir, 0777, true);\n	$zip->extractTo($dir.\'/\');\n	$zip->close();\n\n	// Zip content of a module should be ./mymodule or ./htdocs/mymodule\n\n	// But we first we check if we need to change dir (for zip that are ./module/htdocs/module instead of ./htdocs/module)\n	if (! $error && $dh = opendir($dir))\n	{\n		$nbofsubdirs=0;\n		while (($file = readdir($dh)) !== false)\n		{\n			if ($file == \'.\' || $file == \'..\') continue;\n			dol_syslog(\"We check if dir \".$dir.\'/\'.$file.\'/htdocs exists\');\n			if (is_dir($dir.\'/\'.$file.\'/htdocs\'))\n			{\n				dol_syslog(\'Dir \'.$dir.\'/\'.$file.\'/htdocs exists. So we use dir=\'.$dir.\'/\'.$file.\' as root for package to analyse.\');\n				$dir=$dir.\'/\'.$file;\n				break;\n			}\n		}\n		closedir($dh);\n	}\n\n	// Now $dir contains root of zip, so mymodule or htdocs/mymodule\n	// Analyze files\n	$ismodule=$istheme=0;\n\n	if (preg_match(\'/^module([a-zA-Z0-9]*)_([-a-zA-Z0-9]+)\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename,$reg))\n	{\n		$ismodule=$reg[2];\n		$extmoduleornot=$reg[1];\n		if ($extmoduleornot) $ismodule=0;\n	}\n	if (preg_match(\'/^theme_([-a-zA-Z0-9]+)\\-([0-9][0-9\\.]*)\\.zip$/i\',$originalfilename,$reg)) $istheme=$reg[1];\n\n\n	dol_syslog(\"Now dir is the directory with root of the zip = \".$dir, LOG_DEBUG);\n\n	$dirmoduletheme = $dir.\'/\'.($ismodule?$ismodule:($istheme?$istheme:\'\'));\n	if (is_dir($dir.\'/htdocs\')) $dirmoduletheme = $dir.\'/htdocs/\'.($ismodule?$ismodule:($istheme?$istheme:\'\'));\n	$dirmodulethemeroot = dirname($dirmoduletheme);\n	dol_syslog(\"Now dirmodulethemeroot = dir where is the module dir = \".$dirmodulethemeroot.\" and dirmoduletheme = dir with name of the module = \".$dirmoduletheme, LOG_DEBUG);\n\n	if (! empty($ismodule) || ! empty($istheme))\n	{\n		dol_syslog(\"file ismodule=\".$ismodule.\" istheme=\".$istheme);\n		// It\'s a module or theme file\n		if (! $error && (! empty($ismodule) || ! empty($istheme)) && $dh = opendir($dir))\n		{\n			$nbofsubdirs=0; $direrror=\'\';\n			while (($file = readdir($dh)) !== false)\n			{\n				if ($file == \'.\' || $file == \'..\' || $file == \'README\' || $file == \'README.txt\' || $file == \'README.md\') continue;\n				dol_syslog(\"subdirs found for package:\".$file);\n				$nbofsubdirs++;\n				$alloweddirs=array(\'htdocs\', \'docs\', \'scripts\', \'test\', \'build\', ($ismodule?$ismodule:($istheme?$istheme:\'\')));\n				if (! in_array($file,$alloweddirs))\n				{\n					$error++;\n					$direrror=$file;\n					break;\n				}\n			}\n			if ($error)\n			{\n				$return[\'errormsg\'].= $weblangs->trans(\"validationFail\") . \'<br>\';\n				$return[\'errormsg\'].= $weblangs->trans(\"moduleContents\") . \'<br>\';\n				$return[\'errormsg\'].= $weblangs->trans(\"moduleDirectoryRule1\") . \'<br>\';\n				$return[\'errormsg\'].= $weblangs->trans(\"moduleDirectoryRule2\") . \'<br>\';\n				$return[\'errormsg\'].= $weblangs->trans(\"directoryFound\").\' \'.$direrror.\'<br><br>\'.\"\\n\";\n			}\n			closedir($dh);\n		}\n\n		// It\'s a module or theme file (check htdocs directory)\n		if (! $error && ! empty($ismodule) && is_dir($dirmodulethemeroot) && $dh = opendir($dirmodulethemeroot))\n		{\n			dol_syslog(\"we scan module dir \".$dirmodulethemeroot.\" to be sure there is only one directory (with name of your module) into root\");\n			$nbofsubdir=0; $lastdirfound=\'\';\n			dol_syslog(\"check there is only one dir into root\");\n			while (($file = readdir($dh)) !== false)\n			{\n				if ($file == \'.\' || $file == \'..\' || $file == \'README\' || $file == \'README.txt\' || $file == \'README.md\') continue;\n				$lastdirfound = $file;\n				dol_syslog(\"we found file or dir \".$file);\n				$nbofsubdir++;\n			}\n			closedir($dh);\n			if ($nbofsubdir >= 2 && ! is_file($dirmoduletheme.\'/metapackage.conf\'))\n			{\n				$return[\'errormsg\'].= $weblangs->trans(\"rootDirWarning\", $nbofsubdir, basename($dirmoduletheme)) . \'<br><br>\';\n				$error++;\n			}\n\n			if ($ismodule != $lastdirfound)\n			{\n				if (is_file($dirmoduletheme.\'/metapackage.conf\'))\n				{\n					// TODO Check each dir found is inside list of modules\n\n				} else {\n					$return[\'errormsg\'].= $weblangs->trans(\"moduleNameMismatch\", $lastdirfound, $ismodule) .\'<br><br>\';\n					$error++;\n				}\n			}\n		}\n		// Check \"custom\" compatibility\n		if (! $error && ! empty($ismodule))\n		{\n			dol_syslog(\"check the good practice of code\");\n			$count = 0;\n			$results = array();\n\n			$search = array(\n				0 => array(\n					\'name\'          => \'main\',\n					\'types\'         => array(\'php\'),\n					\'pattern\'       => \'(require|include).*(main|master)\\.inc\\.php\',\n					\'multiple\'      => true     // Means we must find 0 or several times the pattern. Error if found 1 occurrence.\n				),\n				/*2 => array(\n				 \'name\'          => \'dol_include_once\',\n				 \'types\'         => array(\'php\', \'class.php\', \'lib.php\', \'modules.php\'),\n				 \'pattern\'       => \'dol\\_include\\_once\\([\\\"\\\']\\/([^\\/]*)\\/.*;\',\n				 \'contain\'       => array($ismodule)     // error if it contains\n				 ),*/\n				1 => array(\n					\'name\'                  => \'dol_document_root\',\n					\'types\'                 => array(\'php\', \'class.php\', \'lib.php\', \'modules.php\'),\n					\'pattern\'               => \'(require|include)(_once)?\\(?(.*)[\\\"\\\']+\\)?;\',\n					\'id\'                    => 3,           // eg. Use $regs[3] for test instead $regs[1]\n					\'contain\'               => array(\'DOL_DOCUMENT_ROOT\'),\n					\'notcontain\'            => array($ismodule),\n					\'strict\'                => true         // if true (\'contain\' && \'notcontain\'), if false or not use (\'contain\' || \'notcontain\')\n				)\n			);\n\n			getDirContents($dir, $search, $results);     // This include a global $count\n\n			dol_syslog(\"count of errors = \".$count);\n\n			if (!empty($count)) // count of errors is not null\n			{\n				foreach($results as $result)\n				{\n					if ($result[\'testname\'] == \'main\')\n					{\n						$return[\'errormsg\'].= $weblangs->trans(\"mainIncludeError\", $result[\'filename\'], $ismodule) .\'<br><br>\';\n					}\n					else if ($result[\'testname\'] == \'dol_include_once\')\n					{\n						$return[\'errormsg\'].= $weblangs->trans(\"dolIncludeError\", $result[\'filename\'], $ismodule) .\'<br>\';\n						$return[\'errormsg\'].= $result[\'line\'].\'<br><br>\';\n					}\n					else if ($result[\'testname\'] == \'dol_document_root\')\n					{\n						$return[\'errormsg\'].= $weblangs->trans(\"docRootError\", $result[\'filename\'], $ismodule) .\'<br>\';\n						$return[\'errormsg\'].= $result[\'line\'].\'<br><br>\';\n					}\n				}\n\n				dol_syslog(\"file \".$originalfilename.\" is not compatible with custom directory!\", LOG_ERR);\n\n				$error++;\n			}\n		}\n	}\n	else\n	{\n		dol_syslog(\"file \".$originalfilename.\" is not a module and not a theme!\", LOG_WARNING);    // It can be a doc, android app, ...\n	}\n\n	if (!empty($error))\n	{\n		dol_syslog(\"validateZipFile Error\");\n\n		$link = \'<a target=\"_blank\" class=\"linktowiki\" href=\"https://wiki.dolibarr.org/index.php/Modules - Packaging rules and Dolistore validation rules\">Dolibarr wiki developer documentation</a>\';\n		$return[\'errormsg\'].= $weblangs->trans(\"invalidZipFile\") .\'<br>\';\n		$return[\'errormsg\'].= $weblangs->trans(\"seeDocumentation\", $link).\'<br>\';\n		$return[\'errormsg\'].= \"<br>\\n\";\n		$return[\'errormsg\'].= $weblangs->trans(\"contactDolistore\");\n		$return[\'upload\'] = -1;\n		$error++;\n	}\n	else\n	{\n		dol_syslog(\"validateZipFile OK\");\n	}\n\n	$return[\'error\'] = $error;\n\n	return $return;\n}\n\nfunction getDirContents($dir, $search = array(), &$results = array())\n{\n	global $count;\n\n	$files = scandir($dir);\n\n	foreach ($files as $key => $value)\n	{\n		$path = realpath($dir . DIRECTORY_SEPARATOR . $value);\n		if (!is_dir($path))\n		{\n			$content = file_get_contents($path);\n			$fileName = basename($path);\n			$fileNameWithoutTmp = preg_replace(\'/\\/tmp\\/unzip[^\\/]+\\//\', \'\', $path);\n\n			$file_array = explode(\".\", $fileName);\n\n			foreach ($search as $pattern)\n			{\n				if (count($file_array) > 1)\n				{\n					$ext = $file_array[1];\n					if (!empty($file_array[2])) {\n						$ext = $file_array[1] . \'.\' . $file_array[2];\n					}\n\n					if (in_array($ext, $pattern[\'types\']))\n					{\n\n						if (strpos($content, \'<?php\') !== 0) continue;  // We discard files that are not php pages (we discard scripts)\n						if (strpos($path, \'htdocs_\') > 0) continue;  // We discard files that are files into htdocs_... because it is files for core, so no need to be compatible with custom\n						if (strpos($path, \'phpunit\') > 0) continue;  // We discard files that are files into phpunit because it is files for core, so no need to be compatible with custom\n\n						$regs = array();\n						if (!empty($pattern[\'multiple\']))\n						{\n							preg_match_all(\'/\' . $pattern[\'pattern\'] . \'/\', $content, $regs);\n							// Error if only one result (0 is ok, >1 is ok)\n							if (!empty($regs) && count($regs[0]) == 1)\n							{\n								$results[] = array(\n									\'testname\'      => $pattern[\'name\'],\n									\'filename\'      => $fileNameWithoutTmp\n								);\n								$count++;\n							}\n						}\n						else\n						{\n							$id = (!empty($pattern[\'id\']) ? $pattern[\'id\'] : 1);\n							preg_match_all(\'/\' . $pattern[\'pattern\'] . \'/\', $content, $regs);\n\n							if (!empty($regs) && !empty($regs[$id]))\n							{\n								foreach($regs[$id] as $i => $string)\n								{\n									if (!empty($pattern[\'contain\']) && is_array($pattern[\'contain\']))\n									{\n										foreach ($pattern[\'contain\'] as $contain)\n										{\n											// Mode strict true : doit contenir && ne pas contenir\n											if (!empty($pattern[\'notcontain\']) && !empty($pattern[\'strict\']) && is_array($pattern[\'notcontain\']))\n											{\n												foreach ($pattern[\'notcontain\'] as $notcontain)\n												{\n													if (strstr($string, $contain) && strstr($string, $notcontain))\n													{\n														$results[] = array(\n															\'testname\'      => $pattern[\'name\'],\n															\'filename\'      => $fileName,\n															\'line\'          => $regs[0][$i]\n														);\n														$count++;\n													}\n												}\n											}\n											// Mode strict false : doit contenir. Note strstr return false if not found\n											else if (!strstr($string, $contain))        // If found\n											{\n												// We found $contain into $string\n												$results[] = array(\n													\'testname\'      => $pattern[\'name\'],\n													\'filename\'      => $fileName,\n													\'line\'          => $regs[0][$i]\n												);\n												$count++;\n											}\n										}\n									}\n									// Ou ne doit pas contenir\n									if (empty($count) && !empty($pattern[\'notcontain\']) && empty($pattern[\'strict\']) && is_array($pattern[\'notcontain\']))\n									{\n										foreach ($pattern[\'notcontain\'] as $notcontain)\n										{\n											if (strstr($string, $notcontain))\n											{\n												$results[] = array(\n													\'testname\'      => $pattern[\'name\'],\n													\'filename\'      => $fileName,\n													\'line\'          => $regs[0][$i]\n												);\n												$count++;\n											}\n										}\n									}\n								}\n							}\n						}\n					}\n				}\n			}\n\n		}\n		else if ($value != \".\" && $value != \"..\") {\n			getDirContents($path, $search, $results);\n		}\n	}\n}\n\nfunction checkImage($image)\n{\n	global $weblangs;\n	$flagError = false;\n\n	if ($image[\'error\'])\n	{\n		switch ($image[\'error\'])\n		{\n			case 1: // UPLOAD_ERR_INI_SIZE\n				$flagError = $weblangs->trans(\"fileSizeHigherServerLimit\");\n				break;\n			case 2: // UPLOAD_ERR_FORM_SIZE\n				$flagError = $weblangs->trans(\"fileSizeHigherHtmlFormLimit\");\n				break;\n			case 3: // UPLOAD_ERR_PARTIAL\n				$flagError = $weblangs->trans(\"uploadAborted\");\n				break;\n			case 4: // UPLOAD_ERR_NO_FILE\n				$flagError = $weblangs->trans(\"noFileOrSizeZero\");\n				break;\n			default:\n				$flagError = \'Unknown error in check image\';\n				break;\n		}\n	}\n	else\n	{\n	    include_once DOL_DOCUMENT_ROOT.\'/core/lib/images.lib.php\';\n	    \n		// Check extension\n		if (image_format_supported($image[\'name\']) <= 0) {\n		    $flagError = $weblangs->trans(\"errorImageFormat\", strtoupper($extention_image));\n		}\n	}\n\n	return $flagError;\n}\n\n\n/*\n * @param array 		$product 		Selected value\n * @param int	 	$id 			Id of the product (empty for creation, set for update)\n */\nfunction addProduct($object, $id = null) {\n\n	global $langs, $db, $user, $conf, $weblangs;\n	$error = 0;\n    $error_messages = array();\n\n	include_once DOL_DOCUMENT_ROOT . \'/product/class/product.class.php\';\n	include_once DOL_DOCUMENT_ROOT . \'/categories/class/categorie.class.php\';\n	include_once DOL_DOCUMENT_ROOT . \'/ecm/class/ecmfiles.class.php\';\n	require_once DOL_DOCUMENT_ROOT . \"/core/lib/files.lib.php\";\n	include_once DOL_DOCUMENT_ROOT . \'/core/lib/security.lib.php\';\n	require_once DOL_DOCUMENT_ROOT . \'/core/class/html.formbarcode.class.php\';\n	require_once DOL_DOCUMENT_ROOT . \'/fourn/class/fournisseur.product.class.php\';\n	include_once DOL_DOCUMENT_ROOT . \'/societe/class/societeaccount.class.php\';\n\n\n	// Load user and its permissions\n	$result = $user->fetch(\'\', \'admin\'); // Load user for login \'admin\'. Comment line to run as anonymous user.\n	if (!($result > 0)) {\n		dol_print_error(null, $user->error);\n		exit;\n	}\n	$user->getrights();\n\n	// Get Account ID.\n	$user_id = $_SESSION[\'user\'][\'id_user\'];\n	$supplier_account = new SocieteAccount($db);\n	$result = $supplier_account->fetch($user_id);\n	$supplier_id = $supplier_account->fk_soc;\n\n	// Get customer ID.\n	$supplier = new Societe($db);\n	$supplier->fetch($supplier_id);\n\n	// Update customer to vendor\n	if (empty($supplier->fournisseur) || empty($supplier->code_fournisseur)) {\n	    $supplier->fournisseur = 1;\n	    if (empty($supplier->code_fournisseur)) {\n	        $supplier->code_fournisseur = \'auto\';\n	    }\n	    \n	    $supplier->update($supplier_id, $user);\n	\n	    $result = $supplier->fetch($supplier_id);\n	}\n\n	// We enable recursive category assignement (we use it for search and filter purposes)\n    $conf->global->CATEGORIE_RECURSIV_ADD = 1;\n\n	// Start of transaction\n	$db->begin();\n\n	//add one product\n	$product = new Product($db);\n\n	if ($id > 0) {\n		$result = $product->fetch($id);\n	} else {\n	    // Defined a reference for marketplace : mp999dYYYMMDDHHMMSS\n	    // Use product default numbering module ?\n		$dateRef = date (\"YmdHis\");\n		$reference = \'mp\'.$supplier->id.\'d\'.$dateRef;\n		\n		$product->ref = $reference;\n		$product->barcode = \'auto\';\n	}\n\n	$product->type = $product::TYPE_SERVICE;\n	\n	// New Products will be status 0\n	if (!$id) {\n	    $product->status = 0;\n	} else {\n	    // Author can only make product disabled\n	    if ($object[\'status\'] == 0) {\n	        $product->status = 0;\n	    }\n    	$product->status_buy = 0;\n	}\n\n	$product->label = $object[\'name\'];\n	$product->description = $object[\'short_description\'];\n	$product->other = $object[\'description\'];\n	$product->price = price2num($object[\'sale_price\']);\n	$product->price_base_type = \'HT\';\n	$product->tva_tx = \"20\";    // TODO Take default vat of $mysoc\n	$product->mandatory_period = 0;\n\n	// Extrafields\n	$product->array_options[\'options_marketplace_module_keywords\'] = $object[\'keywords\'];\n	$product->array_options[\'options_marketplace_module_version\'] = $object[\'version\'];\n	if (!empty($object[\'version_min\'])) {\n    	$version_min_object = new Categorie($db);\n    	$result = $version_min_object->fetch($object[\'version_min\']);\n    	if ($result > 0) {\n    	    $product->array_options[\'options_marketplace_min_version\'] = $version_min_object->label;\n    	}\n	}\n	if (!empty($object[\'version_max\'])) {\n    	$version_max_object = new Categorie($db);\n    	$result = $version_max_object->fetch($object[\'version_max\']);\n    	if ($result > 0) {\n    	    $product->array_options[\'options_marketplace_max_version\'] = $version_max_object->label;\n    	}\n	}\n	$product->array_options[\'options_marketplace_contact_support\'] = $object[\'contact_support\'];\n	$object[\'dolibarr_core_include\'] = $object[\'dolibarr_core_include\'] ? 1 : 0;\n	$product->array_options[\'options_marketplace_allow_source_in_core\'] = $object[\'dolibarr_core_include\'];\n	//$product->array_options[\'options_marketplace_short_description\'] = $object[\'resume\'];\n	//$product->array_options[\'options_marketplace_reason_disabled\'] = $obj->dolibarr_disable_info;\n\n	if ($id > 0) {\n		$result = $product->update($id, $user);\n	} else {\n		$result = $product->create($user);\n	}\n	if ($result < 0) {\n	    print $product->errorsToString();\n		dol_syslog(\"Create Error => \" . $result . \" - \" . $product->errorsToString());\n		$error++;\n	} else {\n		dol_syslog(\"Product id=\".$product->id.\" successfully\");\n	}\n	\n	// Add langs, categories, versions and photos\n	if (!$error && 1) {\n	    \n	    // Update Price\n	    if ($id) {\n	        $product->updatePrice($product->price, \'HT\', $user);\n	    }\n\n		// Add alternative languages\n		if ($object[\'multilangs\']) {\n			foreach ($object[\'multilangs\'] as $key => $value) {\n				$availableLangsShortCode = getAvailableLangs()[\'langs_code_shortcode\'];\n				$product->multilangs[$availableLangsShortCode[$key]] = array(\n					\'label\' => $value[\'name\'],\n					\'description\' => $value[\'short_description\'],\n					\'other\' => $value[\'description\'],\n				);\n			}\n		}\n		$product->multilangs;\n		$langs->setDefaultLang(\'en_US\');\n		$ret = $product->setMultiLangs($user);\n		if ($ret < 0) {\n			dol_syslog(\"Error in setMultiLangs result code = \" . $ret . \" - \" . $product->errorsToString());\n			$error++;\n		} else {\n			dol_syslog(\"Set MultiLangs OK\");\n		}\n\n		// Add owner of a module by adding supplier price\n		if (!$id) {\n		    $object_ProductFournisseur = new ProductFournisseur($db);\n		    $object_ProductFournisseur->fetch($product->id);\n		    $object_ProductFournisseur->add_fournisseur($user, $supplier->id, $product->ref, 1);\n		    $object_ProductFournisseur->update_buyprice(1, 0, $user, \'HT\', $supplier, 1, $supplier->ref, 20, 0, \'\', 0, 0, \'\', \'\', array(), \'\', 0, \'HT\');\n		    dol_syslog(\"Adding supplier prices (id_fourn=\".$supplier->id.\" ref_product_fourn=\".$product->ref.\") OK\");\n		}\n\n		// Add categories and versions\n		if (!empty($object[\'version_min\']) && !empty($object[\'version_max\'])) {\n			$version_tags = get_all_tags_between($version_min_object->label,$version_max_object->label);\n			$version_ids = array();\n			foreach ($version_tags as $key => $value) {\n				$version_object = new Categorie($db);\n				$result = $version_object->fetch(\'\', $value);\n				$version_ids[$version_object->id] = $version_object->id;\n			}\n		}\n		if (!empty($object[\'categories\'])) {\n		    $marketplaceMainCat = array(getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\") => getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\"));\n		    $object[\'categories\'] = array_merge($marketplaceMainCat, $object[\'categories\']);\n			if (!empty($version_ids)) {\n				$object[\'categories\'] = array_merge($version_ids, $object[\'categories\']); // Add versions to categories\n			}\n			$ret_cat = $product->setCategories($object[\'categories\']);\n			if ($ret_cat < 0) {\n				dol_syslog(\"Error in setCategories result code = \" . $ret_cat . \" - \" . $product->errorsToString().\' \'.join(\',\', $object[\'categories\']));\n				$error++;\n			} else {\n				dol_syslog(\"Set Categories and versions OK\");\n			}\n		}\n\n		// Add pictures AND package\n		$upload_dir = $conf->product->multidir_output[1] . \'/\' . get_exdir(0, 0, 0, 1, $product, \'product\');\n		if (!is_dir($upload_dir)) {\n			mkdir($upload_dir);\n		}\n		if (!empty($object[\'image_cover\'][\'name\'])) {\n			$images[\'image_cover\'] = $object[\'image_cover\'];\n\n            // Delete old cover files from disk\n            dol_delete_file($upload_dir . \'/\' . $product->ref.\"-image_cover.*\");\n		}\n		if (!empty($object[\'other_images\'])) {\n			$other_images = $object[\'other_images\'];\n			foreach ($other_images as $key => $value) {\n				$images[$key] = $value;\n			}\n		}\n		if (!empty($images)) {\n			foreach ($images as $key_image => $value_image) {\n				$extension = pathinfo($value_image[\'name\'], PATHINFO_EXTENSION);\n\n				$img = $upload_dir . \'/\' . $product->ref . \'-\' . $key_image . \'.\' . $extension;\n	\n	            $resultdolmove = dol_move_uploaded_file($value_image[\'tmp_name\'], $img, 1);\n	            \n				if ((int) $resultdolmove <= 0) {\n					$error++;\n					dol_syslog(\"file copy impossible for the moment, please try again later\");\n				} else {\n					// Add thumb\n					$product->addThumbs($img, 40);\n					\n					$filename = basename($product->ref . \'-\' . $key_image  . \'.\' . $extension);\n					$rel_dir = preg_replace(\'/^\' . preg_quote(DOL_DATA_ROOT, \'/\') . \'/\', \'\', $upload_dir);\n					$rel_dir = preg_replace(\'/^[\\\\/]/\', \'\', $rel_dir);\n\n					$ref = dol_hash($rel_dir . \'/\' . $filename, 3);\n\n					// Delete existing index entry\n					deleteFilesIntoDatabaseIndex($upload_dir, $filename, \'\');\n					\n					// Add index to db\n					addFileIntoDatabaseIndex($upload_dir, $filename, \'MARKETPLACE\', \'uploaded\', 1, $product);\n\n	\n					// Update index to put position\n					$ecmfile = new EcmFiles($db);\n					$result_get_ecmfile = $ecmfile->fetch(\'\', $ref);\n					if ($key_image == \'image_cover\'){\n						$ecmfile->position = 0;\n					} else {\n						$position = preg_match(\'/_(\\d+)$/\', $key_image, $matches) ? $matches[1] : 100;\n						$ecmfile->position = $position;\n					}\n					\n					$result_update_ecmfile = $ecmfile->update($user);\n	\n					if ($result_update_ecmfile < 0) {\n						dol_syslog(\"Error in set image \" . $key_image . \" result code = \" . $result_update_ecmfile . \" - \" . $ecmfile->errorsToString());\n						$error++;\n					} else {\n						dol_syslog(\"Set Image \" . $key_image . \" OK\");\n					}\n				}\n			}\n		}		\n		\n\n\n		// Add package\n		if (!empty($object[\'virtual_product_file\'][\'name\'])) {\n			$package = $upload_dir . \'/\' . basename($object[\'virtual_product_file\'][\'name\']);\n\n			if (move_uploaded_file($object[\'virtual_product_file\'][\'tmp_name\'], $package) != true){\n				dol_syslog(\'Error: Failed to move uploaded file. \');\n				$error++;\n			} else {\n			    // Get Id of current ECMFile if exist \n			    if ($id) {\n			        $sql_file = \"SELECT rowid \";\n                	$sql_file .= \" FROM \".MAIN_DB_PREFIX.\"ecm_files\";\n                	$sql_file .= \" WHERE entity IN (\".getEntity($product->element).\")\";\n                	$sql_file .= \" AND src_object_type = \'\".$db->escape($product->element).\"\' AND src_object_id = \".((int) $product->id).\" AND position = 100 \";\n                	$fileQuery = $db->query($sql_file);\n                    $fileDetails = $db->fetch_object($fileQuery);\n                    $oldFileId = $fileDetails->rowid;\n			    }\n\n				// Add index to db\n				$filename = basename($object[\'virtual_product_file\'][\'name\']);\n				addFileIntoDatabaseIndex($upload_dir, $filename, \'MARKETPLACE\', \'uploaded\', 1, $product);\n\n				// Update index to put position\n				$rel_dir = preg_replace(\'/^\' . preg_quote(DOL_DATA_ROOT, \'/\') . \'/\', \'\', $upload_dir);\n				$rel_dir = preg_replace(\'/^[\\\\/]/\', \'\', $rel_dir);\n				$ref = dol_hash($rel_dir . \'/\' . $filename, 3);\n\n				$ecmfile = new EcmFiles($db);\n				$result_get_ecmfile = $ecmfile->fetch(\'\', $ref);\n				$ecmfile->position = 100;\n				$result_update_ecmfile = $ecmfile->update($user);\n\n				if ($result_update_ecmfile < 0) {\n					dol_syslog(\"Error in setPackage result code = \" . $result_update_ecmfile . \" - \" . $ecmfile->errorsToString());\n					$error++;\n				} else {\n					dol_syslog(\"Set Package OK\");\n					// Delete old ECMFILE\n					if ($id && $oldFileId) {\n					    $ecmfiletodelete = new EcmFiles($db);\n        				$resultecmfiletodelete = $ecmfiletodelete->fetch($oldFileId);\n        				if ($resultecmfiletodelete > 0) {\n        					$ecmfiletodelete->delete($user);\n        				}\n					}\n				}\n			}\n		}\n	}\n    \n    //$langs->setDefaultLang($_SESSION[\'lang\'][\'code\']);\n	if ($error == 0) {\n		$db->commit();\n		dol_syslog(\"Product id=\".$product->ref.\" successfully\");\n		return 1;\n	} else {\n		$db->rollback();\n		dol_syslog(\'--- end error nb=\' . $error);\n		return $weblangs->trans(\"errorOccurred\");\n	}\n}\n\nfunction get_all_tags_between($start, $end) {\n    $start_num = intval(substr($start, 1));\n    $end_num = intval(substr($end, 1));\n    \n    $result = array();\n    \n    for ($i = $start_num; $i <= $end_num; $i++) {\n        $result[] = \'V\' . $i;\n    }\n    \n    return $result;\n}\n\n// Send an email\nfunction marketplace_send_email($id_template, $type_template, $object, $to, $additionalSubstitutionArray) {\n    global $db, $conf, $user;\n    \n    $subject = \'\';\n	$msg = \'\';\n\n	// Send email\n	include_once DOL_DOCUMENT_ROOT.\'/core/class/html.formmail.class.php\';\n	$formmail = new FormMail($db);\n	// Set output language\n	$outputlangs = new Translate(\'\', $conf);\n	$outputlangs->setDefaultLang($_SESSION[\'lang\'][\'code\']);\n	// Load traductions files required by page\n	$outputlangs->loadLangs(array(\"main\", \"website\", \"marketplace@marketplace\"));\n\n	// Get email content from template\n	$arraydefaultmessage = null;\n\n	$arraydefaultmessage = $formmail->getEMailTemplate($db, $type_template, $user, $outputlangs, $id_template, 1, \'\');\n\n	if (!empty($id_template) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {\n		$subject = $arraydefaultmessage->topic;\n		$msg     = $arraydefaultmessage->content;\n	}\n\n    //$substitutionarray = $additionalSubstitutionArray;\n	$substitutionarray = getCommonSubstitutionArray($outputlangs, 0, null, $object);\n	$substitutionarray = array_merge($substitutionarray, $additionalSubstitutionArray);\n	complete_substitutions_array($substitutionarray, $outputlangs, $object);\n	$subjecttosend = make_substitutions($subject, $substitutionarray, $outputlangs);\n	$texttosend = make_substitutions($msg, $substitutionarray, $outputlangs);\n\n\n	$moreinheader = \'X-Dolibarr-Info: marketplace_send_email by Marketplace\'.\"\\r\\n\";\n\n	// Detect if message is HTML\n	if (dol_textishtml($texttosend, 0)) {\n		$texttosend = dol_htmlentitiesbr($texttosend);\n	}\n\n\n	// Envoi mail confirmation\n	$from = $conf->email_from;\n	if (getDolGlobalString(\'MAIN_MAIL_EMAIL_FROM\')) {\n		$from = getDolGlobalString(\'MAIN_MAIL_EMAIL_FROM\');\n	}\n	if (getDolGlobalString(\'MARKETPLACE_EMAIL\')) {\n		$from = getDolGlobalString(\'MARKETPLACE_EMAIL\');\n	}\n\n    $trackid = \'\';\n    if ($object instanceof Societe) {\n	    $trackid = \'thi\'.$object->id;\n    }\n    if ($object instanceof SocieteAccount) {\n	    $trackid = \'thi\'.$object->fk_soc;\n    }\n\n    dol_syslog(\"marketplace_send_email: \".$from.\" - \".$to);\n    \n	// Send email (substitutionarray must be done just before this)\n	include_once DOL_DOCUMENT_ROOT.\'/core/class/CMailFile.class.php\';\n	$mailfile = new CMailFile($subjecttosend, $to, $from, $texttosend, array(), array(), array(), \'\', \'\', 0, -1, \'\', \'\', $trackid, $moreinheader);\n	if ($mailfile->sendfile()) {\n		return 1;\n	} else {\n		return 0;\n	}\n}\n\nfunction marketplace_check_discount($id_product) {\n    global $db;\n    \n    include_once DOL_DOCUMENT_ROOT . \'/categories/class/categorie.class.php\';\n\n    $discount = 0;\n    $mode = \"\";\n    \n    $canBeDiscounted = 1;\n    // Check if this product is allowed for discount\n    $noDiscountProductCat = getDolGlobalInt(\"MARKETPLACE_DISCOUNT_EXCLUDE_PRODUCTS_CATEGORY_ID\");\n    if (!empty($noDiscountProductCat)) {\n        $category = new Categorie($db);\n        $prod_categories = $category->getListForItem($id_product, \'product\');\n\n        foreach ($prod_categories as $prod_categorie) {\n            if (!empty($prod_categorie[\'id\']) && $prod_categorie[\'id\'] == $noDiscountProductCat) {\n                $canBeDiscounted = 0;\n                break;\n            }\n        }\n    }\n    \n    // Check discount for preferred members\n    if ($canBeDiscounted == 1 && !empty($_SESSION[\'user\'][\'is_preferred_member\']) && $_SESSION[\'user\'][\'is_preferred_member\'] == 1) {\n        $discountValue = getDolGlobalInt(\"MARKETPLACE_PROSPECTCUSTOMER_PREFERRED_DISCOUNT\");\n        if (!empty($discountValue)) {\n            $discount = $discountValue;\n            $mode = \"percent\";\n        }\n    }\n    \n    // TODO Check discount for other cases\n    \n    return array(\n        \'value\' => $discount,\n        \'mode\' => $mode\n    );\n}\n\nfunction marketplace_calculate_discounted_price($price, $discount) {\n    $discounted_price = $price;\n    if ($discount[\'value\'] && $discount[\'mode\']) {\n        if ($discount[\'mode\'] === \"percent\") {\n            $discounted_price = $price * ((1 - $discount[\'value\'] / 100));\n        }\n        \n        if ($discount[\'mode\'] === \"amount\") {\n            $discounted_price = $price - $discount[\'value\'];\n        }\n    }\n    \n    return $discounted_price;\n}\n\nfunction marketplaceNotifySellersBuyerByEmail ($order_id) {\n	global $db, $website;\n\n    dol_syslog(\"marketplaceNotifySellersBuyerByEmail: start\");\n    \n	// Get order\n	require_once DOL_DOCUMENT_ROOT.\"/commande/class/commande.class.php\";\n	$order = new Commande($db);\n	$result = $order->fetch($order_id);\n\n	// Get customer\n	$customer = new SocieteAccount($db);\n	$result = $customer->fetch($_SESSION[\'user\'][\'id_user\']);\n	\n    // Get buyer\n	$buyer = new Societe($db);\n	$result = $buyer->fetch($customer->fk_soc);\n\n	$products_list = \'<ol>\';\n\n	// Find sellers\n	$sql_get_order_products = \"select cd.fk_product, cd.qty from \".MAIN_DB_PREFIX.\"commandedet as cd where cd.fk_commande = \".((int) $order_id);\n	\n	if ($result_commande_det = $db->query($sql_get_order_products)) {\n	    // Loop on each line of product\n		while ($commande_det = $result_commande_det->fetch_object()) {\n			// Get product\n			$product = new Product($db);\n			$result = $product->fetch($commande_det->fk_product);\n\n			// Add product to list\n			$products_list .= \'<li>[\'.$product->ref.\'] \'.$product->label.\' (x\'.$commande_det->qty.\')</li>\';\n\n			// Get product seller\n			$sql_get_seller_id = \"select lpfp.fk_soc from \".MAIN_DB_PREFIX.\"product_fournisseur_price lpfp where lpfp.fk_product =\".((int) $product->id). \" LIMIT 1\";\n			$resql = $db->query($sql_get_seller_id);\n			$objsql = $db->fetch_object($resql);\n			\n			if (!empty($objsql->fk_soc)) {\n				// Get seller email\n			    $sql_get_seller_email = \"SELECT lsa.login \n                    FROM \".MAIN_DB_PREFIX.\"societe_account lsa \n                    WHERE \n                    lsa.fk_soc = \".$objsql->fk_soc.\"\n                    AND lsa.site = \'dolibarr_website\' \n                    AND lsa.fk_website = \" . $website->id;\n                    \n			    dol_syslog(\"marketplaceNotifySellersBuyerByEmail: Get seller email \".$sql_get_seller_email);\n                    \n                $resql = $db->query($sql_get_seller_email);\n			    $objSocAccountEmail = $db->fetch_object($resql);\n				\n				if ($objSocAccountEmail) {\n    				$seller_email = $objSocAccountEmail->login;\n    \n    				// Get seller name\n    				$seller = new Societe($db);\n    				$result = $seller->fetch($objsql->fk_soc);\n    				$seller_name = $seller->name;\n    				\n    				$langseller = new Translate(\'\', $conf);\n    				$langseller->setDefaultLang($seller->default_lang);\n\n    				\n    				if ($result > 0) {\n    					$substitutionarray = array(\n    						\'__SELLER_NAME__\' => $seller_name,\n    						\'__BUYER_NAME__\' => strtoupper($_SESSION[\'user\'][\'pseudo\']),\n    						\'__BUYER_EMAIL__\' => $_SESSION[\'user\'][\'email\'],\n    						\'__BUYER_ADDRESS__\' => $buyer->address,\n    						\'__BUYER_ZIP__\' => ($buyer->zip ? $buyer->zip : \' \'),\n    						\'__BUYER_TOWN__\' => ($buyer->town ? $buyer->town : \' \'),\n    						\'__BUYER_COUNTRY__\' => $buyer->country_code,\n    						\'__BUYER_IDPROF2__\' => $buyer->idprof2,\n    						\'__BUYER_TVAINTRA__\' => $buyer->tva_intra,\n    						\'__ORDER_REF__\' => $order->ref,\n    						\'__ORDER_DATE__\' => dol_print_date($order->date, \'dayhour\', \'auto\', $langseller),\n    						\'__PRODUCTREF__\' => $product->ref,\n    						\'__PRODUCT__\' => $product->label,\n    						\'__QTY__\' => $commande_det->qty\n    					);\n    					\n    					dol_syslog(\"marketplaceNotifySellersBuyerByEmail: send email MARKETPLACE_SELLERS_ORDER_CONFIRMATION_TEMPLATE to \".$seller_email);\n    					\n    					marketplace_send_email(getDolGlobalInt(\"MARKETPLACE_SELLERS_ORDER_CONFIRMATION_TEMPLATE\"), \'order_send\', $seller, $seller_email, $substitutionarray);\n    				}\n				}\n			}\n		}\n	}\n	$products_list .= \"</ol>\";\n	\n	\n	// Send buyer email\n	$substitutionarray = array(\n		\'__BUYER_NAME__\' => strtoupper($_SESSION[\'user\'][\'pseudo\']),\n		\'__ORDER_REF__\' => $order->ref,\n		\'__ORDER_DATE__\' => dol_print_date($order->date, \'day\'),\n		\'__PRODUCTS__\' => $products_list\n	);\n	//marketplace_send_email(151, $customer, $customer->login, $substitutionarray);\n	return marketplace_send_email(getDolGlobalInt(\"MARKETPLACE_BUYER_ORDER_CONFIRMATION_TEMPLATE\"), \'order_send\', $customer, $customer->login, $substitutionarray);\n\n    dol_syslog(\"marketplaceNotifySellersBuyerByEmail: end\");\n}\n\n\n?>',1,'2024-05-22 11:22:17',NULL,'2025-01-23 21:38:08',NULL,NULL,'library','',NULL,'','',NULL,'','',0,NULL,NULL),
