-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathNotification_NoFile_Handler.php
More file actions
51 lines (40 loc) · 1.16 KB
/
Notification_NoFile_Handler.php
File metadata and controls
51 lines (40 loc) · 1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
require_once('controller.php');
$idDemande = $_POST["id"];
$action= $_POST["action"];
$target= $_POST["target"];
$prix = $_POST["prix"];
$fileExist = $_POST["fileExist"];
$userId = $_COOKIE["userid"];
$file = "";
echo ($fileExist == false);
if (strcmp($fileExist, "true")==0){
$file = $_FILES["customFile"];
}
$notification_Controller = new NotificationInterractionController();
if (strcmp($action, "accept") == 0){
$r = $notification_Controller->acceptDemande($idDemande, $userId, $target, $prix);
echo $r;
}
if (strcmp($action, "vu") == 0){
echo $file;
$r = $notification_Controller->seeDemande($idDemande, $target, $file);
echo $r;
}
if (strcmp($action, "vuPaiementClient") == 0){
$r = $notification_Controller->seePaiementClient($idDemande, $target);
echo $r;
}
if (strcmp($action, "startWork") == 0){
$r = $notification_Controller->startWork($idDemande, $target);
echo $r;
}
if (strcmp($action, "startVu") == 0){
$r = $notification_Controller->seeStart($idDemande, $target);
echo $r;
}
if (strcmp($action, "finishedVu") == 0){
$r = $notification_Controller->seeAccepted($idDemande, $target);
echo $r;
}
?>