Source for file DBMS_FIELD_SQLSTATEMENT.phpclass

Documentation is available at DBMS_FIELD_SQLSTATEMENT.phpclass

  1. <?php
  2. /**
  3.   * Class file DBMS_FIELD_SQLSTATEMENT.phpclass
  4.   *
  5.   * @project    Open CSP-Management
  6.   * @package    dbms_field
  7.   * @category   blob
  8.   *
  9.   * @author     Peter Krebs <pitlinz@users.sourceforge.net>
  10.   *
  11.   * @license    http://opensource.org/licenses/gpl-license.php GNU Public License
  12.   *
  13.   * @version pk-05-10-04
  14.   *
  15.   ***/
  16.  
  17.  
  18.     require_once dirname(__FILE__)._OCSP_DIRSEP_."DBMS_FIELD_TEXTAREA.phpclass";
  19.  
  20. /**
  21.   * Class DBMS_FIELD_SQLSTATEMENT
  22.   *
  23.   * @project    Open CSP-Management
  24.   * @package    dbms_field
  25.   * @category   blob
  26.   *
  27.   * @author     Peter Krebs <pitlinz@users.sourceforge.net>
  28.   *
  29.   * @license    http://opensource.org/licenses/gpl-license.php GNU Public License
  30.   *
  31.   * @version pk-05-10-04
  32.   *
  33.   ***/
  34.       var $className     = "SQL-Statement";
  35.       var $isSearchable  = FALSE;
  36.       var $nlToBr        = FALSE;
  37.       var $allowSQL      = TRUE;
  38.  
  39.     /**
  40.       * source file of the class
  41.       *
  42.       * @var string $classSrcFile 
  43.       * @since pk-05-10-04
  44.       ***/
  45.     var $classSrcFile=__FILE__;
  46.  
  47.     /**
  48.       * @param boolean $showSize 
  49.       * @param boolean $showSortFld 
  50.       * @param boolean $showDBFld 
  51.       *
  52.       ***/
  53.     function editTblForm($showSize=FALSE{
  54.         parent::editTblForm($showSize);
  55.         $this->allowSQL=TRUE;
  56.     }
  57.  
  58.     /**
  59.       * @return boolean 
  60.       ***/
  61.     function save({
  62.         $ret parent::save();
  63.         $this->allowSQL=TRUE;
  64.         $this->allowHTML=FALSE;
  65.         return $ret;
  66.     }
  67.  
  68.     /**
  69.       * returns the html code for a editable formular element
  70.       *
  71.       * @param mixed $aValue the value to set
  72.       * @param string $arrName 
  73.       * @param string $nameAdd  append something to name like "[VALUE]" for search forms
  74.       *
  75.       * @global array $OCSP_CONF 
  76.       *
  77.       * @return string 
  78.       *
  79.       * @since pk-04-10-05
  80.       *
  81.       ***/
  82.     function getInputTag($aValue,$arrName="DBVAL",$nameAdd="",$debug=FALSE{
  83.         global $OCSP_CONF;
  84.  
  85.         if ($debugechoDebugMethod(__FILE__,get_class($this),"DBMS_FIELD_SQLSTATEMENT::getInputTag(\$aValue,$arrName,$nameAdd,...) [".$this->getKey()."]");
  86.  
  87.         $tag="<img src=\"".$OCSP_CONF['SYSIMGURL']."/icons-16x16/utilities.png\" border=\"0\" alt=\"SQL-Editor\" class=\"button\" onClick=\"";
  88.         $tag.="\t\turl='".$OCSP_CONF['SYSTEMURL']."forms/sqlStatement.php';\n";
  89.         $tag.="\t\turl+='?ARRNAME=".$this->myDataArrName."';\n";
  90.         $tag.="\t\turl+='&FLDNAME=".$this->myName."';\n";
  91.         $tag.="\t\twnd=openWindow('selectgen_".$this->myName."',url,700,600);\n";
  92.         $tag.="\"/>";
  93.  
  94.         $tag.=" SELECT <br />";
  95.         $tag.=parent::getInputTag($aValue,$arrName,$nameAdd,$debug);
  96.  
  97.         return $tag;
  98.  
  99.     }
  100.  
  101. // end class DBMS_FIELD_SQLSTATEMENT
  102. ?>

Documentation generated on Thu, 08 Jan 2009 17:42:55 +0100 by phpDocumentor 1.4.0a2