Core  3.2
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
Dir Class Reference
+ Inheritance diagram for Dir:
+ Collaboration diagram for Dir:

Public Member Functions

 __construct ($dbaccess= '', $id= '', $res= '', $dbid=0)
 
 GetHome ($create=true)
 
 Clear ()
 
 preInsertDocument ($docid, $multiple=false)
 
 preInsertDoc ($docid, $multiple=false)
 
 postInsertDocument ($docid, $multiple=false)
 
 postInsertDoc ($docid, $multiple=false)
 
 postInsertMultipleDocuments ($tdocid)
 
 preInsertMultipleDocuments ($tdocid)
 
 postMInsertDoc ($tdocid)
 
 preRemoveDocument ($docid, $multiple=false)
 
 postRemoveDocument ($docid, $multiple=false)
 
 preUnlinkDoc ($docid, $multiple=false)
 
 postUnlinkDoc ($docid, $multiple=false)
 
 canModify ()
 
 AddFile ($docid, $mode="latest", $noprepost=false, $forcerestrict=false, $nocontrol=false)
 
 insertDocument ($docid, $mode="latest", $noprepost=false, $forcerestrict=false, $nocontrol=false)
 
 InsertMDoc ($tdocs, $mode="latest", $noprepost=false, &$tinserted=array(), &$twarning=array())
 
 insertMultipleDocuments (array $tdocs, $mode="latest", $noprepost=false, &$tinserted=array(), &$twarning=array(), &$info=array())
 
 QuickInsertMSDocId ($tdocids)
 
 insertFolder ($docid)
 
 getQids ($docid)
 
 DelFile ($docid, $noprepost=false, $nocontrol=false)
 
 removeDocument ($docid, $noprepost=false, $nocontrol=false)
 
 moveDocument ($docid, $movetoid)
 
 postStore ()
 
 postModify ()
 
 hasNoRestriction ()
 
 getAuthorizedFamilies ($classid=0, $verifyCreate=false)
 
 isAuthorized ($classid)
 
 getContent ($controlview=true, array $filter=array(), $famid="", $qtype="TABLE", $trash="")
 
 updateFldRelations ()
 
 count ($onlyprimary=false)
 
 getContentInitid ()
 
 getPrimaryChild ()
 
 deleteItems ()
 
 copyItems ($indirid)
 
 deleteRecursive ()
 
 reviveItems ()
 
- Public Member Functions inherited from PDir
 __construct ($dbaccess= '', $id= '', $res= '', $dbid=0)
 
- Public Member Functions inherited from DocCollection
 getOperatorLabel ($operator, $attributeType)
 
 getContent ($controlview=true, array $filter=array(), $famid="", $qtype="TABLE", $trash="")
 
 object2SqlFilter ($of, &$famid, &$fsql)
 
 getSpecificFilters ()
 
 hasSpecificFilters ()
 
 getDocumentList ()
 
- Public Member Functions inherited from Doc
 __toString ()
 
 postInsert ()
 
 setChanged ()
 
 isChanged ()
 
 PreInsert ()
 
 preUpdate ()
 
 postUpdate ()
 
 regenerateTemplate ($aid, $index=-1)
 
 regenerateTemplates ()
 
 updateRelations ($force=false)
 
 getCurSequence ()
 
 nextSequence ($fromid=0)
 
 disableEditControl ()
 
 enableEditControl ()
 
 isRevisable ()
 
 transfertValuesFrom (&$from)
 
 convert ($fromid, $prevalues=array())
 
 canUpdateDoc ()
 
 save (&$info=null, $skipConstraint=false)
 
 store (&$info=null, $skipConstraint=false)
 
 canEdit ($verifyDomain=true)
 
 CanLockFile ()
 
 canLock ()
 
 canUnLock ()
 
 CanUnLockFile ()
 
 isLocked ($my=false)
 
 isConfidential ()
 
 getFamDoc ()
 
 getFamilyDocument ()
 
 getFreedomFromTitle ($title)
 
 getParamValue ($idp, $def="")
 
 getFamilyParameterValue ($idp, $def="")
 
 getDocWithSameTitle ($key1="title", $key2="")
 
 getRevisionState ($state, $fixed=false)
 
 deleteTemporary ()
 
 PreDocDelete ()
 
 ReallyDelete ($nopost)
 
 delete ($really=false, $control=true, $nopost=false)
 
 revive ()
 
 undelete ()
 
 affect ($array, $more=false, $reset=true)
 
 complete ()
 
 init ()
 
 description ()
 
 getFathersDoc ()
 
 getFromDoc ()
 
 getChildFam ($id=-1, $controlcreate=false)
 
 getRevisions ($type="LIST", $limit=200)
 
 latestId ($fixed=false, $forcequery=false)
 
 getLatestId ($fixed=false, $forcequery=false)
 
 getVersion ()
 
 getLabel ($idAttr)
 
 getProperty ($prop)
 
 getPropertyValue ($prop)
 
