mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
Merge branch 'seeddms-5.1.x' into seeddms-6.0.x
This commit is contained in:
commit
b2f0f2fa30
|
@ -4097,7 +4097,13 @@ class SeedDMS_Core_DMS {
|
|||
/** @var SeedDMS_Core_Document[] $timeline */
|
||||
$timeline = array();
|
||||
|
||||
$queryStr = "SELECT DISTINCT document FROM `tblDocumentContent` WHERE `date` > ".$startts." AND `date` < ".$endts." OR `revisiondate` > '".date('Y-m-d H:i:s', $startts)."' AND `revisiondate` < '".date('Y-m-d H:i:s', $endts)."' UNION SELECT DISTINCT document FROM `tblDocumentFiles` WHERE `date` > ".$startts." AND `date` < ".$endts;
|
||||
if(0) {
|
||||
$queryStr = "SELECT DISTINCT `document` FROM `tblDocumentContent` WHERE `date` > ".$startts." AND `date` < ".$endts." OR `revisiondate` > '".date('Y-m-d H:i:s', $startts)."' AND `revisiondate` < '".date('Y-m-d H:i:s', $endts)."' UNION SELECT DISTINCT `document` FROM `tblDocumentFiles` WHERE `date` > ".$startts." AND `date` < ".$endts;
|
||||
} else {
|
||||
$startdate = date('Y-m-d H:i:s', $startts);
|
||||
$enddate = date('Y-m-d H:i:s', $endts);
|
||||
$queryStr = "SELECT DISTINCT `documentID` AS `document` FROM `tblDocumentStatus` LEFT JOIN `tblDocumentStatusLog` ON `tblDocumentStatus`.`statusId`=`tblDocumentStatusLog`.`statusID` WHERE `date` > ".$this->db->qstr($startdate)." AND `date` < ".$this->db->qstr($enddate)." UNION SELECT DISTINCT document FROM `tblDocumentFiles` WHERE `date` > ".$this->db->qstr($startdate)." AND `date` < ".$this->db->qstr($enddate)." UNION SELECT DISTINCT `document` FROM `tblDocumentFiles` WHERE `date` > ".$startts." AND `date` < ".$endts;
|
||||
}
|
||||
$resArr = $this->db->getResultArray($queryStr);
|
||||
if ($resArr === false)
|
||||
return false;
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<email>uwe@steinmann.cx</email>
|
||||
<active>yes</active>
|
||||
</lead>
|
||||
<date>2021-04-13</date>
|
||||
<date>2021-05-07</date>
|
||||
<time>13:44:55</time>
|
||||
<version>
|
||||
<release>6.0.16</release>
|
||||
|
@ -1888,6 +1888,22 @@ add method SeedDMS_Core_DatabaseAccess::setLogFp()
|
|||
problem when removing a document
|
||||
</notes>
|
||||
</release>
|
||||
<release>
|
||||
<date>2021-05-07</date>
|
||||
<time>13:44:55</time>
|
||||
<version>
|
||||
<release>5.1.23</release>
|
||||
<api>5.1.23</api>
|
||||
</version>
|
||||
<stability>
|
||||
<release>stable</release>
|
||||
<api>stable</api>
|
||||
</stability>
|
||||
<license uri="http://opensource.org/licenses/gpl-license">GPL License</license>
|
||||
<notes>
|
||||
- SeedDMS_Core_DMS::getTimeline() uses status log instead of document content
|
||||
</notes>
|
||||
</release>
|
||||
<release>
|
||||
<date>2017-02-28</date>
|
||||
<time>06:34:50</time>
|
||||
|
|
|
@ -98,7 +98,7 @@ class SeedDMS_View_Timeline extends SeedDMS_Theme_Style {
|
|||
$msg = getMLText('timeline_full_'.$item['type'], array('document'=>htmlspecialchars($item['document']->getName()), 'version'=> $item['version']));
|
||||
break;
|
||||
default:
|
||||
$msg = '???';
|
||||
$msg = getMLText('timeline_full_'.$item['type'], array('document'=>htmlspecialchars($item['document']->getName())));
|
||||
}
|
||||
$data[$i]['msg'] = $msg;
|
||||
}
|
||||
|
@ -185,6 +185,11 @@ div.timeline-frame {
|
|||
border-color: #e3e3e3;
|
||||
}
|
||||
|
||||
div.add_file {
|
||||
background-color: #E5D5F5;
|
||||
border-color: #AA9ABA;
|
||||
}
|
||||
|
||||
div.status_change_2 {
|
||||
background-color: #DAF6D5;
|
||||
border-color: #AAF897;
|
||||
|
@ -195,6 +200,16 @@ div.status_change_-1 {
|
|||
border-color: #F89797;
|
||||
}
|
||||
|
||||
div.status_change_-2 {
|
||||
background-color: #eee;
|
||||
border-color: #ccc;
|
||||
}
|
||||
|
||||
div.status_change_-3 {
|
||||
background-color: #eee;
|
||||
border-color: #ccc;
|
||||
}
|
||||
|
||||
div.timeline-event-selected {
|
||||
background-color: #fff785;
|
||||
border-color: #ffc200;
|
||||
|
@ -258,6 +273,7 @@ div.timeline-event-selected {
|
|||
<input type="checkbox" name="skip[]" value="status_change_4" '.(($skip && in_array('status_change_4', $skip)) ? 'checked' : '').'> '.getMLText('timeline_skip_status_change_4').'<br />
|
||||
<input type="checkbox" name="skip[]" value="status_change_5" '.(($skip && in_array('status_change_5', $skip)) ? 'checked' : '').'> '.getMLText('timeline_skip_status_change_5').'<br />
|
||||
<input type="checkbox" name="skip[]" value="status_change_-1" '.(($skip && in_array('status_change_-1', $skip)) ? 'checked' : '').'> '.getMLText('timeline_skip_status_change_-1').'<br />
|
||||
<input type="checkbox" name="skip[]" value="status_change_-2" '.(($skip && in_array('status_change_-2', $skip)) ? 'checked' : '').'> '.getMLText('timeline_skip_status_change_-2').'<br />
|
||||
<input type="checkbox" name="skip[]" value="status_change_-3" '.(($skip && in_array('status_change_-3', $skip)) ? 'checked' : '').'> '.getMLText('timeline_skip_status_change_-3').'<br />';
|
||||
$this->formField(
|
||||
getMLText("exclude_items"),
|
||||
|
|
|
@ -72,10 +72,10 @@ class SeedDMS_View_TimelineFeed extends SeedDMS_Theme_Style {
|
|||
// Use core setChannelElement() function for other optional channel elements.
|
||||
// See http://www.rssboard.org/rss-specification#optionalChannelElements
|
||||
// for other optional channel elements. Here the language code for American English and
|
||||
$feed->setChannelElement('language', 'en-US');
|
||||
$feed->setChannelElement('language', str_replace('_', '-', $user->getLanguage()));
|
||||
// The date when this feed was lastly updated. The publication date is also set.
|
||||
$feed->setDate(date(DATE_RSS, time()));
|
||||
$feed->setChannelElement('pubDate', date(\DATE_RSS, strtotime('2013-04-06')));
|
||||
$feed->setChannelElement('pubDate', date(\DATE_RSS, time() /*strtotime('2013-04-06')*/));
|
||||
// You can add additional link elements, e.g. to a PubSubHubbub server with custom relations.
|
||||
// It's recommended to provide a backlink to the feed URL.
|
||||
$feed->setSelfLink($baseurl.'out/out.TimelineFeed.php');
|
||||
|
@ -93,13 +93,13 @@ class SeedDMS_View_TimelineFeed extends SeedDMS_Theme_Style {
|
|||
foreach($data as $i=>$item) {
|
||||
switch($item['type']) {
|
||||
case 'add_version':
|
||||
$msg = getMLText('timeline_'.$item['type']);
|
||||
$msg = getMLText('timeline_'.$item['type'], array(), null, $user->getLanguage());
|
||||
break;
|
||||
case 'add_file':
|
||||
$msg = getMLText('timeline_'.$item['type']);
|
||||
$msg = getMLText('timeline_'.$item['type'], array(), null, $user->getLanguage());
|
||||
break;
|
||||
case 'status_change':
|
||||
$msg = getMLText('timeline_'.$item['type'], array('version'=> $item['version'], 'status'=> getOverallStatusText($item['status'])));
|
||||
$msg = getMLText('timeline_'.$item['type'], array('version'=> $item['version'], 'status'=> getOverallStatusText($item['status'])), null, $user->getLanguage());
|
||||
break;
|
||||
default:
|
||||
$msg = '???';
|
||||
|
@ -121,9 +121,9 @@ class SeedDMS_View_TimelineFeed extends SeedDMS_Theme_Style {
|
|||
$newItem->setTitle($doc->getName()." (".$item['msg'].")");
|
||||
$newItem->setLink($baseurl.'out/out.ViewDocument.php?documentid='.$doc->getID());
|
||||
$newItem->setDescription("<h2>".$item['msg']."</h2>".
|
||||
"<p>".getMLText('comment').": <b>".$doc->getComment()."</b></p>".
|
||||
"<p>".getMLText('owner').": <b><a href=\"mailto:".htmlspecialchars($owner->getEmail())."\">".htmlspecialchars($owner->getFullName())."</a></b></p>".
|
||||
"<p>".getMLText("creation_date").": <b>".getLongReadableDate($doc->getDate())."</p>"
|
||||
"<p>".getMLText('comment', array(), null, $user->getLanguage()).": <b>".$doc->getComment()."</b></p>".
|
||||
"<p>".getMLText('owner', array(), null, $user->getLanguage()).": <b><a href=\"mailto:".htmlspecialchars($owner->getEmail())."\">".htmlspecialchars($owner->getFullName())."</a></b></p>".
|
||||
"<p>".getMLText("creation_date", array(), null, $user->getLanguage()).": <b>".getLongReadableDate($doc->getDate())."</p>"
|
||||
);
|
||||
$newItem->setDate(date('c', $d));
|
||||
$newItem->setAuthor($owner->getFullName(), preg_match('/.+@.+/', $owner->getEmail()) == 1 ? $owner->getEmail() : null);
|
||||
|
|
Loading…
Reference in New Issue
Block a user