mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-13 17:05:43 +01:00
start rebuilding of bookmarkable functions
This commit is contained in:
@@ -116,8 +116,6 @@ Sonia.group.Grid = Ext.extend(Sonia.rest.Grid, {
|
|||||||
console.debug( group.name + ' selected' );
|
console.debug( group.name + ' selected' );
|
||||||
}
|
}
|
||||||
|
|
||||||
Sonia.History.append(group.name);
|
|
||||||
|
|
||||||
Ext.getCmp('groupRmButton').setDisabled(false);
|
Ext.getCmp('groupRmButton').setDisabled(false);
|
||||||
Sonia.group.setEditPanel([{
|
Sonia.group.setEditPanel([{
|
||||||
item: group,
|
item: group,
|
||||||
|
|||||||
@@ -34,7 +34,6 @@ Sonia.repository.ChangesetViewerPanel = Ext.extend(Ext.Panel, {
|
|||||||
repository: null,
|
repository: null,
|
||||||
start: 0,
|
start: 0,
|
||||||
pageSize: 20,
|
pageSize: 20,
|
||||||
historyId: null,
|
|
||||||
changesetStore: null,
|
changesetStore: null,
|
||||||
|
|
||||||
// parameters for file history view
|
// parameters for file history view
|
||||||
@@ -45,13 +44,6 @@ Sonia.repository.ChangesetViewerPanel = Ext.extend(Ext.Panel, {
|
|||||||
changesetViewerTitleText: 'Commits {0}',
|
changesetViewerTitleText: 'Commits {0}',
|
||||||
|
|
||||||
initComponent: function(){
|
initComponent: function(){
|
||||||
this.historyId = Sonia.History.createToken([
|
|
||||||
'changesetviewer',
|
|
||||||
this.repository.id,
|
|
||||||
this.start,
|
|
||||||
this.pageSize
|
|
||||||
]);
|
|
||||||
|
|
||||||
if (! this.url){
|
if (! this.url){
|
||||||
this.url = restUrl + 'repositories/' + this.repository.id + '/changesets.json';
|
this.url = restUrl + 'repositories/' + this.repository.id + '/changesets.json';
|
||||||
}
|
}
|
||||||
@@ -114,10 +106,7 @@ Sonia.repository.ChangesetViewerPanel = Ext.extend(Ext.Panel, {
|
|||||||
},
|
},
|
||||||
|
|
||||||
updateHistory: function(store, records, options){
|
updateHistory: function(store, records, options){
|
||||||
var id = Sonia.History.appendWithDepth([options.params.start, options.params.limit], 2);
|
|
||||||
if (id){
|
|
||||||
this.historyId = id;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
loadChangesets: function(start, limit){
|
loadChangesets: function(start, limit){
|
||||||
@@ -131,38 +120,3 @@ Sonia.repository.ChangesetViewerPanel = Ext.extend(Ext.Panel, {
|
|||||||
|
|
||||||
// register xtype
|
// register xtype
|
||||||
Ext.reg('repositoryChangesetViewerPanel', Sonia.repository.ChangesetViewerPanel);
|
Ext.reg('repositoryChangesetViewerPanel', Sonia.repository.ChangesetViewerPanel);
|
||||||
|
|
||||||
// register history handler
|
|
||||||
Sonia.History.register('changesetviewer', function(params){
|
|
||||||
|
|
||||||
if (params){
|
|
||||||
|
|
||||||
var id = params[0] + '-changesetViewer';
|
|
||||||
var start = Sonia.util.parseInt(params[1], 0);
|
|
||||||
var pageSize = Sonia.util.parseInt(params[2], 20);
|
|
||||||
|
|
||||||
if (debug){
|
|
||||||
console.debug('load changesetviewer for ' + id + ', ' + start + ', ' + pageSize );
|
|
||||||
}
|
|
||||||
|
|
||||||
var tab = Ext.getCmp(id);
|
|
||||||
|
|
||||||
if ( tab ){
|
|
||||||
main.getMainTabPanel().setActiveTab(id);
|
|
||||||
tab.loadChangesets(start, pageSize);
|
|
||||||
} else {
|
|
||||||
Sonia.repository.get(params[0], function(repository){
|
|
||||||
main.addTab({
|
|
||||||
id: repository.id + '-changesetViewer',
|
|
||||||
xtype: 'repositoryChangesetViewerPanel',
|
|
||||||
repository: repository,
|
|
||||||
start: start,
|
|
||||||
pageSize: pageSize,
|
|
||||||
closable: true
|
|
||||||
})
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
});
|
|
||||||
|
|||||||
@@ -42,6 +42,9 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
|
|||||||
searchValue: null,
|
searchValue: null,
|
||||||
typeFilter: null,
|
typeFilter: null,
|
||||||
|
|
||||||
|
// for history
|
||||||
|
parentPanel: null,
|
||||||
|
|
||||||
initComponent: function(){
|
initComponent: function(){
|
||||||
|
|
||||||
var repositoryStore = new Sonia.rest.JsonStore({
|
var repositoryStore = new Sonia.rest.JsonStore({
|
||||||
@@ -93,6 +96,10 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
|
|||||||
|
|
||||||
Ext.apply(this, Ext.apply(this.initialConfig, config));
|
Ext.apply(this, Ext.apply(this.initialConfig, config));
|
||||||
Sonia.repository.Grid.superclass.initComponent.apply(this, arguments);
|
Sonia.repository.Grid.superclass.initComponent.apply(this, arguments);
|
||||||
|
|
||||||
|
if (this.parentPanel){
|
||||||
|
this.parentPanel.repositoryGrid = this;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
storeLoad: function(){
|
storeLoad: function(){
|
||||||
@@ -152,7 +159,9 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
|
|||||||
console.debug( item.name + ' selected' );
|
console.debug( item.name + ' selected' );
|
||||||
}
|
}
|
||||||
|
|
||||||
Sonia.History.append(item.id);
|
if ( this.parentPanel ){
|
||||||
|
this.parentPanel.updateHistory(item);
|
||||||
|
}
|
||||||
|
|
||||||
var infoPanel = main.getInfoPanel(item.type);
|
var infoPanel = main.getInfoPanel(item.type);
|
||||||
infoPanel.item = item;
|
infoPanel.item = item;
|
||||||
|
|||||||
@@ -39,6 +39,8 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
errorTitleText: 'Error',
|
errorTitleText: 'Error',
|
||||||
errorMsgText: 'Repository deletion failed',
|
errorMsgText: 'Repository deletion failed',
|
||||||
|
|
||||||
|
repositoryGrid: null,
|
||||||
|
|
||||||
initComponent: function(){
|
initComponent: function(){
|
||||||
|
|
||||||
// create new store for repository types
|
// create new store for repository types
|
||||||
@@ -128,7 +130,8 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
items: [{
|
items: [{
|
||||||
id: 'repositoryGrid',
|
id: 'repositoryGrid',
|
||||||
xtype: 'repositoryGrid',
|
xtype: 'repositoryGrid',
|
||||||
region: 'center'
|
region: 'center',
|
||||||
|
parentPanel: this
|
||||||
},{
|
},{
|
||||||
id: 'repositoryEditPanel',
|
id: 'repositoryEditPanel',
|
||||||
xtype: 'tabpanel',
|
xtype: 'tabpanel',
|
||||||
@@ -143,24 +146,38 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
padding: 5,
|
padding: 5,
|
||||||
html: this.emptyText
|
html: this.emptyText
|
||||||
}]
|
}]
|
||||||
}
|
}]
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Ext.apply(this, Ext.apply(this.initialConfig, config));
|
Ext.apply(this, Ext.apply(this.initialConfig, config));
|
||||||
Sonia.repository.Panel.superclass.initComponent.apply(this, arguments);
|
Sonia.repository.Panel.superclass.initComponent.apply(this, arguments);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
getGrid: function(){
|
||||||
|
if ( ! this.repositoryGrid ){
|
||||||
|
if ( debug ){
|
||||||
|
console.debug('repository grid not found, retrive by cmp id');
|
||||||
|
}
|
||||||
|
this.repositoryGrid = Ext.getCmp('repositoryGrid');
|
||||||
|
}
|
||||||
|
return this.repositoryGrid;
|
||||||
|
},
|
||||||
|
|
||||||
|
updateHistory: function(item){
|
||||||
|
var token = Sonia.History.createToken(['repositoryPanel', item.id]);
|
||||||
|
Sonia.History.add(token);
|
||||||
|
},
|
||||||
|
|
||||||
filterByType: function(combo, rec){
|
filterByType: function(combo, rec){
|
||||||
Ext.getCmp('repositoryGrid').filter(rec.get('name'));
|
this.getGrid().filter(rec.get('name'));
|
||||||
},
|
},
|
||||||
|
|
||||||
search: function(field){
|
search: function(field){
|
||||||
Ext.getCmp('repositoryGrid').search(field.getValue());
|
this.getGrid().search(field.getValue());
|
||||||
},
|
},
|
||||||
|
|
||||||
removeRepository: function(){
|
removeRepository: function(){
|
||||||
var grid = Ext.getCmp('repositoryGrid');
|
var grid = this.getGrid();
|
||||||
var selected = grid.getSelectionModel().getSelected();
|
var selected = grid.getSelectionModel().getSelected();
|
||||||
if ( selected ){
|
if ( selected ){
|
||||||
var item = selected.data;
|
var item = selected.data;
|
||||||
@@ -227,7 +244,7 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
},
|
},
|
||||||
|
|
||||||
repositoryCreated: function(item){
|
repositoryCreated: function(item){
|
||||||
var grid = Ext.getCmp('repositoryGrid');
|
var grid = this.getGrid();
|
||||||
this.clearRepositoryFilter(grid);
|
this.clearRepositoryFilter(grid);
|
||||||
|
|
||||||
grid.reload(function(){
|
grid.reload(function(){
|
||||||
@@ -243,7 +260,7 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
console.debug('clear repository filter');
|
console.debug('clear repository filter');
|
||||||
}
|
}
|
||||||
if (! grid ){
|
if (! grid ){
|
||||||
grid = Ext.getCmp('repositoryGrid');
|
grid = this.getGrid();
|
||||||
}
|
}
|
||||||
Ext.getCmp('repositorySearch').setValue('');
|
Ext.getCmp('repositorySearch').setValue('');
|
||||||
Ext.getCmp('repositoryTypeFilter').setValue('');
|
Ext.getCmp('repositoryTypeFilter').setValue('');
|
||||||
@@ -251,10 +268,36 @@ Sonia.repository.Panel = Ext.extend(Sonia.rest.Panel, {
|
|||||||
},
|
},
|
||||||
|
|
||||||
reload: function(){
|
reload: function(){
|
||||||
Ext.getCmp('repositoryGrid').reload();
|
this.getGrid().reload();
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// register xtype
|
// register xtype
|
||||||
Ext.reg('repositoryPanel', Sonia.repository.Panel);
|
Ext.reg('repositoryPanel', Sonia.repository.Panel);
|
||||||
|
|
||||||
|
// register history handler
|
||||||
|
Sonia.History.register('repositoryPanel', {
|
||||||
|
|
||||||
|
onActivate: function(panel){
|
||||||
|
var token = null;
|
||||||
|
var rec = panel.getGrid().getSelectionModel().getSelected();
|
||||||
|
if ( rec != null ){
|
||||||
|
token = Sonia.History.createToken('repositoryPanel', rec.get('id'));
|
||||||
|
} else {
|
||||||
|
token = Sonia.History.createToken('repositoryPanel');
|
||||||
|
}
|
||||||
|
return token;
|
||||||
|
},
|
||||||
|
|
||||||
|
onChange: function(repoId){
|
||||||
|
var panel = Ext.getCmp('repositories');
|
||||||
|
if ( ! panel ){
|
||||||
|
main.addRepositoriesTabPanel();
|
||||||
|
panel = Ext.getCmp('repositories');
|
||||||
|
}
|
||||||
|
if (repoId){
|
||||||
|
panel.getGrid().selectById(repoId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
@@ -32,7 +32,6 @@ Sonia.repository.RepositoryBrowser = Ext.extend(Ext.grid.GridPanel, {
|
|||||||
|
|
||||||
repository: null,
|
repository: null,
|
||||||
revision: null,
|
revision: null,
|
||||||
historyId: null,
|
|
||||||
path: null,
|
path: null,
|
||||||
|
|
||||||
repositoryBrowserTitleText: 'Source {0}',
|
repositoryBrowserTitleText: 'Source {0}',
|
||||||
@@ -50,12 +49,6 @@ Sonia.repository.RepositoryBrowser = Ext.extend(Ext.grid.GridPanel, {
|
|||||||
console.debug('create new browser for repository ' + this.repository.name + " and revision " + this.revision);
|
console.debug('create new browser for repository ' + this.repository.name + " and revision " + this.revision);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.historyId = Sonia.History.createToken([
|
|
||||||
'repositorybrowser',
|
|
||||||
this.repository.id,
|
|
||||||
this.revision ? this.revision : '_'
|
|
||||||
]);
|
|
||||||
|
|
||||||
var browserStore = new Sonia.rest.JsonStore({
|
var browserStore = new Sonia.rest.JsonStore({
|
||||||
proxy: new Ext.data.HttpProxy({
|
proxy: new Ext.data.HttpProxy({
|
||||||
url: restUrl + 'repositories/' + this.repository.id + '/browse.json',
|
url: restUrl + 'repositories/' + this.repository.id + '/browse.json',
|
||||||
@@ -174,22 +167,6 @@ Sonia.repository.RepositoryBrowser = Ext.extend(Ext.grid.GridPanel, {
|
|||||||
length: 0
|
length: 0
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
var historyParams = [];
|
|
||||||
if ( this.revision ){
|
|
||||||
historyParams.push(this.revision)
|
|
||||||
} else {
|
|
||||||
historyParams.push('_');
|
|
||||||
}
|
|
||||||
|
|
||||||
if ( extra.params.path ){
|
|
||||||
historyParams.push(extra.params.path);
|
|
||||||
}
|
|
||||||
|
|
||||||
var id = Sonia.History.appendWithDepth(historyParams, 2);
|
|
||||||
if (id){
|
|
||||||
this.historyId = id;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
onClick: function(e){
|
onClick: function(e){
|
||||||
@@ -318,41 +295,3 @@ Sonia.repository.RepositoryBrowser = Ext.extend(Ext.grid.GridPanel, {
|
|||||||
|
|
||||||
// register xtype
|
// register xtype
|
||||||
Ext.reg('repositoryBrowser', Sonia.repository.RepositoryBrowser);
|
Ext.reg('repositoryBrowser', Sonia.repository.RepositoryBrowser);
|
||||||
|
|
||||||
// register history handler
|
|
||||||
Sonia.History.register('repositorybrowser', function(params){
|
|
||||||
|
|
||||||
if (params){
|
|
||||||
|
|
||||||
var id = 'repositorybrowser-' + params[0] + ':';
|
|
||||||
var revision = params[1];
|
|
||||||
id += revision;
|
|
||||||
var path = params[2] ? params[2] : '';
|
|
||||||
|
|
||||||
if ( revision == '_' ){
|
|
||||||
revision = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (debug){
|
|
||||||
console.debug('load repositorybrowser for ' + id + ', ' + revision + ', ' + path );
|
|
||||||
}
|
|
||||||
|
|
||||||
var tab = Ext.getCmp(id);
|
|
||||||
|
|
||||||
if ( tab ){
|
|
||||||
main.getMainTabPanel().setActiveTab(id);
|
|
||||||
tab.changeDirectory(path);
|
|
||||||
} else {
|
|
||||||
Sonia.repository.get(params[0], function(repository){
|
|
||||||
main.addTab({
|
|
||||||
id: id,
|
|
||||||
xtype: 'repositoryBrowser',
|
|
||||||
repository: repository,
|
|
||||||
revision: revision,
|
|
||||||
path: path,
|
|
||||||
closable: true
|
|
||||||
})
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
@@ -117,6 +117,20 @@ Sonia.History = {
|
|||||||
return invokeable;
|
return invokeable;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
onActivate: function(tab){
|
||||||
|
if (tab){
|
||||||
|
var el = this.historyElements[tab.xtype];
|
||||||
|
if (el){
|
||||||
|
var token = Sonia.util.apply(el.onActivate, tab);
|
||||||
|
if (token){
|
||||||
|
this.add(token);
|
||||||
|
}
|
||||||
|
} else if (debug) {
|
||||||
|
console.debug('could not find xtype ' + tab.xtype);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
onChange: function(token){
|
onChange: function(token){
|
||||||
if (!this.initialized){
|
if (!this.initialized){
|
||||||
this.initialized = true;
|
this.initialized = true;
|
||||||
@@ -133,17 +147,13 @@ Sonia.History = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
handleChange: function(id, params){
|
handleChange: function(id, p){
|
||||||
var el = this.historyElements[id];
|
var el = this.historyElements[id];
|
||||||
if (el){
|
if (el){
|
||||||
if (debug){
|
if (debug){
|
||||||
console.debug('handle history event for ' + id + ' with "' + params + '"');
|
console.debug('handle history event for ' + id + ' with "' + p + '"');
|
||||||
}
|
|
||||||
if (Ext.isFunction(el) ){
|
|
||||||
el(params);
|
|
||||||
} else {
|
|
||||||
el.fn.call(el.scope, params);
|
|
||||||
}
|
}
|
||||||
|
Sonia.util.apply(el.onChange, p);
|
||||||
} else if (Ext.ComponentMgr.isRegistered(id)) {
|
} else if (Ext.ComponentMgr.isRegistered(id)) {
|
||||||
try {
|
try {
|
||||||
main.addTabPanel(id);
|
main.addTabPanel(id);
|
||||||
|
|||||||
@@ -74,7 +74,6 @@ Sonia.scm.Main = Ext.extend(Ext.util.Observable, {
|
|||||||
this.addEvents('login', 'logout', 'init');
|
this.addEvents('login', 'logout', 'init');
|
||||||
this.mainTabPanel = Ext.getCmp('mainTabPanel');
|
this.mainTabPanel = Ext.getCmp('mainTabPanel');
|
||||||
this.addListener('login', this.postLogin, this);
|
this.addListener('login', this.postLogin, this);
|
||||||
this.createHistory();
|
|
||||||
Sonia.scm.Main.superclass.constructor.call(this, config);
|
Sonia.scm.Main.superclass.constructor.call(this, config);
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -152,39 +151,6 @@ Sonia.scm.Main = Ext.extend(Ext.util.Observable, {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
createHistory: function(){
|
|
||||||
Sonia.History.register('repositories', function(params){
|
|
||||||
this.addRepositoriesTabPanel();
|
|
||||||
var grid = Ext.getCmp('repositoryGrid');
|
|
||||||
if (grid){
|
|
||||||
grid.handleHistory(params);
|
|
||||||
} else if (debug){
|
|
||||||
console.debug('could not find repository grid');
|
|
||||||
}
|
|
||||||
}, this);
|
|
||||||
Sonia.History.register('scmConfig', this.addScmConfigTabPanel, this);
|
|
||||||
Sonia.History.register('repositoryConfig', this.addRepositoryConfigTabPanel, this);
|
|
||||||
Sonia.History.register('plugins', this.addPluginTabPanel, this);
|
|
||||||
Sonia.History.register('users', function(params){
|
|
||||||
this.addUsersTabPanel();
|
|
||||||
var grid = Ext.getCmp('userGrid');
|
|
||||||
if (grid){
|
|
||||||
grid.handleHistory(params);
|
|
||||||
} else if (debug){
|
|
||||||
console.debug('could not find user grid');
|
|
||||||
}
|
|
||||||
}, this);
|
|
||||||
Sonia.History.register('groups', function(params){
|
|
||||||
this.addGroupsTabPanel();
|
|
||||||
var grid = Ext.getCmp('groupGrid');
|
|
||||||
if (grid){
|
|
||||||
grid.handleHistory(params);
|
|
||||||
} else if (debug){
|
|
||||||
console.debug('could not find group grid');
|
|
||||||
}
|
|
||||||
}, this);
|
|
||||||
},
|
|
||||||
|
|
||||||
createMainMenu: function(){
|
createMainMenu: function(){
|
||||||
if ( debug ){
|
if ( debug ){
|
||||||
console.debug('create main menu');
|
console.debug('create main menu');
|
||||||
@@ -510,10 +476,7 @@ Ext.onReady(function(){
|
|||||||
listeners: {
|
listeners: {
|
||||||
tabchange: function(tabPanel, tab){
|
tabchange: function(tabPanel, tab){
|
||||||
if ( Ext.isDefined(tab) ){
|
if ( Ext.isDefined(tab) ){
|
||||||
var id = tab.historyId ? tab.historyId : tab.id;
|
Sonia.History.onActivate(tab);
|
||||||
if (id){
|
|
||||||
Sonia.History.add(id, true);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -90,6 +90,40 @@ Sonia.util.getStringFromArray = function(array){
|
|||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Sonia.util.applySub = function(obj, name, p){
|
||||||
|
if (name){
|
||||||
|
obj = obj[name];
|
||||||
|
}
|
||||||
|
return Sonia.util.call(obj, p);
|
||||||
|
}
|
||||||
|
|
||||||
|
Sonia.util.apply = function(obj, p){
|
||||||
|
var result = null;
|
||||||
|
// use call instead of apply for compatiblity
|
||||||
|
if (Ext.isFunction(obj)) {
|
||||||
|
if (p){
|
||||||
|
if (Ext.isArray(p)){
|
||||||
|
result = obj(p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9]);
|
||||||
|
} else {
|
||||||
|
result = obj(p);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
result = obj();
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (p){
|
||||||
|
if ( Ext.isArray(p) ){
|
||||||
|
obj.fn.call(obj.scope, p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9]);
|
||||||
|
} else {
|
||||||
|
obj.fn.call(obj.scope, p);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
obj.fn.call(obj.scope);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
if (!Array.prototype.filter) {
|
if (!Array.prototype.filter) {
|
||||||
|
|
||||||
Array.prototype.filter = function(fn, scope){
|
Array.prototype.filter = function(fn, scope){
|
||||||
|
|||||||
Reference in New Issue
Block a user