tag ()
 
getAttribute ($idAttr, &$oa=null, $useMask=true)
 
getAttributes ($useMask=true)
 
 setMask ($mid)
 
 getNormalAttributes ($onlyopt=false)
 
 getFieldAttributes ()
 
 getActionAttributes ()
 
 getAbstractAttributes ()
 
 getTitleAttributes ()
 
 getProfilAttributes ()
 
 getInputAttributes ($onlyopt=false)
 
 getParamAttributes ()
 
 getFileAttributes ($onlyfile=false)
 
 getFilesProperties ()
 
 hasWaitingFiles ()
 
 resetConvertVaultFile ($attrid, $index)
 
 convertVaultFile ($va, $engine, $isimage=false)
 
 getMenuAttributes ($viewhidden=false)
 
 getNeededAttributes ($parameters=false)
 
 isCompleteNeeded ()
 
 equal ($a, $b)
 
 getExportAttributes ($withfile=false, $forcedefault=false)
 
 getImportAttributes ()
 
 getSortAttributes ()
 
 refreshTitle ()
 
 postConstructor ()
 
 postModify ()
 
 postStore ()
 
 preStore ()
 
 preEdition ()
 
 preConsultation ()
 
 postCreated ()
 
 preCreated ()
 
 preImport (array $extra=array())
 
 postImport (array $extra=array())
 
 preRevise ()
 
 postRevise ()
 
 preUndelete ()
 
 postUndelete ()
 
 preRevive ()
 
 postRevive ()
 
 setTitle ($title)
 
 getValues ()
 
 getRawValue ($idAttr, $def="")
 
 setAttributeValue ($idAttr, $value)
 
 getValue ($idAttr, $def="")
 
 getTValue ($idAttr, $def="", $index=-1)
 
 getMultipleRawValues ($idAttr, $def="", $index=-1)
 
 getAValues ($idAttr, $index=-1)
 
 getArrayRawValues ($idAttr, $index=-1)
 
 removeArrayRow ($idAttr, $index)
 
 completeArrayRow ($idAttr, $deleteLastEmptyRows=true)
 
 addArrayRow ($idAttr, $tv, $index=-1)
 
 clearArrayValues ($idAttr)
 
 deleteArray ($idAttr)
 
 setValue ($attrid, $value, $index=-1, &$kvalue=null)
 
 recomputeTextFiles ($aid= '')
 
 setTextValueInFile ($attrid, $value, $ftitle="")
 
 getTextValueFromFile ($attrid, &$text)
 
 copyFile ($idattr, $newname="", $index=-1)
 
 renameFile ($idattr, $newname, $index=-1)
 
 vaultRegisterFile ($filename, $ftitle="", &$info=null)
 
 setFile ($attrid, $filename, $ftitle="", $index=-1)
 
 storeFile ($attrid, $filename, $ftitle="", $index=-1)
 
 storeFiles ($attrid, $filenames, $ftitle="")
 
 duplicateFiles ()
 
 getRValue ($RidAttr, $def="", $latest=true, $html=false)
 
 getOldValue ($attrid)
 
 getOldRawValue ($attrid)
 
 getOldValues ()
 
 getOldRawValues ()
 
 clearValue ($attrid)
 
 deleteValue ($attrid)
 
 getValueMethod ($value)
 
 applyMethod ($method, $def="", $index=-1, array $bargs=array(), array $mapArgs=array(), &$err= '')
 
 verifyConstraint ($attrid, $index=-1)
 
 verifyAllConstraints ($stoptofirst=true, &$info=array())
 
 getFirstFileAttributes ()
 
 addHistoryEntry ($comment= '', $level=DocHisto::INFO, $code= '', $uid= '')
 
 addComment ($comment= '', $level=DocHisto::INFO, $code= '', $uid= '')
 
 addLog ($code= '', $arg= '', $comment= '', $level= '', $uid= '')
 
 getHisto ($allrev=false, $code="", $limit=0)
 
 addATag ($tag)
 
 getATag ($tag)
 
 delATag ($tag)
 
 addUTag ($uid, $tag, $datas="", $allrevision=true)
 
 hasUTag ($tag, $allrevision=true)
 
 getUTag ($tag, $allrevision=true, $uid=null)
 
 delUTag ($uid, $tag, $allrevision=true)
 
 delUTags ($uid=0)
 
 refreshUTags ()
 
 searchUTags ($tag="", $allrevision=true, $allusers=false)
 
 setWaskAnswer ($waskid, $answer)
 
 askIsCompleted ()
 
 getLatestIdWithAsk ()
 
 isFixed ()
 
 addRevision ($comment= '')
 
 changeFreeState ($newstateid, $comment= '', $revision=true)
 
 setState ($newstate, $comment= '', $force=false, $withcontrol=true, $wm1=true, $wm2=true, $wneed=true, $wm0=true, $wm3=true, &$msg= '')
 
 getState ()
 
 getStateColor ($def="")
 
 getStateActivity ($def="")
 
 getStatelabel ()
 
 copy ($temporary=false, $control=true, $linkfld=false, $copyfile=false)
 
 duplicate ($temporary=false, $control=true, $linkfld=false, $copyfile=false)
 
 preDuplicate (&$copyfrom)
 
 preCopy (&$copyfrom)
 
 postDuplicate (&$copyfrom)
 
 postCopy (&$copyfrom)
 
 translate ($docid, $translate)
 
 archive (&$archive)
 
 unArchive (&$archive)
 
 lock ($auto=false, $userid=0)
 
 unLock ($auto=false, $force=false)
 
 allocate ($userid, $comment="", $revision=false, $autolock=true)
 
 unallocate ($comment="", $revision=true)
 
 getIcon ($idicon="", $size=null, $otherId=null)
 
 changeIcon ($icon)
 
 addParamRefresh ($in, $out)
 
 getRefreshVisibility ()
 
 preRefresh ()
 
 specRefresh ()
 
 postRefresh ()
 
 specRefreshGen ($onlyspec=false)
 
 refresh ()
 
 refreshRn ()
 
 urlWhatEncode ($link, $k=-1)
 
 urlWhatEncodeSpec ($l)
 
 getRssLink ()
 
 getFileLink ($attrid, $index=-1, $cache=false, $inline=false, $otherValue= '', $info=null)
 
 getDocAnchor ($id, $target="_self", $htmllink=true, $title=false, $js=true, $docrev="latest", $viewIcon=false)
 
 getHtmlValue ($oattr, $value, $target="_self", $htmllink=true, $index=-1, $entities=true, $abstract=false)
 
 getHtmlAttrValue ($attrid, $target="_self", $htmllink=2, $index=-1, $entities=true, $abstract=false)
 
 getTextualAttrValue ($attrId, $index=-1, Array $configuration=array())
 
 getOooAttrValue ($attrid, $target="_self", $htmllink=false, $index=-1)
 
 getOooValue ($oattr, $value, $target="_self", $htmllink=false, $index=-1)
 
 control ($aclname, $strict=false)
 
 hasPermission ($aclName, $strict=false)
 
 controlUser ($uid, $aclname)
 
 isAlive ()
 
 sqlTrigger ($onlydrop=false, $code=false)
 
 getSqlIndex ()
 
 getZoneFile ($zone)
 
 getZoneOption ($zone="")
 
 getZoneTransform ($zone="")
 
 setDefaultValues ($tdefval, $method=true, $forcedefault=false)
 
 setNameAuto ($temporary=false)
 
 getMainPath ()
 
 viewDoc ($layout="FDL:VIEWBODYCARD", $target="_self", $ulink=true, $abstract=false, $changelayout=false)
 
 viewdefaultcard ($target="_self", $ulink=true, $abstract=false, $viewhidden=false)
 
 viewthumbcard ($target="finfo", $ulink=true, $abstract=true)
 
 viewproperties ($target="finfo", $ulink=true, $abstract=true)
 
 viewabstractcard ($target="finfo", $ulink=true, $abstract=false)
 
 viewattr ($target="_self", $ulink=true, $abstract=false, $viewhidden=false)
 
 viewprop ($target="_self", $ulink=true, $abstract=false)
 
 setLogicalIdentificator ($name, $reset=false)
 
 setLogicalName ($name, $reset=false, $verifyOnly=false)
 
 viewoptcard ($target="_self", $ulink=true, $abstract=false)
 
 editoptcard ($target="_self", $ulink=true, $abstract=false)
 
 editbodycard ($target="_self", $ulink=true, $abstract=false, $onlyopt=false)
 
 editattr ($withtd=true)
 
 setFamidInLayout ()
 
 vault_filename ($attrid, $path=false, $index=-1)
 
 vault_filename_fromvalue ($fileid, $path=false)
 
 vault_properties (NormalAttribute $attr)
 
 getFileInfo ($filesvalue, $key="", $returnType="array")
 
 exportXml (&$xml, $withfile=false, $outfile="", $wident=true, $flat=false, $exportAttributes=array())
 
 toxml ($withdtd=false, $id_doc="")
 
 todtd ()
 
 getCustomTitle ()
 
 getSpecTitle ()
 
 refreshDocTitle ($nameId, $nameTitle)
 
 getEmblem ($size=null)
 
 nothing ($a="", $b="", $c="")
 
 getParam ($param, $defv="")
 
 getLastTitle ($id="-1", $def="")
 
 getTitle ($id="-1", $def="", $latest=false)
 
 getHTMLTitle ($id="-1", $def="", $latest=false)
 
 getDocValue ($docid, $attrid, $def=" ", $latest=false)
 
 getDocProp ($docid, $propid, $latest=false)
 
 getMyAttribute ($idattr)
 
 formatString ($fmt)
 
 updateVaultIndex ()
 
 attachTimer (&$timer, $origin=null, $execdate=null)
 
 unattachTimer (&$timer)
 
 getAttachedTimers ()
 
 getDomainIds ($user=true, $folderName=false)
 
 lockToDomain ($domainId, $userid=0)
 
 getParentFolderIds ()
 
 updateDomains ()
 
 isInDomain ($user=true, $userId= '')
 
 getHelpPage ($fromid="")
 
 getSearchMethods ($attrId, $attrType= '')
 
 isValidSearchMethod ($className, $methodName)
 
 resolveDocIdLogicalNames (NormalAttribute &$oattr, $avalue, &$unknownLogicalNames=array(), &$knownLogicalNames=array())
 
