')).parent().on("click",function(){d.input.focus()});if(d.values.length){c.each(d.values,function(){d.createBadge(this)})}d.input=c('
').attr("placeholder",d.options.placeholder).insertAfter(d.element).on("focus",function(){d.element.parent().addClass("tags-hover")}).on("blur",function(){if(!d.skip){d.process();d.element.parent().removeClass("tags-hover");d.element.siblings(".tag").removeClass("tag-important")}d.skip=false}).on("keydown",function(g){if(g.keyCode==188||g.keyCode==13||g.keyCode==9){if(c.trim(c(this).val())&&(!d.element.siblings(".typeahead").length||d.element.siblings(".typeahead").is(":hidden"))){if(g.keyCode!=9){g.preventDefault()}d.process()}else{if(g.keyCode==188){if(!d.element.siblings(".typeahead").length||d.element.siblings(".typeahead").is(":hidden")){g.preventDefault()}else{d.input.data("typeahead").select();g.stopPropagation();g.preventDefault()}}}}else{if(!c.trim(c(this).val())&&g.keyCode==8){var f=d.element.siblings(".tag").length;if(f){var e=d.element.siblings(".tag:eq("+(f-1)+")");if(e.hasClass("tag-important")){d.remove(f-1)}else{e.addClass("tag-important")}}}else{d.element.siblings(".tag").removeClass("tag-important")}}}).typeahead({source:d.options.source,matcher:function(e){return ~e.toLowerCase().indexOf(this.query.toLowerCase())&&(d.inValues(e)==-1||d.options.allowDuplicates)},updater:c.proxy(d.add,d)});c(d.input.data("typeahead").$menu).on("mousedown",function(){d.skip=true});this.element.trigger("shown")},inValues:function(e){if(this.options.caseInsensitive){var d=-1;c.each(this.values,function(f,g){if(g.toLowerCase()==e.toLowerCase()){d=f;return false}});return d}else{return c.inArray(e,this.values)}},createBadge:function(e){var d=this;c("
",{"class":"tag"}).text(e).append(c('
× ').on("click",function(){d.remove(d.element.siblings(".tag").index(c(this).closest(".tag")))})).insertBefore(d.element)},add:function(g){var f=this;if(!f.options.allowDuplicates){var e=f.inValues(g);if(e!=-1){var d=f.element.siblings(".tag:eq("+e+")");d.addClass("tag-warning");setTimeout(function(){c(d).removeClass("tag-warning")},500);return}}this.values.push(g);this.createBadge(g);this.element.val(this.values.join(", "));this.element.trigger("added",[g])},remove:function(d){if(d>=0){var e=this.values.splice(d,1);this.element.siblings(".tag:eq("+d+")").remove();this.element.val(this.values.join(", "));this.element.trigger("removed",[e])}},process:function(){var d=c.grep(c.map(this.input.val().split(","),c.trim),function(f){return f.length>0}),e=this;c.each(d,function(){e.add(this)});this.input.val("")},skip:false};var a=c.fn.tag;c.fn.tag=function(d){return this.each(function(){var f=c(this),g=f.data("tag"),e=typeof d=="object"&&d;if(!g){f.data("tag",(g=new b(this,e)))}if(typeof d=="string"){g[d]()}})};c.fn.tag.defaults={allowDuplicates:false,caseInsensitive:true,placeholder:"",source:[]};c.fn.tag.Constructor=b;c.fn.tag.noConflict=function(){c.fn.tag=a;return this};c(window).on("load",function(){c('[data-provide="tag"]').each(function(){var d=c(this);if(d.data("tag")){return}d.tag(d.data())})})}(window.jQuery);
--------------------------------------------------------------------------------
/assets/js/bootstrap-wysiwyg.min.js:
--------------------------------------------------------------------------------
1 | (function(b){var a=function(e){var c=b.Deferred(),d=new FileReader();d.onload=function(f){c.resolve(f.target.result)};d.onerror=c.reject;d.onprogress=c.notify;d.readAsDataURL(e);return c.promise()};b.fn.cleanHtml=function(){var c=b(this).html();return c&&c.replace(/(
|\s|
<\/div>| )*$/,"")};b.fn.wysiwyg=function(k){var l=this,h,q,d,p=function(){if(q.activeToolbarClass){b(q.toolbarSelector).find(d).each(function(){try{var s=b(this).data(q.commandRole);if(document.queryCommandState(s)){b(this).addClass(q.activeToolbarClass)}else{b(this).removeClass(q.activeToolbarClass)}}catch(r){}})}},o=function(r,s){var u=r.split(" "),v=u.shift(),t=u.join(" ")+(s||"");document.execCommand(v,0,t);p()},f=function(r){b.each(r,function(s,t){l.keydown(s,function(u){if(l.attr("contenteditable")&&l.is(":visible")){u.preventDefault();u.stopPropagation();o(t)}}).keyup(s,function(u){if(l.attr("contenteditable")&&l.is(":visible")){u.preventDefault();u.stopPropagation()}})})},g=function(){try{var r=window.getSelection();if(r.getRangeAt&&r.rangeCount){return r.getRangeAt(0)}}catch(s){}},i=function(){h=g()},e=function(){try{var s=window.getSelection();if(h){try{s.removeAllRanges()}catch(r){document.body.createTextRange().select();document.selection.empty()}s.addRange(h)}}catch(t){}},j=function(r){l.focus();b.each(r,function(s,t){if(/^image\//.test(t.type)){b.when(a(t)).done(function(u){o("insertimage",u)}).fail(function(u){q.fileUploadError("file-reader",u)})}else{q.fileUploadError("unsupported-file-type",t.type)}})},c=function(s,r){e();if(document.queryCommandSupported("hiliteColor")){document.execCommand("hiliteColor",0,r||"transparent")}i();s.data(q.selectionMarker,r)},m=function(s,r){s.find(d).click(function(){e();l.focus();o(b(this).data(r.commandRole));i()});s.find("[data-toggle=dropdown]").click(e);s.find("input[type=text][data-"+r.commandRole+"]").on("webkitspeechchange change",function(){var t=this.value;this.value="";e();if(t){l.focus();o(b(this).data(r.commandRole),t)}i()}).on("focus",function(){var t=b(this);if(!t.data(r.selectionMarker)){c(t,r.selectionColor);t.focus()}}).on("blur",function(){var t=b(this);if(t.data(r.selectionMarker)){c(t,false)}});s.find("input[type=file][data-"+r.commandRole+"]").change(function(){e();if(this.type==="file"&&this.files&&this.files.length>0){j(this.files)}i();this.value=""})},n=function(){l.on("dragenter dragover",false).on("drop",function(s){var r=s.originalEvent.dataTransfer;s.stopPropagation();s.preventDefault();if(r&&r.files&&r.files.length>0){j(r.files)}})};q=b.extend({},b.fn.wysiwyg.defaults,k);d="a[data-"+q.commandRole+"],button[data-"+q.commandRole+"],input[type=button][data-"+q.commandRole+"]";f(q.hotKeys);if(q.dragAndDropImages){n()}m(b(q.toolbarSelector),q);l.attr("contenteditable",true).on("mouseup keyup mouseout",function(){i();p()});b(window).bind("touchend",function(u){var t=(l.is(u.target)||l.has(u.target).length>0),s=g(),r=s&&(s.startContainer===s.endContainer&&s.startOffset===s.endOffset);if(!r||t){i();p()}});return this};b.fn.wysiwyg.defaults={hotKeys:{"ctrl+b meta+b":"bold","ctrl+i meta+i":"italic","ctrl+u meta+u":"underline","ctrl+z meta+z":"undo","ctrl+y meta+y meta+shift+z":"redo","ctrl+l meta+l":"justifyleft","ctrl+r meta+r":"justifyright","ctrl+e meta+e":"justifycenter","ctrl+j meta+j":"justifyfull","shift+tab":"outdent",tab:"indent"},toolbarSelector:"[data-role=editor-toolbar]",commandRole:"edit",activeToolbarClass:"btn-info",selectionMarker:"edit-focus-marker",selectionColor:"darkgrey",dragAndDropImages:true,fileUploadError:function(d,c){console.log("File upload error",d,c)}}}(window.jQuery));
--------------------------------------------------------------------------------
/assets/js/flot/jquery.flot.pie.min.js:
--------------------------------------------------------------------------------
1 | /* Flot plugin for rendering pie charts.
2 |
3 | Copyright (c) 2007-2013 IOLA and Ole Laursen.
4 | Licensed under the MIT license.
5 |
6 | The plugin assumes that each series has a single data value, and that each
7 | value is a positive integer or zero. Negative numbers don't make sense for a
8 | pie chart, and have unpredictable results. The values do NOT need to be
9 | passed in as percentages; the plugin will calculate the total and per-slice
10 | percentages internally.
11 |
12 | * Created by Brian Medendorp
13 |
14 | * Updated with contributions from btburnett3, Anthony Aragues and Xavi Ivars
15 |
16 | The plugin supports these options:
17 |
18 | series: {
19 | pie: {
20 | show: true/false
21 | radius: 0-1 for percentage of fullsize, or a specified pixel length, or 'auto'
22 | innerRadius: 0-1 for percentage of fullsize or a specified pixel length, for creating a donut effect
23 | startAngle: 0-2 factor of PI used for starting angle (in radians) i.e 3/2 starts at the top, 0 and 2 have the same result
24 | tilt: 0-1 for percentage to tilt the pie, where 1 is no tilt, and 0 is completely flat (nothing will show)
25 | offset: {
26 | top: integer value to move the pie up or down
27 | left: integer value to move the pie left or right, or 'auto'
28 | },
29 | stroke: {
30 | color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#FFF')
31 | width: integer pixel width of the stroke
32 | },
33 | label: {
34 | show: true/false, or 'auto'
35 | formatter: a user-defined function that modifies the text/style of the label text
36 | radius: 0-1 for percentage of fullsize, or a specified pixel length
37 | background: {
38 | color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#000')
39 | opacity: 0-1
40 | },
41 | threshold: 0-1 for the percentage value at which to hide labels (if they're too small)
42 | },
43 | combine: {
44 | threshold: 0-1 for the percentage value at which to combine slices (if they're too small)
45 | color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#CCC'), if null, the plugin will automatically use the color of the first slice to be combined
46 | label: any text value of what the combined slice should be labeled
47 | }
48 | highlight: {
49 | opacity: 0-1
50 | }
51 | }
52 | }
53 |
54 | More detail and specific examples can be found in the included HTML file.
55 |
56 | */(function(e){function r(r){function p(t,n,r){l||(l=!0,s=t.getCanvas(),o=e(s).parent(),i=t.getOptions(),t.setData(d(t.getData())))}function d(t){var n=0,r=0,s=0,o=i.series.pie.combine.color,u=[];for(var a=0;a
i.series.pie.combine.threshold)&&u.push({data:[[1,f]],color:t[a].color,label:t[a].label,angle:f*Math.PI*2/n,percent:f/(n/100)})}return s>1&&u.push({data:[[1,r]],color:o,label:i.series.pie.combine.label,angle:r*Math.PI*2/n,percent:r/(n/100)}),u}function v(r,s){function y(){c.clearRect(0,0,h,p),o.children().filter(".pieLabel, .pieLabelBackground").remove()}function b(){var e=i.series.pie.shadow.left,t=i.series.pie.shadow.top,n=10,r=i.series.pie.shadow.alpha,s=i.series.pie.radius>1?i.series.pie.radius:u*i.series.pie.radius;if(s>=h/2-e||s*i.series.pie.tilt>=p/2-t||s<=n)return;c.save(),c.translate(e,t),c.globalAlpha=r,c.fillStyle="#000",c.translate(a,f),c.scale(1,i.series.pie.tilt);for(var o=1;o<=n;o++)c.beginPath(),c.arc(0,0,s,0,Math.PI*2,!1),c.fill(),s-=o;c.restore()}function w(){function l(e,t,i){if(e<=0||isNaN(e))return;i?c.fillStyle=t:(c.strokeStyle=t,c.lineJoin="round"),c.beginPath(),Math.abs(e-Math.PI*2)>1e-9&&c.moveTo(0,0),c.arc(0,0,n,r,r+e/2,!1),c.arc(0,0,n,r+e/2,r+e,!1),c.closePath(),r+=e,i?c.fill():c.stroke()}function d(){function l(t,n,s){if(t.data[0][1]==0)return!0;var u=i.legend.labelFormatter,l,c=i.series.pie.label.formatter;u?l=u(t.label,t):l=t.label,c&&(l=c(l,t));var d=(n+t.angle+n)/2,v=a+Math.round(Math.cos(d)*r),m=f+Math.round(Math.sin(d)*r)*i.series.pie.tilt,g=""+l+" ";o.append(g);var y=o.children("#pieLabel"+s),b=m-y.height()/2,w=v-y.width()/2;y.css("top",b),y.css("left",w);if(0-b>0||0-w>0||p-(b+y.height())<0||h-(w+y.width())<0)return!1;if(i.series.pie.label.background.opacity!=0){var E=i.series.pie.label.background.color;E==null&&(E=t.color);var S="top:"+b+"px;left:"+w+"px;";e("
").css("opacity",i.series.pie.label.background.opacity).insertBefore(y)}return!0}var n=t,r=i.series.pie.label.radius>1?i.series.pie.label.radius:u*i.series.pie.label.radius;for(var s=0;s=i.series.pie.label.threshold*100&&!l(v[s],n,s))return!1;n+=v[s].angle}return!0}var t=Math.PI*i.series.pie.startAngle,n=i.series.pie.radius>1?i.series.pie.radius:u*i.series.pie.radius;c.save(),c.translate(a,f),c.scale(1,i.series.pie.tilt),c.save();var r=t;for(var s=0;s0){c.save(),c.lineWidth=i.series.pie.stroke.width,r=t;for(var s=0;sh-u&&(a=h-u);var v=r.getData(),g=0;do g>0&&(u*=n),g+=1,y(),i.series.pie.tilt<=.8&&b();while(!w()&&g=t&&(y(),o.prepend("Could not draw pie with labels contained inside canvas
")),r.setSeries&&r.insertLegend&&(r.setSeries(v),r.insertLegend())}function m(e){if(i.series.pie.innerRadius>0){e.save();var t=i.series.pie.innerRadius>1?i.series.pie.innerRadius:u*i.series.pie.innerRadius;e.globalCompositeOperation="destination-out",e.beginPath(),e.fillStyle=i.series.pie.stroke.color,e.arc(0,0,t,0,Math.PI*2,!1),e.fill(),e.closePath(),e.restore(),e.save(),e.beginPath(),e.strokeStyle=i.series.pie.stroke.color,e.arc(0,0,t,0,Math.PI*2,!1),e.stroke(),e.closePath(),e.restore()}}function g(e,t){for(var n=!1,r=-1,i=e.length,s=i-1;++r1?i.series.pie.radius:u*i.series.pie.radius,o,l;for(var h=0;h1e-9&&t.moveTo(0,0),t.arc(0,0,r,e.startAngle,e.startAngle+e.angle/2,!1),t.arc(0,0,r,e.startAngle+e.angle/2,e.startAngle+e.angle,!1),t.closePath(),t.fill()}var n=e.getOptions(),r=n.series.pie.radius>1?n.series.pie.radius:u*n.series.pie.radius;t.save(),t.translate(a,f),t.scale(1,n.series.pie.tilt);for(var i=0;i1?t.series.pie.tilt=1:t.series.pie.tilt<0&&(t.series.pie.tilt=0))}),r.hooks.bindEvents.push(function(e,t){var n=e.getOptions();n.series.pie.show&&(n.grid.hoverable&&t.unbind("mousemove").mousemove(b),n.grid.clickable&&t.unbind("click").click(w))}),r.hooks.processDatapoints.push(function(e,t,n,r){var i=e.getOptions();i.series.pie.show&&p(e,t,n,r)}),r.hooks.drawOverlay.push(function(e,t){var n=e.getOptions();n.series.pie.show&&N(e,t)}),r.hooks.draw.push(function(e,t){var n=e.getOptions();n.series.pie.show&&v(e,t)})}var t=10,n=.95,i={series:{pie:{show:!1,radius:"auto",innerRadius:0,startAngle:1.5,tilt:1,shadow:{left:5,top:15,alpha:.02},offset:{top:0,left:"auto"},stroke:{color:"#fff",width:1},label:{show:"auto",formatter:function(e,t){return""+e+" "+Math.round(t.percent)+"%
"},radius:1,background:{color:null,opacity:0},threshold:0},combine:{threshold:-1,color:null,label:"Other"},highlight:{opacity:.5}}}};e.plot.plugins.push({init:r,options:i,name:"pie",version:"1.1"})})(jQuery);
--------------------------------------------------------------------------------
/assets/js/flot/jquery.flot.resize.min.js:
--------------------------------------------------------------------------------
1 | /* Flot plugin for automatically redrawing plots as the placeholder resizes.
2 |
3 | Copyright (c) 2007-2013 IOLA and Ole Laursen.
4 | Licensed under the MIT license.
5 |
6 | It works by listening for changes on the placeholder div (through the jQuery
7 | resize event plugin) - if the size changes, it will redraw the plot.
8 |
9 | There are no options. If you need to disable the plugin for some plots, you
10 | can just fix the size of their placeholders.
11 |
12 | *//* Inline dependency:
13 | * jQuery resize event - v1.1 - 3/14/2010
14 | * http://benalman.com/projects/jquery-resize-plugin/
15 | *
16 | * Copyright (c) 2010 "Cowboy" Ben Alman
17 | * Dual licensed under the MIT and GPL licenses.
18 | * http://benalman.com/about/license/
19 | */(function(e,t,n){function c(){s=t[o](function(){r.each(function(){var t=e(this),n=t.width(),r=t.height(),i=e.data(this,a);(n!==i.w||r!==i.h)&&t.trigger(u,[i.w=n,i.h=r])}),c()},i[f])}var r=e([]),i=e.resize=e.extend(e.resize,{}),s,o="setTimeout",u="resize",a=u+"-special-event",f="delay",l="throttleWindow";i[f]=250,i[l]=!0,e.event.special[u]={setup:function(){if(!i[l]&&this[o])return!1;var t=e(this);r=r.add(t),e.data(this,a,{w:t.width(),h:t.height()}),r.length===1&&c()},teardown:function(){if(!i[l]&&this[o])return!1;var t=e(this);r=r.not(t),t.removeData(a),r.length||clearTimeout(s)},add:function(t){function s(t,i,s){var o=e(this),u=e.data(this,a);u.w=i!==n?i:o.width(),u.h=s!==n?s:o.height(),r.apply(this,arguments)}if(!i[l]&&this[o])return!1;var r;if(e.isFunction(t))return r=t,s;r=t.handler,t.handler=s}}})(jQuery,this),function(e){function n(e){function t(){var t=e.getPlaceholder();if(t.width()==0||t.height()==0)return;e.resize(),e.setupGrid(),e.draw()}function n(e,n){e.getPlaceholder().resize(t)}function r(e,n){e.getPlaceholder().unbind("resize",t)}e.hooks.bindEvents.push(n),e.hooks.shutdown.push(r)}var t={};e.plot.plugins.push({init:n,options:t,name:"resize",version:"1.0"})}(jQuery);
--------------------------------------------------------------------------------
/assets/js/fuelux/data/fuelux.tree-sampledata.js:
--------------------------------------------------------------------------------
1 | var DataSourceTree = function(options) {
2 | this._data = options.data;
3 | this._delay = options.delay;
4 | }
5 |
6 | DataSourceTree.prototype.data = function(options, callback) {
7 | var self = this;
8 | var $data = null;
9 |
10 | if(!("name" in options) && !("type" in options)){
11 | $data = this._data;//the root tree
12 | callback({ data: $data });
13 | return;
14 | }
15 | else if("type" in options && options.type == "folder") {
16 | if("additionalParameters" in options && "children" in options.additionalParameters)
17 | $data = options.additionalParameters.children;
18 | else $data = {}//no data
19 | }
20 |
21 | if($data != null)//this setTimeout is only for mimicking some random delay
22 | setTimeout(function(){callback({ data: $data });} , parseInt(Math.random() * 500) + 200);
23 |
24 | //we have used static data here
25 | //but you can retrieve your data dynamically from a server using ajax call
26 | //checkout examples/treeview.html and examples/treeview.js for more info
27 | };
28 |
29 | var tree_data = {
30 | 'for-sale' : {name: 'For Sale', type: 'folder'} ,
31 | 'vehicles' : {name: 'Vehicles', type: 'folder'} ,
32 | 'rentals' : {name: 'Rentals', type: 'folder'} ,
33 | 'real-estate' : {name: 'Real Estate', type: 'folder'} ,
34 | 'pets' : {name: 'Pets', type: 'folder'} ,
35 | 'tickets' : {name: 'Tickets', type: 'item'} ,
36 | 'services' : {name: 'Services', type: 'item'} ,
37 | 'personals' : {name: 'Personals', type: 'item'}
38 | }
39 | tree_data['for-sale']['additionalParameters'] = {
40 | 'children' : {
41 | 'appliances' : {name: 'Appliances', type: 'item'},
42 | 'arts-crafts' : {name: 'Arts & Crafts', type: 'item'},
43 | 'clothing' : {name: 'Clothing', type: 'item'},
44 | 'computers' : {name: 'Computers', type: 'item'},
45 | 'jewelry' : {name: 'Jewelry', type: 'item'},
46 | 'office-business' : {name: 'Office & Business', type: 'item'},
47 | 'sports-fitness' : {name: 'Sports & Fitness', type: 'item'}
48 | }
49 | }
50 | tree_data['vehicles']['additionalParameters'] = {
51 | 'children' : {
52 | 'cars' : {name: 'Cars', type: 'folder'},
53 | 'motorcycles' : {name: 'Motorcycles', type: 'item'},
54 | 'boats' : {name: 'Boats', type: 'item'}
55 | }
56 | }
57 | tree_data['vehicles']['additionalParameters']['children']['cars']['additionalParameters'] = {
58 | 'children' : {
59 | 'classics' : {name: 'Classics', type: 'item'},
60 | 'convertibles' : {name: 'Convertibles', type: 'item'},
61 | 'coupes' : {name: 'Coupes', type: 'item'},
62 | 'hatchbacks' : {name: 'Hatchbacks', type: 'item'},
63 | 'hybrids' : {name: 'Hybrids', type: 'item'},
64 | 'suvs' : {name: 'SUVs', type: 'item'},
65 | 'sedans' : {name: 'Sedans', type: 'item'},
66 | 'trucks' : {name: 'Trucks', type: 'item'}
67 | }
68 | }
69 |
70 | tree_data['rentals']['additionalParameters'] = {
71 | 'children' : {
72 | 'apartments-rentals' : {name: 'Apartments', type: 'item'},
73 | 'office-space-rentals' : {name: 'Office Space', type: 'item'},
74 | 'vacation-rentals' : {name: 'Vacation Rentals', type: 'item'}
75 | }
76 | }
77 | tree_data['real-estate']['additionalParameters'] = {
78 | 'children' : {
79 | 'apartments' : {name: 'Apartments', type: 'item'},
80 | 'villas' : {name: 'Villas', type: 'item'},
81 | 'plots' : {name: 'Plots', type: 'item'}
82 | }
83 | }
84 | tree_data['pets']['additionalParameters'] = {
85 | 'children' : {
86 | 'cats' : {name: 'Cats', type: 'item'},
87 | 'dogs' : {name: 'Dogs', type: 'item'},
88 | 'horses' : {name: 'Horses', type: 'item'},
89 | 'reptiles' : {name: 'Reptiles', type: 'item'}
90 | }
91 | }
92 |
93 | var treeDataSource = new DataSourceTree({data: tree_data});
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 | var tree_data_2 = {
106 | 'pictures' : {name: 'Pictures', type: 'folder', 'icon-class':'red'} ,
107 | 'music' : {name: 'Music', type: 'folder', 'icon-class':'orange'} ,
108 | 'video' : {name: 'Video', type: 'folder', 'icon-class':'blue'} ,
109 | 'documents' : {name: 'Documents', type: 'folder', 'icon-class':'green'} ,
110 | 'backup' : {name: 'Backup', type: 'folder'} ,
111 | 'readme' : {name: ' ReadMe.txt', type: 'item'},
112 | 'manual' : {name: ' Manual.html', type: 'item'}
113 | }
114 | tree_data_2['music']['additionalParameters'] = {
115 | 'children' : [
116 | {name: ' song1.ogg', type: 'item'},
117 | {name: ' song2.ogg', type: 'item'},
118 | {name: ' song3.ogg', type: 'item'},
119 | {name: ' song4.ogg', type: 'item'},
120 | {name: ' song5.ogg', type: 'item'}
121 | ]
122 | }
123 | tree_data_2['video']['additionalParameters'] = {
124 | 'children' : [
125 | {name: ' movie1.avi', type: 'item'},
126 | {name: ' movie2.avi', type: 'item'},
127 | {name: ' movie3.avi', type: 'item'},
128 | {name: ' movie4.avi', type: 'item'},
129 | {name: ' movie5.avi', type: 'item'}
130 | ]
131 | }
132 | tree_data_2['pictures']['additionalParameters'] = {
133 | 'children' : {
134 | 'wallpapers' : {name: 'Wallpapers', type: 'folder', 'icon-class':'pink'},
135 | 'camera' : {name: 'Camera', type: 'folder', 'icon-class':'pink'}
136 | }
137 | }
138 | tree_data_2['pictures']['additionalParameters']['children']['wallpapers']['additionalParameters'] = {
139 | 'children' : [
140 | {name: ' wallpaper1.jpg', type: 'item'},
141 | {name: ' wallpaper2.jpg', type: 'item'},
142 | {name: ' wallpaper3.jpg', type: 'item'},
143 | {name: ' wallpaper4.jpg', type: 'item'}
144 | ]
145 | }
146 | tree_data_2['pictures']['additionalParameters']['children']['camera']['additionalParameters'] = {
147 | 'children' : [
148 | {name: ' photo1.jpg', type: 'item'},
149 | {name: ' photo2.jpg', type: 'item'},
150 | {name: ' photo3.jpg', type: 'item'},
151 | {name: ' photo4.jpg', type: 'item'},
152 | {name: ' photo5.jpg', type: 'item'},
153 | {name: ' photo6.jpg', type: 'item'}
154 | ]
155 | }
156 |
157 |
158 | tree_data_2['documents']['additionalParameters'] = {
159 | 'children' : [
160 | {name: ' document1.pdf', type: 'item'},
161 | {name: ' document2.doc', type: 'item'},
162 | {name: ' document3.doc', type: 'item'},
163 | {name: ' document4.pdf', type: 'item'},
164 | {name: ' document5.doc', type: 'item'}
165 | ]
166 | }
167 |
168 | tree_data_2['backup']['additionalParameters'] = {
169 | 'children' : [
170 | {name: ' backup1.zip', type: 'item'},
171 | {name: ' backup2.zip', type: 'item'},
172 | {name: ' backup3.zip', type: 'item'},
173 | {name: ' backup4.zip', type: 'item'}
174 | ]
175 | }
176 | var treeDataSource2 = new DataSourceTree({data: tree_data_2});
--------------------------------------------------------------------------------
/assets/js/fuelux/fuelux.spinner.min.js:
--------------------------------------------------------------------------------
1 | (function(b,c){var a=function(e,d){this.$element=b(e);this.options=b.extend({},b.fn.spinner.defaults,d);this.$input=this.$element.find(".spinner-input");this.$element.on("keyup",this.$input,b.proxy(this.change,this));if(this.options.hold){this.$element.on("mousedown",".spinner-up",b.proxy(function(){this.startSpin(true)},this));this.$element.on("mouseup",".spinner-up, .spinner-down",b.proxy(this.stopSpin,this));this.$element.on("mouseout",".spinner-up, .spinner-down",b.proxy(this.stopSpin,this));this.$element.on("mousedown",".spinner-down",b.proxy(function(){this.startSpin(false)},this))}else{this.$element.on("click",".spinner-up",b.proxy(function(){this.step(true)},this));this.$element.on("click",".spinner-down",b.proxy(function(){this.step(false)},this))}this.switches={count:1,enabled:true};if(this.options.speed==="medium"){this.switches.speed=300}else{if(this.options.speed==="fast"){this.switches.speed=100}else{this.switches.speed=500}}this.lastValue=null;this.render();if(this.options.disabled){this.disable()}};a.prototype={constructor:a,render:function(){this.$input.val(this.options.value);this.$input.attr("maxlength",(this.options.max+"").split("").length)},change:function(){var d=this.$input.val();if(d/1){this.options.value=d/1}else{d=d.replace(/[^0-9]/g,"");this.$input.val(d);this.options.value=d/1}this.triggerChangedEvent()},stopSpin:function(){clearTimeout(this.switches.timeout);this.switches.count=1;this.triggerChangedEvent()},triggerChangedEvent:function(){var d=this.value();if(d===this.lastValue){return}this.lastValue=d;this.$element.trigger("changed",d);this.$element.trigger("change")},startSpin:function(d){if(!this.options.disabled){var e=this.switches.count;if(e===1){this.step(d);e=1}else{if(e<3){e=1.5}else{if(e<8){e=2.5}else{e=4}}}this.switches.timeout=setTimeout(b.proxy(function(){this.iterator(d)},this),this.switches.speed/e);this.switches.count++}},iterator:function(d){this.step(d);this.startSpin(d)},step:function(e){var g=this.options.value;var f=e?this.options.max:this.options.min;if((e?gf)){var d=g+(e?1:-1)*this.options.step;if(e?d>f:dLoading... ",cacheItems:true};a.fn.tree.Constructor=b})(window.jQuery);
--------------------------------------------------------------------------------
/assets/js/fuelux/fuelux.wizard.min.js:
--------------------------------------------------------------------------------
1 | (function(b,c){var a=function(f,e){var d;this.$element=b(f);this.options=b.extend({},b.fn.wizard.defaults,e);this.currentStep=1;this.numSteps=this.$element.find("li").length;this.$prevBtn=this.$element.find("button.btn-prev");this.$nextBtn=this.$element.find("button.btn-next");d=this.$nextBtn.children().detach();this.nextText=b.trim(this.$nextBtn.text());this.$nextBtn.append(d);this.$prevBtn.on("click",b.proxy(this.previous,this));this.$nextBtn.on("click",b.proxy(this.next,this));this.$element.on("click","li.complete",b.proxy(this.stepclicked,this));this.$stepContainer=this.$element.data("target")||"body";this.$stepContainer=b(this.$stepContainer)};a.prototype={constructor:a,setState:function(){var n=(this.currentStep>1);var o=(this.currentStep===1);var d=(this.currentStep===this.numSteps);this.$prevBtn.attr("disabled",(o===true||n===false));var h=this.$nextBtn.data();if(h&&h.last){this.lastText=h.last;if(typeof this.lastText!=="undefined"){var l=(d!==true)?this.nextText:this.lastText;var f=this.$nextBtn.children().detach();this.$nextBtn.text(l).append(f)}}var j=this.$element.find("li");j.removeClass("active").removeClass("complete");j.find("span.badge").removeClass("badge-info").removeClass("badge-success");var m="li:lt("+(this.currentStep-1)+")";var g=this.$element.find(m);g.addClass("complete");g.find("span.badge").addClass("badge-success");var e="li:eq("+(this.currentStep-1)+")";var k=this.$element.find(e);k.addClass("active");k.find("span.badge").addClass("badge-info");var i=k.data().target;this.$stepContainer.find(".step-pane").removeClass("active");b(i).addClass("active");this.$element.trigger("changed")},stepclicked:function(h){var d=b(h.currentTarget);var g=this.$element.find("li").index(d);var f=b.Event("stepclick");this.$element.trigger(f,{step:g+1});if(f.isDefaultPrevented()){return}this.currentStep=(g+1);this.setState()},previous:function(){var d=(this.currentStep>1);if(d){var f=b.Event("change");this.$element.trigger(f,{step:this.currentStep,direction:"previous"});if(f.isDefaultPrevented()){return}this.currentStep-=1;this.setState()}},next:function(){var g=(this.currentStep+1<=this.numSteps);var d=(this.currentStep===this.numSteps);if(g){var f=b.Event("change");this.$element.trigger(f,{step:this.currentStep,direction:"next"});if(f.isDefaultPrevented()){return}this.currentStep+=1;this.setState()}else{if(d){this.$element.trigger("finished")}}},selectedItem:function(d){return{step:this.currentStep}}};b.fn.wizard=function(e,g){var f;var d=this.each(function(){var j=b(this);var i=j.data("wizard");var h=typeof e==="object"&&e;if(!i){j.data("wizard",(i=new a(this,h)))}if(typeof e==="string"){f=i[e](g)}});return(f===c)?d:f};b.fn.wizard.defaults={};b.fn.wizard.Constructor=a;b(function(){b("body").on("mousedown.wizard.data-api",".wizard",function(){var d=b(this);if(d.data("wizard")){return}d.wizard(d.data())})})})(window.jQuery);
--------------------------------------------------------------------------------
/assets/js/jqGrid/i18n/grid.locale-en.js:
--------------------------------------------------------------------------------
1 | ;(function($){
2 | /**
3 | * jqGrid English Translation
4 | * Tony Tomov tony@trirand.com
5 | * http://trirand.com/blog/
6 | * Dual licensed under the MIT and GPL licenses:
7 | * http://www.opensource.org/licenses/mit-license.php
8 | * http://www.gnu.org/licenses/gpl.html
9 | **/
10 | $.jgrid = $.jgrid || {};
11 | $.extend($.jgrid,{
12 | defaults : {
13 | recordtext: "View {0} - {1} of {2}",
14 | emptyrecords: "No records to view",
15 | loadtext: "Loading...",
16 | pgtext : "Page {0} of {1}"
17 | },
18 | search : {
19 | caption: "Search...",
20 | Find: "Find",
21 | Reset: "Reset",
22 | odata: [{ oper:'eq', text:'equal'},{ oper:'ne', text:'not equal'},{ oper:'lt', text:'less'},{ oper:'le', text:'less or equal'},{ oper:'gt', text:'greater'},{ oper:'ge', text:'greater or equal'},{ oper:'bw', text:'begins with'},{ oper:'bn', text:'does not begin with'},{ oper:'in', text:'is in'},{ oper:'ni', text:'is not in'},{ oper:'ew', text:'ends with'},{ oper:'en', text:'does not end with'},{ oper:'cn', text:'contains'},{ oper:'nc', text:'does not contain'}],
23 | groupOps: [ { op: "AND", text: "all" }, { op: "OR", text: "any" } ]
24 | },
25 | edit : {
26 | addCaption: "Add Record",
27 | editCaption: "Edit Record",
28 | bSubmit: "Submit",
29 | bCancel: "Cancel",
30 | bClose: "Close",
31 | saveData: "Data has been changed! Save changes?",
32 | bYes : "Yes",
33 | bNo : "No",
34 | bExit : "Cancel",
35 | msg: {
36 | required:"Field is required",
37 | number:"Please, enter valid number",
38 | minValue:"value must be greater than or equal to ",
39 | maxValue:"value must be less than or equal to",
40 | email: "is not a valid e-mail",
41 | integer: "Please, enter valid integer value",
42 | date: "Please, enter valid date value",
43 | url: "is not a valid URL. Prefix required ('http://' or 'https://')",
44 | nodefined : " is not defined!",
45 | novalue : " return value is required!",
46 | customarray : "Custom function should return array!",
47 | customfcheck : "Custom function should be present in case of custom checking!"
48 |
49 | }
50 | },
51 | view : {
52 | caption: "View Record",
53 | bClose: "Close"
54 | },
55 | del : {
56 | caption: "Delete",
57 | msg: "Delete selected record(s)?",
58 | bSubmit: "Delete",
59 | bCancel: "Cancel"
60 | },
61 | nav : {
62 | edittext: "",
63 | edittitle: "Edit selected row",
64 | addtext:"",
65 | addtitle: "Add new row",
66 | deltext: "",
67 | deltitle: "Delete selected row",
68 | searchtext: "",
69 | searchtitle: "Find records",
70 | refreshtext: "",
71 | refreshtitle: "Reload Grid",
72 | alertcap: "Warning",
73 | alerttext: "Please, select row",
74 | viewtext: "",
75 | viewtitle: "View selected row"
76 | },
77 | col : {
78 | caption: "Select columns",
79 | bSubmit: "Ok",
80 | bCancel: "Cancel"
81 | },
82 | errors : {
83 | errcap : "Error",
84 | nourl : "No url is set",
85 | norecords: "No records to process",
86 | model : "Length of colNames <> colModel!"
87 | },
88 | formatter : {
89 | integer : {thousandsSeparator: ",", defaultValue: '0'},
90 | number : {decimalSeparator:".", thousandsSeparator: ",", decimalPlaces: 2, defaultValue: '0.00'},
91 | currency : {decimalSeparator:".", thousandsSeparator: ",", decimalPlaces: 2, prefix: "", suffix:"", defaultValue: '0.00'},
92 | date : {
93 | dayNames: [
94 | "Sun", "Mon", "Tue", "Wed", "Thr", "Fri", "Sat",
95 | "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"
96 | ],
97 | monthNames: [
98 | "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec",
99 | "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"
100 | ],
101 | AmPm : ["am","pm","AM","PM"],
102 | S: function (j) {return j < 11 || j > 13 ? ['st', 'nd', 'rd', 'th'][Math.min((j - 1) % 10, 3)] : 'th';},
103 | srcformat: 'Y-m-d',
104 | newformat: 'n/j/Y',
105 | parseRe : /[Tt\\\/:_;.,\t\s-]/,
106 | masks : {
107 | // see http://php.net/manual/en/function.date.php for PHP format used in jqGrid
108 | // and see http://docs.jquery.com/UI/Datepicker/formatDate
109 | // and https://github.com/jquery/globalize#dates for alternative formats used frequently
110 | // one can find on https://github.com/jquery/globalize/tree/master/lib/cultures many
111 | // information about date, time, numbers and currency formats used in different countries
112 | // one should just convert the information in PHP format
113 | ISO8601Long:"Y-m-d H:i:s",
114 | ISO8601Short:"Y-m-d",
115 | // short date:
116 | // n - Numeric representation of a month, without leading zeros
117 | // j - Day of the month without leading zeros
118 | // Y - A full numeric representation of a year, 4 digits
119 | // example: 3/1/2012 which means 1 March 2012
120 | ShortDate: "n/j/Y", // in jQuery UI Datepicker: "M/d/yyyy"
121 | // long date:
122 | // l - A full textual representation of the day of the week
123 | // F - A full textual representation of a month
124 | // d - Day of the month, 2 digits with leading zeros
125 | // Y - A full numeric representation of a year, 4 digits
126 | LongDate: "l, F d, Y", // in jQuery UI Datepicker: "dddd, MMMM dd, yyyy"
127 | // long date with long time:
128 | // l - A full textual representation of the day of the week
129 | // F - A full textual representation of a month
130 | // d - Day of the month, 2 digits with leading zeros
131 | // Y - A full numeric representation of a year, 4 digits
132 | // g - 12-hour format of an hour without leading zeros
133 | // i - Minutes with leading zeros
134 | // s - Seconds, with leading zeros
135 | // A - Uppercase Ante meridiem and Post meridiem (AM or PM)
136 | FullDateTime: "l, F d, Y g:i:s A", // in jQuery UI Datepicker: "dddd, MMMM dd, yyyy h:mm:ss tt"
137 | // month day:
138 | // F - A full textual representation of a month
139 | // d - Day of the month, 2 digits with leading zeros
140 | MonthDay: "F d", // in jQuery UI Datepicker: "MMMM dd"
141 | // short time (without seconds)
142 | // g - 12-hour format of an hour without leading zeros
143 | // i - Minutes with leading zeros
144 | // A - Uppercase Ante meridiem and Post meridiem (AM or PM)
145 | ShortTime: "g:i A", // in jQuery UI Datepicker: "h:mm tt"
146 | // long time (with seconds)
147 | // g - 12-hour format of an hour without leading zeros
148 | // i - Minutes with leading zeros
149 | // s - Seconds, with leading zeros
150 | // A - Uppercase Ante meridiem and Post meridiem (AM or PM)
151 | LongTime: "g:i:s A", // in jQuery UI Datepicker: "h:mm:ss tt"
152 | SortableDateTime: "Y-m-d\\TH:i:s",
153 | UniversalSortableDateTime: "Y-m-d H:i:sO",
154 | // month with year
155 | // Y - A full numeric representation of a year, 4 digits
156 | // F - A full textual representation of a month
157 | YearMonth: "F, Y" // in jQuery UI Datepicker: "MMMM, yyyy"
158 | },
159 | reformatAfterEdit : false
160 | },
161 | baseLinkUrl: '',
162 | showAction: '',
163 | target: '',
164 | checkbox : {disabled:true},
165 | idName : 'id'
166 | }
167 | });
168 | })(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.autosize.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | Autosize v1.17.7 - 2013-09-03
3 | Automatically adjust textarea height based on user input.
4 | (c) 2013 Jack Moore - http://www.jacklmoore.com/autosize
5 | license: http://www.opensource.org/licenses/mit-license.php
6 | */
7 | (function(e){"function"==typeof define&&define.amd?define(["jquery"],e):e(window.jQuery||window.$)})(function(e){var t,o={className:"autosizejs",append:"",callback:!1,resizeDelay:10},i='
',n=["fontFamily","fontSize","fontWeight","fontStyle","letterSpacing","textTransform","wordSpacing","textIndent"],s=e(i).data("autosize",!0)[0];s.style.lineHeight="99px","99px"===e(s).css("lineHeight")&&n.push("lineHeight"),s.style.lineHeight="",e.fn.autosize=function(i){return i=e.extend({},o,i||{}),s.parentNode!==document.body&&e(document.body).append(s),this.each(function(){function o(){var t,o;"getComputedStyle"in window?(t=window.getComputedStyle(h),o=h.getBoundingClientRect().width,e.each(["paddingLeft","paddingRight","borderLeftWidth","borderRightWidth"],function(e,i){o-=parseInt(t[i],10)}),s.style.width=o+"px"):s.style.width=Math.max(p.width(),0)+"px"}function a(){var a={};if(t=h,s.className=i.className,d=parseInt(p.css("maxHeight"),10),e.each(n,function(e,t){a[t]=p.css(t)}),e(s).css(a),o(),window.chrome){var r=h.style.width;h.style.width="0px",h.offsetWidth,h.style.width=r}}function r(){var e,n;t!==h?a():o(),s.value=h.value+i.append,s.style.overflowY=h.style.overflowY,n=parseInt(h.style.height,10),s.scrollTop=0,s.scrollTop=9e4,e=s.scrollTop,d&&e>d?(h.style.overflowY="scroll",e=d):(h.style.overflowY="hidden",c>e&&(e=c)),e+=f,n!==e&&(h.style.height=e+"px",w&&i.callback.call(h,h))}function l(){clearTimeout(u),u=setTimeout(function(){var e=p.width();e!==y&&(y=e,r())},parseInt(i.resizeDelay,10))}var d,c,u,h=this,p=e(h),f=0,w=e.isFunction(i.callback),z={height:h.style.height,overflow:h.style.overflow,overflowY:h.style.overflowY,wordWrap:h.style.wordWrap,resize:h.style.resize},y=p.width();p.data("autosize")||(p.data("autosize",!0),("border-box"===p.css("box-sizing")||"border-box"===p.css("-moz-box-sizing")||"border-box"===p.css("-webkit-box-sizing"))&&(f=p.outerHeight()-p.height()),c=Math.max(parseInt(p.css("minHeight"),10)-f||0,p.height()),p.css({overflow:"hidden",overflowY:"hidden",wordWrap:"break-word",resize:"none"===p.css("resize")||"vertical"===p.css("resize")?"none":"horizontal"}),"onpropertychange"in h?"oninput"in h?p.on("input.autosize keyup.autosize",r):p.on("propertychange.autosize",function(){"value"===event.propertyName&&r()}):p.on("input.autosize",r),i.resizeDelay!==!1&&e(window).on("resize.autosize",l),p.on("autosize.resize",r),p.on("autosize.resizeIncludeStyle",function(){t=null,r()}),p.on("autosize.destroy",function(){t=null,clearTimeout(u),e(window).off("resize",l),p.off("autosize").off(".autosize").css(z).removeData("autosize")}),r())})}});
--------------------------------------------------------------------------------
/assets/js/jquery.colorbox-min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | Colorbox v1.4.27 - 2013-07-16
3 | jQuery lightbox and modal window plugin
4 | (c) 2013 Jack Moore - http://www.jacklmoore.com/colorbox
5 | license: http://www.opensource.org/licenses/mit-license.php
6 | */
7 | (function(t,e,i){function o(i,o,n){var r=e.createElement(i);return o&&(r.id=te+o),n&&(r.style.cssText=n),t(r)}function n(){return i.innerHeight?i.innerHeight:t(i).height()}function r(t){var e=E.length,i=(j+t)%e;return 0>i?e+i:i}function l(t,e){return Math.round((/%/.test(t)?("x"===e?H.width():n())/100:1)*parseInt(t,10))}function h(t,e){return t.photo||t.photoRegex.test(e)}function s(t,e){return t.retinaUrl&&i.devicePixelRatio>1?e.replace(t.photoRegex,t.retinaSuffix):e}function a(t){"contains"in v[0]&&!v[0].contains(t.target)&&(t.stopPropagation(),v.focus())}function d(){var e,i=t.data(A,Z);null==i?(O=t.extend({},Y),console&&console.log&&console.log("Error: cboxElement missing settings object")):O=t.extend({},i);for(e in O)t.isFunction(O[e])&&"on"!==e.slice(0,2)&&(O[e]=O[e].call(A));O.rel=O.rel||A.rel||t(A).data("rel")||"nofollow",O.href=O.href||t(A).attr("href"),O.title=O.title||A.title,"string"==typeof O.href&&(O.href=t.trim(O.href))}function c(i,o){t(e).trigger(i),se.trigger(i),t.isFunction(o)&&o.call(A)}function u(){var t,e,i,o,n,r=te+"Slideshow_",l="click."+te;O.slideshow&&E[1]?(e=function(){clearTimeout(t)},i=function(){(O.loop||E[j+1])&&(t=setTimeout(J.next,O.slideshowSpeed))},o=function(){R.html(O.slideshowStop).unbind(l).one(l,n),se.bind(ne,i).bind(oe,e).bind(re,n),v.removeClass(r+"off").addClass(r+"on")},n=function(){e(),se.unbind(ne,i).unbind(oe,e).unbind(re,n),R.html(O.slideshowStart).unbind(l).one(l,function(){J.next(),o()}),v.removeClass(r+"on").addClass(r+"off")},O.slideshowAuto?o():n()):v.removeClass(r+"off "+r+"on")}function p(i){G||(A=i,d(),E=t(A),j=0,"nofollow"!==O.rel&&(E=t("."+ee).filter(function(){var e,i=t.data(this,Z);return i&&(e=t(this).data("rel")||i.rel||this.rel),e===O.rel}),j=E.index(A),-1===j&&(E=E.add(A),j=E.length-1)),g.css({opacity:parseFloat(O.opacity),cursor:O.overlayClose?"pointer":"auto",visibility:"visible"}).show(),V&&v.add(g).removeClass(V),O.className&&v.add(g).addClass(O.className),V=O.className,O.closeButton?P.html(O.close).appendTo(x):P.appendTo("
"),$||($=q=!0,v.css({visibility:"hidden",display:"block"}),W=o(ae,"LoadedContent","width:0; height:0; overflow:hidden"),x.css({width:"",height:""}).append(W),_=b.height()+k.height()+x.outerHeight(!0)-x.height(),D=T.width()+C.width()+x.outerWidth(!0)-x.width(),N=W.outerHeight(!0),z=W.outerWidth(!0),O.w=l(O.initialWidth,"x"),O.h=l(O.initialHeight,"y"),J.position(),u(),c(ie,O.onOpen),B.add(S).hide(),v.focus(),O.trapFocus&&e.addEventListener&&(e.addEventListener("focus",a,!0),se.one(le,function(){e.removeEventListener("focus",a,!0)})),O.returnFocus&&se.one(le,function(){t(A).focus()})),w())}function f(){!v&&e.body&&(X=!1,H=t(i),v=o(ae).attr({id:Z,"class":t.support.opacity===!1?te+"IE":"",role:"dialog",tabindex:"-1"}).hide(),g=o(ae,"Overlay").hide(),L=t([o(ae,"LoadingOverlay")[0],o(ae,"LoadingGraphic")[0]]),y=o(ae,"Wrapper"),x=o(ae,"Content").append(S=o(ae,"Title"),M=o(ae,"Current"),K=t('
').attr({id:te+"Previous"}),I=t('
').attr({id:te+"Next"}),R=o("button","Slideshow"),L),P=t('
').attr({id:te+"Close"}),y.append(o(ae).append(o(ae,"TopLeft"),b=o(ae,"TopCenter"),o(ae,"TopRight")),o(ae,!1,"clear:left").append(T=o(ae,"MiddleLeft"),x,C=o(ae,"MiddleRight")),o(ae,!1,"clear:left").append(o(ae,"BottomLeft"),k=o(ae,"BottomCenter"),o(ae,"BottomRight"))).find("div div").css({"float":"left"}),F=o(ae,!1,"position:absolute; width:9999px; visibility:hidden; display:none"),B=I.add(K).add(M).add(R),t(e.body).append(g,v.append(y,F)))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),p(this))}return v?(X||(X=!0,I.click(function(){J.next()}),K.click(function(){J.prev()}),P.click(function(){J.close()}),g.click(function(){O.overlayClose&&J.close()}),t(e).bind("keydown."+te,function(t){var e=t.keyCode;$&&O.escKey&&27===e&&(t.preventDefault(),J.close()),$&&O.arrowKey&&E[1]&&!t.altKey&&(37===e?(t.preventDefault(),K.click()):39===e&&(t.preventDefault(),I.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+te,"."+ee,i):t("."+ee).live("click."+te,i)),!0):!1}function w(){var n,r,a,u=J.prep,p=++de;q=!0,U=!1,A=E[j],d(),c(he),c(oe,O.onLoad),O.h=O.height?l(O.height,"y")-N-_:O.innerHeight&&l(O.innerHeight,"y"),O.w=O.width?l(O.width,"x")-z-D:O.innerWidth&&l(O.innerWidth,"x"),O.mw=O.w,O.mh=O.h,O.maxWidth&&(O.mw=l(O.maxWidth,"x")-z-D,O.mw=O.w&&O.w
1&&(U.height=U.height/i.devicePixelRatio,U.width=U.width/i.devicePixelRatio),O.scalePhotos&&(r=function(){U.height-=U.height*e,U.width-=U.width*e},O.mw&&U.width>O.mw&&(e=(U.width-O.mw)/U.width,r()),O.mh&&U.height>O.mh&&(e=(U.height-O.mh)/U.height,r())),O.h&&(U.style.marginTop=Math.max(O.mh-U.height,0)/2+"px"),E[1]&&(O.loop||E[j+1])&&(U.style.cursor="pointer",U.onclick=function(){J.next()}),U.style.width=U.width+"px",U.style.height=U.height+"px",setTimeout(function(){u(U)},1))}),setTimeout(function(){U.src=n},1)):n&&F.load(n,O.data,function(e,i){p===de&&u("error"===i?o(ae,"Error").html(O.xhrError):t(this).contents())})}var g,v,y,x,b,T,C,k,E,H,W,F,L,S,M,R,I,K,P,B,O,_,D,N,z,A,j,U,$,q,G,Q,J,V,X,Y={transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,inline:!1,html:!1,iframe:!1,fastIframe:!0,photo:!1,href:!1,title:!1,rel:!1,opacity:.9,preloading:!0,className:!1,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",open:!1,returnFocus:!0,trapFocus:!0,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp)((#|\?).*)?$/i,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0},Z="colorbox",te="cbox",ee=te+"Element",ie=te+"_open",oe=te+"_load",ne=te+"_complete",re=te+"_cleanup",le=te+"_closed",he=te+"_purge",se=t(" "),ae="div",de=0,ce={};t.colorbox||(t(f),J=t.fn[Z]=t[Z]=function(e,i){var o=this;if(e=e||{},f(),m()){if(t.isFunction(o))o=t(" "),e.open=!0;else if(!o[0])return o;i&&(e.onComplete=i),o.each(function(){t.data(this,Z,t.extend({},t.data(this,Z)||Y,e))}).addClass(ee),(t.isFunction(e.open)&&e.open.call(o)||e.open)&&p(o[0])}return o},J.position=function(e,i){function o(){b[0].style.width=k[0].style.width=x[0].style.width=parseInt(v[0].style.width,10)-D+"px",x[0].style.height=T[0].style.height=C[0].style.height=parseInt(v[0].style.height,10)-_+"px"}var r,h,s,a=0,d=0,c=v.offset();if(H.unbind("resize."+te),v.css({top:-9e4,left:-9e4}),h=H.scrollTop(),s=H.scrollLeft(),O.fixed?(c.top-=h,c.left-=s,v.css({position:"fixed"})):(a=h,d=s,v.css({position:"absolute"})),d+=O.right!==!1?Math.max(H.width()-O.w-z-D-l(O.right,"x"),0):O.left!==!1?l(O.left,"x"):Math.round(Math.max(H.width()-O.w-z-D,0)/2),a+=O.bottom!==!1?Math.max(n()-O.h-N-_-l(O.bottom,"y"),0):O.top!==!1?l(O.top,"y"):Math.round(Math.max(n()-O.h-N-_,0)/2),v.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:O.w+z+D,height:O.h+N+_,top:a,left:d},e){var u=0;t.each(r,function(t){return r[t]!==ce[t]?(u=e,void 0):void 0}),e=u}ce=r,e||v.css(r),v.dequeue().animate(r,{duration:e||0,complete:function(){o(),q=!1,y[0].style.width=O.w+z+D+"px",y[0].style.height=O.h+N+_+"px",O.reposition&&setTimeout(function(){H.bind("resize."+te,J.position)},1),i&&i()},step:o})},J.resize=function(t){var e;$&&(t=t||{},t.width&&(O.w=l(t.width,"x")-z-D),t.innerWidth&&(O.w=l(t.innerWidth,"x")),W.css({width:O.w}),t.height&&(O.h=l(t.height,"y")-N-_),t.innerHeight&&(O.h=l(t.innerHeight,"y")),t.innerHeight||t.height||(e=W.scrollTop(),W.css({height:"auto"}),O.h=W.height()),W.css({height:O.h}),e&&W.scrollTop(e),J.position("none"===O.transition?0:O.speed))},J.prep=function(i){function n(){return O.w=O.w||W.width(),O.w=O.mw&&O.mw1?("string"==typeof O.current&&M.html(O.current.replace("{current}",j+1).replace("{total}",a)).show(),I[O.loop||a-1>j?"show":"hide"]().html(O.next),K[O.loop||j?"show":"hide"]().html(O.previous),O.slideshow&&R.show(),O.preloading&&t.each([r(-1),r(1)],function(){var i,o,n=E[this],r=t.data(n,Z);r&&r.href?(i=r.href,t.isFunction(i)&&(i=i.call(n))):i=t(n).attr("href"),i&&h(r,i)&&(i=s(r,i),o=e.createElement("img"),o.src=i)})):B.hide(),O.iframe?(n=o("iframe")[0],u in n&&(n[u]=0),p in n&&(n[p]="true"),O.scrolling||(n.scrolling="no"),t(n).attr({src:O.href,name:(new Date).getTime(),"class":te+"Iframe",allowFullScreen:!0,webkitAllowFullScreen:!0,mozallowfullscreen:!0}).one("load",l).appendTo(W),se.one(he,function(){n.src="//about:blank"}),O.fastIframe&&t(n).trigger("load")):l(),"fade"===O.transition?v.fadeTo(d,1,i):i())},"fade"===O.transition?v.fadeTo(d,0,function(){J.position(0,a)}):J.position(d,a)}},J.next=function(){!q&&E[1]&&(O.loop||E[j+1])&&(j=r(1),p(E[j]))},J.prev=function(){!q&&E[1]&&(O.loop||j)&&(j=r(-1),p(E[j]))},J.close=function(){$&&!G&&(G=!0,$=!1,c(re,O.onCleanup),H.unbind("."+te),g.fadeTo(O.fadeOut||0,0),v.stop().fadeTo(O.fadeOut||0,0,function(){v.add(g).css({opacity:1,cursor:"auto"}).hide(),c(he),W.empty().remove(),setTimeout(function(){G=!1,c(le,O.onClosed)},1)}))},J.remove=function(){v&&(v.stop(),t.colorbox.close(),v.stop().remove(),g.remove(),G=!1,v=null,t("."+ee).removeData(Z).removeClass(ee),t(e).unbind("click."+te))},J.element=function(){return t(A)},J.settings=Y)})(jQuery,document,window);
--------------------------------------------------------------------------------
/assets/js/jquery.dataTables.bootstrap.js:
--------------------------------------------------------------------------------
1 | //http://datatables.net/plug-ins/pagination#bootstrap
2 | $.extend( true, $.fn.dataTable.defaults, {
3 | "sDom": "<'row'<'col-sm-6'l><'col-sm-6'f>r>t<'row'<'col-sm-6'i><'col-sm-6'p>>",
4 | "sPaginationType": "bootstrap",
5 | "oLanguage": {
6 | "sLengthMenu": "Display _MENU_ records"
7 | }
8 | } );
9 |
10 |
11 | /* API method to get paging information */
12 | $.fn.dataTableExt.oApi.fnPagingInfo = function ( oSettings )
13 | {
14 | return {
15 | "iStart": oSettings._iDisplayStart,
16 | "iEnd": oSettings.fnDisplayEnd(),
17 | "iLength": oSettings._iDisplayLength,
18 | "iTotal": oSettings.fnRecordsTotal(),
19 | "iFilteredTotal": oSettings.fnRecordsDisplay(),
20 | "iPage": Math.ceil( oSettings._iDisplayStart / oSettings._iDisplayLength ),
21 | "iTotalPages": Math.ceil( oSettings.fnRecordsDisplay() / oSettings._iDisplayLength )
22 | };
23 | }
24 |
25 | /* Bootstrap style pagination control */
26 | $.extend( $.fn.dataTableExt.oPagination, {
27 | "bootstrap": {
28 | "fnInit": function( oSettings, nPaging, fnDraw ) {
29 | var oLang = oSettings.oLanguage.oPaginate;
30 | var fnClickHandler = function ( e ) {
31 | e.preventDefault();
32 | if ( oSettings.oApi._fnPageChange(oSettings, e.data.action) ) {
33 | fnDraw( oSettings );
34 | }
35 | };
36 |
37 | $(nPaging).append(
38 | ''
42 | );
43 | var els = $('a', nPaging);
44 | $(els[0]).bind( 'click.DT', { action: "previous" }, fnClickHandler );
45 | $(els[1]).bind( 'click.DT', { action: "next" }, fnClickHandler );
46 | },
47 |
48 | "fnUpdate": function ( oSettings, fnDraw ) {
49 | var iListLength = 5;
50 | var oPaging = oSettings.oInstance.fnPagingInfo();
51 | var an = oSettings.aanFeatures.p;
52 | var i, j, sClass, iStart, iEnd, iHalf=Math.floor(iListLength/2);
53 |
54 | if ( oPaging.iTotalPages < iListLength) {
55 | iStart = 1;
56 | iEnd = oPaging.iTotalPages;
57 | }
58 | else if ( oPaging.iPage <= iHalf ) {
59 | iStart = 1;
60 | iEnd = iListLength;
61 | } else if ( oPaging.iPage >= (oPaging.iTotalPages-iHalf) ) {
62 | iStart = oPaging.iTotalPages - iListLength + 1;
63 | iEnd = oPaging.iTotalPages;
64 | } else {
65 | iStart = oPaging.iPage - iHalf + 1;
66 | iEnd = iStart + iListLength - 1;
67 | }
68 |
69 | for ( i=0, iLen=an.length ; i'+j+' ')
77 | .insertBefore( $('li:last', an[i])[0] )
78 | .bind('click', function (e) {
79 | e.preventDefault();
80 | oSettings._iDisplayStart = (parseInt($('a', this).text(),10)-1) * oPaging.iLength;
81 | fnDraw( oSettings );
82 | } );
83 | }
84 |
85 | // Add / remove disabled classes from the static elements
86 | if ( oPaging.iPage === 0 ) {
87 | $('li:first', an[i]).addClass('disabled');
88 | } else {
89 | $('li:first', an[i]).removeClass('disabled');
90 | }
91 |
92 | if ( oPaging.iPage === oPaging.iTotalPages-1 || oPaging.iTotalPages === 0 ) {
93 | $('li:last', an[i]).addClass('disabled');
94 | } else {
95 | $('li:last', an[i]).removeClass('disabled');
96 | }
97 | }
98 | }
99 | }
100 | } );
--------------------------------------------------------------------------------
/assets/js/jquery.easy-pie-chart.min.js:
--------------------------------------------------------------------------------
1 | (function(a){a.easyPieChart=function(d,l){var f,g,i,j,c,k,e,b,h=this;this.el=d;this.$el=a(d);this.$el.data("easyPieChart",this);this.init=function(){var n,m;h.options=a.extend({},a.easyPieChart.defaultOptions,l);n=parseInt(h.$el.data("percent"),10);h.percentage=0;h.canvas=a(" ").get(0);h.$el.append(h.canvas);if(typeof G_vmlCanvasManager!=="undefined"&&G_vmlCanvasManager!==null){G_vmlCanvasManager.initElement(h.canvas)}h.ctx=h.canvas.getContext("2d");if(window.devicePixelRatio>1){m=window.devicePixelRatio;a(h.canvas).css({width:h.options.size,height:h.options.size});h.canvas.width*=m;h.canvas.height*=m;h.ctx.scale(m,m)}h.ctx.translate(h.options.size/2,h.options.size/2);h.ctx.rotate(h.options.rotate*Math.PI/180);h.$el.addClass("easyPieChart");h.$el.css({width:h.options.size,height:h.options.size,lineHeight:""+h.options.size+"px"});h.update(n);return h};this.update=function(m){m=parseFloat(m)||0;if(h.options.animate===false){i(m)}else{if(h.options.delay){g(h.percentage,0);setTimeout(function(){return g(h.percentage,m)},h.options.delay)}else{g(h.percentage,m)}}return h};e=function(){var n,o,m;h.ctx.fillStyle=h.options.scaleColor;h.ctx.lineWidth=1;m=[];for(n=o=0;o<=24;n=++o){m.push(f(n))}return m};f=function(m){var n;n=m%6===0?0:h.options.size*0.017;h.ctx.save();h.ctx.rotate(m*Math.PI/12);h.ctx.fillRect(h.options.size/2-n,0,-h.options.size*0.05+n,1);h.ctx.restore()};b=function(){var m;m=h.options.size/2-h.options.lineWidth/2;if(h.options.scaleColor!==false){m-=h.options.size*0.08}h.ctx.beginPath();h.ctx.arc(0,0,m,0,Math.PI*2,true);h.ctx.closePath();h.ctx.strokeStyle=h.options.trackColor;h.ctx.lineWidth=h.options.lineWidth;h.ctx.stroke()};k=function(){if(h.options.scaleColor!==false){e()}if(h.options.trackColor!==false){b()}};i=function(m){var n;k();h.ctx.strokeStyle=a.isFunction(h.options.barColor)?h.options.barColor(m):h.options.barColor;h.ctx.lineCap=h.options.lineCap;h.ctx.lineWidth=h.options.lineWidth;n=h.options.size/2-h.options.lineWidth/2;if(h.options.scaleColor!==false){n-=h.options.size*0.08}h.ctx.save();h.ctx.rotate(-Math.PI/2);h.ctx.beginPath();h.ctx.arc(0,0,n,0,Math.PI*2*m/100,false);h.ctx.stroke();h.ctx.restore()};c=(function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(m){return window.setTimeout(m,1000/60)}})();g=function(p,o){var n,m;h.options.onStart.call(h);h.percentage=o;Date.now||(Date.now=function(){return +(new Date)});m=Date.now();n=function(){var q,r;r=Math.min(Date.now()-m,h.options.animate);h.ctx.clearRect(-h.options.size/2,-h.options.size/2,h.options.size,h.options.size);k.call(h);q=[j(r,p,o-p,h.options.animate)];h.options.onStep.call(h,q);i.call(h,q);if(r>=h.options.animate){return h.options.onStop.call(h,q,o)}else{return c(n)}};c(n)};j=function(o,n,r,p){var m,q;m=function(s){return Math.pow(s,2)};q=function(s){if(s<1){return m(s)}else{return 2-m((s/2)*-2+2)}};o/=p/2;return r/2*q(o)+n};return this.init()};a.easyPieChart.defaultOptions={barColor:"#ef1e25",trackColor:"#f2f2f2",scaleColor:"#dfe0e0",lineCap:"round",rotate:0,size:110,lineWidth:3,animate:false,delay:false,onStart:a.noop,onStop:a.noop,onStep:a.noop};a.fn.easyPieChart=function(b){return a.each(this,function(d,e){var c,f;c=a(e);if(!c.data("easyPieChart")){f=a.extend({},b,c.data());return c.data("easyPieChart",new a.easyPieChart(e,f))}})};return void 0})(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.gritter.min.js:
--------------------------------------------------------------------------------
1 | (function(b){b.gritter={};b.gritter.options={position:"",class_name:"",fade_in_speed:"medium",fade_out_speed:1000,time:6000};b.gritter.add=function(f){try{return a.add(f||{})}catch(d){var c="Gritter Error: "+d;(typeof(console)!="undefined"&&console.error)?console.error(c,f):alert(c)}};b.gritter.remove=function(d,c){a.removeSpecific(d,c||{})};b.gritter.removeAll=function(c){a.stop(c||{})};var a={position:"",fade_in_speed:"",fade_out_speed:"",time:"",_custom_timer:0,_item_count:0,_is_setup:0,_tpl_close:'
',_tpl_title:'[[title]] ',_tpl_item:'',_tpl_wrap:'
',add:function(g){if(typeof(g)=="string"){g={text:g}}if(g.text===null){throw'You must supply "text" parameter.'}if(!this._is_setup){this._runSetup()}var k=g.title,n=g.text,e=g.image||"",l=g.sticky||false,m=g.class_name||b.gritter.options.class_name,j=b.gritter.options.position,d=g.time||"";this._verifyWrapper();this._item_count++;var f=this._item_count,i=this._tpl_item;b(["before_open","after_open","before_close","after_close"]).each(function(p,q){a["_"+q+"_"+f]=(b.isFunction(g[q]))?g[q]:function(){}});this._custom_timer=0;if(d){this._custom_timer=d}var c=(e!="")?' ':"",h=(e!="")?"gritter-with-image":"gritter-without-image";if(k){k=this._str_replace("[[title]]",k,this._tpl_title)}else{k=""}i=this._str_replace(["[[title]]","[[text]]","[[close]]","[[image]]","[[number]]","[[class_name]]","[[item_class]]"],[k,n,this._tpl_close,c,this._item_count,h,m],i);if(this["_before_open_"+f]()===false){return false}b("#gritter-notice-wrapper").addClass(j).append(i);var o=b("#gritter-item-"+this._item_count);o.fadeIn(this.fade_in_speed,function(){a["_after_open_"+f](b(this))});if(!l){this._setFadeTimer(o,f)}b(o).bind("mouseenter mouseleave",function(p){if(p.type=="mouseenter"){if(!l){a._restoreItemIfFading(b(this),f)}}else{if(!l){a._setFadeTimer(b(this),f)}}a._hoverState(b(this),p.type)});b(o).find(".gritter-close").click(function(){a.removeSpecific(f,{},null,true)});return f},_countRemoveWrapper:function(c,d,f){d.remove();this["_after_close_"+c](d,f);if(b(".gritter-item-wrapper").length==0){b("#gritter-notice-wrapper").remove()}},_fade:function(g,d,j,f){var j=j||{},i=(typeof(j.fade)!="undefined")?j.fade:true,c=j.speed||this.fade_out_speed,h=f;this["_before_close_"+d](g,h);if(f){g.unbind("mouseenter mouseleave")}if(i){g.animate({opacity:0},c,function(){g.animate({height:0},300,function(){a._countRemoveWrapper(d,g,h)})})}else{this._countRemoveWrapper(d,g)}},_hoverState:function(d,c){if(c=="mouseenter"){d.addClass("hover");d.find(".gritter-close").show()}else{d.removeClass("hover");d.find(".gritter-close").hide()}},removeSpecific:function(c,g,f,d){if(!f){var f=b("#gritter-item-"+c)}this._fade(f,c,g||{},d)},_restoreItemIfFading:function(d,c){clearTimeout(this["_int_id_"+c]);d.stop().css({opacity:"",height:""})},_runSetup:function(){for(opt in b.gritter.options){this[opt]=b.gritter.options[opt]}this._is_setup=1},_setFadeTimer:function(f,d){var c=(this._custom_timer)?this._custom_timer:this.time;this["_int_id_"+d]=setTimeout(function(){a._fade(f,d)},c)},stop:function(e){var c=(b.isFunction(e.before_close))?e.before_close:function(){};var f=(b.isFunction(e.after_close))?e.after_close:function(){};var d=b("#gritter-notice-wrapper");c(d);d.fadeOut(function(){b(this).remove();f()})},_str_replace:function(v,e,o,n){var k=0,h=0,t="",m="",g=0,q=0,l=[].concat(v),c=[].concat(e),u=o,d=c instanceof Array,p=u instanceof Array;u=[].concat(u);if(n){this.window[n]=0}for(k=0,g=u.length;k","/":"?","\\":"|"}};function a(d){if(typeof d.data=="undefined"){return}if(typeof d.data==="string"){d.data={keys:d.data}}if(!d.data||!d.data.keys||typeof d.data.keys!=="string"){return}var c=d.handler,e=d.data.keys.toLowerCase().split(" "),f=["text","password","number","email","url","range","date","month","week","time","datetime","datetime-local","search","color","tel"];d.handler=function(k){if(this!==k.target&&(/textarea|select/i.test(k.target.nodeName)||b.inArray(k.target.type,f)>-1)){return}var h=b.hotkeys.specialKeys[k.keyCode],m=(k.type==="keydown"||k.type==="keypress")&&String.fromCharCode(k.which).toLowerCase();modif="",possible={};if(k.altKey&&h!=="alt"){modif+="alt+"}if(k.ctrlKey&&h!=="ctrl"){modif+="ctrl+"}if(k.metaKey&&!k.ctrlKey&&h!=="meta"){modif+="meta+"}if(k.shiftKey&&h!=="shift"){modif+="shift+"}if(h){possible[modif+h]=true}if(m){possible[modif+m]=true;possible[modif+b.hotkeys.shiftNums[m]]=true;if(modif==="shift+"){possible[b.hotkeys.shiftNums[m]]=true}}for(var j=0,g=e.length;j').appendTo("body").attr({id:opts.boxId,'class':opts.boxClass}).css({'position':'absolute'}).hide();if($.fn.bgiframe){$('#'+opts.boxId).bgiframe();}}
2 | var inputlimiterKeyup=function(e){var $this=$(this),count=counter($this.val());if(!opts.allowExceed&&count>opts.limit){$this.val(truncater($this.val()));}
3 | if(opts.boxAttach){$('#'+opts.boxId).css({'width':$this.outerWidth()-($('#'+opts.boxId).outerWidth()-$('#'+opts.boxId).width())+'px','left':$this.offset().left+'px','top':($this.offset().top+$this.outerHeight())-1+'px','z-index':2000});}
4 | var charsRemaining=(opts.limit-count>0?opts.limit-count:0),remText=opts.remTextFilter(opts,charsRemaining),limitText=opts.limitTextFilter(opts);if(opts.limitTextShow){$('#'+opts.boxId).html(remText+' '+limitText);var textWidth=$(" ").appendTo("body").attr({id:'19cc9195583bfae1fad88e19d443be7a','class':opts.boxClass}).html(remText+' '+limitText).innerWidth();$("#19cc9195583bfae1fad88e19d443be7a").remove();if(textWidth>$('#'+opts.boxId).innerWidth()){$('#'+opts.boxId).html(remText+' '+limitText);}
5 | $('#'+opts.boxId).show();}else{$('#'+opts.boxId).html(remText).show();}},inputlimiterKeypress=function(e){var count=counter($(this).val());if(!opts.allowExceed&&count>opts.limit){var modifierKeyPressed=e.ctrlKey||e.altKey||e.metaKey;if(!modifierKeyPressed&&(e.which>=32&&e.which<=122)&&this.selectionStart===this.selectionEnd){return false;}}},inputlimiterBlur=function(){var $this=$(this);count=counter($this.val());if(!opts.allowExceed&&count>opts.limit){$this.val(truncater($this.val()));}
6 | if(opts.boxAttach){$('#'+opts.boxId).fadeOut('fast');}else if(opts.remTextHideOnBlur){var limitText=opts.limitText;limitText=limitText.replace(/\%n/g,opts.limit);limitText=limitText.replace(/\%s/g,(opts.limit===1?'':'s'));$('#'+opts.boxId).html(limitText);}},counter=function(value){if(opts.limitBy.toLowerCase()==="words"){return(value.length>0?$.trim(value).replace(/\ +(?= )/g,'').split(' ').length:0);}
7 | var count=value.length,newlines=value.match(/\n/g);if(newlines&&opts.lineReturnCount>1){count+=newlines.length*(opts.lineReturnCount-1);}
8 | return count;},truncater=function(value){if(opts.limitBy.toLowerCase()==="words"){return $.trim(value).replace(/\ +(?= )/g,'').split(' ').splice(0,opts.limit).join(' ')+' ';}
9 | return value.substring(0,opts.limit);};$(this).each(function(i){var $this=$(this);if((!options||!options.limit)&&opts.useMaxlength&&parseInt($this.attr('maxlength'))>0&&parseInt($this.attr('maxlength'))!=opts.limit){$this.inputlimiter($.extend({},opts,{limit:parseInt($this.attr('maxlength'))}));}else{if(!opts.allowExceed&&opts.useMaxlength&&opts.limitBy.toLowerCase()==="characters"){$this.attr('maxlength',opts.limit);}
10 | $this.unbind('.inputlimiter');$this.bind('keyup.inputlimiter',inputlimiterKeyup);$this.bind('keypress.inputlimiter',inputlimiterKeypress);$this.bind('blur.inputlimiter',inputlimiterBlur);}});};$.fn.inputlimiter.remtextfilter=function(opts,charsRemaining){var remText=opts.remText;if(charsRemaining===0&&opts.remFullText!==null){remText=opts.remFullText;}
11 | remText=remText.replace(/\%n/g,charsRemaining);remText=remText.replace(/\%s/g,(opts.zeroPlural?(charsRemaining===1?'':'s'):(charsRemaining<=1?'':'s')));return remText;};$.fn.inputlimiter.limittextfilter=function(opts){var limitText=opts.limitText;limitText=limitText.replace(/\%n/g,opts.limit);limitText=limitText.replace(/\%s/g,(opts.limit<=1?'':'s'));return limitText;};$.fn.inputlimiter.defaults={limit:255,boxAttach:true,boxId:'limiterBox',boxClass:'limiterBox',remText:'%n character%s remaining.',remTextFilter:$.fn.inputlimiter.remtextfilter,remTextHideOnBlur:true,remFullText:null,limitTextShow:true,limitText:'Field limited to %n character%s.',limitTextFilter:$.fn.inputlimiter.limittextfilter,zeroPlural:true,allowExceed:false,useMaxlength:true,limitBy:'characters',lineReturnCount:1};})(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.knob.min.js:
--------------------------------------------------------------------------------
1 | /*!jQuery Knob*/
2 | /**
3 | * Downward compatible, touchable dial
4 | *
5 | * Version: 1.2.0 (15/07/2012)
6 | * Requires: jQuery v1.7+
7 | *
8 | * Copyright (c) 2012 Anthony Terrien
9 | * Under MIT and GPL licenses:
10 | * http://www.opensource.org/licenses/mit-license.php
11 | * http://www.gnu.org/licenses/gpl.html
12 | *
13 | * Thanks to vor, eskimoblood, spiffistan, FabrizioC
14 | */
15 | (function($){"use strict";var k={},max=Math.max,min=Math.min;k.c={};k.c.d=$(document);k.c.t=function(e){return e.originalEvent.touches.length-1};k.o=function(){var s=this;this.o=null;this.$=null;this.i=null;this.g=null;this.v=null;this.cv=null;this.x=0;this.y=0;this.$c=null;this.c=null;this.t=0;this.isInit=false;this.fgColor=null;this.pColor=null;this.dH=null;this.cH=null;this.eH=null;this.rH=null;this.usesExcanvas=typeof G_vmlCanvasManager!=="undefined";this.run=function(){var cf=function(e,conf){var k;for(k in conf){s.o[k]=conf[k]}s.init();s._configure()._draw()};if(this.$.data("kontroled"))return;this.$.data("kontroled",true);this.extend();this.o=$.extend({min:this.$.data("min")||0,max:this.$.data("max")||100,stopper:true,readOnly:this.$.data("readonly"),cursor:this.$.data("cursor")===true&&30||this.$.data("cursor")||0,thickness:this.$.data("thickness")||.35,width:this.$.data("width")||200,height:this.$.data("height")||200,displayInput:this.$.data("displayinput")==null||this.$.data("displayinput"),displayPrevious:this.$.data("displayprevious"),fgColor:this.$.data("fgcolor")||"#87CEEB",inline:false,draw:null,change:null,cancel:null,release:null},this.o);if(this.$.is("fieldset")){this.v={};this.i=this.$.find("input");this.i.each(function(k){var $this=$(this);s.i[k]=$this;s.v[k]=$this.val();$this.bind("change",function(){var val={};val[k]=$this.val();s.val(val)})});this.$.find("legend").remove()}else{this.i=this.$;this.v=this.$.val();this.v==""&&(this.v=this.o.min);this.$.bind("change",function(){s.val(s.$.val())})}!this.o.displayInput&&this.$.hide();this.$c=$(document.createElement("canvas")).attr({width:this.o.width,height:this.o.height});this.$.wrap($('
')).before(this.$c);if(typeof G_vmlCanvasManager!=="undefined"){G_vmlCanvasManager.initElement(this.$c[0])}if(this.usesExcanvas){G_vmlCanvasManager.initElement(this.$c[0])}this.c=this.$c[0].getContext("2d");if(this.v instanceof Object){this.cv={};this.copy(this.v,this.cv)}else{this.cv=this.v}this.$.bind("configure",cf).parent().bind("configure",cf);this._listen()._configure()._xy().init();this.isInit=true;this._draw();return this};this._draw=function(){var d=true;s.g=s.c;s.clear();s.dH&&(d=s.dH());d!==false&&s.draw()};this._touch=function(e){var touchMove=function(e){var v=s.xy2val(e.originalEvent.touches[s.t].pageX,e.originalEvent.touches[s.t].pageY);if(v==s.cv)return;if(s.cH&&s.cH(v)===false)return;s.change(v);s._draw()};this.t=k.c.t(e);touchMove(e);k.c.d.bind("touchmove.k",touchMove).bind("touchend.k",function(){k.c.d.unbind("touchmove.k touchend.k");if(s.rH&&s.rH(s.cv)===false)return;s.val(s.cv)});return this};this._mouse=function(e){var mouseMove=function(e){var v=s.xy2val(e.pageX,e.pageY);if(v==s.cv)return;if(s.cH&&s.cH(v)===false)return;s.change(v);s._draw()};mouseMove(e);k.c.d.bind("mousemove.k",mouseMove).bind("keyup.k",function(e){if(e.keyCode===27){k.c.d.unbind("mouseup.k mousemove.k keyup.k");if(s.eH&&s.eH()===false)return;s.cancel()}}).bind("mouseup.k",function(e){k.c.d.unbind("mousemove.k mouseup.k keyup.k");if(s.rH&&s.rH(s.cv)===false)return;s.val(s.cv)});return this};this._xy=function(){var o=this.$c.offset();this.x=o.left;this.y=o.top;return this};this._listen=function(){if(!this.o.readOnly){this.$c.bind("mousedown",function(e){e.preventDefault();s._xy()._mouse(e)}).bind("touchstart",function(e){e.preventDefault();s._xy()._touch(e)});this.listen()}else{this.$.attr("readonly","readonly")}return this};this._configure=function(){if(this.o.draw)this.dH=this.o.draw;if(this.o.change)this.cH=this.o.change;if(this.o.cancel)this.eH=this.o.cancel;if(this.o.release)this.rH=this.o.release;if(this.o.displayPrevious){this.pColor=this.h2rgba(this.o.fgColor,"0.4");this.fgColor=this.h2rgba(this.o.fgColor,"0.6")}else{this.fgColor=this.o.fgColor}return this};this._clear=function(){this.$c[0].width=this.$c[0].width};this.listen=function(){};this.extend=function(){};this.init=function(){};this.change=function(v){};this.val=function(v){};this.xy2val=function(x,y){};this.draw=function(){};this.clear=function(){this._clear()};this.h2rgba=function(h,a){var rgb;h=h.substring(1,7);rgb=[parseInt(h.substring(0,2),16),parseInt(h.substring(2,4),16),parseInt(h.substring(4,6),16)];return"rgba("+rgb[0]+","+rgb[1]+","+rgb[2]+","+a+")"};this.copy=function(f,t){for(var i in f){t[i]=f[i]}}};k.Dial=function(){k.o.call(this);this.startAngle=null;this.xy=null;this.radius=null;this.lineWidth=null;this.cursorExt=null;this.w2=null;this.PI2=2*Math.PI;this.extend=function(){this.o=$.extend({bgColor:this.$.data("bgcolor")||"#EEEEEE",angleOffset:this.$.data("angleoffset")||0,angleArc:this.$.data("anglearc")||360,inline:true},this.o)};this.val=function(v){if(null!=v){this.cv=this.o.stopper?max(min(v,this.o.max),this.o.min):v;this.v=this.cv;this.$.val(this.v);this._draw()}else{return this.v}};this.xy2val=function(x,y){var a,ret;a=Math.atan2(x-(this.x+this.w2),-(y-this.y-this.w2))-this.angleOffset;if(this.angleArc!=this.PI2&&a<0&&a>-.5){a=0}else if(a<0){a+=this.PI2}ret=~~(.5+a*(this.o.max-this.o.min)/this.angleArc)+this.o.min;this.o.stopper&&(ret=max(min(ret,this.o.max),this.o.min));return ret};this.listen=function(){var s=this,mw=function(e){e.preventDefault();var ori=e.originalEvent,deltaX=ori.detail||ori.wheelDeltaX,deltaY=ori.detail||ori.wheelDeltaY,v=parseInt(s.$.val()||s.o.min)+(deltaX>0||deltaY>0?1:deltaX<0||deltaY<0?-1:0);if(s.cH&&s.cH(v)===false)return;s.val(v)},kval,to,m=1,kv={37:-1,38:1,39:1,40:-1};this.$.bind("keydown",function(e){var kc=e.keyCode;if(kc>=96&&kc<=105){kc=e.keyCode=kc-48}kval=parseInt(String.fromCharCode(kc));if(isNaN(kval)){kc!==13&&kc!==8&&kc!==9&&kc!==189&&e.preventDefault();if($.inArray(kc,[37,38,39,40])>-1){e.preventDefault();var v=parseInt(s.$.val())+kv[kc]*m;s.o.stopper&&(v=max(min(v,s.o.max),s.o.min));s.change(v);s._draw();to=window.setTimeout(function(){m*=2},30)}}}).bind("keyup",function(e){if(isNaN(kval)){if(to){window.clearTimeout(to);to=null;m=1;s.val(s.$.val())}}else{s.$.val()>s.o.max&&s.$.val(s.o.max)||s.$.val()this.o.max)this.v=this.o.min;this.$.val(this.v);this.w2=this.o.width/2;this.cursorExt=this.o.cursor/100;this.xy=this.w2;this.lineWidth=this.xy*this.o.thickness;this.radius=this.xy-this.lineWidth/2;this.o.angleOffset&&(this.o.angleOffset=isNaN(this.o.angleOffset)?0:this.o.angleOffset);this.o.angleArc&&(this.o.angleArc=isNaN(this.o.angleArc)?this.PI2:this.o.angleArc);this.angleOffset=this.o.angleOffset*Math.PI/180;this.angleArc=this.o.angleArc*Math.PI/180;this.startAngle=1.5*Math.PI+this.angleOffset;this.endAngle=1.5*Math.PI+this.angleOffset+this.angleArc;var s=max(String(Math.abs(this.o.max)).length,String(Math.abs(this.o.min)).length,2)+2;this.o.displayInput&&this.i.css({width:(this.o.width/2+4>>0)+"px",height:(this.o.width/3>>0)+"px",position:"absolute","vertical-align":"middle","margin-top":(this.o.width/3>>0)+"px","margin-left":"-"+(this.o.width*3/4+2>>0)+"px",border:0,background:"none",font:"bold "+(this.o.width/s>>0)+"px Arial","text-align":"center",color:this.o.fgColor,padding:"0px","-webkit-appearance":"none"})||this.i.css({width:"0px",visibility:"hidden"})};this.change=function(v){this.cv=v;this.$.val(v)};this.angle=function(v){return(v-this.o.min)*this.angleArc/(this.o.max-this.o.min)};this.draw=function(){var c=this.g,a=this.angle(this.cv),sat=this.startAngle,eat=sat+a,sa,ea,r=1;c.lineWidth=this.lineWidth;this.o.cursor&&(sat=eat-this.cursorExt)&&(eat=eat+this.cursorExt);c.beginPath();c.strokeStyle=this.o.bgColor;c.arc(this.xy,this.xy,this.radius,this.endAngle,this.startAngle,true);c.stroke();if(this.o.displayPrevious){ea=this.startAngle+this.angle(this.v);sa=this.startAngle;this.o.cursor&&(sa=ea-this.cursorExt)&&(ea=ea+this.cursorExt);c.beginPath();c.strokeStyle=this.pColor;c.arc(this.xy,this.xy,this.radius,sa,ea,false);c.stroke();r=this.cv==this.v}c.beginPath();c.strokeStyle=r?this.o.fgColor:this.fgColor;c.arc(this.xy,this.xy,this.radius,sat,eat,false);c.stroke()};this.cancel=function(){this.val(this.v)}};$.fn.dial=$.fn.knob=function(o){return this.each(function(){var d=new k.Dial;d.o=o;d.$=$(this);d.run()}).parent()}})(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.maskedinput.min.js:
--------------------------------------------------------------------------------
1 | /*
2 | Masked Input plugin for jQuery
3 | Copyright (c) 2007-2013 Josh Bush (digitalbush.com)
4 | Licensed under the MIT license (http://digitalbush.com/projects/masked-input-plugin/#license)
5 | Version: 1.3.1
6 | */
7 | (function(e){function t(){var e=document.createElement("input"),t="onpaste";return e.setAttribute(t,""),"function"==typeof e[t]?"paste":"input"}var n,a=t()+".mask",r=navigator.userAgent,i=/iphone/i.test(r),o=/android/i.test(r);e.mask={definitions:{9:"[0-9]",a:"[A-Za-z]","*":"[A-Za-z0-9]"},dataName:"rawMaskFn",placeholder:"_"},e.fn.extend({caret:function(e,t){var n;if(0!==this.length&&!this.is(":hidden"))return"number"==typeof e?(t="number"==typeof t?t:e,this.each(function(){this.setSelectionRange?this.setSelectionRange(e,t):this.createTextRange&&(n=this.createTextRange(),n.collapse(!0),n.moveEnd("character",t),n.moveStart("character",e),n.select())})):(this[0].setSelectionRange?(e=this[0].selectionStart,t=this[0].selectionEnd):document.selection&&document.selection.createRange&&(n=document.selection.createRange(),e=0-n.duplicate().moveStart("character",-1e5),t=e+n.text.length),{begin:e,end:t})},unmask:function(){return this.trigger("unmask")},mask:function(t,r){var c,l,s,u,f,h;return!t&&this.length>0?(c=e(this[0]),c.data(e.mask.dataName)()):(r=e.extend({placeholder:e.mask.placeholder,completed:null},r),l=e.mask.definitions,s=[],u=h=t.length,f=null,e.each(t.split(""),function(e,t){"?"==t?(h--,u=e):l[t]?(s.push(RegExp(l[t])),null===f&&(f=s.length-1)):s.push(null)}),this.trigger("unmask").each(function(){function c(e){for(;h>++e&&!s[e];);return e}function d(e){for(;--e>=0&&!s[e];);return e}function m(e,t){var n,a;if(!(0>e)){for(n=e,a=c(t);h>n;n++)if(s[n]){if(!(h>a&&s[n].test(R[a])))break;R[n]=R[a],R[a]=r.placeholder,a=c(a)}b(),x.caret(Math.max(f,e))}}function p(e){var t,n,a,i;for(t=e,n=r.placeholder;h>t;t++)if(s[t]){if(a=c(t),i=R[t],R[t]=n,!(h>a&&s[a].test(i)))break;n=i}}function g(e){var t,n,a,r=e.which;8===r||46===r||i&&127===r?(t=x.caret(),n=t.begin,a=t.end,0===a-n&&(n=46!==r?d(n):a=c(n-1),a=46===r?c(a):a),k(n,a),m(n,a-1),e.preventDefault()):27==r&&(x.val(S),x.caret(0,y()),e.preventDefault())}function v(t){var n,a,i,l=t.which,u=x.caret();t.ctrlKey||t.altKey||t.metaKey||32>l||l&&(0!==u.end-u.begin&&(k(u.begin,u.end),m(u.begin,u.end-1)),n=c(u.begin-1),h>n&&(a=String.fromCharCode(l),s[n].test(a)&&(p(n),R[n]=a,b(),i=c(n),o?setTimeout(e.proxy(e.fn.caret,x,i),0):x.caret(i),r.completed&&i>=h&&r.completed.call(x))),t.preventDefault())}function k(e,t){var n;for(n=e;t>n&&h>n;n++)s[n]&&(R[n]=r.placeholder)}function b(){x.val(R.join(""))}function y(e){var t,n,a=x.val(),i=-1;for(t=0,pos=0;h>t;t++)if(s[t]){for(R[t]=r.placeholder;pos++a.length)break}else R[t]===a.charAt(pos)&&t!==u&&(pos++,i=t);return e?b():u>i+1?(x.val(""),k(0,h)):(b(),x.val(x.val().substring(0,i+1))),u?t:f}var x=e(this),R=e.map(t.split(""),function(e){return"?"!=e?l[e]?r.placeholder:e:void 0}),S=x.val();x.data(e.mask.dataName,function(){return e.map(R,function(e,t){return s[t]&&e!=r.placeholder?e:null}).join("")}),x.attr("readonly")||x.one("unmask",function(){x.unbind(".mask").removeData(e.mask.dataName)}).bind("focus.mask",function(){clearTimeout(n);var e;S=x.val(),e=y(),n=setTimeout(function(){b(),e==t.length?x.caret(0,e):x.caret(e)},10)}).bind("blur.mask",function(){y(),x.val()!=S&&x.change()}).bind("keydown.mask",g).bind("keypress.mask",v).bind(a,function(){setTimeout(function(){var e=y(!0);x.caret(e),r.completed&&e==x.val().length&&r.completed.call(x)},0)}),y()}))}})})(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.mobile.custom.min.js:
--------------------------------------------------------------------------------
1 | /*! jQuery Mobile v1.3.2 | Copyright 2010, 2013 jQuery Foundation, Inc. | jquery.org/license */
2 |
3 | (function(e,t,n){typeof define=="function"&&define.amd?define(["jquery"],function(r){return n(r,e,t),r.mobile}):n(e.jQuery,e,t)})(this,document,function(e,t,n,r){(function(e,t,n,r){function x(e){while(e&&typeof e.originalEvent!="undefined")e=e.originalEvent;return e}function T(t,n){var i=t.type,s,o,a,l,c,h,p,d,v;t=e.Event(t),t.type=n,s=t.originalEvent,o=e.event.props,i.search(/^(mouse|click)/)>-1&&(o=f);if(s)for(p=o.length,l;p;)l=o[--p],t[l]=s[l];i.search(/mouse(down|up)|click/)>-1&&!t.which&&(t.which=1);if(i.search(/^touch/)!==-1){a=x(s),i=a.touches,c=a.changedTouches,h=i&&i.length?i[0]:c&&c.length?c[0]:r;if(h)for(d=0,v=u.length;di||Math.abs(n.pageY-p)>i,d&&!r&&D("vmousecancel",t,s),D("vmousemove",t,s),M()}function F(e){if(g)return;L();var t=N(e.target),n;D("vmouseup",e,t);if(!d){var r=D("vclick",e,t);r&&r.isDefaultPrevented()&&(n=x(e).changedTouches[0],v.push({touchID:E,x:n.clientX,y:n.clientY}),m=!0)}D("vmouseout",e,t),d=!1,M()}function I(t){var n=e.data(t,i),r;if(n)for(r in n)if(n[r])return!0;return!1}function q(){}function R(t){var n=t.substr(1);return{setup:function(r,s){I(this)||e.data(this,i,{});var o=e.data(this,i);o[t]=!0,l[t]=(l[t]||0)+1,l[t]===1&&b.bind(n,P),e(this).bind(n,q),y&&(l.touchstart=(l.touchstart||0)+1,l.touchstart===1&&b.bind("touchstart",H).bind("touchend",F).bind("touchmove",j).bind("scroll",B))},teardown:function(r,s){--l[t],l[t]||b.unbind(n,P),y&&(--l.touchstart,l.touchstart||b.unbind("touchstart",H).unbind("touchmove",j).unbind("touchend",F).unbind("scroll",B));var o=e(this),u=e.data(this,i);u&&(u[t]=!1),o.unbind(n,q),I(this)||o.removeData(i)}}}var i="virtualMouseBindings",s="virtualTouchID",o="vmouseover vmousedown vmousemove vmouseup vclick vmouseout vmousecancel".split(" "),u="clientX clientY pageX pageY screenX screenY".split(" "),a=e.event.mouseHooks?e.event.mouseHooks.props:[],f=e.event.props.concat(a),l={},c=0,h=0,p=0,d=!1,v=[],m=!1,g=!1,y="addEventListener"in n,b=e(n),w=1,E=0,S;e.vmouse={moveDistanceThreshold:10,clickDistanceThreshold:10,resetTimerDuration:1500};for(var U=0;Ue.event.special.swipe.horizontalDistanceThreshold&&Math.abs(t.coords[1]-n.coords[1])n.coords[0]?"swipeleft":"swiperight")},setup:function(){var t=this,n=e(t);n.bind(u,function(t){function o(t){if(!i)return;s=e.event.special.swipe.stop(t),Math.abs(i.coords[0]-s.coords[0])>e.event.special.swipe.scrollSupressionThreshold&&t.preventDefault()}var i=e.event.special.swipe.start(t),s;n.bind(f,o).one(a,function(){n.unbind(f,o),i&&s&&e.event.special.swipe.handleSwipe(i,s),i=s=r})})}},e.each({scrollstop:"scrollstart",taphold:"tap",swipeleft:"swipe",swiperight:"swipe"},function(t,n){e.event.special[t]={setup:function(){e(this).bind(n,e.noop)}}})}(e,this),function(e,t,r){var i={};e.mobile=e.extend(e.mobile,{version:"1.3.2",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},window:e(t),document:e(n),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},behaviors:{},silentScroll:function(n){e.type(n)!=="number"&&(n=e.mobile.defaultHomeScroll),e.event.special.scrollstart.enabled=!1,setTimeout(function(){t.scrollTo(0,n),e.mobile.document.trigger("silentscroll",{x:0,y:n})},20),setTimeout(function(){e.event.special.scrollstart.enabled=!0},150)},nsNormalizeDict:i,nsNormalize:function(t){if(!t)return;return i[t]||(i[t]=e.camelCase(e.mobile.ns+t))},getInheritedTheme:function(e,t){var n=e[0],r="",i=/ui-(bar|body|overlay)-([a-z])\b/,s,o;while(n){s=n.className||"";if(s&&(o=i.exec(s))&&(r=o[2]))break;n=n.parentNode}return r||t||"a"},closestPageData:function(e){return e.closest(':jqmData(role="page"), :jqmData(role="dialog")').data("mobile-page")},enhanceable:function(e){return this.haveParents(e,"enhance")},hijackable:function(e){return this.haveParents(e,"ajax")},haveParents:function(t,n){if(!e.mobile.ignoreContentEnabled)return t;var r=t.length,i=e(),s,o,u;for(var a=0;a ").text(e(this).text()).html()},e.fn.jqmEnhanceable=function(){return e.mobile.enhanceable(this)},e.fn.jqmHijackable=function(){return e.mobile.hijackable(this)};var s=e.find,o=/:jqmData\(([^)]*)\)/g;e.find=function(t,n,r,i){return t=t.replace(o,"[data-"+(e.mobile.ns||"")+"$1]"),s.call(this,t,n,r,i)},e.extend(e.find,s),e.find.matches=function(t,n){return e.find(t,null,null,n)},e.find.matchesSelector=function(t,n){return e.find(n,null,null,[t]).length>0}}(e,this)});
--------------------------------------------------------------------------------
/assets/js/jquery.nestable.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * Nestable jQuery Plugin - Copyright (c) 2012 David Bushell - http://dbushell.com/
3 | * Dual-licensed under the BSD or MIT licenses
4 | */
5 | (function(e,g,h,c){var f="ontouchstart" in g;var b=(function(){var m=h.createElement("div"),n=h.documentElement;if(!("pointerEvents" in m.style)){return false}m.style.pointerEvents="auto";m.style.pointerEvents="x";n.appendChild(m);var l=g.getComputedStyle&&g.getComputedStyle(m,"").pointerEvents==="auto";n.removeChild(m);return !!l})();var k=f?"touchstart":"mousedown",j=f?"touchmove":"mousemove",a=f?"touchend":"mouseup";eCancel=f?"touchcancel":"mouseup";var d={listNodeName:"ol",itemNodeName:"li",rootClass:"dd",listClass:"dd-list",itemClass:"dd-item",dragClass:"dd-dragel",handleClass:"dd-handle",collapsedClass:"dd-collapsed",placeClass:"dd-placeholder",noDragClass:"dd-nodrag",emptyClass:"dd-empty",expandBtnHTML:'Expand ',collapseBtnHTML:'Collapse ',group:0,maxDepth:5,threshold:20};function i(m,l){this.w=e(g);this.el=e(m);this.options=e.extend({},d,l);this.init()}i.prototype={init:function(){var o=this;o.reset();o.el.data("nestable-group",this.options.group);o.placeEl=e('
');e.each(this.el.find(o.options.itemNodeName),function(p,q){o.setParent(e(q))});o.el.on("click","button",function(s){if(o.dragEl||(!f&&s.button!==0)){return}var r=e(s.currentTarget),q=r.data("action"),p=r.parent(o.options.itemNodeName);if(q==="collapse"){o.collapseItem(p)}if(q==="expand"){o.expandItem(p)}});var l=function(q){var p=e(q.target);if(!p.hasClass(o.options.handleClass)){if(p.closest("."+o.options.noDragClass).length){return}p=p.closest("."+o.options.handleClass)}if(!p.length||o.dragEl||(!f&&q.button!==0)||(f&&q.touches.length!==1)){return}q.preventDefault();o.dragStart(f?q.touches[0]:q)};var n=function(p){if(o.dragEl){p.preventDefault();o.dragMove(f?p.touches[0]:p)}};var m=function(p){if(o.dragEl){p.preventDefault();o.dragStop(f?p.touches[0]:p)}};if(f){o.el[0].addEventListener(k,l,false);g.addEventListener(j,n,false);g.addEventListener(a,m,false);g.addEventListener(eCancel,m,false)}else{o.el.on(k,l);o.w.on(j,n);o.w.on(a,m)}},serialize:function(){var m,n=0,l=this;step=function(r,p){var q=[],o=r.children(l.options.itemNodeName);o.each(function(){var s=e(this),u=e.extend({},s.data()),t=s.children(l.options.listNodeName);if(t.length){u.children=step(t,p+1)}q.push(u)});return q};m=step(l.el.find(l.options.listNodeName).first(),n);return m},serialise:function(){return this.serialize()},reset:function(){this.mouse={offsetX:0,offsetY:0,startX:0,startY:0,lastX:0,lastY:0,nowX:0,nowY:0,distX:0,distY:0,dirAx:0,dirX:0,dirY:0,lastDirX:0,lastDirY:0,distAxX:0,distAxY:0};this.moving=false;this.dragEl=null;this.dragRootEl=null;this.dragDepth=0;this.hasNewRoot=false;this.pointEl=null},expandItem:function(l){l.removeClass(this.options.collapsedClass);l.children('[data-action="expand"]').hide();l.children('[data-action="collapse"]').show();l.children(this.options.listNodeName).show()},collapseItem:function(m){var l=m.children(this.options.listNodeName);if(l.length){m.addClass(this.options.collapsedClass);m.children('[data-action="collapse"]').hide();m.children('[data-action="expand"]').show();m.children(this.options.listNodeName).hide()}},expandAll:function(){var l=this;l.el.find(l.options.itemNodeName).each(function(){l.expandItem(e(this))})},collapseAll:function(){var l=this;l.el.find(l.options.itemNodeName).each(function(){l.collapseItem(e(this))})},setParent:function(l){if(l.children(this.options.listNodeName).length){l.prepend(e(this.options.expandBtnHTML));l.prepend(e(this.options.collapseBtnHTML))}l.children('[data-action="expand"]').hide()},unsetParent:function(l){l.removeClass(this.options.collapsedClass);l.children("[data-action]").remove();l.children(this.options.listNodeName).remove()},dragStart:function(q){var m=this.mouse,p=e(q.target).closest("."+this.options.handleClass),o=p.closest(this.options.itemNodeName);console.log(p);this.placeEl.css("height",o.height());m.offsetX=q.offsetX!==c?q.offsetX:q.pageX-p.offset().left;m.offsetY=q.offsetY!==c?q.offsetY:q.pageY-p.offset().top;m.startX=m.lastX=q.pageX;m.startY=m.lastY=q.pageY;this.dragRootEl=this.el;this.dragEl=e(h.createElement(this.options.listNodeName)).addClass(this.options.listClass+" "+this.options.dragClass);this.dragEl.css("width",o.width());o.after(this.placeEl);o[0].parentNode.removeChild(o[0]);o.appendTo(this.dragEl);e(h.body).append(this.dragEl);this.dragEl.css({left:q.pageX-m.offsetX,top:q.pageY-m.offsetY});var n,r,l=this.dragEl.find(this.options.itemNodeName);for(n=0;nthis.dragDepth){this.dragDepth=r}}},dragStop:function(m){var l=this.dragEl.children(this.options.itemNodeName).first();l[0].parentNode.removeChild(l[0]);this.placeEl.replaceWith(l);this.dragEl.remove();this.el.trigger("change");if(this.hasNewRoot){this.dragRootEl.trigger("change")}this.reset()},dragMove:function(s){var t,x,n,q,p,m=this.options,u=this.mouse;this.dragEl.css({left:s.pageX-u.offsetX,top:s.pageY-u.offsetY});u.lastX=u.nowX;u.lastY=u.nowY;u.nowX=s.pageX;u.nowY=s.pageY;u.distX=u.nowX-u.lastX;u.distY=u.nowY-u.lastY;u.lastDirX=u.dirX;u.lastDirY=u.dirY;u.dirX=u.distX===0?0:u.distX>0?1:-1;u.dirY=u.distY===0?0:u.distY>0?1:-1;var l=Math.abs(u.distX)>Math.abs(u.distY)?1:0;if(!u.moving){u.dirAx=l;u.moving=true;return}if(u.dirAx!==l){u.distAxX=0;u.distAxY=0}else{u.distAxX+=Math.abs(u.distX);if(u.dirX!==0&&u.dirX!==u.lastDirX){u.distAxX=0}u.distAxY+=Math.abs(u.distY);if(u.dirY!==0&&u.dirY!==u.lastDirY){u.distAxY=0}}u.dirAx=l;if(u.dirAx&&u.distAxX>=m.threshold){u.distAxX=0;n=this.placeEl.prev(m.itemNodeName);if(u.distX>0&&n.length&&!n.hasClass(m.collapsedClass)){t=n.find(m.listNodeName).last();p=this.placeEl.parents(m.listNodeName).length;if(p+this.dragDepth<=m.maxDepth){if(!t.length){t=e("<"+m.listNodeName+"/>").addClass(m.listClass);t.append(this.placeEl);n.append(t);this.setParent(n)}else{t=n.children(m.listNodeName).last();t.append(this.placeEl)}}}if(u.distX<0){q=this.placeEl.next(m.itemNodeName);if(!q.length){x=this.placeEl.parent();this.placeEl.closest(m.itemNodeName).after(this.placeEl);if(!x.children().length){this.unsetParent(x.parent())}}}}var o=false;if(!b){this.dragEl[0].style.visibility="hidden"}this.pointEl=e(h.elementFromPoint(s.pageX-h.body.scrollLeft,s.pageY-(g.pageYOffset||h.documentElement.scrollTop)));if(!b){this.dragEl[0].style.visibility="visible"}if(this.pointEl.hasClass(m.handleClass)){this.pointEl=this.pointEl.parent(m.itemNodeName)}if(this.pointEl.hasClass(m.emptyClass)){o=true}else{if(!this.pointEl.length||!this.pointEl.hasClass(m.itemClass)){return}}var r=this.pointEl.closest("."+m.rootClass),w=this.dragRootEl.data("nestable-id")!==r.data("nestable-id");if(!u.dirAx||w||o){if(w&&m.group!==r.data("nestable-group")){return}p=this.dragDepth-1+this.pointEl.parents(m.listNodeName).length;if(p>m.maxDepth){return}var v=s.pageY<(this.pointEl.offset().top+this.pointEl.height()/2);x=this.placeEl.parent();if(o){t=e(h.createElement(m.listNodeName)).addClass(m.listClass);t.append(this.placeEl);this.pointEl.replaceWith(t)}else{if(v){this.pointEl.before(this.placeEl)}else{this.pointEl.after(this.placeEl)}}if(!x.children().length){this.unsetParent(x.parent())}if(!this.dragRootEl.find(m.itemNodeName).length){this.dragRootEl.append('
')}if(w){this.dragRootEl=r;this.hasNewRoot=this.el[0]!==this.dragRootEl[0]}}}};e.fn.nestable=function(n){var l=this,m=this;l.each(function(){var o=e(this).data("nestable");if(!o){e(this).data("nestable",new i(this,n));e(this).data("nestable-id",new Date().getTime())}else{if(typeof n==="string"&&typeof o[n]==="function"){m=o[n]()}}});return m||l}})(window.jQuery||window.Zepto,window,document);
--------------------------------------------------------------------------------
/assets/js/jquery.slimscroll.min.js:
--------------------------------------------------------------------------------
1 | /*! Copyright (c) 2011 Piotr Rochala (http://rocha.la)
2 | * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
3 | * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
4 | *
5 | * Version: 1.2.0
6 | *
7 | */
8 | (function(a){jQuery.fn.extend({slimScroll:function(b){var c={width:"auto",height:"250px",size:"7px",color:"#000",position:"right",distance:"1px",start:"top",opacity:0.4,alwaysVisible:false,disableFadeOut:false,railVisible:false,railColor:"#333",railOpacity:0.2,railDraggable:true,railClass:"slimScrollRail",barClass:"slimScrollBar",wrapperClass:"slimScrollDiv",allowPageScroll:false,wheelStep:20,touchScrollStep:200,borderRadius:"7px",railBorderRadius:"7px"};var d=a.extend(c,b);this.each(function(){var w,r,k,p,z,s,o,j,l="
",t=30,q=false;var A=a(this);if(A.parent().hasClass(d.wrapperClass)){var h=A.scrollTop();u=A.parent().find("."+d.barClass);e=A.parent().find("."+d.railClass);B();if(a.isPlainObject(b)){if("height" in b&&b.height=="auto"){A.parent().css("height","auto");A.css("height","auto");var n=A.parent().parent().height();A.parent().css("height",n);A.css("height",n)}if("scrollTo" in b){h=parseInt(d.scrollTo)}else{if("scrollBy" in b){h+=parseInt(d.scrollBy)}else{if("destroy" in b){u.remove();e.remove();A.unwrap();return}}}v(h,false,true)}return}d.height=(d.height=="auto")?A.parent().height():d.height;var i=a(l).addClass(d.wrapperClass).css({position:"relative",overflow:"hidden",width:d.width,height:d.height});A.css({overflow:"hidden",width:d.width,height:d.height});var e=a(l).addClass(d.railClass).css({width:d.size,height:"100%",position:"absolute",top:0,display:(d.alwaysVisible&&d.railVisible)?"block":"none","border-radius":d.railBorderRadius,background:d.railColor,opacity:d.railOpacity,zIndex:90});var u=a(l).addClass(d.barClass).css({background:d.color,width:d.size,position:"absolute",top:0,opacity:d.opacity,display:d.alwaysVisible?"block":"none","border-radius":d.borderRadius,BorderRadius:d.borderRadius,MozBorderRadius:d.borderRadius,WebkitBorderRadius:d.borderRadius,zIndex:99});var f=(d.position=="right")?{right:d.distance}:{left:d.distance};e.css(f);u.css(f);A.wrap(i);A.parent().append(u);A.parent().append(e);if(d.railDraggable&&a.ui&&typeof(a.ui.draggable)=="function"){u.draggable({axis:"y",containment:"parent",start:function(){k=true},stop:function(){k=false;m()},drag:function(C){v(0,a(this).position().top,false)}})}e.hover(function(){g()},function(){m()});u.hover(function(){r=true},function(){r=false});A.hover(function(){w=true;g();m()},function(){w=false;m()});A.bind("touchstart",function(D,C){if(D.originalEvent.touches.length){z=D.originalEvent.touches[0].pageY}});A.bind("touchmove",function(D){D.originalEvent.preventDefault();if(D.originalEvent.touches.length){var C=(z-D.originalEvent.touches[0].pageY)/d.touchScrollStep;v(C,true)}});if(d.start==="bottom"){u.css({top:A.outerHeight()-u.outerHeight()});v(0,true)}else{if(d.start!=="top"){v(a(d.start).position().top,null,true);if(!d.alwaysVisible){u.hide()}}}x();B();function y(D){if(!w){return}var D=D||window.event;var E=0;if(D.wheelDelta){E=-D.wheelDelta/120}if(D.detail){E=D.detail/3}var C=D.target||D.srcTarget||D.srcElement;if(a(C).closest("."+d.wrapperClass).is(A.parent())){v(E,true)}if(D.preventDefault&&!q){D.preventDefault()}if(!q){D.returnValue=false}}function v(H,E,C){var G=H;var F=A.outerHeight()-u.outerHeight();if(E){G=parseInt(u.css("top"))+H*parseInt(d.wheelStep)/100*u.outerHeight();G=Math.min(Math.max(G,0),F);G=(H>0)?Math.ceil(G):Math.floor(G);u.css({top:G+"px"})}o=parseInt(u.css("top"))/(A.outerHeight()-u.outerHeight());G=o*(A[0].scrollHeight-A.outerHeight());if(C){G=H;var D=G/A[0].scrollHeight*A.outerHeight();D=Math.min(Math.max(D,0),F);u.css({top:D+"px"})}A.scrollTop(G);A.trigger("slimscrolling",~~G);g();m()}function x(){if(window.addEventListener){this.addEventListener("DOMMouseScroll",y,false);this.addEventListener("mousewheel",y,false)}else{document.attachEvent("onmousewheel",y)}}function B(){s=Math.max((A.outerHeight()/A[0].scrollHeight)*A.outerHeight(),t);u.css({height:s+"px"});var C=s==A.outerHeight()?"none":"block";u.css({display:C})}function g(){B();clearTimeout(p);if(o==~~o){q=d.allowPageScroll;if(j!=o){var C=(~~o==0)?"top":"bottom";A.trigger("slimscroll",C)}}else{q=false}j=o;if(s>=A.outerHeight()){q=true;return}u.stop(true,true).fadeIn("fast");if(d.railVisible){e.stop(true,true).fadeIn("fast")}}function m(){if(!d.alwaysVisible){p=setTimeout(function(){if(!(d.disableFadeOut&&w)&&!r&&!k){u.fadeOut("slow");e.fadeOut("slow")}},1000)}}});return this}});jQuery.fn.extend({slimscroll:jQuery.fn.slimScroll})})(jQuery);
--------------------------------------------------------------------------------
/assets/js/jquery.ui.touch-punch.min.js:
--------------------------------------------------------------------------------
1 | /*
2 | * jQuery UI Touch Punch 0.2.2
3 | *
4 | * Copyright 2011, Dave Furfero
5 | * Dual licensed under the MIT or GPL Version 2 licenses.
6 | *
7 | * Depends:
8 | * jquery.ui.widget.js
9 | * jquery.ui.mouse.js
10 | */
11 | (function(b){b.support.touch="ontouchend" in document;if(!b.support.touch){return;}var c=b.ui.mouse.prototype,e=c._mouseInit,a;function d(g,h){if(g.originalEvent.touches.length>1){return;}g.preventDefault();var i=g.originalEvent.changedTouches[0],f=document.createEvent("MouseEvents");f.initMouseEvent(h,true,true,window,1,i.screenX,i.screenY,i.clientX,i.clientY,false,false,false,false,0,null);g.target.dispatchEvent(f);}c._touchStart=function(g){var f=this;if(a||!f._mouseCapture(g.originalEvent.changedTouches[0])){return;}a=true;f._touchMoved=false;d(g,"mouseover");d(g,"mousemove");d(g,"mousedown");};c._touchMove=function(f){if(!a){return;}this._touchMoved=true;d(f,"mousemove");};c._touchEnd=function(f){if(!a){return;}d(f,"mouseup");d(f,"mouseout");if(!this._touchMoved){d(f,"click");}a=false;};c._mouseInit=function(){var f=this;f.element.bind("touchstart",b.proxy(f,"_touchStart")).bind("touchmove",b.proxy(f,"_touchMove")).bind("touchend",b.proxy(f,"_touchEnd"));e.call(f);};})(jQuery);
--------------------------------------------------------------------------------
/assets/js/respond.min.js:
--------------------------------------------------------------------------------
1 | /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */
2 | /*! NOTE: If you're already including a window.matchMedia polyfill via Modernizr or otherwise, you don't need this part */
3 | window.matchMedia=window.matchMedia||function(a){"use strict";var c,d=a.documentElement,e=d.firstElementChild||d.firstChild,f=a.createElement("body"),g=a.createElement("div");return g.id="mq-test-1",g.style.cssText="position:absolute;top:-100em",f.style.background="none",f.appendChild(g),function(a){return g.innerHTML='',d.insertBefore(f,e),c=42===g.offsetWidth,d.removeChild(f),{matches:c,media:a}}}(document);
4 |
5 | /*! Respond.js v1.3.0: min/max-width media query polyfill. (c) Scott Jehl. MIT/GPLv2 Lic. j.mp/respondjs */
6 | (function(a){"use strict";function x(){u(!0)}var b={};if(a.respond=b,b.update=function(){},b.mediaQueriesSupported=a.matchMedia&&a.matchMedia("only all").matches,!b.mediaQueriesSupported){var q,r,t,c=a.document,d=c.documentElement,e=[],f=[],g=[],h={},i=30,j=c.getElementsByTagName("head")[0]||d,k=c.getElementsByTagName("base")[0],l=j.getElementsByTagName("link"),m=[],n=function(){for(var b=0;l.length>b;b++){var c=l[b],d=c.href,e=c.media,f=c.rel&&"stylesheet"===c.rel.toLowerCase();d&&f&&!h[d]&&(c.styleSheet&&c.styleSheet.rawCssText?(p(c.styleSheet.rawCssText,d,e),h[d]=!0):(!/^([a-zA-Z:]*\/\/)/.test(d)&&!k||d.replace(RegExp.$1,"").split("/")[0]===a.location.host)&&m.push({href:d,media:e}))}o()},o=function(){if(m.length){var b=m.shift();v(b.href,function(c){p(c,b.href,b.media),h[b.href]=!0,a.setTimeout(function(){o()},0)})}},p=function(a,b,c){var d=a.match(/@media[^\{]+\{([^\{\}]*\{[^\}\{]*\})+/gi),g=d&&d.length||0;b=b.substring(0,b.lastIndexOf("/"));var h=function(a){return a.replace(/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,"$1"+b+"$2$3")},i=!g&&c;b.length&&(b+="/"),i&&(g=1);for(var j=0;g>j;j++){var k,l,m,n;i?(k=c,f.push(h(a))):(k=d[j].match(/@media *([^\{]+)\{([\S\s]+?)$/)&&RegExp.$1,f.push(RegExp.$2&&h(RegExp.$2))),m=k.split(","),n=m.length;for(var o=0;n>o;o++)l=m[o],e.push({media:l.split("(")[0].match(/(only\s+)?([a-zA-Z]+)\s?/)&&RegExp.$2||"all",rules:f.length-1,hasquery:l.indexOf("(")>-1,minw:l.match(/\(\s*min\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||""),maxw:l.match(/\(\s*max\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||"")})}u()},s=function(){var a,b=c.createElement("div"),e=c.body,f=!1;return b.style.cssText="position:absolute;font-size:1em;width:1em",e||(e=f=c.createElement("body"),e.style.background="none"),e.appendChild(b),d.insertBefore(e,d.firstChild),a=b.offsetWidth,f?d.removeChild(e):e.removeChild(b),a=t=parseFloat(a)},u=function(b){var h="clientWidth",k=d[h],m="CSS1Compat"===c.compatMode&&k||c.body[h]||k,n={},o=l[l.length-1],p=(new Date).getTime();if(b&&q&&i>p-q)return a.clearTimeout(r),r=a.setTimeout(u,i),void 0;q=p;for(var v in e)if(e.hasOwnProperty(v)){var w=e[v],x=w.minw,y=w.maxw,z=null===x,A=null===y,B="em";x&&(x=parseFloat(x)*(x.indexOf(B)>-1?t||s():1)),y&&(y=parseFloat(y)*(y.indexOf(B)>-1?t||s():1)),w.hasquery&&(z&&A||!(z||m>=x)||!(A||y>=m))||(n[w.media]||(n[w.media]=[]),n[w.media].push(f[w.rules]))}for(var C in g)g.hasOwnProperty(C)&&g[C]&&g[C].parentNode===j&&j.removeChild(g[C]);for(var D in n)if(n.hasOwnProperty(D)){var E=c.createElement("style"),F=n[D].join("\n");E.type="text/css",E.media=D,j.insertBefore(E,o.nextSibling),E.styleSheet?E.styleSheet.cssText=F:E.appendChild(c.createTextNode(F)),g.push(E)}},v=function(a,b){var c=w();c&&(c.open("GET",a,!0),c.onreadystatechange=function(){4!==c.readyState||200!==c.status&&304!==c.status||b(c.responseText)},4!==c.readyState&&c.send(null))},w=function(){var b=!1;try{b=new a.XMLHttpRequest}catch(c){b=new a.ActiveXObject("Microsoft.XMLHTTP")}return function(){return b}}();n(),b.update=n,a.addEventListener?a.addEventListener("resize",x,!1):a.attachEvent&&a.attachEvent("onresize",x)}})(this);
7 |
--------------------------------------------------------------------------------
/assets/js/typeahead-bs2.min.js:
--------------------------------------------------------------------------------
1 | /* =============================================================
2 | * bootstrap-typeahead.js v2.3.2
3 | * http://twitter.github.com/bootstrap/javascript.html#typeahead
4 | * =============================================================
5 | * Copyright 2012 Twitter, Inc.
6 | *
7 | * Licensed under the Apache License, Version 2.0 (the "License");
8 | * you may not use this file except in compliance with the License.
9 | * You may obtain a copy of the License at
10 | *
11 | * http://www.apache.org/licenses/LICENSE-2.0
12 | *
13 | * Unless required by applicable law or agreed to in writing, software
14 | * distributed under the License is distributed on an "AS IS" BASIS,
15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 | * See the License for the specific language governing permissions and
17 | * limitations under the License.
18 | * ============================================================ */
19 |
20 |
21 | !function($){
22 |
23 | "use strict"; // jshint ;_;
24 |
25 |
26 | /* TYPEAHEAD PUBLIC CLASS DEFINITION
27 | * ================================= */
28 |
29 | var Typeahead = function (element, options) {
30 | this.$element = $(element)
31 | this.options = $.extend({}, $.fn.typeahead.defaults, options)
32 | this.matcher = this.options.matcher || this.matcher
33 | this.sorter = this.options.sorter || this.sorter
34 | this.highlighter = this.options.highlighter || this.highlighter
35 | this.updater = this.options.updater || this.updater
36 | this.source = this.options.source
37 | this.$menu = $(this.options.menu)
38 | this.shown = false
39 | this.listen()
40 | }
41 |
42 | Typeahead.prototype = {
43 |
44 | constructor: Typeahead
45 |
46 | , select: function () {
47 | var val = this.$menu.find('.active').attr('data-value')
48 | this.$element
49 | .val(this.updater(val))
50 | .change()
51 | return this.hide()
52 | }
53 |
54 | , updater: function (item) {
55 | return item
56 | }
57 |
58 | , show: function () {
59 | var pos = $.extend({}, this.$element.position(), {
60 | height: this.$element[0].offsetHeight
61 | })
62 |
63 | this.$menu
64 | .insertAfter(this.$element)
65 | .css({
66 | top: pos.top + pos.height
67 | , left: pos.left
68 | })
69 | .show()
70 |
71 | this.shown = true
72 | return this
73 | }
74 |
75 | , hide: function () {
76 | this.$menu.hide()
77 | this.shown = false
78 | return this
79 | }
80 |
81 | , lookup: function (event) {
82 | var items
83 |
84 | this.query = this.$element.val()
85 |
86 | if (!this.query || this.query.length < this.options.minLength) {
87 | return this.shown ? this.hide() : this
88 | }
89 |
90 | items = $.isFunction(this.source) ? this.source(this.query, $.proxy(this.process, this)) : this.source
91 |
92 | return items ? this.process(items) : this
93 | }
94 |
95 | , process: function (items) {
96 | var that = this
97 |
98 | items = $.grep(items, function (item) {
99 | return that.matcher(item)
100 | })
101 |
102 | items = this.sorter(items)
103 |
104 | if (!items.length) {
105 | return this.shown ? this.hide() : this
106 | }
107 |
108 | return this.render(items.slice(0, this.options.items)).show()
109 | }
110 |
111 | , matcher: function (item) {
112 | return ~item.toLowerCase().indexOf(this.query.toLowerCase())
113 | }
114 |
115 | , sorter: function (items) {
116 | var beginswith = []
117 | , caseSensitive = []
118 | , caseInsensitive = []
119 | , item
120 |
121 | while (item = items.shift()) {
122 | if (!item.toLowerCase().indexOf(this.query.toLowerCase())) beginswith.push(item)
123 | else if (~item.indexOf(this.query)) caseSensitive.push(item)
124 | else caseInsensitive.push(item)
125 | }
126 |
127 | return beginswith.concat(caseSensitive, caseInsensitive)
128 | }
129 |
130 | , highlighter: function (item) {
131 | var query = this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, '\\$&')
132 | return item.replace(new RegExp('(' + query + ')', 'ig'), function ($1, match) {
133 | return '' + match + ' '
134 | })
135 | }
136 |
137 | , render: function (items) {
138 | var that = this
139 |
140 | items = $(items).map(function (i, item) {
141 | i = $(that.options.item).attr('data-value', item)
142 | i.find('a').html(that.highlighter(item))
143 | return i[0]
144 | })
145 |
146 | items.first().addClass('active')
147 | this.$menu.html(items)
148 | return this
149 | }
150 |
151 | , next: function (event) {
152 | var active = this.$menu.find('.active').removeClass('active')
153 | , next = active.next()
154 |
155 | if (!next.length) {
156 | next = $(this.$menu.find('li')[0])
157 | }
158 |
159 | next.addClass('active')
160 | }
161 |
162 | , prev: function (event) {
163 | var active = this.$menu.find('.active').removeClass('active')
164 | , prev = active.prev()
165 |
166 | if (!prev.length) {
167 | prev = this.$menu.find('li').last()
168 | }
169 |
170 | prev.addClass('active')
171 | }
172 |
173 | , listen: function () {
174 | this.$element
175 | .on('focus', $.proxy(this.focus, this))
176 | .on('blur', $.proxy(this.blur, this))
177 | .on('keypress', $.proxy(this.keypress, this))
178 | .on('keyup', $.proxy(this.keyup, this))
179 |
180 | if (this.eventSupported('keydown')) {
181 | this.$element.on('keydown', $.proxy(this.keydown, this))
182 | }
183 |
184 | this.$menu
185 | .on('click', $.proxy(this.click, this))
186 | .on('mouseenter', 'li', $.proxy(this.mouseenter, this))
187 | .on('mouseleave', 'li', $.proxy(this.mouseleave, this))
188 | }
189 |
190 | , eventSupported: function(eventName) {
191 | var isSupported = eventName in this.$element
192 | if (!isSupported) {
193 | this.$element.setAttribute(eventName, 'return;')
194 | isSupported = typeof this.$element[eventName] === 'function'
195 | }
196 | return isSupported
197 | }
198 |
199 | , move: function (e) {
200 | if (!this.shown) return
201 |
202 | switch(e.keyCode) {
203 | case 9: // tab
204 | case 13: // enter
205 | case 27: // escape
206 | e.preventDefault()
207 | break
208 |
209 | case 38: // up arrow
210 | e.preventDefault()
211 | this.prev()
212 | break
213 |
214 | case 40: // down arrow
215 | e.preventDefault()
216 | this.next()
217 | break
218 | }
219 |
220 | e.stopPropagation()
221 | }
222 |
223 | , keydown: function (e) {
224 | this.suppressKeyPressRepeat = ~$.inArray(e.keyCode, [40,38,9,13,27])
225 | this.move(e)
226 | }
227 |
228 | , keypress: function (e) {
229 | if (this.suppressKeyPressRepeat) return
230 | this.move(e)
231 | }
232 |
233 | , keyup: function (e) {
234 | switch(e.keyCode) {
235 | case 40: // down arrow
236 | case 38: // up arrow
237 | case 16: // shift
238 | case 17: // ctrl
239 | case 18: // alt
240 | break
241 |
242 | case 9: // tab
243 | case 13: // enter
244 | if (!this.shown) return
245 | this.select()
246 | break
247 |
248 | case 27: // escape
249 | if (!this.shown) return
250 | this.hide()
251 | break
252 |
253 | default:
254 | this.lookup()
255 | }
256 |
257 | e.stopPropagation()
258 | e.preventDefault()
259 | }
260 |
261 | , focus: function (e) {
262 | this.focused = true
263 | }
264 |
265 | , blur: function (e) {
266 | this.focused = false
267 | if (!this.mousedover && this.shown) this.hide()
268 | }
269 |
270 | , click: function (e) {
271 | e.stopPropagation()
272 | e.preventDefault()
273 | this.select()
274 | this.$element.focus()
275 | }
276 |
277 | , mouseenter: function (e) {
278 | this.mousedover = true
279 | this.$menu.find('.active').removeClass('active')
280 | $(e.currentTarget).addClass('active')
281 | }
282 |
283 | , mouseleave: function (e) {
284 | this.mousedover = false
285 | if (!this.focused && this.shown) this.hide()
286 | }
287 |
288 | }
289 |
290 |
291 | /* TYPEAHEAD PLUGIN DEFINITION
292 | * =========================== */
293 |
294 | var old = $.fn.typeahead
295 |
296 | $.fn.typeahead = function (option) {
297 | return this.each(function () {
298 | var $this = $(this)
299 | , data = $this.data('typeahead')
300 | , options = typeof option == 'object' && option
301 | if (!data) $this.data('typeahead', (data = new Typeahead(this, options)))
302 | if (typeof option == 'string') data[option]()
303 | })
304 | }
305 |
306 | $.fn.typeahead.defaults = {
307 | source: []
308 | , items: 8
309 | , menu: ''
310 | , item: ' '
311 | , minLength: 1
312 | }
313 |
314 | $.fn.typeahead.Constructor = Typeahead
315 |
316 |
317 | /* TYPEAHEAD NO CONFLICT
318 | * =================== */
319 |
320 | $.fn.typeahead.noConflict = function () {
321 | $.fn.typeahead = old
322 | return this
323 | }
324 |
325 |
326 | /* TYPEAHEAD DATA-API
327 | * ================== */
328 |
329 | $(document).on('focus.typeahead.data-api', '[data-provide="typeahead"]', function (e) {
330 | var $this = $(this)
331 | if ($this.data('typeahead')) return
332 | $this.typeahead($this.data())
333 | })
334 |
335 | }(window.jQuery);
--------------------------------------------------------------------------------
/assets/js/x-editable/ace-editable.min.js:
--------------------------------------------------------------------------------
1 | (function(b){var a=function(c){this.init("image",c,a.defaults);if("on_error" in c.image){this.on_error=c.image.on_error;delete c.image.on_error}if("on_success" in c.image){this.on_success=c.image.on_success;delete c.image.on_success}if("max_size" in c.image){this.max_size=c.image.max_size;delete c.image.max_size}this.initImage(c,a.defaults)};b.fn.editableutils.inherit(a,b.fn.editabletypes.abstractinput);b.extend(a.prototype,{initImage:function(c,d){this.options.image=b.extend({},d.image,c.image);this.name=this.options.image.name||"editable-image-input"},render:function(){var c=this;this.$input=this.$tpl.find("input[type=hidden]:eq(0)");this.$file=this.$tpl.find("input[type=file]:eq(0)");this.$file.attr({name:this.name});this.$input.attr({name:this.name+"-hidden"});this.options.image.before_change=this.options.image.before_change||function(f,g){var d=f[0];if(typeof d==="string"){if(!(/\.(jpe?g|png|gif)$/i).test(d)){if(c.on_error){c.on_error(1)}return false}}else{var e=b.trim(d.type);if((e.length>0&&!(/^image\/(jpe?g|png|gif)$/i).test(e))||(e.length==0&&!(/\.(jpe?g|png|gif)$/i).test(d.name))){if(c.on_error){c.on_error(1)}return false}if(c.max_size&&d.size>c.max_size){if(c.on_error){c.on_error(2)}return false}}if(c.on_success){c.on_success()}return true};this.options.image.before_remove=this.options.image.before_remove||function(){c.$input.val(null);return true};this.$file.ace_file_input(this.options.image).on("change",function(){var d=(c.$file.val()||c.$file.data("ace_input_files"))?Math.random()+""+(new Date()).getTime():null;c.$input.val(d)}).closest(".ace-file-input").css({width:"150px"}).closest(".editable-input").addClass("editable-image")}});a.defaults=b.extend({},b.fn.editabletypes.abstractinput.defaults,{tpl:' ',inputclass:"",image:{style:"well",btn_choose:"Change Image",btn_change:null,no_icon:"icon-picture",thumbnail:"large"}});b.fn.editabletypes.image=a}(window.jQuery));(function(a){var b=function(c){this.init("wysiwyg",c,b.defaults);this.options.wysiwyg=a.extend({},b.defaults.wysiwyg,c.wysiwyg)};a.fn.editableutils.inherit(b,a.fn.editabletypes.abstractinput);a.extend(b.prototype,{render:function(){this.$editor=this.$input.nextAll(".wysiwyg-editor:eq(0)");this.$tpl.parent().find(".wysiwyg-editor").show().ace_wysiwyg({toolbar:["bold","italic","strikethrough","underline",null,"foreColor",null,"insertImage"]}).prev().addClass("wysiwyg-style2").closest(".editable-input").addClass("editable-wysiwyg").closest(".editable-container").css({display:"block"});if(this.options.wysiwyg&&this.options.wysiwyg.css){this.$tpl.closest(".editable-wysiwyg").css(this.options.wysiwyg.css)}},value2html:function(d,c){a(c).html(d);return false},html2value:function(c){return c},value2input:function(c){this.$editor.html(c)},input2value:function(){return this.$editor.html()},activate:function(){}});b.defaults=a.extend({},a.fn.editabletypes.abstractinput.defaults,{tpl:'
',inputclass:"editable-wysiwyg",wysiwyg:{}});a.fn.editabletypes.wysiwyg=b}(window.jQuery));(function(b){var a=function(c){this.init("spinner",c,a.defaults);this.initSpinner(c,a.defaults)};b.fn.editableutils.inherit(a,b.fn.editabletypes.abstractinput);b.extend(a.prototype,{initSpinner:function(c,d){this.options.spinner=b.extend({},d.spinner,c.spinner)},render:function(){},activate:function(){if(this.$input.is(":visible")){this.$input.focus();b.fn.editableutils.setCursorPosition(this.$input.get(0),this.$input.val().length);var d=parseInt(this.$input.val());var c=b.extend({value:d},this.options.spinner);this.$input.ace_spinner(c)}},autosubmit:function(){this.$input.keydown(function(c){if(c.which===13){b(this).closest("form").submit()}})}});a.defaults=b.extend({},b.fn.editabletypes.abstractinput.defaults,{tpl:' ',inputclass:"",spinner:{min:0,max:100,step:1,icon_up:"icon-plus",icon_down:"icon-minus",btn_up_class:"btn-success",btn_down_class:"btn-danger"}});b.fn.editabletypes.spinner=a}(window.jQuery));(function(b){var a=function(c){this.init("slider",c,a.defaults);this.initSlider(c,a.defaults)};b.fn.editableutils.inherit(a,b.fn.editabletypes.abstractinput);b.extend(a.prototype,{initSlider:function(c,d){this.options.slider=b.extend({},d.slider,c.slider)},render:function(){},activate:function(){if(this.$input.is(":visible")){this.$input.focus();b.fn.editableutils.setCursorPosition(this.$input.get(0),this.$input.val().length);var c=this;var f=parseInt(this.$input.val());var e=this.options.slider.width||200;var d=b.extend(this.options.slider,{value:f,slide:function(g,h){var i=parseInt(h.value);c.$input.val(i);if(h.handle.firstChild==null){b(h.handle).append("")}b(h.handle.firstChild).show().children().eq(1).text(i)}});this.$input.parent().addClass("editable-slider").css("width",e+"px").slider(d)}},value2html:function(d,c){},autosubmit:function(){this.$input.keydown(function(c){if(c.which===13){b(this).closest("form").submit()}})}});a.defaults=b.extend({},b.fn.editabletypes.abstractinput.defaults,{tpl:' ',inputclass:"",slider:{min:1,max:100,step:1,range:"min"}});b.fn.editabletypes.slider=a}(window.jQuery));
--------------------------------------------------------------------------------
/common.php:
--------------------------------------------------------------------------------
1 | ';
25 | echo "