Platform
3.1
PHP API documentation
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Pages
editwdoc.php
Go to the documentation of this file.
1
<?php
2
/*
3
* @author Anakeen
4
* @license http://creativecommons.org/licenses/by-nc-sa/2.0/fr/ Anakeen - licence CC
5
* @package FDL
6
*/
7
/**
8
* Generated Header (not documented yet)
9
*
10
* @author Anakeen 2000
11
* @version $Id: editwdoc.php,v 1.4 2005/06/28 08:37:46 eric Exp $
12
* @license http://creativecommons.org/licenses/by-nc-sa/2.0/fr/ Anakeen - licence CC
13
* @package FDL
14
* @subpackage GED
15
*/
16
/**
17
*/
18
// ---------------------------------------------------------------
19
// $Id: editwdoc.php,v 1.4 2005/06/28 08:37:46 eric Exp $
20
// $Source: /home/cvsroot/anakeen/freedom/freedom/Action/Freedom/editwdoc.php,v $
21
// ---------------------------------------------------------------
22
include_once (
"FDL/Lib.Dir.php"
);
23
24
function
editwdoc
(&
$action
)
25
{
26
$dbaccess
=
$action
->GetParam(
"FREEDOM_DB"
);
27
$docid
=
GetHttpVars
(
"id"
, 0);
28
$current = (
GetHttpVars
(
"current"
,
"N"
) ==
"Y"
);
29
30
$action
->lay->Set(
"docid"
,
$docid
);
31
32
$doc
=
new_Doc
(
$dbaccess
,
$docid
);
33
34
$action
->lay->Set(
"doctitle"
,
$doc
->title);
35
$sqlfilters = array();
36
37
$wid =
$doc
->wid;
38
39
$chdoc =
$doc
->GetFromDoc();
40
$sqlfilters[] =
"("
.
GetSqlCond
($chdoc,
"wf_famid"
) .
") OR (wf_famid isnull)"
;
41
$tclassdoc =
getChildDoc
(
$dbaccess
, 0,
"0"
,
"ALL"
, $sqlfilters,
$action
->user->id,
"TABLE"
,
"WDOC"
);
42
43
$selectclass = array();
44
if
(is_array($tclassdoc)) {
45
while
(list($k, $pdoc) = each($tclassdoc)) {
46
47
$selectclass[$k][
"idpdoc"
] = $pdoc[
"id"
];
48
$selectclass[$k][
"profname"
] = $pdoc[
"title"
];
49
50
$selectclass[$k][
"selected"
] = ($pdoc[
"id"
] == $wid) ?
"selected"
:
""
;
51
}
52
}
53
54
$action
->lay->SetBlockData(
"SELECTFLD"
, $selectclass);
55
}
56
?>
← centre documentaire
© anakeen
- published under
CC License
-
Dynacase