Compare commits

..
Author SHA1 Message Date
harrybomrah 8b1702f358 isotope embedded inside desktop kernel 2013-08-28 16:30:08 +08:00
harrybomrah 4a68b1edb6 file title translations fixed 2013-08-21 13:46:04 +08:00
707 changed files with 10307 additions and 19850 deletions

No files matched your search

+3 -6
View File
@@ -11,14 +11,13 @@ gem "net-ldap", "~> 0.3.1"
gem 'devise', '1.5.3'
gem 'exception_notification' # Send error trace
gem 'execjs'
gem 'jquery-rails', '3.0.4'
gem 'jquery-ui-rails', "4.0.5"
gem 'jquery-rails', '2.1.4'
gem 'jquery-ui-rails'
gem "select2-rails", '3.3.1'
gem 'kaminari'
gem 'time_difference'
gem "acts_as_unvlogable"
gem 'youtube_it'
gem 'gotcha'
# gem "memcached", "~> 1.4.3"
# gem "memcache-client"
@@ -39,7 +38,7 @@ gem 'resque-scheduler' # job scheduling
gem 'resque-restriction'
#gem 'rb-readline'
# gem 'ruby-debug19'
gem 'rubyzip', '< 1.0.0'
gem 'rubyzip'
gem 'sunspot_mongo'
gem 'sunspot_solr'
@@ -98,8 +97,6 @@ group :test, :development do
gem "watchr"
gem "spork"
gem "capybara"
#gem 'rack-mini-profiler'
gem "better_errors"
# gem 'yard'
# gem "bluecloth"
end
+1 -1
View File
@@ -5,7 +5,7 @@
// the compiled file.
//
//= require jquery
//= require cycle2
//= require mobile/jquery.cycle.all
//= require mobile/jquery.mu.image.resize
//= require mobile/orbit.mobile
//= require mobile/jquery.mobile-1.2.0.min
Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 78 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.8 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

