eslint (additional rules)

This commit is contained in:
RainLoop Team 2016-06-30 03:02:45 +03:00
parent 77a1d3f3df
commit 8e8a041032
150 changed files with 21911 additions and 23106 deletions

View file

@ -1,77 +1,69 @@
(function () {
var
_ = require('_'),
ko = require('ko'),
'use strict';
Utils = require('Common/Utils'),
var
_ = require('_'),
ko = require('ko'),
AbstractModel = require('Knoin/AbstractModel');
Utils = require('Common/Utils'),
/**
* @constructor
* @param {string} sID
* @param {string} sName
* @param {string} sBody
*/
function TemplateModel(sID, sName, sBody)
{
AbstractModel.call(this, 'TemplateModel');
AbstractModel = require('Knoin/AbstractModel')
;
this.id = sID;
this.name = sName;
this.body = sBody;
this.populated = true;
/**
* @constructor
*
* @param {string} sID
* @param {string} sName
* @param {string} sBody
*/
function TemplateModel(sID, sName, sBody)
this.deleteAccess = ko.observable(false);
}
_.extend(TemplateModel.prototype, AbstractModel.prototype);
/**
* @type {string}
*/
TemplateModel.prototype.id = '';
/**
* @type {string}
*/
TemplateModel.prototype.name = '';
/**
* @type {string}
*/
TemplateModel.prototype.body = '';
/**
* @type {boolean}
*/
TemplateModel.prototype.populated = true;
/**
* @type {boolean}
*/
TemplateModel.prototype.parse = function(oItem)
{
var bResult = false;
if (oItem && 'Object/Template' === oItem['@Object'])
{
AbstractModel.call(this, 'TemplateModel');
this.id = Utils.pString(oItem.ID);
this.name = Utils.pString(oItem.Name);
this.body = Utils.pString(oItem.Body);
this.populated = !!oItem.Populated;
this.id = sID;
this.name = sName;
this.body = sBody;
this.populated = true;
this.deleteAccess = ko.observable(false);
bResult = true;
}
_.extend(TemplateModel.prototype, AbstractModel.prototype);
return bResult;
};
/**
* @type {string}
*/
TemplateModel.prototype.id = '';
/**
* @type {string}
*/
TemplateModel.prototype.name = '';
/**
* @type {string}
*/
TemplateModel.prototype.body = '';
/**
* @type {boolean}
*/
TemplateModel.prototype.populated = true;
/**
* @type {boolean}
*/
TemplateModel.prototype.parse = function (oItem)
{
var bResult = false;
if (oItem && 'Object/Template' === oItem['@Object'])
{
this.id = Utils.pString(oItem.ID);
this.name = Utils.pString(oItem.Name);
this.body = Utils.pString(oItem.Body);
this.populated = !!oItem.Populated;
bResult = true;
}
return bResult;
};
module.exports = TemplateModel;
}());
module.exports = TemplateModel;