public function initPullDown() { $this->ttidtm_ressource->DataSource = PFH::build_SQLPullDown(RessourceRecord::finder(), "tm_ressource", array("idtm_ressource", "res_name")); $this->ttidtm_ressource->dataBind(); $this->Tedidta_aufgaben_type->DataSource = PFH::build_SQLPullDown(AufgabenTypeRecord::finder(), "ta_aufgaben_type", array("idta_aufgaben_type", "auf_type_name")); $this->Tedidta_aufgaben_type->dataBind(); }
public function onLoad($param) { //Globale definition f�r dieses Dokument $this->finder = TerminRecord::finder(); $this->MASTERRECORD = new TerminRecord(); $this->setUserStartId($this->user->getStartNode($this->user->getUserId($this->user->Name), "tm_activity")); date_default_timezone_set('Europe/Berlin'); parent::onLoad($param); if (!$this->isPostBack && !$this->isCallback) { $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_activity"); $HRKEYTest->setRecordClass(ActivityRecord::finder()); $HRKEYTest->setPKField("idtm_activity"); $HRKEYTest->setField("act_name"); $HRKEYTest->setStartNode($this->UserStartId); $HRKEYTest->setSQLCondition("idta_activity_type = 2"); $HRKEYTest->letsrun(); $this->FFidtm_activity->DataSource = $HRKEYTest->myTree; $this->FFidtm_activity->dataBind(); $tmpstartdate = new DateTime(); $this->ter_startdate->setDate($tmpstartdate->format("Y-m-d")); $this->ter_enddate->setDate($tmpstartdate->format("Y-m-d")); $this->ttidtm_ressource->DataSource = PFH::build_SQLPullDown(RessourceRecord::finder(), "tm_ressource", array("idtm_ressource", "res_name"), "idta_ressource_type>1"); $this->ttidtm_ressource->dataBind(); $this->bindListTermin(); } }
public function bindList() { $SQL1 = "SELECT ta_adresse.idta_adresse FROM ta_adresse INNER JOIN ta_partei_has_ta_adresse ON ta_adresse.idta_adresse = ta_partei_has_ta_adresse.idta_adresse INNER JOIN ta_partei ON ta_partei_has_ta_adresse.idta_partei = ta_partei.idta_partei WHERE ta_partei.idtm_user = "******"idta_adresse = '0'"; } $criteria->Condition = $myCondition; $criteria->setLimit($this->RepeaterWaren->PageSize); $criteria->setOffset($this->RepeaterWaren->PageSize * $this->RepeaterWaren->CurrentPageIndex); if (is_Object(WarenRecord::finder()->find($criteria))) { $this->RepeaterWaren->VirtualItemCount = WarenRecord::finder()->find($criteria)->count(); } $this->RepeaterWaren->DataSource = WarenRecord::finder()->findAll($criteria); $this->RepeaterWaren->DataBind(); }
public function onInit($param) { parent::onInit($param); if (!$this->isPostBack) { switch ($this->Request['modus']) { case 0: $sql = "SELECT idtm_country, country_ful FROM tm_country"; $data = PFH::convertdbObjectArray(CountryRecord::finder()->findAllBySql($sql), array("idtm_country", "country_ful")); $this->Country->DataSource = $data; $this->Country->dataBind(); $this->idta_partei->Data = $this->Request['idta_partei']; break; case 1: $sql = "SELECT idtm_country, country_ful FROM tm_country"; $data = PFH::convertdbObjectArray(CountryRecord::finder()->findAllBySql($sql), array("idtm_country", "country_ful")); $this->edCountry->DataSource = $data; $this->edCountry->dataBind(); $this->fillValues($this->getSelected($this->Request['idta_adresse'])); break; default: break; } $this->viewPanel->ActiveViewIndex = $this->Request['modus']; } }
private function generateListFields() { $this->idtm_organisation->DataSource = PFH::build_SQLPullDown(OrganisationRecord::finder(), "tm_organisation", array("idtm_organisation", "org_name"), "idta_organisation_type = 4"); $this->idtm_organisation->dataBind(); $this->idta_protokoll_ergebnistype->DataSource = PFH::build_SQLPullDown(ProtokollErgebnistypeRecord::finder(), "ta_protokoll_ergebnistype", array("idta_protokoll_ergebnistype", "prt_ergtype_name")); $this->idta_protokoll_ergebnistype->dataBind(); }
public function buildPivotPullDown() { $this->PBDedidta_stammdaten_group->DataSource = PFH::build_SQLPullDown(StammdatenGroupRecord::finder(), "ta_stammdaten_group", array("idta_stammdaten_group", "stammdaten_group_name")); $this->PBDedidta_stammdaten_group->dataBind(); $this->PBDedparent_idtm_pivot->DataSource = PFH::build_SQLPullDown(PivotRecord::finder(), "tm_pivot", array("idtm_pivot", "idtm_pivot"), "idta_pivot_bericht = " . $this->page->idta_pivot_bericht->Text); $this->PBDedparent_idtm_pivot->DataBind(); }
public function onInit($param) { parent::onInit($param); //Globale definition f�r dieses Dokument $this->finder = StrukturRecord::finder(); $this->MASTERRECORD = new StrukturRecord(); if (!$this->isPostBack && !$this->isCallback) { switch ($this->Request['modus']) { case 0: $sql = "SELECT idta_struktur_type, struktur_type_name FROM ta_struktur_type"; $data = PFH::convertdbObjectArray(StrukturTypeRecord::finder()->findAllBySql($sql), array("idta_struktur_type", "struktur_type_name")); $this->idta_struktur_type->DataSource = $data; $this->idta_struktur_type->dataBind(); $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_struktur"); $HRKEYTest->setRecordClass(StrukturRecord::finder()); $HRKEYTest->setPKField("idtm_struktur"); $HRKEYTest->setField("struktur_name"); $HRKEYTest->letsrun(); $this->parent_idtm_struktur->DataSource = $HRKEYTest->myTree; $this->parent_idtm_struktur->dataBind(); $this->idtm_stammdaten->DataSource = PFH::build_SQLPullDown(StammdatenRecord::finder(), "tm_stammdaten", array("idtm_stammdaten", "stammdaten_name")); $this->idtm_stammdaten->dataBind(); break; case 1: $sql = "SELECT idta_struktur_type, struktur_type_name FROM ta_struktur_type"; $data = PFH::convertdbObjectArray(StrukturTypeRecord::finder()->findAllBySql($sql), array("idta_struktur_type", "struktur_type_name")); $this->edidta_struktur_type->DataSource = $data; $this->edidta_struktur_type->dataBind(); if ($this->Request[$this->primarykey] != 1) { $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_struktur"); $HRKEYTest->setRecordClass(StrukturRecord::finder()); $HRKEYTest->setPKField("idtm_struktur"); $HRKEYTest->setField("struktur_name"); $HRKEYTest->letsrun(); $data = $HRKEYTest->myTree; } else { $data = array(); $data[0] = "START"; } $this->edparent_idtm_struktur->DataSource = $data; $this->edparent_idtm_struktur->dataBind(); $this->fillValues($this->getSelected($this->Request[$this->primarykey])); $this->edidtm_stammdaten->DataSource = PFH::build_SQLPullDown(StammdatenRecord::finder(), "tm_stammdaten", array("idtm_stammdaten", "stammdaten_name")); $this->edidtm_stammdaten->dataBind(); $Usersql = "SELECT idtm_user, user_name FROM tm_user"; $Userdata = PFH::convertdbObjectArray(UserRecord::finder()->findAllBySql($Usersql), array("idtm_user", "user_name")); $this->idtm_user->DataSource = $Userdata; $this->idtm_user->dataBind(); $this->loadBerechtigung(); break; default: break; } $this->viewPanel->ActiveViewIndex = $this->Request['modus']; $this->StrukturStammdatenGroupContainer->RCedidtm_struktur->Text = $this->Request[$this->primarykey]; } }
public function onLoad($param) { parent::onLoad($param); $sql = "SELECT idtm_user_role, user_role_name FROM tm_user_role WHERE user_role_name = 'Benutzer'"; $data = PFH::convertdbObjectArray(UserRoleRecord::finder()->findAllBySql($sql), array("idtm_user_role", "user_role_name")); $this->Role->DataSource = $data; $this->Role->dataBind(); }
public function initPullDown() { $sql = "SELECT idta_organisation_type, org_type_name FROM ta_organisation_type ORDER BY org_type_name"; $data = PFH::convertdbObjectArray(OrganisationTypeRecord::finder()->findAllBySql($sql), array("idta_organisation_type", "org_type_name")); $data[-1] = "alle"; $this->WINOrgaidta_organisation_type->DataSource = $data; $this->WINOrgaidta_organisation_type->dataBind(); }
public function buildStrukturStrukturPullDown() { $this->SSedidta_feldfunktion->DataSource = PFH::build_SQLPullDown(FeldfunktionRecord::finder(), "ta_feldfunktion", array("idta_feldfunktion", "ff_name"), "idta_struktur_type = " . $this->page->idta_struktur_type->Text); $this->SSedidta_feldfunktion->DataBind(); $StrukRec = StrukturRecord::finder()->findByidtm_struktur($this->user->getStartNode($this->user->getUserId($this->user->Name), "tm_struktur")); $this->SSedidtm_struktur_to->DataSource = PFH::build_SQLPullDown(StrukturRecord::finder(), "tm_struktur INNER JOIN ta_feldfunktion ON tm_struktur.idta_struktur_type = ta_feldfunktion.idta_struktur_type", array("idtm_struktur", "struktur_name"), "ff_type=3 AND struktur_lft BETWEEN " . $StrukRec->struktur_lft . " AND " . $StrukRec->struktur_rgt); $this->SSedidtm_struktur_to->DataBind(); }
public function suggestUser($sender, $param) { // Get the token $token = $param->getToken(); // Sender is the Suggestions repeater $mySQL = "SELECT idtm_user,user_name FROM tm_user WHERE user_name LIKE '%" . $token . "%'"; $sender->DataSource = PFH::convertdbObjectSuggest(TActiveRecord::finder('UserRecord')->findAllBySQL($mySQL), array('idtm_user', 'user_name')); $sender->dataBind(); }
public function suggestOrganisation($sender, $param) { // Get the token $token = $param->getToken(); // Sender is the Suggestions repeater $mySQL = "SELECT idtm_organisation,org_name,org_vorname FROM tm_organisation WHERE org_name LIKE '%" . $token . "%'"; $sender->DataSource = PFH::convertdbObjectSuggest(TActiveRecord::finder('OrganisationRecord')->findAllBySQL($mySQL), array('idtm_organisation', 'org_name', 'org_vorname')); $sender->dataBind(); }
public function createRiskPullDown() { //risiko oder chance $data = array(0 => "Risiko", 1 => "Chance"); $this->RCedrcv_type->DataSource = $data; $this->RCedrcv_type->DataBind(); //die Risikoklasse $this->RCedidtm_risiko->DataSource = PFH::build_SQLPullDown(RisikoRecord::finder(), "tm_risiko", array("idtm_risiko", "ris_name")); $this->RCedidtm_risiko->dataBind(); }
public function reloadStammdatensichtPullDown($sender, $param) { $item = $param->item; if ($item->ItemType === 'Item' || $item->ItemType === 'AlternatingItem') { $values = PFH::build_SQLPullDown(StammdatenGroupRecord::finder(), "ta_stammdaten_group", array("idta_stammdaten_group", "stammdaten_group_name")); array_push($values, array("no values", "0")); $item->parent_idta_stammdaten_group->DataSource = $values; $item->parent_idta_stammdaten_group->dataBind(); } }
public function onLoad($param) { parent::onLoad($param); if (!$this->isPostBack && !$this->isCallback) { $this->idtm_activity->DataSource = PFH::build_SQLPullDownAdvanced(ActivityRecord::finder(), "tm_activity", array("idtm_activity", "act_name", "act_pspcode"), "idta_activity_type = 2", "act_name ASC"); $this->idtm_activity->dataBind(); $this->idtm_activity->Text = ActivityRecord::finder()->findByparent_idtm_activity('0')->idtm_activity; $this->loadGridValues($sender, $param); } }
public function buildPivotBerichtPullDown() { $this->PBedidta_feldfunktion->DataSource = PFH::build_SQLPullDownAdvanced(FeldfunktionRecord::finder(), "ta_feldfunktion", array("idta_feldfunktion", "idta_struktur_type", "ff_name")); $this->PBedidta_feldfunktion->dataBind(); $this->PBedidta_variante->DataSource = PFH::build_SQLPullDown(VarianteRecord::finder(), "ta_variante", array("idta_variante", "var_descr")); $this->PBedidta_variante->dataBind(); $data = array('SUM' => "SUM", "AVG" => "AVG", "MAX" => "MAX", "MIN" => "MIN"); $this->PBedpivot_bericht_operator->DataSource = $data; $this->PBedpivot_bericht_operator->DataBind(); }
public function initPullDowns() { $this->CBAufgabeDone->DataSource = $this->auf_done; $this->CBAufgabeDone->dataBind(); $this->ttidtm_ressource->DataSource = PFH::build_SQLPullDown(RessourceRecord::finder(), "tm_ressource", array("idtm_ressource", "res_name")); $this->ttidtm_ressource->dataBind(); $this->Tedidta_aufgaben_type->DataSource = PFH::build_SQLPullDown(AufgabenTypeRecord::finder(), "ta_aufgaben_type", array("idta_aufgaben_type", "auf_type_name")); $this->Tedidta_aufgaben_type->dataBind(); $this->CCAufgabenContainerPageSize->DataSource = array(5 => "5", 10 => "10", 25 => "25", 50 => "50"); $this->CCAufgabenContainerPageSize->dataBind(); }
public function calcDistButtonClicked($sender, $param) { //lets add the coordinates $myGTranslator = new GoogleAdressTranslator(); $mapparams = $myGTranslator->getLatAndLong(implode(",", array($this->partner_street->Text, $this->partner_town->Text))); $myLatandLong = explode(",", $mapparams); $arraydistance = array(array($myLatandLong['1'], $myLatandLong['0']), array($this->adresse_lat->Text, $this->adresse_long->Text)); $distance = PFH::getDistance($arraydistance); $baseweight = (double) $this->waren_gewicht->Text; $baseprice = (double) $this->waren_preis->Text; $this->est_waren_preis->Text = $distance * 1.4 / 1000 * 2.5 / 2 * $baseweight / 10000 + $baseprice; }
public function onLoad($param) { //Globale definition f�r dieses Dokument $this->finder = VerteilerRecord::finder(); $this->MASTERRECORD = new VerteilerRecord(); parent::onLoad($param); if (!$this->isPostBack && !$this->isCallback) { $this->ttidtm_organisation->DataSource = PFH::build_SQLPullDown(OrganisationRecord::finder(), "tm_organisation", array("idtm_organisation", "org_name"), "idta_organisation_type=4"); $this->ttidtm_organisation->dataBind(); $this->bindListVerteiler(); } }
public function createRfCPullDown() { //Als erstes die Organisation $this->RfCedsuggest_idtm_organisation->DataSource = PFH::build_SQLPullDown(OrganisationRecord::finder(), "tm_organisation", array("idtm_organisation", "org_name"), "idta_organisation_type = 4"); $this->RfCedsuggest_idtm_organisation->dataBind(); //Als erstes die Organisation $this->RfCedgenemigt_idtm_organisation->DataSource = PFH::build_SQLPullDown(OrganisationRecord::finder(), "tm_organisation", array("idtm_organisation", "org_name"), "idta_organisation_type = 4"); $this->RfCedgenemigt_idtm_organisation->dataBind(); //einlesen der aktivitaeten $this->RfCedidtm_activity->DataSource = PFH::build_SQLPullDownAdvanced(ActivityRecord::finder(), "tm_activity", array("idtm_activity", "act_pspcode", "act_name")); $this->RfCedidtm_activity->dataBind(); }
public function onLoad($param) { date_default_timezone_set('Europe/Berlin'); parent::onLoad($param); if (!$this->page->isPostBack && !$this->page->isCallback) { $tmpstartdate = new DateTime(); $this->res_selected_date->setDate($tmpstartdate->format("Y-m-d")); $this->idta_ressource_type->DataSource = PFH::build_SQLPullDown(RessourceTypeRecord::finder(), "ta_ressource_type", array("idta_ressource_type", "res_type_name")); $this->idta_ressource_type->dataBind(); $this->idta_ressource_type->Text = 4; $this->bindListBelegungsplan(); } }
public function onLoad($param) { parent::onLoad($param); //if(!$this->isPostBack && !$this->isCallback){ $this->DWH_idta_variante->DataSource = PFH::build_SQLPullDown(VarianteRecord::finder(), "ta_variante", array("idta_variante", "var_descr")); $this->DWH_idta_variante->dataBind(); $this->DWH_idta_perioden->DataSource = PFH::build_SQLPullDown(PeriodenRecord::finder(), "ta_perioden", array("per_intern", "per_extern")); $this->DWH_idta_perioden->dataBind(); $tree = $this->MyTree; //$this->addContextMenu($tree->getID()); $node = new StrukturRecord(); $this->fullInTreeStrukturRecord($tree, $node); //} }
private function bindListed() { $SQL1 = "SELECT ta_adresse.* FROM ta_adresse INNER JOIN ta_partei_has_ta_adresse ON ta_adresse.idta_adresse = ta_partei_has_ta_adresse.idta_adresse INNER JOIN ta_partei ON ta_partei_has_ta_adresse.idta_partei = ta_partei.idta_partei WHERE ta_partei.idtm_user = "******" LIMIT " . $this->AdresseListe->PageSize * $this->AdresseListe->CurrentPageIndex . "," . $this->AdresseListe->PageSize; $this->edAdresseListe->DataKeyField = 'edlstidta_adresse'; $validate = PFH::checkCountStatement(AdresseRecord::finder()->findBySql($SQL1)); if ($validate) { $this->edAdresseListe->VirtualItemCount = AdresseRecord::finder()->findBySql($SQL1)->Count(); } else { $this->edAdresseListe->VirtualItemCount = 0; } $this->edAdresseListe->DataSource = $adressen = AdresseRecord::finder()->findAllBySql($SQL1); $this->edAdresseListe->dataBind(); }
public function onLoad($param) { if (!$this->page->IsPostBack && !$this->page->isCallback) { $this->DWH_idta_variante->DataSource = PFH::build_SQLPullDown(VarianteRecord::finder(), "ta_variante", array("idta_variante", "var_descr")); $this->DWH_idta_variante->dataBind(); $this->DWH_idta_stammdatensicht->DataSource = PFH::build_SQLPullDown(StammdatensichtRecord::finder(), "ta_stammdatensicht", array("idta_stammdatensicht", "sts_name")); $this->DWH_idta_stammdatensicht->dataBind(); $this->DWH_idta_struktur_bericht->DataSource = PFH::build_SQLPullDownAdvanced(StrukturBerichtRecord::finder(), "ta_struktur_bericht", array("idta_struktur_bericht", "sb_order", "pivot_struktur_name"), '', 'sb_order'); $this->DWH_idta_struktur_bericht->dataBind(); //first we need to check the szenario, because we recieve the startperiod from the variante... if ($this->Request['idta_variante'] != "") { $this->DWH_idta_variante->Text = $this->Request['idta_variante']; } else { $this->DWH_idta_variante->Text = VarianteRecord::finder()->findByvar_default(1)->idta_variante; $this->DWH_idta_variante->Text == "" ? $this->DWH_idta_variante->Text = 1 : ''; } if ($this->Request['idta_stammdatensicht'] != "") { $this->DWH_idta_stammdatensicht->Text = $this->Request['idta_stammdatensicht']; } else { $this->DWH_idta_stammdatensicht->Text == "" ? $this->DWH_idta_stammdatensicht->Text = 1 : ''; } if ($this->Request['periode'] != "") { $this->DWH_idta_perioden->Text = $this->Request['periode']; } else { $sec_per = "10001"; $this->DWH_idta_perioden->Text = VarianteRecord::finder()->findByidta_variante($this->DWH_idta_variante->Text)->idta_perioden; $this->DWH_idta_perioden->Text == '' ? $this->DWH_idta_perioden->Text = $sec_per : ''; } $this->Request['per_single'] != "" ? $this->DWH_per_single->setChecked($this->Request['per_single']) : $this->DWH_per_single->setChecked(0); if ($this->Request['idta_struktur_bericht'] != '') { $this->DWH_idta_struktur_bericht->Text = $this->Request['idta_struktur_bericht']; } else { $this->DWH_idta_struktur_bericht->Text = StrukturBerichtRecord::finder()->findBysb_startbericht(1)->idta_struktur_bericht; } if ($this->checkPeriodeArea($this->DWH_idta_struktur_bericht->Text)) { $this->DWH_PERIODAREA->setVisible($this->checkPeriodeArea($this->DWH_idta_struktur_bericht->Text)); } else { $this->DWH_PERIODAREA->setVisible($this->checkPeriodeArea($this->DWH_idta_struktur_bericht->Text)); //$this->getPage()->getClientScript()->registerEndScript('XXX','dhxinTab.hideTab("tab2",true);'); } $this->Request['idta_struktur_type'] != "" ? $this->Request['idta_struktur_type'] = 1 : ''; if ($this->Request['idtm_struktur'] != '') { $this->DWH_idtm_struktur->Text = $this->Request['idtm_struktur']; } else { $this->DWH_idtm_struktur->Text = $this->user->getStartNode($this->user->getUserId($this->user->Name), "tm_struktur"); $this->DWH_idtm_struktur->Text == '' ? $this->DWH_idtm_struktur->Text = 1 : ''; } } }
public function onInit($param) { parent::onInit($param); //Globale definition f�r dieses Dokument $this->finder = RisikoRecord::finder(); $this->MASTERRECORD = new RisikoRecord(); if (!$this->isPostBack) { switch ($this->Request['modus']) { case 0: $sql = "SELECT idta_risiko_type, ris_type_name FROM ta_risiko_type"; $data = PFH::convertdbObjectArray(RisikoTypeRecord::finder()->findAllBySql($sql), array("idta_risiko_type", "ris_type_name")); $this->idta_risiko_type->DataSource = $data; $this->idta_risiko_type->dataBind(); if ($this->Request[$this->primarykey] != 1) { $sql = "SELECT idtm_risiko, ris_name FROM tm_risiko ORDER BY idta_risiko_type"; $data = PFH::convertdbObjectArray(RisikoRecord::finder()->findAllBySql($sql), array("idtm_risiko", "ris_name")); } else { $data = array(); $data[0] = "START"; } $this->parent_idtm_risiko->DataSource = $data; $this->parent_idtm_risiko->dataBind(); break; case 1: $sql = "SELECT idta_risiko_type, ris_type_name FROM ta_risiko_type"; $data = PFH::convertdbObjectArray(RisikoTypeRecord::finder()->findAllBySql($sql), array("idta_risiko_type", "ris_type_name")); $this->edidta_risiko_type->DataSource = $data; $this->edidta_risiko_type->dataBind(); if ($this->Request[$this->primarykey] != 1) { $sql = "SELECT idtm_risiko, ris_name FROM tm_risiko ORDER BY idta_risiko_type"; $data = PFH::convertdbObjectArray(RisikoRecord::finder()->findAllBySql($sql), array("idtm_risiko", "ris_name")); } else { $data = array(); $data[0] = "START"; } $this->edparent_idtm_risiko->DataSource = $data; $this->edparent_idtm_risiko->dataBind(); $this->fillValues($this->getSelected($this->Request[$this->primarykey])); //$this->bindListed(); break; default: break; } $this->viewPanel->ActiveViewIndex = $this->Request['modus']; //the parameters for the RiskValueContainer $this->RCedrcv_tabelle->Text = "tm_risiko"; $this->RCedrcv_id->Text = $this->Request[$this->primarykey]; } }
public function onLoad($param) { parent::onLoad($param); if (!$this->isPostBack && !$this->isCallback) { //here comes the part for gantt 1 MUST BE DONE FIRST $tmpstartdate = new DateTime(); $this->gantt_datestart->setDate($tmpstartdate->format("Y-m-d")); $tmpstartdate->modify("30days"); $this->gantt_dateende->setDate($tmpstartdate->format("Y-m-d")); $this->idtm_activity->DataSource = PFH::build_SQLPullDownAdvanced(ActivityRecord::finder(), "tm_activity", array("idtm_activity", "act_name", "act_pspcode"), "idta_activity_type = 2", "act_name ASC"); $this->idtm_activity->dataBind(); $this->idtm_activity->Text = ActivityRecord::finder()->findByparent_idtm_activity('0')->idtm_activity; $this->bindTerminListe(); } }
public function onInit($param) { parent::onInit($param); //Globale definition fuer dieses Dokument $this->finder = ZieleRecord::finder(); $this->MASTERRECORD = new ZieleRecord(); if (!$this->isPostBack) { switch ($this->Request['modus']) { case 0: $sql = "SELECT idta_ziele_type, zie_type_name FROM ta_ziele_type"; $data = PFH::convertdbObjectArray(ZieleTypeRecord::finder()->findAllBySql($sql), array("idta_ziele_type", "zie_type_name")); $this->idta_ziele_type->DataSource = $data; $this->idta_ziele_type->dataBind(); $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_ziele"); $HRKEYTest->setRecordClass(ZieleRecord::finder()); $HRKEYTest->setPKField("idtm_ziele"); $HRKEYTest->setField("zie_name"); $HRKEYTest->letsrun(); $this->parent_idtm_ziele->DataSource = $HRKEYTest->myTree; $this->parent_idtm_ziele->dataBind(); $this->idtm_activity->DataSource = PFH::build_SQLPullDownAdvanced(ActivityRecord::finder(), "tm_activity", array("idtm_activity", "act_pspcode", "act_name"), "idta_activity_type = 2"); $this->idtm_activity->dataBind(); break; case 1: $sql = "SELECT idta_ziele_type, zie_type_name FROM ta_ziele_type"; $data = PFH::convertdbObjectArray(ZieleTypeRecord::finder()->findAllBySql($sql), array("idta_ziele_type", "zie_type_name")); $this->edidta_ziele_type->DataSource = $data; $this->edidta_ziele_type->dataBind(); $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_ziele"); $HRKEYTest->setRecordClass(ZieleRecord::finder()); $HRKEYTest->setPKField("idtm_ziele"); $HRKEYTest->setField("zie_name"); $HRKEYTest->letsrun(); $this->edparent_idtm_ziele->DataSource = $HRKEYTest->myTree; $this->edparent_idtm_ziele->dataBind(); $this->fillValues($this->getSelected($this->Request[$this->primarykey])); $this->edidtm_activity->DataSource = PFH::build_SQLPullDownAdvanced(ActivityRecord::finder(), "tm_activity", array("idtm_activity", "act_pspcode", "act_name"), "idta_activity_type = 2"); $this->edidtm_activity->dataBind(); //$this->bindListed(); break; default: break; } $this->viewPanel->ActiveViewIndex = $this->Request['modus']; } }
public function bindListBox() { $this->for_idta_feldfunktion->DataSource = PFH::build_SQLPullDownAdvanced(FeldfunktionRecord::finder(), "ta_feldfunktion", array("idta_feldfunktion", "ff_name", "idta_struktur_type")); $this->for_idta_feldfunktion->DataBind(); $this->for_from_idta_periode->DataSource = PFH::build_SQLPullDown(PeriodenRecord::finder(), "ta_perioden", array("per_intern", "per_extern")); $this->for_from_idta_periode->dataBind(); $this->for_to_idta_periode->DataSource = PFH::build_SQLPullDown(PeriodenRecord::finder(), "ta_perioden", array("per_intern", "per_extern")); $this->for_to_idta_periode->dataBind(); $this->for_idta_variante->DataSource = PFH::build_SQLPullDown(VarianteRecord::finder(), "ta_variante", array("idta_variante", "var_descr")); $this->for_idta_variante->dataBind(); //definition der wachstumstypen... // 1 = year to year $growthtypes = array(1 => 'year to year'); $this->for_idta_fortschreibungs_type->DataSource = $growthtypes; $this->for_idta_fortschreibungs_type->dataBind(); }
public function initPullDown() { $this->idta_protokoll_ergebnistype->dataSource = PFH::build_SQLPullDown(ProtokollErgebnistypeRecord::finder(), "ta_protokoll_ergebnistype", array("idta_protokoll_ergebnistype", "prt_ergtype_name")); $this->idta_protokoll_ergebnistype->dataBind(); $HRKEYTest = new PFHierarchyPullDown(); $HRKEYTest->setStructureTable("tm_activity"); $HRKEYTest->setRecordClass(ActivityRecord::finder()); $HRKEYTest->setPKField("idtm_activity"); $HRKEYTest->setField("act_name"); $CheckStart = TerminRecord::finder()->findByPK($this->page->edidtm_termin->Text)->idtm_activity; if ($CheckStart > 0) { $HRKEYTest->setStartNode($CheckStart); } $HRKEYTest->letsrun(); $this->idtm_activity->DataSource = $HRKEYTest->myTree; $this->idtm_activity->dataBind(); }
public function onInit($param) { parent::onInit($param); //Globale definition f�r dieses Dokument $this->finder = ProzessRecord::finder(); $this->MASTERRECORD = new ProzessRecord(); if (!$this->isPostBack) { switch ($this->Request['modus']) { case 0: $sql = "SELECT idta_prozess_type, pro_type_name FROM ta_prozess_type"; $data = PFH::convertdbObjectArray(ProzessTypeRecord::finder()->findAllBySql($sql), array("idta_prozess_type", "pro_type_name")); $this->idta_prozess_type->DataSource = $data; $this->idta_prozess_type->dataBind(); if ($this->Request[$this->primarykey] != 1) { $sql = "SELECT idtm_prozess, pro_name FROM tm_prozess ORDER BY idta_prozess_type"; $data = PFH::convertdbObjectArray(ProzessRecord::finder()->findAllBySql($sql), array("idtm_prozess", "pro_name")); } else { $data = array(); $data[0] = "START"; } $this->parent_idtm_prozess->DataSource = $data; $this->parent_idtm_prozess->dataBind(); break; case 1: $sql = "SELECT idta_prozess_type, pro_type_name FROM ta_prozess_type"; $data = PFH::convertdbObjectArray(ProzessTypeRecord::finder()->findAllBySql($sql), array("idta_prozess_type", "pro_type_name")); $this->edidta_prozess_type->DataSource = $data; $this->edidta_prozess_type->dataBind(); if ($this->Request[$this->primarykey] != 1) { $sql = "SELECT idtm_prozess, pro_name FROM tm_prozess ORDER BY idta_prozess_type"; $data = PFH::convertdbObjectArray(ProzessRecord::finder()->findAllBySql($sql), array("idtm_prozess", "pro_name")); } else { $data = array(); $data[0] = "START"; } $this->edparent_idtm_prozess->DataSource = $data; $this->edparent_idtm_prozess->dataBind(); $this->fillValues($this->getSelected($this->Request[$this->primarykey])); //$this->bindListed(); break; default: break; } $this->viewPanel->ActiveViewIndex = $this->Request['modus']; } }