mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-14 05:31:42 +00:00
added check for missing filesize field
This commit is contained in:
parent
e81f19e714
commit
a41ede18bb
|
@ -146,9 +146,11 @@ class LetoDMS_View_ObjectCheck extends LetoDMS_Bootstrap_Style {
|
||||||
$dms = $this->params['dms'];
|
$dms = $this->params['dms'];
|
||||||
$user = $this->params['user'];
|
$user = $this->params['user'];
|
||||||
$folder = $this->params['folder'];
|
$folder = $this->params['folder'];
|
||||||
$versions = $this->params['unlinkedcontent'];
|
$unlinkedversions = $this->params['unlinkedcontent'];
|
||||||
|
$nofilesizeversions = $this->params['nofilesizeversions'];
|
||||||
$repair = $this->params['repair'];
|
$repair = $this->params['repair'];
|
||||||
$unlink = $this->params['unlink'];
|
$unlink = $this->params['unlink'];
|
||||||
|
$setfilesize = $this->params['setfilesize'];
|
||||||
|
|
||||||
$this->htmlStartPage(getMLText("admin_tools"));
|
$this->htmlStartPage(getMLText("admin_tools"));
|
||||||
$this->globalNavigation();
|
$this->globalNavigation();
|
||||||
|
@ -183,7 +185,7 @@ class LetoDMS_View_ObjectCheck extends LetoDMS_Bootstrap_Style {
|
||||||
echo "<p>".getMLText('unlinking_objects')."</p>";
|
echo "<p>".getMLText('unlinking_objects')."</p>";
|
||||||
}
|
}
|
||||||
|
|
||||||
if($versions) {
|
if($unlinkedversions) {
|
||||||
print "<table class=\"table-condensed\">";
|
print "<table class=\"table-condensed\">";
|
||||||
print "<thead>\n<tr>\n";
|
print "<thead>\n<tr>\n";
|
||||||
print "<th>".getMLText("document")."</th>\n";
|
print "<th>".getMLText("document")."</th>\n";
|
||||||
|
@ -192,7 +194,7 @@ class LetoDMS_View_ObjectCheck extends LetoDMS_Bootstrap_Style {
|
||||||
print "<th>".getMLText("mimetype")."</th>\n";
|
print "<th>".getMLText("mimetype")."</th>\n";
|
||||||
print "<th></th>\n";
|
print "<th></th>\n";
|
||||||
print "</tr>\n</thead>\n<tbody>\n";
|
print "</tr>\n</thead>\n<tbody>\n";
|
||||||
foreach($versions as $version) {
|
foreach($unlinkedversions as $version) {
|
||||||
$doc = $version->getDocument();
|
$doc = $version->getDocument();
|
||||||
print "<tr><td>".$doc->getId()."</td><td>".$version->getVersion()."</td><td>".$version->getOriginalFileName()."</td><td>".$version->getMimeType()."</td>";
|
print "<tr><td>".$doc->getId()."</td><td>".$version->getVersion()."</td><td>".$version->getOriginalFileName()."</td><td>".$version->getMimeType()."</td>";
|
||||||
if($unlink) {
|
if($unlink) {
|
||||||
|
@ -206,6 +208,34 @@ class LetoDMS_View_ObjectCheck extends LetoDMS_Bootstrap_Style {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$this->contentContainerEnd();
|
||||||
|
|
||||||
|
$this->contentHeading(getMLText("missing_filesize"));
|
||||||
|
$this->contentContainerStart();
|
||||||
|
|
||||||
|
if($nofilesizeversions) {
|
||||||
|
print "<table class=\"table-condensed\">";
|
||||||
|
print "<thead>\n<tr>\n";
|
||||||
|
print "<th>".getMLText("document")."</th>\n";
|
||||||
|
print "<th>".getMLText("version")."</th>\n";
|
||||||
|
print "<th>".getMLText("original_filename")."</th>\n";
|
||||||
|
print "<th>".getMLText("mimetype")."</th>\n";
|
||||||
|
print "<th></th>\n";
|
||||||
|
print "</tr>\n</thead>\n<tbody>\n";
|
||||||
|
foreach($nofilesizeversions as $version) {
|
||||||
|
$doc = $version->getDocument();
|
||||||
|
print "<tr><td>".$doc->getId()."</td><td>".$version->getVersion()."</td><td>".$version->getOriginalFileName()."</td><td>".$version->getMimeType()."</td>";
|
||||||
|
if($setfilesize) {
|
||||||
|
$version->setFileSize();
|
||||||
|
}
|
||||||
|
print "</tr>\n";
|
||||||
|
}
|
||||||
|
print "</tbody></table>\n";
|
||||||
|
if($setfilesize == 0) {
|
||||||
|
echo '<p><a href="out.ObjectCheck.php?setfilesize=1">'.getMLText('do_object_setfilesize').'</a></p>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$this->contentContainerEnd();
|
$this->contentContainerEnd();
|
||||||
$this->htmlEndPage();
|
$this->htmlEndPage();
|
||||||
} /* }}} */
|
} /* }}} */
|
||||||
|
|
Loading…
Reference in New Issue
Block a user