- Public Member Functions inherited from DocCtrl
 __construct ($dbaccess= '', $id= '', $res= '', $dbid=0)
 
 isControlled ()
 
 unsetControl ()
 
 removeControl ($userid=-1)
 
 setControl ($userctrl=true)
 
 setProfil ($profid, $fromdocidvalues=null)
 
 computeDProfil ($dprofid=0, $fromdocidvalues=null)
 
 setViewProfil ()
 
 isRealProfile ()
 
 modifyControl ($uid, $aclname, $deletecontrol=false)
 
 addControl ($uid, $aclname)
 
 isExtendedAcl ($aclname)
 
 delControl ($uid, $aclname)
 
 setCvid ($cvid)
 
 controlId ($docid, $aclname, $strict=false)
 
 controlExtId ($docid, $aclname, $strict=false)
 
 controlUserId ($docid, $uid, $aclname)
 
 controlUp ($uperm, $aclname)
 
 getUsersForAcl ($aclname)
 
 recomputeProfiledDocument ()
 
 isDocLinked ($title, $docid)
 
 isValidLink ($title, $docid)
 
 canEditMenu ()
 
 controlAclAccess ($acl)
 
 controlActifProfil ()
 
 profilIsActivate ($yes=true)
 
- Public Member Functions inherited from DocLDAP
 OrgInit ()
 
 UseLdap ()
 
 SetLdapParam ()
 
 getDNs ()
 
 setDNs ($ds, $tdn)
 
 canUpdateLdapCard ()
 
 RefreshLdapCard ()
 
 DeleteLdapCard ()
 
 getLDAPDN ($rdn, $path="")
 
 getMapAttributes ()
 
 ConvertToLdap ()
 
 getLDAPValue ($idattr, $index="")
 
 ModifyLdapCard ($tinfoldap)
 
 createLDAPDc ($ds, $n)
 
