diff --git a/add_calendar_event_modal.php b/add_calendar_event_modal.php
index 3337b2c3..a845b9a3 100644
--- a/add_calendar_event_modal.php
+++ b/add_calendar_event_modal.php
@@ -67,6 +67,22 @@
+
+
diff --git a/calendar_events.php b/calendar_events.php
index 07e059dd..39c914b1 100644
--- a/calendar_events.php
+++ b/calendar_events.php
@@ -26,6 +26,7 @@ while($row = mysqli_fetch_array($sql)){
$event_title = $row['event_title'];
$event_start = $row['event_start'];
$event_end = $row['event_end'];
+ $event_repeat = $row['event_repeat'];
$calendar_id = $row['calendar_id'];
$calendar_name = $row['calendar_name'];
$calendar_color = $row['calendar_color'];
diff --git a/db.sql b/db.sql
index da5a3114..ce6b0496 100644
--- a/db.sql
+++ b/db.sql
@@ -295,6 +295,7 @@ CREATE TABLE `events` (
`event_title` varchar(200) NOT NULL,
`event_start` datetime NOT NULL,
`event_end` datetime DEFAULT NULL,
+ `event_repeat` varchar(200) DEFAULT NULL,
`event_created_at` datetime NOT NULL,
`event_updated_at` datetime DEFAULT NULL,
`event_archived_at` datetime DEFAULT NULL,
@@ -980,4 +981,4 @@ CREATE TABLE `vendors` (
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
--- Dump completed on 2021-03-24 22:03:13
+-- Dump completed on 2021-03-27 16:49:58
diff --git a/edit_calendar_event_modal.php b/edit_calendar_event_modal.php
index 80224e4e..ccb3f77a 100644
--- a/edit_calendar_event_modal.php
+++ b/edit_calendar_event_modal.php
@@ -66,6 +66,22 @@
+
+
@@ -113,4 +129,4 @@
-
\ No newline at end of file
+
diff --git a/post.php b/post.php
index 1cbc317c..73b5f442 100644
--- a/post.php
+++ b/post.php
@@ -842,10 +842,11 @@ if(isset($_POST['add_event'])){
$title = strip_tags(mysqli_real_escape_string($mysqli,$_POST['title']));
$start = strip_tags(mysqli_real_escape_string($mysqli,$_POST['start']));
$end = strip_tags(mysqli_real_escape_string($mysqli,$_POST['end']));
+ $repeat = strip_tags(mysqli_real_escape_string($mysqli,$_POST['repeat']));
$client = intval($_POST['client']);
$email_event = intval($_POST['email_event']);
- mysqli_query($mysqli,"INSERT INTO events SET event_title = '$title', event_start = '$start', event_end = '$end', event_created_at = NOW(), calendar_id = $calendar_id, client_id = $client, company_id = $session_company_id");
+ mysqli_query($mysqli,"INSERT INTO events SET event_title = '$title', event_start = '$start', event_end = '$end', event_repeat = '$repeat', event_created_at = NOW(), calendar_id = $calendar_id, client_id = $client, company_id = $session_company_id");
//If email is checked
if($email_event == 1){
@@ -919,10 +920,11 @@ if(isset($_POST['edit_event'])){
$title = strip_tags(mysqli_real_escape_string($mysqli,$_POST['title']));
$start = strip_tags(mysqli_real_escape_string($mysqli,$_POST['start']));
$end = strip_tags(mysqli_real_escape_string($mysqli,$_POST['end']));
+ $repeat = strip_tags(mysqli_real_escape_string($mysqli,$_POST['repeat']));
$client = intval($_POST['client']);
$email_event = intval($_POST['email_event']);
- mysqli_query($mysqli,"UPDATE events SET event_title = '$title', event_start = '$start', event_end = '$end', event_updated_at = NOW(), calendar_id = $calendar_id, client_id = $client WHERE event_id = $event_id AND company_id = $session_company_id");
+ mysqli_query($mysqli,"UPDATE events SET event_title = '$title', event_start = '$start', event_end = '$end', event_repeat = '$repeat', event_updated_at = NOW(), calendar_id = $calendar_id, client_id = $client WHERE event_id = $event_id AND company_id = $session_company_id");
//If email is checked
if($email_event == 1){
@@ -3907,4 +3909,4 @@ if(isset($_GET['export_trips_csv'])){
}
-?>
\ No newline at end of file
+?>