tinyscrollbar fixed
This commit is contained in:
parent
0f12314213
commit
23c8c28b52
|
@ -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
|
// 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.
|
//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[':'], {
|
$.extend($.expr[':'], {
|
||||||
'containsi': function (elem, i, match, array) {
|
'containsi': function (elem, i, match, array) {
|
||||||
|
@ -163,8 +169,10 @@ var orbitDesktop = function(dom){
|
||||||
if(typeof data == "string"){
|
if(typeof data == "string"){
|
||||||
if(ca)
|
if(ca)
|
||||||
$(ca).html(data);
|
$(ca).html(data);
|
||||||
else
|
else{
|
||||||
$("div[container=true]").html(data);
|
o.layout_data(data);
|
||||||
|
// $("div[container=true]").html(data);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if(exe)
|
if(exe)
|
||||||
window.o[o.data_method][exe](data,$e);
|
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){
|
this.menu_item = function(dom,customload,submenuitem){
|
||||||
if(!customload)customload=false;
|
if(!customload)customload=false;
|
||||||
var target = dom.attr("id");
|
var target = dom.attr("id");
|
||||||
|
@ -310,17 +363,25 @@ var orbitDesktop = function(dom){
|
||||||
this.sub_menu_item = function(dom){
|
this.sub_menu_item = function(dom){
|
||||||
var sub_data_method = dom.attr('callback-method');
|
var sub_data_method = dom.attr('callback-method');
|
||||||
if(sub_data_method){
|
if(sub_data_method){
|
||||||
$("div[container=true]").load(dom.attr("href"),function(){
|
$.ajax({
|
||||||
if(typeof o.data_method != "undefined"){
|
url : dom.attr("href"),
|
||||||
if(o.data_method != ""){
|
type : "get",
|
||||||
if(typeof sub_data_method != "undefined"){
|
success : function(data){
|
||||||
if(sub_data_method != ""){
|
o.layout_data(data);
|
||||||
window.o[o.data_method][sub_data_method]();
|
if(typeof o.data_method != "undefined"){
|
||||||
|
if(o.data_method != ""){
|
||||||
|
if(typeof sub_data_method != "undefined"){
|
||||||
|
if(sub_data_method != ""){
|
||||||
|
window.o[o.data_method][sub_data_method]();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
// $("div[container=true]").load(dom.attr("href"),function(data){
|
||||||
|
|
||||||
|
// })
|
||||||
}
|
}
|
||||||
$('*[content-type=menu] a').removeClass('thmc1 thmtxt active');
|
$('*[content-type=menu] a').removeClass('thmc1 thmtxt active');
|
||||||
dom.addClass('thmc1 thmtxt active');
|
dom.addClass('thmc1 thmtxt active');
|
||||||
|
@ -765,9 +826,7 @@ var orbitDesktop = function(dom){
|
||||||
},
|
},
|
||||||
accept: '.to_drop'
|
accept: '.to_drop'
|
||||||
});
|
});
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas'
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
@ -1216,64 +1275,6 @@ var orbitDesktop = function(dom){
|
||||||
bindHandlers();
|
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
|
this.loadWallpaper = function(wallpaper){ // this is to load new wallpaper
|
||||||
if(!wallpaper)wallpapernm = o.themesettings.background;else wallpapernm = wallpaper
|
if(!wallpaper)wallpapernm = o.themesettings.background;else wallpapernm = wallpaper
|
||||||
var ww = $(window).width();
|
var ww = $(window).width();
|
||||||
|
@ -1338,6 +1339,7 @@ var orbitDesktop = function(dom){
|
||||||
baseWidth = $(target.fill).eq(1).outerWidth(true);
|
baseWidth = $(target.fill).eq(1).outerWidth(true);
|
||||||
target.main.find('.overview').width( baseWidth * count);
|
target.main.find('.overview').width( baseWidth * count);
|
||||||
} else if( typeof target.fill == 'number' ){
|
} else if( typeof target.fill == 'number' ){
|
||||||
|
|
||||||
target.main.find('.overview').width( target.fill );
|
target.main.find('.overview').width( target.fill );
|
||||||
} else if( typeof target.fill == 'undefined' ){
|
} else if( typeof target.fill == 'undefined' ){
|
||||||
|
|
||||||
|
|
|
@ -9,167 +9,9 @@
|
||||||
<div class="tinycanvas">
|
<div class="tinycanvas">
|
||||||
<div class="scrollbar sb_h"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
<div class="scrollbar sb_h"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div id="group_wrapper" class="overview">
|
<div id="group_wrapper" class="overview" content-layout="simple" base-width="3000">
|
||||||
<!-- <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 class="clear"></div>
|
||||||
</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>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<div class="tinycanvas vp">
|
<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="scrollbar sb_v hp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="simple" base-width="1000">
|
||||||
<div class="s_title hh3">Section Names</div>
|
<div class="s_title hh3">Section Names</div>
|
||||||
<ul class="s_form" id="desktop_names">
|
<ul class="s_form" id="desktop_names">
|
||||||
<li><label for="s_name1">Section 1</label><input id="s_name1" type="text" value=""></li>
|
<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="tinycanvas vp">
|
||||||
<div class="scrollbar sb_v vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
<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="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="simple" base-width="1000">
|
||||||
<div id="st1" class="st_c">
|
<div id="st1" class="st_c">
|
||||||
<div class="theme_list ssl">
|
<div class="theme_list ssl">
|
||||||
<% @themes.each do |theme| %>
|
<% @themes.each do |theme| %>
|
||||||
|
|
|
@ -68,7 +68,7 @@
|
||||||
<div id="paper_list" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="datalist" per-column="5" base-width="300">
|
||||||
<% @writing_conferences.each do |w| %>
|
<% @writing_conferences.each do |w| %>
|
||||||
<%= publication_record w, @view_by%>
|
<%= publication_record w, @view_by%>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
|
@ -13,11 +13,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
||||||
var bindHandlers = function(){ // to bind handlers for list page
|
var bindHandlers = function(){ // to bind handlers for list page
|
||||||
o.simple_drop_down();
|
o.simple_drop_down();
|
||||||
|
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas',
|
|
||||||
fill: '.list_t'
|
|
||||||
})
|
|
||||||
|
|
||||||
// $("#journal_selection_options a").click(function(){
|
// $("#journal_selection_options a").click(function(){
|
||||||
// switch($(this).attr("href")){
|
// switch($(this).attr("href")){
|
||||||
// case "all":
|
// case "all":
|
||||||
|
@ -29,26 +24,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
||||||
// }
|
// }
|
||||||
// return false;
|
// 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(){
|
var bindSecondaryHandlers = function(){
|
||||||
|
@ -65,125 +40,6 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
||||||
return false;
|
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){
|
this.initializeJournalPapers.paperDelete = function(data,dom){
|
||||||
var parent = dom.parent().parent();
|
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
|
this.initializeJournalPapers.addpaper = function(){ // to open add pages in journal papers page
|
||||||
var bindHandlers = function(){ // to bind handlers for add page
|
var bindHandlers = function(){ // to bind handlers for add page
|
||||||
o.simple_drop_down();
|
o.simple_drop_down();
|
||||||
|
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas',
|
|
||||||
fill: '.s_grid_con'
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
}
|
}
|
||||||
|
@ -207,10 +58,7 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
||||||
this.initializeJournalPapers.journal = function(){ // to open add pages in journal papers page
|
this.initializeJournalPapers.journal = function(){ // to open add pages in journal papers page
|
||||||
var bindHandlers = function(){ // to bind handlers for add page
|
var bindHandlers = function(){ // to bind handlers for add page
|
||||||
o.simple_drop_down();
|
o.simple_drop_down();
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas',
|
|
||||||
fill: '.g_col'
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
}
|
}
|
||||||
|
@ -226,13 +74,7 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ //
|
||||||
this.initializeJournalPapers.coauthor = function(){ // to open add pages in coauthor page
|
this.initializeJournalPapers.coauthor = function(){ // to open add pages in coauthor page
|
||||||
var bindHandlers = function(){ // to bind handlers for add page
|
var bindHandlers = function(){ // to bind handlers for add page
|
||||||
o.simple_drop_down();
|
o.simple_drop_down();
|
||||||
|
}
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas',
|
|
||||||
fill: '.g_col'
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
}
|
}
|
||||||
this.initializeJournalPapers.coauthorRelationForm = function(data){
|
this.initializeJournalPapers.coauthorRelationForm = function(data){
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
<div id="co_author_relation_table" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="datalist" per-column="5" base-width="300">
|
||||||
<%= render :partial => 'show_form'%>
|
<%= render :partial => 'show_form'%>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
<div id="co_author" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<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| %>
|
<% @journal_co_authors.each_with_index do |co_author,i| %>
|
||||||
<% if ( i % 4 ) == 0 %>
|
<% if ( i % 4 ) == 0 %>
|
||||||
<div class="g_col">
|
<div class="g_col">
|
||||||
|
|
|
@ -24,8 +24,9 @@
|
||||||
<div id="paper_add" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="column" base-width="450">
|
||||||
<div class="s_grid_con s_form">
|
<div column="true">
|
||||||
|
<div class="s_form">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="s_grid_row">
|
<li class="s_grid_row">
|
||||||
<%= f.fields_for :paper_title_translations do |f| %>
|
<%= f.fields_for :paper_title_translations do |f| %>
|
||||||
|
@ -85,7 +86,9 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="s_grid_con s_form">
|
</div>
|
||||||
|
<div column="true">
|
||||||
|
<div class="s_form">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="s_grid_row">
|
<li class="s_grid_row">
|
||||||
<%= f.fields_for :authors_translations do |f| %>
|
<%= f.fields_for :authors_translations do |f| %>
|
||||||
|
@ -158,7 +161,9 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="s_grid_con s_form">
|
</div>
|
||||||
|
<div column="true">
|
||||||
|
<div class="s_form">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="s_grid_row">
|
<li class="s_grid_row">
|
||||||
<table class="s_table">
|
<table class="s_table">
|
||||||
|
@ -189,14 +194,18 @@
|
||||||
</table>
|
</table>
|
||||||
</li>
|
</li>
|
||||||
</div>
|
</div>
|
||||||
<div class="s_grid_con s_form">
|
</div>
|
||||||
|
<div column="true">
|
||||||
|
<div class="s_form">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="s_grid_row">
|
<li class="s_grid_row">
|
||||||
<%= f.text_area :note, size: "20x22", placeholder: t("personal_journal.note"), class: "s_grid_6 s_grid full_height"%>
|
<%= f.text_area :note, size: "20x22", placeholder: t("personal_journal.note"), class: "s_grid_6 s_grid full_height"%>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="s_grid_con s_form">
|
</div>
|
||||||
|
<div column="true">
|
||||||
|
<div class="s_form">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="s_grid_row">
|
<li class="s_grid_row">
|
||||||
<%= f.text_area :abstract, size: "20x22", placeholder: t("personal_journal.abstract"), class: "s_grid_6 s_grid full_height"%>
|
<%= f.text_area :abstract, size: "20x22", placeholder: t("personal_journal.abstract"), class: "s_grid_6 s_grid full_height"%>
|
||||||
|
@ -204,6 +213,7 @@
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
|
@ -80,7 +80,7 @@
|
||||||
<div id="paper_list" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<div class="viewport">
|
||||||
<div class="overview">
|
<div class="overview" content-layout="datalist" base-width="300" per-column="5">
|
||||||
<% @writing_journals.each do |w| %>
|
<% @writing_journals.each do |w| %>
|
||||||
<%= publication_record w, @view_by%>
|
<%= publication_record w, @view_by%>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
<div id="journal_list" class="tinycanvas vp">
|
<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="scrollbar sb_h vp"><div class="track"><div class="thumb thmc2"><div class="end"></div></div></div></div>
|
||||||
<div class="viewport">
|
<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| %>
|
<% @journal_lists.each_with_index do |journal_list,i| %>
|
||||||
<% if ( i % 5 ) == 0 %>
|
<% if ( i % 5 ) == 0 %>
|
||||||
<div class="g_col">
|
<div class="g_col">
|
||||||
|
|
Reference in New Issue