- Public Member Functions inherited from DbObj
 __construct ($dbaccess= '', $id= '', $res= '', $dbid=0)
 
 Select ($id)
 
 getValues ()
 
 affectColumn ($fields, $reset=true)
 
 affect ($array, $more=false, $reset=true)
 
 isAffected ()
 
 Complete ()
 
 preInsert ()
 
 postInsert ()
 
 preUpdate ()
 
 postUpdate ()
 
 preDelete ()
 
 postDelete ()
 
 preSelect ($id)
 
 postSelect ($id)
 
 Add ($nopost=false, $nopre=false)
 
 modify ($nopost=false, $sfields="", $nopre=false)
 
 delete ($nopost=false)
 
 Adds (&$tcopy, $nopost=false)
 
 lw ($prop)
 
 CloseConnect ()
 
 Create ($nopost=false)
 
 postInit ()
 
 init_dbid ()
 
 exec_query ($sql, $lvl=0, $prepare=false)
 
 numrows ()
 
 fetch_array ($c, $type=PGSQL_ASSOC)
 
 update ()
 
 setError ($moreerr= '')
 
 autoUpdate ()
 
 savePoint ($point)
 
 lockPoint ($exclusiveLock, $exclusiveLockPrefix= '')
 
 setMasterLock ($useLock)
 
 rollbackPoint ($point)
 
 commitPoint ($point)
 

