From 64f251c3dbfa051d9af88b43a6f1df36ad0e18af Mon Sep 17 00:00:00 2001 From: Karl Burkhart Date: Mon, 7 Mar 2011 09:36:19 +0000 Subject: [PATCH] --- include/wawi_tags.class.php | 169 ------------------------------------ 1 file changed, 169 deletions(-) delete mode 100644 include/wawi_tags.class.php diff --git a/include/wawi_tags.class.php b/include/wawi_tags.class.php deleted file mode 100644 index ff18ea4cf..000000000 --- a/include/wawi_tags.class.php +++ /dev/null @@ -1,169 +0,0 @@ -, - * Andreas Oesterreicher and - * Karl Burkhart . - */ -/** - * Klasse WaWi Tags - */ - -require_once(dirname(__FILE__).'/basis_db.class.php'); -require_once(dirname(__FILE__).'/sprache.class.php'); - -class wawi_tags extends basis_db -{ - public $result = array(); // Konto Objekt - - //Tabellenspalten - public $tag; // integer - public $bestellung_id; // string - public $insertamum; // timestamp - public $insertvon; // string - - public $bestelldetail_id; - - - - - /** - * Konstruktor - * @param $konto_id ID des Kontos das geladen werden soll (Default=null) - */ - public function __construct($tag=null) - { - parent::__construct(); - - if(!is_null($tag)) - $this->load($tag); - } - - - public function getAll() - { - $qry = "Select * from public.tbl_tag; "; - - if($this->db_query($qry)) - { - while($row = $this->db_fetch_object()) - { - $tag = new wawi_tags(); - - $tag->tag = $row->tag; - - $this->result[] = $tag; - } - return true; - } - else - { - $this->errormsg = "Fehler bei der Abfrage aufgetreten."; - return false; - } - - } - - /** - * - * Gibt die Tags einer Bestellung zurück - * @param unknown_type $bestellung_id - */ - public function GetTagsByBestellung($bestellung_id) - { - if(!is_numeric($bestellung_id)) - { - $this->errormsg = "Ungültige Bestellung ID"; - return false; - } - - $qry = "Select * from wawi.tbl_bestellungtag where bestellung_id = ".$bestellung_id.";"; - - if($this->db_query($qry)) - { - while($row = $this->db_fetch_object()) - { - $bestelltag = new wawi_tags(); - - $bestelltag->tag = $row->tag; - $bestelltag->bestellung_id = $row->bestellung_id; - $bestelltag->insertamum = $row->insertamum; - $bestelltag->insertvon = $row->insertvon; - - $this->result[] = $bestelltag; - } - } - else - { - $this->errormsg = "Fehler bei Abfrage aufgetreten."; - return false; - } - return true; - } - - /** - * - * gibt die Tags per strichpunkt getrennt zurück - */ - public function GetStringTags() - { - $string = ''; - foreach($this->result as $row) - { - if($string!='') - $string.='; '; - $string.=($row->tag); - } - return $string; - } - - - public function GetTagsByBesteldetail($bestelldetail_id) - { - /*if(!is_numeric($bestelldetail_id)) - { - $this->errormsg = "Ungültige Bestelldetail ID"; - return false; - }*/ - - $qry = "Select * from wawi.tbl_bestelldetailtag where bestelldetail_id = ".$bestelldetail_id.";"; - - if($this->db_query($qry)) - { - while($row = $this->db_fetch_object()) - { - $bestelltag = new wawi_tags(); - - $bestelltag->tag = $row->tag; - $bestelltag->bestelldetail_id = $row->bestelldetail_id; - $bestelltag->insertamum = $row->insertamum; - $bestelltag->insertvon = $row->insertvon; - - $this->result[] = $bestelltag; - } - } - else - { - $this->errormsg = "Fehler bei Abfrage aufgetreten."; - return false; - } - return true; - } - - -} -