Class PRO_GROUP

Description

openCSP class PRO_GROUP

Located in /products/PRO_GROUP.phpclass (line 36)

OCSP_OBJ
   |
   --DBMS_TABLEOBJ
      |
      --PRO_GROUP
Class Constant Summary
 CLASS_SRC_FILE = __FILE__
Variable Summary
 static array $loadedNodes
 array $myChildren
 array() $myProducts
 string $myTable
Method Summary
 static PRO_GROUP factoryFromDBRow (array $aRow)
 static PRO_GROUP factoryFromId (int $aId)
 static PRO_GROUP &getInstance (int $aId)
 void addProduct ( &$aProduct, PRO_PRODUCT $aProduct)
 boolean curUserCanAddChild ([boolean $debug = False])
 boolean curUserCanAddProduct ([boolean $debug = False])
 boolean curUserCanDelete ([boolean $debug = False])
 boolean curUserCanEdit ([boolean $debug = False])
 boolean curUserCanOpen ([boolean $debug = False])
 int dbInsert ([boolean $debug = False])
 array getAllChildProducts ([boolean $debug = False])
 array getChildren ([boolean $debug = False])
 int getId ()
 int getOrderNr ()
 int getParentId ()
 PRO_PRODUCT &getProduct (int $aProId, [boolean $debug = False])
 array getProductList ([boolean $debug = False])
 void getRootPath ([ $debug = False])
 string getTitle ([int $langId = 0], [boolean $debug = False])
 boolean hasChildren ([boolean $debug = False])
 void isOnline ([boolean $checkProducts = True], [boolean $checkParts = True], [boolean $debug = False])
 void populateChildren ([boolean $debug = False])
 void populateProducts ([boolean $debug = False])
 void setId (int $aId)
 void setOrderNr (int $aNbr)
 void setParentId (int $aId)
Variables
static array $loadedNodes = array() (line 59)

unit of work of loaded product groups

  • access: protected
double $childrenPopulateTS = 0 (line 93)
  • access: protected
array $myChildren = array() (line 74)

children array

  • access: protected
array() $myProducts = array() (line 81)

products assigned to the group

  • access: protected
string $myProductTable = "T_PRO_PRODUCT" (line 100)

product table

  • access: protected
string $myTable = "T_PRO_GROUP" (line 88)
  • access: protected

Redefinition of:
DBMS_TABLEOBJ::$myTable
NOT FINAL !!!!!
double $productPopulateTS = 0 (line 105)
  • access: protected

Inherited Variables

Inherited from DBMS_TABLEOBJ

DBMS_TABLEOBJ::$autoIncFld
DBMS_TABLEOBJ::$dbTableDefinitions
DBMS_TABLEOBJ::$frmPostSubOjects
DBMS_TABLEOBJ::$hasObjVals
DBMS_TABLEOBJ::$initTS
DBMS_TABLEOBJ::$myCacheTS
DBMS_TABLEOBJ::$myFields
DBMS_TABLEOBJ::$myKeys
DBMS_TABLEOBJ::$myLinkedTableRows
DBMS_TABLEOBJ::$myMode
DBMS_TABLEOBJ::$myObjVals
DBMS_TABLEOBJ::$myObjValsPopulateTS
DBMS_TABLEOBJ::$objError
DBMS_TABLEOBJ::$objErrorMsg
DBMS_TABLEOBJ::$populateTS
DBMS_TABLEOBJ::$staticClassVars
DBMS_TABLEOBJ::$valChangeTS

Inherited from OCSP_OBJ

OCSP_OBJ::$global_currentUser
OCSP_OBJ::$global_defaultDBObj_read
OCSP_OBJ::$global_defaultDBObj_write
OCSP_OBJ::$myDBObj
Methods
static factoryFromDBRow (line 135)

factory a product group from an db row

  • access: public
PRO_GROUP factoryFromDBRow (array $aRow)
  • array $aRow
static factoryFromId (line 118)

factory a product group

  • access: public
PRO_GROUP factoryFromId (int $aId)
  • int $aId
static getInstance (line 147)

returns a product group in $self::loadedNodes

  • access: public
PRO_GROUP &getInstance (int $aId)
  • int $aId
addProduct (line 489)

adds a product

  • access: public
void addProduct ( &$aProduct, PRO_PRODUCT $aProduct)
curUserCanAddChild (line 587)