Data Fields

 $defDoctype = 'D'
 
 $eviews
 
- Data Fields inherited from PDir
 $acls
 
 $defDoctype = 'P'
 
 $defProfFamId = FAM_ACCESSDIR
 
- Data Fields inherited from DocCollection
 $top
 
- Data Fields inherited from Doc
const USEMASKCVVIEW = - 1
 
const USEMASKCVEDIT = - 2
 
 $fields
 
 $sup_fields
 
 $id
 
 $owner
 
 $title
 
 $revision
 
 $version
 
 $initid
 
 $fromid
 
 $lockdomainid
 
 $domainid
 
 $doctype
 
 $locked
 
 $icon
 
 $lmodify
 
 $profid
 
 $views
 
 $usefor
 
 $revdate
 
 $cdate
 
 $adate
 
 $comment
 
 $classname
 
 $state
 
 $wid
 
 $cvid
 
 $name
 
 $mid = 0
 
 $dprofid = 0
 
 $prelid = 0
 
 $atags
 
 $postitid
 
 $confidential
 
 $ldapdn
 
 $allocated
 
 $archiveid
 
 $fromname
 
 $fromtitle
 
 $fulltext
 
 $cviews
 
 $eviews
 
 $wdoc = null
 
 $attributes = null
 
 $id_fields
 
 $dbtable = "doc"
 
 $order_by = "title, revision desc"
 
 $fulltextfields
 
 $acls = array()
 
 $lay = null
 
 $defProfFamId = FAM_ACCESSDOC
 
 $sqlcreate
 
 $obj_acl = array()
 
 $defaultview = "FDL:VIEWBODYCARD"
 
 $defaultedit = "FDL:EDITBODYCARD"
 
 $defaultabstract = "FDL:VIEWABSTRACTCARD"
 
 $defaultcreate = ""
 
 $defaultmview = ""
 
 $specialmenu = array()
 
 $defDoctype = 'F'
 
 $paramRefresh = array()
 
- Data Fields inherited from DocCtrl
 $title = ''
 
 $dacls
 
 $extendedAcls = array()
 
 $profid
 
 $dprofid
 
 $views
 
 $attributes = null
 
 $doctype
 
 $id
 
 $initid
 
 $uperm
 
 $cvid
 
 $userid
 
- Data Fields inherited from DocLDAP
 $serveur
 
 $port
 
 $racine
 
 $rootdn
 
 $rootpw
 
 $useldap = false
 
 $infoldap = array()
 
 $cindex = false
 
 $ldapmap
 
 $ldapdn
 
- Data Fields inherited from DbObj
 $dbid = - 1
 
 $dbaccess = ''
 
 $fields
 
 $dbtable = ''
 
 $id_fields
 
 $criterias = array()
 
 $sup_fields = array()
 
 $sup_where = array()
 
 $sup_tables = array()
 
 $fulltextfields = array()
 
 $order_by = ""
 
 $isset = false
 
 $msg_err = ''
 
 $err_code = ''
 
 $res = ''
 
 $debug = false
 
 $sqlcreate
 
 $sqlinit
 
 $log
 

Protected Member Functions

 postAffect (array $data, $more, $reset)
 
- Protected Member Functions inherited from Doc
 getParameterFamilyRawValue ($idp, $def)
 
 preAffect (array &$data, &$more, &$reset)
 
 postAffect (array $data, $more, $reset)
 
 specRefreshGenAttribute ($attrId, $callMethod)
 
 noPrivilegeMessage (Doc &$doc, $aclname)
 
 getCustomSearchValues ()
 
- Protected Member Functions inherited from DbObj
 tryCreate ()
 

Additional Inherited Members

- Static Public Member Functions inherited from Doc
static seemsMethod ($method)
 
static rawValueToArray ($v)
 
static _val2array ($v)
 
static arrayToRawValue ($v, $br= '< BR >')
 
static _array2val ($v, $br= '< BR >')
 
static _cmpanswers ($a, $b)
 
static htmlEncode ($s)
 
static getDate ($daydelta=0, $dayhour="", $daymin="", $getlocale=false)
 
static getTimeDate ($hourdelta=0, $second=false)
 
static getUserName ($withfirst=false)
 
