33 if (!method_exists($this,
"addfile"))
return;
41 include_once (
"FDL/Lib.Dir.php");
42 $child =
getChildDir($this->dbaccess, 1, $this->initid,
false,
"TABLE");
43 if (count($child) == 0) {
56 include_once (
"FDL/Lib.Dir.php");
58 $ddocid = $this->
getValue(
"PFL_IDDEF");
61 $ddoc =
new_Doc($this->dbaccess, $ddocid);
62 if ($ddoc->isAffected()) {
63 $child =
getChildDir($this->dbaccess, $this->userid, $ddoc->initid,
false,
"TABLE");
65 foreach ($child as $k =>
$tdoc) {
68 if (!is_object($copy))
$err.= $copy;
69 else $err.= $this->AddFile($copy->id,
"latest",
true,
true);
72 $err = sprintf(_(
"Error in portfolio : folder %s not exists") , $ddocid);
85 include_once (
"FDL/Lib.Dir.php");
90 foreach ($copytab as $k =>
$id) {
95 if (!is_object($copy))
$err.= $copy;
96 else $err.= $this->AddFile($copy->id,
"latest",
true,
true);
105 if (
$doc->doctype ==
"S") {
106 $doc->setValue(
"SE_IDCFLD", $this->initid);
124 foreach (
$tdoc as $k => $v) {
125 if (($v[
"doctype"] ==
"D") || ($v[
"doctype"] ==
"S")) {
127 $todoc = array_merge($todoc,
$dir->getContent($controlview,
$filter));
133 $todoc = array_merge(
$tdoc, $todoc);
135 foreach ($todoc as $k => $v) {
136 $tdoc[$v[
"id"]] = $v;