mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-16 22:42:16 +00:00
delete Projektphase hinzugefügt
This commit is contained in:
@@ -33,6 +33,7 @@ require_once('../include/benutzerberechtigung.class.php');
|
||||
|
||||
$SOAPServer = new SoapServer(APP_ROOT."/soap/projektphase.wsdl.php?".microtime());
|
||||
$SOAPServer->addFunction("saveProjektphase");
|
||||
$SOAPServer->addFunction("deleteProjektphase");
|
||||
$SOAPServer->handle();
|
||||
|
||||
// WSDL Chache auf aus
|
||||
@@ -88,6 +89,29 @@ function saveProjektphase($username, $passwort, $phase)
|
||||
else
|
||||
return new SoapFault("Server", $projektphase->errormsg);
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* Loescht die übergebene Projektphase
|
||||
* @param $username
|
||||
* @param $passwort
|
||||
* @param $projektphase_kurzbz
|
||||
*/
|
||||
function deleteProjektphase($username, $passwort, $projektphase_id)
|
||||
{
|
||||
if(!$user = check_user($username, $passwort))
|
||||
return new SoapFault("Server", "Invalid Credentials");
|
||||
|
||||
$rechte = new benutzerberechtigung();
|
||||
$rechte->getBerechtigungen($user);
|
||||
|
||||
if(!$rechte->isBerechtigt('planner', null, 'suid'))
|
||||
return new SoapFault("Server", "Sie haben keine Berechtigung zum Loeschen von Phasen");
|
||||
|
||||
$phase = new projektphase();
|
||||
if($phase->delete($projektphase_id))
|
||||
return "OK";
|
||||
else
|
||||
return new SoapFault("Server", $phase->errormsg);
|
||||
}
|
||||
?>
|
||||
+52
-30
@@ -13,14 +13,14 @@ xmlns:xsd1="http://localhost/soap/projektphase.xsd"
|
||||
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
|
||||
|
||||
|
||||
<wsdl:message name="SaveProjektphaseRequest">
|
||||
<wsdl:message name="SaveProjektphaseRequest">
|
||||
<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="phase" type="tns:phase"></wsdl:part>
|
||||
</wsdl:message>
|
||||
</wsdl:message>
|
||||
|
||||
<xsd:complexType name="phase">
|
||||
<xsd:all>
|
||||
<xsd:complexType name="phase">
|
||||
<xsd:all>
|
||||
<wsdl:part name="projektphase_id" type="xsd:string"></wsdl:part>
|
||||
<wsdl:part name="projekt_kurzbz" type="xsd:string"></wsdl:part>
|
||||
<wsdl:part name="projektphase_fk" type="xsd:string"></wsdl:part>
|
||||
@@ -35,33 +35,55 @@ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
|
||||
</xsd:all>
|
||||
</xsd:complexType>
|
||||
|
||||
<wsdl:message name="SaveProjektphaseResponse">
|
||||
<wsdl:part name="message" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
<wsdl:message name="SaveProjektphaseResponse">
|
||||
<wsdl:part name="message" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
|
||||
<wsdl:message name="DeleteProjektphaseRequest">
|
||||
<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="projektphase_id" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
<wsdl:message name="DeleteProjektphaseResponse">
|
||||
<wsdl:part name="message" type="xsd:string"></wsdl:part>
|
||||
</wsdl:message>
|
||||
|
||||
<wsdl:portType name="ConfigPortType" >
|
||||
<wsdl:operation name="saveProjektphase">
|
||||
<wsdl:input message="tns:SaveProjektphaseRequest"></wsdl:input>
|
||||
<wsdl:output message="tns:SaveProjektphaseResponse"></wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:portType>
|
||||
<wsdl:portType name="ConfigPortType" >
|
||||
<wsdl:operation name="saveProjektphase">
|
||||
<wsdl:input message="tns:SaveProjektphaseRequest"></wsdl:input>
|
||||
<wsdl:output message="tns:SaveProjektphaseResponse"></wsdl:output>
|
||||
</wsdl:operation>
|
||||
<wsdl:operation name="deleteProjektphase">
|
||||
<wsdl:input message="tns:DeleteProjektphaseRequest"></wsdl:input>
|
||||
<wsdl:output message="tns:DeleteProjektphaseResponse"></wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:portType>
|
||||
|
||||
<wsdl:binding name="ConfigBinding" type="tns:ConfigPortType">
|
||||
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
|
||||
<wsdl:operation name="saveProjektphase">
|
||||
<soap:operation soapAction="<?php echo APP_ROOT."soap/saveProjektphase";?>" />
|
||||
<wsdl:input>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
|
||||
</wsdl:input>
|
||||
<wsdl:output>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:binding>
|
||||
<wsdl:binding name="ConfigBinding" type="tns:ConfigPortType">
|
||||
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
|
||||
<wsdl:operation name="saveProjektphase">
|
||||
<soap:operation soapAction="<?php echo APP_ROOT."soap/saveProjektphase";?>" />
|
||||
<wsdl:input>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
|
||||
</wsdl:input>
|
||||
<wsdl:output>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
<wsdl:operation name="deleteProjektphase">
|
||||
<soap:operation soapAction="<?php echo APP_ROOT."soap/deleteProjektphase";?>" />
|
||||
<wsdl:input>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
|
||||
</wsdl:input>
|
||||
<wsdl:output>
|
||||
<soap:body use="encoded" namespace="http://localhost/soap/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:binding>
|
||||
|
||||
<wsdl:service name="Projektphase">
|
||||
<wsdl:port name="ConfigWebservicePort" binding="tns:ConfigBinding">
|
||||
<soap:address location="<?php echo APP_ROOT."soap/projektphase.soap.php";?>"/>
|
||||
</wsdl:port>
|
||||
</wsdl:service>
|
||||
<wsdl:service name="Projektphase">
|
||||
<wsdl:port name="ConfigWebservicePort" binding="tns:ConfigBinding">
|
||||
<soap:address location="<?php echo APP_ROOT."soap/projektphase.soap.php";?>"/>
|
||||
</wsdl:port>
|
||||
</wsdl:service>
|
||||
</wsdl:definitions>
|
||||
|
||||
Reference in New Issue
Block a user