|
|
@@ -81,24 +81,16 @@ class Factory extends React.Component {
|
|
|
current: current,
|
|
|
next: next
|
|
|
};
|
|
|
- // 刷新
|
|
|
if (refresh.current) {
|
|
|
if (refresh.current.enable) {
|
|
|
this.refreshThis = setInterval(function () {
|
|
|
- this.getModelConfig(this.props.code[0] + '?kanbanCode=' + codes[this.index]);
|
|
|
- }.bind(this), refresh.current.interval * 1000 || 10000)
|
|
|
- }
|
|
|
- }
|
|
|
- // 切换
|
|
|
- if (refresh.next) {
|
|
|
- if (refresh.next.enable) {
|
|
|
- this.refreshNext = setInterval(function () {
|
|
|
if (this.index == codes.length - 1) {
|
|
|
this.index = 0;
|
|
|
} else {
|
|
|
this.index++;
|
|
|
}
|
|
|
- }.bind(this), refresh.next.interval * 1000 || 30000)
|
|
|
+ this.getModelConfig(this.props.code[0] + '?kanbanCode=' + codes[this.index]);
|
|
|
+ }.bind(this), refresh.current.interval * 1000 || 10000)
|
|
|
}
|
|
|
}
|
|
|
}
|