static userDocId ()
 
static getUserId ()
 
static getWhatUserId ()
 
static getSystemUserId ()
 
static parseZone ($zone)
 
- Static Public Member Functions inherited from DocCtrl
static parseMail ($Email)
 
static isFutureDate ($date)
 
static isFloat ($x, $min=null, $max=null)
 
static isInteger ($x, $min=null, $max=null)
 
static isString ($x, $p)
 
static canExecute ($appname, $actname)
 
- Static Public Attributes inherited from Doc
static $infofields
 
static $sqlindex
 
- Static Public Attributes inherited from DbObj
static $savepoint = array()
 
static $lockpoint = array()
 
static $sqlStrict = null
 
- Protected Attributes inherited from Doc
 $svalues
 
 $values
 
 $attrids
 

Detailed Description

Folder document Class

Definition at line 22 of file Class.Dir.php.

Constructor & Destructor Documentation

__construct (   $dbaccess = '',
  $id = '',
  $res = '',
  $dbid = 0 
)

Definition at line 33 of file Class.Dir.php.

Member Function Documentation

AddFile (   $docid,
  $mode = "latest",
  $noprepost = false,
  $forcerestrict = false,
  $nocontrol = false 
)

add a document reference in this folder

if mode is latest the user always see latest revision if mode is static the user see the revision which has been inserted

Deprecated:
use Dir::insertDocument instead
See Also
Dir::insertDocument
Parameters
int$dociddocument ident for the insertion
string$modelatest|static
bool$noprepostif true if the virtuals methods Dir::preInsertDoc() and Dir::postInsertDoc() are not called
bool$forcerestrictif true don't test restriction (if have)
bool$nocontrolif true no test acl "modify"
Returns
string error message, if no error empty string

Definition at line 295 of file Class.Dir.php.

+ Here is the call graph for this function:

canModify ( )

Test if current user can add or delete document in this folder

Returns
string error message, if no error empty string

Definition at line 272 of file Class.Dir.php.

+ Here is the call graph for this function:

Clear ( )

clear containt of this folder

Returns
string error message, if no error empty string

Definition at line 108 of file Class.Dir.php.

+ Here is the call graph for this function:

copyItems (   $indirid)

copy (clone) all documents which primary relation is the folder (recurively) the others documents are just linked all document are put in $indirid folder id

Parameters
int$indiridthe folder where put the copies
Returns
array of possible errors. Empty array means no errors

Definition at line 991 of file Class.Dir.php.

+ Here is the call graph for this function:

count (   $onlyprimary = false)

return number of item in the static folder

Parameters
bool$onlyprimaryset to true if you wnat only document linked by primary relation
Returns
int -1 if it is not a static folder

Definition at line 916 of file Class.Dir.php.

+ Here is the call graph for this function:

deleteItems ( )

delete all document which primary relation is the folder (recurively) different of Dir::Clear() all document are put in the trash (zombie mode)

Returns
array of possible errors. Empty array means no errors

Definition at line 964 of file Class.Dir.php.

+ Here is the call graph for this function:

deleteRecursive ( )

delete the folder and its containt different of Dir::Clear() all document are put in the trash (zombie mode)

Returns
string error message, if no error empty string

Definition at line 1028 of file Class.Dir.php.

+ Here is the call graph for this function:

DelFile (   $docid,
  $noprepost = false,
  $nocontrol = false 
)

remove a document reference from this folder

Deprecated:
use Dir::removeDocument instead
See Also
Dir::removeDocument
Parameters
int$dociddocument ident for the deletion
bool$noprepostif true then the virtuals methods Dir::preUnlinkDoc() and Dir::postUnlinkDoc() are not called
bool$nocontrolif true no test acl "modify"
Returns
string error message, if no error empty string

Definition at line 658 of file Class.Dir.php.

+ Here is the call graph for this function:

getAuthorizedFamilies (   $classid = 0,
  $verifyCreate = false 
)

return families that can be use in insertion

Parameters
int$classid: restrict for same usefor families
bool$verifyCreateset to true if you want to get only families the user can create (icreate acl)
Returns
array

Definition at line 815 of file Class.Dir.php.

+ Here is the call graph for this function:

getContent (   $controlview = true,
array  $filter = array(),
  $famid = "",
  $qtype = "TABLE",
  $trash = "" 
)

return document includes in folder

Parameters
bool$controlviewif false all document are returned else only visible for current user document are return
array$filterto add list sql filter for selected document
int | string$famidfamily identifier to restrict search
string$qtypetype os result TABLE|LIST|ITEM
string$trash
Returns
array array of document array

