"use strict";
|
cc._RF.push(module, '1abe1v1FFJFJbuyXQKjrfxE', 'exchange_model');
|
// Scripts/mod/exchange/exchange_model.js
|
|
"use strict";
|
|
// --------------------------------------------------------------------
|
// @author: xxx@syg.com(必填, 创建模块的人员)
|
// @description:
|
// 这里填写详细说明,主要填写该模块的功能简要
|
// <br/>Create: 2018-12-25 16:37:10
|
// --------------------------------------------------------------------
|
var ExchangeModel = cc.Class({
|
"extends": BaseClass,
|
ctor: function ctor() {},
|
properties: {},
|
initConfig: function initConfig() {
|
this.exchangeList = [];
|
},
|
setExchangeData: function setExchangeData(data) {
|
this.exchangeList = data.list;
|
},
|
getRedStatus: function getRedStatus() {
|
var status = false;
|
|
for (var i = 0; i < this.exchangeList.length; ++i) {
|
var v = this.exchangeList[i];
|
|
if (v.id == 1) {
|
if (v.max - v.num > 0) {
|
status = true;
|
}
|
|
break;
|
}
|
}
|
|
return status;
|
}
|
});
|
module.exports = ExchangeModel;
|
|
cc._RF.pop();
|