Compare commits
104
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
caf0426bd4 | ||
|
|
7d077a92a5 | ||
|
|
64101109dd | ||
|
|
3e567223e3 | ||
|
|
79ef86f2c9 | ||
|
|
d047a3d62a | ||
|
|
2945e14385 | ||
|
|
c68c563fb0 | ||
|
|
697944a029 | ||
|
|
12e39b4d77 | ||
|
|
a0478f2a8f | ||
|
|
b198b1a17b | ||
|
|
62fa589e8a | ||
|
|
5ff7dfbac6 | ||
|
|
11067ef34f | ||
|
|
536f0d30af | ||
|
|
41168f4c99 | ||
|
|
7e9fce0c2d | ||
|
|
2416030adc | ||
|
|
38d5a193e0 | ||
|
|
fcfdd562a6 | ||
|
|
989e5aa974 | ||
|
|
4cbf2fd8b9 | ||
|
|
c94a86c3a4 | ||
|
|
aedab01ae6 | ||
|
|
e3782c9cf7 | ||
|
|
e2802d94d0 | ||
|
|
055d758769 | ||
|
|
0734f73291 | ||
|
|
a4ebe31ada | ||
|
|
3098496083 | ||
|
|
28f0df5da8 | ||
|
|
3de4591413 | ||
|
|
d177fe0369 | ||
|
|
d288972035 | ||
|
|
c6868bf2e0 | ||
|
|
95e308e046 | ||
|
|
425a320c02 | ||
|
|
dc5f24ab22 | ||
|
|
bc0477a5ed | ||
|
|
0781779ac0 | ||
|
|
e7bffe4c0f | ||
|
|
dd10b3147c | ||
|
|
cae43e8acd | ||
|
|
793d739726 | ||
|
|
c8aa50ee87 | ||
|
|
0f6f5aafce | ||
|
|
f6b600df59 | ||
|
|
6af375efa4 | ||
|
|
1709773b0a | ||
|
|
95805cfdee | ||
|
|
84afbfa86c | ||
|
|
44fede2b71 | ||
|
|
764f83d58c | ||
|
|
8dee211ab4 | ||
|
|
27ad25ccca | ||
|
|
f9e7cefc94 | ||
|
|
df220397b2 | ||
|
|
b5fd6c7a1a | ||
|
|
65e306a854 | ||
|
|
41643d1f61 | ||
|
|
aad4119892 | ||
|
|
54af5e8bd4 | ||
|
|
6db9e70132 | ||
|
|
dabceec3ea | ||
|
|
52789fa032 | ||
|
|
dc68f40cb4 | ||
|
|
228dd1b767 | ||
|
|
dae3f069ff | ||
|
|
5f2c669568 | ||
|
|
1b12412596 | ||
|
|
b1d7d5345e | ||
|
|
6efef253a6 | ||
|
|
0d5ab20efa | ||
|
|
9815950083 | ||
|
|
50449b55e8 | ||
|
|
00db66b8c4 | ||
|
|
b8ee2fd559 | ||
|
|
401c75c0de | ||
|
|
1ebae504dc | ||
|
|
323fadc210 | ||
|
|
69a49a69aa | ||
|
|
5178ce3bde | ||
|
|
95128a3465 | ||
|
|
8783b8e5fe | ||
|
|
a3de4cc2d4 | ||
|
|
bdaef3af0f | ||
|
|
625f2e9ad6 | ||
|
|
db60a3bcfa | ||
|
|
a7667d586a | ||
|
|
e9ddb85734 | ||
|
|
d840b82fa9 | ||
|
|
84dfb44e78 | ||
|
|
4a08a1992b | ||
|
|
15be80a35f | ||
|
|
1d06bcaae7 | ||
|
|
8e98cb3ec9 | ||
|
|
6cd97adf21 | ||
|
|
0189d1c2c0 | ||
|
|
3e96cfe514 | ||
|
|
468555a037 | ||
|
|
da8a5123c2 | ||
|
|
4ebc8cbb77 | ||
|
|
ec1605358b |
No files matched your search
@@ -18,3 +18,6 @@ uploads/**/*
|
|||||||
*.swp
|
*.swp
|
||||||
*.pid
|
*.pid
|
||||||
*.lck
|
*.lck
|
||||||
|
|
||||||
|
.sass-cache/*
|
||||||
|
*.supported
|
||||||
@@ -26,6 +26,7 @@ gem "mongo_session_store-rails3", '3.0.6'
|
|||||||
gem 'nokogiri'
|
gem 'nokogiri'
|
||||||
|
|
||||||
gem 'fb_graph'
|
gem 'fb_graph'
|
||||||
|
gem 'rack-gridfs'
|
||||||
gem 'radius'
|
gem 'radius'
|
||||||
gem 'rake'
|
gem 'rake'
|
||||||
# gem 'remotipart'
|
# gem 'remotipart'
|
||||||
|
|||||||
@@ -194,6 +194,10 @@ GEM
|
|||||||
rack (1.4.5)
|
rack (1.4.5)
|
||||||
rack-cache (1.2)
|
rack-cache (1.2)
|
||||||
rack (>= 0.4)
|
rack (>= 0.4)
|
||||||
|
rack-gridfs (0.4.1)
|
||||||
|
mime-types
|
||||||
|
mongo (~> 1.2)
|
||||||
|
rack
|
||||||
rack-oauth2 (1.0.0)
|
rack-oauth2 (1.0.0)
|
||||||
activesupport (>= 2.3)
|
activesupport (>= 2.3)
|
||||||
attr_required (>= 0.0.5)
|
attr_required (>= 0.0.5)
|
||||||
@@ -373,6 +377,7 @@ DEPENDENCIES
|
|||||||
pry-debugger
|
pry-debugger
|
||||||
pry-remote
|
pry-remote
|
||||||
pry-stack_explorer
|
pry-stack_explorer
|
||||||
|
rack-gridfs
|
||||||
radius
|
radius
|
||||||
rails (~> 3.2.9)
|
rails (~> 3.2.9)
|
||||||
rake
|
rake
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 613 B After Width: | Height: | Size: 824 B |
@@ -0,0 +1,34 @@
|
|||||||
|
function append_id(){
|
||||||
|
if ($("#object_id").length == 1) {
|
||||||
|
return "&id="+$("#object_id").val();
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
return '';
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
$("#page_design").live('change', function() {
|
||||||
|
$.getScript($(this).attr('rel') + '?design_id=' + $(this).val() + append_id());
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
$("#module_app_list select").live('change', function() {
|
||||||
|
$.getScript($(this).attr('rel') + '?module_app_id='+$(this).val() + append_id());
|
||||||
|
});
|
||||||
|
|
||||||
|
$("#widget_list select,#frontend_list select").live('change', function() {
|
||||||
|
$.getScript($(this).attr('rel') +'?frontend=' + $(this).val() + '&module_app_id=' + $("#module_app_list select").val() + append_id() );
|
||||||
|
});
|
||||||
|
|
||||||
|
$("#tag_list select").live('change', function() {
|
||||||
|
$.getScript($(this).attr('rel') + '?type=' + $(this).val() + append_id() );
|
||||||
|
});
|
||||||
|
|
||||||
|
$("select.widget_field_select").live('change', function() {
|
||||||
|
$.getScript($(this).attr('rel') + '?widget_field_value='+ $(this).val()+'&dom_id=' + $(this).attr("id") + '&field_seri=' +$(this).attr('field_seri')+ '&module_app_id=' +$("#page_module_app_id,page_part_module_app_id").val() + append_id() );
|
||||||
|
});
|
||||||
|
|
||||||
|
$('.part_kind').live('click', function() {
|
||||||
|
$('.part_kind_partial').hide();
|
||||||
|
$('#part_' + $(this).attr('value')).show();
|
||||||
|
});
|
||||||
@@ -108,7 +108,7 @@ var orbitDesktop = function(dom){
|
|||||||
this.contentHolder = dom;
|
this.contentHolder = dom;
|
||||||
this.themesettings = "";
|
this.themesettings = "";
|
||||||
this.theme = "4f8d3f493b67fcd05f086359";
|
this.theme = "4f8d3f493b67fcd05f086359";
|
||||||
this.transitionTime = 500;
|
this.transitionTime = 1000;
|
||||||
this.currenthtml = "desktop.html";
|
this.currenthtml = "desktop.html";
|
||||||
this.currentface = "home";
|
this.currentface = "home";
|
||||||
this.desktopData = {};
|
this.desktopData = {};
|
||||||
@@ -135,7 +135,7 @@ var orbitDesktop = function(dom){
|
|||||||
o.theme = theme;
|
o.theme = theme;
|
||||||
loadTheme(desktopSettings.customtheme,desktopSettings.wallpaper);
|
loadTheme(desktopSettings.customtheme,desktopSettings.wallpaper);
|
||||||
}else{loadTheme();}
|
}else{loadTheme();}
|
||||||
})
|
});
|
||||||
var loadTheme = function(customtheme,customwallpaper){ //This function will load the theme from database
|
var loadTheme = function(customtheme,customwallpaper){ //This function will load the theme from database
|
||||||
$.getJSON("/"+o.themefolder+"/"+theme+"/settings/"+theme+".json",function(ts){
|
$.getJSON("/"+o.themefolder+"/"+theme+"/settings/"+theme+".json",function(ts){
|
||||||
o.themesettings = eval(ts);
|
o.themesettings = eval(ts);
|
||||||
@@ -160,8 +160,8 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
}
|
};
|
||||||
}
|
};
|
||||||
this.customPage = function(customload){
|
this.customPage = function(customload){
|
||||||
customload = customload.replace("#","");
|
customload = customload.replace("#","");
|
||||||
if(customload.search("-") != -1){
|
if(customload.search("-") != -1){
|
||||||
@@ -170,7 +170,7 @@ var orbitDesktop = function(dom){
|
|||||||
}else{
|
}else{
|
||||||
o.menu_item($(".docklist a[custom-load="+customload+"]"),true);
|
o.menu_item($(".docklist a[custom-load="+customload+"]"),true);
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
this.changeTheme = function(theme){ // this function is used for changing theme
|
this.changeTheme = function(theme){ // this function is used for changing theme
|
||||||
o.theme = theme;
|
o.theme = theme;
|
||||||
$.getJSON("/"+o.themefolder+"/"+theme+"/settings/"+theme+".json",function(ts){
|
$.getJSON("/"+o.themefolder+"/"+theme+"/settings/"+theme+".json",function(ts){
|
||||||
@@ -189,9 +189,9 @@ var orbitDesktop = function(dom){
|
|||||||
$.getJSON("http://maps.googleapis.com/maps/api/geocode/json?latlng="+o.locationdata.lat+","+o.locationdata.lng+"&sensor=true",function(data){
|
$.getJSON("http://maps.googleapis.com/maps/api/geocode/json?latlng="+o.locationdata.lat+","+o.locationdata.lng+"&sensor=true",function(data){
|
||||||
$.each(data.results[0].address_components,function(i,val){
|
$.each(data.results[0].address_components,function(i,val){
|
||||||
o.locationdata[val.types[0]] = val.long_name;
|
o.locationdata[val.types[0]] = val.long_name;
|
||||||
})
|
});
|
||||||
o.locationdata.formatted_address = data.results[0].formatted_address;
|
o.locationdata.formatted_address = data.results[0].formatted_address;
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
var locationError = function(){
|
var locationError = function(){
|
||||||
@@ -211,7 +211,7 @@ var orbitDesktop = function(dom){
|
|||||||
$(".docklist a").click(function(){
|
$(".docklist a").click(function(){
|
||||||
o.menu_item($(this));
|
o.menu_item($(this));
|
||||||
return false;
|
return false;
|
||||||
})
|
});
|
||||||
|
|
||||||
|
|
||||||
$('body').on({
|
$('body').on({
|
||||||
@@ -254,7 +254,7 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
$(this).ajaxSubmit(options);
|
$(this).ajaxSubmit(options);
|
||||||
return false;
|
return false;
|
||||||
})
|
});
|
||||||
|
|
||||||
$("body").on("click","*[ajax-remote]",function(){
|
$("body").on("click","*[ajax-remote]",function(){
|
||||||
var $e = $(this);
|
var $e = $(this);
|
||||||
@@ -310,11 +310,11 @@ var orbitDesktop = function(dom){
|
|||||||
a();
|
a();
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
})
|
});
|
||||||
|
|
||||||
$(window).resize(function(){
|
$(window).resize(function(){
|
||||||
var ww = $(window).width();
|
// var ww = $(window).width();
|
||||||
$("img#thmbackground").attr({"width":ww});
|
// $("img#thmbackground").attr({"width":ww});
|
||||||
if( $('.tinycanvas').length > 0 ){ $('.tinycanvas').tinyscrollbar_update('relative'); }
|
if( $('.tinycanvas').length > 0 ){ $('.tinycanvas').tinyscrollbar_update('relative'); }
|
||||||
if($(o.contentHolder).find("div.app_frame").length > 0){
|
if($(o.contentHolder).find("div.app_frame").length > 0){
|
||||||
$(o.contentHolder).find("div.app_frame").each(function(){
|
$(o.contentHolder).find("div.app_frame").each(function(){
|
||||||
@@ -322,7 +322,7 @@ var orbitDesktop = function(dom){
|
|||||||
var app_holder_width = $(this).width();
|
var app_holder_width = $(this).width();
|
||||||
$(this).find("div.app_holder").height(app_holder_height);
|
$(this).find("div.app_holder").height(app_holder_height);
|
||||||
$(this).find("div.app_holder iframe").attr({"height":app_holder_height,"width":app_holder_width});
|
$(this).find("div.app_holder iframe").attr({"height":app_holder_height,"width":app_holder_width});
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -372,14 +372,14 @@ var orbitDesktop = function(dom){
|
|||||||
this.value = terms.join( ", " );
|
this.value = terms.join( ", " );
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
this.layout_data = function(h){
|
this.layout_data = function(h){
|
||||||
var $e;
|
var $e;
|
||||||
var column_container,layout, base_width , no_of_entries = 0, pagination_link , pagination_variable, gutter, total_width;
|
var column_container,layout, base_width, total_width, gutter, no_of_entries = 0, pagination_link, pagination_variable;
|
||||||
o.paging = true;
|
o.paging = true;
|
||||||
gutter = (!isNaN(gutter)) ? gutter : 12;
|
gutter = (!isNaN(gutter)) ? gutter : 12;
|
||||||
this.layout_data.generate_layout_html = function(l){
|
this.layout_data.generate_layout_html = function(l){
|
||||||
@@ -393,7 +393,6 @@ var orbitDesktop = function(dom){
|
|||||||
case "simple":
|
case "simple":
|
||||||
total_columns++;
|
total_columns++;
|
||||||
temp_div.append(column_container.html());
|
temp_div.append(column_container.html());
|
||||||
total_width = "auto";
|
|
||||||
break;
|
break;
|
||||||
case "datalist":
|
case "datalist":
|
||||||
no_of_entries = (typeof column_container.attr("per-column") != "undefined"? parseInt(column_container.attr("per-column")) : 4);
|
no_of_entries = (typeof column_container.attr("per-column") != "undefined"? parseInt(column_container.attr("per-column")) : 4);
|
||||||
@@ -412,10 +411,7 @@ var orbitDesktop = function(dom){
|
|||||||
x = 0;
|
x = 0;
|
||||||
temp_div.append(column);
|
temp_div.append(column);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
if(x != 0){
|
|
||||||
temp_div.append(column);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
total_width = (!isNaN(base_width)) ? (base_width + gutter*2 +1) * total_columns : null;
|
total_width = (!isNaN(base_width)) ? (base_width + gutter*2 +1) * total_columns : null;
|
||||||
break;
|
break;
|
||||||
@@ -428,11 +424,12 @@ var orbitDesktop = function(dom){
|
|||||||
column.append(ul);
|
column.append(ul);
|
||||||
x++;
|
x++;
|
||||||
temp_div.append(column);
|
temp_div.append(column);
|
||||||
})
|
});
|
||||||
total_width = (!isNaN(base_width)) ? (base_width + gutter*2 +1) * total_columns : null;
|
|
||||||
}
|
}
|
||||||
|
total_width = (!isNaN(base_width)) ? (base_width + gutter*2 +1) * total_columns : null;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// total_width = (!isNaN(base_width) ? ( base_width + 12 ) * total_columns : null);
|
// total_width = (!isNaN(base_width) ? ( base_width + 12 ) * total_columns : null);
|
||||||
@@ -473,20 +470,22 @@ var orbitDesktop = function(dom){
|
|||||||
var f = o.layout_data.generate_layout_html(html);
|
var f = o.layout_data.generate_layout_html(html);
|
||||||
// console.log(f.total)
|
// console.log(f.total)
|
||||||
if(f.total > 0){
|
if(f.total > 0){
|
||||||
$("div[container=true] div.overview").append(f.markup);
|
$("div[container=true] .overview").append(f.markup);
|
||||||
if(f.width){
|
if(f.width){
|
||||||
var w = $("div[container=true] div.overview").width();
|
var w = $("div[container=true] .overview").width();
|
||||||
$("div[container=true] div.overview").width(w+f.width);
|
$("div[container=true] .overview").width(w+f.width);
|
||||||
}
|
}
|
||||||
o.tinyscrollbar.tinyscrollbar_update("relative");
|
o.tinyscrollbar.tinyscrollbar_update("relative");
|
||||||
o.paging = true;
|
o.paging = true;
|
||||||
}else{o.paging = false;}
|
} else {
|
||||||
|
o.paging = false;
|
||||||
}
|
}
|
||||||
})
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
this.insert_new_column = function(index){
|
this.insert_new_column = function(index){
|
||||||
var column_container = $("div[container=true] div.overview"),layout = column_container.attr("content-layout"),base_width = parseInt(column_container.attr("base-width")),column;
|
var column_container = $("div[container=true] .overview"),layout = column_container.attr("content-layout"),base_width = parseInt(column_container.attr("base-width")),column;
|
||||||
var i = (index == 0? 0 : index-1);
|
var i = (index == 0? 0 : index-1);
|
||||||
var previous_column = column_container.find(".column").eq(i);
|
var previous_column = column_container.find(".column").eq(i);
|
||||||
if(previous_column.length == 0)return false;
|
if(previous_column.length == 0)return false;
|
||||||
@@ -515,7 +514,7 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.remove_column = function(index){
|
this.remove_column = function(index){
|
||||||
var column_container = $("div[container=true] div.overview"),layout = column_container.attr("content-layout"),column = column_container.find(".column").eq(index),base_width = parseInt(column_container.attr("base-width"));
|
var column_container = $("div[container=true] .overview"),layout = column_container.attr("content-layout"),column = column_container.find(".column").eq(index),base_width = parseInt(column_container.attr("base-width"));
|
||||||
if(column.length == 0)return false;
|
if(column.length == 0)return false;
|
||||||
switch(layout){
|
switch(layout){
|
||||||
case "datalist":
|
case "datalist":
|
||||||
@@ -542,52 +541,69 @@ var orbitDesktop = function(dom){
|
|||||||
o.lastlink = url;
|
o.lastlink = url;
|
||||||
o.data_method = dom.attr("callback-method");
|
o.data_method = dom.attr("callback-method");
|
||||||
if(o.currenthtml!=target){
|
if(o.currenthtml!=target){
|
||||||
if(o.desktopData[o.currentface] == "undefined")
|
if(o.desktopData[o.currentface] == "undefined"){
|
||||||
o.desktopData[o.currentface] = "";
|
o.desktopData[o.currentface] = "";
|
||||||
|
}
|
||||||
o.desktopData[o.currentface] = $(o.contentHolder).html();
|
o.desktopData[o.currentface] = $(o.contentHolder).html();
|
||||||
if(customload){
|
if(customload){
|
||||||
$(o.contentHolder).html("<div id='content'></div>");
|
$(o.contentHolder).html("<div id='content'></div>");
|
||||||
}
|
}
|
||||||
$("#content").hide("drop",o.transitionTime,function(){
|
$("#content > #holder").toggle("drop",{ easing: "easeInOutQuint" },o.transitionTime,function(){
|
||||||
o.currenthtml = target;
|
o.currenthtml = target;
|
||||||
o.currentface = target;
|
o.currentface = target;
|
||||||
var cache = false;
|
var cache = false;
|
||||||
if(!o.desktopData[o.currentface]){
|
if(!o.desktopData[o.currentface]){
|
||||||
$(o.contentHolder).empty().load(url,function(data){
|
$(o.contentHolder).empty().load(url,function(data){
|
||||||
if(typeof o.data_method != "undefined"){
|
if(typeof o.data_method != "undefined"){
|
||||||
if(o.data_method != "")
|
if(o.data_method != ""){
|
||||||
window.o[o.data_method](target,url,cache);
|
window.o[o.data_method](target,url,cache);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
if(!customload)
|
if(!customload){
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
||||||
else{
|
} else {
|
||||||
if(submenuitem)
|
if(submenuitem){
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
|
||||||
else
|
} else {
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} catch(EX){}
|
} catch(EX){}
|
||||||
|
header_ani();
|
||||||
})
|
});
|
||||||
}else{
|
}else{
|
||||||
$(o.contentHolder).html(o.desktopData[o.currentface]);
|
$(o.contentHolder).html(o.desktopData[o.currentface]);
|
||||||
try{
|
try{
|
||||||
if(!customload)
|
if(!customload){
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"));
|
||||||
else{
|
}else{
|
||||||
if(submenuitem)
|
if(submenuitem)
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
|
||||||
else
|
else
|
||||||
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
|
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"));
|
||||||
}
|
}
|
||||||
}catch(EX){}
|
}catch(EX){}
|
||||||
cache = true;
|
cache = true;
|
||||||
if(typeof o.data_method != "undefined"){
|
if(typeof o.data_method != "undefined"){
|
||||||
if(o.data_method != "")
|
if(o.data_method != ""){
|
||||||
window.o[o.data_method](target,url,cache);
|
window.o[o.data_method](target,url,cache);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
$('#header')
|
||||||
|
.delay(600)
|
||||||
|
.effect('drop',{
|
||||||
|
easing: 'easeInOutQuint',
|
||||||
|
direction: 'down'
|
||||||
|
},300);
|
||||||
|
}
|
||||||
|
|
||||||
|
var header_ani = function(){
|
||||||
|
$('#header').hide().toggle('drop',{easing: 'easeInOutQuint', direction:'down'});
|
||||||
|
$('#header > *').each(function(i){
|
||||||
|
$(this).hide().delay(i*100).fadeIn(600,'easeInOutQuint');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -632,173 +648,56 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.initializeDesktop = function(target,url,cache){ //this is for initializing main desktops that are sections and tiles
|
this.initializeDesktop = function(target,url,cache){ //this is for initializing main desktops that are sections and tiles
|
||||||
if(!target)target = "desktop";
|
target = (!target) ? 'desktop' : target;
|
||||||
var bindHandlers = function(){ // this function will bind all the handlers in the desktop
|
var bindHandlers = function(){ // this function will bind all the handlers in the desktop
|
||||||
// var groupWrapperWidth = 0;
|
|
||||||
// $("div#desktop .group").each(function(){groupWrapperWidth+=$(this).outerWidth(true);});
|
|
||||||
// var grps = new Array;
|
|
||||||
// $("div#desktop #group_wrapper").css("width",groupWrapperWidth);
|
|
||||||
// var first = true;
|
|
||||||
// $("div#desktop .g_col").sortable({
|
|
||||||
// connectWith: ".g_col",
|
|
||||||
// tolerance: 'pointer' ,
|
|
||||||
// revert: 300,
|
|
||||||
// containment: '#group_wrapper',
|
|
||||||
// helper: 'clone',
|
|
||||||
// stop:function(){
|
|
||||||
// first = true;
|
|
||||||
// var grpwidth = 0;
|
|
||||||
// for(i in grps){
|
|
||||||
// var grp = grps[i];
|
|
||||||
// if(grp.find(".element").length == 0){
|
|
||||||
// grp.animate({"width":"0px"},500,function(){$(this).remove();});
|
|
||||||
// grpwidth+=225;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// grps = [];
|
|
||||||
// $("#group_wrapper").width($("#group_wrapper").width()-grpwidth);
|
|
||||||
// },
|
|
||||||
// start:function(){
|
|
||||||
// $("#group_wrapper").find("div.group").each(function(i,par){
|
|
||||||
// var nextnumber = $(this).find("ul").length;
|
|
||||||
// $newcol = $('<ul class="g_col g_col_w2 col'+nextnumber+' ui-sortable">');
|
|
||||||
// $(this).append($newcol);
|
|
||||||
// $newcol.sortable({connectWith: '.g_col'});
|
|
||||||
// grps.push($newcol);
|
|
||||||
// $("#group_wrapper").width($("#group_wrapper").width()+225);
|
|
||||||
// });
|
|
||||||
// $("div#desktop .g_col").sortable('refresh');
|
|
||||||
// },
|
|
||||||
// update:function(){
|
|
||||||
// if(first){
|
|
||||||
// first = false;
|
|
||||||
// var newpostitions = new Array;
|
|
||||||
// var groupids = new Array;
|
|
||||||
// $.each($("div#desktop .group"),function(i,grp){
|
|
||||||
// var groupone = new Array;
|
|
||||||
// groupids.push($(grp).attr("id"));
|
|
||||||
// $ul = $(grp).find(".g_col .element");
|
|
||||||
// $.each($ul,function(){
|
|
||||||
// groupone.push($(this).attr("id"));
|
|
||||||
// })
|
|
||||||
// newpostitions.push(groupone);
|
|
||||||
// });
|
|
||||||
// $.post("/desktop/newpositions",{"sectionid":o.sectionId,"newpos":newpostitions,"groupids":groupids});
|
|
||||||
// }
|
|
||||||
// var s = $(this).find('.element').length;
|
|
||||||
// if(s!=0){
|
|
||||||
// last = $(this).find('.element').eq(s-1).position(),
|
|
||||||
// lasth = $(this).find('.element').eq(s-1).outerHeight(true);
|
|
||||||
// if ((last.top+lasth)>528){
|
|
||||||
// $(this).sortable('cancel');
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// $("#group_wrapper ul").each(function(){
|
|
||||||
// if($(this).find('.element').length == 0)
|
|
||||||
// $(this).animate({"width":"0px"},500,function(){$(this).remove();});
|
|
||||||
// })
|
|
||||||
// },
|
|
||||||
// receive: function(event, ui){
|
|
||||||
// var s = $(this).find('.element').length,
|
|
||||||
// last = $(this).find('.element').eq(s-1).position(),
|
|
||||||
// lasth = $(this).find('.element').eq(s-1).outerHeight(true);
|
|
||||||
// if ((last.top+lasth)>528){
|
|
||||||
// $(ui.sender).sortable('cancel');
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
var dragged = null,draggable,lastpos = [];
|
var dragged = null,draggable,lastpos = [];
|
||||||
o.gridvar = $(".grid ul").find("> li ").mousedown(function(e){
|
o.gridvar = $(".grid ul").find("> li ")
|
||||||
|
.mousedown(function(e){
|
||||||
!draggable;
|
!draggable;
|
||||||
dragged = $(this);
|
dragged = $(this);
|
||||||
lastpos = [];
|
lastpos = [];
|
||||||
$(".grid ul li").each(function(){
|
$(".grid ul li").each(function(){
|
||||||
lastpos.push({"col":$(this).attr("data-col"),"row":$(this).attr("data-row")})
|
lastpos.push({"col":$(this).attr("data-col"),"row":$(this).attr("data-row")});
|
||||||
|
});
|
||||||
})
|
})
|
||||||
}).end()
|
.end()
|
||||||
.gridster({
|
.gridster({
|
||||||
widget_margins: [6, 6],
|
widget_margins: [6, 6],
|
||||||
widget_base_dimensions: [120, 120],
|
widget_base_dimensions: [120, 120],
|
||||||
// avoid_overlapped_widgets: true,
|
|
||||||
serialize_params: function($w, wgd) { return { col: wgd.col, row: wgd.row, id: $w.data("id") } },
|
|
||||||
draggable : {
|
draggable : {
|
||||||
start: function(event, ui){
|
start: function(event, ui){
|
||||||
dragged.addClass("noClick");
|
dragged.addClass("noClick");
|
||||||
},
|
},
|
||||||
stop: function(event, ui){
|
stop: function(event, ui){
|
||||||
|
|
||||||
// var widgetchanged_col = dragged.attr("data-col");
|
|
||||||
// var total = 0;
|
|
||||||
// // console.log(widgetchanged.col);
|
|
||||||
// // console.log(o.gridvar.serialize_changed());
|
|
||||||
// $(".grid ul li[data-col="+widgetchanged_col+"]").each(function(i,w){
|
|
||||||
// var size = parseInt($(this).attr("data-sizey"));
|
|
||||||
// if(!isNaN(size)){
|
|
||||||
// total += size;
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// // other way to calculate the overflow is by top > height of div
|
|
||||||
// if(total>totaltiles_in_a_row){
|
|
||||||
// revertbacktiles();
|
|
||||||
// }else{
|
|
||||||
// console.log(widgetchanged_col-1);
|
|
||||||
// $(".grid ul li[data-col="+(widgetchanged_col-1)+"]").each(function(i,w){
|
|
||||||
// var sizey = parseInt($(this).attr("data-sizey"));
|
|
||||||
// var sizex = parseInt($(this).attr("data-sizex"));
|
|
||||||
// if(sizey==1){
|
|
||||||
// sizex = sizex - 1;
|
|
||||||
// }
|
|
||||||
// console.log(sizex);
|
|
||||||
|
|
||||||
// if(!isNaN(sizex)){
|
|
||||||
// total += sizex;
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// if(total>totaltiles_in_a_row){
|
|
||||||
// revertbacktiles();
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
for (var i = 1; i <= 30; i++) {
|
for (var i = 1; i <= 30; i++) {
|
||||||
// var celement = $(".grid ul .widget[data-col="+i+"]:last");
|
// var celement = $(".grid ul .widget[data-col="+i+"]:last");
|
||||||
$(".grid ul .widget[data-col="+i+"]").each(function(){
|
$(".grid ul .widget[data-col="+i+"]").each(function(){
|
||||||
var pos = $(this).position();
|
var pos = $(this).position();
|
||||||
if(pos){
|
if(pos && (pos.top + $(this).height() + 6) > 550){
|
||||||
|
|
||||||
if((pos.top + $(this).height() + 6) > 550){
|
|
||||||
revertbacktiles();
|
revertbacktiles();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
.data('gridster');
|
||||||
}
|
|
||||||
var newpos = o.gridvar.serialize();
|
|
||||||
console.log(newpos);
|
|
||||||
$.post("/desktop/newpositions",{"newpositions":newpos});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}).data('gridster');
|
|
||||||
var revertbacktiles = function(){
|
var revertbacktiles = function(){
|
||||||
lastpos.push({"col":"","row":""});
|
lastpos.push({"col":"","row":""});
|
||||||
$(".grid ul li").each(function(i){
|
$(".grid ul li").each(function(i){
|
||||||
$(this).attr({"data-col":lastpos[i].col,"data-row":lastpos[i].row});
|
$(this).attr({"data-col":lastpos[i].col,"data-row":lastpos[i].row});
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
var remove_empty_columns = function(){
|
var remove_empty_columns = function(){
|
||||||
for (var i = 1; i <= 30; i++) {
|
for (var i = 1; i <= 30; i++) {
|
||||||
// var celement = $(".grid ul .widget[data-col="+i+"]:last");
|
// var celement = $(".grid ul .widget[data-col="+i+"]:last");
|
||||||
$(".grid ul .widget[data-col="+i+"]").each(function(){
|
$(".grid ul .widget[data-col="+i+"]").each(function(){
|
||||||
|
|
||||||
})
|
});
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
o.simple_drop_down();
|
$(".app[data-category=app]").click(function(){
|
||||||
o.tinyscrollbar_ext({
|
|
||||||
main: '.tinycanvas'
|
|
||||||
})
|
|
||||||
$("li.app[data-category=app]").click(function(){
|
|
||||||
if(!$(this).hasClass("noClick")){
|
if(!$(this).hasClass("noClick")){
|
||||||
var url = $(this).find("a").data("url");
|
var url = $(this).find("a").data("url");
|
||||||
var app = $(this);
|
var app = $(this);
|
||||||
@@ -810,135 +709,64 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
dragged.removeClass("noClick");
|
dragged.removeClass("noClick");
|
||||||
|
|
||||||
})
|
});
|
||||||
|
var element = $('.gridster li');
|
||||||
|
$.each(element, function(i){
|
||||||
|
if($(this).attr("data-category")=="app" && $(this).find('.text_wrapper').length < 1){
|
||||||
|
$(this).find('.appname').wrapInner('<span class="text_wrapper"/>');
|
||||||
|
var w = $(this).find('.text_wrapper').width();
|
||||||
|
if (w > 96){
|
||||||
|
var text = $(this).find('.text_wrapper').text();
|
||||||
|
slice = text.substr(0,12);
|
||||||
|
$(this).find('.text_wrapper').attr('title',text).text(slice+'...');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
// $("div#group_wrapper ul li[data-category=app]").click(function(){
|
o.simple_drop_down();
|
||||||
// o.appWindow({
|
o.tinyscrollbar_ext({
|
||||||
// title : $(this).find("a").attr("href"),
|
main: '.tinycanvas'
|
||||||
// appid : $(this).find("a").attr("href")
|
});
|
||||||
// });
|
|
||||||
// });
|
|
||||||
}
|
}
|
||||||
var loadTiles = function(id){ //This will load tiles for a specific desktop .. id of section has to be passed here to load tiles
|
var loadTiles = function(id){ //This will load tiles for a specific desktop .. id of section has to be passed here to load tiles
|
||||||
$("div#desktop div#group_wrapper").empty();
|
$("#desktop #group_wrapper").empty();
|
||||||
$.getJSON("/desktop/getgroups",{sectionid:id},function(tiles){
|
$.getJSON("/desktop/getgroups",{sectionid:id},function(tiles){
|
||||||
// tiles.sort(o.sortJSON("position",true,parseInt));
|
tiles.sort(o.sortJSON("position",true,parseInt));
|
||||||
var tilecolors = o.themesettings.tilecolor;
|
var tilecolors = o.themesettings.tilecolor;
|
||||||
var totaltiles_in_a_row = 4;
|
var totaltiles_in_a_row = 4;
|
||||||
var opacity = ["op07","op08","op09",""];
|
var opacity = ["op07","op08","op09",""];
|
||||||
var row = 0,col = 1,x = 1,y = 1,total_x = 0,prev_y = 0;
|
var row = 1, col = 1, x = 1, y = 1;
|
||||||
var $group = $('<div class="grid gridster"></div>');
|
var $group = $('<div class="grid gridster"></div>');
|
||||||
var $ul = $('<ul style="margin: -6px 0 0 -6px;"></ul>');
|
var $ul = $('<ul></ul>');
|
||||||
|
|
||||||
$.each(tiles,function(i,tile){
|
$.each(tiles,function(i,tile){
|
||||||
var shape = tile.shape.split(" ");
|
if(row >= 4){
|
||||||
// if(tile.title == "Weather")console.log("Big - row : " + tile.row + ", col : "+ tile.column);
|
|
||||||
// if(tile.title == "Google Scholar")console.log("Scholar - row : " + tile.row + ", col : "+ tile.column);
|
|
||||||
|
|
||||||
// if(total_x % 2 != 0)
|
|
||||||
// row = row - y;
|
|
||||||
// if(i == 7)tile.row = null;
|
|
||||||
if(tile.row){
|
|
||||||
row = tile.row;
|
|
||||||
col = tile.column;
|
|
||||||
x = parseInt(shape[0].substr(1,1));
|
|
||||||
y = parseInt(shape[1].substr(1,1));
|
|
||||||
}else{
|
|
||||||
console.log(row + " : " + col);
|
|
||||||
x = parseInt(shape[0].substr(1,1));
|
|
||||||
if(total_x % 2 == 0){
|
|
||||||
row = row + y;
|
|
||||||
}else if(x == 1){
|
|
||||||
col++;
|
|
||||||
}
|
|
||||||
y = parseInt(shape[1].substr(1,1));
|
|
||||||
total_x = total_x + ( x * y );
|
|
||||||
prev_y = y;
|
|
||||||
if(total_x > 8){
|
|
||||||
row = 1;
|
row = 1;
|
||||||
total_x = 0;
|
|
||||||
col++;
|
col++;
|
||||||
}
|
}
|
||||||
}
|
var shape = tile.shape.split(" ");
|
||||||
|
x = parseInt(shape[0].substr(1,1));
|
||||||
|
y = parseInt(shape[1].substr(1,1));
|
||||||
var tilecolor = tilecolors[Math.floor(Math.random()*tilecolors.length)];
|
var tilecolor = tilecolors[Math.floor(Math.random()*tilecolors.length)];
|
||||||
var op = opacity[Math.floor(Math.random()*opacity.length)];
|
var op = opacity[Math.floor(Math.random()*opacity.length)];
|
||||||
var f = (tile.fullsize?"fullsize":null);
|
var f = (tile.fullsize?"fullsize":null);
|
||||||
|
|
||||||
if(tile.data_category == "app")
|
if(tile.data_category == "app"){
|
||||||
$li = $('<li data-id="'+tile.id+'" class="app" data-row="'+row+'" data-col="'+col+'" data-sizex="'+x+'" data-sizey="'+y+'" data-title="'+tile.title+'" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'"><span class="tile '+tilecolor+' '+op+'"></span><a href="'+tile.data_content+'" class="appicon" onclick="return false;" data-url="'+tile.link+'"><img src="'+o.iconPath+tile.data_content+'.png" alt="" ></a><h1 class="appname thmtxt">'+tile.title+'</h1></li>');
|
$li = $('<li data-id="'+tile.id+'" class="app" data-row="'+row+'" data-col="'+col+'" data-sizex="'+x+'" data-sizey="'+y+'" data-title="'+tile.title+'" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'"><span class="tile '+tilecolor+' '+op+'"></span><a href="'+tile.data_content+'" class="appicon" onclick="return false;" data-url="'+tile.link+'"><img src="'+o.iconPath+tile.data_content+'.png" alt="" ></a><h1 class="appname thmtxt">'+tile.title+'</h1></li>');
|
||||||
else
|
} else {
|
||||||
$li = $('<li data-id="'+tile.id+'" class="widget '+f+'" data-row="'+row+'" data-col="'+col+'" data-sizex="'+x+'" data-sizey="'+y+'" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'" js-link="'+tile.js[0].url+'" css-link="'+tile.css.url+'"><span class="tile '+tilecolor+' '+op+'"></span><div class="appholder"><div class="thmtxt all-loading"><i class="icon-spinner icon-spin"></i> Loading </div></div><h1 class="appname thmtxt">'+tile.title+'</h1></li>');
|
$li = $('<li data-id="'+tile.id+'" class="widget '+f+'" data-row="'+row+'" data-col="'+col+'" data-sizex="'+x+'" data-sizey="'+y+'" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'" js-link="'+tile.js[0].url+'" css-link="'+tile.css.url+'"><span class="tile '+tilecolor+' '+op+'"></span><div class="appholder"></div><h1 class="appname thmtxt">'+tile.title+'</h1></li>');
|
||||||
|
}
|
||||||
|
|
||||||
|
row = row + y;
|
||||||
|
|
||||||
$ul.append($li);
|
$ul.append($li);
|
||||||
})
|
});
|
||||||
$group.append($ul);
|
$group.append($ul);
|
||||||
$("div#desktop div#group_wrapper").append($group);
|
$("#desktop #group_wrapper").append($group);
|
||||||
|
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
o.initializeWidgets();
|
o.initializeWidgets();
|
||||||
})
|
});
|
||||||
// var tilecolors = o.themesettings.tilecolor;
|
|
||||||
// var opacity = ["op05","op06","op07","op08","op09"];
|
|
||||||
// $.each(groups,function(i,group){
|
|
||||||
// group.sort(o.sortJSON("position",true,parseInt));
|
|
||||||
// // var $group = $('<div class="group"><ul class="grp ui-sortable"></ul></div>'),
|
|
||||||
// var colindex = 0,
|
|
||||||
// $group = $('<div class="group"></div>'),
|
|
||||||
// $col = $('<ul class="g_col g_col_w2 col'+ colindex +'"/>'),
|
|
||||||
// $li,
|
|
||||||
// bdsum = 0,
|
|
||||||
// bwsum = 0,
|
|
||||||
// bhsum = 0,
|
|
||||||
// small = 0,
|
|
||||||
// single = false;
|
|
||||||
// $group.append($col);
|
|
||||||
// for(j=0;j<group.length;j++){
|
|
||||||
// var tile = group[j];
|
|
||||||
// var brick = tile.shape.replace(' holder_f','').split(' '),
|
|
||||||
// bw = parseInt(brick[0].substr(1)),
|
|
||||||
// bh = parseInt(brick[1].substr(1)),
|
|
||||||
// bd = bw * bh;
|
|
||||||
// if(bh==1 && bw==1){
|
|
||||||
// small++;
|
|
||||||
// }else if(bh!=1 && bw!=1){
|
|
||||||
// single = true;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// if(small==2){
|
|
||||||
// small=0;
|
|
||||||
// single=false;
|
|
||||||
// }else if(small==1 && single==true){
|
|
||||||
// bh++;
|
|
||||||
// small=0;
|
|
||||||
// single=false;
|
|
||||||
// }else{small=0;single=false;}
|
|
||||||
|
|
||||||
// bdsum+=bd;
|
|
||||||
// bwsum+=bw;
|
|
||||||
// bhsum+=bh;
|
|
||||||
|
|
||||||
// if(bdsum > 8 || bhsum > 6){
|
|
||||||
// bdsum = 0, bhsum = 0, colindex++,j--;
|
|
||||||
// $group.append('<ul class="g_col g_col_w2 col'+ colindex +'"/>');
|
|
||||||
// }else{
|
|
||||||
// var tilecolor = tilecolors[Math.floor(Math.random()*tilecolors.length)];
|
|
||||||
// var op = opacity[Math.floor(Math.random()*opacity.length)];
|
|
||||||
// if(j==0)$group.attr("id",tile.group_id);
|
|
||||||
|
|
||||||
// if(tile.data_category == "app")
|
|
||||||
// $li = $('<li data-id="'+tile.id+'" class="element '+tile.shape+' hp vp" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'" ><span class="tile '+tilecolor+' '+op+'"></span><a href="'+tile.data_content+'" class="appicon" onclick="return false;"><img src="'+o.iconPath+tile.data_content+'.png" alt="" ></a><h1 class="appname thmtxt">'+tile.title+'</h1></li>');
|
|
||||||
// else
|
|
||||||
// $li = $('<li data-id="'+tile.id+'" class="element '+tile.shape+' hp vp" data-category="'+tile.data_category+'" data-content="'+tile.data_content+'" js-link="'+tile.js[0].url+'" css-link="'+tile.css.url+'"><span class="tile '+tilecolor+' '+op+'"></span><h1 class="appname thmtxt">'+tile.title+'</h1><div class="appholder">Loading...</div></li>');
|
|
||||||
|
|
||||||
// $group.find('.col'+colindex).append($li);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// $("div#desktop div#group_wrapper").append($group);
|
|
||||||
// })
|
|
||||||
|
|
||||||
// })
|
|
||||||
}
|
}
|
||||||
var loadSectionList = function(){ //This will load the section list from the db
|
var loadSectionList = function(){ //This will load the section list from the db
|
||||||
$.getJSON("/desktop/getsectionlist",{desktopid:o.desktopId},function(sectionlist){
|
$.getJSON("/desktop/getsectionlist",{desktopid:o.desktopId},function(sectionlist){
|
||||||
@@ -949,39 +777,39 @@ var orbitDesktop = function(dom){
|
|||||||
tempstyle = "style='display:none;'";
|
tempstyle = "style='display:none;'";
|
||||||
$("#desktop #section_heading").text(section.name);
|
$("#desktop #section_heading").text(section.name);
|
||||||
}
|
}
|
||||||
$("div#desktop ul#section_list").append($('<li class="section_name" '+tempstyle+'><a class="admtxt hp w2 hh1" onclick="return false;" href="'+section._id+'" >'+section.name+'</a></li>'));
|
$("#desktop #section_list").append($('<li class="section_name" '+tempstyle+'><a class="admtxt hp hh1" onclick="return false;" href="'+section._id+'" >'+section.name+'</a></li>'));
|
||||||
})
|
});
|
||||||
bindSecondaryHandlers();
|
bindSecondaryHandlers();
|
||||||
|
o.simple_drop_down();
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
var bindSecondaryHandlers = function(){ //This is the secondary bind handler function which is used to bind events which are repeatative
|
var bindSecondaryHandlers = function(){ //This is the secondary bind handler function which is used to bind events which are repeatative
|
||||||
$("div#desktop ul#section_list li.section_name").click(function(){
|
$("#desktop #section_list .section_name").click(function(){
|
||||||
$("div#desktop li.section_name").show();
|
$("#desktop .section_name").show();
|
||||||
$(this).hide();
|
$(this).hide();
|
||||||
$("#desktop #section_heading").text($(this).text());
|
$("#desktop #section_heading").text($(this).text());
|
||||||
o.sectionId = $(this).find("a").attr("href");
|
o.sectionId = $(this).find("a").attr("href");
|
||||||
loadTiles(o.sectionId);
|
loadTiles(o.sectionId);
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
if(cache){
|
if(cache){
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
o.initializeWidgets();
|
o.initializeWidgets();
|
||||||
bindSecondaryHandlers();
|
$("#desktop #section_list").empty();
|
||||||
$("div#desktop ul#section_list").empty();
|
|
||||||
$.each(o.sectionList,function(i,section){
|
$.each(o.sectionList,function(i,section){
|
||||||
var tempstyle="";
|
var tempstyle="";
|
||||||
if(section._id==o.sectionId){
|
if(section._id==o.sectionId){
|
||||||
tempstyle = "style='display:none;'";
|
tempstyle = "style='display:none;'";
|
||||||
$("div#desktop span#section_heading").text(section.name);
|
$("#desktop #section_heading").text(section.name);
|
||||||
}
|
}
|
||||||
$("div#desktop ul#section_list").append($('<li class="section_name" '+tempstyle+'><a class="admtxt hp w2 hh1" onclick="return false;" href="'+section._id+'" >'+section.name+'</a></li>'));
|
$("#desktop #section_list").append($('<li class="section_name" '+tempstyle+'><a class="admtxt hp hh1" onclick="return false;" href="'+section._id+'" >'+section.name+'</a></li>'));
|
||||||
})
|
});
|
||||||
bindSecondaryHandlers();
|
bindSecondaryHandlers();
|
||||||
}else{
|
}else{
|
||||||
loadTiles(o.sectionId);
|
|
||||||
loadSectionList();
|
loadSectionList();
|
||||||
|
loadTiles(o.sectionId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
|
||||||
|
|
||||||
this.tempFunc = function(th){
|
this.tempFunc = function(th){
|
||||||
$.post("desktop/twitter",function(){});
|
$.post("desktop/twitter",function(){});
|
||||||
@@ -997,11 +825,11 @@ var orbitDesktop = function(dom){
|
|||||||
//for textbox search
|
//for textbox search
|
||||||
$("#app_manager #searchbox").focus(function(){$(this).val("");}).keyup(function(e){
|
$("#app_manager #searchbox").focus(function(){$(this).val("");}).keyup(function(e){
|
||||||
if($(this).val()){
|
if($(this).val()){
|
||||||
$("div#app_manager .search_result").empty();
|
$("#app_manager .search_result").empty();
|
||||||
$("div#app_manager #seperator").hide();
|
$("#app_manager #seperator").hide();
|
||||||
searchArray = $("div#app_manager .element:containsi("+$(this).val()+")");
|
searchArray = $("#app_manager .element:containsi("+$(this).val()+")");
|
||||||
if(searchArray.length>0){
|
if(searchArray.length>0){
|
||||||
$("div#app_manager #seperator").show();
|
$("#app_manager #seperator").show();
|
||||||
var i = 0;
|
var i = 0;
|
||||||
var $column;
|
var $column;
|
||||||
searchArray.each(function(){
|
searchArray.each(function(){
|
||||||
@@ -1012,19 +840,19 @@ var orbitDesktop = function(dom){
|
|||||||
var $newelement = $('<div class="search element w1 h1 hp vp thmc2" data-category="desktop">'+$(this).html()+'</div>');
|
var $newelement = $('<div class="search element w1 h1 hp vp thmc2" data-category="desktop">'+$(this).html()+'</div>');
|
||||||
$column.append($newelement);
|
$column.append($newelement);
|
||||||
if(i == 4){
|
if(i == 4){
|
||||||
$("div#app_manager .search_result").append($column);
|
$("#app_manager .search_result").append($column);
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
if(i != 0){
|
if(i != 0){
|
||||||
$("div#app_manager .search_result").append($column);
|
$("#app_manager .search_result").append($column);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}else{$("div#app_manager #seperator").hide();$("div#app_manager .search_result").empty();}
|
}else{$("#app_manager #seperator").hide();$("#app_manager .search_result").empty();}
|
||||||
}).blur(function(){$(this).val("Search");});
|
}).blur(function(){$(this).val("Search");});
|
||||||
|
|
||||||
//for Alphabet sorting
|
//for Alphabet sorting
|
||||||
$("div#app_manager a#alphabet_sort_btn").click(function(){
|
$("#app_manager #alphabet_sort_btn").click(function(){
|
||||||
switch ($(this).attr("href")){
|
switch ($(this).attr("href")){
|
||||||
case "ascending":
|
case "ascending":
|
||||||
$(this).attr("href","descending").find(".thmtxt").text("Alphabet [Z-A]");
|
$(this).attr("href","descending").find(".thmtxt").text("Alphabet [Z-A]");
|
||||||
@@ -1032,10 +860,10 @@ var orbitDesktop = function(dom){
|
|||||||
break;
|
break;
|
||||||
case "descending":
|
case "descending":
|
||||||
$(this).attr("href","ascending").find(".thmtxt").text("Alphabet [A-Z]");
|
$(this).attr("href","ascending").find(".thmtxt").text("Alphabet [A-Z]");
|
||||||
allApps = $("div#app_manager .group_search .element").sort(sortDescending);
|
allApps = $("#app_manager .group_search .element").sort(sortDescending);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
$("div#app_manager #app_list").empty();
|
$("#app_manager #app_list").empty();
|
||||||
var count = 0, colindex = 0;
|
var count = 0, colindex = 0;
|
||||||
$('#app_list').append('<div class="g_col g_col_w1 col'+ colindex +'"/>');
|
$('#app_list').append('<div class="g_col g_col_w1 col'+ colindex +'"/>');
|
||||||
$.each(allApps,function(i,app){
|
$.each(allApps,function(i,app){
|
||||||
@@ -1047,9 +875,9 @@ var orbitDesktop = function(dom){
|
|||||||
} else {
|
} else {
|
||||||
$('.g_col.col'+ colindex).append(app);
|
$('.g_col.col'+ colindex).append(app);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
return false;
|
return false;
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
var loadApps = function(){ //this load apps for sorting and searching
|
var loadApps = function(){ //this load apps for sorting and searching
|
||||||
$.getJSON("/desktop/getapplist",{desktopid:o.desktopId},function(appss){
|
$.getJSON("/desktop/getapplist",{desktopid:o.desktopId},function(appss){
|
||||||
@@ -1067,22 +895,23 @@ var orbitDesktop = function(dom){
|
|||||||
} else {
|
} else {
|
||||||
$('.g_col.col'+ colindex).append($app);
|
$('.g_col.col'+ colindex).append($app);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
if(cache)
|
if(cache){
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
else
|
} else {
|
||||||
loadApps();
|
loadApps();
|
||||||
|
}
|
||||||
};
|
};
|
||||||
this.initializeSectionsManager = function(target,url,cache){ // this is init function for section manager
|
this.initializeSectionsManager = function(target,url,cache){ // this is init function for section manager
|
||||||
var elementParent,element,slabel;
|
var elementParent,element,slabel;
|
||||||
var bindHandlers = function(){ // this is bind handler for section manager page
|
var bindHandlers = function(){ // this is bind handler for section manager page
|
||||||
var groupWrapperWidth = 0;
|
var groupWrapperWidth = 0;
|
||||||
$("div#sections .group").each(function(){groupWrapperWidth+=$(this).width();})
|
$("#sections .group").each(function(){groupWrapperWidth+=$(this).width();})
|
||||||
groupWrapperWidth+=200;
|
groupWrapperWidth+=200;
|
||||||
groupWrapperHeight = $(".group").height() + 20;
|
groupWrapperHeight = $(".group").height() + 20;
|
||||||
$("#group_wrapper").width(groupWrapperWidth);
|
$("#group_wrapper").width(groupWrapperWidth);
|
||||||
@@ -1096,9 +925,9 @@ var orbitDesktop = function(dom){
|
|||||||
slabel.find('li:not(:nth-child(1))').stop(1,1).fadeOut(500);
|
slabel.find('li:not(:nth-child(1))').stop(1,1).fadeOut(500);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$("div#sections #group_wrapper .appgroup").sortable(sortingoptions);
|
$("#sections #group_wrapper .appgroup").sortable(sortingoptions);
|
||||||
|
|
||||||
$("div#sections .section_label li:not(:nth-child(1))").droppable({
|
$("#sections .section_label li:not(:nth-child(1))").droppable({
|
||||||
drop:function(event, ui){
|
drop:function(event, ui){
|
||||||
elementParent = ui.draggable.parents('.group');
|
elementParent = ui.draggable.parents('.group');
|
||||||
elementParentUl = ui.draggable.parents(".appgroup");
|
elementParentUl = ui.draggable.parents(".appgroup");
|
||||||
@@ -1142,7 +971,7 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(newul){
|
if(newul){
|
||||||
$("div#sections #group_wrapper .appgroup").sortable(sortingoptions);
|
$("#sections #group_wrapper .appgroup").sortable(sortingoptions);
|
||||||
$list.removeClass("no_app");
|
$list.removeClass("no_app");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -1176,12 +1005,12 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
if(z!=x){
|
if(z!=x){
|
||||||
$lii = $('<li class="element w1 h1 hp vp thmtxt" style="display: none;" data-category="section'+(x+1)+'" data-content="'+o.sectionList[x]._id+'"><span class="tile thmc2 op06"></span><span class="thmtxt">'+o.sectionList[x].name+'</span></li>');
|
$lii = $('<li class="element w1 h1 hp vp thmtxt" style="display: none;" data-category="section'+(x+1)+'" data-content="'+o.sectionList[x]._id+'"><span class="tile thmc2 op06"></span><span class="thmtxt">'+o.sectionList[x].name+'</span></li>');
|
||||||
$group.find("ul.section_grp").append($lii);
|
$group.find(".section_grp").append($lii);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
z++;
|
z++;
|
||||||
|
|
||||||
$("div#group_wrapper").append($group);
|
$("#group_wrapper").append($group);
|
||||||
}
|
}
|
||||||
|
|
||||||
var x = 0;
|
var x = 0;
|
||||||
@@ -1195,14 +1024,14 @@ var orbitDesktop = function(dom){
|
|||||||
$li = $('<li class="element to_drop w1 hh2 hp vp" data-category="'+app.data_category+'" data-content="'+app.data_content+'" id="'+app._id+'"><div class="appicon"><img src="'+o.iconPath+app.data_content+'.png" class="" width="30" /></div><h1 class="appname thmtxth">'+app.title+'</h1></li>');
|
$li = $('<li class="element to_drop w1 hh2 hp vp" data-category="'+app.data_category+'" data-content="'+app.data_content+'" id="'+app._id+'"><div class="appicon"><img src="'+o.iconPath+app.data_content+'.png" class="" width="30" /></div><h1 class="appname thmtxth">'+app.title+'</h1></li>');
|
||||||
$ul.append($li);
|
$ul.append($li);
|
||||||
if(x == 7){
|
if(x == 7){
|
||||||
$("div#group_wrapper div#section"+(i+1)).append($ul);
|
$("#group_wrapper #section"+(i+1)).append($ul);
|
||||||
$("div#group_wrapper div#section"+(i+1)).removeClass("no_app")
|
$("#group_wrapper #section"+(i+1)).removeClass("no_app")
|
||||||
x = 0;
|
x = 0;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
if(x != 0){
|
if(x != 0){
|
||||||
$("div#group_wrapper div#section"+(i+1)).append($ul);
|
$("#group_wrapper #section"+(i+1)).append($ul);
|
||||||
$("div#group_wrapper div#section"+(i+1)).removeClass("no_app")
|
$("#group_wrapper #section"+(i+1)).removeClass("no_app")
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
@@ -1228,7 +1057,7 @@ var orbitDesktop = function(dom){
|
|||||||
this.initializeSettings.sections = function(){ // this load section page in setting page
|
this.initializeSettings.sections = function(){ // this load section page in setting page
|
||||||
var bindHandlers = function(){ // binding handlers in section page
|
var bindHandlers = function(){ // binding handlers in section page
|
||||||
|
|
||||||
$("a#name_save_btn").click(function(){
|
$("#name_save_btn").click(function(){
|
||||||
var desktopnm = new Array;
|
var desktopnm = new Array;
|
||||||
$("#desktop_names input").each(function(){
|
$("#desktop_names input").each(function(){
|
||||||
desktopnm.push($(this).val());
|
desktopnm.push($(this).val());
|
||||||
@@ -1295,7 +1124,7 @@ var orbitDesktop = function(dom){
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
$("a#theme_submit").click(function(){
|
$("#theme_submit").click(function(){
|
||||||
o.confirm({
|
o.confirm({
|
||||||
message : "Are you sure that you want to save custom theme?",
|
message : "Are you sure that you want to save custom theme?",
|
||||||
highlighted : 1,
|
highlighted : 1,
|
||||||
@@ -1439,7 +1268,7 @@ var orbitDesktop = function(dom){
|
|||||||
$ul.find("input[type=password]").replaceWith("<div class='c_info pwd'>••••••</div>");
|
$ul.find("input[type=password]").replaceWith("<div class='c_info pwd'>••••••</div>");
|
||||||
$ul.find("a[for=new]").text("Edit").attr("for","edit");
|
$ul.find("a[for=new]").text("Edit").attr("for","edit");
|
||||||
$ul.find("a[for=delete]").show();
|
$ul.find("a[for=delete]").show();
|
||||||
$ul.find("span.c_status").text("Connected").addClass("c_status_on");
|
$ul.find(".c_status").text("Connected").addClass("c_status_on");
|
||||||
})
|
})
|
||||||
bindHandlers();
|
bindHandlers();
|
||||||
})
|
})
|
||||||
@@ -1559,21 +1388,21 @@ var orbitDesktop = function(dom){
|
|||||||
s_name_list_not+= "<a href='addthis' for='"+sec_link+"' style='text-decoration:underline;'>"+sec_name+"</a> ";
|
s_name_list_not+= "<a href='addthis' for='"+sec_link+"' style='text-decoration:underline;'>"+sec_name+"</a> ";
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
li.find("div.status").html("Status : Installed on "+s_name_list);
|
li.find(".status").html("Status : Installed on "+s_name_list);
|
||||||
if(s_name_list_not)
|
if(s_name_list_not)
|
||||||
li.find("div.not_status").html("Install on "+s_name_list_not);
|
li.find(".not_status").html("Install on "+s_name_list_not);
|
||||||
}else{
|
}else{
|
||||||
li.find("div.not_status").html("Install on <a href='addthis' for='"+o.sectionList[0]._id+"' style='text-decoration:underline;'>"+o.sectionList[0].name+"</a> <a href='addthis' for='"+o.sectionList[1]._id+"' style='text-decoration:underline;'>"+o.sectionList[1].name+"</a> <a href='addthis' for='"+o.sectionList[2]._id+"' style='text-decoration:underline;'>"+o.sectionList[2].name+"</a> <a href='addthis' for='"+o.sectionList[3]._id+"' style='text-decoration:underline;'>"+o.sectionList[3].name)+"</a>";
|
li.find(".not_status").html("Install on <a href='addthis' for='"+o.sectionList[0]._id+"' style='text-decoration:underline;'>"+o.sectionList[0].name+"</a> <a href='addthis' for='"+o.sectionList[1]._id+"' style='text-decoration:underline;'>"+o.sectionList[1].name+"</a> <a href='addthis' for='"+o.sectionList[2]._id+"' style='text-decoration:underline;'>"+o.sectionList[2].name+"</a> <a href='addthis' for='"+o.sectionList[3]._id+"' style='text-decoration:underline;'>"+o.sectionList[3].name)+"</a>";
|
||||||
}
|
}
|
||||||
//console.log(section_names);
|
//console.log(section_names);
|
||||||
column.find("ul").append(li);
|
column.find("ul").append(li);
|
||||||
if(counter%4==0){
|
if(counter%4==0){
|
||||||
$("#apps_store div#widget_list").append(column);
|
$("#apps_store #widget_list").append(column);
|
||||||
column = $('<div class="g_col list_t" style="width:350px;"><ul></ul></div>');
|
column = $('<div class="g_col list_t" style="width:350px;"><ul></ul></div>');
|
||||||
}
|
}
|
||||||
counter++;
|
counter++;
|
||||||
})
|
})
|
||||||
$("#apps_store div#widget_list").append(column);
|
$("#apps_store #widget_list").append(column);
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -1593,32 +1422,52 @@ var orbitDesktop = function(dom){
|
|||||||
this.loadWallpaper = function(wallpaper){ // this is to load new wallpaper
|
this.loadWallpaper = function(wallpaper){ // this is to load new wallpaper
|
||||||
wallpapernm = (!wallpaper) ? o.themesettings.background : wallpaper;
|
wallpapernm = (!wallpaper) ? o.themesettings.background : wallpaper;
|
||||||
if(!wallpaper){
|
if(!wallpaper){
|
||||||
$("img#thmbackground").attr("src","/"+o.themefolder+"/"+o.theme+"/images/"+wallpapernm);
|
$("#thmbackground").attr("src","/"+o.themefolder+"/"+o.theme+"/images/"+wallpapernm);
|
||||||
} else {
|
} else {
|
||||||
$("img#thmbackground").attr("src",o.wallpaperPath+wallpaper);
|
$("#thmbackground").attr("src",o.wallpaperPath+wallpaper);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
this.loadIconCache = function(){ // this function load or refresh icon cache for the theme
|
this.loadIconCache = function(){ // this function load or refresh icon cache for the theme
|
||||||
var imgs = $("ul.docklist img");
|
var imgs = $(".docklist img");
|
||||||
$.each(imgs,function(){
|
$.each(imgs,function(){
|
||||||
var setting_name = $(this).attr("id").replace("_icon","");
|
var setting_name = $(this).attr("id").replace("_icon","");
|
||||||
$(this).attr("src","/"+o.themefolder+"/"+o.theme+"/images/"+o.themesettings.icons[setting_name])
|
$(this).attr("src","/"+o.themefolder+"/"+o.theme+"/images/"+o.themesettings.icons[setting_name])
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
this.initializeWidgets = function(){ // this function will initialize all the widgets in the desktop
|
this.initializeWidgets = function(){ // this function will initialize all the widgets in the desktop
|
||||||
var elements = $("#group_wrapper li.widget");
|
var elements = $("#group_wrapper .widget"),
|
||||||
|
loading = '<div class="thmtxt o-loading"><i class="icon-spin icon-spinner"></i> Loading</div>';
|
||||||
$.each(elements,function(){
|
$.each(elements,function(){
|
||||||
var widget = $(this);
|
var widget = $(this),
|
||||||
|
widget_holder = $(this).find('.appholder'),
|
||||||
|
widget_style = (widget.find('.widget_style').length > 0) ? '' : '<link class="widget_style" rel="stylesheet" href="'+widget.attr("css-link")+'" type="text/css" />';
|
||||||
if(widget.attr("data-category")=="widget"){
|
if(widget.attr("data-category")=="widget"){
|
||||||
var widgename = widget.attr("data-content");
|
var widgetname = widget.attr("data-content");
|
||||||
$.getScript(widget.attr("js-link"),function(){
|
widget_holder.before(widget_style).empty();
|
||||||
widget.find("div.appholder").load(widget.attr("data-content"));
|
$.getScript(widget.attr("js-link")).done(function(){
|
||||||
|
// widget.find(".appholder").load(widget.attr("data-content"));
|
||||||
|
$.ajax({
|
||||||
|
url: widgetname,
|
||||||
|
beforeSend: function(){
|
||||||
|
widget_holder.html(loading);
|
||||||
|
},
|
||||||
|
success: function(html){
|
||||||
|
widget_holder
|
||||||
|
.css('top','100%')
|
||||||
|
.html(html);
|
||||||
|
},
|
||||||
|
complete: function(){
|
||||||
|
widget_holder
|
||||||
|
.delay(300)
|
||||||
|
.animate({top:'0'},500,'easeInOutQuint');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
$(this).find("div.appholder").append( '<link rel="stylesheet" id="dyn_css" href="'+widget.attr("css-link")+'" type="text/css" />')
|
});
|
||||||
|
// $(this).find(".appholder").append( '<link rel="stylesheet" href="'+widget.attr("css-link")+'" type="text/css" />');
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
});
|
||||||
};
|
};
|
||||||
this.saveWallpaper = function(wallpaper){ // this function saves wallpaper in db
|
this.saveWallpaper = function(wallpaper){ // this function saves wallpaper in db
|
||||||
$.post("/desktop/save_desktop_settings",{"save":"wallpaper","wallpapernm":wallpaper,"desktopid":o.desktopId},function(result){
|
$.post("/desktop/save_desktop_settings",{"save":"wallpaper","wallpapernm":wallpaper,"desktopid":o.desktopId},function(result){
|
||||||
@@ -1666,20 +1515,18 @@ var orbitDesktop = function(dom){
|
|||||||
};
|
};
|
||||||
this.simple_drop_down = function(){
|
this.simple_drop_down = function(){
|
||||||
// simple dropdown menu
|
// simple dropdown menu
|
||||||
if( !$('.sdm').children('.sdm_o').length > 0 ){
|
var $sdm = $('.sdm');
|
||||||
return;
|
if( $sdm.find('.sdm_o') ){
|
||||||
} else {
|
$sdm.find('a').andSelf().on({
|
||||||
$('.sdm').hover(function(){
|
mouseenter: function(){
|
||||||
$(this).stop(1,1).toggleClass('thmc2 thmtxt');
|
$(this).addClass('thmc2 thmtxt');
|
||||||
}, function(){
|
},
|
||||||
$(this).stop(1,1).toggleClass('thmc2 thmtxt');
|
mouseleave: function(){
|
||||||
});
|
$(this).removeClass('thmc2 thmtxt');
|
||||||
$('.sdm').find('a').hover(function(){
|
}
|
||||||
$(this).stop(1,1).toggleClass('thmc2 thmtxt');
|
|
||||||
}, function(){
|
|
||||||
$(this).stop(1,1).toggleClass('thmc2 thmtxt');
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
this.simple_tab = function(){
|
this.simple_tab = function(){
|
||||||
// tab
|
// tab
|
||||||
|
|||||||
@@ -147,7 +147,7 @@ var orbitDesktopAPI = function(){
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var whtml =$('<div id="app_frame_'+o.windowcounter+'" class="thmc2 app_frame" data-app="'+settings.appid+'"><div id="content"><div id="header" class="hh3"><div class="dtitle w2 hh3 hp" style="text-transform:capitalize;"><span class="thmtxth">'+settings.title+'</span></div><span class="icon-remove hh3 hp thmtxt"></span></div><div id="holder_'+o.windowcounter+'" class="app_holder"><iframe src="'+appurl+'" frameborder="0" scrolling="auto"></iframe><div class="clear"></div></div></div></div>');
|
var whtml =$('<div id="app_frame_'+o.windowcounter+'" class="thmc2 app_frame" data-app="'+settings.appid+'"><div id="content"><div id="header" class="hh3"><div class="dtitle hh3 hp" style="text-transform:capitalize;"><span class="thmtxth">'+settings.title+'</span></div><span class="icon-remove hh3 hp thmtxt"></span></div><div id="holder_'+o.windowcounter+'" class="app_holder"><iframe src="'+appurl+'" frameborder="0" scrolling="auto"></iframe><div class="clear"></div></div></div></div>');
|
||||||
$(o.contentHolder).append(whtml);
|
$(o.contentHolder).append(whtml);
|
||||||
var parentwindow = $(o.contentHolder).find("div#app_frame_"+o.windowcounter);
|
var parentwindow = $(o.contentHolder).find("div#app_frame_"+o.windowcounter);
|
||||||
var app_holder_height = parentwindow.height() - 72;
|
var app_holder_height = parentwindow.height() - 72;
|
||||||
@@ -206,12 +206,6 @@ var orbitDesktopAPI = function(){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
this.use_select2 = function(){
|
|
||||||
$('select:not(.select2-offscreen)').select2({
|
|
||||||
minimumResultsForSearch: -1
|
|
||||||
// minimumInputLength: -1
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
orbitDesktopAPI.prototype.notifyImgPath = "temp";
|
orbitDesktopAPI.prototype.notifyImgPath = "temp";
|
||||||
orbitDesktopAPI.prototype.wallpaperPath = "temp";
|
orbitDesktopAPI.prototype.wallpaperPath = "temp";
|
||||||
@@ -1,42 +1,3 @@
|
|||||||
function append_id(){
|
|
||||||
if ($("#object_id").length == 1) {
|
|
||||||
return "&id="+$("#object_id").val();
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
return '';
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
$("div.editable").live("mouseenter mouseleave", function (event) {
|
|
||||||
$(this).children('.edit_link').toggle();
|
|
||||||
});
|
|
||||||
|
|
||||||
$("#page_design").live('change', function() {
|
|
||||||
$.getScript($(this).attr('rel') + '?design_id=' + $(this).val() + append_id());
|
|
||||||
});
|
|
||||||
|
|
||||||
|
|
||||||
$("#module_app_list select").live('change', function() {
|
|
||||||
$.getScript($(this).attr('rel') + '?module_app_id='+$(this).val() + append_id());
|
|
||||||
});
|
|
||||||
|
|
||||||
$("#widget_list select,#frontend_list select").live('change', function() {
|
|
||||||
$.getScript($(this).attr('rel') +'?frontend=' + $(this).val() + '&module_app_id=' + $("#module_app_list select").val() + append_id() );
|
|
||||||
});
|
|
||||||
|
|
||||||
$("#tag_list select").live('change', function() {
|
|
||||||
$.getScript($(this).attr('rel') + '?type=' + $(this).val() + append_id() );
|
|
||||||
});
|
|
||||||
|
|
||||||
$("select.widget_field_select").live('change', function() {
|
|
||||||
$.getScript($(this).attr('rel') + '?widget_field_value='+ $(this).val()+'&dom_id=' + $(this).attr("id") + '&field_seri=' +$(this).attr('field_seri')+ '&module_app_id=' +$("#page_module_app_id,page_part_module_app_id").val() + append_id() );
|
|
||||||
});
|
|
||||||
|
|
||||||
$('.part_kind').live('click', function() {
|
|
||||||
$('.part_kind_partial').hide();
|
|
||||||
$('#part_' + $(this).attr('value')).show();
|
|
||||||
});
|
|
||||||
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
bindTreeDragHandle();
|
bindTreeDragHandle();
|
||||||
});
|
});
|
||||||
@@ -61,3 +22,7 @@ var bindTreeDragHandle = function(){
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$("div.editable").live("mouseenter mouseleave", function (event) {
|
||||||
|
$(this).children('.edit_link').toggle();
|
||||||
|
});
|
||||||
@@ -3,12 +3,10 @@ $gray: #ddd;
|
|||||||
@mixin font-main($font-size) {
|
@mixin font-main($font-size) {
|
||||||
font-family: "Source Sans Pro", sans-serif;
|
font-family: "Source Sans Pro", sans-serif;
|
||||||
font-size: #{$font-size}px;
|
font-size: #{$font-size}px;
|
||||||
font-weight: 300;
|
|
||||||
}
|
}
|
||||||
@mixin font-sub($font-size) {
|
@mixin font-sub($font-size) {
|
||||||
font-family: "Source Sans Pro", Arial, sans-serif;
|
font-family: "Source Sans Pro", Arial, sans-serif;
|
||||||
font-size: #{$font-size}px;
|
font-size: #{$font-size}px;
|
||||||
font-weight: 300;
|
|
||||||
}
|
}
|
||||||
@mixin transition-type($property, $sec) {
|
@mixin transition-type($property, $sec) {
|
||||||
-webkit-transition: #{$property} #{$sec}s ease;
|
-webkit-transition: #{$property} #{$sec}s ease;
|
||||||
|
|||||||
@@ -92,17 +92,25 @@
|
|||||||
z-index: 9;
|
z-index: 9;
|
||||||
left: 0;
|
left: 0;
|
||||||
top: 60px;
|
top: 60px;
|
||||||
font-size: 15px; }
|
font-size: 15px;
|
||||||
|
width: 120px;
|
||||||
|
border: solid 2px #dddddd;
|
||||||
|
-webkit-box-sizing: border-box;
|
||||||
|
/* webkit */
|
||||||
|
-khtml-box-sizing: border-box;
|
||||||
|
/* konqueror */
|
||||||
|
-moz-box-sizing: border-box;
|
||||||
|
/* firefox */
|
||||||
|
-ms-box-sizing: border-box;
|
||||||
|
/* ie */
|
||||||
|
box-sizing: border-box;
|
||||||
|
/* css3 */ }
|
||||||
.sdm_o li {
|
.sdm_o li {
|
||||||
border-top: solid 1px #f2f2f2; }
|
border-top: solid 1px #f7f7f7; }
|
||||||
|
|
||||||
.sdm_o li:first-child {
|
.sdm_o li:first-child {
|
||||||
border: none; }
|
border: none; }
|
||||||
|
|
||||||
.sdm_o a {
|
.sdm_o a {
|
||||||
display: block; }
|
display: block; }
|
||||||
|
|
||||||
.sdm_o .admtxt {
|
.sdm_o .admtxt {
|
||||||
display: block;
|
display: block;
|
||||||
line-height: 36px; }
|
line-height: 36px; }
|
||||||
@@ -119,13 +127,10 @@
|
|||||||
.s_menu {
|
.s_menu {
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
line-height: 36px; }
|
line-height: 36px; }
|
||||||
|
|
||||||
.s_menu li {
|
.s_menu li {
|
||||||
border-top: solid 1px #dddddd; }
|
border-top: solid 1px #dddddd; }
|
||||||
|
|
||||||
.s_menu li:first-child {
|
.s_menu li:first-child {
|
||||||
border: none; }
|
border: none; }
|
||||||
|
|
||||||
.s_menu a {
|
.s_menu a {
|
||||||
display: block; }
|
display: block; }
|
||||||
|
|
||||||
@@ -157,7 +162,7 @@
|
|||||||
font-size: 15px; }
|
font-size: 15px; }
|
||||||
.s_form label {
|
.s_form label {
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
font-weight: normal;
|
font-weight: bold;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
width: 100px;
|
width: 100px;
|
||||||
@@ -197,7 +202,8 @@
|
|||||||
.s_form input[type=text]:focus,
|
.s_form input[type=text]:focus,
|
||||||
.s_form input[type=password]:focus,
|
.s_form input[type=password]:focus,
|
||||||
.s_form textarea:focus {
|
.s_form textarea:focus {
|
||||||
background-color: #f7f7f7; }
|
background-color: #f7f7f7;
|
||||||
|
border-color: #c4c4c4; }
|
||||||
.s_form textarea {
|
.s_form textarea {
|
||||||
resize: none; }
|
resize: none; }
|
||||||
.s_form textarea.full_height {
|
.s_form textarea.full_height {
|
||||||
@@ -250,15 +256,11 @@
|
|||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 9; }
|
z-index: 9; }
|
||||||
|
|
||||||
.toolbar .sdm, .toolbar .fn_g {
|
.toolbar .sdm, .toolbar .fn_g {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: top; }
|
vertical-align: top; }
|
||||||
|
|
||||||
.toolbar .sdm_o {
|
.toolbar .sdm_o {
|
||||||
top: 36px;
|
top: 36px; }
|
||||||
background-color: #f0f0f0; }
|
|
||||||
|
|
||||||
.toolbar button {
|
.toolbar button {
|
||||||
border: none;
|
border: none;
|
||||||
outline: none;
|
outline: none;
|
||||||
@@ -267,7 +269,6 @@
|
|||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
vertical-align: top; }
|
vertical-align: top; }
|
||||||
|
|
||||||
.toolbar .fn_btn {
|
.toolbar .fn_btn {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: top; }
|
vertical-align: top; }
|
||||||
@@ -368,10 +369,7 @@
|
|||||||
.tinycanvas:hover .scrollbar {
|
.tinycanvas:hover .scrollbar {
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
opacity: 1; }
|
opacity: 1; }
|
||||||
|
.toolbar + .tinycanvas, .s_tab + .tinycanvas {
|
||||||
.toolbar + .tinycanvas,
|
|
||||||
.s_tab + .tinycanvas {
|
|
||||||
height: 480px; }
|
height: 480px; }
|
||||||
|
|
||||||
#panel_r .tinycanvas {
|
#panel_r .tinycanvas {
|
||||||
padding: 12px 0; }
|
padding: 12px 0; }
|
||||||
@@ -58,20 +58,24 @@
|
|||||||
left: 0;
|
left: 0;
|
||||||
top: 60px;
|
top: 60px;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
|
width: 120px;
|
||||||
|
border: solid 2px $gray;
|
||||||
|
@include box-sizing;
|
||||||
|
|
||||||
|
li {
|
||||||
|
border-top: solid 1px lighten( $gray, 10% );
|
||||||
}
|
}
|
||||||
.sdm_o li {
|
li:first-child {
|
||||||
border-top: solid 1px #f2f2f2;
|
|
||||||
}
|
|
||||||
.sdm_o li:first-child {
|
|
||||||
border: none;
|
border: none;
|
||||||
}
|
}
|
||||||
.sdm_o a {
|
a {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
.sdm_o .admtxt {
|
.admtxt {
|
||||||
display: block;
|
display: block;
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* simple dropdown menu with indicator */
|
/* simple dropdown menu with indicator */
|
||||||
.sdm_mdr .sdm_t {
|
.sdm_mdr .sdm_t {
|
||||||
@@ -86,16 +90,17 @@
|
|||||||
.s_menu {
|
.s_menu {
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
|
|
||||||
|
li {
|
||||||
|
border-top: solid 1px $gray;
|
||||||
}
|
}
|
||||||
.s_menu li {
|
li:first-child {
|
||||||
border-top: solid 1px #ddd;
|
|
||||||
}
|
|
||||||
.s_menu li:first-child {
|
|
||||||
border: none;
|
border: none;
|
||||||
}
|
}
|
||||||
.s_menu a {
|
a {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* simple tabs */
|
/* simple tabs */
|
||||||
.s_tab {
|
.s_tab {
|
||||||
@@ -130,7 +135,7 @@
|
|||||||
// basic style
|
// basic style
|
||||||
label {
|
label {
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
font-weight: normal;
|
font-weight: bold;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
width: 100px;
|
width: 100px;
|
||||||
@@ -165,6 +170,7 @@
|
|||||||
|
|
||||||
&:focus {
|
&:focus {
|
||||||
background-color: lighten($gray, 10%);
|
background-color: lighten($gray, 10%);
|
||||||
|
border-color: darken($gray, 10%);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
textarea {
|
textarea {
|
||||||
@@ -228,16 +234,15 @@
|
|||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 9;
|
z-index: 9;
|
||||||
}
|
|
||||||
.toolbar .sdm, .toolbar .fn_g {
|
.sdm, .fn_g {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
}
|
}
|
||||||
.toolbar .sdm_o {
|
.sdm_o {
|
||||||
top: 36px;
|
top: 36px;
|
||||||
background-color: #f0f0f0;
|
|
||||||
}
|
}
|
||||||
.toolbar button {
|
button {
|
||||||
border: none;
|
border: none;
|
||||||
outline: none;
|
outline: none;
|
||||||
padding: 0 16px;
|
padding: 0 16px;
|
||||||
@@ -246,10 +251,11 @@
|
|||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
}
|
}
|
||||||
.toolbar .fn_btn {
|
.fn_btn {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* tiny scrollbar */
|
/* tiny scrollbar */
|
||||||
.tinycanvas {
|
.tinycanvas {
|
||||||
@@ -351,11 +357,11 @@
|
|||||||
visibility: visible;
|
visibility: visible;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
}
|
.toolbar + &,
|
||||||
.toolbar + .tinycanvas,
|
.s_tab + & {
|
||||||
.s_tab + .tinycanvas {
|
|
||||||
height: 480px;
|
height: 480px;
|
||||||
}
|
}
|
||||||
#panel_r .tinycanvas {
|
#panel_r & {
|
||||||
padding: 12px 0;
|
padding: 12px 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
@@ -54,7 +54,6 @@ table {
|
|||||||
body {
|
body {
|
||||||
font-family: "Source Sans Pro", sans-serif;
|
font-family: "Source Sans Pro", sans-serif;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
font-weight: 300;
|
|
||||||
background-color: #000; }
|
background-color: #000; }
|
||||||
|
|
||||||
a, a:hover {
|
a, a:hover {
|
||||||
@@ -70,11 +69,13 @@ a:focus {
|
|||||||
.clear:after {
|
.clear:after {
|
||||||
display: table;
|
display: table;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
content: ''; }
|
content: '';
|
||||||
|
clear: both; }
|
||||||
|
|
||||||
.o-loading {
|
.o-loading {
|
||||||
font-size: 13px;
|
font-size: 13px; }
|
||||||
font-weight: normal; }
|
.fullsize .o-loading {
|
||||||
|
padding: 12px; }
|
||||||
.o-loading i {
|
.o-loading i {
|
||||||
font-size: 20px; }
|
font-size: 20px; }
|
||||||
|
|
||||||
@@ -294,7 +295,7 @@ a:focus {
|
|||||||
|
|
||||||
.fn_des.admtxt {
|
.fn_des.admtxt {
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
padding: 0 6px;
|
padding: 0 12px;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 9;
|
z-index: 9;
|
||||||
@@ -333,8 +334,7 @@ a:focus {
|
|||||||
.section_label li {
|
.section_label li {
|
||||||
font-size: 15px; }
|
font-size: 15px; }
|
||||||
.section_label li:first-child {
|
.section_label li:first-child {
|
||||||
font-size: 18px;
|
font-size: 18px; }
|
||||||
font-weight: normal; }
|
|
||||||
|
|
||||||
/* panel */
|
/* panel */
|
||||||
#panel_l {
|
#panel_l {
|
||||||
@@ -369,8 +369,7 @@ a:focus {
|
|||||||
#orbitnote .note_holder .note_message {
|
#orbitnote .note_holder .note_message {
|
||||||
color: #333;
|
color: #333;
|
||||||
margin: 10px 0 0 48px;
|
margin: 10px 0 0 48px;
|
||||||
font-size: 15px;
|
font-size: 15px; }
|
||||||
font-weight: normal; }
|
|
||||||
|
|
||||||
/* Desktop Dialogue */
|
/* Desktop Dialogue */
|
||||||
#orbitdiag {
|
#orbitdiag {
|
||||||
@@ -401,7 +400,6 @@ a:focus {
|
|||||||
margin: 0 6px;
|
margin: 0 6px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
|
||||||
line-height: 36px; }
|
line-height: 36px; }
|
||||||
#orbitdiag .diag_holder .diag_holder_inner .diag_btn:hover {
|
#orbitdiag .diag_holder .diag_holder_inner .diag_btn:hover {
|
||||||
outline: solid 2px white; }
|
outline: solid 2px white; }
|
||||||
@@ -418,12 +416,12 @@ a:focus {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
z-index: 3; }
|
z-index: 3;
|
||||||
|
white-space: nowrap; }
|
||||||
[data-sizex="1"] .appname, .w1.h1 .appname {
|
[data-sizex="1"] .appname, .w1.h1 .appname {
|
||||||
text-align: center; }
|
text-align: center; }
|
||||||
[data-sizey="2"] .appname {
|
[data-sizey="2"] .appname {
|
||||||
font-size: 21px;
|
font-size: 21px; }
|
||||||
font-weight: normal; }
|
|
||||||
.hh2 .appname {
|
.hh2 .appname {
|
||||||
position: relative;
|
position: relative;
|
||||||
width: auto;
|
width: auto;
|
||||||
@@ -475,8 +473,12 @@ a:focus {
|
|||||||
left: 0;
|
left: 0;
|
||||||
top: 0; }
|
top: 0; }
|
||||||
|
|
||||||
|
.gridster ul {
|
||||||
|
margin: -6px 0 0 -6px; }
|
||||||
|
|
||||||
.widget.gs_w {
|
.widget.gs_w {
|
||||||
cursor: move; }
|
cursor: move;
|
||||||
|
overflow: hidden; }
|
||||||
|
|
||||||
/* header drop menu */
|
/* header drop menu */
|
||||||
.sdm_mdr .sdm_o {
|
.sdm_mdr .sdm_o {
|
||||||
@@ -507,7 +509,6 @@ a:focus {
|
|||||||
|
|
||||||
.theme_preview {
|
.theme_preview {
|
||||||
width: 528px;
|
width: 528px;
|
||||||
height: 150px;
|
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
font-size: 15px; }
|
font-size: 15px; }
|
||||||
|
|
||||||
@@ -518,15 +519,24 @@ a:focus {
|
|||||||
margin-right: 12px; }
|
margin-right: 12px; }
|
||||||
.theme_plate > div:first-child {
|
.theme_plate > div:first-child {
|
||||||
margin-right: 48px; }
|
margin-right: 48px; }
|
||||||
|
.theme_plate .g_sep {
|
||||||
|
margin-right: 0; }
|
||||||
|
|
||||||
|
#color_input th {
|
||||||
|
vertical-align: bottom; }
|
||||||
|
|
||||||
.stock_wallpaper .ssl_item {
|
.stock_wallpaper .ssl_item {
|
||||||
margin-bottom: 6px; }
|
margin-bottom: 6px; }
|
||||||
|
|
||||||
.s_title {
|
.s_title {
|
||||||
font-size: 21px;
|
font-size: 21px;
|
||||||
font-weight: normal;
|
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
text-align: left; }
|
text-align: left; }
|
||||||
|
.s_title.size_large {
|
||||||
|
font-size: 36px; }
|
||||||
|
.s_title.size_small {
|
||||||
|
font-size: 15px;
|
||||||
|
line-height: 2em; }
|
||||||
|
|
||||||
.s_subtitle {
|
.s_subtitle {
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
@@ -545,7 +555,6 @@ a:focus {
|
|||||||
display: block;
|
display: block;
|
||||||
float: right;
|
float: right;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
border: 0; }
|
border: 0; }
|
||||||
@@ -560,8 +569,18 @@ a:focus {
|
|||||||
max-width: 340px; }
|
max-width: 340px; }
|
||||||
|
|
||||||
.g_sep {
|
.g_sep {
|
||||||
width: 11px;
|
width: 12px;
|
||||||
border-left: solid 1px white; }
|
border-left: solid 1px white;
|
||||||
|
-webkit-box-sizing: border-box;
|
||||||
|
/* webkit */
|
||||||
|
-khtml-box-sizing: border-box;
|
||||||
|
/* konqueror */
|
||||||
|
-moz-box-sizing: border-box;
|
||||||
|
/* firefox */
|
||||||
|
-ms-box-sizing: border-box;
|
||||||
|
/* ie */
|
||||||
|
box-sizing: border-box;
|
||||||
|
/* css3 */ }
|
||||||
|
|
||||||
.grp {
|
.grp {
|
||||||
height: 528px;
|
height: 528px;
|
||||||
@@ -586,14 +605,12 @@ a:focus {
|
|||||||
|
|
||||||
/* list item */
|
/* list item */
|
||||||
.list_t_item {
|
.list_t_item {
|
||||||
/*padding: 2px;*/
|
|
||||||
overflow: hidden; }
|
overflow: hidden; }
|
||||||
|
|
||||||
.list_t_title {
|
.list_t_title {
|
||||||
margin-bottom: 6px;
|
margin-bottom: 6px;
|
||||||
color: #333;
|
color: #333;
|
||||||
font-size: 15px;
|
font-size: 15px; }
|
||||||
font-weight: normal; }
|
|
||||||
|
|
||||||
.list_t_des {
|
.list_t_des {
|
||||||
line-height: 1.5em;
|
line-height: 1.5em;
|
||||||
@@ -607,118 +624,74 @@ a:focus {
|
|||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
-webkit-text-size-adjust: none; }
|
-webkit-text-size-adjust: none; }
|
||||||
|
|
||||||
/* Connection Page */
|
|
||||||
#connection_setting {
|
|
||||||
height: 492px; }
|
|
||||||
|
|
||||||
#connection_setting .s_form {
|
|
||||||
float: left;
|
|
||||||
margin: 0 12px 0 0;
|
|
||||||
padding-left: 24px;
|
|
||||||
height: 100%;
|
|
||||||
border-left: solid 1px #dddddd; }
|
|
||||||
|
|
||||||
#connection_setting .s_form:first-child {
|
|
||||||
padding-left: 0;
|
|
||||||
border: none; }
|
|
||||||
|
|
||||||
#connection_setting .s_form label {
|
|
||||||
line-height: 30px; }
|
|
||||||
|
|
||||||
#connection_setting .s_form .c_icon, #connection_setting .s_form .c_name {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle; }
|
|
||||||
|
|
||||||
#connection_setting .s_form .c_name {
|
|
||||||
padding: 0 12px;
|
|
||||||
font-size: 18px; }
|
|
||||||
|
|
||||||
#connection_setting .s_form input[type=text], #connection_setting .s_form input[type=password] {
|
|
||||||
width: 202px; }
|
|
||||||
|
|
||||||
#connection_setting .setting_btn {
|
|
||||||
margin-left: 12px; }
|
|
||||||
|
|
||||||
#connection_setting .setting_btn.disable {
|
|
||||||
background-color: #ddd;
|
|
||||||
cursor: default; }
|
|
||||||
|
|
||||||
#connection_setting .c_status {
|
|
||||||
float: right;
|
|
||||||
padding: 6px;
|
|
||||||
background-color: #eee;
|
|
||||||
color: #ccc;
|
|
||||||
font-size: 9px;
|
|
||||||
font-weight: normal;
|
|
||||||
-webkit-text-size-adjust: none;
|
|
||||||
-webkit-transition: background-color 0.5s ease;
|
|
||||||
-moz-transition: background-color 0.5s ease;
|
|
||||||
transition: background-color 0.5s ease; }
|
|
||||||
|
|
||||||
#connection_setting .c_status_on {
|
|
||||||
background-color: #51A351;
|
|
||||||
color: #fff; }
|
|
||||||
|
|
||||||
#connection_setting .c_info {
|
|
||||||
padding: 7px 6px;
|
|
||||||
background-color: #fcfcfc;
|
|
||||||
cursor: default;
|
|
||||||
font-size: 18px;
|
|
||||||
font-weight: normal; }
|
|
||||||
|
|
||||||
/* Journal Papers */
|
/* Journal Papers */
|
||||||
[page-name="journal_p_list"] .list_t_item .inner {
|
[page-name="journal_p_list"] .list_t_item .inner {
|
||||||
padding-left: 30px; }
|
padding-left: 30px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action {
|
[page-name="journal_p_list"] .list_item_action {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
float: left;
|
float: left;
|
||||||
margin-left: -30px; }
|
margin-left: -30px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action a {
|
[page-name="journal_p_list"] .list_item_action a {
|
||||||
display: block;
|
display: block;
|
||||||
width: 20px;
|
width: 20px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
margin: 1px 1px 6px 1px; }
|
margin: 1px 1px 6px 1px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-star-empty {
|
[page-name="journal_p_list"] .list_item_action .icon-star-empty {
|
||||||
color: #999;
|
color: #999;
|
||||||
font-size: 20px; }
|
font-size: 20px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-star {
|
[page-name="journal_p_list"] .list_item_action .icon-star {
|
||||||
color: #faa732;
|
color: #faa732;
|
||||||
font-size: 20px; }
|
font-size: 20px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-check-empty {
|
[page-name="journal_p_list"] .list_item_action .icon-check-empty {
|
||||||
color: #999;
|
color: #999;
|
||||||
font-size: 20px; }
|
font-size: 20px; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-check {
|
[page-name="journal_p_list"] .list_item_action .icon-check {
|
||||||
color: #333;
|
color: #333;
|
||||||
font-size: 20px; }
|
font-size: 20px; }
|
||||||
|
[page-name="journal_p_list"] .file_view .list_t_des {
|
||||||
[page-name="journal_p_list"] .list_t_item.file_view {
|
overflow: hidden; }
|
||||||
height: 148px; }
|
|
||||||
|
|
||||||
[page-name="journal_p_list"] .file_view .file {
|
[page-name="journal_p_list"] .file_view .file {
|
||||||
display: inline-block;
|
float: left;
|
||||||
width: 62px;
|
width: 120px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
text-align: center; }
|
padding: 6px;
|
||||||
|
margin: 1px;
|
||||||
|
position: relative;
|
||||||
|
-webkit-box-sizing: border-box;
|
||||||
|
/* webkit */
|
||||||
|
-khtml-box-sizing: border-box;
|
||||||
|
/* konqueror */
|
||||||
|
-moz-box-sizing: border-box;
|
||||||
|
/* firefox */
|
||||||
|
-ms-box-sizing: border-box;
|
||||||
|
/* ie */
|
||||||
|
box-sizing: border-box;
|
||||||
|
/* css3 */ }
|
||||||
[page-name="journal_p_list"] .file_view .file:hover {
|
[page-name="journal_p_list"] .file_view .file:hover {
|
||||||
background-color: #ddd; }
|
background-color: #f7f7f7; }
|
||||||
|
|
||||||
[page-name="journal_p_list"] .file_view .file img {
|
[page-name="journal_p_list"] .file_view .file img {
|
||||||
width: 24px;
|
width: 38px;
|
||||||
|
height: 38px;
|
||||||
|
position: absolute;
|
||||||
|
left: 6px;
|
||||||
|
top: 6px; }
|
||||||
|
[page-name="journal_p_list"] .file_view .file .filetitle {
|
||||||
display: block;
|
display: block;
|
||||||
margin: 0 auto;
|
width: 100%;
|
||||||
margin-top: 4px; }
|
height: 38px;
|
||||||
|
padding-left: 40px;
|
||||||
[page-name="journal_p_list"] .file_view .filetitle {
|
overflow: hidden;
|
||||||
font-size: 11px;
|
-webkit-box-sizing: border-box;
|
||||||
-webkit-text-size-adjust: none; }
|
/* webkit */
|
||||||
|
-khtml-box-sizing: border-box;
|
||||||
|
/* konqueror */
|
||||||
|
-moz-box-sizing: border-box;
|
||||||
|
/* firefox */
|
||||||
|
-ms-box-sizing: border-box;
|
||||||
|
/* ie */
|
||||||
|
box-sizing: border-box;
|
||||||
|
/* css3 */ }
|
||||||
|
|
||||||
/* Journal Paper Add */
|
/* Journal Paper Add */
|
||||||
#paper_add .s_grid_con {
|
#paper_add .s_grid_con {
|
||||||
@@ -727,27 +700,22 @@ a:focus {
|
|||||||
margin-left: 12px;
|
margin-left: 12px;
|
||||||
padding-left: 12px;
|
padding-left: 12px;
|
||||||
border-left: solid 1px #eeeeee; }
|
border-left: solid 1px #eeeeee; }
|
||||||
|
|
||||||
#paper_add .s_grid_con:first-child {
|
#paper_add .s_grid_con:first-child {
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
border: none; }
|
border: none; }
|
||||||
|
|
||||||
#paper_add .f_w {
|
#paper_add .f_w {
|
||||||
width: 336px; }
|
width: 336px; }
|
||||||
|
|
||||||
#paper_add label {
|
#paper_add label {
|
||||||
margin-right: 0; }
|
margin-right: 0; }
|
||||||
|
|
||||||
/* Journal Journal list */
|
/* Journal Journal list */
|
||||||
[page-name="journal_p_journal"] .datalist_item .inner {
|
[page-name="journal_p_journal"] .datalist_item .inner {
|
||||||
padding-left: 30px; }
|
padding-left: 30px; }
|
||||||
|
|
||||||
[page-name="journal_p_journal"] .list_item_action {
|
[page-name="journal_p_journal"] .list_item_action {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
float: left;
|
float: left;
|
||||||
margin-left: -30px; }
|
margin-left: -30px; }
|
||||||
|
|
||||||
[page-name="journal_p_journal"] .list_item_action i {
|
[page-name="journal_p_journal"] .list_item_action i {
|
||||||
color: #999;
|
color: #999;
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
@@ -756,7 +724,6 @@ a:focus {
|
|||||||
height: 20px;
|
height: 20px;
|
||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
margin: 1px 1px 6px 1px; }
|
margin: 1px 1px 6px 1px; }
|
||||||
|
|
||||||
[page-name="journal_p_journal"] .list_t_desc {
|
[page-name="journal_p_journal"] .list_t_desc {
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
@@ -765,21 +732,17 @@ a:focus {
|
|||||||
/* Journal Co-Author */
|
/* Journal Co-Author */
|
||||||
[page-name="journal_p_coauthor"] .list_t_item {
|
[page-name="journal_p_coauthor"] .list_t_item {
|
||||||
height: 110px; }
|
height: 110px; }
|
||||||
|
|
||||||
[page-name="journal_p_coauthor"] .list_item_function a {
|
[page-name="journal_p_coauthor"] .list_item_function a {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
-webkit-text-size-adjust: none; }
|
-webkit-text-size-adjust: none; }
|
||||||
|
|
||||||
[page-name="journal_p_coauthor"] .info {
|
[page-name="journal_p_coauthor"] .info {
|
||||||
font-family: Arial, sans-serif; }
|
font-family: Arial, sans-serif; }
|
||||||
|
|
||||||
[page-name="journal_p_coauthor"] .info li {
|
[page-name="journal_p_coauthor"] .info li {
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
color: #999; }
|
color: #999; }
|
||||||
|
|
||||||
[page-name="journal_p_coauthor"] .info .name {
|
[page-name="journal_p_coauthor"] .info .name {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
line-height: 24px;
|
line-height: 24px;
|
||||||
@@ -788,7 +751,6 @@ a:focus {
|
|||||||
/* Journal Co-Author Relationship*/
|
/* Journal Co-Author Relationship*/
|
||||||
[page-name="journal_p_coauthor_relation"] .edit_co_author_relation {
|
[page-name="journal_p_coauthor_relation"] .edit_co_author_relation {
|
||||||
/*margin-left: -10px;*/ }
|
/*margin-left: -10px;*/ }
|
||||||
|
|
||||||
[page-name="journal_p_coauthor_relation"] .form_space {
|
[page-name="journal_p_coauthor_relation"] .form_space {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
@@ -809,12 +771,10 @@ a:focus {
|
|||||||
right: 0;
|
right: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
z-index: 12; }
|
z-index: 12; }
|
||||||
|
|
||||||
.app_frame .app_holder {
|
.app_frame .app_holder {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%; }
|
width: 100%; }
|
||||||
|
|
||||||
.app_frame #header .icon-remove {
|
.app_frame #header .icon-remove {
|
||||||
display: block;
|
display: block;
|
||||||
float: right;
|
float: right;
|
||||||
|
|||||||
@@ -66,11 +66,15 @@ a:focus { outline: none; }
|
|||||||
display: table;
|
display: table;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
content: '';
|
content: '';
|
||||||
|
clear: both;
|
||||||
}
|
}
|
||||||
.o-loading {
|
.o-loading {
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
|
|
||||||
|
.fullsize & {
|
||||||
|
padding: 12px;
|
||||||
|
}
|
||||||
i {
|
i {
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
}
|
}
|
||||||
@@ -227,7 +231,7 @@ a:focus { outline: none; }
|
|||||||
}
|
}
|
||||||
.fn_des.admtxt {
|
.fn_des.admtxt {
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
padding: 0 6px;
|
padding: 0 12px;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 9;
|
z-index: 9;
|
||||||
@@ -273,10 +277,9 @@ a:focus { outline: none; }
|
|||||||
}
|
}
|
||||||
li:first-child {
|
li:first-child {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* panel */
|
/* panel */
|
||||||
#panel_l {
|
#panel_l {
|
||||||
background-color: #f0f0f0;
|
background-color: #f0f0f0;
|
||||||
@@ -317,7 +320,7 @@ a:focus { outline: none; }
|
|||||||
color: #333;
|
color: #333;
|
||||||
margin: 10px 0 0 48px;
|
margin: 10px 0 0 48px;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -357,7 +360,7 @@ a:focus { outline: none; }
|
|||||||
margin: 0 6px;
|
margin: 0 6px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@@ -382,6 +385,7 @@ a:focus { outline: none; }
|
|||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
z-index: 3;
|
z-index: 3;
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
[data-sizex="1"] &,
|
[data-sizex="1"] &,
|
||||||
.w1.h1 & {
|
.w1.h1 & {
|
||||||
@@ -389,7 +393,7 @@ a:focus { outline: none; }
|
|||||||
}
|
}
|
||||||
[data-sizey="2"] & {
|
[data-sizey="2"] & {
|
||||||
font-size: 21px;
|
font-size: 21px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
}
|
}
|
||||||
.hh2 & {
|
.hh2 & {
|
||||||
position: relative;
|
position: relative;
|
||||||
@@ -417,8 +421,6 @@ a:focus { outline: none; }
|
|||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.appholder {
|
.appholder {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
@@ -451,9 +453,18 @@ a:focus { outline: none; }
|
|||||||
left: 0;
|
left: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
|
.gridster ul {
|
||||||
|
margin: -6px 0 0 -6px;
|
||||||
|
}
|
||||||
.widget.gs_w {
|
.widget.gs_w {
|
||||||
cursor: move;
|
cursor: move;
|
||||||
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
// .app.gs_w:active {
|
||||||
|
// -webkit-transform: scale(0.9);
|
||||||
|
// -moz-transform: scale(0.9);
|
||||||
|
// transform: scale(0.9);
|
||||||
|
// }
|
||||||
|
|
||||||
/* header drop menu */
|
/* header drop menu */
|
||||||
.sdm_mdr .sdm_o { top: 36px; }
|
.sdm_mdr .sdm_o { top: 36px; }
|
||||||
@@ -484,7 +495,6 @@ a:focus { outline: none; }
|
|||||||
}
|
}
|
||||||
.theme_preview {
|
.theme_preview {
|
||||||
width: 528px;
|
width: 528px;
|
||||||
height: 150px;
|
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
}
|
}
|
||||||
@@ -498,6 +508,12 @@ a:focus { outline: none; }
|
|||||||
> div:first-child {
|
> div:first-child {
|
||||||
margin-right: 48px;
|
margin-right: 48px;
|
||||||
}
|
}
|
||||||
|
.g_sep {
|
||||||
|
margin-right: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#color_input th {
|
||||||
|
vertical-align: bottom
|
||||||
}
|
}
|
||||||
.stock_wallpaper {
|
.stock_wallpaper {
|
||||||
.ssl_item {
|
.ssl_item {
|
||||||
@@ -507,9 +523,17 @@ a:focus { outline: none; }
|
|||||||
|
|
||||||
.s_title {
|
.s_title {
|
||||||
font-size: 21px;
|
font-size: 21px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
|
||||||
|
&.size_large {
|
||||||
|
font-size: 36px;
|
||||||
|
}
|
||||||
|
&.size_small {
|
||||||
|
font-size: 15px;
|
||||||
|
line-height: 2em;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.s_subtitle {
|
.s_subtitle {
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
@@ -528,7 +552,7 @@ a:focus { outline: none; }
|
|||||||
display: block;
|
display: block;
|
||||||
float: right;
|
float: right;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
line-height: 36px;
|
line-height: 36px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
border: 0;
|
border: 0;
|
||||||
@@ -546,9 +570,9 @@ a:focus { outline: none; }
|
|||||||
max-width: 340px;
|
max-width: 340px;
|
||||||
}
|
}
|
||||||
.g_sep {
|
.g_sep {
|
||||||
width: 11px;
|
width: 12px;
|
||||||
border-left:
|
border-left: solid 1px #fff;
|
||||||
solid 1px #fff;
|
@include box-sizing;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -572,12 +596,12 @@ a:focus { outline: none; }
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* list item */
|
/* list item */
|
||||||
.list_t_item { /*padding: 2px;*/ overflow: hidden; }
|
.list_t_item { overflow: hidden; }
|
||||||
.list_t_title {
|
.list_t_title {
|
||||||
margin-bottom: 6px;
|
margin-bottom: 6px;
|
||||||
color: #333;
|
color: #333;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-weight: normal;
|
// font-weight: normal;
|
||||||
}
|
}
|
||||||
.list_t_des {
|
.list_t_des {
|
||||||
line-height: 1.5em;
|
line-height: 1.5em;
|
||||||
@@ -592,108 +616,93 @@ a:focus { outline: none; }
|
|||||||
-webkit-text-size-adjust: none;
|
-webkit-text-size-adjust: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Connection Page */
|
|
||||||
#connection_setting { height: 492px; }
|
|
||||||
#connection_setting .s_form {
|
|
||||||
float: left;
|
|
||||||
margin: 0 12px 0 0;
|
|
||||||
padding-left: 24px;
|
|
||||||
height: 100%;
|
|
||||||
border-left: solid 1px #ddd;
|
|
||||||
}
|
|
||||||
#connection_setting .s_form:first-child { padding-left: 0; border: none; }
|
|
||||||
#connection_setting .s_form label { line-height: 30px; }
|
|
||||||
#connection_setting .s_form .c_icon, #connection_setting .s_form .c_name {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle;
|
|
||||||
}
|
|
||||||
#connection_setting .s_form .c_name { padding: 0 12px; font-size: 18px; }
|
|
||||||
#connection_setting .s_form input[type=text], #connection_setting .s_form input[type=password] { width: 202px; }
|
|
||||||
#connection_setting .setting_btn { margin-left: 12px; }
|
|
||||||
#connection_setting .setting_btn.disable { background-color: #ddd; cursor: default; }
|
|
||||||
#connection_setting .c_status {
|
|
||||||
float: right;
|
|
||||||
padding: 6px;
|
|
||||||
background-color: #eee;
|
|
||||||
color: #ccc;
|
|
||||||
font-size: 9px;
|
|
||||||
font-weight: normal;
|
|
||||||
-webkit-text-size-adjust: none;
|
|
||||||
@include transition-type("background-color",0.5);
|
|
||||||
}
|
|
||||||
#connection_setting .c_status_on { background-color: #51A351; color: #fff; }
|
|
||||||
#connection_setting .c_info {
|
|
||||||
padding: 7px 6px;
|
|
||||||
background-color: #fcfcfc;
|
|
||||||
cursor: default;
|
|
||||||
font-size: 18px;
|
|
||||||
font-weight: normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Journal Papers */
|
/* Journal Papers */
|
||||||
[page-name="journal_p_list"] .list_t_item .inner { padding-left: 30px; }
|
[page-name="journal_p_list"] {
|
||||||
[page-name="journal_p_list"] .list_item_action {
|
.list_t_item .inner { padding-left: 30px; }
|
||||||
|
.list_item_action {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
float: left;
|
float: left;
|
||||||
margin-left: -30px;
|
margin-left: -30px;
|
||||||
}
|
|
||||||
[page-name="journal_p_list"] .list_item_action a {
|
a {
|
||||||
display: block;
|
display: block;
|
||||||
width: 20px;
|
width: 20px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
margin: 1px 1px 6px 1px;
|
margin: 1px 1px 6px 1px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-star-empty { color: #999; font-size: 20px; }
|
.icon-star-empty { color: #999; font-size: 20px; }
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-star { color: #faa732; font-size: 20px; }
|
.icon-star { color: #faa732; font-size: 20px; }
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-check-empty { color: #999; font-size: 20px; }
|
.icon-check-empty { color: #999; font-size: 20px; }
|
||||||
[page-name="journal_p_list"] .list_item_action .icon-check { color: #333; font-size: 20px; }
|
.icon-check { color: #333; font-size: 20px; }
|
||||||
|
}
|
||||||
|
|
||||||
[page-name="journal_p_list"] .list_t_item.file_view {
|
.file_view {
|
||||||
height: 148px;
|
.list_t_des {
|
||||||
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_list"] .file_view .file {
|
.file {
|
||||||
display: inline-block;
|
float: left;
|
||||||
width: 62px;
|
width: 120px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
text-align: center;
|
padding: 6px;
|
||||||
|
margin: 1px;
|
||||||
|
position: relative;
|
||||||
|
@include box-sizing;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
background-color: lighten($gray, 10%);
|
||||||
}
|
}
|
||||||
[page-name="journal_p_list"] .file_view .file:hover {
|
img {
|
||||||
background-color: #ddd;
|
width: 38px;
|
||||||
|
height: 38px;
|
||||||
|
position: absolute;
|
||||||
|
left: 6px;
|
||||||
|
top: 6px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_list"] .file_view .file img {
|
.filetitle {
|
||||||
width: 24px;
|
|
||||||
display: block;
|
display: block;
|
||||||
margin: 0 auto;
|
width: 100%;
|
||||||
margin-top: 4px;
|
height: 38px;
|
||||||
|
padding-left: 40px;
|
||||||
|
overflow: hidden;
|
||||||
|
@include box-sizing;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
[page-name="journal_p_list"] .file_view .filetitle {
|
|
||||||
font-size: 11px;
|
|
||||||
-webkit-text-size-adjust: none;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Journal Paper Add */
|
/* Journal Paper Add */
|
||||||
#paper_add .s_grid_con {
|
#paper_add {
|
||||||
|
.s_grid_con {
|
||||||
float: left;
|
float: left;
|
||||||
height: 456px;
|
height: 456px;
|
||||||
margin-left: 12px;
|
margin-left: 12px;
|
||||||
padding-left: 12px;
|
padding-left: 12px;
|
||||||
border-left: solid 1px #eee;
|
border-left: solid 1px #eee;
|
||||||
|
|
||||||
|
&:first-child {
|
||||||
|
margin-left: 0;
|
||||||
|
padding-left: 0;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.f_w { width: 336px; }
|
||||||
|
label { margin-right: 0; }
|
||||||
}
|
}
|
||||||
#paper_add .s_grid_con:first-child { margin-left: 0; padding-left: 0; border: none; }
|
|
||||||
#paper_add .f_w { width: 336px; }
|
|
||||||
#paper_add label { margin-right: 0; }
|
|
||||||
|
|
||||||
/* Journal Journal list */
|
/* Journal Journal list */
|
||||||
[page-name="journal_p_journal"] .datalist_item .inner {
|
[page-name="journal_p_journal"] {
|
||||||
|
|
||||||
|
.datalist_item .inner {
|
||||||
padding-left: 30px;
|
padding-left: 30px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_journal"] .list_item_action {
|
.list_item_action {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
float: left;
|
float: left;
|
||||||
margin-left: -30px;
|
margin-left: -30px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_journal"] .list_item_action i {
|
.list_item_action i {
|
||||||
color: #999;
|
color: #999;
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
display: block;
|
display: block;
|
||||||
@@ -702,46 +711,51 @@ a:focus { outline: none; }
|
|||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
margin: 1px 1px 6px 1px;
|
margin: 1px 1px 6px 1px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_journal"] .list_t_desc {
|
.list_t_desc {
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #999;
|
color: #999;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Journal Co-Author */
|
/* Journal Co-Author */
|
||||||
[page-name="journal_p_coauthor"] {}
|
[page-name="journal_p_coauthor"] {
|
||||||
[page-name="journal_p_coauthor"] .list_t_item {
|
.list_t_item {
|
||||||
height: 110px;
|
height: 110px;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_coauthor"] .list_item_function {}
|
.list_item_function {}
|
||||||
[page-name="journal_p_coauthor"] .list_item_function a {
|
.list_item_function a {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
-webkit-text-size-adjust: none;
|
-webkit-text-size-adjust: none;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_coauthor"] .info {
|
.info {
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_coauthor"] .info li {
|
.info li {
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
color: #999;
|
color: #999;
|
||||||
}
|
}
|
||||||
[page-name="journal_p_coauthor"] .info .name {
|
.info .name {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
line-height: 24px;
|
line-height: 24px;
|
||||||
color: #333;
|
color: #333;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Journal Co-Author Relationship*/
|
/* Journal Co-Author Relationship*/
|
||||||
[page-name="journal_p_coauthor_relation"] .edit_co_author_relation {
|
[page-name="journal_p_coauthor_relation"]{
|
||||||
|
.edit_co_author_relation {
|
||||||
/*margin-left: -10px;*/
|
/*margin-left: -10px;*/
|
||||||
}
|
}
|
||||||
[page-name="journal_p_coauthor_relation"] .form_space {
|
.form_space {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
/* Journal New Co-Author */
|
/* Journal New Co-Author */
|
||||||
#new_co_author label {
|
#new_co_author label {
|
||||||
margin-right: 0;
|
margin-right: 0;
|
||||||
@@ -759,19 +773,20 @@ a:focus { outline: none; }
|
|||||||
right: 0;
|
right: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
z-index: 12;
|
z-index: 12;
|
||||||
}
|
|
||||||
.app_frame .app_holder {
|
.app_holder {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
.app_frame #header .icon-remove {
|
#header .icon-remove {
|
||||||
display: block;
|
display: block;
|
||||||
float: right;
|
float: right;
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*Tooltip popup */
|
/*Tooltip popup */
|
||||||
.desktop_toolpopup {
|
.desktop_toolpopup {
|
||||||
|
|||||||
+27
-30
@@ -65,7 +65,7 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
font-size: 1px;
|
font-size: 1px;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
border: 0;
|
border: 0;
|
||||||
background: url(<%= asset_path "desktop/select2/select2.png" %>) right top no-repeat;
|
background: url("select2/select2.png") right top no-repeat;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
outline: 0; }
|
outline: 0; }
|
||||||
|
|
||||||
@@ -86,24 +86,21 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 9999;
|
z-index: 9999;
|
||||||
top: 100%;
|
top: 100%;
|
||||||
background: #fff;
|
background-color: #fff;
|
||||||
color: #000;
|
color: #000;
|
||||||
border: 1px solid #dddddd;
|
border: 2px solid #dddddd; }
|
||||||
border-top: 0; }
|
|
||||||
|
|
||||||
.select2-drop.select2-drop-above {
|
.select2-drop.select2-drop-above {
|
||||||
margin-top: 1px;
|
margin-top: 1px; }
|
||||||
border-top: 1px solid #dddddd;
|
|
||||||
border-bottom: 0; }
|
|
||||||
|
|
||||||
.select2-container .select2-choice div {
|
.select2-container .select2-choice div {
|
||||||
display: block;
|
display: block;
|
||||||
width: 20px;
|
width: 21px;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0;
|
right: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
background: #ccc;
|
border-left: solid 1px #dddddd;
|
||||||
-webkit-box-sizing: border-box;
|
-webkit-box-sizing: border-box;
|
||||||
/* webkit */
|
/* webkit */
|
||||||
-khtml-box-sizing: border-box;
|
-khtml-box-sizing: border-box;
|
||||||
@@ -119,7 +116,7 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background: url(<%= asset_path "desktop/select2/select2.png" %>) no-repeat 0 1px; }
|
background: url("select2/select2.png") no-repeat 0 50%; }
|
||||||
|
|
||||||
.select2-search {
|
.select2-search {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
@@ -152,29 +149,25 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
margin-top: 4px; }
|
margin-top: 4px; }
|
||||||
|
|
||||||
.select2-search input.select2-active {
|
.select2-search input.select2-active {
|
||||||
background: white image-url(<%= asset_path "desktop/select2/select2-spinner.gif" %>) no-repeat 100%; }
|
background: white image-url("select2-spinner.gif") no-repeat 100%; }
|
||||||
|
|
||||||
.select2-container-active .select2-choice,
|
.select2-container-active .select2-choice,
|
||||||
.select2-container-active .select2-choices {
|
.select2-container-active .select2-choices {
|
||||||
outline: none; }
|
outline: none; }
|
||||||
|
|
||||||
.select2-dropdown-open .select2-choice {
|
.select2-dropdown-open .select2-choice {
|
||||||
border-bottom-color: transparent;
|
border-bottom-color: transparent; }
|
||||||
background-color: #eee; }
|
|
||||||
|
|
||||||
.select2-dropdown-open .select2-choice div {
|
.select2-dropdown-open .select2-choice div {
|
||||||
background: transparent;
|
background-color: #dddddd;
|
||||||
border-left: none;
|
|
||||||
filter: none; }
|
filter: none; }
|
||||||
|
|
||||||
.select2-dropdown-open .select2-choice div b {
|
.select2-dropdown-open .select2-choice div b {
|
||||||
background-position: -18px 1px; }
|
background-position: -20px 50%; }
|
||||||
|
|
||||||
/* results */
|
/* results */
|
||||||
.select2-results {
|
.select2-results {
|
||||||
max-height: 200px;
|
max-height: 200px;
|
||||||
padding: 0 0 0 4px;
|
|
||||||
margin: 4px 4px 4px 0;
|
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
position: relative;
|
position: relative;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
@@ -208,13 +201,16 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
.select2-results li {
|
.select2-results li {
|
||||||
list-style: none;
|
list-style: none;
|
||||||
display: list-item;
|
display: list-item;
|
||||||
background-image: none; }
|
background-image: none;
|
||||||
|
border-top: solid 1px #f7f7f7; }
|
||||||
|
.select2-results li :first-child {
|
||||||
|
border-top: 0; }
|
||||||
|
|
||||||
.select2-results li.select2-result-with-children > .select2-result-label {
|
.select2-results li.select2-result-with-children > .select2-result-label {
|
||||||
font-weight: bold; }
|
font-weight: bold; }
|
||||||
|
|
||||||
.select2-results .select2-result-label {
|
.select2-results .select2-result-label {
|
||||||
padding: 4px 6px;
|
padding: 6px;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
-webkit-touch-callout: none;
|
-webkit-touch-callout: none;
|
||||||
@@ -265,7 +261,7 @@ disabled look for disabled choices in the results dropdown
|
|||||||
display: none; }
|
display: none; }
|
||||||
|
|
||||||
.select2-more-results.select2-active {
|
.select2-more-results.select2-active {
|
||||||
background: #f4f4f4 image-url(<%= asset_path "desktop/select2/select2-spinner.gif" %>) no-repeat 100%; }
|
background: #f4f4f4 image-url("select2-spinner.gif") no-repeat 100%; }
|
||||||
|
|
||||||
.select2-more-results {
|
.select2-more-results {
|
||||||
background: #f4f4f4;
|
background: #f4f4f4;
|
||||||
@@ -327,7 +323,7 @@ disabled look for disabled choices in the results dropdown
|
|||||||
background: transparent !important; }
|
background: transparent !important; }
|
||||||
|
|
||||||
.select2-container-multi .select2-choices .select2-search-field input.select2-active {
|
.select2-container-multi .select2-choices .select2-search-field input.select2-active {
|
||||||
background: white image-url(<%= asset_path "desktop/select2/select2-spinner.gif" %>) no-repeat 100% !important; }
|
background: white image-url("select2-spinner.gif") no-repeat 100% !important; }
|
||||||
|
|
||||||
.select2-default {
|
.select2-default {
|
||||||
color: #999999 !important; }
|
color: #999999 !important; }
|
||||||
@@ -356,23 +352,23 @@ disabled look for disabled choices in the results dropdown
|
|||||||
|
|
||||||
.select2-search-choice-close {
|
.select2-search-choice-close {
|
||||||
display: block;
|
display: block;
|
||||||
width: 12px;
|
width: 10px;
|
||||||
height: 13px;
|
height: 10px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 3px;
|
right: 3px;
|
||||||
top: 4px;
|
top: 5px;
|
||||||
font-size: 1px;
|
font-size: 1px;
|
||||||
outline: none;
|
outline: none;
|
||||||
background: url(<%= asset_path "desktop/select2/select2.png" %>) right top no-repeat; }
|
background: url("select2/select2.png") right top no-repeat; }
|
||||||
|
|
||||||
.select2-container-multi .select2-search-choice-close {
|
.select2-container-multi .select2-search-choice-close {
|
||||||
left: 3px; }
|
left: 3px; }
|
||||||
|
|
||||||
.select2-container-multi .select2-choices .select2-search-choice .select2-search-choice-close:hover {
|
.select2-container-multi .select2-choices .select2-search-choice .select2-search-choice-close:hover {
|
||||||
background-position: right -11px; }
|
background-position: right -20px; }
|
||||||
|
|
||||||
.select2-container-multi .select2-choices .select2-search-choice-focus .select2-search-choice-close {
|
.select2-container-multi .select2-choices .select2-search-choice-focus .select2-search-choice-close {
|
||||||
background-position: right -11px; }
|
background-position: right -20px; }
|
||||||
|
|
||||||
/* disabled styles */
|
/* disabled styles */
|
||||||
.select2-container-multi.select2-container-disabled .select2-choices {
|
.select2-container-multi.select2-container-disabled .select2-choices {
|
||||||
@@ -397,12 +393,13 @@ disabled look for disabled choices in the results dropdown
|
|||||||
|
|
||||||
.select2-offscreen {
|
.select2-offscreen {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -10000px; }
|
left: -10000px;
|
||||||
|
top: 0; }
|
||||||
|
|
||||||
/* Retina-ize icons */
|
/* Retina-ize icons */
|
||||||
@media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-resolution: 144dpi) {
|
@media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-resolution: 144dpi) {
|
||||||
.select2-search input, .select2-search-choice-close, .select2-container .select2-choice abbr, .select2-container .select2-choice div b {
|
.select2-search input, .select2-search-choice-close, .select2-container .select2-choice abbr, .select2-container .select2-choice div b {
|
||||||
background-image: url(<%= asset_path "desktop/select2/select2x2.png" %>) !important;
|
background-image: url("select2/select2x2.png") !important;
|
||||||
background-repeat: no-repeat !important;
|
background-repeat: no-repeat !important;
|
||||||
background-size: 60px 40px !important; }
|
background-size: 60px 40px !important; }
|
||||||
|
|
||||||
@@ -86,27 +86,26 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 9999;
|
z-index: 9999;
|
||||||
top: 100%;
|
top: 100%;
|
||||||
|
background-color: #fff;
|
||||||
background: #fff;
|
|
||||||
color: #000;
|
color: #000;
|
||||||
border: 1px solid $gray;
|
border: 2px solid $gray;
|
||||||
border-top: 0;
|
// border-top: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-drop.select2-drop-above {
|
.select2-drop.select2-drop-above {
|
||||||
margin-top: 1px;
|
margin-top: 1px;
|
||||||
border-top: 1px solid $gray;
|
// border-top: 1px solid $gray;
|
||||||
border-bottom: 0;
|
// border-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-container .select2-choice div {
|
.select2-container .select2-choice div {
|
||||||
display: block;
|
display: block;
|
||||||
width: 20px;
|
width: 21px;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0;
|
right: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
background: #ccc;
|
border-left: solid 1px $gray;
|
||||||
@include box-sizing;
|
@include box-sizing;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -114,7 +113,7 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background: url('select2/select2.png') no-repeat 0 1px;
|
background: url('select2/select2.png') no-repeat 0 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-search {
|
.select2-search {
|
||||||
@@ -167,23 +166,22 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
|
|
||||||
.select2-dropdown-open .select2-choice {
|
.select2-dropdown-open .select2-choice {
|
||||||
border-bottom-color: transparent;
|
border-bottom-color: transparent;
|
||||||
background-color: #eee;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-dropdown-open .select2-choice div {
|
.select2-dropdown-open .select2-choice div {
|
||||||
background: transparent;
|
background-color: $gray;
|
||||||
border-left: none;
|
// border-left: none;
|
||||||
filter: none;
|
filter: none;
|
||||||
}
|
}
|
||||||
.select2-dropdown-open .select2-choice div b {
|
.select2-dropdown-open .select2-choice div b {
|
||||||
background-position: -18px 1px;
|
background-position: -20px 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* results */
|
/* results */
|
||||||
.select2-results {
|
.select2-results {
|
||||||
max-height: 200px;
|
max-height: 200px;
|
||||||
padding: 0 0 0 4px;
|
// padding: 0 0 0 4px;
|
||||||
margin: 4px 4px 4px 0;
|
// margin: 4px 4px 4px 0;
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
position: relative;
|
position: relative;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
@@ -207,6 +205,11 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
list-style: none;
|
list-style: none;
|
||||||
display: list-item;
|
display: list-item;
|
||||||
background-image: none;
|
background-image: none;
|
||||||
|
border-top: solid 1px lighten($gray, 10%);
|
||||||
|
|
||||||
|
:first-child {
|
||||||
|
border-top: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-results li.select2-result-with-children > .select2-result-label {
|
.select2-results li.select2-result-with-children > .select2-result-label {
|
||||||
@@ -214,7 +217,7 @@ Version: 3.3.1 Timestamp: Wed Feb 20 09:57:22 PST 2013
|
|||||||
}
|
}
|
||||||
|
|
||||||
.select2-results .select2-result-label {
|
.select2-results .select2-result-label {
|
||||||
padding: 4px 6px;
|
padding: 6px;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
@@ -377,11 +380,11 @@ disabled look for disabled choices in the results dropdown
|
|||||||
|
|
||||||
.select2-search-choice-close {
|
.select2-search-choice-close {
|
||||||
display: block;
|
display: block;
|
||||||
width: 12px;
|
width: 10px;
|
||||||
height: 13px;
|
height: 10px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 3px;
|
right: 3px;
|
||||||
top: 4px;
|
top: 5px;
|
||||||
font-size: 1px;
|
font-size: 1px;
|
||||||
outline: none;
|
outline: none;
|
||||||
background: url('select2/select2.png') right top no-repeat;
|
background: url('select2/select2.png') right top no-repeat;
|
||||||
@@ -392,10 +395,10 @@ disabled look for disabled choices in the results dropdown
|
|||||||
}
|
}
|
||||||
|
|
||||||
.select2-container-multi .select2-choices .select2-search-choice .select2-search-choice-close:hover {
|
.select2-container-multi .select2-choices .select2-search-choice .select2-search-choice-close:hover {
|
||||||
background-position: right -11px;
|
background-position: right -20px;
|
||||||
}
|
}
|
||||||
.select2-container-multi .select2-choices .select2-search-choice-focus .select2-search-choice-close {
|
.select2-container-multi .select2-choices .select2-search-choice-focus .select2-search-choice-close {
|
||||||
background-position: right -11px;
|
background-position: right -20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* disabled styles */
|
/* disabled styles */
|
||||||
@@ -427,6 +430,7 @@ disabled look for disabled choices in the results dropdown
|
|||||||
.select2-offscreen {
|
.select2-offscreen {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -10000px;
|
left: -10000px;
|
||||||
|
top: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Retina-ize icons */
|
/* Retina-ize icons */
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ class Admin::DashboardsController < OrbitBackendController
|
|||||||
# before_filter :is_admin?
|
# before_filter :is_admin?
|
||||||
|
|
||||||
def index
|
def index
|
||||||
|
check_backend_openness
|
||||||
@module_app_contents, @module_app_contents_total = get_module_app_count('bulletin', 'page_context', 'web_link')
|
@module_app_contents, @module_app_contents_total = get_module_app_count('bulletin', 'page_context', 'web_link')
|
||||||
@recent_updated = get_recently_updated('bulletin', 'page_context', 'web_link')
|
@recent_updated = get_recently_updated('bulletin', 'page_context', 'web_link')
|
||||||
@most_visited = get_most_visited('bulletin', 'page_context')
|
@most_visited = get_most_visited('bulletin', 'page_context')
|
||||||
|
|||||||
@@ -148,7 +148,22 @@ include Admin::FrontendWidgetInterface
|
|||||||
else
|
else
|
||||||
flash.now[:error] = t('create.error.page')
|
flash.now[:error] = t('create.error.page')
|
||||||
@designs = Design.all.entries
|
@designs = Design.all.entries
|
||||||
@design = Design.first
|
@design = Design.find(params[:page][:design]) || Design.first
|
||||||
|
@themes = @design.themes
|
||||||
|
@module_apps = ModuleApp.for_frontend_select
|
||||||
|
@selected={
|
||||||
|
:design => params[:page][:design],
|
||||||
|
:theme=> (Theme.find(params[:page][:theme_id]) rescue nil),
|
||||||
|
:module_app=> (ModuleApp.find(params[:page][:module_app_id]) rescue nil) ,#@module_apps.first
|
||||||
|
:app_frontend_url=> params[:page][:app_frontend_url], #@module_apps.first
|
||||||
|
:category=>params[:page][:category],
|
||||||
|
:tag=>params[:page][:tag],
|
||||||
|
:page_frontend_data_count=>params[:page][:page_frontend_data_count],
|
||||||
|
:frontend_style => params[:page][:frontend_style]
|
||||||
|
}
|
||||||
|
@app_frontend_urls = @item.module_app ? select_array_for_app_frontend_urls(@item.module_app.app_pages) : nil
|
||||||
|
get_categories_and_tags
|
||||||
|
get_frontend_data_count
|
||||||
render :action => "new"
|
render :action => "new"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
class Admin::RoleCategorysController < Admin::RoleFiltersController
|
||||||
|
|
||||||
|
def initialize
|
||||||
|
super
|
||||||
|
@app_type = 'role_category'
|
||||||
|
@app_type_name = 'category'
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -0,0 +1,144 @@
|
|||||||
|
class Admin::RoleFiltersController < OrbitBackendController
|
||||||
|
|
||||||
|
include OrbitControllerLib::DivisionForDisable
|
||||||
|
|
||||||
|
layout "new_admin"
|
||||||
|
|
||||||
|
before_filter :authenticate_user!
|
||||||
|
before_filter :is_admin?
|
||||||
|
# before_filter :set_attribute, :only => [:index, :show, :new, :edit]
|
||||||
|
helper Admin::AttributeValuesViewHelper
|
||||||
|
|
||||||
|
def index
|
||||||
|
get_types
|
||||||
|
@role = Role.find(params[:role_id])
|
||||||
|
@role_filters = @types.where(:role_id=>params[:role_id])
|
||||||
|
@role_filter = @types.new(:display => 'List')
|
||||||
|
|
||||||
|
# @url = admin_role_filter_role_filters_path
|
||||||
|
|
||||||
|
if @app_type == 'role_statuses'
|
||||||
|
@url = eval("admin_#{@app_type}_path")
|
||||||
|
else
|
||||||
|
@url = eval("admin_#{@app_type}s_path")
|
||||||
|
end
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
format.html # index.html.erb
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def show
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.find(params[:id])
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
format.html # show.html.erb
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def new
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.new(:display => 'List')
|
||||||
|
|
||||||
|
@verb = :post
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
format.html # new.html.erb
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def edit
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.find(params[:id])
|
||||||
|
|
||||||
|
@url = polymorphic_path([:admin, @role_filter])
|
||||||
|
|
||||||
|
@verb = :put
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
format.html
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def create
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.new(params[:role_filter])
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
if @role_filter.save
|
||||||
|
format.html { redirect_to(admin_role_filter_url(params[:role_filter][:role_id])) }
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def update
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.find(params[:id])
|
||||||
|
# debugger
|
||||||
|
# @url = admin_role_filter_role_filter_path(@role_filter)
|
||||||
|
# @url = eval("admin_role_filter_#{@app_type}_path(#{@role_filter})")
|
||||||
|
@url = polymorphic_path([:admin, @role_filter])
|
||||||
|
|
||||||
|
respond_to do |format|
|
||||||
|
if @role_filter.update_attributes(params[:role_filter])
|
||||||
|
format.html { redirect_to(admin_role_filter_role_filters_url(params[:role_id]), :notice => t('role_filter.update_role_filter_success')) }
|
||||||
|
# format.xml { head :ok }
|
||||||
|
format.js
|
||||||
|
else
|
||||||
|
format.html { render :action => "edit" }
|
||||||
|
format.js { render :action => "edit" }
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def destroy
|
||||||
|
|
||||||
|
get_types
|
||||||
|
|
||||||
|
@role_filter = @types.find(params[:id])
|
||||||
|
@role_filter.disable = @role_filter.disable ? false : true
|
||||||
|
|
||||||
|
if @role_filter.save!
|
||||||
|
respond_to do |format|
|
||||||
|
format.html { redirect_to(admin_role_filter_role_filters_url) }
|
||||||
|
# format.xml { head :ok }
|
||||||
|
format.js
|
||||||
|
end
|
||||||
|
else
|
||||||
|
flash[:error] = t("role_filter.update_failed")
|
||||||
|
format.html { render :action => "index" }
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
protected
|
||||||
|
|
||||||
|
def get_types
|
||||||
|
@types = @app_type.classify.constantize
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
class Admin::RoleStatusesController < Admin::RoleFiltersController
|
||||||
|
|
||||||
|
def initialize
|
||||||
|
super
|
||||||
|
@app_type = 'role_statuses'
|
||||||
|
@app_type_name = 'status'
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -28,7 +28,6 @@ class Admin::RolesController < OrbitBackendController
|
|||||||
@attribute = Role.find(params[:role_id])
|
@attribute = Role.find(params[:role_id])
|
||||||
@attribute_fields_upper_object = @attribute.sub_roles
|
@attribute_fields_upper_object = @attribute.sub_roles
|
||||||
|
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def add_sub_role
|
def add_sub_role
|
||||||
@@ -95,7 +94,6 @@ class Admin::RolesController < OrbitBackendController
|
|||||||
format.js { render 'add_attribute_field' }
|
format.js { render 'add_attribute_field' }
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def new
|
def new
|
||||||
|
|||||||
@@ -14,8 +14,16 @@ class Admin::SitesController < OrbitBackendController
|
|||||||
# @site = Site.new
|
# @site = Site.new
|
||||||
# end
|
# end
|
||||||
|
|
||||||
|
def show_system_preference
|
||||||
|
@git_commit_list_file = File.new(OrbitSystemPreference::GitCommitListPath, "r") rescue nil
|
||||||
|
@db_backup_list_file = File.new(OrbitSystemPreference::ArchiveDbListPath, "r") rescue nil
|
||||||
|
@resque_logs_file = File.new(OrbitSystemPreference::ResqueLogFile, "r") rescue nil
|
||||||
|
@site = Site.first
|
||||||
|
end
|
||||||
|
|
||||||
def update
|
def update
|
||||||
@site.update_attributes(params[:site])
|
@site.update_attributes(params[:site])
|
||||||
|
site_restart
|
||||||
redirect_to :back
|
redirect_to :back
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -2,16 +2,10 @@ class Admin::TagsController < OrbitBackendController
|
|||||||
before_filter :force_order_for_visitor,:only=>[:index]
|
before_filter :force_order_for_visitor,:only=>[:index]
|
||||||
before_filter :force_order_for_user,:except => [:index]
|
before_filter :force_order_for_user,:except => [:index]
|
||||||
before_filter :for_app_sub_manager,:except => [:index]
|
before_filter :for_app_sub_manager,:except => [:index]
|
||||||
|
|
||||||
|
|
||||||
# layout 'new_admin'
|
|
||||||
# before_filter :authenticate_user!
|
|
||||||
# before_filter :is_admin?
|
|
||||||
# before_filter :set_module_app
|
# before_filter :set_module_app
|
||||||
|
|
||||||
def index
|
def index
|
||||||
get_tags
|
@tags = get_tags
|
||||||
@module_app_id = @module_app.id rescue nil
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def new
|
def new
|
||||||
@@ -23,12 +17,7 @@ class Admin::TagsController < OrbitBackendController
|
|||||||
end
|
end
|
||||||
|
|
||||||
def create
|
def create
|
||||||
if params[:tag][:module_app_id].blank?
|
@tag = @module_app ? @module_app.tags.create(params[:tag]) : Tag.create(params[:tag])
|
||||||
@tag = Tag.create(params[:tag])
|
|
||||||
else
|
|
||||||
module_app = ModuleApp.find(params[:tag][:module_app_id])
|
|
||||||
@tag = eval("#{module_app.key.camelize}Tag").create(params[:tag])
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def update
|
def update
|
||||||
@@ -47,15 +36,12 @@ class Admin::TagsController < OrbitBackendController
|
|||||||
protected
|
protected
|
||||||
|
|
||||||
def get_tags
|
def get_tags
|
||||||
@tags = (@module_app ? @module_app.tags : Tag.all)
|
@tags = @module_app.blank? ? Tag.all : @module_app.tags
|
||||||
end
|
end
|
||||||
|
|
||||||
def setup_vars
|
def setup_vars
|
||||||
@app_key = request.env['HTTP_REFERER'].split('/')[4]
|
@module_app = ModuleApp.find(params[:module_app_id]) if params[:module_app_id]
|
||||||
if @app_key
|
@module_app_id = @module_app.id rescue nil
|
||||||
@app_key.gsub!(/[?].*/, '')
|
|
||||||
@module_app = ModuleApp.first(conditions: {:key => @app_key})
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
@@ -1,5 +1,7 @@
|
|||||||
class Admin::UsersNewInterfaceController < OrbitBackendController
|
class Admin::UsersNewInterfaceController < OrbitBackendController
|
||||||
|
|
||||||
|
helper MemberHelper
|
||||||
|
|
||||||
layout "new_admin"
|
layout "new_admin"
|
||||||
# before_filter :authenticate_user!
|
# before_filter :authenticate_user!
|
||||||
# before_filter :set_attribute, :only => [:index, :show, :new, :edit]
|
# before_filter :set_attribute, :only => [:index, :show, :new, :edit]
|
||||||
@@ -23,13 +25,13 @@ class Admin::UsersNewInterfaceController < OrbitBackendController
|
|||||||
|
|
||||||
render case params[:at]
|
render case params[:at]
|
||||||
when 'summary'
|
when 'summary'
|
||||||
@users=User.not_guest_user.page(page_num).per(12).includes('avatar')
|
@users=User.not_guest_user.page(page_num).per(12).asc("_id").includes('avatar')
|
||||||
"index_summary"
|
"index_summary"
|
||||||
when 'thumbnail'
|
when 'thumbnail'
|
||||||
@users=User.not_guest_user.page(page_num).per(36).includes('avatar')
|
@users=User.not_guest_user.page(page_num).per(36).asc("_id").includes('avatar')
|
||||||
"index_thumbnail"
|
"index_thumbnail"
|
||||||
else
|
else
|
||||||
@users=User.not_guest_user.page(page_num).per(10).includes('avatar')
|
@users=User.not_guest_user.page(page_num).per(10).asc("_id").includes('avatar')
|
||||||
"index"
|
"index"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -43,7 +45,7 @@ class Admin::UsersNewInterfaceController < OrbitBackendController
|
|||||||
@student_data = []
|
@student_data = []
|
||||||
@staff_data = []
|
@staff_data = []
|
||||||
|
|
||||||
attribute_values = @user.attribute_values
|
attribute_values = @user.attribute_values.asc("_id")
|
||||||
attribute_values.each{|att_val|
|
attribute_values.each{|att_val|
|
||||||
@profile_data.push({:name => att_val.attribute_field.title,:value =>att_val.get_value_by_locale(I18n.locale.to_s)}) if att_val.attribute_field.attribute.key=="profile" rescue false
|
@profile_data.push({:name => att_val.attribute_field.title,:value =>att_val.get_value_by_locale(I18n.locale.to_s)}) if att_val.attribute_field.attribute.key=="profile" rescue false
|
||||||
}
|
}
|
||||||
@@ -80,21 +82,29 @@ class Admin::UsersNewInterfaceController < OrbitBackendController
|
|||||||
end
|
end
|
||||||
|
|
||||||
def create
|
def create
|
||||||
puts params.to_yaml
|
# puts params.to_yaml
|
||||||
# attribute_values_key = params[:user].has_key?('new_attribute_values') ? 'new_attribute_values' : 'attribute_values'
|
# attribute_values_key = params[:user].has_key?('new_attribute_values') ? 'new_attribute_values' : 'attribute_values'
|
||||||
# attribute_values = params[:user].delete(attribute_values_key)
|
# attribute_values = params[:user].delete(attribute_values_key)
|
||||||
@user = User.new(params["user"])
|
@user = User.new(params["user"])
|
||||||
|
|
||||||
|
@checkuser = User.where(:user_id => params[:user][:user_id]).first
|
||||||
|
|
||||||
|
if !@checkuser.blank?
|
||||||
|
flash.now[:error] = t("users.user_id_error")
|
||||||
|
end
|
||||||
|
|
||||||
# attribute_values.to_hash.each{|key,value|
|
# attribute_values.to_hash.each{|key,value|
|
||||||
# @user.attribute_values.build(value)
|
# @user.attribute_values.build(value)
|
||||||
# }
|
# }
|
||||||
# @user.rebuild_sub_roles_from_attribute_values!(attribute_values)
|
# @user.rebuild_sub_roles_from_attribute_values!(attribute_values)
|
||||||
# binding.pry
|
# binding.pry
|
||||||
if @user.save
|
if !flash.now[:error] && @user.save
|
||||||
flash[:notice] = t('create.success.user')
|
flash[:notice] = t('create.success.user')
|
||||||
redirect_to :action => :index
|
redirect_to :action => :index
|
||||||
else
|
else
|
||||||
|
@user.attribute_values = nil
|
||||||
@form_index = 0
|
@form_index = 0
|
||||||
render :action => :new
|
render :action => :new , :notice => flash.now[:error]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -111,15 +121,45 @@ class Admin::UsersNewInterfaceController < OrbitBackendController
|
|||||||
get_info_and_roles
|
get_info_and_roles
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def edit_passwd
|
||||||
|
# @disable_all_field = false
|
||||||
|
@user = User.find(params[:users_new_interface_id])
|
||||||
|
end
|
||||||
|
|
||||||
def update
|
def update
|
||||||
|
|
||||||
@user = User.find(params[:id])
|
@user = User.find(params[:id])
|
||||||
|
|
||||||
|
if params[:edit_type] == 'edit_passwd'
|
||||||
|
|
||||||
|
@checkuser = User.where(:user_id => params[:user][:user_id]).first
|
||||||
|
|
||||||
|
if !@checkuser.blank? && @checkuser.id != @user.id
|
||||||
|
flash.now[:error] = t("users.user_id_error")
|
||||||
|
elsif @user.admin && current_user.id == @user.id
|
||||||
|
flash.now[:error] = t("users.admin_change_password")
|
||||||
|
end
|
||||||
|
|
||||||
|
if !flash.now[:error] && @user.update_attributes(params[:user])
|
||||||
|
redirect_to :action => :show
|
||||||
|
else
|
||||||
|
render :action => :edit_passwd, :notice => flash.now[:error]
|
||||||
|
end
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
@user.update_attributes(params[:user])
|
@user.update_attributes(params[:user])
|
||||||
|
|
||||||
attribute_values_key = params[:user].has_key?('new_attribute_values') ? 'new_attribute_values' : 'attribute_values'
|
attribute_values_key = params[:user].has_key?('new_attribute_values') ? 'new_attribute_values' : 'attribute_values'
|
||||||
attribute_values = params[:user].delete(attribute_values_key)
|
attribute_values = params[:user].delete(attribute_values_key)
|
||||||
# @user.rebuild_sub_roles_from_attribute_values!(attribute_values)
|
# @user.rebuild_sub_roles_from_attribute_values!(attribute_values)
|
||||||
@user.save
|
@user.save
|
||||||
|
|
||||||
redirect_to :action => :show
|
redirect_to :action => :show
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
# # Update changes to the avatar
|
# # Update changes to the avatar
|
||||||
# @user.remove_avatar! if params[:file]
|
# @user.remove_avatar! if params[:file]
|
||||||
# @user.avatar = params[:file] if params[:file]
|
# @user.avatar = params[:file] if params[:file]
|
||||||
|
|||||||
@@ -17,7 +17,15 @@ class ApplicationController < ActionController::Base
|
|||||||
|
|
||||||
helper_attr :site_valid_locales
|
helper_attr :site_valid_locales
|
||||||
|
|
||||||
|
def check_backend_openness
|
||||||
|
if !Me.backend_openness_on
|
||||||
|
redirect_to '/users/sign_in' if not (authenticate_user! and is_member? )
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def site_restart
|
||||||
|
Resque.enqueue(RestartServer)
|
||||||
|
end
|
||||||
|
|
||||||
def set_current_user
|
def set_current_user
|
||||||
User.current = current_or_guest_user
|
User.current = current_or_guest_user
|
||||||
@@ -101,10 +109,10 @@ class ApplicationController < ActionController::Base
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Render the page
|
# Render the page
|
||||||
def render_page
|
def render_page(args=nil)
|
||||||
if @item
|
if @item
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html { render :text => parse_page_content(@item), :layout => 'page_layout' }
|
format.html { render :text => parse_page_content(@item,args), :layout => 'page_layout' }
|
||||||
format.rss { render_main_rss }
|
format.rss { render_main_rss }
|
||||||
format.mobile { redirect_to mobile_path(:app => params[:app]) }
|
format.mobile { redirect_to mobile_path(:app => params[:app]) }
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -36,12 +36,13 @@ class DefaultWidgetController< OrbitWidgetController
|
|||||||
result = eval("#{ori_class_name}.where(:#{get_category_field_name(ori_class_name)}.in=>params['category_id'])")
|
result = eval("#{ori_class_name}.where(:#{get_category_field_name(ori_class_name)}.in=>params['category_id'])")
|
||||||
end
|
end
|
||||||
date_now = Time.now
|
date_now = Time.now
|
||||||
result.available_for_lang(I18n.locale).can_display.any_of( {deadline: nil,:postdate.lte => date_now} , {:deadline.gte => date_now,:postdate.lte => date_now} ).desc(:is_top, :postdate)
|
result.available_for_lang(I18n.locale).can_display.desc(:is_top, :postdate)
|
||||||
end
|
end
|
||||||
|
|
||||||
def default_widget
|
def default_widget
|
||||||
if !params[:id].blank?
|
if !params[:id].blank?
|
||||||
redirect_to eval("#{@page_part.module_app.widget_fields_link_method[:title][:method]}('#{params[:id]}', {inner: #{params[:inner] || true}})")
|
clicked_field_name = params["clicked_field_name"].to_sym
|
||||||
|
redirect_to eval("#{@page_part.module_app.widget_fields_link_method[clicked_field_name][:method]}('#{params[:id]}', {inner: #{params[:inner] || true}})")
|
||||||
else
|
else
|
||||||
@tag_class = nil
|
@tag_class = nil
|
||||||
@default_widget = @page_part.module_app.get_default_widget
|
@default_widget = @page_part.module_app.get_default_widget
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
class OrbitBackendController < ApplicationController
|
class OrbitBackendController < ApplicationController
|
||||||
include OrbitCoreLib::AppBackendUtility
|
include OrbitCoreLib::AppBackendUtility
|
||||||
include OrbitCoreLib::PermissionUtility
|
include OrbitCoreLib::PermissionUtility
|
||||||
|
include OrbitTag::Tagging
|
||||||
include AdminHelper
|
include AdminHelper
|
||||||
include ApplicationHelper
|
include ApplicationHelper
|
||||||
|
|
||||||
@@ -15,6 +16,7 @@ class OrbitBackendController < ApplicationController
|
|||||||
private
|
private
|
||||||
|
|
||||||
def force_order_for_visitor
|
def force_order_for_visitor
|
||||||
|
check_backend_openness
|
||||||
setup_vars
|
setup_vars
|
||||||
set_current_user
|
set_current_user
|
||||||
end
|
end
|
||||||
@@ -59,6 +61,20 @@ class OrbitBackendController < ApplicationController
|
|||||||
when :referenced_in
|
when :referenced_in
|
||||||
objects = get_objects_from_referenced_objects(object_class.relations[option].class_name.constantize, objects, "#{option}_id")
|
objects = get_objects_from_referenced_objects(object_class.relations[option].class_name.constantize, objects, "#{option}_id")
|
||||||
end
|
end
|
||||||
|
elsif option.eql?('tags')
|
||||||
|
tag_array = @module_app.tags.inject([]){ |result, value|
|
||||||
|
result << [value.name, value]
|
||||||
|
}
|
||||||
|
params[:direction].eql?('asc') ? tag_array.sort : tag_array.sort.reverse!
|
||||||
|
sorted_objects = Array.new
|
||||||
|
tag_array.each do |x|
|
||||||
|
taggings = x[1].taggings
|
||||||
|
taggings.each {|tagging| sorted_objects << tagging.taggable }
|
||||||
|
end
|
||||||
|
# debugger
|
||||||
|
sorted_objects.flatten!
|
||||||
|
sorted_objects.uniq!
|
||||||
|
objects = get_with_nil(objects, option, sorted_objects)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -1,8 +1,15 @@
|
|||||||
class PagesController < ApplicationController
|
class PagesController < ApplicationController
|
||||||
include ApplicationHelper
|
include ApplicationHelper
|
||||||
before_filter :get_item, :only => [:index_from_link, :show_from_link]
|
before_filter :get_item, :only => [:index_from_link, :show_from_link]
|
||||||
|
before_filter :check_frontend_open, :only => [:index,:show]
|
||||||
# caches_page :index
|
# caches_page :index
|
||||||
|
|
||||||
|
def check_frontend_open
|
||||||
|
if Me.frontend_closed
|
||||||
|
redirect_to '/admin/dashboards'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
def index
|
def index
|
||||||
@item = Page.find_by_name('home')
|
@item = Page.find_by_name('home')
|
||||||
|
|
||||||
@@ -21,7 +28,11 @@ class PagesController < ApplicationController
|
|||||||
impressionist(@item)
|
impressionist(@item)
|
||||||
case @item.class.to_s
|
case @item.class.to_s
|
||||||
when 'Page'
|
when 'Page'
|
||||||
|
if params[:clicked_field_name]
|
||||||
|
render_page({"clicked_field_name"=>params["clicked_field_name"]}) unless save_from_no_lang_for_page
|
||||||
|
else
|
||||||
render_page unless save_from_no_lang_for_page
|
render_page unless save_from_no_lang_for_page
|
||||||
|
end
|
||||||
when 'Link'
|
when 'Link'
|
||||||
redirect_to(@item[:url]) unless save_from_no_lang_for_page
|
redirect_to(@item[:url]) unless save_from_no_lang_for_page
|
||||||
end
|
end
|
||||||
@@ -54,6 +65,7 @@ class PagesController < ApplicationController
|
|||||||
options << "#{options.blank? ? '?' : '&'}tag_id=#{params[:tag_id]}" unless params[:tag_id].blank?
|
options << "#{options.blank? ? '?' : '&'}tag_id=#{params[:tag_id]}" unless params[:tag_id].blank?
|
||||||
options << "#{options.blank? ? '?' : '&'}preview=#{params[:preview]}" unless params[:preview].blank?
|
options << "#{options.blank? ? '?' : '&'}preview=#{params[:preview]}" unless params[:preview].blank?
|
||||||
options << "#{options.blank? ? '?' : '&'}controller_action=#{params[:controller_action]}" unless params[:controller_action].blank?
|
options << "#{options.blank? ? '?' : '&'}controller_action=#{params[:controller_action]}" unless params[:controller_action].blank?
|
||||||
|
options << "#{options.blank? ? '?' : '&'}clicked_field_name=#{params[:clicked_field_name]}" unless params[:clicked_field_name].blank?
|
||||||
redirect_to(url + options) unless save_from_no_lang_for_page
|
redirect_to(url + options) unless save_from_no_lang_for_page
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ protected
|
|||||||
def get_categories_and_tags
|
def get_categories_and_tags
|
||||||
unless @selected[:module_app].nil?
|
unless @selected[:module_app].nil?
|
||||||
@categories = @selected[:module_app].get_categories
|
@categories = @selected[:module_app].get_categories
|
||||||
@tags = @selected[:module_app].get_tags
|
@tags = @selected[:module_app].tags
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,9 @@ module DefaultWidgetHelper
|
|||||||
def link_to_field(row_data,field, switch, options=nil)
|
def link_to_field(row_data,field, switch, options=nil)
|
||||||
method_ary = @page_part.module_app.widget_fields_link_method
|
method_ary = @page_part.module_app.widget_fields_link_method
|
||||||
field = field.to_sym
|
field = field.to_sym
|
||||||
if(method_ary.has_key?(field) and (switch == true))
|
options = options || {}
|
||||||
|
options[:clicked_field_name] = field
|
||||||
|
if(method_ary.has_key?(field) and (switch.to_s == "true"))
|
||||||
url = case method_ary[field][:args]
|
url = case method_ary[field][:args]
|
||||||
when nil # no args
|
when nil # no args
|
||||||
get_data_link(method_ary[field][:method], options)
|
get_data_link(method_ary[field][:method], options)
|
||||||
|
|||||||
@@ -0,0 +1,5 @@
|
|||||||
|
module MemberHelper
|
||||||
|
def nl2br(val)
|
||||||
|
val.gsub(/\r\n/, '<br />').html_safe
|
||||||
|
end
|
||||||
|
end
|
||||||
@@ -5,9 +5,13 @@ class BackupServer
|
|||||||
#CronMail.time_check("Going to backup Orbit").deliver
|
#CronMail.time_check("Going to backup Orbit").deliver
|
||||||
dbhost = Mongoid.config.database.connection.primary.join ':'
|
dbhost = Mongoid.config.database.connection.primary.join ':'
|
||||||
dbname = Mongoid.config.database.name
|
dbname = Mongoid.config.database.name
|
||||||
|
archive_db_list_path = OrbitSystemPreference::ArchiveDbListPath
|
||||||
dbdirectory = "#{Rails.root}/tmp/#{dbname}-"+Time.now.strftime("%Y-%m-%d-%H-%M")
|
dbdirectory = "#{Rails.root}/tmp/#{dbname}-"+Time.now.strftime("%Y-%m-%d-%H-%M")
|
||||||
%x[mongodump -h #{dbhost} -d #{dbname} -o #{dbdirectory} ]
|
%x[mongodump -h #{dbhost} -d #{dbname} -o #{dbdirectory} ]
|
||||||
|
|
||||||
# %x[touch #{Rails.root}/tmp/restart]
|
%x[rm #{archive_db_list_path}]
|
||||||
|
%x[ls #{Rails.root}/tmp/#{dbname}* | du -h --max-depth=1 --block-size=1M |sort -h >> #{archive_db_list_path}]
|
||||||
|
OrbitJobLogger.info "DB backup done Path:#{dbdirectory}"
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
class DashboardCounter < Resque::Plugins::RestrictionJob
|
||||||
|
@queue = :high
|
||||||
|
|
||||||
|
def self.perform(*args)
|
||||||
|
site = Site.first
|
||||||
|
obj = new(*args)
|
||||||
|
site.dashboard_counter[:visitors_this_week] = obj.display_visitors_this_week
|
||||||
|
site.dashboard_counter[:visitors_this_month] = obj.display_visitors_this_month
|
||||||
|
site.dashboard_counter[:visitors_this_year] = obj.display_visitors_this_year
|
||||||
|
site.save
|
||||||
|
OrbitJobLogger.info "DashboardCounter done #{site.dashboard_counter.to_s}"
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def display_visitors(options={})
|
||||||
|
impressions = Impression.where(options).and(:referrer.ne => nil)
|
||||||
|
impressions.map{|i| i[:session_hash]}.uniq.count
|
||||||
|
end
|
||||||
|
|
||||||
|
def display_visitors_today
|
||||||
|
display_visitors(created_at: {'$gte' => Date.today.beginning_of_day, '$lte' => Date.today.end_of_day})
|
||||||
|
end
|
||||||
|
|
||||||
|
def display_visitors_this_week
|
||||||
|
display_visitors(created_at: {'$gte' => Date.today.beginning_of_week, '$lte' => Date.today.end_of_week})
|
||||||
|
end
|
||||||
|
|
||||||
|
def display_visitors_this_month
|
||||||
|
display_visitors(created_at: {'$gte' => Date.today.beginning_of_month, '$lte' => Date.today.end_of_month})
|
||||||
|
end
|
||||||
|
|
||||||
|
def display_visitors_this_year
|
||||||
|
display_visitors(created_at: {'$gte' => Date.today.beginning_of_year, '$lte' => Date.today.end_of_year})
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
class GenerateSystemSummary
|
||||||
|
@queue = :high
|
||||||
|
|
||||||
|
def self.perform()
|
||||||
|
@site = Site.first
|
||||||
|
get_disk_free
|
||||||
|
get_git_log_list
|
||||||
|
get_package_info
|
||||||
|
@site.save
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_package_info
|
||||||
|
@info = {}
|
||||||
|
get_nginx_version
|
||||||
|
get_MongoDB_version
|
||||||
|
get_Linux_version
|
||||||
|
@site.system_package_info = @info
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_git_log_list
|
||||||
|
git_commit_list_path = OrbitSystemPreference::GitCommitListPath
|
||||||
|
%x[rm #{git_commit_list_path}]
|
||||||
|
%x[cd #{Rails.root};#{OrbitSystemPreference::GitLogCommend} >>#{git_commit_list_path} ]
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_disk_free
|
||||||
|
@site.disk_space= %x[#{OrbitSystemPreference::DiskFree}]
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_nginx_version
|
||||||
|
@info[:nginx] = %x[#{OrbitSystemPreference::SystemPackage::NginxVersion} ]
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_MongoDB_version
|
||||||
|
@info[:mongodb] = %x[#{OrbitSystemPreference::SystemPackage::MongodbVersion} ]
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_Linux_version
|
||||||
|
@info[:linux] = %x[#{OrbitSystemPreference::SystemPackage::SystemVersion} ]
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.check_system_has_enough_space( limit =OrbitSystemPreference::DefaultDiskSpaceLimit )
|
||||||
|
binding.pry
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -1,21 +0,0 @@
|
|||||||
class NccuCalendar
|
|
||||||
require 'open-uri'
|
|
||||||
require 'tempfile'
|
|
||||||
|
|
||||||
@queue = :high
|
|
||||||
|
|
||||||
def self.perform()
|
|
||||||
# temp_file = Tempfile.new('new_cal')
|
|
||||||
# open('http://events.nccu.edu.tw/Month').read{|data|
|
|
||||||
# temp_file << data
|
|
||||||
# }
|
|
||||||
|
|
||||||
open(File.join(Rails.root, 'public/static', 'nccu_calendar.xml'), 'wb') do |fo|
|
|
||||||
fo.print open('http://events.nccu.edu.tw/Month').read
|
|
||||||
end
|
|
||||||
|
|
||||||
# FileUtils.mv(temp_file, File.join(Rails.root, 'public/static', 'nccu_calendar.xml'))
|
|
||||||
|
|
||||||
puts "[#{ DateTime.now.strftime("%Y %D %H:%M")}]NccuCalendar Synced #{File.join(Rails.root, 'public/static', 'nccu_calendar.xml')}"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
class RestartServer
|
||||||
|
@queue = :high
|
||||||
|
|
||||||
|
def self.perform()
|
||||||
|
temp_directory = "#{Rails.root}/tmp/"
|
||||||
|
%x[touch #{temp_directory}restart.txt ]
|
||||||
|
end
|
||||||
|
end
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
class SyncDb
|
|
||||||
|
|
||||||
@queue = :high
|
|
||||||
|
|
||||||
def self.perform()
|
|
||||||
puts "[ #{DateTime.now.strftime("%Y %D %H:%M") }]\t SyncDb Starting"
|
|
||||||
self.start_sync
|
|
||||||
self.set_admin
|
|
||||||
end
|
|
||||||
|
|
||||||
def self.start_sync
|
|
||||||
task = 'mid_site:sync'
|
|
||||||
args = []
|
|
||||||
%x[rake #{task} --trace >> #{Rails.root}/log/rake.log]
|
|
||||||
User.all.each{|ur| ur.create_dept_cache}
|
|
||||||
puts "[#{ DateTime.now.strftime("%Y %D %H:%M")}]\tSyncDb Synced"
|
|
||||||
end
|
|
||||||
|
|
||||||
def self.set_admin
|
|
||||||
task = 'mid_site:install_admin'
|
|
||||||
args = []
|
|
||||||
%x[rake #{task} --trace >> #{Rails.root}/log/rake.log]
|
|
||||||
puts "[#{ DateTime.now.strftime("%Y %D %H:%M")}]\tAdmin done"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
@@ -5,5 +5,6 @@ class UpdateTagCloud
|
|||||||
Tag.all.each do |tag|
|
Tag.all.each do |tag|
|
||||||
tag.update_attribute(:cloud_view_count, tag.impressionist_count(:created_at.gte => 14.days.ago, :created_at.lte => Time.now))
|
tag.update_attribute(:cloud_view_count, tag.impressionist_count(:created_at.gte => 14.days.ago, :created_at.lte => Time.now))
|
||||||
end
|
end
|
||||||
|
OrbitJobLogger.info "UpdateTagCloud Done"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
+2
-1
@@ -21,7 +21,8 @@ class Asset
|
|||||||
before_save :clean_tags
|
before_save :clean_tags
|
||||||
|
|
||||||
def sorted_tags
|
def sorted_tags
|
||||||
tags.order_by(I18n.locale, :asc)
|
#tags.order_by(I18n.locale, :asc)
|
||||||
|
tags
|
||||||
end
|
end
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|||||||
+1
-1
@@ -17,7 +17,7 @@ class Item
|
|||||||
|
|
||||||
validates_format_of :name, :with => /^[0-9a-zA-Z\-_]+$/
|
validates_format_of :name, :with => /^[0-9a-zA-Z\-_]+$/
|
||||||
# validates :name, :exclusion => { :in => LIST[:forbidden_item_names] }
|
# validates :name, :exclusion => { :in => LIST[:forbidden_item_names] }
|
||||||
validates_uniqueness_of :name, :scope => :parent_id
|
validates_uniqueness_of :name #, :scope => :parent_id
|
||||||
validates_presence_of :name
|
validates_presence_of :name
|
||||||
validates_associated :parent, :children
|
validates_associated :parent, :children
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ class ModuleApp
|
|||||||
field :title
|
field :title
|
||||||
field :sidebar_order,type: Integer,default: 0
|
field :sidebar_order,type: Integer,default: 0
|
||||||
|
|
||||||
|
has_many :tags, as: :module_tag, dependent: :destroy
|
||||||
|
|
||||||
def refetch_setting!(reg)
|
def refetch_setting!(reg)
|
||||||
# %w{module_label category base_url version organization author intro update_info create_date}.each do |field|
|
# %w{module_label category base_url version organization author intro update_info create_date}.each do |field|
|
||||||
# self[field.to_sym] = reg.send field
|
# self[field.to_sym] = reg.send field
|
||||||
@@ -118,10 +120,6 @@ class ModuleApp
|
|||||||
|
|
||||||
has_one :app_auth,dependent: :delete
|
has_one :app_auth,dependent: :delete
|
||||||
|
|
||||||
def get_tags
|
|
||||||
get_registration.get_tags
|
|
||||||
end
|
|
||||||
|
|
||||||
def get_categories
|
def get_categories
|
||||||
get_registration.get_categories
|
get_registration.get_categories
|
||||||
end
|
end
|
||||||
@@ -134,4 +132,8 @@ class ModuleApp
|
|||||||
OrbitApp::Module::Registration.find_by_key(key)
|
OrbitApp::Module::Registration.find_by_key(key)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def self.find_by_key(key)
|
||||||
|
self.where(key: key)[0] rescue nil
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
@@ -11,10 +11,17 @@ class Site
|
|||||||
field :roaming_id
|
field :roaming_id
|
||||||
field :private_key, :type => Binary
|
field :private_key, :type => Binary
|
||||||
field :public_key, :type => Binary
|
field :public_key, :type => Binary
|
||||||
|
|
||||||
|
field :frontend_closed, :type => Boolean, :default => false
|
||||||
|
field :backend_openness_on, :type => Boolean, :default => false
|
||||||
|
|
||||||
field :title_always_on, :type => Boolean, :default => false
|
field :title_always_on, :type => Boolean, :default => false
|
||||||
field :dashbroad_allow_visitor, :type => Boolean, :default => false
|
field :dashbroad_allow_visitor, :type => Boolean, :default => false
|
||||||
field :mail_settings, :type => Hash
|
field :mail_settings, :type => Hash
|
||||||
|
|
||||||
|
field :disk_space, :type => String
|
||||||
|
field :system_package_info, :type => Hash,:default=>{}
|
||||||
|
|
||||||
field :school
|
field :school
|
||||||
field :department
|
field :department
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
class SubRoleTag < ProtoTag
|
class SubRoleTag < ProtoTag
|
||||||
has_and_belongs_to_many :sub_roles
|
has_and_belongs_to_many :sub_roles
|
||||||
|
|
||||||
end
|
end
|
||||||
+4
-1
@@ -10,10 +10,13 @@ class Tag
|
|||||||
|
|
||||||
is_impressionable :counter_cache => { :column_name => :view_count }
|
is_impressionable :counter_cache => { :column_name => :view_count }
|
||||||
|
|
||||||
field :key
|
field :name, localize: true
|
||||||
field :view_count, :type => Integer, :default => 0
|
field :view_count, :type => Integer, :default => 0
|
||||||
field :cloud_view_count, :type => Integer, :default => 0
|
field :cloud_view_count, :type => Integer, :default => 0
|
||||||
|
|
||||||
|
belongs_to :module_tag, polymorphic: true
|
||||||
|
has_many :taggings, dependent: :destroy
|
||||||
|
|
||||||
#field :cloud_amper,:type: Integer,:default=> 0
|
#field :cloud_amper,:type: Integer,:default=> 0
|
||||||
|
|
||||||
def self.sorted_for_cloud
|
def self.sorted_for_cloud
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
class Tagging
|
||||||
|
include Mongoid::Document
|
||||||
|
include Mongoid::Timestamps
|
||||||
|
|
||||||
|
field :to_destroy, default: false
|
||||||
|
|
||||||
|
belongs_to :tag
|
||||||
|
belongs_to :taggable, polymorphic: true
|
||||||
|
end
|
||||||
@@ -11,9 +11,14 @@ class Role < Attribute
|
|||||||
|
|
||||||
has_many :sub_roles, :autosave => true, :dependent => :destroy
|
has_many :sub_roles, :autosave => true, :dependent => :destroy
|
||||||
has_many :users
|
has_many :users
|
||||||
has_many :statuses, :autosave => true, :dependent => :destroy
|
# has_many :statuses, :autosave => true, :dependent => :destroy
|
||||||
# has_many :attribute_fields, :autosave => true, :dependent => :destroy
|
# has_many :attribute_fields, :autosave => true, :dependent => :destroy
|
||||||
|
has_many :role_statuses, :autosave => true, :dependent => :destroy
|
||||||
|
has_many :role_categorys, :autosave => true, :dependent => :destroy
|
||||||
|
|
||||||
accepts_nested_attributes_for :sub_roles, :allow_destroy => true
|
accepts_nested_attributes_for :sub_roles, :allow_destroy => true
|
||||||
|
accepts_nested_attributes_for :role_statuses, :allow_destroy => true
|
||||||
|
accepts_nested_attributes_for :role_categorys, :allow_destroy => true
|
||||||
|
|
||||||
def is_built_in?
|
def is_built_in?
|
||||||
self.built_in
|
self.built_in
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
class RoleCategory < RoleFilter
|
||||||
|
|
||||||
|
has_and_belongs_to_many :users
|
||||||
|
belongs_to :role
|
||||||
|
|
||||||
|
def self.get_role_data(role_key)
|
||||||
|
|
||||||
|
@role = Role.where(:key =>role_key).first
|
||||||
|
|
||||||
|
return @role.id
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
class RoleFilter
|
||||||
|
|
||||||
|
include Mongoid::Document
|
||||||
|
include Mongoid::Timestamps
|
||||||
|
# include OrbitCoreLib::ObjectAuthable
|
||||||
|
include OrbitCoreLib::ObjectDisable
|
||||||
|
|
||||||
|
|
||||||
|
field :key
|
||||||
|
field :title, localize: true
|
||||||
|
|
||||||
|
# belongs_to :role
|
||||||
|
|
||||||
|
def pp_object
|
||||||
|
title
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.from_id(id)
|
||||||
|
RoleFilter.find(id) rescue nil
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.is_localized?(field_name)
|
||||||
|
self.fields[field_name.to_s].localized?
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
class RoleStatus < RoleFilter
|
||||||
|
|
||||||
|
has_and_belongs_to_many :users
|
||||||
|
belongs_to :role
|
||||||
|
|
||||||
|
scope :can_display,where(disable: false)
|
||||||
|
|
||||||
|
def self.get_role_data(role_key)
|
||||||
|
|
||||||
|
@role = Role.where(:key =>role_key).first
|
||||||
|
|
||||||
|
return @role.id
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
+62
-5
@@ -9,7 +9,13 @@ class User
|
|||||||
|
|
||||||
field :admin, :type => Boolean, :default => true
|
field :admin, :type => Boolean, :default => true
|
||||||
field :active_role
|
field :active_role
|
||||||
|
field :user_id
|
||||||
|
field :sid
|
||||||
|
field :first_name, localize: true
|
||||||
|
field :last_name, localize: true
|
||||||
field :email
|
field :email
|
||||||
|
field :sex, :default => 'unknown'
|
||||||
|
field :office_tel
|
||||||
field :cache_dept,type: Hash
|
field :cache_dept,type: Hash
|
||||||
field :status_record,type: Hash
|
field :status_record,type: Hash
|
||||||
|
|
||||||
@@ -25,9 +31,11 @@ class User
|
|||||||
# has_many :papers, :autosave => true, :dependent => :destroy
|
# has_many :papers, :autosave => true, :dependent => :destroy
|
||||||
has_and_belongs_to_many :sub_role_tags
|
has_and_belongs_to_many :sub_role_tags
|
||||||
|
|
||||||
has_and_belongs_to_many :statuses
|
# has_and_belongs_to_many :statuses
|
||||||
has_and_belongs_to_many :roles
|
has_and_belongs_to_many :roles
|
||||||
has_and_belongs_to_many :sub_roles
|
has_and_belongs_to_many :sub_roles
|
||||||
|
has_and_belongs_to_many :role_statuses
|
||||||
|
has_and_belongs_to_many :role_categorys
|
||||||
accepts_nested_attributes_for :attribute_values, :allow_destroy => true
|
accepts_nested_attributes_for :attribute_values, :allow_destroy => true
|
||||||
|
|
||||||
before_create :initialize_desktop
|
before_create :initialize_desktop
|
||||||
@@ -36,6 +44,9 @@ class User
|
|||||||
scope :remote_account, where(:nccu_id.ne => nil)
|
scope :remote_account, where(:nccu_id.ne => nil)
|
||||||
scope :not_guest_user, all_of(:name.ne => "guest")
|
scope :not_guest_user, all_of(:name.ne => "guest")
|
||||||
|
|
||||||
|
validates :user_id,
|
||||||
|
:presence => { :message => I18n.t("users.user_id_not_null") } ,
|
||||||
|
:length => {:minimum => 3, :maximum => 50, :message => I18n.t("users.user_id_length") }
|
||||||
# validates_uniqueness_of :email,:message=> I18n.t("devise.registrations.email_not_unique")
|
# validates_uniqueness_of :email,:message=> I18n.t("devise.registrations.email_not_unique")
|
||||||
|
|
||||||
# def new_attribute_values=(vars)
|
# def new_attribute_values=(vars)
|
||||||
@@ -101,6 +112,24 @@ class User
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def role_status=(var)
|
||||||
|
self.role_statuses = []
|
||||||
|
var[:id].each do |id,val|
|
||||||
|
if (val=="true")
|
||||||
|
self.role_statuses << RoleStatus.find(id)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def role_category=(var)
|
||||||
|
self.role_categorys = []
|
||||||
|
var[:id].each do |id,val|
|
||||||
|
if (val=="true")
|
||||||
|
self.role_categorys << RoleCategory.find(id)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def set_sub_role(sub_role_id,status_id)
|
def set_sub_role(sub_role_id,status_id)
|
||||||
@@ -144,6 +173,17 @@ class User
|
|||||||
}.uniq!
|
}.uniq!
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def self.get_member_list_attribute_field_name(role_type,field_key)
|
||||||
|
@attribute = ::Attribute.where(:key => role_type).first
|
||||||
|
return ::AttributeField.where(:key => field_key, :attribute_id => @attribute.id).first.title
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.get_member_list_attribute_value(user_id,role_type,field_key)
|
||||||
|
@attribute = ::Attribute.where(:key => role_type).first
|
||||||
|
@AttributeField = ::AttributeField.where(:key => field_key, :attribute_id => @attribute.id).first
|
||||||
|
return ::AttributeValue.where(attribute_field_id: @AttributeField.id, :user_id => user_id).first[I18n.locale.to_s]
|
||||||
|
end
|
||||||
|
|
||||||
def create_dept_cache
|
def create_dept_cache
|
||||||
dept_hash = {}
|
dept_hash = {}
|
||||||
|
|
||||||
@@ -170,12 +210,30 @@ class User
|
|||||||
(query1 + query2).uniq
|
(query1 + query2).uniq
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# def name
|
||||||
|
# info = Class::Info.first(:conditions => {:key => 'profile'})
|
||||||
|
# if info
|
||||||
|
# first_name = get_attribute_values.detect {|value| value.key.to_s.eql?('first_name') }[I18n.locale.to_s] rescue nil
|
||||||
|
# last_name = get_attribute_values.detect {|value| value.key.to_s.eql?('last_name') }[I18n.locale.to_s] rescue nil
|
||||||
|
# full_name = "#{last_name} #{first_name}"
|
||||||
|
|
||||||
|
# if full_name.strip.empty?
|
||||||
|
# full_name = email
|
||||||
|
# end
|
||||||
|
|
||||||
|
# return full_name
|
||||||
|
# else
|
||||||
|
# return nil
|
||||||
|
# end
|
||||||
|
# end
|
||||||
|
|
||||||
def name
|
def name
|
||||||
info = Class::Info.first(:conditions => {:key => 'profile'})
|
info = Class::Info.first(:conditions => {:key => 'profile'})
|
||||||
if info
|
if info
|
||||||
first_name = get_attribute_values.detect {|value| value.key.to_s.eql?('first_name') }[I18n.locale.to_s] rescue nil
|
# first_name = get_attribute_values.detect {|value| value.key.to_s.eql?('first_name') }[I18n.locale.to_s] rescue nil
|
||||||
last_name = get_attribute_values.detect {|value| value.key.to_s.eql?('last_name') }[I18n.locale.to_s] rescue nil
|
# last_name = get_attribute_values.detect {|value| value.key.to_s.eql?('last_name') }[I18n.locale.to_s] rescue nil
|
||||||
full_name = "#{last_name} #{first_name}"
|
# full_name = (I18n.locale != 'zh_tw') ? "#{self.last_name} #{self.first_name}" : "#{self.first_name} #{self.last_name}"
|
||||||
|
full_name = (I18n.locale.to_s == 'zh_tw') ? "#{self.last_name} #{self.first_name}" : "#{self.first_name} #{self.last_name}"
|
||||||
|
|
||||||
if full_name.strip.empty?
|
if full_name.strip.empty?
|
||||||
full_name = email
|
full_name = email
|
||||||
@@ -211,7 +269,6 @@ class User
|
|||||||
self.roles = self.roles.uniq
|
self.roles = self.roles.uniq
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
def rebuild_status_record
|
def rebuild_status_record
|
||||||
self.status_record = {}
|
self.status_record = {}
|
||||||
self.attribute_values.reject{|t| t.key!='status'}.each do |status|
|
self.attribute_values.reject{|t| t.key!='status'}.each do |status|
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
<div class="label-group">
|
<div class="label-group">
|
||||||
<div class="label-td">
|
<div class="label-td">
|
||||||
<% asset.sorted_tags.each do |tag| %>
|
<% asset.sorted_tags.each do |tag| %>
|
||||||
<span class="label label-tags"><%= tag[I18n.locale] %></span>
|
<span class="label label-tags"><%= tag.name %></span>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
<% @tags.each do |tag| %>
|
<% @tags.each do |tag| %>
|
||||||
<%= content_tag :label, :class => "checkbox inline" do -%>
|
<%= content_tag :label, :class => "checkbox inline" do -%>
|
||||||
<%= check_box_tag 'asset[tag_ids][]', tag.id, @asset.tag_ids.include?(tag.id) %>
|
<%= check_box_tag 'asset[tag_ids][]', tag.id, @asset.tag_ids.include?(tag.id) %>
|
||||||
<%= tag[I18n.locale] %>
|
<%= tag.name %>
|
||||||
<%= hidden_field_tag 'asset[tag_ids][]', '' %>
|
<%= hidden_field_tag 'asset[tag_ids][]', '' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
|
||||||
@@ -37,6 +37,8 @@
|
|||||||
<% if @attribute_type == 'role' %>
|
<% if @attribute_type == 'role' %>
|
||||||
<li><%= link_to t(:role_field), eval("admin_#{@attribute_type}_role_field_path(attribute)") %></li>
|
<li><%= link_to t(:role_field), eval("admin_#{@attribute_type}_role_field_path(attribute)") %></li>
|
||||||
<li><%= link_to t(:sub_role), eval("admin_#{@attribute_type}_sub_role_path(attribute)") %></li>
|
<li><%= link_to t(:sub_role), eval("admin_#{@attribute_type}_sub_role_path(attribute)") %></li>
|
||||||
|
<li><%= link_to t(:status), eval("admin_role_statuses_path(:role_id=>attribute)") %></li>
|
||||||
|
<li><%= link_to t(:category), eval("admin_role_categorys_path(:role_id=>attribute)") %></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<li><%= link_to t(:enable), eval("admin_#{@attribute_type}_path(attribute, :authenticity_token => form_authenticity_token, :#{@attribute_type} => {:disabled => true})"), :remote => true, :method => :put, :id => "disable_#{attribute.id}", :style => "display:#{attribute.is_disabled? ? 'none' : ''}", :class => 'switch' %></li>
|
<li><%= link_to t(:enable), eval("admin_#{@attribute_type}_path(attribute, :authenticity_token => form_authenticity_token, :#{@attribute_type} => {:disabled => true})"), :remote => true, :method => :put, :id => "disable_#{attribute.id}", :style => "display:#{attribute.is_disabled? ? 'none' : ''}", :class => 'switch' %></li>
|
||||||
<li><%= link_to t(:disable), eval("admin_#{@attribute_type}_path(attribute, :authenticity_token => form_authenticity_token, :#{@attribute_type} => {:disabled => false})"), :remote => true, :method => :put, :id => "enable_#{attribute.id}", :style => "display:#{attribute.is_disabled? ? '' : 'none'}", :class => 'switch' %></li>
|
<li><%= link_to t(:disable), eval("admin_#{@attribute_type}_path(attribute, :authenticity_token => form_authenticity_token, :#{@attribute_type} => {:disabled => false})"), :remote => true, :method => :put, :id => "enable_#{attribute.id}", :style => "display:#{attribute.is_disabled? ? '' : 'none'}", :class => 'switch' %></li>
|
||||||
|
|||||||
@@ -40,7 +40,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="item element">
|
<!-- <div class="item element">
|
||||||
<h3><i class="icons-"></i><a href=""><%= t(:member) %></a></h3>
|
<h3><i class="icons-"></i><a href=""><%= t(:member_) %></a></h3>
|
||||||
<div class="detail w-a h-a">
|
<div class="detail w-a h-a">
|
||||||
<p class="totle"><span><%= t(:all_member) %></span>2,217</p>
|
<p class="totle"><span><%= t(:all_member) %></span>2,217</p>
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
|
|||||||
@@ -2,5 +2,14 @@
|
|||||||
<%= render_node_and_children(Item.first(:conditions => {:parent_id => nil})) %>
|
<%= render_node_and_children(Item.first(:conditions => {:parent_id => nil})) %>
|
||||||
</ol>
|
</ol>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
$.ajaxSetup({
|
||||||
|
error: function(xhr, status, err) {
|
||||||
|
if (xhr.status == 401){
|
||||||
|
alert("<%= I18n.t('access.denied.ajax_401_error') %>");
|
||||||
|
window.location.href = '/';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
bindTreeDragHandle();
|
bindTreeDragHandle();
|
||||||
</script>
|
</script>
|
||||||
@@ -21,3 +21,4 @@
|
|||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%=javascript_include_tag "inc/update_cates_and_tags.js" %>
|
<%=javascript_include_tag "inc/update_cates_and_tags.js" %>
|
||||||
|
<%= javascript_include_tag "inc/page_widget_edit_interface.js" %>
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
<%= nil_checkbox_button(object,:tag) %>
|
<%= nil_checkbox_button(object,:tag) %>
|
||||||
<%= content_tag_for(:label, @tags,:class=>"radio inline") do |tag|%>
|
<%= content_tag_for(:label, @tags,:class=>"radio inline") do |tag|%>
|
||||||
<%= check_box_tag("#{field_name}[tag][]", tag.id, tag_checked_value(object,tag.id),:class=>'select_option' ) %>
|
<%= check_box_tag("#{field_name}[tag][]", tag.id, tag_checked_value(object,tag.id),:class=>'select_option' ) %>
|
||||||
<%= tag[I18n.locale]%>
|
<%= tag.name%>
|
||||||
<% end if @tags%>
|
<% end if @tags%>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<% else %>
|
<% else %>
|
||||||
|
|||||||
@@ -2,8 +2,4 @@
|
|||||||
<%= render 'admin/items/site_map_left_bar' %>
|
<%= render 'admin/items/site_map_left_bar' %>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<%= render 'edit' %>
|
<%= render 'edit' %>
|
||||||
@@ -113,3 +113,4 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<%=javascript_include_tag "inc/update_cates_and_tags.js" %>
|
<%=javascript_include_tag "inc/update_cates_and_tags.js" %>
|
||||||
|
<%= javascript_include_tag "inc/page_widget_edit_interface.js" %>
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
<% # encoding: utf-8 %>
|
||||||
|
|
||||||
|
<%= form_for(:role_filter, :remote => true, :url => @url, :method => @verb, :html => { :id => 'form_role_filter' } ) do |f| %>
|
||||||
|
|
||||||
|
<h2><%= (@role_filter.new_record? ? 'Add' : 'Edit') %></h2>
|
||||||
|
|
||||||
|
<div id="widget-title">
|
||||||
|
<%= f.label :key %>
|
||||||
|
<%= f.text_field :key %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="widget-title">
|
||||||
|
<%= f.fields_for :title_translations do |f| %>
|
||||||
|
<% @site_valid_locales.each do |locale| %>
|
||||||
|
<div class="control-group">
|
||||||
|
<%= label_tag "name-#{locale}", "Name-#{I18nVariable.from_locale(locale)}", :class => 'control-label' %>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.text_field locale, :class =>' input-xxlarge', :value => (@role_filter.title_translations[locale] rescue nil) %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-actions">
|
||||||
|
<%= f.hidden_field :role_id, :value => params[:role_id] if !params[:role_id].blank? %>
|
||||||
|
<%= f.submit 'Submit/送出', :class=>'btn btn-primary' %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<% end %>
|
||||||
|
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
|
||||||
|
<tr id="<%= dom_id role_filter %>" class="with_action">
|
||||||
|
<td>
|
||||||
|
<%= role_filter.key %>
|
||||||
|
<div class="quick-edit">
|
||||||
|
<ul class="nav nav-pills hide">
|
||||||
|
<% if is_admin?%>
|
||||||
|
<li><%= link_to t('role_filter.edit'),
|
||||||
|
polymorphic_path([:admin, role_filter], {:action => :edit}), :remote => true %></li>
|
||||||
|
<li><%= link_to show_toggle_archive_btn(role_filter),
|
||||||
|
polymorphic_path([:admin, role_filter]), :confirm => t('sure?'), :method => :delete, :remote => true,:class=>"archive_toggle" %></li>
|
||||||
|
<% end %>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<% if @types.is_localized?(:title) %>
|
||||||
|
<% @site_valid_locales.each do |locale| %>
|
||||||
|
<td><%= role_filter.title_translations[locale] rescue nil %></td>
|
||||||
|
<% end %>
|
||||||
|
<% else %>
|
||||||
|
<td><%= role_filter.title %></td>
|
||||||
|
<% end %>
|
||||||
|
</tr>
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
$('<%= j render :partial => 'role_filter', :collection => [@role_filter] %>').appendTo('#role_filters').hide().fadeIn();
|
||||||
|
$("#form_role_filter")[0].reset();
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
$("#<%= dom_id @role_filter %>").find(".archive_toggle").text("<%= show_toggle_archive_btn(@role_filter) %> ");
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
$("#form > form").replaceWith("<%= j render "form" %>");
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
|
||||||
|
<% content_for :side_bar do %>
|
||||||
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="subnav">
|
||||||
|
<ul class="breadcrumb">
|
||||||
|
<li><%= link_to( t("role"), admin_roles_path ) %> <span class="divider">/</span></li>
|
||||||
|
<li class="active">( <%= @role.title %> ) <%= t(@app_type_name) %></li>
|
||||||
|
</ul>
|
||||||
|
<div id="accordion">
|
||||||
|
<div class="accordion-group filters">
|
||||||
|
<div class="table-label">
|
||||||
|
<table class="table main-list">
|
||||||
|
<thead>
|
||||||
|
<tr class="sort-header">
|
||||||
|
|
||||||
|
<th id="sort-name" class="sort span1-2 select"><span><a href="#"><%= t('role_filters.key') %><b class="web-symbol"></b></a></span></th>
|
||||||
|
<% @site_valid_locales.each do |locale| %>
|
||||||
|
<th id="sort-name" class="sort span1-2 select"><span><a href="#"><%= I18nVariable.first(:conditions => {:key => locale})[I18n.locale] %><b class="web-symbol"></b></a></span></th>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<table id="role_filters" class="table main-list">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th class="span1-2"></th>
|
||||||
|
<% @site_valid_locales.each do |locale| %>
|
||||||
|
<th class="span1-2"></th>
|
||||||
|
<% end %>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
<%= render :partial => 'role_filter', :collection => @role_filters %>
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<div id="form"><%= render :partial => "form" %></div>
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
$("#form > form").replaceWith("<%= j render "form" %>");
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
$("#<%= dom_id @role_filter %>").replaceWith("<%= j render :partial => 'role_filter', :collection => [@role_filter] %>");
|
||||||
|
<% @role_filter = @types.new(:display => 'List') # reset for new form %>
|
||||||
|
$("#form_role_filter").replaceWith("<%= j render "form" %>")
|
||||||
|
$("#form_role_filter")[0].reset();
|
||||||
@@ -1,3 +1,9 @@
|
|||||||
|
|
||||||
|
<% content_for :side_bar do %>
|
||||||
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
|
||||||
<%= form_for @sub_attribute,:url => eval("admin_#{@attribute_type}s_path") ,:class=> "form-horizontal" do |f| %>
|
<%= form_for @sub_attribute,:url => eval("admin_#{@attribute_type}s_path") ,:class=> "form-horizontal" do |f| %>
|
||||||
<div class="site-map role-block">
|
<div class="site-map role-block">
|
||||||
<div class="map-block back">
|
<div class="map-block back">
|
||||||
|
|||||||
@@ -1,3 +1,9 @@
|
|||||||
|
|
||||||
|
<% content_for :side_bar do %>
|
||||||
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
|
||||||
<%= form_for @sub_attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
<%= form_for @sub_attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
||||||
<div class="site-map role-block">
|
<div class="site-map role-block">
|
||||||
<div class="map-block back">
|
<div class="map-block back">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<% # encoding: utf-8 %>
|
<% # encoding: utf-8 %>
|
||||||
|
|
||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-group', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
<%= form_for @attribute,:url => eval("admin_#{@attribute_type}_path(@attribute)") ,:class=> "form-horizontal" do |f| %>
|
||||||
|
|||||||
@@ -0,0 +1,47 @@
|
|||||||
|
<h1><%= I18n.t("site.system_preference") %></h1>
|
||||||
|
<ul class="nav nav-tabs" id="myTab">
|
||||||
|
<li class="active"><a href="#summary" data-toggle="tab"><%= I18n.t("site.system_preference_.tab_summary") %></a></li>
|
||||||
|
<li><a href="#commits" data-toggle="tab"><%= I18n.t("site.system_preference_.tab_commits") %></a></li>
|
||||||
|
<li><a href="#backups" data-toggle="tab"><%= I18n.t("site.system_preference_.tab_backups") %></a></li>
|
||||||
|
<li><a href="#resque_logs" data-toggle="tab"><%= I18n.t("site.system_preference_.tab_logs") %></a></li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="tab-content">
|
||||||
|
<div class="tab-pane active in" id="summary">
|
||||||
|
<h2><%= I18n.t("site.system_preference_.summary.disk_space") %>:</h2>
|
||||||
|
<%= content_tag :p,@site.disk_space.gsub(/\n/,"<br />").html_safe if @site.disk_space %>
|
||||||
|
<h2><%= I18n.t("site.system_preference_.summary.code_update_at") %>: </h2>
|
||||||
|
<% @site.system_package_info.each do |index,value| %>
|
||||||
|
<h2><%= index.titleize %> <%= I18n.t("site.system_preference_.summary.version") %>:</h2>
|
||||||
|
<%= content_tag :p,value %>
|
||||||
|
<% end %>
|
||||||
|
<h2><%= I18n.t("site.system_preference_.summary.weekness_report") %>:<%= '' %></h2>
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="commits">
|
||||||
|
<% if @git_commit_list_file %>
|
||||||
|
<% @git_commit_list_file.lines do |line|%>
|
||||||
|
<%= line %><br/>
|
||||||
|
<% end%>
|
||||||
|
<% else %>
|
||||||
|
<div class="well"><%= I18n.t("site.system_preference_.summary.no_data") %></div>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="backups">
|
||||||
|
<%if @db_backup_list_file %>
|
||||||
|
<% @db_backup_list_file.lines do |line|%>
|
||||||
|
<%=line %><br/>
|
||||||
|
<% end %>
|
||||||
|
<% else %>
|
||||||
|
<div class="well"><%= I18n.t("site.system_preference_.summary.no_data") %></div>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="resque_logs">
|
||||||
|
<%if @db_backup_list_file %>
|
||||||
|
<% @resque_logs_file.lines do |line|%>
|
||||||
|
<%=line %><br/>
|
||||||
|
<% end if @resque_logs_file%>
|
||||||
|
<%else %>
|
||||||
|
<div class="well"><%= I18n.t("site.system_preference_.summary.no_data") %></div>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
@@ -35,6 +35,14 @@
|
|||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<div class="control-group">
|
||||||
|
<label class="control-label"><%= t 'site.openness' %></label>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.check_box :frontend_closed %><%= I18n.t('site.frontend_closed') %><br/>
|
||||||
|
<%= f.check_box :backend_openness_on %><%= I18n.t('site.backend_openness_on') %>
|
||||||
|
<p class="help-block"><%= (t 'site.search_help').html_safe %></p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="control-group">
|
<div class="control-group">
|
||||||
<label class="control-label"><%= t 'site.search' %></label>
|
<label class="control-label"><%= t 'site.search' %></label>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
<%= form_for :tag, :url => admin_tags_path, :remote => true, :html => {:id => 'tag_form'} do |f| %>
|
<%= form_for :tag, :url => admin_tags_path, :remote => true, :html => {:id => 'tag_form'} do |f| %>
|
||||||
|
<%= f.fields_for :name_translations do |f| %>
|
||||||
<% @site_valid_locales.each do |locale| %>
|
<% @site_valid_locales.each do |locale| %>
|
||||||
<%= I18nVariable.from_locale(locale) %>:<%= f.text_field locale %>
|
<%= I18nVariable.from_locale(locale) %>:<%= f.text_field locale %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= f.hidden_field :module_app_id, :value => @module_app_id %>
|
<% end %>
|
||||||
|
<%= hidden_field_tag :module_app_id, @module_app_id %>
|
||||||
<%= f.submit t(:add) %>
|
<%= f.submit t(:add) %>
|
||||||
<% end %>
|
<% end %>
|
||||||
@@ -1,7 +1,9 @@
|
|||||||
<%= form_for :tag, :url => admin_tag_path(tag), :method => :put, :remote => true do |f| %>
|
<%= form_for :tag, :url => admin_tag_path(tag), :method => :put, :remote => true do |f| %>
|
||||||
|
<%= f.fields_for :name_translations do |f| %>
|
||||||
<% @site_valid_locales.each do |locale| %>
|
<% @site_valid_locales.each do |locale| %>
|
||||||
<%= I18nVariable.from_locale(locale) %>:<%= f.text_field locale %>
|
<%= I18nVariable.from_locale(locale) %>:<%= f.text_field locale, value: @tag.name_translations[locale] %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= f.hidden_field :module_app_id, :value => tag.module_app_id %>
|
<% end %>
|
||||||
|
<%= hidden_field_tag :module_app_id, @module_app_id %>
|
||||||
<%= f.submit t(:update_) %>
|
<%= f.submit t(:update_) %>
|
||||||
<% end %>
|
<% end %>
|
||||||
@@ -3,11 +3,11 @@
|
|||||||
<i class="icons-tag"></i>
|
<i class="icons-tag"></i>
|
||||||
<% @site_valid_locales.each do |locale| %>
|
<% @site_valid_locales.each do |locale| %>
|
||||||
<%#= I18nVariable.from_locale(locale) %>
|
<%#= I18nVariable.from_locale(locale) %>
|
||||||
<%= tag[locale] %>
|
<%= tag.name_translations[locale] %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div class="action">
|
<div class="action">
|
||||||
<%= link_to t(:edit), edit_admin_tag_path(tag), :remote => true %>
|
<%= link_to t(:edit), edit_admin_tag_path(tag, :module_app_id => @module_app_id), :remote => true %>
|
||||||
<%= link_to t(:delete_), admin_tag_path(tag), :confirm => t('sure?'), :method => :delete, :remote => true %>
|
<%= link_to t(:delete_), admin_tag_path(tag), :confirm => t('sure?'), :method => :delete, :remote => true %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -4,12 +4,34 @@
|
|||||||
|
|
||||||
<div class="groups map-block back <%= role_disable ? 'disabled' : '' %>">
|
<div class="groups map-block back <%= role_disable ? 'disabled' : '' %>">
|
||||||
<h4>
|
<h4>
|
||||||
<button for=<%=@form_index%> class="onoff pull-right"><%= role_disable ? 'OFF' : 'ON' %></button><span><%= role.title %></span>
|
<button for=<%=@form_index%> class="onoff pull-right"><%= role_disable ? 'OFF' : 'ON' %></button><span><%= role.title %><%= t(:role_info)%></span>
|
||||||
<%= hidden_field_tag("user[disable_role][id][#{role.id}]",role_disable,:for=>@form_index,:class=>"subrole_disable_field",:value=>role_disable)%>
|
<%= hidden_field_tag("user[disable_role][id][#{role.id}]",role_disable,:for=>@form_index,:class=>"subrole_disable_field",:value=>role_disable)%>
|
||||||
</h4>
|
</h4>
|
||||||
|
|
||||||
<div class="form-horizontal <%= role_disable ? 'hide' : '' %>">
|
<div class="form-horizontal <%= role_disable ? 'hide' : '' %>">
|
||||||
|
|
||||||
|
<% @form_index = @form_index +1 %>
|
||||||
|
|
||||||
|
<div class="control-group">
|
||||||
|
|
||||||
|
<%= label_tag t(:status), nil, {:func=>"field_label", :for=>"1", :class=>"control-label"} %>
|
||||||
|
<% role.role_statuses.where(:disable => false).each_with_index do |rrs, i|%>
|
||||||
|
<%= hidden_field_tag("user[role_status][id][#{rrs.id}]", false,:for=>"#{@form_index}")%>
|
||||||
|
<%= label_tag(i,check_box_tag( "user[role_status][id][#{rrs.id}]", true, @user.role_statuses.include?(rrs))+rrs.title,:class=>"control-label") %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<% @form_index = @form_index +1 %>
|
||||||
|
|
||||||
|
<div class="control-group">
|
||||||
|
<%= label_tag t(:category), nil, {:func=>"field_label", :for=>"1", :class=>"control-label"} %>
|
||||||
|
<% role.role_categorys.where(:disable => false).each_with_index do |rrcg, i|%>
|
||||||
|
<%= hidden_field_tag("user[role_category][id][#{rrcg.id}]", false,:for=>"#{@form_index}")%>
|
||||||
|
<%= label_tag(i,check_box_tag( "user[role_category][id][#{rrcg.id}]", true, @user.role_categorys.include?(rrcg))+rrcg.title,:class=>"control-label") %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<% role.attribute_fields.each do |rf|%>
|
<% role.attribute_fields.each do |rf|%>
|
||||||
|
|
||||||
<%= rf.block_helper(@user,@form_index)%>
|
<%= rf.block_helper(@user,@form_index)%>
|
||||||
|
|||||||
@@ -1,14 +1,22 @@
|
|||||||
<div class="roles <%= show_roles.key %>">
|
<div class="roles <%= show_roles.key %>">
|
||||||
<%= show_roles.title %>
|
<%= show_roles.title %><%= t(:role_info)%>
|
||||||
<div class="label-line">
|
<div class="label-line">
|
||||||
<hr />
|
<hr />
|
||||||
</div>
|
</div>
|
||||||
<table class="table">
|
<table class="table">
|
||||||
<tbody>
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('status') %></td>
|
||||||
|
<td><%= show_attribute_value(@user.role_statuses.where(:role_id=>show_roles.id).map{|t|t.title.to_s}.join(',')) rescue '' %></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('category') %></td>
|
||||||
|
<td><%= show_attribute_value(@user.role_categorys.where(:role_id=>show_roles.id).map{|t|t.title.to_s}.join(',')) rescue '' %></td>
|
||||||
|
</tr>
|
||||||
<% show_roles.attribute_fields.where(:disabled=>false).each do |rf| %>
|
<% show_roles.attribute_fields.where(:disabled=>false).each do |rf| %>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="span1"><%= rf.title %></td>
|
<td class="span1"><%= rf.title %></td>
|
||||||
<td><%= show_attribute_value(@user.get_attribute_value(rf).get_value_by_locale(I18n.locale)) rescue '' %></td>
|
<td><%= nl2br(show_attribute_value(@user.get_attribute_value(rf).get_value_by_locale(I18n.locale))) rescue '' %></td>
|
||||||
</tr>
|
</tr>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
<%= render :partial => 'show_sub_role',:collection=> @user.get_sub_roles_by_role(show_roles)%>
|
<%= render :partial => 'show_sub_role',:collection=> @user.get_sub_roles_by_role(show_roles)%>
|
||||||
|
|||||||
@@ -2,6 +2,6 @@
|
|||||||
<% show_sub_role.attribute_fields.each do |item|%>
|
<% show_sub_role.attribute_fields.each do |item|%>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="span1"><%= item.title %></td>
|
<td class="span1"><%= item.title %></td>
|
||||||
<td><%= show_attribute_value(@user.get_attribute_value(item).get_value_by_locale(I18n.locale)) rescue '' %></td>
|
<td><%= nl2br(show_attribute_value(@user.get_attribute_value(item).get_value_by_locale(I18n.locale))) rescue '' %></td>
|
||||||
</tr>
|
</tr>
|
||||||
<% end %>
|
<% end %>
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<%= content_tag :li, :class => active_for_controllers('users_new_interface') do -%>
|
<%= content_tag :li, :class => active_for_controllers('users_new_interface') do -%>
|
||||||
<%= link_to content_tag(:i, nil, :class => 'icons-user')+ content_tag(:span, t(:member)), admin_users_new_interface_index_path %>
|
<%= link_to content_tag(:i, nil, :class => 'icons-user')+ content_tag(:span, t(:member_)), admin_users_new_interface_index_path %>
|
||||||
<%= content_tag :ul, :class => ("nav nav-list " + visible_for_controllers('users_new_interface')) do -%>
|
<%= content_tag :ul, :class => ("nav nav-list " + visible_for_controllers('users_new_interface')) do -%>
|
||||||
<%= content_tag :li, link_to((t(:all_member) + content_tag(:i, nil, :class => 'icon-chevron-right')).html_safe, admin_users_new_interface_index_path), :class => active_for_action('users_new_interface', 'index') %>
|
<%= content_tag :li, link_to((t(:all_member) + content_tag(:i, nil, :class => 'icon-chevron-right')).html_safe, admin_users_new_interface_index_path), :class => active_for_action('users_new_interface', 'index') %>
|
||||||
<%= content_tag :li, link_to((t(:add_member) + content_tag(:i, nil, :class => 'icon-chevron-right')).html_safe, new_admin_users_new_interface_path), :class => active_for_action('users_new_interface', 'new') if (is_admin? rescue nil) %>
|
<%= content_tag :li, link_to((t(:add_member) + content_tag(:i, nil, :class => 'icon-chevron-right')).html_safe, new_admin_users_new_interface_path), :class => active_for_action('users_new_interface', 'new') if (is_admin? rescue nil) %>
|
||||||
|
|||||||
@@ -3,9 +3,63 @@
|
|||||||
<div class="map-block back">
|
<div class="map-block back">
|
||||||
<h4><span><%=t(:sys_basic_form)%></span></h4>
|
<h4><span><%=t(:sys_basic_form)%></span></h4>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="controls-block" >
|
||||||
|
<div class="control-group language-swich">
|
||||||
|
<%= f.label t("users.first_name"),{:class=>"control-label", :func=>"field_label"} %>
|
||||||
|
<div class="controls">
|
||||||
|
<div class="tabbable">
|
||||||
|
<div class="tab-content">
|
||||||
|
<% @site_valid_locales.each_with_index do |locale, i| %>
|
||||||
|
<div class="tab-pane fade <%= locale %> user-attribute_values-first_name <%= ( i == 0 ) ? "in active" : '' %>">
|
||||||
|
<%= f.fields_for :first_name_translations do |f| %>
|
||||||
|
<%= f.text_field locale, :func=>'input_unit', :value => (@user.first_name_translations[locale] rescue nil) %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<ul class="nav nav-pills">
|
||||||
|
<% @site_valid_locales.each_with_index do |locale, i| %>
|
||||||
|
<li <%= ( i == 0 ) ? "class=active" : '' %> for="<%= locale %>">
|
||||||
|
<a data-toggle="tab" href=".user-attribute_values-first_name.<%= locale %>"><%= I18nVariable.from_locale(locale) %></a></li>
|
||||||
|
<% end %>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="controls-block" >
|
||||||
|
<div class="control-group language-swich">
|
||||||
|
<%= f.label t("users.last_name"),{:class=>"control-label", :func=>"field_label"} %>
|
||||||
|
<div class="controls">
|
||||||
|
<div class="tabbable">
|
||||||
|
<div class="tab-content">
|
||||||
|
<% @site_valid_locales.each_with_index do |locale, i| %>
|
||||||
|
<div class="tab-pane fade <%= locale %> user-attribute_values-last_name <%= ( i == 0 ) ? "in active" : '' %>">
|
||||||
|
<%= f.fields_for :last_name_translations do |f| %>
|
||||||
|
<%= f.text_field locale, :func=>'input_unit', :value => (@user.last_name_translations[locale] rescue nil) %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<ul class="nav nav-pills">
|
||||||
|
<% @site_valid_locales.each_with_index do |locale, i| %>
|
||||||
|
<li <%= ( i == 0 ) ? "class=active" : '' %> for="<%= locale %>">
|
||||||
|
<a data-toggle="tab" href=".user-attribute_values-last_name.<%= locale %>"><%= I18nVariable.from_locale(locale) %></a></li>
|
||||||
|
<% end %>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="form-horizontal">
|
<div class="form-horizontal">
|
||||||
<div class="control-group">
|
<div class="control-group">
|
||||||
<%= f.label t(:email),:class=>"control-label" %><br />
|
<%= f.label t("users.email"),:class=>"control-label" %>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<%= f.email_field :email %>
|
<%= f.email_field :email %>
|
||||||
</div>
|
</div>
|
||||||
@@ -14,19 +68,53 @@
|
|||||||
|
|
||||||
<div class="form-horizontal">
|
<div class="form-horizontal">
|
||||||
<div class="control-group">
|
<div class="control-group">
|
||||||
<%= f.label t(:password),:class=>"control-label" %>
|
<%= f.label t("users.sid"),:class=>"control-label" %>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<%= f.password_field :password %>
|
<%= f.text_field :sid %>
|
||||||
|
<span>( <%= t("users.sid_note")%> )</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="control-group">
|
||||||
|
<%= f.label t("users.office_tel"),:class=>"control-label" %>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.text_field :office_tel %>
|
||||||
|
<span>( <%= t("users.office_tel_note")%> )</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-horizontal">
|
<div class="form-horizontal">
|
||||||
<div class="control-group">
|
<div class="control-group">
|
||||||
<%= f.label t(:password_confirmation),:class=>"control-label" %>
|
<%= f.label t("users.avatar"),:class=>"control-label" %>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<%= f.password_field :password_confirmation %>
|
<%= f.file_field :avatar %>
|
||||||
|
<% if @user.avatar.file %>
|
||||||
|
<%= f.check_box :remove_avatar %>
|
||||||
|
<%= t('delete.file') %>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="control-group">
|
||||||
|
<%= f.label t("users.sex"),:class=>"control-label" %>
|
||||||
|
<div class="controls">
|
||||||
|
<label func="input_unit" for="0" class=" radio inline">
|
||||||
|
<%= f.radio_button :sex, "male" %><%= t('users.male')%>
|
||||||
|
</label>
|
||||||
|
<label func="input_unit" for="1" class=" radio inline">
|
||||||
|
<%= f.radio_button :sex, "female" %><%= t('users.female')%>
|
||||||
|
</label>
|
||||||
|
<label func="input_unit" for="2" class=" radio inline">
|
||||||
|
<%= f.radio_button :sex, "unknown" %><%= t('users.unknown')%>
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
<%#= devise_error_messages! %>
|
||||||
|
<%= flash_messages %>
|
||||||
|
|
||||||
|
<div class="map-block back">
|
||||||
|
<h4><span><%=t(:sys_basic_id_form)%></span></h4>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="control-group">
|
||||||
|
<%= f.label t("users.user_id"),:class=>"control-label" %>
|
||||||
|
<%#= f.label t(:user_id),:class=>"control-label" %>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.text_field :user_id %>
|
||||||
|
<span>( <%= t("users.user_id_note")%> )</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="control-group">
|
||||||
|
<%= f.label t("users.new_password"),:class=>"control-label" %>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.password_field :password %>
|
||||||
|
<span>( <%= t("users.new_password_note")%> )</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-horizontal">
|
||||||
|
<div class="control-group">
|
||||||
|
<%= f.label t("users.new_password_confirmation"),:class=>"control-label" %>
|
||||||
|
<div class="controls">
|
||||||
|
<%= f.password_field :password_confirmation %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
@@ -18,7 +18,10 @@
|
|||||||
<%= link_to user_for_summary.name,admin_users_new_interface_path(user_for_summary)%>
|
<%= link_to user_for_summary.name,admin_users_new_interface_path(user_for_summary)%>
|
||||||
</p>
|
</p>
|
||||||
<div class="user-title">
|
<div class="user-title">
|
||||||
<span>#TODO 教授兼系主任</span><span>#TODO 大學部校友</span>
|
<% user_for_summary.roles.each do |rf| %>
|
||||||
|
<% @roledata = Role.find(rf.id) %>
|
||||||
|
<span><%= @roledata.title %></span>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<ul class="user-itemborder clear">
|
<ul class="user-itemborder clear">
|
||||||
<li class="pull-left"><span>#TODO 258</span>Publications</li>
|
<li class="pull-left"><span>#TODO 258</span>Publications</li>
|
||||||
|
|||||||
@@ -5,6 +5,32 @@
|
|||||||
</div>
|
</div>
|
||||||
<table class="table">
|
<table class="table">
|
||||||
<tbody>
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.first_name')%></td>
|
||||||
|
<td><%= @user.first_name %></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.last_name')%></td>
|
||||||
|
<td><%= @user.last_name %></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.email')%></td>
|
||||||
|
<td><%= @user.email %></td>
|
||||||
|
</tr>
|
||||||
|
<% if !@user.sid.blank? %>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.sid')%></td>
|
||||||
|
<td><%= @user.sid %></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.office_tel')%></td>
|
||||||
|
<td><%= @user.office_tel %></td>
|
||||||
|
</tr>
|
||||||
|
<% end %>
|
||||||
|
<tr>
|
||||||
|
<td class="span1"><%= t('users.sex')%></td>
|
||||||
|
<td><%= t("users.#{@user.sex}") %></td>
|
||||||
|
</tr>
|
||||||
<% items.each do |item| %>
|
<% items.each do |item| %>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="span1"><%= item[:name] %></td>
|
<td class="span1"><%= item[:name] %></td>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% content_for :page_specific_css do -%>
|
<% content_for :page_specific_css do -%>
|
||||||
|
|||||||
@@ -0,0 +1,32 @@
|
|||||||
|
<% content_for :side_bar do %>
|
||||||
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% content_for :page_specific_css do -%>
|
||||||
|
<%= stylesheet_link_tag "member" %>
|
||||||
|
<%= stylesheet_link_tag "site-map" %>
|
||||||
|
<% end -%>
|
||||||
|
<% content_for :page_specific_javascript do -%>
|
||||||
|
<%= javascript_include_tag "/static/jquery.cycle.all.latest.js" %>
|
||||||
|
<%= javascript_include_tag "inc/modal-preview" %>
|
||||||
|
<%= javascript_include_tag "lib/contenteditable" %>
|
||||||
|
<%= javascript_include_tag "inc/ploy_input_field" %>
|
||||||
|
<%= javascript_include_tag "inc/input_module" %>
|
||||||
|
<%= javascript_include_tag "inc/attribute_panel_select" %>
|
||||||
|
<%= javascript_include_tag "inc/attribute_onoff" %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
|
|
||||||
|
<%= content_tag :div,:class=>"user-role site-map role-block" do%>
|
||||||
|
|
||||||
|
<%= form_for @user, :url => admin_users_new_interface_path(@user), :html => { :multipart => true } do |f| %>
|
||||||
|
<%= f.error_messages %>
|
||||||
|
<%= render :partial => 'user_basic_passwd', :locals => {:f => f}%>
|
||||||
|
<div class="button_bar">
|
||||||
|
<%= link_back %>
|
||||||
|
<%= hidden_field_tag 'edit_type', 'edit_passwd' %>
|
||||||
|
<%= link_to t(:update_), "#", :onclick=>"$('#edit_user_#{@user.id}').submit()" %>
|
||||||
|
</div>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
|
<% end -%>
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial => "js_and_css"%>
|
<%= render :partial => "js_and_css"%>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial => "js_and_css"%>
|
<%= render :partial => "js_and_css"%>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial => "js_and_css"%>
|
<%= render :partial => "js_and_css"%>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% content_for :page_specific_css do -%>
|
<% content_for :page_specific_css do -%>
|
||||||
@@ -21,6 +21,7 @@
|
|||||||
<%= form_for @user, :url => admin_users_new_interface_index_path, :html => { :multipart => true },:method => :post do |f| %>
|
<%= form_for @user, :url => admin_users_new_interface_index_path, :html => { :multipart => true },:method => :post do |f| %>
|
||||||
|
|
||||||
<%= f.error_messages %>
|
<%= f.error_messages %>
|
||||||
|
<%= render :partial => 'user_basic_passwd', :locals => {:f => f}%>
|
||||||
<%= render :partial => 'user_basic', :locals => {:f => f}%>
|
<%= render :partial => 'user_basic', :locals => {:f => f}%>
|
||||||
<%= render :partial => 'form', :locals => { :f => f } %>
|
<%= render :partial => 'form', :locals => { :f => f } %>
|
||||||
<div class="button_bar">
|
<div class="button_bar">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="member-plugin">
|
<div class="member-plugin">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial => "js_and_css"%>
|
<%= render :partial => "js_and_css"%>
|
||||||
@@ -39,6 +39,7 @@
|
|||||||
<%= @user.email %>
|
<%= @user.email %>
|
||||||
</p>
|
</p>
|
||||||
<%= link_to("<i class='icon-pencil'></i>#{t(:edit)}".html_safe,edit_admin_users_new_interface_path(@user),:class=>"btn btn-small" ) if is_admin?%>
|
<%= link_to("<i class='icon-pencil'></i>#{t(:edit)}".html_safe,edit_admin_users_new_interface_path(@user),:class=>"btn btn-small" ) if is_admin?%>
|
||||||
|
<%= link_to("<i class='icon-pencil'></i>#{t("users.change_passwd")}".html_safe,admin_users_new_interface_edit_passwd_path(@user),:class=>"btn btn-small" ) if is_admin?%>
|
||||||
</div>
|
</div>
|
||||||
<div class="user-roles my_scroll">
|
<div class="user-roles my_scroll">
|
||||||
<div class="scrollbar">
|
<div class="scrollbar">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<% content_for :side_bar do %>
|
<% content_for :side_bar do %>
|
||||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:member_), :link_url => admin_site_site_info_path(@site), :icon => 'icons-users', :side_bar_content => 'admin/users_new_interface/side_bar'} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% content_for :page_specific_css do -%>
|
<% content_for :page_specific_css do -%>
|
||||||
|
|||||||
@@ -2,13 +2,9 @@
|
|||||||
<div id="content">
|
<div id="content">
|
||||||
<div id="header" class="hh2">
|
<div id="header" class="hh2">
|
||||||
<div class="dtitle w2 hh2 hp sdm">
|
<div class="dtitle w2 hh2 hp sdm">
|
||||||
<div class="thmtxth sdm_t" id="section_heading">Loading...</div>
|
<div class="thmtxth sdm_t" id="section_heading"></div>
|
||||||
<div class="admbg sdm_o">
|
<div class="admbg sdm_o w2">
|
||||||
<ul id="section_list">
|
<ul id="section_list">
|
||||||
<!-- <li><a class="admtxt hp w2 hh2" href="">Campus</a></li>
|
|
||||||
<li><a class="admtxt hp w2 hh2" href="">Research</a></li>
|
|
||||||
<li><a class="admtxt hp w2 hh2" href="">Social</a></li>
|
|
||||||
<li><a class="admtxt hp w2 hh2" href="">Private</a></li> -->
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<div id="side">
|
<div id="side">
|
||||||
<div id="rwidget" class="wh2 thmc4">
|
<div id="rwidget" class="wh2 thmc4">
|
||||||
<ul class="docklist">
|
<ul class="docklist">
|
||||||
<li class="d_cate"><a callback-method='initializeDesktop' href="desktop/" class="widget_fn wh2 hh2" id='home' onclick="return false;"><span class="widget_icon"><img src="" alt="Home" id="home_icon" width="30" height="30"/></span></a>
|
<li class="d_cate"><a callback-method='initializeDesktop' href="desktop/desktop" class="widget_fn wh2 hh2" id='home' onclick="return false;"><span class="widget_icon"><img src="" alt="Home" id="home_icon" width="30" height="30"/></span></a>
|
||||||
<ul class="dock_child hh2 thmc4" style="width: 180px;">
|
<ul class="dock_child hh2 thmc4" style="width: 180px;">
|
||||||
<li class="dock_item"><a callback-method='initializeAppSearch' href="<%= desktop_app_manager_path %>" class="widget_fn wh2 hh2" id="d_app_manager" onclick="return false;"><span class="widget_icon"><img src="" alt="App Manager" id="app_manager_icon" width="30" height="30"/></span></a></li>
|
<li class="dock_item"><a callback-method='initializeAppSearch' href="<%= desktop_app_manager_path %>" class="widget_fn wh2 hh2" id="d_app_manager" onclick="return false;"><span class="widget_icon"><img src="" alt="App Manager" id="app_manager_icon" width="30" height="30"/></span></a></li>
|
||||||
<li class="dock_item"><a callback-method='initializeSectionsManager' href="<%= desktop_allsections_path %>" class="widget_fn wh2 hh2" id="d_sections" custom-load="sections" onclick="return false;"><span class="widget_icon"><img src="" alt="All Sections" id="sections_icon" width="30" height="30"/></span></a></li>
|
<li class="dock_item"><a callback-method='initializeSectionsManager' href="<%= desktop_allsections_path %>" class="widget_fn wh2 hh2" id="d_sections" custom-load="sections" onclick="return false;"><span class="widget_icon"><img src="" alt="All Sections" id="sections_icon" width="30" height="30"/></span></a></li>
|
||||||
|
|||||||
@@ -2,10 +2,10 @@
|
|||||||
<div class="overview" content-layout="simple" base-width="1000">
|
<div class="overview" content-layout="simple" base-width="1000">
|
||||||
<div class="s_title hh2">Section Names</div>
|
<div class="s_title hh2">Section Names</div>
|
||||||
<ul class="s_form" id="desktop_names">
|
<ul class="s_form" id="desktop_names">
|
||||||
<li class="s_grid_row"><label for="s_name1">Section 1</label><input id="s_name1" type="text" value=""></li>
|
<li class="s_grid_row"><label class="s_grid s_grid_4" for="s_name1">Section 1</label><input id="s_name1" class="s_grid s_grid_8" type="text" value=""></li>
|
||||||
<li class="s_grid_row"><label for="s_name2">Section 2</label><input id="s_name2" type="text" value=""></li>
|
<li class="s_grid_row"><label class="s_grid s_grid_4" for="s_name2">Section 2</label><input id="s_name2" class="s_grid s_grid_8" type="text" value=""></li>
|
||||||
<li class="s_grid_row"><label for="s_name3">Section 3</label><input id="s_name3" type="text" value=""></li>
|
<li class="s_grid_row"><label class="s_grid s_grid_4" for="s_name3">Section 3</label><input id="s_name3" class="s_grid s_grid_8" type="text" value=""></li>
|
||||||
<li class="s_grid_row"><label for="s_name4">Section 4</label><input id="s_name4" type="text" value=""></li>
|
<li class="s_grid_row"><label class="s_grid s_grid_4" for="s_name4">Section 4</label><input id="s_name4" class="s_grid s_grid_8" type="text" value=""></li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="s_subtitle">sample desciption</div>
|
<div class="s_subtitle">sample desciption</div>
|
||||||
<div class="s_action">
|
<div class="s_action">
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
<div class="theme_preview vp thmbgc" style="background-color: #000;" id="theme_preview_area">
|
<div class="theme_preview vp thmbgc" style="background-color: #000;" id="theme_preview_area">
|
||||||
<div class="thmtxth hh1 hp" style="margin-left:108px;">Theme Text1</div>
|
<div class="thmtxth hh1 hp" style="margin-left:108px;">Theme Text1</div>
|
||||||
<div class="theme_plate">
|
<div class="theme_plate">
|
||||||
<div class="thmc4 h1 wh3"></div>
|
<div class="thmc4 h1 wh2"></div>
|
||||||
<div class="thmc1 h1 w1"><div class="thmtxt hp">Theme Text2</div></div>
|
<div class="thmc1 h1 w1"><div class="thmtxt hp">Theme Text2</div></div>
|
||||||
<div class="g_sep h1 op07"></div>
|
<div class="g_sep h1 op07"></div>
|
||||||
<div class="thmc2 h1 w1"><div class="thmtxt hp">Theme Text</div></div>
|
<div class="thmc2 h1 w1"><div class="thmtxt hp">Theme Text</div></div>
|
||||||
@@ -30,10 +30,10 @@
|
|||||||
<div>
|
<div>
|
||||||
<table id="color_input" cellpadding="0" cellspacing="0" border="0" width="528" >
|
<table id="color_input" cellpadding="0" cellspacing="0" border="0" width="528" >
|
||||||
<tr>
|
<tr>
|
||||||
<th class="s_title hh2" width="190px">Theme Color</th>
|
<th class="s_title size_small hh2" width="190px">Theme Color</th>
|
||||||
<th class="s_title hh2">Line Color</th>
|
<th class="s_title size_small hh2">Line Color</th>
|
||||||
<th class="s_title hh2" width="120px">Text Color</th>
|
<th class="s_title size_small hh2" width="120px">Text Color</th>
|
||||||
<th class="s_title hh2" width="120px">Background Color</th>
|
<th class="s_title size_small hh2" width="120px">Background Color</th>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
|
|||||||
@@ -2,17 +2,22 @@
|
|||||||
<div class="s_title hh2">Password Managment</div>
|
<div class="s_title hh2">Password Managment</div>
|
||||||
<%= form_for(resource, :as => resource_name, :url => users_passwd_path(resource_name), :html => { :method => :put, "form-type"=>"ajax_form" ,"callback-method"=>"passwordUpdate" }) do |f| %>
|
<%= form_for(resource, :as => resource_name, :url => users_passwd_path(resource_name), :html => { :method => :put, "form-type"=>"ajax_form" ,"callback-method"=>"passwordUpdate" }) do |f| %>
|
||||||
<ul class="s_form">
|
<ul class="s_form">
|
||||||
<li class="s_grid_row"><%= f.label :current_password %>
|
<li class="s_grid_row">
|
||||||
<%= f.password_field :current_password %></li>
|
<%= f.label :current_password, :class => 's_grid s_grid_4' %>
|
||||||
|
<%= f.password_field :current_password, :class => 's_grid s_grid_8' %>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="s_grid_row"><%= f.label :password %>
|
<li class="s_grid_row">
|
||||||
<%= f.password_field :password %></li>
|
<%= f.label :password, :class => 's_grid s_grid_4' %>
|
||||||
|
<%= f.password_field :password, :class => 's_grid s_grid_8' %>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="s_grid_row"><%= f.label :password_confirmation %>
|
<li class="s_grid_row">
|
||||||
<%= f.password_field :password_confirmation %></li>
|
<%= f.label :password_confirmation, :class => 's_grid s_grid_4' %>
|
||||||
|
<%= f.password_field :password_confirmation, :class => 's_grid s_grid_8' %>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="s_action"><%= f.submit "Update", :class => "setting_btn thmc1 thmtxt w1 hh1 hp" %></div>
|
<div class="s_action"><%= f.submit "Update", :class => "setting_btn thmc1 thmtxt w1 hh1 hp" %></div>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
Loaded 100 of 407 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user