Definition at line 895 of file Class.Dir.php.

+ Here is the call graph for this function:

getContentInitid ( )

return array of document identificators included in folder

Returns
array of initial identificators (initid)

Definition at line 932 of file Class.Dir.php.

+ Here is the call graph for this function:

GetHome (   $create = true)

get the home and basket folder

Parameters
bool$createset to false to disable auto creation
Returns
bool| false if the dir does not exists and $create is false, home document either

Definition at line 43 of file Class.Dir.php.

+ Here is the call graph for this function:

getPrimaryChild ( )

get document which primary relation is this folder

Returns
array of doc (array document)

Definition at line 947 of file Class.Dir.php.

+ Here is the call graph for this function:

getQids (   $docid)

Definition at line 624 of file Class.Dir.php.

+ Here is the call graph for this function:

hasNoRestriction ( )

Definition at line 802 of file Class.Dir.php.

+ Here is the call graph for this function:

insertDocument (   $docid,
  $mode = "latest",
  $noprepost = false,
  $forcerestrict = false,
  $nocontrol = false 
)

add a document reference in this folder

if mode is latest the user always see latest revision if mode is static the user see the revision which has been inserted

Api:
add a document reference in this folder
Parameters
int$dociddocument ident for the insertion
string$modelatest|static
bool$noprepostif true if the virtuals methods Dir::preInsertDoc() and Dir::postInsertDoc() are not called
bool$forcerestrictif true don't test restriction (if have)
bool$nocontrolif true no test acl "modify"
Returns
string error message, if no error empty string

Definition at line 315 of file Class.Dir.php.

+ Here is the call graph for this function:

insertFolder (   $docid)

insert all static document which are included in $docid in this folder be carreful : not verify restriction folders to be use when many include (verification constraint must ne set before by caller)

Parameters
int$docididentifier document for the insertion (must be initial id)
Returns
string error message, if no error empty string

Definition at line 610 of file Class.Dir.php.

+ Here is the call graph for this function:

InsertMDoc (   $tdocs,
  $mode = "latest",
  $noprepost = false,
$tinserted = array(),
$twarning = array() 
)

insert multiple document reference in this folder

if mode is latest the user always see latest revision if mode is static the user see the revision which has been inserted

Deprecated:
use Dir::InsertMultipleDocuments instead
See Also
insertMultipleDocuments::InsertMultipleDocuments
Parameters
$tdocs
string$modelatest|static
boolean$noprepostnot call preInsert and postInsert method (default if false)
array$tinserted
array$twarning

Definition at line 433 of file Class.Dir.php.

+ Here is the call graph for this function:

insertMultipleDocuments ( array  $tdocs,
  $mode = "latest",
  $noprepost = false,
$tinserted = array(),
$twarning = array(),
$info = array() 
)

insert multiple document reference in this folder

if mode is latest the user always see latest revision if mode is static the user see the revision which has been inserted

Api:
insert multiple document reference in this folder
Parameters
array$tdocsdocuments for the insertion
string$modelatest|static static is not implemented yet
boolean$noprepostnot call preInsert and postInsert method (default if false)
array$tinserted
array$twarning
array$info
Returns
string error message, if no error empty string

Definition at line 454 of file Class.Dir.php.

+ Here is the call graph for this function:

isAuthorized (   $classid)

return families that can be use in insertion

Parameters
int$classid: restrict for same usefor families
Returns
bool

Definition at line 874 of file Class.Dir.php.

+ Here is the call graph for this function:

moveDocument (   $docid,
  $movetoid 
)

move a document from me to a folder

Parameters
integer$docidthe document identifier to move
integer$movetoidtarget destination
Returns
string error message (empty if null)

Definition at line 736 of file Class.Dir.php.

+ Here is the call graph for this function:

postAffect ( array  $data,
  $more,
  $reset 
)
protected

Definition at line 953 of file Class.Dir.php.

postInsertDoc (   $docid,
  $multiple = false 
)

virtual method use after insert document in folder

Deprecated:
hook use Dir::postInsertDocument instead
Parameters
int$dociddocument identifier to insert
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message

Definition at line 167 of file Class.Dir.php.

+ Here is the call graph for this function:

postInsertDocument (   $docid,
  $multiple = false 
)

virtual method use after insert document in folder

Api:
hook method called after insert document in folder
See Also
Dir::insertDocument
Parameters
int$dociddocument identifier to insert
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message

Definition at line 154 of file Class.Dir.php.

postInsertMultipleDocuments (   $tdocid)

hook method use after insert multiple document in this folder must be redefined to optimize algorithm

