implement functionallity for phase

This commit is contained in:
OliiverHacker
2021-03-31 19:14:01 +02:00
parent 1b38b1adca
commit c37fb8836d
5 changed files with 39 additions and 12 deletions
+1 -1
View File
@@ -236,7 +236,7 @@ function saveProjektDetail()
projekt.appendChild(new SOAPObject("aufwandstyp_kurzbz")).val(aufwandstyp_kurzbz);
projekt.appendChild(new SOAPObject("anzahl_ma")).val(anzahl_ma);
projekt.appendChild(new SOAPObject("aufwand_pt")).val(aufwand_pt);
console.log(buchbar);
if(buchbar)
{
projekt.appendChild(new SOAPObject("buchbar")).val('true');
+17 -4
View File
@@ -190,9 +190,9 @@ function onselectTreeProjektphase()
document.getElementById('textbox-projektphase-detail-farbe').value=farbe;
document.getElementById('checkbox-projektphase-detail-neu').checked=false;
if(buchbar=='Nein')
document.getElementById('checkbox-projekt-detail-buchbar').checked=false;
document.getElementById('checkbox-projektphase-detail-buchbar').checked=false;
else
document.getElementById('checkbox-projekt-detail-buchbar').checked=true;
document.getElementById('checkbox-projektphase-detail-buchbar').checked=true;
MenulistSelectItemOnValue('menulist-projektphase-detail-projektphase_fk', projektphase_fk);
MenulistSelectItemOnValue('menulist-projektphase-detail-ressource', ressource_id);
@@ -247,6 +247,7 @@ function saveProjektphaseDetail()
var personentage = document.getElementById('textbox-projektphase-detail-personentage').value;
var farbe = document.getElementById('textbox-projektphase-detail-farbe').value;
var neu = document.getElementById('checkbox-projektphase-detail-neu').checked;
var buchbar = document.getElementById('checkbox-projektphase-detail-buchbar').checked;
var soapBody = new SOAPObject("saveProjektphase");
//soapBody.appendChild(new SOAPObject("username")).val('joe');
@@ -265,10 +266,22 @@ function saveProjektphaseDetail()
phase.appendChild(new SOAPObject("budget")).val(budget);
phase.appendChild(new SOAPObject("personentage")).val(personentage);
phase.appendChild(new SOAPObject("farbe")).val(farbe);
if(neu)
phase.appendChild(new SOAPObject("neu")).val('true');
if(buchbar)
{
phase.appendChild(new SOAPObject("buchbar")).val('true');
}
else
{
phase.appendChild(new SOAPObject("buchbar")).val('false');
}
if(neu)
{
phase.appendChild(new SOAPObject("neu")).val('true');
}
else
{
phase.appendChild(new SOAPObject("neu")).val('false');
}
phase.appendChild(new SOAPObject("user")).val(getUsername());
soapBody.appendChild(phase);
+1 -1
View File
@@ -358,7 +358,7 @@ class projektphase extends basis_db
'farbe='.$this->db_add_param($this->farbe).', '.
'personentage='.$this->db_add_param($this->personentage).', '.
'updateamum= now(), '.
'updatevon='.$this->db_add_param($this->updatevon).' '.
'updatevon='.$this->db_add_param($this->updatevon).', '.
'buchbar='.$this->db_add_param($this->buchbar,FHC_BOOLEAN).' '.
'WHERE projektphase_id='.$this->db_add_param($this->projektphase_id, FHC_INTEGER).';';
}
+17 -4
View File
@@ -70,8 +70,8 @@ function saveProjektphase($username, $passwort, $phase)
$projektphase->projektphase_id=$phase->projektphase_id;
$projektphase->projekt_kurzbz=$phase->projekt_kurzbz;
$projektphase->projektphase_fk=$phase->projektphase_fk;
$projektphase->bezeichnung = $phase->bezeichnung;
$projektphase->typ = $phase->typ;
$projektphase->bezeichnung = $phase->bezeichnung;
$projektphase->typ = $phase->typ;
$projektphase->ressource_id = $phase->ressource_id;
$projektphase->beschreibung = $phase->beschreibung;
$projektphase->start = $phase->start;
@@ -82,10 +82,23 @@ function saveProjektphase($username, $passwort, $phase)
$projektphase->updatevon = $user;
$projektphase->updateamum = date('Y-m-d H:i:s');
if($phase->neu=='true')
$projektphase->new = true;
if($phase->buchbar=='true')
{
$projektphase->buchbar = true;
}
else
{
$projektphase->buchbar = false;
}
if($phase->neu=='true')
{
$projektphase->new = true;
}
else
{
$projektphase->new = false;
}
if($projektphase->save())
return $projektphase->projektphase_id;
+3 -2
View File
@@ -24,8 +24,8 @@ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
<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>
<wsdl:part name="bezeichnung" type="xsd:string"></wsdl:part>
<wsdl:part name="typ" type="xsd:string"></wsdl:part>
<wsdl:part name="bezeichnung" type="xsd:string"></wsdl:part>
<wsdl:part name="typ" type="xsd:string"></wsdl:part>
<wsdl:part name="ressource_id" type="xsd:string"></wsdl:part>
<wsdl:part name="beschreibung" type="xsd:string"></wsdl:part>
<wsdl:part name="start" type="xsd:string"></wsdl:part>
@@ -35,6 +35,7 @@ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
<wsdl:part name="farbe" type="xsd:string"></wsdl:part>
<wsdl:part name="user" type="xsd:string"></wsdl:part>
<wsdl:part name="neu" type="xsd:boolean"></wsdl:part>
<wsdl:part name="buchbar" type="xsd:string"></wsdl:part>
</xsd:all>
</xsd:complexType>