Fix plugins registration
This commit is contained in:
parent
a78dceb1a3
commit
6bd9d991ee
|
@ -204,17 +204,7 @@ define([
|
|||
arr = [];
|
||||
storePlugins.each(function(item){
|
||||
var plugin = new Asc.CPlugin();
|
||||
plugin.deserialize(item.attributes);
|
||||
|
||||
var variations = item.get('variations'),
|
||||
variationsArr = [];
|
||||
variations.forEach(function(itemVar){
|
||||
var variation = new Asc.CPluginVariation();
|
||||
variation.deserialize(itemVar.attributes);
|
||||
variationsArr.push(variation);
|
||||
});
|
||||
|
||||
plugin.set_Variations(variationsArr);
|
||||
plugin.deserialize(item.get('original'));
|
||||
item.set('pluginObj', plugin);
|
||||
arr.push(plugin);
|
||||
});
|
||||
|
@ -562,7 +552,8 @@ define([
|
|||
visible: pluginVisible,
|
||||
groupName: (item.group) ? item.group.name : '',
|
||||
groupRank: (item.group) ? item.group.rank : 0,
|
||||
minVersion: item.minVersion
|
||||
minVersion: item.minVersion,
|
||||
original: item
|
||||
}));
|
||||
}
|
||||
});
|
||||
|
|
|
@ -133,17 +133,7 @@ define([
|
|||
arr = [];
|
||||
storePlugins.each(function(item){
|
||||
var plugin = new Asc.CPlugin();
|
||||
plugin.deserialize(item.attributes);
|
||||
|
||||
var variations = item.get('variations'),
|
||||
variationsArr = [];
|
||||
variations.forEach(function(itemVar){
|
||||
var variation = new Asc.CPluginVariation();
|
||||
variation.deserialize(itemVar.attributes);
|
||||
variationsArr.push(variation);
|
||||
});
|
||||
|
||||
plugin.set_Variations(variationsArr);
|
||||
plugin.deserialize(item.get('original'));
|
||||
item.set('pluginObj', plugin);
|
||||
arr.push(plugin);
|
||||
});
|
||||
|
@ -332,7 +322,8 @@ define([
|
|||
visible: pluginVisible,
|
||||
groupName: (item.group) ? item.group.name : '',
|
||||
groupRank: (item.group) ? item.group.rank : 0,
|
||||
minVersion: item.minVersion
|
||||
minVersion: item.minVersion,
|
||||
original: item
|
||||
}));
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue