ViroManchego Posted March 18, 2021 Report Posted March 18, 2021 public function add() { $ticket_data = [ 'vars' => [ 'department_id' => 1, 'staff_id' => 1, // This field is optional 'service_id' => null, // This field is optional 'client_id' => 1, // This field is optional 'email' => null, // This field is optional 'summary' => 'Something is terribly wrong', 'priority' => 'emergency', 'status' => 'awaiting_reply' ] ]; $response = $this->post("support_manager.support_manager_tickets", "add", $ticket_data); if ($response->errors() !== false) { if ($response->errors() !== false) { // There were errors attempting that action return($response->errors()); } elseif (($result = $response->response())) { // The response was successful and returned data return($result); } else { // Something else happened echo "Response code: " . $response->responseCode(); var_dump($response->raw()); } } elseif (($result = $response->response())) { // The response was successful and returned data return $result; } else { // Something else happened echo "Response code: " . $response->responseCode(); var_dump($response->raw()); } } this is working , got response with ticket id , but tickets not available on control panel . i'm missing something ?
ViroManchego Posted March 18, 2021 Author Report Posted March 18, 2021 replys are required in order to appear on admin interface ?
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now