returns if the current user can add a childmenu

boolean curUserCanAddChild ([boolean $debug = False])
  • boolean $debug
curUserCanAddProduct (line 600)

returns if the current user can add a page

boolean curUserCanAddProduct ([boolean $debug = False])
  • boolean $debug
curUserCanDelete (line 613)

returns if the current user can delete the menu

boolean curUserCanDelete ([boolean $debug = False])
  • boolean $debug
curUserCanEdit (line 628)

returns if the current user can edit the menu

  • since: pk-06-11-06
boolean curUserCanEdit ([boolean $debug = False])
  • boolean $debug
curUserCanOpen (line 569)

returns if the current user can open the menu

NOTE: does not dates or PGP_SHOW

boolean curUserCanOpen ([boolean $debug = False])
  • boolean $debug
dbInsert (line 256)

inserts a new row to the table

  • return: returns the autoIncFld ID if exists or 1 on success
  • access: public
int dbInsert ([boolean $debug = False])
  • boolean $debug: show debug info

Redefinition of:
DBMS_TABLEOBJ::dbInsert()
inserts a new row to the table
getAllChildProducts (line 401)

returns an array of all products in the product group and all child groups

NOTE: this method uses the T_PRO_PRODGROUP table take care this table is up to date

  • return: of
  • access: public
array getAllChildProducts ([boolean $debug = False])
  • boolean $debug
getChildren (line 346)

returns an array with the children

  • access: public
array getChildren ([boolean $debug = False])
  • boolean $debug
getId (line 170)

returns the pro group id

  • access: public
int getId ()
getOrderNr (line 210)

returns the sort order number

  • access: public
int getOrderNr ()
getParentId (line 190)

returns the parent Id

  • access: public
int getParentId ()
getProduct (line 434)

returns a product

  • access: public
PRO_PRODUCT &getProduct (int $aProId, [boolean $debug = False])
  • int $aProId
  • boolean $debug
getProductList (line 475)

returns an array with all products in the group

  • access: public
array getProductList ([boolean $debug = False])
  • boolean $debug
getRootPath (line 274)
  • access: public
void getRootPath ([ $debug = False])
  • $debug
getTitle (line 234)

returns the title if set otherwise the name

  • access: public
string getTitle ([int $langId = 0], [boolean $debug = False])
  • int $langId
  • boolean $debug
hasChildren (line 293)

returns if the product group has children

  • access: public
boolean hasChildren ([boolean $debug = False])
  • boolean $debug
isOnline (line 506)

returns if a product is online or not

  • access: public
void isOnline ([boolean $checkProducts = True], [boolean $checkParts = True], [boolean $debug = False])
  • boolean $checkProducts: (check if we have an online part)
  • boolean $checkParts: (force to check product parts)
  • boolean $debug
populateChildren (line 309)

populates $this->myChildren

  • access: protected
void populateChildren ([boolean $debug = False])
  • boolean $debug
populateProducts (line 367)

populates the products and sets $this->productPopulateTS

  • access: public
void populateProducts ([boolean $debug = False])
  • boolean $debug
setId (line 180)

sets the product group id

  • access: public
void setId (int $aId)
  • int $aId
setOrderNr (line 220)

sets the order number

  • access: public
void setOrderNr (int $aNbr)
  • int $aNbr
setParentId (line 200)

sets the parent Id

  • access: public
void setParentId (int $aId)
  • int $aId

Inherited Methods

