2012-12-14 07:53:13 +00:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Implementation of AttributeMgr view
|
|
|
|
*
|
|
|
|
* @category DMS
|
2013-02-14 11:10:53 +00:00
|
|
|
* @package SeedDMS
|
2012-12-14 07:53:13 +00:00
|
|
|
* @license GPL 2
|
|
|
|
* @version @version@
|
|
|
|
* @author Uwe Steinmann <uwe@steinmann.cx>
|
|
|
|
* @copyright Copyright (C) 2002-2005 Markus Westphal,
|
|
|
|
* 2006-2008 Malcolm Cowe, 2010 Matteo Lucarelli,
|
|
|
|
* 2010-2012 Uwe Steinmann
|
|
|
|
* @version Release: @package_version@
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Include parent class
|
|
|
|
*/
|
|
|
|
require_once("class.Bootstrap.php");
|
|
|
|
|
2016-04-26 11:43:02 +00:00
|
|
|
/**
|
|
|
|
* Include class to preview documents
|
|
|
|
*/
|
|
|
|
require_once("SeedDMS/Preview.php");
|
|
|
|
|
2012-12-14 07:53:13 +00:00
|
|
|
/**
|
|
|
|
* Class which outputs the html page for AttributeMgr view
|
|
|
|
*
|
|
|
|
* @category DMS
|
2013-02-14 11:10:53 +00:00
|
|
|
* @package SeedDMS
|
2012-12-14 07:53:13 +00:00
|
|
|
* @author Markus Westphal, Malcolm Cowe, Uwe Steinmann <uwe@steinmann.cx>
|
|
|
|
* @copyright Copyright (C) 2002-2005 Markus Westphal,
|
|
|
|
* 2006-2008 Malcolm Cowe, 2010 Matteo Lucarelli,
|
|
|
|
* 2010-2012 Uwe Steinmann
|
|
|
|
* @version Release: @package_version@
|
|
|
|
*/
|
2013-02-14 11:10:53 +00:00
|
|
|
class SeedDMS_View_AttributeMgr extends SeedDMS_Bootstrap_Style {
|
2012-12-14 07:53:13 +00:00
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
function js() { /* {{{ */
|
|
|
|
$selattrdef = $this->params['selattrdef'];
|
2016-02-09 11:36:19 +00:00
|
|
|
header('Content-Type: application/javascript');
|
2016-02-04 18:03:19 +00:00
|
|
|
?>
|
|
|
|
|
|
|
|
$(document).ready( function() {
|
|
|
|
$('body').on('submit', '#form', function(ev){
|
|
|
|
// if(checkForm()) return;
|
2016-03-22 13:47:13 +00:00
|
|
|
// ev.preventDefault();
|
2016-02-04 18:03:19 +00:00
|
|
|
});
|
|
|
|
$( "#selector" ).change(function() {
|
|
|
|
$('div.ajax').trigger('update', {attrdefid: $(this).val()});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
<?php
|
2016-02-09 11:36:19 +00:00
|
|
|
$this->printDeleteFolderButtonJs();
|
|
|
|
$this->printDeleteDocumentButtonJs();
|
2016-02-04 18:03:19 +00:00
|
|
|
} /* }}} */
|
|
|
|
|
|
|
|
function info() { /* {{{ */
|
2012-12-14 07:53:13 +00:00
|
|
|
$dms = $this->params['dms'];
|
|
|
|
$user = $this->params['user'];
|
|
|
|
$attrdefs = $this->params['attrdefs'];
|
2016-02-04 18:03:19 +00:00
|
|
|
$selattrdef = $this->params['selattrdef'];
|
|
|
|
$cachedir = $this->params['cachedir'];
|
|
|
|
$previewwidth = $this->params['previewWidthList'];
|
|
|
|
$enableRecursiveCount = $this->params['enableRecursiveCount'];
|
|
|
|
$maxRecursiveCount = $this->params['maxRecursiveCount'];
|
2016-02-15 09:57:37 +00:00
|
|
|
$timeout = $this->params['timeout'];
|
2012-12-14 07:53:13 +00:00
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
if($selattrdef) {
|
|
|
|
$this->contentHeading(getMLText("attrdef_info"));
|
|
|
|
$res = $selattrdef->getStatistics(30);
|
2016-02-11 16:47:40 +00:00
|
|
|
if(!empty($res['frequencies']['document']) ||!empty($res['frequencies']['folder']) ||!empty($res['frequencies']['content'])) {
|
2017-01-12 16:26:05 +00:00
|
|
|
foreach(array('document', 'folder', 'content') as $type) {
|
|
|
|
$content = '';
|
|
|
|
if(isset($res['frequencies'][$type]) && $res['frequencies'][$type]) {
|
|
|
|
$content .= "<table class=\"table table-condensed\">";
|
|
|
|
$content .= "<thead>\n<tr>\n";
|
|
|
|
$content .= "<th>".getMLText("attribute_value")."</th>\n";
|
|
|
|
$content .= "<th>".getMLText("attribute_count")."</th>\n";
|
|
|
|
$content .= "<th></th>\n";
|
|
|
|
$content .= "</tr></thead>\n<tbody>\n";
|
|
|
|
foreach($res['frequencies'][$type] as $entry) {
|
|
|
|
$value = $selattrdef->parseValue($entry['value']);
|
|
|
|
$content .= "<tr>";
|
2017-07-21 14:54:49 +00:00
|
|
|
$content .= "<td>".implode(';', $value)."</td>";
|
|
|
|
$content .= "<td><a href=\"../out/out.Search.php?resultmode=".($type == 'folder' ? 2 : ($type == 'document' ? 1 : 3))."&attributes[".$selattrdef->getID()."]=".$entry['value']."\">".urlencode($entry['c'])."</a></td>";
|
|
|
|
$content .= "<td>";
|
2017-01-12 16:26:05 +00:00
|
|
|
/* various checks, if the value is valid */
|
2017-01-12 17:03:01 +00:00
|
|
|
if(!$selattrdef->validate($entry['value'])) {
|
2017-07-21 14:54:49 +00:00
|
|
|
$content .= getAttributeValidationText($selattrdef->getValidationError(), $selattrdef->getName(), $entry['value'], $selattrdef->getRegex());
|
2017-01-12 17:03:01 +00:00
|
|
|
}
|
2017-01-12 16:26:05 +00:00
|
|
|
/* Check if value is in value set */
|
2017-07-26 05:50:36 +00:00
|
|
|
/*
|
2017-01-12 16:26:05 +00:00
|
|
|
if($selattrdef->getValueSet()) {
|
2017-05-02 16:31:23 +00:00
|
|
|
foreach($value as $v) {
|
|
|
|
if(!in_array($v, $selattrdef->getValueSetAsArray()))
|
2017-01-12 16:26:05 +00:00
|
|
|
$content .= getMLText("attribute_value_not_in_valueset");
|
|
|
|
}
|
2016-11-14 10:06:38 +00:00
|
|
|
}
|
2017-07-26 05:50:36 +00:00
|
|
|
*/
|
2017-01-12 16:26:05 +00:00
|
|
|
$content .= "</td>";
|
|
|
|
$content .= "</tr>";
|
2016-10-27 05:04:32 +00:00
|
|
|
}
|
2017-01-12 16:26:05 +00:00
|
|
|
$content .= "</tbody></table>";
|
2016-02-04 18:03:19 +00:00
|
|
|
}
|
2017-01-12 16:26:05 +00:00
|
|
|
if($content)
|
|
|
|
$this->printAccordion(getMLText('attribute_value')." (".getMLText($type).")", $content);
|
2016-02-04 18:03:19 +00:00
|
|
|
}
|
|
|
|
}
|
2017-01-12 16:26:05 +00:00
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
if($res['folders'] || $res['docs']) {
|
|
|
|
print "<table id=\"viewfolder-table\" class=\"table table-condensed\">";
|
|
|
|
print "<thead>\n<tr>\n";
|
|
|
|
print "<th></th>\n";
|
|
|
|
print "<th>".getMLText("name")."</th>\n";
|
|
|
|
print "<th>".getMLText("status")."</th>\n";
|
|
|
|
print "<th>".getMLText("action")."</th>\n";
|
|
|
|
print "</tr>\n</thead>\n<tbody>\n";
|
|
|
|
foreach($res['folders'] as $subFolder) {
|
|
|
|
echo $this->folderListRow($subFolder);
|
2012-12-14 07:53:13 +00:00
|
|
|
}
|
2016-02-15 09:57:37 +00:00
|
|
|
$previewer = new SeedDMS_Preview_Previewer($cachedir, $previewwidth, $timeout);
|
2016-02-04 18:03:19 +00:00
|
|
|
foreach($res['docs'] as $document) {
|
|
|
|
echo $this->documentListRow($document, $previewer);
|
2015-04-14 17:38:09 +00:00
|
|
|
}
|
2016-02-04 18:03:19 +00:00
|
|
|
|
|
|
|
echo "</tbody>\n</table>\n";
|
|
|
|
}
|
|
|
|
|
|
|
|
if($res['contents']) {
|
|
|
|
print "<table id=\"viewfolder-table\" class=\"table\">";
|
|
|
|
print "<thead>\n<tr>\n";
|
|
|
|
print "<th></th>\n";
|
|
|
|
print "<th>".getMLText("name")."</th>\n";
|
|
|
|
print "<th>".getMLText("status")."</th>\n";
|
|
|
|
print "<th>".getMLText("action")."</th>\n";
|
|
|
|
print "</tr>\n</thead>\n<tbody>\n";
|
2016-02-15 09:57:37 +00:00
|
|
|
$previewer = new SeedDMS_Preview_Previewer($cachedir, $previewwidth, $timeout);
|
2016-02-04 18:03:19 +00:00
|
|
|
foreach($res['contents'] as $content) {
|
|
|
|
$doc = $content->getDocument();
|
|
|
|
echo $this->documentListRow($doc, $previewer);
|
2012-12-14 07:53:13 +00:00
|
|
|
}
|
2016-02-04 18:03:19 +00:00
|
|
|
print "</tbody></table>";
|
2012-12-14 07:53:13 +00:00
|
|
|
}
|
|
|
|
}
|
2016-02-04 18:03:19 +00:00
|
|
|
} /* }}} */
|
2012-12-14 07:53:13 +00:00
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
function showAttributeForm($attrdef) { /* {{{ */
|
|
|
|
if($attrdef && !$attrdef->isUsed()) {
|
|
|
|
?>
|
|
|
|
<form style="display: inline-block;" method="post" action="../op/op.AttributeMgr.php" >
|
|
|
|
<?php echo createHiddenFieldWithKey('removeattrdef'); ?>
|
|
|
|
<input type="hidden" name="attrdefid" value="<?php echo $attrdef->getID()?>">
|
|
|
|
<input type="hidden" name="action" value="removeattrdef">
|
|
|
|
<button type="submit" class="btn"><i class="icon-remove"></i> <?php echo getMLText("rm_attrdef")?></button>
|
2012-12-14 07:53:13 +00:00
|
|
|
</form>
|
2016-02-04 18:03:19 +00:00
|
|
|
<?php
|
|
|
|
}
|
2012-12-14 07:53:13 +00:00
|
|
|
?>
|
2017-01-04 06:03:05 +00:00
|
|
|
<form class="form-horizontal" action="../op/op.AttributeMgr.php" method="post">
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php
|
2016-02-04 18:03:19 +00:00
|
|
|
if($attrdef) {
|
|
|
|
echo createHiddenFieldWithKey('editattrdef');
|
2014-02-21 20:26:56 +00:00
|
|
|
?>
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="hidden" name="action" value="editattrdef">
|
|
|
|
<input type="hidden" name="attrdefid" value="<?php echo $attrdef->getID()?>" />
|
2014-02-21 20:26:56 +00:00
|
|
|
<?php
|
2016-02-04 18:03:19 +00:00
|
|
|
} else {
|
|
|
|
echo createHiddenFieldWithKey('addattrdef');
|
|
|
|
?>
|
|
|
|
<input type="hidden" name="action" value="addattrdef">
|
|
|
|
<?php
|
|
|
|
}
|
2012-12-14 07:53:13 +00:00
|
|
|
?>
|
2017-01-04 06:03:05 +00:00
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php printMLText("attrdef_name");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="text" name="name" value="<?php echo $attrdef ? htmlspecialchars($attrdef->getName()) : '' ?>">
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2015-10-30 07:01:37 +00:00
|
|
|
<?php printMLText("attrdef_objtype");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
<div class="controls">
|
2017-01-12 11:08:13 +00:00
|
|
|
<select name="objtype"><option value="<?php echo SeedDMS_Core_AttributeDefinition::objtype_all ?>"><?php printMLText('all'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::objtype_folder ?>" <?php if($attrdef && $attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_folder) echo "selected"; ?>><?php printMLText('folder'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::objtype_document ?>" <?php if($attrdef && $attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_document) echo "selected"; ?>><?php printMLText('document'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::objtype_documentcontent ?>" <?php if($attrdef && $attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_documentcontent) echo "selected"; ?>><?php printMLText('documentcontent'); ?></option></select>
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label"><?php printMLText("attrdef_type");?>:</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:13:06 +00:00
|
|
|
<select name="type"><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_int ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_int) echo "selected"; ?>><?php printMLText('attrdef_type_int'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_float ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_float) echo "selected"; ?>><?php printMLText('attrdef_type_float'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_string ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_string) echo "selected"; ?>><?php printMLText('attrdef_type_string'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_boolean ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_boolean) echo "selected"; ?>><?php printMLText('attrdef_type_boolean'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_date ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_date) echo "selected"; ?>><?php printMLText('attrdef_type_date'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_email ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_email) echo "selected"; ?>><?php printMLText('attrdef_type_email'); ?></option><option value="<?php echo SeedDMS_Core_AttributeDefinition::type_url ?>" <?php if($attrdef && $attrdef->getType() == SeedDMS_Core_AttributeDefinition::type_url) echo "selected"; ?>><?php printMLText('attrdef_type_url'); ?></option></select>
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php printMLText("attrdef_multiple");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="checkbox" value="1" name="multiple" <?php echo ($attrdef && $attrdef->getMultipleValues()) ? "checked" : "" ?>/>
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label"><?php printMLText("attrdef_minvalues");?>:</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="text" value="<?php echo $attrdef ? $attrdef->getMinValues() : '' ?>" name="minvalues" />
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php printMLText("attrdef_maxvalues");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="text" value="<?php echo $attrdef ? $attrdef->getMaxValues() : '' ?>" name="maxvalues" />
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php printMLText("attrdef_valueset");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
|
|
|
|
<div class="controls">
|
2016-10-06 06:02:32 +00:00
|
|
|
<?php if($attrdef && strlen($attrdef->getValueSet()) > 30) { ?>
|
2016-10-07 09:39:33 +00:00
|
|
|
<textarea name="valueset" rows="5"><?php echo ($attrdef && $attrdef->getValueSet()) ? $attrdef->getValueSetSeparator().implode("\n".$attrdef->getValueSetSeparator(), $attrdef->getValueSetAsArray()) : '' ?></textarea>
|
2016-10-06 06:02:32 +00:00
|
|
|
<?php } else { ?>
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="text" value="<?php echo $attrdef ? $attrdef->getValueSet() : '' ?>" name="valueset" />
|
2016-10-06 06:02:32 +00:00
|
|
|
<?php } ?>
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">
|
2013-05-28 07:03:21 +00:00
|
|
|
<?php printMLText("attrdef_regex");?>:
|
2017-01-04 06:03:05 +00:00
|
|
|
</label>
|
|
|
|
<div class="controls">
|
2016-02-04 18:03:19 +00:00
|
|
|
<input type="text" value="<?php echo $attrdef ? $attrdef->getRegex() : '' ?>" name="regex" />
|
2017-01-04 06:03:05 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="controls">
|
|
|
|
<button type="submit" class="btn"><i class="icon-save"></i> <?php printMLText("save");?></button>
|
|
|
|
</div>
|
2016-02-04 18:03:19 +00:00
|
|
|
</form>
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php
|
2016-02-04 18:03:19 +00:00
|
|
|
} /* }}} */
|
|
|
|
|
|
|
|
function form() { /* {{{ */
|
|
|
|
$selattrdef = $this->params['selattrdef'];
|
|
|
|
|
|
|
|
$this->showAttributeForm($selattrdef);
|
|
|
|
} /* }}} */
|
|
|
|
|
|
|
|
function show() { /* {{{ */
|
|
|
|
$dms = $this->params['dms'];
|
|
|
|
$user = $this->params['user'];
|
|
|
|
$attrdefs = $this->params['attrdefs'];
|
|
|
|
$selattrdef = $this->params['selattrdef'];
|
|
|
|
|
2016-02-09 11:36:19 +00:00
|
|
|
$this->htmlAddHeader('<script type="text/javascript" src="../styles/'.$this->theme.'/bootbox/bootbox.min.js"></script>'."\n", 'js');
|
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
$this->htmlStartPage(getMLText("admin_tools"));
|
|
|
|
$this->globalNavigation();
|
|
|
|
$this->contentStart();
|
|
|
|
$this->pageNavigation(getMLText("admin_tools"), "admin_tools");
|
|
|
|
$this->contentHeading(getMLText("attrdef_management"));
|
|
|
|
?>
|
|
|
|
|
|
|
|
<div class="row-fluid">
|
|
|
|
<div class="span6">
|
|
|
|
<div class="well">
|
2016-11-03 19:24:28 +00:00
|
|
|
<form class="form-horizontal">
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label" for="login"><?php printMLText("selection");?>:</label>
|
|
|
|
<div class="controls">
|
2016-11-02 11:25:03 +00:00
|
|
|
<select class="chzn-select" id="selector" class="input-xlarge">
|
|
|
|
<option value="-1"><?php echo getMLText("choose_attrdef")?></option>
|
|
|
|
<option value="0"><?php echo getMLText("new_attrdef")?></option>
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php
|
2016-02-04 18:03:19 +00:00
|
|
|
if($attrdefs) {
|
|
|
|
foreach ($attrdefs as $attrdef) {
|
|
|
|
switch($attrdef->getObjType()) {
|
|
|
|
case SeedDMS_Core_AttributeDefinition::objtype_all:
|
|
|
|
$ot = getMLText("all");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::objtype_folder:
|
|
|
|
$ot = getMLText("folder");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::objtype_document:
|
|
|
|
$ot = getMLText("document");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::objtype_documentcontent:
|
2017-01-12 11:08:13 +00:00
|
|
|
$ot = getMLText("documentcontent");
|
2016-02-04 18:03:19 +00:00
|
|
|
break;
|
2012-12-14 07:53:13 +00:00
|
|
|
}
|
2016-02-11 16:47:40 +00:00
|
|
|
switch($attrdef->getType()) {
|
|
|
|
case SeedDMS_Core_AttributeDefinition::type_int:
|
|
|
|
$t = getMLText("attrdef_type_int");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::type_float:
|
|
|
|
$t = getMLText("attrdef_type_float");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::type_string:
|
|
|
|
$t = getMLText("attrdef_type_string");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::type_date:
|
|
|
|
$t = getMLText("attrdef_type_date");
|
|
|
|
break;
|
|
|
|
case SeedDMS_Core_AttributeDefinition::type_boolean:
|
|
|
|
$t = getMLText("attrdef_type_boolean");
|
|
|
|
break;
|
|
|
|
}
|
2016-11-02 11:25:03 +00:00
|
|
|
print "<option value=\"".$attrdef->getID()."\" ".($selattrdef && $attrdef->getID()==$selattrdef->getID() ? 'selected' : '')." data-subtitle=\"".htmlspecialchars($ot.", ".$t)."\">" . htmlspecialchars($attrdef->getName()/* ." (".$ot.", ".$t.")"*/);
|
2012-12-14 07:53:13 +00:00
|
|
|
}
|
2016-02-04 18:03:19 +00:00
|
|
|
}
|
2012-12-14 07:53:13 +00:00
|
|
|
?>
|
2016-02-04 18:03:19 +00:00
|
|
|
</select>
|
2016-11-03 19:24:28 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
2012-12-14 07:53:13 +00:00
|
|
|
</div>
|
2016-04-22 06:30:19 +00:00
|
|
|
<div class="ajax" data-view="AttributeMgr" data-action="info" <?php echo ($selattrdef ? "data-query=\"attrdefid=".$selattrdef->getID()."\"" : "") ?>></div>
|
2012-12-14 07:53:13 +00:00
|
|
|
</div>
|
|
|
|
|
2016-02-04 18:03:19 +00:00
|
|
|
<div class="span6">
|
|
|
|
<div class="well">
|
|
|
|
<div class="ajax" data-view="AttributeMgr" data-action="form" <?php echo ($selattrdef ? "data-query=\"attrdefid=".$selattrdef->getID()."\"" : "") ?>></div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2012-12-14 07:53:13 +00:00
|
|
|
|
2016-03-18 14:33:18 +00:00
|
|
|
</div>
|
|
|
|
|
2012-12-14 07:53:13 +00:00
|
|
|
<?php
|
2016-03-15 07:30:53 +00:00
|
|
|
$this->contentEnd();
|
2012-12-14 07:53:13 +00:00
|
|
|
$this->htmlEndPage();
|
|
|
|
} /* }}} */
|
|
|
|
}
|
|
|
|
?>
|