@@ -1,21 +0,0 @@
$(function() {
$.pageslide.closeCallback(function(pageslide, item) {
$("tr").removeClass("active");
pageslide.find('.preview').cycle('destroy')
});
$.pageslide.loadComplete(function(pageslide, item) {
$("tr").removeClass("active");
item.closest('tr').addClass('active');
if(item.data('id') == 'new') {
resetForm();
pageslide.find('form').attr('action', '/admin/ad_banners/');
pageslide.find('form').attr('method', 'post');
}
else {
setForm(item.data('form'));
pageslide.find('form').attr('action', '/admin/ad_banners/' + item.data('id'));
pageslide.find('form').attr('method', 'put');
}
setSlideshow(pageslide.find('.preview'), item.data());
});
})
@@ -1,19 +0,0 @@
$(function() {
$.pageslide.closeCallback(function(pageslide, item) {
$("tr").removeClass("active");
});
$.pageslide.loadComplete(function(pageslide, item) {
$("tr").removeClass("active");
item.closest('tr').addClass('active');
if(item.data('id') == 'new') {
resetForm();
pageslide.find('form').attr('action', '/admin/module_apps/' + item.data('module') + '/categories/');
pageslide.find('form').attr('method', 'post');
}
else {
setForm(item.data('form'));
pageslide.find('form').attr('action', '/admin/module_apps/' + item.data('module') + '/categories/' + item.data('id'));
pageslide.find('form').attr('method', 'put');
}
});
})
-102
View File
@@ -1,102 +0,0 @@
!function ($) {
$.fn.checkListLength = function (param){
_defaultSettings = {
onlyOne: null,
};
_set = $.extend(_defaultSettings, param);
$this = this;
$li = this.children('li');
$dropzone = $('#dropzone');
if(($li.length - _set.onlyOne) == 0) {
$('#dropzone').fadeIn(300);
} else {
$('#dropzone').fadeOut(300);
};
$('#file-list').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
}
}(window.jQuery);
$(function () {
'use strict';
// Initialize the jQuery File Upload widget:
$('#fileupload').fileupload({
maxFileSize: 5000000,
acceptFileTypes: /(\.|\/)(gif|jpe?g|png|pdf|doc|docx|ppt|pptx|xls|xlsx)$/i,
dropZone: $('#dropzone'),
headers:{
'X-CSRF-Token': $('meta[name="csrf-token"]').attr("content")
}
}).bind('fileuploadstop', function (e, data) {
window.location.reload();
});
});
$(document).ready(function(){
var insertBtn = $("#insert_btn"),
deleteBtn = $("#delete_btn"),
url = null;
$("#asset_sort_list").on(clickEvent,"input[type=checkbox]",function(){
if($("#asset_sort_list input[type=checkbox]:checked").length == 1){
url = window.location.protocol + "//" + window.location.host + $("#url_" + $("input[type=checkbox]:checked").val()).val();
insertBtn.show();
}else{
insertBtn.hide();
url = null;
}
if($("#asset_sort_list input[type=checkbox]:checked").length)
deleteBtn.show();
else
deleteBtn.hide();
})
insertBtn.bind(clickEvent,function(){
var alt_text = $("#"+language+"_desc_"+$("input[type=checkbox]:checked").val()).val();
alt_text = (alt_text ? alt_text : "This is an image");
if(url){
window.opener.CKEDITOR.tools.callFunction( funcNum, url, function() {
var element,
dialog = this.getDialog();
if ( dialog.getName() == 'image' ) {
element = dialog.getContentElement( 'info', 'txtAlt' );
if ( element )
element.setValue( alt_text );
}
});
window.close();
}
})
deleteBtn.bind( clickEvent,function(){
var items_to_delete = [],
type = getUrlParam("type");
$("input[type=checkbox]:checked").each(function(){
items_to_delete.push($(this).val());
})
$.post("<%= delete_files_admin_assets_path %>",{"files":items_to_delete,"type":type},function(){
deleteBtn.hide();
})
})
var currentEdit = null;
$(document).on("ajax:success","form[data-remote=true]",function(evt, data, xhr){
currentEdit.replaceWith($(data));
$("#editform").modal("hide");
})
$("#asset_sort_list").on(clickEvent,".editform",function(){
currentEdit = $(this).parent().parent();
$.get($(this).attr("href"),function(data){
$("#editform").html(data).modal("show");
})
return false;
})
function getUrlParam( paramName ) {
var reParam = new RegExp( '(?:[\?&]|&)' + paramName + '=([^&]+)', 'i' ) ;
var match = window.location.search.match(reParam) ;
return ( match && match.length > 1 ) ? match[ 1 ] : null ;
}
var funcNum = getUrlParam( 'CKEditorFuncNum' ),
t = getUrlParam('CKEditor').split("_"),
language = t[t.length-1];
language = (language == "tw" ? "zh_tw" : language);
})
+1 -18
View File
@@ -1,18 +1 @@
//= require lib/tags
$(function() {
$.pageslide.closeCallback(function(pageslide, item) {
$('.filter-item').removeClass("active");
});
$.pageslide.loadComplete(function(pageslide, item) {
$('.filter-item').removeClass("active");
item.closest('li').addClass('active');
if(item.hasClass('btn')) {
addTagsTab();
$('#filter-default-tag').fastLiveFilter('.add-default-tags-list', '.filter-item', '.tag');
$('.tags-groups').cardCheck({
item: '.card',
});
};
});
})
//= require admin/tags
+1 -21
View File
@@ -1,21 +1 @@
//= require lib/tags
$(function() {
$.pageslide.closeCallback(function(pageslide, item) {
$('.filter-item').removeClass("active");
});
$.pageslide.loadComplete(function(pageslide, item) {
$('.filter-item').removeClass("active");
item.closest('li').addClass('active');
if(item.data('id') == 'new') {
resetForm();
pageslide.find('form').attr('action', '/admin/tags/');
pageslide.find('form').attr('method', 'post');
}
else {
setForm(item.data('form'));
pageslide.find('form').attr('action', '/admin/tags/' + item.data('id'));
pageslide.find('form').attr('method', 'put');
}
});
})
//= require lib/tags
+33 -36
View File
@@ -38,11 +38,7 @@ if($.support.touch) {
$checked.each(function() {
if(!$(this).closest('div').hasClass('togglebox')) {
$(this).wrap('<div class="toggle-control"/>');
if($(this).attr('type') == "hidden" && $(this).attr('value')) {
$(this).wrap('<div class="togglebox disabled" />');
} else {
$(this).wrap('<div class="togglebox" />');
}
$(this).wrap('<div class="togglebox" />');
$('<label><b></b></label>').insertAfter($(this));
if($(this).data().deploy) {
switch($(this).data().deploy) {
@@ -256,8 +252,8 @@ if($.support.touch) {
$arrow = $('.sub-nav-arrow'),
$wrap = $('#main-wrap'),
$wrapLeft = $wrap.css('margin-left'),
$position = $arrow.outerHeight(true)*-1,
$arrowHeightFormat = $arrow.outerHeight(true)/2;
$position = 0,
$arrowHeightFormat = $('.position').height()-8;
if($('#sidebar').length>0) {
$wrap.css({'margin-left': 61});
$wrapLeft = 61;
@@ -274,7 +270,7 @@ if($.support.touch) {
}
// Arrow defaults position
$position = $el.eq($elIndex).position().top+$el.eq($elIndex).height()/2-$arrowHeightFormat+$('.scroller').position().top;
$position = $el.eq($elIndex).offset().top-$el.eq($elIndex).height()/2+$arrowHeightFormat-$(document).scrollTop();
$arrow.css({
'top': $position,
});
@@ -285,7 +281,7 @@ if($.support.touch) {
$el.on(mouseenterEvent, function(e) {
$block.siblings().removeClass('show').eq($(this).index()).addClass('show');
$arrow.stop(true, false).animate({
top: ($(this).position().top+$(this).height()/2)-$arrowHeightFormat+$('.scroller').position().top,
top: ($(this).offset().top-$(this).height()/2)+$arrowHeightFormat-$(document).scrollTop(),
},{
duration: 500,
easing: 'easeInOutBack',
@@ -329,7 +325,7 @@ if($.support.touch) {
})
};
// $el.on('mouseleave', function() {
// $el.hasClass('active') ? $position = $el.eq($elIndex).position().top+$el.eq($elIndex).height()/2-$arrowHeightFormat+$('.scroller').position().top;
// $el.hasClass('active') ? $position = $el.eq($elIndex).offset().top-$el.eq($elIndex).height()/2+$arrowHeightFormat-$(document).scrollTop() : 0;
// $(this).hasClass('active') ? '':$(this).children('span').removeClass('hover');
// });
$block.on({
@@ -376,9 +372,9 @@ if($.support.touch) {
if($elIndex === null) {
$position = $arrow.outerHeight(true)*-1;
$position = 0;
} else {
$position = $el.eq($elIndex).position().top+$el.eq($elIndex).height()/2-$arrowHeightFormat+$('.scroller').position().top;
$position = $el.eq($elIndex).offset().top-$el.eq($elIndex).height()/2+$arrowHeightFormat-$(document).scrollTop();
}
$arrow.stop(true, false).animate({
top: $position,
@@ -413,8 +409,8 @@ if($.support.touch) {
});
// Sidebar Nav Drag
if(/MSIE 8.0/g.test($ua)){
$arrow.remove();
$sidebarMenu.addClass('nano')
.css({'position': 'relative', 'top': '0px'})
.children('.scroller')
.addClass('content')
.removeClass('scroller');
@@ -473,26 +469,9 @@ if($.support.touch) {
// }
// }
};
$.fn.delayKeyup = function(callback, ms){
var timer = 0;
$(this).keyup(function(){
clearTimeout (timer);
timer = setTimeout(callback, ms);
});
return $(this);
};
}(window.jQuery);
var ini = function() {
api = this
api.modal = function(e) {
$('#dialog a.delete-item').attr("href", e);
$('#dialog').modal('show');
}
}
var ini = function() {
api = this
api.modal = function(e) {
@@ -504,13 +483,31 @@ var ini = function() {
// Open Slide
function openSlide() {
var $openSlide = $('.open-slide');
typeof customOpenSlide === 'function' ? customOpenSlide($openSlide) : $openSlide.pageslide();
var $openSlide = $('.open-slide'),
$pageslideW;
$(window).width() > 1440 ? $pageslideW = 1024 : $pageslideW = 954;
$(window).resize(function() {
$(this).width() > 1440 ? $pageslideW = 1024 : $pageslideW = 954;
})
$openSlide.each(function() {
if($(this).hasClass('view-page')) {
$(this).pageslide({ W: $pageslideW, iframe: true });
} else if($('.item-groups').length) {
$(this).pageslide({ W: 324 });
} else {
$(this).pageslide();
};
});
$('.bottomnav .open-slide').on('click', function() {
$('.table tr').removeClass('active');
$('.filter-item').removeClass('active')
});
}
function formTip() {
if($('.main-forms').length && $('.add-on').length || $('.phtot-action').length) {
$('.main-forms .add-on, .main-forms .file-link, .phtot-action li').tooltip({
if($('.main-forms').length && $('.add-on').length) {
$('.main-forms .add-on, .main-forms .file-link').tooltip({
position: {
my: "center bottom-4",
at: "center top"
@@ -540,7 +537,7 @@ function changeStatusHidden() {
// Document Ready
$(function() {
new ini();
$('#main-wrap').on('click', '.delete', function() {
$('.delete').on('click', function() {
api.modal($(this).attr('rel'));
})
initialState();
@@ -568,7 +565,7 @@ $(function() {
if($('#sidebar').length) {
if(!/MSIE 8.0/g.test(navigator.userAgent)){
document.getElementById('sidebar').addEventListener('touchmove', function (e) { e.preventDefault(); }, false);
}
};
}
if($('#pageslide').length) {
openSlide();
@@ -26,11 +26,10 @@ CKEDITOR.editorConfig = function( config ) {
// config.filebrowserImageBrowseUrl = '/browser/browse.php?type=Images';
// config.filebrowserUploadUrl = '/uploader/upload.php';
config.filebrowserBrowseUrl = "<%= Rails.application.routes.url_helpers.admin_assets_path %>?module_app_id=<%= ModuleApp.first(conditions: {title: 'Asset'}).id.to_s %>";
config.filebrowserImageBrowseUrl = "<%= Rails.application.routes.url_helpers.admin_assets_path %>?type=images&module_app_id=<%= ModuleApp.first(conditions: {title: 'Asset'}).id.to_s %>";
// config.filebrowserUploadUrl = "<%= Rails.application.routes.url_helpers.file_upload_admin_assets_path %>";
config.filebrowserBrowseUrl = "<%= Rails.application.routes.url_helpers.file_upload_admin_assets_path %>"
config.filebrowserUploadUrl = "<%= Rails.application.routes.url_helpers.file_upload_admin_assets_path %>"
// config.contentsCss = '/orbit_4.0.1/assets/javascripts/lib/ckeditor/plugins/stylesheetparser/samples/assets/sample.css';
config.contentsCss = '/orbit_4.0.1/assets/javascripts/lib/ckeditor/plugins/stylesheetparser/samples/assets/sample.css';
// Load from a list of definitions.
// config.stylesSet = [
-10
View File
@@ -1,10 +0,0 @@
/*
Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
(function(a){CKEDITOR.config.jqueryOverrideVal="undefined"==typeof CKEDITOR.config.jqueryOverrideVal?!0:CKEDITOR.config.jqueryOverrideVal;"undefined"!=typeof a&&(a.extend(a.fn,{ckeditorGet:function(){var a=this.eq(0).data("ckeditorInstance");if(!a)throw"CKEditor is not initialized yet, use ckeditor() with a callback.";return a},ckeditor:function(g,d){if(!CKEDITOR.env.isCompatible)throw Error("The environment is incompatible.");if(!a.isFunction(g))var k=d,d=g,g=k;var i=[],d=d||{};this.each(function(){var b=
a(this),c=b.data("ckeditorInstance"),f=b.data("_ckeditorInstanceLock"),h=this,j=new a.Deferred;i.push(j.promise());if(c&&!f)g&&g.apply(c,[this]),j.resolve();else if(f)c.once("instanceReady",function(){setTimeout(function(){c.element?(c.element.$==h&&g&&g.apply(c,[h]),j.resolve()):setTimeout(arguments.callee,100)},0)},null,null,9999);else{if(d.autoUpdateElement||"undefined"==typeof d.autoUpdateElement&&CKEDITOR.config.autoUpdateElement)d.autoUpdateElementJquery=!0;d.autoUpdateElement=!1;b.data("_ckeditorInstanceLock",
!0);c=a(this).is("textarea")?CKEDITOR.replace(h,d):CKEDITOR.inline(h,d);b.data("ckeditorInstance",c);c.on("instanceReady",function(d){var e=d.editor;setTimeout(function(){if(e.element){d.removeListener();e.on("dataReady",function(){b.trigger("dataReady.ckeditor",[e])});e.on("setData",function(a){b.trigger("setData.ckeditor",[e,a.data])});e.on("getData",function(a){b.trigger("getData.ckeditor",[e,a.data])},999);e.on("destroy",function(){b.trigger("destroy.ckeditor",[e])});e.on("save",function(){a(h.form).submit();
return!1},null,null,20);if(e.config.autoUpdateElementJquery&&b.is("textarea")&&a(h.form).length){var c=function(){b.ckeditor(function(){e.updateElement()})};a(h.form).submit(c);a(h.form).bind("form-pre-serialize",c);b.bind("destroy.ckeditor",function(){a(h.form).unbind("submit",c);a(h.form).unbind("form-pre-serialize",c)})}e.on("destroy",function(){b.removeData("ckeditorInstance")});b.removeData("_ckeditorInstanceLock");b.trigger("instanceReady.ckeditor",[e]);g&&g.apply(e,[h]);j.resolve()}else setTimeout(arguments.callee,
100)},0)},null,null,9999)}});var f=new a.Deferred;this.promise=f.promise();a.when.apply(this,i).then(function(){f.resolve()});this.editor=this.eq(0).data("ckeditorInstance");return this}}),CKEDITOR.config.jqueryOverrideVal&&(a.fn.val=CKEDITOR.tools.override(a.fn.val,function(g){return function(d){if(arguments.length){var k=this,i=[],f=this.each(function(){var b=a(this),c=b.data("ckeditorInstance");if(b.is("textarea")&&c){var f=new a.Deferred;c.setData(d,function(){f.resolve()});i.push(f.promise());
return!0}return g.call(b,d)});if(i.length){var b=new a.Deferred;a.when.apply(this,i).done(function(){b.resolveWith(k)});return b.promise()}return f}var f=a(this).eq(0),c=f.data("ckeditorInstance");return f.is("textarea")&&c?c.getData():g.call(f)}})))})(window.jQuery);
-4
View File
@@ -1,4 +0,0 @@
//= require lib/cycle2/jquery.cycle2.min.js
//= require lib/cycle2/transition/jquery.cycle2.flip.min.js
//= require lib/cycle2/transition/jquery.cycle2.scrollVert.min.js
//= require lib/cycle2/transition/jquery.cycle2.tile.min.js
+1 -4
View File
@@ -6,7 +6,7 @@
//
//= require jquery
//= require jquery_ujs
//= require jquery.ui.all
//= require jquery-ui
//= require desktop/jquery.form
//= require desktop/jquery.tinyscrollbar
//= require desktop/jquery.miniColors.min
@@ -19,6 +19,3 @@
//= require select2
//= require jquery.isotope.min.js
//= require orbit_js_1.0.1-front-end
//= require ckeditor/init
//= require ckeditor/jquery-ckeditor
+52 -99
View File
@@ -20,7 +20,6 @@
//for forms
//form-type = "ajax_form" will turn form to ajax submit
//notification = string will display after the form is succesfully submitted
//response-type = "json"|"script"|"xml|html" default is json
//for layout tinyscrollbar
//content-layout="datalist|column|simple" datalist is for data list from database.. column is usually for forms and some other pages.. simple is without any columns, the page will be displayed as it is.. base width will be considered the default width for tinyscrollbar
@@ -29,9 +28,6 @@
//column="true" this option is only for column layout... the columns will be formed on this column=true attribute and it should be a div
//item=true this attribute should be present in the li tag. li with this attribute are considered as a separate item.
//enableLanguageSelect( dom ) children <a> will be binded with language, data-lang = string ex "en"|"zh_tw" will toggle all data-langunage throughout the page
//enableSharing( dom ) children <a> will be binded with share, data-mode = string ex "public"|"private" will change the mode for all the selected items. the dom with class should have data-link = url data-var = vaiable_name, default will be mode
$.extend($.expr[':'], {
'containsi': function (elem, i, match, array) {
@@ -168,7 +164,7 @@ var orbitDesktop = function(dom){
o.loadIconCache();
var custom_load = window.location.hash;
if(!custom_load){
$(o.contentHolder).empty().load("/desktop/desktop_container",function(){
$(o.contentHolder).empty().load("/desktop/desktop",function(){
o.desktopData["d_desktop"] = "";
o.initializeDesktop("d_desktop","",false);
})
@@ -226,8 +222,7 @@ var orbitDesktop = function(dom){
this.bindDesktopEvents = function(){ //this function will bind the global handlers to thd desktop, for example doc
$(".docklist a").click(function(){
if( !$( this ).parent().hasClass( 'disable' ) )
o.menu_item($(this));
o.menu_item($(this));
return false;
});
@@ -252,12 +247,16 @@ var orbitDesktop = function(dom){
$("body").on("submit","form[form-type=ajax_form]",function(){
var callback_method = $(this).attr("callback-method"),
dt = ($(this).attr("response-type") == null ? "json" : $(this).attr("response-type")),
dt = null,
notification = $(this).attr("notification");
dt = $(this).attr("response-type");
if(dt == null){
dt = "json";
}
var options = {
dataType : dt,
resetForm : false,
success: function(responseText, statusText, xhr, $form){
resetForm : true,
success:function(responseText, statusText, xhr, $form){
if(typeof callback_method != "undefined"){
if(callback_method != ""){
window.o[o.data_method][callback_method](responseText,statusText,xhr,$form);
@@ -266,7 +265,7 @@ var orbitDesktop = function(dom){
if(typeof notification == "string")
o.notify(notification,"success");
},
error: function(){
error:function(){
o.notify("Please try again later!","imp");
}
}
@@ -275,11 +274,10 @@ var orbitDesktop = function(dom){
});
$("body").on("click","*[ajax-remote]",function(){
var $e = $(this),
t = $e.attr("ajax-remote"),
classes_to_toggle = $e.attr("toggle-onclick"),
responsetype = $e.attr('response-type') ? $e.attr('response-type') : "html",
exe = $e.attr("callback-method"); // (typeof $e.attr("callback-method") == "function"? $e.attr("callback-method") : "");
var $e = $(this);
var t = $e.attr("ajax-remote");
var classes_to_toggle = $e.attr("toggle-onclick");
var exe = $e.attr("callback-method"); // (typeof $e.attr("callback-method") == "function"? $e.attr("callback-method") : "");
if(classes_to_toggle){
$e.toggleClass(classes_to_toggle);
}
@@ -291,9 +289,9 @@ var orbitDesktop = function(dom){
}
var ca = $e.attr("content-holder");
var a = function(){
$.ajax({
type : t,
dataType : responsetype,
url : $e.attr("href"),
success : function(data){
if(typeof data == "string"){
@@ -304,7 +302,6 @@ var orbitDesktop = function(dom){
// $("div[container=true]").html(data);
}
}
if(exe)
window.o[o.data_method][exe](data,$e);
if(t == "delete"){
@@ -454,7 +451,7 @@ var orbitDesktop = function(dom){
var ist = function(){
$('#holder').css('height', $('#container').height() - 72);
$('.tinycanvas').css('height', $('#holder').height() - 36);
$('.tinycanvas').css('height', $('#panel_r').height() - 36);
var dom = $("*[isotope=true]").isotope({
layoutMode: 'fitColumns',
onLayout: function($elems, instance){
@@ -605,11 +602,10 @@ var orbitDesktop = function(dom){
this.menu_item = function(dom,customload,submenuitem){
if(!customload)customload=false;
var target = dom.attr("id"),
url = dom.attr("href"),
submenu_pass = ( dom.attr("sub-menu") == "false" ? false : true);
var target = dom.attr("id");
var url = dom.attr("href");
if(!url)return false;
o.data_method = dom.attr("callback-method");
if(o.currenthtml!=target){
if(o.desktopData[o.currentface] == "undefined"){
@@ -630,37 +626,33 @@ var orbitDesktop = function(dom){
window.o[o.data_method](target,url,cache);
}
}
if( submenu_pass ){
try {
if(!customload){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
try {
if(!customload){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),data);
} else {
if(submenuitem){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
} else {
if(submenuitem){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"));
} 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{
$(o.contentHolder).html(o.desktopData[o.currentface]);
if( submenu_pass ){
try{
if(!customload){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),o.desktopData[o.currentface]);
}else{
if(submenuitem)
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"),o.desktopData[o.currentface]);
else
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),o.desktopData[o.currentface]);
}
}catch(EX){}
}
try{
if(!customload){
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),o.desktopData[o.currentface]);
}else{
if(submenuitem)
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[custom-load="+submenuitem+"]"),o.desktopData[o.currentface]);
else
o.sub_menu_item($(o.contentHolder).find("*[content-type=menu] a[load=true]"),o.desktopData[o.currentface]);
}
}catch(EX){}
// cache = (o.lastlink == "/desktop/app_manager" ? false : true);
cache = (o.lastlink == "/desktop/app_manager" ? false : true);
if(typeof o.data_method != "undefined"){
if(o.data_method != ""){
window.o[o.data_method](target,url,cache);
@@ -706,15 +698,6 @@ var orbitDesktop = function(dom){
}
})
o.highlight_sub_menu_item(dom);
} else {
o.lastlink = dom.attr("href");
$.ajax({
url : dom.attr("href"),
type : "get",
success : function(data){
o.layout_data(data);
}
})
}
if(dom.length == 0)
o.layout_data(data);
@@ -1100,7 +1083,7 @@ var orbitDesktop = function(dom){
data : options,
success : function(data){
if(data.success == "true"){
if(dom.is(":checked")){
if(dom.is(":checked")){ console.log("true");
elementSettingsData[$e.data("id")].sections.push({"id" : dom.data("section"),"name":sectionDetails.name});
o.notify("Added to " + sectionDetails.name,"success");
}else{
@@ -1124,16 +1107,20 @@ var orbitDesktop = function(dom){
var info_open = function(){
if($appinfo.is(":hidden")){
$('.overview').stop().animate({'width': '+=480'},0 , function(){
// $('.tinycanvas').tinyscrollbar_update('relative');
$('.tinycanvas').tinyscrollbar_update();
});
$appinfo
.css({
'display': 'block',
'margin-left': -480
}).fadeIn(200)
})
.delay(300)
.animate({
'margin-left': 0
}, 500, 'easeInOutQuint');
}
} else {
$('.tinycanvas').tinyscrollbar_update();
}
}
var info_close = function(){
@@ -1144,11 +1131,13 @@ var orbitDesktop = function(dom){
'margin-left': -480
},500 , 'easeInOutQuint', function(){
$('.overview').animate({'width': '-=480'}, 0, function(){
// $('.tinycanvas').tinyscrollbar_update();
$('.tinycanvas').tinyscrollbar_update();
});
$(this).fadeOut(300).attr("style","");
$(this).attr("style","");
});
}
} else {
$('.tinycanvas').tinyscrollbar_update();
}
}
$(window).on('keydown', function(){
if($('#searchbox').val() == 'Search'){
@@ -1879,42 +1868,6 @@ var orbitDesktop = function(dom){
}
}
}
this.enablelanguageSelect = function(){
$(".language_select a").click(function(event) {
$("*[data-language]").hide();
$("*[data-language="+$(this).data("lang")+"]").show();
return false;
});
}
this.enableSharing = function( dom ){
var el = $( dom ),
variable = ( el.data( 'var' ) ? el.data( "var" ) : "mode"),
_url = el.data( 'link' ) + "?" + variable + "=",
classes = [];
el.find( "a" ).each( function(){
classes.push( $( this ).attr( "item-class" ) ? $( this ).attr( "item-class" ) : $( this ).data( 'mode' ) );
})
el.find( "a" ).click( function(){
var ids = [],
mode = $( this ).data( 'mode' ),
inject_class = $( this ).attr( 'item-class' ) ? $( this ).attr( 'item-class' ) : mode;
$( ".overview li[item=true] a.icon-check" ).each( function(){
ids.push( $( this ).data( 'id' ) );
$( "li[data-id="+ $( this ).data( 'id' ) +"]").removeClass( classes.join( " " ) ).addClass( inject_class );
})
$.ajax({
url : _url + mode,
data : {"ids" : ids},
datatype : "json",
})
return false;
})
}
this.minimizeBarManager = function(){
var minimizedApps = [],
minimizeBar = $("#minimizebar");
+21 -18
View File
@@ -1,30 +1,33 @@
var banners = [];
var banner_index = 0;
$(document).ready(function() {
$.each($(".dymanic_load"),function(){
if($(this).attr("path")==''){
$(this).html("App setting Failed");
}else{
ajax_load_proc($(this),$(this).attr("path"));
}
if($(this).attr("path")==''){$(this).html("App setting Failed");}
if($(this).attr("path")!=''){
ajax_load_proc($(this),$(this).attr("path"));
}
}
);
$("#main_content").addClass("module");
});
$("#main_content").addClass("module");
});
function ajax_load_proc(wapper,url,isBanner){
function ajax_load_proc(wapper,url){
$.get(encodeURI(url), {}, function(respText,textSta,XML){
if (textSta == 'success') {
wapper.html(respText);
};
if(textSta == 'error')
wapper.html("Loading Failed<br/> <a href='"+$(this).attr('path')+"'>Go See</a>");
if (textSta == 'success') {
wapper.html(respText);
};
if(textSta == 'error')
wapper.html("Loading Failed<br/> <a href='"+$(this).attr('path')+"'>Go See</a>");
});
}
// Ad Banner FX code [start]
function getTimeout() {
return $(this).attr('time_to_next');
}
$(document).ready(function() {
$(document).on('click', '.orbit-cycle-slideshow img', function()
$(document).on('click', '.slideshow img', function()
{
if($(this).attr('link_url')!='')
{
@@ -1,82 +1,79 @@
function slideshow (element, bannerEffect, bannerTime, bannerSpeed) {
element.cycle('destroy');
element.children('img').removeAttr('style');
element.cycle({
fx: bannerEffect,
timeout: bannerTime,
speed: bannerSpeed,
});
};
function setSlideshow(element, data) {
$("#pageslide .ad_banner_ad_fx").children('option:selected').each(function(index, el) {
$(this).val() == 'flipHorz' || $(this).val() == 'flipVert' ? $('.suckIE').show() : $('.suckIE').hide();
});
element.cycle('destroy');
slideshow(element, data['fx'], 2000, 1000);
}
$(function() {
var bannerEffect,
bannerTime,
bannerSpeed,
bannerW,
bannerH;
function preview() {
$(".ad_banner_ad_fx").change(function () {
bannerTime = $("#pageslide #timeout").val()*1000;
bannerSpeed = $("#pageslide #speed").val()*1000;
bannerTime = parseInt(bannerTime) || 300;
bannerSpeed = parseInt(bannerSpeed) || 300;
slideshow($(this).val(), bannerTime, bannerSpeed);
});
slideshow = function (bannerEffect, bannerTime, bannerSpeed) {
var $preview = $('#pageslide .preview'),
$previewImg = $('#pageslide .preview img');
$preview.cycle('destroy');
$previewImg.removeAttr('style');
$preview.cycle({
fx: bannerEffect,
timeout: bannerTime,
speed: bannerSpeed,
});
}
$('.open-slide').on('click', function() {
var $preview = $('#pageslide .preview'),
$data = $(this).data(),
effect = $data.fx,
time = $data.time,
speed = $data.speed,
W = $data.w,
H = $data.h;
$("#pageslide #timeout").attr("value", time/1000);
$("#pageslide #speed").attr("value", speed/1000);
$("#pageslide #banner_width").attr("value", W);
$("#pageslide #banner_height").attr("value", H);
$("#pageslide #ad_banner_ad_fx option").each(function(i) {
if($(this).attr("value") == effect) {
this.selected = true;
}
});
slideshow(effect, time, speed)
})
$('.open-modal').on('click', function() {
var _data = $(this).data();
bannerName = _data.name;
bannerEffect = _data.fx;
bannerTime = _data.time;
bannerSpeed = _data.speed;
bannerW = _data.w;
bannerH = _data.h;
var $data = $(this).data()
bannerEffect = $data.fx;
bannerTime = $data.time;
bannerSpeed = $data.speed;
bannerW = $data.w;
bannerH = $data.h;
$('#preview').modal('show');
});
$('#preview').on('shown', function() {
$(this).attr('aria-labelledby', bannerName.toString()).find('h3').text(bannerName.toString())
if(bannerW > 500) {
var resize = 500/bannerW
bannerW = Math.floor(bannerW*resize);
bannerH = Math.floor(bannerH*resize);
console.log(bannerW)
};
if(bannerH > 300) {
var resize = 300/bannerH
bannerW = Math.floor(bannerW*resize);
bannerH = Math.floor(bannerH*resize);
}
slideshow($(this).find('.preview'), bannerEffect, bannerTime, bannerSpeed);
$(this).find('.preview').css({
'width': bannerW,
'height': bannerH
});
$(this).find('.preview img').css({
'width': '100%',
'height': '100%'
$(this).find('.preview').cycle({
fx: bannerEffect,
timeout: bannerTime,
speed: bannerSpeed,
fit: 1,
width: bannerW,
height: bannerH,
});
});
$('#preview').on('hidden', function() {
$(this).attr('aria-labelledby', '').find('h3').text('')
$(this).find('.preview').cycle('destroy');
$(this).find('.preview img').removeAttr('style');
});
};
$(function() {
var bannerName = null,
bannerEffect = null,
bannerTime = null,
bannerSpeed = null,
bannerW = null,
bannerH = null,
$preview = $('#pageslide .preview');
$(".ad_banner_ad_fx").change(function () {
var suckIE = false;
// bannerTime = $("#pageslide #timeout").val()*1000;
// bannerSpeed = $("#pageslide #speed").val()*1000;
bannerTime = parseInt(bannerTime) || 300;
bannerSpeed = parseInt(bannerSpeed) || 300;
$(this).children('option:selected').each(function(index, el) {
$(this).val() == 'flipHorz' || $(this).val() == 'flipVert' ? $('.suckIE').show() : $('.suckIE').hide();
});
slideshow($preview, $(this).val(), 2000, 1000);
});
preview();
});
-17
View File
@@ -1,17 +0,0 @@
/*!
* jQuery Cycle2; build: v20131005
* http://jquery.malsup.com/cycle2/
* Copyright (c) 2013 M. Alsup; Dual licensed: MIT/GPL
*/
/*! core engine; version: 20131003 */
(function(e){"use strict";function t(e){return(e||"").toLowerCase()}var i="20131003";e.fn.cycle=function(i){var n;return 0!==this.length||e.isReady?this.each(function(){var n,s,o,c,r=e(this),l=e.fn.cycle.log;if(!r.data("cycle.opts")){(r.data("cycle-log")===!1||i&&i.log===!1||s&&s.log===!1)&&(l=e.noop),l("--c2 init--"),n=r.data();for(var a in n)n.hasOwnProperty(a)&&/^cycle[A-Z]+/.test(a)&&(c=n[a],o=a.match(/^cycle(.*)/)[1].replace(/^[A-Z]/,t),l(o+":",c,"("+typeof c+")"),n[o]=c);s=e.extend({},e.fn.cycle.defaults,n,i||{}),s.timeoutId=0,s.paused=s.paused||!1,s.container=r,s._maxZ=s.maxZ,s.API=e.extend({_container:r},e.fn.cycle.API),s.API.log=l,s.API.trigger=function(e,t){return s.container.trigger(e,t),s.API},r.data("cycle.opts",s),r.data("cycle.API",s.API),s.API.trigger("cycle-bootstrap",[s,s.API]),s.API.addInitialSlides(),s.API.preInitSlideshow(),s.slides.length&&s.API.initSlideshow()}}):(n={s:this.selector,c:this.context},e.fn.cycle.log("requeuing slideshow (dom not ready)"),e(function(){e(n.s,n.c).cycle(i)}),this)},e.fn.cycle.API={opts:function(){return this._container.data("cycle.opts")},addInitialSlides:function(){var t=this.opts(),i=t.slides;t.slideCount=0,t.slides=e(),i=i.jquery?i:t.container.find(i),t.random&&i.sort(function(){return Math.random()-.5}),t.API.add(i)},preInitSlideshow:function(){var t=this.opts();t.API.trigger("cycle-pre-initialize",[t]);var i=e.fn.cycle.transitions[t.fx];i&&e.isFunction(i.preInit)&&i.preInit(t),t._preInitialized=!0},postInitSlideshow:function(){var t=this.opts();t.API.trigger("cycle-post-initialize",[t]);var i=e.fn.cycle.transitions[t.fx];i&&e.isFunction(i.postInit)&&i.postInit(t)},initSlideshow:function(){var t,i=this.opts(),n=i.container;i.API.calcFirstSlide(),"static"==i.container.css("position")&&i.container.css("position","relative"),e(i.slides[i.currSlide]).css("opacity",1).show(),i.API.stackSlides(i.slides[i.currSlide],i.slides[i.nextSlide],!i.reverse),i.pauseOnHover&&(i.pauseOnHover!==!0&&(n=e(i.pauseOnHover)),n.hover(function(){i.API.pause(!0)},function(){i.API.resume(!0)})),i.timeout&&(t=i.API.getSlideOpts(i.currSlide),i.API.queueTransition(t,t.timeout+i.delay)),i._initialized=!0,i.API.updateView(!0),i.API.trigger("cycle-initialized",[i]),i.API.postInitSlideshow()},pause:function(t){var i=this.opts(),n=i.API.getSlideOpts(),s=i.hoverPaused||i.paused;t?i.hoverPaused=!0:i.paused=!0,s||(i.container.addClass("cycle-paused"),i.API.trigger("cycle-paused",[i]).log("cycle-paused"),n.timeout&&(clearTimeout(i.timeoutId),i.timeoutId=0,i._remainingTimeout-=e.now()-i._lastQueue,(0>i._remainingTimeout||isNaN(i._remainingTimeout))&&(i._remainingTimeout=void 0)))},resume:function(e){var t=this.opts(),i=!t.hoverPaused&&!t.paused;e?t.hoverPaused=!1:t.paused=!1,i||(t.container.removeClass("cycle-paused"),0===t.slides.filter(":animated").length&&t.API.queueTransition(t.API.getSlideOpts(),t._remainingTimeout),t.API.trigger("cycle-resumed",[t,t._remainingTimeout]).log("cycle-resumed"))},add:function(t,i){var n,s=this.opts(),o=s.slideCount,c=!1;"string"==e.type(t)&&(t=e.trim(t)),e(t).each(function(){var t,n=e(this);i?s.container.prepend(n):s.container.append(n),s.slideCount++,t=s.API.buildSlideOpts(n),s.slides=i?e(n).add(s.slides):s.slides.add(n),s.API.initSlide(t,n,--s._maxZ),n.data("cycle.opts",t),s.API.trigger("cycle-slide-added",[s,t,n])}),s.API.updateView(!0),c=s._preInitialized&&2>o&&s.slideCount>=1,c&&(s._initialized?s.timeout&&(n=s.slides.length,s.nextSlide=s.reverse?n-1:1,s.timeoutId||s.API.queueTransition(s)):s.API.initSlideshow())},calcFirstSlide:function(){var e,t=this.opts();e=parseInt(t.startingSlide||0,10),(e>=t.slides.length||0>e)&&(e=0),t.currSlide=e,t.reverse?(t.nextSlide=e-1,0>t.nextSlide&&(t.nextSlide=t.slides.length-1)):(t.nextSlide=e+1,t.nextSlide==t.slides.length&&(t.nextSlide=0))},calcNextSlide:function(){var e,t=this.opts();t.reverse?(e=0>t.nextSlide-1,t.nextSlide=e?t.slideCount-1:t.nextSlide-1,t.currSlide=e?0:t.nextSlide+1):(e=t.nextSlide+1==t.slides.length,t.nextSlide=e?0:t.nextSlide+1,t.currSlide=e?t.slides.length-1:t.nextSlide-1)},calcTx:function(t,i){var n,s=t;return i&&s.manualFx&&(n=e.fn.cycle.transitions[s.manualFx]),n||(n=e.fn.cycle.transitions[s.fx]),n||(n=e.fn.cycle.transitions.fade,s.API.log('Transition "'+s.fx+'" not found. Using fade.')),n},prepareTx:function(e,t){var i,n,s,o,c,r=this.opts();return 2>r.slideCount?(r.timeoutId=0,void 0):(!e||r.busy&&!r.manualTrump||(r.API.stopTransition(),r.busy=!1,clearTimeout(r.timeoutId),r.timeoutId=0),r.busy||(0!==r.timeoutId||e)&&(n=r.slides[r.currSlide],s=r.slides[r.nextSlide],o=r.API.getSlideOpts(r.nextSlide),c=r.API.calcTx(o,e),r._tx=c,e&&void 0!==o.manualSpeed&&(o.speed=o.manualSpeed),r.nextSlide!=r.currSlide&&(e||!r.paused&&!r.hoverPaused&&r.timeout)?(r.API.trigger("cycle-before",[o,n,s,t]),c.before&&c.before(o,n,s,t),i=function(){r.busy=!1,r.container.data("cycle.opts")&&(c.after&&c.after(o,n,s,t),r.API.trigger("cycle-after",[o,n,s,t]),r.API.queueTransition(o),r.API.updateView(!0))},r.busy=!0,c.transLine truncated
function(e){"use strict";function t(t,n){var s,o,c,r=n.autoHeight;if("container"==r)o=e(n.slides[n.currSlide]).outerHeight(),n.container.height(o);else if(n._autoHeightRatio)n.container.height(n.container.width()/n._autoHeightRatio);else if("calc"===r||"number"==e.type(r)&&r>=0){if(c="calc"===r?i(t,n):r>=n.slides.length?0:r,c==n._sentinelIndex)return;n._sentinelIndex=c,n._sentinel&&n._sentinel.remove(),s=e(n.slides[c].cloneNode(!0)),s.removeAttr("id name rel").find("[id],[name],[rel]").removeAttr("id name rel"),s.css({position:"static",visibility:"hidden",display:"block"}).prependTo(n.container).addClass("cycle-sentinel cycle-slide").removeClass("cycle-slide-active"),s.find("*").css("visibility","hidden"),n._sentinel=s}}function i(t,i){var n=0,s=-1;return i.slides.each(function(t){var i=e(this).height();i>s&&(s=i,n=t)}),n}function n(t,i,n,s){var o=e(s).outerHeight(),c=i.sync?i.speed/2:i.speed;i.container.animate({height:o},c)}function s(i,o){o._autoHeightOnResize&&(e(window).off("resize orientationchange",o._autoHeightOnResize),o._autoHeightOnResize=null),o.container.off("cycle-slide-added cycle-slide-removed",t),o.container.off("cycle-destroyed",s),o.container.off("cycle-before",n),o._sentinel&&(o._sentinel.remove(),o._sentinel=null)}e.extend(e.fn.cycle.defaults,{autoHeight:0}),e(document).on("cycle-initialized",function(i,o){function c(){t(i,o)}var r,l=o.autoHeight,a=e.type(l),d=null;("string"===a||"number"===a)&&(o.container.on("cycle-slide-added cycle-slide-removed",t),o.container.on("cycle-destroyed",s),"container"==l?o.container.on("cycle-before",n):"string"===a&&/\d+\:\d+/.test(l)&&(r=l.match(/(\d+)\:(\d+)/),r=r[1]/r[2],o._autoHeightRatio=r),"number"!==a&&(o._autoHeightOnResize=function(){clearTimeout(d),d=setTimeout(c,50)},e(window).on("resize orientationchange",o._autoHeightOnResize)),setTimeout(c,30))})}(jQuery),/*! caption plugin for Cycle2; version: 20130306 */
function(e){"use strict";e.extend(e.fn.cycle.defaults,{caption:"> .cycle-caption",captionTemplate:"{{slideNum}} / {{slideCount}}",overlay:"> .cycle-overlay",overlayTemplate:"<div>{{title}}</div><div>{{desc}}</div>",captionModule:"caption"}),e(document).on("cycle-update-view",function(t,i,n,s){"caption"===i.captionModule&&e.each(["caption","overlay"],function(){var e=this,t=n[e+"Template"],o=i.API.getComponent(e);o.length&&t?(o.html(i.API.tmpl(t,n,i,s)),o.show()):o.hide()})}),e(document).on("cycle-destroyed",function(t,i){var n;e.each(["caption","overlay"],function(){var e=this,t=i[e+"Template"];i[e]&&t&&(n=i.API.getComponent("caption"),n.empty())})})}(jQuery),/*! command plugin for Cycle2; version: 20130707 */
function(e){"use strict";var t=e.fn.cycle;e.fn.cycle=function(i){var n,s,o,c=e.makeArray(arguments);return"number"==e.type(i)?this.cycle("goto",i):"string"==e.type(i)?this.each(function(){var r;return n=i,o=e(this).data("cycle.opts"),void 0===o?(t.log('slideshow must be initialized before sending commands; "'+n+'" ignored'),void 0):(n="goto"==n?"jump":n,s=o.API[n],e.isFunction(s)?(r=e.makeArray(c),r.shift(),s.apply(o.API,r)):(t.log("unknown command: ",n),void 0))}):t.apply(this,arguments)},e.extend(e.fn.cycle,t),e.extend(t.API,{next:function(){var e=this.opts();if(!e.busy||e.manualTrump){var t=e.reverse?-1:1;e.allowWrap===!1&&e.currSlide+t>=e.slideCount||(e.API.advanceSlide(t),e.API.trigger("cycle-next",[e]).log("cycle-next"))}},prev:function(){var e=this.opts();if(!e.busy||e.manualTrump){var t=e.reverse?1:-1;e.allowWrap===!1&&0>e.currSlide+t||(e.API.advanceSlide(t),e.API.trigger("cycle-prev",[e]).log("cycle-prev"))}},destroy:function(){this.stop();var t=this.opts(),i=e.isFunction(e._data)?e._data:e.noop;clearTimeout(t.timeoutId),t.timeoutId=0,t.API.stop(),t.API.trigger("cycle-destroyed",[t]).log("cycle-destroyed"),t.container.removeData(),i(t.container[0],"parsedAttrs",!1),t.retainStylesOnDestroy||(t.container.removeAttr("style"),t.slides.removeAttr("style"),t.slides.removeClass(t.slideActiveClass)),t.slides.each(function(){e(this).removeData(),i(this,"parsedAttrs",!1)})},jump:function(e){var t,i=this.opts();if(!i.busy||i.manualTrump){var n=parseInt(e,10);if(isNaN(n)||0>n||n>=i.slides.length)return i.API.log("goto: invalid slide index: "+n),void 0;if(n==i.currSlide)return i.API.log("goto: skipping, already on slide",n),void 0;i.nextSlide=n,clearTimeout(i.timeoutId),i.timeoutId=0,i.API.log("goto: ",n," (zero-index)"),t=i.currSlide<i.nextSlide,i.API.prepareTx(!0,t)}},stop:function(){var t=this.opts(),i=t.container;clearTimeout(t.timeoutId),t.timeoutId=0,t.API.stopTransition(),t.pauseOnHover&&(t.pauseOnHover!==!0&&(i=e(t.pauseOnHover)),i.off("mouseenter mouseleave")),t.API.trigger("cycle-stopped",[t]).log("cycle-stopped")},reinit:function(){var e=this.opts();e.API.destroy(),e.container.cycle()},remove:function(t){for(var i,n,s=this.opts(),o=[],c=1,r=0;s.slides.length>r;r++)i=s.slides[r],r==t?n=i:(o.push(i),e(i).data("cycle.opts").slideNum=c,c++);n&&(s.slides=e(o),s.slideCount--,e(n).remove(),t==s.currSlide?s.API.advanceSlide(1):s.currSlide>t?s.currSlide--:s.currSlide++,s.API.trigger("cycle-slide-removed",[s,t,n]).log("cycle-slide-removed"),s.API.updateView())}}),e(document).on("click.cycle","[data-cycle-cmd]",function(t){t.preventDefault();var i=e(this),n=i.data("cycle-cmd"),s=i.data("cycle-context")||".cycle-slideshow";e(s).cycle(n,i.data("cycle-arg"))})}(jQuery),/*! hash plugin for Cycle2; version: 20130905 */
function(e){"use strict";function t(t,i){var n;return t._hashFence?(t._hashFence=!1,void 0):(n=window.location.hash.substring(1),t.slides.each(function(s){if(e(this).data("cycle-hash")==n){if(i===!0)t.startingSlide=s;else{var o=s>t.currSlide;t.nextSlide=s,t.API.prepareTx(!0,o)}return!1}}),void 0)}e(document).on("cycle-pre-initialize",function(i,n){t(n,!0),n._onHashChange=function(){t(n,!1)},e(window).on("hashchange",n._onHashChange)}),e(document).on("cycle-update-view",function(e,t,i){i.hash&&"#"+i.hash!=window.location.hash&&(t._hashFence=!0,window.location.hash=i.hash)}),e(document).on("cycle-destroyed",function(t,i){i._onHashChange&&e(window).off("hashchange",i._onHashChange)})}(jQuery),/*! loader plugin for Cycle2; version: 20130307 */
function(e){"use strict";e.extend(e.fn.cycle.defaults,{loader:!1}),e(document).on("cycle-bootstrap",function(t,i){function n(t,n){function o(t){var o;"wait"==i.loader?(r.push(t),0===a&&(r.sort(c),s.apply(i.API,[r,n]),i.container.removeClass("cycle-loading"))):(o=e(i.slides[i.currSlide]),s.apply(i.API,[t,n]),o.show(),i.container.removeClass("cycle-loading"))}function c(e,t){return e.data("index")-t.data("index")}var r=[];if("string"==e.type(t))t=e.trim(t);else if("array"===e.type(t))for(var l=0;t.length>l;l++)t[l]=e(t[l])[0];t=e(t);var a=t.length;a&&(t.hide().appendTo("body").each(function(t){function c(){0===--l&&(--a,o(d))}var l=0,d=e(this),u=d.is("img")?d:d.find("img");return d.data("index",t),u=u.filter(":not(.cycle-loader-ignore)").filter(':not([src=""])'),u.length?(l=u.length,u.each(function(){this.complete?c():e(this).load(function(){c()}).error(function(){0===--l&&(i.API.log("slide skipped; img not loaded:",this.src),0===--a&&"wait"==i.loader&&s.apply(i.API,[r,n]))})}),void 0):(--a,r.push(d),void 0)}),a&&i.container.addClass("cycle-loading"))}var s;i.loader&&(s=i.API.add,i.API.add=n)})}(jQuery),/*! pager plugin for Cycle2; version: 20130525 */
function(e){"use strict";function t(t,i,n){var s,o=t.API.getComponent("pager");o.each(function(){var o=e(this);if(i.pagerTemplate){var c=t.API.tmpl(i.pagerTemplate,i,t,n[0]);s=e(c).appendTo(o)}else s=o.children().eq(t.slideCount-1);s.on(t.pagerEvent,function(e){e.preventDefault(),t.API.page(o,e.currentTarget)})})}function i(e,t){var i=this.opts();if(!i.busy||i.manualTrump){var n=e.children().index(t),s=n,o=s>i.currSlide;i.currSlide!=s&&(i.nextSlide=s,i.API.prepareTx(!0,o),i.API.trigger("cycle-pager-activated",[i,e,t]))}}e.extend(e.fn.cycle.defaults,{pager:"> .cycle-pager",pagerActiveClass:"cycle-pager-active",pagerEvent:"click.cycle",pagerTemplate:"<span>&bull;</span>"}),e(document).on("cycle-bootstrap",function(e,i,n){n.buildPagerLink=t}),e(document).on("cycle-slide-added",function(e,t,n,s){t.pager&&(t.API.buildPagerLink(t,n,s),t.API.page=i)}),e(document).on("cycle-slide-removed",function(t,i,n){if(i.pager){var s=i.API.getComponent("pager");s.each(function(){var t=e(this);e(t.children()[n]).remove()})}}),e(document).on("cycle-update-view",function(t,i){var n;i.pager&&(n=i.API.getComponent("pager"),n.each(function(){e(this).children().removeClass(i.pagerActiveClass).eq(i.currSlide).addClass(i.pagerActiveClass)}))}),e(document).on("cycle-destroyed",function(e,t){var i=t.API.getComponent("pager");i&&(i.children().off(t.pagerEvent),t.pagerTemplate&&i.empty())})}(jQuery),/*! prevnext plugin for Cycle2; version: 20130709 */
function(e){"use strict";e.extend(e.fn.cycle.defaults,{next:"> .cycle-next",nextEvent:"click.cycle",disabledClass:"disabled",prev:"> .cycle-prev",prevEvent:"click.cycle",swipe:!1}),e(document).on("cycle-initialized",function(e,t){if(t.API.getComponent("next").on(t.nextEvent,function(e){e.preventDefault(),t.API.next()}),t.API.getComponent("prev").on(t.prevEvent,function(e){e.preventDefault(),t.API.prev()}),t.swipe){var i=t.swipeVert?"swipeUp.cycle":"swipeLeft.cycle swipeleft.cycle",n=t.swipeVert?"swipeDown.cycle":"swipeRight.cycle swiperight.cycle";t.container.on(i,function(){t.API.next()}),t.container.on(n,function(){t.API.prev()})}}),e(document).on("cycle-update-view",function(e,t){if(!t.allowWrap){var i=t.disabledClass,n=t.API.getComponent("next"),s=t.API.getComponent("prev"),o=t._prevBoundry||0,c=void 0!==t._nextBoundry?t._nextBoundry:t.slideCount-1;t.currSlide==c?n.addClass(i).prop("disabled",!0):n.removeClass(i).prop("disabled",!1),t.currSlide===o?s.addClass(i).prop("disabled",!0):s.removeClass(i).prop("disabled",!1)}}),e(document).on("cycle-destroyed",function(e,t){t.API.getComponent("prev").off(t.nextEvent),t.API.getComponent("next").off(t.prevEvent),t.container.off("swipeleft.cycle swiperight.cycle swipeLeft.cycle swipeRight.cycle swipeUp.cycle swipeDown.cycle")})}(jQuery),/*! progressive loader plugin for Cycle2; version: 20130315 */
function(e){"use strict";e.extend(e.fn.cycle.defaults,{progressive:!1}),e(document).on("cycle-pre-initialize",function(t,i){if(i.progressive){var n,s,o=i.API,c=o.next,r=o.prev,l=o.prepareTx,a=e.type(i.progressive);if("array"==a)n=i.progressive;else if(e.isFunction(i.progressive))n=i.progressive(i);else if("string"==a){if(s=e(i.progressive),n=e.trim(s.html()),!n)return;if(/^(\[)/.test(n))try{n=e.parseJSON(n)}catch(d){return o.log("error parsing progressive slides",d),void 0}else n=n.split(RegExp(s.data("cycle-split")||"\n")),n[n.length-1]||n.pop()}l&&(o.prepareTx=function(e,t){var s,o;return e||0===n.length?(l.apply(i.API,[e,t]),void 0):(t&&i.currSlide==i.slideCount-1?(o=n[0],n=n.slice(1),i.container.one("cycle-slide-added",function(e,t){setTimeout(function(){t.API.advanceSlide(1)},50)}),i.API.add(o)):t||0!==i.currSlide?l.apply(i.API,[e,t]):(s=n.length-1,o=n[s],n=n.slice(0,s),i.container.one("cycle-slide-added",function(e,t){setTimeout(function(){t.currSlide=1,t.API.advanceSlide(-1)},50)}),i.API.add(o,!0)),void 0)}),c&&(o.next=function(){var e=this.opts();if(n.length&&e.currSlide==e.slideCount-1){var t=n[0];n=n.slice(1),e.container.one("cycle-slide-added",function(e,t){c.apply(t.API),t.container.removeClass("cycle-loading")}),e.container.addClass("cycle-loading"),e.API.add(t)}else c.apply(e.API)}),r&&(o.prev=function(){var e=this.opts();if(n.length&&0===e.currSlide){var t=n.length-1,i=n[t];n=n.slice(0,t),e.container.one("cycle-slide-added",function(e,t){t.currSlide=1,t.API.advanceSlide(-1),t.container.removeClass("cycle-loading")}),e.container.addClass("cycle-loading"),e.API.add(i,!0)}else r.apply(e.API)})}})}(jQuery),/*! tmpl plugin for Cycle2; version: 20121227 */
function(e){"use strict";e.extend(e.fn.cycle.defaults,{tmplRegex:"{{((.)?.*?)}}"}),e.extend(e.fn.cycle.API,{tmpl:function(t,i){var n=RegExp(i.tmplRegex||e.fn.cycle.defaults.tmplRegex,"g"),s=e.makeArray(arguments);return s.shift(),t.replace(n,function(t,i){var n,o,c,r,l=i.split(".");for(n=0;s.length>n;n++)if(c=s[n]){if(l.length>1)for(r=c,o=0;l.length>o;o++)c=r,r=r[l[o]]||i;else r=c[i];if(e.isFunction(r))return r.apply(c,s);if(void 0!==r&&null!==r&&r!=i)return r}return i})}})}(jQuery);
//@ sourceMappingURL=jquery.cycle2.js.map
@@ -1,2 +0,0 @@
/* Plugin for Cycle2; Copyright (c) 2012 M. Alsup; v20130909 */
(function(e){"use strict";function t(t){return{preInit:function(e){e.slides.css(n)},transition:function(i,n,s,o,r){var l=i,c=e(n),a=e(s),d=l.speed/2;t.call(a,-90),a.css({display:"block","background-position":"-90px",opacity:1}),c.css("background-position","0px"),c.animate({backgroundPosition:90},{step:t,duration:d,easing:l.easeOut||l.easing,complete:function(){i.API.updateView(!1,!0),a.animate({backgroundPosition:0},{step:t,duration:d,easing:l.easeIn||l.easing,complete:r})}})}}}function i(t){return function(i){var n=e(this);n.css({"-webkit-transform":"rotate"+t+"("+i+"deg)","-moz-transform":"rotate"+t+"("+i+"deg)","-ms-transform":"rotate"+t+"("+i+"deg)","-o-transform":"rotate"+t+"("+i+"deg)",transform:"rotate"+t+"("+i+"deg)"})}}var n,s=document.createElement("div").style,o=e.fn.cycle.transitions,r=void 0!==s.transform||void 0!==s.MozTransform||void 0!==s.webkitTransform||void 0!==s.oTransform||void 0!==s.msTransform;r&&void 0!==s.msTransform&&(s.msTransform="rotateY(0deg)",s.msTransform||(r=!1)),r?(o.flipHorz=t(i("Y")),o.flipVert=t(i("X")),n={"-webkit-backface-visibility":"hidden","-moz-backface-visibility":"hidden","-o-backface-visibility":"hidden","backface-visibility":"hidden"}):(o.flipHorz=o.scrollHorz,o.flipVert=o.scrollVert||o.scrollHorz)})(jQuery);
@@ -1,2 +0,0 @@
/*! Plugin for Cycle2; Copyright (c) 2012 M. Alsup; ver: 20121120 */
(function(a){function b(a,b,c){if(a&&c.style.filter){b._filter=c.style.filter;try{c.style.removeAttribute("filter")}catch(d){}}else!a&&b._filter&&(c.style.filter=b._filter)}"use strict",a.extend(a.fn.cycle.transitions,{fade:{before:function(c,d,e,f){var g=c.API.getSlideOpts(c.nextSlide).slideCss||{};c.API.stackSlides(d,e,f),c.cssBefore=a.extend(g,{opacity:0,display:"block"}),c.animIn={opacity:1},c.animOut={opacity:0},b(!0,c,e)},after:function(a,c,d){b(!1,a,d)}},fadeout:{before:function(c,d,e,f){var g=c.API.getSlideOpts(c.nextSlide).slideCss||{};c.API.stackSlides(d,e,f),c.cssBefore=a.extend(g,{opacity:1,display:"block"}),c.animOut={opacity:0},b(!0,c,e)},after:function(a,c,d){b(!1,a,d)}}})})(jQuery);
@@ -1,2 +0,0 @@
/*! Plugin for Cycle2; Copyright (c) 2012 M. Alsup; ver: 20121120 */
(function(a){"use strict",a.fn.cycle.transitions.scrollVert={before:function(a,b,c,d){a.API.stackSlides(a,b,c,d);var e=a.container.css("overflow","hidden").height();a.cssBefore={top:d?-e:e,left:0,opacity:1,display:"block"},a.animIn={top:0},a.animOut={top:d?e:-e}}}})(jQuery);
@@ -1,2 +0,0 @@
/* Plugin for Cycle2; Copyright (c) 2012 M. Alsup; v20130721 */
(function(e){"use strict";e.fn.cycle.transitions.tileSlide=e.fn.cycle.transitions.tileBlind={before:function(t,i,n,s){t.API.stackSlides(i,n,s),e(i).show(),t.container.css("overflow","hidden"),t.tileDelay=t.tileDelay||"tileSlide"==t.fx?100:125,t.tileCount=t.tileCount||7,t.tileVertical=t.tileVertical!==!1,t.container.data("cycleTileInitialized")||(t.container.on("cycle-destroyed",e.proxy(this.onDestroy,t.API)),t.container.data("cycleTileInitialized",!0))},transition:function(t,i,n,s,o){function r(e){p.eq(e).animate(I,{duration:t.speed,easing:t.easing,complete:function(){(s?v-1===e:0===e)&&t._tileAniCallback()}}),setTimeout(function(){(s?v-1!==e:0!==e)&&r(s?e+1:e-1)},t.tileDelay)}t.slides.not(i).not(n).hide();var c,l,a,d,u,p=e(),f=e(i),y=e(n),v=t.tileCount,h=t.tileVertical,g=t.container.height(),m=t.container.width();h?(l=Math.floor(m/v),d=m-l*(v-1),a=u=g):(l=d=m,a=Math.floor(g/v),u=g-a*(v-1)),t.container.find(".cycle-tiles-container").remove();var I,A={left:0,top:0,overflow:"hidden",position:"absolute",margin:0,padding:0};I=h?"tileSlide"==t.fx?{top:g}:{width:0}:"tileSlide"==t.fx?{left:m}:{height:0};var S=e('<div class="cycle-tiles-container"></div>');S.css({zIndex:f.css("z-index"),overflow:"visible",position:"absolute",top:0,left:0,direction:"ltr"}),S.insertBefore(n);for(var x=0;v>x;x++)c=e("<div></div>").css(A).css({width:v-1===x?d:l,height:v-1===x?u:a,marginLeft:h?x*l:0,marginTop:h?0:x*a}).append(f.clone().css({position:"relative",maxWidth:"none",width:f.width(),margin:0,padding:0,marginLeft:h?-(x*l):0,marginTop:h?0:-(x*a)})),p=p.add(c);S.append(p),f.hide(),y.show().css("opacity",1),r(s?0:v-1),t._tileAniCallback=function(){y.show(),f.hide(),S.remove(),o()}},stopTransition:function(e){e.container.find("*").stop(!0,!0),e._tileAniCallback&&e._tileAniCallback()},onDestroy:function(){var e=this.opts();e.container.find(".cycle-tiles-container").remove()}}})(jQuery);
+3 -256
View File
@@ -32,254 +32,8 @@ function touchSupport() {
})
}
}
function customOpenSlide() {
var $openSlide = $('.open-slide'),
$pageslideW;
$(window).width() > 1440 ? $pageslideW = 1024 : $pageslideW = 954;
$(window).resize(function() {
$(this).width() > 1440 ? $pageslideW = 1024 : $pageslideW = 954;
});
$noiFrame = $openSlide.not('.view-page');
$iFrame = $openSlide.filter('.view-page.open-slide');
$noiFrame.pageslide({
W: 314,
openFn: function(pageslide, element) {
element.addClass('active')
.closest('.item-menu')
.css('display', 'inline-block')
.closest('.navbar-inner')
.addClass('active');
},
closeFn: function(pageslide, element) {
$('.item-menu').removeAttr('style');
element.removeClass('active')
.closest('.navbar-inner')
.removeClass('active');
},
loadComplete: function(pageslide, element) {
$openSlide.removeClass('active');
$('.navbar-inner').removeClass('active');
$('.item-menu').removeAttr('style');
element.addClass('active')
.closest('.item-menu')
.css('display', 'inline-block')
.closest('.navbar-inner')
.addClass('active');
var _id = element.data('id'),
_type = element.hasClass('page') ? 'page' : 'link',
_edit = element.hasClass('edit') ? true : false;
if(_id !== 'new') {
$('#pageslide form').attr({
'action': $('#pageslide form').attr('action') + '/' + _id,
'id': 'edit_' + _type + '_' + _id
});
};
_type == 'page' ? pageSetting(element.data('id'), _edit) : '';
}
});
$iFrame.pageslide({
W: $pageslideW,
iframe: true,
openFn: function(pageslide, element) {
element.addClass('active')
.closest('.item-menu')
.css('display', 'inline-block')
.closest('.navbar-inner')
.addClass('active');
},
closeFn: function(pageslide, element) {
$('.item-menu').removeAttr('style');
element.removeClass('active')
.closest('.navbar-inner')
.removeClass('active');
$('#main-wrap').css('width', 'auto')
},
loadComplete: function(pageslide, element) {
$openSlide.removeClass('active');
$('.navbar-inner').removeClass('active');
$('.item-menu').removeAttr('style');
element.addClass('active')
.closest('.item-menu')
.css('display', 'inline-block')
.closest('.navbar-inner')
.addClass('active');
pageslide.find('.content').css('padding', 0);
}
});
}
function pageSetting(id, edit) {
$pageModule = $('#page_module_app_id'),
$pageF2E = $('#page_app_frontend_url'),
$pageDesign = $('#page_design'),
$pageTheme = $('#page_theme_id'),
$pageCategory = $('#page-category'),
$pageTags = $('#page-tags');
if(edit) {
$.ajax({
url: 'page-setting.json',
type: 'POST',
contentType: "application/json; charset=utf-8",
dataType: 'json',
data: '{"id": ' + id + '}',
cache: false,
})
.done(function(data) {
_selectData = data;
$.each(_pageData.design, function(index, val) {
$pageDesign.append('<option value="' + val.main[1] + '" ' + (val.main[1] == _selectData.design.main ? 'selected="selected"' : '') + '>' + val.main[0] + '</option>');
if(val.main[1] == _selectData.design.main) {
$.each(val.sub, function(index, val) {
$pageTheme.append('<option value="' + $(this)[1] + '" ' + ($(this)[1] == _selectData.design.sub ? 'selected="selected"' : '') + '>' + $(this)[0]+ '</option>')
});
};
});
$.each(_pageData.module, function(index, val) {
$pageModule.append('<option value="' + val.main[1] + '" ' + (val.main[1] == _selectData.module.main ? 'selected="selected"' : '') + '>' + val.main[0] + '</option>');
if(val.main[1] == _selectData.module.main) {
$.each(val.sub, function(index, val) {
$pageF2E.append('<option value="' + $(this)[1] + '" ' + ($(this)[1] == _selectData.module.sub ? 'selected="selected"' : '') + '>' + $(this)[0]+ '</option>')
});
$.each(val.category, function(index, val) {
var _arr = $.inArray($(this)[1], _selectData.module.category[1]);
$pageCategory.append('<label class="checkbox"><input type="checkbox" name="page[category][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
if(!_selectData.module.category[0] && _arr !== -1) {
$pageCategory.find('input[type="checkbox"]').eq(index).prop('checked', true);
}
_selectData.module.category[0] ? $pageCategory.siblings('.checkbox').children('.select_all').prop('checked', true) : '';
});
$.each(val.tags, function(index, val) {
var _arr = $.inArray($(this)[1], _selectData.module.tags[1]);
$pageTags.append('<label class="checkbox"><input type="checkbox" name="page[tag][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
if(!_selectData.module.tags[0] && _arr !== -1) {
$pageTags.find('input[type="checkbox"]').eq(index).prop('checked', true);
}
_selectData.module.tags[0] ? $pageTags.siblings('.checkbox').children('.select_all').prop('checked', true) : '';
});
};
});
changeSetting(true);
})
.fail(function(jqXHR, textStatus) {
console.log(jqXHR.status, textStatus)
var $errorMsg = '<div class="error-cover"><div class="msg"><i class="icons-warning"></i><p>Sorry! Something is wrong</p></div></div>'
$('#pageslide .view-page').append($errorMsg);
});
} else {
$.each(_pageData.design, function(index, val) {
$pageDesign.append('<option value="' + val.main[1] + '">' + val.main[0] + '</option>');
if(index == 0) {
$.each(val.sub, function(index, val) {
$pageTheme.append('<option value="' + $(this)[1] + '">' + $(this)[0]+ '</option>')
});
};
});
$.each(_pageData.module, function(index, val) {
$pageModule.append('<option value="' + val.main[1] + '">' + val.main[0] + '</option>');
if(index == 0) {
$.each(val.sub, function(index, val) {
$pageF2E.append('<option value="' + $(this)[1] + '">' + $(this)[0]+ '</option>')
});
$.each(val.category, function(index, val) {
$pageCategory.append('<label class="checkbox"><input type="checkbox" name="page[category][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
});
$.each(val.tags, function(index, val) {
$pageTags.append('<label class="checkbox"><input type="checkbox" name="page[tag][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
});
};
});
changeSetting(false);
};
};
function changeSetting(boolean) {
$('#pageslide').on('change', '.change', function(event) {
var _data, _select, _subData, $subSelete;
if(event.target.id == 'page_design') {
_data = _pageData.design;
_select = boolean ? _selectData.design : null;
_subData = 'template';
$subSelete = $('#page_theme_id');
} else {
_data = _pageData.module;
_select = boolean ? _selectData.module : null;
_subData = 'module';
$subSelete = $('#page_app_frontend_url');
};
$(this).children("option:selected").each(function () {
var _val = $(this).val();
$subSelete.empty();
$.each(_data, function(index, val) {
if(_val == val.main[1]) {
$.each(val.sub, function(index, val) {
var _selected = _select && $(this)[1] == _select.sub ? 'selected="selected"' : '';
$subSelete.append('<option value="' + $(this)[1] + '" ' + _selected + '>' + $(this)[0] + '</option>');
});
if(event.target.id == 'page_module_app_id') {
$pageCategory.empty();
$pageTags.empty();
$('.select_all').prop('checked', false)
$.each(val.category, function(index, val) {
if(val !== 0) {
$('#page-category-groups').slideDown(300);
var _arr = _select ? $.inArray($(this)[1], _select.category[1]) : '';
$pageCategory.append('<label class="checkbox"><input type="checkbox" name="page[category][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
if(_select && !_select.category[0] && _arr !== -1) {
$pageCategory.find('input[type="checkbox"]').eq(index).prop('checked', true);
}
_select && _val == _select.main && _select.category[0] ? $pageCategory.siblings('.checkbox').children('.select_all').prop('checked', true) : '';
} else {
$('#page-category-groups').slideUp(300);
}
});
$.each(val.tags, function(index, val) {
if(val !== 0) {
$('#page-tags-groups').slideDown(300);
var _arr = _select ? $.inArray($(this)[1], _select.tags[1]) : '';
$pageTags.append('<label class="checkbox"><input type="checkbox" name="page[tag][]" value="'+ $(this)[1] + '">'+ $(this)[0] +'</label>');
if(_select && !_select.tags[0] && _arr !== -1) {
$pageTags.find('input[type="checkbox"]').eq(index).prop('checked', true);
}
_select && _val == _select.main && _select.tags[0] ? $pageTags.siblings('.checkbox').children('.select_all').prop('checked', true) : '';
} else {
$('#page-tags-groups').slideUp(300);
}
});
}
return false;
};
});
});
event.preventDefault();
});
$('#pageslide').on('change', '.checkbox-groups input[type="checkbox"]', function(event) {
if($(this).hasClass('select_all') && $(this).prop('checked')) {
$(this).closest('.checkbox').siblings('.groups').find('input[type="checkbox"]').prop('checked', false);
} else if($(this).prop('checked')) {
$(this).closest('.groups').siblings('.checkbox').find('.select_all').prop('checked', false);
}
event.preventDefault();
});
}
function getPageData() {
$.getJSON('page-design-module.json').done(function(data) {
_pageData = data;
});
}
$(function(){
var $pageModule = null,
$pageF2E = null,
$pageDesign = null,
$pageTheme = null,
$pageCategory = null,
$pageTags = null;
_pageData = null;
_selectData = null;
$('.sortable').nestedSortable({
handle: '.brand',
items: 'li',
@@ -289,14 +43,8 @@ $(function(){
placeholder: 'placeholder',
startCollapsed: true,
disableNesting: 'no-nest',
update: function(event, ui) {
var position = null;
if($(ui.item).closest('ol').hasClass('item-groups')) {
position = $(ui.item).index() - 1;
} else {
position = $(ui.item).index();
};
$.post("<%= Rails.application.routes.url_helpers.admin_update_position_path %>", { id: ui.item.attr('id'), parent_id: (ui.item.parent().closest('li').attr('id') || ui.item.parent().closest('ol').attr('id')), position: position } );
stop: function(event, ui) {
$.post("<%= Rails.application.routes.url_helpers.admin_update_position_path %>", { id: ui.item.attr('id'), parent_id: (ui.item.parent().closest('li').attr('id') || ui.item.parent().closest('ol').attr('id')), position: ui.item.index() } );
}
});
$(".sortable").delegate(".brand, .delete", clickEvent, function(e){
@@ -315,12 +63,11 @@ $(function(){
tip();
touchSupport()
itemsQuantity();
getPageData();
});
function reloadStructure(){
$.pageslide.close();
customOpenSlide();
openSlide();
tip();
touchSupport()
itemsQuantity();
@@ -7,29 +7,32 @@ function append_id(){
};
}
$(document).on('change', 'select', function(e) {
if(!e.target.className == 'widget_field_select') {
switch(e.target.id) {
case 'page_module_app_id':
$.getScript($(this).attr('rel') + '?module_app_id='+$(this).val() + append_id());
break;
case 'page_app_frontend_url':
case 'page_part_widget_path':
$.getScript($(this).attr('rel') +'?frontend=' + $(this).val() + '&module_app_id=' + $("#module_app_list select").val() + append_id() );
break;
case 'page_design':
$.getScript($(this).attr('rel') + '?design_id=' + $(this).val() + append_id());
break;
case 'page_part_public_r_tag':
$.getScript($(this).attr('rel') + '?type=' + $(this).val() + append_id());
break;
};
} else {
$.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() );
}
$("div.editable").live("mouseenter mouseleave", function (event) {
$(this).children('.edit_link').toggle();
});
$(document).on('click', '.part_kind', function(event) {
$("#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();
});
});
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -1,124 +0,0 @@
/* ===================================================
* jquery-lite-image-resize v.1.0.1
* https://github.com/RayChang/jquery-lite-image-resize
* ===================================================
* How to use ?
*
* HTML element closest to the image to add class "resizeimg".
*
* Example:
* <div class="resizeimg">
* <img src="images url" />
* </div>
*
* Or you can use:
* $('your class').rsImg();
*
* Note : HTML structure must be a structure like the example above.
*
*/
!function ($) {
"use strict";
var ResizeImg = function(element) {
this.element = $(element);
this.element.data('exists', true);
};
ResizeImg.prototype.resize = function() {
var $img = this.element.children('img').eq(0),
elW = this.element.innerWidth(),
elH = this.element.innerHeight(),
elScale = elW/elH,
image = document.createElement("img");
image.src = $img.attr('src');
this.element.css({
'position': 'relative',
'overflow': 'hidden',
});
function imageLoadComplete() {
var imgW = image.width,
imgH = image.height,
imgScale = imgW/imgH,
portrait = {
'position': 'absolute',
'height': '100%',
'width': 'auto',
'max-width': 'none',
'left': '50%',
'top': 0,
'margin-left': imgW*(elH/imgH)/-2
},
landscape = {
'position': 'absolute',
'height': 'auto',
'max-height': 'none',
'width': '100%',
'left': 0,
'top': '50%',
'margin-top': imgH*(elW/imgW)/-2
},
center = {
'position': 'absolute',
'height': '100%',
'width': '100%',
'top': 0,
'left': 0
};
if(imgScale < 1) {
if(elScale < 1) {
if(elScale > imgScale) {
$img.css(landscape);
} else {
$img.css(portrait);
};
} else {
$img.css(landscape);
};
};
if(imgScale > 1) {
if(elScale > 1) {
if(elScale > imgScale) {
$img.css(landscape);
} else {
$img.css(portrait);
};
} else {
$img.css(portrait);
};
};
if(imgScale == 1) {
if(elScale < 1) {
$img.css(portrait);
} else if(elScale > 1) {
$img.css(landscape);
} else {
$img.css(center);
};
};
$img.fadeTo(500, 1);
}
if(/MSIE 8.0/g.test($ua)) {
imageLoadComplete();
} else {
image.onload = imageLoadComplete;
}
};
$.fn.rsImg = function () {
this.each(function () {
if(!$(this).data('exists')) {
$(this).children("img").fadeTo(0,0);
new ResizeImg(this).resize();
};
});
};
$(function() {
$('.resizeimg').rsImg();
});
}(window.jQuery);
+41 -78
View File
@@ -12,14 +12,13 @@
!(function($){
// Convenience vars for accessing elements
var $body = $('#main-wrap'),
$bottomNav = $('.bottomnav'),
$pageslide = $('#pageslide'),
$viewPage = $('#view-page');
var _sliding = false, // Mutex to assist closing only once
_lastCaller; // Used to keep track of last element to trigger pageslide
// If the pageslide element doesn't exist, create it
// If the pageslide element doesn't exist, create it
if( $pageslide.length == 0 ) {
$pageslide = $('<div />').attr( 'id', 'pageslide' )
.css( 'display', 'none' )
@@ -29,12 +28,11 @@
/*
* Private methods
*/
function _load( url, useIframe, callback,element ) {
function _load( url, useIframe ) {
// Are we loading an element from the page or a URL?
if ( url.indexOf("#") === 0 ) {
// Load a page element
$(url).clone(true).appendTo( $pageslide.empty() ).show();
if(callback)callback.call(this,$pageslide,element);
} else {
// Load a URL. Into an iframe?
if( useIframe ) {
@@ -51,18 +49,9 @@
$viewPage.find('.content').html( iframe );
$viewPage.clone(true).appendTo( $pageslide.empty() ).show();
$viewPage.find('.content').empty();
if(callback)callback.call(this,$viewPage,element);
} else {
$viewPage.find('.content').load(url, function(){
$viewPage.clone(true).appendTo( $pageslide.empty() ).show();
if($('#filter-default-tag').length) {
$('#filter-default-tag').fastLiveFilter('.add-default-tags-list', '.filter-item', '.tag');
addTagsTab();
$('#view-page .card').cardCheck({
item: $('#view-page input[type="checkbox"]'),
});
};
if(callback)callback.call(this,$viewPage,element);
});
}
@@ -75,11 +64,10 @@
function _start( direction, speed ) {
var slideWidth = $pageslide.outerWidth( true ),
bodyAnimateIn = {},
bottomnavAnimateIn = {},
slideAnimateIn = {};
// If the slide is open or opening, just ignore the call
if( $pageslide.is(':visible') || _sliding ) return;
if( $pageslide.is(':visible') || _sliding ) return;
_sliding = true;
switch( direction ) {
@@ -95,7 +83,6 @@
$pageslide.css({ left: '-' + (slideWidth-61) + 'px', right: 'auto' });
};
bodyAnimateIn['margin-left'] = '+=' + slideWidth;
bottomnavAnimateIn['left'] = '+=' + slideWidth;
if($(window).width() <= 1440 && slideWidth > 963 ) {
bodyAnimateIn['width'] = $body.width();
}
@@ -105,7 +92,6 @@
// Animate the slide, and attach this slide's settings to the element
$body.animate(bodyAnimateIn, speed);
$bottomNav.animate(bottomnavAnimateIn, speed);
$pageslide.show().animate(slideAnimateIn, speed, function() {
_sliding = false;
$pageslide.children('.nano').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
@@ -122,7 +108,7 @@
$.fn.pageslide = function(options) {
var $elements = this;
// On click
$elements.bind(clickEvent, function(e) {
$elements.on(clickEvent, function(e) {
var $self = $(this),
settings = $.extend({ href: $self.attr('href') }, options);
@@ -135,7 +121,7 @@
$.pageslide.close();
} else {
// Open
$.pageslide( settings,$self );
$.pageslide( settings );
if($('.item-groups').length) {
$('.item-menu > a, .navbar-inner').removeClass("active");
@@ -154,16 +140,7 @@
$pageName = $self.parents('.item-title').children('a').text();
$('.page-name').text($pageName);
} else if($('.tags-groups').length) {
if($('.gallery').length) {
$(this).closest('.rgalbum').addClass('active-single').siblings().removeClass('active-single');
if($(this).closest('ul').hasClass('photo-action')) {
$('.checkbox').prop('checked', false);
$('.rgalbum').removeClass('active');
$('.deletephoto, .deselect, .addtags').addClass('hide');
}
} else {
$(this).closest('li').addClass("active").siblings().removeClass("active").parent('ul').siblings().children('li').removeClass("active");
}
$(this).parents('li').addClass("active").siblings().removeClass("active").parent('ul').siblings().children('li').removeClass("active");
} else {
$(this).parents("tr").addClass("active").siblings().removeClass("active");;
}
@@ -174,9 +151,9 @@
};
});
};
/*
};
/*
* Default settings
*/
$.fn.pageslide.defaults = {
@@ -187,18 +164,18 @@
href: null, // Override the source of the content. Optional in most cases, but required when opening pageslide programmatically.
W: 264,
closeFn : null,
openFn : null,
loadComplete : null
openFn : null
};
/*
/*
* Public methods
*/
// Open the pageslide
$.pageslide = function( options,element ) {
// Extend the settings with those the user has provided
// Open the pageslide
$.pageslide = function( options ) {
// Extend the settings with those the user has provided
var settings = $.extend({}, $.fn.pageslide.defaults, options);
var convertToFunction = function(fn){
var x = new Function();
x = fn;
@@ -213,19 +190,16 @@
if(settings.closeFn) {
$.fn.pageslide.defaults.closeFn = convertToFunction(settings.closeFn);
}
if(settings.loadComplete) {
$.fn.pageslide.defaults.loadComplete = convertToFunction(settings.loadComplete);
}
// Are we trying to open in different direction?
// Are we trying to open in different direction?
if( ($pageslide.is(':visible') && $pageslide.data( 'W' ) != settings.W) || ($pageslide.is(':visible') && $pageslide.data( 'direction' ) != settings.direction) ) {
$.pageslide.close(function(){
$pageslide.css({'width': settings.W});
_load( settings.href, settings.iframe, settings.loadComplete, element );
_load( settings.href, settings.iframe );
_start( settings.direction, settings.speed );
});
} else {
_load( settings.href, settings.iframe, settings.loadComplete,element );
_load( settings.href, settings.iframe );
if( $pageslide.is(':hidden') ) {
$pageslide.css({'width': settings.W});
_start( settings.direction, settings.speed );
@@ -244,19 +218,18 @@
};
};
};
// Close the pageslide
$.pageslide.close = function( callback ) {
// Close the pageslide
$.pageslide.close = function( callback ) {
var $pageslide = $('#pageslide'),
slideWidth = $pageslide.outerWidth( true ),
speed = $pageslide.data( 'speed' ),
bodyAnimateIn = {},
bottomnavAnimateIn = {};
slideAnimateIn = {}
// If the slide isn't open, just ignore the call
if( $pageslide.is(':hidden') || _sliding ) return;
if( $pageslide.is(':hidden') || _sliding ) return;
_sliding = true;
switch( $pageslide.data( 'direction' ) ) {
@@ -266,10 +239,9 @@
break;
default:
bodyAnimateIn['margin-left'] = '-=' + slideWidth;
bottomnavAnimateIn['left'] = '-=' + slideWidth;
slideAnimateIn['left'] = '-=' + slideWidth;
if($pageslide.find('.preview').length) {
$pageslide.find('.preview').cycle('destroy');
// $pageslide.find('.preview').cycle('destroy');
$pageslide.find('.preview img').removeAttr('style');
}
break;
@@ -285,13 +257,11 @@
}
} else if($('.tags-groups').length) {
$('.tags-groups').children('li').removeClass("active");
$('.rgalbum').removeClass("active-single");
} else {
$("tr").removeClass("active");
};
$pageslide.animate(slideAnimateIn, speed);
$bottomNav.animate(bottomnavAnimateIn, speed);
$body.animate(bodyAnimateIn, speed, function() {
$pageslide.hide();
_sliding = false;
@@ -317,33 +287,26 @@
$.fn.pageslide.defaults.openFn = callback;
};
};
//data load complete callback
$.pageslide.loadComplete = function(callback) {
if(typeof callback === "function"){
$.fn.pageslide.defaults.loadComplete = callback;
};
};
/* Events */
// Don't let clicks to the pageslide close the window
/* Events */
// Don't let clicks to the pageslide close the window
$pageslide.click(function(e) {
e.stopPropagation();
});
// Close the pageslide if the document is clicked or the users presses the ESC key, unless the pageslide is modal
$(document).bind('click keyup', function(e) {
// If this is a keyup event, let's see if it's an ESC key
// Close the pageslide if the document is clicked or the users presses the ESC key, unless the pageslide is modal
$(document).bind('click keyup', function(e) {
// If this is a keyup event, let's see if it's an ESC key
if( e.type == "keyup" && e.keyCode != 27) return;
// Make sure it's visible, and we're not modal
if( $pageslide.is( ':visible' ) && !$pageslide.data( 'modal' ) ) {
$.pageslide.close();
}
});
// Make sure it's visible, and we're not modal
if( $pageslide.is( ':visible' ) && !$pageslide.data( 'modal' ) ) {
$.pageslide.close();
}
});
function setScroll(){
$pageslide.children('.nano').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true }); // set nano scroll
};
})(jQuery);
+9
View File
@@ -0,0 +1,9 @@
/**
* jQuery.Preload - Multifunctional preloader
* Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com
* Dual licensed under MIT and GPL.
* Date: 3/25/2009
* @author Ariel Flesler
* @version 1.0.8
*/
;(function($){var h=$.preload=function(c,d){if(c.split)c=$(c);d=$.extend({},h.defaults,d);var f=$.map(c,function(a){if(!a)return;if(a.split)return d.base+a+d.ext;var b=a.src||a.href;if(typeof d.placeholder=='string'&&a.src)a.src=d.placeholder;if(b&&d.find)b=b.replace(d.find,d.replace);return b||null}),data={loaded:0,failed:0,next:0,done:0,total:f.length};if(!data.total)return finish();var g=$(Array(d.threshold+1).join('<img/>')).load(handler).error(handler).bind('abort',handler).each(fetch);function handler(e){data.element=this;data.found=e.type=='load';data.image=this.src;data.index=this.index;var a=data.original=c[this.index];data[data.found?'loaded':'failed']++;data.done++;if(d.enforceCache)h.cache.push($('<img/>').attr('src',data.image)[0]);if(d.placeholder&&a.src)a.src=data.found?data.image:d.notFound||a.src;if(d.onComplete)d.onComplete(data);if(data.done<data.total)fetch(0,this);else{if(g&&g.unbind)g.unbind('load').unbind('error').unbind('abort');g=null;finish()}};function fetch(i,a,b){if(a.attachEvent&&data.next&&data.next%h.gap==0&&!b){setTimeout(function(){fetch(i,a,1)},0);return!1}if(data.next==data.total)return!1;a.index=data.next;a.src=f[data.next++];if(d.onRequest){data.index=a.index;data.element=a;data.image=a.src;data.original=c[data.next-1];d.onRequest(data)}};function finish(){if(d.onFinish)d.onFinish(data)}};h.gap=14;h.cache=[];h.defaults={threshold:2,base:'',ext:'',replace:''};$.fn.preload=function(a){h(this,a);return this}})(jQuery);
-13
View File
@@ -1,13 +0,0 @@
/**
* jQuery.Preload
* https://github.com/htmlhero/jQuery.preload
*
* Created by Andrew Motoshin
* http://htmlhero.ru
*
* Version: 1.5.0
* Requires: jQuery 1.6+
*
*/
!function(a){a.preload=function(){var b=[],c=function(a){for(var c=0;c<b.length;c++)if(b[c].src===a.src)return b[c];return b.push(a),a},d=function(a,b,c){"function"==typeof b&&b.call(a,c)};return function(b,e,f){if("undefined"!=typeof b){"string"==typeof b&&(b=[b]),2===arguments.length&&"function"==typeof e&&(f=e,e=0);var g,h=b.length;if(e>0&&h>e&&(g=b.slice(e,h),b=b.slice(0,e),h=b.length),!h)return d(b,f,!0),void 0;for(var i,j=arguments.callee,k=0,l=function(){k++,k===h&&(d(b,f,!g),j(g,e,f))},m=0;m<b.length;m++)i=new Image,i.src=b[m],i=c(i),i.complete?l():a(i).on("load error",l)}}}();var b=function(b,c){var d,e,f,g,h,i=[],j=new RegExp("url\\(['\"]?([^\"')]*)['\"]?\\)","i");return c.recursive&&(b=b.find("*").add(b)),b.each(function(){for(d=a(this),e=d.css("background-image")+","+d.css("border-image-source"),e=e.split(","),h=0;h<e.length;h++)f=e[h],-1===f.indexOf("about:blank")&&-1===f.indexOf("data:image")&&(g=j.exec(f),g&&i.push(g[1]));"IMG"===this.nodeName&&i.push(this.src)}),i};a.fn.preload=function(){var c,d;1===arguments.length?"object"==typeof arguments[0]?c=arguments[0]:d=arguments[0]:arguments.length>1&&(c=arguments[0],d=arguments[1]),c=a.extend({recursive:!0,part:0},c);var e=this,f=b(e,c);return a.preload(f,c.part,function(a){a&&"function"==typeof d&&d.call(e.get())}),this}}(jQuery);
-101
View File
@@ -1,101 +0,0 @@
var ListCheck = function(element) {
this.element = $(element);
this.element.data('exists', true);
if(this.element.context.parentNode.tagName == "TD") {
this.elementWrap = $(this.element.context.parentNode);
this.elementWrap.addClass('listCheck');
} else if(this.element.context.parentNode.tagName == "TH") {
this.elementWrap = $(this.element.context.parentNode);
this.elementWrap.addClass('listCheckHead');
}
this.element.before('<i class="icon-check-empty" />');
};
$.fn.listCheck = function (callback) {
this.each(function (i) {
if(!$(this).data('exists')) {
new ListCheck(this);
};
});
this.on(clickEvent, function(e) {
if($(this).prop('checked')) {
$(this).siblings('i').addClass('icon-check').removeClass('icon-check-empty').closest('tr').addClass('checkHit');
} else {
$(this).siblings('i').addClass('icon-check-empty').removeClass('icon-check').closest('tr').removeClass('checkHit');
};
if ($(this).closest('.listCheckHead').length) {
$('.listCheck .list-check').prop('checked', $(this).prop('checked'));
if($(this).prop('checked')) {
$('.listCheck i').addClass('icon-check').removeClass('icon-check-empty').closest('tr').addClass('checkHit');
} else {
$('.listCheck i').addClass('icon-check-empty').removeClass('icon-check').closest('tr').removeClass('checkHit');
}
};
var _isCheck = $('tbody .list-check').filter(':checked').length,
_defaultLength = $('tbody .list-check').length;
if(_isCheck > 0 && _isCheck < _defaultLength) {
$('.listCheckHead i').removeClass('icon-check-empty icon-check').addClass('icon-minus');
} else if(!_isCheck) {
$('.listCheckHead i').removeClass('icon-minus icon-check').addClass('icon-check-empty');
} else {
$('.listCheckHead i').removeClass('icon-check-empty icon-minus').addClass('icon-check');
}
_isCheck ? $('.list-active-btn').removeClass('disabled').data('actionable', true) : $('.list-active-btn').addClass('disabled').data('actionable', false);
});
};
function clearCheck() {
$('.list-check').each(function() {
$(this).prop('checked', false);
})
}
function actionSuccess(e) {
$("tbody .list-check").each(function() {
switch(e) {
case 'list-be-hide':
$(this).filter(':checked').closest('tr').addClass('checkHide');
break;
case 'list-be-show':
$(this).filter(':checked').closest('tr').removeClass('checkHide');
break;
case 'list-be-remove':
$(this).filter(':checked').closest('tr').fadeOut(300, function() {
$(this).remove();
});
break;
};
$('.list-check').siblings('i').removeAttr('class').addClass('icon-check-empty').closest('tr').removeClass('checkHit');
});
clearCheck();
}
$(function() {
var $t = null,
_data = null;
clearCheck();
$('.list-check').listCheck();
$('.list-active-btn').data('actionable', false).on(clickEvent, function(e) {
$t = $(this)
_data = $(this).data()
_data.actionable ? $('#dialog').modal('show') : "";
e.preventDefault();
});
$('.delete-item').on(clickEvent, function() {
var _v = [];
$("tbody .list-check").each(function() {
this.checked && _v.push("ids[]="+this.value)
});
var _t = $t.attr("rel");
if(_t.indexOf("?") > -1) {
$.ajax(_t + "&" + _v.join("&")).done(function() {
actionSuccess(_data.checkAction)
});
} else {
$.ajax(_t + "?" + _v.join("&")).done(function() {
actionSuccess(_data.checkAction)
});
}
$('#dialog').modal('hide');
$('.list-active-btn').addClass('disabled').data('actionable', false);
});
});
+35 -1
View File
@@ -1,3 +1,37 @@
function loadViewPage(url, id) {
var $listView = $(id);
$listView.empty().removeClass('in active');
$listView.load(url, function(response, status, xhr) {
$(this).addClass('in active');
$('#member-card').imagesLoaded(function() {
$('#member-card .member-avatar img').muImageResize({width: 150, height:150});
});
$('#member-abstract').imagesLoaded(function() {
$('#member-abstract .member-avatar img').muImageResize({width: 250, height:120});
});
})
}
$(function() {
$('.member-avatar').rsImg();
$search = window.location.pathname.substring(1);
$search = $search.split("/");
$search = $search[$search.length-1];
$viewType = window.localStorage.getItem('viewType') || '#member-list';
$viewSwitchNo = window.localStorage.getItem('viewSwitchNo') || 0;
if($search == 'users-registrant-list.shtml') {
loadViewPage('member-registrant-list.html ' + $viewType, '#list-view');
} else {
loadViewPage('member-list.html ' + $viewType, '#list-view');
};
$('.view-switch').children('.btn').eq($viewSwitchNo).addClass('active');
$('.view-switch').delegate(".btn", 'click', function(e){
var url = $(this).attr('href'),
ID = url.split("#"),
ID = '#' + ID[ID.length-1];
window.localStorage.setItem('viewType', ID);
window.localStorage.setItem('viewSwitchNo', $(this).index());
loadViewPage(url, '#list-view');
e.preventDefault();
});
})
+27 -30
View File
@@ -1,4 +1,3 @@
var H,P = [];
// Go to
!function ($) {
$.fn.goTo = function (){
@@ -14,45 +13,43 @@ var H,P = [];
}
}(window.jQuery);
function checkHeight() {
// if($('#member-module').height() > $(window).height()) {
// H = $(window).height()-
// parseInt($('.wrap-inner').css('padding-top'))+
// parseInt($('.wrap-inner').css('padding-bottom'))-
// $('#orbit-bar').outerHeight(true);
// }else{
// H = $(window).height()-
// parseInt($('.wrap-inner').css('padding-top'))+
// parseInt($('.wrap-inner').css('padding-bottom'))-
// $('#filter').outerHeight()+
// parseInt($('#filter').css('margin-bottom'))-
// $('#orbit-bar').outerHeight(true);
// };
H = $(window).height()-
parseInt($('.wrap-inner').css('padding-top'))-
$('#orbit-bar').outerHeight(true);
if($('#member-module').height() > $(window).height()) {
H = $(window).height()-
parseInt($('.wrap-inner').css('padding-top'))+
parseInt($('.wrap-inner').css('padding-bottom'))-
$('#orbit-bar').outerHeight(true);
}else{
H = $(window).height()-
parseInt($('.wrap-inner').css('padding-top'))+
parseInt($('.wrap-inner').css('padding-bottom'))-
$('#filter').outerHeight()+
parseInt($('#filter').css('margin-bottom'))-
$('#orbit-bar').outerHeight(true);
};
$('#basic-info').height(H);
$('#member-roles').height(H-$('.member-avatar').outerHeight(true)-parseInt($('#member-roles').css('margin-top'))+20);
$('#module-content').height(H-$('#module-navbar .navbar').outerHeight(true)-$('.bottomnav').innerHeight());
$('#member-roles').height(H-$('.member-avatar').outerHeight(true)-parseInt($('#member-roles').css('margin-top')))
};
$(function() {
var H;
checkHeight();
$('.wrap-inner').css('padding-bottom', 0);
$(window).resize(checkHeight);
$(window).resize(function() {
checkHeight();
// setModuleBlockWidth();
});
$('#member-roles h4 > span').each(function() {
$(this).css('margin-left',function() {
return $(this).innerWidth()/2*-1;
})
})
// $('#basic-info').scrollToFixed({
// marginTop: $('#orbit-bar').outerHeight(true)+20,
// });
// $('#module-navbar').scrollToFixed({
// marginTop: $('#orbit-bar').outerHeight(true),
// });
$('#basic-info').scrollToFixed({
marginTop: $('#orbit-bar').outerHeight(true)+20,
});
$('#module-navbar').scrollToFixed({
marginTop: $('#orbit-bar').outerHeight(true),
});
// $('.member-avatar').imagesLoaded(function() {
// $('#basic-info .member-avatar img').muImageResize({width: 100, height:100});
// });
$('.member-avatar').rsImg();
$('#member-roles, #module-content .nano').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
});
$('#member-roles').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
})
@@ -191,17 +191,12 @@ function returnAddressForm(element, decide) {
$(function() {
appendIndex = null;
if($('#user-forms').length) {
if($('#new-user-forms').length) {
addressVal = [];
addressArray = [];
addressInputId = [];
roleType = null;
returnDecide = false;
$('.attributes').each(function() {
if($(this).find('.toggle-check').attr('value') == "true") {
$(this).addClass('disabled').children('.attributes-body').hide();
}
});
$('.returnDecide').on(clickEvent, function() {
returnDecide = true;
})
@@ -220,21 +215,21 @@ $(function() {
});
$('#address-field').on('show', getAddressForm($trigger, $('#address-field'), true));
});
$('#user-forms').delegate('.togglebox, .delete, .trigger, .remove-input', clickEvent, function(event) {
$('#new-user-forms').delegate('.togglebox, .delete, .trigger, .remove-input', clickEvent, function(event) {
if($(this).hasClass('togglebox')) {
if($(this).hasClass('disabled')) {
$(this).find('.toggle-check')
.attr('value', 'false')
.closest('.attributes')
.removeClass('disabled')
.children('.attributes-body')
.find('.attributes-body')
.fadeIn(300);
} else {
$(this).find('.toggle-check')
.attr('value', 'true')
.closest('.attributes')
.addClass('disabled')
.children('.attributes-body')
.find('.attributes-body')
.fadeOut(300);
}
$(this).toggleClass('disabled');
@@ -427,13 +422,12 @@ $(function() {
if($(this).hasClass('trigger')) {
// appendIndex = $(this).closest('.controls').find('.input-append').length;
appendIndex = $(this).closest('.controls').find('.input-append:last-child').children('input:first-child').attr('name');
// appendIndex = appendIndex.split("][");
// appendIndex = parseInt(appendIndex[appendIndex.length-2])+1;
appendIndex = parseInt(appendIndex.match(/[^[\D\]]+(?=])/g)[1])+1;
console.log(appendIndex)
appendIndex = appendIndex.split("][");
appendIndex = parseInt(appendIndex[appendIndex.length-2])+1;
attributeIndex = $(this).closest('.attributes').index();
templateType = $(this).closest('.attributes').find('.dataType').children("option:selected").attr('ref');
$("#template-input-append").tmpl(setData(attributeIndex, templateType, appendIndex)).appendTo($(this).closest('.controls').find('.add-target'));
inputAppendLength();
};
if($(this).hasClass('remove-input')) {
@@ -1,56 +0,0 @@
function dragMode() {
$('#card-list').sortable({
placeholder: "highlight",
update: function( event, ui ) {
var _userPosition = {};
_userPosition.position = $(ui.item).index();
_userPosition.id = $(ui.item).data('user-id');
$.ajax({
url: "<%= Rails.application.routes.url_helpers.update_order_card_admin_users_new_interface_index_path %>",
type: 'POST',
dataType: 'script',
data: {users: _userPosition}
});
}
});
$('#card-list').disableSelection();
}
function typeMode() {
var _userPosition = [];
$('#list-view tbody tr').each(function(i) {
$(this).data('user-index', i);
});
$('#member-list').on(clickEvent, '.edit_position', function(e){
var $input = $('<input type="text">'),
$cross = $('<a class="btn btn-mini"><i class="icons-cross"/></a>');
if($(this).siblings('input').length) {
$(this).siblings('input').attr('type', 'text').after($cross);
} else {
$(this).after($cross);
$(this).after($input);
}
$(this).hide();
$input.val($(this).text());
e.preventDefault();
$cross.click(function(event) {
$input.remove();
$(this).siblings('a').show().end().remove();
});
});
$('.bottomnav').on(clickEvent, '.btn', function(e) {
_userPosition = [];
$('#member-list tbody input').each(function(i) {
_userPosition.push([$(this).val(), $(this).siblings('a').data('user-id')]);
});
$.ajax({
url: "<%= Rails.application.routes.url_helpers.update_order_list_admin_users_new_interface_index_path %>",
type: 'POST',
dataType: 'script',
data: {users: _userPosition}
});
e.preventDefault();
});
};
@@ -1,4 +1,4 @@
function textareaResizable() {
$(function() {
var $btnW = null,
$textareaLangBtnGroup = $('.textarea-lang > .btn-group'),
$textareaLang = $('.textarea-lang'),
@@ -8,12 +8,12 @@ function textareaResizable() {
$btnW = 4
$(this).find('.btn').each(function() {
$btnW += $(this).outerWidth(true);
$(this).on(clickEvent, function() {
$(this).on('click', function() {
var $id = $($(this).attr('href'));
if($id.find('.ui-wrapper').height() < 96) {
$id.find('.ui-wrapper').height(96)
};
});
}
})
});
});
$textarea.each(function() {
@@ -26,7 +26,4 @@ function textareaResizable() {
minWidth: $btnW+114,
handles: "se",
});
};
$(function() {
textareaResizable();
});
@@ -1,8 +0,0 @@
$(function() {
$('.module-area [data-toggle=buttons-checkbox]').find('input[type="checkbox"]').each(function() {
$(this).prop('checked') ? $(this).siblings('input[type="hidden"]').val(1) : $(this).siblings('input[type="hidden"]').val(0);
});
$('.module-area').delegate('input[type="checkbox"]', clickEvent, function(event) {
$(this).prop('checked') ? $(this).siblings('input[type="hidden"]').val(1) : $(this).siblings('input[type="hidden"]').val(0);
});
});
-354
View File
@@ -1,354 +0,0 @@
!function ($) {
// Convenience vars for accessing elements
var $pageslide = $('#pageslide'),
$body = $('#main-wrap'),
$bottomNav = $('.bottomnav'),
$element;
if($pageslide.length == 0) {
var _html = '<div id="pageslide"><div class="page-title clearfix"><a class="pull-right" href="javascript:$.pageslide.close()"><i class="icons-arrow-left-2"/></a><span/></div><div class="view-page"><div class="nano"><div class="content"/></div></div></div>';
$pageslide = $(_html).css('display', 'none').appendTo( $body );
} else {
$pageslide.css('display', 'none')
}
var _sliding = false, // Mutex to assist closing only once
_lastCaller; // Used to keep track of last element to trigger pageslide
// $(window).resize(function(event) {
// if($pageslide.is(':visible')) {
// console.log("ddd")
// $pageslide.find('.nano').height($('body').height() - $('#orbit-bar').height() - $pageslide.find('.page-title').outerHeight(true));
// }
// });
function _checkTitle(settings) {
if(settings.pageTitle) {
$pageslide.find('.page-title').show().children('span').text(settings.pageTitle);
$pageslide.find('.view-page').css('top', 48);
} else {
$pageslide.find('.page-title').hide();
$pageslide.find('.view-page').css('top', 0);
}
}
function _load(settings) {
// Are we loading an element from the page or a URL?
if ( settings.href.indexOf("#") === 0 ) {
// Load a page element
var _contentHtml = $(settings.href).html();
var dtd = $.Deferred();
function appendHtml(dtd) {
$pageslide.find('.content').html(_contentHtml);
if($pageslide.find('.content').find('*').length !== 0) {
dtd.resolve();
} else {
dtd.reject();
}
return dtd;
}
$.when(appendHtml(dtd))
.done(function() {
setTimeout(function() {
$pageslide.find('.nano').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
}, 1);
if(settings.loadComplete)settings.loadComplete.call(this, $pageslide, $element);
})
.fail(function() {});
} else {
// Load a URL. Into an iframe?
if(settings.iframe) {
var iframe = $("<iframe />").attr({
src: settings.href,
frameborder: 0,
hspace: 0
})
.css({
width: "100%",
height: "100%"
});
$pageslide.find('.content').html(iframe).show();
if(settings.loadComplete)settings.loadComplete.call(this, $pageslide, $element);
} else {
$pageslide.find('.content').load(settings.href, function(response, status, xhr){
if(status == 'success') {
$pageslide.show();
if(settings.loadComplete)settings.loadComplete.call(this, $pageslide, $element);
$pageslide.find('.nano').nanoScroller({ scrollTop: 0, iOSNativeScrolling: true });
} else {
var msg = '<div style="text-align: center;"><i class="icons-warning" style="font-size: 5em;"></i><h4>Oops!</h4>System may be wrong<br/> or please try again later</div>'
$pageslide.find('.content').html(msg);
}
});
}
if($pageslide.find('.error-cover').length) $pageslide.find('.error-cover').remove();
$pageslide.data( 'localEl', false );
}
_checkTitle(settings);
}
// Function that controls opening of the pageslide
function _start(settings) {
var slideWidth = $pageslide.outerWidth(true),
bodyMove = $sidebarState && !$('.item-groups').length ? slideWidth - 241 : settings.direction == 'right' ? slideWidth - 61 : slideWidth,
bodyAnimateIn = {},
bottomnavAnimateIn = {},
slideAnimateIn = {};
// If the slide is open or opening, just ignore the call
if($pageslide.is(':visible') || _sliding) return;
_sliding = true;
switch(settings.direction) {
case 'left':
$pageslide.css({left: 'auto', right: '-' + slideWidth + 'px'});
bodyAnimateIn['padding-right'] = '+=' + bodyMove;
slideAnimateIn['right'] = '+=' + slideWidth;
break;
default:
$pageslide.css({left: '-' + slideWidth + 'px', right: 'auto'});
bodyAnimateIn['margin-left'] = '+=' + bodyMove;
bottomnavAnimateIn['left'] = '+=' + bodyMove;
if($(window).width() <= 1440 && slideWidth > 963 ) {
bodyAnimateIn['width'] = $body.width();
}
slideAnimateIn['left'] = '+=' + slideWidth;
break;
}
// Animate the slide, and attach this slide's settings to the element
$body.animate(bodyAnimateIn, settings.speed);
$bottomNav.animate(bottomnavAnimateIn, settings.speed);
$pageslide.show().animate(slideAnimateIn, settings.speed, function() {
_sliding = false;
if(typeof settings.openFn === "function") {
settings.openFn.call(this, $pageslide, $element);
};
});
}
$.fn.pageslide = function(options) {
var $elements = this;
// On click
$elements.click( function(e) {
var $self = $(this),
settings = $.extend({href: $self.attr('href'), pageTitle: $self.data('title')}, options);
$element = $self;
// Prevent the default behavior and stop propagation
e.preventDefault();
e.stopPropagation();
if ($pageslide.is(':visible') && $self[0] == _lastCaller) {
// If we clicked the same element twice, toggle closed
$.pageslide.close();
} else {
// Open
$.pageslide(settings);
// Record the last element to trigger pageslide
_lastCaller = $self[0];
}
});
};
/*
* Default settings
*/
$.fn.pageslide.defaults = {
speed: 300, // Accepts standard jQuery effects speeds (i.e. fast, normal or milliseconds)
direction: 'right', // Accepts 'left' or 'right'
modal: false, // If set to true, you must explicitly close pageslide using $.pageslide.close();
iframe: false, // By default, linked pages are loaded into an iframe. Set this to false if you don't want an iframe.
href: null, // Override the source of the content. Optional in most cases, but required when opening pageslide programmatically.
W: 264,
closeFn : null,
openFn : null,
loadComplete : null,
pageTitle: '',
};
/*
* Public methods
*/
// Open the pageslide
$.pageslide = function(options) {
// Extend the settings with those the user has provided
var settings = $.extend({}, $.fn.pageslide.defaults, options),
pageCss = {},
convertToFunction = function(fn){
var x = new Function();
x = fn;
return x;
};
pageCss['width'] = settings.W;
pageCss['margin-left'] = $sidebarState && !$('.item-groups').length ? 241 : settings.direction == 'right' ? 61 : 0;
// Change Object to Function
if(settings.openFn) {
$.fn.pageslide.defaults.openFn = convertToFunction(settings.openFn);
};
if(settings.closeFn) {
$.fn.pageslide.defaults.closeFn = convertToFunction(settings.closeFn);
};
if(settings.loadComplete) {
$.fn.pageslide.defaults.loadComplete = convertToFunction(settings.loadComplete);
};
// Are we trying to open in different direction?
if(($pageslide.is(':visible') && $pageslide.data('W') != settings.W) || ($pageslide.is(':visible') && $pageslide.data('direction') != settings.direction)) {
$.pageslide.close(function(){
$pageslide.css(pageCss);
_checkTitle(settings)
_load(settings);
_start(settings);
});
} else {
_checkTitle(settings)
_load(settings);
if($pageslide.is(':hidden')) {
$pageslide.css(pageCss);
_start(settings);
}
}
$pageslide.data(settings);
}
// Close the pageslide
$.pageslide.close = function(callback) {
var $pageslide = $('#pageslide'),
slideWidth = $pageslide.outerWidth(true),
bodyMove = $sidebarState && !$('.item-groups').length ? slideWidth - 241 : $.fn.pageslide.defaults.direction == 'right' ? slideWidth - 61 : slideWidth
speed = $pageslide.data('speed'),
bodyAnimateIn = {},
bottomnavAnimateIn = {},
slideAnimateIn = {};
// If the slide isn't open, just ignore the call
if( $pageslide.is(':hidden') || _sliding ) return;
_sliding = true;
switch($pageslide.data('direction')) {
case 'left':
bodyAnimateIn['padding-right'] = '-=' + bodyMove;
slideAnimateIn['right'] = '-=' + slideWidth;
break;
default:
bodyAnimateIn['margin-left'] = '-=' + bodyMove;
bottomnavAnimateIn['left'] = '-=' + bodyMove;
slideAnimateIn['left'] = '-=' + slideWidth;
break;
}
$pageslide.animate(slideAnimateIn, speed);
$bottomNav.animate(bottomnavAnimateIn, speed);
$body.animate(bodyAnimateIn, speed, function() {
if($pageslide.data('href') == '#') {
$pageslide.attr('style', '')
.hide()
.find('.content')
.attr('style', '')
.end()
.find('.view-page')
.attr('style', '')
.end()
.find('.pane')
.remove()
.end()
.find('.page-title')
.attr('style', '')
.children('span');
} else {
$pageslide.attr('style', '')
.hide()
.find('.content')
.attr('style', '')
.empty()
.end()
.find('.view-page')
.attr('style', '')
.end()
.find('.pane')
.remove()
.end()
.find('.page-title')
.attr('style', '')
.children('span')
.empty();
}
_sliding = false;
if($pageslide.find('.error-cover').length) $pageslide.find('.error-cover').remove();
if(typeof callback != 'undefined') callback();
if(typeof $.fn.pageslide.defaults.closeFn === "function") {
$.fn.pageslide.defaults.closeFn.call(this, $pageslide, $element);
};
});
}
// Close Callback
$.pageslide.closeCallback = function( callback ) {
if(typeof callback === "function"){
$.fn.pageslide.defaults.closeFn = callback;
};
};
// Open Callback
$.pageslide.openCallback = function( callback ) {
if(typeof callback === "function"){
$.fn.pageslide.defaults.openFn = callback;
};
};
//data load complete callback
$.pageslide.loadComplete = function( callback ) {
if(typeof callback === "function"){
$.fn.pageslide.defaults.loadComplete = callback;
};
};
/* Events */
// Don't let clicks to the pageslide close the window
$pageslide.click(function(e) {
e.stopPropagation();
});
// Close the pageslide if the document is clicked or the users presses the ESC key, unless the pageslide is modal
$(document).bind('click keyup', function(e) {
// If this is a keyup event, let's see if it's an ESC key
if( e.type == "keyup" && e.keyCode != 27) return;
// Make sure it's visible, and we're not modal
if( $pageslide.is( ':visible' ) && !$pageslide.data( 'modal' ) ) {
$.pageslide.close();
}
});
}(window.jQuery);
function setForm(data) {
$.each(data, function(key, value) {
switch($("#pageslide form #" + key).prop("tagName"))
{
case "INPUT":
$("#pageslide form #" + key).val(value);
break;
case "SELECT":
$("#pageslide form #" + key).val(value);
break;
}
});
}
function resetForm() {
$("#pageslide form").find("input[type=text], input[type=number], textarea")
.val("")
.end()
.find("select")
.prop('selectedIndex', 0)
.end()
.find("input[type=checkbox]")
.prop('checked', false)
.end()
.find("input[type=radio]")
.prop('checked', false);
}
+2
View File
@@ -197,6 +197,7 @@ function mergerTags() {
}
$(function() {
if($('.default-tags').length) {
// checkTagsQuantity();
checkedLength();
$('#tags-merger').on('hidden', function () {
$(this).find('.filter-item').remove();
@@ -204,4 +205,5 @@ $(function() {
} else {
checkedLength();
};
// addTagsTab();
});
-16
View File
@@ -1,16 +0,0 @@
// This is a manifest file that'll be compiled into including all the files listed below.
// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
// be included in the compiled file accessible from http://example.com/assets/application.js
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// the compiled file.
//
//= require jquery
//= require lib/jquery.preload.min.js
//= require cycle2
//= require mobile/jquery.mu.image.resize
//= require mobile/orbit.mobile
//= require mobile/jquery.mobile-1.2.0.min
//= require mobile/jquery.swipeplanes-1.2.min
//= require mobile/add2home
//= require mobile/gmAPI
//= require mobile/jquery.ui.map
-350
View File
@@ -1,350 +0,0 @@
/*!
* Add to Homescreen v2.0.4 ~ Copyright (c) 2012 Matteo Spinelli, http://cubiq.org
* Released under MIT license, http://cubiq.org/license
*/
var addToHome = (function (w) {
var nav = w.navigator,
isIDevice = 'platform' in nav && (/iphone|ipod|ipad/gi).test(nav.platform),
isIPad,
isRetina,
isSafari,
isStandalone,
OSVersion,
startX = 0,
startY = 0,
lastVisit = 0,
isExpired,
isSessionActive,
isReturningVisitor,
balloon,
overrideChecks,
positionInterval,
closeTimeout,
options = {
autostart: true, // Automatically open the balloon
returningVisitor: false, // Show the balloon to returning visitors only (setting this to true is HIGHLY RECCOMENDED)
animationIn: 'bubble', // drop || bubble || fade
animationOut: 'drop', // drop || bubble || fade
startDelay: 2000, // 2 seconds from page load before the balloon appears
lifespan: 10000, // 15 seconds before it is automatically destroyed
bottomOffset: 14, // Distance of the balloon from bottom
expire: 0, // Minutes to wait before showing the popup again (0 = always displayed)
message: '', // Customize your message or force a language ('' = automatic)
touchIcon: true, // Display the touch icon
arrow: true, // Display the balloon arrow
hookOnLoad: true, // Should we hook to onload event? (really advanced usage)
iterations: 100 // Internal/debug use
},
intl = {
ca_es: 'Per instal·lar aquesta aplicació al vostre %device premeu %icon i llavors <strong>Afegir a pantalla d\'inici</strong>.',
cs_cz: 'Pro instalaci aplikace na Váš %device, stiskněte %icon a v nabídce <strong>Přidat na plochu</strong>.',
da_dk: 'Tilføj denne side til din %device: tryk på %icon og derefter <strong>Føj til hjemmeskærm</strong>.',
de_de: 'Installieren Sie diese App auf Ihrem %device: %icon antippen und dann <strong>Zum Home-Bildschirm</strong>.',
el_gr: 'Εγκαταστήσετε αυτήν την Εφαρμογή στήν συσκευή σας %device: %icon μετά πατάτε <strong>Προσθήκη σε Αφετηρία</strong>.',
en_us: 'Install this web app on your %device: tap %icon and then <strong>Add to Home Screen</strong>.',
es_es: 'Para instalar esta app en su %device, pulse %icon y seleccione <strong>Añadir a pantalla de inicio</strong>.',
fi_fi: 'Asenna tämä web-sovellus laitteeseesi %device: paina %icon ja sen jälkeen valitse <strong>Lisää Koti-valikkoon</strong>.',
fr_fr: 'Ajoutez cette application sur votre %device en cliquant sur %icon, puis <strong>Ajouter à l\'écran d\'accueil</strong>.',
he_il: '<span dir="rtl">התקן אפליקציה זו על ה-%device שלך: הקש %icon ואז <strong>הוסף למסך הבית</strong>.</span>',
hr_hr: 'Instaliraj ovu aplikaciju na svoj %device: klikni na %icon i odaberi <strong>Dodaj u početni zaslon</strong>.',
hu_hu: 'Telepítse ezt a web-alkalmazást az Ön %device-jára: nyomjon a %icon-ra majd a <strong>Főképernyőhöz adás</strong> gombra.',
it_it: 'Installa questa applicazione sul tuo %device: premi su %icon e poi <strong>Aggiungi a Home</strong>.',
ja_jp: 'このウェブアプリをあなたの%deviceにインストールするには%iconをタップして<strong>ホーム画面に追加</strong>を選んでください。',
ko_kr: '%device에 웹앱을 설치하려면 %icon을 터치 후 "홈화면에 추가"를 선택하세요',
nb_no: 'Installer denne appen på din %device: trykk på %icon og deretter <strong>Legg til på Hjem-skjerm</strong>',
nl_nl: 'Installeer deze webapp op uw %device: tik %icon en dan <strong>Zet in beginscherm</strong>.',
pl_pl: 'Aby zainstalować tę aplikacje na %device: naciśnij %icon a następnie <strong>Dodaj jako ikonę</strong>.',
pt_br: 'Instale este web app em seu %device: aperte %icon e selecione <strong>Adicionar à Tela Inicio</strong>.',
pt_pt: 'Para instalar esta aplicação no seu %device, prima o %icon e depois o <strong>Adicionar ao ecrã principal</strong>.',
ru_ru: 'Установите это веб-приложение на ваш %device: нажмите %icon, затем <strong>Добавить в «Домой»</strong>.',
sv_se: 'Lägg till denna webbapplikation på din %device: tryck på %icon och därefter <strong>Lägg till på hemskärmen</strong>.',
th_th: 'ติดตั้งเว็บแอพฯ นี้บน %device ของคุณ: แตะ %icon และ <strong>เพิ่มที่หน้าจอโฮม</strong>',
tr_tr: '%device için bu uygulamayı kurduktan sonra %icon simgesine dokunarak <strong>Ana Ekrana Ekle</strong>yin.',
zh_cn: '您可以将此应用程式安装到您的 %device 上。请按 %icon 然后点选<strong>添加至主屏幕</strong>。',
zh_tw: '您可以將此應用程式安裝到您的 %device 上。請按 %icon 然後點選<strong>加入主畫面螢幕</strong>。'
};
function init () {
// Preliminary check, all further checks are performed on iDevices only
if ( !isIDevice ) return;
var now = Date.now(),
i;
// Merge local with global options
if ( w.addToHomeConfig ) {
for ( i in w.addToHomeConfig ) {
options[i] = w.addToHomeConfig[i];
}
}
if ( !options.autostart ) options.hookOnLoad = false;
isIPad = (/ipad/gi).test(nav.platform);
isRetina = w.devicePixelRatio && w.devicePixelRatio > 1;
isSafari = (/Safari/i).test(nav.appVersion) && !(/CriOS/i).test(nav.appVersion);
isStandalone = nav.standalone;
OSVersion = nav.appVersion.match(/OS (\d+_\d+)/i);
OSVersion = OSVersion[1] ? +OSVersion[1].replace('_', '.') : 0;
lastVisit = +w.localStorage.getItem('addToHome');
isSessionActive = w.sessionStorage.getItem('addToHomeSession');
isReturningVisitor = options.returningVisitor ? lastVisit && lastVisit + 28*24*60*60*1000 > now : true;
if ( !lastVisit ) lastVisit = now;
// If it is expired we need to reissue a new balloon
isExpired = isReturningVisitor && lastVisit <= now;
if ( options.hookOnLoad ) w.addEventListener('load', loaded, false);
else if ( !options.hookOnLoad && options.autostart ) loaded();
}
function loaded () {
w.removeEventListener('load', loaded, false);
if ( !isReturningVisitor ) w.localStorage.setItem('addToHome', Date.now());
else if ( options.expire && isExpired ) w.localStorage.setItem('addToHome', Date.now() + options.expire * 60000);
if ( !overrideChecks && ( !isSafari || !isExpired || isSessionActive || isStandalone || !isReturningVisitor ) ) return;
var icons = options.touchIcon ? document.querySelectorAll('head link[rel=apple-touch-icon],head link[rel=apple-touch-icon-precomposed]') : [],
sizes,
touchIcon = '',
closeButton,
platform = nav.platform.split(' ')[0],
language = nav.language.replace('-', '_'),
i, l;
balloon = document.createElement('div');
balloon.id = 'addToHomeScreen';
balloon.style.cssText += 'left:-9999px;-webkit-transition-property:-webkit-transform,opacity;-webkit-transition-duration:0;-webkit-transform:translate3d(0,0,0);position:' + (OSVersion < 5 ? 'absolute' : 'fixed');
// Localize message
if ( options.message in intl ) { // You may force a language despite the user's locale
language = options.message;
options.message = '';
}
if ( options.message === '' ) { // We look for a suitable language (defaulted to en_us)
options.message = language in intl ? intl[language] : intl['en_us'];
}
// Search for the apple-touch-icon
if ( icons.length ) {
for ( i = 0, l = icons.length; i < l; i++ ) {
sizes = icons[i].getAttribute('sizes');
if ( sizes ) {
if ( isRetina && sizes == '114x114' ) {
touchIcon = icons[i].href;
break;
}
} else {
touchIcon = icons[i].href;
}
}
touchIcon = '<span style="background-image:url(' + touchIcon + ')" class="addToHomeTouchIcon"></span>';
}
balloon.className = (isIPad ? 'addToHomeIpad' : 'addToHomeIphone') + (touchIcon ? ' addToHomeWide' : '');
balloon.innerHTML = touchIcon +
options.message.replace('%device', platform).replace('%icon', OSVersion >= 4.2 ? '<span class="addToHomeShare"></span>' : '<span class="addToHomePlus">+</span>') +
(options.arrow ? '<span class="addToHomeArrow"></span>' : '') +
'<span class="addToHomeClose">\u00D7</span>';
document.body.appendChild(balloon);
// Add the close action
closeButton = balloon.querySelector('.addToHomeClose');
if ( closeButton ) closeButton.addEventListener('click', clicked, false);
if ( !isIPad && OSVersion >= 6 ) window.addEventListener('orientationchange', orientationCheck, false);
setTimeout(show, options.startDelay);
}
function show () {
var duration,
iPadXShift = 208;
// Set the initial position
if ( isIPad ) {
if ( OSVersion < 5 ) {
startY = w.scrollY;
startX = w.scrollX;
} else if ( OSVersion < 6 ) {
iPadXShift = 160;
}
balloon.style.top = startY + options.bottomOffset + 'px';
balloon.style.left = startX + iPadXShift - Math.round(balloon.offsetWidth / 2) + 'px';
switch ( options.animationIn ) {
case 'drop':
duration = '0.6s';
balloon.style.webkitTransform = 'translate3d(0,' + -(w.scrollY + options.bottomOffset + balloon.offsetHeight) + 'px,0)';
break;
case 'bubble':
duration = '0.6s';
balloon.style.opacity = '0';
balloon.style.webkitTransform = 'translate3d(0,' + (startY + 50) + 'px,0)';
break;
default:
duration = '1s';
balloon.style.opacity = '0';
}
} else {
startY = w.innerHeight + w.scrollY;
if ( OSVersion < 5 ) {
startX = Math.round((w.innerWidth - balloon.offsetWidth) / 2) + w.scrollX;
balloon.style.left = startX + 'px';
balloon.style.top = startY - balloon.offsetHeight - options.bottomOffset + 'px';
} else {
balloon.style.left = '50%';
balloon.style.marginLeft = -Math.round(balloon.offsetWidth / 2) - ( w.orientation%180 && OSVersion >= 6 ? 40 : 0 ) + 'px';
balloon.style.bottom = options.bottomOffset + 'px';
}
switch (options.animationIn) {
case 'drop':
duration = '1s';
balloon.style.webkitTransform = 'translate3d(0,' + -(startY + options.bottomOffset) + 'px,0)';
break;
case 'bubble':
duration = '0.6s';
balloon.style.webkitTransform = 'translate3d(0,' + (balloon.offsetHeight + options.bottomOffset + 50) + 'px,0)';
break;
default:
duration = '1s';
balloon.style.opacity = '0';
}
}
balloon.offsetHeight; // repaint trick
balloon.style.webkitTransitionDuration = duration;
balloon.style.opacity = '1';
balloon.style.webkitTransform = 'translate3d(0,0,0)';
balloon.addEventListener('webkitTransitionEnd', transitionEnd, false);
closeTimeout = setTimeout(close, options.lifespan);
}
function manualShow (override) {
if ( !isIDevice || balloon ) return;
overrideChecks = override;
loaded();
}
function close () {
clearInterval( positionInterval );
clearTimeout( closeTimeout );
closeTimeout = null;
var posY = 0,
posX = 0,
opacity = '1',
duration = '0',
closeButton = balloon.querySelector('.addToHomeClose');
if ( closeButton ) closeButton.removeEventListener('click', close, false);
if ( !isIPad && OSVersion >= 6 ) window.removeEventListener('orientationchange', orientationCheck, false);
if ( OSVersion < 5 ) {
posY = isIPad ? w.scrollY - startY : w.scrollY + w.innerHeight - startY;
posX = isIPad ? w.scrollX - startX : w.scrollX + Math.round((w.innerWidth - balloon.offsetWidth)/2) - startX;
}
balloon.style.webkitTransitionProperty = '-webkit-transform,opacity';
switch ( options.animationOut ) {
case 'drop':
if ( isIPad ) {
duration = '0.4s';
opacity = '0';
posY = posY + 50;
} else {
duration = '0.6s';
posY = posY + balloon.offsetHeight + options.bottomOffset + 50;
}
break;
case 'bubble':
if ( isIPad ) {
duration = '0.8s';
posY = posY - balloon.offsetHeight - options.bottomOffset - 50;
} else {
duration = '0.4s';
opacity = '0';
posY = posY - 50;
}
break;
default:
duration = '0.8s';
opacity = '0';
}
balloon.addEventListener('webkitTransitionEnd', transitionEnd, false);
balloon.style.opacity = opacity;
balloon.style.webkitTransitionDuration = duration;
balloon.style.webkitTransform = 'translate3d(' + posX + 'px,' + posY + 'px,0)';
}
function clicked () {
w.sessionStorage.setItem('addToHomeSession', '1');
isSessionActive = true;
close();
}
function transitionEnd () {
balloon.removeEventListener('webkitTransitionEnd', transitionEnd, false);
balloon.style.webkitTransitionProperty = '-webkit-transform';
balloon.style.webkitTransitionDuration = '0.2s';
// We reached the end!
if ( !closeTimeout ) {
balloon.parentNode.removeChild(balloon);
balloon = null;
return;
}
// On iOS 4 we start checking the element position
if ( OSVersion < 5 && closeTimeout ) positionInterval = setInterval(setPosition, options.iterations);
}
function setPosition () {
var matrix = new WebKitCSSMatrix(w.getComputedStyle(balloon, null).webkitTransform),
posY = isIPad ? w.scrollY - startY : w.scrollY + w.innerHeight - startY,
posX = isIPad ? w.scrollX - startX : w.scrollX + Math.round((w.innerWidth - balloon.offsetWidth) / 2) - startX;
// Screen didn't move
if ( posY == matrix.m42 && posX == matrix.m41 ) return;
balloon.style.webkitTransform = 'translate3d(' + posX + 'px,' + posY + 'px,0)';
}
// Clear local and session storages (this is useful primarily in development)
function reset () {
w.localStorage.removeItem('addToHome');
w.sessionStorage.removeItem('addToHomeSession');
}
function orientationCheck () {
balloon.style.marginLeft = -Math.round(balloon.offsetWidth / 2) - ( w.orientation%180 && OSVersion >= 6 ? 40 : 0 ) + 'px';
}
// Bootstrap!
init();
return {
show: manualShow,
close: close,
reset: reset
};
})(window);
-34
View File
@@ -1,34 +0,0 @@
String.prototype.format = function() { a = this; for ( k in arguments ) { a = a.replace("{" + k + "}", arguments[k]); } return a; };
window.gmAPI = {
'version': '3.0-rc1',
'ga': '',
'primaryUrl': 'http://code.google.com/p/jquery-ui-map/',
'url': 'http://jquery-ui-map.googlecode.com/',
'forum': 'http://groups.google.com/group/jquery-ui-map-discuss/feed/rss_v2_0_msgs.xml',
'subscribe': 'http://groups.google.com/group/jquery-ui-map-discuss/boxsubscribe',
'exception': 'Unable to load due to either poor internet connection or some CDN\'s aren\'t as responsive as we would like them to be. Try refreshing the page :D.',
'init': function() {
//window._gaq = [['_setAccount', this.ga], ['_trackPageview'], ['_trackPageLoadTime']];
//Modernizr.load({ 'test': ( location.href.indexOf(this.url) > -1 ), 'yep': 'http://www.google-analytics.com/ga.js' });
this.test('Backbone', function() {
$('#forum').append('<h2>Forum</h2><ul id="forum_posts"></ul><h2>Subscribe</h2><form id="forum_subscribe" class="subscribe" action="#"><label for="email">E-mail:</label><input id="email" type="text" name="email" /><input type="submit" name="sub" value="Subscribe" /></form>');
ForumCollection = Backbone.Collection.extend({ 'url': 'http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&callback=?&q={0}'.format(encodeURIComponent(gmAPI.forum)), 'parse': function(response) { return response.responseData.feed.entries; } });
ForumPost = Backbone.View.extend({ 'tagName': 'li', 'className': 'group-item', 'template': _.template('<a href="<%=link%>"><%=title%></a></h3>'), 'render': function() { $(this.el).html(this.template(this.model.toJSON())); return this; } });
Forum = Backbone.View.extend({ 'el': $("#forum"), 'initialize': function() { this.col = new ForumCollection(); this.col.bind('reset', this.load, this); this.col.fetch(); }, 'add': function(post) { var view = new ForumPost({'model': post}); $('#forum_posts').append(view.render().el); }, 'load': function () { this.col.each(this.add); $('#forum_subscribe').attr('action', gmAPI.subscribe); $(this.el).show(); } });
var app = new Forum();
});
this.test('prettyPrint', function() { prettyPrint(); });
$('#version').text(this.version);
},
'redirect': function(url) { alert('This page is deprecated. Please update your URL. Redirecting to new page.'); window.location = url; },
'col': [],
'tests': [],
'test': function(a, b) { if ( window[a] ) { b(); } },
'add': function(a, b) { if (b) { this.col[a] = b; } else { this.col.push(a); } return this; },
'load': function(a) { var self = this; if (a) { self.col[a](); } else { $.each(self.col, function(i,d) { try { d(); } catch (err) { alert(self.exception); } }); } },
'timeStart': function(key, desc) { this.tests[key] = { 'start': new Date().getTime(), 'desc': desc }; },
'timeEnd': function(key) { this.tests[key].elapsed = new Date().getTime(); },
'report': function(id) { var i = 1; for ( var k in this.tests ) { var t = this.tests[k]; $(id).append('<div class="benchmark rounded"><div class="benchmark-result lt">' + (t.elapsed - t.start) + ' ms</div><div class="lt"><p class="benchmark-iteration">Benchmark case ' + i + '</p><p class="benchmark-title">' + t.desc + '</p></div></div>'); i++; }; }
};
gmAPI.init();
@@ -1,2 +0,0 @@
/*! jQuery Mobile vGit Build: SHA1: b49cc06499abf8f987cf90f35349cfac0918c939 <> Date: Tue Oct 2 11:22:34 2012 -0700 jquerymobile.com | jquery.org/license !*/
(function(a,b,c){typeof define=="function"&&define.amd?define(["jquery"],function(d){return c(d,a,b),d.mobile}):c(a.jQuery,a,b)})(this,document,function(a,b,c,d){(function(a,b,d){var e={};a.mobile=a.extend({},{version:"1.2.0",ns:"",subPageUrlKey:"ui-page",activePageClass:"ui-page-active",activeBtnClass:"ui-btn-active",focusClass:"ui-focus",ajaxEnabled:!0,hashListeningEnabled:!0,linkBindingEnabled:!0,defaultPageTransition:"fade",maxTransitionWidth:!1,minScrollBack:250,touchOverflowEnabled:!1,defaultDialogTransition:"pop",pageLoadErrorMessage:"Error Loading Page",pageLoadErrorMessageTheme:"e",phonegapNavigationEnabled:!1,autoInitializePage:!0,pushStateEnabled:!0,ignoreContentEnabled:!1,orientationChangeEnabled:!0,buttonMarkup:{hoverDelay:200},keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91},silentScroll:function(d){a.type(d)!=="number"&&(d=a.mobile.defaultHomeScroll),a.event.special.scrollstart.enabled=!1,setTimeout(function(){b.scrollTo(0,d),a(c).trigger("silentscroll",{x:0,y:d})},20),setTimeout(function(){a.event.special.scrollstart.enabled=!0},150)},nsNormalizeDict:e,nsNormalize:function(b){if(!b)return;return e[b]||(e[b]=a.camelCase(a.mobile.ns+b))},getInheritedTheme:function(a,b){var c=a[0],d="",e=/ui-(bar|body|overlay)-([a-z])\b/,f,g;while(c){f=c.className||"";if(f&&(g=e.exec(f))&&(d=g[2]))break;c=c.parentNode}return d||b||"a"},closestPageData:function(a){return a.closest(':jqmData(role="page"), :jqmData(role="dialog")').data("page")},enhanceable:function(a){return this.haveParents(a,"enhance")},hijackable:function(a){return this.haveParents(a,"ajax")},haveParents:function(b,c){if(!a.mobile.ignoreContentEnabled)return b;var d=b.length,e=a(),f,g,h;for(var i=0;i<d;i++){g=b.eq(i),h=!1,f=b[i];while(f){var j=f.getAttribute?f.getAttribute("data-"+a.mobile.ns+c):"";if(j==="false"){h=!0;break}f=f.parentNode}h||(e=e.add(g))}return e},getScreenHeight:function(){return b.innerHeight||a(b).height()}},a.mobile),a.fn.jqmData=function(b,c){var e;return typeof b!="undefined"&&(b&&(b=a.mobile.nsNormalize(b)),arguments.length<2||c===d?e=this.data(b):e=this.data(b,c)),e},a.jqmData=function(b,c,d){var e;return typeof c!="undefined"&&(e=a.data(b,c?a.mobile.nsNormalize(c):c,d)),e},a.fn.jqmRemoveData=function(b){return this.removeData(a.mobile.nsNormalize(b))},a.jqmRemoveData=function(b,c){return a.removeData(b,a.mobile.nsNormalize(c))},a.fn.removeWithDependents=function(){a.removeWithDependents(this)},a.removeWithDependents=function(b){var c=a(b);(c.jqmData("dependents")||a()).remove(),c.remove()},a.fn.addDependents=function(b){a.addDependents(a(this),b)},a.addDependents=function(b,c){var d=a(b).jqmData("dependents")||a();a(b).jqmData("dependents",a.merge(d,c))},a.fn.getEncodedText=function(){return a("<div/>").text(a(this).text()).html()},a.fn.jqmEnhanceable=function(){return a.mobile.enhanceable(this)},a.fn.jqmHijackable=function(){return a.mobile.hijackable(this)};var f=a.find,g=/:jqmData\(([^)]*)\)/g;a.find=function(b,c,d,e){return b=b.replace(g,"[data-"+(a.mobile.ns||"")+"$1]"),f.call(this,b,c,d,e)},a.extend(a.find,f),a.find.matches=function(b,c){return a.find(b,null,null,c)},a.find.matchesSelector=function(b,c){return a.find(c,null,null,[b]).length>0}})(a,this),function(a,b){var c=0,d=Array.prototype.slice,e=a.cleanData;a.cleanData=function(b){for(var c=0,d;(d=b[c])!=null;c++)try{a(d).triggerHandler("remove")}catch(f){}e(b)},a.widget=function(b,c,d){var e,f,g,h,i=b.split(".")[0];b=b.split(".")[1],e=i+"-"+b,d||(d=c,c=a.Widget),a.expr[":"][e]=function(b){return!!a.data(b,e)},a[i]=a[i]||{},f=a[i][b],g=a[i][b]=function(a,b){if(!this._createWidget)return new g(a,b);arguments.length&&this._createWidget(a,b)},a.extend(g,f,{version:d.version,_proto:a.extend({},d),_childConstructors:[]}),h=new c,h.options=a.widget.extend({},h.options),a.each(d,function(b,e){a.isFunction(e)&&(d[b]=function(){var a=function(){return c.prototype[b].apply(this,arguments)},d=function(a){return c.prototype[b].apply(this,a)};return function(){var b=this._super,c=this._superApply,f;return this._super=a,this._superApply=d,f=e.apply(this,arguments),this._super=b,this._superApply=c,f}}())}),g.prototype=a.widget.extend(h,{widgetEventPrefix:b},d,{constructor:g,namespace:i,widgetName:b,widgetBaseClass:e,widgetFullName:e}),f?(a.each(f._childConstructors,function(b,c){var d=c.prototype;a.widget(d.namespace+"."+d.widgetName,g,c._proto)}),delete f._childConstructors):c._childConstructors.push(g),a.widget.bridge(b,g)},a.widget.extend=function(c){var e=d.call(arguments,1),f=0,g=e.length,h,i;for(;f<g;f++)for(h in e[f])i=e[f][h],e[f].hasOwnProperty(h)&&i!==b&&(c[h]=a.isPlainObject(i)?a.widget.extend({},c[h],i):i);return c},a.widget.bridge=fuLine truncated
@@ -1,242 +0,0 @@
//SwipePlanes v1.2 jQuery Plugin by REMD
$.fn.swipePlanes = function(opciones){
return this.each(function(){
var randId = Math.round(100*Math.random()); ////IDENTIFICADOR ALEATORIO DE LA INSTANCIA//////////
//EL VISOR /////////////////////////////////////
this.onselectstart = function(){return false;};
this.unselectable = "on";
$(this).css('-moz-user-select', 'none');
$(this).css('-webkit-user-select', 'none');
$(this).css('overflow','hidden');
if($(this).css('position') != 'absolute')$(this).css('position','relative');
var anchoVisor = $(this).width();
var altoVisor = $(this).height;
var divVisor = this;
//El CONTENEDOR /////////////////////////////////////
var divContenedor;
var pagActual = 0;
divContenedor = $(this).children('div:first');
divContenedor.css('transition','none');
divContenedor.css('-moz-user-select', 'none');
divContenedor.css('-webkit-user-select', 'none');
divContenedor.css('position','relative');
divContenedor.css('left','0px');
//LAS PAGINAS /////////////////////////////////////////
var divPaginas;
var bufferPaginas = 0;
var metaPaginas = 0;
var metaPagNum = 0;
divPaginas = divContenedor.children('div,a');
divPaginas.css('display','inline-block');
divPaginas.css('float','left');
divPaginas.css('position','relative');
metaPaginas = new Array();
metaPaginas[0] = 0;
divPaginas.each(function(){
if((bufferPaginas+(this.offsetWidth)) > anchoVisor+metaPaginas[metaPagNum]){
if(bufferPaginas > 0)metaPagNum++;
metaPaginas[metaPagNum] = bufferPaginas;
}
bufferPaginas += (this.offsetWidth + parseInt($(this).css('margin-left'))+parseInt($(this).css('margin-right')));
});
metaPaginas[metaPagNum] -= anchoVisor - (bufferPaginas-metaPaginas[metaPagNum]); //Ajuste �ltimo salto
divContenedor.css('width',bufferPaginas+'px'); //Ajuste Contenedor al tamano de las paginas
generarControles($(this),metaPagNum);
//LOS EVENTOS ////////////////////////////////////////////
var iX = 0,aX = 0,fX = 0; //Manejo de coordenadas
var drag = 0,t = 0,ms = 0,metaEvento,dX = 0; //Manejo del entorno/tiempo
$(this).bind('touchstart',function(event){
clearInterval(t);
if(event.pageX)iX = event.pageX;
if(event.originalEvent.touches)iX = event.originalEvent.touches[0].pageX;
divContenedor.css('transition','none');
drag = 1;
ms = 0;
metaEvento = 'click';
t = setInterval(function(){ms++;},1);
});
$(this).bind('touchmove',function(event){
if(event.pageX)aX = event.pageX;
if(event.originalEvent.touches)aX = event.originalEvent.touches[0].pageX;
dX = Math.abs(aX - iX);
if(dX > 50)event.preventDefault();
if(drag && dX > 50){
divContenedor.css('left',(((metaPaginas[pagActual]*-1)+(aX - iX)))+'px');
}
});
$(this).bind('touchend touchcancel touchleave',function(event){
if(drag && dX > 20){
drag = 0;
console.log(metaPaginas);
dX = Math.abs(fX - iX);
clearInterval(t);
if(event.pageX)fX = event.pageX;
if(event.originalEvent.touches)fX = aX;
if((iX-fX) > 0 && ms < 100 && dX > 50)metaEvento = 'swipeLeft';
if((iX-fX) <= 0 && ms < 100 && dX > 50)metaEvento = 'swipeRight';
if((iX-fX) > 0 && ms > 100 && dX > 50)metaEvento = 'moveLeft';
if((iX-fX) <= 0 && ms > 100 && dX > 50)metaEvento = 'moveRight';
if(dX <= 50)metaEvento = 'click';
switch(metaEvento){
case 'swipeLeft':
if(pagActual < metaPagNum){pagActual++;}
break;
case 'moveLeft':
if(pagActual < metaPagNum && dX > (Math.abs(anchoVisor/2))){pagActual++;}
break;
case 'swipeRight':
if(pagActual > 0){pagActual--;}
break;
case 'moveRight':
if(pagActual > 0 && dX > (Math.abs(anchoVisor/2))){pagActual--;}
break;
}
ms = 0; dX = 0; iX = 0; aX = 0; fX = 0; metaEvento = '';
irPagina(pagActual);
}
});
//EVENTOS CONTROLES /////////////////////////////////////////
$('.'+randId+'swipePlanesMiniPag').click(function(){
pagActual = $(this).attr('mpg');
irPagina();
});
$('.'+randId+'swipePlanesRowLeft').click(function(e){
e.stopPropagation();
e.preventDefault();
if(pagActual > 0)pagActual--;
irPagina();
});
$('.'+randId+'swipePlanesRowRight').click(function(e){
e.preventDefault();
e.stopPropagation();
if(pagActual < metaPagNum)pagActual++;
irPagina();
});
$(this).bind('mousemove',function(){
$('.'+randId+'swipePlanesRowLeft').css('display','block');
$('.'+randId+'swipePlanesRowRight').css('display','block');
$('.'+randId+'swipePlanesRowLeft').css('opacity','1');
$('.'+randId+'swipePlanesRowRight').css('opacity','1');
});
$('.'+randId+'swipePlanesRowLeft').bind('mousemove',function(){
$('.'+randId+'swipePlanesRowLeft').css('opacity','1');
$('.'+randId+'swipePlanesRowRight').css('opacity','1');
});
$('.'+randId+'swipePlanesRowRight').bind('mousemove',function(){
$('.'+randId+'swipePlanesRowLeft').css('opacity','1');
$('.'+randId+'swipePlanesRowRight').css('opacity','1');
});
$(this).mouseout(function(){
$('.'+randId+'swipePlanesRowLeft').css('opacity','0');
$('.'+randId+'swipePlanesRowRight').css('opacity','0');
});
//CONTROLES //////////////////////////////////////////////
function generarControles(divVisor,metaPagNum){
var i = 0;
var miniPaginasHtml = '';
var style = '';
for(i;i <= metaPagNum; i++){
if(!i)style='background:#CECECE';
else style='';
miniPaginasHtml += '<div mpg="'+i+'" style="'+style+'" class="'+randId+'swipePlanesMiniPag"></div>';
}
// <div class="'+randId+'swipePlanesRowLeft"></div><div class="'+randId+'swipePlanesRowRight"></div>
var controlesHtml = '<div class="'+randId+'swipePlanesPaginator">'+miniPaginasHtml+'</div>';
divVisor.append(controlesHtml);
$('.'+randId+'swipePlanesMiniPag').css('display','inline-block');
$('.'+randId+'swipePlanesMiniPag').css('width','7px');
$('.'+randId+'swipePlanesMiniPag').css('height','7px');
$('.'+randId+'swipePlanesMiniPag').css('margin-left','2px');
$('.'+randId+'swipePlanesMiniPag').css('margin-right','2px');
$('.'+randId+'swipePlanesMiniPag').css('border','1px solid #CECECE');
$('.'+randId+'swipePlanesMiniPag').css('border-radius','4px');
$('.'+randId+'swipePlanesMiniPag').css('cursor','pointer');
$('.'+randId+'swipePlanesRowLeft').css('background-image','url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABkCAYAAADE6GNbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAKwwAACsMBNCkkqwAAABx0RVh0U29mdHdhcmUAQWRvYmUgRmlyZXdvcmtzIENTNui8sowAAAAWdEVYdENyZWF0aW9uIFRpbWUAMTAvMTkvMTJlCtGpAAABaElEQVR4nO3cS3HEMBRE0atU1oaURTCIwxiSh4NQBNIQcDDEfp/OVF8AKp3yR5IXHsD3GIP/3HmefI4xOI6jey632vedj+5JRGWIWoaoZYhahqhliFqGqGWIWoaoZYhahqhliFqGqGWIWoZENed8RIzTCplzPrZt+4oYqw0SiYAmSDQCGiAZCCiGZCGgEJKJgCJINgIKIBUISIZUISARUomAJEg1AhIgHQgIhnQhIBDSiYAgSDcCAiAKCLgJUUHADYgSAi5C1BBwAaKIAIGPD1H9GbLWer5er5+Mydzp0hVRxFy+tdQwt54RJczth10FE/LWUsCEvX67MaHrSCcmfEHswqSs7B2YtC1KNSZ1r1WJSd80VmFKdr8VmLJtfDam9DySiSk/WGVhWk6IGZi2o240pvXMHolp//iw1npGjNMOicoQtQxRyxC1DFHLELUMUcsQtQxRyxC1DFHLELUMUettIIM3+XXbL64qrlAHZEgkAAAAAElFTkSuQmCC)');
$('.'+randId+'swipePlanesRowLeft').css('position','absolute');
$('.'+randId+'swipePlanesRowLeft').css('width','50px');
$('.'+randId+'swipePlanesRowLeft').css('height','100px');
$('.'+randId+'swipePlanesRowLeft').css('cursor','pointer');
$('.'+randId+'swipePlanesRowLeft').css('left','0px');
$('.'+randId+'swipePlanesRowLeft').css('top',((divVisor.height()/2)-50)+'px');
$('.'+randId+'swipePlanesRowLeft').css('z-index','909');
$('.'+randId+'swipePlanesRowLeft').css('display','none');
$('.'+randId+'swipePlanesRowLeft').css('box-shadow','0 1px 3px rgba(0, 0, 0, 0.3);');
$('.'+randId+'swipePlanesRowRight').css('background-image','url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABkCAYAAADE6GNbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAKwwAACsMBNCkkqwAAABx0RVh0U29mdHdhcmUAQWRvYmUgRmlyZXdvcmtzIENTNui8sowAAAAWdEVYdENyZWF0aW9uIFRpbWUAMTAvMTkvMTJlCtGpAAABXklEQVR4nO3cvW2EQBRF4TPWxpTkwDXQw1IS7oEqXBINsKlTM+/nenVPDuKTYOZNwgC+xhj8567r4jHGYN/37meZats2ProfIipD1DJELUPUMkQtQ9QyRC1D1DJELUPUMkQtQ9QyRC1D1DLkd+u6PiPuM1MIZFmWz25M2KvVjQn9Rjox4R97FyZl1erApC2/1ZjUfaQSk74hVmFKdvYKTNmIko0pnbUyMeVDYxamZfrNwLSN8dGY1vNIJKb9YBWFaYdADEYCAvMYGQjMYaQgcB8jB7mbHOQ8z5/jOL7/ep0U5C4ChCAzCBCBzCJAABKBgGZIFAIaIZEIaIJEI6ABkoGAYkgWAgohmQgogmQjoABSgYBkSBUCEiGVCEiCVCMgAdKBgGBIFwICIZ0ICIJ0IyAI0o0AgYNVVIaoZYhahqhliFqGqGWIWoaoZYhahqhliFqGqGWIWm8DGbzJr9teHYWuULzgkDAAAAAASUVORK5CYII=)');
$('.'+randId+'swipePlanesRowRight').css('position','absolute');
$('.'+randId+'swipePlanesRowRight').css('width','50px');
$('.'+randId+'swipePlanesRowRight').css('height','100px');
$('.'+randId+'swipePlanesRowRight').css('cursor','pointer');
$('.'+randId+'swipePlanesRowRight').css('right','0px');
$('.'+randId+'swipePlanesRowRight').css('top',((divVisor.height()/2)-50)+'px');
$('.'+randId+'swipePlanesRowRight').css('z-index','909');
$('.'+randId+'swipePlanesRowRight').css('display','none');
$('.'+randId+'swipePlanesRowRight').css('box-shadow','0 1px 3px rgba(0, 0, 0, 0.3);');
$('.'+randId+'swipePlanesPaginator').css('position','absolute');
$('.'+randId+'swipePlanesPaginator').css('padding','0px 4px');
$('.'+randId+'swipePlanesPaginator').css('top','10px');
$('.'+randId+'swipePlanesPaginator').css('box-shadow','0 1px 3px rgba(0, 0, 0, 0.3);');
$('.'+randId+'swipePlanesPaginator').css('border-radius','4px');
$('.'+randId+'swipePlanesPaginator').css('left',((divVisor.width()/2)-($('.'+randId+'swipePlanesPaginator').width()/2))+'px');
}
function irPagina(){
divContenedor.css('transition','left 500ms');
divContenedor.css('left',((metaPaginas[pagActual])*-1)+'px');
$('.'+randId+'swipePlanesMiniPag').css('background','');
$('.'+randId+'swipePlanesMiniPag[mpg='+pagActual+']').css('background','#CECECE');
}
});
};
-373
View File
@@ -1,373 +0,0 @@
/*!
* jQuery FN Google Map 3.0-rc
* http://code.google.com/p/jquery-ui-map/
* Copyright (c) 2010 - 2012 Johan Säll Larsson
* Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php
*/
( function($) {
/**
* @param name:string
* @param prototype:object
*/
$.a = function(name, prototype) {
var namespace = name.split('.')[0];
name = name.split('.')[1];
$[namespace] = $[namespace] || {};
$[namespace][name] = function(options, element) {
if ( arguments.length ) {
this._setup(options, element);
}
};
$[namespace][name].prototype = $.extend({
'namespace': namespace,
'pluginName': name
}, prototype);
$.fn[name] = function(options) {
var isMethodCall = typeof options === "string",
args = Array.prototype.slice.call(arguments, 1),
returnValue = this;
if ( isMethodCall && options.substring(0, 1) === '_' ) {
return returnValue;
}
this.each(function() {
var instance = $.data(this, name);
if (!instance) {
instance = $.data(this, name, new $[namespace][name](options, this));
}
if (isMethodCall) {
returnValue = instance[options].apply(instance, args);
}
});
return returnValue;
};
};
$.a('ui.gmap', {
/**
* Map options
* @see http://code.google.com/intl/sv-SE/apis/maps/documentation/javascript/reference.html#MapOptions
*/
options: {
mapTypeId: 'roadmap',
zoom: 5
},
/**
* Get or set options
* @param key:string
* @param options:object
* @return object
*/
option: function(key, options) {
if (options) {
this.options[key] = options;
this.get('map').set(key, options);
return this;
}
return this.options[key];
},
/**
* Setup plugin basics,
* @param options:object
* @param element:node
*/
_setup: function(options, element) {
this.el = element;
options = options || {};
jQuery.extend(this.options, options, { 'center': this._latLng(options.center) });
this._create();
if ( this._init ) { this._init(); }
},
/**
* Instanciate the Google Maps object
*/
_create: function() {
var self = this;
this.instance = { 'map': new google.maps.Map(self.el, self.options), 'markers': [], 'overlays': [], 'services': [] };
google.maps.event.addListenerOnce(self.instance.map, 'bounds_changed', function() { $(self.el).trigger('init', self.instance.map); });
self._call(self.options.callback, self.instance.map);
},
/**
* Adds a latitude longitude pair to the bounds.
* @param position:google.maps.LatLng/string
*/
addBounds: function(position) {
var bounds = this.get('bounds', new google.maps.LatLngBounds());
bounds.extend(this._latLng(position));
this.get('map').fitBounds(bounds);
return this;
},
/**
* Helper function to check if a LatLng is within the viewport
* @param marker:google.maps.Marker
*/
inViewport: function(marker) {
var bounds = this.get('map').getBounds();
return (bounds) ? bounds.contains(marker.getPosition()) : false;
},
/**
* Adds a custom control to the map
* @param panel:jquery/node/string
* @param position:google.maps.ControlPosition
* @see http://code.google.com/intl/sv-SE/apis/maps/documentation/javascript/reference.html#ControlPosition
*/
addControl: function(panel, position) {
this.get('map').controls[position].push(this._unwrap(panel));
return this;
},
/**
* Adds a Marker to the map
* @param markerOptions:google.maps.MarkerOptions
* @param callback:function(map:google.maps.Map, marker:google.maps.Marker) (optional)
* @return $(google.maps.Marker)
* @see http://code.google.com/intl/sv-SE/apis/maps/documentation/javascript/reference.html#MarkerOptions
*/
addMarker: function(markerOptions, callback) {
markerOptions.map = this.get('map');
markerOptions.position = this._latLng(markerOptions.position);
var marker = new (markerOptions.marker || google.maps.Marker)(markerOptions);
var markers = this.get('markers');
if ( marker.id ) {
markers[marker.id] = marker;
} else {
markers.push(marker);
}
if ( marker.bounds ) {
this.addBounds(marker.getPosition());
}
this._call(callback, markerOptions.map, marker);
return $(marker);
},
/**
* Clears by type
* @param ctx:string e.g. 'markers', 'overlays', 'services'
*/
clear: function(ctx) {
this._c(this.get(ctx));
this.set(ctx, []);
return this;
},
_c: function(obj) {
for ( var property in obj ) {
if ( obj.hasOwnProperty(property) ) {
if ( obj[property] instanceof google.maps.MVCObject ) {
google.maps.event.clearInstanceListeners(obj[property]);
if ( obj[property].setMap ) {
obj[property].setMap(null);
}
} else if ( obj[property] instanceof Array ) {
this._c(obj[property]);
}
obj[property] = null;
}
}
},
/**
* Returns the objects with a specific property and value, e.g. 'category', 'tags'
* @param ctx:string in what context, e.g. 'markers'
* @param options:object property:string the property to search within, value:string, operator:string (optional) (AND/OR)
* @param callback:function(marker:google.maps.Marker, isFound:boolean)
*/
find: function(ctx, options, callback) {
var obj = this.get(ctx);
options.value = $.isArray(options.value) ? options.value : [options.value];
for ( var property in obj ) {
if ( obj.hasOwnProperty(property) ) {
var isFound = false;
for ( var value in options.value ) {
if ( $.inArray(options.value[value], obj[property][options.property]) > -1 ) {
isFound = true;
} else {
if ( options.operator && options.operator === 'AND' ) {
isFound = false;
break;
}
}
}
callback(obj[property], isFound);
}
}
return this;
},
/**
* Returns an instance property by key. Has the ability to set an object if the property does not exist
* @param key:string
* @param value:object(optional)
*/
get: function(key, value) {
var instance = this.instance;
if ( !instance[key] ) {
if ( key.indexOf('>') > -1 ) {
var e = key.replace(/ /g, '').split('>');
for ( var i = 0; i < e.length; i++ ) {
if ( !instance[e[i]] ) {
if (value) {
instance[e[i]] = ( (i + 1) < e.length ) ? [] : value;
} else {
return null;
}
}
instance = instance[e[i]];
}
return instance;
} else if ( value && !instance[key] ) {
this.set(key, value);
}
}
return instance[key];
},
/**
* Triggers an InfoWindow to open
* @param infoWindowOptions:google.maps.InfoWindowOptions
* @param marker:google.maps.Marker (optional)
* @param callback:function (optional)
* @see http://code.google.com/intl/sv-SE/apis/maps/documentation/javascript/reference.html#InfoWindowOptions
*/
openInfoWindow: function(infoWindowOptions, marker, callback) {
var iw = this.get('iw', infoWindowOptions.infoWindow || new google.maps.InfoWindow);
iw.setOptions(infoWindowOptions);
iw.open(this.get('map'), this._unwrap(marker));
this._call(callback, iw);
return this;
},
/**
* Triggers an InfoWindow to close
*/
closeInfoWindow: function() {
if ( this.get('iw') != null ) {
this.get('iw').close();
}
return this;
},
/**
* Sets an instance property
* @param key:string
* @param value:object
*/
set: function(key, value) {
this.instance[key] = value;
return this;
},
/**
* Refreshes the map
*/
refresh: function() {
var map = this.get('map');
var latLng = map.getCenter();
$(map).triggerEvent('resize');
map.setCenter(latLng);
return this;
},
/**
* Destroys the plugin.
*/
destroy: function() {
this.clear('markers').clear('services').clear('overlays')._c(this.instance);
jQuery.removeData(this.el, this.name);
},
/**
* Helper method for calling a function
* @param callback
*/
_call: function(callback) {
if ( callback && $.isFunction(callback) ) {
callback.apply(this, Array.prototype.slice.call(arguments, 1));
}
},
/**
* Helper method for google.maps.Latlng
* @param latLng:string/google.maps.LatLng
*/
_latLng: function(latLng) {
if ( !latLng ) {
return new google.maps.LatLng(0.0, 0.0);
}
if ( latLng instanceof google.maps.LatLng ) {
return latLng;
} else {
latLng = latLng.replace(/ /g,'').split(',');
return new google.maps.LatLng(latLng[0], latLng[1]);
}
},
/**
* Helper method for unwrapping jQuery/DOM/string elements
* @param obj:string/node/jQuery
*/
_unwrap: function(obj) {
return (!obj) ? null : ( (obj instanceof jQuery) ? obj[0] : ((obj instanceof Object) ? obj : $('#'+obj)[0]) )
}
});
jQuery.fn.extend( {
triggerEvent: function(eventType) {
google.maps.event.trigger(this[0], eventType);
return this;
},
addEventListener: function(eventType, eventDataOrCallback, eventCallback) {
if ( google.maps && this[0] instanceof google.maps.MVCObject ) {
google.maps.event.addListener(this[0], eventType, eventDataOrCallback);
} else {
if (eventCallback) {
this.bind(eventType, eventDataOrCallback, eventCallback);
} else {
this.bind(eventType, eventDataOrCallback);
}
}
return this;
}
/*removeEventListener: function(eventType) {
if ( google.maps && this[0] instanceof google.maps.MVCObject ) {
if (eventType) {
google.maps.event.clearListeners(this[0], eventType);
} else {
google.maps.event.clearInstanceListeners(this[0]);
}
} else {
this.unbind(eventType);
}
return this;
}*/
});
jQuery.each(('click rightclick dblclick mouseover mouseout drag dragend').split(' '), function(i, name) {
jQuery.fn[name] = function(a, b) {
return this.addEventListener(name, a, b);
}
});
} (jQuery) );
@@ -1,130 +0,0 @@
<%#= encoding: utf-8 %>
// function slideshow() {
// var $globalW = $(".global").width(),
// $slideImg = $(".slideImg"),
// $slidebanner = $(".slidebanner"),
// $slideshow = $(".slideshow"),
// $slideImgOW = $slideImg.width(),
// $slideImgOH = $slideImg.height();
// $slideImg.css({
// "widht": $globalW,
// "height": Math.floor(($globalW/$slideImgOW)*$slideImgOH),
// });
// $slideshow.css({
// "width": $globalW,
// "height": Math.floor(($globalW/$slideImgOW)*$slideImgOH),
// });
// alert(Math.floor(($globalW/$slideImgOW)*$slideImgOH))
// }
$('#index').live('pageinit',function(){
var $globalW = $(window).width(),
$slideshow = $(".slideshow");
$slideshow.css({
"width": $globalW, "height": Math.floor($globalW/720*240)
});
$(".slideImg").muImageResize({width: $globalW, height: Math.floor($globalW/720*240)});
$(this).find(".newpic img").muImageResize({width: 280, height: 200});
$('.slideshow').cycle({
fx: $effect,
timeout: $timeout
});
$(".newlist").css({
"width" : $(".newitem").outerWidth()*(Math.floor($globalW/$(".newitem").outerWidth()))+30,
})
// var oc_timer;
// clearTimeout(oc_timer);
// oc_timer = setTimeout(function () {
// $('.newlist').swipePlanes();
// }, 1000);
});
$('#announcement_content').live('pageinit',function(){
$(this).find(".newpic img").muImageResize({width: 320, height: 220});
});
$('#map').live('pageinit', function() {
var mobileDemo = { 'center': $map_center, 'zoom': $map_zoom };
var $windowH = $(window).height();
$("#map_canvas").css({
'height' : $windowH,
})
gmAPI.add('basic_map', function() {
$('#map_canvas').gmap({'center': mobileDemo.center, 'zoom': mobileDemo.zoom, 'disableDefaultUI':false, 'callback': function() {
var self = this;
self.addMarker({'position': this.get('map').getCenter() }).click(function() {
self.openInfoWindow({ 'content': $info }, this);
});
}});
}).load('basic_map');
});
$('#map').live('pageshow', function() {
gmAPI.add('basic_map', function() { $('#map_canvas').gmap('refresh'); }).load('basic_map');
});
$(document).bind('pagebeforehide',function(){
$("section.main-menu").removeClass("expanded");
});
$(document).bind("ready", function(){
// $(".openmenu").live("tap", function(){
// $("section.main-menu").toggleClass("expanded");
// return!1
// });
$("body").delegate(".openmenu","vclick",function(){
$("section.main-menu").toggleClass("expanded");
return!1
});
// alert(navigator.userAgent)
// $(".newpic img").muImageResize({width: 280, height: 100});
// $('.newlist').swipePlanes();
});
// $(window).resize(function(){
// alert("Resize");
// $(".slidebanner").removeAttr("style");
// $(".slidebanner").find("div").removeAttr("style");
// $(".slideImg").removeAttr("style");
// var $globalW = $(window).width(),
// $slideshow = $(".slideshow");
// $slideshow.css({
// "width": $globalW, "height": Math.floor($globalW/720*240)
// });
// $(".slideImg").muImageResize({width: $globalW, height: Math.floor($globalW/720*240)});
// $('.slideshow').cycle({
// fx:'scrollLeft',
// timeout: 6000,
// });
// });
$(window).bind("orientationchange", function(){
var oc_timer;
clearTimeout(oc_timer);
oc_timer = setTimeout(function () {
$(".slidebanner").removeAttr("style");
$(".slidebanner").find("div").removeAttr("style");
$(".slideImg").removeAttr("style");
// $(".newlist").removeAttr("style");
// $(".newlist").find(".clear").removeAttr("style");
// $(".newitem").removeAttr("style");
// $(".newlist").find(".clear").nextAll("div").remove();
var $globalW = $(window).width(),
$slideshow = $(".slideshow"),
$windowH = $(window).height();
$slideshow.css({
"width": $globalW, "height": Math.floor($globalW/720*240)
});
$(".slideImg").muImageResize({width: $globalW, height: Math.floor($globalW/720*240)});
$('.slideshow').cycle({
fx: $effect,
timeout: $timeout
});
$(".newlist").css({
"width" : $(".newitem").outerWidth()*(Math.floor($globalW/$(".newitem").outerWidth()))+30,
})
$("#map_canvas").css({
'height' : $windowH,
})
// $('.newlist').swipePlanes();
}, 500);
});
+2 -2
View File
@@ -3,5 +3,5 @@
//= require basic/bootstrap
//= require kernel
//= require lib/jquery.preload.min.js
//= require cycle2
//= require lib/jquery.preload-min.js
//= require lib/jquery.cycle.all.latest.js
+1 -1
View File
@@ -1,5 +1,5 @@
//= require basic
//= require jquery.ui.sortable
//= require lib/jquery-ui-1.10.2.custom.min.js
//= require lib/jquery.ui.touch-punch.min.js
//= require lib/jquery.mjs.nestedSortable.js
//= require lib/items/items
+5 -5
View File
@@ -1,17 +1,17 @@
.banner_nav {
#banner_nav {
position: absolute;
z-index: 10;
bottom: 0;
margin-right: 5px;
right: 0;
}
.banner_nav>li {
#banner_nav>li {
float: left;
display: inline-block;
*display: inline;
}
.banner_nav>li>a {
#banner_nav>li>a {
display:block;
width: 10px;
height: 10px;
@@ -25,11 +25,11 @@
text-indent: -9999px;
box-shadow: 0 0 5px rgba(0,0,0,.7);
}
.banner_nav>li>a:hover {
#banner_nav>li>a:hover {
opacity: 1;
filter: alpha(opacity = 100);
}
.banner_nav>li.activeSlide>a {
#banner_nav>li.activeSlide>a {
opacity: 1;
filter: alpha(opacity = 100);
}
+29 -158
View File
@@ -83,7 +83,6 @@ legend {
min-width: 61px;
z-index: 1030;
position: fixed;
padding-top: 40px;
background-color: #171717;
-webkit-box-shadow: inset -1px 0px 10px #000000;
-moz-box-shadow: inset -1px 0px 10px #000000;
@@ -92,14 +91,12 @@ legend {
}
#sidebar #sidebar-menu {
position: absolute;
top: 85px;
top: 88px;
bottom: 0;
z-index: 0;
z-index: 1;
display: block;
width: 61px;
}
#sidebar #sidebar-menu.nano {
top: 0;
/*overflow: auto;*/
}
#sidebar .scroller {
position: absolute;
@@ -123,12 +120,16 @@ legend {
list-style: none;
}
#sidebar > h2.position {
top: 40px;
margin: 0;
width: 61px;
color: #FFFFFF;
font-weight: normal;
font-size: 2.4em;
line-height: 47px;
line-height: 46px\9;
text-align: center;
position: relative;
position: absolute;
background-color: #08c;
background-image: -moz-linear-gradient(top, #08c, #006091);
background-image: -ms-linear-gradient(top, #08c, #006091);
@@ -157,20 +158,24 @@ legend {
}
#sidebar > h2.position a {
color: #FFFFFF;
padding: 6px 6px 5px;
text-decoration: none;
display: inline-block;
-webkit-text-shadow: 0px -1px 0px #333333;
-moz-text-shadow: 0px -1px 0px #333333;
-o-text-shadow: 0px -1px 0px #333333;
text-shadow: 0px -1px 0px #333333;
}
#sidebar > h2.position a i {
line-height: 45px;
}
#sidebar .sidebar-nav > li {
min-width: 61px;
height: 45px;
}
#sidebar .sidebar-nav > li.active span {
#sidebar .sidebar-nav > li.active {
font-size: 1.2em;
}
#sidebar .sidebar-nav > li.active .sub-nav-block {
display: block;
}
#sidebar .sidebar-nav > li.active > a > span {
color: #FFFFFF;
cursor: pointer;
-webkit-text-shadow: 0px -1px 0px #636363;
@@ -178,7 +183,8 @@ legend {
-o-text-shadow: 0px -1px 0px #636363;
text-shadow: 0px -1px 0px #636363;
}
#sidebar .sidebar-nav > li span {
#sidebar .sidebar-nav > li > a > span {
padding: 10px;
color: #B0B0B0;
display: block;
-webkit-text-shadow: 0px 1px 0px #000000;
@@ -186,15 +192,8 @@ legend {
-o-text-shadow: 0px 1px 0px #000000;
text-shadow: 0px 1px 0px #000000;
}
#sidebar .sidebar-nav > li a {
display: block;
}
#sidebar .sidebar-nav > li i {
font-size: 1.6em;
line-height: 45px;
}
#sidebar .sidebar-nav > li.active i {
font-size: 2.2em;
#sidebar .sidebar-nav > li > a > span > i {
font-size: 1.7em;
}
#sidebar .sub-nav-block-list {
top: 40px;
@@ -275,7 +274,7 @@ legend {
}
#sidebar .sub-nav-arrow {
left: 53px;
top: -16px;
top: -10px;
width: 0px;
height: 0px;
z-index: -1;
@@ -283,6 +282,7 @@ legend {
border-style: solid;
border-width: 8px 8px 8px 0;
border-color: transparent #0088CC transparent transparent;
display: none\9; /* 用IE的去死 */
}
@@ -300,15 +300,14 @@ legend {
position: absolute;
z-index: 100;
width: 100%;
border-radius: 50%/1px;
background-color: rgba(0, 136, 204, .6);
border-radius: 1px;
background-color: rgba(0, 136, 204, .3);
}
/* Main Wrap */
#main-wrap {
padding-top: 40px;
position: relative;
}
#main-wrap .wrap-inner {
padding: 60px 20px 20px;
@@ -420,7 +419,6 @@ legend {
/* Search Clear */
.searchClear {
position: relative;
display: inline-block;
}
.searchClear .icon-search {
position: absolute;
@@ -522,9 +520,10 @@ legend {
padding: 0px 5px;
position: absolute;
z-index: 9999;
max-width: 300px;
max-width: 500px;
border-radius: 3px;
background-color: #0088CC;
white-space: nowrap;
}
#sideset .ui-tooltip.sidebar-tooltip:after {
display: none;
@@ -534,9 +533,10 @@ legend {
padding: 0px 5px;
position: absolute;
z-index: 9999;
max-width: 300px;
max-width: 500px;
border-radius: 3px;
background-color: #000000;
white-space: nowrap;
}
.ui-tooltip:after {
content: '';
@@ -551,135 +551,6 @@ legend {
border-color: #000000 transparent transparent transparent;
}
/* Sign In */
#sign-in {
background-color: #F3F3F3;
background-repeat: no-repeat;
background : -webkit-radial-gradient(center center,circle cover, #F3F3F3 10%, #DBDBDB 100%);
background : -moz-radial-gradient(center center,circle cover, #F3F3F3 10%, #DBDBDB 100%);
background : -o-radial-gradient(center center,circle cover, #F3F3F3 10%, #DBDBDB 100%);
background : -ms-radial-gradient(center center,circle cover, #F3F3F3 10%, #DBDBDB 100%);
background : -radial-gradient(center center,circle cover, #F3F3F3 10%, #DBDBDB 100%);
}
.sign-in {
text-align: center;
position: relative;
width: 300px;
margin: 150px auto 0;
}
.sign-in .other-sign-in {
display: none;
}
.sign-in .login-logo {
margin: 0;
padding-bottom: 15px;
border-bottom: 1px solid #ededed;
}
.sign-in .alert {
box-shadow: 0 3px 10px #CBCBCB;
text-align: left;
}
.sign-in .form {
background-color: #FFF;
box-shadow: 0 10px 20px #CBCBCB;
padding: 15px;
margin-bottom: 20px;
}
.sign-in .form-block {
overflow: hidden;
}
.sign-in .form-list {
width: 555px;
}
.sign-in .content {
float: left;
margin-bottom: 0;
position: relative;
}
.sign-in .content + .content {
margin-left: 15px;
}
.sign-in .control-group {
position: relative;
width: 270px;
margin: 0;
}
.sign-in .control-group label {
position: absolute;
top: 0;
left: 0;
width: 39px;
height: 40px;
line-height: 40px;
margin: 0;
color: #5C5C5C;
}
.sign-in .control-group input {
width: 222px;
height: 30px;
padding: 4px 6px 4px 40px;
margin-bottom: 25px;
}
.sign-in .btn {
padding: 4px 0;
display: block;
width: 100%;
margin-bottom: 10px;
}
.sign-in .other-sign-in {
position: relative;
margin-top: 20px;
margin-bottom: 30px;
padding-bottom: 20px;
border-bottom: 1px solid #ededed;
}
.sign-in .other-sign-in p {
position: absolute;
width: 30px;
height: 30px;
background-color: #FFF;
padding: 0 10px;
margin-bottom: 0;
margin-left: -25px;
line-height: 30px;
left: 50%;
bottom: -15px;
font-size: 1.3em;
color: #b1b1b1;
}
.sign-in .checkbox {
position: absolute;
text-align: left;
bottom: 37px;
}
.sign-in .switchboard {
color: #08C;
cursor: pointer;
}
.sign-in .switchboard span,
.sign-in .switchboard.active i {
display: inline;
}
.sign-in .switchboard.active span,
.sign-in .switchboard i {
display: none;
}
.register {
box-shadow: inset 0 5px 5px #E0E0E0;
background-color: #eee;
padding: 15px;
margin: 15px -15px -15px;
}
.register .btn {
margin: 0;
}
.have-other-sign-in {
margin: 80px auto 0;
}
.have-other-sign-in .other-sign-in {
display: block;
}
/* IE go die */
:root #sidebar .sub-nav-block:before {
display: block\9;
@@ -19,18 +19,6 @@
margin-left: 0;
}
}
.form_fix {
textarea {
margin-bottom: 12px;
}
input[type="text"] {
margin-left: 0;
margin-top: 0;
}
input[type="text"] + input {
margin-top: 12px;
}
}
// fixed width column with 12px gutter
// 276px width for 8 columns
// 420px width for 12 columns
@@ -323,29 +323,6 @@ a.admtxt.admbg2:hover {
float: left; }
.docklist .d_cate:hover .dock_child {
display: block; }
.disable {
opacity: .3;
}
.disable a {
cursor: not-allowed;
}
.private {
position: relative;
padding-right: 10px;
width: 300px;
opacity: .3 !important;
}
.private:after {
content: "\e073";
display: inline-block;
font-family: 'entypo';
font-size: 1.5em;
position: absolute;
right: 0;
text-align: center;
text-decoration: inherit;
top: 5px;
}
.fn_des.admtxt {
line-height: 60px;
@@ -737,8 +714,7 @@ a.admtxt.admbg2:hover {
/* list item */
.list_t_item {
overflow: hidden;
height: 100px; }
overflow: hidden; }
.list_t_title {
padding-bottom: 6px;
@@ -772,8 +748,7 @@ a.admtxt.admbg2:hover {
-webkit-text-size-adjust: none; }
.list_item_function a :first-child {
margin-left: 0; }
.datalist_item:hover .list_item_function,
.list_t_item:hover .list_item_function {
.datalist_item:hover .list_item_function {
bottom: 0; }
/* App */
@@ -125,14 +125,6 @@
}
#list-view .checkbox-card li {
-webkit-transition: none;
-moz-transition: none;
-o-transition: none;
transition: none;
}
/* Responsive */
@media (max-width: 767px) {
@@ -1,52 +0,0 @@
/* Based on the theme at http://bonsaiden.github.com/JavaScript-Garden */
/*<!--breakpoint-->*/
.breakpoints {width: .8em;}
.breakpoint { color: #822; }
/*<!--match-->*/
span.CodeMirror-matchhighlight { background: #494949 }
.CodeMirror-focused span.CodeMirror-matchhighlight { background: #314D67 !important; }
/*<!--activeline-->*/
.activeline {background: #253540 !important;}
.cm-s-midnight.CodeMirror {
background: #0F192A;
color: #D1EDFF;
}
.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}
.cm-s-midnight div.CodeMirror-selected {background: #314D67 !important;}
.cm-s-midnight .CodeMirror-gutters {background: #0F192A; border-right: 1px solid;}
.cm-s-midnight .CodeMirror-linenumber {color: #D0D0D0;}
.cm-s-midnight .CodeMirror-cursor {
border-left: 1px solid #F8F8F0 !important;
}
.cm-s-midnight span.cm-comment {color: #428BDD;}
.cm-s-midnight span.cm-atom {color: #AE81FF;}
.cm-s-midnight span.cm-number {color: #D1EDFF;}
.cm-s-midnight span.cm-property, .cm-s-tropicaleve span.cm-attribute {color: #A6E22E;}
.cm-s-midnight span.cm-keyword {color: #E83737;}
.cm-s-midnight span.cm-string {color: #1DC116;}
.cm-s-midnight span.cm-variable {color: #FFAA3E;}
.cm-s-midnight span.cm-variable-2 {color: #FFAA3E;}
.cm-s-midnight span.cm-def {color: #4DD;}
.cm-s-midnight span.cm-error {background: #F92672; color: #F8F8F0;}
.cm-s-midnight span.cm-bracket {color: #D1EDFF;}
.cm-s-midnight span.cm-tag {color: #008;}
.cm-s-midnight span.cm-link {color: #AE81FF;}
.cm-s-midnight .CodeMirror-matchingbracket {
text-decoration: underline;
color: white !important;
}
.typ { color: #FFAA3E; }
.atn { color: #606; }
.atv { color: #080; }
.dec { color: #606; }
+18 -20
View File
@@ -1,23 +1,21 @@
/*
*= require 'lib/codemirror/theme/ambiance-mobile'
*= require "lib/codemirror/theme/ambiance"
*= require "lib/codemirror/theme/blackboard"
*= require "lib/codemirror/theme/cobalt"
*= require "lib/codemirror/theme/eclipse"
*= require "lib/codemirror/theme/elegant"
*= require "lib/codemirror/theme/erlang-dark"
*= require "lib/codemirror/theme/midnight"
*= require "lib/codemirror/theme/monokai"
*= require "lib/codemirror/theme/neat"
*= require "lib/codemirror/theme/night"
*= require "lib/codemirror/theme/rubyblue"
*= require "lib/codemirror/theme/solarized"
*= require "lib/codemirror/theme/theme"
*= require "lib/codemirror/theme/twilight"
*= require "lib/codemirror/theme/vibrant-ink"
*= require "lib/codemirror/theme/xq-dark"
*= require "lib/codemirror/theme/xq-light"
*/
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/ambiance-mobile.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/ambiance.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/blackboard.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/cobalt.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/eclipse.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/elegant.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/erlang-dark.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/midnight.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/monokai.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/neat.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/night.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/rubyblue.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/solarized.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/theme.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/twilight.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/vibrant-ink.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/xq-dark.css);
@import url(/orbit_4.0.1/assets/stylesheets/lib/codemirror/theme/xq-light.css);
.cm-tab {
border-left: 1px solid rgba(200, 200, 200, .2);
}
-28
View File
@@ -1,28 +0,0 @@
.table .listCheckHead,
.table .listCheck {
width: 30px;
vertical-align: middle;
padding: 0 0 0 10px!important;
}
.listCheckHead .list-check,
.listCheck .list-check {
position: absolute;
margin: -12px 0 0 -1px;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=0);
opacity: 0;
}
.listCheckHead i,
.listCheck i {
display: block;
}
.checkHide td {
background-color: #E6E6E6 !important;
color: #B9B9B9;
}
.checkHide a {
color: #B9B9B9;
}
.checkHit td {
background-color: #FFFEDB !important;
}
+2 -13
View File
@@ -280,17 +280,6 @@
line-height: 26px;
margin: 0;
}
.main-forms .attributes-header h4 b {
padding: 0 1px;
border-style: dotted;
border-width: 0 2px;
border-color: #AAA;
margin-right: 5px;
cursor: move;
}
.main-forms .attributes-header h4 i {
cursor: pointer;
}
.main-forms .field-type {
background-color: #f5f5f5;
border-radius: 5px;
@@ -318,7 +307,7 @@
.main-forms .field-type .control-group:last-child {
margin-bottom: 10px;
}
#user-forms .control-group .add-target .input-append,
#new-user-forms .control-group .add-target .input-append,
.main-forms .field-type .control-group .add-target .input-append {
display: block;
margin-bottom: 10px;
@@ -335,7 +324,7 @@
border-radius: 0 4px 4px 0;
}
#user-forms .control-group .add-target .input-append input.last {
#new-user-forms .control-group .add-target .input-append input.last {
border-radius: 4px;
}
+193
View File
@@ -0,0 +1,193 @@
/* Main List */
.main-list {
margin-bottom: 10px;
}
.main-list tbody {
border: 1px solid #dddddd;
}
.main-list thead {
border: 1px solid #454545;
}
.main-list thead th {
vertical-align: middle;
background-color: #454545;
white-space: nowrap;
color: #FFFFFF;
}
.main-list tbody tr.disable td {
color: #C5C5C5;
background-color: #eeeeee;
}
.main-list tbody tr.disable td .label-info {
background-color: #999999;
}
.main-list tbody tr.active td:first-child {
position: relative;
}
.main-list tbody tr.active td:first-child:before {
content: "";
width: 0px;
height: 0px;
left: -21px;
top: 50%;
margin-top: -6px;
position: absolute;
border-style: solid;
border-width: 6px 0 6px 6px;
border-color: transparent transparent transparent #333333;
}
.main-list td {
background-color: #FFFFFF;
}
.main-list td.action {
vertical-align: middle;
text-align: right;
}
.main-list td.preview img {
width: 100%;
}
.main-list td .banner-link {
width: 100px;
max-width: 120px;
display: inline-block;
text-overflow: ellipsis;
overflow: hidden;
}
.main-list td .file-list {
display: inline-block;
margin: 0 0 -6px;
}
.main-list td .file-list:after {
content: "";
clear: both;
display: block;
height: 0;
visibility: hidden;
}
.main-list td .file-type {
position: relative;
list-style: none;
float: left;
display: inline-block;
}
.main-list td .file-type a {
background-color: #A6A6A6;
color: #FFFFFF;
margin-right: 10px;
padding: 2px 5px 2px 3px;
border-radius: 3px;
text-decoration: none;
text-shadow: 0px -1px 0px rgba(100, 100, 100, .6);
}
.main-list td .file-type i,
.main-forms fieldset .input-area .controls .file-type i {
width: 16px;
height: 16px;
margin-bottom: -1px;
display: inline-block;
}
.main-list td .file-type[class^="type-"] i,
.main-list td .file-type[class*=" type-"] i,
.main-forms fieldset .input-area .controls .file-type[class*=" type-"] i,
.main-forms fieldset .input-area .controls .file-type[class^="type-"] i {
background-image: url(/orbit_4.0.1/assets/images/file_type.png);
}
.file-type.type-pdf i {background-position: 0px 0px;}
.file-type.type-psd i {background-position: -16px 0px;}
.file-type.type-ai i {background-position: -32px 0px;}
.file-type.type-fla i {background-position: -48px 0px;}
.file-type.type-in i {background-position: -64px 0px;}
.file-type.type-acc i {background-position: 0px -16px;}
.file-type.type-do i {background-position: -16px -16px;}
.file-type.type-xl i {background-position: -32px -16px;}
.file-type.type-pp i {background-position: -48px -16px;}
.file-type.type-zip i {background-position: -64px -16px;}
.file-type.type-txt i {background-position: 0px -32px;}
.file-type.type-jp i {background-position: -16px -32px;}
.file-type.type-gif i {background-position: -32px -32px;}
.file-type.type-png i {background-position: -48px -32px;}
.file-type.type-audio i {background-position: -64px -32px;}
.main-list td .quick-edit {
height: 24px;
margin-top: 5px;
}
.main-list td .quick-edit .nav {
display: none;
margin-bottom: 0;
}
.main-list tr:hover .quick-edit .nav {
display: block;
}
.main-list td .quick-edit .nav > li > a {
padding-top: 4px;
padding-bottom: 4px;
margin-top: 0px;
margin-bottom: 0px;
border: 1px dotted #d1d1d1;
}
.main-list td .quick-edit .nav > li > a:hover {
border: 1px dotted transparent;
}
.main-list thead tr.sort-header th a {
padding: 8px;
margin: -8px;
display: block;
color: #FFFFFF;
text-decoration: none;
}
.main-list thead tr.sort-header th.active a {
padding-bottom: 4px;
border-bottom: 4px solid #08c;
}
.main-list .footable-row-detail td {
padding: 0;
border-top: none;
}
.main-list .footable-row-detail td .footable-row-detail-inner {
display: none;
padding: 8px;
position: relative;
border-radius: 5px;
margin: 0 8px 8px;
background-color: #ededed;
}
.main-list .footable-row-detail td .footable-row-detail-inner:after {
display: block;
height: 0px;
width: 0px;
position: absolute;
top: -6px;
left: 50%;
margin-left: -3px;
content: "";
border-style: solid;
border-width: 0 6px 6px 6px;
border-color: transparent transparent #ededed transparent;
}
.main-list .footable-row-detail td .footable-row-detail-inner div {
margin: 10px 0;
}
#preview .preview {
margin: 0 auto;
}
/* For Retina */
@media screen and (-webkit-min-device-pixel-ratio: 2), screen and (max--moz-device-pixel-ratio: 2) {
.main-list td .file-type[class^="type-"] i,
.main-list td .file-type[class*=" type-"] i,
.main-forms fieldset .input-area .controls .file-type[class*=" type-"] i,
.main-forms fieldset .input-area .controls .file-type[class^="type-"] i {
background-image: url(/orbit_4.0.1/assets/images/file_type@2x.png);
background-size: 80px 48px;
}
}
/* Responsive */
@media (max-width: 480px) {
.main-list td .quick-edit .nav {
display: block;
}
}
@@ -39,13 +39,6 @@
.main-list td {
background-color: #FFFFFF;
}
.main-list td input[type="text"] {
margin-bottom: 0;
margin-left: -.4em;
margin-right: 3px;
padding: 0 .3em;
width: 4em;
}
.main-list td.action {
vertical-align: middle;
text-align: right;
+30 -95
View File
@@ -2,20 +2,9 @@
#list-view h4 a {
color: #000;
text-decoration: none;
display: block;
width: 100%;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
}
/* List */
#list-view #member-list tr.highlight td {
background-color: #FFFAE5;
}
#list-view #member-list tr.highlight td:first-child {
padding: 0
}
#list-view #member-list .gender,
#list-view #member-list td[class^="gender-"] {
width: 5px;
@@ -117,31 +106,10 @@
#list-view #member-abstract .member-avatar .action > a.trash {
background-color: #b94a48;
}
/*#list-view #member-abstract .member-avatar:after {
content: "";
#list-view #member-abstract .member-avatar > span {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
display: block;
margin: 0;
background-color: #000000;
-webkit-border-radius: 5px 5px 0 0;
-moz-border-radius: 5px 5px 0 0;
border-radius: 5px 5px 0 0;
opacity: 0;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
filter: alpha(opacity=0);
}*/
#list-view #member-abstract > li .member-avatar:after {
-webkit-backface-visibility: hidden;
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
width: 250px;
height: 120px;
display: block;
margin: 0;
background-color: #000000;
@@ -152,8 +120,7 @@
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
filter: alpha(opacity=0);
}
#list-view #member-abstract > li:hover .member-avatar:after {
-webkit-backface-visibility: hidden;
#list-view #member-abstract > li:hover .member-avatar > span {
opacity: .4;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";
filter: alpha(opacity=40);
@@ -192,13 +159,14 @@
float: left;
position: relative;
}
#list-view #member-card > li:hover .member-avatar > span {
opacity: 0.4;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";
filter: alpha(opacity=40);
}
#list-view #member-card > li:hover .member-avatar .action {
visibility: visible;
}
#list-view #member-card .highlight {
background-color: #F0F0F0;
outline: 1px dashed #9E9E9E;
}
#list-view #member-card .member-avatar {
width: 150px;
height: 150px;
@@ -215,37 +183,14 @@
#list-view #member-card .member-avatar.gender-woman {
border-color: #FF3196;
}
#list-view #member-card .member-avatar.gender-nene {
#list-view #member-card .member-avatar.gender-none {
border-color: #DDDDDD;
}
#list-view #member-card .member-avatar img {
/*width: 100%;*/
max-width: none;
}
#list-view #member-card > li .member-avatar:after {
-webkit-backface-visibility: hidden;
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
display: block;
margin: 0;
background-color: #000000;
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
border-radius: 50%;
opacity: 0;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
filter: alpha(opacity=100);
}
#list-view #member-card > li:hover .member-avatar:after {
opacity: .4;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";
filter: alpha(opacity=40);
}
/*#list-view #member-card .member-avatar > span {
#list-view #member-card .member-avatar > span {
position: absolute;
width: 150px;
height: 150px;
@@ -258,7 +203,7 @@
opacity: 0;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
filter: alpha(opacity=0);
}*/
}
#list-view #member-card .member-avatar .action {
position: absolute;
z-index: 1;
@@ -317,25 +262,22 @@
margin-top: 20px;
}
#profile #basic-info .member-avatar {
width: 103px;
height: 103px;
width: 106px;
height: 106px;
float: left;
}
#profile #basic-info .member-avatar img {
border: 3px solid #ffffff;
-webkit-border-radius: 9px;
-moz-border-radius: 9px;
border-radius: 9px;
width: 100%;
max-width: none;
}
#profile #basic-info .member-avatar:after {
content: "";
-webkit-backface-visibility: hidden;
}
#profile #basic-info .member-avatar.gender-man {
#profile #basic-info .member-avatar.gender-man img {
border-color: #34ADFF;
}
#profile #basic-info .member-avatar.gender-woman {
#profile #basic-info .member-avatar.gender-woman img {
border-color: #FF3196;
}
#profile #basic-info .member-avatar.gender-none {
#profile #basic-info .member-avatar.gender-none img {
border-color: #DDDDDD;
}
#profile #member-roles {
@@ -371,28 +313,21 @@
#profile #member-roles .roles dd {
color: #999999;
}
#profile #module-navbar {
margin-left: 10px;
}
#profile #module-navbar .navbar {
margin-bottom: 15px;
}
#profile #member-module {
margin-left: 360px;
}
#profile #member-module #module-navbar.scroll-to-fixed-fixed {
background-color: #F3F3F3;
padding-top: 20px;
}
#profile #member-module #module-navbar.scroll-to-fixed-fixed .navbar {
margin-bottom: 10px;
}
#profile #member-module #module-content {
padding: 0 0 0 10px;
}
#profile #member-module #module-content .content {
right: 10px;
padding-bottom: 10px;
outline: none;
}
#profile #member-module #module-content .list-active {
padding-bottom: 8px;
/*border-bottom: 1px solid #DDD;*/
padding: 0 10px;
}
/* Responsive */
@media (max-width: 979px) {
#profile #member-info {
+26 -52
View File
@@ -8,7 +8,7 @@
overflow: auto;
/* Specify the width of your pageslide here */
/*padding: 5px;*/
padding: 5px;
/* These styles are optional, and describe how the pageslide will look */
background-color: #333;
@@ -17,29 +17,34 @@
-moz-box-shadow: inset 0 0 5px 5px #222;
box-shadow: inset 0 0 5px 5px #222;
}
#pageslide .page-title {
padding: 10px;
background-color: #232323;
border-bottom: 1px solid #424242;
line-height: 2em;
}
#pageslide .page-title a {
color: #FFF;
text-decoration: none;
font-size: 1.6em;
}
#pageslide .page-title span {
font-size: 1.7em;
}
#pageslide .view-page {
position: absolute;
top: 0;
bottom: 0;
width: 100%;
}
#pageslide .content {
padding: 15px;
}
#pageslide #view-page .content,
#pageslide #view-page .pane {
outline: none;
padding: 0px;
margin-top: 57px;
}
#pageslide #view-page .content {
padding-bottom: 10px;
}
#pageslide #view-page .page-info {
padding: 0 10px;
border-bottom: 1px solid #222222;
box-shadow: 0px 1px 0px #404040;
line-height: 50px;
}
#pageslide #view-page .page-info a {
color: #8f8f8f;
font-size: 2em;
text-decoration: none;
}
#pageslide #view-page .page-info a:hover {
color: #efefef;
}
#pageslide #view-page .page-info h3 {
margin: 5px 0;
}
#pageslide form {
margin-bottom: 0;
@@ -84,35 +89,4 @@
display: inline-block;
height: 30px;
padding: 0 2px 0 5px;
}
#pageslide .groups {
margin-bottom: 10px;
}
#pageslide .error-cover {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
text-align: center;
background-color: #333;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=95)";
filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=95);
opacity: .95;
}
#pageslide .error-cover .msg {
position: absolute;
top: 50%;
margin-top: -55px;
height: 110px;
width: 100%;
}
#pageslide .error-cover i {
font-size: 6em;
}
#pageslide .error-cover p {
font-size: 1.3em;
}
#pageslide .suckIE {
color: #EE4545;
}
+21 -21
View File
@@ -6,22 +6,22 @@
.tags .lead .badge {
margin-top: 5px;
}
.tags-groups {
.tags .tags-groups {
list-style: none;
margin: 0 0 20px;
padding: 0;
}
.tags-groups:after {
.tags .tags-groups:after {
content: "";
clear: both;
height: 0;
display: block;
visibility: hidden;
}
.tags-groups.module-tags li.default a {
.tags .tags-groups.module-tags li.default a {
margin-left: 5px;
}
.tags-groups li {
.tags .tags-groups li {
overflow: hidden;
float: left;
width: auto;
@@ -39,7 +39,7 @@
-o-transition: all .2s linear;
transition: all .2s linear;
}
.tags-groups li.mark {
.tags .tags-groups li.mark {
width: 0;
height: 0;
padding: 0;
@@ -49,28 +49,28 @@
opacity: 0;
visibility: hidden;
}
.tags-groups li.active {
.tags .tags-groups li.active {
background-color: #3a87ad;
}
.tags-groups li.active .amount {
.tags .tags-groups li.active .amount {
color: #8cb8be;
}
.tags-groups li a {
.tags .tags-groups li a {
text-decoration: none;
color: #ededed;
}
.tags-groups li .amount {
.tags .tags-groups li .amount {
color: #fdcf3b;
float: right;
margin-left: 15px;
}
.tags-groups li .card {
.tags .tags-groups li .card {
position: relative;
margin: 0;
width: 18px;
height: 18px;
}
.tags-groups li .card:after {
.tags .tags-groups li .card:after {
font-family: FontAwesome;
content: '\f111';
color: #fdcf3b;
@@ -82,13 +82,13 @@
left: 0;
top: 0;
}
.tags-groups li .card.active:after {
.tags .tags-groups li .card.active:after {
content: '\f058';
font-size: 18px;
left: -2px;
top: 1px;
}
.tags-groups li .card input {
.tags .tags-groups li .card input {
position: absolute;
top: 0;
left: 0;
@@ -110,10 +110,10 @@
#tags-merger form {
margin-bottom: 0;
}
#tags-merger .tags-groups li {
#tags-merger .tags .tags-groups li {
cursor: pointer;
}
#tags-merger .tags-groups li.def {
#tags-merger .tags .tags-groups li.def {
background-color: #468847;
}
#tags-merger .modal-body .pull-left {
@@ -127,22 +127,22 @@
.tags-groups li.default {
.tags .tags-groups li.default {
background-color: #468847;
}
.tags-groups li.default.active {
.tags .tags-groups li.default.active {
background-color: #3a87ad;
}
.tags-groups li.default .amount {
.tags .tags-groups li.default .amount {
color: #8cbe9a;
}
.tags-groups li.default.active .amount {
.tags .tags-groups li.default.active .amount {
color: #8cb8be;
}
.tags-groups li.default .card:after {
.tags .tags-groups li.default .card:after {
color: #8cbe9a;
}
.tags-groups li.active .card:after {
.tags .tags-groups li.active .card:after {
color: #8cb8be;
}
-16
View File
@@ -26,12 +26,6 @@
margin-top: 4px;
margin-left: 10px;
}
.topnav .btn-group {
margin-left: 0;
}
.topnav .view-switch {
margin-left: 10px;
}
/* Bottom Nav */
.bottomnav {
@@ -47,16 +41,6 @@
.bottomnav .action {
margin-bottom: 6px;
}
.bottomnav .divider {
display: inline-block;
position: relative;
margin: 0 5px;
background-color: #E0E0E0;
width: 1px;
height: 16px;
top: 5px;
box-shadow: 1px 0 0 #FFF;
}
.bottomnav .pagination {
margin: 0;
}
-10
View File
@@ -1,10 +0,0 @@
/*
*This is a manifest file that'll automatically include all the stylesheets available in this directory
*and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
*the top of the compiled file, but it's generally better to create a new file per style scope.
*= require mobile/jquery.mobile-1.2.0.css
*= require mobile/add2home
*= require mobile/orbit-mobile
*= require basic/icon
*= require basic/font-awesome
*/
-158
View File
@@ -1,158 +0,0 @@
/**
*
* Main container
*
*/
#addToHomeScreen {
z-index:9999;
-webkit-user-select:none;
-webkit-box-sizing:border-box;
width:240px;
font-size:15px;
padding:12px 14px;
text-align:left;
font-family:helvetica;
background-image:-webkit-gradient(linear,0 0,0 100%,color-stop(0,#fff),color-stop(0.02,#eee),color-stop(0.98,#ccc),color-stop(1,#a3a3a3));
border:1px solid #505050;
-webkit-border-radius:8px;
-webkit-background-clip:padding-box;
color:#333;
text-shadow:0 1px 0 rgba(255,255,255,0.75);
line-height:130%;
-webkit-box-shadow:0 0 4px rgba(0,0,0,0.5);
}
#addToHomeScreen.addToHomeIpad {
width:268px;
font-size:18px;
padding:14px;
}
/**
*
* The 'wide' class is added when the popup contains the touch icon
*
*/
#addToHomeScreen.addToHomeWide {
width:296px;
}
#addToHomeScreen.addToHomeIpad.addToHomeWide {
width:320px;
font-size:18px;
padding:14px;
}
/**
*
* The balloon arrow
*
*/
#addToHomeScreen .addToHomeArrow {
position:absolute;
background-image:-webkit-gradient(linear,0 0,100% 100%,color-stop(0,rgba(204,204,204,0)),color-stop(0.4,rgba(204,204,204,0)),color-stop(0.4,#ccc));
border-width:0 1px 1px 0;
border-style:solid;
border-color:#505050;
width:16px; height:16px;
-webkit-transform:rotateZ(45deg);
bottom:-9px; left:50%;
margin-left:-8px;
-webkit-box-shadow:inset -1px -1px 0 #a9a9a9;
-webkit-border-bottom-right-radius:2px;
}
/**
*
* The balloon arrow for iPad
*
*/
#addToHomeScreen.addToHomeIpad .addToHomeArrow {
-webkit-transform:rotateZ(-135deg);
background-image:-webkit-gradient(linear,0 0,100% 100%,color-stop(0,rgba(238,238,238,0)),color-stop(0.4,rgba(238,238,238,0)),color-stop(0.4,#eee));
-webkit-box-shadow:inset -1px -1px 0 #fff;
top:-9px; bottom:auto; left:50%;
}
/**
*
* Close button
*
*/
#addToHomeScreen .addToHomeClose {
-webkit-box-sizing:border-box;
position:absolute;
right:4px;
top:4px;
width:18px;
height:18px; line-height:14px;
text-align:center;
text-indent:1px;
-webkit-border-radius:9px;
background:rgba(0,0,0,0.12);
color:#707070;
-webkit-box-shadow:0 1px 0 #fff;
font-size:16px;
}
/**
*
* The '+' icon, displayed only on iOS < 4.2
*
*/
#addToHomeScreen .addToHomePlus {
font-weight:bold;
font-size:1.3em;
}
/**
*
* The 'share' icon, displayed only on iOS >= 4.2
*
*/
#addToHomeScreen .addToHomeShare {
display:inline-block;
width:18px;
height:15px;
background-repeat:no-repeat;
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAAPCAQAAABDj1eZAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAUdJREFUKFNtkLtLw1AYxS/qJLhXVKr2ZRulUNtiqgSb3CziICI6ucTFVYcOnaQOFRwUnNTRwUWXgpP/QdHNUEQUHGxofYBTlRs83iZNjKTncOGe7/vx3QchXUWn6FL3jhfKUdCCr5zuifV5oDiHQM+c+CIhiiCSWNu08iq9oHXKLAiqrgR4UXqlOEYZt++ExEL0wW7+OW0G10muLv9gmqfe5FAWKmTMYQYiFL7PYwyLOD8lSjNh2gdnPzMII4QUBxc4OothbAF7GCBKQ0YbSWyPQsIhqvetS+y0ygGMo/KFZfviDvR4AhwgZU9dGYnA0J/6ndc15i3ouYIMcVVUcEXIoOxCeRCfwP8sXBSdjtpUv/1QW+K16kCCIUC4id9Fa0JtkluwVkSfqPL6RwfSDA0aNlx7k/bWgViB7bMS2/1vk5sdsZLN/ALSuL3tylO4RAAAAABJRU5ErkJggg==);
background-size:18px 15px;
text-indent:-9999em;
overflow:hidden;
}
/**
*
* The touch icon (if available)
*
*/
#addToHomeScreen .addToHomeTouchIcon {
display:block;
float:left;
-webkit-border-radius:6px;
-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.5),
inset 0 0 2px rgba(255,255,255,0.9);
background-repeat:no-repeat;
width:57px; height:57px;
-webkit-background-size:57px 57px;
margin:0 12px 0 0;
border:1px solid #333;
-webkit-background-clip:padding-box;
}
/**
*
* The 'share' icon for retina display
*
*/
@media all and (-webkit-min-device-pixel-ratio: 2) {
#addToHomeScreen .addToHomeShare {
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAeCAQAAADu6HTYAAADPElEQVR4Xq3TX2gcRRzA8e/M7mVv2+TSNpc/TZtrY6jUGqgaSAmEChKLrYK0YH0RFC2CSCkEfCghiKU04J8qNigq6os+iQV98MHWFwVBrQQRWs21lBw5cw3NNb1/udu72RGG5Y77IzXW77D7sAwf5scyYoL6BGXSDKFZwaGpLvIUaeoCkvX1MmsM0Ny6oRSQYOLuIS+YZOpfQdqslpUxcZrzTVAz4qPwW2O3CeIwC/RSzeY6Ow1QhUrkr+YOWfEKDkEP8Rij7CHKJmrFSDHBdwGEE5wiGChPN+PnT8VdRtEIl1d4gRj/1EVe5ZSBKGh8iqQpo/Fo5+3C/gz0MYg4zgwbqday1/Q4B8BGQ45d/Hi54lakCrU5obOcidJpu1+Lg9whjabyaOYLnrIBFFaRD+xe2ybMDWY66GmP/WA9cGfGp0CWhy0wkMN8inepFiH2rV1j0NQSNQbFLRQnS8/8YSDBBpadfv4CYDub2fmeHDNAsL1MBWUel0iA+Xik6eHcyvD3vAMSU1TGuA/YRS+dD7ovCQN43GKRFCU20Kd3V/avDVVyAZ5niTEuLA5/zBGWg9EEEhfJKN200Tat8CmRAQb9+wv7soPlHt2tQorsz1uPbr0HTY4sJwrH47zJZwABBAKLMBoQXepwgTwdHCo+fXMkQ4lrxEmQ5AaXipPqDY9V2vn09tgvTPI71EEGYxM+/uMJLJ4svpgaWGKOi/xKgmqLSUGSUd5f2vIVJ/CgBaTIUsZ7ZBsn0+NzfMOXLFCXQyTcybN6ep5ZZgUOHn7jpfUpsZshdugPGf+E5zjbyHTSRyQ8xfRPPM/s63RHeuknSoT22mjmmnAOIMkUZ6D1xSfPPAfd1WFKM3sO2CMaHx8M1NjnXKHaAGGkOW0C02WeYHUz4qMtx+w5gUDS8NckYe5lHsMYwCZEPyEEmjLDZFmAS7CDviMdxyTkMNVBKEmYLvbiQQBIBBbCQG04bGQvFWz6CfsCQLWCigILFwcfkGYBiOpbYuOizTAyYyDdCtrGaRG1LCkIgMYEFhI0WqQZoSlbGRyHKe4qOx7iv2bVQW9dp4dlM/x6kmwnWQcd/Q3FCqwTEiT5s+6D5v/pb0SSHyg7uhMWAAAAAElFTkSuQmCC);
}
}
-303
View File
@@ -1,303 +0,0 @@
/* Font Awesome
the iconic font designed for use with Twitter Bootstrap
-------------------------------------------------------
The full suite of pictographic icons, examples, and documentation
can be found at: http://fortawesome.github.com/Font-Awesome/
License
-------------------------------------------------------
The Font Awesome webfont, CSS, and LESS files are licensed under CC BY 3.0:
http://creativecommons.org/licenses/by/3.0/ A mention of
'Font Awesome - http://fortawesome.github.com/Font-Awesome' in human-readable
source code is considered acceptable attribution (most common on the web).
If human readable source code is not available to the end user, a mention in
an 'About' or 'Credits' screen is considered acceptable (most common in desktop
or mobile software).
Contact
-------------------------------------------------------
Email: dave@davegandy.com
Twitter: http://twitter.com/fortaweso_me
Work: http://lemonwi.se co-founder
*/
@font-face {
font-family: "FontAwesome";
src: url('../fonts/fontawesome-webfont.eot');
src: url('../fonts/fontawesome-webfont.eot?#iefix') format('eot'), url('../fonts/fontawesome-webfont.woff') format('woff'), url('../fonts/fontawesome-webfont.ttf') format('truetype'), url('../font/fontawesome-webfont.svg#FontAwesome') format('svg');
font-weight: normal;
font-style: normal;
}
/* Font Awesome styles
------------------------------------------------------- */
[class^="icon-"]:before, [class*=" icon-"]:before {
font-family: FontAwesome;
font-weight: normal;
font-style: normal;
display: inline-block;
text-decoration: inherit;
}
a [class^="icon-"], a [class*=" icon-"] {
display: inline-block;
text-decoration: inherit;
}
/* makes the font 33% larger relative to the icon container */
.icon-large:before {
vertical-align: top;
font-size: 1.3333333333333333em;
}
.btn [class^="icon-"], .btn [class*=" icon-"] {
/* keeps button heights with and without icons the same */
line-height: .9em;
}
li [class^="icon-"], li [class*=" icon-"] {
display: inline-block;
width: 1.25em;
text-align: center;
}
li .icon-large[class^="icon-"], li .icon-large[class*=" icon-"] {
/* 1.5 increased font size for icon-large * 1.25 width */
width: 1.875em;
}
li[class^="icon-"], li[class*=" icon-"] {
margin-left: 0;
list-style-type: none;
}
li[class^="icon-"]:before, li[class*=" icon-"]:before {
text-indent: -2em;
text-align: center;
}
li[class^="icon-"].icon-large:before, li[class*=" icon-"].icon-large:before {
text-indent: -1.3333333333333333em;
}
/* Font Awesome uses the Unicode Private Use Area (PUA) to ensure screen
readers do not read off random characters that represent icons */
.icon-glass:before { content: "\f000"; }
.icon-music:before { content: "\f001"; }
.icon-search:before { content: "\f002"; }
.icon-envelope:before { content: "\f003"; }
.icon-heart:before { content: "\f004"; }
.icon-star:before { content: "\f005"; }
.icon-star-empty:before { content: "\f006"; }
.icon-user:before { content: "\f007"; }
.icon-film:before { content: "\f008"; }
.icon-th-large:before { content: "\f009"; }
.icon-th:before { content: "\f00a"; }
.icon-th-list:before { content: "\f00b"; }
.icon-ok:before { content: "\f00c"; }
.icon-remove:before { content: "\f00d"; }
.icon-zoom-in:before { content: "\f00e"; }
.icon-zoom-out:before { content: "\f010"; }
.icon-off:before { content: "\f011"; }
.icon-signal:before { content: "\f012"; }
.icon-cog:before { content: "\f013"; }
.icon-trash:before { content: "\f014"; }
.icon-home:before { content: "\f015"; }
.icon-file:before { content: "\f016"; }
.icon-time:before { content: "\f017"; }
.icon-road:before { content: "\f018"; }
.icon-download-alt:before { content: "\f019"; }
.icon-download:before { content: "\f01a"; }
.icon-upload:before { content: "\f01b"; }
.icon-inbox:before { content: "\f01c"; }
.icon-play-circle:before { content: "\f01d"; }
.icon-repeat:before { content: "\f01e"; }
/* \f020 doesn't work in Safari. all shifted one down */
.icon-refresh:before { content: "\f021"; }
.icon-list-alt:before { content: "\f022"; }
.icon-lock:before { content: "\f023"; }
.icon-flag:before { content: "\f024"; }
.icon-headphones:before { content: "\f025"; }
.icon-volume-off:before { content: "\f026"; }
.icon-volume-down:before { content: "\f027"; }
.icon-volume-up:before { content: "\f028"; }
.icon-qrcode:before { content: "\f029"; }
.icon-barcode:before { content: "\f02a"; }
.icon-tag:before { content: "\f02b"; }
.icon-tags:before { content: "\f02c"; }
.icon-book:before { content: "\f02d"; }
.icon-bookmark:before { content: "\f02e"; }
.icon-print:before { content: "\f02f"; }
.icon-camera:before { content: "\f030"; }
.icon-font:before { content: "\f031"; }
.icon-bold:before { content: "\f032"; }
.icon-italic:before { content: "\f033"; }
.icon-text-height:before { content: "\f034"; }
.icon-text-width:before { content: "\f035"; }
.icon-align-left:before { content: "\f036"; }
.icon-align-center:before { content: "\f037"; }
.icon-align-right:before { content: "\f038"; }
.icon-align-justify:before { content: "\f039"; }
.icon-list:before { content: "\f03a"; }
.icon-indent-left:before { content: "\f03b"; }
.icon-indent-right:before { content: "\f03c"; }
.icon-facetime-video:before { content: "\f03d"; }
.icon-picture:before { content: "\f03e"; }
.icon-pencil:before { content: "\f040"; }
.icon-map-marker:before { content: "\f041"; }
.icon-adjust:before { content: "\f042"; }
.icon-tint:before { content: "\f043"; }
.icon-edit:before { content: "\f044"; }
.icon-share:before { content: "\f045"; }
.icon-check:before { content: "\f046"; }
.icon-move:before { content: "\f047"; }
.icon-step-backward:before { content: "\f048"; }
.icon-fast-backward:before { content: "\f049"; }
.icon-backward:before { content: "\f04a"; }
.icon-play:before { content: "\f04b"; }
.icon-pause:before { content: "\f04c"; }
.icon-stop:before { content: "\f04d"; }
.icon-forward:before { content: "\f04e"; }
.icon-fast-forward:before { content: "\f050"; }
.icon-step-forward:before { content: "\f051"; }
.icon-eject:before { content: "\f052"; }
.icon-chevron-left:before { content: "\f053"; }
.icon-chevron-right:before { content: "\f054"; }
.icon-plus-sign:before { content: "\f055"; }
.icon-minus-sign:before { content: "\f056"; }
.icon-remove-sign:before { content: "\f057"; }
.icon-ok-sign:before { content: "\f058"; }
.icon-question-sign:before { content: "\f059"; }
.icon-info-sign:before { content: "\f05a"; }
.icon-screenshot:before { content: "\f05b"; }
.icon-remove-circle:before { content: "\f05c"; }
.icon-ok-circle:before { content: "\f05d"; }
.icon-ban-circle:before { content: "\f05e"; }
.icon-arrow-left:before { content: "\f060"; }
.icon-arrow-right:before { content: "\f061"; }
.icon-arrow-up:before { content: "\f062"; }
.icon-arrow-down:before { content: "\f063"; }
.icon-share-alt:before { content: "\f064"; }
.icon-resize-full:before { content: "\f065"; }
.icon-resize-small:before { content: "\f066"; }
.icon-plus:before { content: "\f067"; }
.icon-minus:before { content: "\f068"; }
.icon-asterisk:before { content: "\f069"; }
.icon-exclamation-sign:before { content: "\f06a"; }
.icon-gift:before { content: "\f06b"; }
.icon-leaf:before { content: "\f06c"; }
.icon-fire:before { content: "\f06d"; }
.icon-eye-open:before { content: "\f06e"; }
.icon-eye-close:before { content: "\f070"; }
.icon-warning-sign:before { content: "\f071"; }
.icon-plane:before { content: "\f072"; }
.icon-calendar:before { content: "\f073"; }
.icon-random:before { content: "\f074"; }
.icon-comment:before { content: "\f075"; }
.icon-magnet:before { content: "\f076"; }
.icon-chevron-up:before { content: "\f077"; }
.icon-chevron-down:before { content: "\f078"; }
.icon-retweet:before { content: "\f079"; }
.icon-shopping-cart:before { content: "\f07a"; }
.icon-folder-close:before { content: "\f07b"; }
.icon-folder-open:before { content: "\f07c"; }
.icon-resize-vertical:before { content: "\f07d"; }
.icon-resize-horizontal:before { content: "\f07e"; }
.icon-bar-chart:before { content: "\f080"; }
.icon-twitter-sign:before { content: "\f081"; }
.icon-facebook-sign:before { content: "\f082"; }
.icon-camera-retro:before { content: "\f083"; }
.icon-key:before { content: "\f084"; }
.icon-cogs:before { content: "\f085"; }
.icon-comments:before { content: "\f086"; }
.icon-thumbs-up:before { content: "\f087"; }
.icon-thumbs-down:before { content: "\f088"; }
.icon-star-half:before { content: "\f089"; }
.icon-heart-empty:before { content: "\f08a"; }
.icon-signout:before { content: "\f08b"; }
.icon-linkedin-sign:before { content: "\f08c"; }
.icon-pushpin:before { content: "\f08d"; }
.icon-external-link:before { content: "\f08e"; }
.icon-signin:before { content: "\f090"; }
.icon-trophy:before { content: "\f091"; }
.icon-github-sign:before { content: "\f092"; }
.icon-upload-alt:before { content: "\f093"; }
.icon-lemon:before { content: "\f094"; }
.icon-phone:before { content: "\f095"; }
.icon-check-empty:before { content: "\f096"; }
.icon-bookmark-empty:before { content: "\f097"; }
.icon-phone-sign:before { content: "\f098"; }
.icon-twitter:before { content: "\f099"; }
.icon-facebook:before { content: "\f09a"; }
.icon-github:before { content: "\f09b"; }
.icon-unlock:before { content: "\f09c"; }
.icon-credit-card:before { content: "\f09d"; }
.icon-rss:before { content: "\f09e"; }
.icon-hdd:before { content: "\f0a0"; }
.icon-bullhorn:before { content: "\f0a1"; }
.icon-bell:before { content: "\f0a2"; }
.icon-certificate:before { content: "\f0a3"; }
.icon-hand-right:before { content: "\f0a4"; }
.icon-hand-left:before { content: "\f0a5"; }
.icon-hand-up:before { content: "\f0a6"; }
.icon-hand-down:before { content: "\f0a7"; }
.icon-circle-arrow-left:before { content: "\f0a8"; }
.icon-circle-arrow-right:before { content: "\f0a9"; }
.icon-circle-arrow-up:before { content: "\f0aa"; }
.icon-circle-arrow-down:before { content: "\f0ab"; }
.icon-globe:before { content: "\f0ac"; }
.icon-wrench:before { content: "\f0ad"; }
.icon-tasks:before { content: "\f0ae"; }
.icon-filter:before { content: "\f0b0"; }
.icon-briefcase:before { content: "\f0b1"; }
.icon-fullscreen:before { content: "\f0b2"; }
.icon-group:before { content: "\f0c0"; }
.icon-link:before { content: "\f0c1"; }
.icon-cloud:before { content: "\f0c2"; }
.icon-beaker:before { content: "\f0c3"; }
.icon-cut:before { content: "\f0c4"; }
.icon-copy:before { content: "\f0c5"; }
.icon-paper-clip:before { content: "\f0c6"; }
.icon-save:before { content: "\f0c7"; }
.icon-sign-blank:before { content: "\f0c8"; }
.icon-reorder:before { content: "\f0c9"; }
.icon-list-ul:before { content: "\f0ca"; }
.icon-list-ol:before { content: "\f0cb"; }
.icon-strikethrough:before { content: "\f0cc"; }
.icon-underline:before { content: "\f0cd"; }
.icon-table:before { content: "\f0ce"; }
.icon-magic:before { content: "\f0d0"; }
.icon-truck:before { content: "\f0d1"; }
.icon-pinterest:before { content: "\f0d2"; }
.icon-pinterest-sign:before { content: "\f0d3"; }
.icon-google-plus-sign:before { content: "\f0d4"; }
.icon-google-plus:before { content: "\f0d5"; }
.icon-money:before { content: "\f0d6"; }
.icon-caret-down:before { content: "\f0d7"; }
.icon-caret-up:before { content: "\f0d8"; }
.icon-caret-left:before { content: "\f0d9"; }
.icon-caret-right:before { content: "\f0da"; }
.icon-columns:before { content: "\f0db"; }
.icon-sort:before { content: "\f0dc"; }
.icon-sort-down:before { content: "\f0dd"; }
.icon-sort-up:before { content: "\f0de"; }
.icon-envelope-alt:before { content: "\f0e0"; }
.icon-linkedin:before { content: "\f0e1"; }
.icon-undo:before { content: "\f0e2"; }
.icon-legal:before { content: "\f0e3"; }
.icon-dashboard:before { content: "\f0e4"; }
.icon-comment-alt:before { content: "\f0e5"; }
.icon-comments-alt:before { content: "\f0e6"; }
.icon-bolt:before { content: "\f0e7"; }
.icon-sitemap:before { content: "\f0e8"; }
.icon-umbrella:before { content: "\f0e9"; }
.icon-paste:before { content: "\f0ea"; }
.icon-user-md:before { content: "\f200"; }
-519
View File
@@ -1,519 +0,0 @@
/* WARNING: Your are using ligatures for your icon font.
Ligatures are not supported in IE 9 (and older).
Use the Private Use Area encoding for best browser support.
==================================================================== */
@font-face {
font-family: 'entypo';
src:url(<%= asset_path 'entypo.eot' %>);
src:url(<%= asset_path 'entypo.eot?#iefix' %>) format('embedded-opentype'),
url(<%= asset_path 'entypo.svg#entypo' %>) format('svg'),
url(<%= asset_path 'entypo.woff' %>) format('woff'),
url(<%= asset_path 'entypo.ttf' %>) format('truetype');
font-weight: normal;
font-style: normal;
}
/* Use the following CSS code if you want to use data attributes for inserting your icons */
[data-icons]:before {
font-family: 'entypo';
content: attr(data-icon);
speak: none;
/* Enable Ligatures */
-webkit-font-feature-settings:"liga","dlig";
-moz-font-feature-settings:"liga=1, dlig=1";
-moz-font-feature-settings:"liga","dlig";
-ms-font-feature-settings:"liga","dlig";
-o-font-feature-settings:"liga","dlig";
font-feature-settings:"liga","dlig";
text-rendering:optimizeLegibility;
font-weight: normal;
-webkit-font-smoothing: antialiased;
}
/* Use the following CSS code if you want to have a class per icon */
[class^="icons-"]:before, [class*=" icons-"]:before {
font-size: 1.5em;
font-family: 'entypo';
font-style: normal;
speak: none;
/* Enable Ligatures */
-webkit-font-feature-settings:"liga","dlig";
-moz-font-feature-settings:"liga=1, dlig=1";
-moz-font-feature-settings:"liga","dlig";
-ms-font-feature-settings:"liga","dlig";
-o-font-feature-settings:"liga","dlig";
font-feature-settings:"liga","dlig";
text-rendering:optimizeLegibility;
font-weight: normal;
-webkit-font-smoothing: antialiased;
display: inline-block;
text-decoration: inherit;
}
a [class^="icons-"], a [class*=" icons-"] {
display: inline-block;
text-decoration: inherit;
}
/* makes the font 33% larger relative to the icon container */
.icons-large:before {
vertical-align: top;
font-size: 1.3333333333333333em;
}
.btn [class^="icons-"], .btn [class*=" icons-"] {
/* keeps button heights with and without icons the same */
line-height: .9em;
}
li [class^="icons-"], li [class*=" icons-"] {
display: inline-block;
width: 1.25em;
text-align: center;
margin-right: 10px;
}
li .icons-large[class^="icons-"], li .icons-large[class*=" icons-"] {
/* 1.5 increased font size for icons-large * 1.25 width */
width: 1.875em;
}
li[class^="icons-"], li[class*=" icons-"] {
margin-left: 0;
list-style-type: none;
}
li[class^="icons-"]:before, li[class*=" icons-"]:before {
text-indent: -2em;
text-align: center;
}
li[class^="icons-"].icons-large:before, li[class*=" icons-"].icons-large:before {
text-indent: -1.3333333333333333em;
}
.icons-phone:before {
content: "\70\68\6f\6e\65";
}
.icons-directions:before {
content: "\64\69\72\65\63\74\69\6f\6e\73";
}
.icons-mail:before {
content: "\6d\61\69\6c";
}
.icons-pencil:before {
content: "\70\65\6e\63\69\6c";
}
.icons-paperclip:before {
content: "\70\61\70\65\72\63\6c\69\70";
}
.icons-drawer:before {
content: "\64\72\61\77\65\72";
}
.icons-member:before {
content: "\6d\65\6d\62\65\72";
}
.icons-group:before {
content: "\67\72\6f\75\70";
}
.icons-addmember:before {
content: "\61\64\64\6d\65\6d\62\65\72";
}
.icons-location:before {
content: "\6c\6f\63\61\74\69\6f\6e";
}
.icons-share:before {
content: "\73\68\61\72\65";
}
.icons-heart-full:before {
content: "\68\65\61\72\74\2d\66\75\6c\6c";
}
.icons-heart-bare:before {
content: "\68\65\61\72\74\2d\62\61\72\65";
}
.icons-star-full:before {
content: "\73\74\61\72\2d\66\75\6c\6c";
}
.icons-star-bare:before {
content: "\73\74\61\72\2d\62\61\72\65";
}
.icons-discuss:before {
content: "\64\69\73\63\75\73\73";
}
.icons-comment:before {
content: "\63\6f\6d\6d\65\6e\74";
}
.icons-quote:before {
content: "\71\75\6f\74\65";
}
.icons-house:before {
content: "\68\6f\75\73\65";
}
.icons-search:before {
content: "\73\65\61\72\63\68";
}
.icons-printer:before {
content: "\70\72\69\6e\74\65\72";
}
.icons-bell:before {
content: "\62\65\6c\6c";
}
.icons-link:before {
content: "\6c\69\6e\6b";
}
.icons-flag:before {
content: "\66\61\6c\67";
}
.icons-cog:before {
content: "\63\6f\67";
}
.icons-tools:before {
content: "\74\6f\6f\6c\73";
}
.icons-tag:before {
content: "\74\61\67";
}
.icons-camera:before {
content: "\63\61\6d\65\72\61";
}
.icons-megaphone:before {
content: "\6d\65\67\61\70\68\6f\6e\65";
}
.icons-new:before {
content: "\6e\65\77";
}
.icons-graduation:before {
content: "\67\72\61\64\75\61\74\69\6f\6e";
}
.icons-books:before {
content: "\62\6f\6f\6b\73";
}
.icons-page:before {
content: "\70\61\67\65";
}
.icons-lifebuoy:before {
content: "\6c\69\66\65\62\75\6f\79";
}
.icons-eye:before {
content: "\65\79\65";
}
.icons-clock:before {
content: "\63\6c\6f\63\6b";
}
.icons-calendar:before {
content: "\63\61\6c\65\6e\64\61\72";
}
.icons-briefcase:before {
content: "\62\72\69\65\66\63\61\73\65";
}
.icons-gauge:before {
content: "\67\61\75\67\65";
}
.icons-language:before {
content: "\6c\61\6e\67\75\61\67\65";
}
.icons-keys:before {
content: "\6b\65\79\73";
}
.icons-earth:before {
content: "\65\61\72\74\68";
}
.icons-keyboard:before {
content: "\6b\65\79\62\6f\61\72\64";
}
.icons-browser:before {
content: "\62\72\6f\77\73\65\72";
}
.icons-publish:before {
content: "\70\75\62\6c\69\73\68";
}
.icons-code:before {
content: "\63\6f\64\65";
}
.icons-light-bulb:before {
content: "\6c\69\67\68\74\2d\62\75\6c\62";
}
.icons-database:before {
content: "\64\61\74\61\62\61\73\65";
}
.icons-box:before {
content: "\62\6f\78";
}
.icons-rss:before {
content: "\72\73\73";
}
.icons-clipboard:before {
content: "\63\6c\69\70\62\6f\61\72\64";
}
.icons-cart:before {
content: "\63\61\72\74";
}
.icons-untitled:before {
content: "\75\6e\74\69\74\6c\65\64";
}
.icons-statistics:before {
content: "\73\74\61\74\69\73\74\69\63\73";
}
.icons-pie:before {
content: "\70\69\65";
}
.icons-bars:before {
content: "\62\61\72\73";
}
.icons-graph:before {
content: "\67\72\61\70\68";
}
.icons-lock:before {
content: "\6c\6f\63\6b";
}
.icons-unlock:before {
content: "\75\6e\6c\6f\63\6b";
}
.icons-outlog:before {
content: "\6f\75\74\6c\6f\67";
}
.icons-inlog:before {
content: "\69\6e\6c\6f\67";
}
.icons-checkmark:before {
content: "\63\68\65\63\6b\6d\61\72\6b";
}
.icons-aminus:before {
content: "\61\6d\69\6e\75\73";
}
.icons-aplus:before {
content: "\61\70\6c\75\73";
}
.icons-aclose:before {
content: "\61\63\6c\6f\73\65";
}
.icons-bminus:before {
content: "\62\6d\69\6e\75\73";
}
.icons-bplus:before {
content: "\62\70\6c\75\73";
}
.icons-bclose:before {
content: "\62\63\6c\6f\73\65";
}
.icons-cminus:before {
content: "\63\6d\69\6e\75\73";
}
.icons-cplus:before {
content: "\63\70\6c\75\73";
}
.icons-cross:before {
content: "\63\72\6f\73\73";
}
.icons-blocked:before {
content: "\62\6c\6f\63\6b\65\64";
}
.icons-information:before {
content: "\69\6e\66\6f\72\6d\61\74\69\6f\6e";
}
.icons-binfo:before {
content: "\62\69\6e\66\6f";
}
.icons-question:before {
content: "\71\75\65\73\74\69\6f\6e";
}
.icons-help:before {
content: "\68\65\6c\70";
}
.icons-warning:before {
content: "\77\61\72\6e\69\6e\67";
}
.icons-shuffle:before {
content: "\73\68\75\66\66\6c\65";
}
.icons-return:before {
content: "\72\65\74\75\72\6e";
}
.icons-enter:before {
content: "\65\6e\74\65\72";
}
.icons-exchange:before {
content: "\65\78\63\68\61\6e\67\65";
}
.icons-loop:before {
content: "\6c\6f\6f\70";
}
.icons-th-list:before {
content: "\74\68\2d\6c\69\73\74";
}
.icons-th-large:before {
content: "\74\68\2d\6c\61\72\67\65";
}
.icons-align-justify:before {
content: "\61\6c\69\67\6e\2d\6a\75\73\74\69\66\79";
}
.icons-wtext:before {
content: "\77\74\65\78\74";
}
.icons-btext:before {
content: "\62\74\65\78\74";
}
.icons-pictures:before {
content: "\70\69\63\74\75\72\65";
}
.icons-video:before {
content: "\76\69\64\65\6f";
}
.icons-music:before {
content: "\6d\6f\75\73\65";
}
.icons-folder:before {
content: "\66\6f\6c\64\65\72";
}
.icons-archive:before {
content: "\61\72\63\68\69\76\65";
}
.icons-trash:before {
content: "\74\72\61\73\68";
}
.icons-upload:before {
content: "\75\70\6c\6f\61\64";
}
.icons-download:before {
content: "\64\6f\77\6e\6c\6f\61\64";
}
.icons-disk:before {
content: "\64\69\73\6b";
}
.icons-bookmark:before {
content: "\62\6f\6f\6b\6d\61\72\6b";
}
.icons-booma:before {
content: "\62\6f\6f\6d\61";
}
.icons-resize-enlarge:before {
content: "\72\65\73\69\7a\65\2d\65\6e\6c\61\72\67\65";
}
.icons-resize-shrink:before {
content: "\72\65\73\69\7a\65\2d\73\68\72\69\6e\6b";
}
.icons-flow-tree:before {
content: "\66\6c\6f\77\2d\74\72\65\65";
}
.icons-arrow-left-a:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\61";
}
.icons-arrow-bottom-a:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\61";
}
.icons-arrow-top-a:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\61";
}
.icons-arrow-right-a:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\61";
}
.icons-arrow-left-b:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\62";
}
.icons-arrow-bottom-b:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\62";
}
.icons-arrow-top-b:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\62";
}
.icons-arrow-right-b:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\62";
}
.icons-arrow-left-c:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\63";
}
.icons-arrow-bottom-c:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\63";
}
.icons-arrow-top-c:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\63";
}
.icons-arrow-right-c:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\63";
}
.icons-arrow-left-d:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\64";
}
.icons-arrow-bottom-d:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\64";
}
.icons-arrow-top-d:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\64";
}
.icons-arrow-right-d:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\64";
}
.icons-arrow-left-e:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\65";
}
.icons-arrow-bottom-e:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\65";
}
.icons-arrow-top-e:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\65";
}
.icons-arrow-right-e:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\65";
}
.icons-arrow-left-f:before {
content: "\61\72\72\6f\77\2d\6c\65\66\74\2d\66";
}
.icons-arrow-bottom-f:before {
content: "\61\72\72\6f\77\2d\62\6f\74\74\6f\6d\2d\66";
}
.icons-arrow-top-f:before {
content: "\61\72\72\6f\77\2d\74\6f\70\2d\66";
}
.icons-left-f:before {
content: "\61\72\72\6f\77\2d\72\69\67\68\74\2d\66";
}
.icons-menu:before {
content: "\6d\65\6e\75";
}
.icons-ellipsis:before {
content: "\65\6c\6c\69\70\73\69\73";
}
.icons-dots:before {
content: "\64\6f\74\73";
}
.icons-dot:before {
content: "\64\6f\74";
}
.icons-like:before {
content: "\6c\69\6b\65";
}
.icons-suck:before {
content: "\73\75\63\6b";
}
.icons-export:before {
content: "\65\78\70\6f\72\74";
}
.icons-vcard:before {
content: "\76\63\61\72\64";
}
.icons-flow-cascade:before {
content: "\21";
}
.icons-landscape:before {
content: "\22";
}
.icons-brush:before {
content: "\62\72\75\73\68";
}
.icons-palette:before {
content: "\70\61\6c\65\74\74\65";
}
.icons-desktop:before {
content: "\64\65\73\6b\74\6f\70";
}
.icons-plane:before {
content: "\70\6c\61\6e\65";
}
.icons-booklet:before {
content: "\62\6f\6f\6b\6c\65\74";
}
.icons-update:before {
content: "\75\70\64\61\74\65";
}
.icons-reload:before {
content: "\72\65\6c\6f\61\64";
}
.icons-unload:before {
content: "\75\6e\6c\6f\61\64";
}
.icons-trophy:before {
content: "\74\72\6f\70\68\79";
}
File diff suppressed because it is too large. Load diff
@@ -1,374 +0,0 @@
a {
text-decoration: none;
}
div[data-role="page"] {
padding-bottom: 0!important;
}
.clear:after {
clear: both;
content: "";
display: block;
height: 0;
visibility: hidden;
}
.main-menu {
display: block;
position: fixed;
width: 100%;
left: 0;
top: -50px;
display: block;
z-index: 49;
-webkit-transition: all 0.3s linear;
-moz-transition: all 0.3s linear;
-ms-transition: all 0.3s linear;
-o-transition: all 0.3s linear;
transition: all 0.3s linear;
}
.main-menu.expanded {
top: 50px;
-webkit-transition: all 0.3s linear;
-moz-transition: all 0.3s linear;
-ms-transition: all 0.3s linear;
-o-transition: all 0.3s linear;
transition: all 0.3s linear;
}
.main-menu ul {
background-color: #333;
width: 210px;
list-style: none;
margin: 0 auto;
padding: 0;
-webkit-box-shadow: 0 3px 10px rgba(0,0,0,.8), inset 0 3px 15px rgba(0,0,0,.3);;
-webkit-border-radius: 0 0 10px 10px;
}
.main-menu ul li {
float: left;
width: 58px;
border-right: 1px solid #292929;
border-left: 1px solid #3F3F3F;
padding: 0 5px;
}
.main-menu ul li:last-child {
-webkit-border-radius: 0 0 10px 0;
border-right-color: transparent;
}
.main-menu ul li:first-child {
-webkit-border-radius: 0 0 0 10px;
border-left-color: transparent;
}
.main-menu ul li:hover {
background-color: #b4111a;
}
.main-menu ul i {
font-size: 1.4em;
width: 100%;
display: block;
margin: 10px auto 0;
}
.main-menu ul span {
display: block;
margin-bottom: 10px;
text-align: center;
}
.main-menu ul li a:link, .main-menu ul li a:visited {
font-size: .6em;
color: #DFDFDF!important;
text-shadow: 0 -1px 0px #000;
text-decoration: none;
display: block;
}
.main-menu ul li a:hover, .main-menu ul li a:active {
color: #DFDFDF!important;
}
.global {
position: relative;
background-color: #333;
overflow-x: hidden;
width: 100%;
-webkit-box-shadow: -3px 0px 15px rgba(0,0,0,.5);
padding-top: 50px;
padding-bottom: 64px;
/*margin-bottom: -64px;*/
}
.header {
position: fixed;
top: 0;
left: 0;
right: 0;
background-color: #000;
padding: 0;
border: none;
z-index: 50;
/*background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#545b60), to(#191a1c));*/
background-image: -webkit-linear-gradient(top, #5282A6, #133757);
-webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(127, 149, 165, 1), 0 -1px 0 rgba(31, 32, 36, 1) inset;
}
.header h1.ui-title {
margin: 8px 30%;
position: relative;
}
.header i.openmenu {
position: absolute;
display: block;
top: 40px;
left: 50%;
margin-left: -15px;
font-size: 20px;
/*color: #727272;*/
color: #7CA6C5;
/*background-color: #252525;*/
background-color: #144366;
border-radius: 0 0 5px 5px;
height: 15px;
line-height: 16px;
box-shadow: 1px 2px 2px rgba(0, 0, 0, .5);
}
.header .language .ui-btn-text {
left: 0;
}
.header .language .ui-btn-text i {
font-size: 1.1em;
margin-top: .33em;
}
.header .language .ui-icon {
background-image: none;
}
.header .ui-btn-up-a {
border: 1px solid #133547;
background-color: #0C4C64;
background-image: -webkit-gradient(linear, left top, left bottom, from( #0D6691 ), to( #0E3A4B ));
background-image: -webkit-linear-gradient( #0D6691 , #0E3A4B );
background-image: -moz-linear-gradient( #0D6691 , #0E3A4B );
background-image: -ms-linear-gradient( #0D6691 , #0E3A4B );
background-image: -o-linear-gradient( #0D6691 , #0E3A4B );
background-image: linear-gradient( #0D6691 , #0E3A4B );
}
.header h1 img {
height: 30px;
width: auto;
}
.header.ui-header > .ui-btn {
margin-top: 6px;
}
.content {
position: relative;
background-color: #FFF;
min-height: 330px;
background: url(<%= asset_path "mobile/newlist-bg.jpg" %>) repeat 0 0 transparent;
}
/*.content .list {
position: relative;
z-index: 5;
box-shadow: -5px 0px 15px rgba(0,0,0,.8)
}*/
.content .newlist {
margin: 0 auto;
padding: 10px;
}
.content .newitem {
display: inline-block;
float: left;
width: 280px;
min-height: 490px;
max-height: 490px;
background-color: #FFFFFF;
padding: 10px;
margin: 0 10px 10px 0;
box-shadow: 0px 3px 5px rgba(0,0,0,.1);
}
#index .content .newpic {
width: 280px;
height: 200px;
margin: 0 auto;
}
#index .content .newstitle {
font-size: 1.4em;
margin: 1em 0;
}
#index .content .newsDate {
font-size: 1em;
color: #8D8D8D;
}
#index .content .newsummary {
padding: 0 0 20px;
margin-bottom: 0;
}
#announcement_content .content .newpic {
width: 320px;
height: 220px;
margin: 0 auto;
}
#announcement_content .content .newstitle {
font-size: 1.4em;
padding: 0 10px;
margin: 1em 0;
}
#announcement_content .content .newsDate {
padding: 0 10px;
font-size: 1em;
color: #8D8D8D;
}
#announcement_content .content .newsummary {
padding: 0 10px 20px;
margin-bottom: 0;
}
#announcement_content .content {
padding: 10px;
}
#map div[data-role="content"] {
padding: 0;
}
#map .global {
padding: 0;
}
#page_content .global {
overflow-x: auto;
-webkit-box-shadow: none;
background-color: #f9f9f9;
}
#page_content .content {
background-image: none;
padding: 10px;
background-color: #f9f9f9;
}
#page_content .content .newsummary > * {
width: 750px!important;
}
#page_content .content .newsummary > *:after {
clear: both;
height: 0;
display: block;
content: "";
visibility: hidden;
}
div[id^="dialog"] .global {
padding: 0;
}
div[id^="dialog"] .content {
padding: 10px;
height: auto!important;
min-height: 70px;
}
/*.content .newitem:first-child {
margin-left: 0;
}
.content .newitem:last-child {
margin-right: 0;
}*/
.pagination {
height: 36px;
margin: 18px 0 0;
padding-bottom: 18px;
text-align: center;
}
.pagination ul {
padding: 0;
display: inline-block;
margin-left: 0;
margin: 0;
-webkit-border-radius: 3px;
-moz-border-radius: 3px;
border-radius: 3px;
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
-moz-box-shadow: 0 1px 2px rgba(0,0,0,0.05);
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}
.pagination li {
display: inline;
}
.pagination li:first-child a {
border-left-width: 1px;
-webkit-border-radius: 3px 0 0 3px;
-moz-border-radius: 3px 0 0 3px;
border-radius: 3px 0 0 3px;
}
.pagination li:last-child a {
-webkit-border-radius: 0 3px 3px 0;
-moz-border-radius: 0 3px 3px 0;
border-radius: 0 3px 3px 0;
}
.pagination .active a {
color: #999;
cursor: default;
}
.pagination a:hover, .pagination .active a {
background-color: #E8E8E8;
}
.pagination a {
background-color: white;
}
.pagination a {
float: left;
padding: 0 10px;
line-height: 30px;
text-decoration: none;
border: 1px solid #DDD;
border-left-width: 0;
font-size: .8em;
}
.footer {
color: #999;
/*background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#545b60), to(#191a1c));*/
background-image: -webkit-linear-gradient(top, #5282A6, #133757);
}
.footer div[data-role="navbar"] i {
display: block;
width: 100%;
margin-bottom: 5px;
}
@media(min-width:320px){
}
@media(min-width: 480px){
.content .newitem {
width: 440px;
}
}
@media(min-width:600px) {
.main-menu ul {
width: 420px;
}
.main-menu ul li {
width: 128px;
}
}
@media(min-width:768px) {
.main-menu ul {
width: 480px;
}
.main-menu ul li {
width: 148px;
}
.content .newitem {
width: 280px;
}
}
@media(min-width:800px) {
.main-menu ul {
width: 480px;
}
.main-menu ul li {
width: 148px;
}
}
@media(min-width:961px) {
.main-menu ul {
width: 480px;
}
.main-menu ul li {
width: 148px;
}
}
@media(min-width: 1024px) {
.main-menu ul {
width: 600px;
}
.main-menu ul li {
width: 188px;
}
.content .newitem {
width: 280px;
}
}
@media(min-width:1280px) {
}
@@ -223,7 +223,7 @@
#orbit-bar {
margin: 0;
font-family: "Chivo";
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 12px;
line-height: 20px;
color: #333333;
+32 -18
View File
@@ -1,10 +1,20 @@
class Admin::AdBannersController < OrbitBackendController
open_for_visitor :only => [:index, :show]
open_for_sub_manager
def index
@ad_banners = AdBanner.all.page(params[:page]).per(10)
before_filter :force_order_for_visitor,:only=>[:index, :show]
before_filter :force_order_for_user,:except => [:index, :show]
before_filter :for_app_sub_manager,:except => [:index, :show]
before_filter :for_app_manager,:except => [:index,:show,:update,:realtime_preview]
def rename
@ad_banner = AdBanner.find(params[:id])
@ad_banner.title = params[:body]
render :json => {:success =>@ad_banner.save!}
end
def destroy
@ad_banner = AdBanner.find(params[:id])
@ad_banner.destroy
redirect_to admin_ad_banners_url
end
def show
@@ -21,31 +31,35 @@ class Admin::AdBannersController < OrbitBackendController
def create
@ad_banner = AdBanner.new(params[:ad_banner])
if @ad_banner.save
@active = @ad_banner
redirect_to admin_ad_banners_url
#respond_to do |format|
# format.js {render 'new_created_node'}
#end
else
@ad_banner = AdBanner.new(params[:ad_banner])
render :new
render 'create_error_msg'
end
end
def edit
@ad_banner = AdBanner.find(params[:id])
render layout: false
end
def update
@ad_banner = AdBanner.find(params[:id])
if @ad_banner.update_attributes(params[:ad_banner])
redirect_to admin_ad_banners_url, :status => 303
else
render :edit
end
end
def destroy
@ad_banner = AdBanner.find(params[:id])
@ad_banner.destroy
@ad_banner.update_attributes(params[:ad_banner])
@ad_banner.save
redirect_to admin_ad_banners_url
end
def realtime_preview
@ad_banner = AdBanner.find( params[:id] ).preview_clone
@ad_banner.update_attributes(params[:ad_banner])#.update_attributes(params[:ad_images])
end
def index
@ad_banners = AdBanner.all
@active = @ad_banners.first
end
end
+29 -25
View File
@@ -1,56 +1,60 @@
class Admin::AdImagesController < Admin::AdBannersController
before_filter :only => [ :new, :edit ] do
@ad_banners = AdBanner.all
@tags = get_tags
end
# before_filter :force_order_for_user
# before_filter :for_app_sub_manager
# before_filter :for_app_manager
def initialize
super
@app_title = "ad_banner"
end
def index
@ad_images = AdImage.all.page(params[:page]).per(10)
#@ad_banner = AdBanner.find params[:ad_banner_id]
#@ad_images = @ad_banner.ad_images.all.page(params[:page]).per(10)
@ad_images = AdImage.all.page(params[:page]).per(10)
end
def edit
#@ad_banner = AdBanner.find params[:ad_banner_id]
@ad_image = AdImage.find(params[:id])
@tags = get_tags
end
def update
@ad_image = AdImage.find(params[:id])
if @ad_image.update_attributes(params[:ad_image])
redirect_to admin_ad_images_url
else
@ad_banners = AdBanner.all
@tags = get_tags
render action: :edit
end
@ad_image.update_attributes(params[:ad_image])
redirect_to admin_ad_images_path
end
def new
def new
#ad_banner = AdBanner.find params[:ad_banner_id]
#@ad_image =ad_banner.ad_images.build
@ad_image = AdImage.new
@ad_image.postdate = Date.today
@ad_image.deadline = Date.today + 30
@ad_image.post_date = Date.today
@ad_image.unpost_date = Date.today + 30
@tags = get_tags
#render :action => 'new',:url=> {:ad_banner_id => params.has_key?(:ad_banner_id)? params[:ad_banner_id],nil}
end
def create
@ad_image = AdImage.new(params[:ad_image])
# @ad_banner = AdBanner.find params[:ad_banner][:id]
@ad_image = AdImage.new params[:ad_image]
#@ad_image.to_save = true
#@ad_banner.ad_images << ad_image
if @ad_image.save
redirect_to admin_ad_images_url
else
@ad_banners = AdBanner.all
@tags = get_tags
@ad_image = AdImage.new(params[:ad_image])
render action: :new
redirect_to admin_ad_images_path
end
end
def destroy
#@ad_banner = AdBanner.find params[:ad_banner_id]
@ad_image = AdImage.find params[:id]
if @ad_image.destroy
redirect_to admin_ad_images_url
flash[:notice] = t('ad.success_destroy_ad_image')
redirect_to admin_ad_images_path
end
end
+14 -37
View File
@@ -3,17 +3,7 @@ class Admin::AssetsController < OrbitBackendController
before_filter :setup_vars
def index
@assets = (params[:sort] || @filter) ? get_sorted_and_filtered("asset") : Asset.all.desc(:created_at).page(params[:page]).per(10)
if params[:type] == "images"
@assets = @assets.where(:content_type => /^image/)
end
@tag = ModuleTag.new
@module_app = ModuleApp.find(params[:module_app_id]) rescue nil
raise ModuleAppError, 'Can not find ModuleApp' if @module_app.nil?
@module_app_id = @module_app.id rescue nil
render :layout => "assets"
@assets = (params[:sort] || @filter) ? get_sorted_and_filtered("asset") : Asset.all.page(params[:page]).per(10)
end
def show
@@ -32,8 +22,12 @@ class Admin::AssetsController < OrbitBackendController
def edit
@asset = Asset.find(params[:id])
@asset_categories = AssetCategory.all
@tags = get_tags
render layout: false
respond_to do |format|
format.html {}
format.js { render 'js/show_pop_up', :locals => {:partial => 'admin/assets/edit'} }
end
end
def create
@@ -70,7 +64,10 @@ class Admin::AssetsController < OrbitBackendController
def update
@asset = Asset.find(params[:id])
if @asset.update_attributes(params[:asset])
render layout: false
respond_to do |format|
format.html { redirect_to admin_assets_url }
format.js { render 'js/remove_pop_up_and_reload_content', :locals => {:function => 'replaceWith', :id => "asset_#{@asset.id}", :value => @asset, :values => nil, :partial => 'admin/assets/asset', :locals => nil} }
end
else
flash[:error] = t('update.fail')
@asset_categories = AssetCategory.all
@@ -98,31 +95,11 @@ class Admin::AssetsController < OrbitBackendController
redirect_to assets_url(:filter => params[:filter], :direction => params[:direction], :sort => params[:sort], :sort_options => params[:sort_options])
end
def delete_files
@files = params[:files]
@files.each do |file|
asset = Asset.find(file)
asset.destroy
end
@assets = (params[:sort] || @filter) ? get_sorted_and_filtered("asset") : Asset.all.desc(:created_at).page(params[:page]).per(10)
if params[:type] == "images"
@assets = @assets.where(:content_type => /^image/)
end
# render :json =>{"success"=>true}.to_json
end
def file_upload
@files = params['files']
a = Array.new
@files.each do |file|
@asset = current_user.assets.new
@asset.data = file
@asset.title_translations = {:en => file.original_filename, :zh_tw => file.original_filename}
# @asset.title_translations[:zh_tw] = file.original_filename
@asset.save!
a << {"url"=>@asset.data.url}
end
render :json=>{"files"=>a}.to_json
@asset = Asset.new
@asset_categories = AssetCategory.all
@tags = get_tags
render :layout => false
end
def file_select
@@ -1,13 +1,13 @@
class Admin::AuthorizationsController < OrbitBackendController
prepend_before_filter :admin_or_manager
before_filter :admin_or_manager
def index
@module_apps ||= ModuleApp.any_of({is_authorizable: true}, {is_approvable: true}).order_by([:title, :asc])
@module_apps ||= ModuleApp.where(is_authorizable: true).order_by([:title, :asc])
if @module_apps && @module_apps.include?(@module_app)
if @type
case @type
when 'category_authorization', 'category_approval'
when 'category', 'approval'
if @module_app.has_category
@objects = @module_app.categories
else
@@ -18,12 +18,12 @@ class Admin::AuthorizationsController < OrbitBackendController
end
unless @objects.blank?
@object ||= @objects.first
@users = @object.get_authorization_by_title("#{@type}_#{@module_app.key}").authorized_users rescue nil
@users = @object.get_object_auth_by_title("#{@type}_#{@module_app.key}").auth_users
else
@error = t(:no_data)
end
else
@users = @module_app.managers
@users = @module_app.managing_users
end
elsif @module_apps
@module_app = @module_apps.first
@@ -33,34 +33,35 @@ class Admin::AuthorizationsController < OrbitBackendController
end
end
def add_roles
roles = Role.find(params[:role_ids]) rescue nil
unless roles.nil?
authorization = get_or_create_authorization
add_roles_to_auth(authorization, roles)
def add(users)
unless users.blank?
if @type
if @object
object_auth = @object.get_object_auth_by_title("#{@type}_#{@module_app.key}")
add_users_to_object_auth(object_auth, users)
else
@error = t(:no_data)
end
else
add_managers(users) unless users.blank?
end
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
end
def add_sub_roles
sub_roles = SubRole.find(params[:sub_role_ids]) rescue nil
unless sub_roles.nil?
authorization = get_or_create_authorization
add_sub_roles_to_auth(authorization, sub_roles)
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
@users = users
render 'admin/authorizations/insert_users'
end
def add_users
users = User.find(params[:user_ids]) rescue nil
unless users.nil?
authorization = get_or_create_authorization
add_users_to_auth(authorization, users)
users = User.find(params[:user_ids]) rescue []
add(users)
end
def add_roles
roles = Role.find(params[:role_ids]) rescue []
users = roles.inject([]) do |users, role|
users += role.users.all.entries
users
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
add(users)
end
def modal_select
@@ -69,103 +70,63 @@ class Admin::AuthorizationsController < OrbitBackendController
if @type
@object_id = @object.id if @object
@sorted_users = roles.inject({}) do |users, role|
users[role] = role.users.where(admin: false) - existing_users - @module_app.managers
users[role] = role.users.where(admin: false).not_guest_user - existing_users - @module_app.managing_users
users
end
else
@sorted_users = roles.inject({}) do |users, role|
users[role] = role.users.where(admin: false) - existing_users
users[role] = role.users.where(admin: false).not_guest_user - existing_users
users
end
end
end
def remove_roles
roles = Role.find(params[:role_ids]) rescue []
unless roles.blank?
authorization = get_or_create_authorization
remove_roles_form_auth(authorization, roles)
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
end
def remove_sub_roles
sub_roles = SubRole.find(params[:sub_role_ids]) rescue []
unless sub_roles.blank?
authorization = get_or_create_authorization
remove_sub_roles_from_auth(authorization, sub_roles)
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
end
def remove_users
@users = User.find(params[:ids]) rescue []
unless @users.blank?
authorization = get_or_create_authorization
remove_users_from_auth(authorization, @users)
if @type
if @object
object_auth = @object.get_object_auth_by_title("#{@type}_#{@module_app.key}")
remove_users_form_object_auth(object_auth, @users)
else
@error = t(:no_data)
end
else
remove_managers(@users)
end
end
@users = authorization.authorized_users
render 'admin/authorizations/reload_users'
render 'admin/authorizations/remove_users'
end
protected
def add_roles_to_auth(authorization, roles)
authorization.add_roles(roles)
end
def add_sub_roles_to_auth(authorization, sub_roles)
authorization.add_sub_roles(sub_roles)
end
def add_users_to_auth(authorization, users)
authorization.add_users(users)
end
def get_or_create_authorization
case @type
when 'category_approval'
if @object
@object.auth_approval || @object.create_auth_approval(module_app_id: @module_app.id, title: "#{@type}_#{@module_app.key}")
else
@error = t(:no_data)
end
when 'category_authorization'
if @object
@object.auth_sub_manager || @object.create_auth_sub_manager(module_app_id: @module_app.id, title: "#{@type}_#{@module_app.key}")
else
@error = t(:no_data)
end
when nil
@module_app.auth_manager || @module_app.create_auth_manager(module_app_id: @module_app.id, title: @module_app.key)
else
auth = @object.get_authorization_by_title("#{@type}_#{@module_app.key}")
unless auth
auth = @object.create_auth_approval(module_app_id: @module_app.id, title: "#{@type}_#{@module_app.key}") if @type.include?('approval')
auth = @object.create_auth_sub_manager(module_app_id: @module_app.id, title: "#{@type}_#{@module_app.key}") if @type.include?('authorization')
end
auth
def add_managers(users)
users.each do |user|
@module_app.assign_manager(user, current_user)
end
end
def remove_roles_form_auth(authorization, roles)
authorization.remove_roles(roles)
def add_users_to_object_auth(object_auth, users)
users.each do |user|
object_auth.add_user_to_privilege_list(user)
end
end
def remove_sub_roles_from_auth(authorization, sub_roles)
authorization.remove_sub_roles(sub_roles)
def remove_managers(users)
users.each do |user|
@module_app.remove_manager(user)
end
end
def remove_users_from_auth(authorization, users)
authorization.remove_users(users)
def remove_users_form_object_auth(object_auth, users)
users.each do |user|
object_auth.remove_user_from_privilege_list(user)
end
end
private
def admin_or_manager
@override_can_use = true
setup_vars
authenticate_user!
user_is_manager?
@@ -175,7 +136,7 @@ class Admin::AuthorizationsController < OrbitBackendController
@module_app = ModuleApp.first(conditions: {:key => params[:module]} ) if params[:module]
@type = params[:type].underscore if params[:type]
if @type
@klass = @type.gsub('_authorization', '').gsub('_approval', '').classify.constantize rescue nil
@klass = @type.classify.constantize rescue nil
@object = @klass.find(params[:id]) rescue nil
end
end
@@ -1,6 +1,12 @@
class Admin::CategoriesController < OrbitBackendController
open_for_manager
# TODO = put back ========================
# before_filter :force_order_for_visitor, only: [:index]
# before_filter :force_order_for_user, except: [:index]
# before_filter :for_app_sub_manager, except: [:index]
# ========================================
before_filter :setup_vars
# ========================================
def index
@categories = get_categories_for_index
@@ -31,7 +37,7 @@ class Admin::CategoriesController < OrbitBackendController
def update
@category = Category.find(params[:id])
if @category.update_attributes(params[:category])
redirect_to admin_module_app_categories_url(@module_app_id), :status => 303
redirect_to admin_module_app_categories_url(@module_app_id)
else
flash.now[:error] = t('update.error.category')
render action: :edit
@@ -1,6 +1,8 @@
class Admin::DashboardsController < OrbitBackendController
open_for_visitor
#before_filter :set_current_user
#before_filter :authenticate_user!, :except => [:index]
# before_filter :is_admin?
layout "basic_back_end"
+8 -3
View File
@@ -2,7 +2,12 @@ class Admin::ItemsController < OrbitBackendController
layout "structure"
open_for_admin
# TODO = put back ========================
# before_filter :authenticate_user!
# before_filter :find_parent_item
# before_filter :is_admin?
# before_filter :set_current_item
#=========================================
def index
if params[:item_id]
@@ -22,8 +27,8 @@ class Admin::ItemsController < OrbitBackendController
def update_position
item = Item.find(params[:id])
item.shift_to(params[:parent_id], params[:position].to_i)
render :nothing => true, status: 200
item.shift_to(params[:parent_id], params[:position])
render :nothing => true
end
end
@@ -1,5 +1,9 @@
class Admin::LinksController < Admin::ItemsController
def show
@item ||= Link.find(params[:id])
end
def new
@item = Link.new
@item.parent = Page.find(params[:parent_id]) rescue nil
@@ -1,7 +1,13 @@
class Admin::ModuleTagsController < OrbitBackendController
include OrbitTag::Merging
open_for_manager
# TODO = put back ========================
# before_filter :force_order_for_visitor, only: [:index]
# before_filter :force_order_for_user, except: [:index]
# before_filter :for_app_sub_manager, except: [:index]
# ========================================
before_filter :setup_vars
# ========================================
helper 'admin/tags'
@@ -27,7 +33,6 @@ class Admin::ModuleTagsController < OrbitBackendController
redirect_to admin_module_tags_url(module_app_id: @module_app_id)
else
@tag = ModuleTag.new(params[:module_tag])
flash.now[:error] = t('create.error.tag')
render :action => "new"
end
end
@@ -37,7 +42,6 @@ class Admin::ModuleTagsController < OrbitBackendController
if @tag.update_attributes(params[:module_tag])
redirect_to admin_module_tags_url(module_app_id: @module_app_id)
else
flash.now[:error] = t('update.error.tag')
render :action => "edit"
end
end
+1 -2
View File
@@ -5,8 +5,7 @@ class Admin::PagesController < Admin::ItemsController
def show
@item = Page.find(params[:id])
@no_orbit_bar = true
@edit = true
render :text => parse_page_content(@item), :layout => 'page_layout'
render layout: 'page_layout'
end
def new
@@ -1,83 +0,0 @@
class Admin::PersonalPluginIntrosController < OrbitMemberController
include OrbitControllerLib::DivisionForDisable
before_filter :authenticate_user!
before_filter :is_admin?
def index
get_types
@plugin_intro = @types.where(:user_id => params[:user_id]).first
if @plugin_intro.blank?
@set_type = @types.new()
@url = eval("panel_#{@app_type_name}_back_end_#{@app_type}s_path(:user_id=>params[:user_id])")
@verb = :post
else
@set_type = @types.find(@plugin_intro.id)
@url = polymorphic_path(["panel_#{@app_type_name}_back_end", @plugin_intro])
@verb = :put
end
end
def show
end
def new
end
def edit
end
def create
get_types
@plugin_intro = @types.new(params[:plugin_intro])
respond_to do |format|
if @plugin_intro.save
format.html { redirect_to(admin_users_new_interface_url(:id=>params[:plugin_intro][:user_id],:show_plugin_profile=>@reback_name)) }
end
end
end
def update
get_types
@plugin_intro = @types.find(params[:id])
respond_to do |format|
if @plugin_intro.update_attributes(params[:plugin_intro])
format.html { redirect_to(admin_users_new_interface_url(:id=>params[:plugin_intro][:user_id],:show_plugin_profile=>@reback_name)) }
end
end
end
def destroy
end
protected
def get_types
@types = @app_type.classify.constantize
end
end
+9 -9
View File
@@ -4,19 +4,19 @@ class Admin::PluginsController < ApplicationController
def index
@plugins = OrbitApp::Plugin::Registration.all
@plugins = OrbitApp::Plugin::Registration.all
if(!params[:show_plugin_profile].nil?)
@right_partial = OrbitApp::Plugin::Registration.find_by_app_name(params[:show_plugin_profile]).admin_partial_path
@right_partial = OrbitApp::Plugin::Registration.find_by_key(params[:show_plugin_profile]).admin_partial_path
if !@right_partial.blank?
respond_to do |format|
format.html { redirect_to( @right_partial ) }
end
else
@right_partial = ""
end
if !@right_partial.blank?
respond_to do |format|
format.html { redirect_to( @right_partial ) }
end
else
@right_partial = ""
end
else
@right_partial = ""
@@ -55,15 +55,6 @@ class Admin::SitesController < OrbitBackendController
end
def search_engine
end
def preference
end
def ui_theme
end
+3 -3
View File
@@ -1,8 +1,8 @@
class Admin::TagsController < OrbitBackendController
include OrbitTag::Merging
open_for_user only: [:index]
open_for_manager
before_filter :force_order_for_visitor, only: [:index]
before_filter :force_order_for_user, except: [:index]
def index
@tags = @module_app.module_tags
@@ -33,7 +33,7 @@ class Admin::TagsController < OrbitBackendController
def update
@tag = ModuleTag.find(params[:id])
if @tag.update_attributes(params[:module_tag])
redirect_to action: :index, :status => 303
redirect_to action: :index
else
flash.now[:error] = t('update.error.tag')
render :action => "edit"
@@ -1,11 +1,19 @@
class Admin::UsersNewInterfaceController < OrbitMemberController
helper MemberHelper
helper OrbitBackendHelper
# before_filter :authenticate_user!
# before_filter :set_attribute, :only => [:index, :show, :new, :edit]
before_filter :force_order_for_visitor,:only=>[:index,:show]
before_filter :force_order_for_user,:except => [:index,:show]
before_filter :set_attribute,:except => [:index,:show]
open_for_user :only => [:setting_account, :edit_user_data, :update]
open_for_visitor :only => [:index, :show]
def setup_vars
# @app_title ||= controller_path.split('/')[1].singularize
# @module_app ||= ModuleApp.first(conditions: {:key => @app_title} )
# raise ModuleAppError, 'Can not find ModuleApp' if @module_app.nil?
end
def index
get_tags
@@ -18,64 +26,50 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
@filter = params[:filter]
@mq = params[:mq]
@new_filter = params[:new_filter]
new_filter = params[:new_filter]
if @filter && params[:clear]
@filter.delete(params[:type])
elsif @filter && @new_filter
if @filter.has_key?(@new_filter[:type]) && @filter[@new_filter[:type]].include?(@new_filter[:id].to_s)
@filter[@new_filter[:type]].delete(@new_filter[:id].to_s)
elsif @filter.has_key?(@new_filter[:type])
@filter[@new_filter[:type]] << @new_filter[:id].to_s
elsif @filter && new_filter
if @filter.has_key?(new_filter[:type]) && @filter[new_filter[:type]].include?(new_filter[:id].to_s)
@filter[new_filter[:type]].delete(new_filter[:id].to_s)
elsif @filter.has_key?(new_filter[:type])
@filter[new_filter[:type]] << new_filter[:id].to_s
else
@filter.merge!({@new_filter[:type] => [@new_filter[:id].to_s]})
@filter.merge!({new_filter[:type] => [new_filter[:id].to_s]})
end
elsif @new_filter
@filter = {@new_filter[:type] => [@new_filter[:id].to_s]}
elsif new_filter
@filter = {new_filter[:type] => [new_filter[:id].to_s]}
end
if @filter.blank? and @mq.blank?
if @filter.blank?
render case params[:at]
when 'summary'
@users=User.not_guest_user.page(page_num).per(12).desc("_id").includes('avatar')
@users=User.not_guest_user.page(page_num).per(12).asc("_id").includes('avatar')
"index_summary"
when 'thumbnail'
@users=User.not_guest_user.page(page_num).per(36).desc("_id").includes('avatar')
@users=User.not_guest_user.page(page_num).per(36).asc("_id").includes('avatar')
"index_thumbnail"
else
@users=User.not_guest_user.page(page_num).per(10).desc("_id").includes('avatar')
@users=User.not_guest_user.page(page_num).per(10).asc("_id").includes('avatar')
"index"
end
elsif @filter.blank? and !@mq.blank?
else
render case params[:at]
when 'summary'
@users=User.not_guest_user.any_of({:user_id => /#{@mq}/i}, {:first_name => /#{@mq}/i}, {:last_name => /#{@mq}/i}, {:email => /#{@mq}/i}, {:office_tel => /#{@mq}/i}).desc("_id").includes('avatar')
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(12).asc("_id").includes('avatar')
"index_summary"
when 'thumbnail'
@users=User.not_guest_user.any_of({:user_id => /#{@mq}/i}, {:first_name => /#{@mq}/i}, {:last_name => /#{@mq}/i}, {:email => /#{@mq}/i}, {:office_tel => /#{@mq}/i}).desc("_id").includes('avatar')
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(36).asc("_id").includes('avatar')
"index_thumbnail"
else
@users=User.not_guest_user.any_of({:user_id => /#{@mq}/i}, {:first_name => /#{@mq}/i}, {:last_name => /#{@mq}/i}, {:email => /#{@mq}/i}, {:office_tel => /#{@mq}/i}).desc("_id").includes('avatar')
"index"
end
elsif !@filter.blank? and @mq.blank?
render case params[:at]
when 'summary'
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(12).desc("_id").includes('avatar')
"index_summary"
when 'thumbnail'
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(36).desc("_id").includes('avatar')
"index_thumbnail"
else
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(10).desc("_id").includes('avatar')
@users=User.not_guest_user.any_in(:role_ids=>@filter['role']).page(page_num).per(10).asc("_id").includes('avatar')
"index"
end
@@ -84,18 +78,9 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
end
def show
@user = User.find(params[:id])
@plugins = OrbitApp::Plugin::Registration.all
@ppname = Array.new
@plugins.each do |aa|
@ppname << [aa.sort_number.to_i, [aa.name, aa.app_name, aa.intro_app_name, aa.front_partial_path]]
end
@plugin_shows = @ppname.sort.collect {|v| {"name"=>v[1][0],"app_name"=>v[1][1],"intro_app_name"=>v[1][2],"front_partial_path"=>v[1][3]} }
@profile_data = []
@teacher_data = []
@student_data = []
@@ -108,11 +93,9 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
if(!params[:show_plugin_profile].nil?)
@right_partial = OrbitApp::Plugin::Registration.find_by_app_name(params[:show_plugin_profile]).profile_partial_path rescue 'plugin_summary'
@plugin_app_name = OrbitApp::Plugin::Registration.find_by_app_name(params[:show_plugin_profile]).name rescue nil
@right_partial = OrbitApp::Plugin::Registration.find_by_key(params[:show_plugin_profile]).profile_partial_path rescue 'plugin_summary'
else
@right_partial = "plugin_summary"
@plugin_app_name = ''
end
# @user.attribute_values.each{|att_val|
@@ -182,46 +165,6 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
def edit_passwd
# @disable_all_field = false
@user = User.find(params[:users_new_interface_id])
if current_user.id == @user.id
redirect_to :action => :index
end
end
def edit_privilege
@user = User.find(params[:users_new_interface_id])
if current_user.id == @user.id
redirect_to :action => :index
end
end
def edit_user_data
if params[:users_new_interface_id].blank?
redirect_to :action => :index
else
@user = User.find(params[:users_new_interface_id])
if current_user.id != @user.id
redirect_to :action => :index
end
@form_index = 0
get_info_and_roles
end
end
def setting_account
if params[:users_new_interface_id].blank?
redirect_to :action => :index
else
@user = User.find(params[:users_new_interface_id])
if current_user.id != @user.id
redirect_to :action => :index
end
end
end
def update
@@ -244,49 +187,6 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
render :action => :edit_passwd, :notice => flash.now[:error]
end
elsif params[:edit_type] == 'edit_user_data'
if current_user.id != @user.id
redirect_to :action => :index
end
@user.update_attributes(params[:user])
attribute_values_key = params[:user].has_key?('new_attribute_values') ? 'new_attribute_values' : 'attribute_values'
attribute_values = params[:user].delete(attribute_values_key)
@user.save
redirect_to :action => :show
elsif params[:edit_type] == 'setting_account'
if current_user.id != @user.id
redirect_to :action => :index
end
if !@user.valid_password?(params[:old_password])
flash.now[:error] = t("users.valid_old_password")
end
if !flash.now[:error] && @user.update_attributes(params[:user])
redirect_to :action => :show
else
render :action => :setting_account, :notice => flash.now[:error]
end
elsif params[:edit_type] == 'edit_privilege'
if @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_privilege, :notice => flash.now[:error]
end
else
@user.update_attributes(params[:user])
@@ -325,65 +225,7 @@ class Admin::UsersNewInterfaceController < OrbitMemberController
@user.destroy
end
# redirect_to :action => :index
respond_to do |format|
format.html { redirect_to(admin_users_new_interface_index_url(:at=>params[:at])) }
# format.xml { head :ok }
format.js
end
end
def edit_order_card
@users = User.not_guest_user
@type = 'card'
render 'edit_order'
end
def edit_order_list
@users = User.not_guest_user
@type = 'list'
render 'edit_order'
end
def update_order_card
@error = false
if params[:users].present?
to_go = params[:users][:position].to_i
user_at_position = User.where(position: to_go).first
user = User.find(params[:users][:id])
if user_at_position
if user.position > user_at_position.position
user.move_above(user_at_position)
else
user.move_below(user_at_position)
end
end
end
render nothing: true, status: 200
end
def update_order_list
@error = []
if params[:users].present?
params[:users].values.sort.each do |pair|
to_go = pair[0].to_i
if to_go > 0
user_at_position = User.where(position: to_go - 1).first
user = User.find(pair[1])
if user_at_position && !(user_at_position == user)
if user.position > user_at_position.position
user.move_above(user_at_position)
else
user.move_below(user_at_position)
end
elsif to_go > User.count
user.move_to_bottom
end
end
end
end
@users = User.not_guest_user
redirect_to :action => :index
end
protected
+6 -13
View File
@@ -18,7 +18,7 @@ class ApplicationController < ActionController::Base
helper_attr :site_valid_locales
def check_backend_openness
if Site.first.backend_openness_on
if !Me.backend_openness_on
redirect_to '/users/sign_in' if not (authenticate_user! and is_member? )
end
end
@@ -140,23 +140,16 @@ class ApplicationController < ActionController::Base
# update session if passed
session[:locale] = params[:locale] if params[:locale]
browser_locale = condition = nil
default_locale = condition = nil
# check if locale is valid for non site pages
if LIST[:forbidden_item_names].include?(env['PATH_INFO'].split('/')[1].to_s)
condition = VALID_LOCALES.include?(session[:locale])
#check if the default locale is present or not
elsif @site.default_locale.present?
default_locale = @site.default_locale
condition = @site.in_use_locales.include?(default_locale)
elsif !@site.enable_language_detection
#check enable langauge detection
browser_locale = request.env['HTTP_ACCEPT_LANGUAGE'].scan(/^[a-z]{2}/).first rescue nil
condition = @site.in_use_locales.include?(browser_locale)
elsif session[:locale]
condition = @site.in_use_locales.include?(session[:locale])
else
browser_locale = request.env['HTTP_ACCEPT_LANGUAGE'].scan(/^[a-z]{2}/).first rescue nil
condition = @site.in_use_locales.include?(browser_locale)
end
session[:locale] = condition ? (default_locale || browser_locale || session[:locale]) : I18n.default_locale.to_s
session[:locale] = condition ? (browser_locale || session[:locale]) : I18n.default_locale.to_s
I18n.locale = session[:locale].to_sym
@site_in_use_locales = site_locales_default_head(@site.in_use_locales)
@site_valid_locales = site_locales_default_head(@site.valid_locales)
@@ -325,7 +318,7 @@ class ApplicationController < ActionController::Base
a << object if (value.include?(object.category.id.to_s) rescue nil)
end
objects = a.uniq
when 'tags'
when 'tag'
a = Array.new
objects.each do |object|
object.tags.each do |tag|
+1 -1
View File
@@ -1,4 +1,4 @@
class DesktopAppsController < ApplicationController
class DesktopAppsController < OrbitBackendController
require "net/http"
require "uri"
require 'zip/zip'
+2 -14
View File
@@ -1,16 +1,12 @@
class DesktopController< ApplicationController
layout 'desktop'
before_filter :authenticate_user!
before_filter :check_desktop_open, :only => [:index,:show]
#to load pages...
# caches_page :index
def index
@desktop = current_user.desktop
@currentusername = current_user.name
@currentname = current_user.first_name + current_user.last_name
@title = "Desktop - " + @currentusername
@section = @desktop.sections.first
end
@@ -19,7 +15,7 @@ class DesktopController< ApplicationController
render :layout => "compatibility"
end
def desktop_container
def desktop
render :layout => false
end
@@ -339,15 +335,7 @@ class DesktopController< ApplicationController
b = {"success"=>"true"}
render :json=>b.to_json
end
protected
def check_desktop_open
@site = Site.first
if @site.desktop_closed #Need to be change
redirect_to '/admin/dashboards'
end
end
end
+1 -1
View File
@@ -1,4 +1,4 @@
class DesktopThemesController < ApplicationController
class DesktopThemesController < OrbitBackendController
require "net/http"
require "uri"
require 'zip/zip'
@@ -1,4 +1,4 @@
class DesktopWidgetsController < ApplicationController
class DesktopWidgetsController < OrbitBackendController
require "net/http"
require "uri"
require 'zip/zip'
Loaded 100 of 707 files, more files were not shown because too many files have changed in this diff. Show more