* Finish docmycollectionblock zin page and adjust doc dashboard layout.
This commit is contained in:
@@ -10,15 +10,57 @@ declare(strict_types=1);
|
||||
*/
|
||||
|
||||
namespace zin;
|
||||
|
||||
?>
|
||||
<?php $canView = common::hasPriv('doc', 'view');?>
|
||||
<div>
|
||||
<?php if(empty($docList)):?>
|
||||
<div class='table-empty-tip'><p><span class='text-muted'><?php echo $lang->doc->noDoc;?></p></span></div>
|
||||
<?php else:?>
|
||||
<div class="doc-list">
|
||||
<?php foreach($docList as $doc):?>
|
||||
<div class="doc-box">
|
||||
<a href='<?php echo $this->createLink("doc", "view", "docID=$doc->id");?>'>
|
||||
<div class="p-2 border">
|
||||
<span class='date-interval text-muted text-gray'>
|
||||
<?php
|
||||
$interval = $doc->editInterval;
|
||||
$editTip = $lang->doc->todayUpdated;
|
||||
if($interval->year)
|
||||
{
|
||||
$editTip = sprintf($lang->doc->yearsUpdated, $interval->year);
|
||||
}
|
||||
elseif($interval->month)
|
||||
{
|
||||
$editTip = sprintf($lang->doc->monthsUpdated, $interval->month);
|
||||
}
|
||||
elseif($interval->day)
|
||||
{
|
||||
$editTip = sprintf($lang->doc->daysUpdated, $interval->day);
|
||||
}
|
||||
echo $editTip;
|
||||
?>
|
||||
</span>
|
||||
<h4 class="plug-title my-2 text-black font-bold" title="<?php echo $doc->title;?>">
|
||||
<?php
|
||||
$docType = $doc->type == 'text' ? 'wiki-file' : $doc->type;
|
||||
echo html::image("static/svg/{$docType}.svg", "class='file-icon inline'");
|
||||
?>
|
||||
<?php echo $doc->title;?>
|
||||
</h4>
|
||||
<p class='edit-date text-muted text-gray mb-2'><?php echo $lang->doc->editedDate . (common::checkNotCN() ? ': ' : ':') . $doc->editedDate;?></p>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
<?php
|
||||
panel
|
||||
(
|
||||
set('headingClass', 'border-b'),
|
||||
set('class', 'docmycollection-block ' . ($longBlock ? 'block-long' : 'block-sm')),
|
||||
set::title($block->title),
|
||||
div
|
||||
(
|
||||
'正在开发中...'
|
||||
)
|
||||
rawContent()
|
||||
);
|
||||
|
||||
render();
|
||||
|
||||
Reference in New Issue
Block a user