mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-26 09:04:28 +00:00
Notizen löschen würde hinzugefügt
This commit is contained in:
+6
-4
@@ -128,15 +128,17 @@ function saveNotiz($username, $passwort, $notiz)
|
||||
* Löscht die Notiz mit der vom Webservice übergebenen ID
|
||||
* @param $notiz_id
|
||||
*/
|
||||
function deleteNotiz($notiz_id)
|
||||
function deleteNotiz($username, $passwort, $notiz_id)
|
||||
{
|
||||
$user = get_uid();
|
||||
|
||||
|
||||
if(!$user = check_user($username, $passwort))
|
||||
return new SoapFault("Server", "Invalid Credentials");
|
||||
|
||||
$rechte = new benutzerberechtigung();
|
||||
$rechte->getBerechtigungen($user);
|
||||
|
||||
if(!$rechte->isBerechtigt('basis/notiz', null, 'suid'))
|
||||
return new SoapFault("Server", "Sie haben keine Berechtigung zum Speichern von Notizen");
|
||||
return new SoapFault("Server", "Sie haben keine Berechtigung zum Loeschen von Notizen");
|
||||
|
||||
$notiz = new notiz();
|
||||
if($notiz->delete($notiz_id))
|
||||
|
||||
@@ -41,6 +41,8 @@ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
|
||||
<wsdl:part name="message" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
<wsdl:message name="deleteNotizRequest">
|
||||
<wsdl:part name="username" type="xsd:string" minOccurs="0"></wsdl:part>
|
||||
<wsdl:part name="passwort" type="xsd:string" minOccurs="0"></wsdl:part>
|
||||
<wsdl:part name="notiz_id" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
<wsdl:message name="deleteNotizResponse">
|
||||
|
||||
Reference in New Issue
Block a user