22 include_once (
"FDL/Class.Doc.php");
23 include_once (
"FDL/Class.DocAttr.php");
25 include_once (
"FDL/freedom_util.php");
38 if ($ulink ==
"N") $ulink =
false;
42 $action->lay->Set(
"cursor", $ulink ?
"crosshair" :
"inherit");
45 if (($vid !=
"") && (
$doc->cvid > 0)) {
48 $tview = $cvdoc->getView($vid);
50 $doc->setMask($tview[
"CV_MSKID"]);
53 $listattr =
$doc->GetNormalAttributes();
55 $foa =
$doc->getAttribute($frameid);
56 if (!$foa)
$action->exitError(sprintf(
"attribute %s not found") , $frameid);
57 if ($foa->getOption(
"vlabel") ==
"none")
$action->lay->set(
"flabel",
'');
61 foreach ($listattr as $k => $v) {
63 if ($v->fieldSet->id != $frameid)
continue;
67 $goodvalue = (((
$value !=
"") || ($v->type ==
"array") || $v->getOption(
"showempty")) && ($v->mvisibility !=
"H") && ($v->mvisibility !=
"O") && (!$v->inArray()));
69 if ((
$value ==
"") && ($v->type !=
"array")) $htmlvalue = $v->getOption(
"showempty");
71 }
else $htmlvalue =
"";
72 if ($htmlvalue ==
"")
continue;
73 if ($v->mvisibility ==
"O")
continue;
74 if ($v->inArray())
continue;
77 if (($v->mvisibility !=
"H") && ($v->mvisibility !=
"I")) {
79 if ((!$abstract) || ($v->isInAbstract)) {
80 $tval[$k][
"nonelabel"] =
false;
81 $tval[$k][
"normallabel"] =
true;
82 $tval[$k][
"uplabel"] =
false;
83 $tval[$k][
"wvalue"] = ($v->type ==
"array") ?
"1%" :
"30%";
84 $tval[$k][
"ndisplay"] =
"inline";
85 if ($v->getOption(
"vlabel") ==
"none") {
86 $tval[$k][
"nonelabel"] =
true;
87 $tval[$k][
"normallabel"] =
false;
88 }
else if ($v->getOption(
"vlabel") ==
"up") {
89 $tval[$k][
"normallabel"] =
false;
90 $tval[$k][
"uplabel"] =
true;
92 $tval[$k][
"alabel"] = $v->getLabel();;
93 $tval[$k][
"avalue"] = $htmlvalue;
98 if (count($tval) > 0) {
100 $action->lay->setBlockData(
"FIELDSET", array(
105 $action->lay->setBlockData(
"FVALUES", $tval);