From e63939b64ea06c989f8b2276566bf935b89108b3 Mon Sep 17 00:00:00 2001 From: Javier Pastor Date: Mon, 4 May 2020 16:29:52 +0200 Subject: [PATCH] fix: mysql error: Field 'grouptype' doesn't have a default value I have set "grouptype" to 0, but I don't know if it will be the appropriate value. --- src/admin/groups.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/admin/groups.php b/src/admin/groups.php index b1a13dc..41e8548 100644 --- a/src/admin/groups.php +++ b/src/admin/groups.php @@ -331,9 +331,10 @@ if ( isset($_POST['op']) ) else { // Add new Group now! - $result = DB_Query("INSERT INTO " . DB_GROUPS . " (groupname, groupdescription) + $result = DB_Query("INSERT INTO " . DB_GROUPS . " (groupname, groupdescription, grouptype) VALUES ( '" . $content['groupname'] . "', - '" . $content['groupdescription'] . "' )"); + '" . $content['groupdescription'] . "', + 0 )"); DB_FreeQuery($result); // Do the final redirect @@ -523,4 +524,4 @@ $page -> parser($content, "admin/admin_groups.html"); $page -> output(); // --- -?> \ No newline at end of file +?>