Inherited From DBMS_TABLEOBJ

 DBMS_TABLEOBJ::DBMS_TABLEOBJ()
 DBMS_TABLEOBJ::cacheRestore()
 DBMS_TABLEOBJ::cacheWriteTo()
 DBMS_TABLEOBJ::clearErrors()
 DBMS_TABLEOBJ::dbDelete()
 DBMS_TABLEOBJ::dbGetDataArray()
 DBMS_TABLEOBJ::dbGetForm()
 DBMS_TABLEOBJ::dbInsert()
 DBMS_TABLEOBJ::dbPopulate()
 DBMS_TABLEOBJ::dbReplace()
 DBMS_TABLEOBJ::dbSave()
 DBMS_TABLEOBJ::db_SetKey()
 DBMS_TABLEOBJ::db_SetKeyArray()
 DBMS_TABLEOBJ::getClassInclude()
 DBMS_TABLEOBJ::getDbDesc()
 DBMS_TABLEOBJ::getDBField()
 DBMS_TABLEOBJ::getDBRow()
 DBMS_TABLEOBJ::getDBVal()
 DBMS_TABLEOBJ::getDefaults()
 DBMS_TABLEOBJ::getErrorMsg()
 DBMS_TABLEOBJ::getFieldDBDefault()
 DBMS_TABLEOBJ::getForm()
 DBMS_TABLEOBJ::getFormClassName()
 DBMS_TABLEOBJ::getFormName()
 DBMS_TABLEOBJ::getJSON()
 DBMS_TABLEOBJ::getKeyArr()
 DBMS_TABLEOBJ::getMyTable()
 DBMS_TABLEOBJ::getObjValArray()
 DBMS_TABLEOBJ::getObjValValue()
 DBMS_TABLEOBJ::getPopulateTs()
 DBMS_TABLEOBJ::getWhere()
 DBMS_TABLEOBJ::hasChanged()
 DBMS_TABLEOBJ::hasColumn()
 DBMS_TABLEOBJ::hasErrors()
 DBMS_TABLEOBJ::hasObjVals()
 DBMS_TABLEOBJ::init()
 DBMS_TABLEOBJ::isInit()
 DBMS_TABLEOBJ::isPopulated()
 DBMS_TABLEOBJ::keysAreSet()
 DBMS_TABLEOBJ::populateFromKeys()
 DBMS_TABLEOBJ::populateFromValues()
 DBMS_TABLEOBJ::populateObjVals()
 DBMS_TABLEOBJ::p_cacheIsExpired()
 DBMS_TABLEOBJ::saveLinkedRow()
 DBMS_TABLEOBJ::saveLinkedTableRows()
 DBMS_TABLEOBJ::saveObjVals()
 DBMS_TABLEOBJ::setChanged()
 DBMS_TABLEOBJ::setDBField()
 DBMS_TABLEOBJ::setDBFieldIfDiff()
 DBMS_TABLEOBJ::setDBFieldIfEmpty()
 DBMS_TABLEOBJ::setDBRow()
 DBMS_TABLEOBJ::setDBVal()
 DBMS_TABLEOBJ::setDefaults()
 DBMS_TABLEOBJ::setError()
 DBMS_TABLEOBJ::setLinkedTableRow()
 DBMS_TABLEOBJ::setMyTable()
 DBMS_TABLEOBJ::setObjValArray()
 DBMS_TABLEOBJ::setObjValValue()
 DBMS_TABLEOBJ::setObjVarIfEmpty()
 DBMS_TABLEOBJ::setUnChanged()
 DBMS_TABLEOBJ::userIsAllowed()
 DBMS_TABLEOBJ::writeDebugInfo()
 DBMS_TABLEOBJ::xmladdDOMElement()
 DBMS_TABLEOBJ::xmlExport()
 DBMS_TABLEOBJ::_getCacheFileName()
 DBMS_TABLEOBJ::_getDBFields()

Inherited From OCSP_OBJ

 OCSP_OBJ::castObj()
 OCSP_OBJ::cloneMe()
 OCSP_OBJ::currentUser()
 OCSP_OBJ::dbConnect()
 OCSP_OBJ::defaultDBObj()
 OCSP_OBJ::defaultReadDBObj()
 OCSP_OBJ::defaultWriteDBObj()
 OCSP_OBJ::getConf()
 OCSP_OBJ::getDBObj()
 OCSP_OBJ::get_myClassConstant()
 OCSP_OBJ::get_myObject_vars()
 OCSP_OBJ::get_mySourceFile()
 OCSP_OBJ::isConnected()
 OCSP_OBJ::isMultiByteStr()
 OCSP_OBJ::isUTF8()
 OCSP_OBJ::setConf()
 OCSP_OBJ::setDBObj()
 OCSP_OBJ::set_myObject_vars()
 OCSP_OBJ::set_myVarsFrom()
Class Constants
CLASS_SRC_FILE = __FILE__ (line 45)

Inherited Constants

Inherited from DBMS_TABLEOBJ

DBMS_TABLEOBJ::CLASS_SRC_FILE

Inherited from OCSP_OBJ

OCSP_OBJ::CLASS_SRC_FILE

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