Browse Source

Allow user to click on calendar events and redirect them to the moment's page or milestones' page accordingly

Victor Hernandez 4 years ago
parent
commit
ac58d723b3
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      special2.php

+ 2
- 0
special2.php View File

98
 		
98
 		
99
 		
99
 		
100
 		// Create a new event for each moment
100
 		// Create a new event for each moment
101
+		// NOTE: Same query as $query4 in viewExperience.php
101
 		$queryMoments = "SELECT SQ.* FROM subquestionnair AS SQ JOIN experience_subquestionnair AS ES WHERE SQ.id = ES.id_subquestionnair AND ES.id_experience = '$experienceID';";
102
 		$queryMoments = "SELECT SQ.* FROM subquestionnair AS SQ JOIN experience_subquestionnair AS ES WHERE SQ.id = ES.id_subquestionnair AND ES.id_experience = '$experienceID';";
102
 // 		$queryMoments = "SELECT * FROM `subquestionnair` WHERE id_questionnair IN (SELECT id_questionnair FROM `experience_questionnair` WHERE id_experience = '$experienceID');";
103
 // 		$queryMoments = "SELECT * FROM `subquestionnair` WHERE id_questionnair IN (SELECT id_questionnair FROM `experience_questionnair` WHERE id_experience = '$experienceID');";
103
 		$resultMoments = mysqli_query($connection, $queryMoments);
104
 		$resultMoments = mysqli_query($connection, $queryMoments);
108
 			$moment->id = $rowMoments['id'] . '-moment';
109
 			$moment->id = $rowMoments['id'] . '-moment';
109
 			$moment->title = $rowMoments['title'];
110
 			$moment->title = $rowMoments['title'];
110
 			$moment->start = $rowMoments['date_to_administer'];//explode(" ", $rowMoments['date_to_administer'])[0];
111
 			$moment->start = $rowMoments['date_to_administer'];//explode(" ", $rowMoments['date_to_administer'])[0];
112
+			$moment->url = 'https://tania.uprrp.edu/admin_nuevo/viewMoment.php?view=' . $rowMoments['id'];
111
 			
113
 			
112
 			// Compute end with expiry_time from experience...
114
 			// Compute end with expiry_time from experience...
113
 			$computedEndTimestamp = strtotime($rowMoments['date_to_administer'] . ' + ' . $rowExperience['expiry_time'] .' minutes');
115
 			$computedEndTimestamp = strtotime($rowMoments['date_to_administer'] . ' + ' . $rowExperience['expiry_time'] .' minutes');