The clone button on my form is not working. Here is what happens:
After clicking on Clone, changing info, and clicking on Save, my form gets all empty. Here is the error message in the debug console:
Code: Select all
[0] :
===USER==========
globeadmin
===PDO MESSAGE===
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '72' for key 'PRIMARY'
===SQL===========
INSERT INTO entreprise (`entreprise_groupe_id`, `entreprise_telfixe`, `entreprise_ville`, `entreprise_siteweb`, `entreprise_cp`, `entreprise_pays`, `entreprise_contrat_maintenance`, `entreprise_conditions_commerciales_particulieres`, `entreprise_radie`, `entreprise_rachete`, `entreprise_date_ajout`, `entreprise_etat`, `entreprise_statut`, `entreprise_email`, `entreprise_commentaires`, `entreprise_adresse`, `entreprise_nom`, `entreprise_id`) VALUES ('', '', '', '', '', '', '0', '', '0', '', '2018-05-29 19:09:38', '', '', '', '', '', 'TEST2', '72');
===BACK TRACE====
/var/www/erpversus/nudata.php - line 320 (nuRunQuery)
/var/www/erpversus/nuapi.php - line 50 (nuUpdateDatabase)