tinyscrollbar fixed
This commit is contained in:
parent
7ef02d3108
commit
c82e9a646d
|
@ -11,6 +11,12 @@
|
|||
// content-holder = "jquery dom", the returned html of server will be put inside the dom mentioned in content-holder of a tag. this can be used in a tags as attributes
|
||||
//confirm-message ="Some message", this will prompt user with a confirm box and show the message before ajax call is made.
|
||||
|
||||
//for layout tinyscrollbar
|
||||
//content-layout="datalist|column|simple" datalist is for data list from database.. column is usually for forms and some other pages.. simple is without any columns, the page will be displayed as it is.. base width will be considered the default width for tinyscrollbar
|
||||
//base-width="300" this is the basic width of each column and in case of simple layout it ll be the final width
|
||||
//per-column="5" this option is only for datalist layout.. this ll specify number of enteries per column.. default is 4
|
||||
//column="true" this option is only for column layout... the columns will be formed on this column=true attribute and it should be a div
|
||||
|
||||
|
||||
$.extend($.expr[':'], {
|
||||
'containsi': function (elem, i, match, array) {
|
||||
|
@ -163,8 +169,10 @@ var orbitDesktop = function(dom){
|
|||
if(typeof data == "string"){
|
||||
if(ca)
|
||||
$(ca).html(data);
|
||||
else
|
||||
$("div[container=true]").html(data);
|
||||
else{
|
||||
o.layout_data(data);
|
||||
// $("div[container=true]").html(data);
|
||||
}
|
||||
}
|
||||
if(exe)
|
||||
window.o[o.data_method][exe](data,$e);
|
||||
|
@ -251,6 +259,51 @@ var orbitDesktop = function(dom){
|
|||
})
|
||||
|
||||
};
|
||||
this.layout_data = function(h){
|
||||
var $e = $(h);
|
||||
var column_container = $e.find("div.overview");
|
||||
var layout = column_container.attr("content-layout"), base_width = parseInt(column_container.attr("base-width")), no_of_entries,temp_div = $("<div></div>"),total_columns=0;
|
||||
switch (layout){
|
||||
case "simple":
|
||||
total_columns++;
|
||||
temp_div.append(column_container.html());
|
||||
break;
|
||||
case "datalist":
|
||||
no_of_entries = (typeof column_container.attr("per-column") != "undefined"? column_container.attr("per-column") : 4);
|
||||
var entries = column_container.find("li"),x = 0;
|
||||
entries.each(function(i,li){
|
||||
if(x == 0){
|
||||
column = $("<div class='g_col list_t' style='width:"+base_width+"px'><ul></ul></div");
|
||||
total_columns++;
|
||||
}
|
||||
column.find("ul").append(li);
|
||||
x++;
|
||||
if(x == no_of_entries){
|
||||
x = 0;
|
||||
temp_div.append(column);
|
||||
}
|
||||
})
|
||||
break;
|
||||
case "column":
|
||||
var entries = column_container.find("div[column=true]"),x = 0,column;
|
||||
entries.each(function(i,ul){
|
||||
column = $("<div class='s_grid_con' style='width:"+base_width+"px'></div");
|
||||
total_columns++;
|
||||
column.append(ul);
|
||||
x++;
|
||||
temp_div.append(column);
|
||||
})
|
||||
break;
|
||||
}
|
||||
column_container.empty();
|
||||
$("div[container=true]").html(h);
|
||||
$("div[container=true] div.overview").html(temp_div.html());
|
||||
o.tinyscrollbar_ext({
|
||||
main : ".tinycanvas",
|
||||
fill : base_width * total_columns
|
||||
})
|
||||
|
||||
}
|
||||
this.menu_item = function(dom,customload,submenuitem){
|
||||
if(!customload)customload=false;
|
||||
var target = dom.attr("id");
|
||||
|
@ -310,7 +363,11 @@ var orbitDesktop = function(dom){
|
|||
this.sub_menu_item = function(dom){
|
||||
var sub_data_method = dom.attr('callback-method');
|
||||
if(sub_data_method){
|
||||
$("div[container=true]").load(dom.attr("href"),function(){
|
||||
$.ajax({
|
||||
url : dom.attr("href"),
|
||||
type : "get",
|
||||
success : function(data){
|
||||
o.layout_data(data);
|
||||
if(typeof o.data_method != "undefined"){
|
||||
if(o.data_method != ""){
|
||||
if(typeof sub_data_method != "undefined"){
|
||||
|
@ -320,7 +377,11 @@ var orbitDesktop = function(dom){
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
// $("div[container=true]").load(dom.attr("href"),function(data){
|
||||
|
||||
// })
|
||||
}
|
||||
$('*[content-type=menu] a').removeClass('thmc1 thmtxt active');
|
||||
dom.addClass('thmc1 thmtxt active');
|
||||
|
@ -765,9 +826,7 @@ var orbitDesktop = function(dom){
|
|||
},
|
||||
accept: '.to_drop'
|
||||
});
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas'
|
||||
})
|
||||
|
||||
|
||||
|
||||
};
|
||||
|
@ -1216,64 +1275,6 @@ var orbitDesktop = function(dom){
|
|||
bindHandlers();
|
||||
}
|
||||
|
||||
|
||||
this.initializeResearchDomain = function(target,url,cache){
|
||||
|
||||
this.initializeResearchDomain.list = function(){
|
||||
var bindHandlers = function(){
|
||||
o.tinyscrollbar_ext({
|
||||
main : ".tinycanvas",
|
||||
fill : ".list_t"
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
bindHandlers();
|
||||
|
||||
}
|
||||
this.initializeResearchDomain.add_this = function(){
|
||||
var bindHandlers = function(){
|
||||
|
||||
}
|
||||
|
||||
|
||||
bindHandlers();
|
||||
|
||||
}
|
||||
this.initializeResearchDomain.list();
|
||||
|
||||
}
|
||||
this.initializeResearchProject = function(target,url,cache){
|
||||
|
||||
this.initializeResearchProject.list = function(){
|
||||
var bindHandlers = function(){
|
||||
o.tinyscrollbar_ext({
|
||||
main : ".tinycanvas",
|
||||
fill : ".list_t"
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
bindHandlers();
|
||||
|
||||
}
|
||||
this.initializeResearchProject.add_this = function(){
|
||||
var bindHandlers = function(){
|
||||
o.simple_drop_down();
|
||||
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas',
|
||||
fill: '.s_grid_con'
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
bindHandlers();
|
||||
|
||||
}
|
||||
this.initializeResearchProject.list();
|
||||
|
||||
}
|
||||
this.loadWallpaper = function(wallpaper){ // this is to load new wallpaper
|
||||
if(!wallpaper)wallpapernm = o.themesettings.background;else wallpapernm = wallpaper
|
||||
var ww = $(window).width();
|
||||
|
@ -1338,6 +1339,7 @@ var orbitDesktop = function(dom){
|
|||
baseWidth = $(target.fill).eq(1).outerWidth(true);
|
||||
target.main.find('.overview').width( baseWidth * count);
|
||||
} else if( typeof target.fill == 'number' ){
|
||||
|
||||
target.main.find('.overview').width( target.fill );
|
||||
} else if( typeof target.fill == 'undefined' ){
|
||||
|
||||
|
|
|
@ -9,166 +9,8 @@
|
|||
<div class="tinycanvas">
|
||||
<div class="scrollbar sb_h"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div id="group_wrapper" class="overview">
|
||||
<!-- <div class="group">
|
||||
<div class="section_label" >
|
||||
<ul>
|
||||
<li class="element w1 h1 hp vp thmtxt"><span class="tile thmc1"></span><span class="thmtxt">section 1</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section2"><span class="tile thmc2 op06"></span><span class="thmtxt">section 2</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section3"><span class="tile thmc2 op06"></span><span class="thmtxt">section 3</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section4"><span class="tile thmc2 op06"></span><span class="thmtxt">section 4</span></li>
|
||||
</ul>
|
||||
</div>
|
||||
<ul class="grp" id="section1">
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<div id="group_wrapper" class="overview" content-layout="simple" base-width="3000">
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div class="group">
|
||||
<div class="section_label" >
|
||||
<ul>
|
||||
<li class="element w1 h1 hp vp thmtxt"><span class="tile thmc1"></span><span class="thmtxt">section 2</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section1"><span class="tile thmc2 op06"></span><span class="thmtxt">section 1</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section3"><span class="tile thmc2 op06"></span><span class="thmtxt">section 3</span></li>
|
||||
<li class="element w1 h1 hp vp thmtxt " style="display: none;" data-category="section4"><span class="tile thmc2 op06"></span><span class="thmtxt">section 4</span></li>
|
||||
</ul>
|
||||
</div>
|
||||
<ul class="grp" id="section2">
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
<li class="element w1 hh2 hp vp" data-category="abc">
|
||||
<h1 class="appname thmtxth">Garage Band</h1>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>-->
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<div class="tinycanvas vp">
|
||||
<div class="scrollbar sb_v hp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="simple" base-width="1000">
|
||||
<div class="s_title hh3">Section Names</div>
|
||||
<ul class="s_form" id="desktop_names">
|
||||
<li><label for="s_name1">Section 1</label><input id="s_name1" type="text" value=""></li>
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<div class="tinycanvas vp">
|
||||
<div class="scrollbar sb_v vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="simple" base-width="1000">
|
||||
<div id="st1" class="st_c">
|
||||
<div class="theme_list ssl">
|
||||
<% @themes.each do |theme| %>
|
||||
|
|
|
@ -68,7 +68,7 @@
|
|||
<div id="paper_list" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="datalist" per-column="5" base-width="300">
|
||||
<% @writing_conferences.each do |w| %>
|
||||
<%= publication_record w, @view_by%>
|
||||
<% end %>
|
||||
|
|
|
@ -13,11 +13,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
var bindHandlers = function(){ // to bind handlers for list page
|
||||
o.simple_drop_down();
|
||||
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas',
|
||||
fill: '.list_t'
|
||||
})
|
||||
|
||||
// $("#journal_selection_options a").click(function(){
|
||||
// switch($(this).attr("href")){
|
||||
// case "all":
|
||||
|
@ -29,26 +24,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
// }
|
||||
// return false;
|
||||
// })
|
||||
// $("#journal_view_selection a").click(function(){
|
||||
// switch($(this).attr("href")){
|
||||
// case "journal":
|
||||
// journalview();
|
||||
// break;
|
||||
// case "keywords":
|
||||
// keywordsview();
|
||||
// break;
|
||||
// case "title":
|
||||
// titleview();
|
||||
// break;
|
||||
// case "abstract":
|
||||
// abstractview();
|
||||
// break;
|
||||
// case "file":
|
||||
// fileview();
|
||||
// break;
|
||||
// }
|
||||
// return false;
|
||||
// })
|
||||
}
|
||||
|
||||
var bindSecondaryHandlers = function(){
|
||||
|
@ -65,125 +40,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
return false;
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
// var journalview = function(){
|
||||
// $("#journal_p div#paper_list div.overview").empty();
|
||||
// var column = $('<div class="g_col list_t"><ul></ul></div>'),
|
||||
// counter = 1,
|
||||
// li;
|
||||
// $.each(journalData,function(i,journal){
|
||||
// $.each(journal.papers,function(j,paper){
|
||||
// li = $('<li class="list_t_item"><div class="list_item_action"><a href="" class="icon-check-empty"></a><a href="" class="icon-star-empty"></a></div><div class="list_t_title">'+journal.title+'</div><div class="list_t_des">'+paper.title+'</div><div class="list_item_function"><a class="journal_paper_edit admbg2 admtxt" href="'+paper.url_edit+'" ajax-remote="get" >Edit</a> <a ajax-remote="delete" confirm-message="Are you sure?" callback-method="paperDelete" class="journal_paper_delete admbg2 admtxt" href="'+paper.url_delete+'">Delete</a></div></li>');
|
||||
// column.find("ul").append(li);
|
||||
// if(counter%5==0){
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// column = $('<div class="g_col list_t"><ul></ul></div>');
|
||||
// }
|
||||
// counter++;
|
||||
// })
|
||||
// })
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// bindSecondaryHandlers();
|
||||
// }
|
||||
// var fileview = function(){
|
||||
// $("#journal_p div#paper_list div.overview").empty();
|
||||
// var column = $('<div class="g_col list_t"><ul></ul></div>'),
|
||||
// counter = 1,
|
||||
// li = null;
|
||||
// $.each(journalData,function(i,journal){
|
||||
// $.each(journal.papers,function(j,paper){
|
||||
// li = null;
|
||||
// li = $('<li class="list_t_item file_view"></li>');
|
||||
// li.append('<div class="list_item_action"><a href="" class="icon-check-empty"></a><a href="" class="icon-star-empty"></a></div><div class="list_t_title">'+journal.title+'</div><div class="list_t_des"></div>');
|
||||
// var file_list = li.find('.list_t_des');
|
||||
// $.each(paper.files,function(k,file){
|
||||
// var thistitle = file.title;
|
||||
// if(!thistitle)
|
||||
// thistitle = "";
|
||||
// thistitle = ( thistitle.length > 8 )? thistitle.substring(0,8)+'...' : thistitle;
|
||||
// if(!file.title){
|
||||
// thistitle = "Untitled File";
|
||||
// }
|
||||
// var img = $('<a class="file" href="'+file.url+'" target="_blank" ><img src="'+file.icon+'" /><span class="filetitle">'+thistitle+'</span></a>');
|
||||
// file_list.append(img);
|
||||
// })
|
||||
// li.append('<div class="list_item_function"><a class="journal_paper_edit admbg2 admtxt" href="'+paper.url_edit+'" ajax-remote="get" >Edit</a> <a ajax-remote="delete" confirm-message="Are you sure?" callback-method="paperDelete" class="journal_paper_delete admbg2 admtxt" href="'+paper.url_delete+'">Delete</a></div>');
|
||||
// column.find("ul").append(li);
|
||||
// if(counter%3==0){
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// column = $('<div class="g_col list_t"><ul></ul></div>');
|
||||
// }
|
||||
// counter++;
|
||||
// })
|
||||
// })
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// bindSecondaryHandlers();
|
||||
// }
|
||||
// var keywordsview = function(){
|
||||
// $("#journal_p div#paper_list div.overview").empty();
|
||||
// var column = $('<div class="g_col list_t"><ul></ul></div>'),
|
||||
// counter = 1,
|
||||
// li;
|
||||
// $.each(journalData,function(i,journal){
|
||||
// $.each(journal.papers,function(j,paper){
|
||||
// li = $('<li class="list_t_item"><div class="list_item_action"><a href="" class="icon-check-empty"></a><a href="" class="icon-star-empty"></a></div><div class="list_t_title">'+paper.title+'</div><div class="list_t_des">'+paper.keywords+'</div><div class="list_item_function"><a class="journal_paper_edit admbg2 admtxt" href="'+paper.url_edit+'" ajax-remote="get" >Edit</a> <a ajax-remote="delete" confirm-message="Are you sure?" callback-method="paperDelete" class="journal_paper_delete admbg2 admtxt" href="'+paper.url_delete+'">Delete</a></div></li>');
|
||||
// column.find("ul").append(li);
|
||||
// if(counter%5==0){
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// column = $('<div class="g_col list_t"><ul></ul></div>');
|
||||
// }
|
||||
// counter++;
|
||||
// })
|
||||
// })
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// bindSecondaryHandlers();
|
||||
// }
|
||||
|
||||
// var titleview = function(){
|
||||
// $("#journal_p div#paper_list div.overview").empty();
|
||||
// var column = $('<div class="g_col list_t"><ul></ul></div>'),
|
||||
// counter = 1,
|
||||
// li;
|
||||
// $.each(journalData,function(i,journal){
|
||||
// $.each(journal.papers,function(j,paper){
|
||||
// li = $('<li class="list_t_item"><div class="list_item_action"><a href="" class="icon-check-empty"></a><a href="" class="icon-star-empty"></a></div><div class="list_t_title">'+paper.title+'</div><div class="list_item_function"><a class="journal_paper_edit admbg2 admtxt" href="'+paper.url_edit+'" ajax-remote="get" >Edit</a> <a ajax-remote="delete" confirm-message="Are you sure?" callback-method="paperDelete" class="journal_paper_delete admbg2 admtxt" href="'+paper.url_delete+'">Delete</a></div></li>');
|
||||
// column.find("ul").append(li);
|
||||
// if(counter%5==0){
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// column = $('<div class="g_col list_t"><ul></ul></div>');
|
||||
// }
|
||||
// counter++;
|
||||
// })
|
||||
// })
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// bindSecondaryHandlers();
|
||||
// }
|
||||
|
||||
// var abstractview = function(){
|
||||
// $("#journal_p div#paper_list div.overview").empty();
|
||||
// var column = $('<div class="g_col list_t"><ul></ul></div>'),
|
||||
// li;
|
||||
// $.each(journalData,function(i,journal){
|
||||
// $.each(journal.papers,function(j,paper){
|
||||
// li = $('<li class="list_t_item" style="height:auto;"><div class="list_item_action"><a href="" class="icon-check-empty"></a><a href="" class="icon-star-empty"></a></div><div class="list_t_title">'+paper.title+'</div><div class="list_t_des">'+paper.abstract+'</div><div class="list_item_function"><a class="journal_paper_edit admbg2 admtxt" href="'+paper.url_edit+'" ajax-remote="get" >Edit</a> <a ajax-remote="delete" confirm-message="Are you sure?" callback-method="paperDelete" class="journal_paper_delete admbg2 admtxt" href="'+paper.url_delete+'">Delete</a></div></li>');
|
||||
// column.find("ul").append(li);
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// column = $('<div class="g_col list_t"><ul></ul></div>');
|
||||
// })
|
||||
// })
|
||||
// $("#journal_p div#paper_list div.overview").append(column);
|
||||
// bindSecondaryHandlers();
|
||||
// }
|
||||
|
||||
// var getData = function(){
|
||||
// $.getJSON("/panel/personal_journal/desktop/get_journals_json",function(journals){
|
||||
// journalData = eval(journals);
|
||||
// journalview();
|
||||
// bindHandlers();
|
||||
// })
|
||||
// }
|
||||
// getData();
|
||||
}
|
||||
this.initializeJournalPapers.paperDelete = function(data,dom){
|
||||
var parent = dom.parent().parent();
|
||||
|
@ -195,11 +51,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
this.initializeJournalPapers.addpaper = function(){ // to open add pages in journal papers page
|
||||
var bindHandlers = function(){ // to bind handlers for add page
|
||||
o.simple_drop_down();
|
||||
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas',
|
||||
fill: '.s_grid_con'
|
||||
})
|
||||
}
|
||||
bindHandlers();
|
||||
}
|
||||
|
@ -207,10 +58,7 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
this.initializeJournalPapers.journal = function(){ // to open add pages in journal papers page
|
||||
var bindHandlers = function(){ // to bind handlers for add page
|
||||
o.simple_drop_down();
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas',
|
||||
fill: '.g_col'
|
||||
})
|
||||
|
||||
}
|
||||
bindHandlers();
|
||||
}
|
||||
|
@ -226,12 +74,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
|||
this.initializeJournalPapers.coauthor = function(){ // to open add pages in coauthor page
|
||||
var bindHandlers = function(){ // to bind handlers for add page
|
||||
o.simple_drop_down();
|
||||
|
||||
o.tinyscrollbar_ext({
|
||||
main: '.tinycanvas',
|
||||
fill: '.g_col'
|
||||
})
|
||||
|
||||
}
|
||||
bindHandlers();
|
||||
}
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<div id="co_author_relation_table" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="datalist" per-column="5" base-width="300">
|
||||
<%= render :partial => 'show_form'%>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<div id="co_author" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="datalist" per-column="5" base-width="300">
|
||||
<% @journal_co_authors.each_with_index do |co_author,i| %>
|
||||
<% if ( i % 4 ) == 0 %>
|
||||
<div class="g_col">
|
||||
|
|
|
@ -24,8 +24,9 @@
|
|||
<div id="paper_add" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="s_grid_con s_form">
|
||||
<div class="overview" content-layout="column" base-width="450">
|
||||
<div column="true">
|
||||
<div class="s_form">
|
||||
<ul>
|
||||
<li class="s_grid_row">
|
||||
<%= f.fields_for :paper_title_translations do |f| %>
|
||||
|
@ -85,7 +86,9 @@
|
|||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="s_grid_con s_form">
|
||||
</div>
|
||||
<div column="true">
|
||||
<div class="s_form">
|
||||
<ul>
|
||||
<li class="s_grid_row">
|
||||
<%= f.fields_for :authors_translations do |f| %>
|
||||
|
@ -158,7 +161,9 @@
|
|||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="s_grid_con s_form">
|
||||
</div>
|
||||
<div column="true">
|
||||
<div class="s_form">
|
||||
<ul>
|
||||
<li class="s_grid_row">
|
||||
<table class="s_table">
|
||||
|
@ -189,14 +194,18 @@
|
|||
</table>
|
||||
</li>
|
||||
</div>
|
||||
<div class="s_grid_con s_form">
|
||||
</div>
|
||||
<div column="true">
|
||||
<div class="s_form">
|
||||
<ul>
|
||||
<li class="s_grid_row">
|
||||
<%= f.text_area :note, size: "20x22", placeholder: t("personal_journal.note"), class: "s_grid_6 s_grid full_height"%>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="s_grid_con s_form">
|
||||
</div>
|
||||
<div column="true">
|
||||
<div class="s_form">
|
||||
<ul>
|
||||
<li class="s_grid_row">
|
||||
<%= f.text_area :abstract, size: "20x22", placeholder: t("personal_journal.abstract"), class: "s_grid_6 s_grid full_height"%>
|
||||
|
@ -206,6 +215,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
orbitDesktop.prototype.initializeJournalPapers.journal_title_autocomplete_list = <%= @journal_candidate.to_json.html_safe %>;
|
||||
orbitDesktop.prototype.initializeJournalPapers.coauthor_autocomplete_list = <%= @co_author_candidate.to_json.html_safe %>;
|
||||
|
|
|
@ -80,7 +80,7 @@
|
|||
<div id="paper_list" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="datalist" base-width="300" per-column="5">
|
||||
<% @writing_journals.each do |w| %>
|
||||
<%= publication_record w, @view_by%>
|
||||
<% end %>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<div id="journal_list" class="tinycanvas vp">
|
||||
<div class="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||
<div class="viewport">
|
||||
<div class="overview">
|
||||
<div class="overview" content-layout="datalist" base-width="300" per-column="5">
|
||||
<% @journal_lists.each_with_index do |journal_list,i| %>
|
||||
<% if ( i % 5 ) == 0 %>
|
||||
<div class="g_col">
|
||||
|
|
Loading…
Reference in New Issue