mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-20 00:12:15 +00:00
- Removed body tag from footer.php and header.php
- Added permission fs/dms to dump.sql and fhcomplete.php - Added FilesystemLib to read and write from/in filesystem - Added FS_Model to manage filesystem with the same permission system of DB_Model - Added more models to handle the Dms - Modified Dms controller to use the new models
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
|
||||
class DmsVersion_model extends DB_Model
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->dbTable = 'campus.tbl_dms_version';
|
||||
$this->pk = array('dms_id', 'version');
|
||||
$this->hasSequence = false;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function filterFields($dms, $dms_id = null, $fileName = null)
|
||||
{
|
||||
$fieldsArray = array(
|
||||
'version',
|
||||
'mimetype',
|
||||
'name',
|
||||
'beschreibung',
|
||||
'letzterzugriff',
|
||||
'insertamum',
|
||||
'insertvon',
|
||||
'updateamum',
|
||||
'updatevon'
|
||||
);
|
||||
$returnArray = array();
|
||||
|
||||
foreach ($fieldsArray as $value)
|
||||
{
|
||||
if (isset($dms[$value]))
|
||||
{
|
||||
$returnArray[$value] = $dms[$value];
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($dms_id))
|
||||
{
|
||||
$returnArray['dms_id'] = $dms_id;
|
||||
}
|
||||
if (isset($fileName))
|
||||
{
|
||||
$returnArray['filename'] = $fileName;
|
||||
}
|
||||
|
||||
return $returnArray;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user