Commit 29b6eddd authored by Leo Iannacone's avatar Leo Iannacone

renamed data.package.archives in sources

parent 795ca2d4
......@@ -8,7 +8,7 @@ function __get_files_list_from_package(data, callback) {
utils.get_files_list(package_path, false, function(files) {
data.package.files = []
data.package.debs = []
data.package.archives = []
data.package.sources = []
files.forEach(function (f) {
file = {}
file.path = path.join(package_path, f).replace(config.debomatic.path, config.routes.debomatic)
......@@ -26,7 +26,7 @@ function __get_files_list_from_package(data, callback) {
file.name = file.extension
else if (f.indexOf('.tar') >= 0 && f.indexOf('.orig.') > 0)
file.name = 'orig.' + f.split('.orig.').pop()
data.package.archives.push(file)
data.package.sources.push(file)
}
else {
file.name = file.extension
......
......@@ -34,7 +34,7 @@ var Page_Distrubion = {
tmp.package = p
$('#packages ul').append('<li id="package-' + p.orig_name + '"><a href="' + Utils.from_data_to_hash(tmp) + '">'+ p.name + ' <span>'+p.version+'</span></a></li>')
})
Page_Distrubion.select()
Page_Distrubion.select(data)
},
clean: function () {
......@@ -87,11 +87,11 @@ var Page_Distrubion = {
$('#debs').show()
}
if (data.package.archives && data.package.archives.length > 0) {
data.package.archives.forEach(function(f){
$('#archives ul').append('<li><a title="'+ f.orig_name +'" href="' + f.path + '">' + f.name +'</a></li>')
if (data.package.sources && data.package.sources.length > 0) {
data.package.sources.forEach(function(f){
$('#sources ul').append('<li><a title="'+ f.orig_name +'" href="' + f.path + '">' + f.name +'</a></li>')
})
$('#archives').show()
$('#sources').show()
}
$('#files').show()
},
......@@ -100,8 +100,8 @@ var Page_Distrubion = {
$('#logs').hide()
$('#debs ul').html('');
$('#debs').hide();
$('#archives ul').html('')
$('#archives').hide()
$('#sources ul').html('')
$('#sources').hide()
$('#files').hide()
},
get: function (data) {
......
......@@ -16,8 +16,8 @@
<nav id="logs">
<ul class="nav nav-pills nav-stacked"></ul>
</nav>
<nav id="archives">
<h4>Archives</h4>
<nav id="sources">
<h4>Sources</h4>
<ul></ul>
</nav>
<nav id="debs">
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment