Przeglądaj źródła

U UserMsgs objects

Piotr Labudda 7 lat temu
rodzic
commit
498acd0f1e

+ 32 - 41
SE/se-lib/Route/UserMsgs.php

@@ -5,42 +5,33 @@ Lib::loadClass('RouteBase');
 Lib::loadClass('TypespecialVariable');
 Lib::loadClass('ProcesHelper');
 Lib::loadClass('UsersHelper');
+Lib::loadClass('UI');
 
 class Route_UserMsgs extends RouteBase {
 
 	var $_listLimit = 20;
 
-	public function handleAuth() {
+	function handleAuth() {
 		if (!User::logged()) {
 			User::authByRequest();
 		}
 	}
 
-	public function defaultAction() {
-		SE_Layout::gora();
-		SE_Layout::menu();
-
-		try {
-			$usrLogin = User::getLogin();
-			//$this->menu();
-			$this->userMsgs($usrLogin);
-		} catch (Exception $e) {
-			SE_Layout::alert('danger', $e->getMessage() . ' #' . $e->getLine());
-		}
-
-		SE_Layout::dol();
+	function defaultAction() { UI::layout([ $this, 'defaultView' ]); }
+	function defaultView() {
+		$usrLogin = User::getLogin();
+		//$this->menu();
+		$this->userMsgs($usrLogin);
 	}
 
-	public function menu() {
+	function menu() {
 		$usrLogin = User::getLogin();
-?>
-<ul>
-	<li>TODO: ...</li>
-</ul>
-<?php
+		echo UI::h('ul', [], [
+			UI::h('li', [], "TODO: ..."),
+		]);
 	}
 
-	public function userMsgs($usrLogin) {
+	function userMsgs($usrLogin) {
 		$msgsList = $this->getMsgs('inbox', $usrLogin);
 		$totalReadMsgs = 0;
 		$totalUnreadMsgs = 0;
@@ -212,7 +203,7 @@ function tblMsgsLoadMoreRows(n) {
 		//throw new Exception("TODO: ...");
 	}
 
-	public function loadMoreRowsAction() {
+	function loadMoreRowsAction() {
 		$usrLogin = V::get('usrLogin', '', $_GET, 'word');
 		$lastMsgId = V::get('lastMsgId', 0, $_GET, 'int');
 		$listType = V::get('listType', '', $_GET, 'word');
@@ -226,7 +217,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($resultData);
 	}
 
-	public function _printUserMsgsList($listType, $msgsList, $usrLogin) {
+	function _printUserMsgsList($listType, $msgsList, $usrLogin) {
 		$msgsTotal = count($msgsList);
 		$listLimit = $this->_listLimit;
 		$lastMsgId = 0;
@@ -306,7 +297,7 @@ function tblMsgsLoadMoreRows(n) {
 <?php
 	}
 
-	public function getMsgs($filterType, $usrLogin, $lastMsgId = null, $fromTime = null) {
+	function getMsgs($filterType, $usrLogin, $lastMsgId = null, $fromTime = null) {
 		$lastMsgId = (int)$lastMsgId;
 		$msgsRoute = Router::getRoute('Msgs');
 		$msgsList = array();
@@ -386,7 +377,7 @@ function tblMsgsLoadMoreRows(n) {
 		return $msgsList;
 	}
 
-	public function _validate($args) {
+	function _validate($args) {
 		$toType = V::get('to_type', '', $args);
 		$to = V::get('to', '', $args);
 		$msg = V::get('msg', '', $args);
@@ -401,7 +392,7 @@ function tblMsgsLoadMoreRows(n) {
 		}
 	}
 
-	public function _create($args, $tableName, $idRow) {
+	function _create($args, $tableName, $idRow) {
 		$toType = V::get('to_type', '', $args);
 		$to = V::get('to', '', $args);
 		$msg = V::get('msg', '', $args);
@@ -430,7 +421,7 @@ function tblMsgsLoadMoreRows(n) {
 		return $createdId;
 	}
 
-	public function _printMsgForm($args) {
+	function _printMsgForm($args) {
 		$toType = V::get('to_type', '', $args);
 		$to = V::get('to', '', $args);
 		$msg = V::get('msg', '', $args);
@@ -522,7 +513,7 @@ function tblMsgsLoadMoreRows(n) {
 <?php
 	}
 
-	public function typeSpecialUserLoginAction() {
+	function typeSpecialUserLoginAction() {
 		header("Content-type: application/json");
 		$typeSpecialUserId = TypespecialVariable::getInstance(-1, '__USER_LOGIN');
 		if (!$typeSpecialUserId) {
@@ -549,7 +540,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($jsonData);
 	}
 
-	public function typeSpecialGroupIdAction() {
+	function typeSpecialGroupIdAction() {
 		header("Content-type: application/json");
 		Lib::loadClass('TypespecialVariable');
 		$typeSpecialZasob = TypespecialVariable::getInstance(-1, '__ZASOB');
@@ -579,7 +570,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($jsonData);
 	}
 
-	public function readAction() {
+	function readAction() {
 		$idMsg = V::get('id', 0, $_GET, 'int');
 		$usrLogin = V::get('usrLogin', '', $_REQUEST, 'word');
 		if ($idMsg <= 0) throw new HttpException("Wiadomość nie istnieje!", 404);
@@ -599,7 +590,7 @@ function tblMsgsLoadMoreRows(n) {
 		SE_Layout::dol();
 	}
 
-	public function viewAction() {
+	function viewAction() {
 		$idMsg = V::get('id', 0, $_GET, 'int');
 		$usrLogin = V::get('usrLogin', 0, $_REQUEST, 'word');
 		if ($idMsg <= 0) throw new HttpException("Wiadomość nie istnieje!", 404);
@@ -618,7 +609,7 @@ function tblMsgsLoadMoreRows(n) {
 		SE_Layout::dol();
 	}
 
-	public function _getMsg($idMsg, $usrLogin) {
+	function _getMsg($idMsg, $usrLogin) {
 		$msgsRoute = Router::getRoute('Msgs');
 		$msg['_raw'] = $msgsRoute->getMessage($idMsg);
 		if (!$msg['_raw']) throw new HttpException("Wiadomość nie istnieje!", 404);
@@ -640,7 +631,7 @@ function tblMsgsLoadMoreRows(n) {
 		return $msg;
 	}
 
-	public function _markAsRead($msg) {
+	function _markAsRead($msg) {
 		if ($msg['_read']) return;
 
 		$usrLogin = User::getLogin();
@@ -668,7 +659,7 @@ function tblMsgsLoadMoreRows(n) {
 		if (!$res || $db->has_errors()) throw new Exception("Wystąpiły błędy podczas próby zapisu wiadomości: " . implode("\n<br>", $db->get_errors()));
 	}
 
-	public function viewMsg($msg) {
+	function viewMsg($msg) {
 		$usrLogin = User::getLogin();
 		$idTable = 0;
 		if (!empty($msg['tblName'])) {
@@ -705,7 +696,7 @@ function tblMsgsLoadMoreRows(n) {
 <?php
 	}
 
-	public function printWidgetViewMsg($msg) {
+	function printWidgetViewMsg($msg) {
 		$messageList = array();
 		$uiTargetName = $msg['_raw']->uiTargetName;
 		$uiTargetType = $msg['_raw']->uiTargetType;
@@ -901,7 +892,7 @@ function tblMsgsLoadMoreRows(n) {
 <?php
 	}
 
-	public function _convertMessageToJson($rawMsg) {
+	function _convertMessageToJson($rawMsg) {
 		/* $msg = {_raw: {A_RECORD_CREATE_AUTHOR: "plabudda",
 											A_RECORD_CREATE_DATE: "2015-10-26 12:20:05",
 											A_RECORD_DELETE_AUTHOR: "",
@@ -954,7 +945,7 @@ function tblMsgsLoadMoreRows(n) {
 		return $message;
 	}
 
-	public function getMessagesByIdAction() {
+	function getMessagesByIdAction() {
 		try {
 			$idThread = V::get('idThread', '', $_GET, 'int');
 			$idLastMsg = V::get('idLastMsg', '', $_GET, 'int');
@@ -987,7 +978,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($response);
 	}
 
-	public function replyAction() {
+	function replyAction() {
 		try {
 			$uiTargetType = V::get('uiTargetType', '', $_GET);
 			$uiTargetName = V::get('uiTargetName', '', $_GET);
@@ -1000,7 +991,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($response);
 	}
 
-	public function markAsReadAction() {
+	function markAsReadAction() {
 		$usrLogin = User::getLogin();
 		try {
 			$idMsg = V::get('idMsg', '', $_GET, 'int');
@@ -1019,7 +1010,7 @@ function tblMsgsLoadMoreRows(n) {
 		echo json_encode($response);
 	}
 
-	public function _reply($uiTargetType, $uiTargetName, $args) {
+	function _reply($uiTargetType, $uiTargetName, $args) {
 		$ds = DB::getDataSource();
 		$newMsg = array();
 		$newMsg['idReplyTo'] = V::get('idReplyTo', '', $args, 'int');
@@ -1051,7 +1042,7 @@ function tblMsgsLoadMoreRows(n) {
 		return $response;
 	}
 
-	public function removeMsgAction() {
+	function removeMsgAction() {
 		$idMsg = V::get('id', 0, $_GET, 'int');
 		$usrLogin = V::get('usrLogin', 0, $_REQUEST, 'word');
 		if ($idMsg <= 0) throw new HttpException("Wiadomość nie istnieje!", 404);

+ 27 - 0
SE/se-lib/Schema/UserMsgsSentStorageAcl.php

@@ -0,0 +1,27 @@
+<?php
+
+Lib::loadClass('Core_AclSimpleSchemaBase');
+Lib::loadClass('Schema_UserMsgsStorageAcl');
+Lib::loadClass('ParseOgcFilter');
+
+class Schema_UserMsgsSentStorageAcl extends Schema_UserMsgsStorageAcl {
+
+	function _parseSqlWhere($params = []) {
+		$sqlWhereAnd = [];
+
+		$sqlWhereAnd[] = " m.`uiTargetType` = 'default_db_table_record' ";
+
+		$sqlUserLogin = DB::getPDO()->quote($this->login);
+		$sqlWhereAnd[] = " m.`A_RECORD_CREATE_AUTHOR` = {$sqlUserLogin} ";
+		$sqlWhereAnd[] = "
+			(	m.`A_STATUS` in('WAITING', 'NORMAL')
+				or ( m.`A_STATUS` = 'OFF_HARD' and m.`A_RECORD_DELETE_AUTHOR` != 'plabudda' )
+			)
+		";
+
+		// TODO: parse where/ogc, etc.
+
+		return implode(" and ", $sqlWhereAnd);
+	}
+
+}

+ 58 - 71
SE/se-lib/Schema/UserMsgsStorageAcl.php

@@ -58,12 +58,12 @@ class Schema_UserMsgsStorageAcl extends Core_AclSimpleSchemaBase {
 			'actionNotes' => [ '@type' => 'xsd:string' ],
 			'A_STATUS' => [ '@type' => 'xsd:string' ], // enum('WAITING','NORMAL','OFF_HARD','DELETED') NOT NULL DEFAULT 'WAITING',
 			'actionNotes' => [ '@type' => 'xsd:string' ],
-			'autor' => [ '@type' => 'xsd:string', '@alias' => 'A_RECORD_CREATE_AUTHOR' ],
-			'utworzono' => [ '@type' => 'xsd:date', '@alias' => 'A_RECORD_CREATE_DATE' ],
-			'zaktualizował' => [ '@type' => 'xsd:string', '@alias' => 'A_RECORD_UPDATE_AUTHOR' ],
-			'zaktualizowano' => [ '@type' => 'xsd:date', '@alias' => 'A_RECORD_UPDATE_DATE' ],
-			'usunął' => [ '@type' => 'xsd:string', '@alias' => 'A_RECORD_DELETE_AUTHOR' ],
-			'usunięto' => [ '@type' => 'xsd:date', '@alias' => 'A_RECORD_DELETE_DATE' ],
+			'A_RECORD_CREATE_AUTHOR' => [ '@type' => 'xsd:string' ], // label: "autor"
+			'A_RECORD_CREATE_DATE' => [ '@type' => 'xsd:date' ], // label: "utworzono"
+			'A_RECORD_UPDATE_AUTHOR' => [ '@type' => 'xsd:string' ], // label: "zaktualizował"
+			'A_RECORD_UPDATE_DATE' => [ '@type' => 'xsd:date' ], // label: "zaktualizowano"
+			'A_RECORD_DELETE_AUTHOR' => [ '@type' => 'xsd:string' ], // label: "usunął"
+			'A_RECORD_DELETE_DATE' => [ '@type' => 'xsd:date' ], // label: "usunięto"
 			// 'custom_field_name' => [ '@type' => 'p5:www_link' ],
 		]
 	];
@@ -71,49 +71,53 @@ class Schema_UserMsgsStorageAcl extends Core_AclSimpleSchemaBase {
 	public $idUser = null;
 	public $login = null;
 
-	public function __construct($simpleSchema = null) {
+	function __construct($simpleSchema = null) {
 		parent::__construct($simpleSchema);
 		$this->idUser = User::getID(); // default - current user
 		$this->login = User::getLogin();
 	}
 
-	public function setIdUser($idUser) { $this->idUser = intval($idUser); }
-	public function getIdUser() { return $this->idUser; }
+	function setIdUser($idUser) { $this->idUser = intval($idUser); }
+	function getIdUser() { return $this->idUser; }
 
-	public function getTotal($params = []) {
-		$sqlWhereAnd = $this->_parseSqlWhere($params);
-
-		$idGroupList = $this->_getUserIdGroupList();
-		if (empty($idGroupList)) throw new Exception("Brak przypisanych grup do użytkownika");
-		$sqlIdGroupsCsv = implode(",", $idGroupList);
+	function getTotal($params = []) {
+		$sqlWhere = $this->_parseSqlWhere($params);
 
 		return DB::getPDO()->fetchValue("
 			select count(1) as total
 			from `CRM_UI_MSGS` m
-			where m.`uiTargetType` = 'default_db_table_record'
-		--		and m.`uiTargetName` = '.'
-				and (
-					m.`userTargetType` in('everyone')
-					or ( m.`userTargetType`='user' and m.`userTargetName` = :login )
-					or ( m.`userTargetType`='group' and m.`userTargetName` in( {$sqlIdGroupsCsv} ) )
-				)
-				and m.`A_STATUS` in('WAITING', 'NORMAL')
-				{$sqlWhereAnd}
-		", [
-			':login' => $this->login,
-		]);
+			where {$sqlWhere}
+		");
 	}
 
-	public function _parseSqlWhere($params = []) {
-		$sqlWhereAnd = "";
+	function _parseSqlWhere($params = []) {
+		$sqlWhereAnd = [];
+
+		$sqlWhereAnd[] = " m.`uiTargetType` = 'default_db_table_record' ";
+
+		$sqlUserLogin = DB::getPDO()->quote($this->login);
+		$idGroupList = $this->_getUserIdGroupList();
+		if (empty($idGroupList)) throw new Exception("Brak przypisanych grup do użytkownika");
+		$sqlIdGroupsCsv = implode(",", $idGroupList);
+		$sqlWhereAnd[] = "
+			(
+				m.`userTargetType` in('everyone')
+				or ( m.`userTargetType`='user' and m.`userTargetName` = {$sqlUserLogin} )
+				or ( m.`userTargetType`='group' and m.`userTargetName` in( {$sqlIdGroupsCsv} ) )
+			)
+		";
+
+		$sqlWhereAnd[] = " m.`A_STATUS` in('WAITING', 'NORMAL') ";
+
 		// TODO: parse where/ogc, etc.
-		return $sqlWhereAnd;
+
+		return implode(" and ", $sqlWhereAnd);
 	}
 
-	public function getItems($params = []) {
+	function getItems($params = []) {
 		$sqlOrderBy = "";
 		$sqlLimitOffset = "";
-		$sqlWhereAnd = $this->_parseSqlWhere($params);
+		$sqlWhere = $this->_parseSqlWhere($params);
 
 		$currSortCol = V::get('order_by', 'ID', $params);
 		$currSortFlip = strtolower(V::get('order_dir', 'desc', $params));
@@ -138,10 +142,6 @@ class Schema_UserMsgsStorageAcl extends Core_AclSimpleSchemaBase {
 		$offset = ($offset < 0) ? 0 : $offset;
 		if ($limit > 0) $sqlLimitOffset = "limit {$limit} offset {$offset}";
 
-		$idGroupList = $this->_getUserIdGroupList();
-		if (empty($idGroupList)) throw new Exception("Brak przypisanych grup do użytkownika");
-		$sqlIdGroupsCsv = implode(",", $idGroupList);
-
 		$items = DB::getPDO()->fetchAllByKey("
 			select m.ID
 				, m.idReplyTo
@@ -157,50 +157,37 @@ class Schema_UserMsgsStorageAcl extends Core_AclSimpleSchemaBase {
 				, m.actionNotes
 				, m.A_STATUS
 				, m.actionNotes
-				, m.A_RECORD_CREATE_AUTHOR as `autor`
-				, m.A_RECORD_CREATE_DATE as `utworzono`
-				, m.A_RECORD_UPDATE_AUTHOR as `zaktualizował`
-				, m.A_RECORD_UPDATE_DATE as `zaktualizowano`
-				, m.A_RECORD_DELETE_AUTHOR as `usunął`
-				, m.A_RECORD_DELETE_DATE as `usunięto`
+				, m.A_RECORD_CREATE_AUTHOR
+				, m.A_RECORD_CREATE_DATE
+				, m.A_RECORD_UPDATE_AUTHOR
+				, m.A_RECORD_UPDATE_DATE
+				, m.A_RECORD_DELETE_AUTHOR
+				, m.A_RECORD_DELETE_DATE
 			from `CRM_UI_MSGS` m
-			where m.`uiTargetType` = 'default_db_table_record'
-		--		and m.`uiTargetName` = '.'
-				and (
-					m.`userTargetType` in('everyone')
-					or ( m.`userTargetType`='user' and m.`userTargetName` = :login )
-					or ( m.`userTargetType`='group' and m.`userTargetName` in( {$sqlIdGroupsCsv} ) )
-				)
-				and m.`A_STATUS` in('WAITING', 'NORMAL')
-				{$sqlWhereAnd}
+			where {$sqlWhere}
 			{$sqlOrderBy}
 			{$sqlLimitOffset}
-		", 'ID', [
-			':login' => $this->login,
-		]);
+		", 'ID');
 		// array_walk($items, function (&$item, $key) {
 		// 	$item['link_uruchom_filtr_procesu'] = Request::getPathUri() . "index.php?FUNCTION_INIT=MENU_SELECT_PROCES&_action=setPermsByProces&id_proces={$item['ID']}";
 		// });
 		return $items;
 	}
 
-	public function _getUserIdGroupList() {
-		return array_map(
-			function ($row) {
-				return $row['ID'];
-			}
-			, DB::getPDO()->fetchAll("
-				select z.ID
-				from `CRM_AUTH_PROFILE` as up
-					left join `CRM_LISTA_ZASOBOW` as z on(z.`ID`=up.`ID_ZASOB`)
-				where
-					up.`REMOTE_ID`='{$this->idUser}'
-					and up.`A_STATUS` in('WAITING', 'NORMAL')
-					and up.`REMOTE_TABLE`='ADMIN_USERS'
-					and z.`ID` is not null
-					and z.`TYPE` in('STANOWISKO','PODMIOT','DZIAL')
-			")
-		);
+	function _getUserIdGroupList() {
+		return DB::getPDO()->fetchValuesList("
+			select z.ID
+			from `CRM_AUTH_PROFILE` as up
+				left join `CRM_LISTA_ZASOBOW` as z on(z.`ID`=up.`ID_ZASOB`)
+			where
+				up.`REMOTE_ID` = :id_user
+				and up.`A_STATUS` in('WAITING', 'NORMAL')
+				and up.`REMOTE_TABLE`='ADMIN_USERS'
+				and z.`ID` is not null
+				and z.`TYPE` in('STANOWISKO','PODMIOT','DZIAL')
+		", [
+			':id_user' => $this->idUser,
+		]);
 	}
 
 }

+ 35 - 0
SE/se-lib/Schema/UserMsgsTrashStorageAcl.php

@@ -0,0 +1,35 @@
+<?php
+
+Lib::loadClass('Core_AclSimpleSchemaBase');
+Lib::loadClass('Schema_UserMsgsStorageAcl');
+Lib::loadClass('ParseOgcFilter');
+
+class Schema_UserMsgsTrashStorageAcl extends Schema_UserMsgsStorageAcl {
+
+	function _parseSqlWhere($params = []) {
+		$sqlWhereAnd = [];
+
+		$sqlWhereAnd[] = " m.`uiTargetType` = 'default_db_table_record' ";
+
+		$sqlUserLogin = DB::getPDO()->quote($this->login);
+		$idGroupList = $this->_getUserIdGroupList();
+		if (empty($idGroupList)) throw new Exception("Brak przypisanych grup do użytkownika");
+		$sqlIdGroupsCsv = implode(",", $idGroupList);
+		$sqlWhereAnd[] = "
+			(
+				m.`A_RECORD_CREATE_AUTHOR` = {$sqlUserLogin}
+				or (	m.`userTargetType` in('everyone')
+					or ( m.`userTargetType`='user' and m.`userTargetName` = {$sqlUserLogin} )
+					or ( m.`userTargetType`='group' and m.`userTargetName` in( {$sqlIdGroupsCsv} ) )
+				)
+			)
+		";
+
+		$sqlWhereAnd[] = " m.`A_STATUS` in('OFF_HARD', 'DELETED') ";
+
+		// TODO: parse where/ogc, etc.
+
+		return implode(" and ", $sqlWhereAnd);
+	}
+
+}

+ 1 - 3
SE/se-lib/tmpl/defaultPage.php

@@ -15,7 +15,7 @@
 	<?php elseif ('Partner' == User::getType()) : ?>
 
 		<p>Jesteś zalogowany jako <?php echo User::getFullName(); ?></p>
-		
+
 	<?php else : ?>
 
 		<?= UI::h('script', ['src'=>"static/vendor.js?v=71baa97d", 'type'=>"text/javascript"]); ?>
@@ -71,5 +71,3 @@
 	<?php endif; ?>
 
 </div>
-
-

+ 8 - 8
SE/se-lib/tmpl/defaultPage.php.widget-msgs.js

@@ -60,7 +60,6 @@ var P5UI__WidgetMsgs = createReactClass({
 		// ID: "985"
 		// actionExecutedTime: "2019-03-13 15:16:23"
 		// app_className: "TableMsgs"
-		// autor: "..."
 		// idReplyTo: "0"
 		// idThread: "0"
 		// msg: "..."
@@ -68,12 +67,13 @@ var P5UI__WidgetMsgs = createReactClass({
 		// uiTargetName: "IN7_DZIENNIK_KORESP.64417"
 		// uiTargetType: "default_db_table_record"
 		// userTargetType: "everyone"
-		// utworzono: "2019-03-13 14:58:22"
-		// zaktualizowano: "2019-03-13 15:16:23"
-		// zaktualizował: "..."
+		// A_RECORD_CREATE_AUTHOR: "..."
+		// A_RECORD_CREATE_DATE: "2019-03-13 14:58:22"
+		// A_RECORD_UPDATE_DATE: "2019-03-13 15:16:23"
+		// A_RECORD_UPDATE_AUTHOR: "..."
 		row._read = ('WAITING' != row.A_STATUS);
 		row._readByUser = ('WAITING' != row.A_STATUS);
-		if ('WAITING' == row.A_STATUS && USER_LOGIN == row.autor) {
+		if ('WAITING' == row.A_STATUS && USER_LOGIN == row.A_RECORD_CREATE_AUTHOR) {
 			if ('user' == row.userTargetType && USER_LOGIN == row.userTargetName) {
 				row._readByUser = false;
 			} else {
@@ -81,8 +81,8 @@ var P5UI__WidgetMsgs = createReactClass({
 			}
 		}
 		if (row._read) {
-			if (row.zaktualizowano) row._readDate = row.zaktualizowano;
-			if (row.zaktualizował) row._readBy = row.zaktualizował;
+			if (row.A_RECORD_UPDATE_DATE) row._readDate = row.A_RECORD_UPDATE_DATE;
+			if (row.A_RECORD_UPDATE_AUTHOR) row._readBy = row.A_RECORD_UPDATE_AUTHOR;
 		}
 
 		return h('div', {
@@ -100,7 +100,7 @@ var P5UI__WidgetMsgs = createReactClass({
 		}, [
 			row.msg,
 			h('div', { className: "text-muted", style: { fontStyle: "italic", fontSize: "x-small" } }, [
-				row.utworzono.substr(0, 10) + " od " + row.autor + " do " + this.renderMsgTo(row),
+				row.A_RECORD_CREATE_DATE.substr(0, 10) + " od " + row.A_RECORD_CREATE_AUTHOR + " do " + this.renderMsgTo(row),
 			]),
 		]);
 	},