helpdesk-z / helpdeskz-dev

HelpDeskZ is a free PHP based software which allows you to manage your site's support with a web-based support ticket system.
http://www.helpdeskz.com/
GNU General Public License v2.0
83 stars 64 forks source link

Error when creating a ticket from the API #56

Open donpadlo opened 2 years ago

donpadlo commented 2 years ago

When creating a ticket from the API without a file attachment, the ticket is not created

Which code, ticket create ok:

CURLOPT_POSTFIELDS => array('opener' => 'user','user_id' => '1','staff_id' => '1','department_id' => '4','subject' => 'Hello world','body' => 'This is a test message.','attachment[]'=> new CURLFILE('/home/andres/Images/hdz.png'),'notify' => '0'),

Which code, ticket not create :

CURLOPT_POSTFIELDS => array('opener' => 'user','user_id' => '1','staff_id' => '1','department_id' => '4','subject' => 'Hello world','body' => 'This is a test message.','notify' => '0'),