Api:
hook method called after insert several documents in folder
See Also
Dir::insertMultipleDocuments
Dir::postInsertDocument
Parameters
array$tdocidarray of document identifier to insert
Returns
string warning message

Definition at line 183 of file Class.Dir.php.

postMInsertDoc (   $tdocid)

hook method use after insert multiple document in this folder must be redefined to optimize algorithm

Deprecated:
hook use {::postInsertMultipleDocuments} instead
Parameters
array$tdocidarray of document identifier to insert
Returns
string warning message

Definition at line 211 of file Class.Dir.php.

+ Here is the call graph for this function:

postModify ( )
Deprecated:
use postStore() instead
Returns
string

Definition at line 796 of file Class.Dir.php.

+ Here is the call graph for this function:

postRemoveDocument (   $docid,
  $multiple = false 
)

hook method use after unlink document in folder

Api:
hook method use after remove document of folder
Parameters
int$dociddocument identifier to unlink
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message

Definition at line 237 of file Class.Dir.php.

postStore ( )

Definition at line 780 of file Class.Dir.php.

+ Here is the call graph for this function:

postUnlinkDoc (   $docid,
  $multiple = false 
)

hook method use after unlink document in folder

Deprecated:
hook use Doc::postRemoveDocument instead
Parameters
int$dociddocument identifier to unlink
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message

Definition at line 263 of file Class.Dir.php.

+ Here is the call graph for this function:

preInsertDoc (   $docid,
  $multiple = false 
)

virtual method use before insert document in folder

Deprecated:
hook use Dir::preInsertDocument instead
Parameters
int$dociddocument identifier to insert
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message if not empty the insert will be aborted

Definition at line 142 of file Class.Dir.php.

+ Here is the call graph for this function:

preInsertDocument (   $docid,
  $multiple = false 
)

hook method use before insert document in folder

Api:
hook method use before insert document in folder
Parameters
int$dociddocument identifier to insert
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message if not empty the insertion will be aborted

Definition at line 129 of file Class.Dir.php.

preInsertMultipleDocuments (   $tdocid)

hook method use after insert multiple document in this folder must be redefined to optimize algorithm

Api:
hook method called before insert several documents in folder
See Also
Dir::preInsertDocument
Dir::insertMultipleDocuments
Parameters
array$tdocidarray of document identifier to insert
Returns
string warning message

Definition at line 198 of file Class.Dir.php.

preRemoveDocument (   $docid,
  $multiple = false 
)

hook method use after unlink document in folder

Api:
hook method use before remove document to folder
Parameters
int$dociddocument identifier to unlink
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message if not empty the insert will be aborted

Definition at line 225 of file Class.Dir.php.

preUnlinkDoc (   $docid,
  $multiple = false 
)

hook method use after unlink document in folder

Deprecated:
hook use Doc::preRemoveDocument instead
Parameters
int$dociddocument identifier to unlink
bool$multipleflag to indicate if the insertion is a part of grouped insertion
Returns
string error message if not empty the insert will be aborted

Definition at line 250 of file Class.Dir.php.

+ Here is the call graph for this function:

QuickInsertMSDocId (   $tdocids)

insert multiple static document reference in this folder be carreful : not verify restriction folders to be use when many include (verification constraint must ne set before by caller)

Parameters
array$tdocidsidentifier documents for the insertion
Returns
string error message, if no error empty string

Definition at line 584 of file Class.Dir.php.

+ Here is the call graph for this function:

removeDocument (   $docid,
  $noprepost = false,
  $nocontrol = false 
)

delete a document reference from this folder

Api:
remove a document reference from this folder
Parameters
int$dociddocument ident for the deletion
bool$noprepostif true then the virtuals methods Dir::preRemoveDocument() and Dir::postRemoveDocument() are not called
bool$nocontrolif true no test acl "modify"
Returns
string error message, if no error empty string

Definition at line 673 of file Class.Dir.php.

+ Here is the call graph for this function:

reviveItems ( )

restore all document which primary relation is the folder (recurively)

Returns
array an array of errors

Definition at line 1050 of file Class.Dir.php.

+ Here is the call graph for this function:

updateFldRelations ( )

update folder relations

Definition at line 906 of file Class.Dir.php.

Field Documentation

$defDoctype = 'D'

Definition at line 25 of file Class.Dir.php.

$eviews
Initial value:
= array(
"FDL:EDITBODYCARD",
"FDL:EDITRESTRICTION"
)

Definition at line 29 of file Class.Dir.php.


The documentation for this class was generated from the following file:
← centre documentaire © anakeen