Minor changes.
This commit is contained in:
parent
f97a4e490b
commit
1dd6e5c7b0
2 changed files with 10 additions and 15 deletions
|
@ -1,5 +1,5 @@
|
|||
|
||||
modulejs.define('model/entry', ['$', '_', 'config', 'core/types', 'core/event', 'core/settings', 'core/server', 'core/location'], function ($, _, config, types, event, settings, server, location) {
|
||||
modulejs.define('model/entry', ['_', 'core/types', 'core/event', 'core/settings', 'core/server', 'core/location'], function (_, types, event, settings, server, location) {
|
||||
|
||||
|
||||
var reEndsWithSlash = /\/$/,
|
||||
|
@ -129,14 +129,6 @@ modulejs.define('model/entry', ['$', '_', 'config', 'core/types', 'core/event',
|
|||
callback(self);
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
init = function () {
|
||||
|
||||
_.each(config.entries || [], function (entry) {
|
||||
|
||||
getEntry(entry.absHref, entry.time, entry.size, entry.status, entry.content);
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
|
@ -268,9 +260,6 @@ modulejs.define('model/entry', ['$', '_', 'config', 'core/types', 'core/event',
|
|||
}
|
||||
});
|
||||
|
||||
|
||||
init();
|
||||
|
||||
return {
|
||||
get: getEntry,
|
||||
remove: removeEntry
|
||||
|
|
|
@ -39,10 +39,16 @@
|
|||
|
||||
} else {
|
||||
|
||||
$.getJSON('.', {action: 'get', options: true, types: true, langs: true, server: true, entries: true}, function (config) {
|
||||
$.ajax({
|
||||
url: '.',
|
||||
data: {action: 'get', options: true, types: true, langs: true, server: true},
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
success: function (config) {
|
||||
|
||||
modulejs.define('config', config);
|
||||
$(function () { modulejs.require('main'); });
|
||||
modulejs.define('config', config);
|
||||
$(function () { modulejs.require('main'); });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue