(122,37,'message-de-bienvenue','','message de bienvenue','message de bienvenue','','<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=\"https://www.dolistore.com/modules/editorial/img/homepage_logo_1.jpg\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\">\n        <h3></h3>\n        <h3>Bienvenue</h3>\n        <p>Ce site est la place de marché officielle pour trouver des modules et extensions au projet <a\n                href=\"http://www.dolibarr.fr\" target=\"_blank\">Dolibarr ERP/CRM</a>.</p>\n        <ul>\n            <li><span style=\"color: #bf6c00;\"><strong>Si vous êtes utilisateur de Dolibarr</strong></span> :</li>\n        </ul>\n        <p>Vous pouvez rechercher des fonctionnalités supplémentaires et trouver des modules ou extensions diverses.\n            Naviguer dans les categories pour trouver votre extension ou utiliser le formulaire de recherche en haut de la\n            page...</p>\n        <p>La plupart des extensions/modules sont gratuits, certains sont payants (Les adhérents à l\'<a\n                title=\"Dolibarr foundation\" href=\"https://asso.dolibarr.org\" target=\"_blank\">association Dolibarr</a>\n            peuvent bénéficer de 20% de réduction si la demande est faite à l\'association une fois le compte DoliStore créé\n            et avant l\'achat)</p>\n        <ul>\n            <li><strong><span style=\"color: #bf6c00;\">Si vous êtes développeur :</span></strong></li>\n        </ul>\n        <p>Vous pouvez soumettre vos modules à la vente au prix de votre choix (ou gratuit). Pour cela, il vous suffit de\n            créer un compte, et soumettre votre module.</p>\n        <p></p>\n    </div>\n  </div>\n</section>',1,'2024-05-12 10:58:10',NULL,'2024-09-16 17:48:40',NULL,NULL,'banner','fr',148,'','',NULL,'','',0,NULL,NULL),
(123,37,'messaggio-di-benvenuto','','messaggio di benvenuto','messaggio di benvenuto','','<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=\"https://www.dolistore.com/modules/editorial/img/homepage_logo_1.jpg\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\"><h3></h3>\n        <h3>Benvenuto</h3>\n        <p>Questo è il marketplace ufficiale dove trovare moduli e plugin per&nbsp;<a href=\"https://www.dolibarr.org\" target=\"_blank\">Dolibarr ERP/CRM</a>.</p>\n        <ul>\n        <li>Se sei un utente Dolibarr:</li>\n        </ul>\n        <p>Puoi cercare funzionalità aggiuntive e trovare vari moduli o estensioni. Sfoglia&nbsp;le categorie o usa il modulo di ricerca in alto&nbsp;per trovare il plugin&nbsp;adatto alle tue necessità...</p>\n        <p>Molti modulsono gratuiti, altri sono a pagamento (I soci della <a href=\"https://asso.dolibarr.org\">Dolibarr Foundation</a>&nbsp;hanno diritto ad uno sconto del 20% facendo richiesta all\'associazione dopo aver creato il proprio account DoliStore. Per ricevere lo sconto del 20% bisogna attendere l\'approvazione della richiesta prima di effettuare gli acquisti)</p>\n        <ul>\n        <li><strong>Se sei uno sviluppatore:</strong></li>\n        </ul>\n        <p>Puoi pubblicare i tuoi moduli stabilendo&nbsp;tu il prezzo (se è gratis ancora meglio). Ti basta creare un account e inviare il tuo modulo usando il menu a sinistra.</p>\n        <p></p>\n    </div>\n  </div>\n</section>',1,'2024-05-12 11:59:51',NULL,'2024-09-16 17:48:53',NULL,NULL,'banner','it',148,'','',NULL,'','',0,NULL,NULL),
(124,37,'myaccount','','myaccount','','','<?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$action = GETPOST(\'action\', \'alpha\');\nsession_start(); // start session\nif(!empty($action) && $action == \"logout\"){\n    unset($_SESSION[\'user\']);\n    redirectToContainer(\'index\');\n}\nif(empty($_SESSION[\'user\'][\'id_user\'])){\n    redirectToContainer(\'login-register\');\n}\n// END PHP \n?>\n<div id=\"page\">\n  <div class=\"header-container\">\n    <?php\n        includeContainer(\'header\');\n        $__PAGE__TITLE__ = $weblangs->trans(\"myAccountPageTitle\");\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(\"myAccount\"); ?>\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 id=\"my-account\">\n                <h1 class=\"page-heading\"><?php print $weblangs->trans(\"myAccount\"); ?></h1>\n                <p class=\"info-account\"><?php print $weblangs->trans(\"welcomeToYourAccount\"); ?></p>\n                <div class=\"row addresses-lists\">\n                	<div class=\"col-xs-12 col-sm-6 col-lg-6\">\n                		<ul class=\"myaccount-link-list\">\n                		    <li><a href=\"account-information.php\" title=\"<?php print $weblangs->trans(\"personalInfo\"); ?>\"><i class=\"icon-user\"></i><span><?php print $weblangs->trans(\"personalInfo\"); ?></span></a></li>\n                            <li><a href=\"order-history.php\" title=\"<?php print $weblangs->trans(\"orderHistoryDetails\"); ?>\"><i class=\"icon-list-ol\"></i><span><?php print $weblangs->trans(\"orderHistoryDetails\"); ?></span></a></li>\n                        </ul>\n                	</div>\n                	<div class=\"col-xs-12 col-sm-6 col-lg-6\">\n                        <ul class=\"myaccount-link-list\">\n                		    <li><a href=\"edit-module-product.php\" title=\"<?php print $weblangs->trans(\"newModuleProduct\"); ?>\"><i class=\"icon-add\"></i><span><?php print $weblangs->trans(\"newModuleProduct\"); ?></span></a></li>\n                		    <li><a href=\"manage-products.php\" title=\"<?php print $weblangs->trans(\"manageProducts\"); ?>\"><i class=\"icon-manage\"></i><span><?php print $weblangs->trans(\"manageProducts\"); ?></span></a></li>\n                            <li><a href=\"income-payments.php\" title=\"<?php print $weblangs->trans(\"incomeAndPayments\"); ?>\"><i class=\"icon-euro\"></i><span><?php print $weblangs->trans(\"incomeAndPayments\"); ?></span></a></li>\n                        </ul>\n                    </div>\n                </div>\n                <ul class=\"footer_links clearfix\">\n                    <li><a class=\"btn btn-default button button-small\" href=\"https://www.dolistore.com/\" title=\"<?php print $weblangs->trans(\"home\"); ?>\"><span><i class=\"icon-chevron-left\"></i> <?php print $weblangs->trans(\"home\"); ?></span></a></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-03-18 12:14:17',NULL,'2024-09-20 19:50:06',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(125,37,'myproducts','','myproducts','','','',1,'2024-06-30 13:45:26',NULL,'2024-06-30 13:45:26',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(126,37,'nota-legale-chi-siamo','','Nota legale - Chi siamo','','','<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                <section id=\"Legal_notice_section\" contenteditable=\"true\">\n				    <div class=\"rte\">\n                    	<h2>Chi siamo – Informativa sulla privacy</h2>\n                    	<p><span>Ultimo aggiornamento: 09-03-2024</span></p>\n                    	<p></p>\n                    	<h3>Presentazione</h3>\n                    	<p>L\'associazione Dolibarr offre la piattaforma DoliStore per aiutare venditori e acquirenti a incontrarsi. La\n                    		fondazione offre esclusivamente il servizio di visibilità dei prodotti venduti. La fondazione non garantisce\n                    		nulla sulla qualità dei prodotti acquistati dal cliente.</p>\n                    	<p>L\'associazione DOLIBARR, tramite DOLISTORE, raccoglie per conto di<br>pagamenti agli autori/editori per i beni\n                    		venduti e gestisce il pagamento dei fondi loro dovuti. In quanto tale, l\'associazione agisce in regime di\n                    		esenzione dall\'approvazione degli istituti di pagamento prevista dall\'articolo L521-3 I 2° del Codice monetario\n                    		e finanziario.</p>\n                    	<h3>L\'associazione Dolibarr</h3>\n                    	<p>L\'associazione Dolibarr è un\'associazione francese (legge 1901) creata per contribuire alla promozione e allo\n                    		sviluppo del software ERP e CRM Open Source Dolibarr.</p>\n                    	<p>Informazioni legali sulla fondazione:</p>\n                    	<ul>\n                    		<li>WALDEC: W452006878</li>\n                    		<li>SIRENA: 52033993800018</li>\n                    		<li>NAF: 9499Z</li>\n                    	</ul>\n                    	<p>Maggiori informazioni alla pagina <a href=\"https://asso.dolibarr.org/index.php/Dolibarr_foundation\"\n                    			target=\"_blank\">https://asso.dolibarr.org/index.php /Dolibarr_foundation </a></p>\n                    	<p></p>\n                    	<h3>Host di questo sito web</h3>\n                    	<p>Questo sito web è ospitato da OVH, 2 rue Kellermann - 59100 Roubaix - Francia</p>\n                    	<p></p>\n                    	<p></p>\n                    	<h2>1. Informazioni che raccogliamo</h2>\n                    	<p>Potremmo raccogliere i seguenti tipi di informazioni quando utilizzi DoliStore:</p>\n                    	<p></p>\n                    	<ul>\n                    		<li><strong>Informazioni fornite dall\'utente</strong>:<br>DoliStore raccoglie il tuo nome, indirizzo, partita\n                    			IVA, email e password dell\'account. Salviamo anche l\'elenco dei moduli che hai acquistato sulla piattaforma\n                    			con il prezzo.<br><br></li>\n                    		<li><strong>Informazioni raccolte automaticamente</strong>:<br>DoliStore utilizza Matomo per il suo strumento\n                    			statistico. Non vengono raccolti dati privati ​​(anche il tuo indirizzo IP è reso anonimo.</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>2. Come utilizziamo le informazioni</h2>\n                    	<p>Le informazioni raccolte vengono utilizzate per scopi di fatturazione.</p>\n                    	<ul>\n                    		<li>Queste informazioni sono archiviate nel nostro database.</li>\n                    		<li>Puoi modificare queste informazioni per il tuo account</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>3. Condivisione delle informazioni</h2>\n                    	<ul>\n                    		<li>Nessun dato viene condiviso con altre terze parti. Solo i membri del team del consiglio di amministrazione\n                    			della Fondazione Dolibarr, con accesso al back office, hanno accesso alle informazioni raccolte.</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>4. Sicurezza dei dati</h2>\n                    	<p>Adottiamo misure ragionevoli per proteggere le informazioni da accesso, modifica, divulgazione o distruzione non\n                    		autorizzati. Le password degli account vengono archiviate utilizzando un hash irreversibile nel database.</p>\n                    	<p></p>\n                    	<h2>5. I tuoi diritti</h2>\n                    	<p>Hai il diritto di accedere, modificare o eliminare le tue informazioni personali conservate dal sito web.\n                    		Consulta la sezione \"Contattaci\" per questo.</p>\n                    	<p></p>\n                    	<h2>6. Modifiche alla nostra politica sulla privacy</h2>\n                    	<p>Potremmo aggiornare la presente informativa sulla privacy di tanto in tanto. Ti informeremo di eventuali\n                    		modifiche pubblicando la nuova politica sulla privacy in questa pagina.</p>\n                    	<p></p>\n                    	<h2>7. Contattaci</h2>\n                    	<p>Il titolare della protezione dei dati (DPD) ai sensi della legge GDPR è il <strong>Presidente della fondazione\n                    			Dolibarr</strong>. Dovresti trovare il suo nome su questa pagina: <a\n                    			href=\"https://wiki.dolibarr.org/index.php/Office_and_Board_Members\">https://wiki.dolibarr.org/index.php/Office_and_Board_Members</a>\n                    	</p>\n                    	<p>Se avete domande riguardanti la presente informativa sulla privacy, contattateci all\'indirizzo:\n                    		<b>dolistore@dolibarr.org</b></p>\n                    	<p></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 19:20:07',NULL,'2024-05-06 20:59:08',NULL,NULL,'page','it',97,'','',NULL,'','',0,NULL,NULL),
(127,37,'order','','order','','','<?php // BEGIN PHP\nsession_start(); // start session\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 \n?>\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			<!--  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> <?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				<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(\"cartSummary\"); ?>\n						<span class=\"heading-counter\"><?php print $weblangs->trans(\"yourCartContains\"); ?>:\n    						<?php if ($_SESSION[\'products\']): ?>\n                                <span class=\"ajax_cart_no_product\"><?php print count($_SESSION[\'products\']); ?></span> <?php if(count($_SESSION[\'products\']) > 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\']): ?>\n                            <p class=\"alert alert-warning\"><?php print $weblangs->trans(\"cartIsEmpty\"); ?></p>\n                        <?php else: ?>\n							<div id=\"order-detail-content\" class=\"table_block table-responsive\">\n							    \n							    <?php if (getDolGlobalInt(\"MARKETPLACE_BLOCK_SALES\")): ?>\n                                    <div class=\"block-sells-notification\">\n                                        <?php print $weblangs->trans(\"marketplacePurchasesDisabled\"); ?>\n                                    </div>\n                                <?php endif ?>\n                                \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\"><?php print $weblangs->trans(\"unitPrice\"); ?></th>\n											<th class=\"cart_quantity item\"><?php print $weblangs->trans(\"quantity\"); ?></th>\n											<th class=\"cart_total item\"><?php print $weblangs->trans(\"total\"); ?></th>\n											<th class=\"cart_delete last_item\">&nbsp;</th>\n										</tr>\n									</thead>\n									\n									<tbody>\n                                        <?php $total = 0; ?>\n                                        <?php foreach ($_SESSION[\'products\'] as $cart_product): ?>\n                                            <tr id=\"product_<?php print $cart_product[\'product_id\']; ?>\" class=\"cart_item\">\n    											<td class=\"cart_product\">\n    												<a href=\"product.php?id=<?php print $cart_product[\'product_id\']; ?>\"><img src=\"<?php print $cart_product[\'product_thumb\']; ?>\" id=\"product_img_<?php print $cart_product[\'product_id\']; ?>\" alt=\"<?php print $cart_product[\'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 $cart_product[\'product_id\']; ?>\"><?php print $cart_product[\'product_name\']; ?></a></p>\n    												<small class=\"cart_ref\"><?php print $weblangs->trans(\"sku\"); ?> : <?php print $cart_product[\'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 $cart_product[\'product_id\']; ?>\"><?php print price($cart_product[\'product_price\']); ?></span> €</span>\n    											</td>\n    \n    											<td class=\"cart_quantity text-center\">\n    \n    												<input type=\"hidden\" value=\"1\" name=\"quantity_<?php print $cart_product[\'product_id\']; ?>_hidden\">\n    												<input size=\"2\" type=\"text\" autocomplete=\"off\" class=\"cart_quantity_input form-control grey\" value=\"<?php print $cart_product[\'product_qty\']; ?>\" name=\"quantity_<?php print $cart_product[\'product_id\']; ?>\">\n    												<div class=\"cart_quantity_button clearfix\">\n    													<a rel=\"nofollow\" class=\"product_quantity_down btn btn-default button-minus button-minus-order\" id=\"cart_quantity_down\" data-field-qty=\"quantity_<?php print $cart_product[\'product_id\']; ?>\" data-ref=\"<?php print $cart_product[\'product_id\']; ?>\" href=\"\" title=\"<?php print $weblangs->trans(\"subtract\"); ?>\">\n    														<span><i class=\"icon-minus\"></i></span>\n    													</a>\n    													<a rel=\"nofollow\" class=\"product_quantity_up btn btn-default button-plus button-plus-order\" id=\"cart_quantity_up\" data-field-qty=\"quantity_<?php print $cart_product[\'product_id\']; ?>\" data-ref=\"<?php print $cart_product[\'product_id\']; ?>\" href=\"\" title=\"<?php print $weblangs->trans(\"add\"); ?>\"><span><i class=\"icon-plus\"></i></span></a>\n    												</div>\n    											</td>\n    											<td class=\"cart_total\" data-title=\"Total\">\n    												<span class=\"price\"><span class=\"total_line\" id=\"total_product_price_<?php print $cart_product[\'product_id\']; ?>\"><?php print price($cart_product[\'product_price\']*$cart_product[\'product_qty\']); ?></span> €</span>\n    											</td>\n    											<td class=\"cart_delete text-center\" data-title=\"Delete\">\n    												<div>\n    													<a rel=\"nofollow\" title=\"<?php print $weblangs->trans(\"delete\"); ?>\" class=\"cart_quantity_delete ajax_cart_block_remove_link\" data-code=\"<?php print $cart_product[\'product_id\']; ?>\" href=\"\"><i class=\"icon-trash\"></i></a>\n    												</div>\n    											</td>\n    										</tr>\n										\n                                            	\n                                            <?php\n                                                $subtotal = ($cart_product[\'product_price\'] * $cart_product[\'product_qty\']);\n                                                $total = ($total + $subtotal);\n                                            ?>\n                                        <?php endforeach ?>\n										\n									</tbody>\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($total); ?></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($total); ?></span> €</span>\n											</td>\n										</tr>\n									</tfoot>\n								</table>\n							</div>\n\n							<p class=\"cart_navigation clearfix\">\n							    <?php if (!getDolGlobalInt(\"MARKETPLACE_BLOCK_SALES\")): ?>\n                                    <a href=\"payment.php\" class=\"button btn btn-default standard-checkout button-medium\" title=\"<?php print $weblangs->trans(\"LoginCheckout\"); ?>\">\n    									<span><?php print $retVal = (empty($_SESSION[\'user\'][\'id_user\'])) ? $weblangs->trans(\"LoginCheckout\") : $weblangs->trans(\"proceedToCheckout\") ; ?><i class=\"icon-chevron-right right\"></i></span>\n    								</a>\n                                <?php endif ?>\n\n								<a href=\"\" onclick=\"history.go(-1)\" 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							</p>\n\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>',1,'2024-03-26 14:44:16',NULL,'2024-11-07 15:09:34',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(128,37,'order-details','','order details','','','<?php // BEGIN PHP\nsession_start(); // start session\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\';\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 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        // 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        $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        $ecmfile = new EcmFiles($db);\n    	$result = $ecmfile->fetch($invoice_pdf_id);\n    	if ($result > 0) {\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    } 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                    		<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                    		</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                    	<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(\"totalTaxExcl\"); ?> </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(\"total\"); ?></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(\"sku\"); ?> : <?php print $product->ref; ?></small>\n    											</td>\n    											<td class=\"download_icon\">\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    												<p><a target=\"_blank\" href=\"<?php print $url_attached_file; ?>\"><i class=\"icon-cloud-download\"></i></a></p>\n    											</td>\n                        						<td class=\"return_quantity\">\n                        							<span class=\"order_qte_span\"><?php print $line->qty; ?></span>\n                        						</td>\n                        						<td>\n                        						    <p><?php print price($line->price); ?> €</span></p>\n                        						</td>\n                        						<td>\n                        							<p><?php print price($line->total_ttc); ?> €</span></p>\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,'2024-12-27 17:28:55',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(129,37,'order-history','','order history','','','<?php // BEGIN PHP\nsession_start(); // start session\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\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// 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        // 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 = \".$customer_id.\" AND fk_website = \".$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_commande, c.module_source \";\n$sql_find_orders .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n$sql_find_orders .= \"WHERE c.fk_soc = \" . $customer_id . \" and 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                                                    if ($last_invoice_object instanceof Facture) {\n                                                        $invoice_object = $last_invoice_object;\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    												$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 = \" . $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=\" . $obj_invoice_pdf->share;\n    \n                                                } else {\n    												$payment_method = \"/\";\n    												$invoice_pdf_link = \"#\";\n                                                }\n                                            ?>\n                        					<tr class=\"item\">\n                        					    <td>\n                        						    <p><small class=\"cart_ref\"><?php print $order_object->ref; ?></small>\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><?php print dol_print_date($order_object->date, \'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>\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 $weblangs->trans(\"invoicePdf\"); ?></a>\n                                                		</p>\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,'2024-12-27 17:20:20',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(130,37,'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 la banca&nbsp;Caisse d\'Epargne.</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,'2024-05-06 22:13:51',NULL,NULL,'page','it',96,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(131,37,'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 pourqoi 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 la banque Caisse d\'Epargne.</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,'2024-05-06 22:11:16',NULL,NULL,'page','fr',96,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(132,37,'payment','','payment','','','<?php\nsession_start(); // start session\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				<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 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.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) {\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 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                                        	dol_print_error($db, $thirdparty_buyer->error);\n                                        	exit;\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                            				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                                    $result = $com->valid($user);\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();\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                            \n                            \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(\"unitPrice\"); ?></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(\"total\"); ?></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                                        \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\")): ?>\n    							<div id=\"HOOK_PAYMENT\">\n    							    <?php $current_lang = $_SESSION[\'lang\'][\'code\']; ?>\n    							    <?php require_once DOL_DOCUMENT_ROOT.\'/core/lib/payments.lib.php\'; ?>\n        				            <iframe frameborder=\"0\" style=\"overflow:hidden;height:100%;width:100%\" height=\"100%\" width=\"100%\" src=\"<?php print getOnlinePaymentUrl(0,\'order\', $commande->ref); ?>&ws=<?php print $website->ref; ?>&lang=<?php print $current_lang; ?>\"></iframe>\n    							</div>\n    						<?php else: ?>\n    						    <div class=\"block-sells-notification\">\n                                    <?php print $weblangs->trans(\"marketplacePurchasesDisabled\"); ?>\n                                </div>\n    						<?php endif ?>\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,'2024-12-27 17:55:48',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(133,37,'paymentok','','paymentok','','','<?php // BEGIN PHP\nsession_start(); // start session\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\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.\';\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.\';\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.\';\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=\'.$order_ref;\n} else {\n	$url_order_details = DOL_URL_ROOT.\'/public/website/index.php?website=\'.urlencode($website->ref).\'&pageref=order-details&ref=\'.$order_ref;\n}\n?>\n\n<?php //$url_order_details = DOL_URL_ROOT.\'/public/website/index.php?website=\'.$website->ref.\'&pageref=order-details&ref=\'.$order_ref; ?>\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>',1,'2024-04-22 12:33:58',NULL,'2024-12-11 09:32:01',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(134,37,'product','','product','product','','<?php // BEGIN PHP\nsession_start(); // start session\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                  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\">\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                      <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\">\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(strtotime($product->date_creation) > strtotime(\'-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 endif ?>\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                      <!-- \n\n\n	<br><b>This module has not been sold enough or has been on sale for a too short to have statistics</b><li id=\"left_share_fb\"><a href=\"http://www.facebook.com/sharer.php?u=https%3A%2F%2Fwww.dolistore.com%2Fen%2Fmodules%2F1998-Advanced-Notifier.html&amp;t=Advanced+Notifier\" class=\"_blank\">Share on Facebook!</a></li> -->\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=\"<?php print $url_attached_file; ?>\" 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 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> <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 $product->date_creation; ?></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 $product->date_modification; ?></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    <script src=\"/document.php?modulepart=medias&file=js/all.js\"></script>\n\n  </body>\n</html>',1,'2024-02-02 16:48:47',NULL,'2024-12-04 12:48:31',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),
(135,37,'product-statistics','','product statistics','','','<?php // BEGIN PHP\nsession_start(); // start session\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 \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\' \";\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,'2024-12-27 16:44:36',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(136,37,'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\n//$db->query(\"SET SESSION sql_mode = (SELECT REPLACE(@@session.sql_mode, \'ONLY_FULL_GROUP_BY\', \'\'))\");\n\n\n$root_cat_object = new Categorie($db);\n\nif(GETPOST(\'cat\', \'alpha\')){\n	$root_category_id = GETPOST(\'cat\', \'alpha\');\n}\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\n$search_words = GETPOST(\'search_query\', \'alpha\');\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 .= \" OR \";\n        }\n        $value = $db->escape($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                    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\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		$result = $root_cat_object->fetch(getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\"));\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 = \" . $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 = \" . $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($root_category_id == getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\") && empty($tag) && empty($search_words) && empty(GETPOST(\'cat\', \'alpha\')) && empty($list)){\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__ = $root_cat_object->label;\n                    $__PAGE__DESC__ = $root_cat_object->description;\n    		    ?>\n    			<!-- Category image -->\n    			<div class=\"content_scene_cat_bg\">\n    				<div class=\"cat_desc\">\n    					<span class=\"category-name\"><?php print $root_cat_object->label; ?></span>\n    					<div class=\"rte\">\n    						<p><?php print $root_cat_object->description; ?></p>\n    					</div>\n    				</div>\n    			</div>\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 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 class=\"display-title\"><section id=\"grid_list_bottom_section\" contenteditable=\"true\"><?php print $weblangs->trans(\"view\"); ?></section></li>\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				<label for=\"selectProductSort\"><?php print $weblangs->trans(\"sortBy\"); ?></label>\n				<div class=\"\" id=\"uniform-selectProductSort\" style=\"width: 190.4px;\">\n				<!--<span style=\"width: 180.4px; user-select: none;\">Price: Lowest first</span>-->\n				<select id=\"selectProductSort\" class=\"selectProductSort form-control\">\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				<label for=\"nb_item\"> <?php print $weblangs->trans(\"show\"); ?> </label>\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><?php print $weblangs->trans(\"perPage\"); ?></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);\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        			<div class=\"left-block\">\n        			<div class=\"product-image-container\">\n        				<a class=\"product_img_link\" href=\"product.php?id=<?php print $product->id; ?>\" 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 $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_escape_htmltag($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=\"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,'2024-12-18 19:39:23',NULL,NULL,'blogpost','',NULL,'','',NULL,'','',0,NULL,NULL),
(137,37,'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\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				    <div class=\"rte\">\n                    	<h2>Über uns – Datenschutzrichtlinie</h2>\n                    	<p><span>Letzte Aktualisierung: 09.03.2024</span></p>\n                    	<p></p>\n                    	<h3>Präsentation</h3>\n                    	<p>Der Dolibarr-Verband bietet die DoliStore-Plattform an, um Verkäufern und Käufern die Begegnung zu erleichtern.\n                    		Die Stiftung bietet lediglich den Sichtbarkeitsservice für die verkauften Produkte an. Die Stiftung übernimmt\n                    		keine Gewähr für die Qualität der vom Kunden erworbenen Produkte.</p>\n                    	<p>Der Verein DOLIBARR erhebt über DOLISTORE im Namen von<br>Er zahlt den Autoren/Verlegern die verkauften Waren und\n                    		verwaltet die Zahlung der ihnen zustehenden Beträge. Als solcher handelt der Verein im Rahmen der Befreiung von\n                    		der Zulassung als Zahlungsinstitut gemäß Artikel L. 521-3 I Nr. 2° des Währungs- und Finanzgesetzbuchs.</p>\n                    	<p></p>\n                    	<h3>Der Dolibarr-Verein</h3>\n                    	<p>Der Verein Dolibarr ist ein französischer Verein (Gesetz 1901), der gegründet wurde, um zur Förderung und\n                    		Entwicklung der Open-Source-ERP- und CRM-Software Dolibarr beizutragen.</p>\n                    	<p>Rechtliche Informationen zur Stiftung:</p>\n                    	<ul>\n                    		<li>WALDEC: W452006878</li>\n                    		<li>SIREN: 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\"\n                    			target=\"_blank\">https://asso.dolibarr.org/index.php /Dolibarr_foundation </a></p>\n                    	<p></p>\n                    	<h3>Host dieser Website</h3>\n                    	<p>Diese Website wird von OVH, 2 rue Kellermann – 59100 Roubaix – Frankreich gehostet</p>\n                    	<p></p>\n                    	<p></p>\n                    	<h2>1. Von uns erfasste Informationen</h2>\n                    	<p>Wir erfassen möglicherweise die folgenden Arten von Informationen, wenn Sie DoliStore nutzen:</p>\n                    	<p></p>\n                    	<ul>\n                    		<li><strong>Vom Benutzer bereitgestellte Informationen</strong>:<br>DoliStore erfasst Ihren Namen, Ihre Adresse,\n                    			Ihre Umsatzsteuer-Identifikationsnummer, Ihre E-Mail-Adresse und Ihr Kontopasswort. Wir speichern auch die\n                    			Liste der Module, die Sie auf der Plattform gekauft haben, mit dem Preis.<br><br></li>\n                    		<li><strong>Automatisch erfasste Informationen</strong>:<br>DoliStore nutzt Matomo für sein Statistiktool. Es\n                    			werden keine privaten Daten erfasst (auch Ihre IP-Adresse wird anonymisiert).</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>2. Wie wir Informationen verwenden</h2>\n                    	<p>Die gesammelten Informationen werden zu Abrechnungszwecken verwendet.</p>\n                    	<ul>\n                    		<li>Diese Informationen werden in unserer Datenbank gespeichert.</li>\n                    		<li>Sie können diese Informationen für Ihr Konto ändern</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>3. Informationsaustausch</h2>\n                    	<ul>\n                    		<li>Es werden keine Daten an Dritte weitergegeben. Nur Mitglieder des Vorstandsteams der Dolibarr Foundation mit\n                    			Zugang zum Backoffice haben Zugriff auf die gesammelten Informationen.</li>\n                    	</ul>\n                    	<p></p>\n                    	<h2>4. Datensicherheit</h2>\n                    	<p>Wir ergreifen angemessene Maßnahmen, um Informationen vor unbefugtem Zugriff, Änderung, Offenlegung oder\n                    		Zerstörung zu schützen. Kontopasswörter werden mit einem irreversiblen Hash in der Datenbank gespeichert.</p>\n                    	<p></p>\n                    	<h2>5. Ihre Rechte</h2>\n                    	<p>Sie haben das Recht, auf Ihre auf der Website gespeicherten persönlichen Daten zuzugreifen, diese zu ändern oder\n                    		zu löschen. Weitere Informationen finden Sie im Abschnitt „Kontakt“.</p>\n                    	<p></p>\n                    	<h2>6. Änderungen unserer Datenschutzrichtlinie</h2>\n                    	<p>Wir können diese Datenschutzrichtlinie von Zeit zu Zeit aktualisieren. Wir werden Sie über etwaige Änderungen\n                    		informieren, indem wir die neue Datenschutzrichtlinie auf dieser Seite veröffentlichen.</p>\n                    	<p></p>\n                    	<h2>7. Kontaktieren Sie uns</h2>\n                    	<p>Der Datenschutzbeauftragte (Data Protection Owner, DPD) im Sinne des DSGVO-Gesetzes ist der <strong>Präsident der\n                    			Dolibarr-Stiftung</strong>. Seinen Namen finden Sie auf dieser Seite: <a\n                    			href=\"https://wiki.dolibarr.org/index.php/Office_and_Board_Members\">https://wiki.dolibarr.org/index.php/Office_and_Board_Members</a>\n                    	</p>\n                    	<p>Wenn Sie Fragen zu dieser Datenschutzrichtlinie haben, kontaktieren Sie uns bitte unter:\n                    		<b>dolistore@dolibarr.org</b></p>\n                    	<p></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 19:20:58',NULL,'2024-05-06 20:59:39',NULL,NULL,'page','de',97,'','',NULL,'','',0,NULL,NULL),
(138,37,'register','','register','','','<?php\n    require_once DOL_DOCUMENT_ROOT.\'/core/class/html.formcompany.class.php\';\n    $form = new Form($db);\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/modGeneratePassPerso.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_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        if (!isValidEmail($customer_email)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"emailInvalid\");\n    	}\n    	\n    	$sql  = \"select lsa.rowid \";\n        $sql .= \"from \".MAIN_DB_PREFIX.\"societe_account lsa \";\n        $sql .= \"where lsa.login = \'\". $customer_email .\"\' \";\n        $sql .= \"and lsa.fk_website = \". $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->trans(\"firstname\"));\n    	}\n    	\n    	if (ctype_alpha(str_replace(array(\"\\n\", \"\\t\", \' \'), \'\', $customer_firstname)) === false) {\n    	    $error++;\n            $error_messages[] = $weblangs->trans(\"firstnameContainsLettersOnly\");\n        }\n    	\n    	if (empty($customer_lastname)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->trans(\"lastname\"));\n    	}\n    	\n    	if (ctype_alpha(str_replace(array(\"\\n\", \"\\t\", \' \'), \'\', $customer_lastname)) === false) {\n    	    $error++;\n            $error_messages[] = $weblangs->trans(\"lastnameContainsLettersOnly\");\n        }\n    	\n    	$check_pass = new modGeneratePassPerso($db, $conf, $langs, $user);\n    	$is_valid = $check_pass->validatePassword($customer_passwd);\n    	if(!$is_valid){\n    	    $error++;\n    		$error_messages[] = $weblangs->trans(\"passwordCriteria\");\n    	}\n    	\n    	if (empty($customer_address)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->trans(\"address\"));\n    	}\n    	\n    	if (empty($customer_country)) {\n    		$error++;\n    		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->trans(\"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        	\n        	$customer->address = $customer_address;\n        	$customer->country_id = $customer_country;\n        \n        	$customer->name_alias = \'\';\n        	$customer->idprof2 = $customer_siret;\n        	$customer->idprof3 = $customer_tin;\n        	\n        	// TODO if a valid siret set define customer as a company\n        \n        	$customer->client = \'2\';\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        	$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->country_id = $customer_country;\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    				$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 = \'\" . $id_user . \"\', note_private = \'Marketplace contact for 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            	session_start(); // start session\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\'][\'email\'] = $customer_email;\n                $_SESSION[\'user\'][\'pseudo\'] = $customer->name;\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	<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\" value=\"<?php if (isset($customer_passwd)){print $customer_passwd;} ?>\">\n			</div>\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=\"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\n		</div>\n		<div class=\"account_creation\">\n			<h3 class=\"page-subheading page-subheading-login\"><?php print $weblangs->trans(\"yourCompanyInformation\"); ?></h3>\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(\"siret\"); ?></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(\"taxIdentificationNumber\"); ?></label>\n				<input type=\"text\" class=\"form-control\" id=\"tin\" name=\"tin\" value=\"<?php if (isset($customer_tin)){print $customer_tin;} ?>\">\n			</p>\n		</div>\n		<input type=\"hidden\" name=\"action\" value=\"register\">\n		<input type=\"hidden\" name=\"back\" value=\"<?php print $back; ?>\">\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 required\"><span><sup>*</sup> <?php print $weblangs->trans(\"requiredField\"); ?></span></p>\n		</div>\n	</form>\n</div>',1,'2024-03-14 13:51:50',NULL,'2024-12-23 17:20:40',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(139,37,'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 Bank Caisse d\'Epargne 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,'2024-05-06 22:15:18',NULL,NULL,'page','de',96,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(140,37,'sidebar','','sidebar','sidebar','','<?php // BEGIN PHP\n\ninclude_once \"_library_page_lib.php\";\n\n$current_lang = $_SESSION[\'lang\'][\'code\'];\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\']; ?>\" <?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\']; ?>\" <?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\">\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 .= $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; ?>\">\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 $product->label; ?>\"> <?php print $product->label; ?> </a>\n                      </h5>\n                      <p class=\"product-description truncate2\">\n                        <?php\n                        if (isset($product->description)) {\n                          print htmlspecialchars(strip_tags($product->description), ENT_QUOTES, \'UTF-8\');\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\" 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 = 1;\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 .= $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 $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 $product->label; ?>\"> <?php print $product->label; ?> </a>\n                      </h5>\n                      <p class=\"product-description truncate2\">\n                        <?php\n                        if (isset($product->description)) {\n                          print htmlspecialchars(strip_tags($product->description), ENT_QUOTES, \'UTF-8\');\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<!-- BEGIN LEFT SIDEBAR -->',1,'2024-02-02 16:48:47',NULL,'2024-10-16 15:54:14',NULL,NULL,'other','',NULL,'','',NULL,'','',0,NULL,NULL),
(141,37,'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',144,'','',NULL,'','',0,NULL,NULL),
(142,37,'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',143,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(143,37,'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),
(144,37,'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                	<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                	<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-04-19 10:28:36',NULL,'2024-05-06 21:13:45',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),
(145,37,'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',107,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(146,37,'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',143,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(147,37,'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',144,'','',NULL,'','',0,NULL,NULL),
(148,37,'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=\"https://www.dolistore.com/modules/editorial/img/homepage_logo_1.jpg\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\">\n      <h3></h3>\n      <h3>Welcome</h3>\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: #bf6c00;\">\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: #bf6c00;\">\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,'2024-09-16 17:47:55',NULL,NULL,'banner','en',NULL,'','',NULL,'','',0,NULL,NULL),
(149,37,'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=\"https://www.dolistore.com/modules/editorial/img/homepage_logo_1.jpg\"\n        alt=\"\" width=\"578\" height=\"160\" />\n    </a>\n    <div class=\"rte\">\n        <h3></h3>\n        <h3>Willkommen</h3>\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: #bf6c00;\"><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: #bf6c00;\">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,'2024-09-16 17:48:08',NULL,NULL,'banner','de',148,'','',NULL,'','',0,NULL,NULL),
(150,37,'_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(\'language\', \'alpha\')) {\n        // Get browser language\n        $browser_lang = $weblangs->getDefaultLang(1);\n\n        // Change used lang\n        $new_lang = GETPOST(\'language\', \'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        $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_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\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		}\n	}\n	else\n	{\n		//Check exctention\n		preg_match(\'/\\.([a-zA-Z0-9]+)$/\', $image[\'name\'], $reg);\n		$extention_image = strtolower($reg[1]);\n		if (! in_array($extention_image, array(\"jpg\",\"png\",\"gif\",\"jpeg\"))) {\n			$flagError = $weblangs->trans(\"errorImageFormat\", strtoupper($extention_image));\n		}\n	}\n\n	return $flagError;\n}\n/*\n* @param array 		$product 		Selected value\n* @param int	 	$id 			Id of the product\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	$supplier->fournisseur = \'1\';\n	$supplier->code_fournisseur = \'auto\';\n	$supplier->update($supplier_id, $user);\n	$result = $supplier->fetch($supplier_id);\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		$dateRef = date (\"YmdHis\");\n		$reference = \'c\'.$supplier->id.\'d\'.$dateRef;\n		$product->ref = $reference;\n		$product->barcode = \'auto\';\n	}\n\n	$product->type = $product::TYPE_SERVICE;\n	$product->status = 0;\n	\n	// New Products will be status 0\n	if ($id) {\n	    $product->status = $object[\'status\'];\n	}\n	$product->status_buy = 0;\n\n	$product->label = $object[\'name\'];\n	$product->description = $object[\'short_description\'];\n	$product->other = $object[\'description\'];\n	$product->ref_ext = \'Marketplace\';\n	$product->price = price2num($object[\'sale_price\']);\n	$product->price_base_type = \'HT\';\n	$product->tva_tx = \"20\";\n	$product->mandatory_period = !empty(GETPOST(\"mandatoryperiod\", \'alpha\')) ? 1 : 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	//$result = $product->create($user);\n\n	if ($result < 0) {\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		\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\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		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				$img = $upload_dir . \'/\' . $product->ref . \'-\' . $key_image . \'.jpg\';\n	\n				if (move_uploaded_file($value_image[\'tmp_name\'], $img) != true){\n					$error++;\n					dol_syslog(\"file copy impossible for the moment, please try again later\");\n				} else {\n					// Add thumb\n					$product->addThumbs($img);\n					\n					$filename = basename($product->ref . \'-\' . $key_image  . \'.jpg\');\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					// Add index to db\n					if (empty ($id)) {\n						addFileIntoDatabaseIndex($upload_dir, $filename, \'MARKETPLACE\', \'uploaded\', 1, $product);\n					}\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				// 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				}\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: send_an_email by Marketplace\'.\"\\r\\n\";\n\n	//$result = $customer->sendEmail($texttosend, $subjecttosend, array(), array(), array(), \"\", \"\", 0, -1, \'\', $moreinheader);\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\n	$trackid = \'conf\'.$object->id;\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;\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	$products_list = \'<ol>\';\n\n	// Find sellers\n	$sql_get_order_products = \"select cd.fk_product, cd.qty \n	from \".MAIN_DB_PREFIX.\"commandedet  cd \n	where cd.fk_commande =\" .$order_id;\n	if ($result_commande_det = $db->query($sql_get_order_products)) {\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->label.\' (x\'.$commande_det->qty.\')</li>\';\n\n			// Get product seller\n			$sql_get_seller_id = \"select lpfp.fk_soc \n				from \".MAIN_DB_PREFIX.\"product_fournisseur_price lpfp \n				where lpfp.fk_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				// Get seller email\n				$societeaccount = new SocieteAccount($db);\n				$result = $societeaccount->fetch($objsql->fk_soc);\n				$seller_email = $societeaccount->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				if ($result > 0) {\n					$substitutionarray = array(\n						\'__SELLER_NAME__\' => $seller_name,\n						\'__BUYER_NAME__\' => strtoupper($_SESSION[\'user\'][\'pseudo\']),\n						\'__ORDER_REF__\' => $order->ref,\n						\'__ORDER_DATE__\' => dol_print_date($order->date, \'day\'),\n						\'__PRODUCT__\' => $product->label,\n						\'__QTY__\' => $commande_det->qty\n					);\n					//marketplace_send_email(150, $societeaccount, $seller_email, $substitutionarray);\n					marketplace_send_email(getDolGlobalInt(\"MARKETPLACE_SELLERS_ORDER_CONFIRMATION_TEMPLATE\"), \'order_send\', $societeaccount, $seller_email, $substitutionarray);\n				}\n			}\n		}\n	}\n	$products_list .= \"</ol>\";\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\n?>',1,'2024-05-22 11:22:17',NULL,'2024-12-23 19:20:24',NULL,NULL,'library','',NULL,'','',NULL,'','',0,NULL,NULL),
(151,37,'_service_page_ajax','','ajax','','','<?php\n/* Copyright (C) 2008-2011  Laurent Destailleur\n *\n * This program is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <https://www.gnu.org/licenses/>.\n * or see https://www.gnu.org/\n */\n\nsession_start(); // start session\n/*print \'<pre>\';\nprint_r($website);\nprint \'</pre>\';\nexit;*/\n//require \"../../master.inc.php\";\ninclude_once DOL_DOCUMENT_ROOT . \'/product/class/product.class.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/website/class/website.class.php\';\ninclude_once DOL_DOCUMENT_ROOT . \'/core/lib/website.lib.php\';\nincludeContainer(\'_library_page_lib.php\');\nsetSessionLang();\n\n$website_id = getDolGlobalInt(\"MARKETPLACE_WEBSITE_ID\");\n\n$weblangs->load(\"marketplace@marketplace\");\n\n$website_object = new Website($db);\n$this_website = $website_object->fetch($website_id);\n$order_page_url = \"index.php?website=\".$website->ref.\"&pageref=order\";\n\n$product_id = GETPOST(\'product_id\', \'int\');\n$product_thumb = GETPOST(\'product_thumb\');\n$product_qty = GETPOST(\'product_quantity\', \'int\');\n\nif($product_id && $product_qty) {\n\n	$object = new Product($db);\n	$get_product = $object->fetch($product_id);\n	\n	// check discount and calculate discounted price\n    $discount = marketplace_check_discount($object->id);\n    $discounted_price = marketplace_calculate_discounted_price($object->price_ttc, $discount);\n    \n    if ($discounted_price != $object->price_ttc) {\n        $price_to_display = $discounted_price;\n    } else {\n        $price_to_display = $object->price_ttc;\n    }\n\n    $new_product[\'product_id\'] = $object->id;\n    $new_product[\'product_thumb\'] = $product_thumb;\n    $new_product[\'product_name\'] = $object->label;\n    $new_product[\'product_ref\'] = $object->ref;\n    $new_product[\'product_price\'] = $price_to_display;\n    $new_product[\'product_qty\'] = $product_qty;\n\n        if(isset($_SESSION[\'products\'])){  //if session var already exist\n\n            if(isset($_SESSION[\'products\'][$new_product[\'product_id\']])) //check item exist in products array\n            {\n                unset($_SESSION[\'products\'][$new_product[\'product_id\']]); //unset old item\n            }\n        }\n\n        $_SESSION[\'products\'][$new_product[\'product_id\']] = $new_product;	//update products with new item array\n\n    $total_items = count($_SESSION[\'products\']); //count total items\n\n    $popup_product_html = \'\n        <span class=\"cross\" title=\"Close window\"></span>\n        <h2>\n            <i class=\"icon-ok\"></i>\'.$weblangs->trans(\"ProductAddedSuccessfully\").\'\n        </h2>\n        <div class=\"product-image-container layer_cart_img\">\n            <img class=\"layer_cart_img img-responsive\" src=\"\'.$product_thumb.\'\" alt=\"\'.$object->label.\'\" title=\"\'.$object->label.\'\">\n        </div>\n        <div id=\"layer_cart_product_info\">\n            <span id=\"layer_cart_product_title\" class=\"product-name\">\'.$object->label.\'</span>\n            <span id=\"layer_cart_product_attributes\"></span>\n            <div>\n            <strong class=\"dark\">\'.$weblangs->trans(\"Quantity\").\' : </strong>\n            <span id=\"layer_cart_product_quantity\">\'.$product_qty.\'</span>\n            </div>\n            <div>\n            <strong class=\"dark\">\'.$weblangs->trans(\"total\").\' : </strong>\n            <span id=\"layer_cart_product_price\">(\'.($product_qty * $price_to_display).\' €)</span>\n            </div>\n        </div>\';\n\n    die(json_encode(array(\'items\'=>$total_items,\'popup_product_html\'=>$popup_product_html))); //output json\n\n}\n\nif(!empty(GETPOST(\'load_cart\')) && GETPOST(\'load_cart\') == 1)\n{\n    if(isset($_SESSION[\'products\']) && count($_SESSION[\'products\'])>0){ //if we have session variable\n        $cart_box = \'\';\n        $total = 0;\n        foreach($_SESSION[\'products\'] as $cart_product){ //loop though items and prepare html content\n\n            $cart_box .= \"<dl class=\\\"products\\\">\n                <dt class=\\\"item\\\" data-id=\\\"cart_block_product_\" . $cart_product[\'product_id\'] . \"\\\" style=\\\"display: block;\\\">\n                    <a class=\\\"cart-images\\\" href=\\\"product.php?id=\" . $cart_product[\'product_id\'] . \"\\\" title=\\\"\" . $cart_product[\'product_name\'] . \"\\\"><img src=\\\"\" . $cart_product[\'product_thumb\'] . \"\\\" alt=\\\"\" . $cart_product[\'product_name\'] . \"\\\"></a>\n                    <div class=\\\"cart-info\\\">\n                        <div class=\\\"product-name\\\"><span class=\\\"quantity-formated\\\"><span class=\\\"quantity\\\">\" . $cart_product[\'product_qty\'] . \"</span>&nbsp;x&nbsp;</span><a href=\\\"product.php?id=\" . $cart_product[\'product_id\'] . \"\\\" title=\\\"\" . $cart_product[\'product_name\'] . \"\\\" class=\\\"cart_block_product_name truncate3\\\">\" . $cart_product[\'product_name\'] . \"</a></div>\n                        <span class=\\\"price\\\">\" . price($cart_product[\'product_price\']) . \" €</span>\n                    </div>\n                    <span class=\\\"remove_link\\\"><a rel=\\\"nofollow\\\" class=\\\"ajax_cart_block_remove_link\\\" href=\\\"\\\" data-code=\\\"\" . $cart_product[\'product_id\'] . \"\\\"> </a></span>\n                </dt>\n            </dl>\";\n\n            $subtotal = ($cart_product[\'product_price\'] * $cart_product[\'product_qty\']);\n            $total = ($total + $subtotal);\n        }\n        $cart_box .= \'\n        <div class=\"cart-prices\">\n            <div class=\"cart-prices-line first-line last-line\">\n                <span class=\"price cart_block_total ajax_block_cart_total\">\' . $total . \' €</span>\n                <span>\'.$weblangs->trans(\"Total\").\'</span>\n            </div>\n            <p> \'.$weblangs->trans(\"priceDependCountry\").\' </p>\n        </div>\n        <p class=\"cart-buttons\">\n            <a id=\"button_order_cart\" class=\"btn btn-default button button-small\" href=\"\' . $order_page_url . \'\" title=\"Check out\" rel=\"nofollow\">\n                <span> \'.$weblangs->trans(\"cartCheckout\").\' <i class=\"icon-chevron-right right\"></i>\n                </span>\n            </a>\n        </p>\';\n        die($cart_box); //exit and output content\n    }else{\n        die(\"<p class=\'cart_block_no_products\'> No products </p>\"); //we have empty cart\n    }\n}\n\nif(!empty(GETPOST(\'load_popup_products_html\')) && GETPOST(\'load_popup_products_html\') == 1)\n{\n    if(isset($_SESSION[\'products\']) && count($_SESSION[\'products\'])>0){ //if we have session variable\n        $total = 0;\n        foreach($_SESSION[\'products\'] as $cart_product){ //loop though items and prepare html content\n            $subtotal = ($cart_product[\'product_price\'] * $cart_product[\'product_qty\']);\n            $total = ($total + $subtotal);\n        }\n        if(count($_SESSION[\'products\']) == 1){\n            $title = \'<span class=\"ajax_cart_product_txt\"> \'.$weblangs->trans(\"OneItemInCart\").\' </span>\';\n        }else{\n            $title = \'<span class=\"ajax_cart_product_txt_s\"> \'.$weblangs->trans(\"NbreProductsInCart\", count($_SESSION[\"products\"])).\' </span>\';\n        }\n        $popup_products_html = \'\n        <h2>\'.$title.\'</h2>\n        <div class=\"layer_cart_row\">\n            <strong class=\"dark\"> \'.$weblangs->trans(\"TotalProductsInCart\").\' </strong>\n            <span class=\"ajax_block_products_total\">\'.$total.\' €</span>\n        </div>\n        <div class=\"button-container\">\n            <span class=\"continue btn btn-default button exclusive-medium\" title=\"\'.$weblangs->trans(\"ContinueShopping\").\'\">\n            <span>\n                <i class=\"icon-chevron-left left\"></i>\'.$weblangs->trans(\"ContinueShopping\").\' </span>\n            </span>\n            <a class=\"btn btn-default button button-medium\" href=\"\' . $order_page_url . \'\" title=\"\'.$weblangs->trans(\"ProceedToCheckout\").\'\" rel=\"nofollow\">\n            <span> \'.$weblangs->trans(\"ProceedToCheckout\").\' <i class=\"icon-chevron-right right\"></i>\n            </span>\n            </a>\n        </div>\';\n\n        die($popup_products_html); //exit and output content\n    }\n}\n\n\n//Remove item from shopping cart\nif(!empty(GETPOST(\'remove_code\')) && isset($_SESSION[\'products\']))\n{\n    $product_code   = GETPOST(\'remove_code\'); //get the product code to remove\n\n    if(isset($_SESSION[\'products\'][$product_code]))\n    {\n        unset($_SESSION[\'products\'][$product_code]);\n    }\n\n    $total_items = count($_SESSION[\'products\']);\n    die(json_encode(array(\'items\'=>$total_items)));\n}\n\nif(!empty(GETPOST(\'action\')) && GETPOST(\'action\') == \"update_order\" && !empty(GETPOST(\'order\'))){\n    include_once DOL_DOCUMENT_ROOT . \'/ecm/class/ecmfiles.class.php\';\n    $error = 0;\n    foreach (GETPOST(\'order\') as $id_image => $position_image) {\n        $ecmfile = new EcmFiles($db);\n        $result_get_ecmfile = $ecmfile->fetch($id_image);\n        $ecmfile->position = $db->escape($position_image);\n        $result_update_ecmfile = $ecmfile->update($user);\n        if ($result_update_ecmfile < 0) {\n		    $error++;\n    	}\n    }    \n    if ($error > 0) {\n        die(json_encode(array(\'success\' => false, \'message\' => $weblangs->trans(\'errorOccurred\'))));\n	} else {\n		die(json_encode(array(\'success\' => true, \'message\' => $weblangs->trans(\'orderChanged\'))));\n	}\n\n}\n\nif ($_SERVER[\'REQUEST_METHOD\'] == \'POST\' && !empty(GETPOST(\'action\')) && GETPOST(\'action\') == \'add_product_image\' && !empty(GETPOST(\'position\')) && !empty(GETPOST(\'product_id\')) && isset($_FILES[\'file\'][\'name\'])) {\n    includeContainer(\'_library_page_lib.php\');\n    \n    $error = 0;\n    $error_messages = \'\';\n    $product = new Product($db);\n	$ret = $product->fetch(GETPOST(\'product_id\', \'int\'));\n	if ($ret < 0) {\n		$error++;\n	}\n    \n    if ($error == 0) {\n        $checkImage = checkImage($_FILES[\'file\']);\n        if ($checkImage != false) {\n            $error++;\n    	    $error_messages = $checkImage;\n        }\n    }\n    \n    if ($error == 0){\n        $upload_dir = $conf->product->multidir_output[1] . \'/\' . get_exdir(0, 0, 0, 1, $product, \'product\');\n        $img = $upload_dir . \'/\' . $product->ref . \'-image_\' . GETPOST(\'position\', \'int\') . \'.jpg\';\n        if (move_uploaded_file($_FILES[\'file\'][\'tmp_name\'], $img) != true){\n            $error++;\n            $error_messages = $weblangs->trans(\'fileCopyError\');\n        } else {\n            // Add thumb\n            $product->addThumbs($img);\n\n            // Add index to db\n            $filename = basename($product->ref . \'-image_\' . GETPOST(\'position\', \'int\')  . \'.jpg\');\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    \n    		$ecmfile->position = GETPOST(\'position\', \'int\');\n    		\n    		$result_update_ecmfile = $ecmfile->update($user);\n    \n    		if ($result_update_ecmfile < 0) {\n    			$error++;\n    		    $error_messages = $weblangs->trans(\'fileCopyError\');\n    	    }\n    	}\n    }\n    \n    if ($error > 0) {\n        die(json_encode(array(\'success\' => false, \'message\' => $error_messages)));\n	} else {\n		die(json_encode(array(\'success\' => true, \'message\' => $weblangs->trans(\'imageAdded\'))));\n	}\n}\n\nif(!empty(GETPOST(\'action\')) && GETPOST(\'action\') == \"delete_image\" && !empty(GETPOST(\'id_image\'))){\n    include_once DOL_DOCUMENT_ROOT . \'/ecm/class/ecmfiles.class.php\';\n    $id_image = GETPOST(\'id_image\');\n    $error = 0;\n    $ecmfile = new EcmFiles($db);\n    $result_get_ecmfile = $ecmfile->fetch($id_image);\n    $result_delete_ecmfile = $ecmfile->delete($user);\n    if ($result_delete_ecmfile < 0) {\n	    $error++;\n	}\n	\n    if ($error > 0) {\n        die(json_encode(array(\'success\' => false, \'message\' => $weblangs->trans(\'errorOccurred\'))));\n	} else {\n		die(json_encode(array(\'success\' => true, \'message\' => $weblangs->trans(\'imageDeleted\'))));\n	}\n\n}\n\n// Generate CVS of sells history\nif (!empty(GETPOST(\'sells_history\')) && GETPOST(\'sells_history\') == 1) {\n\n    // Get Account ID.\n    include_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\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    // Render a CSV of another customer\n    if (!empty(GETPOST(\'id_customer\')) && GETPOST(\'id_customer\') != $customer_id) {\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            $customer_id = GETPOST(\'id_customer\');\n    	}\n    }\n\n\n    // Get liste of products\n    $products_ids = array();\n    $sql = \'SELECT fk_product, MIN(datec) AS first_date FROM \'.MAIN_DB_PREFIX.\"product_fournisseur_price WHERE fk_soc = \".((int) $customer_id). \" GROUP BY fk_product ORDER BY first_date DESC\";\n    if ($result_products = $db->query($sql)) {\n    	while ($product_id = $result_products->fetch_object()) {\n            $products_ids[] = $product_id->fk_product;\n    	}\n    }\n    $products_ids_str = implode(\',\', $products_ids);\n    \n\n    /*$data_for_csv = \"SELECT s.nom as customer, c.date_commande as registred_on, sp.email, sc.label as country, c.date_commande, p.rowid as product_id ,p.label ,p.ref, d.total_ht as total_earned, d.total_ht as total_origin, c.fk_statut \";\n    $data_for_csv .= \"FROM \".MAIN_DB_PREFIX.\"commande as c, \".MAIN_DB_PREFIX.\"commandedet as d , \".MAIN_DB_PREFIX.\"product as p , \".MAIN_DB_PREFIX.\"societe as s , \".MAIN_DB_PREFIX.\"socpeople as sp , \".MAIN_DB_PREFIX.\"c_country as sc \";\n    $data_for_csv .= \"WHERE p.rowid = d.fk_product AND s.rowid = c.fk_soc AND sp.fk_soc = s.rowid AND sp.fk_pays = sc.rowid AND c.rowid = d.fk_commande and d.fk_product IN (\" . $products_ids_str . \") and d.total_ht != 0 and c.fk_statut IN (1,3) and (c.facture = 1 || c.ref_ext IS NOT NULL) and c.module_source = \'Marketplace\' \";\n    $data_for_csv .= \"ORDER BY c.date_commande DESC\";*/\n    \n    $data_for_csv = \"SELECT c.rowid as c_id, d.rowid as d_id, s.nom as customer, s.datec as registred_on, sp.email, sc.label as country, c.date_commande, \";\n    $data_for_csv .= \"p.rowid as product_id, p.label, p.ref, d.total_ht as total_earned, d.total_ht as total_origin, c.fk_statut \";\n    $data_for_csv .= \"FROM \".MAIN_DB_PREFIX.\"commande as c \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"commandedet as d ON c.rowid = d.fk_commande \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"product as p ON p.rowid = d.fk_product \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"societe as s ON s.rowid = c.fk_soc \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"societe_account as sa ON s.rowid = sa.fk_soc \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"socpeople as sp ON sp.fk_soc = s.rowid  AND sp.ref_ext = sa.rowid \";\n    $data_for_csv .= \"JOIN \".MAIN_DB_PREFIX.\"c_country as sc ON sp.fk_pays = sc.rowid \";\n    $data_for_csv .= \"WHERE d.fk_product IN (\" . $products_ids_str . \") \";\n    $data_for_csv .= \"AND d.total_ht != 0 \";\n    $data_for_csv .= \"AND c.fk_statut IN (1,3) \";\n    $data_for_csv .= \"AND (c.facture = 1 OR c.ref_ext IS NOT NULL) \";\n    $data_for_csv .= \"AND c.module_source = \'Marketplace\' \";\n    $data_for_csv .= \"ORDER BY c.date_commande DESC\";\n    //print $data_for_csv;\n    \n    //print $data_for_csv;\n\n    if ($result_data_for_csv = $db->query($data_for_csv)) {\n        $row_no = 1;\n        $data = [\n            [\'#\', \'Customer\', \'Customer date creation\', \'Customer email\', \'Customer country\', \'Date sell\', \'Product id\', \'Product label\', \'Product ref\', \'Amount earned\', \'Amount origin\', \'Note\']\n        ];\n        $current_date = new DateTime();\n        while ($row = $result_data_for_csv->fetch_object()) {\n\n            $date_commande = new DateTime($row->date_commande);\n        \n            $interval = $current_date->diff($date_commande);\n            $days_diff = $interval->days;\n            \n            if ($days_diff > 30) {\n                $status = \'validated\';\n            } else {\n                $status = \'\';\n            }\n            \n            $data[] = [\n                $row_no++,\n                $row->customer,\n                $row->registred_on,\n                $row->email,\n                $row->country,\n                $row->date_commande,\n                $row->product_id,\n                $row->label,\n                $row->ref,\n                /*price($row->total_earned),\n                price($row->total_origin),*/\n                number_format($row->total_earned, 2, \'.\', \'\'),\n                number_format($row->total_origin, 2, \'.\', \'\'),\n                $status\n            ];\n        }\n    }\n\n    $filepath = \'export_\' . date(\'Ymd\') . \'.csv\';\n\n    $fp = fopen($filepath, \'w\');\n\n    foreach ($data as $row) {\n        fputcsv($fp, $row, \';\');\n    }\n\n    fclose($fp);\n    \n    \n    print json_encode([\'filepath\' => $filepath]);\n    exit();\n}\n\nif (!empty(GETPOST(\'filepath\')) && !empty(GETPOST(\'action\')) && GETPOST(\'action\') === \'remove_csv\') {\n    $filepath = GETPOST(\'filepath\');\n    if (file_exists($filepath)) {\n        unlink($filepath);\n        echo json_encode([\'status\' => \'success\', \'message\' => \'File deleted\']);\n    } else {\n        echo json_encode([\'status\' => \'error\', \'message\' => \'file not found\']);\n    }\n}\n\n\n\n\n?>\n',1,'2024-05-22 11:20:07',NULL,'2024-12-23 18:07:45',NULL,NULL,'service','',NULL,'','',NULL,'','',0,NULL,NULL),
(152,38,'404','','404','','','<?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 = GETPOSTINT(\'cat\');\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 \n            includeContainer(\'header\');\n            $__PAGE__TITLE__ = $weblangs->trans(\"notFoundPageTitle\");\n        ?>\n      </div>\n      <div class=\"columns-container\">\n        <div id=\"columns\" class=\"container\">\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=\"e404_section\" contenteditable=\"true\">\n    			<div class=\"rte e404\">\n    				<h1>404</h1>\n                    <h2><?php print $weblangs->trans(\"pageNotFound\"); ?></h2>\n                    <p><?php print $weblangs->trans(\"pageNotFoundDesc\"); ?></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-08-19 11:40:14',NULL,'2025-01-15 22:11:36',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),
(153,38,'about-payments','','About payments','About payments','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>About payments</h2>\n					<p>&nbsp;</p>\n					<h3>When and why a payment if software has an Opensource Licence (GPL, ...) ?</h3>\n					<p>Most products available on this market place are free of charge and can be downloaded directly from this market place. No payment in required in this case.</p>\n					<p>However, some authors decide to charge something to distribute their works. There is no problem to conciliate both approaches (Price to distribute code versus OpenSource licence): The<strong> Free Software Foundation</strong>, that has created the GNU GPL Licence, one of the most used licence for OpenSource software, allow and encourage this, and provides some explanations on this page :<br><a href=\"http://www.gnu.org/philosophy/selling.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.html</a></p>\n					<p>&nbsp;</p>\n					<h3>Secure payment</h3>\n					<p>All payments are securised with SSL.</p>\n					<p>&nbsp;</p>\n					<h3>Using Visa/Mastercard/Paypal</h3>\n					<p>Payments using a credit card are provided by Stripe.</p>\n					<p>Payment using Paypal are provided by the Paypal online payment service.</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-02-02 16:48:47',NULL,'2025-01-14 01:26:28',NULL,NULL,'page','en',NULL,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(154,38,'about-us','','Legal notice - About us','About us','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                <section id=\"Legal_notice_section\" contenteditable=\"true\">\n                    \n                    \n\n<div class=\"rte\">\n		<h3>Presentation</h3>\n<p>The Dolibarr Association offers the DoliStore.com platform to help buyers and sellers connect. Only the product visibility service is provided by the foundation. The foundation does not guarantee the quality of the products purchased by the client.</p>\n<p>The Dolibarr Association, via DoliStore, collects payments for the authors/publishers of the sold goods and manages the distribution of the funds owed to them. In this capacity, the association acts under the payment institution exemption as provided by Article L521-3 I 2° of the Monetary and Financial Code.</p>\n<p>The Dolibarr Association is a French association (Law 1901) created to promote and develop the Open Source ERP and CRM software Dolibarr.</p>\n<p><strong>Legal information about the foundation:</strong></p>\n<ul>\n<li>WALDEC: W452006878</li>\n<li>SIRÈNE: 52033993800018</li>\n<li>NAF: 9499Z</li>\n</ul>\n<p>More information on the page <a href=\"https://asso.dolibarr.org/index.php/Dolibarr_foundation\">https://asso.dolibarr.org/index.php/Dolibarr_foundation</a>.</p>\n<h3>Data Protection Principles</h3>\n<p>By using the DoliStore.com website, you agree to the processing of your personal data as described in this privacy policy.</p>\n<p><strong>Our commitments to data protection principles are as follows:</strong></p>\n<ul>\n<li><strong>Lawful, fair, transparent processing:</strong> Our data processing activities have legitimate grounds. We always consider your rights before processing personal data.</li>\n<li><strong>Purpose limitation:</strong> Data processing is limited to the purpose for which the personal data was collected.</li>\n<li><strong>Data minimization:</strong> We collect and process only the minimal amount of personal data required for any purpose.</li>\n<li><strong>Storage period:</strong> Data processing is limited to a specific period. We will not retain your personal data longer than necessary.</li>\n<li><strong>Integrity:</strong> We do our best to ensure the accuracy, integrity, and confidentiality of the data.</li>\n</ul>\n<h3>Definition of Personal Data Rights</h3>\n<ul>\n<li><strong>Right to information:</strong> You must be informed if your personal data is being processed; what data is collected, where it comes from, and why and by whom it is processed.</li>\n<li><strong>Right of access:</strong> You have the right to access the data collected from/about you. This includes your right to request and obtain a copy of your collected personal data.</li>\n<li><strong>Right to rectification:</strong> You have the right to request the correction or erasure of your inaccurate or incomplete personal data.</li>\n<li><strong>Right to erasure:</strong> In certain circumstances, you can request that your personal data be erased from our records.</li>\n<li><strong>Right to restriction or objection to processing:</strong> You have the right to restrict or object to the processing of your personal data under certain conditions.</li>\n<li><strong>Right to data portability:</strong> You have the right to obtain your personal data in a machine-readable format.</li>\n<li><strong>Right to withdraw consent:</strong> You have the right to withdraw any given consent for the processing of your personal data.</li>\n</ul>\n<h3>Data We Collect</h3>\n<p><strong>Information provided by sellers:</strong></p>\n<ul>\n<li>Email address, first and last name, company name, company or tax number (VAT number), billing information.</li>\n</ul>\n<p><strong>Information provided by buyers:</strong></p>\n<ul>\n<li>Email address, first and last name, company name, company or tax number (VAT number), billing information, membership status in the association.</li>\n</ul>\n<p><strong>Note:</strong> Payment information (credit card or payment partner ID) is not collected or known by DoliStore, as it is provided directly to the payment provider.</p>\n<p><strong>Automatically collected information:</strong></p>\n<ul>\n<li>Includes information stored automatically by session or analytical cookies (based on Google and Matomo).</li>\n<li>Also includes purchase history.</li>\n</ul>\n<p><strong>Information from partners:</strong></p>\n<ul>\n<li>We do not collect information from partners.</li>\n</ul>\n<p><strong>Links to other sites:</strong></p>\n<ul>\n<li>Site pages may include embedded content (e.g., videos, images, articles, links). Embedded content from other sites behaves as if the visitor were on that other site. These sites may collect data about you (IP address, use cookies, embed third-party tracking tools) or track your interactions with embedded content if you have an account and are logged in to their site.</li>\n</ul>\n<h3>Use of Your Personal Data</h3>\n<p>We use your personal data for the following purposes:</p>\n<ul>\n<li>To identify you (login email and hashed password)</li>\n<li>To communicate with you regarding sold products for sellers or purchased products for buyers (email)</li>\n<li>To improve your seller or customer experience and respond to your inquiries (purchase or sales history)</li>\n<li>To fulfill a legal or contractual obligation (billing data)</li>\n<li>To conduct analysis and research to improve our services (anonymized browsing and consultation statistics on the website).</li>\n</ul>\n<p>We process your personal data to fulfill legal obligations and/or use your personal data as provided by law. We reserve the right to anonymize collected personal data and use such anonymized data long-term. We will only use data outside the scope of this policy if it is anonymized.</p>\n<p>We may process your personal data for other purposes not mentioned here. In that case, this document will be updated.</p>\n<h3>Data Retention Periods</h3>\n<p>For users who register on our site, we store the personal data indicated in their profile. All users can view, modify, or delete their personal information at any time.</p>\n<p>We also retain billing information as long as necessary for accounting or other legal obligations, until your request for data deletion, or the legal time for billing data.</p>\n<h3>Sharing Your Personal Data</h3>\n<p><strong>Sellers:</strong> The following buyer personal data is provided to sellers to facilitate service provision or improve the customer experience: email, first and last name, name of the purchased module, its price, and purchase date.</p>\n<p><strong>Buyers:</strong> The following seller personal data is provided to buyers to facilitate service provision or improve the customer experience: email or contact URL for module support (if the seller provides support).</p>\n<p><strong>Payment entities:</strong> To ensure third-party payment, we use the services of Stripe and Paypal. We provide them with the buyer\'s email and address. Payment method information is not stored by DoliStore but collected and stored directly by Stripe or Paypal, which informs us of the payment success or failure.</p>\n<p><strong>Legal entities:</strong> We disclose your personal data to third parties or officials when legally required.</p>\n<p><strong>Other Third Parties outside the European Economic Area:</strong> We do not transmit data to other third parties than those mentioned previously. When transferring personal information to non-EEA countries (cited previously for non-European sellers or payment entities), we ensure these transfers comply with this Notice and applicable data protection laws. We rely on European Commission adequacy decisions or use contracts with standard guarantees published by the European Commission.</p>\n<p><strong>Administrators and Moderators:</strong> The DoliStore platform is administered and moderated by members of the Dolibarr Association\'s Board of Directors. Each board member has access and modification rights to seller and buyer profile information and the sales/purchase list.</p>\n<p>The Dolibarr Association cannot be held responsible for the use that may be made of this data by sellers or any other third party with authorized access.</p>\n<h3>How We Secure Your Data</h3>\n<p>We do our best to protect your personal data.</p>\n<p><strong>Hosting: </strong>The service is hosted under the OVH SAS Public Cloud offering. RCS Lille: 537 407 926, 2, rue Kellermann, 59100 Roubaix</p>\n<p><strong>Communication encryption:</strong> We use secure protocols for data communication and transfer (e.g., HTTPS). We use anonymization and pseudonymization where appropriate.</p>\n<p><strong>Monitoring:</strong> We monitor our systems for potential vulnerabilities and attacks.</p>\n<p><strong>Backups:</strong> Regular backups are automated.</p>\n<p>Although we do our best, we cannot guarantee total information security. However, we commit to informing the competent authorities of data breaches. We will also notify you if there is a threat to your rights or interests. We will do everything reasonably possible to prevent security breaches and assist authorities in case of a breach.</p>\n<p><strong>Password:</strong> Your password is stored in an encrypted, non-reversible form (hash). If you have an account with us, you must keep your username and password confidential.</p>\n<h3>Cookies and Other Technologies We Use</h3>\n<p>We use cookies and/or similar technologies to enable user session functionality and obtain anonymous site browsing statistics.</p>\n<p>A cookie is a small text file stored on your computer (in memory or on the disk). Cookies store information used to help operate sites. We can only access cookies created by our site. You can control your cookies at the browser level. Disabling cookies may prevent you from using certain features.</p>\n<p><strong>We use cookies for the following purposes:</strong></p>\n<ul>\n<li><strong>Necessary cookies:</strong> These cookies are required to use essential features on our site, such as login and session persistence. These cookies do not collect any personal information.</li>\n<li><strong>Functionality cookies:</strong> These cookies provide functionalities that make our service more convenient and allow for more personalized features. For example, they can remember your name and email address in comment forms, so you don\'t need to re-enter this information next time.</li>\n<li><strong>Analytical cookies:</strong> These cookies are used to track the anonymous usage and performance of our website and services.</li>\n</ul>\n<p>You can delete cookies stored on your computer through your browser settings. You can also control some third-party cookies using a privacy enhancement platform such as optout.aboutads.info or youronlinechoices.com. For more information about cookies, visit allaboutcookies.org.</p>\n<h3>Contact Information - DPO</h3>\n<p>The Data Protection Officer (DPO) is the President of the Dolibarr Association. Their name is indicated on this page: <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>Any request regarding your personal data can be made by email to <a>dolistore@dolibarr.org</a>.</p>\n<h3>Modifications to This Privacy Policy</h3>\n<p>We reserve the right to make changes to this privacy policy. Last modification made on 14/05/2024.</p>\n	</div>\n	\n\n\n\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,'2025-01-13 23:22:32',NULL,NULL,'page','en',NULL,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(155,38,'account-information','','account info','','','<?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\';\nrequire_once DOL_DOCUMENT_ROOT.\'/core/class/html.formcompany.class.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/societe/class/societeaccount.class.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/core/lib/admin.lib.php\';\ninclude_once DOL_DOCUMENT_ROOT.\'/core/modules/security/generate/modGeneratePassStandard.class.php\';\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\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// Get customer 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$id_website = $website->id;\n\n// Get customer object.\n$customer = new Societe($db);\n$result = $customer->fetch($customer_id);\n\n$weblangs->loadLangs(array(\"main\", \"companies\", \"website\", \"marketplace@marketplace\"));\n\n$__PAGE__TITLE__ = $weblangs->trans(\"accountInformationPageTitle\");\n\n// Action to update\nif (GETPOST(\'email\')) {\n    $customer_firstname = GETPOST(\'firstname\');\n    $customer_lastname = GETPOST(\'lastname\');\n    $customer_email = GETPOST(\'email\');\n    $customer_lang_code = GETPOST(\'lang_code\');\n    \n    $customer_address = GETPOST(\'address\');\n    $customer_city = GETPOST(\'city\');\n    $customer_postalcode = GETPOST(\'postalcode\');\n    $customer_country = GETPOSTINT(\'country_id\');\n\n    $customer_company = GETPOST(\'company\');\n    $customer_siret = GETPOST(\'siret\');\n    $customer_tin = GETPOST(\'tin\');\n\n    \n    $customer_passwd = GETPOST(\'passwd\');\n    $customer_new_passwd = GETPOST(\'new_passwd\');\n\n    // From logged session    \n    $customer_id = $_SESSION[\'user\'][\'socid\'];\n    $contact_id = GETPOST(\'contact\');   // TODO This should come from the session\n\n    $error = 0;\n    $error_messages = array();\n	\n	if (empty($customer_firstname)) {\n		$error++;\n		$error_messages[] = $weblangs->trans(\"ErrorFieldRequired\", $weblangs->transnoentitiesnoconv(\"Firstname\"));\n	} elseif (!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(\"ErrorFieldRequired\", $weblangs->transnoentitiesnoconv(\"Lastname\"));\n	} elseif (!preg_match(\'/^[a-zA-ZÀ-ÖØ-öø-ÿ\\- ]+$/u\', $customer_lastname)) {\n	    $error++;\n        $error_messages[] = $weblangs->trans(\"lastnameContainsLettersOnly\");\n    }\n	\n\n	if (!empty($customer_passwd) && !empty($customer_new_passwd)) {\n        $sql  = \"select lsa.rowid, lsa.pass_encoding, lsa.pass_crypted, ls.nom, fk_soc \";\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.rowid = \". ((int) $user_id);\n        \n        $result = $db->query($sql);\n		$objsql = $db->fetch_object($result);\n		\n        if (!empty($objsql)) {\n    		if ($objsql->pass_encoding != \'dolistore\') {\n    			$correct_password = dol_verifyHash($customer_passwd, $objsql->pass_crypted, $objsql->pass_encoding);\n    		} else {\n    		    $dolistore_key = getDolGlobalString(\"MARKETPLACE_SECRET_KEY\");\n    		    $to_check = md5($dolistore_key.$customer_passwd);\n    		    if ($objsql->pass_crypted === $to_check) {\n    		        $correct_password = 1;\n    		    }\n    		}\n        } else {\n            $error++;\n    		$error_messages[] = $weblangs->trans(\"noValidAccount\");\n        }\n\n        if ($correct_password) {\n        	$check_pass = new modGeneratePassStandard($db, $conf, $langs, $user);\n        	$is_valid = $check_pass->validatePassword($customer_new_passwd);\n        	if (!$is_valid) {\n        	    $error++;\n        	    $weblangs->load(\"other\");\n        		$error_messages[] = $weblangs->trans(\"YourPasswordMustHaveAtLeastXChars\", (string) $check_pass->length2);\n        	}            \n        } else {\n            $customer_account = new SocieteAccount($db);\n            $result = $customer_account->fetch($user_id);\n\n            $error++;\n		    $error_messages[] = $weblangs->trans(\"currentPasswordIncorrect\");\n        }\n	} else {\n	    if (empty($customer_passwd) && !empty($customer_new_passwd)) {\n            $error++;\n		    $error_messages[] = $weblangs->trans(\"bothCurrentNewPassRequired\");\n    	}\n	}\n	\n	if (empty($customer_address)) {\n		$error++;\n		$error_messages[] = $weblangs->trans(\"fieldRequired\", $weblangs->transnoentitiesnoconv(\"Address\"));\n	}\n	\n    if (!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(\"ErrorFieldRequired\", $weblangs->transnoentitiesnoconv(\"Country\"));\n	}\n    \n    if ($error == 0) {\n        // Start of transaction\n        $db->begin();\n\n        $customer = new Societe($db);\n        $result = $customer->fetch($customer_id);\n        if ($result <= 0) {\n            print \"Third party not found using _SESSION[\'user\'][\'socid\']\";\n            exit;\n        }\n    \n    	if (!empty($customer_company)) {\n    		$customer->name = $customer_company;\n    	} elseif (empty($customer->name)) {\n    		$customer->name = dolGetFirstLastname($customer_firstname, $customer_lastname);\n    	}\n\n        if ($customer_email) {\n    	    $customer->email = $customer_email;\n        }\n\n    	$customer->address = $customer_address;\n    	$customer->town = $customer_city;\n        $customer->zip = $customer_postalcode;\n    	$customer->country_id = $customer_country;\n    \n        if (GETPOSTISSET(\'siret\')) {\n    	    $customer->idprof2 = $customer_siret;\n        }\n    	if (GETPOSTISSET(\'tin\')) {\n    	    $customer->tva_intra = $customer_tin;\n    	}\n\n        if ($customer_lang_code){\n    	    $customer->default_lang = $customer_lang_code;\n        }\n    	\n    	$result = $customer->update($customer_id, $user);\n    	if ($result < 0) {\n			$error++;\n			$error_messages[] = $weblangs->trans(\"errorOccurred\");\n		}\n    \n        if ($error == 0) {\n			// Update contact (but only if linked to a contact)\n			if ($contact_id > 0) {\n    			$contact = new Contact($db);\n    			$result = $contact->fetch($contact_id);\n    			if ($result <= 0) {\n    			    print \"Contact not found using contact_id\";\n                    exit;\n    			}\n\n    			//$contact->name_bis = $customer_lastname;\n    			if ($customer_email) {\n    			    $contact->email = $customer_email;\n    			}\n    \n    			$contact->firstname = $customer_firstname;\n    			$contact->lastname = $customer_lastname;\n    			$contact->address = $customer_address;\n    			$contact->town = $customer_city;\n    			$contact->zip = $customer_postalcode;\n    			$contact->country_id = $customer_country;\n    \n    			$ret_contact = $contact->update($contact_id, $user);\n    			if ($ret_contact < 0) {\n    				$error++;\n    			}\n			}\n\n\n			// Now update the login account to log on the website\n			if (!empty($id_website)) {\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                	$error++;\n			        $error_messages[] = $weblangs->trans(\"errorOccurred\");\n                }\n                $user->getrights();\n    \n				$societeaccount = new SocieteAccount($db);\n				$societeaccount->fetch($_SESSION[\'user\'][\'id_user\']);\n				\n				if ($societeaccount->id > 0) {\n    				$societeaccount->login = $customer_email;\n\n    				if ($customer_new_passwd) {\n    				    $societeaccount->pass_encoding = \"md5\";\n    				    $societeaccount->pass_crypted = dol_hash($customer_new_passwd, \'md5\');\n    				}\n\n    				$ret_account = $societeaccount->update($user);\n    				if ($ret_account < 0) {\n    					$error++;\n    				} else {\n    				    // Update is ok, we reload the website account\n    				    $customer_account = new SocieteAccount($db);\n                        $result = $customer_account->fetch($_SESSION[\'user\'][\'id_user\']);\n    				}\n				}\n			}\n		}\n		\n		if ($error == 0) {\n        	$db->commit();\n        } else {\n        	$db->rollback();\n        }\n    }\n		\n}\n\n\nif ($result > 0) {\n    $id_website = $website->id;\n    $marketplace_third_parties_category = getDolGlobalInt(\"MARKETPLACE_PROSPECTCUSTOMER_ID\");\n    \n    // Get contact record if we found one with same email.\n    $cContacts = $customer->contact_array_objects();\n    foreach ($cContacts as $cContact) {\n        if ($cContact->email == $customer_account->login) {\n            $customer_firstname = $cContact->firstname;\n            $customer_lastname = $cContact->lastname;\n            $customer_email = $cContact->email;\n            $contact_id = $cContact->id;\n        }\n    }\n    \n    $customer_company = $customer->name;\n    $customer_address = $customer->address;\n    $customer_city = $customer->town;\n    $customer_postalcode = $customer->zip;\n    $customer_country = $customer->country_id;\n    $customer_siret = $customer->idprof2;\n    $customer_tin = $customer->tva_intra;\n}\n\n$form = new Form($db);\n\n// END PHP \n?>\n<div id=\"page\">\n  <div class=\"header-container\">\n    <?php \n        includeContainer(\'header\');\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> <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(\"yourPersonalInfo\"); ?>\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                <div class=\"row\">\n                    <div class=\"col-xs-12\">\n                    	<form action=\"\" method=\"post\" id=\"account-creation_form\" class=\"std box\">\n                    		<div class=\"account_creation\">\n                    			<h3 class=\"page-subheading\"><?php print $weblangs->trans(\"yourPersonalInfo\"); ?></h3>\n                    			<p class=\"info-title\">\n                                    <?php print $weblangs->trans(\"beSureToUpdateProfil\"); ?>\n                                </p>\n                                \n                                <br>\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 $weblangs->trans($value); ?></li>\n                                        	<?php endforeach ?>\n                                		</ol>\n                                	</div>\n                            	<?php } ?>\n                            	\n                            	[EN] Warning - Update of firstname, lastname are not supported yet !!!!<br>\n                            	[FR] Attention - La mise à jour du nom, prénom de contact n\'est pas encore géré !!!!<br><br>\n                            	\n                    			<div class=\"required form-group\">\n                    				<label for=\"email\"><?php print $weblangs->trans(\"Login\").\'/\'.$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_account->login)){print $customer_account->login;} ?>\">\n                    			</div>\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>\n                    		\n                    		<br>\n                    		\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($customer_country ? $customer_country : \'\', \'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                    		</div>\n                    		\n                    		<br>\n                    		\n                    		<div class=\"account_creation\">\n                    			<h3 class=\"page-subheading page-subheading-login\"><?php print $weblangs->trans(\"Password\"); ?></h3>\n                    		\n                    			<div class=\"required password form-group\">\n                    				<label for=\"passwd\"><?php print $weblangs->trans(\"currentPasswd\"); ?><sup></sup></label>\n                    				<input type=\"password\" class=\"is_required validate form-control\" name=\"passwd\" id=\"passwd\" value=\"\" autocomplete=\"new-password\">\n                    			</div>\n                    			<div class=\"required password form-group\">\n                    				<label for=\"passwd\"><?php print $weblangs->trans(\"newPasswd\"); ?><sup></sup></label>\n                    				<input type=\"password\" class=\"is_required validate form-control\" name=\"new_passwd\" id=\"passwd\" value=\"\" autocomplete=\"new-password\">\n                    			</div>\n                            </div>\n                    		\n                    		<input type=\"hidden\" name=\"action\" value=\"register\">\n                    		<input type=\"hidden\" name=\"back\" value=\"<?php print $back; ?>\">\n                    		<input type=\"hidden\" name=\"contact\" value=\"<?php print $contact_id; ?>\">\n                    		<input type=\"hidden\" name=\"customer\" value=\"<?php print $customer_id; ?>\">\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(\"Save\"); ?> <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                    </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-26 13:19:51',NULL,'2025-01-17 18:59:44',NULL,NULL,'page','',NULL,'','',NULL,'','',0,NULL,NULL),
(156,38,'acerca-de-los-pagos','','Acerca de los pagos','Acerca de los pagos','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>Acerca de los pagos</h2>\n                  <p>&nbsp;</p>\n                  <h3>¿Cuándo y por qué se realiza un pago si un software tiene una licencia de código abierto (GPL, ...)?</h3>\n                  <p>La mayoría de los productos disponibles en este mercado son gratuitos y se pueden descargar directamente desde él. En este caso, no se requiere ningún pago.</p>\n                  <p>Sin embargo, algunos autores deciden cobrar algo por distribuir sus obras. No hay problema en conciliar ambos enfoques (precio para distribuir el código versus licencia de código abierto): <strong>la Fundación para el Software Libre</strong>, que ha creado la Licencia GPL de GNU, una de las licencias más utilizadas para el software de código abierto, lo permite y lo fomenta, y proporciona algunas explicaciones en esta página: </p>\n                  <p>\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>Pago seguro</h3>\n                  <p>Todos los pagos están asegurados con SSL.</p>\n                  <p>&nbsp;</p>\n                  <h3>Usando Visa/Mastercard/Paypal</h3>\n                  <p>Los pagos con tarjeta de crédito son proporcionados por Stripe.</p>\n                  <p>Los pagos utilizando Paypal son proporcionados por el servicio de pago en línea 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:12:03',NULL,'2025-01-14 01:26:42',NULL,NULL,'page','es',153,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(157,38,'acerca-de-nosotros','','Acerca de nosotros','Acerca de nosotros','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>Contact us</h2>\n				<p>The foundation offers the DoliStore platform to help seller and buyer of <a href=\"https://www.dolibarr.org\">Dolibarr ERP CRM addons </a>to meet each others. Only the service to provide visibility of product on sale is offered by the foundation. The foundation does not guarantee the quality of products the customer buy.</p>\n				<p></p>\n				<p>If you experience troubles with a module, please go on the module page to see how you can contact the support provided by the author of the module.</p>\n				<p>Only authors of module can help you. You must always contact them first for any questions and any troubles.</p>\n				<p>If after contacting the author, your problem is not solved, then, please inform the Dolibarr foundation (email: dolistore@dolibarr.org) with information about:</p>\n				<p>- description of trouble (name of module, version, version of your dolibarr)</p>\n				<p>- a summary of echange you did with the author (cust-paste of emails sent/received)</p>\n				<p>- if you got non answer, date of last contact you tried (must be higher than 7 days)</p>\n				<p>So we will be able to process your case (disable the module, refund you if necessary, ...)</p>\n				<p></p>\n				<h2></h2>\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>',0,'2024-05-06 22:07:09',NULL,'2024-05-17 14:01:11',NULL,NULL,'page','es',164,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(158,38,'breadcrumb','','breadcrumb','breadcrumb','','<?php // BEGIN PHP\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOSTINT(\'cat\');\n$search = GETPOST(\'search_query\', \'alpha\');\n// END PHP \n?>\n<?php if (!empty($cat_id)) : ?>\n  <?php\n  $current_cat = new Categorie($db);\n  $result = $current_cat->fetch($cat_id, \"\");\n  if ($result <= 0) {\n    redirectToContainer(\'404\');\n  }\n  $current_cat_label = $current_cat->label;\n  $current_cat_id = $current_cat->id;\n  $parent_current_cat = new Categorie($db);\n  $parent_current_cat->fetch($current_cat->fk_parent);\n  $parent_current_cat_label = $parent_current_cat->label;\n  $parent_current_cat_id = $parent_current_cat->id;\n  ?>\n  <section id=\"breadcrumb_section\" contenteditable=\"true\">\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>\n      <?php if (!empty($current_cat->fk_parent) && $parent_current_cat_id != getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\")) : ?>\n        <a href=\"index.php?cat=<?php print $current_cat->fk_parent; ?>\" title=\"<?php print $parent_current_cat_label; ?>\" data-gg=\"\"><?php print $parent_current_cat_label; ?></a>\n        <span class=\"navigation-pipe\">&gt;</span>\n      <?php endif ?>\n\n      <?php if ($current_cat_id == getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\")) : ?>\n        <?php print $weblangs->trans(\"newProducts\"); ?>\n      <?php else : ?>\n        <?php print $current_cat_label; ?>\n      <?php endif ?>\n    </div>\n  </section>\n<?php else : ?>\n  <?php if (!empty($search) || !empty($tag)) : ?>\n    <section id=\"breadcrumb_section\" contenteditable=\"true\">\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        <?php if (!empty($tag) && $tag == \"Specials\") : ?>\n          <span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"priceDrop\"); ?>\n        <?php else : ?>\n          <span class=\"navigation-pipe\">&gt;</span> <?php print $weblangs->trans(\"Search\"); ?>\n        <?php endif ?>\n      </div>\n    </section>\n  <?php endif ?>\n<?php endif ?>\n<!--  Breadcrumb  -->',1,'2024-02-02 16:48:47',NULL,'2025-01-17 23:22:58',NULL,NULL,'banner','',NULL,'','',NULL,'','',0,NULL,NULL),
(159,38,'conditions-generales-dutilisation','','Conditions générales d\'utilisation','Conditions générales d\'utilisation','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>Conditions générale d\'utilisation et de ventes</h2>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle n°1</h3>\n                    	<p>Les produits ou modules sont soumis par n\'importe quel fournisseur possédant un compte sur la plateforme, sans\n                    		avoir de lien nécessairement avec l\'association Dolibarr (ceci est susceptible de changer). L\'acheteur s\'engage\n                    		donc dans une relation de confiance client-fournisseur vis à vis de ce vendeur.</p>\n                    	<p><span style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">Seuls\n                    			les modules/extensions diffusés sous une <a href=\"https://opensource.org/licenses/alphabetical\"\n                    				target=\"_blank\">licence approuvée par l\'OSI</a>&nbsp;peuvent être publiés. De plus, si&nbsp;<span\n                    				style=\"font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;font-size:12px;font-style:normal;\">le\n                    				module est une oeuvre dérivée (utilise des composants ou API) de Dolibarr (cas de 99% des modules), il\n                    				doit être dans une licence<span\n                    					style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">&nbsp;compatible\n                    					avec la license GPL v3+ de Dolibarr. Si aucune licence n\'est précisé, en le publiant sur DoliStore,\n                    					vous accepter que votre module soit publié sous licence GPL v3+.</span></span></span></p>\n                    	<p><span 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;\"><span\n                    					style=\"font-style:normal;font-size:12px;font-family:\'Trebuchet MS\', Arial, Helvetica, sans-serif;\">L’association\n                    					DOLIBARR, via le DOLISTORE, collecte pour le compte des&nbsp;auteurs / éditeurs les paiements des\n                    					biens vendus et gère le reversement des&nbsp;fonds leur revenant. A ce titre, l’association agit\n                    					sous le couvert de l’exemption&nbsp;d’agrément d’établissement de paiement prévu à l’article L521-3\n                    					I 2° du code&nbsp;monétaire et financier.</span></span></span></p>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle n°2</h3>\n                    	<p>Le prix de vente de référence est fixé par le vendeur. La vente (et sa commission) ne sont toutefois validées\n                    		réellement que passé un délai de 1 mois après l\'achat (ceci afin de permettre à l\'acheteur d\'échanger avec\n                    		l\'éditeur du module en cas de difficulté). Durant ce délai, l\'association peut annuler toute vente pour toute\n                    		raison et sans nécessairement prévenir le vendeur (si tel était le cas, ceci apparaîtrait dans les statistiques\n                    		de la console d\'administration du vendeur).</p>\n                    	<p>Le prix de vente est un prix de référence Hors Taxe et non le prix définitif de vente. En effet, à ce prix est\n                    		ajouté une TVA que l\'association reverse au trésor publique. De plus, en vendant sur DoliStore, les vendeurs\n                    		acceptent que les ventes faites aux adhérents de l\'association se fassent moyennant une réduction définie par\n                    		l\'association (20%). Le prix réel d\'achat HT apparaîtra dans le détail des statistiques de ventes (Note: La\n                    		plupart des acheteurs de modules n\'étant pas adhérent, ce type de réduction est appliqué rarement).</p>\n                    	<p>L\'association Dolibarr conserve de plus 20% du montant de la vente pour assurer les frais de gestion, bancaires,\n                    		les frais d\'annulation et pour financer la promotion de Dolibarr ERP/CRM.</p>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle n°3</h3>\n                    	<p>Une fois le paiement reçu, l\'acheteur pourra télécharger les modules/produits commandés, soit depuis son espace\n                    		comptes \"Mes commandes\", soit depuis un lien reçu par mail suite à validation de son paiement.</p>\n                    	<p>Le fichier mis à disposition pour téléchargement doit avoir un packaging soumis aux règles définies sur la\n                    		page&nbsp;<a\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                    	<p>Le produit est téléchargeable sur la plateforme DoliStore pour une durée de <strong>1</strong> an après la date\n                    		de paiement.</p>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle n°4</h3>\n                    	<p>L\'acheteur ne peut en aucun cas tenir pour responsable l\'association Dolibarr quant au bon fonctionnement ou non\n                    		du produit acquis, à 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).&nbsp;L\'association se réserve le droit de dé-valider un module, ou alerter dans sa\n                    		description, si celui-ci occasionne trop de réclamations.</p>\n                    	<p>En cas de problème d\'installation ou d\'utilisation du module acheté, toute aide doit être sollicitée par\n                    		l\'acheteur auprès de l\'éditeur du module directement, via le canal d\'assistance décrit dans la description du\n                    		produit, si le fournisseur en fournit, information obligatoire dans la description du produit (si cette\n                    		information n\'est pas disponible, merci d\'alerter l\'association).</p>\n                    	<p>L\'acheteur pourra éventuellement obtenir un remboursement dans les conditions suivantes:</p>\n                    	<p>- L\'acheteur doit avoir dans un premier temps tenté de résoudre le problème via des échanges avec l\'éditeur du\n                    		module. Les mails échangés (ou simplement envoyé en cas de non réponse) avec ce denier&nbsp;devront être\n                    		transmis à l\'association pour preuve (à dolistore@dolibarr.org). Un délai&nbsp;nécessaire pour permettre ces\n                    		échanges entre l\'acheteur et l\'éditeur sera&nbsp;exigé par l\'association afin de maximiser les chances de\n                    		résolutions à l\'amiable avant le déclenchement de l\'annulation de la vente et du remboursement.</p>\n                    	<p>- L\'acheteur doit s\'être manifester pour la première fois auprès de l\'éditeur (ou de l\'association si celui ci ne\n                    		répond pas) dans un délai de 1 mois maximum après la date d\'achat (Pour info, le délai minimum de la directive\n                    		européenne 2011/83 est de 14j). Il n\'est plus possible de demander le remboursement au tiers de confiance assuré\n                    		par l\'association, le paiement ayant alors été reversé à l\'éditeur. Seule une action en direct envers l\'éditeur\n                    		est alors possible). Si les échanges n\'aboutissent pas de manière satisfaisante, l\'acheteur pourra demander un\n                    		arbitrage à l\'association. Cet arbitrage ira à l\'avantage de l\'acheteur en cas d\'impossibilité de\n                    		trancher.&nbsp;</p>\n                    	<p>&nbsp;</p>\n                    	<h3>Quand et pourquoi un paiement si le logiciel est en Open Source (GPL, ...) ?</h3>\n                    	<p>De nombreux produits disponibles sur cette place de marché sont gratuits et peuvent être téléchargés directement\n                    		depuis leur fiche. Aucun paiement dans ce cas n\'est requis.</p>\n                    	<p>Toutefois, certains auteurs décident de faire payer quelque chose en échange de la distribution de leur travail.\n                    		Il n\'y a aucun problème à concilier les 2 approches (Prix pour distribuer du code face à licence Open Source):\n                    		La <strong>Free Software Foundation</strong>, qui a créé la licence GNU GPL, une des licences pour les logiciels\n                    		libre les plus utilisées, autorise et même encourage cela en y donnant les explications, sur cette page :<br><a\n                    			href=\"http://www.gnu.org/philosophy/selling.fr.html\"\n                    			target=\"_blank\">http://www.gnu.org/philosophy/selling.fr.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:16:07',NULL,'2024-05-06 21:17:38',NULL,NULL,'page','fr',201,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(160,38,'conditions-generales-dutilisation_vendeurs-de-modules','','Conditions générales d\'utilisation - vendeurs de modules','Conditions générales d\'utilisation - vendeurs de modules','','<?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>Conditions générale d\'utilisation pour les&nbsp;vendeurs de modules</h2>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle S1</h3>\n                    	<p>Les produits ou modules sont soumis par n\'importe quel fournisseur possédant un compte sur la plateforme, sans\n                    		avoir de lien nécessairement avec l\'association Dolibarr (ceci est susceptible de changer). L\'acheteur s\'engage\n                    		donc dans une relation de confiance client-fournisseur vis à vis de ce vendeur.</p>\n                    	<p><span style=\"\">Seuls\n                    			les modules/extensions diffusés sous une <a href=\"https://opensource.org/licenses/alphabetical\"\n                    				target=\"_blank\">licence approuvée par l\'OSI</a>&nbsp;peuvent être publiés. De plus, si&nbsp;<span\n                    				style=\"\">le\n                    				module est une oeuvre dérivée (utilise des composants ou API) de Dolibarr (cas de 99% des modules), il\n                    				doit être dans une licence<span\n                    					style=\"\">&nbsp;compatible\n                    					avec la license GPL v3+ de Dolibarr. Si aucune licence n\'est précisé, en le publiant sur DoliStore,\n                    					vous accepter que votre module soit publié sous licence GPL v3+.</span></span></span></p>\n                    	<p><span style=\"\"><span\n                    				style=\"\"><span\n                    					style=\"\">L’association\n                    					DOLIBARR, via le DOLISTORE, collecte pour le compte des&nbsp;auteurs / éditeurs les paiements des\n                    					biens vendus et gère le reversement des&nbsp;fonds leur revenant. A ce titre, l’association agit\n                    					sous le couvert de l’exemption&nbsp;d’agrément d’établissement de paiement prévu à l’article L521-3\n                    					I 2° du code&nbsp;monétaire et financier.</span></span></span></p>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle S2</h3>\n                    	<p>Le vendeur, sur soumission d\'une facture, libellé en EURO, et à destination de l\'Association Dolibarr, obtiendra\n                    		le reversement des paiements reçus de la vente de ses modules par l\'association sur la base de\n                    		<strong>80%</strong> des gains reçus. La réclamation des gains ne peut toutefois se faire que<strong> 1</strong>\n                    		mois après les ventes, si le total dépasse <strong>50</strong> euros (pour les pays utilisant l\'euro),\n                    		<strong>100 </strong>euros pour les autres devises et est limitée à<strong> 1</strong> demande par mois. Le\n                    		versement peut se faire:</p>\n                    	<p>- Soit par virement SEPA sur un compte bancaire en EURO.</p>\n                    	<p>- Soit via un paiement par carte (le vendeur doit alors fournir l\'interface pour permettre le paiement)</p>\n                    	<p>- Soit par un paiement via Paypal (le vendeur doit alors fournir son compte paypal).</p>\n                    	<p>Dans tous les cas, une adresse postale valide doit être renseigné au niveau de son compte revendeur Dolistore.\n                    	</p>\n                    	<p>&nbsp;</p>\n                    	<h3>Règle S3</h3>\n                    	<p>A) Le vendeur doit renseigner dans la description de son produit toutes les informations obligatoires, à savoir:\n                    	</p>\n                    	<p><span style=\"\">* une\n                    			description courte significative de l\'apport du module.</span></p>\n                    	<p>* la version du module</p>\n                    	<p><span style=\"\">* le nom\n                    			de l\'auteur, la licence.</span></p>\n                    	<p><span style=\"\">* une\n                    			photo (une photo minimum requise, plusieurs photos juste recommandées)</span></p>\n                    	<p>* si un support est disponible et si oui, par quel canal. <span\n                    			style=\"\">Si aucun\n                    			support n\'est fourni, cela doit être indiqué, par exemple par la mention \"Pas de support disponible\"\n                    			(possible uniquement pour les modules gratuits)</span></p>\n                    	<p>* Si le module est payant, le vendeur doit obligatoirement mettre les informations de contact de support via un\n                    		canal valide (mail fonctionnel, page de support sur le site du vendeur,...) ainsi qu\'une description dans les\n                    		langues disponibles (même si c\'est un copier-coller de la description anglaise pour les langues non supportées\n                    		par exemple). Il est possible de préciser que le support n\'est valable que dans une seule langue. Un lien vers\n                    		un site de démonstration n\'est pas obligatoire mais vivement conseillé.</p>\n                    	<p>* la version de Dolibarr pour lequel il est compatible (Et la version minimale et maximale doivent être fournies.\n                    		Les valeurs doivent être du type \"x.y.z\". La valeur \"dev\" n\'est pas autorisé car ce n\'est pas une version figée,\n                    		le caractère générique * n\'est autorisé que sur la 3eme partie de la version, par exemple x.y.*).</p>\n                    	<p style=\"\">B) Règle sur\n                    		les liens ou mention à d\'autres sites</p>\n                    	<p style=\"\">* Des liens ou\n                    		mention d\'autres sites peuvent être intégrées dans la description, mais uniquement dans le champ description\n                    		longue. Le nombre de liens externes est limité à 10. Les liens peuvent renvoyer à un site Web externe proposant\n                    		l\'un des services suivants (et EXCLUSIVEMENT des services de cette liste): <strong>site de démo, page de\n                    			documentation, page de contact, page accueil d\'une société, forum, page de suivi des problèmes, liens vers\n                    			un réseau social, ou site hébergeant le code sources.</strong>&nbsp;Donc les liens externes pointant vers un\n                    		autre fichier téléchargeable à l\'extérieur de DoliStore, <strong>ou vers une autre boutique ou une page externe\n                    			proposant le module, ou d\'autres, à la vente directement depuis la page sur la page d\'arrivée ne sont pas\n                    			permis</strong>. Un lien vers une page non trouvée ou une page d\'erreur 404 ne sont également pas\n                    		permis<span>.&nbsp;</span>Si il y a un lien vers une fiche d\'un autre produit ou service, cela doit être sur la\n                    		fiche produit de DoliStore même si possible (En résumé, le lien vers un produit ou service complémentaire est\n                    		accepté uniquement si ce produit ou service n\'est pas&nbsp;vendable sur DoliStore).</p>\n                    	<p style=\"\">De plus ces\n                    		liens ne doivent pas pointer sur une&nbsp;URL (ou une URL après redirection) amenant sur un site dont le nom de\n                    		domaine ne respecte pas les règles d\'utilisation du nom \"Dolibarr\" ou \"DoliStore\" définies sur&nbsp;<a\n                    			href=\"https://wiki.dolibarr.org/index.php/R%C3%A8gles_d%27utilisation_du_nom_ou_de_la_marque_%22Dolibarr%22_(ou_%22DoliStore%22)\">cette\n                    			page</a>. Si le site ou page vers lequel pointe le lien contient lui même d\'autres lien menant indirectement\n                    		à un espace où le même module est aussi en vente, le tarif ne doit pas être inférieur à celui sur DoliStore.</p>\n                    	<p style=\"\"><span\n                    			style=\"\">C) Règle\n                    			sur le packaging</span></p>\n                    	<p style=\"\">Le fichier\n                    		package du module doit respecter certaines règles. Si les conditions décrites ici :&nbsp;<a\n                    			href=\"http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles\">http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Regles</a>&nbsp;ne\n                    		sont pas valides le module ne sera pas validé ou sera désactivé (dans ce cas le motif sera affiché sur la fiche\n                    		du module).</p>\n                    	<p style=\"\">D)\n                    		Désactivation du module</p>\n                    	<p style=\"\"><span\n                    			style=\"\">Si un de\n                    			ces points n\'est pas respecté, ou si la version de Dolibarr est trop ancienne (par exemple supporté au mieux\n                    			par une version de Dolibarr qui a plus de 10 versions majeures de retards), l\'association se réserve le\n                    			droit de supprimer la fiche produit (désactivation jusqu\'à mise en conformité), sans autre justification. Le\n                    			motif de désactivation est normalement affiché sur la fiche du module. Si un même module se retrouve à 3\n                    			reprises désactivés suite à une violation des règles précédentes, le module sera soit désactivé de manière\n                    			définitive, soit conserver mais avec un tarif forcé à zéro (en conformité avec le droit de distribuer le\n                    			module gratuitement, attribué par sa licence GPL).&nbsp;De même si l\'auteur d\'un module ne respecte pas les\n                    			règles d\'usage de la marque Dolibarr ou DoliStore (Voir <a\n                    				href=\"https://wiki.dolibarr.org/index.php?title=R%C3%A8gles_d%27utilisation_du_nom_ou_de_la_marque_%22Dolibarr%22_(ou_%22DoliStore%22)\">ici</a>),\n                    			ses modules pourront également être retirés de la vente ou conservés mais avec un tarif forcé à zéro (en\n                    			conformité avec le droit de distribuer le module gratuitement, attribué par sa licence GPL).</span></p>\n                    	<p>E) Dans le but de préserver l\'intégrité de notre place de marché en ligne et de maintenir la confiance de nos\n                    		consommateurs, nous imposons aussi des directives strictes concernant l\'utilisation de logos, labels, et\n                    		affirmations de qualité ou de quantité sur les fiches produits, via ces règles:</p>\n                    	<p>## Définition</p>\n                    	<p>*Logo de Qualité* : Tout symbole ou marque visuelle utilisé pour indiquer un niveau de qualité ou une\n                    		certification obtenue par le produit ou le vendeur.<br>*Affirmation de Qualité* : Toute déclaration écrite\n                    		affirmant des qualités spécifiques, des certifications, ou des standards de qualité relatifs au\n                    		produit.<br>*Affirmation de Quantité* : Toute déclaration écrite concernant la quantité, le volume, ou le nombre\n                    		d\'unités d\'un produit.</p>\n                    	<p>## Exigences Générales</p>\n                    	<p>Les vendeurs qui bénéficient du label Preferred Partner sont autorisé à intégré ce logo dans leur description.\n                    		Des logos de certification gérés ou obtenus par des organismes officiels tiers (organisme de normalisation, ou\n                    		de contrôle qualité d\'organisme gouvernementaux ou ONG reconnus) peuvent être autorisés au cas par cas (ex:\n                    		Certification Qualiopi, NF). Tout autre Logo ou mention superlative non quantifiable ou vérifiable ne sera pas autorisé.\n                    		De plus, l\'association se réserve le droit\n                    		(au cas par cas) ne demander le retrait d\'un logo ou affirmation, de manière définitive à un éditeur. En cas de\n                    		refus ou de réapparition régulière des logos ou phrases concernées, le module sera désactivé.</p>\n                    	<p></p>\n                    	<p style=\"\"><b>Règles propres aux preferred partners</b></p>\n                    	Le label Preferred Partner Dolibarr est un label de qualité attribué par l\'association. L\'attribution de ce dernier \n                    	amène des avantages mais aussi des devoirs et obligations propres à ce label sur l\'utilisation de DoliStore.\n                    	Mais ceci est une contrainte propre au programmes Preferred Partner, voir la <a href=\"https://wiki.dolibarr.org/index.php?title=Dolibarr_Preferred_Partner\">\n                    	    page suivante\n                    	</a>.<br>\n                    	\n                    	<br><br>\n                    	\n                    	<h3>Règle S4</h3>\n                    	<p style=\"\">Lorsque\n                    		plusieurs modules compatibles avec une même version de Dolibarr, sont trop identiques, l\'association se réserve\n                    		le droit de ne pas valider les modules soumis après le premier, ceci afin d\'éviter le copier-coller de modules\n                    		(possible par la licence GPL) qui génère des doublons dégradant l\'expérience utilisateur dans sa recherche de\n                    		solutions complémentaires sur Dolibarr.</p>\n                    	<p style=\"\"><span\n                    			style=\"\">Si un\n                    			module n\'est pas mis à jour dans un délai de <strong>4</strong> mois après la sortie d\'une nouvelle version\n                    			de Dolibarr, l\'association acceptera que le module soit publié par un autre vendeur (que l\'auteur original)\n                    			qui aura porté le module dans la version récente de Dolibarr, ceci afin d\'éviter que certains modules se\n                    			trouvent abandonnés. De plus, l\'association peut sans avertissement désactiver les modules portant sur des\n                    			versions trop anciennes de Dolibarr.</span></p>\n                    			\n                    	<!--\n                    	<p style=\"\">&nbsp;</p>\n                    	<h3>Règle S5 - Comment apparaître sur la Home page</h3>\n                    	<p>Il y a des conditions pour qu\'un module apparaisse sur la page d\'accueil. Le module doit respecter des règles:\n                    	</p>\n                    	<p>- avoir un lien vers une documentation</p>\n                    	<p>- l\'éditeur du module doit être un Dolibarr Preferred Partner</p>\n                    	<p>- maximum 10 modules par éditeur</p>\n                    	<p>- seul les modules compatibles avec la dernière version de Dolibarr sont éligibles</p>\n                    	<p>- une seule version de module par périmètre fonctionnel couvert (the premier qui a couvert la fonctionnalité en\n                    		cas de doublon de module, même si le premier est moins complet)</p>\n                    	<p>- une exception peut être faite pour les modules gratuits s\'ils sont réellement intéressant (soumis à vote du CA\n                    		de l\'association)</p>\n                    	<p>Note: ces règles seront modifiées dans le futur pour être plus strictes afin de réduire le nombre de modules en\n                    		page d\'accueil. Si vos modules respectent ces conditions, vous pouvez envoyer la liste des noms et id à\n                    		dolistore@dolibarr.org pour demander à les avoir en page d\'accueil.</p>\n                    	<p>&nbsp;</p>\n                    	-->\n                    	<br>\n                    	\n                    	<h3>Quand et pourquoi un paiement si le logiciel est en OpenSource (GPL, ...) ?</h3>\n                    	<p>De nombreux produits disponibles sur cette place de marché sont gratuits et peuvent être téléchargés directement\n                    		depuis leur fiche. Aucun paiement dans ce cas n\'est requis.</p>\n                    	<p>Toutefois, certains auteurs décident de faire payer quelque chose en échange de la distribution de leur travail.\n                    		Il n\'y a aucun problème à concilier les 2 approches (Prix pour distribuer du code face à licence Open Source):\n                    		La <strong>Free Software Foundation</strong>, qui a créé la licence GNU GPL, une des licences pour les logiciels\n                    		libre les plus utilisées, autorise et même encourage cela en y donnant les explications, sur cette page :<br><a\n                    			href=\"http://www.gnu.org/philosophy/selling.fr.html\"\n                    			target=\"_blank\">http://www.gnu.org/philosophy/selling.fr.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:53:50',NULL,'2025-01-23 17:12:16',NULL,NULL,'page','fr',202,'','',NULL,'','',0,NULL,NULL),
(161,38,'condizioni-duso','','Condizioni d\'uso','Condizioni d\'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>Condizioni d\'uso</h2>\n                    <p>&nbsp;</p>\n                    <h3>Regola 1</h3>\n                    <p>I prodotti e i moduli offerti su DoliStore sono pubblicati dai fornitori accreditati sulla piattaforma che non sono necessariamente affiliati alla Dolibarr Foundation (questa regola potrebbe cambiare in futuro).</p>\n                    <p>Vengono offerti solo moduli pubblicati sotto&nbsp;<a href=\"https://opensource.org/licenses/alphabetical\">una licenza approvata dalla OSI</a> e compatibile con GPL v3 nel caso di lavori derivati (utilizzo di altri componenti o API) da Dolibarr.</p>\n                    <h3>Regola 2</h3>\n                    <p>Il prezzo di vendita è fissato dal venditore. La convalida della vendita viene effettuata dopo un mese dall\'acquisto. During this delay, durante tale periodo la Fondazione può cancellare la transazione per un qualunque motivo senza inviare notifiche al venditore (se ciò dovesse mai accadere, il venditore vedrà questo dato nella pagina delle statistiche all\'interno della propria area riservata).</p>\n                    <p>Il prezzo di vendita è da intendersi indicativo e al netto dell\'IVA e non rappresenta il prezzo finale da pagare. I venditori, inoltre, acconsentono a che i soci della Fondazione ricevano uno sconto predefinito (20%) su tutti gli acquisti. L\'effettivo prezzo di vendita, IVA esclusa, appare nelle statistiche dettagliate.</p>\n                    <p>La Fondazione trattiene il 20% della somma per pagare i costi bancari e di gestione. Qualsiasi guadagno verrà usato per promuovere Dolibarr ERP/CRM.</p>\n                    <h3>Regola 3</h3>\n                    <p>L\'acquirente rinuncia a qualsiasi pretesa rispetto al funzionamento dei prodotti. La Dolibarr Foundation non esegue alcun test di funzionalità o qualità sui moduli offerti (fatta eccezione per la struttura dei pacchetti). Qualsiasi richiesta o reclamo deve essere inviato ai contatti specificati nella descrizione del prodotto, ammesso che il produttore offra tale servizio (è una informazione obbligatoria per la pubblicazione della descrizione). La fondazione si riserva di ritirare dalla vendita i prodotti nel caso pervengano troppe lamentele.</p>\n                    <h3>Regola 4</h3>\n                    <p>Una volta ricevuto il pagamento, l\'acquirente può scaricare i file dei prodotti acquistati all\'interno della sezione \"Miei ordini\" della propria area riservata o dal link contenuto nell\'email di conferma dell\'acquisto.</p>\n                    <p>Il download del prodotto è disponibile su Dolistore per un anno dal pagamento.</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 Free Software Foundationche ha creato la celebre licenza GPL, una delle licenze più usate per il software OpenSource, permette ed incoraggia questa ciò e fornisce qualche spiegazione sulla seguente pagina:&nbsp;<a href=\"http://www.gnu.org/philosophy/selling.it.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.it.html</a></p>\n                    </div>\n\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:47:29',NULL,'2024-05-06 21:48:43',NULL,NULL,'page','it',201,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(162,38,'condizioni-duso_venditori-di-moduli','','Condizioni d\'uso - Venditori di moduli','Condizioni d\'uso - Venditori di moduli','','<?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>Condizioni d\'uso - Venditori di moduli</h2>\n                        <p>&nbsp;</p>\n                        <h3>Regola S1</h3>\n                        <p>I prodotti e i moduli offerti su DoliStore sono pubblicati dai fornitori accreditati sulla piattaforma che non sono necessariamente affiliati alla Dolibarr Foundation (questa regola potrebbe cambiare in futuro).</p>\n                        <p>Vengono offerti solo moduli pubblicati sotto&nbsp;<a href=\"https://opensource.org/licenses/alphabetical\">una licenza approvata dalla OSI</a> e compatibile con GPL v3 nel caso di lavori derivati (utilizzo di altri componenti o API) da Dolibarr.</p>\n                        <h3></h3>\n                        <h3>Regola S2</h3>\n                        <p>Il venditore riceverà l\'80% del valore netto di vendita. Per ricevere il pagamento dei prodotti venduti, il venditore può inviare una fattura alla Dolibarr Foundation a partire da un mese dopo l\'acquisto dei prodotti (tale lasso di tempo serve ad assicurarsi che non vi siano resi in corso).</p>\n                        <p>Per richiedere un pagamento il venditore deve avere raggiunto una somma di almeno 50€ (100€ nel caso di venditori di paesi extraeuropei). È previsto un limite di una richiesta di pagamento al mese.</p>\n                        <p>Il pagamento può essere effettuato:</p>\n                        <p>- Oppure tramite bonifico SEPA su un conto bancario in EURO.<br>- O tramite pagamento con carta (il venditore deve quindi fornire l\'interfaccia per consentire il pagamento)<br>- O tramite pagamento tramite Paypal (il venditore deve quindi fornire il suo account paypal).</p>\n                        <p></p>\n                        <h3>Regola S3</h3>\n                        <p>Per ogni prodotto il venditore deve fornire una descrizione che includa tutte le informazioni obbligatorie:</p>\n                        <p>* Breve descrizione</p>\n                        <p>* Versione</p>\n                        <p>* Nome dell\'autore e licenza.</p>\n                        <p>* Tipo di supporto/assistenza fornito. È obbligatorio specificare se non viene fornito supporto agli utenti.</p>\n                        <p>* Versione di Dolibarr compatibile con il modulo (È necessario inserire sia una versione che una massima. I valori devono rispettare il formato x.y.z, \"dev\" non è una versione valida e il carattere * è ammesso solo in terza posizione - per esempio x.y.*).</p>\n                        <p>Si possono aggiungere link a versioni estese della documentazione, ma solo all\'interno della descrizione lunga.</p>\n                        <p>Se qualcosa va storto o se la versione di Dolibarr indicata è troppo vecchia, la Fondazione è autorizzata a rimuovere l\'inserzione senza alcun preavviso.</p>\n                        <p>I venditori possono mettere in vendita i prodotti su qualsiasi altra piattaforma a qualunque prezzo, ma non sono ammessi link o alcuna altra forma di pubblicità di altre piattaforme su cui il prodotto venga venduto. Nel caso venga a conoscenza di link o altri riferimenti all\'interno della scheda del prodotto, la Fondazione si riserva di eliminare tali riferimenti o escludere il prodotto dalla piattaforma o bloccare l\'account del venditore a proprio insidacabile giudizio.</p>\n                        <p></p>\n                        <p>È obbligatorio fornire un riferimento per il supporto nel caso di moduli non gratuiti. È necessario fornire una descrizione per il prodotto in ogni lingua prevista dalla piattaforma (anche solo un copia/incolla della versione inglese). È anche consigliato di indicare in quali lingue è disponibile il supporto, per esempio solo italiano e inglese. Un link alla demo del prodotto non è obbligatoria, ma caldamente consigliata.</p>\n                        <p></p>\n                        <p>Qualsiasi modulo che non rispetti le condizioni previste nella documentazione (vedi&nbsp;<a href=\"http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Rules\">http://wiki.dolibarr.org/index.php/Module_Dolistore_Validation_Rules</a>&nbsp;non riceveranno la convalida per la pubblicazione su DoliStore.</p>\n                        <p>&nbsp;</p>\n                        <h3>Regola S4</h3>\n                        <p>Nel caso di moduli molto simili e compatibili con la stessa versione di Dolibarr, la Fondazione si riserva di non convalidare la pubblicazione di moduli successivi al primo, al fine di evitare il copia/incolla di moduli esistenti (ammesso dalla licenza GPL). I moduli che non vengono aggiornati entro 4 mesi dal rilascio di una nuova verisone di Dolibarr verranno rimossi per evitare l\'accumularsi di moduli abbandonati. Potrebbero essere eliminate senza preavviso anche le versioni troppo vecchie di moduli attualmente validi.</p>\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 Free Software Foundationche ha creato la celebre licenza GPL, una delle licenze più usate per il software OpenSource, permette ed incoraggia questa ciò e fornisce qualche spiegazione sulla seguente pagina:&nbsp;<a href=\"http://www.gnu.org/philosophy/selling.it.html\" target=\"_blank\">http://www.gnu.org/philosophy/selling.it.html</a></p>\n                        </div>\n\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:56:58',NULL,'2024-05-06 21:57:36',NULL,NULL,'page','it',202,'','',NULL,'','',0,NULL,NULL),
(163,38,'contact','','Contact','Contact','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            \n            <section id=\"contact_us_section\" contenteditable=\"true\">\n			<div class=\"rte\">\n				<h2>Contact us</h2>\n				<p>The foundation offers the DoliStore platform to help seller and buyer of <a href=\"https://www.dolibarr.org\">Dolibarr ERP CRM addons </a>to meet each others. Only the service to provide visibility of product on sale is offered by the foundation. The foundation does not guarantee the quality of products the customer buy.</p>\n				<p></p>\n				<p>If you experience troubles with a module, please go on the module page to see how you can contact the support provided by the author of the module.</p>\n				<p>Only authors of module can help you. You must always contact them first for any questions and any troubles.</p>\n				<p>If after contacting the author, your problem is not solved, then, please inform the Dolibarr foundation (email: dolistore@dolibarr.org) with information about:</p>\n				<p>- description of trouble (name of module, version, version of your dolibarr)</p>\n				<p>- a summary of echange you did with the author (cust-paste of emails sent/received)</p>\n				<p>- if you got non answer, date of last contact you tried (must be higher than 7 days)</p>\n				<p>So we will be able to process your case (disable the module, refund you if necessary, ...)</p>\n				<p></p>\n				<h2></h2>\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:05',NULL,'2024-08-19 11:41:57',NULL,NULL,'page','it',164,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(164,38,'contact-us','','Contact','Contact us','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>Contact us</h2>\n				<p>The foundation offers the DoliStore platform to help seller and buyer of <a href=\"https://www.dolibarr.org\">Dolibarr ERP CRM addons </a>to meet each others. Only the service to provide visibility of product on sale is offered by the foundation. The foundation does not guarantee the quality of products the customer buy.</p>\n				<p></p>\n				<p>If you experience troubles with a module, please go on the module page to see how you can contact the support provided by the author of the module.</p>\n				<p>Only authors of module can help you. You must always contact them first for any questions and any troubles.</p>\n				<p>If after contacting the author, your problem is not solved, then, please inform the Dolibarr foundation (email: dolistore@dolibarr.org) with information about:</p>\n				<p>- description of trouble (name of module, version, version of your dolibarr)</p>\n				<p>- a summary of echange you did with the author (cust-paste of emails sent/received)</p>\n				<p>- if you got non answer, date of last contact you tried (must be higher than 7 days)</p>\n				<p>So we will be able to process your case (disable the module, refund you if necessary, ...)</p>\n				<p></p>\n				<h2></h2>\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-02-02 16:48:47',NULL,'2024-05-06 21:13:16',NULL,NULL,'page','en',NULL,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(165,38,'contactez-nous','','Contactez nous','Contactez nous','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>Contactez nous</h2>\n              <p>L\'association met en place la plateforme DoliStore afin d\'offrir une mise en relation de vendeurs et clients sur des modules ou extensions prêtes à l\'emploi pour l\'application <a href=\"http://www.dolibarr.fr\">Dolibarr ERP/CRM</a>. Seule la mise en relation est assurée et aucune garantie n\'est fournie par l\'association quand au bon fonctionnement des produits fournis par le vendeur. </p>\n              <p></p>\n              <p>Si vous avez es problèmes avec un module, merci d\'aller sur la page descriptive du module pour voir comment contacter le support fourni par l\'auteur du module.</p>\n              <p>Seul les auteurs du module pourront vous aider. Vous devez toujours les contacter en premier dès que vous avez des questions ou problèmes.</p>\n              <p>Si après les avoir contacter, votre problème n\'est pas résolu, merci d\'informer l\'association Dolibarr&nbsp;(email: dolistore@dolibarr.org) en mentionnant:</p>\n              <p>- la nature de votre problème (nom du module concerné, sa version, votre version de dolibarr et une description du problème)</p>\n              <p>- un résumé des échanges que vous avez pu avoir avec l\'auteur (copié-collé des emails envoyés/reçus)</p>\n              <p>- en cas de non réponse, la date de votre dernière sollicitation (doit être supérieur à 7 jours)</p>\n              <p>Ainsi nous pourrons prendre les mesures nécessaires (désactivation du module, remboursement si justifié)</p>\n              <p></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:05:39',NULL,'2024-05-06 22:06:27',NULL,NULL,'page','fr',164,'https://www.dolistore.com/en/','',NULL,'','',0,NULL,NULL),
(166,38,'edit-module-product','','edit-module-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\';\nrequire_once DOL_DOCUMENT_ROOT . \'/core/class/html.formcompany.class.php\';\nrequire_once DOL_DOCUMENT_ROOT . \'/core/class/doleditor.class.php\';\nrequire_once DOL_DOCUMENT_ROOT . \'/societe/class/societeaccount.class.php\';\n\nerror_reporting(E_ALL);\nini_set(\'display_errors\', 1);\n\n/*print \'<pre>\';\nprint_r($conf);\nprint \'</pre>\';\nexit;*/\n\n$tag = GETPOST(\'tag\', \'alpha\');\n$cat_id = GETPOST(\'cat\', \'alpha\');\n$search = GETPOST(\'search_query\', \'alpha\');\n$product_id = GETPOST(\'id\', \'alpha\');\n\n$isAdmin = false;\n\n$form = new Form($db);\n\n// If not login redirect to login.\nif (empty($_SESSION[\'user\'][\'id_user\'])) {\n    redirectToContainer(\'login-register\');\n}\n\nif (!empty($product_id)) {\n    $product = new Product($db);\n    $result = $product->fetch($product_id);\n    if ($result <= 0) {\n        print \"Product not found from id=\".((int) $product_id);\n        //redirectToContainer(\'myproducts\');\n        exit;\n    } else {\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        /*\n        \n        // Get societe ext_ref\n        $supplier_account_societe = new Societe($db);\n        $result = $supplier_account_societe->fetch($supplier_id);\n        $supplier_id_ext = $supplier_account_societe->ref_ext;\n        //echo $result; exit;\n\n        // Special check for old products with old syntax c...d...\n        if (preg_match(\'/c(\\d+)d/\', $product->ref, $matches) && $matches[1] != $supplier_id && $matches[1] != $supplier_id_ext) {\n            print \"Product not found from c...d... or supplier ref_ext is not matching the id into the product ref c...d...\";\n            //redirectToContainer(\'myproducts\');\n            exit;\n        }\n        */\n        \n        // TODO \n        // Check that product $product_id is owned by the logged company $_SESSION[\'user\'][\'socid\']\n        //var_dump($_SESSION[\'user\'][\'socid\']);\n    }\n}\n\n// END PHP \n?>\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            <!--  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(\"newModuleProduct\"); ?>\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 left 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                        <script type=\"text/javascript\">\n                            var edit_product_url = \"_service_page_ajax.php\";\n                            console.log(edit_product_url);\n                        </script>\n                        <h1 class=\"page-heading\"><?php print $weblangs->trans(\"newModuleProduct\"); ?></h1>\n                        <div class=\"row\">\n                            <div class=\"col-xs-12\">\n                                <div class=\"add-product-page\">\n                                    <?php\n                                    $website_available_langs = getAvailableLangs();\n                                    if (!defined(\'ROWS_3\')) {\n                                        define(\'ROWS_3\', 3);\n                                    }\n                                    \n                                    $mvcid = getDolGlobalInt(\"MARKETPLACE_VERSIONS_CATEGORY_ID\");\n                                    $full_version_tree = getOrganizedTree($mvcid, \'label\');\n\n                                    if (!empty($product_id) && $_SERVER[\'REQUEST_METHOD\'] != \'POST\') {\n\n                                        foreach ($website_available_langs[\'langs_code_shortcode\'] as $lang_key => $code) {\n                                            ${\'name_\' . $lang_key} = $product->multilangs[$code][\'label\'] ?? \'\';\n                                            ${\'short_description_\' . $lang_key} = $product->multilangs[$code][\'description\'] ?? \'\';\n                                            ${\'description_\' . $lang_key} = $product->multilangs[$code][\'other\'] ?? \'\';\n                                        }\n                                        $status = $product->status ?? 0;\n                                        $sale_price = ($product->price ? price($product->price) : \'\');\n\n                                        $c = new Categorie($db);\n                                        $cats = $c->containing($product->id, Categorie::TYPE_PRODUCT);\n                                        $arrayselected = array();\n                                        if (is_array($cats)) {\n                                            foreach ($cats as $cat) {\n                                                $arrayselected[] = $cat->id;\n                                            }\n                                        }\n                                        $categories = array();\n                                        foreach ($arrayselected as $key => $value) {\n                                            if (!in_array($value, [\'PRODUCTS_ON_WEBSITE\', \'VERSIONS\']) && strpos($value, \'V\') !== 0) {\n                                                $categories[$key] = $value;\n                                            }\n                                        }\n\n                                        $version = ($product->array_options[\'options_marketplace_module_version\'] ? $product->array_options[\'options_marketplace_module_version\'] : 0);\n                                        $keywords = ($product->array_options[\'options_marketplace_module_keywords\'] ? $product->array_options[\'options_marketplace_module_keywords\'] : 0);\n                                        $dolibarr_core_include = ($product->array_options[\'options_marketplace_allow_source_in_core\'] ? $product->array_options[\'options_marketplace_allow_source_in_core\'] : 0);\n                                        $version_min = ($product->array_options[\'options_marketplace_min_version\'] ? $product->array_options[\'options_marketplace_min_version\'] : 0);\n                                        $version_max = ($product->array_options[\'options_marketplace_max_version\'] ? $product->array_options[\'options_marketplace_max_version\'] : 0);\n                                        $contact_support = ($product->array_options[\'options_marketplace_contact_support\'] ? $product->array_options[\'options_marketplace_contact_support\'] : 0);\n\n                                        $files_and_images = getPublicFilesOfObject($product);\n                                        foreach ($files_and_images as $key => $file) {\n                                            if ($file[\'position\'] == 100) {\n                                                $virtual_product_file = $file;\n                                            }\n                                            if ($file[\'position\'] == 0) {\n                                                $image_cover = $file;\n                                            }\n                                            if (strpos($file[\'filename\'], \'image_\') !== false && strpos($file[\'filename\'], \'image_cover\') === false) {\n                                                $otherimages[$key] = $file;\n                                            }\n                                        }\n                                    }\n\n\n                                    if (GETPOST(\'action\') == \"new-module\") {    // submit new or update existing one\n                                        foreach ($website_available_langs[\'langs\'] as $lang_key => $lang_label) {\n                                            ${\'name_\' . $lang_key} = GETPOST(\'name_\' . $lang_key) ?? \'\';\n                                            ${\'short_description_\' . $lang_key} = GETPOST(\'short_description_\' . $lang_key) ?? \'\';\n                                            ${\'description_\' . $lang_key} = GETPOST(\'description_\' . $lang_key, \'restricthtmlallowiframe\') ?? \'\';\n                                        }\n\n                                        $error = 0;\n                                        $error_messages = array();\n\n                                        foreach ($website_available_langs[\'langs\'] as $lang_key => $lang_label) {\n                                            $product_name = GETPOST(\'name_\' . $lang_key);\n                                            $short_description = GETPOST(\'short_description_\' . $lang_key);\n                                            $description = GETPOST(\'description_\' . $lang_key, \'restricthtmlallowiframe\');\n\n                                            if ($lang_key == \"en\" && ($product_name == \"\" || $short_description == \"\" || $description == \"\")) {\n                                                $error++;\n                                                $error_messages[] = $weblangs->trans(\"englishFieldsRequired\");\n                                            }\n\n                                            if ($lang_key != \"en\" && $product_name == \"\") {\n                                                $product_name = (isset($productlang[\'en\'][\'name\']) ? $productlang[\'en\'][\'name\'] : \'\');\n                                            }\n\n                                            if ($lang_key != \"en\" && $short_description == \"\") {\n                                                $short_description = (isset($productlang[\'en\'][\'short_description\']) ? $productlang[\'en\'][\'short_description\'] : \'\');\n                                            }\n\n                                            if ($lang_key != \"en\" && $description == \"\") {\n                                                $description = (isset($productlang[\'en\'][\'description\']) ? $productlang[\'en\'][\'description\'] : \'\');\n                                            }\n\n                                            $productlang[$lang_key][\'name\'] = $product_name;\n                                            $productlang[$lang_key][\'short_description\'] = $short_description;\n                                            $productlang[$lang_key][\'description\'] = $description;\n\n                                            $short_descriptionLength = strlen(strip_tags($short_description));\n                                            if ($short_descriptionLength > 400) {\n                                                $error++;\n                                                $error_messages[\'short_description_\' . $lang_key] = $weblangs->trans(\"fieldTooLong\", $weblangs->trans(\"shortDescription\"), 400, $short_descriptionLength);\n                                            }\n                                        }\n\n                                        $keywords = GETPOST(\'keywords\') ?? \'\';\n\n                                        $categories = GETPOST(\'categories\') ?? \'\';\n                                        if (empty($categories)) {\n                                            $error++;\n                                            $error_messages[\'categories\'] = $weblangs->trans(\"requiredCategory\");\n                                        }\n\n                                        if (empty($_FILES[\'virtual_product_file\'][\'name\']) && empty($product_id)) {\n                                            $error++;\n                                            $error_messages[\'virtual_product_file\'] = $weblangs->trans(\"zipProductRequired\");\n                                        } else {\n                                            if (!empty($_FILES[\'virtual_product_file\'][\'name\'])) {\n                                                $checkZipFile = checkZipFile();\n                                                if ($checkZipFile[\'upload\'] < 0) {\n                                                    $error++;\n                                                    $error_messages[\'virtual_product_file\'] = $checkZipFile[\'errormsg\'];\n                                                }\n                                            }\n                                        }\n\n                                        if (empty($_FILES[\'image_cover\'][\'name\']) && empty($product_id)) {\n                                            $error++;\n                                            $error_messages[\'image_cover\'] = $weblangs->trans(\"fieldRequired\", $weblangs->trans(\"coverImage\"));\n                                        } else {\n                                            if (!empty($_FILES[\'image_cover\'][\'name\'])) {\n                                                $checkCoverImage = checkImage($_FILES[\'image_cover\']);\n                                                if ($checkCoverImage != false) {\n                                                    $error++;\n                                                    $error_messages[\'image_cover\'] = $weblangs->trans(\"coverImage\") . \' : \' . $checkCoverImage;\n                                                }\n                                            }\n                                        }\n\n                                        $other_images = array();\n                                        if (!empty($_FILES[\'image_1\'][\'name\'])) {\n                                            $other_images = array();\n                                            $other_images_errors = array();\n                                            for ($x = 1; $x <= 10; $x++) {\n                                                if (!empty($_FILES[\'image_\' . $x][\'name\'])) {\n                                                    $other_images[\'image_\' . $x] = $_FILES[\'image_\' . $x];\n                                                    $checkImage = checkImage($_FILES[\'image_\' . $x]);\n                                                    if ($checkImage != false) {\n                                                        $other_images_errors[\'image_\' . $x] = $checkImage;\n                                                    }\n                                                } else {\n                                                    break;\n                                                }\n                                            }\n                                        }\n                                        if (!empty($other_images_errors)) {\n                                            $error++;\n                                            foreach ($other_images_errors as $key => $value) {\n                                                $error_messages[$key] = $key . \' : \' . $value;\n                                            }\n                                        }\n\n                                        $sale_price = (GETPOST(\'sale_price\') ? GETPOST(\'sale_price\') : 0);\n                                        $version = (GETPOST(\'version\') ? GETPOST(\'version\') : \'\');\n                                        $dolibarr_core_include = (GETPOST(\'dolibarr_core_include\') ? GETPOST(\'dolibarr_core_include\') : 0);\n                                        $version_min = (GETPOST(\'version_min\') ? GETPOST(\'version_min\') : \'\');\n                                        $version_max = (GETPOST(\'version_max\') ? GETPOST(\'version_max\') : \'\');\n                                        $contact_support = (GETPOST(\'contact_support\') ? GETPOST(\'contact_support\') : \'\');\n                                        $status = (GETPOST(\'status\') ? GETPOST(\'status\') : 0);\n\n                                        $dateNow = date(\"Y-m-d H:i:s\");\n                                        $dateRef = date(\"YmdHis\");\n\n                                        if ($error == 0) {\n                                            $product = array(\n                                                \'name\' => $productlang[\'en\'][\'name\'],\n                                                \'short_description\' => $productlang[\'en\'][\'short_description\'],\n                                                \'description\' => $productlang[\'en\'][\'description\'],\n                                                \'multilangs\' => $productlang,\n                                                \'keywords\' => $keywords,\n                                                \'categories\' => $categories,\n                                                \'sale_price\' => $sale_price,\n                                                \'version\' => $version,\n                                                \'version_min\' => $version_min,\n                                                \'version_max\' => $version_max,\n                                                \'contact_support\' => $contact_support,\n                                                \'dolibarr_core_include\' => $dolibarr_core_include,\n                                                \'status\' => $status,\n                                                \'image_cover\' => $_FILES[\'image_cover\'],\n                                                \'other_images\' => $other_images,\n                                                \'virtual_product_file\' => $_FILES[\'virtual_product_file\']\n                                            );\n\n                                            if (!empty($product_id)) {\n                                                $addProduct = addProduct($product, $product_id);\n                                            } else {\n                                                $addProduct = addProduct($product);\n                                            }\n\n                                            if ($addProduct == 1) {\n                                                redirectToContainer(\'manage-products\');\n                                            } else {\n                                                $error++;\n                                                $error_messages[] = $weblangs->trans(\"errorOccurred\");\n                                            }\n                                        }\n                                    }\n                                    ?>\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                                    <center>\n                                        <!-- To remove later -->\n                                        <?php if (!empty(getDolGlobalInt(\"MARKETPLACE_IN_MIGRATION\")) && !in_array($_SESSION[\'user\'][\'id_user\'], array_map(\'trim\', explode(\',\', getDolGlobalString(\"MARKETPLACE_ADMIN_USER_IDS\"))))) : ?>\n                                            <div style=\"color: red; font-weight: bold; font-size: 1.2em;\"><br>\n                                            [EN] This site is currently under maintenance. Please do not submit, edit or buy modules yet.<br>\n                                            [FR] Ce site est toujours en maintenance. Merci de ne pas soumettre, éditer ou acheter des modules.<br>\n                                            <br><br>\n                                            </div>\n                                        <?php endif ?>\n                                        <!-- To remove later -->\n                                        \n                                        \n                                        <?php print $weblangs->trans(\"checkRulesBeforeSubmit\", \"https://wiki.dolibarr.org/index.php?title=Modules_-_Packaging_rules_and_Dolistore_validation_rules\"); ?>\n                                    </center>\n                                    <br><br>\n                                    <?php\n                                    if (!empty($product) && is_object($product)) {\n                                        print strtoupper($weblangs->trans(\"Product\")).\': <b>\'.$product->ref.\'</b><br><br><br>\';\n                                    }\n                                    ?>\n\n                                    <p class=\"form-subheading\"><?php print $weblangs->trans(\"multilingualInformation\"); ?></p>\n\n                                    <nav>\n                                        <div class=\"nav\">\n                                            <?php foreach ($website_available_langs[\'langs\'] as $key => $value) : ?>\n                                                <button class=\"nav-link <?php if ($key == \'en\') {\n                                                                            print \'active\';\n                                                                        } ?>\" id=\"nav-<?php print $key; ?>-tab\" data-target=\"nav-<?php print $key; ?>\"><?php print $value; ?> <?php if ($key == \'en\') {\n                                                                                                                                                                                                                            print \'<sup>*</sup>\';\n                                                                                                                                                                                                                        } ?></button>\n                                            <?php endforeach ?>\n                                        </div>\n                                    </nav>\n                                    \n                                    <form action=\"\" enctype=\"multipart/form-data\" method=\"post\" id=\"product-creation-form\">\n                                        <div class=\"tab-content std\">\n                                            <?php foreach ($website_available_langs[\'langs\'] as $key => $value): ?>\n                                                <div class=\"tab-pane <?php if ($key == \'en\') {\n                                                    print \'active\';\n                                                } ?>\" id=\"nav-<?php print $key; ?>\">\n                                                    <div class=\"form-group row required\">\n                                                        <label for=\"name_<?php print $key; ?>\"\n                                                            class=\"col-xs-4 col-form-label\"><?php print $weblangs->trans(\"moduleProductName\"); ?> <span\n                                                                class=\"lang_span\">[<?php print $key; ?>]</span>\n                                                            <?php if ($key == \'en\') {\n                                                                print \'<sup>*</sup>\';\n                                                            } ?></label>\n                                                        <div class=\"col-xs-8\">\n                                                            <input type=\"text\" class=\"is_required validate form-control\" id=\"name_<?php print $key; ?>\"\n                                                                name=\"name_<?php print $key; ?>\" <?php if ($key == \'en\') {\n                                                                       print \'required\';\n                                                                   } ?> value=\"<?php if (isset(${\'name_\' . $key})) {\n                                                                         print ${\'name_\' . $key};\n                                                                     } ?>\">\n                                                        </div>\n                                                    </div>\n                                                    <div class=\"form-group row required\">\n                                                        <label for=\"short_description_<?php print $key; ?>\"\n                                                            class=\"col-xs-12 col-form-label\"><?php print $weblangs->trans(\"shortDescription\"); ?> <span\n                                                                class=\"lang_span\">[<?php print $key; ?>]</span>\n                                                            <?php if ($key == \'en\') {\n                                                                print \'<sup>*</sup>\';\n                                                            } ?></label>\n                                                        <div class=\"col-xs-12\">\n                                                            <textarea row=\"5\" class=\"rtenockeditor is_required validate form-control textarea-short-description\"\n                                                                id=\"short_description_<?php print $key; ?>\" name=\"short_description_<?php print $key; ?>\" <?php if ($key == \'en\') {\n                                                                          print \'required\';\n                                                                      } ?>><?php if (isset(${\'short_description_\' . $key})) {\n                                                                           print ${\'short_description_\' . $key};\n                                                                       } ?></textarea>\n                                                        </div>\n                                                    </div>\n                                        \n                                                    <div class=\"form-group row required\">\n                                                        <label for=\"description_<?php print $key; ?>\"\n                                                            class=\"col-xs-12 col-form-label\"><?php print $weblangs->trans(\"largeDescription\"); ?> <span\n                                                                class=\"lang_span\">[<?php print $key; ?>]</span>\n                                                            <?php if ($key == \'en\') {\n                                                                print \'<sup>*</sup>\';\n                                                            } ?></label>\n                                                        <div class=\"col-xs-12\">\n                                                            <?php\n                                                            $description_value = ${\'description_\' . $key} ?? \'\';\n                                                            $doleditor = new DolEditor(\'description_\' . $key, $description_value, \'\', 320, \'dolibarr_notes\', \'Basic\', false, false, getDolGlobalString(\'FCKEDITOR_ENABLE_DETAILS\'), \'4\', \'90%\');\n                                                            $doleditor->Create(0, \'\', \'a[target];section[contenteditable,id];div{float,display};iframe[src,width,height]\');\n                                                            ?>\n                                                        </div>\n                                                    </div>\n                                        \n                                                </div>\n                                            <?php endforeach ?>\n                                        </div>\n\n\n                                        <p class=\"form-subheading\"><?php print $weblangs->trans(\"moduleInformation\"); ?></p>\n                                        <div class=\"col-xs-12 box-form\">\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"keywords\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"keywords\"); ?></label>\n                                                <div class=\"col-xs-9\">\n                                                    <input type=\"text\" class=\"is_required validate form-control module-keywords\" id=\"keywords\" name=\"keywords\" value=\"<?php if (isset($keywords)) {\n                                                                                                                                                                            print $keywords;\n                                                                                                                                                                        } ?>\">\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"module-version\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"moduleVersion\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <input type=\"text\" class=\"is_required validate form-control module-version\" id=\"module-version\" name=\"version\" required value=\"<?php if (isset($version)) {\n                                                                                                                                                                                        print $version;\n                                                                                                                                                                                    } ?>\">\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"compatibility\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <div class=\"row\">\n                                                        <div class=\"col-xs-4\">\n                                                            Min\n                                                            <?php\n                                                                $version_min_tag = (empty($version_min) ? \"V?\" : (substr($version_min, 0, 1) !== \"V\" ? \"V\" : \"\").$version_min);\n                                                                $version_min_tag = preg_replace(\'/\\..*$/\', \'\', $version_min_tag);\n                                                            ?>\n                                                            <select name=\"version_min\" id=\"version-min\" class=\"flat maxwidth200onsmartphone selectcountry form-control\" required>\n                                                                <option value=\"\" disabled><?php print $weblangs->trans(\"minVersion\"); ?></option>\n                                                                <?php foreach (array_reverse($full_version_tree) as $key => $value) { ?>\n                                                                    <?php if ($value[\'rowid\'] != $mvcid) { ?>\n                                                                        <option value=\"<?php print $value[\'id\']; ?>\" <?php if ($version_min_tag === $value[\'label\']) {\n                                                                            print \'selected\';\n                                                                        } ?>><?php print $value[\'label\']; ?></option>\n                                                                    <?php } ?>\n                                                                <?php } ?>\n                                                            </select>\n                                                        </div>\n\n                                                        <div class=\"col-xs-4\">\n                                                            Max\n                                                            <?php\n                                                                $version_max_tag = (empty($version_max) ? \"V?\" : (substr($version_max, 0, 1) !== \"V\" ? \"V\" : \"\").$version_max);\n                                                                $version_max_tag = preg_replace(\'/\\..*$/\', \'\', $version_max_tag);\n                                                            ?>\n                                                            <select name=\"version_max\" id=\"version-max\" class=\"flat maxwidth200onsmartphone selectcountry form-control\" required>\n                                                                <option value=\"\" disabled><?php print $weblangs->trans(\"maxVersion\"); ?></option>\n                                                                <?php foreach (array_reverse($full_version_tree) as $key => $value) { ?>\n                                                                    <?php if ($value[\'rowid\'] != $mvcid) { ?>\n                                                                        <option value=\"<?php print $value[\'id\']; ?>\" <?php if ($version_max_tag === $value[\'label\']) {\n                                                                            print \'selected\';\n                                                                        } ?>><?php print $value[\'label\']; ?></option>\n                                                                    <?php } ?>\n                                                                <?php } ?>\n                                                            </select>\n                                                        </div>\n                                                    </div>\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"status\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"status\"); ?></label>\n                                                <div class=\"col-xs-9\">\n                                                    <div class=\"form-check\">\n                                                        <input class=\"form-check-input valignmiddle\" type=\"radio\" name=\"status\" id=\"status-enabled\" value=\"1\" <?php if (isset($status) && $status == 1) {\n                                                                                                                                                        print \'checked\';\n                                                                                                                                                    } elseif (empty($isAdmin)) { print \"disabled\"; } ?>>\n                                                        <label class=\"form-check-label valignmiddle\" for=\"status-enabled\">\n                                                            <?php print $langs->trans(\"Enabled\"); ?>\n                                                        </label>\n                                                    </div>\n                                                    <div class=\"form-check\"> \n                                                        <input class=\"form-check-input valignmiddle\" type=\"radio\" name=\"status\" id=\"status-disabled\" value=\"0\" <?php if (isset($status) && $status == 0) {\n                                                                                                                                                        print \'checked\';\n                                                                                                                                                    } ?>>\n                                                        <label class=\"form-check-label valignmiddle\" for=\"status-disabled\">\n                                                            <?php print $langs->trans(\"Disabled\"); ?>\n                                                        </label>\n                                                    </div>\n                                                    <?php if (isset($status) && $status == 0) { print \' <span class=\"opacitymedium valignmiddle\">\'.$product->array_options[\'options_marketplace_reason_disabled\'].\'</span>\'; } ?>\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"module-sale-price\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"salePriceExlTax\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <input type=\"text\" class=\"is_required validate form-control col-xs-8 price-field\" id=\"module-sale-price\" name=\"sale_price\" value=\"<?php if (isset($sale_price)) {\n                                                                                                                                                                                            print $sale_price;\n                                                                                                                                                                                        } ?>\" required>\n                                                    <span class=\"price-currency\">\n                                                        <?php print $weblangs->trans(\"currencyEuro\"); ?>\n                                                    </span>\n                                                    <span class=\"price-free\">\n                                                        <?php print $weblangs->trans(\"salePriceFree\"); ?>\n                                                    </span>\n                                                    <div class=\"field-info info-inline\">\n                                                        <?php print $weblangs->trans(\"salePriceInfo\"); ?>\n                                                    </div>\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"module-how-to-contact\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"contactSupport\"); ?></label>\n                                                <div class=\"col-xs-9\">\n                                                    <input type=\"text\" class=\"is_required validate form-control how-to-contact\" id=\"module-how-to-contact\" name=\"contact_support\" value=\"<?php if (isset($contact_support)) {\n                                                                                                                                                                                                print $contact_support;\n                                                                                                                                                                                            } ?>\">\n                                                    <div class=\"field-info info-inline\">\n                                                        <?php print $weblangs->trans(\"contactSupportInfo\"); ?>\n                                                    </div>\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"customer_firstname\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"selectCatForProduct\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <?php\n                                                    $mcid = getDolGlobalInt(\"MARKETPLACE_ROOT_CATEGORY_ID\");\n                                                    $organized_tree = getOrganizedTree($mcid);\n                                                    ?>\n\n                                                    <table border=\"0\" cellspacing=\"5\" cellpadding=\"0\" class=\"cat-check-table-submit-product\">\n                                                        <tbody>\n                                                            <?php\n                                                            if (!isset($categories) || !is_array($categories)) {\n                                                                $categories = [];\n                                                            }\n                                                            ?>\n                                                            <?php foreach ($organized_tree as $key => $value) : ?>\n                                                                <?php if ($value[\'label\'] != \"Versions\" && $value[\'label\'] != \"Specials\" && $value[\'label\'] != \"Goodies\") : ?>\n                                                                    <tr bgcolor=\"#FFDBB7\">\n                                                                        <td class=\"cat-checkbox-td\">\n                                                                            <?php $checked = in_array($value[\'id\'], $categories) ? \'checked\' : \'\';  ?>\n                                                                            <input type=\"checkbox\" id=\"cat-<?php print $value[\'rowid\']; ?>\" name=\"categories[]\" value=\"<?php print $value[\'rowid\']; ?>\" <?php print $checked; ?>>\n                                                                            <label for=\"cat-<?php print $value[\'rowid\']; ?>\" class=\"checkbox_label_parent\"> <?php print $value[\'label\']; ?> </label>\n                                                                        </td>\n                                                                    </tr>\n                                                                    <?php if (isset($value[\'children\']) && !empty($value[\'children\'])) : ?>\n                                                                        <?php usort($value[\'children\'], build_sorter(\'position\')); ?>\n                                                                        <?php foreach ($value[\'children\'] as $key_children => $value_children) : ?>\n                                                                            <tr bgcolor=\"#FFF4EA\">\n                                                                                <td class=\"subcat-checkbox-td\">\n                                                                                    <?php $checked = in_array($value_children[\'id\'], $categories) ? \'checked\' : \'\'; ?>\n                                                                                    <input type=\"checkbox\" id=\"subcat-<?php print $value_children[\'rowid\']; ?>\" name=\"categories[]\" value=\"<?php print $value_children[\'rowid\']; ?>\" <?php print $checked; ?>>\n                                                                                    <label for=\"subcat-<?php print $value_children[\'rowid\']; ?>\" class=\"checkbox_label\"> <?php print $value_children[\'label\']; ?> </label>\n                                                                                </td>\n                                                                            </tr>\n                                                                        <?php endforeach; ?>\n                                                                    <?php endif; ?>\n                                                                <?php endif; ?>\n                                                            <?php endforeach; ?>\n                                                        </tbody>\n                                                    </table>\n                                                </div>\n                                            </div>\n\n                                        </div>\n\n\n                                        <p class=\"form-subheading\"><?php print $weblangs->trans(\"attachments\"); ?></p>\n                                        <div class=\"col-xs-12 box-form\">\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"virtual_product_file\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"zipFileModuleField\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <div class=\"uploader\" id=\"uniform-virtual_product_file\">\n                                                        <input id=\"virtual_product_file\" name=\"virtual_product_file\" class=\"\" maxlength=\"10000000\" type=\"file\" <?php if (empty($product_id)) {\n                                                                                                                                                                    print \'required\';\n                                                                                                                                                                } ?>>\n                                                        <div class=\"field-info info-inline\" style=\"margin-left: 10px;\">\n                                                            <?php print $weblangs->trans(\"zipFileModuleInfo\"); ?>\n                                                        </div>\n                                                    </div>\n                                                    <?php if (!empty($product_id) && !empty($virtual_product_file[\'filename\'])) : ?>\n                                                        <div class=\"field-info info-inline\" id=\"field-info-virtual_product_file\">\n                                                            <a href=\"<?php print $virtual_product_file[\'url\']; ?>\" target=\"_new\"><?php print $virtual_product_file[\'filename\']; ?> <i class=\"icon-cloud-download\"></i></a>\n                                                        </div>\n                                                    <?php endif; ?>\n\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <div class=\"form-group row required\">\n                                                <label for=\"image_cover\" class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"coverImage\"); ?> <sup>*</sup></label>\n                                                <div class=\"col-xs-9\">\n                                                    <table>\n                                                        <tbody class=\"tbody-image-cover\">\n                                                            <tr>\n                                                                <td>\n                                                                    <input type=\"file\" name=\"image_cover\" id=\"image_cover\" class=\"input-image-cover\" accept=\"image/*\" <?php if (empty($product_id)) {\n                                                                                                                                                                            print \'required\';\n                                                                                                                                                                        } ?>>\n                                                                </td>\n                                                                <td>\n                                                                    <img src=\"<?php if (!empty($product_id)) {\n                                                                                    print $image_cover[\'url\'];\n                                                                                } else {\n                                                                                    print \'#\';\n                                                                                } ?>\" <?php if (empty($product_id)) {\n                                                                                                                                                                    print  \'style=\"display: none;\"\';\n                                                                                                                                                                } ?> class=\"image-cover-preview\" id=\"image_preview\" width=\"100px\">\n                                                                </td>\n                                                            </tr>\n                                                        </tbody>\n                                                    </table>\n                                                    <!--<div class=\"field-info info-inline\" id=\"field-info-image-cover\">\n                                                        <?php //echo htmlspecialchars($_FILES[\'image_cover\'][\'name\']); \n                                                        ?>\n                                                    </div>-->\n                                                    <?php //endif; \n                                                    ?>\n                                                </div>\n                                            </div>\n\n                                            <hr>\n\n                                            <?php if (empty($product_id)) : ?>\n                                                <div class=\"form-group row required\">\n                                                    <label class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"otherImages\"); ?></label>\n                                                    <div class=\"col-xs-9\">\n                                                        <button type=\"button\" id=\"addImageBtn\" class=\"btn btn-default button\"><?php print $weblangs->trans(\"AddPhoto\"); ?> <span class=\"iconAddImage\"></span></button>\n                                                        <table class=\"table\">\n                                                            <tbody class=\"table-body\" id=\"table-body-add\">\n                                                            </tbody>\n                                                        </table>\n                                                    </div>\n                                                </div>\n                                            <?php endif; ?>\n\n                                            <?php if (!empty($product_id)) : ?>\n                                                <div class=\"form-group row required\">\n                                                    <label class=\"col-xs-3 col-form-label\"><?php print $weblangs->trans(\"otherImages\"); ?></label>\n                                                    <div class=\"col-xs-9\">\n                                                        <button type=\"button\" id=\"addImageBtn2\" class=\"btn btn-default button\"><?php print $weblangs->trans(\"AddPhoto\"); ?> <span class=\"iconAddImage\"></span></button>\n                                                        <input type=\"file\" id=\"fileInput2\" style=\"display:none;\" accept=\"image/*\">\n                                                        <span class=\"notification\"></span>\n                                                        <?php if (!empty($otherimages)) : ?>\n                                                            <table class=\"table\">\n                                                                <tbody class=\"table-body\" id=\"table-body-edit\">\n                                                                    <?php foreach ($otherimages as $key => $image) : ?>\n                                                                        <tr data-id=\"<?php print $key; ?>\">\n                                                                            <td><span class=\"icon-move\"></span></td>\n                                                                            <td class=\"rowCount\"><?php print $image[\'position\']; ?></td>\n                                                                            <td>\n                                                                                <?php print $image[\'filename\']; ?>\n                                                                            </td>\n                                                                            <td>\n                                                                                <img src=\"<?php print $image[\'url\']; ?>\" class=\"image-preview\">\n                                                                            </td>\n                                                                            <td class=\"td-deleteBtn\">\n                                                                                <button type=\"button\" data-id=\"<?php print $key; ?>\" class=\"btn deleteBtn\"><i class=\"icon-delete\"></i></button>\n                                                                            </td>\n                                                                        </tr>\n                                                                    <?php endforeach ?>\n                                                                </tbody>\n                                                            </table>\n                                                        <?php endif; ?>\n                                                    </div>\n                                                </div>\n                                            <?php endif; ?>\n\n                                        </div>\n\n\n                                        <p class=\"form-subheading\"><?php print $weblangs->trans(\"termsAndConditionsOfUse\"); ?></p>\n                                        <div class=\"col-xs-12 box-form\">\n\n                                            <!-- TODO Add hidden option MARKETPLACE_ADD_DOLIBARR_CORE_MESSAGE to enable this section only if option is on -->\n                                            <div class=\"field-info\">\n                                                <?php print $weblangs->trans(\"includeModuleInDolibarrInfo\"); ?>\n                                            </div>\n                                            <?php $checked = (!empty($dolibarr_core_include) && $dolibarr_core_include == \'1\') ? \'checked\' : \'\'; ?>\n                                            <input type=\"checkbox\" value=\"1\" id=\"dolibarr_core_include\" name=\"dolibarr_core_include\" <?php print $checked; ?> class=\"dolibarr_core_include\">\n                                            <label for=\"dolibarr_core_include\" id=\"dolibarr_core_include_label\">\n                                                I would like to have my module included in the core of the project as soon as possible\n                                                <span class=\"tooltip\">\n                                                    <span class=\"fa fa-question-circle\"></span>\n                                                    <!--<img src=\"https://www.dolistore.com/img/admin/help.png\" style=\"padding: 0px 5px;\">-->\n                                                    <span class=\"tooltiptext\">\n                                                        Because a Dolibarr module is a derivative work of Dolibarr, a module must be licensed under a license compatible with Dolibarr gpl v3 license.\n                                                        This means your source code may be included into Dolibarr official version to enhance Dolibarr itself. However, \"may\" does not say \"when\". \n                                                        So if you really want this to happen as soon as possible, just check this box so core team will be informed. \n                                                        This will not guarantee it will be done but increase seriously probability and reduce delay time. If your module is included in core, it means the module will then be maintained by Dolibarr developer community, and module will be disabled from Dolistore as soon as dolibarr version including it is publicly available.\n                                                    </span>\n                                                </span>\n                                            </label>\n\n                                            <hr>\n                                            \n\n                                            <div class=\"form-group required\">\n                                                <?php\n                                                $current_lang = $_SESSION[\'lang\'][\'shortcode\'];\n                                                $page_terms_module_providers = $websitepage->fetchAll($website->id, \'\', \'\', 0, 1, array(\'title\' => \'Terms and conditions of use - Module providers\', \'status\' => \'1\', \'lang\' => $website->lang));\n                                                $obj = $page_terms_module_providers[key($page_terms_module_providers)];\n                                                $link = $obj->pageurl;\n                                                if ($website->lang != $current_lang) {\n                                                    $trans_page = $websitepage->fetchAll($website->id, \'\', \'\', 0, 1, array(\'fk_page\' => $obj->id, \'status\' => \'1\', \'lang\' => $current_lang));\n                                                    $trans_page = $trans_page[key($trans_page)];\n                                                    $link = $trans_page->pageurl;\n                                                }\n                                                ?>\n\n                                                <?php $checked = ($_SERVER[\'REQUEST_METHOD\'] === \'POST\' || !empty($product_id)) ? \'checked\' : \'\'; ?>\n                                                <input type=\"checkbox\" value=\"1\" id=\"dolibarr_terms\" <?php print $checked; ?> name=\"dolibarr_terms\">\n                                                <label for=\"dolibarr_terms\" id=\"dolibarr_terms_label\" class=\"wordbreak\">\n                                                    <?php print $weblangs->trans(\"agreeTermsWebsite\"); ?>\n                                                    <a href=\"<?php print $link.\".php\"; ?>\" target=\"_blank\"><?php print $link; ?></a>\n                                                </label>\n                                            </div>\n                                            <div class=\"form-group required\" style=\"margin-top: 15px;\">\n                                                <input type=\"checkbox\" value=\"1\" id=\"module_wiki\" <?php print $checked; ?> name=\"module_wiki\">\n                                                <label for=\"module_wiki\" id=\"module_wiki_label\" class=\"wordbreak\">\n                                                    <?php print $weblangs->trans(\"suggestToAddWikiPage\"); ?>\n                                                </label>\n                                            </div>\n\n                                        </div>\n\n                                        <hr>\n\n                                        <input type=\"hidden\" name=\"action\" value=\"new-module\">\n                                        <?php if (!empty($product_id)) : ?>\n                                            <span id=\"product_to_edit\" style=\"display:none;\"> <?php print $product_id; ?></span>\n                                        <?php endif; ?>\n\n\n                                        <div class=\"form-group required\">\n                                            <input class=\"button_large_disabled\" id=\"sub\" name=\"sub\" type=\"submit\" value=\"<?php print $langs->trans(\"Submit\"); ?>\" style=\"opacity: 0.5;\" disabled=\"disabled\">\n                                        </div>\n                                    </form>\n                                </div>\n                            </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<?php\n\n$themepath = dol_buildpath($conf->css, 1);\n$themesubdir = \'\';\nif (!empty($conf->modules_parts[\'theme\'])) {    // This slow down\n    foreach ($conf->modules_parts[\'theme\'] as $reldir) {\n        if (file_exists(dol_buildpath($reldir . $conf->css, 0))) {\n            $themepath = dol_buildpath($reldir . $conf->css, 1);\n            $themesubdir = $reldir;\n            break;\n        }\n    }\n}\n\n$ext = \'layout=\' . (empty($conf->browser->layout) ? \'\' : $conf->browser->layout) . \'&amp;version=\' . urlencode(DOL_VERSION);\nprint \'<!-- Includes JS for CKEditor -->\' . \"\\n\";\n$pathckeditor = $conf->file->dol_main_url_root . \'/includes/ckeditor/ckeditor/\';\n$jsckeditor = \'ckeditor.js\';\n\nprint \'<script nonce=\"\' . getNonce() . \'\">\';\nprint \'/* enable ckeditor by main.inc.php */\';\n// TODO Embed the ckeditor or use an online cdn cache for the ckeditor lib. We should not have url using $conf->file->dol_main_url_root that is the url of backoffice.\n//print \'var CKEDITOR_BASEPATH = \\\'\' . dol_escape_js($pathckeditor) . \'\\\';\' . \"\\n\";\nprint \'var ckeditorConfig = \\\'\' . $conf->file->dol_main_url_root . dol_escape_js(dol_buildpath($themesubdir . \'/theme/\' . $conf->theme . \'/ckeditor/config.js\' . ($ext ? \'?\' . $ext : \'\'), 1)) . \'\\\';\' . \"\\n\"; // $themesubdir=\'\' in standard usage\n//print \'var ckeditorFilebrowserBrowseUrl = \\\'\' . $conf->file->dol_main_url_root . \'/core/filemanagerdol/browser/default/browser.php?Connector=\' . $conf->file->dol_main_url_root . \'/core/filemanagerdol/connectors/php/connector.php\\\';\' . \"\\n\";\n//print \'var ckeditorFilebrowserImageBrowseUrl = \\\'\' . $conf->file->dol_main_url_root . \'/core/filemanagerdol/browser/default/browser.php?Type=Image&Connector=\' . $conf->file->dol_main_url_root . \'/core/filemanagerdol/connectors/php/connector.php\\\';\' . \"\\n\";\nprint \'</script>\' . \"\\n\";\nprint \'<script src=\"\' . $pathckeditor . $jsckeditor . ($ext ? \'?\' . $ext : \'\') . \'\"></script>\' . \"\\n\";\n\n?>\n</body>\n</html>',1,'2024-06-10 09:00:09',NULL,'2025-01-19 21:15:21',NULL,NULL,'page','',NULL,'','<script>\n    $(document).ready(function() {\n        var tableBody = $(\'#table-body-add\');\n        var rowCount = 0;\n    \n        $(\'#addImageBtn\').click(function() {\n            rowCount++;\n    \n            var newRow = `\n                <tr>\n                    <td><span class=\"icon-move\"></span></td>\n                    <td class=\"rowCount\" style=\"display:none;\">${rowCount}</td>\n                    <td>\n                        <input type=\"file\" name=\"image_${rowCount}\" class=\"image-input\" accept=\"image/*\" required >\n                    </td>\n                    <td>\n                        <img src=\"#\" style=\"display: none;\" class=\"image-preview\" width=\"100px\">\n                    </td>\n                    <td class=\"td-deleteBtn\">\n                        <button type=\"button\" class=\"btn deleteBtn\"><i class=\"icon-delete\"></i></button>\n                    </td>\n                </tr>\n            `;\n            tableBody.append(newRow);\n    \n            // Attach file input change event\n            var fileInput = tableBody.find(\'tr:last-child .image-input\');\n            fileInput.change(function() {\n                var rowIndex = $(this).closest(\'tr\').index();\n                var imagePreview = tableBody.find(\'tr\').eq(rowIndex).find(\'.image-preview\');\n    \n                if (this.files && this.files[0]) {\n                    var reader = new FileReader();\n    \n                    reader.onload = function(e) {\n                        imagePreview.attr(\'src\', e.target.result).css(\'display\', \'block\');\n                    };\n    \n                    reader.readAsDataURL(this.files[0]);\n                } else {\n                    imagePreview.attr(\'src\', \'\').css(\'display\', \'none\');\n                }\n            });\n        });\n    \n        // Delete row functionality\n        tableBody.on(\'click\', \'.deleteBtn\', function() {\n            $(this).closest(\'tr\').remove();\n            updateRowNumbers();\n        });\n    \n        // Function to update row numbers and input names\n        function updateRowNumbers() {\n            tableBody.find(\'tr\').each(function(index) {\n                var rowNum = index + 1;\n                $(this).find(\'.rowCount\').text(rowNum);\n                $(this).find(\'.image-input\').attr(\'name\', `image_${rowNum}`);\n            });\n        }\n    \n        // Make table rows sortable add\n        $(\'#table-body-add\').sortable({\n            handle: \'td:first-child\', // Restrict drag start to the first cell (Position)\n            update: function(event, ui) {\n                updateRowNumbers(); // Update row numbers and input names after reordering\n            },\n            start: function(event, ui) {\n              ui.item.addClass(\'dragging\');\n            },\n            stop: function(event, ui) {\n              ui.item.removeClass(\'dragging\');\n            },\n        });\n        \n        document.getElementById(\'image_cover\').addEventListener(\'change\', function(event) {\n            const file = event.target.files[0];\n            if (file) {\n                const reader = new FileReader();\n                reader.onload = function(e) {\n                    const img = document.getElementById(\'image_preview\');\n                    img.src = e.target.result;\n                    img.style.display = \'block\';\n                }\n                reader.readAsDataURL(file);\n            }\n        });\n        \n        document.getElementById(\'virtual_product_file\').addEventListener(\'change\', function(event) {\n            var fileInfoDiv = document.getElementById(\'field-info-virtual_product_file\');\n            var fileName = event.target.files[0] ? event.target.files[0].name : \"Aucun fichier sélectionné\";\n            fileInfoDiv.textContent = fileName;\n        });\n        document.getElementById(\'image_cover\').addEventListener(\'change\', function(event) {\n            var fileInfoDiv = document.getElementById(\'field-info-image-cover\');\n            var fileName = event.target.files[0] ? event.target.files[0].name : \"Aucun fichier sélectionné\";\n            fileInfoDiv.textContent = fileName;\n        });\n    \n        // Make table rows sortable edit\n        $(\'#table-body-edit\').sortable({\n            handle: \'td:first-child\',\n            update: function(event, ui) {\n                updateEditRowNumbers();\n        \n                var order = getOrder();\n                $.ajax({\n                    url: edit_product_url,\n                    type: \'POST\',\n                    dataType: \'json\',\n                    data: { action: \'update_order\', order: order },\n                    success: function(response) {\n                        showNotification(response.message);\n                        if (response.success) {\n                            // Optionnel : mettre à jour l\'interface utilisateur\n                        }\n                    },\n                    fail: function(response) {\n                        alert(response.message);\n                    }\n                });\n            },\n            start: function(event, ui) {\n                ui.item.addClass(\'dragging\');\n            },\n            stop: function(event, ui) {\n                ui.item.removeClass(\'dragging\');\n            },\n        });\n    \n        function getOrder() {\n            var order = {};\n            $(\'#table-body-edit tr\').each(function(index, element) {\n                var id = $(element).find(\'.deleteBtn\').data(\'id\');\n                var position = index + 1;\n                order[id] = position;\n            });\n            return order;\n        }\n    \n    \n        $(\'#addImageBtn2\').on(\'click\', function() {\n            $(\'#fileInput2\').click();\n        });\n    \n        $(\'#fileInput2\').on(\'change\', function(e) {\n            e.preventDefault();\n            var formData = new FormData();\n            var position_for_new_photo = $(\'#table-body-edit tr\').length + 1;\n            var product_id = $(\'#product_to_edit\').text();\n    \n            formData.append(\'product_id\', product_id);\n            formData.append(\'action\', \'add_product_image\');\n            formData.append(\'position\', position_for_new_photo);\n            formData.append(\'file\', this.files[0]);\n            \n            $.ajax({\n                url: edit_product_url,\n                type: \'POST\',\n                dataType: \'json\',\n                data: formData,\n                processData: false,\n                contentType: false\n            }).done(function(response) {\n                showNotification(response.message);\n                if (response.success) {\n                    location.reload(); // Recharge la page\n                }\n            }).fail(function(response) {\n                alert(response.message);\n            });\n        });\n    \n        \n        $(\'.deleteBtn\').on(\'click\', function(e) {\n            e.preventDefault();\n            var id_image = $(this).data(\'id\');\n            $.ajax({\n                url: edit_product_url,\n                type: \"POST\",\n                dataType: \"json\", // On attend une réponse JSON du serveur\n                data: { action: \'delete_image\', \'id_image\': id_image }\n            }).done(function(response) {\n                showNotification(response.message);\n                if (response.success) {\n                    $(\'tr[data-id=\"\' + id_image + \'\"]\').remove();\n                    //updateEditRowNumbers();\n                }\n            }).fail(function() {\n                alert(\'error\');\n            });\n        });\n    \n    \n        function updateEditRowNumbers() {\n            $(\'#table-body-edit tr\').each(function(index) {\n                $(this).find(\'.rowCount\').text(index + 1);\n            });\n        }\n    \n        function showNotification(message) {\n            $(\'.notification\').text(message).fadeIn().delay(2000).fadeOut();\n        }\n    \n    \n        // Get references to the checkboxes and the submit button\n        const dolibarrTermsCheckbox = document.getElementById(\'dolibarr_terms\');\n        const moduleWikiCheckbox = document.getElementById(\'module_wiki\');\n        const submitButton = document.getElementById(\'sub\');\n    \n        // Function to check the state of the checkboxes and update the button state\n        function updateButtonState() {\n            if (dolibarrTermsCheckbox.checked && moduleWikiCheckbox.checked) {\n                submitButton.disabled = false;\n                submitButton.style.opacity = 1.0;\n                submitButton.classList.remove(\'button_large_disabled\');\n                submitButton.classList.add(\'button_large\');\n            } else {\n                submitButton.disabled = true;\n                submitButton.style.opacity = 0.5;\n                submitButton.classList.add(\'button_large_disabled\');\n                submitButton.classList.remove(\'button_large\');\n            }\n        }\n    \n        // Add event listeners to the checkboxes to monitor changes\n        dolibarrTermsCheckbox.addEventListener(\'change\', updateButtonState);\n        moduleWikiCheckbox.addEventListener(\'change\', updateButtonState);\n    \n        // Initial check to set the button state based on the initial checkbox states\n        updateButtonState();\n    \n    \n    });\n</script>',NULL,'','',0,NULL,NULL),
