mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-12 08:55:54 +00:00
Merge branch 'seeddms-5.1.x' into seeddms-6.0.x
This commit is contained in:
commit
1b15008870
|
@ -1066,18 +1066,21 @@ class SeedDMS_Core_AttributeDefinition { /* {{{ */
|
|||
* @param integer $limit limit number of documents/folders
|
||||
* @return array array containing list of documents and folders
|
||||
*/
|
||||
public function getObjects($attrvalue, $limit=0) { /* {{{ */
|
||||
public function getObjects($attrvalue, $limit=0, $op=O_EQ) { /* {{{ */
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
$result = array('docs'=>array(), 'folders'=>array(), 'contents'=>array());
|
||||
if($this->_objtype == SeedDMS_Core_AttributeDefinition::objtype_all ||
|
||||
$this->_objtype == SeedDMS_Core_AttributeDefinition::objtype_document) {
|
||||
$queryStr = "SELECT * FROM `tblDocumentAttributes` WHERE `attrdef`=".$this->_id." AND ";
|
||||
if($this->getMultipleValues()) {
|
||||
$sep = $this->getValueSetSeparator();
|
||||
$queryStr .= "(`value` like ".$db->qstr($sep.$attrvalue.'%')." OR `value` like ".$db->qstr('%'.$sep.$attrvalue.$sep.'%')." OR `value` like ".$db->qstr('%'.$sep.$attrvalue).")";
|
||||
} else {
|
||||
$queryStr .= "`value`=".$db->qstr($attrvalue);
|
||||
$this->_objtype == SeedDMS_Core_AttributeDefinition::objtype_document) {
|
||||
$queryStr = "SELECT * FROM `tblDocumentAttributes` WHERE `attrdef`=".$this->_id;
|
||||
if($attrvalue != null) {
|
||||
$queryStr .= " AND ";
|
||||
if($this->getMultipleValues()) {
|
||||
$sep = $this->getValueSetSeparator();
|
||||
$queryStr .= "(`value` like ".$db->qstr($sep.$attrvalue.'%')." OR `value` like ".$db->qstr('%'.$sep.$attrvalue.$sep.'%')." OR `value` like ".$db->qstr('%'.$sep.$attrvalue).")";
|
||||
} else {
|
||||
$queryStr .= "`value`".$op.$db->qstr($attrvalue);
|
||||
}
|
||||
}
|
||||
if($limit)
|
||||
$queryStr .= " limit ".(int) $limit;
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<email>uwe@steinmann.cx</email>
|
||||
<active>yes</active>
|
||||
</lead>
|
||||
<date>2022-04-25</date>
|
||||
<date>2022-05-19</date>
|
||||
<time>13:44:55</time>
|
||||
<version>
|
||||
<release>6.0.19</release>
|
||||
|
@ -1986,6 +1986,10 @@ add method SeedDMS_Core_DatabaseAccess::setLogFp()
|
|||
<license uri="http://opensource.org/licenses/gpl-license">GPL License</license>
|
||||
<notes>
|
||||
- fix validating multi value attributes
|
||||
- SeedDMS_Core_User::removeFromProcesses() can be limited to a list of documents. In that case only the last version will be modified.
|
||||
- add more types to getStatisticalData()
|
||||
- add optional parameter $op to SeedDMS_Core_AttributeDefinition::getObjects()
|
||||
- SeedDMS_Core_AttributeDefinition::getObjects() will not filter by value if null is passed
|
||||
</notes>
|
||||
</release>
|
||||
<release>
|
||||
|
|
|
@ -3854,9 +3854,7 @@ $("body").on("click", "span.openpopupbox", function(e) {
|
|||
*/
|
||||
$html = '
|
||||
<span class="openpopupbox" data-href="#'.$id.'">'.$title.'</span>
|
||||
<div id="'.$id.'" class="popupbox" style="display: none;">
|
||||
'.$content.'
|
||||
<span class="closepopupbox"><i class="fa fa-remove"></i></span>
|
||||
<div id="'.$id.'" class="popupbox" style="display: none;">'.$content.'<span class="closepopupbox"><i class="fa fa-remove"></i></span>
|
||||
</div>';
|
||||
if($ret)
|
||||
return $html;
|
||||
|
|
|
@ -368,11 +368,14 @@ div.popupbox {
|
|||
color: black;
|
||||
text-align: left;
|
||||
text-shadow: none;
|
||||
line-height: 1.4em;
|
||||
border: 1px solid #ccc;
|
||||
padding: 25px 15px 15px 15px;
|
||||
display: none;
|
||||
position: absolute;
|
||||
min-width: 230px;
|
||||
max-width: 280px;
|
||||
white-space: break-spaces;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user