22 include_once (
"FDL/Class.Doc.php");
23 include_once (
"FDL/Class.Dir.php");
24 include_once (
"FDL/Class.DocAttr.php");
25 include_once (
"FDL/freedom_util.php");
38 if (
$docid == 0)
$action->exitError(_(
"the document is not referenced: cannot apply profile access modification"));
53 if ($profid ==
"private") {
60 if (
$doc->cprofid != $profid) {
61 $doc->AddComment(sprintf(_(
"Change creation profil to %s [%d]") ,
$doc->getTitle($profid) , $profid));
62 $doc->cprofid = $profid;
65 if (
$doc->ccvid != $cvid) {
67 $doc->AddComment(sprintf(_(
"Change creation view control to %s [%d]") ,
$doc->getTitle($cvid) , $cvid));
71 if ((
$doc->profid ==
$doc->id) && ($profid == 0)) {
75 if (
$doc->profid != $profid)
$doc->AddComment(sprintf(_(
"Change profil to %s [%d]") ,
$doc->getTitle($profid) , $profid));
76 if (
$doc->cvid != $cvid)
$doc->AddComment(sprintf(_(
"Change view control to %s [%d]") ,
$doc->getTitle($cvid) , $cvid));
77 $doc->setProfil($profid);
82 $doc->disableEditControl();
91 if ($redirid)
$docid = $redirid;
92 redirect(
$action,
"FDL",
"FDL_CARD&props=Y&id=$docid",
$action->GetParam(
"CORE_STANDURL"));