SmartIT_Extensions/BMC/smart-it-full-helix/scripts/app/knowledge-console/knowledge-console-item-vo.js

51 lines
1.2 KiB
JavaScript

"use strict";
/**
* Value object for assignment item.
*
* @author Victor Shevchenko
* @author Igor Samulenko
*
* @constructor
*/
function KnowledgeConsoleItemVO() {
this.articleId = '';
this.title = '';
this.type = '';
this.language = '';
this.version = '';
this.assignee = '';
this.owner = '';
this.tags = '';
this.favorite = '';
this.flagged = '';
this.internal = '';
this.service = '';
this.createDate = '';
this.modifiedDate = '';
this.templateName = '';
this.organization = '';
this.validateCompany = false;
this.articleModifiedDate = '';
// complex fields
this.company = {};
this.author = {};
this.assignee = {};
this.statusValue = {};
this.assignedGroup = {};
}
// inherit BaseVO
KnowledgeConsoleItemVO.prototype = new BaseVO();
// correct the constructor pointer
KnowledgeConsoleItemVO.prototype.constructor = KnowledgeConsoleItemVO;
/**
* @override
* @return {Array}
*/
KnowledgeConsoleItemVO.prototype.getProps = function () {
var keys = Object.keys(new KnowledgeConsoleItemVO());
return BaseVO.prototype.getProps().concat(keys);
};
KnowledgeConsoleItemVO.prototype.postBuild = function () {
this.supportGroup = this.assignedGroup;
};