=a.page.maxh||g==a.page.maxw&&b>=a.page.maxw)&&a.checkContentSize();var p=1;a.cancelAnimationFrame=!1;a.timer=1;a.onscrollstart&&!a.scrollrunning&&a.onscrollstart.call(a,{type:"scrollstart",
+current:{x:g,y:h},request:{x:b,y:d},end:{x:a.newscrollx,y:a.newscrolly},speed:k});e();(h==a.page.maxh&&d>=h||g==a.page.maxw&&b>=g)&&a.checkContentSize();a.noticeCursor()}},this.cancelScroll=function(){a.timer&&v(a.timer);a.timer=0;a.bzscroll=!1;a.scrollrunning=!1;return a}):(this.doScrollLeft=function(b,d){var f=a.getScrollTop();a.doScrollPos(b,f,d)},this.doScrollTop=function(b,d){var f=a.getScrollLeft();a.doScrollPos(f,b,d)},this.doScrollPos=function(b,d,f){var e=b>a.page.maxw?a.page.maxw:b;0>e&&
+(e=0);var h=d>a.page.maxh?a.page.maxh:d;0>h&&(h=0);a.synched("scroll",function(){a.setScrollTop(h);a.setScrollLeft(e)})},this.cancelScroll=function(){});this.doScrollBy=function(b,d){var f=0,f=d?Math.floor((a.scroll.y-b)*a.scrollratio.y):(a.timer?a.newscrolly:a.getScrollTop(!0))-b;if(a.bouncescroll){var e=Math.round(a.view.h/2);f<-e?f=-e:f>a.page.maxh+e&&(f=a.page.maxh+e)}a.cursorfreezed=!1;py=a.getScrollTop(!0);if(0>f&&0>=py)return a.noticeCursor();if(f>a.page.maxh&&py>=a.page.maxh)return a.checkContentSize(),
+a.noticeCursor();a.doScrollTop(f)};this.doScrollLeftBy=function(b,d){var f=0,f=d?Math.floor((a.scroll.x-b)*a.scrollratio.x):(a.timer?a.newscrollx:a.getScrollLeft(!0))-b;if(a.bouncescroll){var e=Math.round(a.view.w/2);f<-e?f=-e:f>a.page.maxw+e&&(f=a.page.maxw+e)}a.cursorfreezed=!1;px=a.getScrollLeft(!0);if(0>f&&0>=px||f>a.page.maxw&&px>=a.page.maxw)return a.noticeCursor();a.doScrollLeft(f)};this.doScrollTo=function(b,d){d&&Math.round(b*a.scrollratio.y);a.cursorfreezed=!1;a.doScrollTop(b)};this.checkContentSize=
+function(){var b=a.getContentSize();(b.h!=a.page.h||b.w!=a.page.w)&&a.resize(!1,b)};a.onscroll=function(b){a.rail.drag||a.cursorfreezed||a.synched("scroll",function(){a.scroll.y=Math.round(a.getScrollTop()*(1/a.scrollratio.y));a.railh&&(a.scroll.x=Math.round(a.getScrollLeft()*(1/a.scrollratio.x)));a.noticeCursor()})};a.bind(a.docscroll,"scroll",a.onscroll);this.doZoomIn=function(b){if(!a.zoomactive){a.zoomactive=!0;a.zoomrestore={style:{}};var h="position top left zIndex backgroundColor marginTop marginBottom marginLeft marginRight".split(" "),
+f=a.win[0].style,g;for(g in h){var k=h[g];a.zoomrestore.style[k]="undefined"!=typeof f[k]?f[k]:""}a.zoomrestore.style.width=a.win.css("width");a.zoomrestore.style.height=a.win.css("height");a.zoomrestore.padding={w:a.win.outerWidth()-a.win.width(),h:a.win.outerHeight()-a.win.height()};d.isios4&&(a.zoomrestore.scrollTop=e(window).scrollTop(),e(window).scrollTop(0));a.win.css({position:d.isios4?"absolute":"fixed",top:0,left:0,"z-index":x+100,margin:"0px"});h=a.win.css("backgroundColor");(""==h||/transparent|rgba\(0, 0, 0, 0\)|rgba\(0,0,0,0\)/.test(h))&&
+a.win.css("backgroundColor","#fff");a.rail.css({"z-index":x+101});a.zoom.css({"z-index":x+102});a.zoom.css("backgroundPosition","0px -18px");a.resizeZoom();a.onzoomin&&a.onzoomin.call(a);return a.cancelEvent(b)}};this.doZoomOut=function(b){if(a.zoomactive)return a.zoomactive=!1,a.win.css("margin",""),a.win.css(a.zoomrestore.style),d.isios4&&e(window).scrollTop(a.zoomrestore.scrollTop),a.rail.css({"z-index":a.zindex}),a.zoom.css({"z-index":a.zindex}),a.zoomrestore=!1,a.zoom.css("backgroundPosition",
+"0px 0px"),a.onResize(),a.onzoomout&&a.onzoomout.call(a),a.cancelEvent(b)};this.doZoom=function(b){return a.zoomactive?a.doZoomOut(b):a.doZoomIn(b)};this.resizeZoom=function(){if(a.zoomactive){var b=a.getScrollTop();a.win.css({width:e(window).width()-a.zoomrestore.padding.w+"px",height:e(window).height()-a.zoomrestore.padding.h+"px"});a.onResize();a.setScrollTop(Math.min(a.page.maxh,b))}};this.init();e.nicescroll.push(this)},H=function(e){var b=this;this.nc=e;this.steptime=this.lasttime=this.speedy=
+this.speedx=this.lasty=this.lastx=0;this.snapy=this.snapx=!1;this.demuly=this.demulx=0;this.lastscrolly=this.lastscrollx=-1;this.timer=this.chky=this.chkx=0;this.time=function(){return+new Date};this.reset=function(e,g){b.stop();var l=b.time();b.steptime=0;b.lasttime=l;b.speedx=0;b.speedy=0;b.lastx=e;b.lasty=g;b.lastscrollx=-1;b.lastscrolly=-1};this.update=function(e,g){var l=b.time();b.steptime=l-b.lasttime;b.lasttime=l;var l=g-b.lasty,q=e-b.lastx,a=b.nc.getScrollTop(),p=b.nc.getScrollLeft(),a=a+
+l,p=p+q;b.snapx=0>p||p>b.nc.page.maxw;b.snapy=0>a||a>b.nc.page.maxh;b.speedx=q;b.speedy=l;b.lastx=e;b.lasty=g};this.stop=function(){b.nc.unsynched("domomentum2d");b.timer&&clearTimeout(b.timer);b.timer=0;b.lastscrollx=-1;b.lastscrolly=-1};this.doSnapy=function(e,g){var l=!1;0>g?(g=0,l=!0):g>b.nc.page.maxh&&(g=b.nc.page.maxh,l=!0);0>e?(e=0,l=!0):e>b.nc.page.maxw&&(e=b.nc.page.maxw,l=!0);l?b.nc.doScrollPos(e,g,b.nc.opt.snapbackspeed):b.nc.triggerScrollEnd()};this.doMomentum=function(e){var g=b.time(),
+l=e?g+e:b.lasttime;e=b.nc.getScrollLeft();var q=b.nc.getScrollTop(),a=b.nc.page.maxh,p=b.nc.page.maxw;b.speedx=0=g-l;if(0>q||q>a||0>e||e>p)l=!1;e=b.speedx&&l?b.speedx:!1;if(b.speedy&&l&&b.speedy||e){var d=Math.max(16,b.steptime);50r||r>p))c=0.1;if(b.speedy&&(t=Math.floor(b.lastscrolly-b.speedy*(1-b.demulxy)),b.lastscrolly=t,0>t||t>a))c=0.1;b.demulxy=Math.min(1,b.demulxy+c);b.nc.synched("domomentum2d",function(){b.speedx&&(b.nc.getScrollLeft()!=b.chkx&&b.stop(),b.chkx=r,b.nc.setScrollLeft(r));b.speedy&&(b.nc.getScrollTop()!=b.chky&&b.stop(),b.chky=t,b.nc.setScrollTop(t));b.timer||(b.nc.hideCursor(),
+b.doSnapy(r,t))});1>b.demulxy?b.timer=setTimeout(s,d):(b.stop(),b.nc.hideCursor(),b.doSnapy(r,t))};s()}else b.doSnapy(b.nc.getScrollLeft(),b.nc.getScrollTop())}},w=e.fn.scrollTop;e.cssHooks.pageYOffset={get:function(g,b,h){return(b=e.data(g,"__nicescroll")||!1)&&b.ishwscroll?b.getScrollTop():w.call(g)},set:function(g,b){var h=e.data(g,"__nicescroll")||!1;h&&h.ishwscroll?h.setScrollTop(parseInt(b)):w.call(g,b);return this}};e.fn.scrollTop=function(g){if("undefined"==typeof g){var b=this[0]?e.data(this[0],
+"__nicescroll")||!1:!1;return b&&b.ishwscroll?b.getScrollTop():w.call(this)}return this.each(function(){var b=e.data(this,"__nicescroll")||!1;b&&b.ishwscroll?b.setScrollTop(parseInt(g)):w.call(e(this),g)})};var A=e.fn.scrollLeft;e.cssHooks.pageXOffset={get:function(g,b,h){return(b=e.data(g,"__nicescroll")||!1)&&b.ishwscroll?b.getScrollLeft():A.call(g)},set:function(g,b){var h=e.data(g,"__nicescroll")||!1;h&&h.ishwscroll?h.setScrollLeft(parseInt(b)):A.call(g,b);return this}};e.fn.scrollLeft=function(g){if("undefined"==
+typeof g){var b=this[0]?e.data(this[0],"__nicescroll")||!1:!1;return b&&b.ishwscroll?b.getScrollLeft():A.call(this)}return this.each(function(){var b=e.data(this,"__nicescroll")||!1;b&&b.ishwscroll?b.setScrollLeft(parseInt(g)):A.call(e(this),g)})};var B=function(g){var b=this;this.length=0;this.name="nicescrollarray";this.each=function(e){for(var g=0,a=0;g', 'g'), "");
+ output = $.trim(output.toLowerCase());
+ return output;
+ };
+
+ this.results = function (bool) {
+ if (typeof options.noResults === "string" && options.noResults !== "") {
+ if (bool) {
+ $(options.noResults).hide();
+ } else {
+ $(options.noResults).show();
+ }
+ }
+ return this;
+ };
+
+ this.loader = function (bool) {
+ if (typeof options.loader === "string" && options.loader !== "") {
+ (bool) ? $(options.loader).show() : $(options.loader).hide();
+ }
+ return this;
+ };
+
+ this.cache = function () {
+
+ jq_results = $(target);
+
+ if (typeof options.noResults === "string" && options.noResults !== "") {
+ jq_results = jq_results.not(options.noResults);
+ }
+
+ var t = (typeof options.selector === "string") ? jq_results.find(options.selector) : $(target).not(options.noResults);
+ cache = t.map(function () {
+ return e.strip_html(this.innerHTML);
+ });
+
+ rowcache = jq_results.map(function () {
+ return this;
+ });
+
+ /*
+ * Modified fix for sync-ing "val".
+ * Original fix https://github.com/michaellwest/quicksearch/commit/4ace4008d079298a01f97f885ba8fa956a9703d1
+ * */
+ val = val || this.val() || "";
+
+ return this.go();
+ };
+
+ this.trigger = function () {
+ this.loader(true);
+ options.onBefore();
+
+ window.clearTimeout(timeout);
+ timeout = window.setTimeout(function () {
+ e.go();
+ }, options.delay);
+
+ return this;
+ };
+
+ this.cache();
+ this.results(true);
+ this.stripe();
+ this.loader(false);
+
+ return this.each(function () {
+
+ /*
+ * Changed from .bind to .on.
+ * */
+ $(this).on(options.bind, function () {
+
+ val = $(this).val();
+ e.trigger();
+ });
+ });
+
+ };
+
+}(jQuery, this, document));
diff --git a/admin/view/javascript/shopunity/jquery.tinysort.min.js b/admin/view/javascript/shopunity/jquery.tinysort.min.js
new file mode 100755
index 0000000..586b663
--- /dev/null
+++ b/admin/view/javascript/shopunity/jquery.tinysort.min.js
@@ -0,0 +1,10 @@
+/* TinySort 1.4.29
+* Copyright (c) 2008-2012 Ron Valstar http://www.sjeiti.com/
+*
+* Dual licensed under the MIT and GPL licenses:
+* http://www.opensource.org/licenses/mit-license.php
+* http://www.gnu.org/licenses/gpl.html
+*/
+(function(c){var e=!1,f=null,j=parseFloat,g=Math.min,i=/(-?\d+\.?\d*)$/g,h=[],d=[];c.tinysort={id:"TinySort",version:"1.4.29",copyright:"Copyright (c) 2008-2012 Ron Valstar",uri:"http://tinysort.sjeiti.com/",licensed:{MIT:"http://www.opensource.org/licenses/mit-license.php",GPL:"http://www.gnu.org/licenses/gpl.html"},plugin:function(k,l){h.push(k);d.push(l)},defaults:{order:"asc",attr:f,data:f,useVal:e,place:"start",returns:e,cases:e,forceStrings:e,sortFunction:f}};c.fn.extend({tinysort:function(o,k){if(o&&typeof(o)!="string"){k=o;o=f}var p=c.extend({},c.tinysort.defaults,k),u,D=this,z=c(this).length,E={},r=!(!o||o==""),s=!(p.attr===f||p.attr==""),y=p.data!==f,l=r&&o[0]==":",m=l?D.filter(o):D,t=p.sortFunction,x=p.order=="asc"?1:-1,n=[];c.each(h,function(G,H){H.call(H,p)});if(!t){t=p.order=="rand"?function(){return Math.random()<0.5?1:-1}:function(O,M){var N=e,J=!p.cases?a(O.s):O.s,I=!p.cases?a(M.s):M.s;if(!p.forceStrings){var H=J&&J.match(i),P=I&&I.match(i);if(H&&P){var L=J.substr(0,J.length-H[0].length),K=I.substr(0,I.length-P[0].length);if(L==K){N=!e;J=j(H[0]);I=j(P[0])}}}var G=x*(JI?1:0));c.each(d,function(Q,R){G=R.call(R,N,J,I,G)});return G}}D.each(function(I,J){var K=c(J),G=r?(l?m.filter(J):K.find(o)):K,L=y?""+G.data(p.data):(s?G.attr(p.attr):(p.useVal?G.val():G.text())),H=K.parent();if(!E[H]){E[H]={s:[],n:[]}}if(G.length>0){E[H].s.push({s:L,e:K,n:I})}else{E[H].n.push({e:K,n:I})}});for(u in E){E[u].s.sort(t)}for(u in E){var A=E[u],C=[],F=z,w=[0,0],B;switch(p.place){case"first":c.each(A.s,function(G,H){F=g(F,H.n)});break;case"org":c.each(A.s,function(G,H){C.push(H.n)});break;case"end":F=A.n.length;break;default:F=0}for(B=0;B=F&&B
+ * Licensed under the Apache v2 License.
+ *
+ * @licence
+ */
+
+function require(a){return window.less[a.split("/")[1]]}function log(a,b){"development"==less.env&&"undefined"!=typeof console&&less.logLevel>=b&&console.log("less: "+a)}function extractId(a){return a.replace(/^[a-z-]+:\/+?[^\/]+/,"").replace(/^\//,"").replace(/\.[a-zA-Z]+$/,"").replace(/[^\.\w-]+/g,"-").replace(/\./g,":")}function errorConsole(a,b){var c="{line} {content}",d=a.filename||b,e=[],f=(a.type||"Syntax")+"Error: "+(a.message||"There is an error in your .less file")+" in "+d+" ",g=function(a,b,d){void 0!==a.extract[b]&&e.push(c.replace(/\{line\}/,(parseInt(a.line,10)||0)+(b-1)).replace(/\{class\}/,d).replace(/\{content\}/,a.extract[b]))};a.extract?(g(a,0,""),g(a,1,"line"),g(a,2,""),f+="on line "+a.line+", column "+(a.column+1)+":\n"+e.join("\n")):a.stack&&(f+=a.stack),log(f,logLevel.errors)}function createCSS(a,b,c){var d=b.href||"",e="less:"+(b.title||extractId(d)),f=document.getElementById(e),g=!1,h=document.createElement("style");if(h.setAttribute("type","text/css"),b.media&&h.setAttribute("media",b.media),h.id=e,h.styleSheet)try{h.styleSheet.cssText=a}catch(i){throw new Error("Couldn't reassign styleSheet.cssText.")}else h.appendChild(document.createTextNode(a)),g=null!==f&&f.childNodes.length>0&&h.childNodes.length>0&&f.firstChild.nodeValue===h.firstChild.nodeValue;var j=document.getElementsByTagName("head")[0];if(null===f||g===!1){var k=b&&b.nextSibling||null;k?k.parentNode.insertBefore(h,k):j.appendChild(h)}if(f&&g===!1&&f.parentNode.removeChild(f),c&&cache){log("saving "+d+" to cache.",logLevel.info);try{cache.setItem(d,a),cache.setItem(d+":timestamp",c)}catch(i){log("failed to save",logLevel.errors)}}}function errorHTML(a,b){var c,d,e="less-error-message:"+extractId(b||""),f='{line} {content} ',g=document.createElement("div"),h=[],i=a.filename||b,j=i.match(/([^\/]+(\?.*)?)$/)[1];g.id=e,g.className="less-error-message",d=""+(a.type||"Syntax")+"Error: "+(a.message||"There is an error in your .less file")+" "+'in '+j+" ";var k=function(a,b,c){void 0!==a.extract[b]&&h.push(f.replace(/\{line\}/,(parseInt(a.line,10)||0)+(b-1)).replace(/\{class\}/,c).replace(/\{content\}/,a.extract[b]))};a.extract?(k(a,0,""),k(a,1,"line"),k(a,2,""),d+="on line "+a.line+", column "+(a.column+1)+":
"+""):a.stack&&(d+=" "+a.stack.split("\n").slice(1).join(" ")),g.innerHTML=d,createCSS([".less-error-message ul, .less-error-message li {","list-style-type: none;","margin-right: 15px;","padding: 4px 0;","margin: 0;","}",".less-error-message label {","font-size: 12px;","margin-right: 15px;","padding: 4px 0;","color: #cc7777;","}",".less-error-message pre {","color: #dd6666;","padding: 4px 0;","margin: 0;","display: inline-block;","}",".less-error-message pre.line {","color: #ff0000;","}",".less-error-message h3 {","font-size: 20px;","font-weight: bold;","padding: 15px 0 5px 0;","margin: 0;","}",".less-error-message a {","color: #10a","}",".less-error-message .error {","color: red;","font-weight: bold;","padding-bottom: 2px;","border-bottom: 1px dashed red;","}"].join("\n"),{title:"error-message"}),g.style.cssText=["font-family: Arial, sans-serif","border: 1px solid #e00","background-color: #eee","border-radius: 5px","-webkit-border-radius: 5px","-moz-border-radius: 5px","color: #e00","padding: 15px","margin-bottom: 15px"].join(";"),"development"==less.env&&(c=setInterval(function(){document.body&&(document.getElementById(e)?document.body.replaceChild(g,document.getElementById(e)):document.body.insertBefore(g,document.body.firstChild),clearInterval(c))},10))}function error(a,b){less.errorReporting&&"html"!==less.errorReporting?"console"===less.errorReporting?errorConsole(a,b):"function"==typeof less.errorReporting&&less.errorReporting("add",a,b):errorHTML(a,b)}function removeErrorHTML(a){var b=document.getElementById("less-error-message:"+extractId(a));b&&b.parentNode.removeChild(b)}function removeErrorConsole(){}function removeError(a){less.errorReporting&&"html"!==less.errorReporting?"console"===less.errorReporting?removeErrorConsole(a):"function"==typeof less.errorReporting&&less.errorReporting("remove",a):removeErrorHTML(a)}function loadStyles(a){for(var b,c=document.getElementsByTagName("style"),d=0;d0&&(h.splice(c-1,2),c-=2)}return g.hostPart=f[1],g.directories=h,g.path=f[1]+h.join("/"),g.fileUrl=g.path+(f[4]||""),g.url=g.fileUrl+(f[5]||""),g}function pathDiff(a,b){var c,d,e,f,g=extractUrlParts(a),h=extractUrlParts(b),i="";if(g.hostPart!==h.hostPart)return"";for(d=Math.max(h.directories.length,g.directories.length),c=0;d>c&&h.directories[c]===g.directories[c];c++);for(f=h.directories.slice(c),e=g.directories.slice(c),c=0;c=200&&b.status<300?c(b.responseText,b.getResponseHeader("Last-Modified")):"function"==typeof d&&d(b.status,a)}var f=getXMLHttpRequest(),g=isFileProtocol?less.fileAsync:less.async;"function"==typeof f.overrideMimeType&&f.overrideMimeType("text/css"),log("XHR: Getting '"+a+"'",logLevel.info),f.open("GET",a,g),f.setRequestHeader("Accept",b||"text/x-less, text/css; q=0.9, */*; q=0.5"),f.send(null),isFileProtocol&&!less.fileAsync?0===f.status||f.status>=200&&f.status<300?c(f.responseText):d(f.status,a):g?f.onreadystatechange=function(){4==f.readyState&&e(f,c,d)}:e(f,c,d)}function loadFile(a,b,c,d,e){b&&b.currentDirectory&&!/^([a-z-]+:)?\//.test(a)&&(a=b.currentDirectory+a);var f=extractUrlParts(a,window.location.href),g=f.url,h={currentDirectory:f.path,filename:g};if(b?(h.entryPath=b.entryPath,h.rootpath=b.rootpath,h.rootFilename=b.rootFilename,h.relativeUrls=b.relativeUrls):(h.entryPath=f.path,h.rootpath=less.rootpath||f.path,h.rootFilename=g,h.relativeUrls=d.relativeUrls),h.relativeUrls&&(h.rootpath=d.rootpath?extractUrlParts(d.rootpath+pathDiff(f.path,h.entryPath)).path:f.path),d.useFileCache&&fileCache[g])try{var i=fileCache[g];e&&(i+="\n"+e),c(null,i,g,h,{lastModified:new Date})}catch(j){c(j,null,g)}else doXHR(g,d.mime,function(a,b){fileCache[g]=a;try{c(null,a,g,h,{lastModified:b})}catch(d){c(d,null,g)}},function(a,b){c({type:"File",message:"'"+b+"' wasn't found ("+a+")"},null,g)})}function loadStyleSheet(a,b,c,d,e){var f=new less.tree.parseEnv(less);f.mime=a.type,e&&(f.useFileCache=!0),loadFile(a.href,null,function(e,g,h,i,j){if(j){j.remaining=d;var k=cache&&cache.getItem(h),l=cache&&cache.getItem(h+":timestamp");if(!c&&l&&j.lastModified&&new Date(j.lastModified).valueOf()===new Date(l).valueOf())return createCSS(k,a),j.local=!0,b(null,null,g,a,j,h),void 0}removeError(h),g?(f.currentFileInfo=i,new less.Parser(f).parse(g,function(c,d){if(c)return b(c,null,null,a);try{b(c,d,g,a,j,h)}catch(c){b(c,null,null,a)}})):b(e,null,null,a,j,h)},f,e)}function loadStyleSheets(a,b,c){for(var d=0;dv&&(u[q]=u[q].slice(p-v),v=p)}function e(a){var b=a.charCodeAt(0);return 32===b||10===b||9===b}function f(a){var b,c;if(a instanceof Function)return a.call(w.parsers);if("string"==typeof a)b=o.charAt(p)===a?a:null,c=1,d();else{if(d(),!(b=a.exec(u[q])))return null;c=b[0].length}return b?(g(c),"string"==typeof b?b:1===b.length?b[0]:b):void 0}function g(a){for(var b=p,c=q,d=p+u[q].length,f=p+=a;d>p&&e(o.charAt(p));)p++;return u[q]=u[q].slice(a+(p-f)),v=p,0===u[q].length&&q=0&&"\n"!==b.charAt(c);)e++;return"number"==typeof a&&(d=(b.slice(0,a).match(/\n/g)||"").length),{line:d,column:e}}function m(a,b,c){var d=c.currentFileInfo.filename;return"browser"!==less.mode&&"rhino"!==less.mode&&(d=require("path").resolve(d)),{lineNumber:l(a,b).line+1,fileName:d}}function n(a,b){var c=k(a,b),d=l(a.index,c),e=d.line,f=d.column,g=a.call&&l(a.call,c).line,h=c.split("\n");this.type=a.type||"Syntax",this.message=a.message,this.filename=a.filename||b.currentFileInfo.filename,this.index=a.index,this.line="number"==typeof e?e+1:null,this.callLine=g+1,this.callExtract=h[g],this.stack=a.stack,this.column=f,this.extract=[h[e-1],h[e],h[e+1]]}var o,p,q,r,s,t,u,v,w,x=a&&a.filename;a instanceof tree.parseEnv||(a=new tree.parseEnv(a));var y=this.imports={paths:a.paths||[],queue:[],files:a.files,contents:a.contents,mime:a.mime,error:null,push:function(b,c,d,e){var f=this;this.queue.push(b);var g=function(a,c,d){f.queue.splice(f.queue.indexOf(b),1);var g=d in f.files||d===x;f.files[d]=c,a&&!f.error&&(f.error=a),e(a,c,g,d)};less.Parser.importer?less.Parser.importer(b,c,g,a):less.Parser.fileLoader(b,c,function(b,e,f,h){if(b)return g(b),void 0;var i=new tree.parseEnv(a);i.currentFileInfo=h,i.processImports=!1,i.contents[f]=e,(c.reference||d.reference)&&(h.reference=!0),d.inline?g(null,e,f):new less.Parser(i).parse(e,function(a,b){g(a,b,f)})},a)}};return n.prototype=new Error,n.prototype.constructor=n,this.env=a=a||{},this.optimization="optimization"in this.env?this.env.optimization:1,w={imports:y,parse:function(b,c){var d,e,g,h=null;if(p=q=v=t=0,o=b.replace(/\r\n/g,"\n"),o=o.replace(/^\uFEFF/,""),w.imports.contents[a.currentFileInfo.filename]=o,u=function(b){for(var c,d,e,f,g=0,i=/(?:@\{[\w-]+\}|[^"'`\{\}\/\(\)\\])+/g,j=/\/\*(?:[^*]|\*+[^\/*])*\*+\/|\/\/.*/g,k=/"((?:[^"\\\r\n]|\\.)*)"|'((?:[^'\\\r\n]|\\.)*)'|`((?:[^`]|\\.)*)`/g,l=0,m=b[0],p=0;p0?"missing closing `}`":"missing opening `{`",filename:a.currentFileInfo.filename},a)),b.map(function(a){return a.join("")})}([[]]),h)return c(new n(h,a));try{d=new tree.Ruleset([],f(this.parsers.primary)),d.root=!0,d.firstRoot=!0}catch(i){return c(new n(i,a))}if(d.toCSS=function(b){return function(c,d){c=c||{};var e,f,g=new tree.evalEnv(c);"object"!=typeof d||Array.isArray(d)||(d=Object.keys(d).map(function(a){var b=d[a];return b instanceof tree.Value||(b instanceof tree.Expression||(b=new tree.Expression([b])),b=new tree.Value([b])),new tree.Rule("@"+a,b,!1,null,0)}),g.frames=[new tree.Ruleset(null,d)]);try{e=b.call(this,g),(new tree.joinSelectorVisitor).run(e),(new tree.processExtendsVisitor).run(e),new tree.toCSSVisitor({compress:Boolean(c.compress)}).run(e),c.sourceMap&&(e=new tree.sourceMapOutput({writeSourceMap:c.writeSourceMap,rootNode:e,contentsMap:w.imports.contents,sourceMapFilename:c.sourceMapFilename,outputFilename:c.sourceMapOutputFilename,sourceMapBasepath:c.sourceMapBasepath,sourceMapRootpath:c.sourceMapRootpath,outputSourceFiles:c.outputSourceFiles,sourceMapGenerator:c.sourceMapGenerator})),f=e.toCSS({compress:Boolean(c.compress),dumpLineNumbers:a.dumpLineNumbers,strictUnits:Boolean(c.strictUnits)})}catch(h){throw new n(h,a)}return c.cleancss&&"node"===less.mode?require("clean-css").process(f):c.compress?f.replace(/(^(\s)+)|((\s)+$)/g,""):f}}(d.eval),p57||43>b||47===b||44==b))return(a=f(/^([+-]?\d*\.?\d+)(%|[a-z]+)?/))?new tree.Dimension(a[1],a[2]):void 0},unicodeDescriptor:function(){var a;return(a=f(/^U\+[0-9a-fA-F?]+(\-[0-9a-fA-F?]+)?/))?new tree.UnicodeDescriptor(a[0]):void 0},javascript:function(){var b,c,d=p;return"~"===o.charAt(d)&&(d++,c=!0),"`"===o.charAt(d)?(void 0===a.javascriptEnabled||a.javascriptEnabled||i("You are using JavaScript, which has been disabled."),c&&f("~"),(b=f(/^`([^`]*)`/))?new tree.JavaScript(b[1],p,c):void 0):void 0}},variable:function(){var a;return"@"===o.charAt(p)&&(a=f(/^(@[\w-]+)\s*:/))?a[1]:void 0},extend:function(a){var b,c,d,e=p,g=[];if(f(a?/^&:extend\(/:/^:extend\(/)){do{for(d=null,b=[];;){if(d=f(/^(all)(?=\s*(\)|,))/))break;if(c=f(this.element),!c)break;b.push(c)}d=d&&d[1],g.push(new tree.Extend(new tree.Selector(b),d,e))}while(f(","));return h(/^\)/),a&&h(/^;/),g}},extendRule:function(){return this.extend(!0)},mixin:{call:function(){var d,e,g,i=[],k=p,l=o.charAt(p),m=!1;if("."===l||"#"===l){for(b();d=f(/^[#.](?:[\w-]|\\(?:[A-Fa-f0-9]{1,6} ?|[^A-Fa-f0-9]))+/);)i.push(new tree.Element(e,d,p,a.currentFileInfo)),e=f(">");return f("(")&&(g=this.mixin.args.call(this,!0).args,h(")")),g=g||[],f(this.important)&&(m=!0),i.length>0&&(f(";")||j("}"))?new tree.mixin.Call(i,g,k,a.currentFileInfo,m):(c(),void 0)}},args:function(a){for(var b,c,d,e,g,j,k=[],l=[],m=[],n={args:null,variadic:!1};;){if(a)j=f(this.expression);else{if(f(this.comments),"."===o.charAt(p)&&f(/^\.{3}/)){n.variadic=!0,f(";")&&!b&&(b=!0),(b?l:m).push({variadic:!0});break}j=f(this.entities.variable)||f(this.entities.literal)||f(this.entities.keyword)}if(!j)break;e=null,j.throwAwayComments&&j.throwAwayComments(),g=j;var q=null;if(a?1==j.value.length&&(q=j.value[0]):q=j,q&&q instanceof tree.Variable)if(f(":"))k.length>0&&(b&&i("Cannot mix ; and , as delimiter types"),c=!0),g=h(this.expression),e=d=q.name;else{if(!a&&f(/^\.{3}/)){n.variadic=!0,f(";")&&!b&&(b=!0),(b?l:m).push({name:j.name,variadic:!0});break}a||(d=e=q.name,g=null)}g&&k.push(g),m.push({name:e,value:g}),f(",")||(f(";")||b)&&(c&&i("Cannot mix ; and , as delimiter types"),b=!0,k.length>1&&(g=new tree.Value(k)),l.push({name:d,value:g}),d=null,k=[],c=!1)}return n.args=b?l:m,n},definition:function(){var a,d,e,g,i=[],k=!1;if(!("."!==o.charAt(p)&&"#"!==o.charAt(p)||j(/^[^{]*\}/))&&(b(),d=f(/^([#.](?:[\w-]|\\(?:[A-Fa-f0-9]{1,6} ?|[^A-Fa-f0-9]))+)\s*\(/))){a=d[1];var l=this.mixin.args.call(this,!1);if(i=l.args,k=l.variadic,f(")")||(t=p,c()),f(this.comments),f(/^when/)&&(g=h(this.conditions,"expected condition")),e=f(this.block))return new tree.mixin.Definition(a,i,e,g,k);c()}}},entity:function(){return f(this.entities.literal)||f(this.entities.variable)||f(this.entities.url)||f(this.entities.call)||f(this.entities.keyword)||f(this.entities.javascript)||f(this.comment)},end:function(){return f(";")||j("}")},alpha:function(){var a;if(f(/^\(opacity=/i))return(a=f(/^\d+/)||f(this.entities.variable))?(h(")"),new tree.Alpha(a)):void 0},element:function(){var b,c,d;return c=f(this.combinator),b=f(/^(?:\d+\.\d+|\d+)%/)||f(/^(?:[.#]?|:*)(?:[\w-]|[^\x00-\x9f]|\\(?:[A-Fa-f0-9]{1,6} ?|[^A-Fa-f0-9]))+/)||f("*")||f("&")||f(this.attribute)||f(/^\([^()@]+\)/)||f(/^[\.#](?=@)/)||f(this.entities.variableCurly),b||f("(")&&(d=f(this.selector))&&f(")")&&(b=new tree.Paren(d)),b?new tree.Element(c,b,p,a.currentFileInfo):void 0},combinator:function(){var a=o.charAt(p);if(">"===a||"+"===a||"~"===a||"|"===a){for(p++;o.charAt(p).match(/\s/);)p++;return new tree.Combinator(a)}return o.charAt(p-1).match(/\s/)?new tree.Combinator(" "):new tree.Combinator(null)},lessSelector:function(){return this.selector(!0)},selector:function(b){for(var c,d,e,g,j,k=[],l=[];(b&&(e=f(this.extend))||b&&(g=f(/^when/))||(c=f(this.element)))&&(g?j=h(this.conditions,"expected condition"):j?i("CSS guard can only be used at the end of selector"):e?l.push.apply(l,e):(l.length&&i("Extend can only be used at the end of selector"),d=o.charAt(p),k.push(c),c=null),"{"!==d&&"}"!==d&&";"!==d&&","!==d&&")"!==d););return k.length>0?new tree.Selector(k,l,j,p,a.currentFileInfo):(l.length&&i("Extend must be used to extend a selector, it cannot be used on its own"),void 0)},attribute:function(){var a,b,c;if(f("["))return(a=f(this.entities.variableCurly))||(a=h(/^(?:[_A-Za-z0-9-\*]*\|)?(?:[_A-Za-z0-9-]|\\.)+/)),(c=f(/^[|~*$^]?=/))&&(b=f(this.entities.quoted)||f(/^[0-9]+%/)||f(/^[\w-]+/)||f(this.entities.variableCurly)),h("]"),new tree.Attribute(a,c,b)},block:function(){var a;return f("{")&&(a=f(this.primary))&&f("}")?a:void 0},ruleset:function(){var d,e,g,h=[];for(b(),a.dumpLineNumbers&&(g=m(p,o,a));(d=f(this.lessSelector))&&(h.push(d),f(this.comments),f(","));)d.condition&&i("Guards are only currently allowed on a single selector."),f(this.comments);if(h.length>0&&(e=f(this.block))){var j=new tree.Ruleset(h,e,a.strictImports);return a.dumpLineNumbers&&(j.debugInfo=g),j}t=p,c()},rule:function(d){var e,g,h,i=o.charAt(p),j=!1;if(b(),"."!==i&&"#"!==i&&"&"!==i&&(e=f(this.variable)||f(this.ruleProperty))){if(g=d||!a.compress&&"@"!==e.charAt(0)?f(this.anonymousValue)||f(this.value):f(this.value)||f(this.anonymousValue),h=f(this.important),"+"===e[e.length-1]&&(j=!0,e=e.substr(0,e.length-1)),g&&f(this.end))return new tree.Rule(e,g,h,j,s,a.currentFileInfo);if(t=p,c(),g&&!d)return this.rule(!0)}},anonymousValue:function(){var a;return(a=/^([^@+\/'"*`(;{}-]*);/.exec(u[q]))?(p+=a[0].length-1,new tree.Anonymous(a[1])):void 0},"import":function(){var d,e,g=p;b();var h=f(/^@import?\s+/),i=(h?f(this.importOptions):null)||{};return h&&(d=f(this.entities.quoted)||f(this.entities.url))&&(e=f(this.mediaFeatures),f(";"))?(e=e&&new tree.Value(e),new tree.Import(d,e,i,g,a.currentFileInfo)):(c(),void 0)},importOptions:function(){var a,b,c,d={};if(!f("("))return null;do if(a=f(this.importOption)){switch(b=a,c=!0,b){case"css":b="less",c=!1;break;case"once":b="multiple",c=!1}if(d[b]=c,!f(","))break}while(a);return h(")"),d},importOption:function(){var a=f(/^(less|css|multiple|once|inline|reference)/);return a?a[1]:void 0},mediaFeature:function(){var b,c,d=[];do if(b=f(this.entities.keyword)||f(this.entities.variable))d.push(b);else if(f("(")){if(c=f(this.property),b=f(this.value),!f(")"))return null;if(c&&b)d.push(new tree.Paren(new tree.Rule(c,b,null,null,p,a.currentFileInfo,!0)));else{if(!b)return null;d.push(new tree.Paren(b))}}while(b);return d.length>0?new tree.Expression(d):void 0},mediaFeatures:function(){var a,b=[];do if(a=f(this.mediaFeature)){if(b.push(a),!f(","))break}else if((a=f(this.entities.variable))&&(b.push(a),!f(",")))break;while(a);return b.length>0?b:null},media:function(){var b,c,d,e;return a.dumpLineNumbers&&(e=m(p,o,a)),f(/^@media/)&&(b=f(this.mediaFeatures),c=f(this.block))?(d=new tree.Media(c,b,p,a.currentFileInfo),a.dumpLineNumbers&&(d.debugInfo=e),d):void 0},directive:function(){var d,e,g,h,i,j,k,l;if("@"===o.charAt(p)){if(e=f(this["import"])||f(this.media))return e;if(b(),d=f(/^@[a-z-]+/)){switch(h=d,"-"==d.charAt(1)&&d.indexOf("-",2)>0&&(h="@"+d.slice(d.indexOf("-",2)+1)),h){case"@font-face":i=!0;break;case"@viewport":case"@top-left":case"@top-left-corner":case"@top-center":case"@top-right":case"@top-right-corner":case"@bottom-left":case"@bottom-left-corner":case"@bottom-center":case"@bottom-right":case"@bottom-right-corner":case"@left-top":case"@left-middle":case"@left-bottom":case"@right-top":case"@right-middle":case"@right-bottom":i=!0;break;case"@host":case"@page":case"@document":case"@supports":case"@keyframes":i=!0,j=!0;break;case"@namespace":k=!0}if(j&&(l=(f(/^[^{]+/)||"").trim(),l&&(d+=" "+l)),i){if(g=f(this.block))return new tree.Directive(d,g,p,a.currentFileInfo)}else if((e=k?f(this.expression):f(this.entity))&&f(";")){var n=new tree.Directive(d,e,p,a.currentFileInfo);return a.dumpLineNumbers&&(n.debugInfo=m(p,o,a)),n}c()}}},value:function(){for(var a,b=[];(a=f(this.expression))&&(b.push(a),f(",")););return b.length>0?new tree.Value(b):void 0},important:function(){return"!"===o.charAt(p)?f(/^! *important/):void 0},sub:function(){var a,b;return f("(")&&(a=f(this.addition))?(b=new tree.Expression([a]),h(")"),b.parens=!0,b):void 0},multiplication:function(){var a,b,c,d,g;if(a=f(this.operand)){for(g=e(o.charAt(p-1));!j(/^\/[*\/]/)&&(c=f("/")||f("*"))&&(b=f(this.operand));)a.parensInOp=!0,b.parensInOp=!0,d=new tree.Operation(c,[d||a,b],g),g=e(o.charAt(p-1));return d||a}},addition:function(){var a,b,c,d,g;if(a=f(this.multiplication)){for(g=e(o.charAt(p-1));(c=f(/^[-+]\s+/)||!g&&(f("+")||f("-")))&&(b=f(this.multiplication));)a.parensInOp=!0,b.parensInOp=!0,d=new tree.Operation(c,[d||a,b],g),g=e(o.charAt(p-1));return d||a}},conditions:function(){var a,b,c,d=p;if(a=f(this.condition)){for(;j(/^,\s*(not\s*)?\(/)&&f(",")&&(b=f(this.condition));)c=new tree.Condition("or",c||a,b,d);return c||a}},condition:function(){var a,b,c,d,e=p,g=!1;return f(/^not/)&&(g=!0),h("("),(a=f(this.addition)||f(this.entities.keyword)||f(this.entities.quoted))?((d=f(/^(?:>=|<=|=<|[<=>])/))?(b=f(this.addition)||f(this.entities.keyword)||f(this.entities.quoted))?c=new tree.Condition(d,a,b,e,g):i("expected expression"):c=new tree.Condition("=",a,new tree.Keyword("true"),e,g),h(")"),f(/^and/)?new tree.Condition("and",c,f(this.condition)):c):void 0},operand:function(){var a,b=o.charAt(p+1);"-"!==o.charAt(p)||"@"!==b&&"("!==b||(a=f("-"));var c=f(this.sub)||f(this.entities.dimension)||f(this.entities.color)||f(this.entities.variable)||f(this.entities.call);return a&&(c.parensInOp=!0,c=new tree.Negative(c)),c},expression:function(){for(var a,b,c=[];a=f(this.addition)||f(this.entity);)c.push(a),!j(/^\/[\/*]/)&&(b=f("/"))&&c.push(new tree.Anonymous(b));return c.length>0?new tree.Expression(c):void 0},property:function(){var a;return(a=f(/^(\*?-?[_a-zA-Z0-9-]+)\s*:/))?a[1]:void 0},ruleProperty:function(){var a;return(a=f(/^(\*?-?[_a-zA-Z0-9-]+)\s*(\+?)\s*:/))?a[1]+(a[2]||""):void 0}}}},function(a){function b(b){return a.functions.hsla(b.h,b.s,b.l,b.a)}function c(b,c){return b instanceof a.Dimension&&b.unit.is("%")?parseFloat(b.value*c/100):d(b)}function d(b){if(b instanceof a.Dimension)return parseFloat(b.unit.is("%")?b.value/100:b.value);if("number"==typeof b)return b;throw{error:"RuntimeError",message:"color functions take numbers as parameters"}}function e(a){return Math.min(1,Math.max(0,a))}a.functions={rgb:function(a,b,c){return this.rgba(a,b,c,1)},rgba:function(b,e,f,g){var h=[b,e,f].map(function(a){return c(a,256)});return g=d(g),new a.Color(h,g)},hsl:function(a,b,c){return this.hsla(a,b,c,1)},hsla:function(a,b,c,f){function g(a){return a=0>a?a+1:a>1?a-1:a,1>6*a?i+6*(h-i)*a:1>2*a?h:2>3*a?i+6*(h-i)*(2/3-a):i}a=d(a)%360/360,b=e(d(b)),c=e(d(c)),f=e(d(f));var h=.5>=c?c*(b+1):c+b-c*b,i=2*c-h;return this.rgba(255*g(a+1/3),255*g(a),255*g(a-1/3),f)},hsv:function(a,b,c){return this.hsva(a,b,c,1)},hsva:function(a,b,c,e){a=360*(d(a)%360/360),b=d(b),c=d(c),e=d(e);var f,g;f=Math.floor(a/60%6),g=a/60-f;var h=[c,c*(1-b),c*(1-g*b),c*(1-(1-g)*b)],i=[[0,3,1],[2,0,1],[1,0,3],[1,2,0],[3,1,0],[0,1,2]];return this.rgba(255*h[i[f][0]],255*h[i[f][1]],255*h[i[f][2]],e)},hue:function(b){return new a.Dimension(Math.round(b.toHSL().h))},saturation:function(b){return new a.Dimension(Math.round(100*b.toHSL().s),"%")},lightness:function(b){return new a.Dimension(Math.round(100*b.toHSL().l),"%")},hsvhue:function(b){return new a.Dimension(Math.round(b.toHSV().h))},hsvsaturation:function(b){return new a.Dimension(Math.round(100*b.toHSV().s),"%")},hsvvalue:function(b){return new a.Dimension(Math.round(100*b.toHSV().v),"%")},red:function(b){return new a.Dimension(b.rgb[0])},green:function(b){return new a.Dimension(b.rgb[1])},blue:function(b){return new a.Dimension(b.rgb[2])},alpha:function(b){return new a.Dimension(b.toHSL().a)},luma:function(b){return new a.Dimension(Math.round(100*b.luma()*b.alpha),"%")},saturate:function(a,c){if(!a.rgb)return null;var d=a.toHSL();return d.s+=c.value/100,d.s=e(d.s),b(d)},desaturate:function(a,c){var d=a.toHSL();return d.s-=c.value/100,d.s=e(d.s),b(d)},lighten:function(a,c){var d=a.toHSL();return d.l+=c.value/100,d.l=e(d.l),b(d)},darken:function(a,c){var d=a.toHSL();return d.l-=c.value/100,d.l=e(d.l),b(d)},fadein:function(a,c){var d=a.toHSL();return d.a+=c.value/100,d.a=e(d.a),b(d)},fadeout:function(a,c){var d=a.toHSL();return d.a-=c.value/100,d.a=e(d.a),b(d)},fade:function(a,c){var d=a.toHSL();return d.a=c.value/100,d.a=e(d.a),b(d)},spin:function(a,c){var d=a.toHSL(),e=(d.h+c.value)%360;return d.h=0>e?360+e:e,b(d)},mix:function(b,c,d){d||(d=new a.Dimension(50));var e=d.value/100,f=2*e-1,g=b.toHSL().a-c.toHSL().a,h=((-1==f*g?f:(f+g)/(1+f*g))+1)/2,i=1-h,j=[b.rgb[0]*h+c.rgb[0]*i,b.rgb[1]*h+c.rgb[1]*i,b.rgb[2]*h+c.rgb[2]*i],k=b.alpha*e+c.alpha*(1-e);return new a.Color(j,k)},greyscale:function(b){return this.desaturate(b,new a.Dimension(100))},contrast:function(a,b,c,e){if(!a.rgb)return null;if("undefined"==typeof c&&(c=this.rgba(255,255,255,1)),"undefined"==typeof b&&(b=this.rgba(0,0,0,1)),b.luma()>c.luma()){var f=c;c=b,b=f}return e="undefined"==typeof e?.43:d(e),a.luma()*a.alphah.value)&&(j[e]=f)):(k[i]=j.length,j.push(f))):j.push(f);return 1==j.length?j[0]:(c=j.map(function(a){return a.toCSS(this.env)}).join(this.env.compress?",":", "),new a.Anonymous((b?"min":"max")+"("+c+")"))},min:function(){return this._minmax(!0,arguments)},max:function(){return this._minmax(!1,arguments)},argb:function(b){return new a.Anonymous(b.toARGB())},percentage:function(b){return new a.Dimension(100*b.value,"%")},color:function(b){if(b instanceof a.Quoted){var c,d=b.value;if(c=a.Color.fromKeyword(d))return c;if(/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})/.test(d))return new a.Color(d.slice(1));throw{type:"Argument",message:"argument must be a color keyword or 3/6 digit hex e.g. #FFF"}}throw{type:"Argument",message:"argument must be a string"}},iscolor:function(b){return this._isa(b,a.Color)},isnumber:function(b){return this._isa(b,a.Dimension)},isstring:function(b){return this._isa(b,a.Quoted)},iskeyword:function(b){return this._isa(b,a.Keyword)},isurl:function(b){return this._isa(b,a.URL)
+},ispixel:function(a){return this.isunit(a,"px")},ispercentage:function(a){return this.isunit(a,"%")},isem:function(a){return this.isunit(a,"em")},isunit:function(b,c){return b instanceof a.Dimension&&b.unit.is(c.value||c)?a.True:a.False},_isa:function(b,c){return b instanceof c?a.True:a.False},multiply:function(a,b){var c=a.rgb[0]*b.rgb[0]/255,d=a.rgb[1]*b.rgb[1]/255,e=a.rgb[2]*b.rgb[2]/255;return this.rgb(c,d,e)},screen:function(a,b){var c=255-(255-a.rgb[0])*(255-b.rgb[0])/255,d=255-(255-a.rgb[1])*(255-b.rgb[1])/255,e=255-(255-a.rgb[2])*(255-b.rgb[2])/255;return this.rgb(c,d,e)},overlay:function(a,b){var c=a.rgb[0]<128?2*a.rgb[0]*b.rgb[0]/255:255-2*(255-a.rgb[0])*(255-b.rgb[0])/255,d=a.rgb[1]<128?2*a.rgb[1]*b.rgb[1]/255:255-2*(255-a.rgb[1])*(255-b.rgb[1])/255,e=a.rgb[2]<128?2*a.rgb[2]*b.rgb[2]/255:255-2*(255-a.rgb[2])*(255-b.rgb[2])/255;return this.rgb(c,d,e)},softlight:function(a,b){var c=b.rgb[0]*a.rgb[0]/255,d=c+a.rgb[0]*(255-(255-a.rgb[0])*(255-b.rgb[0])/255-c)/255;c=b.rgb[1]*a.rgb[1]/255;var e=c+a.rgb[1]*(255-(255-a.rgb[1])*(255-b.rgb[1])/255-c)/255;c=b.rgb[2]*a.rgb[2]/255;var f=c+a.rgb[2]*(255-(255-a.rgb[2])*(255-b.rgb[2])/255-c)/255;return this.rgb(d,e,f)},hardlight:function(a,b){var c=b.rgb[0]<128?2*b.rgb[0]*a.rgb[0]/255:255-2*(255-b.rgb[0])*(255-a.rgb[0])/255,d=b.rgb[1]<128?2*b.rgb[1]*a.rgb[1]/255:255-2*(255-b.rgb[1])*(255-a.rgb[1])/255,e=b.rgb[2]<128?2*b.rgb[2]*a.rgb[2]/255:255-2*(255-b.rgb[2])*(255-a.rgb[2])/255;return this.rgb(c,d,e)},difference:function(a,b){var c=Math.abs(a.rgb[0]-b.rgb[0]),d=Math.abs(a.rgb[1]-b.rgb[1]),e=Math.abs(a.rgb[2]-b.rgb[2]);return this.rgb(c,d,e)},exclusion:function(a,b){var c=a.rgb[0]+b.rgb[0]*(255-a.rgb[0]-a.rgb[0])/255,d=a.rgb[1]+b.rgb[1]*(255-a.rgb[1]-a.rgb[1])/255,e=a.rgb[2]+b.rgb[2]*(255-a.rgb[2]-a.rgb[2])/255;return this.rgb(c,d,e)},average:function(a,b){var c=(a.rgb[0]+b.rgb[0])/2,d=(a.rgb[1]+b.rgb[1])/2,e=(a.rgb[2]+b.rgb[2])/2;return this.rgb(c,d,e)},negation:function(a,b){var c=255-Math.abs(255-b.rgb[0]-a.rgb[0]),d=255-Math.abs(255-b.rgb[1]-a.rgb[1]),e=255-Math.abs(255-b.rgb[2]-a.rgb[2]);return this.rgb(c,d,e)},tint:function(a,b){return this.mix(this.rgb(255,255,255),a,b)},shade:function(a,b){return this.mix(this.rgb(0,0,0),a,b)},extract:function(a,b){return b=b.value-1,Array.isArray(a.value)?a.value[b]:Array(a)[b]},length:function(b){var c=Array.isArray(b.value)?b.value.length:1;return new a.Dimension(c)},"data-uri":function(b,c){if("undefined"!=typeof window)return new a.URL(c||b,this.currentFileInfo).eval(this.env);var d=b.value,e=c&&c.value,f=require("fs"),g=require("path"),h=!1;if(arguments.length<2&&(e=d),this.env.isPathRelative(e)&&(e=this.currentFileInfo.relativeUrls?g.join(this.currentFileInfo.currentDirectory,e):g.join(this.currentFileInfo.entryPath,e)),arguments.length<2){var i;try{i=require("mime")}catch(j){i=a._mime}d=i.lookup(e);var k=i.charsets.lookup(d);h=["US-ASCII","UTF-8"].indexOf(k)<0,h&&(d+=";base64")}else h=/;base64$/.test(d);var l=f.readFileSync(e),m=32,n=parseInt(l.length/1024,10);if(n>=m&&this.env.ieCompat!==!1)return this.env.silent||console.warn("Skipped data-uri embedding of %s because its size (%dKB) exceeds IE8-safe %dKB!",e,n,m),new a.URL(c||b,this.currentFileInfo).eval(this.env);l=h?l.toString("base64"):encodeURIComponent(l);var o="'data:"+d+","+l+"'";return new a.URL(new a.Anonymous(o))},"svg-gradient":function(b){function c(){throw{type:"Argument",message:"svg-gradient expects direction, start_color [start_position], [color position,]..., end_color [end_position]"}}arguments.length<3&&c();var d,e,f,g,h,i,j,k=Array.prototype.slice.call(arguments,1),l="linear",m='x="0" y="0" width="1" height="1"',n=!0,o={compress:!1},p=b.toCSS(o);switch(p){case"to bottom":d='x1="0%" y1="0%" x2="0%" y2="100%"';break;case"to right":d='x1="0%" y1="0%" x2="100%" y2="0%"';break;case"to bottom right":d='x1="0%" y1="0%" x2="100%" y2="100%"';break;case"to top right":d='x1="0%" y1="100%" x2="100%" y2="0%"';break;case"ellipse":case"ellipse at center":l="radial",d='cx="50%" cy="50%" r="75%"',m='x="-50" y="-50" width="101" height="101"';break;default:throw{type:"Argument",message:"svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center'"}}for(e='<'+l+'Gradient id="gradient" gradientUnits="userSpaceOnUse" '+d+">",f=0;fj?' stop-opacity="'+j+'"':"")+"/>";if(e+=""+l+"Gradient>"+" ',n)try{e=new Buffer(e).toString("base64")}catch(q){n=!1}return e="'data:image/svg+xml"+(n?";base64":"")+","+e+"'",new a.URL(new a.Anonymous(e))}},a._mime={_types:{".htm":"text/html",".html":"text/html",".gif":"image/gif",".jpg":"image/jpeg",".jpeg":"image/jpeg",".png":"image/png"},lookup:function(b){var c=require("path").extname(b),d=a._mime._types[c];if(void 0===d)throw new Error('Optional dependency "mime" is required for '+c);return d},charsets:{lookup:function(a){return a&&/^text\//.test(a)?"UTF-8":""}}};for(var f=[{name:"ceil"},{name:"floor"},{name:"sqrt"},{name:"abs"},{name:"tan",unit:""},{name:"sin",unit:""},{name:"cos",unit:""},{name:"atan",unit:"rad"},{name:"asin",unit:"rad"},{name:"acos",unit:"rad"}],g=function(a,b){return function(c){return null!=b&&(c=c.unify()),this._math(Math[a],b,c)}},h=0;h1?"["+a.value.map(function(a){return a.toCSS(!1)}).join(", ")+"]":a.toCSS(!1)},a.toCSS=function(a){var b=[];return this.genCSS(a,{add:function(a){b.push(a)},isEmpty:function(){return 0===b.length}}),b.join("")},a.outputRuleset=function(a,b,c){b.add(a.compress?"{":" {\n"),a.tabLevel=(a.tabLevel||0)+1;for(var d=a.compress?"":Array(a.tabLevel+1).join(" "),e=a.compress?"":Array(a.tabLevel).join(" "),f=0;fb?-1:1},genCSS:function(a,b){b.add(this.value,this.currentFileInfo,this.index,this.mapLines)},toCSS:a.toCSS}}(require("../tree")),function(a){a.Assignment=function(a,b){this.key=a,this.value=b},a.Assignment.prototype={type:"Assignment",accept:function(a){this.value=a.visit(this.value)},eval:function(b){return this.value.eval?new a.Assignment(this.key,this.value.eval(b)):this},genCSS:function(a,b){b.add(this.key+"="),this.value.genCSS?this.value.genCSS(a,b):b.add(this.value)},toCSS:a.toCSS}}(require("../tree")),function(a){a.Call=function(a,b,c,d){this.name=a,this.args=b,this.index=c,this.currentFileInfo=d},a.Call.prototype={type:"Call",accept:function(a){this.args=a.visit(this.args)},eval:function(b){var c,d,e=this.args.map(function(a){return a.eval(b)}),f=this.name.toLowerCase();if(f in a.functions)try{if(d=new a.functionCall(b,this.currentFileInfo),c=d[f].apply(d,e),null!=c)return c}catch(g){throw{type:g.type||"Runtime",message:"error evaluating function `"+this.name+"`"+(g.message?": "+g.message:""),index:this.index,filename:this.currentFileInfo.filename}}return new a.Call(this.name,e,this.index,this.currentFileInfo)},genCSS:function(a,b){b.add(this.name+"(",this.currentFileInfo,this.index);for(var c=0;cf;f++)e[f]=a.operate(b,c,this.rgb[f],d.rgb[f]);return new a.Color(e,this.alpha+d.alpha)},toRGB:function(){return"#"+this.rgb.map(function(a){return a=Math.round(a),a=(a>255?255:0>a?0:a).toString(16),1===a.length?"0"+a:a}).join("")},toHSL:function(){var a,b,c=this.rgb[0]/255,d=this.rgb[1]/255,e=this.rgb[2]/255,f=this.alpha,g=Math.max(c,d,e),h=Math.min(c,d,e),i=(g+h)/2,j=g-h;if(g===h)a=b=0;else{switch(b=i>.5?j/(2-g-h):j/(g+h),g){case c:a=(d-e)/j+(e>d?6:0);break;case d:a=(e-c)/j+2;break;case e:a=(c-d)/j+4}a/=6}return{h:360*a,s:b,l:i,a:f}},toHSV:function(){var a,b,c=this.rgb[0]/255,d=this.rgb[1]/255,e=this.rgb[2]/255,f=this.alpha,g=Math.max(c,d,e),h=Math.min(c,d,e),i=g,j=g-h;if(b=0===g?0:j/g,g===h)a=0;else{switch(g){case c:a=(d-e)/j+(e>d?6:0);break;case d:a=(e-c)/j+2;break;case e:a=(c-d)/j+4}a/=6}return{h:360*a,s:b,v:i,a:f}},toARGB:function(){var a=[Math.round(255*this.alpha)].concat(this.rgb);return"#"+a.map(function(a){return a=Math.round(a),a=(a>255?255:0>a?0:a).toString(16),1===a.length?"0"+a:a}).join("")},compare:function(a){return a.rgb?a.rgb[0]===this.rgb[0]&&a.rgb[1]===this.rgb[1]&&a.rgb[2]===this.rgb[2]&&a.alpha===this.alpha?0:-1:-1}},a.Color.fromKeyword=function(c){if(a.colors.hasOwnProperty(c))return new a.Color(a.colors[c].slice(1));if(c===b){var d=new a.Color([0,0,0],0);return d.isTransparentKeyword=!0,d}}}(require("../tree")),function(a){a.Comment=function(a,b,c,d){this.value=a,this.silent=!!b,this.currentFileInfo=d},a.Comment.prototype={type:"Comment",genCSS:function(b,c){this.debugInfo&&c.add(a.debugInfo(b,this),this.currentFileInfo,this.index),c.add(this.value.trim())},toCSS:a.toCSS,isSilent:function(a){var b=this.currentFileInfo&&this.currentFileInfo.reference&&!this.isReferenced,c=a.compress&&!this.value.match(/^\/\*!/);return this.silent||b||c},eval:function(){return this},markReferenced:function(){this.isReferenced=!0}}}(require("../tree")),function(a){a.Condition=function(a,b,c,d,e){this.op=a.trim(),this.lvalue=b,this.rvalue=c,this.index=d,this.negate=e},a.Condition.prototype={type:"Condition",accept:function(a){this.lvalue=a.visit(this.lvalue),this.rvalue=a.visit(this.rvalue)},eval:function(a){var b,c=this.lvalue.eval(a),d=this.rvalue.eval(a),e=this.index;return b=function(a){switch(a){case"and":return c&&d;case"or":return c||d;default:if(c.compare)b=c.compare(d);else{if(!d.compare)throw{type:"Type",message:"Unable to perform comparison",index:e};b=d.compare(c)}switch(b){case-1:return"<"===a||"=<"===a||"<="===a;case 0:return"="===a||">="===a||"=<"===a||"<="===a;case 1:return">"===a||">="===a}}}(this.op),this.negate?!b:b}}}(require("../tree")),function(a){a.Dimension=function(b,c){this.value=parseFloat(b),this.unit=c&&c instanceof a.Unit?c:new a.Unit(c?[c]:void 0)},a.Dimension.prototype={type:"Dimension",accept:function(a){this.unit=a.visit(this.unit)},eval:function(){return this},toColor:function(){return new a.Color([this.value,this.value,this.value])},genCSS:function(a,b){if(a&&a.strictUnits&&!this.unit.isSingular())throw new Error("Multiple units in dimension. Correct the units or use the unit function. Bad unit: "+this.unit.toString());var c=this.value,d=String(c);if(0!==c&&1e-6>c&&c>-1e-6&&(d=c.toFixed(20).replace(/0+$/,"")),a&&a.compress){if(0===c&&this.unit.isLength())return b.add(d),void 0;c>0&&1>c&&(d=d.substr(1))}b.add(d),this.unit.genCSS(a,b)},toCSS:a.toCSS,operate:function(b,c,d){var e=a.operate(b,c,this.value,d.value),f=this.unit.clone();if("+"===c||"-"===c)if(0===f.numerator.length&&0===f.denominator.length)f.numerator=d.unit.numerator.slice(0),f.denominator=d.unit.denominator.slice(0);else if(0===d.unit.numerator.length&&0===f.denominator.length);else{if(d=d.convertTo(this.unit.usedUnits()),b.strictUnits&&d.unit.toString()!==f.toString())throw new Error("Incompatible units. Change the units or use the unit function. Bad units: '"+f.toString()+"' and '"+d.unit.toString()+"'.");e=a.operate(b,c,this.value,d.value)}else"*"===c?(f.numerator=f.numerator.concat(d.unit.numerator).sort(),f.denominator=f.denominator.concat(d.unit.denominator).sort(),f.cancel()):"/"===c&&(f.numerator=f.numerator.concat(d.unit.denominator).sort(),f.denominator=f.denominator.concat(d.unit.numerator).sort(),f.cancel());return new a.Dimension(e,f)},compare:function(b){if(b instanceof a.Dimension){var c=this.unify(),d=b.unify(),e=c.value,f=d.value;return f>e?-1:e>f?1:d.unit.isEmpty()||0===c.unit.compare(d.unit)?0:-1}return-1},unify:function(){return this.convertTo({length:"m",duration:"s",angle:"rad"})},convertTo:function(b){var c,d,e,f,g,h=this.value,i=this.unit.clone(),j={};if("string"==typeof b){for(c in a.UnitConversions)a.UnitConversions[c].hasOwnProperty(b)&&(j={},j[c]=b);b=j}g=function(a,b){return e.hasOwnProperty(a)?(b?h/=e[a]/e[f]:h*=e[a]/e[f],f):a};for(d in b)b.hasOwnProperty(d)&&(f=b[d],e=a.UnitConversions[d],i.map(g));return i.cancel(),new a.Dimension(h,i)}},a.UnitConversions={length:{m:1,cm:.01,mm:.001,"in":.0254,pt:.0254/72,pc:12*(.0254/72)},duration:{s:1,ms:.001},angle:{rad:1/(2*Math.PI),deg:1/360,grad:.0025,turn:1}},a.Unit=function(a,b,c){this.numerator=a?a.slice(0).sort():[],this.denominator=b?b.slice(0).sort():[],this.backupUnit=c},a.Unit.prototype={type:"Unit",clone:function(){return new a.Unit(this.numerator.slice(0),this.denominator.slice(0),this.backupUnit)},genCSS:function(a,b){this.numerator.length>=1?b.add(this.numerator[0]):this.denominator.length>=1?b.add(this.denominator[0]):a&&a.strictUnits||!this.backupUnit||b.add(this.backupUnit)},toCSS:a.toCSS,toString:function(){var a,b=this.numerator.join("*");for(a=0;a0)for(b=0;e>b;b++)this.numerator.push(a);else if(0>e)for(b=0;-e>b;b++)this.denominator.push(a)}0===this.numerator.length&&0===this.denominator.length&&c&&(this.backupUnit=c),this.numerator.sort(),this.denominator.sort()}}}(require("../tree")),function(a){a.Directive=function(b,c,d,e){this.name=b,Array.isArray(c)?(this.rules=[new a.Ruleset([],c)],this.rules[0].allowImports=!0):this.value=c,this.currentFileInfo=e},a.Directive.prototype={type:"Directive",accept:function(a){this.rules=a.visit(this.rules),this.value=a.visit(this.value)},genCSS:function(b,c){c.add(this.name,this.currentFileInfo,this.index),this.rules?a.outputRuleset(b,c,this.rules):(c.add(" "),this.value.genCSS(b,c),c.add(";"))},toCSS:a.toCSS,eval:function(b){var c=this;return this.rules&&(b.frames.unshift(this),c=new a.Directive(this.name,null,this.index,this.currentFileInfo),c.rules=[this.rules[0].eval(b)],c.rules[0].root=!0,b.frames.shift()),c},variable:function(b){return a.Ruleset.prototype.variable.call(this.rules[0],b)},find:function(){return a.Ruleset.prototype.find.apply(this.rules[0],arguments)},rulesets:function(){return a.Ruleset.prototype.rulesets.apply(this.rules[0])},markReferenced:function(){var a,b;if(this.isReferenced=!0,this.rules)for(b=this.rules[0].rules,a=0;a":" > ","|":"|"},_outputMapCompressed:{"":""," ":" ",":":" :","+":"+","~":"~",">":">","|":"|"},genCSS:function(a,b){b.add((a.compress?this._outputMapCompressed:this._outputMap)[this.value])},toCSS:a.toCSS}}(require("../tree")),function(a){a.Expression=function(a){this.value=a},a.Expression.prototype={type:"Expression",accept:function(a){this.value=a.visit(this.value)},eval:function(b){var c,d=this.parens&&!this.parensInOp,e=!1;return d&&b.inParenthesis(),this.value.length>1?c=new a.Expression(this.value.map(function(a){return a.eval(b)})):1===this.value.length?(this.value[0].parens&&!this.value[0].parensInOp&&(e=!0),c=this.value[0].eval(b)):c=this,d&&b.outOfParenthesis(),this.parens&&this.parensInOp&&!b.isMathOn()&&!e&&(c=new a.Paren(c)),c},genCSS:function(a,b){for(var c=0;c0&&c.length&&""===c[0].combinator.value&&(c[0].combinator.value=" "),d=d.concat(a[b].elements);this.selfSelectors=[{elements:d}]}}}(require("../tree")),function(a){a.Import=function(a,b,c,d,e){if(this.options=c,this.index=d,this.path=a,this.features=b,this.currentFileInfo=e,void 0!==this.options.less||this.options.inline)this.css=!this.options.less||this.options.inline;else{var f=this.getPath();f&&/css([\?;].*)?$/.test(f)&&(this.css=!0)}},a.Import.prototype={type:"Import",accept:function(a){this.features=a.visit(this.features),this.path=a.visit(this.path),this.options.inline||(this.root=a.visit(this.root))},genCSS:function(a,b){this.css&&(b.add("@import ",this.currentFileInfo,this.index),this.path.genCSS(a,b),this.features&&(b.add(" "),this.features.genCSS(a,b)),b.add(";"))},toCSS:a.toCSS,getPath:function(){if(this.path instanceof a.Quoted){var b=this.path.value;return void 0!==this.css||/(\.[a-z]*$)|([\?;].*)$/.test(b)?b:b+".less"}return this.path instanceof a.URL?this.path.value.value:null},evalForImport:function(b){return new a.Import(this.path.eval(b),this.features,this.options,this.index,this.currentFileInfo)},evalPath:function(b){var c=this.path.eval(b),d=this.currentFileInfo&&this.currentFileInfo.rootpath;if(!(c instanceof a.URL)){if(d){var e=c.value;e&&b.isPathRelative(e)&&(c.value=d+e)}c.value=b.normalizePath(c.value)}return c},eval:function(b){var c,d=this.features&&this.features.eval(b);if(this.skip)return[];if(this.options.inline){var e=new a.Anonymous(this.root,0,{filename:this.importedFilename},!0);return this.features?new a.Media([e],this.features.value):[e]}if(this.css){var f=new a.Import(this.evalPath(b),d,this.options,this.index);if(!f.css&&this.error)throw this.error;return f}return c=new a.Ruleset([],this.root.rules.slice(0)),c.evalImports(b),this.features?new a.Media(c.rules,this.features.value):c.rules}}}(require("../tree")),function(a){a.JavaScript=function(a,b,c){this.escaped=c,this.expression=a,this.index=b},a.JavaScript.prototype={type:"JavaScript",eval:function(b){var c,d=this,e={},f=this.expression.replace(/@\{([\w-]+)\}/g,function(c,e){return a.jsify(new a.Variable("@"+e,d.index).eval(b))});try{f=new Function("return ("+f+")")}catch(g){throw{message:"JavaScript evaluation error: "+g.message+" from `"+f+"`",index:this.index}}for(var h in b.frames[0].variables())e[h.slice(1)]={value:b.frames[0].variables()[h].value,toJS:function(){return this.value.eval(b).toCSS()}};try{c=f.call(e)}catch(g){throw{message:"JavaScript evaluation error: '"+g.name+": "+g.message+"'",index:this.index}}return"string"==typeof c?new a.Quoted('"'+c+'"',c,this.escaped,this.index):Array.isArray(c)?new a.Anonymous(c.join(", ")):new a.Anonymous(c)}}}(require("../tree")),function(a){a.Keyword=function(a){this.value=a},a.Keyword.prototype={type:"Keyword",eval:function(){return this},genCSS:function(a,b){b.add(this.value)},toCSS:a.toCSS,compare:function(b){return b instanceof a.Keyword?b.value===this.value?0:1:-1}},a.True=new a.Keyword("true"),a.False=new a.Keyword("false")}(require("../tree")),function(a){a.Media=function(b,c,d,e){this.index=d,this.currentFileInfo=e;var f=this.emptySelectors();this.features=new a.Value(c),this.rules=[new a.Ruleset(f,b)],this.rules[0].allowImports=!0},a.Media.prototype={type:"Media",accept:function(a){this.features=a.visit(this.features),this.rules=a.visit(this.rules)},genCSS:function(b,c){c.add("@media ",this.currentFileInfo,this.index),this.features.genCSS(b,c),a.outputRuleset(b,c,this.rules)},toCSS:a.toCSS,eval:function(b){b.mediaBlocks||(b.mediaBlocks=[],b.mediaPath=[]);var c=new a.Media([],[],this.index,this.currentFileInfo);this.debugInfo&&(this.rules[0].debugInfo=this.debugInfo,c.debugInfo=this.debugInfo);var d=!1;b.strictMath||(d=!0,b.strictMath=!0);try{c.features=this.features.eval(b)}finally{d&&(b.strictMath=!1)}return b.mediaPath.push(c),b.mediaBlocks.push(c),b.frames.unshift(this.rules[0]),c.rules=[this.rules[0].eval(b)],b.frames.shift(),b.mediaPath.pop(),0===b.mediaPath.length?c.evalTop(b):c.evalNested(b)},variable:function(b){return a.Ruleset.prototype.variable.call(this.rules[0],b)},find:function(){return a.Ruleset.prototype.find.apply(this.rules[0],arguments)},rulesets:function(){return a.Ruleset.prototype.rulesets.apply(this.rules[0])},emptySelectors:function(){var b=new a.Element("","&",this.index,this.currentFileInfo);return[new a.Selector([b],null,null,this.index,this.currentFileInfo)]},markReferenced:function(){var a,b=this.rules[0].rules;for(this.isReferenced=!0,a=0;a1){var d=this.emptySelectors();c=new a.Ruleset(d,b.mediaBlocks),c.multiMedia=!0}return delete b.mediaBlocks,delete b.mediaPath,c},evalNested:function(b){var c,d,e=b.mediaPath.concat([this]);for(c=0;c0;c--)b.splice(c,0,new a.Anonymous("and"));return new a.Expression(b)})),new a.Ruleset([],[])},permute:function(a){if(0===a.length)return[];if(1===a.length)return a[0];for(var b=[],c=this.permute(a.slice(1)),d=0;d0){for(j=!0,g=0;gthis.params.length)return!1}c=Math.min(d,this.arity);for(var e=0;c>e;e++)if(!this.params[e].name&&!this.params[e].variadic&&a[e].value.eval(b).toCSS()!=this.params[e].value.eval(b).toCSS())return!1;return!0}}}(require("../tree")),function(a){a.Negative=function(a){this.value=a},a.Negative.prototype={type:"Negative",accept:function(a){this.value=a.visit(this.value)},genCSS:function(a,b){b.add("-"),this.value.genCSS(a,b)},toCSS:a.toCSS,eval:function(b){return b.isMathOn()?new a.Operation("*",[new a.Dimension(-1),this.value]).eval(b):new a.Negative(this.value.eval(b))}}}(require("../tree")),function(a){a.Operation=function(a,b,c){this.op=a.trim(),this.operands=b,this.isSpaced=c},a.Operation.prototype={type:"Operation",accept:function(a){this.operands=a.visit(this.operands)},eval:function(b){var c,d=this.operands[0].eval(b),e=this.operands[1].eval(b);if(b.isMathOn()){if(d instanceof a.Dimension&&e instanceof a.Color){if("*"!==this.op&&"+"!==this.op)throw{type:"Operation",message:"Can't substract or divide a color from a number"};c=e,e=d,d=c}if(!d.operate)throw{type:"Operation",message:"Operation on an invalid type"};return d.operate(b,this.op,e)}return new a.Operation(this.op,[d,e],this.isSpaced)},genCSS:function(a,b){this.operands[0].genCSS(a,b),this.isSpaced&&b.add(" "),b.add(this.op),this.isSpaced&&b.add(" "),this.operands[1].genCSS(a,b)},toCSS:a.toCSS},a.operate=function(a,b,c,d){switch(b){case"+":return c+d;case"-":return c-d;case"*":return c*d;case"/":return c/d}}}(require("../tree")),function(a){a.Paren=function(a){this.value=a},a.Paren.prototype={type:"Paren",accept:function(a){this.value=a.visit(this.value)},genCSS:function(a,b){b.add("("),this.value.genCSS(a,b),b.add(")")},toCSS:a.toCSS,eval:function(b){return new a.Paren(this.value.eval(b))}}}(require("../tree")),function(a){a.Quoted=function(a,b,c,d,e){this.escaped=c,this.value=b||"",this.quote=a.charAt(0),this.index=d,this.currentFileInfo=e},a.Quoted.prototype={type:"Quoted",genCSS:function(a,b){this.escaped||b.add(this.quote,this.currentFileInfo,this.index),b.add(this.value),this.escaped||b.add(this.quote)},toCSS:a.toCSS,eval:function(b){var c=this,d=this.value.replace(/`([^`]+)`/g,function(d,e){return new a.JavaScript(e,c.index,!0).eval(b).value}).replace(/@\{([\w-]+)\}/g,function(d,e){var f=new a.Variable("@"+e,c.index,c.currentFileInfo).eval(b,!0);return f instanceof a.Quoted?f.value:f.toCSS()});return new a.Quoted(this.quote+d+this.quote,d,this.escaped,this.index,this.currentFileInfo)},compare:function(a){if(!a.toCSS)return-1;var b=this.toCSS(),c=a.toCSS();return b===c?0:c>b?-1:1}}}(require("../tree")),function(a){a.Rule=function(b,c,d,e,f,g,h){this.name=b,this.value=c instanceof a.Value?c:new a.Value([c]),this.important=d?" "+d.trim():"",this.merge=e,this.index=f,this.currentFileInfo=g,this.inline=h||!1,this.variable="@"===b.charAt(0)},a.Rule.prototype={type:"Rule",accept:function(a){this.value=a.visit(this.value)},genCSS:function(a,b){b.add(this.name+(a.compress?":":": "),this.currentFileInfo,this.index);try{this.value.genCSS(a,b)}catch(c){throw c.index=this.index,c.filename=this.currentFileInfo.filename,c}b.add(this.important+(this.inline||a.lastRule&&a.compress?"":";"),this.currentFileInfo,this.index)},toCSS:a.toCSS,eval:function(b){var c=!1;"font"!==this.name||b.strictMath||(c=!0,b.strictMath=!0);try{return new a.Rule(this.name,this.value.eval(b),this.important,this.merge,this.index,this.currentFileInfo,this.inline)}finally{c&&(b.strictMath=!1)}},makeImportant:function(){return new a.Rule(this.name,this.value,"!important",this.merge,this.index,this.currentFileInfo,this.inline)}}}(require("../tree")),function(a){a.Ruleset=function(a,b,c){this.selectors=a,this.rules=b,this._lookups={},this.strictImports=c},a.Ruleset.prototype={type:"Ruleset",accept:function(a){if(this.paths)for(var b=0;bf.selectors[g].elements.length?Array.prototype.push.apply(e,f.find(new a.Selector(b.elements.slice(1)),c)):e.push(f);break}}),this._lookups[f]=e)},genCSS:function(b,c){var d,e,f,g,h,i=[],j=[],k=!0;b.tabLevel=b.tabLevel||0,this.root||b.tabLevel++;var l=b.compress?"":Array(b.tabLevel+1).join(" "),m=b.compress?"":Array(b.tabLevel).join(" ");for(d=0;d0&&this.mergeElementsOnToSelectors(r,i),f=0;f0&&(k[0].elements=k[0].elements.slice(0),k[0].elements.push(new a.Element(j.combinator,"",0,j.index,j.currentFileInfo))),s.push(k);else for(g=0;g0?(m=k.slice(0),q=m.pop(),o=d.createDerived(q.elements.slice(0)),p=!1):o=d.createDerived([]),l.length>1&&(n=n.concat(l.slice(1))),l.length>0&&(p=!1,o.elements.push(new a.Element(j.combinator,l[0].elements[0].value,j.index,j.currentFileInfo)),o.elements=o.elements.concat(l[0].elements.slice(1))),p||m.push(o),m=m.concat(n),s.push(m);i=s,r=[]}for(r.length>0&&this.mergeElementsOnToSelectors(r,i),e=0;e0&&b.push(i[e])}else if(c.length>0)for(e=0;e0?e[e.length-1]=e[e.length-1].createDerived(e[e.length-1].elements.concat(b)):e.push(new a.Selector(b))}}}(require("../tree")),function(a){a.Selector=function(a,b,c,d,e,f){this.elements=a,this.extendList=b||[],this.condition=c,this.currentFileInfo=e||{},this.isReferenced=f,c||(this.evaldCondition=!0)},a.Selector.prototype={type:"Selector",accept:function(a){this.elements=a.visit(this.elements),this.extendList=a.visit(this.extendList),this.condition=a.visit(this.condition)},createDerived:function(b,c,d){d=null!=d?d:this.evaldCondition;var e=new a.Selector(b,c||this.extendList,this.condition,this.index,this.currentFileInfo,this.isReferenced);return e.evaldCondition=d,e},match:function(a){var b,c,d,e,f=this.elements,g=f.length;if(b=a.elements.slice(a.elements.length&&"&"===a.elements[0].value?1:0),c=b.length,d=Math.min(g,c),0===c||c>g)return!1;for(e=0;d>e;e++)if(f[e].value!==b[e].value)return!1;return!0},eval:function(a){var b=this.condition&&this.condition.eval(a);return this.createDerived(this.elements.map(function(b){return b.eval(a)}),this.extendList.map(function(b){return b.eval(a)}),b)},genCSS:function(a,b){var c,d;if(a&&a.firstSelector||""!==this.elements[0].combinator.value||b.add(" ",this.currentFileInfo,this.index),!this._css)for(c=0;c0)&&e.splice(0,0,b);else{b.paths=b.paths.filter(function(b){var c;for(" "===b[0].elements[0].combinator.value&&(b[0].elements[0].combinator=new a.Combinator("")),c=0;c0&&b.accept(this._visitor),c.visitDeeper=!1,this._mergeRules(b.rules),this._removeDuplicateRules(b.rules),b.rules.length>0&&b.paths.length>0&&e.splice(0,0,b)}return 1===e.length?e[0]:e},_removeDuplicateRules:function(b){var c,d,e,f={};for(e=b.length-1;e>=0;e--)if(d=b[e],d instanceof a.Rule)if(f[d.name]){c=f[d.name],c instanceof a.Rule&&(c=f[d.name]=[f[d.name].toCSS(this._env)]);var g=d.toCSS(this._env);-1!==c.indexOf(g)?b.splice(e,1):c.push(g)}else f[d.name]=d},_mergeRules:function(b){for(var c,d,e,f={},g=0;g1&&(d=c[0],d.value=new a.Value(c.map(function(a){return a.value})))})}}}(require("./tree")),function(a){a.extendFinderVisitor=function(){this._visitor=new a.visitor(this),this.contexts=[],this.allExtendsStack=[[]]},a.extendFinderVisitor.prototype={run:function(a){return a=this._visitor.visit(a),a.allExtends=this.allExtendsStack[0],a},visitRule:function(a,b){b.visitDeeper=!1},visitMixinDefinition:function(a,b){b.visitDeeper=!1},visitRuleset:function(b){if(!b.root){var c,d,e,f,g=[];for(c=0;c100){var o="{unable to calculate}",p="{unable to calculate}";try{o=m[0].selfSelectors[0].toCSS(),p=m[0].selector.toCSS()}catch(q){}throw{message:"extend circular reference detected. One of the circular extends is currently:"+o+":extend("+p+")"}}return m.concat(n.doExtendChaining(m,c,d+1))}return m},inInheritanceChain:function(a,b){if(a===b)return!0;if(b.parents){if(this.inInheritanceChain(a,b.parents[0]))return!0;if(this.inInheritanceChain(a,b.parents[1]))return!0}return!1},visitRule:function(a,b){b.visitDeeper=!1},visitMixinDefinition:function(a,b){b.visitDeeper=!1},visitSelector:function(a,b){b.visitDeeper=!1},visitRuleset:function(a){if(!a.root){var b,c,d,e,f=this.allExtendsStack[this.allExtendsStack.length-1],g=[],h=this;for(d=0;d0&&k[i.matched].combinator.value!==g?i=null:i.matched++,i&&(i.finished=i.matched===k.length,i.finished&&!a.allowAfter&&(e+1j&&k>0&&(l[l.length-1].elements=l[l.length-1].elements.concat(c[j].elements.slice(k)),k=0,j++),i=f.elements.slice(k,h.index).concat([g]).concat(d.elements.slice(1)),j===h.pathIndex&&e>0?l[l.length-1].elements=l[l.length-1].elements.concat(i):(l=l.concat(c.slice(j,h.pathIndex)),l.push(new a.Selector(i))),j=h.endPathIndex,k=h.endPathElementIndex,k>=c[j].elements.length&&(k=0,j++);return j0&&(l[l.length-1].elements=l[l.length-1].elements.concat(c[j].elements.slice(k)),j++),l=l.concat(c.slice(j,c.length))},visitRulesetOut:function(){},visitMedia:function(a){var b=a.allExtends.concat(this.allExtendsStack[this.allExtendsStack.length-1]);b=b.concat(this.doExtendChaining(b,a.allExtends)),this.allExtendsStack.push(b)},visitMediaOut:function(){this.allExtendsStack.length=this.allExtendsStack.length-1},visitDirective:function(a){var b=a.allExtends.concat(this.allExtendsStack[this.allExtendsStack.length-1]);b=b.concat(this.doExtendChaining(b,a.allExtends)),this.allExtendsStack.push(b)},visitDirectiveOut:function(){this.allExtendsStack.length=this.allExtendsStack.length-1}}}(require("./tree")),function(a){a.sourceMapOutput=function(a){this._css=[],this._rootNode=a.rootNode,this._writeSourceMap=a.writeSourceMap,this._contentsMap=a.contentsMap,this._sourceMapFilename=a.sourceMapFilename,this._outputFilename=a.outputFilename,this._sourceMapBasepath=a.sourceMapBasepath,this._sourceMapRootpath=a.sourceMapRootpath,this._outputSourceFiles=a.outputSourceFiles,this._sourceMapGeneratorConstructor=a.sourceMapGenerator||require("source-map").SourceMapGenerator,this._sourceMapRootpath&&"/"!==this._sourceMapRootpath.charAt(this._sourceMapRootpath.length-1)&&(this._sourceMapRootpath+="/"),this._lineNumber=0,this._column=0},a.sourceMapOutput.prototype.normalizeFilename=function(a){return this._sourceMapBasepath&&0===a.indexOf(this._sourceMapBasepath)&&(a=a.substring(this._sourceMapBasepath.length),("\\"===a.charAt(0)||"/"===a.charAt(0))&&(a=a.substring(1))),(this._sourceMapRootpath||"")+a.replace(/\\/g,"/")},a.sourceMapOutput.prototype.add=function(a,b,c,d){if(a){var e,f,g,h,i;if(b){var j=this._contentsMap[b.filename].substring(0,c);f=j.split("\n"),h=f[f.length-1]}if(e=a.split("\n"),g=e[e.length-1],b)if(d)for(i=0;i0){var c,d=JSON.stringify(this._sourceMapGenerator.toJSON());this._sourceMapFilename&&(c=this.normalizeFilename(this._sourceMapFilename)),this._writeSourceMap?this._writeSourceMap(d):c="data:application/json,"+encodeURIComponent(d),c&&this._css.push("/*# sourceMappingURL="+c+" */")}return this._css.join("")}}(require("./tree"));var isFileProtocol=/^(file|chrome(-extension)?|resource|qrc|app):/.test(location.protocol);less.env=less.env||("127.0.0.1"==location.hostname||"0.0.0.0"==location.hostname||"localhost"==location.hostname||location.port.length>0||isFileProtocol?"development":"production");var logLevel={info:2,errors:1,none:0};if(less.logLevel="undefined"!=typeof less.logLevel?less.logLevel:logLevel.info,less.async=less.async||!1,less.fileAsync=less.fileAsync||!1,less.poll=less.poll||(isFileProtocol?1e3:1500),less.functions)for(var func in less.functions)less.tree.functions[func]=less.functions[func];var dumpLineNumbers=/!dumpLineNumbers:(comments|mediaquery|all)/.exec(location.hash);dumpLineNumbers&&(less.dumpLineNumbers=dumpLineNumbers[1]);var typePattern=/^text\/(x-)?less$/,cache=null,fileCache={};if(less.watch=function(){return less.watchMode||(less.env="development",initRunningMode()),this.watchMode=!0},less.unwatch=function(){return clearInterval(less.watchTimer),this.watchMode=!1},/!watch/.test(location.hash)&&less.watch(),"development"!=less.env)try{cache="undefined"==typeof window.localStorage?null:window.localStorage}catch(_){}var links=document.getElementsByTagName("link");less.sheets=[];for(var i=0;i #menu').length == 0){
+ $('#header').prepend('')
+ }
+
+ $('#header > #menu').prepend(' ');
+ $('#header > #menu').wrapInner('');
+
+ $('#content > .breadcrumb').wrapInner('');
+ $('#content .box .heading').wrapInner('');
+ $('#content .content').wrapInner('');
+ $('#container #content .box .content .layout ').append('');
+ $('#footer').html('© 2013 All rights reserved. Developed by Dreamvention ');
+ $('#footer').appendTo('#container #content .box .content ')
+
+ //Vtabs
+
+ $('.vtabs > a, .vtabs > span').wrap(' ');
+ $('.vtabs').wrapInner('');
+ //$('#container #content.login .box .content .layout .wrap').prepend(' ');
+
+ $("input:checkbox, input:radio").uniform();
+ $('#content').fadeIn(1000);
+
+ $('.tab-trigger').click(function(){
+ $('.vtabs a[href="'+$(this).attr('href')+'"], .htabs a[href="'+$(this).attr('href')+'"]').click();
+ return false
+ })
+
+ $('form thead input[type="checkbox"]').click(function(){
+ $.uniform.update("input:checkbox, input:radio");
+ })
+})
+
+function saveAndStay(){
+ $.ajax( {
+ type: "POST",
+ url: $('#form').attr( 'action' ) + '&save',
+ data: $('#form').serialize(),
+ beforeSend: function() {
+ $('#form').fadeTo('slow', 0.5);
+ },
+ complete: function() {
+ $('#form').fadeTo('slow', 1);
+ },
+ success: function( response ) {
+ console.log( response );
+ }
+ } );
+}
+
+function versionCheck(rout, placeholder, token){
+ $.ajax( {
+ type: "POST",
+ url: 'index.php?route=' + rout + '/version_check&token=' + token,
+ dataType: 'json',
+ beforeSend: function() {
+ $('#form').fadeTo('slow', 0.5);
+ },
+ complete: function() {
+ $('#form').fadeTo('slow', 1);
+ },
+ success: function( json ) {
+ console.log( json );
+ if(json['error']){
+ $(placeholder).html('' + json['error'] + '
')
+ }
+ if(json['attention']){
+ $html = '';
+ if(json['update']){
+ $.each(json['update'] , function(k, v) {
+ $html += 'Version: ' +k+ '
'+ v +'
';
+ });
+ }
+ $(placeholder).html('' + json['attention'] + $html + '
')
+ }
+ if(json['success']){
+ $(placeholder).html('' + json['success'] + '
')
+ }
+ }
+ })
+}
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/tinysort/jquery.tinysort.min.js b/admin/view/javascript/shopunity/tinysort/jquery.tinysort.min.js
new file mode 100755
index 0000000..586b663
--- /dev/null
+++ b/admin/view/javascript/shopunity/tinysort/jquery.tinysort.min.js
@@ -0,0 +1,10 @@
+/* TinySort 1.4.29
+* Copyright (c) 2008-2012 Ron Valstar http://www.sjeiti.com/
+*
+* Dual licensed under the MIT and GPL licenses:
+* http://www.opensource.org/licenses/mit-license.php
+* http://www.gnu.org/licenses/gpl.html
+*/
+(function(c){var e=!1,f=null,j=parseFloat,g=Math.min,i=/(-?\d+\.?\d*)$/g,h=[],d=[];c.tinysort={id:"TinySort",version:"1.4.29",copyright:"Copyright (c) 2008-2012 Ron Valstar",uri:"http://tinysort.sjeiti.com/",licensed:{MIT:"http://www.opensource.org/licenses/mit-license.php",GPL:"http://www.gnu.org/licenses/gpl.html"},plugin:function(k,l){h.push(k);d.push(l)},defaults:{order:"asc",attr:f,data:f,useVal:e,place:"start",returns:e,cases:e,forceStrings:e,sortFunction:f}};c.fn.extend({tinysort:function(o,k){if(o&&typeof(o)!="string"){k=o;o=f}var p=c.extend({},c.tinysort.defaults,k),u,D=this,z=c(this).length,E={},r=!(!o||o==""),s=!(p.attr===f||p.attr==""),y=p.data!==f,l=r&&o[0]==":",m=l?D.filter(o):D,t=p.sortFunction,x=p.order=="asc"?1:-1,n=[];c.each(h,function(G,H){H.call(H,p)});if(!t){t=p.order=="rand"?function(){return Math.random()<0.5?1:-1}:function(O,M){var N=e,J=!p.cases?a(O.s):O.s,I=!p.cases?a(M.s):M.s;if(!p.forceStrings){var H=J&&J.match(i),P=I&&I.match(i);if(H&&P){var L=J.substr(0,J.length-H[0].length),K=I.substr(0,I.length-P[0].length);if(L==K){N=!e;J=j(H[0]);I=j(P[0])}}}var G=x*(JI?1:0));c.each(d,function(Q,R){G=R.call(R,N,J,I,G)});return G}}D.each(function(I,J){var K=c(J),G=r?(l?m.filter(J):K.find(o)):K,L=y?""+G.data(p.data):(s?G.attr(p.attr):(p.useVal?G.val():G.text())),H=K.parent();if(!E[H]){E[H]={s:[],n:[]}}if(G.length>0){E[H].s.push({s:L,e:K,n:I})}else{E[H].n.push({e:K,n:I})}});for(u in E){E[u].s.sort(t)}for(u in E){var A=E[u],C=[],F=z,w=[0,0],B;switch(p.place){case"first":c.each(A.s,function(G,H){F=g(F,H.n)});break;case"org":c.each(A.s,function(G,H){C.push(H.n)});break;case"end":F=A.n.length;break;default:F=0}for(B=0;B=F&&B
+
+
+
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/tooltip/tooltip.js b/admin/view/javascript/shopunity/tooltip/tooltip.js
new file mode 100755
index 0000000..526ff44
--- /dev/null
+++ b/admin/view/javascript/shopunity/tooltip/tooltip.js
@@ -0,0 +1,71 @@
+var dTooltip = {
+
+ init : function() {
+
+ jQuery(document).on('mouseover', '[rel="tooltip"]', function() {
+
+ dTooltip.open(this);
+ });
+
+ jQuery(document).on('mouseout', '[rel="tooltip"]', function() {
+ dTooltip.close();
+ });
+ },
+
+ open : function(el) {
+
+ // Create tooltip
+ jQuery('body').prepend( jQuery('', { 'class' : 'tooltip'})
+ .append( jQuery('
', { 'class' : 'inner' }))
+ .append( jQuery('
') )
+ );
+
+ // Get tooltip
+ var tooltip = jQuery('.tooltip');
+ // Set tooltip text
+ tooltip.find('.inner').text( jQuery(el).attr('data-help'));
+
+ if( $( window ).width() < tooltip.outerWidth() * 1.5 )
+ tooltip.css( 'max-width', $( window ).width() / 2 );
+ else
+ tooltip.css( 'max-width', 340 );
+
+ var pos_left = jQuery(el).offset().left + ( jQuery(el).outerWidth() / 2 ) - ( tooltip.outerWidth() / 2 ),
+ pos_top = jQuery(el).offset().top - tooltip.outerHeight() - 10;
+
+ if( pos_left < 0 )
+ {
+ pos_left = jQuery(el).offset().left + jQuery(el).outerWidth() / 2 - 20;
+ tooltip.addClass( 'left' );
+ }
+ else
+ tooltip.removeClass( 'left' );
+
+ if( pos_left + tooltip.outerWidth() > $( window ).width() )
+ {
+ pos_left = jQuery(el).offset().left - tooltip.outerWidth() + jQuery(el).outerWidth() / 2 + 20;
+ tooltip.addClass( 'right' );
+ }
+ else
+ tooltip.removeClass( 'right' );
+
+ if( pos_top < 0 )
+ {
+ var pos_top = jQuery(el).offset().top + jQuery(el).outerHeight();
+ tooltip.addClass( 'top' );
+ }
+ else
+ tooltip.removeClass( 'top' );
+
+ tooltip.css( { left: pos_left, top: pos_top } )
+ .animate( { top: '+=0', opacity: 1 }, 50 );
+
+
+ },
+
+ close : function() {
+ jQuery('.tooltip').remove();
+
+ }
+};
+dTooltip.init();
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/uniform/_notes/dwsync.xml b/admin/view/javascript/shopunity/uniform/_notes/dwsync.xml
new file mode 100755
index 0000000..7c732a5
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/_notes/dwsync.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/uniform/css/_notes/dwsync.xml b/admin/view/javascript/shopunity/uniform/css/_notes/dwsync.xml
new file mode 100755
index 0000000..4db76a7
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/css/_notes/dwsync.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/uniform/css/uniform.default.css b/admin/view/javascript/shopunity/uniform/css/uniform.default.css
new file mode 100755
index 0000000..8833a50
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/css/uniform.default.css
@@ -0,0 +1,610 @@
+/*
+
+Uniform Theme: Uniform Default
+Version: 1.6
+By: Josh Pyles
+License: MIT License
+---
+For use with the Uniform plugin:
+http://pixelmatrixdesign.com/uniform/
+---
+Generated by Uniform Theme Generator:
+http://pixelmatrixdesign.com/uniform/themer.html
+
+*/
+
+/* Global Declaration */
+
+div.selector,
+div.selector span,
+div.checker span,
+div.radio span,
+div.uploader,
+div.uploader span.action/*,
+div.button,
+div.button span*/ {
+ background-image: url(../images/sprite.png);
+ background-repeat: no-repeat;
+ -webkit-font-smoothing: antialiased;
+}
+
+.selector,
+.radio,
+.checker,
+.uploader,
+/*.button, */
+.selector *,
+.radio *,
+.checker *,
+.uploader */*,
+.button **/{
+ margin: 0;
+ padding: 0;
+}
+
+/* INPUT & TEXTAREA */
+
+input.text,
+input.email,
+input.password,
+textarea.uniform {
+ font-size: 12px;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-weight: normal;
+ padding: 3px;
+ color: #777;
+ background: url('../images/bg-input-focus.png') repeat-x 0px 0px;
+ background: url('../images/bg-input.png') repeat-x 0px 0px;
+ border-top: solid 1px #aaa;
+ border-left: solid 1px #aaa;
+ border-bottom: solid 1px #ccc;
+ border-right: solid 1px #ccc;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ outline: 0;
+}
+
+input.text:focus,
+input.email:focus,
+input.password:focus,
+textarea.uniform:focus {
+ -webkit-box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ -moz-box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ border-color: #999;
+ background: url('../images/bg-input-focus.png') repeat-x 0px 0px;
+}
+
+/* SPRITES */
+
+/* Select */
+
+div.selector {
+ background-position: -483px -130px;
+ line-height: 26px;
+ height: 26px;
+}
+
+div.selector span {
+ background-position: right 0px;
+ height: 26px;
+ line-height: 26px;
+}
+
+div.selector select {
+ /* change these to adjust positioning of select element */
+ top: 0px;
+ left: 0px;
+}
+
+div.selector:active,
+div.selector.active {
+ background-position: -483px -156px;
+}
+
+div.selector:active span,
+div.selector.active span {
+ background-position: right -26px;
+}
+
+div.selector.focus, div.selector.hover, div.selector:hover {
+ background-position: -483px -182px;
+}
+
+div.selector.focus span, div.selector.hover span, div.selector:hover span {
+ background-position: right -52px;
+}
+
+div.selector.focus:active,
+div.selector.focus.active,
+div.selector:hover:active,
+div.selector.active:hover {
+ background-position: -483px -208px;
+}
+
+div.selector.focus:active span,
+div.selector:hover:active span,
+div.selector.active:hover span,
+div.selector.focus.active span {
+ background-position: right -78px;
+}
+
+div.selector.disabled {
+ background-position: -483px -234px;
+}
+
+div.selector.disabled span {
+ background-position: right -104px;
+}
+
+/* Checkbox */
+
+div.checker {
+ width: 19px;
+ height: 19px;
+}
+
+div.checker input {
+ width: 19px;
+ height: 19px;
+}
+
+div.checker span {
+ background-position: 0px -260px;
+ height: 19px;
+ width: 19px;
+}
+
+div.checker:active span,
+div.checker.active span {
+ background-position: -19px -260px;
+}
+
+div.checker.focus span,
+div.checker:hover span {
+ background-position: -38px -260px;
+}
+
+div.checker.focus:active span,
+div.checker:active:hover span,
+div.checker.active:hover span,
+div.checker.focus.active span {
+ background-position: -57px -260px;
+}
+
+div.checker span.checked {
+ background-position: -76px -260px;
+}
+
+div.checker:active span.checked,
+div.checker.active span.checked {
+ background-position: -95px -260px;
+}
+
+div.checker.focus span.checked,
+div.checker:hover span.checked {
+ background-position: -114px -260px;
+}
+
+div.checker.focus:active span.checked,
+div.checker:hover:active span.checked,
+div.checker.active:hover span.checked,
+div.checker.active.focus span.checked {
+ background-position: -133px -260px;
+}
+
+div.checker.disabled span,
+div.checker.disabled:active span,
+div.checker.disabled.active span {
+ background-position: -152px -260px;
+}
+
+div.checker.disabled span.checked,
+div.checker.disabled:active span.checked,
+div.checker.disabled.active span.checked {
+ background-position: -171px -260px;
+}
+
+/* Radio */
+
+div.radio {
+ width: 18px;
+ height: 18px;
+}
+
+div.radio input {
+ width: 18px;
+ height: 18px;
+}
+
+div.radio span {
+ height: 18px;
+ width: 18px;
+ background-position: 0px -279px;
+}
+
+div.radio:active span,
+div.radio.active span {
+ background-position: -18px -279px;
+}
+
+div.radio.focus span,
+div.radio:hover span {
+ background-position: -36px -279px;
+}
+
+div.radio.focus:active span,
+div.radio:active:hover span,
+div.radio.active:hover span,
+div.radio.active.focus span {
+ background-position: -54px -279px;
+}
+
+div.radio span.checked {
+ background-position: -72px -279px;
+}
+
+div.radio:active span.checked,
+div.radio.active span.checked {
+ background-position: -90px -279px;
+}
+
+div.radio.focus span.checked, div.radio:hover span.checked {
+ background-position: -108px -279px;
+}
+
+div.radio.focus:active span.checked,
+div.radio:hover:active span.checked,
+div.radio.focus.active span.checked,
+div.radio.active:hover span.checked {
+ background-position: -126px -279px;
+}
+
+div.radio.disabled span,
+div.radio.disabled:active span,
+div.radio.disabled.active span {
+ background-position: -144px -279px;
+}
+
+div.radio.disabled span.checked,
+div.radio.disabled:active span.checked,
+div.radio.disabled.active span.checked {
+ background-position: -162px -279px;
+}
+
+/* Uploader */
+
+div.uploader {
+ background-position: 0px -297px;
+ height: 28px;
+}
+
+div.uploader span.action {
+ background-position: right -409px;
+ height: 24px;
+ line-height: 24px;
+}
+
+div.uploader span.filename {
+ height: 24px;
+ /* change this line to adjust positioning of filename area */
+ margin: 2px 0px 2px 2px;
+ line-height: 24px;
+}
+
+div.uploader.focus,
+div.uploader.hover,
+div.uploader:hover {
+ background-position: 0px -353px;
+}
+
+div.uploader.focus span.action,
+div.uploader.hover span.action,
+div.uploader:hover span.action {
+ background-position: right -437px;
+}
+
+div.uploader.active span.action,
+div.uploader:active span.action {
+ background-position: right -465px;
+}
+
+div.uploader.focus.active span.action,
+div.uploader:focus.active span.action,
+div.uploader.focus:active span.action,
+div.uploader:focus:active span.action {
+ background-position: right -493px;
+}
+
+div.uploader.disabled {
+ background-position: 0px -325px;
+}
+
+div.uploader.disabled span.action {
+ background-position: right -381px;
+}
+/*
+div.button {
+ background-position: 0px -523px;
+}
+
+div.button span {
+ background-position: right -643px;
+}
+
+div.button.focus,
+div.button:focus,
+div.button:hover,
+div.button.hover {
+ background-position: 0px -553px;
+}
+
+div.button.focus span,
+div.button:focus span,
+div.button:hover span,
+div.button.hover span {
+ background-position: right -673px;
+}
+
+div.button.active,
+div.button:active {
+ background-position: 0px -583px;
+}
+
+div.button.active span,
+div.button:active span {
+ background-position: right -703px;
+ color: #555;
+}
+
+div.button.disabled,
+div.button:disabled {
+ background-position: 0px -613px;
+}
+
+div.button.disabled span,
+div.button:disabled span {
+ background-position: right -733px;
+ color: #bbb;
+ cursor: default;
+}*/
+
+/* PRESENTATION */
+
+/* Button */
+
+/*div.button {
+ height: 30px;
+}
+
+div.button span {
+ margin-left: 13px;
+ height: 22px;
+ padding-top: 8px;
+ font-weight: bold;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-size: 12px;
+ letter-spacing: 1px;
+ text-transform: uppercase;
+ padding-left: 2px;
+ padding-right: 15px;
+}
+
+/* Select */
+div.selector {
+ width: 190px;
+ font-size: 12px;
+}
+
+div.selector select {
+ min-width: 190px;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-size: 12px;
+ border: solid 1px #fff;
+}
+
+div.selector span {
+ padding: 0px 25px 0px 2px;
+ cursor: pointer;
+}
+
+div.selector span {
+ color: #666;
+ width: 158px;
+ text-shadow: 0 1px 0 #fff;
+}
+
+div.selector.disabled span {
+ color: #bbb;
+}*/
+
+/* Checker */
+div.checker {
+ margin-right: 5px;
+}
+
+/* Radio */
+div.radio {
+ margin-right: 3px;
+}
+
+/* Uploader */
+div.uploader {
+ width: 190px;
+ cursor: pointer;
+}
+
+div.uploader span.action {
+ width: 85px;
+ text-align: center;
+ text-shadow: #fff 0px 1px 0px;
+ background-color: #fff;
+ font-size: 11px;
+ font-weight: bold;
+}
+
+div.uploader span.filename {
+ color: #777;
+ width: 82px;
+ border-right: solid 1px #bbb;
+ font-size: 11px;
+}
+
+div.uploader input {
+ width: 190px;
+}
+
+div.uploader.disabled span.action {
+ color: #aaa;
+}
+
+div.uploader.disabled span.filename {
+ border-color: #ddd;
+ color: #aaa;
+}
+/*
+
+CORE FUNCTIONALITY
+
+Not advised to edit stuff below this line
+-----------------------------------------------------
+*/
+
+.selector,
+.checker,
+/*.button, */
+.radio,
+.uploader {
+ display: -moz-inline-box;
+ display: inline-block;
+ vertical-align: text-bottom;
+ zoom: 1;
+ *display: inline;
+}
+
+.selector select:focus, .radio input:focus, .checker input:focus, .uploader input:focus {
+ outline: 0;
+}
+
+/* Button */
+/*
+div.button a,
+div.button button,
+div.button input {
+ position: absolute;
+}
+
+div.button {
+ cursor: pointer;
+ position: relative;
+}
+
+div.button span {
+ display: -moz-inline-box;
+ display: inline-block;
+ line-height: 1;
+ text-align: center;
+}
+*/
+/* Select */
+
+div.selector {
+ position: relative;
+ padding-left: 10px;
+ overflow: hidden;
+}
+
+div.selector span {
+ display: block;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
+
+div.selector select {
+ position: absolute;
+ opacity: 0;
+ filter: alpha(opacity:0);
+ height: 25px;
+ border: none;
+ background: none;
+}
+
+/* Checker */
+
+div.checker {
+ position: relative;
+}
+
+div.checker span {
+ display: -moz-inline-box;
+ display: inline-block;
+ text-align: center;
+}
+
+div.checker input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ display: inline-block;
+ background: none;
+}
+
+/* Radio */
+
+div.radio {
+ position: relative;
+}
+
+div.radio span {
+ display: -moz-inline-box;
+ display: inline-block;
+ text-align: center;
+}
+
+div.radio input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ text-align: center;
+ display: inline-block;
+ background: none;
+}
+
+/* Uploader */
+
+div.uploader {
+ position: relative;
+ overflow: hidden;
+ cursor: default;
+}
+
+div.uploader span.action {
+ float: left;
+ display: inline;
+ padding: 2px 0px;
+ overflow: hidden;
+ cursor: pointer;
+}
+
+div.uploader span.filename {
+ padding: 0px 10px;
+ float: left;
+ display: block;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ cursor: default;
+}
+
+div.uploader input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ float: right;
+ height: 25px;
+ border: none;
+ cursor: default;
+}
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/uniform/images/_notes/dwsync.xml b/admin/view/javascript/shopunity/uniform/images/_notes/dwsync.xml
new file mode 100755
index 0000000..6e2f960
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/images/_notes/dwsync.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/admin/view/javascript/shopunity/uniform/images/sprite.png b/admin/view/javascript/shopunity/uniform/images/sprite.png
new file mode 100755
index 0000000..c8b320b
Binary files /dev/null and b/admin/view/javascript/shopunity/uniform/images/sprite.png differ
diff --git a/admin/view/javascript/shopunity/uniform/jquery.uniform.js b/admin/view/javascript/shopunity/uniform/jquery.uniform.js
new file mode 100755
index 0000000..e80abb3
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/jquery.uniform.js
@@ -0,0 +1,672 @@
+/*
+
+Uniform v1.7.5
+Copyright © 2009 Josh Pyles / Pixelmatrix Design LLC
+http://pixelmatrixdesign.com
+
+Requires jQuery 1.4 or newer
+
+Much thanks to Thomas Reynolds and Buck Wilson for their help and advice on this
+
+Disabling text selection is made possible by Mathias Bynens
+and his noSelect plugin.
+
+Also, thanks to David Kaneda and Eugene Bond for their contributions to the plugin
+
+License:
+MIT License - http://www.opensource.org/licenses/mit-license.php
+
+Enjoy!
+
+*/
+
+(function($) {
+ $.uniform = {
+ options: {
+ selectClass: 'selector',
+ radioClass: 'radio',
+ checkboxClass: 'checker',
+ fileClass: 'uploader',
+ filenameClass: 'filename',
+ fileBtnClass: 'action',
+ fileDefaultText: 'No file selected',
+ fileBtnText: 'Choose File',
+ checkedClass: 'checked',
+ focusClass: 'focus',
+ disabledClass: 'disabled',
+ buttonClass: 'button',
+ activeClass: 'active',
+ hoverClass: 'hover',
+ useID: true,
+ idPrefix: 'uniform',
+ resetSelector: false,
+ autoHide: true
+ },
+ elements: []
+ };
+
+ if($.browser.msie && $.browser.version < 7){
+ $.support.selectOpacity = false;
+ }else{
+ $.support.selectOpacity = true;
+ }
+
+ $.fn.uniform = function(options) {
+
+ options = $.extend($.uniform.options, options);
+
+ var el = this;
+ //code for specifying a reset button
+ if(options.resetSelector != false){
+ $(options.resetSelector).mouseup(function(){
+ function resetThis(){
+ $.uniform.update(el);
+ }
+ setTimeout(resetThis, 10);
+ });
+ }
+
+ function doInput(elem){
+ $el = $(elem);
+ $el.addClass($el.attr("type"));
+ storeElement(elem);
+ }
+
+ function doTextarea(elem){
+ $(elem).addClass("uniform");
+ storeElement(elem);
+ }
+
+ function doButton(elem){
+ var $el = $(elem);
+
+ var divTag = $(""),
+ spanTag = $("
");
+
+ divTag.addClass(options.buttonClass);
+
+ if(options.useID && $el.attr("id") != "") divTag.attr("id", options.idPrefix+"-"+$el.attr("id"));
+
+ var btnText;
+
+ if($el.is("a") || $el.is("button")){
+ btnText = $el.text();
+ }else if($el.is(":submit") || $el.is(":reset") || $el.is("input[type=button]")){
+ btnText = $el.attr("value");
+ }
+
+ btnText = btnText == "" ? $el.is(":reset") ? "Reset" : "Submit" : btnText;
+
+ spanTag.html(btnText);
+
+ $el.css("opacity", 0);
+ $el.wrap(divTag);
+ $el.wrap(spanTag);
+
+ //redefine variables
+ divTag = $el.closest("div");
+ spanTag = $el.closest("span");
+
+ if($el.is(":disabled")) divTag.addClass(options.disabledClass);
+
+ divTag.bind({
+ "mouseenter.uniform": function(){
+ divTag.addClass(options.hoverClass);
+ },
+ "mouseleave.uniform": function(){
+ divTag.removeClass(options.hoverClass);
+ divTag.removeClass(options.activeClass);
+ },
+ "mousedown.uniform touchbegin.uniform": function(){
+ divTag.addClass(options.activeClass);
+ },
+ "mouseup.uniform touchend.uniform": function(){
+ divTag.removeClass(options.activeClass);
+ },
+ "click.uniform touchend.uniform": function(e){
+ if($(e.target).is("span") || $(e.target).is("div")){
+ if(elem[0].dispatchEvent){
+ var ev = document.createEvent('MouseEvents');
+ ev.initEvent( 'click', true, true );
+ elem[0].dispatchEvent(ev);
+ }else{
+ elem[0].click();
+ }
+ }
+ }
+ });
+
+ elem.bind({
+ "focus.uniform": function(){
+ divTag.addClass(options.focusClass);
+ },
+ "blur.uniform": function(){
+ divTag.removeClass(options.focusClass);
+ }
+ });
+
+ $.uniform.noSelect(divTag);
+ storeElement(elem);
+
+ }
+
+ function doSelect(elem){
+ var $el = $(elem);
+
+ var divTag = $('
'),
+ spanTag = $(' ');
+
+ if(!$el.css("display") == "none" && options.autoHide){
+ divTag.hide();
+ }
+
+ divTag.addClass(options.selectClass);
+
+ if(options.useID && elem.attr("id") != ""){
+ divTag.attr("id", options.idPrefix+"-"+elem.attr("id"));
+ }
+
+ var selected = elem.find(":selected:first");
+ if(selected.length == 0){
+ selected = elem.find("option:first");
+ }
+ spanTag.html(selected.text());
+
+ elem.css('opacity', 0);
+ elem.wrap(divTag);
+ elem.before(spanTag);
+
+ //redefine variables
+ divTag = elem.parent("div");
+ spanTag = elem.siblings("span");
+
+ elem.bind({
+ "change.uniform": function() {
+ spanTag.text(elem.find(":selected").text());
+ divTag.removeClass(options.activeClass);
+ },
+ "focus.uniform": function() {
+ divTag.addClass(options.focusClass);
+ },
+ "blur.uniform": function() {
+ divTag.removeClass(options.focusClass);
+ divTag.removeClass(options.activeClass);
+ },
+ "mousedown.uniform touchbegin.uniform": function() {
+ divTag.addClass(options.activeClass);
+ },
+ "mouseup.uniform touchend.uniform": function() {
+ divTag.removeClass(options.activeClass);
+ },
+ "click.uniform touchend.uniform": function(){
+ divTag.removeClass(options.activeClass);
+ },
+ "mouseenter.uniform": function() {
+ divTag.addClass(options.hoverClass);
+ },
+ "mouseleave.uniform": function() {
+ divTag.removeClass(options.hoverClass);
+ divTag.removeClass(options.activeClass);
+ },
+ "keyup.uniform": function(){
+ spanTag.text(elem.find(":selected").text());
+ }
+ });
+
+ //handle disabled state
+ if($(elem).attr("disabled")){
+ //box is checked by default, check our box
+ divTag.addClass(options.disabledClass);
+ }
+ $.uniform.noSelect(spanTag);
+
+ storeElement(elem);
+
+ }
+
+ function doCheckbox(elem){
+ var $el = $(elem);
+
+ var divTag = $('
'),
+ spanTag = $(' ');
+
+ if(!$el.css("display") == "none" && options.autoHide){
+ divTag.hide();
+ }
+
+ divTag.addClass(options.checkboxClass);
+
+ //assign the id of the element
+ if(options.useID && elem.attr("id") != ""){
+ divTag.attr("id", options.idPrefix+"-"+elem.attr("id"));
+ }
+
+ //wrap with the proper elements
+ $(elem).wrap(divTag);
+ $(elem).wrap(spanTag);
+
+ //redefine variables
+ spanTag = elem.parent();
+ divTag = spanTag.parent();
+
+ //hide normal input and add focus classes
+ $(elem)
+ .css("opacity", 0)
+ .bind({
+ "focus.uniform": function(){
+ divTag.addClass(options.focusClass);
+ },
+ "blur.uniform": function(){
+ divTag.removeClass(options.focusClass);
+ },
+ "click.uniform touchend.uniform": function(){
+ if(!$(elem).attr("checked")){
+ //box was just unchecked, uncheck span
+ spanTag.removeClass(options.checkedClass);
+ }else{
+ //box was just checked, check span.
+ spanTag.addClass(options.checkedClass);
+ }
+ },
+ "mousedown.uniform touchbegin.uniform": function() {
+ divTag.addClass(options.activeClass);
+ },
+ "mouseup.uniform touchend.uniform": function() {
+ divTag.removeClass(options.activeClass);
+ },
+ "mouseenter.uniform": function() {
+ divTag.addClass(options.hoverClass);
+ },
+ "mouseleave.uniform": function() {
+ divTag.removeClass(options.hoverClass);
+ divTag.removeClass(options.activeClass);
+ }
+ });
+
+ //handle defaults
+ if($(elem).attr("checked")){
+ //box is checked by default, check our box
+ spanTag.addClass(options.checkedClass);
+ }
+
+ //handle disabled state
+ if($(elem).attr("disabled")){
+ //box is checked by default, check our box
+ divTag.addClass(options.disabledClass);
+ }
+
+ storeElement(elem);
+ }
+
+ function doRadio(elem){
+ var $el = $(elem);
+
+ var divTag = $('
'),
+ spanTag = $(' ');
+
+ if(!$el.css("display") == "none" && options.autoHide){
+ divTag.hide();
+ }
+
+ divTag.addClass(options.radioClass);
+
+ if(options.useID && elem.attr("id") != ""){
+ divTag.attr("id", options.idPrefix+"-"+elem.attr("id"));
+ }
+
+ //wrap with the proper elements
+ $(elem).wrap(divTag);
+ $(elem).wrap(spanTag);
+
+ //redefine variables
+ spanTag = elem.parent();
+ divTag = spanTag.parent();
+
+ //hide normal input and add focus classes
+ $(elem)
+ .css("opacity", 0)
+ .bind({
+ "focus.uniform": function(){
+ divTag.addClass(options.focusClass);
+ },
+ "blur.uniform": function(){
+ divTag.removeClass(options.focusClass);
+ },
+ "click.uniform touchend.uniform": function(){
+ if(!$(elem).attr("checked")){
+ //box was just unchecked, uncheck span
+ spanTag.removeClass(options.checkedClass);
+ }else{
+ //box was just checked, check span
+ var classes = options.radioClass.split(" ")[0];
+ $("." + classes + " span." + options.checkedClass + ":has([name='" + $(elem).attr('name') + "'])").removeClass(options.checkedClass);
+ spanTag.addClass(options.checkedClass);
+ }
+ },
+ "mousedown.uniform touchend.uniform": function() {
+ if(!$(elem).is(":disabled")){
+ divTag.addClass(options.activeClass);
+ }
+ },
+ "mouseup.uniform touchbegin.uniform": function() {
+ divTag.removeClass(options.activeClass);
+ },
+ "mouseenter.uniform touchend.uniform": function() {
+ divTag.addClass(options.hoverClass);
+ },
+ "mouseleave.uniform": function() {
+ divTag.removeClass(options.hoverClass);
+ divTag.removeClass(options.activeClass);
+ }
+ });
+
+ //handle defaults
+ if($(elem).attr("checked")){
+ //box is checked by default, check span
+ spanTag.addClass(options.checkedClass);
+ }
+ //handle disabled state
+ if($(elem).attr("disabled")){
+ //box is checked by default, check our box
+ divTag.addClass(options.disabledClass);
+ }
+
+ storeElement(elem);
+
+ }
+
+ function doFile(elem){
+ //sanitize input
+ var $el = $(elem);
+
+ var divTag = $('
'),
+ filenameTag = $(''+options.fileDefaultText+' '),
+ btnTag = $(''+options.fileBtnText+' ');
+
+ if(!$el.css("display") == "none" && options.autoHide){
+ divTag.hide();
+ }
+
+ divTag.addClass(options.fileClass);
+ filenameTag.addClass(options.filenameClass);
+ btnTag.addClass(options.fileBtnClass);
+
+ if(options.useID && $el.attr("id") != ""){
+ divTag.attr("id", options.idPrefix+"-"+$el.attr("id"));
+ }
+
+ //wrap with the proper elements
+ $el.wrap(divTag);
+ $el.after(btnTag);
+ $el.after(filenameTag);
+
+ //redefine variables
+ divTag = $el.closest("div");
+ filenameTag = $el.siblings("."+options.filenameClass);
+ btnTag = $el.siblings("."+options.fileBtnClass);
+
+ //set the size
+ if(!$el.attr("size")){
+ var divWidth = divTag.width();
+ //$el.css("width", divWidth);
+ $el.attr("size", divWidth/10);
+ }
+
+ //actions
+ var setFilename = function()
+ {
+ var filename = $el.val();
+ if (filename === '')
+ {
+ filename = options.fileDefaultText;
+ }
+ else
+ {
+ filename = filename.split(/[\/\\]+/);
+ filename = filename[(filename.length-1)];
+ }
+ filenameTag.text(filename);
+ };
+
+ // Account for input saved across refreshes
+ setFilename();
+
+ $el
+ .css("opacity", 0)
+ .bind({
+ "focus.uniform": function(){
+ divTag.addClass(options.focusClass);
+ },
+ "blur.uniform": function(){
+ divTag.removeClass(options.focusClass);
+ },
+ "mousedown.uniform": function() {
+ if(!$(elem).is(":disabled")){
+ divTag.addClass(options.activeClass);
+ }
+ },
+ "mouseup.uniform": function() {
+ divTag.removeClass(options.activeClass);
+ },
+ "mouseenter.uniform": function() {
+ divTag.addClass(options.hoverClass);
+ },
+ "mouseleave.uniform": function() {
+ divTag.removeClass(options.hoverClass);
+ divTag.removeClass(options.activeClass);
+ }
+ });
+
+ // IE7 doesn't fire onChange until blur or second fire.
+ if ($.browser.msie){
+ // IE considers browser chrome blocking I/O, so it
+ // suspends tiemouts until after the file has been selected.
+ $el.bind('click.uniform.ie7', function() {
+ setTimeout(setFilename, 0);
+ });
+ }else{
+ // All other browsers behave properly
+ $el.bind('change.uniform', setFilename);
+ }
+
+ //handle defaults
+ if($el.attr("disabled")){
+ //box is checked by default, check our box
+ divTag.addClass(options.disabledClass);
+ }
+
+ $.uniform.noSelect(filenameTag);
+ $.uniform.noSelect(btnTag);
+
+ storeElement(elem);
+
+ }
+
+ $.uniform.restore = function(elem){
+ if(elem == undefined){
+ elem = $($.uniform.elements);
+ }
+
+ $(elem).each(function(){
+ if($(this).is(":checkbox")){
+ //unwrap from span and div
+ $(this).unwrap().unwrap();
+ }else if($(this).is("select")){
+ //remove sibling span
+ $(this).siblings("span").remove();
+ //unwrap parent div
+ $(this).unwrap();
+ }else if($(this).is(":radio")){
+ //unwrap from span and div
+ $(this).unwrap().unwrap();
+ }else if($(this).is(":file")){
+ //remove sibling spans
+ $(this).siblings("span").remove();
+ //unwrap parent div
+ $(this).unwrap();
+ }else if($(this).is("button, :submit, :reset, a, input[type='button']")){
+ //unwrap from span and div
+ $(this).unwrap().unwrap();
+ }
+
+ //unbind events
+ $(this).unbind(".uniform");
+
+ //reset inline style
+ $(this).css("opacity", "1");
+
+ //remove item from list of uniformed elements
+ var index = $.inArray($(elem), $.uniform.elements);
+ $.uniform.elements.splice(index, 1);
+ });
+ };
+
+ function storeElement(elem){
+ //store this element in our global array
+ elem = $(elem).get();
+ if(elem.length > 1){
+ $.each(elem, function(i, val){
+ $.uniform.elements.push(val);
+ });
+ }else{
+ $.uniform.elements.push(elem);
+ }
+ }
+
+ //noSelect v1.0
+ $.uniform.noSelect = function(elem) {
+ function f() {
+ return false;
+ };
+ $(elem).each(function() {
+ this.onselectstart = this.ondragstart = f; // Webkit & IE
+ $(this)
+ .mousedown(f) // Webkit & Opera
+ .css({ MozUserSelect: 'none' }); // Firefox
+ });
+ };
+
+ $.uniform.update = function(elem){
+ if(elem == undefined){
+ elem = $($.uniform.elements);
+ }
+ //sanitize input
+ elem = $(elem);
+
+ elem.each(function(){
+ //do to each item in the selector
+ //function to reset all classes
+ var $e = $(this);
+
+ if($e.is("select")){
+ //element is a select
+ var spanTag = $e.siblings("span");
+ var divTag = $e.parent("div");
+
+ divTag.removeClass(options.hoverClass+" "+options.focusClass+" "+options.activeClass);
+
+ //reset current selected text
+ spanTag.html($e.find(":selected").html());
+
+ if($e.is(":disabled")){
+ divTag.addClass(options.disabledClass);
+ }else{
+ divTag.removeClass(options.disabledClass);
+ }
+
+ }else if($e.is(":checkbox")){
+ //element is a checkbox
+ var spanTag = $e.closest("span");
+ var divTag = $e.closest("div");
+
+ divTag.removeClass(options.hoverClass+" "+options.focusClass+" "+options.activeClass);
+ spanTag.removeClass(options.checkedClass);
+
+ if($e.is(":checked")){
+ spanTag.addClass(options.checkedClass);
+ }
+ if($e.is(":disabled")){
+ divTag.addClass(options.disabledClass);
+ }else{
+ divTag.removeClass(options.disabledClass);
+ }
+
+ }else if($e.is(":radio")){
+ //element is a radio
+ var spanTag = $e.closest("span");
+ var divTag = $e.closest("div");
+
+ divTag.removeClass(options.hoverClass+" "+options.focusClass+" "+options.activeClass);
+ spanTag.removeClass(options.checkedClass);
+
+ if($e.is(":checked")){
+ spanTag.addClass(options.checkedClass);
+ }
+
+ if($e.is(":disabled")){
+ divTag.addClass(options.disabledClass);
+ }else{
+ divTag.removeClass(options.disabledClass);
+ }
+ }else if($e.is(":file")){
+ var divTag = $e.parent("div");
+ var filenameTag = $e.siblings(options.filenameClass);
+ btnTag = $e.siblings(options.fileBtnClass);
+
+ divTag.removeClass(options.hoverClass+" "+options.focusClass+" "+options.activeClass);
+
+ filenameTag.text($e.val());
+
+ if($e.is(":disabled")){
+ divTag.addClass(options.disabledClass);
+ }else{
+ divTag.removeClass(options.disabledClass);
+ }
+ }else if($e.is(":submit") || $e.is(":reset") || $e.is("button") || $e.is("a") || elem.is("input[type=button]")){
+ var divTag = $e.closest("div");
+ divTag.removeClass(options.hoverClass+" "+options.focusClass+" "+options.activeClass);
+
+ if($e.is(":disabled")){
+ divTag.addClass(options.disabledClass);
+ }else{
+ divTag.removeClass(options.disabledClass);
+ }
+
+ }
+
+ });
+ };
+
+ return this.each(function() {
+ if($.support.selectOpacity){
+ var elem = $(this);
+
+ if(elem.is("select")){
+ //element is a select
+ if(elem.attr("multiple") != true){
+ //element is not a multi-select
+ if(elem.attr("size") == undefined || elem.attr("size") <= 1){
+ doSelect(elem);
+ }
+ }
+ }else if(elem.is(":checkbox")){
+ //element is a checkbox
+ doCheckbox(elem);
+ }else if(elem.is(":radio")){
+ //element is a radio
+ doRadio(elem);
+ }else if(elem.is(":file")){
+ //element is a file upload
+ doFile(elem);
+ }else if(elem.is(":text, :password, input[type='email']")){
+ doInput(elem);
+ }else if(elem.is("textarea")){
+ doTextarea(elem);
+ }else if(elem.is("a") || elem.is(":submit") || elem.is(":reset") || elem.is("button") || elem.is("input[type=button]")){
+ doButton(elem);
+ }
+
+ }
+ });
+ };
+})(jQuery);
diff --git a/admin/view/javascript/shopunity/uniform/jquery.uniform.min.js b/admin/view/javascript/shopunity/uniform/jquery.uniform.min.js
new file mode 100755
index 0000000..1198c13
--- /dev/null
+++ b/admin/view/javascript/shopunity/uniform/jquery.uniform.min.js
@@ -0,0 +1 @@
+(function(a){a.uniform={options:{selectClass:"selector",radioClass:"radio",checkboxClass:"checker",fileClass:"uploader",filenameClass:"filename",fileBtnClass:"action",fileDefaultText:"No file selected",fileBtnText:"Choose File",checkedClass:"checked",focusClass:"focus",disabledClass:"disabled",buttonClass:"button",activeClass:"active",hoverClass:"hover",useID:true,idPrefix:"uniform",resetSelector:false,autoHide:true},elements:[]};if(a.browser.msie&&a.browser.version<7){a.support.selectOpacity=false}else{a.support.selectOpacity=true}a.fn.uniform=function(k){k=a.extend(a.uniform.options,k);var d=this;if(k.resetSelector!=false){a(k.resetSelector).mouseup(function(){function l(){a.uniform.update(d)}setTimeout(l,10)})}function j(l){$el=a(l);$el.addClass($el.attr("type"));b(l)}function g(l){a(l).addClass("uniform");b(l)}function i(o){var m=a(o);var p=a(""),l=a("
");p.addClass(k.buttonClass);if(k.useID&&m.attr("id")!=""){p.attr("id",k.idPrefix+"-"+m.attr("id"))}var n;if(m.is("a")||m.is("button")){n=m.text()}else{if(m.is(":submit")||m.is(":reset")||m.is("input[type=button]")){n=m.attr("value")}}n=n==""?m.is(":reset")?"Reset":"Submit":n;l.html(n);m.css("opacity",0);m.wrap(p);m.wrap(l);p=m.closest("div");l=m.closest("span");if(m.is(":disabled")){p.addClass(k.disabledClass)}p.bind({"mouseenter.uniform":function(){p.addClass(k.hoverClass)},"mouseleave.uniform":function(){p.removeClass(k.hoverClass);p.removeClass(k.activeClass)},"mousedown.uniform touchbegin.uniform":function(){p.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"click.uniform touchend.uniform":function(r){if(a(r.target).is("span")||a(r.target).is("div")){if(o[0].dispatchEvent){var q=document.createEvent("MouseEvents");q.initEvent("click",true,true);o[0].dispatchEvent(q)}else{o[0].click()}}}});o.bind({"focus.uniform":function(){p.addClass(k.focusClass)},"blur.uniform":function(){p.removeClass(k.focusClass)}});a.uniform.noSelect(p);b(o)}function e(o){var m=a(o);var p=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){p.hide()}p.addClass(k.selectClass);if(k.useID&&o.attr("id")!=""){p.attr("id",k.idPrefix+"-"+o.attr("id"))}var n=o.find(":selected:first");if(n.length==0){n=o.find("option:first")}l.html(n.html());o.css("opacity",0);o.wrap(p);o.before(l);p=o.parent("div");l=o.siblings("span");o.bind({"change.uniform":function(){l.text(o.find(":selected").html());p.removeClass(k.activeClass)},"focus.uniform":function(){p.addClass(k.focusClass)},"blur.uniform":function(){p.removeClass(k.focusClass);p.removeClass(k.activeClass)},"mousedown.uniform touchbegin.uniform":function(){p.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"click.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"mouseenter.uniform":function(){p.addClass(k.hoverClass)},"mouseleave.uniform":function(){p.removeClass(k.hoverClass);p.removeClass(k.activeClass)},"keyup.uniform":function(){l.text(o.find(":selected").html())}});if(a(o).attr("disabled")){p.addClass(k.disabledClass)}a.uniform.noSelect(l);b(o)}function f(n){var m=a(n);var o=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){o.hide()}o.addClass(k.checkboxClass);if(k.useID&&n.attr("id")!=""){o.attr("id",k.idPrefix+"-"+n.attr("id"))}a(n).wrap(o);a(n).wrap(l);l=n.parent();o=l.parent();a(n).css("opacity",0).bind({"focus.uniform":function(){o.addClass(k.focusClass)},"blur.uniform":function(){o.removeClass(k.focusClass)},"click.uniform touchend.uniform":function(){if(!a(n).attr("checked")){l.removeClass(k.checkedClass)}else{l.addClass(k.checkedClass)}},"mousedown.uniform touchbegin.uniform":function(){o.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){o.removeClass(k.activeClass)},"mouseenter.uniform":function(){o.addClass(k.hoverClass)},"mouseleave.uniform":function(){o.removeClass(k.hoverClass);o.removeClass(k.activeClass)}});if(a(n).attr("checked")){l.addClass(k.checkedClass)}if(a(n).attr("disabled")){o.addClass(k.disabledClass)}b(n)}function c(n){var m=a(n);var o=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){o.hide()}o.addClass(k.radioClass);if(k.useID&&n.attr("id")!=""){o.attr("id",k.idPrefix+"-"+n.attr("id"))}a(n).wrap(o);a(n).wrap(l);l=n.parent();o=l.parent();a(n).css("opacity",0).bind({"focus.uniform":function(){o.addClass(k.focusClass)},"blur.uniform":function(){o.removeClass(k.focusClass)},"click.uniform touchend.uniform":function(){if(!a(n).attr("checked")){l.removeClass(k.checkedClass)}else{var p=k.radioClass.split(" ")[0];a("."+p+" span."+k.checkedClass+":has([name='"+a(n).attr("name")+"'])").removeClass(k.checkedClass);l.addClass(k.checkedClass)}},"mousedown.uniform touchend.uniform":function(){if(!a(n).is(":disabled")){o.addClass(k.activeClass)}},"mouseup.uniform touchbegin.uniform":function(){o.removeClass(k.activeClass)},"mouseenter.uniform touchend.uniform":function(){o.addClass(k.hoverClass)},"mouseleave.uniform":function(){o.removeClass(k.hoverClass);o.removeClass(k.activeClass)}});if(a(n).attr("checked")){l.addClass(k.checkedClass)}if(a(n).attr("disabled")){o.addClass(k.disabledClass)}b(n)}function h(q){var o=a(q);var r=a("
"),p=a(""+k.fileDefaultText+" "),m=a(""+k.fileBtnText+" ");if(!o.css("display")=="none"&&k.autoHide){r.hide()}r.addClass(k.fileClass);p.addClass(k.filenameClass);m.addClass(k.fileBtnClass);if(k.useID&&o.attr("id")!=""){r.attr("id",k.idPrefix+"-"+o.attr("id"))}o.wrap(r);o.after(m);o.after(p);r=o.closest("div");p=o.siblings("."+k.filenameClass);m=o.siblings("."+k.fileBtnClass);if(!o.attr("size")){var l=r.width();o.attr("size",l/10)}var n=function(){var s=o.val();if(s===""){s=k.fileDefaultText}else{s=s.split(/[\/\\]+/);s=s[(s.length-1)]}p.text(s)};n();o.css("opacity",0).bind({"focus.uniform":function(){r.addClass(k.focusClass)},"blur.uniform":function(){r.removeClass(k.focusClass)},"mousedown.uniform":function(){if(!a(q).is(":disabled")){r.addClass(k.activeClass)}},"mouseup.uniform":function(){r.removeClass(k.activeClass)},"mouseenter.uniform":function(){r.addClass(k.hoverClass)},"mouseleave.uniform":function(){r.removeClass(k.hoverClass);r.removeClass(k.activeClass)}});if(a.browser.msie){o.bind("click.uniform.ie7",function(){setTimeout(n,0)})}else{o.bind("change.uniform",n)}if(o.attr("disabled")){r.addClass(k.disabledClass)}a.uniform.noSelect(p);a.uniform.noSelect(m);b(q)}a.uniform.restore=function(l){if(l==undefined){l=a(a.uniform.elements)}a(l).each(function(){if(a(this).is(":checkbox")){a(this).unwrap().unwrap()}else{if(a(this).is("select")){a(this).siblings("span").remove();a(this).unwrap()}else{if(a(this).is(":radio")){a(this).unwrap().unwrap()}else{if(a(this).is(":file")){a(this).siblings("span").remove();a(this).unwrap()}else{if(a(this).is("button, :submit, :reset, a, input[type='button']")){a(this).unwrap().unwrap()}}}}}a(this).unbind(".uniform");a(this).css("opacity","1");var m=a.inArray(a(l),a.uniform.elements);a.uniform.elements.splice(m,1)})};function b(l){l=a(l).get();if(l.length>1){a.each(l,function(m,n){a.uniform.elements.push(n)})}else{a.uniform.elements.push(l)}}a.uniform.noSelect=function(l){function m(){return false}a(l).each(function(){this.onselectstart=this.ondragstart=m;a(this).mousedown(m).css({MozUserSelect:"none"})})};a.uniform.update=function(l){if(l==undefined){l=a(a.uniform.elements)}l=a(l);l.each(function(){var n=a(this);if(n.is("select")){var m=n.siblings("span");var p=n.parent("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.html(n.find(":selected").html());if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":checkbox")){var m=n.closest("span");var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.removeClass(k.checkedClass);if(n.is(":checked")){m.addClass(k.checkedClass)}if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":radio")){var m=n.closest("span");var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.removeClass(k.checkedClass);if(n.is(":checked")){m.addClass(k.checkedClass)}if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":file")){var p=n.parent("div");var o=n.siblings(k.filenameClass);btnTag=n.siblings(k.fileBtnClass);p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);o.text(n.val());if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":submit")||n.is(":reset")||n.is("button")||n.is("a")||l.is("input[type=button]")){var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}}}}}})};return this.each(function(){if(a.support.selectOpacity){var l=a(this);if(l.is("select")){if(l.attr("multiple")!=true){if(l.attr("size")==undefined||l.attr("size")<=1){e(l)}}}else{if(l.is(":checkbox")){f(l)}else{if(l.is(":radio")){c(l)}else{if(l.is(":file")){h(l)}else{if(l.is(":text, :password, input[type='email']")){j(l)}else{if(l.is("textarea")){g(l)}else{if(l.is("a")||l.is(":submit")||l.is(":reset")||l.is("button")||l.is("input[type=button]")){i(l)}}}}}}}}})}})(jQuery);
\ No newline at end of file
diff --git a/admin/view/stylesheet/d_quickcheckout.css b/admin/view/stylesheet/d_quickcheckout.css
new file mode 100755
index 0000000..3139679
--- /dev/null
+++ b/admin/view/stylesheet/d_quickcheckout.css
@@ -0,0 +1,116 @@
+/* Design */
+
+/* Design Columns*/
+#column_slider{
+ width: 100%
+}
+.column-width-group .column-width{
+ border: 0px;
+ padding: 0px;
+ text-align: center;
+}
+body.dragging, body.dragging * {
+ cursor: move !important;
+}
+
+.dragged {
+ position: absolute;
+ z-index: 2000;
+ width: 100%;
+}
+
+#column_groups ul.column li.placeholder {
+ position: relative;
+ background: #eee;
+ height: 100px;
+ margin: 5px 10px;
+ border: 1px dashed #666;
+}
+
+#column_groups ul.column li.placeholder:before {
+ position: absolute;
+}
+
+#column_groups ul{
+ margin: 0px;
+ padding: 0px;
+ list-style: none;
+}
+#column_groups{
+ overflow: hidden;
+}
+
+#column_design .column{
+ min-height: 100px;
+ float: left;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ padding: 5px 0px;
+ overflow: hidden;
+}
+#column_groups .column-group-1{
+ float: left;
+ margin-bottom:-99999px;
+ padding-bottom:100000px;
+}
+#column_groups .column-group-2{
+ border-right: 1px solid #B5B5B5;
+ margin-right: -1px
+}
+#column_1{
+ border-right: 1px solid #B5B5B5;
+ margin-right: -1px !important;
+}
+#column_2{
+ border-right: 1px solid #B5B5B5;
+ margin-right: -1px !important;
+}
+#column_3{
+ border-left: 1px solid #B5B5B5;
+}
+#column_4{
+ float: right !important;
+ border-top: 1px solid #B5B5B5;
+ border-bottom: 1px solid #B5B5B5;
+ margin-left: -1px !important;
+}
+
+.portlet{
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ width: 100%;
+ overflow: hidden;
+ padding: 5px 10px ;
+}
+.portlet-wrap{
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ width: 100%;
+ border: 1px solid #B5B5B5;
+ min-height: 100px;
+ overflow: hidden;
+ background: #eee
+}
+.portlet-header {
+ border-bottom: 1px solid #b5b5b5;
+ text-align: center;
+ font-size: 14px;
+ font-weight: bold;
+ color: #526066;
+ min-width:100px;
+ margin: 5px 10px;
+ padding-bottom:5px;
+}
+.portlet-content .text {
+ margin:8px 10px 0px 10px;
+ max-height:33px;
+ color:#526066;
+ min-width:100px;
+ overflow:hidden
+}
+.portlet-content .text {
+ text-align:center
+}
diff --git a/admin/view/stylesheet/shopunity/bootstrap.css b/admin/view/stylesheet/shopunity/bootstrap.css
new file mode 100755
index 0000000..59918c5
--- /dev/null
+++ b/admin/view/stylesheet/shopunity/bootstrap.css
@@ -0,0 +1,62 @@
+/**
+ * Bootstrap extras
+ * By Dreamvention
+ */
+
+/* callouts */
+ .bs-callout {
+ padding: 20px;
+ margin: 20px 0;
+ border: 1px solid #eee;
+ border-left-width: 5px;
+ border-radius: 3px;
+}
+.bs-callout h4 {
+ margin-top: 0;
+ margin-bottom: 5px;
+}
+.bs-callout p:last-child {
+ margin-bottom: 0;
+}
+.bs-callout code {
+ border-radius: 3px;
+}
+.bs-callout+.bs-callout {
+ margin-top: -5px;
+}
+.bs-callout-default {
+ border-left-color: #777;
+}
+.bs-callout-default h4 {
+ color: #777;
+}
+.bs-callout-primary {
+ border-left-color: #428bca;
+}
+.bs-callout-primary h4 {
+ color: #428bca;
+}
+.bs-callout-success {
+ border-left-color: #5cb85c;
+}
+.bs-callout-success h4 {
+ color: #5cb85c;
+}
+.bs-callout-danger {
+ border-left-color: #d9534f;
+}
+.bs-callout-danger h4 {
+ color: #d9534f;
+}
+.bs-callout-warning {
+ border-left-color: #f0ad4e;
+}
+.bs-callout-warning h4 {
+ color: #f0ad4e;
+}
+.bs-callout-info {
+ border-left-color: #5bc0de;
+}
+.bs-callout-info h4 {
+ color: #5bc0de;
+}
\ No newline at end of file
diff --git a/admin/view/template/module/d_quickcheckout.tpl b/admin/view/template/module/d_quickcheckout.tpl
new file mode 100755
index 0000000..94d3af6
--- /dev/null
+++ b/admin/view/template/module/d_quickcheckout.tpl
@@ -0,0 +1,928 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/catalog/controller/module/d_quickcheckout.php b/catalog/controller/module/d_quickcheckout.php
new file mode 100755
index 0000000..dd2bcfd
--- /dev/null
+++ b/catalog/controller/module/d_quickcheckout.php
@@ -0,0 +1,3131 @@
+ en
+ [currency] => USD
+ [cart] => Array
+ (
+ [YToxOntzOjEwOiJwcm9kdWN0X2lkIjtpOjQwO30=] => 1
+ )
+
+ [captcha] => 773395
+ [account] => guest
+ [guest] => Array
+ (
+ [customer_group_id] => 1
+ [firstname] => dsdasd
+ [lastname] => asdasdas
+ [email] => addd@dsdad.sd
+ [telephone] => 131212
+ [fax] =>
+ [custom_field] => Array
+ (
+ [2] => 2
+ )
+
+ [shipping_address] => 1
+ )
+
+ [payment_address] => Array
+ (
+ [firstname] => dsdasd
+ [lastname] => asdasdas
+ [company] =>
+ [address_1] => dadsdas
+ [address_2] =>
+ [postcode] => sadadas
+ [city] => asddas
+ [country_id] => 222
+ [zone_id] => 3514
+ [country] => United Kingdom
+ [iso_code_2] => GB
+ [iso_code_3] => GBR
+ [address_format] =>
+ [custom_field] => Array
+ (
+ [1] => empty
+ )
+
+ [zone] => Aberdeenshire
+ [zone_code] => ABNS
+ )
+
+ [shipping_address] => Array
+ (
+ [firstname] => dsdasd
+ [lastname] => asdasdas
+ [company] =>
+ [address_1] => dadsdas
+ [address_2] =>
+ [postcode] => sadadas
+ [city] => asddas
+ [country_id] => 222
+ [zone_id] => 3514
+ [country] => United Kingdom
+ [iso_code_2] => GB
+ [iso_code_3] => GBR
+ [address_format] =>
+ [zone] => Aberdeenshire
+ [zone_code] => ABNS
+ [custom_field] => Array
+ (
+ [1] => empty
+ )
+
+ )
+
+ [comment] =>
+ [order_id] => 4
+ [user_id] => 1
+ [token] => 911910cb41cd6a5ec07657d6c012b16d
+ [shipping_methods] => Array
+ (
+ [flat] => Array
+ (
+ [title] => Flat Rate
+ [quote] => Array
+ (
+ [flat] => Array
+ (
+ [code] => flat.flat
+ [title] => Flat Shipping Rate
+ [cost] => 5.00
+ [tax_class_id] => 9
+ [text] => $8.00
+ )
+
+ )
+
+ [sort_order] => 1
+ [error] =>
+ )
+
+ )
+
+ [shipping_method] => Array
+ (
+ [code] => flat.flat
+ [title] => Flat Shipping Rate
+ [cost] => 5.00
+ [tax_class_id] => 9
+ [text] => $8.00
+ )
+
+ [payment_methods] => Array
+ (
+ [cod] => Array
+ (
+ [code] => cod
+ [title] => Cash On Delivery
+ [terms] =>
+ [sort_order] => 5
+ )
+
+ )
+
+ [payment_method] => Array
+ (
+ [code] => cod
+ [title] => Cash On Delivery
+ [terms] =>
+ [sort_order] => 5
+ )
+
+)
+
+custom fields
+Array (
+ [0] => Array (
+ [custom_field_id] => 1
+ [custom_field_value] => Array ( )
+ [name] => This is my first field
+ [type] => text
+ [value] => empty
+ [location] => address
+ [required] =>
+ [sort_order] => 1
+ )
+
+ [1] => Array (
+ [custom_field_id] => 2
+ [custom_field_value] => Array (
+ [0] => Array (
+ [custom_field_value_id] => 2
+ [name] => test
+ )
+ [1] => Array (
+ [custom_field_value_id] => 3
+ [name] => go home
+ )
+ )
+ [name] => another option
+ [type] => radio
+ [value] =>
+ [location] => account
+ [required] =>
+ [sort_order] => 1
+ )
+)
+*/
+//session_unset();
+/**
+ * Class of Ajax Quick Checkout module. This is the main file for calculating and validating all the fields.
+ *
+ * @author dreamvention
+ * @link http://www.opencart.com/index.php?route=extension/extension/info&extension_id=9132
+ * @package quickcheckout
+ */
+
+use Monolog\Logger;
+use Monolog\Handler\BrowserConsoleHandler;
+
+require_once(modification(DIR_SYSTEM . 'library/Ubench.php'));
+
+class ControllerModuleDQuickcheckout extends Controller {
+
+ private $settings = array();
+ private $texts = array('title', 'tooltip', 'description', 'text');
+ private $debug_on = true;
+ private $debug_path = 'system/logs/error.txt';
+ private $time = '';
+ private $data = array();
+ private $template = '';
+ private $log = '';
+ private $bench = '';
+
+/**
+
+ * Index method: loads the quickcheckout module.
+ *
+ * This is the main method to show all view blocks of the get_view methods
+ *
+ * @uses ControllerModuleQuickcheckout:validate()
+ * @uses ControllerModuleQuickcheckout:load_settings()
+ * @uses ControllerModuleQuickcheckout:get_login_view()
+ * @uses ControllerModuleQuickcheckout:get_payment_address_view()
+ * @uses ControllerModuleQuickcheckout:get_shipping_address_view()
+ * @uses ControllerModuleQuickcheckout:get_shipping_method_view()
+ * @uses ControllerModuleQuickcheckout:get_payment_method_view()
+ * @uses ControllerModuleQuickcheckout:get_cart_view()
+ * @uses ControllerModuleQuickcheckout:get_payment_view()
+ * @uses ControllerModuleQuickcheckout:get_confirm_view()
+ */
+
+ public function __construct($registry){
+ parent::__construct($registry);
+ if($this->debug_on){
+ $this->bench = new Ubench;
+ $this->bench->start();
+
+ $this->log = new Logger('d_quickcheckout');
+ $this->log->pushHandler(new BrowserConsoleHandler());
+ }
+ }
+
+ public function __destruct(){
+ if($this->debug_on){
+ $this->bench->end();
+ }
+ }
+
+ private function debug($text){
+ if($this->debug_on){
+ $this->bench->end();
+ $this->log->debug($text . ' (' .$this->bench->getTime(false) . ')');
+ $this->bench->start();
+ }
+ }
+
+ public function index(){
+ $this->debug('index()');
+
+ $this->cache->delete('d_quickcheckout');
+ $this->check_order_id();
+ unset($this->session->data['qc_settings']);
+
+
+ if($this->validate()) {
+ $this->load_settings();
+ $this->clear_session();
+
+ if($this->settings['general']['enable']){
+
+
+ $this->load_head_files();
+ $this->data['heading_title'] = $this->language->get('heading_title');
+
+ //Set Breadcrumbs
+ $this->data['breadcrumbs'] = array();
+
+ $this->data['breadcrumbs'][] = array(
+ 'text' => $this->language->get('text_home'),
+ 'href' => $this->url->link('common/home'),
+ 'separator' => false
+ );
+
+ $this->data['breadcrumbs'][] = array(
+ 'text' => $this->language->get('text_cart'),
+ 'href' => $this->url->link('checkout/cart'),
+ 'separator' => $this->language->get('text_separator')
+ );
+
+ $this->data['breadcrumbs'][] = array(
+ 'text' => $this->language->get('heading_title'),
+ 'href' => $this->url->link('checkout/checkout', '', 'SSL'),
+ 'separator' => $this->language->get('text_separator')
+ );
+
+ $this->data['order_id'] = ($this->session->data['order_id']) ? $this->session->data['order_id'] : '';
+
+ //Get customer option (Guest, Registration, Company etc)
+ if(!$this->customer->isLogged()){
+ $this->data['get_login_view'] = $this->get_login_view();
+ }else{
+ $this->data['get_login_view'] = '';
+ }
+ //Get customer info
+ $this->data['get_payment_address_view'] = $this->get_payment_address_view();
+
+ // //Get Shipping address
+ $this->data['get_shipping_address_view'] = $this->get_shipping_address_view();
+
+ // //Get shipping method
+ $this->data['get_shipping_method_view'] = $this->get_shipping_method_view();
+
+ // //Get payment method
+ $this->data['get_payment_method_view'] = $this->get_payment_method_view();
+
+ // //Get cart view
+ $this->data['get_cart_view'] = $this->get_cart_view();
+
+ // //Get payment view
+ $this->data['get_payment_view'] = $this->get_payment_view();
+
+ // //Get confirm view
+ $this->data['get_confirm_view'] = $this->get_confirm_view();
+
+ //Logo
+ $this->data['logo'] = '';
+ if($this->settings['design']['only_quickcheckout']){
+ $this->data['logo'] = $this->get_logo();
+ $this->data['home'] = $this->url->link('common/home');
+ $this->data['name'] = $this->config->get('config_name');
+ }
+
+ //rest of data
+ $this->data['settings'] = $this->settings;
+ $this->data['checkout'] = $this->session->data;
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/module/d_quickcheckout.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/module/d_quickcheckout.tpl';
+ } else {
+ $this->template = 'default/template/module/d_quickcheckout.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+ } //if enabled
+ }else{
+ $this->language->load('checkout/cart');
+ $this->data['heading_title'] = $this->language->get('heading_title');
+ $this->data['text_message'] = $this->language->get('text_empty');
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/empty.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/empty.tpl';
+ } else {
+ $this->template = 'default/template/d_quickcheckout/empty.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+ }
+ }
+
+/**
+
+ * load_settings()
+ *
+ * builds the settings string and sets the settings in the session. Uploads all the required models.
+ *
+ * @uses ControllerModuleDQuickcheckout:get_settings()
+ * @uses ControllerModuleDQuickcheckout:get_shipping_methods()
+ * @uses ControllerModuleDQuickcheckout:get_shipping_methods()
+ *
+ * @return void
+ */
+ private function load_settings(){
+ $this->debug('load_settings()');
+ //load models
+
+ $this->load->model('account/address');
+ $this->load->model('account/customer');
+ $this->load->model('extension/extension');
+ $this->load->model('setting/setting');
+ $this->load->model('localisation/country');
+ $this->load->model('localisation/zone');
+ $this->load->model('d_quickcheckout/order');
+ $this->load->model('tool/image');
+ $this->load->model('checkout/coupon');
+
+ //Load languages
+ $this->language->load('checkout/cart');
+ $this->language->load('checkout/checkout');
+ $this->language->load('module/d_quickcheckout');
+
+ //Get Settings
+ $this->settings = $this->get_settings();
+
+ //Min order
+ $this->session->data['min_order'] = (($this->cart->getTotal() + $this->get_vouchers_total()) >= $this->settings['general']['min_order']['value']);
+ $this->session->data['min_quantity'] = ($this->cart->countProducts() >= $this->settings['general']['min_quantity']['value']);
+ $this->session->data['min_quantity_product'] = true;
+ foreach ($this->cart->getProducts() as $product) {
+ $product_total = 0;
+
+ foreach ($this->cart->getProducts() as $product_2) {
+ if ($product_2['product_id'] == $product['product_id']) {
+ $product_total += $product_2['quantity'];
+ }
+ }
+
+ if ($product['minimum'] > $product_total) {
+ $this->session->data['min_quantity_product'] = false;
+
+ }
+ }
+
+ //Post
+ if(!empty($this->request->post)){
+ if(!empty($this->request->post['cart'])){
+ foreach ($this->request->post['cart'] as $key => $value){
+ $this->cart->update($key, $value);
+ }
+ unset($this->request->post['cart']);
+ }
+
+ $this->session->data = $this->array_merge_recursive_distinct($this->session->data, $this->request->post);
+
+ if(isset($this->request->post['field']) && isset($this->request->post['value'])){
+ $value = $this->request->post['value'];
+ $field = explode("[", $this->request->post['field']);
+ $field[1] =str_replace("]", "", $field[1]);
+
+ $this->session->data[$field[0]][$field[1]] = $value;
+ }
+ }
+ $this->session->data['customer_group_id'] = (isset($this->session->data['payment_address']) && isset($this->session->data['payment_address']['customer_group_id'])) ? $this->session->data['payment_address']['customer_group_id'] : $this->config->get('config_customer_group_id');
+
+ if($this->customer->isLogged()){
+ $this->session->data['account'] = 'logged';
+ $this->session->data['customer_group_id'] = $this->customer->getGroupId();
+ } elseif ((!$this->customer->isLogged()
+ && isset($this->session->data['account'])
+ && $this->session->data['account'] == 'logged')
+ || !isset($this->session->data['account'])) {
+
+ $this->session->data['account'] = $this->config->get('config_guest_checkout')
+ && !$this->config->get('config_customer_price')
+ && $this->settings['general']['default_option'] == 'guest'
+ && !$this->cart->hasDownload() ? 'guest' : 'register';
+ }
+
+ if(!isset($this->session->data['payment_address'])){
+ $this->session->data['payment_address'] = array();
+ }
+ if(!isset($this->session->data['shipping_address'])){
+ $this->session->data['shipping_address'] = array();
+ }
+
+ //set payment_country_id, payment_zone_id, shipping_country_id, shipping_zone_id, shipping_postcode
+ if(isset($this->session->data['payment_address']['country_id'])){
+ $this->session->data['payment_country_id'] = $this->session->data['payment_address']['country_id'];
+ }
+ if(isset($this->session->data['payment_address']['zone_id'])){
+ $this->session->data['payment_zone_id'] = $this->session->data['payment_address']['zone_id'];
+ }
+
+ if($this->shipping_same_as_payment()){
+ if (isset($this->session->data['payment_address']['country_id'])) {
+ $this->session->data['shipping_country_id'] = $this->session->data['payment_address']['country_id'];
+ $this->session->data['shipping_address']['country_id'] = $this->session->data['payment_address']['country_id'];
+ } else {
+ $this->session->data['shipping_country_id'] = $this->config->get('config_country_id');
+ $this->session->data['shipping_address']['country_id'] = $this->config->get('config_country_id');
+ }
+ if (isset($this->session->data['payment_address']['zone_id'])) {
+ $this->session->data['shipping_zone_id'] = $this->session->data['payment_address']['zone_id'];
+ $this->session->data['shipping_address']['zone_id'] = $this->session->data['payment_address']['zone_id'];
+ } else {
+ $this->session->data['shipping_zone_id'] =$this->config->get('config_zone_id');
+ $this->session->data['shipping_address']['zone_id'] =$this->config->get('config_zone_id');
+ }
+ if (isset($this->session->data['payment_address']['postcode'])) {
+ $this->session->data['shipping_postcode'] = $this->session->data['payment_address']['postcode'];
+ }else{
+ $this->session->data['shipping_postcode'] = '';
+ }
+ $this->session->data['shipping_address'] = $this->session->data['payment_address'];
+ }else{
+ if(isset($this->session->data['shipping_address']['country_id'])){
+ $this->session->data['shipping_country_id'] = $this->session->data['shipping_address']['country_id'];
+ }else{
+ $this->session->data['shipping_address']['country_id'] = $this->config->get('config_country_id');
+ }
+ if(isset($this->session->data['shipping_address']['zone_id'])){
+ $this->session->data['shipping_zone_id'] = $this->session->data['shipping_address']['zone_id'];
+ }else{
+ $this->session->data['shipping_address']['zone_id'] =$this->config->get('config_zone_id');
+ }
+ if(isset($this->session->data['shipping_address']['postcode'])){
+ $this->session->data['shipping_postcode'] = $this->session->data['shipping_address']['postcode'];
+ }
+ if(isset($this->session->data['shipping_address']['country_id']) && isset($this->session->data['shipping_address']['zone_id'])){
+ $country_data = $this->get_country_data($this->session->data['shipping_address']['country_id'], $this->session->data['shipping_address']['zone_id']);
+ if (is_array($country_data)) $this->session->data['shipping_address'] = array_merge($this->session->data['shipping_address'], $country_data);
+ }
+ }
+
+
+
+ if($this->customer->isLogged()){
+ if((isset($this->session->data['payment_address']['address_id']) && $this->session->data['payment_address']['address_id']) && $this->session->data['payment_address']['exists']){
+ $this->session->data['payment_address']['shipping'] = 0;
+ }
+ }
+ if(isset($this->session->data['payment_address']['country_id']) && isset($this->session->data['payment_address']['zone_id'])){
+ if(!isset($this->session->data['payment_address']['exists']) || $this->session->data['payment_address']['exists'] == 0){
+ $country_data = $this->get_country_data($this->session->data['payment_address']['country_id'], $this->session->data['payment_address']['zone_id']);
+ if (is_array($country_data)) $this->session->data['payment_address'] = array_merge($this->session->data['payment_address'], $country_data);
+ }
+ }
+
+ if(isset($this->session->data['shipping_address']['country_id']) && isset($this->session->data['shipping_address']['zone_id'])){
+ if(!isset($this->session->data['shipping_address']['exists']) || $this->session->data['shipping_address']['exists'] == 0){
+ $country_data = $this->get_country_data($this->session->data['shipping_address']['country_id'], $this->session->data['shipping_address']['zone_id']);
+ if (is_array($country_data)) $this->session->data['shipping_address'] = array_merge($this->session->data['shipping_address'], $country_data);
+ }
+ }
+
+
+ if($this->customer->isLogged()){
+ if(isset($this->session->data['payment_address']['address_id']) && $this->session->data['payment_address']['address_id'] != 0){
+ $address = $this->model_account_address->getAddress($this->session->data['payment_address']['address_id']);
+ if($address) $this->session->data['payment_address'] = array_merge($this->session->data['payment_address'], $address);
+ }
+
+ if(isset($this->session->data['shipping_address']['address_id']) && $this->session->data['shipping_address']['address_id'] != 0 && $this->model_account_address->getAddress($this->session->data['shipping_address']['address_id'])){
+ $address = $this->model_account_address->getAddress($this->session->data['shipping_address']['address_id']);
+ if($address) $this->session->data['shipping_address'] = array_merge($this->session->data['shipping_address'], $address);
+ }
+ }
+ //Set new session
+ if($this->customer->isLogged()){
+ $this->session->data['payment_address']['islogged'] = 1;
+ }else{
+ $this->session->data['payment_address']['islogged'] = 0;
+ $this->session->data['payment_address']['exists'] = 0;
+ $this->session->data['shipping_address']['exists'] = 0;
+ }
+
+ //Load shipping methods
+ $this->session->data['shipping_methods'] = $this->get_shipping_methods($this->session->data['shipping_address']);
+
+
+ $this->session->data['default_shipping_method'] = null;
+ if(!empty($this->session->data['shipping_methods'])){
+ $first = current($this->session->data['shipping_methods']);
+ $first = (is_array($first['quote'])) ? current($first['quote']) : $first['quote'];
+
+ $shipping = explode('.', $this->settings['step']['shipping_method']['default_option']);
+ $this->session->data['default_shipping_method'] = (isset($this->session->data['shipping_methods'][$shipping[0]]['quote'])) ? current($this->session->data['shipping_methods'][$shipping[0]]['quote']): $first;
+ }
+
+ //Load shipping method
+ if(isset($this->request->post['shipping_method'])){
+ $shipping = explode('.', $this->request->post['shipping_method']);
+ $this->session->data['shipping_method'] = (isset($this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]])) ? $this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]] : $this->session->data['default_shipping_method'];
+ }
+
+ if(!isset($this->session->data['shipping_method']) || !$this->session->data['shipping_method']){
+ $this->session->data['shipping_method'] = $this->session->data['default_shipping_method'];
+ }
+
+ //Load payment method
+ if(!empty($this->session->data['payment_methods'])){
+ $first = current($this->session->data['payment_methods']);
+ $default_payment_method = (isset($this->session->data['payment_methods'][$this->settings['step']['payment_method']['default_option']])) ? $this->session->data['payment_methods'][$this->settings['step']['payment_method']['default_option']] : $first;
+ }else{
+ $default_payment_method = null;
+ }
+
+ if(isset($this->request->post['payment_method'])){
+ $this->session->data['payment_method'] = (isset($this->session->data['payment_methods'][$this->request->post['payment_method']]))? $this->session->data['payment_methods'][$this->request->post['payment_method']] : $default_payment_method;
+ }
+
+ //Create or Update order
+ if(!isset($this->session->data['order_id'])){
+ $this->create_order();
+ }else{
+ $this->update_order();
+ }
+
+ $this->after_load_settings();
+ }
+
+
+/**
+
+ * Get login view
+ */
+ private function get_login_view(){
+ $this->debug('get_login_view()');
+ //Load languages
+ $this->data['text_checkout_option'] = $this->language->get('text_checkout_option');
+ $this->data['text_new_customer'] = $this->language->get('text_new_customer');
+ $this->data['text_new_guest'] = $this->language->get('text_new_guest');
+ $this->data['text_returning_customer'] = $this->language->get('text_returning_customer');
+ $this->data['text_checkout'] = $this->language->get('text_checkout');
+ $this->data['text_register'] = $this->language->get('text_register');
+ $this->data['text_guest'] = $this->language->get('text_guest');
+ $this->data['text_i_am_returning_customer'] = $this->language->get('text_i_am_returning_customer');
+ $this->data['text_register_account'] = $this->language->get('text_register_account');
+ $this->data['text_forgotten'] = $this->language->get('text_forgotten');
+ $this->data['entry_email'] = $this->language->get('entry_email');
+ $this->data['entry_password'] = $this->language->get('entry_password');
+ $this->data['button_continue'] = $this->language->get('button_continue');
+ $this->data['button_login'] = $this->language->get('button_login');
+ $this->data['forgotten'] = $this->url->link('account/forgotten', '', 'SSL');
+
+ //social login
+ if($this->isInstalled('d_social_login')){
+ $this->data['providers'] = $this->get_social_login_providers();
+ }
+
+ //Check if guest checkout is allowed
+ $this->data['guest_checkout'] = $this->is_guest_checkout_allowed();
+
+ //Get Sellected account
+ $this->data['account'] = $this->session->data['account'];
+
+ //Get settings
+ $this->data['data'] = $this->session->data['qc_settings']['option'][$this->session->data['account']]['login'];
+
+ //Display login, guest and registration blocks.
+ $count = $this->data['data']['option']['login']['display']
+ + $this->data['data']['option']['register']['display']
+ + $this->data['data']['option']['guest']['display'];
+
+ $this->data['count'] = $count;
+ $this->data['width'] = ($count) ? 12/$count : 0;
+ $this->data['login_style'] = $this->settings['design']['login_style'];
+ $this->data['dsl_size'] = $this->settings['general']['socila_login_style'];
+
+ //Get template
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/login.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/login.tpl';
+ } else {
+ $this->template = 'default/template/d_quickcheckout/login.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+
+ }
+
+
+ private function get_field_view($data){
+ $data['settings'] = $this->settings;
+
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/field.tpl')) {
+ $template = $this->config->get('config_template') . '/template/d_quickcheckout/field.tpl';
+ } else {
+ $templatetemplate = 'default/template/d_quickcheckout/field.tpl';
+ }
+
+ return $this->load->view($template, $data);
+ }
+/**
+
+ * Get View: Payment Address
+ *
+ * Load fields
+ * Set default values
+ * Load data if islogged
+ * Set depending values
+ * Set session
+ */
+ private function get_payment_address_view(){
+ $this->debug('get_payment_address_view()');
+ //Load languages
+ $this->data['text_select'] = $this->language->get('text_select');
+ $this->data['text_none'] = $this->language->get('text_none');
+ $this->data['text_address_existing'] = $this->language->get('text_address_existing');
+ $this->data['text_address_new'] = $this->language->get('text_address_new');
+
+ //Load fields
+ $data = $this->session->data['qc_settings']['option'][$this->session->data['account']]['payment_address'];
+ $data['fields']['country_id']['value'] = $this->config->get('config_country_id');
+ $data['fields']['country_id']['options'] = $this->get_countries();
+ $data['fields']['zone_id']['value'] = $this->config->get('config_zone_id');
+ $data['fields']['customer_group_id']['value'] = $this->config->get('config_customer_group_id');
+ $data['fields']['customer_group_id']['options'] = $this->get_customer_groups();
+ //$data['fields']['postcode']['value'] = '';
+
+ $this->data['address_style'] = $this->settings['design']['address_style'];
+
+ if(isset($this->session->data['payment_address'])){
+ foreach($this->session->data['payment_address'] as $field => $value){
+ if(isset($data['fields'][$field])){
+ $data['fields'][$field]['value'] = $value;
+ }
+ }
+ }
+
+ $data['fields']['zone_id']['options'] = $this->get_zones_by_country_id($data['fields']['country_id']['value']);
+
+ //Set default values
+ $payment_address = array();
+ foreach($data['fields'] as $field => $value){
+ $payment_address[$field] = '';
+ if(isset($value['value'])){
+ $payment_address[$field] = $value['value'];
+ }
+ }
+
+ $country_data = $this->get_country_data($payment_address['country_id'], $payment_address['zone_id']);
+ if (is_array($country_data)) $payment_address = array_merge($payment_address, $country_data);
+
+ //Load data of logged
+ $this->session->data['addresses'] = '';
+ $data['exists'] = (isset($data['exists'])) ? $data['exists'] : '';
+ if($this->customer->isLogged()){
+ //get address
+ if ($this->customer->getId()!=null) {
+ $this->session->data['addresses'] = $this->model_account_address->getAddresses();
+ }else{
+ $this->session->data['addresses'] = $this->model_account_address->getAddress($this->customer->getAddressId());
+ }
+
+ if(isset($this->session->data['payment_address']['address_id'])){
+ $data['address_id'] = $this->session->data['payment_address']['address_id'];
+ }else{
+ $data['address_id'] = $this->customer->getAddressId();
+ }
+
+ if(isset($this->session->data['payment_address']['exists'])){
+ $data['exists'] = $this->session->data['payment_address']['exists'];
+ }else{
+ $data['exists'] = '1';
+ }
+
+ if(isset($this->session->data['payment_address']['created'])){
+ $data['address_id'] = $this->session->data['payment_address']['created'];
+ }
+ if($data['address_id'] != 0 && $this->model_account_address->getAddress($data['address_id'])){
+ $payment_address = $this->model_account_address->getAddress($data['address_id']);
+ }
+
+ if($this->data['address_style'] == 'radio'){
+ $data['exists'] = $data['address_id'];
+ $payment_address['exists'] = $data['address_id'];
+ }
+ }else{
+ unset($this->session->data['payment_address']);
+ }
+ $this->data['addresses'] = $this->session->data['addresses'];
+
+ if (!$this->cart->hasShipping()) {
+ $data['fields']['shipping']['value'] = 1;
+ $data['fields']['shipping']['display'] = 0;
+ }
+
+ //Set session
+ $this->tax->setPaymentAddress($payment_address['country_id'], $payment_address['zone_id']);
+ $this->data['payment_address'] = $data;
+ $this->session->data['payment_address'] = $payment_address;
+ $this->session->data['guest']['payment'] = $this->session->data['payment_address'];
+
+ $data['name'] = 'payment_address';
+ $data['customer_group_id'] = $this->session->data['customer_group_id'];
+ $data['text_select'] = $this->language->get('text_select');
+ $data['text_none'] = $this->language->get('text_none');
+ $this->data['field_view'] = $this->get_field_view($data);
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/payment_address.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/payment_address.tpl';
+ } else {
+ $this->template = 'default/template/d_quickcheckout/payment_address.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+
+ }
+
+ private function shipping_same_as_payment(){
+
+ if($this->session->data['qc_settings']['option'][$this->session->data['account']]['shipping_address']['require'] == 1) {
+ $this->session->data['payment_address']['shipping'] = 0;
+ }
+
+
+ if(isset($this->session->data['account']) && isset($this->session->data['payment_address']['shipping'])){
+ if($this->session->data['payment_address']['shipping'] || !$this->settings['option'][$this->session->data['account']]['shipping_address']['display']){
+ return true;
+ }
+ }
+ return false;
+ }
+
+
+/**
+
+ * Get View: Shipping address
+ *
+ * Load fields
+ * Set default values
+ * Load data if islogged
+ * Set depending values
+ * Set session
+ */
+ private function get_shipping_address_view(){
+ $this->debug('get_shipping_address_view()');
+ //Setting language
+ if(!$this->cart->hasShipping()){ return false; }
+
+ $this->data['text_select'] = $this->language->get('text_select');
+ $this->data['text_none'] = $this->language->get('text_none');
+ $this->data['text_address_existing'] = $this->language->get('text_address_existing');
+ $this->data['text_address_new'] = $this->language->get('text_address_new');
+
+ $this->data['address_style'] = $this->settings['design']['address_style'];
+
+ //Load fields
+ $data = $this->session->data['qc_settings']['option'][$this->session->data['account']]['shipping_address'];
+ $data['fields']['country_id']['value'] = $this->config->get('config_country_id');
+ $data['fields']['country_id']['options'] = $this->get_countries();
+ $data['fields']['zone_id']['value'] = $this->config->get('config_zone_id');
+ //$data['fields']['postcode']['value'] = '';
+
+ if(isset($this->session->data['shipping_address'])){
+ foreach($this->session->data['shipping_address'] as $field => $value){
+ if(isset($data['fields'][$field])){
+ $data['fields'][$field]['value'] = $value;
+ }
+ }
+ }
+
+ $data['fields']['zone_id']['options'] = $this->get_zones_by_country_id($data['fields']['country_id']['value']);
+
+ //Set default values
+ $shipping_address = array();
+ foreach($data['fields'] as $field => $value){
+ $shipping_address[$field] = '';
+ if(isset($value['value'])){
+ $shipping_address[$field] = $value['value'];
+ }
+ }
+
+
+ $data['address_id'] = (isset($data['address_id'])) ? $data['address_id'] : '';
+ $data['exists'] = (isset($data['exists'])) ? $data['exists'] : '';
+ $this->session->data['payment_address']['shipping'] = isset($this->session->data['payment_address']['shipping']) ? $this->session->data['payment_address']['shipping'] : 0;
+
+
+ //Load data of logged
+ $this->session->data['addresses'] = '';
+ if($this->customer->isLogged()){
+ //get address
+ if ($this->customer->getId()!=null) {
+ $this->session->data['addresses'] = $this->model_account_address->getAddresses();
+ }else{
+ $this->session->data['addresses'] = $this->model_account_address->getAddress($this->customer->getAddressId());
+ }
+
+ if(isset($this->session->data['shipping_address']['address_id'])){
+ $data['address_id'] = $this->session->data['shipping_address']['address_id'];
+ }else{
+ $data['address_id'] = $this->customer->getAddressId();
+ }
+
+ if(isset($this->session->data['shipping_address']['exists'])){
+ $data['exists'] = $this->session->data['shipping_address']['exists'];
+ }else{
+ $data['exists'] = '1';
+ }
+
+ if(isset($this->session->data['shipping_address']['created'])){
+ $data['address_id'] = $this->session->data['shipping_address']['created'];
+ }
+ if($data['address_id'] != 0 && $this->model_account_address->getAddress($data['address_id'])){
+ $shipping_address = $this->model_account_address->getAddress($data['address_id']);
+ }
+
+ if($this->data['address_style'] == 'radio'){
+ $shipping_address['exists'] = $data['exists'] = $data['address_id'];
+ }
+
+ }
+
+ $this->data['addresses'] = $this->session->data['addresses'];
+
+ //Set session
+ $country_data = $this->get_country_data($shipping_address['country_id'], $shipping_address['zone_id']);
+ if (is_array($country_data)) $shipping_address = array_merge($shipping_address, $country_data);
+
+ $this->tax->setShippingAddress($shipping_address['country_id'], $shipping_address['zone_id']);
+ $this->data['shipping_address'] = $data;
+ $this->session->data['shipping_address'] = $shipping_address;
+ $this->session->data['guest']['shipping'] = $this->session->data['shipping_address'];
+ $this->data['shipping_display'] = ($data['display'] && $this->session->data['payment_address']['shipping'] == 0) ;
+
+
+ $data['name'] = 'shipping_address';
+ $data['customer_group_id'] = $this->session->data['customer_group_id'];
+ $data['text_select'] = $this->language->get('text_select');
+ $data['text_none'] = $this->language->get('text_none');
+ $this->data['field_view'] = $this->get_field_view($data);
+
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/shipping_address.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/shipping_address.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/shipping_address.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+
+ }
+
+
+/**
+
+ * Ger View: Shipping method
+ */
+ private function get_shipping_method_view(){
+ $this->debug('get_shipping_method_view()');
+ if(!$this->cart->hasShipping()){ return false; }
+ //Load shipping method
+ if(isset($this->request->post['shipping_method'])){
+ $shipping = explode('.', $this->request->post['shipping_method']);
+ $this->session->data['shipping_method'] = (isset($this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]])) ? $this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]] : $this->session->data['default_shipping_method'];
+ }
+
+ if(!isset($this->session->data['shipping_method']['code']) ||
+ !isset($this->session->data['shipping_method']['title']) ||
+ !isset($this->session->data['shipping_method']['cost'])){
+ $this->session->data['shipping_method'] = $this->session->data['default_shipping_method'];
+ }
+
+ if ((!$this->cart->hasProducts() && !empty($this->session->data['vouchers']))){
+ $this->data['shipping_methods'] = array();
+ }elseif($this->cart->hasProducts() && !$this->cart->hasShipping()){
+ $this->data['shipping_methods'] = array();
+ }else{
+
+ if (isset($this->session->data['shipping_methods'])) {
+ $this->data['shipping_methods'] = $this->session->data['shipping_methods'];
+ } else {
+ $this->data['shipping_methods'] = array();
+ }
+
+ if (isset($this->session->data['shipping_method']['code'])) {
+ $this->data['code'] = $this->session->data['shipping_method']['code'];
+ } else {
+ $this->data['code'] = '';
+ }
+ }
+ $this->data['text_shipping_method'] = $this->language->get('text_shipping_method');
+
+ if (empty($this->session->data['shipping_methods'])) {
+ $this->data['error_warning'] = sprintf($this->language->get('error_no_shipping'), $this->url->link('information/contact'));
+ } else {
+ $this->data['error_warning'] = '';
+ }
+ $this->data['settings'] = $this->settings;
+
+ $this->data['data'] = $this->array_merge_recursive_distinct($this->settings['option'][$this->session->data['account']]['shipping_method'],$this->settings['step']['shipping_method']);
+
+ $lang = $this->language_merge($this->data['data'], $this->texts);
+ $this->data['data'] = $this->array_merge_recursive_distinct($this->data['data'], $lang);
+
+ if(file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/shipping_method.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/shipping_method.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/shipping_method.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+ }
+
+
+/**
+
+ * Get View: Payment method
+ */
+ private function get_payment_method_view(){
+ $this->debug('get_payment_method_view()');
+ //Load payment methods
+ $this->session->data['payment_methods'] = $this->get_payment_methods($this->session->data['payment_address']);
+
+ if(isset($this->settings['step']['payment_method']['cost']) && is_array($this->settings['step']['payment_method']['cost'])){
+ $this->get_total_data($total_data, $total, $taxes);
+ foreach($this->settings['step']['payment_method']['cost'] as $payment_method){
+ if(isset($this->session->data['payment_methods'][$payment_method['payment_method']])) {
+
+ if(preg_match("/[0-99]%/", $payment_method['cost'])) {
+ $payment_method['cost'] = $total*(floatval($payment_method['cost'])/(100+floatval($payment_method['cost'])));
+ }
+ $this->session->data['payment_methods'][$payment_method['payment_method']]['cost'] = $this->currency->format($payment_method['cost']);
+
+ }
+ }
+ }
+
+
+ if(!empty($this->session->data['payment_methods'])){
+ $first = current($this->session->data['payment_methods']);
+ $default_payment_method = (isset($this->session->data['payment_methods'][$this->settings['step']['payment_method']['default_option']])) ? $this->session->data['payment_methods'][$this->settings['step']['payment_method']['default_option']] : $first;
+ }else{
+ $default_payment_method = null;
+ }
+
+ //Load payment method
+ if(isset($this->request->post['payment_method'])){
+ $this->session->data['payment_method'] = (isset($this->session->data['payment_methods'][$this->request->post['payment_method']]))? $this->session->data['payment_methods'][$this->request->post['payment_method']] : $default_payment_method;
+ }
+
+ if(!isset($this->session->data['payment_method']['code']) ||
+ !isset($this->session->data['payment_method']['title']) ||
+ !isset($this->session->data['payment_method']['sort_order'])){
+ $this->session->data['payment_method'] = $default_payment_method;
+ }
+
+ $this->data['text_payment_method'] = $this->language->get('text_payment_method');
+ $this->data['error_warning'] = '';
+ $this->data['payment_methods'] = '';
+
+ if (isset($this->session->data['payment_methods']) && !empty($this->session->data['payment_methods'])) {
+
+ $this->data['payment_methods'] = $this->session->data['payment_methods'];
+
+ if (isset($this->session->data['payment_method']['code'])) {
+ $this->data['code'] = $this->session->data['payment_method']['code'];
+ } else {
+ $this->data['code'] = '';
+ }
+
+ $this->data['settings'] = $this->settings;
+ $this->data['data'] = $this->array_merge_recursive_distinct($this->settings['option'][$this->session->data['account']]['payment_method'],$this->settings['step']['payment_method']);
+ $lang = $this->language_merge($this->data['data'], $this->texts);
+ $this->data['data'] = $this->array_merge_recursive_distinct($this->data['data'], $lang);
+
+ } else {
+
+ $this->data['error_warning'] = sprintf($this->language->get('error_no_payment'), $this->url->link('information/contact'));
+ }
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/payment_method.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/payment_method.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/payment_method.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+ }
+
+/**
+
+ * Get View: Cart
+ */
+ private function get_cart_view(){
+ $this->debug('get_cart_view()');
+ if($this->cart->getProducts() || !empty($this->session->data['vouchers'])){
+ $this->session->data['shipping_methods'] = $this->get_shipping_methods($this->session->data['shipping_address']);
+ if(isset($this->request->post['shipping_method'])){
+ $shipping = explode('.', $this->request->post['shipping_method']);
+ $this->session->data['shipping_method'] = (isset($this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]])) ? $this->session->data['shipping_methods'][$shipping[0]]['quote'][$shipping[1]] : $this->session->data['default_shipping_method'];
+ }
+ $this->get_total_data($total_data, $total, $taxes);
+
+ $points = $this->customer->getRewardPoints();
+
+ $points_total = 0;
+
+ foreach ($this->cart->getProducts() as $product) {
+ if (isset($product['points']) && $product['points']) {
+ $points_total += $product['points'];
+ }
+ }
+
+ if(!$this->session->data['min_order']){
+ $this->data['error']['error_min_order'] = sprintf($this->settings['general']['min_order']['text'][(int)$this->config->get('config_language_id')], $this->currency->format($this->settings['general']['min_order']['value']));
+ }
+ if(!$this->session->data['min_quantity']){
+ $this->data['error']['error_min_order'] = sprintf($this->settings['general']['min_quantity']['text'][(int)$this->config->get('config_language_id')], $this->settings['general']['min_quantity']['value']);
+ }
+
+ if(!$this->cart->hasStock() && !$this->config->get('config_stock_checkout')){
+ $this->data['error']['error_min_order'] = $this->language->get('error_stock');
+
+ }
+
+ if(!$this->session->data['min_quantity_product']){
+ $this->language->load('checkout/cart');
+ $this->data['error']['error_min_order'] = sprintf($this->language->get('error_minimum'), $product['name'], $product['minimum']);
+ }
+
+ $this->data['column_image'] = $this->language->get('column_image');
+ $this->data['column_name'] = $this->language->get('column_name');
+ $this->data['column_model'] = $this->language->get('column_model');
+ $this->data['column_quantity'] = $this->language->get('column_quantity');
+ $this->data['column_price'] = $this->language->get('column_price');
+ $this->data['column_total'] = $this->language->get('column_total');
+ $this->data['text_comments'] = $this->language->get('text_comments');
+ $this->data['coupon_status'] = ( $this->settings['option'][$this->session->data['account']]['cart']['option']['coupon']['display'] && $this->config->get('coupon_status'));
+ $this->data['voucher_status'] = ( $this->settings['option'][$this->session->data['account']]['cart']['option']['voucher']['display'] && $this->config->get('voucher_status'));
+ $this->data['reward_status'] = ( $this->settings['option'][$this->session->data['account']]['cart']['option']['reward']['display'] && $points && $points_total && $this->config->get('reward_status'));
+
+ $this->data['products'] = array();
+
+
+ $this->language->load('checkout/coupon');
+ $this->data['text_use_coupon'] = $this->language->get('heading_title');
+ $this->language->load('checkout/voucher');
+ $this->data['text_use_voucher'] = $this->language->get('heading_title');
+ $this->language->load('checkout/reward');
+ $this->data['text_use_reward'] = sprintf($this->language->get('heading_title'), $points );
+
+
+ foreach ($this->session->data['cart'] as $key => $value) {
+ $this->cart->update($key, $value);
+ }
+
+ $products = $this->cart->getProducts();
+ foreach ($products as $product) {
+ $product_total = 0;
+
+ foreach ($products as $product_2) {
+ if ($product_2['product_id'] == $product['product_id']) {
+ $product_total += $product_2['quantity'];
+ }
+ }
+
+ if ($product['minimum'] > $product_total) {
+ $data['error_warning'] = sprintf($this->language->get('error_minimum'), $product['name'], $product['minimum']);
+ }
+
+ if ($product['image']) {
+ $thumb = $this->model_tool_image->resize($product['image'], $this->config->get('config_image_cart_width'), $this->config->get('config_image_cart_height'));
+ } else {
+ $thumb = '';
+ }
+
+ if ($product['image']) {
+ $image = $this->model_tool_image->resize($product['image'], $this->settings['design']['cart_image_size']['width'], $this->settings['design']['cart_image_size']['height']);
+ } else {
+ $image = '';
+ }
+
+ $option_data = array();
+
+ foreach ($product['option'] as $option) {
+ if ($option['type'] != 'file') {
+ $value = $option['value'];
+ } else {
+ $upload_info = $this->model_tool_upload->getUploadByCode($option['value']);
+
+ if ($upload_info) {
+ $value = $upload_info['name'];
+ } else {
+ $value = '';
+ }
+ }
+
+ $option_data[] = array(
+ 'name' => $option['name'],
+ 'value' => (utf8_strlen($value) > 20 ? utf8_substr($value, 0, 20) . '..' : $value)
+ );
+ }
+
+ // Display prices
+ if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) {
+ $price = $this->currency->format($this->tax->calculate($product['price'], $product['tax_class_id'], $this->config->get('config_tax')));
+ } else {
+ $price = false;
+ }
+
+ // Display prices
+ if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) {
+ $total = $this->currency->format($this->tax->calculate($product['price'], $product['tax_class_id'], $this->config->get('config_tax')) * $product['quantity']);
+ } else {
+ $total = false;
+ }
+
+ $recurring = '';
+
+ if ($product['recurring']) {
+ $frequencies = array(
+ 'day' => $this->language->get('text_day'),
+ 'week' => $this->language->get('text_week'),
+ 'semi_month' => $this->language->get('text_semi_month'),
+ 'month' => $this->language->get('text_month'),
+ 'year' => $this->language->get('text_year'),
+ );
+
+ if ($product['recurring']['trial']) {
+ $recurring = sprintf($this->language->get('text_trial_description'), $this->currency->format($this->tax->calculate($product['recurring']['trial_price'] * $product['quantity'], $product['tax_class_id'], $this->config->get('config_tax'))), $product['recurring']['trial_cycle'], $frequencies[$product['recurring']['trial_frequency']], $product['recurring']['trial_duration']) . ' ';
+ }
+
+ if ($product['recurring']['duration']) {
+ $recurring .= sprintf($this->language->get('text_payment_description'), $this->currency->format($this->tax->calculate($product['recurring']['price'] * $product['quantity'], $product['tax_class_id'], $this->config->get('config_tax'))), $product['recurring']['cycle'], $frequencies[$product['recurring']['frequency']], $product['recurring']['duration']);
+ } else {
+ $recurring .= sprintf($this->language->get('text_payment_until_canceled_description'), $this->currency->format($this->tax->calculate($product['recurring']['price'] * $product['quantity'], $product['tax_class_id'], $this->config->get('config_tax'))), $product['recurring']['cycle'], $frequencies[$product['recurring']['frequency']], $product['recurring']['duration']);
+ }
+ }
+
+ $this->data['products'][] = array(
+ 'key' => $product['key'],
+ 'image' => $image,
+ 'thumb' => $image,
+ 'name' => $product['name'],
+ 'model' => $product['model'],
+ 'option' => $option_data,
+ 'recurring' => $recurring,
+ 'quantity' => $product['quantity'],
+ 'stock' => $product['stock'] ? true : !(!$this->config->get('config_stock_checkout') || $this->config->get('config_stock_warning')),
+ 'reward' => ($product['reward'] ? sprintf($this->language->get('text_points'), $product['reward']) : ''),
+ 'price' => $price,
+ 'total' => $total,
+ 'href' => $this->url->link('product/product', 'product_id=' . $product['product_id'])
+ );
+ }
+
+
+ // Gift Voucher
+ $this->data['vouchers'] = array();
+
+ if (!empty($this->session->data['vouchers'])) {
+ foreach ($this->session->data['vouchers'] as $voucher) {
+ $this->data['vouchers'][] = array(
+ 'description' => $voucher['description'],
+ 'amount' => $this->currency->format($voucher['amount'])
+ );
+ }
+ }
+
+ if (!$this->cart->hasStock() && $this->config->get('config_stock_warning')) {
+ if(!$this->config->get('config_stock_checkout')){
+ $this->data['error']['error_stock'] = $this->language->get('error_stock');
+ }
+ }
+
+ $this->data['coupon_status'] = $this->config->get('coupon_status');
+
+ if (isset($this->request->post['coupon'])) {
+ $this->data['coupon'] = $this->request->post['coupon'];
+ } elseif (isset($this->session->data['coupon'])) {
+ $this->data['coupon'] = $this->session->data['coupon'];
+ } else {
+ $this->data['coupon'] = '';
+ }
+
+ $this->data['voucher_status'] = $this->config->get('voucher_status');
+
+ if (isset($this->request->post['voucher'])) {
+ $this->data['voucher'] = $this->request->post['voucher'];
+ } elseif (isset($this->session->data['voucher'])) {
+ $this->data['voucher'] = $this->session->data['voucher'];
+ } else {
+ $this->data['voucher'] = '';
+ }
+
+ $this->data['reward_status'] = ($points && $points_total && $this->config->get('reward_status'));
+
+ if (isset($this->request->post['reward'])) {
+ $this->data['reward'] = $this->request->post['reward'];
+ } elseif (isset($this->session->data['reward'])) {
+ $this->data['reward'] = $this->session->data['reward'];
+ } else {
+ $this->data['reward'] = '';
+ }
+
+
+ $this->data['totals'] = array();
+ foreach ($total_data as $total) {
+ $this->data['totals'][] = array(
+ 'title' => $total['title'],
+ 'text' => $this->currency->format($total['value'])
+ );
+ }
+
+ $this->data['data'] = $this->array_merge_recursive_distinct($this->settings['option'][$this->session->data['account']]['cart'], $this->settings['step']['cart']);
+ $this->data['settings'] = $this->settings;
+ $lang = $this->language_merge($this->data['data']['option'], $this->texts);
+ $this->data['data']['option'] = $this->array_merge_recursive_distinct($this->data['data']['option'], $lang);
+ $this->data['show_price'] = ($this->config->get('config_customer_price') && !$this->customer->isLogged());
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/cart.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/cart.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/cart.tpl';
+ }
+
+ return $this->load->view($this->template, $this->data);
+
+ }else{
+ return false;
+ }
+ }
+
+/**
+
+ * Get View: Payment
+ */
+ private function get_payment_view(){
+ $this->debug('get_payment_view()');
+ if($this->cart->getProducts() || !empty($this->session->data['vouchers'])){
+
+ $this->data['payment'] = '';
+ if(isset($this->session->data['payment_method']['code']) && $this->session->data['payment_method']['code']){
+ $this->data['payment'] = $this->load->controller('payment/' . $this->session->data['payment_method']['code']);
+ }
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/payment.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/payment.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/payment.tpl';
+ }
+ return $this->load->view($this->template, $this->data);
+ }else{
+ return false;
+ }
+ }
+
+/**
+
+ * Get View: Confirm
+ */
+ private function get_confirm_view(){
+ $this->debug('get_confirm_view()');
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->data['text_select'] = $this->language->get('text_select');
+ $this->data['text_none'] = $this->language->get('text_none');
+ $this->data['button_confirm'] = $this->language->get('button_confirm');
+
+ $data = $this->session->data['qc_settings']['option'][$this->session->data['account']]['confirm'];
+
+ if(isset($this->session->data['confirm'])){
+ foreach($this->session->data['confirm'] as $field => $value){
+ if(isset($data['fields'][$field])){
+ $data['fields'][$field]['value'] = $value;
+ }
+ }
+ }
+
+ //Set default values
+ $confirm = array();
+ foreach($data['fields'] as $field => $value){
+ $shipping_address[$field] = '';
+ if(isset($value['value'])){
+ $confirm[$field] = $value['value'];
+ }
+ }
+
+ $this->data['confirm'] = $data;
+ $this->session->data['confirm'] = $confirm;
+
+ $this->update_order();
+
+ if(isset($this->session->data['payment_method']['code']) && $this->session->data['payment_method']['code'] != ''){
+ $this->data['payment'] = $this->load->controller('payment/' . $this->session->data['payment_method']['code']);
+ }else{
+ $this->data['payment'] = '';
+ $this->data['error'] = 'No payment method loaded';
+ }
+
+ $this->data['button_confirm_display'] = $this->cart->hasStock() ? true : $this->config->get('config_stock_checkout');
+ if(!$this->session->data['min_order']){
+ $this->data['button_confirm_display'] = false;
+ }
+ if(!$this->session->data['min_quantity']){
+ $this->data['button_confirm_display'] = false;
+ }
+ if(!$this->session->data['min_quantity_product']){
+ $this->data['button_confirm_display'] = false;
+ }
+
+
+ $data['name'] = 'confirm';
+ $data['text_select'] = $this->language->get('text_select');
+ $data['text_none'] = $this->language->get('text_none');
+ $data['customer_group_id'] = $this->session->data['customer_group_id'];
+ $this->data['field_view'] = $this->get_field_view($data);
+
+ if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/d_quickcheckout/confirm.tpl')) {
+ $this->template = $this->config->get('config_template') . '/template/d_quickcheckout/confirm.tpl';
+ }else{
+ $this->template = 'default/template/d_quickcheckout/confirm.tpl';
+ }
+ return $this->load->view($this->template, $this->data);
+ }else{
+ return false;
+ }
+ }
+
+/**
+
+ * Create Order
+ */
+ private function create_order(){
+ $this->debug('create_order()');
+ $this->get_total_data($total_data, $total, $taxes);
+ $data = array();
+ $data['store_id'] = $this->config->get('config_store_id');
+ $data['store_name'] = $this->config->get('config_name');
+
+ if ($data['store_id']) {
+ $data['store_url'] = $this->config->get('config_url');
+ } else {
+ $data['store_url'] = HTTP_SERVER;
+ }
+ if (isset($this->request->cookie['tracking'])) {
+ $this->load->model('affiliate/affiliate');
+
+ $affiliate_info = $this->model_affiliate_affiliate->getAffiliateByCode($this->request->cookie['tracking']);
+ $subtotal = $this->cart->getSubTotal();
+
+ if ($affiliate_info) {
+ $data['affiliate_id'] = $affiliate_info['affiliate_id'];
+ $data['commission'] = ($subtotal / 100) * $affiliate_info['commission'];
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+
+ $data['language_id'] = $this->config->get('config_language_id');
+ $data['currency_id'] = $this->currency->getId();
+ $data['currency_code'] = $this->currency->getCode();
+ $data['currency_value'] = $this->currency->getValue($this->currency->getCode());
+ $data['ip'] = $this->request->server['REMOTE_ADDR'];
+
+ if (!empty($this->request->server['HTTP_X_FORWARDED_FOR'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_X_FORWARDED_FOR'];
+ } elseif(!empty($this->request->server['HTTP_CLIENT_IP'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_CLIENT_IP'];
+ } else {
+ $data['forwarded_ip'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_USER_AGENT'])) {
+ $data['user_agent'] = $this->request->server['HTTP_USER_AGENT'];
+ } else {
+ $data['user_agent'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_ACCEPT_LANGUAGE'])) {
+ $data['accept_language'] = $this->request->server['HTTP_ACCEPT_LANGUAGE'];
+ } else {
+ $data['accept_language'] = '';
+ }
+
+ $data['total'] = $total;
+
+ if(preg_match("/1.5.1/i", VERSION)){
+ $this->session->data['order_id'] = $this->model_d_quickcheckout_order->addOrder151($data);
+ }else{
+ $this->session->data['order_id'] = $this->model_d_quickcheckout_order->addOrder($data);
+ }
+ }
+
+/**
+
+ * Confirm Order
+ */
+ public function confirm_order(){
+ $this->debug('confirm_order()');
+ $this->load_settings();
+
+ $this->get_total_data($total_data, $total, $taxes);
+ $data = array();
+
+ $data['invoice_prefix'] = $this->config->get('config_invoice_prefix');
+ $data['store_id'] = $this->config->get('config_store_id');
+ $data['store_name'] = $this->config->get('config_name');
+
+ if ($data['store_id']) {
+ $data['store_url'] = $this->config->get('config_url');
+ } else {
+ $data['store_url'] = HTTP_SERVER;
+ }
+
+ $this->session->data['guest']['firstname'] = ($this->session->data['payment_address']['firstname']) ? $this->session->data['payment_address']['firstname'] : '';
+ $this->session->data['guest']['lastname'] = ($this->session->data['payment_address']['lastname']) ? $this->session->data['payment_address']['lastname'] : '';
+
+ if(!$this->session->data['payment_address']['email'] || $this->session->data['payment_address']['email']==""){
+ $this->session->data['payment_address']['email'] = $this->settings['general']['default_email'];
+ }
+
+ if($this->customer->isLogged() && $this->session->data['payment_address']['address_id'] == 0){
+ if(isset($this->session->data['payment_address']['created'])){
+ $this->model_account_address->editAddress($this->session->data['payment_address']['created'], $this->session->data['payment_address']);
+ $this->session->data['payment_address']['address_id'] = $this->session->data['payment_address']['created'];
+ }else{
+ $this->session->data['payment_address']['address_id'] = $this->model_account_address->addAddress($this->session->data['payment_address']);
+ $this->session->data['payment_address']['created'] = $this->session->data['payment_address']['address_id'];
+ }
+ //$this->session->data['payment_address']['address_id'] = $this->session->data['payment_address']['address_id'];
+
+ }
+
+
+
+ if($this->customer->isLogged()
+ && $this->session->data['shipping_address']['exists'] == 0
+ && $this->settings['option'][$this->session->data['account']]['shipping_address']['display']
+ && $this->session->data['payment_address']['shipping'] == 0){
+
+ if(isset($this->session->data['shipping_address']['created'])){
+ $this->model_account_address->editAddress($this->session->data['shipping_address']['created'], $this->session->data['shipping_address']);
+ }else{
+ $this->session->data['shipping_address']['address_id'] = $this->model_account_address->addAddress($this->session->data['shipping_address']);
+ $this->session->data['shipping_address']['created'] = $this->session->data['shipping_address']['address_id'];
+ }
+ //$this->session->data['shipping_address']['address_id'] = $this->session->data['shipping_address']['address_id'];
+ }
+
+ if($this->session->data['account'] == 'register'){
+ $this->create_customer($this->session->data['payment_address']);
+ $this->customer->login($this->session->data['payment_address']['email'], $this->session->data['payment_address']['password']);
+ $this->session->data['payment_address']['registered'] = 1;
+ $this->session->data['payment_address']['exists'] = 1;
+ $this->session->data['shipping_address']['registered'] = 1;
+ $this->session->data['shipping_address']['exists'] = 1;
+ if(!$this->session->data['payment_address']['shipping'] && $this->settings['option'][$this->session->data['account']]['shipping_address']['display']){
+ $this->session->data['shipping_address']['address_id'] = $this->model_account_address->addAddress($this->session->data['shipping_address']);
+ $this->session->data['shipping_address']['address_id'] = $this->session->data['shipping_address']['address_id'];
+ }
+ }
+
+ if ($this->customer->isLogged()) {
+ $customer_info = $this->model_account_customer->getCustomer($this->customer->getId());
+
+ $data['customer_id'] = $this->customer->getId();
+ $data['customer_group_id'] = $customer_info['customer_group_id'];
+ $data['firstname'] = $customer_info['firstname'];
+ $data['lastname'] = $customer_info['lastname'];
+ $data['email'] = $customer_info['email'];
+ $data['telephone'] = $customer_info['telephone'];
+ $data['fax'] = $customer_info['fax'];
+ $data['custom_field'] = unserialize($customer_info['custom_field']);
+
+ } elseif (isset($this->session->data['payment_address']) && isset($this->session->data['payment_address']['firstname'])) {
+ $data['customer_id'] = 0;
+ $data['customer_group_id'] = $this->session->data['payment_address']['customer_group_id'];
+ $data['firstname'] = $this->session->data['payment_address']['firstname'];
+ $data['lastname'] = $this->session->data['payment_address']['lastname'];
+ $data['email'] = $this->session->data['payment_address']['email'];
+ $data['telephone'] = $this->session->data['payment_address']['telephone'];
+ $data['fax'] = $this->session->data['payment_address']['fax'];
+ $data['custom_field'] = $this->parseCustomFields($this->session->data['payment_address']);
+ } else {
+ return false;
+ }
+
+
+
+
+ $payment_address = $this->session->data['payment_address'];
+
+ $data['payment_firstname'] = $payment_address['firstname'];
+ $data['payment_lastname'] = $payment_address['lastname'];
+ $data['payment_company'] = $payment_address['company'];
+ $data['payment_address_1'] = $payment_address['address_1'];
+ $data['payment_address_2'] = $payment_address['address_2'];
+ $data['payment_city'] = $payment_address['city'];
+ $data['payment_postcode'] = $payment_address['postcode'];
+ $data['payment_zone'] = $payment_address['zone'];
+ $data['payment_zone_id'] = $payment_address['zone_id'];
+ $data['payment_country'] = $payment_address['country'];
+ $data['payment_country_id'] = $payment_address['country_id'];
+ $data['payment_address_format'] = $payment_address['address_format'];
+ $data['payment_custom_field'] = $this->parseCustomFields($payment_address);
+
+ if (isset($this->session->data['payment_method']['title'])) {
+ if ($this->session->data['payment_method']['code']=="klarna_invoice") $data['payment_method'] = "Klarna Factuur";
+ else $data['payment_method'] = $this->session->data['payment_method']['title'];
+ } else {
+ $data['payment_method'] = '';
+ }
+
+ if (isset($this->session->data['payment_method']['code'])) {
+ $data['payment_code'] = $this->session->data['payment_method']['code'];
+ } else {
+ $data['payment_code'] = '';
+ }
+
+ if ($this->cart->hasShipping()) {
+/* $shipping_address = $this->model_account_address->getAddress($this->session->data['shipping_address']['address_id']);
+ $this->session->data['shipping_address'] = array_merge($this->session->data['shipping_address'], $shipping_address);*/
+ $shipping_address = $this->session->data['shipping_address'];
+ $data['shipping_firstname'] = $shipping_address['firstname'];
+ $data['shipping_lastname'] = $shipping_address['lastname'];
+ $data['shipping_company'] = $shipping_address['company'];
+ $data['shipping_address_1'] = $shipping_address['address_1'];
+ $data['shipping_address_2'] = $shipping_address['address_2'];
+ $data['shipping_city'] = $shipping_address['city'];
+ $data['shipping_postcode'] = $shipping_address['postcode'];
+ $data['shipping_zone'] = $shipping_address['zone'];
+ $data['shipping_zone_id'] = $shipping_address['zone_id'];
+ $data['shipping_country'] = $shipping_address['country'];
+ $data['shipping_country_id'] = $shipping_address['country_id'];
+ $data['shipping_address_format'] = $shipping_address['address_format'];
+ $data['shipping_custom_field'] = $this->parseCustomFields($shipping_address);
+
+ if (isset($this->session->data['shipping_method']['title'])) {
+ $data['shipping_method'] = $this->session->data['shipping_method']['title'];
+ } else {
+ $data['shipping_method'] = '';
+ }
+
+ if (isset($this->session->data['shipping_method']['code'])) {
+ $data['shipping_code'] = $this->session->data['shipping_method']['code'];
+ } else {
+ $data['shipping_code'] = '';
+ }
+ } else {
+ $data['shipping_firstname'] = '';
+ $data['shipping_lastname'] = '';
+ $data['shipping_company'] = '';
+ $data['shipping_address_1'] = '';
+ $data['shipping_address_2'] = '';
+ $data['shipping_city'] = '';
+ $data['shipping_postcode'] = '';
+ $data['shipping_zone'] = '';
+ $data['shipping_zone_id'] = '';
+ $data['shipping_country'] = '';
+ $data['shipping_country_id'] = '';
+ $data['shipping_address_format'] = '';
+ $data['shipping_method'] = '';
+ $data['shipping_code'] = '';
+ $data['shipping_custom_field'] = '';
+ }
+
+ $product_data = array();
+
+ foreach ($this->cart->getProducts() as $product) {
+ $option_data = array();
+
+ foreach ($product['option'] as $option) {
+ if ($option['type'] != 'file') {
+ $value = $option['option_value'];
+ } else {
+ $value = $this->encryption->decrypt($option['option_value']);
+ }
+
+ $option_data[] = array(
+ 'product_option_id' => $option['product_option_id'],
+ 'product_option_value_id' => $option['product_option_value_id'],
+ 'option_id' => $option['option_id'],
+ 'option_value_id' => $option['option_value_id'],
+ 'name' => $option['name'],
+ 'value' => $value,
+ 'type' => $option['type']
+ );
+ }
+
+ $product_data[] = array(
+ 'product_id' => $product['product_id'],
+ 'name' => $product['name'],
+ 'model' => $product['model'],
+ 'option' => $option_data,
+ 'download' => $product['download'],
+ 'quantity' => $product['quantity'],
+ 'subtract' => $product['subtract'],
+ 'price' => $product['price'],
+ 'total' => $product['total'],
+ 'tax' => $this->tax->getTax($product['price'], $product['tax_class_id']),
+ 'reward' => $product['reward']
+ );
+ }
+
+ // Gift Voucher
+ $voucher_data = array();
+
+ if (!empty($this->session->data['vouchers'])) {
+ foreach ($this->session->data['vouchers'] as $voucher) {
+ $voucher_data[] = array(
+ 'description' => $voucher['description'],
+ 'code' => substr(md5(mt_rand()), 0, 10),
+ 'to_name' => $voucher['to_name'],
+ 'to_email' => $voucher['to_email'],
+ 'from_name' => $voucher['from_name'],
+ 'from_email' => $voucher['from_email'],
+ 'voucher_theme_id' => $voucher['voucher_theme_id'],
+ 'message' => $voucher['message'],
+ 'amount' => $voucher['amount']
+ );
+ }
+ }
+
+ $data['products'] = $product_data;
+ $data['vouchers'] = $voucher_data;
+ $data['totals'] = $total_data;
+ $data['comment'] = (isset($this->session->data['confirm']['comment'])) ? $this->session->data['confirm']['comment'] : '';
+ $data['total'] = $total;
+
+ if (isset($this->request->cookie['tracking'])) {
+ $this->load->model('affiliate/affiliate');
+
+ $affiliate_info = $this->model_affiliate_affiliate->getAffiliateByCode($this->request->cookie['tracking']);
+ $subtotal = $this->cart->getSubTotal();
+
+ if ($affiliate_info) {
+ $data['affiliate_id'] = $affiliate_info['affiliate_id'];
+ $data['commission'] = ($subtotal / 100) * $affiliate_info['commission'];
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+
+ $data['language_id'] = $this->config->get('config_language_id');
+ $data['currency_id'] = $this->currency->getId();
+ $data['currency_code'] = $this->currency->getCode();
+ $data['currency_value'] = $this->currency->getValue($this->currency->getCode());
+ $data['ip'] = $this->request->server['REMOTE_ADDR'];
+
+ if (!empty($this->request->server['HTTP_X_FORWARDED_FOR'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_X_FORWARDED_FOR'];
+ } elseif(!empty($this->request->server['HTTP_CLIENT_IP'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_CLIENT_IP'];
+ } else {
+ $data['forwarded_ip'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_USER_AGENT'])) {
+ $data['user_agent'] = $this->request->server['HTTP_USER_AGENT'];
+ } else {
+ $data['user_agent'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_ACCEPT_LANGUAGE'])) {
+ $data['accept_language'] = $this->request->server['HTTP_ACCEPT_LANGUAGE'];
+ } else {
+ $data['accept_language'] = '';
+ }
+ if(preg_match("/1.5.2/i", VERSION)){
+ $this->model_d_quickcheckout_order->updateOrder152($this->session->data['order_id'], $data);
+ }elseif(preg_match("/1.5.1/i", VERSION)){
+ $this->model_d_quickcheckout_order->updateOrder151($this->session->data['order_id'], $data);
+ }else{
+ $this->model_d_quickcheckout_order->updateOrder($this->session->data['order_id'], $data);
+ }
+ }
+
+/**
+
+ * Update Order
+ */
+ function update_order() {
+ $this->debug('update_order()');
+ $this->get_total_data($total_data, $total, $taxes);
+ $data = array();
+
+ $data['invoice_prefix'] = $this->config->get('config_invoice_prefix');
+ $data['store_id'] = $this->config->get('config_store_id');
+ $data['store_name'] = $this->config->get('config_name');
+
+ if ($data['store_id']) {
+ $data['store_url'] = $this->config->get('config_url');
+ } else {
+ $data['store_url'] = HTTP_SERVER;
+ }
+
+ if ($this->customer->isLogged()) {
+ $customer_info = $this->model_account_customer->getCustomer($this->customer->getId());
+
+ $data['customer_id'] = $this->customer->getId();
+ $data['customer_group_id'] = $customer_info['customer_group_id'];
+ $data['firstname'] = $customer_info['firstname'];
+ $data['lastname'] = $customer_info['lastname'];
+ $data['email'] = $customer_info['email'];
+ $data['telephone'] = $customer_info['telephone'];
+ $data['fax'] = $customer_info['fax'];
+ $data['custom_field'] = unserialize($customer_info['custom_field']);
+
+ } elseif (isset($this->session->data['payment_address']) && isset($this->session->data['payment_address']['firstname'])) {
+
+ $data['customer_id'] = 0;
+ $data['customer_group_id'] = $this->session->data['payment_address']['customer_group_id'];
+ $data['firstname'] = $this->session->data['payment_address']['firstname'];
+ $data['lastname'] = $this->session->data['payment_address']['lastname'];
+ $data['email'] = $this->session->data['payment_address']['email'];
+ if(!$this->session->data['payment_address']['email'] || $this->session->data['payment_address']['email']==""){
+ $data['email'] =$this->settings['general']['default_email'];
+ }
+ $data['telephone'] = $this->session->data['payment_address']['telephone'];
+ $data['fax'] = $this->session->data['payment_address']['fax'];
+ $data['custom_field'] = $this->parseCustomFields($this->session->data['payment_address']);
+ } else {
+ return false;
+ }
+
+
+
+ $payment_address = $this->session->data['payment_address'];
+
+ $data['payment_firstname'] = $payment_address['firstname'];
+ $data['payment_lastname'] = $payment_address['lastname'];
+ $data['payment_company'] = $payment_address['company'];
+ $data['payment_address_1'] = $payment_address['address_1'];
+ $data['payment_address_2'] = $payment_address['address_2'];
+ $data['payment_city'] = $payment_address['city'];
+ $data['payment_postcode'] = $payment_address['postcode'];
+ $data['payment_zone'] = $payment_address['zone'];
+ $data['payment_zone_id'] = $payment_address['zone_id'];
+ $data['payment_country'] = $payment_address['country'];
+ $data['payment_country_id'] = $payment_address['country_id'];
+ $data['payment_address_format'] = $payment_address['address_format'];
+ $data['payment_custom_field'] = $this->parseCustomFields($payment_address);
+
+ if (isset($this->session->data['payment_method']['title'])) {
+ $data['payment_method'] = $this->session->data['payment_method']['title'];
+ } else {
+ $data['payment_method'] = '';
+ }
+
+ if (isset($this->session->data['payment_method']['code'])) {
+ $data['payment_code'] = $this->session->data['payment_method']['code'];
+ } else {
+ $data['payment_code'] = '';
+ }
+
+ if ($this->cart->hasShipping()) {
+ $shipping_address = $this->session->data['shipping_address'];
+ $data['shipping_firstname'] = $shipping_address['firstname'];
+ $data['shipping_lastname'] = $shipping_address['lastname'];
+ $data['shipping_company'] = $shipping_address['company'];
+ $data['shipping_address_1'] = $shipping_address['address_1'];
+ $data['shipping_address_2'] = $shipping_address['address_2'];
+ $data['shipping_city'] = $shipping_address['city'];
+ $data['shipping_postcode'] = $shipping_address['postcode'];
+ $data['shipping_zone'] = $shipping_address['zone'];
+ $data['shipping_zone_id'] = $shipping_address['zone_id'];
+ $data['shipping_country'] = $shipping_address['country'];
+ $data['shipping_country_id'] = $shipping_address['country_id'];
+ $data['shipping_address_format'] = $shipping_address['address_format'];
+ $data['shipping_custom_field'] = $this->parseCustomFields($shipping_address);
+
+ if (isset($this->session->data['shipping_method']['title'])) {
+ $data['shipping_method'] = $this->session->data['shipping_method']['title'];
+ } else {
+ $data['shipping_method'] = '';
+ }
+
+ if (isset($this->session->data['shipping_method']['code'])) {
+ $data['shipping_code'] = $this->session->data['shipping_method']['code'];
+ } else {
+ $data['shipping_code'] = '';
+ }
+ } else {
+ $data['shipping_firstname'] = '';
+ $data['shipping_lastname'] = '';
+ $data['shipping_company'] = '';
+ $data['shipping_address_1'] = '';
+ $data['shipping_address_2'] = '';
+ $data['shipping_city'] = '';
+ $data['shipping_postcode'] = '';
+ $data['shipping_zone'] = '';
+ $data['shipping_zone_id'] = '';
+ $data['shipping_country'] = '';
+ $data['shipping_country_id'] = '';
+ $data['shipping_address_format'] = '';
+ $data['shipping_method'] = '';
+ $data['shipping_code'] = '';
+ $data['shipping_custom_field'] = '';
+ }
+
+ $product_data = array();
+
+ foreach ($this->cart->getProducts() as $product) {
+ $option_data = array();
+
+ foreach ($product['option'] as $option) {
+ $option_data[] = array(
+ 'product_option_id' => $option['product_option_id'],
+ 'product_option_value_id' => $option['product_option_value_id'],
+ 'option_id' => $option['option_id'],
+ 'option_value_id' => $option['option_value_id'],
+ 'name' => $option['name'],
+ 'value' => $option['value'],
+ 'type' => $option['type']
+ );
+ }
+
+ $product_data[] = array(
+ 'product_id' => $product['product_id'],
+ 'name' => $product['name'],
+ 'model' => $product['model'],
+ 'option' => $option_data,
+ 'download' => $product['download'],
+ 'quantity' => $product['quantity'],
+ 'subtract' => $product['subtract'],
+ 'price' => $product['price'],
+ 'total' => $product['total'],
+ 'tax' => $this->tax->getTax($product['price'], $product['tax_class_id']),
+ 'reward' => $product['reward']
+ );
+ }
+
+ // Gift Voucher
+ $voucher_data = array();
+
+ if (!empty($this->session->data['vouchers'])) {
+ foreach ($this->session->data['vouchers'] as $voucher) {
+ $voucher_data[] = array(
+ 'description' => $voucher['description'],
+ 'code' => substr(md5(mt_rand()), 0, 10),
+ 'to_name' => $voucher['to_name'],
+ 'to_email' => $voucher['to_email'],
+ 'from_name' => $voucher['from_name'],
+ 'from_email' => $voucher['from_email'],
+ 'voucher_theme_id' => $voucher['voucher_theme_id'],
+ 'message' => $voucher['message'],
+ 'amount' => $voucher['amount']
+ );
+ }
+ }
+
+ $data['products'] = $product_data;
+ $data['vouchers'] = $voucher_data;
+ $data['totals'] = $total_data;
+ $data['comment'] = (isset($this->session->data['confirm']['comment'])) ? $this->session->data['confirm']['comment'] : '';
+ $data['total'] = $total;
+
+ $order_data = $this->getAffiliateAndMarketing();
+
+ $data = array_merge($data, $order_data);
+
+ // compatibility
+ if(preg_match("/1.5.1/i", VERSION)){
+ $data['reward'] = $this->cart->getTotalRewardPoints();
+ }
+
+ if (isset($this->request->cookie['tracking'])) {
+ $this->load->model('affiliate/affiliate');
+
+ $affiliate_info = $this->model_affiliate_affiliate->getAffiliateByCode($this->request->cookie['tracking']);
+ $subtotal = $this->cart->getSubTotal();
+
+ if ($affiliate_info) {
+ $data['affiliate_id'] = $affiliate_info['affiliate_id'];
+ $data['commission'] = ($subtotal / 100) * $affiliate_info['commission'];
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+ } else {
+ $data['affiliate_id'] = 0;
+ $data['commission'] = 0;
+ }
+
+ $data['language_id'] = $this->config->get('config_language_id');
+ $data['currency_id'] = $this->currency->getId();
+ $data['currency_code'] = $this->currency->getCode();
+ $data['currency_value'] = $this->currency->getValue($this->currency->getCode());
+ $data['ip'] = $this->request->server['REMOTE_ADDR'];
+
+ if (!empty($this->request->server['HTTP_X_FORWARDED_FOR'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_X_FORWARDED_FOR'];
+ } elseif(!empty($this->request->server['HTTP_CLIENT_IP'])) {
+ $data['forwarded_ip'] = $this->request->server['HTTP_CLIENT_IP'];
+ } else {
+ $data['forwarded_ip'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_USER_AGENT'])) {
+ $data['user_agent'] = $this->request->server['HTTP_USER_AGENT'];
+ } else {
+ $data['user_agent'] = '';
+ }
+
+ if (isset($this->request->server['HTTP_ACCEPT_LANGUAGE'])) {
+ $data['accept_language'] = $this->request->server['HTTP_ACCEPT_LANGUAGE'];
+ } else {
+ $data['accept_language'] = '';
+ }
+ if(preg_match("/1.5.2/i", VERSION)){
+ $this->model_d_quickcheckout_order->updateOrder152($this->session->data['order_id'], $data);
+ }elseif(preg_match("/1.5.1/i", VERSION)){
+ $this->model_d_quickcheckout_order->updateOrder151($this->session->data['order_id'], $data);
+ }else{
+
+ $this->model_d_quickcheckout_order->updateOrder($this->session->data['order_id'], $data);
+ }
+
+ }
+
+/**
+
+ * Helper: create customer
+ */
+ function create_customer($data) {
+ $this->debug('create_customer()');
+ $this->model_account_customer->addCustomer($data);
+ return true;
+ }
+
+ function get_customer_groups(){
+ $this->debug('get_customer_groups()');
+ $result = array();
+ if (is_array($this->config->get('config_customer_group_display'))) {
+
+ $this->load->model('account/customer_group');
+ $customer_groups = $this->model_account_customer_group->getCustomerGroups();
+
+ foreach ($customer_groups as $customer_group) {
+
+ //customer_group_id
+ $customer_group['value'] = $customer_group['customer_group_id'];
+ //unset($customer_group['customer_group_id']);
+
+ //name
+ $customer_group['title'] = $customer_group['name'];
+ //unset($customer_group['name']);
+
+ if (in_array($customer_group['value'], $this->config->get('config_customer_group_display'))) {
+ $result[] = $customer_group;
+ }
+ }
+ }
+
+ return $result;
+ }
+
+ private function get_countries(){
+ $this->load->model('localisation/country');
+ $countries = $this->model_localisation_country->getCountries();
+ $options = array();
+ foreach ($countries as $country){
+ $country['value'] = $country['country_id'];
+ unset($country['country_id']);
+ $options[] = $country;
+ }
+ return $options;
+
+ }
+
+
+ private function get_zones_by_country_id($country_id){
+ $this->load->model('localisation/zone');
+ $zones = $this->model_localisation_zone->getZonesByCountryId($country_id);
+ $options = array();
+ foreach ($zones as $zone){
+ $zone['value'] = $zone['zone_id'];
+ unset($zone['zone_id']);
+ $options[] = $zone;
+ }
+ return $options;
+
+ }
+
+ private function getAffiliateAndMarketing(){
+ $order_data = array();
+ if (isset($this->request->cookie['tracking'])) {
+ $order_data['tracking'] = $this->request->cookie['tracking'];
+
+ $subtotal = $this->cart->getSubTotal();
+
+ // Affiliate
+ $this->load->model('affiliate/affiliate');
+
+ $affiliate_info = $this->model_affiliate_affiliate->getAffiliateByCode($this->request->cookie['tracking']);
+
+ if ($affiliate_info) {
+ $order_data['affiliate_id'] = $affiliate_info['affiliate_id'];
+ $order_data['commission'] = ($subtotal / 100) * $affiliate_info['commission'];
+ } else {
+ $order_data['affiliate_id'] = 0;
+ $order_data['commission'] = 0;
+ }
+
+ // Marketing
+ $this->load->model('checkout/marketing');
+
+ $marketing_info = $this->model_checkout_marketing->getMarketingByCode($this->request->cookie['tracking']);
+
+ if ($marketing_info) {
+ $order_data['marketing_id'] = $marketing_info['marketing_id'];
+ } else {
+ $order_data['marketing_id'] = 0;
+ }
+ } else {
+ $order_data['affiliate_id'] = 0;
+ $order_data['commission'] = 0;
+ $order_data['marketing_id'] = 0;
+ $order_data['tracking'] = '';
+ }
+
+ return $order_data;
+ }
+
+ /*
+ * Get total data of cart
+ */
+ private function get_total_data(&$total_data, &$total, &$taxes){
+ $this->debug('get_total_data()');
+ $total_data = array();
+ $total = 0;
+ $taxes = $this->cart->getTaxes();
+ $sort_order = array();
+
+ $results = $this->model_extension_extension->getExtensions('total');
+
+ foreach ($results as $key => $value) {
+ $sort_order[$key] = $this->config->get($value['code'] . '_sort_order');
+ }
+
+ array_multisort($sort_order, SORT_ASC, $results);
+
+ foreach ($results as $result) {
+ if ($this->config->get($result['code'] . '_status')) {
+ $this->load->model('total/' . $result['code']);
+ $this->{'model_total_' . $result['code']}->getTotal($total_data, $total, $taxes);
+ }
+ }
+ $sort_order = array();
+
+ foreach ($total_data as $key => $value) {
+ $sort_order[$key] = $value['sort_order'];
+ }
+
+ array_multisort($sort_order, SORT_ASC, $total_data);
+
+ return $total_data;
+ }
+
+ /*
+ * Get shipping methods
+ */
+ private function get_shipping_methods($shipping_address){
+ $this->debug('get_shipping_methods()');
+ $quote_data = array();
+
+ $this->load->model('extension/extension');
+
+ $results = $this->model_extension_extension->getExtensions('shipping');
+
+ foreach ($results as $result) {
+ if ($this->config->get($result['code'] . '_status')) {
+ $this->load->model('shipping/' . $result['code']);
+
+ $quote = $this->{'model_shipping_' . $result['code']}->getQuote($shipping_address);
+
+ if ($quote) {
+ $quote_data[$result['code']] = array(
+ 'title' => $quote['title'],
+ 'quote' => $quote['quote'],
+ 'sort_order' => $quote['sort_order'],
+ 'error' => $quote['error']
+ );
+ }
+ }
+ }
+
+ $sort_order = array();
+
+ foreach ($quote_data as $key => $value) {
+ $sort_order[$key] = $value['sort_order'];
+ }
+
+ array_multisort($sort_order, SORT_ASC, $quote_data);
+
+ return $quote_data;
+
+ }
+ /*
+ * Get Payment Methods
+ */
+ private function get_payment_methods($payment_address){
+ $this->debug('get_payment_methods()');
+ $this->get_total_data($total_data, $total, $taxes);
+
+ $method_data = array();
+
+ $results = $this->model_extension_extension->getExtensions('payment');
+
+ foreach ($results as $result) {
+ if ($this->config->get($result['code'] . '_status')) {
+ $this->load->model('payment/' . $result['code']);
+
+ $method = $this->{'model_payment_' . $result['code']}->getMethod($payment_address, $total);
+
+ if ($method) {
+ $method_data[$result['code']] = $method;
+
+ }
+ }
+ }
+
+ $sort_order = array();
+ foreach ($method_data as $key => $value) {
+ $sort_order[$key] = $value['sort_order'];
+ }
+ array_multisort($sort_order, SORT_ASC, $method_data);
+ return $method_data;
+ }
+
+
+ public function country() {
+ $json = array();
+
+ $this->load->model('localisation/country');
+
+ $country_info = $this->model_localisation_country->getCountry($this->request->get['country_id']);
+
+ if ($country_info) {
+ $this->load->model('localisation/zone');
+
+ $json = array(
+ 'country_id' => $country_info['country_id'],
+ 'name' => $country_info['name'],
+ 'iso_code_2' => $country_info['iso_code_2'],
+ 'iso_code_3' => $country_info['iso_code_3'],
+ 'address_format' => $country_info['address_format'],
+ 'postcode_required' => $country_info['postcode_required'],
+ 'zone' => $this->model_localisation_zone->getZonesByCountryId($this->request->get['country_id']),
+ 'status' => $country_info['status']
+ );
+ }
+
+ $this->response->setOutput(json_encode($json));
+ }
+
+
+ private function get_country_data($country_id, $zone_id = 0){
+
+ $address = array();
+
+ $this->load->model('localisation/country');
+ $country_info = $this->model_localisation_country->getCountry($country_id);
+
+ if ($country_info) {
+ $address['country'] = $country_info['name'];
+ $address['iso_code_2'] = $country_info['iso_code_2'];
+ $address['iso_code_3'] = $country_info['iso_code_3'];
+ $address['address_format'] = $country_info['address_format'];
+ } else {
+ $address['country'] = '';
+ $address['iso_code_2'] = '';
+ $address['iso_code_3'] = '';
+ $address['address_format'] = '';
+ }
+
+ $this->load->model('localisation/zone');
+ $zone_info = $this->model_localisation_zone->getZone($zone_id);
+
+ if ($zone_info) {
+ $address['zone'] = $zone_info['name'];
+ $address['zone_code'] = $zone_info['code'];
+ } else {
+ $address['zone'] = '';
+ $address['zone_code'] = '';
+ }
+ return $address;
+ }
+
+
+ public function update_settings(){
+ $this->debug('update_settings()');
+ $this->load_settings();
+ $json = array();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $json['success'] = $this->session->data;
+ }else{
+ $json['error'] = 'error';
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+ }
+
+
+/**
+
+ * Ajax Functions
+
+ */
+/**
+ * Ajax: Validate login. Load_settings not needed
+ */
+ public function login_validate() {
+ $this->language->load('checkout/checkout');
+
+ $json = array();
+ $this->settings = $this->get_settings();
+
+ //check password
+ if (!$this->customer->login($this->request->post['email'], $this->request->post['password'])) {
+ $json['error']['warning'] = $this->language->get('error_login');
+ }
+
+ $this->load->model('account/customer');
+ $customer_info = $this->model_account_customer->getCustomerByEmail($this->request->post['email']);
+
+ //validate is approved
+ if ($customer_info && !$customer_info['approved']) {
+ $json['error']['warning'] = $this->language->get('error_approved');
+ }
+
+ if (!$json) {
+ unset($this->session->data['guest']);
+
+ // Default Addresses
+ $this->load->model('account/address');
+
+ $address_info = $this->model_account_address->getAddress($this->customer->getAddressId());
+
+ if ($address_info) {
+ if ($this->config->get('config_tax_customer') == 'shipping') {
+ $this->session->data['shipping_country_id'] = $address_info['country_id'];
+ $this->session->data['shipping_zone_id'] = $address_info['zone_id'];
+ $this->session->data['shipping_postcode'] = $address_info['postcode'];
+ }
+
+ if ($this->config->get('config_tax_customer') == 'payment') {
+ $this->session->data['payment_country_id'] = $address_info['country_id'];
+ $this->session->data['payment_zone_id'] = $address_info['zone_id'];
+ }
+ $this->session->data['payment_address'] = array_merge($this->session->data['payment_address'],$address_info);
+ $this->session->data['shipping_address'] = array_merge($this->session->data['shipping_address'],$address_info);
+ $this->session->data['payment_address']['exists'] = 1;
+ $this->session->data['shipping_address']['exists'] = 1;
+ } else {
+ unset($this->session->data['shipping_country_id']);
+ unset($this->session->data['shipping_zone_id']);
+ unset($this->session->data['shipping_postcode']);
+ unset($this->session->data['payment_country_id']);
+ unset($this->session->data['payment_zone_id']);
+ }
+
+ $json['reload'] = $this->settings['general']['login_refresh'];
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+ }
+
+ public function refresh(){
+ $this->load_settings();
+ $this->response->setOutput($this->index());
+ }
+
+ /*
+ * Get login view
+ */
+ public function refresh_payments(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+
+
+ //Get shipping method
+ $this->data['get_shipping_method_view'] = $this->get_shipping_method_view();
+
+ //Get payment method
+ $this->data['get_payment_method_view'] = $this->get_payment_method_view();
+
+ //Get cart view
+ $this->data['get_confirm_view'] = $this->get_confirm_view();
+ }
+ $this->response->setOutput($this->index());
+ }
+ /*
+ * Get views by ajax request
+ */
+ public function refresh_step1(){
+ $this->load_settings();
+ if(($this->cart->hasProducts() || !empty($this->session->data['vouchers'])) && !$this->customer->isLogged()){
+ $this->response->setOutput($this->get_login_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+ public function refresh_step2(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_payment_address_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+ public function refresh_step3(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_shipping_address_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+ public function refresh_step4(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_shipping_method_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+ public function refresh_step5(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_payment_method_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+ public function refresh_step6(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_cart_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+
+ public function refresh_step7(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_payment_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+
+ public function refresh_step8(){
+ $this->load_settings();
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->response->setOutput($this->get_confirm_view());
+ }else{
+ $this->response->setOutput(false);
+ }
+ }
+
+ /*
+ * function for validating the fields input data
+ */
+ public function validate_field(){
+ $this->response->addHeader('Content-Type: application/json');
+ $json = array();
+ if(isset($this->request->post['field'])){
+ $this->load_settings();
+
+ $field = explode("[", $this->request->post['field']);
+ $field[1] =str_replace("]", "", $field[1]);
+ $settings = $this->array_merge_recursive_distinct($this->settings['step'][$field[0]], $this->settings['option'][$this->session->data['account']][$field[0]]);
+
+ if(isset($settings['fields'][$field[1]]['error'])){
+ foreach ($settings['fields'][$field[1]]['error'] as $error){
+ if($this->invalid($this->request->post['value'], $error)){
+ if(is_array($error['text'])){
+ $json['error'] = (isset($error['text'][(int)$this->config->get('config_language_id')])) ? $error['text'][(int)$this->config->get('config_language_id')] : $error['text'][1];
+ }else{
+ $json['error'] = $this->language->get($error['text']);
+ }
+ if(isset($error['information_id']) && !empty($json['error'])){
+ $this->load->model('catalog/information');
+ $information_info = $this->model_catalog_information->getInformation($error['information_id']);
+ $json['error'] = sprintf($json['error'], $information_info['title']);
+ }
+ $this->response->setOutput(json_encode($json));
+ break;
+ }
+ }
+ }
+
+ }
+ $json['success'] = true;
+ $this->response->setOutput(json_encode($json));
+ }
+
+ /*
+ * function for validating all required fields
+ */
+ public function validate_all_fields(){
+ $this->load->model('catalog/information');
+ $json = array();
+ $this->load_settings();
+
+ foreach($this->request->post as $step => $data){
+ if(isset($this->request->post[$step])){
+ $settings = $this->array_merge_recursive_distinct($this->settings['step'][$step], $this->settings['option'][$this->session->data['account']][$step]);
+ foreach($this->request->post[$step] as $key => $value){
+ if(isset($settings['fields'][$key]['error'])){
+ foreach ($settings['fields'][$key]['error'] as $error){
+ if($this->invalid($value, $error)){
+ if(is_array($error['text'])){
+ $json['error'][$step][$key] = (isset($error['text'][(int)$this->config->get('config_language_id')])) ? $error['text'][(int)$this->config->get('config_language_id')] : $error['text'][1];
+ }else{
+ $json['error'][$step][$key] = $this->language->get($error['text']);
+ }
+ }
+ if(isset($error['information_id']) && !empty($json['error'][$step][$key])){
+ $information_info = $this->model_catalog_information->getInformation($error['information_id']);
+ $json['error'][$step][$key] = sprintf($json['error'][$step][$key], $information_info['title']);
+ }
+ }
+ }
+ }
+ }
+ }
+ //shipping
+ if(empty($this->session->data['shipping_methods']) && $this->settings['step']['shipping_method']['display']){
+ $json['error']['shipping_method']['error_warning'] = sprintf($this->language->get('error_no_shipping'), $this->url->link('information/contact'));
+ }
+ //payment
+ if(empty($this->session->data['payment_methods']) && $this->settings['step']['payment_method']['display']){
+ $json['error']['payment_method']['error_warning'] = sprintf($this->language->get('error_no_payment'), $this->url->link('information/contact'));
+ }
+
+ //Confirm
+ if(!$this->cart->hasStock() && $this->config->get('config_stock_warning')){
+ if(!$this->config->get('config_stock_checkout')){
+ $json['error']['confirm']['error_warning']['error_stock'] = $this->language->get('error_stock');
+ }
+ }
+ if(!$this->session->data['min_order']){
+ $json['error']['confirm']['error_warning']['error_min_order'] = sprintf($this->settings['general']['min_order']['text'][(int)$this->config->get('config_language_id')], $this->currency->format($this->settings['general']['min_order']['value']));
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+ }
+
+ public function validate_coupon() {
+ $this->language->load('checkout/coupon');
+ $json = array();
+ $this->load->model('checkout/coupon');
+
+ if(!empty($this->request->post['coupon'])){
+ $coupon_info = $this->model_checkout_coupon->getCoupon($this->request->post['coupon']);
+
+ if (!$coupon_info) {
+ $json['error'] = $this->language->get('error_coupon');
+ }
+ }else{
+ $json['error'] = $this->language->get('error_coupon');
+ }
+
+ if (!isset($json['error'])){
+ $json['success'] = $this->language->get('text_coupon');
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+
+ }
+
+ public function validate_voucher() {
+ $this->language->load('checkout/voucher');
+ $json = array();
+ $this->load->model('checkout/voucher');
+
+ if(!empty($this->request->post['voucher'])){
+ $voucher_info = $this->model_checkout_voucher->getVoucher($this->request->post['voucher']);
+ if (!$voucher_info) {
+ $json['error']= $this->language->get('error_voucher');
+ }
+ }else{
+ $json['error']= $this->language->get('error_voucher');
+ }
+
+ if (!isset($json['error'])){
+ $json['success'] = $this->language->get('text_voucher');
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+ }
+
+ public function validate_reward() {
+ $this->language->load('checkout/reward');
+ $json = array();
+ $points = $this->customer->getRewardPoints();
+
+ $points_total = 0;
+
+ if(!empty($this->request->post['reward'])){
+
+ foreach ($this->cart->getProducts() as $product) {
+ if ($product['points']) {
+ $points_total += $product['points'];
+ }
+ }
+
+ if ($this->request->post['reward'] > $points) {
+ $json['error'] = sprintf($this->language->get('error_points'), $this->request->post['reward']);
+ }
+
+ if ($this->request->post['reward'] > $points_total) {
+ $json['error'] = sprintf($this->language->get('error_maximum'), $points_total);
+ }
+ }else{
+ $json['error']= $this->language->get('error_reward');
+ }
+
+ if (!isset($json['error'])){
+ $json['success'] = $this->language->get('text_reward');
+ }
+ $this->response->addHeader('Content-Type: application/json');
+ $this->response->setOutput(json_encode($json));
+ }
+
+ public function get_vouchers_total(){
+ $total = 0;
+
+ if (isset($this->session->data['vouchers'])) {
+ foreach ($this->session->data['vouchers'] as $voucher) {
+ $total += $voucher['amount'];
+ }
+ }
+ return $total;
+ }
+
+/**
+
+ * Helper functions
+
+ */
+ /*
+ * helper function for validating the fields input data
+ */
+ public function invalid($value, $data = array()){
+ $result = false;
+
+
+ if(isset($data['not_empty'])){
+ $result = (empty($value)) ? true : false;
+ }
+ if(isset($data['min_length']) && !$result){
+ $result = (utf8_strlen($value) < $data['min_length']) ? true : false;
+ }
+ if(isset($data['max_length']) && !$result){
+ $result = (utf8_strlen($value) > $data['max_length']) ? true : false;
+ }
+ if(isset($data['vat_address']) && !$result){
+ $result = (vat_validation($this->session->data[$data['vat_address']]['iso_code_2'], $value) == 'invalid') ? true : false;
+ }
+ if(isset($data['compare_to']) && !$result){
+ $field = explode("[", $data['compare_to']);
+ $field[1] =str_replace("]", "", $field[1]);
+ $data['compare_to'] = (isset($this->session->data[$field[0]][$field[1]])) ? $this->session->data[$field[0]][$field[1]]: '';
+ $result = ($value != $data['compare_to']) ? true : false;
+ }
+ if(isset($data['regex']) && !$result){
+ $result = (!preg_match($data['regex'], $value)) ? true : false;
+ }
+ if(isset($data['email_exists']) && !$result){
+ $result = ($this->model_account_customer->getTotalCustomersByEmail($value)) ? true : false;
+ }
+ if(isset($data['checked']) && !$result){
+ $result =(!$value);
+ }
+
+ return $result ;
+ }
+ public function language_merge($array, $texts){
+ $this->load->model('catalog/information');
+ $array_full = $array;
+ $result = array();
+
+ $result = $this->cache->get('d_quickcheckout.language_merge.' . (int)$this->config->get('config_language_id') . '.' . (int)$this->config->get('config_store_id') . '.' . md5(serialize($array)) . '.' . md5(serialize($texts)));
+
+ if(!$result){
+ foreach ($array as $key => $value){
+ foreach ($texts as $text){
+ if(isset($array_full[$text])){
+ if(!is_array($array_full[$text])){
+ $result[$text] = $this->language->get($array_full[$text]);
+ }else{
+ if(isset($array_full[$text][(int)$this->config->get('config_language_id')])){
+ $result[$text] = $array_full[$text][(int)$this->config->get('config_language_id')];
+ }else{
+ $result[$text] = current($array_full[$text]);
+ }
+ }
+ if((strpos($result[$text], '%s') !== false) && isset($array_full['information_id'])){
+ $information_info = $this->model_catalog_information->getInformation($array_full['information_id']);
+
+ if(isset($information_info['title']) && substr_count($result[$text], '%s') == 2){
+ $result[$text] = sprintf($result[$text], $this->url->link('information/information/agree', 'information_id=' . $array_full['information_id'], 'SSL'), $information_info['title']);
+ }
+ }
+ }
+ }
+ if(is_array($array_full[$key])){
+ $result[$key] = $this->language_merge_loop($array_full[$key], $texts);
+ }
+
+ }
+ $this->cache->set('d_quickcheckout.language_merge.' . (int)$this->config->get('config_language_id') . '.' . (int)$this->config->get('config_store_id') . '.' . md5(serialize($array)) . '.' . md5(serialize($texts)), $result);
+ }
+
+ return $result;
+
+ }
+
+ public function language_merge_loop($array, $texts){
+ $this->load->model('catalog/information');
+ $array_full = $array;
+ $result = array();
+ foreach ($array as $key => $value){
+ foreach ($texts as $text){
+ if(isset($array_full[$text])){
+ if(!is_array($array_full[$text])){
+ $result[$text] = $this->language->get($array_full[$text]);
+ } else {
+ if(isset($array_full[$text][(int)$this->config->get('config_language_id')])){
+ $result[$text] = $array_full[$text][(int)$this->config->get('config_language_id')];
+ } else {
+ $result[$text] = current($array_full[$text]);
+ }
+ }
+ if((strpos($result[$text], '%s') !== false) && isset($array_full['information_id'])){
+ $information_info = $this->model_catalog_information->getInformation($array_full['information_id']);
+ if (strpos($result[$text], 'url->link('information/information/agree', 'information_id=' . $array_full['information_id'], 'SSL'), $information_info['title']);
+ }
+ } elseif (substr_count($result[$text], '%s') == 1 && isset($information_info['title'])) {
+ $result[$text] = sprintf($result[$text], $information_info['title']);
+ }
+
+ }
+ }
+ }
+ if(is_array($array_full[$key])){
+ $result[$key] = $this->language_merge_loop($array_full[$key], $texts);
+ }
+
+ }
+
+ return $result;
+
+ }
+
+ public function array_merge_recursive_distinct( array &$array1, array &$array2 ){
+ $merged = $array1;
+ $result = array();
+ $result = $this->cache->get('d_quickcheckout.array_merge_recursive_distinct.' . (int)$this->config->get('config_language_id') . '.' . (int)$this->config->get('config_store_id') . '.' . md5(serialize($array1)) . '.' . md5(serialize($array2)));
+ if(!$result){
+ foreach ($array2 as $key => &$value) {
+ if (is_array($value) && isset($merged[$key]) && is_array($merged[$key])){
+ $merged [$key] = $this->array_merge_recursive_distinct_loop($merged[$key], $value);
+ }else{
+ $merged [$key] = $value;
+ }
+ }
+ $this->cache->set('d_quickcheckout.array_merge_recursive_distinct.' . (int)$this->config->get('config_language_id') . '.' . (int)$this->config->get('config_store_id') . '.' . md5(serialize($array1)) . '.' . md5(serialize($array2)), $merged);
+ $result = $merged;
+ }
+ return $result;
+ }
+
+ public function array_merge_recursive_distinct_loop( array &$array1, array &$array2 )
+ {
+ $merged = $array1;
+ foreach ( $array2 as $key => &$value )
+ {
+ if ( is_array ( $value ) && isset ( $merged [$key] ) && is_array ( $merged [$key] ) )
+ {
+ $merged [$key] = $this->array_merge_recursive_distinct_loop ( $merged [$key], $value );
+ }
+ else
+ {
+ $merged [$key] = $value;
+ }
+ }
+
+ return $merged;
+ }
+
+ public function isInstalled($code) {
+ $extension_data = array();
+
+ $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "extension WHERE `code` = '" . $this->db->escape($code) . "'");
+
+ if($query->row) {
+ return true;
+ }else{
+ return false;
+ }
+ }
+
+ public function is_guest_checkout_allowed(){
+ return ($this->config->get('config_checkout_guest')
+ && !$this->config->get('config_customer_price')
+ && !$this->cart->hasDownload());
+ }
+
+
+ /**
+ * Used by index()
+ */
+ private function load_head_files(){
+ //Load Scripts
+ //$this->document->addScript('catalog/view/javascript/jquery/colorbox/jquery.colorbox-min.js');
+ $this->document->addScript('catalog/view/javascript/d_quickcheckout/jquery.timer.js');
+ $this->document->addScript('catalog/view/javascript/d_quickcheckout/tinysort/jquery.tinysort.min.js');
+
+ if($this->settings['design']['uniform']){
+ $this->document->addScript('catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.js');
+ $this->document->addStyle('catalog/view/javascript/d_quickcheckout/uniform/css/uniform.default.css');
+ }
+ $this->document->addScript('catalog/view/javascript/d_quickcheckout/tooltip/tooltip.js');
+ $this->document->addScript('catalog/view/javascript/d_quickcheckout/spin.min.js');
+ $this->document->addStyle('catalog/view/theme/default/stylesheet/d_quickcheckout/icon/styles.css');
+
+ //switchery
+ // $this->document->addScript('catalog/view/javascript/d_quickcheckout/switchery/switchery.min.js');
+ // $this->document->addStyle('catalog/view/javascript/d_quickcheckout/switchery/switchery.min.css');
+
+
+ //Load Styles
+ //$this->document->addStyle('catalog/view/javascript/jquery/colorbox/colorbox.css');
+ if (file_exists('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/d_quickcheckout.css')) {
+ $this->document->addStyle('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/d_quickcheckout.css?'.date('m'));
+ } else {
+ $this->document->addStyle('catalog/view/theme/default/stylesheet/d_quickcheckout/d_quickcheckout.css?'.date('m'));
+ }
+
+ if (file_exists('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/mobile.css')) {
+ $this->document->addStyle('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/mobile.css?'.date('m'));
+ } else {
+ $this->document->addStyle('catalog/view/theme/default/stylesheet/d_quickcheckout/mobile.css?'.date('m'));
+ }
+
+ if (file_exists('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/theme/'.$this->settings['design']['theme'].'.css')) {
+ $this->document->addStyle('catalog/view/theme/' . $this->config->get('config_template') . '/stylesheet/d_quickcheckout/theme/'.$this->settings['design']['theme'].'.css?'.date('m'));
+ } else {
+ $this->document->addStyle('catalog/view/theme/default/stylesheet/d_quickcheckout/theme/'.$this->settings['design']['theme'].'.css?'.date('m'));
+ }
+
+ $this->document->addLink('//fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,700italic,400,300,700&subset=latin,cyrillic', "stylesheet");
+ }
+
+/**
+ * Used by index()
+ */
+ private function validate(){
+ $result = false;
+ if($this->cart->hasProducts() || !empty($this->session->data['vouchers'])){
+ $this->load->model('setting/setting');
+ $result = $this->model_setting_setting->getSetting('d_quickcheckout', $this->config->get('config_store_id'));
+ if($result){
+ $result = true;
+ }
+ }
+ return $result;
+ }
+/**
+ * Used by index()
+ */
+ private function get_logo(){
+ if (isset($this->request->server['HTTPS']) && (($this->request->server['HTTPS'] == 'on') || ($this->request->server['HTTPS'] == '1'))) {
+ $server = $this->config->get('config_ssl');
+ } else {
+ $server = $this->config->get('config_url');
+ }
+
+ if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
+ $logo = $server . 'image/' . $this->config->get('config_logo');
+ } else {
+ $logo = '';
+ }
+
+ return $logo;
+ }
+
+/**
+ * Used by load_settings()
+ */
+ private function get_settings(){
+ if(!isset($this->session->data['qc_settings'])){
+ $this->set_settings();
+ }
+
+ return $this->session->data['qc_settings'];
+ }
+
+ private function check_order_id(){
+ if(isset($this->session->data['order_id'])){
+ $this->load->model('checkout/order');
+ $order_info = $this->model_checkout_order->getOrder($this->session->data['order_id']);
+
+ if ($order_info && $order_info['order_status_id']) {
+ unset($this->session->data['order_id']);
+ }
+ }
+ }
+
+ private function clear_session(){
+ if($this->settings['general']['clear_session']){
+ unset($this->session->data['payment_address']);
+ unset($this->session->data['shipping_address']);
+ }
+ }
+
+/**
+ * Used by load_settings()
+ */
+ private function set_settings(){
+ $this->settings = $this->config->get('d_quickcheckout');
+ $this->config->load('d_quickcheckout');
+ $settings = $this->config->get('d_quickcheckout_settings');
+ $settings['general']['default_email'] = $this->config->get('config_email');
+ $settings['step']['payment_address']['fields']['agree']['information_id'] = $this->config->get('config_account_id');
+ $settings['step']['payment_address']['fields']['agree']['error'][0]['information_id'] = $this->config->get('config_account_id');
+ $settings['step']['confirm']['fields']['agree']['information_id'] = $this->config->get('config_checkout_id');
+ $settings['step']['confirm']['fields']['agree']['error'][0]['information_id'] = $this->config->get('config_checkout_id');
+
+ // Custom Fields
+
+ $custom_fields_account = $this->getCustomFields('account');
+ $custom_fields_address = $this->getCustomFields('address');
+
+ $settings['step']['payment_address']['fields'] = array_merge($settings['step']['payment_address']['fields'], $custom_fields_account);
+ $settings['step']['payment_address']['fields'] = array_merge($settings['step']['payment_address']['fields'], $custom_fields_address);
+ $settings['step']['shipping_address']['fields'] = array_merge($settings['step']['shipping_address']['fields'], $custom_fields_address);
+
+ if(!empty($this->settings)){
+ $this->session->data['qc_settings'] = $this->array_merge_recursive_distinct($settings, $this->settings);
+ }else{
+ $this->session->data['qc_settings'] = $settings;
+ }
+
+
+ foreach($this->session->data['qc_settings']['option'] as $account => $value){
+ $this->session->data['qc_settings']['option'][$account] = $this->array_merge_recursive_distinct( $this->session->data['qc_settings']['step'], $this->session->data['qc_settings']['option'][$account]);
+ $lang = $this->language_merge($this->session->data['qc_settings']['option'][$account], $this->texts);
+ $this->session->data['qc_settings']['option'][$account] = $this->array_merge_recursive_distinct($this->session->data['qc_settings']['option'][$account], $lang);
+
+ foreach($this->session->data['qc_settings']['option'][$account] as $step => $value){
+ if(isset($this->session->data['qc_settings']['option'][$account][$step]['fields'])){
+ $sort_order = array();
+ foreach ($this->session->data['qc_settings']['option'][$account][$step]['fields'] as $key => $value) {
+ if(isset($value['sort_order'])){
+ $sort_order[$key] = $value['sort_order'];
+ }else{
+ unset($this->session->data['qc_settings']['option'][$account][$step]['fields'][$key]);
+ }
+ }
+ array_multisort($sort_order, SORT_ASC, $this->session->data['qc_settings']['option'][$account][$step]['fields']);
+ }
+ }
+ $this->session->data['qc_settings']['option'][$account]['payment_address']['fields']['newsletter']['title'] = sprintf($this->session->data['qc_settings']['option'][$account]['payment_address']['fields']['newsletter']['title'], $this->config->get('config_name'));
+ }
+
+
+ $this->session->data['qc_settings'] = $this->array_merge_recursive_distinct($this->session->data['qc_settings'], $this->settings);
+ $this->session->data['qc_settings']['step']['payment_method']['cost'] = $this->get_d_payment_fee();
+
+ return $this->session->data['qc_settings'];
+
+ }
+/* [1] => Array (
+ [custom_field_id] => 2
+ [custom_field_value] => Array (
+ [0] => Array (
+ [custom_field_value_id] => 2
+ [name] => test
+ )
+ [1] => Array (
+ [custom_field_value_id] => 3
+ [name] => go home
+ )
+ )
+ [name] => another option
+ [type] => radio
+ [value] =>
+ [location] => account / address
+ [required] =>
+ [sort_order] => 1
+ )
+ */
+
+ private function getCustomFields($location = 0, $customer_group = 0){
+ $this->load->model('account/custom_field');
+ $custom_fields = $this->model_account_custom_field->getCustomFields($customer_group);
+ $customer_groups = $this->get_customer_groups();
+ $fields = array();
+
+ foreach($custom_fields as $key => $custom_field){
+ if($location == $custom_field['location']){
+
+ $display = array();
+ $require = array();
+ foreach($customer_groups as $group){
+ $display[$group['customer_group_id']] = 0;
+ $require[$group['customer_group_id']] = 0;
+ }
+
+ $custom_field_query = $this->db->query("SELECT * FROM `" . DB_PREFIX . "custom_field_customer_group`
+ WHERE custom_field_id = '" . (int)$custom_field['custom_field_id'] . "'");
+ foreach ($custom_field_query->rows as $custom_field_display) {
+
+ $display[$custom_field_display['customer_group_id']] = 1;
+ $require[$custom_field_display['customer_group_id']] = $custom_field_display['required'];
+ }
+
+ $fields['custom_field_'.$custom_field['custom_field_id']] = array(
+ 'id' => 'custom_field_'.$custom_field['custom_field_id'],
+ 'title' => $custom_field['name'],
+ 'tooltip' => '',
+ 'error' => array(0 => array('min_length' => 1,
+ 'max_length' => 32,
+ 'text' => 'error_custom_field')),
+ 'type' => $custom_field['type'],
+ 'refresh' => '0',
+ 'custom' => 1,
+ 'display' => $display,
+ 'value' => $custom_field['value'],
+ 'require' => $require,
+ 'sort_order' => $custom_field['sort_order'],
+ 'class' => ''
+ );
+ foreach($custom_field['custom_field_value'] as $option){
+ $fields['custom_field_'.$custom_field['custom_field_id']]['options'][] = array(
+ 'title' => $option['name'],
+ 'value' => $option['custom_field_value_id']
+ );
+ }
+ }
+
+ }
+ return $fields;
+ }
+ private function parseCustomFields($data = array()){
+ $data = $this->preg_grep_keys("custom_field_", $data);
+ return $data;
+
+ }
+ private function preg_grep_keys( $pattern, $input, $flags = 0 )
+ {
+ $keys = preg_grep( "/".$pattern."/i", array_keys( $input ), $flags );
+ $vals = array();
+ foreach ( $keys as $key )
+ {
+ $vals[str_replace($pattern,'',$key)] = $input[$key];
+ }
+ return $vals;
+ }
+/**
+ * Used by get_login_view()
+ */
+ private function get_social_login_providers(){
+ $this->document->addStyle('catalog/view/theme/default/stylesheet/d_social_login/styles.css');
+ $this->load->language('module/d_social_login');
+
+ $this->session->data['d_social_login']['return_url'] = $this->getCurrentUrl();
+
+ $this->data['button_sign_in'] = $this->language->get('button_sign_in');
+ $this->config->load($this->check_d_social_login());
+ $social_login_settings = $this->config->get('d_social_login_settings');
+
+ $social_login = $this->array_merge_recursive_distinct($social_login_settings, $this->settings['general']['social_login']);
+ $providers = $social_login['providers'];
+
+ $sort_order = array();
+ foreach ($providers as $key => $value) {
+ if(isset($value['sort_order'])){
+ $sort_order[$key] = $value['sort_order'];
+ }else{
+ unset($providers[$key]);
+ }
+ }
+ array_multisort($sort_order, SORT_ASC, $providers);
+
+ $data = $providers;
+ foreach($providers as $key => $val) {
+ $data[$key]['heading'] = $this->language->get('text_sign_in_with_'.$val['id']);
+ }
+
+ return $data;
+ }
+/**
+ * Used by get_social_login_providers()
+ */
+ public function check_d_social_login(){
+ if($this->isInstalled('d_social_login')){
+ $full = DIR_SYSTEM . "config/d_social_login_settings.php";
+ $light = DIR_SYSTEM . "config/d_social_login_light_settings.php";
+ if (file_exists($full)) {
+ return 'd_social_login_settings';
+ } elseif (file_exists($light)) {
+ return 'd_social_login_light_settings';
+ }else{
+ return false;
+ }
+ }else{
+ return false;
+ }
+
+ }
+
+ public function get_d_payment_fee(){
+ if($this->config->get('d_payment_fee_module')){
+ $modules = $this->config->get('d_payment_fee_module');
+ return $modules;
+ }
+ return false;
+ }
+/**
+ * Used by get_login_view()
+ */
+ public static function getCurrentUrl( $request_uri = true )
+ {
+ if(
+ isset( $_SERVER['HTTPS'] ) && ( $_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1 )
+ || isset( $_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https'
+ ){
+ $protocol = 'https://';
+ }
+ else {
+ $protocol = 'http://';
+ }
+
+ $url = $protocol . $_SERVER['HTTP_HOST'];
+
+ if( isset( $_SERVER['SERVER_PORT'] ) && strpos( $url, ':'.$_SERVER['SERVER_PORT'] ) === FALSE ) {
+ $url .= ($protocol === 'http://' && $_SERVER['SERVER_PORT'] != 80 && !isset( $_SERVER['HTTP_X_FORWARDED_PROTO']))
+ || ($protocol === 'https://' && $_SERVER['SERVER_PORT'] != 443 && !isset( $_SERVER['HTTP_X_FORWARDED_PROTO']))
+ ? ':' . $_SERVER['SERVER_PORT']
+ : '';
+ }
+
+ if( $request_uri ){
+ $url .= $_SERVER['REQUEST_URI'];
+ }
+ else{
+ $url .= $_SERVER['PHP_SELF'];
+ }
+
+ // return current url
+ return $url;
+ }
+
+
+ public function after_load_settings(){
+ if(isset($this->session->data['payment_method']['title'])){
+ if(strpos($this->session->data['payment_method']['title'], 'larna Factuur') ){
+ $this->db->query("UPDATE `" . DB_PREFIX . "order` SET `payment_method` = '" . $this->db->escape('Klarna Factuur') . "' WHERE `order_id` = " . (int)$this->session->data['order_id']);
+ }
+
+ if(strpos($this->session->data['payment_method']['title'], 'larna Invoice') ){
+ $this->db->query("UPDATE `" . DB_PREFIX . "order` SET `payment_method` = '" . $this->db->escape('Klarna Invoice') . "' WHERE `order_id` = " . (int)$this->session->data['order_id']);
+ }
+ }
+
+ }
+}
+
+
+?>
\ No newline at end of file
diff --git a/catalog/language/english/module/d_quickcheckout.php b/catalog/language/english/module/d_quickcheckout.php
new file mode 100755
index 0000000..639e564
--- /dev/null
+++ b/catalog/language/english/module/d_quickcheckout.php
@@ -0,0 +1,39 @@
+
\ No newline at end of file
diff --git a/catalog/model/d_quickcheckout/order.php b/catalog/model/d_quickcheckout/order.php
new file mode 100755
index 0000000..0212f09
--- /dev/null
+++ b/catalog/model/d_quickcheckout/order.php
@@ -0,0 +1,319 @@
+db->query("INSERT INTO `" . DB_PREFIX . "order` SET
+ store_id = '" . (int)$data['store_id'] . "',
+ store_name = '" . $this->db->escape($data['store_name']) . "',
+ store_url = '" . $this->db->escape($data['store_url']) . "',
+ total = '" . (float)$data['total'] . "',
+ affiliate_id = '" . (int)$data['affiliate_id'] . "',
+ commission = '" . (float)$data['commission'] . "',
+ language_id = '" . (int)$data['language_id'] . "',
+ currency_id = '" . (int)$data['currency_id'] . "',
+ currency_code = '" . $this->db->escape($data['currency_code']) . "',
+ currency_value = '" . (float)$data['currency_value'] . "',
+ ip = '" . $this->db->escape($data['ip']) . "',
+ forwarded_ip = '" . $this->db->escape($data['forwarded_ip']) . "',
+ user_agent = '" . $this->db->escape($data['user_agent']) . "',
+ accept_language = '" . $this->db->escape($data['accept_language']) . "',
+ date_added = NOW(),
+ date_modified = NOW()");
+ $order_id = $this->db->getLastId();
+ return $order_id;
+}
+
+// public function addOrder151($data) {
+// $this->db->query("INSERT INTO `" . DB_PREFIX . "order` SET
+// store_id = '" . (int)$data['store_id'] . "',
+// store_name = '" . $this->db->escape($data['store_name']) . "',
+// store_url = '" . $this->db->escape($data['store_url']) . "',
+// total = '" . (float)$data['total'] . "',
+// affiliate_id = '" . (int)$data['affiliate_id'] . "',
+// commission = '" . (float)$data['commission'] . "',
+// language_id = '" . (int)$data['language_id'] . "',
+// currency_id = '" . (int)$data['currency_id'] . "',
+// currency_code = '" . $this->db->escape($data['currency_code']) . "',
+// currency_value = '" . (float)$data['currency_value'] . "',
+// ip = '" . $this->db->escape($data['ip']) . "',
+// date_added = NOW(),
+// date_modified = NOW()");
+// $order_id = $this->db->getLastId();
+// return $order_id;
+// }
+
+public function updateOrder($order_id,$data) {
+ $this->event->trigger('pre.order.add', $data);
+
+ $this->db->query("UPDATE `" . DB_PREFIX . "order` SET
+ invoice_prefix = '" . $this->db->escape($data['invoice_prefix']) . "',
+ store_id = '" . (int)$data['store_id'] . "',
+ store_name = '" . $this->db->escape($data['store_name']) . "',
+ store_url = '" . $this->db->escape($data['store_url']) . "',
+ customer_id = '" . (int)$data['customer_id'] . "',
+ customer_group_id = '" . (int)$data['customer_group_id'] . "',
+ firstname = '" . $this->db->escape($data['firstname']) . "',
+ lastname = '" . $this->db->escape($data['lastname']) . "',
+ email = '" . $this->db->escape($data['email']) . "',
+ telephone = '" . $this->db->escape($data['telephone']) . "',
+ fax = '" . $this->db->escape($data['fax']) . "',
+ custom_field = '" . $this->db->escape(isset($data['custom_field']) ? serialize($data['custom_field']) : '') . "',
+ payment_firstname = '" . $this->db->escape($data['payment_firstname']) . "',
+ payment_lastname = '" . $this->db->escape($data['payment_lastname']) . "',
+ payment_company = '" . $this->db->escape($data['payment_company']) . "',
+ payment_address_1 = '" . $this->db->escape($data['payment_address_1']) . "',
+ payment_address_2 = '" . $this->db->escape($data['payment_address_2']) . "',
+ payment_city = '" . $this->db->escape($data['payment_city']) . "',
+ payment_postcode = '" . $this->db->escape($data['payment_postcode']) . "',
+ payment_country = '" . $this->db->escape($data['payment_country']) . "',
+ payment_country_id = '" . (int)$data['payment_country_id'] . "',
+ payment_zone = '" . $this->db->escape($data['payment_zone']) . "',
+ payment_zone_id = '" . (int)$data['payment_zone_id'] . "',
+ payment_address_format = '" . $this->db->escape($data['payment_address_format']) . "',
+ payment_custom_field = '" . $this->db->escape(isset($data['payment_custom_field']) ? serialize($data['payment_custom_field']) : '') . "',
+ payment_method = '" . $this->db->escape($data['payment_method']) . "',
+ payment_code = '" . $this->db->escape($data['payment_code']) . "',
+ shipping_firstname = '" . $this->db->escape($data['shipping_firstname']) . "',
+ shipping_lastname = '" . $this->db->escape($data['shipping_lastname']) . "',
+ shipping_company = '" . $this->db->escape($data['shipping_company']) . "',
+ shipping_address_1 = '" . $this->db->escape($data['shipping_address_1']) . "',
+ shipping_address_2 = '" . $this->db->escape($data['shipping_address_2']) . "',
+ shipping_city = '" . $this->db->escape($data['shipping_city']) . "',
+ shipping_postcode = '" . $this->db->escape($data['shipping_postcode']) . "',
+ shipping_country = '" . $this->db->escape($data['shipping_country']) . "',
+ shipping_country_id = '" . (int)$data['shipping_country_id'] . "',
+ shipping_zone = '" . $this->db->escape($data['shipping_zone']) . "',
+ shipping_zone_id = '" . (int)$data['shipping_zone_id'] . "',
+ shipping_address_format = '" . $this->db->escape($data['shipping_address_format']) . "',
+ shipping_custom_field = '" . $this->db->escape(isset($data['shipping_custom_field']) ? serialize($data['shipping_custom_field']) : '') . "',
+ shipping_method = '" . $this->db->escape($data['shipping_method']) . "',
+ shipping_code = '" . $this->db->escape($data['shipping_code']) . "',
+ comment = '" . $this->db->escape($data['comment']) . "',
+ total = '" . (float)$data['total'] . "',
+ affiliate_id = '" . (int)$data['affiliate_id'] . "',
+ commission = '" . (float)$data['commission'] . "',
+ marketing_id = '" . (int)$data['marketing_id'] . "',
+ tracking = '" . $this->db->escape($data['tracking']) . "',
+ language_id = '" . (int)$data['language_id'] . "',
+ currency_id = '" . (int)$data['currency_id'] . "',
+ currency_code = '" . $this->db->escape($data['currency_code']) . "',
+ currency_value = '" . (float)$data['currency_value'] . "',
+ ip = '" . $this->db->escape($data['ip']) . "',
+ forwarded_ip = '" . $this->db->escape($data['forwarded_ip']) . "',
+ user_agent = '" . $this->db->escape($data['user_agent']) . "',
+ accept_language = '" . $this->db->escape($data['accept_language']) . "',
+ date_added = NOW(),
+ date_modified = NOW()
+ WHERE order_id = '" . (int)$order_id . "'");
+
+ $this->db->query("DELETE FROM " . DB_PREFIX . "order_product WHERE order_id = '" . (int)$order_id . "'");
+ $this->db->query("DELETE FROM " . DB_PREFIX . "order_option WHERE order_id = '" . (int)$order_id . "'");
+
+
+ // Products
+ foreach ($data['products'] as $product) {
+ $this->db->query("INSERT INTO " . DB_PREFIX . "order_product SET order_id = '" . (int)$order_id . "', product_id = '" . (int)$product['product_id'] . "', name = '" . $this->db->escape($product['name']) . "', model = '" . $this->db->escape($product['model']) . "', quantity = '" . (int)$product['quantity'] . "', price = '" . (float)$product['price'] . "', total = '" . (float)$product['total'] . "', tax = '" . (float)$product['tax'] . "', reward = '" . (int)$product['reward'] . "'");
+
+ $order_product_id = $this->db->getLastId();
+
+ foreach ($product['option'] as $option) {
+ $this->db->query("INSERT INTO " . DB_PREFIX . "order_option SET order_id = '" . (int)$order_id . "', order_product_id = '" . (int)$order_product_id . "', product_option_id = '" . (int)$option['product_option_id'] . "', product_option_value_id = '" . (int)$option['product_option_value_id'] . "', name = '" . $this->db->escape($option['name']) . "', `value` = '" . $this->db->escape($option['value']) . "', `type` = '" . $this->db->escape($option['type']) . "'");
+ }
+ }
+
+ // Gift Voucher
+ $this->load->model('checkout/voucher');
+
+ $this->db->query("DELETE FROM " . DB_PREFIX . "order_voucher WHERE order_id = '" . (int)$order_id . "'");
+
+ // Vouchers
+ foreach ($data['vouchers'] as $voucher) {
+ $this->db->query("INSERT INTO " . DB_PREFIX . "order_voucher SET order_id = '" . (int)$order_id . "', description = '" . $this->db->escape($voucher['description']) . "', code = '" . $this->db->escape($voucher['code']) . "', from_name = '" . $this->db->escape($voucher['from_name']) . "', from_email = '" . $this->db->escape($voucher['from_email']) . "', to_name = '" . $this->db->escape($voucher['to_name']) . "', to_email = '" . $this->db->escape($voucher['to_email']) . "', voucher_theme_id = '" . (int)$voucher['voucher_theme_id'] . "', message = '" . $this->db->escape($voucher['message']) . "', amount = '" . (float)$voucher['amount'] . "'");
+
+ $order_voucher_id = $this->db->getLastId();
+
+ $voucher_id = $this->model_checkout_voucher->addVoucher($order_id, $voucher);
+
+ $this->db->query("UPDATE " . DB_PREFIX . "order_voucher SET voucher_id = '" . (int)$voucher_id . "' WHERE order_voucher_id = '" . (int)$order_voucher_id . "'");
+ }
+
+ // Totals
+ $this->db->query("DELETE FROM " . DB_PREFIX . "order_total WHERE order_id = '" . (int)$order_id . "'");
+ foreach ($data['totals'] as $total) {
+ $this->db->query("INSERT INTO " . DB_PREFIX . "order_total SET order_id = '" . (int)$order_id . "', code = '" . $this->db->escape($total['code']) . "', title = '" . $this->db->escape($total['title']) . "', `value` = '" . (float)$total['value'] . "', sort_order = '" . (int)$total['sort_order'] . "'");
+ }
+
+ $this->event->trigger('post.order.add', $order_id);
+
+ return $order_id;
+ }
+ // public function updateOrder152($order_id, $data) {
+ // $this->db->query("UPDATE `" . DB_PREFIX . "order` SET
+ // invoice_prefix = '" . $this->db->escape($data['invoice_prefix']) . "',
+ // store_id = '" . (int)$data['store_id'] . "',
+ // store_name = '" . $this->db->escape($data['store_name']) . "',
+ // store_url = '" . $this->db->escape($data['store_url']) . "',
+ // customer_id = '" . (int)$data['customer_id'] . "',
+ // customer_group_id = '" . (int)$data['customer_group_id'] . "',
+ // firstname = '" . $this->db->escape($data['firstname']) . "',
+ // lastname = '" . $this->db->escape($data['lastname']) . "',
+ // email = '" . $this->db->escape($data['email']) . "',
+ // telephone = '" . $this->db->escape($data['telephone']) . "',
+ // fax = '" . $this->db->escape($data['fax']) . "',
+ // shipping_firstname = '" . $this->db->escape($data['shipping_firstname']) . "',
+ // shipping_lastname = '" . $this->db->escape($data['shipping_lastname']) . "',
+ // shipping_company = '" . $this->db->escape($data['shipping_company']) . "',
+ // shipping_address_1 = '" . $this->db->escape($data['shipping_address_1']) . "',
+ // shipping_address_2 = '" . $this->db->escape($data['shipping_address_2']) . "',
+ // shipping_city = '" . $this->db->escape($data['shipping_city']) . "',
+ // shipping_postcode = '" . $this->db->escape($data['shipping_postcode']) . "',
+ // shipping_country = '" . $this->db->escape($data['shipping_country']) . "',
+ // shipping_country_id = '" . (int)$data['shipping_country_id'] . "',
+ // shipping_zone = '" . $this->db->escape($data['shipping_zone']) . "',
+ // shipping_zone_id = '" . (int)$data['shipping_zone_id'] . "',
+ // shipping_address_format = '" . $this->db->escape($data['shipping_address_format']) . "',
+ // shipping_method = '" . $this->db->escape($data['shipping_method']) . "',
+ // shipping_code = '" . $this->db->escape($data['shipping_code']) . "',
+ // payment_firstname = '" . $this->db->escape($data['payment_firstname']) . "',
+ // payment_lastname = '" . $this->db->escape($data['payment_lastname']) . "',
+ // payment_company = '" . $this->db->escape($data['payment_company']) . "',
+ // payment_address_1 = '" . $this->db->escape($data['payment_address_1']) . "',
+ // payment_address_2 = '" . $this->db->escape($data['payment_address_2']) . "',
+ // payment_city = '" . $this->db->escape($data['payment_city']) . "',
+ // payment_postcode = '" . $this->db->escape($data['payment_postcode']) . "',
+ // payment_country = '" . $this->db->escape($data['payment_country']) . "',
+ // payment_country_id = '" . (int)$data['payment_country_id'] . "',
+ // payment_zone = '" . $this->db->escape($data['payment_zone']) . "',
+ // payment_zone_id = '" . (int)$data['payment_zone_id'] . "',
+ // payment_address_format = '" . $this->db->escape($data['payment_address_format']) . "',
+ // payment_method = '" . $this->db->escape($data['payment_method']) . "',
+ // payment_code = '" . $this->db->escape($data['payment_code']) . "',
+ // comment = '" . $this->db->escape($data['comment']) . "',
+ // total = '" . (float)$data['total'] . "',
+ // affiliate_id = '" . (int)$data['affiliate_id'] . "',
+ // commission = '" . (float)$data['commission'] . "',
+ // language_id = '" . (int)$data['language_id'] . "',
+ // currency_id = '" . (int)$data['currency_id'] . "',
+ // currency_code = '" . $this->db->escape($data['currency_code']) . "',
+ // currency_value = '" . (float)$data['currency_value'] . "',
+ // ip = '" . $this->db->escape($data['ip']) . "',
+ // forwarded_ip = '" . $this->db->escape($data['forwarded_ip']) . "',
+ // user_agent = '" . $this->db->escape($data['user_agent']) . "',
+ // accept_language = '" . $this->db->escape($data['accept_language']) . "',
+ // date_added = NOW(),
+ // date_modified = NOW()
+ // WHERE order_id = '" . (int)$order_id . "'");
+
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_product WHERE order_id = '" . (int)$order_id . "'");
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_option WHERE order_id = '" . (int)$order_id . "'");
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_download WHERE order_id = '" . (int)$order_id . "'");
+
+ // foreach ($data['products'] as $product) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_product SET order_id = '" . (int)$order_id . "', product_id = '" . (int)$product['product_id'] . "', name = '" . $this->db->escape($product['name']) . "', model = '" . $this->db->escape($product['model']) . "', quantity = '" . (int)$product['quantity'] . "', price = '" . (float)$product['price'] . "', total = '" . (float)$product['total'] . "', tax = '" . (float)$product['tax'] . "', reward = '" . (int)$product['reward'] . "'");
+
+ // $order_product_id = $this->db->getLastId();
+
+ // foreach ($product['option'] as $option) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_option SET order_id = '" . (int)$order_id . "', order_product_id = '" . (int)$order_product_id . "', product_option_id = '" . (int)$option['product_option_id'] . "', product_option_value_id = '" . (int)$option['product_option_value_id'] . "', name = '" . $this->db->escape($option['name']) . "', `value` = '" . $this->db->escape($option['value']) . "', `type` = '" . $this->db->escape($option['type']) . "'");
+ // }
+
+ // foreach ($product['download'] as $download) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_download SET order_id = '" . (int)$order_id . "', order_product_id = '" . (int)$order_product_id . "', name = '" . $this->db->escape($download['name']) . "', filename = '" . $this->db->escape($download['filename']) . "', mask = '" . $this->db->escape($download['mask']) . "', remaining = '" . (int)($download['remaining'] * $product['quantity']) . "'");
+ // }
+ // }
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_voucher WHERE order_id = '" . (int)$order_id . "'");
+
+ // foreach ($data['vouchers'] as $voucher) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_voucher SET order_id = '" . (int)$order_id . "', description = '" . $this->db->escape($voucher['description']) . "', code = '" . $this->db->escape($voucher['code']) . "', from_name = '" . $this->db->escape($voucher['from_name']) . "', from_email = '" . $this->db->escape($voucher['from_email']) . "', to_name = '" . $this->db->escape($voucher['to_name']) . "', to_email = '" . $this->db->escape($voucher['to_email']) . "', voucher_theme_id = '" . (int)$voucher['voucher_theme_id'] . "', message = '" . $this->db->escape($voucher['message']) . "', amount = '" . (float)$voucher['amount'] . "'");
+ // }
+
+ // $total = 0;
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_total WHERE order_id = '" . (int)$order_id . "'");
+
+ // foreach ($data['totals'] as $total) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_total SET order_id = '" . (int)$order_id . "', code = '" . $this->db->escape($total['code']) . "', title = '" . $this->db->escape($total['title']) . "', text = '" . $this->db->escape($total['text']) . "', `value` = '" . (float)$total['value'] . "', sort_order = '" . (int)$total['sort_order'] . "'");
+ // }
+
+ // return $order_id;
+ // }
+ // public function updateOrder151($order_id, $data) {
+ // // compatibility - removed: , reward = '" . (float)$data['reward'] . "',
+ // $this->db->query("UPDATE `" . DB_PREFIX . "order` SET
+ // invoice_prefix = '" . $this->db->escape($data['invoice_prefix']) . "',
+ // store_id = '" . (int)$data['store_id'] . "',
+ // store_name = '" . $this->db->escape($data['store_name']) . "',
+ // store_url = '" . $this->db->escape($data['store_url']) . "',
+ // customer_id = '" . (int)$data['customer_id'] . "',
+ // customer_group_id = '" . (int)$data['customer_group_id'] . "',
+ // firstname = '" . $this->db->escape($data['firstname']) . "',
+ // lastname = '" . $this->db->escape($data['lastname']) . "',
+ // email = '" . $this->db->escape($data['email']) . "',
+ // telephone = '" . $this->db->escape($data['telephone']) . "',
+ // fax = '" . $this->db->escape($data['fax']) . "',
+ // shipping_firstname = '" . $this->db->escape($data['shipping_firstname']) . "',
+ // shipping_lastname = '" . $this->db->escape($data['shipping_lastname']) . "',
+ // shipping_company = '" . $this->db->escape($data['shipping_company']) . "',
+ // shipping_address_1 = '" . $this->db->escape($data['shipping_address_1']) . "',
+ // shipping_address_2 = '" . $this->db->escape($data['shipping_address_2']) . "',
+ // shipping_city = '" . $this->db->escape($data['shipping_city']) . "',
+ // shipping_postcode = '" . $this->db->escape($data['shipping_postcode']) . "',
+ // shipping_country = '" . $this->db->escape($data['shipping_country']) . "',
+ // shipping_country_id = '" . (int)$data['shipping_country_id'] . "',
+ // shipping_zone = '" . $this->db->escape($data['shipping_zone']) . "',
+ // shipping_zone_id = '" . (int)$data['shipping_zone_id'] . "',
+ // shipping_address_format = '" . $this->db->escape($data['shipping_address_format']) . "',
+ // shipping_method = '" . $this->db->escape($data['shipping_method']) . "',
+ // payment_firstname = '" . $this->db->escape($data['payment_firstname']) . "',
+ // payment_lastname = '" . $this->db->escape($data['payment_lastname']) . "',
+ // payment_company = '" . $this->db->escape($data['payment_company']) . "',
+ // payment_address_1 = '" . $this->db->escape($data['payment_address_1']) . "',
+ // payment_address_2 = '" . $this->db->escape($data['payment_address_2']) . "',
+ // payment_city = '" . $this->db->escape($data['payment_city']) . "',
+ // payment_postcode = '" . $this->db->escape($data['payment_postcode']) . "',
+ // payment_country = '" . $this->db->escape($data['payment_country']) . "',
+ // payment_country_id = '" . (int)$data['payment_country_id'] . "',
+ // payment_zone = '" . $this->db->escape($data['payment_zone']) . "',
+ // payment_zone_id = '" . (int)$data['payment_zone_id'] . "',
+ // payment_address_format = '" . $this->db->escape($data['payment_address_format']) . "',
+ // payment_method = '" . $this->db->escape($data['payment_method']) . "',
+ // comment = '" . $this->db->escape($data['comment']) . "',
+ // total = '" . (float)$data['total'] . "',
+ // affiliate_id = '" . (int)$data['affiliate_id'] . "',
+ // commission = '" . (float)$data['commission'] . "',
+ // language_id = '" . (int)$data['language_id'] . "',
+ // currency_id = '" . (int)$data['currency_id'] . "',
+ // currency_code = '" . $this->db->escape($data['currency_code']) . "',
+ // currency_value = '" . (float)$data['currency_value'] . "',
+ // ip = '" . $this->db->escape($data['ip']) . "',
+ // date_added = NOW(),
+ // date_modified = NOW()
+ // WHERE order_id = '" . (int)$order_id . "'");
+
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_product WHERE order_id = '" . (int)$order_id . "'");
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_option WHERE order_id = '" . (int)$order_id . "'");
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_download WHERE order_id = '" . (int)$order_id . "'");
+
+ // foreach ($data['products'] as $product) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_product SET order_id = '" . (int)$order_id . "', product_id = '" . (int)$product['product_id'] . "', name = '" . $this->db->escape($product['name']) . "', model = '" . $this->db->escape($product['model']) . "', quantity = '" . (int)$product['quantity'] . "', price = '" . (float)$product['price'] . "', total = '" . (float)$product['total'] . "', tax = '" . (float)$product['tax'] . "'");
+
+ // $order_product_id = $this->db->getLastId();
+
+ // foreach ($product['option'] as $option) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_option SET order_id = '" . (int)$order_id . "', order_product_id = '" . (int)$order_product_id . "', product_option_id = '" . (int)$option['product_option_id'] . "', product_option_value_id = '" . (int)$option['product_option_value_id'] . "', name = '" . $this->db->escape($option['name']) . "', `value` = '" . $this->db->escape($option['value']) . "', `type` = '" . $this->db->escape($option['type']) . "'");
+ // }
+
+ // foreach ($product['download'] as $download) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_download SET order_id = '" . (int)$order_id . "', order_product_id = '" . (int)$order_product_id . "', name = '" . $this->db->escape($download['name']) . "', filename = '" . $this->db->escape($download['filename']) . "', mask = '" . $this->db->escape($download['mask']) . "', remaining = '" . (int)($download['remaining'] * $product['quantity']) . "'");
+ // }
+ // }
+ // $total = 0;
+ // $this->db->query("DELETE FROM " . DB_PREFIX . "order_total WHERE order_id = '" . (int)$order_id . "'");
+
+ // foreach ($data['totals'] as $total) {
+ // $this->db->query("INSERT INTO " . DB_PREFIX . "order_total SET order_id = '" . (int)$order_id . "', code = '" . $this->db->escape($total['code']) . "', title = '" . $this->db->escape($total['title']) . "', text = '" . $this->db->escape($total['text']) . "', `value` = '" . (float)$total['value'] . "', sort_order = '" . (int)$total['sort_order'] . "'");
+ // }
+
+ // return $order_id;
+ // }
+}
+?>
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/jquery.timer.js b/catalog/view/javascript/d_quickcheckout/jquery.timer.js
new file mode 100755
index 0000000..68880dd
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/jquery.timer.js
@@ -0,0 +1,111 @@
+/**
+ * jquery.timer.js
+ *
+ * Copyright (c) 2011 Jason Chavannes
+ *
+ * http://jchavannes.com/jquery-timer
+ *
+ * Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use, copy,
+ * modify, merge, publish, distribute, sublicense, and/or sell copies
+ * of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+;(function($) {
+ $.timer = function(func, time, autostart) {
+ this.set = function(func, time, autostart) {
+ this.init = true;
+ if(typeof func == 'object') {
+ var paramList = ['autostart', 'time'];
+ for(var arg in paramList) {if(func[paramList[arg]] != undefined) {eval(paramList[arg] + " = func[paramList[arg]]");}};
+ func = func.action;
+ }
+ if(typeof func == 'function') {this.action = func;}
+ if(!isNaN(time)) {this.intervalTime = time;}
+ if(autostart && !this.isActive) {
+ this.isActive = true;
+ this.setTimer();
+ }
+ return this;
+ };
+ this.once = function(time) {
+ var timer = this;
+ if(isNaN(time)) {time = 0;}
+ window.setTimeout(function() {timer.action();}, time);
+ return this;
+ };
+ this.play = function(reset) {
+ if(!this.isActive) {
+ if(reset) {this.setTimer();}
+ else {this.setTimer(this.remaining);}
+ this.isActive = true;
+ }
+ return this;
+ };
+ this.pause = function() {
+ if(this.isActive) {
+ this.isActive = false;
+ this.remaining -= new Date() - this.last;
+ this.clearTimer();
+ }
+ return this;
+ };
+ this.stop = function() {
+ this.isActive = false;
+ this.remaining = this.intervalTime;
+ this.clearTimer();
+ return this;
+ };
+ this.toggle = function(reset) {
+ if(this.isActive) {this.pause();}
+ else if(reset) {this.play(true);}
+ else {this.play();}
+ return this;
+ };
+ this.reset = function() {
+ this.isActive = false;
+ this.play(true);
+ return this;
+ };
+ this.clearTimer = function() {
+ window.clearTimeout(this.timeoutObject);
+ };
+ this.setTimer = function(time) {
+ var timer = this;
+ if(typeof this.action != 'function') {return;}
+ if(isNaN(time)) {time = this.intervalTime;}
+ this.remaining = time;
+ this.last = new Date();
+ this.clearTimer();
+ this.timeoutObject = window.setTimeout(function() {timer.go();}, time);
+ };
+ this.go = function() {
+ if(this.isActive) {
+ this.action();
+ this.setTimer();
+ }
+ };
+
+ if(this.init) {
+ return new $.timer(func, time, autostart);
+ } else {
+ this.set(func, time, autostart);
+ return this;
+ }
+ };
+})(jQuery);
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/spin.min.js b/catalog/view/javascript/d_quickcheckout/spin.min.js
new file mode 100755
index 0000000..6d2cf30
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/spin.min.js
@@ -0,0 +1,68 @@
+//fgnass.github.com/spin.js#v2.0.0
+!function(a,b){"object"==typeof exports?module.exports=b():"function"==typeof define&&define.amd?define(b):a.Spinner=b()}(this,function(){"use strict";function a(a,b){var c,d=document.createElement(a||"div");for(c in b)d[c]=b[c];return d}function b(a){for(var b=1,c=arguments.length;c>b;b++)a.appendChild(arguments[b]);return a}function c(a,b,c,d){var e=["opacity",b,~~(100*a),c,d].join("-"),f=.01+c/d*100,g=Math.max(1-(1-a)/b*(100-f),a),h=j.substring(0,j.indexOf("Animation")).toLowerCase(),i=h&&"-"+h+"-"||"";return l[e]||(m.insertRule("@"+i+"keyframes "+e+"{0%{opacity:"+g+"}"+f+"%{opacity:"+a+"}"+(f+.01)+"%{opacity:1}"+(f+b)%100+"%{opacity:"+a+"}100%{opacity:"+g+"}}",m.cssRules.length),l[e]=1),e}function d(a,b){var c,d,e=a.style;for(b=b.charAt(0).toUpperCase()+b.slice(1),d=0;d',c)}m.addRule(".spin-vml","behavior:url(#default#VML)"),h.prototype.lines=function(a,d){function f(){return e(c("group",{coordsize:k+" "+k,coordorigin:-j+" "+-j}),{width:k,height:k})}function h(a,h,i){b(m,b(e(f(),{rotation:360/d.lines*a+"deg",left:~~h}),b(e(c("roundrect",{arcsize:d.corners}),{width:j,height:d.width,left:d.radius,top:-d.width>>1,filter:i}),c("fill",{color:g(d.color,a),opacity:d.opacity}),c("stroke",{opacity:0}))))}var i,j=d.length+d.width,k=2*j,l=2*-(d.width+d.length)+"px",m=e(f(),{position:"absolute",top:l,left:l});if(d.shadow)for(i=1;i<=d.lines;i++)h(i,-2,"progid:DXImageTransform.Microsoft.Blur(pixelradius=2,makeshadow=1,shadowopacity=.3)");for(i=1;i<=d.lines;i++)h(i);return b(a,m)},h.prototype.opacity=function(a,b,c,d){var e=a.firstChild;d=d.shadow&&d.lines||0,e&&b+d>1)+"px"})}for(var i,k=0,l=(f.lines-1)*(1-f.direction)/2;k small {
+ background: #fff;
+ border-radius: 100%;
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
+ height: 30px;
+ position: absolute;
+ top: 0;
+ width: 30px;
+}
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/switchery/switchery.js b/catalog/view/javascript/d_quickcheckout/switchery/switchery.js
new file mode 100755
index 0000000..22a708b
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/switchery/switchery.js
@@ -0,0 +1,1393 @@
+;(function(){
+
+/**
+ * Require the given path.
+ *
+ * @param {String} path
+ * @return {Object} exports
+ * @api public
+ */
+
+function require(path, parent, orig) {
+ var resolved = require.resolve(path);
+
+ // lookup failed
+ if (null == resolved) {
+ orig = orig || path;
+ parent = parent || 'root';
+ var err = new Error('Failed to require "' + orig + '" from "' + parent + '"');
+ err.path = orig;
+ err.parent = parent;
+ err.require = true;
+ throw err;
+ }
+
+ var module = require.modules[resolved];
+
+ // perform real require()
+ // by invoking the module's
+ // registered function
+ if (!module._resolving && !module.exports) {
+ var mod = {};
+ mod.exports = {};
+ mod.client = mod.component = true;
+ module._resolving = true;
+ module.call(this, mod.exports, require.relative(resolved), mod);
+ delete module._resolving;
+ module.exports = mod.exports;
+ }
+
+ return module.exports;
+}
+
+/**
+ * Registered modules.
+ */
+
+require.modules = {};
+
+/**
+ * Registered aliases.
+ */
+
+require.aliases = {};
+
+/**
+ * Resolve `path`.
+ *
+ * Lookup:
+ *
+ * - PATH/index.js
+ * - PATH.js
+ * - PATH
+ *
+ * @param {String} path
+ * @return {String} path or null
+ * @api private
+ */
+
+require.resolve = function(path) {
+ if (path.charAt(0) === '/') path = path.slice(1);
+
+ var paths = [
+ path,
+ path + '.js',
+ path + '.json',
+ path + '/index.js',
+ path + '/index.json'
+ ];
+
+ for (var i = 0; i < paths.length; i++) {
+ var path = paths[i];
+ if (require.modules.hasOwnProperty(path)) return path;
+ if (require.aliases.hasOwnProperty(path)) return require.aliases[path];
+ }
+};
+
+/**
+ * Normalize `path` relative to the current path.
+ *
+ * @param {String} curr
+ * @param {String} path
+ * @return {String}
+ * @api private
+ */
+
+require.normalize = function(curr, path) {
+ var segs = [];
+
+ if ('.' != path.charAt(0)) return path;
+
+ curr = curr.split('/');
+ path = path.split('/');
+
+ for (var i = 0; i < path.length; ++i) {
+ if ('..' == path[i]) {
+ curr.pop();
+ } else if ('.' != path[i] && '' != path[i]) {
+ segs.push(path[i]);
+ }
+ }
+
+ return curr.concat(segs).join('/');
+};
+
+/**
+ * Register module at `path` with callback `definition`.
+ *
+ * @param {String} path
+ * @param {Function} definition
+ * @api private
+ */
+
+require.register = function(path, definition) {
+ require.modules[path] = definition;
+};
+
+/**
+ * Alias a module definition.
+ *
+ * @param {String} from
+ * @param {String} to
+ * @api private
+ */
+
+require.alias = function(from, to) {
+ if (!require.modules.hasOwnProperty(from)) {
+ throw new Error('Failed to alias "' + from + '", it does not exist');
+ }
+ require.aliases[to] = from;
+};
+
+/**
+ * Return a require function relative to the `parent` path.
+ *
+ * @param {String} parent
+ * @return {Function}
+ * @api private
+ */
+
+require.relative = function(parent) {
+ var p = require.normalize(parent, '..');
+
+ /**
+ * lastIndexOf helper.
+ */
+
+ function lastIndexOf(arr, obj) {
+ var i = arr.length;
+ while (i--) {
+ if (arr[i] === obj) return i;
+ }
+ return -1;
+ }
+
+ /**
+ * The relative require() itself.
+ */
+
+ function localRequire(path) {
+ var resolved = localRequire.resolve(path);
+ return require(resolved, parent, path);
+ }
+
+ /**
+ * Resolve relative to the parent.
+ */
+
+ localRequire.resolve = function(path) {
+ var c = path.charAt(0);
+ if ('/' == c) return path.slice(1);
+ if ('.' == c) return require.normalize(p, path);
+
+ // resolve deps by returning
+ // the dep in the nearest "deps"
+ // directory
+ var segs = parent.split('/');
+ var i = lastIndexOf(segs, 'deps') + 1;
+ if (!i) i = 0;
+ path = segs.slice(0, i + 1).join('/') + '/deps/' + path;
+ return path;
+ };
+
+ /**
+ * Check if module is defined at `path`.
+ */
+
+ localRequire.exists = function(path) {
+ return require.modules.hasOwnProperty(localRequire.resolve(path));
+ };
+
+ return localRequire;
+};
+require.register("abpetkov-transitionize/transitionize.js", function(exports, require, module){
+
+/**
+ * Transitionize 0.0.3
+ * https://github.com/abpetkov/transitionize
+ *
+ * Authored by Alexander Petkov
+ * https://github.com/abpetkov
+ *
+ * Copyright 2013, Alexander Petkov
+ * License: The MIT License (MIT)
+ * http://opensource.org/licenses/MIT
+ *
+ */
+
+/**
+ * Expose `Transitionize`.
+ */
+
+module.exports = Transitionize;
+
+/**
+ * Initialize new Transitionize.
+ *
+ * @param {Object} element
+ * @param {Object} props
+ * @api public
+ */
+
+function Transitionize(element, props) {
+ if (!(this instanceof Transitionize)) return new Transitionize(element, props);
+
+ this.element = element;
+ this.props = props || {};
+ this.init();
+}
+
+/**
+ * Detect if Safari.
+ *
+ * @returns {Boolean}
+ * @api private
+ */
+
+Transitionize.prototype.isSafari = function() {
+ return (/Safari/).test(navigator.userAgent) && (/Apple Computer/).test(navigator.vendor);
+};
+
+/**
+ * Loop though the object and push the keys and values in an array.
+ * Apply the CSS3 transition to the element and prefix with -webkit- for Safari.
+ *
+ * @api private
+ */
+
+Transitionize.prototype.init = function() {
+ var transitions = [];
+
+ for (var key in this.props) {
+ transitions.push(key + ' ' + this.props[key]);
+ }
+
+ this.element.style.transition = transitions.join(', ');
+ if (this.isSafari()) this.element.style.webkitTransition = transitions.join(', ');
+};
+});
+require.register("ftlabs-fastclick/lib/fastclick.js", function(exports, require, module){
+/**
+ * @preserve FastClick: polyfill to remove click delays on browsers with touch UIs.
+ *
+ * @version 0.6.11
+ * @codingstandard ftlabs-jsv2
+ * @copyright The Financial Times Limited [All Rights Reserved]
+ * @license MIT License (see LICENSE.txt)
+ */
+
+/*jslint browser:true, node:true*/
+/*global define, Event, Node*/
+
+
+/**
+ * Instantiate fast-clicking listeners on the specificed layer.
+ *
+ * @constructor
+ * @param {Element} layer The layer to listen on
+ */
+function FastClick(layer) {
+ 'use strict';
+ var oldOnClick, self = this;
+
+
+ /**
+ * Whether a click is currently being tracked.
+ *
+ * @type boolean
+ */
+ this.trackingClick = false;
+
+
+ /**
+ * Timestamp for when when click tracking started.
+ *
+ * @type number
+ */
+ this.trackingClickStart = 0;
+
+
+ /**
+ * The element being tracked for a click.
+ *
+ * @type EventTarget
+ */
+ this.targetElement = null;
+
+
+ /**
+ * X-coordinate of touch start event.
+ *
+ * @type number
+ */
+ this.touchStartX = 0;
+
+
+ /**
+ * Y-coordinate of touch start event.
+ *
+ * @type number
+ */
+ this.touchStartY = 0;
+
+
+ /**
+ * ID of the last touch, retrieved from Touch.identifier.
+ *
+ * @type number
+ */
+ this.lastTouchIdentifier = 0;
+
+
+ /**
+ * Touchmove boundary, beyond which a click will be cancelled.
+ *
+ * @type number
+ */
+ this.touchBoundary = 10;
+
+
+ /**
+ * The FastClick layer.
+ *
+ * @type Element
+ */
+ this.layer = layer;
+
+ if (!layer || !layer.nodeType) {
+ throw new TypeError('Layer must be a document node');
+ }
+
+ /** @type function() */
+ this.onClick = function() { return FastClick.prototype.onClick.apply(self, arguments); };
+
+ /** @type function() */
+ this.onMouse = function() { return FastClick.prototype.onMouse.apply(self, arguments); };
+
+ /** @type function() */
+ this.onTouchStart = function() { return FastClick.prototype.onTouchStart.apply(self, arguments); };
+
+ /** @type function() */
+ this.onTouchMove = function() { return FastClick.prototype.onTouchMove.apply(self, arguments); };
+
+ /** @type function() */
+ this.onTouchEnd = function() { return FastClick.prototype.onTouchEnd.apply(self, arguments); };
+
+ /** @type function() */
+ this.onTouchCancel = function() { return FastClick.prototype.onTouchCancel.apply(self, arguments); };
+
+ if (FastClick.notNeeded(layer)) {
+ return;
+ }
+
+ // Set up event handlers as required
+ if (this.deviceIsAndroid) {
+ layer.addEventListener('mouseover', this.onMouse, true);
+ layer.addEventListener('mousedown', this.onMouse, true);
+ layer.addEventListener('mouseup', this.onMouse, true);
+ }
+
+ layer.addEventListener('click', this.onClick, true);
+ layer.addEventListener('touchstart', this.onTouchStart, false);
+ layer.addEventListener('touchmove', this.onTouchMove, false);
+ layer.addEventListener('touchend', this.onTouchEnd, false);
+ layer.addEventListener('touchcancel', this.onTouchCancel, false);
+
+ // Hack is required for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
+ // which is how FastClick normally stops click events bubbling to callbacks registered on the FastClick
+ // layer when they are cancelled.
+ if (!Event.prototype.stopImmediatePropagation) {
+ layer.removeEventListener = function(type, callback, capture) {
+ var rmv = Node.prototype.removeEventListener;
+ if (type === 'click') {
+ rmv.call(layer, type, callback.hijacked || callback, capture);
+ } else {
+ rmv.call(layer, type, callback, capture);
+ }
+ };
+
+ layer.addEventListener = function(type, callback, capture) {
+ var adv = Node.prototype.addEventListener;
+ if (type === 'click') {
+ adv.call(layer, type, callback.hijacked || (callback.hijacked = function(event) {
+ if (!event.propagationStopped) {
+ callback(event);
+ }
+ }), capture);
+ } else {
+ adv.call(layer, type, callback, capture);
+ }
+ };
+ }
+
+ // If a handler is already declared in the element's onclick attribute, it will be fired before
+ // FastClick's onClick handler. Fix this by pulling out the user-defined handler function and
+ // adding it as listener.
+ if (typeof layer.onclick === 'function') {
+
+ // Android browser on at least 3.2 requires a new reference to the function in layer.onclick
+ // - the old one won't work if passed to addEventListener directly.
+ oldOnClick = layer.onclick;
+ layer.addEventListener('click', function(event) {
+ oldOnClick(event);
+ }, false);
+ layer.onclick = null;
+ }
+}
+
+
+/**
+ * Android requires exceptions.
+ *
+ * @type boolean
+ */
+FastClick.prototype.deviceIsAndroid = navigator.userAgent.indexOf('Android') > 0;
+
+
+/**
+ * iOS requires exceptions.
+ *
+ * @type boolean
+ */
+FastClick.prototype.deviceIsIOS = /iP(ad|hone|od)/.test(navigator.userAgent);
+
+
+/**
+ * iOS 4 requires an exception for select elements.
+ *
+ * @type boolean
+ */
+FastClick.prototype.deviceIsIOS4 = FastClick.prototype.deviceIsIOS && (/OS 4_\d(_\d)?/).test(navigator.userAgent);
+
+
+/**
+ * iOS 6.0(+?) requires the target element to be manually derived
+ *
+ * @type boolean
+ */
+FastClick.prototype.deviceIsIOSWithBadTarget = FastClick.prototype.deviceIsIOS && (/OS ([6-9]|\d{2})_\d/).test(navigator.userAgent);
+
+
+/**
+ * Determine whether a given element requires a native click.
+ *
+ * @param {EventTarget|Element} target Target DOM element
+ * @returns {boolean} Returns true if the element needs a native click
+ */
+FastClick.prototype.needsClick = function(target) {
+ 'use strict';
+ switch (target.nodeName.toLowerCase()) {
+
+ // Don't send a synthetic click to disabled inputs (issue #62)
+ case 'button':
+ case 'select':
+ case 'textarea':
+ if (target.disabled) {
+ return true;
+ }
+
+ break;
+ case 'input':
+
+ // File inputs need real clicks on iOS 6 due to a browser bug (issue #68)
+ if ((this.deviceIsIOS && target.type === 'file') || target.disabled) {
+ return true;
+ }
+
+ break;
+ case 'label':
+ case 'video':
+ return true;
+ }
+
+ return (/\bneedsclick\b/).test(target.className);
+};
+
+
+/**
+ * Determine whether a given element requires a call to focus to simulate click into element.
+ *
+ * @param {EventTarget|Element} target Target DOM element
+ * @returns {boolean} Returns true if the element requires a call to focus to simulate native click.
+ */
+FastClick.prototype.needsFocus = function(target) {
+ 'use strict';
+ switch (target.nodeName.toLowerCase()) {
+ case 'textarea':
+ return true;
+ case 'select':
+ return !this.deviceIsAndroid;
+ case 'input':
+ switch (target.type) {
+ case 'button':
+ case 'checkbox':
+ case 'file':
+ case 'image':
+ case 'radio':
+ case 'submit':
+ return false;
+ }
+
+ // No point in attempting to focus disabled inputs
+ return !target.disabled && !target.readOnly;
+ default:
+ return (/\bneedsfocus\b/).test(target.className);
+ }
+};
+
+
+/**
+ * Send a click event to the specified element.
+ *
+ * @param {EventTarget|Element} targetElement
+ * @param {Event} event
+ */
+FastClick.prototype.sendClick = function(targetElement, event) {
+ 'use strict';
+ var clickEvent, touch;
+
+ // On some Android devices activeElement needs to be blurred otherwise the synthetic click will have no effect (#24)
+ if (document.activeElement && document.activeElement !== targetElement) {
+ document.activeElement.blur();
+ }
+
+ touch = event.changedTouches[0];
+
+ // Synthesise a click event, with an extra attribute so it can be tracked
+ clickEvent = document.createEvent('MouseEvents');
+ clickEvent.initMouseEvent(this.determineEventType(targetElement), true, true, window, 1, touch.screenX, touch.screenY, touch.clientX, touch.clientY, false, false, false, false, 0, null);
+ clickEvent.forwardedTouchEvent = true;
+ targetElement.dispatchEvent(clickEvent);
+};
+
+FastClick.prototype.determineEventType = function(targetElement) {
+ 'use strict';
+
+ //Issue #159: Android Chrome Select Box does not open with a synthetic click event
+ if (this.deviceIsAndroid && targetElement.tagName.toLowerCase() === 'select') {
+ return 'mousedown';
+ }
+
+ return 'click';
+};
+
+
+/**
+ * @param {EventTarget|Element} targetElement
+ */
+FastClick.prototype.focus = function(targetElement) {
+ 'use strict';
+ var length;
+
+ // Issue #160: on iOS 7, some input elements (e.g. date datetime) throw a vague TypeError on setSelectionRange. These elements don't have an integer value for the selectionStart and selectionEnd properties, but unfortunately that can't be used for detection because accessing the properties also throws a TypeError. Just check the type instead. Filed as Apple bug #15122724.
+ if (this.deviceIsIOS && targetElement.setSelectionRange && targetElement.type.indexOf('date') !== 0 && targetElement.type !== 'time') {
+ length = targetElement.value.length;
+ targetElement.setSelectionRange(length, length);
+ } else {
+ targetElement.focus();
+ }
+};
+
+
+/**
+ * Check whether the given target element is a child of a scrollable layer and if so, set a flag on it.
+ *
+ * @param {EventTarget|Element} targetElement
+ */
+FastClick.prototype.updateScrollParent = function(targetElement) {
+ 'use strict';
+ var scrollParent, parentElement;
+
+ scrollParent = targetElement.fastClickScrollParent;
+
+ // Attempt to discover whether the target element is contained within a scrollable layer. Re-check if the
+ // target element was moved to another parent.
+ if (!scrollParent || !scrollParent.contains(targetElement)) {
+ parentElement = targetElement;
+ do {
+ if (parentElement.scrollHeight > parentElement.offsetHeight) {
+ scrollParent = parentElement;
+ targetElement.fastClickScrollParent = parentElement;
+ break;
+ }
+
+ parentElement = parentElement.parentElement;
+ } while (parentElement);
+ }
+
+ // Always update the scroll top tracker if possible.
+ if (scrollParent) {
+ scrollParent.fastClickLastScrollTop = scrollParent.scrollTop;
+ }
+};
+
+
+/**
+ * @param {EventTarget} targetElement
+ * @returns {Element|EventTarget}
+ */
+FastClick.prototype.getTargetElementFromEventTarget = function(eventTarget) {
+ 'use strict';
+
+ // On some older browsers (notably Safari on iOS 4.1 - see issue #56) the event target may be a text node.
+ if (eventTarget.nodeType === Node.TEXT_NODE) {
+ return eventTarget.parentNode;
+ }
+
+ return eventTarget;
+};
+
+
+/**
+ * On touch start, record the position and scroll offset.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.onTouchStart = function(event) {
+ 'use strict';
+ var targetElement, touch, selection;
+
+ // Ignore multiple touches, otherwise pinch-to-zoom is prevented if both fingers are on the FastClick element (issue #111).
+ if (event.targetTouches.length > 1) {
+ return true;
+ }
+
+ targetElement = this.getTargetElementFromEventTarget(event.target);
+ touch = event.targetTouches[0];
+
+ if (this.deviceIsIOS) {
+
+ // Only trusted events will deselect text on iOS (issue #49)
+ selection = window.getSelection();
+ if (selection.rangeCount && !selection.isCollapsed) {
+ return true;
+ }
+
+ if (!this.deviceIsIOS4) {
+
+ // Weird things happen on iOS when an alert or confirm dialog is opened from a click event callback (issue #23):
+ // when the user next taps anywhere else on the page, new touchstart and touchend events are dispatched
+ // with the same identifier as the touch event that previously triggered the click that triggered the alert.
+ // Sadly, there is an issue on iOS 4 that causes some normal touch events to have the same identifier as an
+ // immediately preceeding touch event (issue #52), so this fix is unavailable on that platform.
+ if (touch.identifier === this.lastTouchIdentifier) {
+ event.preventDefault();
+ return false;
+ }
+
+ this.lastTouchIdentifier = touch.identifier;
+
+ // If the target element is a child of a scrollable layer (using -webkit-overflow-scrolling: touch) and:
+ // 1) the user does a fling scroll on the scrollable layer
+ // 2) the user stops the fling scroll with another tap
+ // then the event.target of the last 'touchend' event will be the element that was under the user's finger
+ // when the fling scroll was started, causing FastClick to send a click event to that layer - unless a check
+ // is made to ensure that a parent layer was not scrolled before sending a synthetic click (issue #42).
+ this.updateScrollParent(targetElement);
+ }
+ }
+
+ this.trackingClick = true;
+ this.trackingClickStart = event.timeStamp;
+ this.targetElement = targetElement;
+
+ this.touchStartX = touch.pageX;
+ this.touchStartY = touch.pageY;
+
+ // Prevent phantom clicks on fast double-tap (issue #36)
+ if ((event.timeStamp - this.lastClickTime) < 200) {
+ event.preventDefault();
+ }
+
+ return true;
+};
+
+
+/**
+ * Based on a touchmove event object, check whether the touch has moved past a boundary since it started.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.touchHasMoved = function(event) {
+ 'use strict';
+ var touch = event.changedTouches[0], boundary = this.touchBoundary;
+
+ if (Math.abs(touch.pageX - this.touchStartX) > boundary || Math.abs(touch.pageY - this.touchStartY) > boundary) {
+ return true;
+ }
+
+ return false;
+};
+
+
+/**
+ * Update the last position.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.onTouchMove = function(event) {
+ 'use strict';
+ if (!this.trackingClick) {
+ return true;
+ }
+
+ // If the touch has moved, cancel the click tracking
+ if (this.targetElement !== this.getTargetElementFromEventTarget(event.target) || this.touchHasMoved(event)) {
+ this.trackingClick = false;
+ this.targetElement = null;
+ }
+
+ return true;
+};
+
+
+/**
+ * Attempt to find the labelled control for the given label element.
+ *
+ * @param {EventTarget|HTMLLabelElement} labelElement
+ * @returns {Element|null}
+ */
+FastClick.prototype.findControl = function(labelElement) {
+ 'use strict';
+
+ // Fast path for newer browsers supporting the HTML5 control attribute
+ if (labelElement.control !== undefined) {
+ return labelElement.control;
+ }
+
+ // All browsers under test that support touch events also support the HTML5 htmlFor attribute
+ if (labelElement.htmlFor) {
+ return document.getElementById(labelElement.htmlFor);
+ }
+
+ // If no for attribute exists, attempt to retrieve the first labellable descendant element
+ // the list of which is defined here: http://www.w3.org/TR/html5/forms.html#category-label
+ return labelElement.querySelector('button, input:not([type=hidden]), keygen, meter, output, progress, select, textarea');
+};
+
+
+/**
+ * On touch end, determine whether to send a click event at once.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.onTouchEnd = function(event) {
+ 'use strict';
+ var forElement, trackingClickStart, targetTagName, scrollParent, touch, targetElement = this.targetElement;
+
+ if (!this.trackingClick) {
+ return true;
+ }
+
+ // Prevent phantom clicks on fast double-tap (issue #36)
+ if ((event.timeStamp - this.lastClickTime) < 200) {
+ this.cancelNextClick = true;
+ return true;
+ }
+
+ // Reset to prevent wrong click cancel on input (issue #156).
+ this.cancelNextClick = false;
+
+ this.lastClickTime = event.timeStamp;
+
+ trackingClickStart = this.trackingClickStart;
+ this.trackingClick = false;
+ this.trackingClickStart = 0;
+
+ // On some iOS devices, the targetElement supplied with the event is invalid if the layer
+ // is performing a transition or scroll, and has to be re-detected manually. Note that
+ // for this to function correctly, it must be called *after* the event target is checked!
+ // See issue #57; also filed as rdar://13048589 .
+ if (this.deviceIsIOSWithBadTarget) {
+ touch = event.changedTouches[0];
+
+ // In certain cases arguments of elementFromPoint can be negative, so prevent setting targetElement to null
+ targetElement = document.elementFromPoint(touch.pageX - window.pageXOffset, touch.pageY - window.pageYOffset) || targetElement;
+ targetElement.fastClickScrollParent = this.targetElement.fastClickScrollParent;
+ }
+
+ targetTagName = targetElement.tagName.toLowerCase();
+ if (targetTagName === 'label') {
+ forElement = this.findControl(targetElement);
+ if (forElement) {
+ this.focus(targetElement);
+ if (this.deviceIsAndroid) {
+ return false;
+ }
+
+ targetElement = forElement;
+ }
+ } else if (this.needsFocus(targetElement)) {
+
+ // Case 1: If the touch started a while ago (best guess is 100ms based on tests for issue #36) then focus will be triggered anyway. Return early and unset the target element reference so that the subsequent click will be allowed through.
+ // Case 2: Without this exception for input elements tapped when the document is contained in an iframe, then any inputted text won't be visible even though the value attribute is updated as the user types (issue #37).
+ if ((event.timeStamp - trackingClickStart) > 100 || (this.deviceIsIOS && window.top !== window && targetTagName === 'input')) {
+ this.targetElement = null;
+ return false;
+ }
+
+ this.focus(targetElement);
+
+ // Select elements need the event to go through on iOS 4, otherwise the selector menu won't open.
+ if (!this.deviceIsIOS4 || targetTagName !== 'select') {
+ this.targetElement = null;
+ event.preventDefault();
+ }
+
+ return false;
+ }
+
+ if (this.deviceIsIOS && !this.deviceIsIOS4) {
+
+ // Don't send a synthetic click event if the target element is contained within a parent layer that was scrolled
+ // and this tap is being used to stop the scrolling (usually initiated by a fling - issue #42).
+ scrollParent = targetElement.fastClickScrollParent;
+ if (scrollParent && scrollParent.fastClickLastScrollTop !== scrollParent.scrollTop) {
+ return true;
+ }
+ }
+
+ // Prevent the actual click from going though - unless the target node is marked as requiring
+ // real clicks or if it is in the whitelist in which case only non-programmatic clicks are permitted.
+ if (!this.needsClick(targetElement)) {
+ event.preventDefault();
+ this.sendClick(targetElement, event);
+ }
+
+ return false;
+};
+
+
+/**
+ * On touch cancel, stop tracking the click.
+ *
+ * @returns {void}
+ */
+FastClick.prototype.onTouchCancel = function() {
+ 'use strict';
+ this.trackingClick = false;
+ this.targetElement = null;
+};
+
+
+/**
+ * Determine mouse events which should be permitted.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.onMouse = function(event) {
+ 'use strict';
+
+ // If a target element was never set (because a touch event was never fired) allow the event
+ if (!this.targetElement) {
+ return true;
+ }
+
+ if (event.forwardedTouchEvent) {
+ return true;
+ }
+
+ // Programmatically generated events targeting a specific element should be permitted
+ if (!event.cancelable) {
+ return true;
+ }
+
+ // Derive and check the target element to see whether the mouse event needs to be permitted;
+ // unless explicitly enabled, prevent non-touch click events from triggering actions,
+ // to prevent ghost/doubleclicks.
+ if (!this.needsClick(this.targetElement) || this.cancelNextClick) {
+
+ // Prevent any user-added listeners declared on FastClick element from being fired.
+ if (event.stopImmediatePropagation) {
+ event.stopImmediatePropagation();
+ } else {
+
+ // Part of the hack for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
+ event.propagationStopped = true;
+ }
+
+ // Cancel the event
+ event.stopPropagation();
+ event.preventDefault();
+
+ return false;
+ }
+
+ // If the mouse event is permitted, return true for the action to go through.
+ return true;
+};
+
+
+/**
+ * On actual clicks, determine whether this is a touch-generated click, a click action occurring
+ * naturally after a delay after a touch (which needs to be cancelled to avoid duplication), or
+ * an actual click which should be permitted.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+FastClick.prototype.onClick = function(event) {
+ 'use strict';
+ var permitted;
+
+ // It's possible for another FastClick-like library delivered with third-party code to fire a click event before FastClick does (issue #44). In that case, set the click-tracking flag back to false and return early. This will cause onTouchEnd to return early.
+ if (this.trackingClick) {
+ this.targetElement = null;
+ this.trackingClick = false;
+ return true;
+ }
+
+ // Very odd behaviour on iOS (issue #18): if a submit element is present inside a form and the user hits enter in the iOS simulator or clicks the Go button on the pop-up OS keyboard the a kind of 'fake' click event will be triggered with the submit-type input element as the target.
+ if (event.target.type === 'submit' && event.detail === 0) {
+ return true;
+ }
+
+ permitted = this.onMouse(event);
+
+ // Only unset targetElement if the click is not permitted. This will ensure that the check for !targetElement in onMouse fails and the browser's click doesn't go through.
+ if (!permitted) {
+ this.targetElement = null;
+ }
+
+ // If clicks are permitted, return true for the action to go through.
+ return permitted;
+};
+
+
+/**
+ * Remove all FastClick's event listeners.
+ *
+ * @returns {void}
+ */
+FastClick.prototype.destroy = function() {
+ 'use strict';
+ var layer = this.layer;
+
+ if (this.deviceIsAndroid) {
+ layer.removeEventListener('mouseover', this.onMouse, true);
+ layer.removeEventListener('mousedown', this.onMouse, true);
+ layer.removeEventListener('mouseup', this.onMouse, true);
+ }
+
+ layer.removeEventListener('click', this.onClick, true);
+ layer.removeEventListener('touchstart', this.onTouchStart, false);
+ layer.removeEventListener('touchmove', this.onTouchMove, false);
+ layer.removeEventListener('touchend', this.onTouchEnd, false);
+ layer.removeEventListener('touchcancel', this.onTouchCancel, false);
+};
+
+
+/**
+ * Check whether FastClick is needed.
+ *
+ * @param {Element} layer The layer to listen on
+ */
+FastClick.notNeeded = function(layer) {
+ 'use strict';
+ var metaViewport;
+ var chromeVersion;
+
+ // Devices that don't support touch don't need FastClick
+ if (typeof window.ontouchstart === 'undefined') {
+ return true;
+ }
+
+ // Chrome version - zero for other browsers
+ chromeVersion = +(/Chrome\/([0-9]+)/.exec(navigator.userAgent) || [,0])[1];
+
+ if (chromeVersion) {
+
+ if (FastClick.prototype.deviceIsAndroid) {
+ metaViewport = document.querySelector('meta[name=viewport]');
+
+ if (metaViewport) {
+ // Chrome on Android with user-scalable="no" doesn't need FastClick (issue #89)
+ if (metaViewport.content.indexOf('user-scalable=no') !== -1) {
+ return true;
+ }
+ // Chrome 32 and above with width=device-width or less don't need FastClick
+ if (chromeVersion > 31 && window.innerWidth <= window.screen.width) {
+ return true;
+ }
+ }
+
+ // Chrome desktop doesn't need FastClick (issue #15)
+ } else {
+ return true;
+ }
+ }
+
+ // IE10 with -ms-touch-action: none, which disables double-tap-to-zoom (issue #97)
+ if (layer.style.msTouchAction === 'none') {
+ return true;
+ }
+
+ return false;
+};
+
+
+/**
+ * Factory method for creating a FastClick object
+ *
+ * @param {Element} layer The layer to listen on
+ */
+FastClick.attach = function(layer) {
+ 'use strict';
+ return new FastClick(layer);
+};
+
+
+if (typeof define !== 'undefined' && define.amd) {
+
+ // AMD. Register as an anonymous module.
+ define(function() {
+ 'use strict';
+ return FastClick;
+ });
+} else if (typeof module !== 'undefined' && module.exports) {
+ module.exports = FastClick.attach;
+ module.exports.FastClick = FastClick;
+} else {
+ window.FastClick = FastClick;
+}
+
+});
+require.register("switchery/switchery.js", function(exports, require, module){
+/**
+ * Switchery 0.6.2
+ * http://abpetkov.github.io/switchery/
+ *
+ * Authored by Alexander Petkov
+ * https://github.com/abpetkov
+ *
+ * Copyright 2013-2014, Alexander Petkov
+ * License: The MIT License (MIT)
+ * http://opensource.org/licenses/MIT
+ *
+ */
+
+/**
+ * External dependencies.
+ */
+
+var transitionize = require('transitionize')
+ , fastclick = require('fastclick');
+
+/**
+ * Expose `Switchery`.
+ */
+
+module.exports = Switchery;
+
+/**
+ * Set Switchery default values.
+ *
+ * @api public
+ */
+
+var defaults = {
+ color : '#64bd63'
+ , secondaryColor : '#dfdfdf'
+ , className : 'switchery'
+ , disabled : false
+ , disabledOpacity: 0.5
+ , speed : '0.4s'
+};
+
+/**
+ * Create Switchery object.
+ *
+ * @param {Object} element
+ * @param {Object} options
+ * @api public
+ */
+
+function Switchery(element, options) {
+ if (!(this instanceof Switchery)) return new Switchery(element, options);
+
+ this.element = element;
+ this.options = options || {};
+
+ for (var i in defaults) {
+ if (this.options[i] == null) {
+ this.options[i] = defaults[i];
+ }
+ }
+
+ if (this.element != null && this.element.type == 'checkbox') this.init();
+}
+
+/**
+ * Hide the target element.
+ *
+ * @api private
+ */
+
+Switchery.prototype.hide = function() {
+ this.element.style.display = 'none';
+};
+
+/**
+ * Show custom switch after the target element.
+ *
+ * @api private
+ */
+
+Switchery.prototype.show = function() {
+ var switcher = this.create();
+ this.insertAfter(this.element, switcher);
+};
+
+/**
+ * Create custom switch.
+ *
+ * @returns {Object} this.switcher
+ * @api private
+ */
+
+Switchery.prototype.create = function() {
+ this.switcher = document.createElement('span');
+ this.jack = document.createElement('small');
+ this.switcher.appendChild(this.jack);
+ this.switcher.className = this.options.className;
+
+ return this.switcher;
+};
+
+/**
+ * Insert after element after another element.
+ *
+ * @param {Object} reference
+ * @param {Object} target
+ * @api private
+ */
+
+Switchery.prototype.insertAfter = function(reference, target) {
+ reference.parentNode.insertBefore(target, reference.nextSibling);
+};
+
+/**
+ * See if input is checked.
+ *
+ * @returns {Boolean}
+ * @api private
+ */
+
+Switchery.prototype.isChecked = function() {
+ return this.element.checked;
+};
+
+/**
+ * See if switcher should be disabled.
+ *
+ * @returns {Boolean}
+ * @api private
+ */
+
+Switchery.prototype.isDisabled = function() {
+ return this.options.disabled || this.element.disabled;
+};
+
+/**
+ * Set switch jack proper position.
+ *
+ * @param {Boolean} clicked - we need this in order to uncheck the input when the switch is clicked
+ * @api private
+ */
+
+Switchery.prototype.setPosition = function (clicked) {
+ var checked = this.isChecked()
+ , switcher = this.switcher
+ , jack = this.jack;
+
+ if (clicked && checked) checked = false;
+ else if (clicked && !checked) checked = true;
+
+ if (checked === true) {
+ this.element.checked = true;
+
+ if (window.getComputedStyle) jack.style.left = parseInt(window.getComputedStyle(switcher).width) - parseInt(window.getComputedStyle(jack).width) + 'px';
+ else jack.style.left = parseInt(switcher.currentStyle['width']) - parseInt(jack.currentStyle['width']) + 'px';
+
+ if (this.options.color) this.colorize();
+ this.setSpeed();
+ } else {
+ jack.style.left = 0;
+ this.element.checked = false;
+ this.switcher.style.boxShadow = 'inset 0 0 0 0 ' + this.options.secondaryColor;
+ this.switcher.style.borderColor = this.options.secondaryColor;
+ this.switcher.style.backgroundColor = (this.options.secondaryColor !== defaults.secondaryColor) ? this.options.secondaryColor : '#fff';
+ this.setSpeed();
+ }
+};
+
+/**
+ * Set speed.
+ *
+ * @api private
+ */
+
+Switchery.prototype.setSpeed = function() {
+ var switcherProp = {}
+ , jackProp = { 'left': this.options.speed.replace(/[a-z]/, '') / 2 + 's' };
+
+ if (this.isChecked()) {
+ switcherProp = {
+ 'border': this.options.speed
+ , 'box-shadow': this.options.speed
+ , 'background-color': this.options.speed.replace(/[a-z]/, '') * 3 + 's'
+ };
+ } else {
+ switcherProp = {
+ 'border': this.options.speed
+ , 'box-shadow': this.options.speed
+ };
+ }
+
+ transitionize(this.switcher, switcherProp);
+ transitionize(this.jack, jackProp);
+};
+
+/**
+ * Set switch color.
+ *
+ * @api private
+ */
+
+Switchery.prototype.colorize = function() {
+ this.switcher.style.backgroundColor = this.options.color;
+ this.switcher.style.borderColor = this.options.color;
+ this.switcher.style.boxShadow = 'inset 0 0 0 16px ' + this.options.color;
+};
+
+/**
+ * Handle the onchange event.
+ *
+ * @param {Boolean} state
+ * @api private
+ */
+
+Switchery.prototype.handleOnchange = function(state) {
+ if (typeof Event === 'function' || !document.fireEvent) {
+ var event = document.createEvent('HTMLEvents');
+ event.initEvent('change', true, true);
+ this.element.dispatchEvent(event);
+ } else {
+ this.element.fireEvent('onchange');
+ }
+};
+
+/**
+ * Handle the native input element state change.
+ * A `change` event must be fired in order to detect the change.
+ *
+ * @api private
+ */
+
+Switchery.prototype.handleChange = function() {
+ var self = this
+ , el = this.element;
+
+ if (el.addEventListener) {
+ el.addEventListener('change', function() {
+ self.setPosition();
+ });
+ } else {
+ el.attachEvent('onchange', function() {
+ self.setPosition();
+ });
+ }
+};
+
+/**
+ * Handle the switch click event.
+ *
+ * @api private
+ */
+
+Switchery.prototype.handleClick = function() {
+ var self = this
+ , switcher = this.switcher
+ , parent = self.element.parentNode.tagName.toLowerCase()
+ , labelParent = (parent === 'label') ? false : true;
+
+ if (this.isDisabled() === false) {
+ fastclick(switcher);
+
+ if (switcher.addEventListener) {
+ switcher.addEventListener('click', function() {
+ self.setPosition(labelParent);
+ self.handleOnchange(self.element.checked);
+ });
+ } else {
+ switcher.attachEvent('onclick', function() {
+ self.setPosition(labelParent);
+ self.handleOnchange(self.element.checked);
+ });
+ }
+ } else {
+ this.element.disabled = true;
+ this.switcher.style.opacity = this.options.disabledOpacity;
+ }
+};
+
+/**
+ * Mark an individual switch as already handled.
+ *
+ * @api private
+ */
+
+Switchery.prototype.markAsSwitched = function() {
+ this.element.setAttribute('data-switchery', true);
+};
+
+/**
+ * Check if an individual switch is already handled.
+ *
+ * @api private
+ */
+
+Switchery.prototype.markedAsSwitched = function() {
+ return this.element.getAttribute('data-switchery');
+};
+
+/**
+ * Initialize Switchery.
+ *
+ * @api private
+ */
+
+Switchery.prototype.init = function() {
+ this.hide();
+ this.show();
+ this.setPosition();
+ this.markAsSwitched();
+ this.handleChange();
+ this.handleClick();
+};
+
+});
+
+
+
+
+require.alias("abpetkov-transitionize/transitionize.js", "switchery/deps/transitionize/transitionize.js");
+require.alias("abpetkov-transitionize/transitionize.js", "switchery/deps/transitionize/index.js");
+require.alias("abpetkov-transitionize/transitionize.js", "transitionize/index.js");
+require.alias("abpetkov-transitionize/transitionize.js", "abpetkov-transitionize/index.js");
+require.alias("ftlabs-fastclick/lib/fastclick.js", "switchery/deps/fastclick/lib/fastclick.js");
+require.alias("ftlabs-fastclick/lib/fastclick.js", "switchery/deps/fastclick/index.js");
+require.alias("ftlabs-fastclick/lib/fastclick.js", "fastclick/index.js");
+require.alias("ftlabs-fastclick/lib/fastclick.js", "ftlabs-fastclick/index.js");
+require.alias("switchery/switchery.js", "switchery/index.js");if (typeof exports == "object") {
+ module.exports = require("switchery");
+} else if (typeof define == "function" && define.amd) {
+ define(function(){ return require("switchery"); });
+} else {
+ this["Switchery"] = require("switchery");
+}})();
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.css b/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.css
new file mode 100755
index 0000000..e68cf6d
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.css
@@ -0,0 +1 @@
+.switchery{background-color:#fff;border:1px solid #dfdfdf;border-radius:20px;cursor:pointer;display:inline-block;height:30px;position:relative;vertical-align:middle;width:50px;-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.switchery>small{background:#fff;border-radius:100%;box-shadow:0 1px 3px rgba(0,0,0,0.4);height:30px;position:absolute;top:0;width:30px}
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.js b/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.js
new file mode 100755
index 0000000..4b181c4
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/switchery/switchery.min.js
@@ -0,0 +1 @@
+(function(){function require(path,parent,orig){var resolved=require.resolve(path);if(null==resolved){orig=orig||path;parent=parent||"root";var err=new Error('Failed to require "'+orig+'" from "'+parent+'"');err.path=orig;err.parent=parent;err.require=true;throw err}var module=require.modules[resolved];if(!module._resolving&&!module.exports){var mod={};mod.exports={};mod.client=mod.component=true;module._resolving=true;module.call(this,mod.exports,require.relative(resolved),mod);delete module._resolving;module.exports=mod.exports}return module.exports}require.modules={};require.aliases={};require.resolve=function(path){if(path.charAt(0)==="/")path=path.slice(1);var paths=[path,path+".js",path+".json",path+"/index.js",path+"/index.json"];for(var i=0;i0;FastClick.prototype.deviceIsIOS=/iP(ad|hone|od)/.test(navigator.userAgent);FastClick.prototype.deviceIsIOS4=FastClick.prototype.deviceIsIOS&&/OS 4_\d(_\d)?/.test(navigator.userAgent);FastClick.prototype.deviceIsIOSWithBadTarget=FastClick.prototype.deviceIsIOS&&/OS ([6-9]|\d{2})_\d/.test(navigator.userAgent);FastClick.prototype.needsClick=function(target){"use strict";switch(target.nodeName.toLowerCase()){case"button":case"select":case"textarea":if(target.disabled){return true}break;case"input":if(this.deviceIsIOS&&target.type==="file"||target.disabled){return true}break;case"label":case"video":return true}return/\bneedsclick\b/.test(target.className)};FastClick.prototype.needsFocus=function(target){"use strict";switch(target.nodeName.toLowerCase()){case"textarea":return true;case"select":return!this.deviceIsAndroid;case"input":switch(target.type){case"button":case"checkbox":case"file":case"image":case"radio":case"submit":return false}return!target.disabled&&!target.readOnly;default:return/\bneedsfocus\b/.test(target.className)}};FastClick.prototype.sendClick=function(targetElement,event){"use strict";var clickEvent,touch;if(document.activeElement&&document.activeElement!==targetElement){document.activeElement.blur()}touch=event.changedTouches[0];clickEvent=document.createEvent("MouseEvents");clickEvent.initMouseEvent(this.determineEventType(targetElement),true,true,window,1,touch.screenX,touch.screenY,touch.clientX,touch.clientY,false,false,false,false,0,null);clickEvent.forwardedTouchEvent=true;targetElement.dispatchEvent(clickEvent)};FastClick.prototype.determineEventType=function(targetElement){"use strict";if(this.deviceIsAndroid&&targetElement.tagName.toLowerCase()==="select"){return"mousedown"}return"click"};FastClick.prototype.focus=function(targetElement){"use strict";var length;if(this.deviceIsIOS&&targetElement.setSelectionRange&&targetElement.type.indexOf("date")!==0&&targetElement.type!=="time"){length=targetElement.value.length;targetElement.setSelectionRange(length,length)}else{targetElement.focus()}};FastClick.prototype.updateScrollParent=function(targetElement){"use strict";var scrollParent,parentElement;scrollParent=targetElement.fastClickScrollParent;if(!scrollParent||!scrollParent.contains(targetElement)){parentElement=targetElement;do{if(parentElement.scrollHeight>parentElement.offsetHeight){scrollParent=parentElement;targetElement.fastClickScrollParent=parentElement;break}parentElement=parentElement.parentElement}while(parentElement)}if(scrollParent){scrollParent.fastClickLastScrollTop=scrollParent.scrollTop}};FastClick.prototype.getTargetElementFromEventTarget=function(eventTarget){"use strict";if(eventTarget.nodeType===Node.TEXT_NODE){return eventTarget.parentNode}return eventTarget};FastClick.prototype.onTouchStart=function(event){"use strict";var targetElement,touch,selection;if(event.targetTouches.length>1){return true}targetElement=this.getTargetElementFromEventTarget(event.target);touch=event.targetTouches[0];if(this.deviceIsIOS){selection=window.getSelection();if(selection.rangeCount&&!selection.isCollapsed){return true}if(!this.deviceIsIOS4){if(touch.identifier===this.lastTouchIdentifier){event.preventDefault();return false}this.lastTouchIdentifier=touch.identifier;this.updateScrollParent(targetElement)}}this.trackingClick=true;this.trackingClickStart=event.timeStamp;this.targetElement=targetElement;this.touchStartX=touch.pageX;this.touchStartY=touch.pageY;if(event.timeStamp-this.lastClickTime<200){event.preventDefault()}return true};FastClick.prototype.touchHasMoved=function(event){"use strict";var touch=event.changedTouches[0],boundary=this.touchBoundary;if(Math.abs(touch.pageX-this.touchStartX)>boundary||Math.abs(touch.pageY-this.touchStartY)>boundary){return true}return false};FastClick.prototype.onTouchMove=function(event){"use strict";if(!this.trackingClick){return true}if(this.targetElement!==this.getTargetElementFromEventTarget(event.target)||this.touchHasMoved(event)){this.trackingClick=false;this.targetElement=null}return true};FastClick.prototype.findControl=function(labelElement){"use strict";if(labelElement.control!==undefined){return labelElement.control}if(labelElement.htmlFor){return document.getElementById(labelElement.htmlFor)}return labelElement.querySelector("button, input:not([type=hidden]), keygen, meter, output, progress, select, textarea")};FastClick.prototype.onTouchEnd=function(event){"use strict";var forElement,trackingClickStart,targetTagName,scrollParent,touch,targetElement=this.targetElement;if(!this.trackingClick){return true}if(event.timeStamp-this.lastClickTime<200){this.cancelNextClick=true;return true}this.cancelNextClick=false;this.lastClickTime=event.timeStamp;trackingClickStart=this.trackingClickStart;this.trackingClick=false;this.trackingClickStart=0;if(this.deviceIsIOSWithBadTarget){touch=event.changedTouches[0];targetElement=document.elementFromPoint(touch.pageX-window.pageXOffset,touch.pageY-window.pageYOffset)||targetElement;targetElement.fastClickScrollParent=this.targetElement.fastClickScrollParent}targetTagName=targetElement.tagName.toLowerCase();if(targetTagName==="label"){forElement=this.findControl(targetElement);if(forElement){this.focus(targetElement);if(this.deviceIsAndroid){return false}targetElement=forElement}}else if(this.needsFocus(targetElement)){if(event.timeStamp-trackingClickStart>100||this.deviceIsIOS&&window.top!==window&&targetTagName==="input"){this.targetElement=null;return false}this.focus(targetElement);if(!this.deviceIsIOS4||targetTagName!=="select"){this.targetElement=null;event.preventDefault()}return false}if(this.deviceIsIOS&&!this.deviceIsIOS4){scrollParent=targetElement.fastClickScrollParent;if(scrollParent&&scrollParent.fastClickLastScrollTop!==scrollParent.scrollTop){return true}}if(!this.needsClick(targetElement)){event.preventDefault();this.sendClick(targetElement,event)}return false};FastClick.prototype.onTouchCancel=function(){"use strict";this.trackingClick=false;this.targetElement=null};FastClick.prototype.onMouse=function(event){"use strict";if(!this.targetElement){return true}if(event.forwardedTouchEvent){return true}if(!event.cancelable){return true}if(!this.needsClick(this.targetElement)||this.cancelNextClick){if(event.stopImmediatePropagation){event.stopImmediatePropagation()}else{event.propagationStopped=true}event.stopPropagation();event.preventDefault();return false}return true};FastClick.prototype.onClick=function(event){"use strict";var permitted;if(this.trackingClick){this.targetElement=null;this.trackingClick=false;return true}if(event.target.type==="submit"&&event.detail===0){return true}permitted=this.onMouse(event);if(!permitted){this.targetElement=null}return permitted};FastClick.prototype.destroy=function(){"use strict";var layer=this.layer;if(this.deviceIsAndroid){layer.removeEventListener("mouseover",this.onMouse,true);layer.removeEventListener("mousedown",this.onMouse,true);layer.removeEventListener("mouseup",this.onMouse,true)}layer.removeEventListener("click",this.onClick,true);layer.removeEventListener("touchstart",this.onTouchStart,false);layer.removeEventListener("touchmove",this.onTouchMove,false);layer.removeEventListener("touchend",this.onTouchEnd,false);layer.removeEventListener("touchcancel",this.onTouchCancel,false)};FastClick.notNeeded=function(layer){"use strict";var metaViewport;var chromeVersion;if(typeof window.ontouchstart==="undefined"){return true}chromeVersion=+(/Chrome\/([0-9]+)/.exec(navigator.userAgent)||[,0])[1];if(chromeVersion){if(FastClick.prototype.deviceIsAndroid){metaViewport=document.querySelector("meta[name=viewport]");if(metaViewport){if(metaViewport.content.indexOf("user-scalable=no")!==-1){return true}if(chromeVersion>31&&window.innerWidth<=window.screen.width){return true}}}else{return true}}if(layer.style.msTouchAction==="none"){return true}return false};FastClick.attach=function(layer){"use strict";return new FastClick(layer)};if(typeof define!=="undefined"&&define.amd){define(function(){"use strict";return FastClick})}else if(typeof module!=="undefined"&&module.exports){module.exports=FastClick.attach;module.exports.FastClick=FastClick}else{window.FastClick=FastClick}});require.register("switchery/switchery.js",function(exports,require,module){var transitionize=require("transitionize"),fastclick=require("fastclick");module.exports=Switchery;var defaults={color:"#64bd63",secondaryColor:"#dfdfdf",className:"switchery",disabled:false,disabledOpacity:.5,speed:"0.4s"};function Switchery(element,options){if(!(this instanceof Switchery))return new Switchery(element,options);this.element=element;this.options=options||{};for(var i in defaults){if(this.options[i]==null){this.options[i]=defaults[i]}}if(this.element!=null&&this.element.type=="checkbox")this.init()}Switchery.prototype.hide=function(){this.element.style.display="none"};Switchery.prototype.show=function(){var switcher=this.create();this.insertAfter(this.element,switcher)};Switchery.prototype.create=function(){this.switcher=document.createElement("span");this.jack=document.createElement("small");this.switcher.appendChild(this.jack);this.switcher.className=this.options.className;return this.switcher};Switchery.prototype.insertAfter=function(reference,target){reference.parentNode.insertBefore(target,reference.nextSibling)};Switchery.prototype.isChecked=function(){return this.element.checked};Switchery.prototype.isDisabled=function(){return this.options.disabled||this.element.disabled};Switchery.prototype.setPosition=function(clicked){var checked=this.isChecked(),switcher=this.switcher,jack=this.jack;if(clicked&&checked)checked=false;else if(clicked&&!checked)checked=true;if(checked===true){this.element.checked=true;if(window.getComputedStyle)jack.style.left=parseInt(window.getComputedStyle(switcher).width)-parseInt(window.getComputedStyle(jack).width)+"px";else jack.style.left=parseInt(switcher.currentStyle["width"])-parseInt(jack.currentStyle["width"])+"px";if(this.options.color)this.colorize();this.setSpeed()}else{jack.style.left=0;this.element.checked=false;this.switcher.style.boxShadow="inset 0 0 0 0 "+this.options.secondaryColor;this.switcher.style.borderColor=this.options.secondaryColor;this.switcher.style.backgroundColor=this.options.secondaryColor!==defaults.secondaryColor?this.options.secondaryColor:"#fff";this.setSpeed()}};Switchery.prototype.setSpeed=function(){var switcherProp={},jackProp={left:this.options.speed.replace(/[a-z]/,"")/2+"s"};if(this.isChecked()){switcherProp={border:this.options.speed,"box-shadow":this.options.speed,"background-color":this.options.speed.replace(/[a-z]/,"")*3+"s"}}else{switcherProp={border:this.options.speed,"box-shadow":this.options.speed}}transitionize(this.switcher,switcherProp);transitionize(this.jack,jackProp)};Switchery.prototype.colorize=function(){this.switcher.style.backgroundColor=this.options.color;this.switcher.style.borderColor=this.options.color;this.switcher.style.boxShadow="inset 0 0 0 16px "+this.options.color};Switchery.prototype.handleOnchange=function(state){if(typeof Event==="function"||!document.fireEvent){var event=document.createEvent("HTMLEvents");event.initEvent("change",true,true);this.element.dispatchEvent(event)}else{this.element.fireEvent("onchange")}};Switchery.prototype.handleChange=function(){var self=this,el=this.element;if(el.addEventListener){el.addEventListener("change",function(){self.setPosition()})}else{el.attachEvent("onchange",function(){self.setPosition()})}};Switchery.prototype.handleClick=function(){var self=this,switcher=this.switcher,parent=self.element.parentNode.tagName.toLowerCase(),labelParent=parent==="label"?false:true;if(this.isDisabled()===false){fastclick(switcher);if(switcher.addEventListener){switcher.addEventListener("click",function(){self.setPosition(labelParent);self.handleOnchange(self.element.checked)})}else{switcher.attachEvent("onclick",function(){self.setPosition(labelParent);self.handleOnchange(self.element.checked)})}}else{this.element.disabled=true;this.switcher.style.opacity=this.options.disabledOpacity}};Switchery.prototype.markAsSwitched=function(){this.element.setAttribute("data-switchery",true)};Switchery.prototype.markedAsSwitched=function(){return this.element.getAttribute("data-switchery")};Switchery.prototype.init=function(){this.hide();this.show();this.setPosition();this.markAsSwitched();this.handleChange();this.handleClick()}});require.alias("abpetkov-transitionize/transitionize.js","switchery/deps/transitionize/transitionize.js");require.alias("abpetkov-transitionize/transitionize.js","switchery/deps/transitionize/index.js");require.alias("abpetkov-transitionize/transitionize.js","transitionize/index.js");require.alias("abpetkov-transitionize/transitionize.js","abpetkov-transitionize/index.js");require.alias("ftlabs-fastclick/lib/fastclick.js","switchery/deps/fastclick/lib/fastclick.js");require.alias("ftlabs-fastclick/lib/fastclick.js","switchery/deps/fastclick/index.js");require.alias("ftlabs-fastclick/lib/fastclick.js","fastclick/index.js");require.alias("ftlabs-fastclick/lib/fastclick.js","ftlabs-fastclick/index.js");require.alias("switchery/switchery.js","switchery/index.js");if(typeof exports=="object"){module.exports=require("switchery")}else if(typeof define=="function"&&define.amd){define(function(){return require("switchery")})}else{this["Switchery"]=require("switchery")}})();
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/tinysort/jquery.tinysort.min.js b/catalog/view/javascript/d_quickcheckout/tinysort/jquery.tinysort.min.js
new file mode 100755
index 0000000..586b663
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/tinysort/jquery.tinysort.min.js
@@ -0,0 +1,10 @@
+/* TinySort 1.4.29
+* Copyright (c) 2008-2012 Ron Valstar http://www.sjeiti.com/
+*
+* Dual licensed under the MIT and GPL licenses:
+* http://www.opensource.org/licenses/mit-license.php
+* http://www.gnu.org/licenses/gpl.html
+*/
+(function(c){var e=!1,f=null,j=parseFloat,g=Math.min,i=/(-?\d+\.?\d*)$/g,h=[],d=[];c.tinysort={id:"TinySort",version:"1.4.29",copyright:"Copyright (c) 2008-2012 Ron Valstar",uri:"http://tinysort.sjeiti.com/",licensed:{MIT:"http://www.opensource.org/licenses/mit-license.php",GPL:"http://www.gnu.org/licenses/gpl.html"},plugin:function(k,l){h.push(k);d.push(l)},defaults:{order:"asc",attr:f,data:f,useVal:e,place:"start",returns:e,cases:e,forceStrings:e,sortFunction:f}};c.fn.extend({tinysort:function(o,k){if(o&&typeof(o)!="string"){k=o;o=f}var p=c.extend({},c.tinysort.defaults,k),u,D=this,z=c(this).length,E={},r=!(!o||o==""),s=!(p.attr===f||p.attr==""),y=p.data!==f,l=r&&o[0]==":",m=l?D.filter(o):D,t=p.sortFunction,x=p.order=="asc"?1:-1,n=[];c.each(h,function(G,H){H.call(H,p)});if(!t){t=p.order=="rand"?function(){return Math.random()<0.5?1:-1}:function(O,M){var N=e,J=!p.cases?a(O.s):O.s,I=!p.cases?a(M.s):M.s;if(!p.forceStrings){var H=J&&J.match(i),P=I&&I.match(i);if(H&&P){var L=J.substr(0,J.length-H[0].length),K=I.substr(0,I.length-P[0].length);if(L==K){N=!e;J=j(H[0]);I=j(P[0])}}}var G=x*(JI?1:0));c.each(d,function(Q,R){G=R.call(R,N,J,I,G)});return G}}D.each(function(I,J){var K=c(J),G=r?(l?m.filter(J):K.find(o)):K,L=y?""+G.data(p.data):(s?G.attr(p.attr):(p.useVal?G.val():G.text())),H=K.parent();if(!E[H]){E[H]={s:[],n:[]}}if(G.length>0){E[H].s.push({s:L,e:K,n:I})}else{E[H].n.push({e:K,n:I})}});for(u in E){E[u].s.sort(t)}for(u in E){var A=E[u],C=[],F=z,w=[0,0],B;switch(p.place){case"first":c.each(A.s,function(G,H){F=g(F,H.n)});break;case"org":c.each(A.s,function(G,H){C.push(H.n)});break;case"end":F=A.n.length;break;default:F=0}for(B=0;B=F&&B', { 'class' : 'qc qc-tooltip'})
+ .append( jQuery('', { 'class' : 'inner' }))
+ .append( jQuery('
') )
+ );
+
+ // Get tooltip
+ var tooltip = jQuery('.qc.qc-tooltip');
+
+ if( $( window ).width() < tooltip.outerWidth() * 1.5 )
+ tooltip.css( 'max-width', $( window ).width() / 2 );
+ else
+ tooltip.css( 'max-width', 340 );
+
+ var pos_left = jQuery(el).offset().left + ( jQuery(el).outerWidth() / 2 ) - ( tooltip.outerWidth() / 2 ),
+ pos_top = jQuery(el).offset().top - tooltip.outerHeight() - 23;
+
+ if( pos_left < 0 )
+ {
+ pos_left = jQuery(el).offset().left + jQuery(el).outerWidth() / 2 - 20;
+ tooltip.addClass( 'left' );
+ }
+ else
+ tooltip.removeClass( 'left' );
+
+ if( pos_left + tooltip.outerWidth() > $( window ).width() )
+ {
+ pos_left = jQuery(el).offset().left - tooltip.outerWidth() + jQuery(el).outerWidth() / 2 + 20;
+ tooltip.addClass( 'right' );
+ }
+ else
+ tooltip.removeClass( 'right' );
+
+ if( pos_top < 0 )
+ {
+ var pos_top = jQuery(el).offset().top + jQuery(el).outerHeight();
+ tooltip.addClass( 'top' );
+ }
+ else
+ tooltip.removeClass( 'top' );
+
+ tooltip.css( { left: pos_left, top: pos_top } )
+ .animate( { top: '+=0', opacity: 1 }, 50 );
+
+ // Set tooltip text
+ tooltip.find('.inner').html( jQuery(el).attr('data-help'));
+ },
+
+ close : function() {
+ jQuery('.qc.qc-tooltip').remove();
+
+ }
+};
+dTooltip.init();
+
+var dpopup = {
+
+ init : function() {
+
+ jQuery(document).on('mouseover', '[rel="qc-popup"]', function() {
+
+ dpopup.open(this);
+ });
+
+ jQuery(document).on('mouseout', '[rel="qc-popup"]', function() {
+ dpopup.close();
+ });
+ },
+
+ open : function(el) {
+
+ // Create popup
+ jQuery('body').prepend( jQuery('', { 'class' : 'qc qc-popup'})
+ .append( jQuery('
', { 'class' : 'inner' }))
+ .append( jQuery('
') )
+ );
+
+ // Get popup
+ var popup = jQuery('.qc-popup');
+
+ if( $( window ).width() < popup.outerWidth() * 1.5 )
+ popup.css( 'max-width', $( window ).width() / 2 );
+ else
+ popup.css( 'max-width', 340 );
+
+ var pos_left = jQuery(el).offset().left + ( jQuery(el).outerWidth() / 2 ) - ( popup.outerWidth() / 2 ),
+ pos_top = jQuery(el).offset().top - popup.outerHeight() - 38;
+
+ if( pos_left < 0 )
+ {
+ pos_left = jQuery(el).offset().left + jQuery(el).outerWidth() / 2 - 20;
+ popup.addClass( 'left' );
+ }
+ else
+ popup.removeClass( 'left' );
+
+ if( pos_left + popup.outerWidth() > $( window ).width() )
+ {
+ pos_left = jQuery(el).offset().left - popup.outerWidth() + jQuery(el).outerWidth() / 2 + 20;
+ popup.addClass( 'right' );
+ }
+ else
+ popup.removeClass( 'right' );
+
+ if( pos_top < 0 )
+ {
+ var pos_top = jQuery(el).offset().top + jQuery(el).outerHeight();
+ popup.addClass( 'top' );
+ }
+ else
+ popup.removeClass( 'top' );
+
+ popup.css( { left: pos_left, top: pos_top } )
+ .animate( { top: '+=0', opacity: 1 }, 50 );
+
+ // Set popup text
+ popup.find('.inner').html( jQuery(el).attr('data-help'));
+ },
+
+ close : function() {
+ jQuery('.qc.qc-popup').remove();
+
+ }
+};
+dpopup.init();
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/uniform/css/uniform.default.css b/catalog/view/javascript/d_quickcheckout/uniform/css/uniform.default.css
new file mode 100755
index 0000000..3277fbb
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/uniform/css/uniform.default.css
@@ -0,0 +1,617 @@
+/*
+
+Uniform Theme: Uniform Default
+Version: 1.6
+By: Josh Pyles
+License: MIT License
+---
+For use with the Uniform plugin:
+http://pixelmatrixdesign.com/uniform/
+---
+Generated by Uniform Theme Generator:
+http://pixelmatrixdesign.com/uniform/themer.html
+
+*/
+
+/* Global Declaration */
+
+div.selector,
+div.selector span,
+div.checker span,
+div.radio span,
+div.uploader,
+div.uploader span.action/*,
+div.button,
+div.button span*/ {
+ background-image: url(../images/sprite.png);
+ background-repeat: no-repeat;
+ -webkit-font-smoothing: antialiased;
+}
+
+.selector,
+.radio,
+.checker,
+.uploader,
+/*.button, */
+.selector *,
+.radio *,
+.checker *,
+.uploader */*,
+.button **/{
+ margin: 0;
+ padding: 0;
+}
+
+/* INPUT & TEXTAREA */
+
+input.text,
+input.email,
+input.password,
+textarea.uniform {
+ font-size: 12px;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-weight: normal;
+ padding: 3px;
+ color: #777;
+ background: url('../images/bg-input-focus.png') repeat-x 0px 0px;
+ background: url('../images/bg-input.png') repeat-x 0px 0px;
+ border-top: solid 1px #aaa;
+ border-left: solid 1px #aaa;
+ border-bottom: solid 1px #ccc;
+ border-right: solid 1px #ccc;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ outline: 0;
+}
+
+input.text:focus,
+input.email:focus,
+input.password:focus,
+textarea.uniform:focus {
+ -webkit-box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ -moz-box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ box-shadow: 0px 0px 4px rgba(0,0,0,0.3);
+ border-color: #999;
+ background: url('../images/bg-input-focus.png') repeat-x 0px 0px;
+}
+
+/* SPRITES */
+
+/* Select */
+
+div.selector {
+ background-position: -483px -130px;
+ line-height: 26px;
+ height: 26px;
+}
+
+div.selector span {
+ background-position: right 0px;
+ height: 26px;
+ line-height: 26px;
+}
+
+div.selector select {
+ /* change these to adjust positioning of select element */
+ top: 0px;
+ left: 0px;
+}
+
+div.selector:active,
+div.selector.active {
+ background-position: -483px -156px;
+}
+
+div.selector:active span,
+div.selector.active span {
+ background-position: right -26px;
+}
+
+div.selector.focus, div.selector.hover, div.selector:hover {
+ background-position: -483px -182px;
+}
+
+div.selector.focus span, div.selector.hover span, div.selector:hover span {
+ background-position: right -52px;
+}
+
+div.selector.focus:active,
+div.selector.focus.active,
+div.selector:hover:active,
+div.selector.active:hover {
+ background-position: -483px -208px;
+}
+
+div.selector.focus:active span,
+div.selector:hover:active span,
+div.selector.active:hover span,
+div.selector.focus.active span {
+ background-position: right -78px;
+}
+
+div.selector.disabled {
+ background-position: -483px -234px;
+}
+
+div.selector.disabled span {
+ background-position: right -104px;
+}
+
+/* Checkbox */
+
+div.checker {
+ width: 19px;
+ height: 19px;
+ vertical-align: middle;
+ /*margin-top: -2px;*/
+}
+
+
+div.checker input {
+ width: 19px;
+ height: 19px;
+
+}
+
+div.checker span {
+ background-position: 0px -260px;
+ height: 19px;
+ width: 19px;
+}
+
+div.checker:active span,
+div.checker.active span {
+ background-position: -19px -260px;
+}
+
+div.checker.focus span,
+div.checker:hover span {
+ background-position: -38px -260px;
+}
+
+div.checker.focus:active span,
+div.checker:active:hover span,
+div.checker.active:hover span,
+div.checker.focus.active span {
+ background-position: -57px -260px;
+}
+
+div.checker span.checked {
+ background-position: -76px -260px;
+}
+
+div.checker:active span.checked,
+div.checker.active span.checked {
+ background-position: -95px -260px;
+}
+
+div.checker.focus span.checked,
+div.checker:hover span.checked {
+ background-position: -114px -260px;
+}
+
+div.checker.focus:active span.checked,
+div.checker:hover:active span.checked,
+div.checker.active:hover span.checked,
+div.checker.active.focus span.checked {
+ background-position: -133px -260px;
+}
+
+div.checker.disabled span,
+div.checker.disabled:active span,
+div.checker.disabled.active span {
+ background-position: -152px -260px;
+}
+
+div.checker.disabled span.checked,
+div.checker.disabled:active span.checked,
+div.checker.disabled.active span.checked {
+ background-position: -171px -260px;
+}
+
+/* Radio */
+
+div.radio {
+ width: 18px;
+ height: 18px;
+}
+
+div.radio input {
+ width: 18px;
+ height: 18px;
+}
+
+div.radio span {
+ height: 18px;
+ width: 18px;
+ background-position: 0px -279px;
+}
+
+div.radio:active span,
+div.radio.active span {
+ background-position: -18px -279px;
+}
+
+div.radio.focus span,
+div.radio:hover span {
+ background-position: -36px -279px;
+}
+
+div.radio.focus:active span,
+div.radio:active:hover span,
+div.radio.active:hover span,
+div.radio.active.focus span {
+ background-position: -54px -279px;
+}
+
+div.radio span.checked {
+ background-position: -72px -279px;
+}
+
+div.radio:active span.checked,
+div.radio.active span.checked {
+ background-position: -90px -279px;
+}
+
+div.radio.focus span.checked, div.radio:hover span.checked {
+ background-position: -108px -279px;
+}
+
+div.radio.focus:active span.checked,
+div.radio:hover:active span.checked,
+div.radio.focus.active span.checked,
+div.radio.active:hover span.checked {
+ background-position: -126px -279px;
+}
+
+div.radio.disabled span,
+div.radio.disabled:active span,
+div.radio.disabled.active span {
+ background-position: -144px -279px;
+}
+
+div.radio.disabled span.checked,
+div.radio.disabled:active span.checked,
+div.radio.disabled.active span.checked {
+ background-position: -162px -279px;
+}
+
+/* Uploader */
+
+div.uploader {
+ background-position: 0px -297px;
+ height: 28px;
+}
+
+div.uploader span.action {
+ background-position: right -409px;
+ height: 24px;
+ line-height: 24px;
+}
+
+div.uploader span.filename {
+ height: 24px;
+ /* change this line to adjust positioning of filename area */
+ margin: 2px 0px 2px 2px;
+ line-height: 24px;
+}
+
+div.uploader.focus,
+div.uploader.hover,
+div.uploader:hover {
+ background-position: 0px -353px;
+}
+
+div.uploader.focus span.action,
+div.uploader.hover span.action,
+div.uploader:hover span.action {
+ background-position: right -437px;
+}
+
+div.uploader.active span.action,
+div.uploader:active span.action {
+ background-position: right -465px;
+}
+
+div.uploader.focus.active span.action,
+div.uploader:focus.active span.action,
+div.uploader.focus:active span.action,
+div.uploader:focus:active span.action {
+ background-position: right -493px;
+}
+
+div.uploader.disabled {
+ background-position: 0px -325px;
+}
+
+div.uploader.disabled span.action {
+ background-position: right -381px;
+}
+/*
+div.button {
+ background-position: 0px -523px;
+}
+
+div.button span {
+ background-position: right -643px;
+}
+
+div.button.focus,
+div.button:focus,
+div.button:hover,
+div.button.hover {
+ background-position: 0px -553px;
+}
+
+div.button.focus span,
+div.button:focus span,
+div.button:hover span,
+div.button.hover span {
+ background-position: right -673px;
+}
+
+div.button.active,
+div.button:active {
+ background-position: 0px -583px;
+}
+
+div.button.active span,
+div.button:active span {
+ background-position: right -703px;
+ color: #555;
+}
+
+div.button.disabled,
+div.button:disabled {
+ background-position: 0px -613px;
+}
+
+div.button.disabled span,
+div.button:disabled span {
+ background-position: right -733px;
+ color: #bbb;
+ cursor: default;
+}*/
+
+/* PRESENTATION */
+
+/* Button */
+
+/*div.button {
+ height: 30px;
+}
+
+div.button span {
+ margin-left: 13px;
+ height: 22px;
+ padding-top: 8px;
+ font-weight: bold;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-size: 12px;
+ letter-spacing: 1px;
+ text-transform: uppercase;
+ padding-left: 2px;
+ padding-right: 15px;
+}
+
+/* Select */
+div.selector {
+ width: 190px;
+ font-size: 12px;
+}
+
+div.selector select {
+ min-width: 190px;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-size: 12px;
+ border: solid 1px #fff;
+}
+
+div.selector span {
+ padding: 0px 25px 0px 2px;
+
+ cursor: pointer;
+}
+
+div.selector span {
+ color: #666;
+ width: 158px;
+ text-shadow: 0 1px 0 #fff;
+}
+
+div.selector.disabled span {
+ color: #bbb;
+}
+
+/* Checker */
+div.checker{
+ margin-right: 5px;
+ margin-top: -1px;
+}
+
+/* Radio */
+div.radio {
+ margin-right: 3px;
+ margin-top: -1px;
+}
+
+/* Uploader */
+div.uploader {
+ width: 190px;
+ cursor: pointer;
+}
+
+div.uploader span.action {
+ width: 85px;
+ text-align: center;
+ text-shadow: #fff 0px 1px 0px;
+ background-color: #fff;
+ font-size: 11px;
+ font-weight: bold;
+}
+
+div.uploader span.filename {
+ color: #777;
+ width: 82px;
+ border-right: solid 1px #bbb;
+ font-size: 11px;
+}
+
+div.uploader input {
+ width: 190px;
+}
+
+div.uploader.disabled span.action {
+ color: #aaa;
+}
+
+div.uploader.disabled span.filename {
+ border-color: #ddd;
+ color: #aaa;
+}
+/*
+
+CORE FUNCTIONALITY
+
+Not advised to edit stuff below this line
+-----------------------------------------------------
+*/
+
+.selector,
+.checker,
+/*.button, */
+.radio,
+.uploader {
+ display: -moz-inline-box;
+ display: inline-block;
+ vertical-align: top;
+ zoom: 1;
+ *display: inline;
+}
+
+.selector select:focus, .radio input:focus, .checker input:focus, .uploader input:focus {
+ outline: 0;
+}
+
+/* Button */
+/*
+div.button a,
+div.button button,
+div.button input {
+ position: absolute;
+}
+
+div.button {
+ cursor: pointer;
+ position: relative;
+}
+
+div.button span {
+ display: -moz-inline-box;
+ display: inline-block;
+ line-height: 1;
+ text-align: center;
+}
+*/
+/* Select */
+
+div.selector {
+ position: relative;
+ padding-left: 10px;
+ overflow: hidden;
+}
+
+div.selector span {
+ display: block;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
+
+div.selector select {
+ position: absolute;
+ opacity: 0;
+ filter: alpha(opacity:0);
+ height: 25px;
+ border: none;
+ background: none;
+}
+
+/* Checker */
+
+div.checker {
+ position: relative;
+}
+
+div.checker span {
+ display: -moz-inline-box;
+ display: inline-block;
+ text-align: center;
+}
+
+div.checker input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ display: inline-block;
+ background: none;
+}
+
+/* Radio */
+
+div.radio {
+ position: relative;
+}
+
+div.radio span {
+ display: -moz-inline-box;
+ display: inline-block;
+ text-align: center;
+}
+
+div.radio input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ text-align: center;
+ display: inline-block;
+ background: none;
+}
+
+/* Uploader */
+
+div.uploader {
+ position: relative;
+ overflow: hidden;
+ cursor: default;
+}
+
+div.uploader span.action {
+ float: left;
+ display: inline;
+ padding: 2px 0px;
+ overflow: hidden;
+ cursor: pointer;
+}
+
+div.uploader span.filename {
+ padding: 0px 10px;
+ float: left;
+ display: block;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ cursor: default;
+}
+
+div.uploader input {
+ opacity: 0;
+ filter: alpha(opacity:0);
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ float: right;
+ height: 25px;
+ border: none;
+ cursor: default;
+}
\ No newline at end of file
diff --git a/catalog/view/javascript/d_quickcheckout/uniform/images/sprite.png b/catalog/view/javascript/d_quickcheckout/uniform/images/sprite.png
new file mode 100755
index 0000000..c8b320b
Binary files /dev/null and b/catalog/view/javascript/d_quickcheckout/uniform/images/sprite.png differ
diff --git a/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.js b/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.js
new file mode 100755
index 0000000..bf6af3f
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.js
@@ -0,0 +1,1072 @@
+/*
+
+Uniform v2.1.0
+Copyright © 2009 Josh Pyles / Pixelmatrix Design LLC
+http://pixelmatrixdesign.com
+
+Requires jQuery 1.3 or newer
+
+Much thanks to Thomas Reynolds and Buck Wilson for their help and advice on
+this.
+
+Disabling text selection is made possible by Mathias Bynens
+ and his noSelect plugin.
+, which is embedded.
+
+Also, thanks to David Kaneda and Eugene Bond for their contributions to the
+plugin.
+
+Tyler Akins has also rewritten chunks of the plugin, helped close many issues,
+and ensured version 2 got out the door.
+
+License:
+MIT License - http://www.opensource.org/licenses/mit-license.php
+
+Enjoy!
+
+*/
+/*global jQuery, window, document, navigator*/
+
+(function ($, undef) {
+ "use strict";
+
+ /**
+ * Use .prop() if jQuery supports it, otherwise fall back to .attr()
+ *
+ * @param jQuery $el jQuery'd element on which we're calling attr/prop
+ * @param ... All other parameters are passed to jQuery's function
+ * @return The result from jQuery
+ */
+ function attrOrProp($el) {
+ var args = Array.prototype.slice.call(arguments, 1);
+
+ if ($el.prop) {
+ // jQuery 1.6+
+ return $el.prop.apply($el, args);
+ }
+
+ // jQuery 1.5 and below
+ return $el.attr.apply($el, args);
+ }
+
+ /**
+ * For backwards compatibility with older jQuery libraries, only bind
+ * one thing at a time. Also, this function adds our namespace to
+ * events in one consistent location, shrinking the minified code.
+ *
+ * The properties on the events object are the names of the events
+ * that we are supposed to add to. It can be a space separated list.
+ * The namespace will be added automatically.
+ *
+ * @param jQuery $el
+ * @param Object options Uniform options for this element
+ * @param Object events Events to bind, properties are event names
+ */
+ function bindMany($el, options, events) {
+ var name, namespaced;
+
+ for (name in events) {
+ if (events.hasOwnProperty(name)) {
+ namespaced = name.replace(/ |$/g, options.eventNamespace);
+ $el.bind(namespaced, events[name]);
+ }
+ }
+ }
+
+ /**
+ * Bind the hover, active, focus, and blur UI updates
+ *
+ * @param jQuery $el Original element
+ * @param jQuery $target Target for the events (our div/span)
+ * @param Object options Uniform options for the element $target
+ */
+ function bindUi($el, $target, options) {
+ bindMany($el, options, {
+ focus: function () {
+ $target.addClass(options.focusClass);
+ },
+ blur: function () {
+ $target.removeClass(options.focusClass);
+ $target.removeClass(options.activeClass);
+ },
+ mouseenter: function () {
+ $target.addClass(options.hoverClass);
+ },
+ mouseleave: function () {
+ $target.removeClass(options.hoverClass);
+ $target.removeClass(options.activeClass);
+ },
+ "mousedown touchbegin": function () {
+ if (!$el.is(":disabled")) {
+ $target.addClass(options.activeClass);
+ }
+ },
+ "mouseup touchend": function () {
+ $target.removeClass(options.activeClass);
+ }
+ });
+ }
+
+ /**
+ * Remove the hover, focus, active classes.
+ *
+ * @param jQuery $el Element with classes
+ * @param Object options Uniform options for the element
+ */
+ function classClearStandard($el, options) {
+ $el.removeClass(options.hoverClass + " " + options.focusClass + " " + options.activeClass);
+ }
+
+ /**
+ * Add or remove a class, depending on if it's "enabled"
+ *
+ * @param jQuery $el Element that has the class added/removed
+ * @param String className Class or classes to add/remove
+ * @param Boolean enabled True to add the class, false to remove
+ */
+ function classUpdate($el, className, enabled) {
+ if (enabled) {
+ $el.addClass(className);
+ $el.parent().parent().addClass(className);
+ $('#'+$el.find('input[type="checkbox"]').attr('id')).val(1)
+ } else {
+ $el.removeClass(className);
+ $el.parent().parent().removeClass(className);
+ $('#'+$el.find('input[type="checkbox"]').attr('id')).val(0)
+ }
+ }
+
+ /**
+ * Updating the "checked" property can be a little tricky. This
+ * changed in jQuery 1.6 and now we can pass booleans to .prop().
+ * Prior to that, one either adds an attribute ("checked=checked") or
+ * removes the attribute.
+ *
+ * @param jQuery $tag Our Uniform span/div
+ * @param jQuery $el Original form element
+ * @param Object options Uniform options for this element
+ */
+ function classUpdateChecked($tag, $el, options) {
+ var c = "checked",
+ isChecked = $el.is(":" + c);
+
+ if ($el.prop) {
+ // jQuery 1.6+
+ $el.prop(c, isChecked);
+ } else {
+ // jQuery 1.5 and below
+ if (isChecked) {
+ $el.attr(c, c);
+ } else {
+ $el.removeAttr(c);
+ }
+ }
+
+ classUpdate($tag, options.checkedClass, isChecked);
+ }
+
+ /**
+ * Set or remove the "disabled" class for disabled elements, based on
+ * if the
+ *
+ * @param jQuery $tag Our Uniform span/div
+ * @param jQuery $el Original form element
+ * @param Object options Uniform options for this element
+ */
+ function classUpdateDisabled($tag, $el, options) {
+ classUpdate($tag, options.disabledClass, $el.is(":disabled"));
+ }
+
+ /**
+ * Wrap an element inside of a container or put the container next
+ * to the element. See the code for examples of the different methods.
+ *
+ * Returns the container that was added to the HTML.
+ *
+ * @param jQuery $el Element to wrap
+ * @param jQuery $container Add this new container around/near $el
+ * @param String method One of "after", "before" or "wrap"
+ * @return $container after it has been cloned for adding to $el
+ */
+ function divSpanWrap($el, $container, method) {
+ switch (method) {
+ case "after":
+ // Result:
+ $el.after($container);
+ return $el.next();
+ case "before":
+ // Result:
+ $el.before($container);
+ return $el.prev();
+ case "wrap":
+ // Result:
+ $el.wrap($container);
+ return $el.parent();
+ }
+
+ return null;
+ }
+
+
+ /**
+ * Create a div/span combo for uniforming an element
+ *
+ * @param jQuery $el Element to wrap
+ * @param Object options Options for the element, set by the user
+ * @param Object divSpanConfig Options for how we wrap the div/span
+ * @return Object Contains the div and span as properties
+ */
+ function divSpan($el, options, divSpanConfig) {
+ var $div, $span, id;
+
+ if (!divSpanConfig) {
+ divSpanConfig = {};
+ }
+
+ divSpanConfig = $.extend({
+ bind: {},
+ divClass: null,
+ divWrap: "wrap",
+ spanClass: null,
+ spanHtml: null,
+ spanWrap: "wrap"
+ }, divSpanConfig);
+
+ $div = $('
');
+ $span = $(' ');
+
+ // Automatically hide this div/span if the element is hidden.
+ // Do not hide if the element is hidden because a parent is hidden.
+ if (options.autoHide && $el.is(':hidden') && $el.css('display') === 'none') {
+ $div.hide();
+ }
+
+ if (divSpanConfig.divClass) {
+ $div.addClass(divSpanConfig.divClass);
+ }
+
+ if (options.wrapperClass) {
+ $div.addClass(options.wrapperClass);
+ }
+
+ if (divSpanConfig.spanClass) {
+ $span.addClass(divSpanConfig.spanClass);
+ }
+
+ id = attrOrProp($el, 'id');
+
+ if (options.useID && id) {
+ attrOrProp($div, 'id', options.idPrefix + '-' + id);
+ }
+
+ if (divSpanConfig.spanHtml) {
+ $span.html(divSpanConfig.spanHtml);
+ }
+
+ $div = divSpanWrap($el, $div, divSpanConfig.divWrap);
+ $span = divSpanWrap($el, $span, divSpanConfig.spanWrap);
+ classUpdateDisabled($div, $el, options);
+ return {
+ div: $div,
+ span: $span
+ };
+ }
+
+
+ /**
+ * Wrap an element with a span to apply a global wrapper class
+ *
+ * @param jQuery $el Element to wrap
+ * @param object options
+ * @return jQuery Wrapper element
+ */
+ function wrapWithWrapperClass($el, options) {
+ var $span;
+
+ if (!options.wrapperClass) {
+ return null;
+ }
+
+ $span = $(' ').addClass(options.wrapperClass);
+ $span = divSpanWrap($el, $span, "wrap");
+ return $span;
+ }
+
+
+ /**
+ * Test if high contrast mode is enabled.
+ *
+ * In high contrast mode, background images can not be set and
+ * they are always returned as 'none'.
+ *
+ * @return boolean True if in high contrast mode
+ */
+ function highContrast() {
+ var c, $div, el, rgb;
+
+ // High contrast mode deals with white and black
+ rgb = 'rgb(120,2,153)';
+ $div = $('');
+ $('body').append($div);
+ el = $div.get(0);
+
+ // $div.css() will get the style definition, not
+ // the actually displaying style
+ if (window.getComputedStyle) {
+ c = window.getComputedStyle(el, '').color;
+ } else {
+ c = (el.currentStyle || el.style || {}).color;
+ }
+
+ $div.remove();
+ return c.replace(/ /g, '') !== rgb;
+ }
+
+
+ /**
+ * Change text into safe HTML
+ *
+ * @param String text
+ * @return String HTML version
+ */
+ function htmlify(text) {
+ if (!text) {
+ return "";
+ }
+
+ return $('
').text(text).html();
+ }
+
+ /**
+ * If not MSIE, return false.
+ * If it is, return the version number.
+ *
+ * @return false|number
+ */
+ function isMsie() {
+ return navigator.cpuClass && !navigator.product;
+ }
+
+ /**
+ * Return true if this version of IE allows styling
+ *
+ * @return boolean
+ */
+ function isMsieSevenOrNewer() {
+ if (typeof window.XMLHttpRequest !== 'undefined') {
+ return true;
+ }
+
+ return false;
+ }
+
+ /**
+ * Test if the element is a multiselect
+ *
+ * @param jQuery $el Element
+ * @return boolean true/false
+ */
+ function isMultiselect($el) {
+ var elSize;
+
+ if ($el[0].multiple) {
+ return true;
+ }
+
+ elSize = attrOrProp($el, "size");
+
+ if (!elSize || elSize <= 1) {
+ return false;
+ }
+
+ return true;
+ }
+
+ /**
+ * Meaningless utility function. Used mostly for improving minification.
+ *
+ * @return false
+ */
+ function returnFalse() {
+ return false;
+ }
+
+ /**
+ * noSelect plugin, very slightly modified
+ * http://mths.be/noselect v1.0.3
+ *
+ * @param jQuery $elem Element that we don't want to select
+ * @param Object options Uniform options for the element
+ */
+ function noSelect($elem, options) {
+ var none = 'none';
+ bindMany($elem, options, {
+ 'selectstart dragstart mousedown': returnFalse
+ });
+
+ $elem.css({
+ MozUserSelect: none,
+ msUserSelect: none,
+ webkitUserSelect: none,
+ userSelect: none
+ });
+ }
+
+ /**
+ * Updates the filename tag based on the value of the real input
+ * element.
+ *
+ * @param jQuery $el Actual form element
+ * @param jQuery $filenameTag Span/div to update
+ * @param Object options Uniform options for this element
+ */
+ function setFilename($el, $filenameTag, options) {
+ var filename = $el.val();
+
+ if (filename === "") {
+ filename = options.fileDefaultHtml;
+ } else {
+ filename = filename.split(/[\/\\]+/);
+ filename = filename[(filename.length - 1)];
+ }
+
+ $filenameTag.text(filename);
+ }
+
+
+ /**
+ * Function from jQuery to swap some CSS values, run a callback,
+ * then restore the CSS. Modified to pass JSLint and handle undefined
+ * values with 'use strict'.
+ *
+ * @param jQuery $el Element
+ * @param object newCss CSS values to swap out
+ * @param Function callback Function to run
+ */
+ function swap($elements, newCss, callback) {
+ var restore, item;
+
+ restore = [];
+
+ $elements.each(function () {
+ var name;
+
+ for (name in newCss) {
+ if (Object.prototype.hasOwnProperty.call(newCss, name)) {
+ restore.push({
+ el: this,
+ name: name,
+ old: this.style[name]
+ });
+
+ this.style[name] = newCss[name];
+ }
+ }
+ });
+
+ callback();
+
+ while (restore.length) {
+ item = restore.pop();
+ item.el.style[item.name] = item.old;
+ }
+ }
+
+
+ /**
+ * The browser doesn't provide sizes of elements that are not visible.
+ * This will clone an element and add it to the DOM for calculations.
+ *
+ * @param jQuery $el
+ * @param String method
+ */
+ function sizingInvisible($el, callback) {
+ var targets;
+
+ // We wish to target ourselves and any parents as long as
+ // they are not visible
+ targets = $el.parents();
+ targets.push($el[0]);
+ targets = targets.not(':visible');
+ swap(targets, {
+ visibility: "hidden",
+ display: "block",
+ position: "absolute"
+ }, callback);
+ }
+
+
+ /**
+ * Standard way to unwrap the div/span combination from an element
+ *
+ * @param jQuery $el Element that we wish to preserve
+ * @param Object options Uniform options for the element
+ * @return Function This generated function will perform the given work
+ */
+ function unwrapUnwrapUnbindFunction($el, options) {
+ return function () {
+ $el.unwrap().unwrap().unbind(options.eventNamespace);
+ };
+ }
+
+ var allowStyling = true, // False if IE6 or other unsupported browsers
+ highContrastTest = false, // Was the high contrast test ran?
+ uniformHandlers = [ // Objects that take care of "unification"
+ {
+ // Buttons
+ match: function ($el) {
+ return $el.is("a, button, :submit, :reset, input[type='button']");
+ },
+ apply: function ($el, options) {
+ var $div, defaultSpanHtml, ds, getHtml, doingClickEvent;
+ defaultSpanHtml = options.submitDefaultHtml;
+
+ if ($el.is(":reset")) {
+ defaultSpanHtml = options.resetDefaultHtml;
+ }
+
+ if ($el.is("a, button")) {
+ // Use the HTML inside the tag
+ getHtml = function () {
+ return $el.html() || defaultSpanHtml;
+ };
+ } else {
+ // Use the value property of the element
+ getHtml = function () {
+ return htmlify(attrOrProp($el, "value")) || defaultSpanHtml;
+ };
+ }
+
+ ds = divSpan($el, options, {
+ divClass: options.buttonClass,
+ spanHtml: getHtml(),
+ });
+ $div = ds.div;
+ bindUi($el, $div, options);
+ doingClickEvent = false;
+ bindMany($div, options, {
+ "click touchend": function () {
+ var ev, res, target, href;
+
+ if (doingClickEvent) {
+ return;
+ }
+
+ if ($el.is(':disabled')) {
+ return;
+ }
+
+ doingClickEvent = true;
+
+ if ($el[0].dispatchEvent) {
+ ev = document.createEvent("MouseEvents");
+ ev.initEvent("click", true, true);
+ res = $el[0].dispatchEvent(ev);
+
+ if ($el.is('a') && res) {
+ target = attrOrProp($el, 'target');
+ href = attrOrProp($el, 'href');
+
+ if (!target || target === '_self') {
+ document.location.href = href;
+ } else {
+ window.open(href, target);
+ }
+ }
+ } else {
+ $el.click();
+ }
+
+ doingClickEvent = false;
+ }
+ });
+ noSelect($div, options);
+ return {
+ remove: function () {
+ // Move $el out
+ $div.after($el);
+
+ // Remove div and span
+ $div.remove();
+
+ // Unbind events
+ $el.unbind(options.eventNamespace);
+ return $el;
+ },
+ update: function () {
+ classClearStandard($div, options);
+ classUpdateDisabled($div, $el, options);
+ $el.detach();
+ ds.span.html(getHtml()).append($el);
+ }
+ };
+ }
+ },
+ {
+ // Checkboxes
+ match: function ($el) {
+ return $el.is(":checkbox");
+ },
+ apply: function ($el, options) {
+ var ds, $div, $span;
+ ds = divSpan($el, options, {
+ divClass: options.checkboxClass
+ });
+ $div = ds.div;
+ $span = ds.span;
+
+ // Add focus classes, toggling, active, etc.
+ bindUi($el, $div, options);
+ bindMany($el, options, {
+ "click touchend": function () {
+ classUpdateChecked($span, $el, options);
+ }
+ });
+ classUpdateChecked($span, $el, options);
+ return {
+ remove: unwrapUnwrapUnbindFunction($el, options),
+ update: function () {
+ classClearStandard($div, options);
+ $span.removeClass(options.checkedClass);
+ classUpdateChecked($span, $el, options);
+ classUpdateDisabled($div, $el, options);
+ }
+ };
+ }
+ },
+ {
+ // File selection / uploads
+ match: function ($el) {
+ return $el.is(":file");
+ },
+ apply: function ($el, options) {
+ var ds, $div, $filename, $button;
+
+ // The "span" is the button
+ ds = divSpan($el, options, {
+ divClass: options.fileClass,
+ spanClass: options.fileButtonClass,
+ spanHtml: options.fileButtonHtml,
+ spanWrap: "after"
+ });
+ $div = ds.div;
+ $button = ds.span;
+ $filename = $("
").html(options.fileDefaultHtml);
+ $filename.addClass(options.filenameClass);
+ $filename = divSpanWrap($el, $filename, "after");
+
+ // Set the size
+ if (!attrOrProp($el, "size")) {
+ attrOrProp($el, "size", $div.width() / 10);
+ }
+
+ // Actions
+ function filenameUpdate() {
+ setFilename($el, $filename, options);
+ }
+
+ bindUi($el, $div, options);
+
+ // Account for input saved across refreshes
+ filenameUpdate();
+
+ // IE7 doesn't fire onChange until blur or second fire.
+ if (isMsie()) {
+ // IE considers browser chrome blocking I/O, so it
+ // suspends tiemouts until after the file has
+ // been selected.
+ bindMany($el, options, {
+ click: function () {
+ $el.trigger("change");
+ setTimeout(filenameUpdate, 0);
+ }
+ });
+ } else {
+ // All other browsers behave properly
+ bindMany($el, options, {
+ change: filenameUpdate
+ });
+ }
+
+ noSelect($filename, options);
+ noSelect($button, options);
+ return {
+ remove: function () {
+ // Remove filename and button
+ $filename.remove();
+ $button.remove();
+
+ // Unwrap parent div, remove events
+ return $el.unwrap().unbind(options.eventNamespace);
+ },
+ update: function () {
+ classClearStandard($div, options);
+ setFilename($el, $filename, options);
+ classUpdateDisabled($div, $el, options);
+ }
+ };
+ }
+ },
+ {
+ // Input fields (text)
+ match: function ($el) {
+ if ($el.is("input")) {
+ var t = (" " + attrOrProp($el, "type") + " ").toLowerCase(),
+ allowed = " color date datetime datetime-local email month number password search tel text time url week ";
+ return allowed.indexOf(t) >= 0;
+ }
+
+ return false;
+ },
+ apply: function ($el, options) {
+ var elType, $wrapper;
+
+ elType = attrOrProp($el, "type");
+ $el.addClass(options.inputClass);
+ $wrapper = wrapWithWrapperClass($el, options);
+ bindUi($el, $el, options);
+
+ if (options.inputAddTypeAsClass) {
+ $el.addClass(elType);
+ }
+
+ return {
+ remove: function () {
+ $el.removeClass(options.inputClass);
+
+ if (options.inputAddTypeAsClass) {
+ $el.removeClass(elType);
+ }
+
+ if ($wrapper) {
+ $el.unwrap();
+ }
+ },
+ update: returnFalse
+ };
+ }
+ },
+ {
+ // Radio buttons
+ match: function ($el) {
+ return $el.is(":radio");
+ },
+ apply: function ($el, options) {
+ var ds, $div, $span;
+ ds = divSpan($el, options, {
+ divClass: options.radioClass
+ });
+ $div = ds.div;
+ $span = ds.span;
+
+ // Add classes for focus, handle active, checked
+ bindUi($el, $div, options);
+ bindMany($el, options, {
+ "click touchend": function () {
+ // Find all radios with the same name, then update
+ // them with $.uniform.update() so the right
+ // per-element options are used
+ $.uniform.update($(':radio[name="' + attrOrProp($el, "name") + '"]'));
+ }
+ });
+ classUpdateChecked($span, $el, options);
+ return {
+ remove: unwrapUnwrapUnbindFunction($el, options),
+ update: function () {
+ classClearStandard($div, options);
+ classUpdateChecked($span, $el, options);
+ classUpdateDisabled($div, $el, options);
+ }
+ };
+ }
+ },
+ {
+ // Select lists, but do not style multiselects here
+ match: function ($el) {
+ if ($el.is("select") && !isMultiselect($el)) {
+ return true;
+ }
+
+ return false;
+ },
+ apply: function ($el, options) {
+ var ds, $div, $span, origElemWidth;
+
+ if (options.selectAutoWidth) {
+ sizingInvisible($el, function () {
+ origElemWidth = $el.width();
+ });
+ }
+
+ ds = divSpan($el, options, {
+ divClass: options.selectClass,
+ spanHtml: ($el.find(":selected:first") || $el.find("option:first")).html(),
+ spanWrap: "before"
+ });
+ $div = ds.div;
+ $span = ds.span;
+
+ if (options.selectAutoWidth) {
+ // Use the width of the select and adjust the
+ // span and div accordingly
+ sizingInvisible($el, function () {
+ // Force "display: block" - related to bug #287
+ swap($([ $span[0], $div[0] ]), {
+ display: "block"
+ }, function () {
+ var spanPad;
+ spanPad = $span.outerWidth() - $span.width();
+ $div.width(origElemWidth + spanPad);
+ $span.width(origElemWidth);
+ });
+ });
+ } else {
+ // Force the select to fill the size of the div
+ $div.addClass('fixedWidth');
+ }
+
+ // Take care of events
+ bindUi($el, $div, options);
+ bindMany($el, options, {
+ change: function () {
+ $span.html($el.find(":selected").html());
+ $div.removeClass(options.activeClass);
+ },
+ "click touchend": function () {
+ // IE7 and IE8 may not update the value right
+ // until after click event - issue #238
+ var selHtml = $el.find(":selected").html();
+
+ if ($span.html() !== selHtml) {
+ // Change was detected
+ // Fire the change event on the select tag
+ $el.trigger('change');
+ }
+ },
+ keyup: function () {
+ $span.html($el.find(":selected").html());
+ }
+ });
+ noSelect($span, options);
+ return {
+ remove: function () {
+ // Remove sibling span
+ $span.remove();
+
+ // Unwrap parent div
+ $el.unwrap().unbind(options.eventNamespace);
+ return $el;
+ },
+ update: function () {
+ if (options.selectAutoWidth) {
+ // Easier to remove and reapply formatting
+ $.uniform.restore($el);
+ $el.uniform(options);
+ } else {
+ classClearStandard($div, options);
+
+ // Reset current selected text
+ $span.html($el.find(":selected").html());
+ classUpdateDisabled($div, $el, options);
+ }
+ }
+ };
+ }
+ },
+ {
+ // Select lists - multiselect lists only
+ match: function ($el) {
+ if ($el.is("select") && isMultiselect($el)) {
+ return true;
+ }
+
+ return false;
+ },
+ apply: function ($el, options) {
+ var $wrapper;
+
+ $el.addClass(options.selectMultiClass);
+ $wrapper = wrapWithWrapperClass($el, options);
+ bindUi($el, $el, options);
+
+ return {
+ remove: function () {
+ $el.removeClass(options.selectMultiClass);
+
+ if ($wrapper) {
+ $el.unwrap();
+ }
+ },
+ update: returnFalse
+ };
+ }
+ },
+ {
+ // Textareas
+ match: function ($el) {
+ return $el.is("textarea");
+ },
+ apply: function ($el, options) {
+ var $wrapper;
+
+ $el.addClass(options.textareaClass);
+ $wrapper = wrapWithWrapperClass($el, options);
+ bindUi($el, $el, options);
+
+ return {
+ remove: function () {
+ $el.removeClass(options.textareaClass);
+
+ if ($wrapper) {
+ $el.unwrap();
+ }
+ },
+ update: returnFalse
+ };
+ }
+ }
+ ];
+
+ // IE6 can't be styled - can't set opacity on select
+ if (isMsie() && !isMsieSevenOrNewer()) {
+ allowStyling = false;
+ }
+
+ $.uniform = {
+ // Default options that can be overridden globally or when uniformed
+ // globally: $.uniform.defaults.fileButtonHtml = "Pick A File";
+ // on uniform: $('input').uniform({fileButtonHtml: "Pick a File"});
+ defaults: {
+ activeClass: "active",
+ autoHide: true,
+ buttonClass: "button",
+ checkboxClass: "checker",
+ checkedClass: "checked",
+ disabledClass: "disabled",
+ eventNamespace: ".uniform",
+ fileButtonClass: "action",
+ fileButtonHtml: "Choose File",
+ fileClass: "uploader",
+ fileDefaultHtml: "No file selected",
+ filenameClass: "filename",
+ focusClass: "focus",
+ hoverClass: "hover",
+ idPrefix: "uniform",
+ inputAddTypeAsClass: true,
+ inputClass: "uniform-input",
+ radioClass: "radio",
+ resetDefaultHtml: "Reset",
+ resetSelector: false, // We'll use our own function when you don't specify one
+ selectAutoWidth: true,
+ selectClass: "selector",
+ selectMultiClass: "uniform-multiselect",
+ submitDefaultHtml: "Submit", // Only text allowed
+ textareaClass: "uniform",
+ useID: true,
+ wrapperClass: null
+ },
+
+ // All uniformed elements - DOM objects
+ elements: []
+ };
+
+ $.fn.uniform = function (options) {
+ var el = this;
+ options = $.extend({}, $.uniform.defaults, options);
+
+ // If we are in high contrast mode, do not allow styling
+ if (!highContrastTest) {
+ highContrastTest = true;
+
+ if (highContrast()) {
+ allowStyling = false;
+ }
+ }
+
+ // Only uniform on browsers that work
+ if (!allowStyling) {
+ return this;
+ }
+
+ // Code for specifying a reset button
+ if (options.resetSelector) {
+ $(options.resetSelector).mouseup(function () {
+ window.setTimeout(function () {
+ $.uniform.update(el);
+ }, 10);
+ });
+ }
+
+ return this.each(function () {
+ var $el = $(this), i, handler, callbacks;
+
+ // Avoid uniforming elements already uniformed - just update
+ if ($el.data("uniformed")) {
+ $.uniform.update($el);
+ return;
+ }
+
+ // See if we have any handler for this type of element
+ for (i = 0; i < uniformHandlers.length; i = i + 1) {
+ handler = uniformHandlers[i];
+
+ if (handler.match($el, options)) {
+ callbacks = handler.apply($el, options);
+ $el.data("uniformed", callbacks);
+
+ // Store element in our global array
+ $.uniform.elements.push($el.get(0));
+ return;
+ }
+ }
+
+ // Could not style this element
+ });
+ };
+
+ $.uniform.restore = $.fn.uniform.restore = function (elem) {
+ if (elem === undef) {
+ elem = $.uniform.elements;
+ }
+
+ $(elem).each(function () {
+ var $el = $(this), index, elementData;
+ elementData = $el.data("uniformed");
+
+ // Skip elements that are not uniformed
+ if (!elementData) {
+ return;
+ }
+
+ // Unbind events, remove additional markup that was added
+ elementData.remove();
+
+ // Remove item from list of uniformed elements
+ index = $.inArray(this, $.uniform.elements);
+
+ if (index >= 0) {
+ $.uniform.elements.splice(index, 1);
+ }
+
+ $el.removeData("uniformed");
+ });
+ };
+
+ $.uniform.update = $.fn.uniform.update = function (elem) {
+ if (elem === undef) {
+ elem = $.uniform.elements;
+ }
+
+ $(elem).each(function () {
+ var $el = $(this), elementData;
+ elementData = $el.data("uniformed");
+
+ // Skip elements that are not uniformed
+ if (!elementData) {
+ return;
+ }
+
+ elementData.update($el, elementData.options);
+ });
+ };
+}(jQuery));
diff --git a/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.min.js b/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.min.js
new file mode 100755
index 0000000..1198c13
--- /dev/null
+++ b/catalog/view/javascript/d_quickcheckout/uniform/jquery.uniform.min.js
@@ -0,0 +1 @@
+(function(a){a.uniform={options:{selectClass:"selector",radioClass:"radio",checkboxClass:"checker",fileClass:"uploader",filenameClass:"filename",fileBtnClass:"action",fileDefaultText:"No file selected",fileBtnText:"Choose File",checkedClass:"checked",focusClass:"focus",disabledClass:"disabled",buttonClass:"button",activeClass:"active",hoverClass:"hover",useID:true,idPrefix:"uniform",resetSelector:false,autoHide:true},elements:[]};if(a.browser.msie&&a.browser.version<7){a.support.selectOpacity=false}else{a.support.selectOpacity=true}a.fn.uniform=function(k){k=a.extend(a.uniform.options,k);var d=this;if(k.resetSelector!=false){a(k.resetSelector).mouseup(function(){function l(){a.uniform.update(d)}setTimeout(l,10)})}function j(l){$el=a(l);$el.addClass($el.attr("type"));b(l)}function g(l){a(l).addClass("uniform");b(l)}function i(o){var m=a(o);var p=a("
"),l=a("
");p.addClass(k.buttonClass);if(k.useID&&m.attr("id")!=""){p.attr("id",k.idPrefix+"-"+m.attr("id"))}var n;if(m.is("a")||m.is("button")){n=m.text()}else{if(m.is(":submit")||m.is(":reset")||m.is("input[type=button]")){n=m.attr("value")}}n=n==""?m.is(":reset")?"Reset":"Submit":n;l.html(n);m.css("opacity",0);m.wrap(p);m.wrap(l);p=m.closest("div");l=m.closest("span");if(m.is(":disabled")){p.addClass(k.disabledClass)}p.bind({"mouseenter.uniform":function(){p.addClass(k.hoverClass)},"mouseleave.uniform":function(){p.removeClass(k.hoverClass);p.removeClass(k.activeClass)},"mousedown.uniform touchbegin.uniform":function(){p.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"click.uniform touchend.uniform":function(r){if(a(r.target).is("span")||a(r.target).is("div")){if(o[0].dispatchEvent){var q=document.createEvent("MouseEvents");q.initEvent("click",true,true);o[0].dispatchEvent(q)}else{o[0].click()}}}});o.bind({"focus.uniform":function(){p.addClass(k.focusClass)},"blur.uniform":function(){p.removeClass(k.focusClass)}});a.uniform.noSelect(p);b(o)}function e(o){var m=a(o);var p=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){p.hide()}p.addClass(k.selectClass);if(k.useID&&o.attr("id")!=""){p.attr("id",k.idPrefix+"-"+o.attr("id"))}var n=o.find(":selected:first");if(n.length==0){n=o.find("option:first")}l.html(n.html());o.css("opacity",0);o.wrap(p);o.before(l);p=o.parent("div");l=o.siblings("span");o.bind({"change.uniform":function(){l.text(o.find(":selected").html());p.removeClass(k.activeClass)},"focus.uniform":function(){p.addClass(k.focusClass)},"blur.uniform":function(){p.removeClass(k.focusClass);p.removeClass(k.activeClass)},"mousedown.uniform touchbegin.uniform":function(){p.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"click.uniform touchend.uniform":function(){p.removeClass(k.activeClass)},"mouseenter.uniform":function(){p.addClass(k.hoverClass)},"mouseleave.uniform":function(){p.removeClass(k.hoverClass);p.removeClass(k.activeClass)},"keyup.uniform":function(){l.text(o.find(":selected").html())}});if(a(o).attr("disabled")){p.addClass(k.disabledClass)}a.uniform.noSelect(l);b(o)}function f(n){var m=a(n);var o=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){o.hide()}o.addClass(k.checkboxClass);if(k.useID&&n.attr("id")!=""){o.attr("id",k.idPrefix+"-"+n.attr("id"))}a(n).wrap(o);a(n).wrap(l);l=n.parent();o=l.parent();a(n).css("opacity",0).bind({"focus.uniform":function(){o.addClass(k.focusClass)},"blur.uniform":function(){o.removeClass(k.focusClass)},"click.uniform touchend.uniform":function(){if(!a(n).attr("checked")){l.removeClass(k.checkedClass)}else{l.addClass(k.checkedClass)}},"mousedown.uniform touchbegin.uniform":function(){o.addClass(k.activeClass)},"mouseup.uniform touchend.uniform":function(){o.removeClass(k.activeClass)},"mouseenter.uniform":function(){o.addClass(k.hoverClass)},"mouseleave.uniform":function(){o.removeClass(k.hoverClass);o.removeClass(k.activeClass)}});if(a(n).attr("checked")){l.addClass(k.checkedClass)}if(a(n).attr("disabled")){o.addClass(k.disabledClass)}b(n)}function c(n){var m=a(n);var o=a("
"),l=a(" ");if(!m.css("display")=="none"&&k.autoHide){o.hide()}o.addClass(k.radioClass);if(k.useID&&n.attr("id")!=""){o.attr("id",k.idPrefix+"-"+n.attr("id"))}a(n).wrap(o);a(n).wrap(l);l=n.parent();o=l.parent();a(n).css("opacity",0).bind({"focus.uniform":function(){o.addClass(k.focusClass)},"blur.uniform":function(){o.removeClass(k.focusClass)},"click.uniform touchend.uniform":function(){if(!a(n).attr("checked")){l.removeClass(k.checkedClass)}else{var p=k.radioClass.split(" ")[0];a("."+p+" span."+k.checkedClass+":has([name='"+a(n).attr("name")+"'])").removeClass(k.checkedClass);l.addClass(k.checkedClass)}},"mousedown.uniform touchend.uniform":function(){if(!a(n).is(":disabled")){o.addClass(k.activeClass)}},"mouseup.uniform touchbegin.uniform":function(){o.removeClass(k.activeClass)},"mouseenter.uniform touchend.uniform":function(){o.addClass(k.hoverClass)},"mouseleave.uniform":function(){o.removeClass(k.hoverClass);o.removeClass(k.activeClass)}});if(a(n).attr("checked")){l.addClass(k.checkedClass)}if(a(n).attr("disabled")){o.addClass(k.disabledClass)}b(n)}function h(q){var o=a(q);var r=a("
"),p=a(""+k.fileDefaultText+" "),m=a(""+k.fileBtnText+" ");if(!o.css("display")=="none"&&k.autoHide){r.hide()}r.addClass(k.fileClass);p.addClass(k.filenameClass);m.addClass(k.fileBtnClass);if(k.useID&&o.attr("id")!=""){r.attr("id",k.idPrefix+"-"+o.attr("id"))}o.wrap(r);o.after(m);o.after(p);r=o.closest("div");p=o.siblings("."+k.filenameClass);m=o.siblings("."+k.fileBtnClass);if(!o.attr("size")){var l=r.width();o.attr("size",l/10)}var n=function(){var s=o.val();if(s===""){s=k.fileDefaultText}else{s=s.split(/[\/\\]+/);s=s[(s.length-1)]}p.text(s)};n();o.css("opacity",0).bind({"focus.uniform":function(){r.addClass(k.focusClass)},"blur.uniform":function(){r.removeClass(k.focusClass)},"mousedown.uniform":function(){if(!a(q).is(":disabled")){r.addClass(k.activeClass)}},"mouseup.uniform":function(){r.removeClass(k.activeClass)},"mouseenter.uniform":function(){r.addClass(k.hoverClass)},"mouseleave.uniform":function(){r.removeClass(k.hoverClass);r.removeClass(k.activeClass)}});if(a.browser.msie){o.bind("click.uniform.ie7",function(){setTimeout(n,0)})}else{o.bind("change.uniform",n)}if(o.attr("disabled")){r.addClass(k.disabledClass)}a.uniform.noSelect(p);a.uniform.noSelect(m);b(q)}a.uniform.restore=function(l){if(l==undefined){l=a(a.uniform.elements)}a(l).each(function(){if(a(this).is(":checkbox")){a(this).unwrap().unwrap()}else{if(a(this).is("select")){a(this).siblings("span").remove();a(this).unwrap()}else{if(a(this).is(":radio")){a(this).unwrap().unwrap()}else{if(a(this).is(":file")){a(this).siblings("span").remove();a(this).unwrap()}else{if(a(this).is("button, :submit, :reset, a, input[type='button']")){a(this).unwrap().unwrap()}}}}}a(this).unbind(".uniform");a(this).css("opacity","1");var m=a.inArray(a(l),a.uniform.elements);a.uniform.elements.splice(m,1)})};function b(l){l=a(l).get();if(l.length>1){a.each(l,function(m,n){a.uniform.elements.push(n)})}else{a.uniform.elements.push(l)}}a.uniform.noSelect=function(l){function m(){return false}a(l).each(function(){this.onselectstart=this.ondragstart=m;a(this).mousedown(m).css({MozUserSelect:"none"})})};a.uniform.update=function(l){if(l==undefined){l=a(a.uniform.elements)}l=a(l);l.each(function(){var n=a(this);if(n.is("select")){var m=n.siblings("span");var p=n.parent("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.html(n.find(":selected").html());if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":checkbox")){var m=n.closest("span");var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.removeClass(k.checkedClass);if(n.is(":checked")){m.addClass(k.checkedClass)}if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":radio")){var m=n.closest("span");var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);m.removeClass(k.checkedClass);if(n.is(":checked")){m.addClass(k.checkedClass)}if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":file")){var p=n.parent("div");var o=n.siblings(k.filenameClass);btnTag=n.siblings(k.fileBtnClass);p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);o.text(n.val());if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}else{if(n.is(":submit")||n.is(":reset")||n.is("button")||n.is("a")||l.is("input[type=button]")){var p=n.closest("div");p.removeClass(k.hoverClass+" "+k.focusClass+" "+k.activeClass);if(n.is(":disabled")){p.addClass(k.disabledClass)}else{p.removeClass(k.disabledClass)}}}}}}})};return this.each(function(){if(a.support.selectOpacity){var l=a(this);if(l.is("select")){if(l.attr("multiple")!=true){if(l.attr("size")==undefined||l.attr("size")<=1){e(l)}}}else{if(l.is(":checkbox")){f(l)}else{if(l.is(":radio")){c(l)}else{if(l.is(":file")){h(l)}else{if(l.is(":text, :password, input[type='email']")){j(l)}else{if(l.is("textarea")){g(l)}else{if(l.is("a")||l.is(":submit")||l.is(":reset")||l.is("button")||l.is("input[type=button]")){i(l)}}}}}}}}})}})(jQuery);
\ No newline at end of file
diff --git a/catalog/view/theme/default/image/d_quickcheckout/apple.jpg b/catalog/view/theme/default/image/d_quickcheckout/apple.jpg
new file mode 100755
index 0000000..76fca9e
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/apple.jpg differ
diff --git a/catalog/view/theme/default/image/d_quickcheckout/icons_sprite.png b/catalog/view/theme/default/image/d_quickcheckout/icons_sprite.png
new file mode 100755
index 0000000..c276fec
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/icons_sprite.png differ
diff --git a/catalog/view/theme/default/image/d_quickcheckout/preloader.gif b/catalog/view/theme/default/image/d_quickcheckout/preloader.gif
new file mode 100755
index 0000000..e150018
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/preloader.gif differ
diff --git a/catalog/view/theme/default/image/d_quickcheckout/preloader_classic.gif b/catalog/view/theme/default/image/d_quickcheckout/preloader_classic.gif
new file mode 100755
index 0000000..a171bc6
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/preloader_classic.gif differ
diff --git a/catalog/view/theme/default/image/d_quickcheckout/sprite.png b/catalog/view/theme/default/image/d_quickcheckout/sprite.png
new file mode 100755
index 0000000..c8b320b
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/sprite.png differ
diff --git a/catalog/view/theme/default/image/d_quickcheckout/ui_admin_panel_sprite.png b/catalog/view/theme/default/image/d_quickcheckout/ui_admin_panel_sprite.png
new file mode 100755
index 0000000..c276fec
Binary files /dev/null and b/catalog/view/theme/default/image/d_quickcheckout/ui_admin_panel_sprite.png differ
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/d_quickcheckout.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/d_quickcheckout.css
new file mode 100755
index 0000000..0e5f080
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/d_quickcheckout.css
@@ -0,0 +1,889 @@
+@charset "utf-8";
+
+
+/* Modal */
+#quickcheckout .modal-footer {
+ margin-top: 0px;
+}
+
+/*
+* Content
+* Basic styles
+* Labels
+* Tooltips
+* Popups
+* Step 1 login
+* Step 2 payment address
+* Step 3 shipping address
+* Step 4 shipping method
+* Step 5 payment method
+* Step 6 cart
+* Step 7 payment
+* Step 8 confirm
+* Debug
+* Fixes
+*/
+
+/* CSS Document */
+/*#quickcheckout,
+#quickcheckout input,
+#quickcheckout select,
+#quickcheckout textarea{
+ font-family: 'Open Sans', sans-serif;
+ font-size: 14px;
+ line-height: 1.1
+}*/
+#quickcheckout [class^="qc-icon-"]{
+ background: none
+}
+/*#quickcheckout .block-content {
+ margin-bottom:10px;
+}*/
+#quickcheckout #qc_logo{
+ margin:20px 0px;
+ display: block;
+ text-align: center;
+}
+#quickcheckout .column {
+ overflow:hidden
+}
+#quickcheckout .hide,
+#quickcheckout .qc-hide{
+ display:none
+}
+/*#quickcheckout b {
+ font-weight:bold
+}*/
+#quickcheckout .wait {
+ width:100%;
+ text-align:center;
+ background:rgba(0, 0, 0, 0.1);
+ position:relative;
+ height:0px;
+ position:fixed;
+ top:0px;
+ left:0px;
+ z-index:10000;
+}
+#quickcheckout .wait span {
+ display: inline-block;
+ zoom:1;
+ *display:inline;
+ background-color:#efefef;
+ width:48px;
+ height:45px;
+ padding:5px;
+ position:relative;
+ border-radius: 0px 0px 5px 5px;
+ top:0px;
+ margin-top:0px;
+}
+#quickcheckout {
+ position: relative;
+}
+#quickcheckout .processing-payment{
+ position: fixed;
+ z-index: 100000000;
+ top:0px;
+ left: 0px;
+ width: 100%;
+ height: 100%;
+ background: rgba(0,0,0,0.6);
+ display: none;
+
+}
+#quickcheckout .processing-payment .text{
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ display: block;
+ width: 200px;
+ box-sizing: border-box;
+ margin: 25px 0px 0px -100px;
+ font-size: 18px;
+ color: #fff;
+ text-align: center;
+}
+#quickcheckout .processing-payment .preloader .spinner *{
+ background: #fff !important
+}
+#quickcheckout .block-content{
+ margin: 0 -15px;
+}
+#quickcheckout .panel-heading *{
+ vertical-align: middle;
+ font-size: 14px;
+}
+/*#quickcheckout small {
+ font-size:11px;
+ line-height:14px;
+}
+#quickcheckout .box {
+ margin: 9px 0px 0px 0px;
+ min-width: 180px;
+}*/
+/*#quickcheckout .box .box-heading {
+ padding: 10px;
+}*/
+/*#quickcheckout .box .box-content {
+ padding:10px;
+}*/
+/*#quickcheckout .box .box-content ul li {
+ display:block
+}*/
+/*#quickcheckout #confirm_inputs {
+ padding:5px;
+}
+#quickcheckout .clear {
+ clear:both;
+ visibility: visible;
+ height: inherit;
+}*/
+/*#quickcheckout #step_1 .box {
+ float:left;
+ width:32%;
+ margin-left: 0.5%;
+ margin-right:0.5%
+}
+#quickcheckout #step_1 .box .box-heading {
+ white-space: nowrap;
+ overflow: hidden;
+}
+#quickcheckout label {
+ width:45% !important;
+ margin: 0px 0px 3px 0px !important;
+ display:inline-block !important;
+ zoom:1;
+ *display:inline;
+}
+#quickcheckout #step_1 #option_register label, #quickcheckout #step_1 #option_guest label {
+ width: 80% !important;
+ float: none !important;
+}
+#quickcheckout #button_login {
+ margin-bottom:4px;
+}
+#quickcheckout #remeber_password {
+ white-space: nowrap;
+ vertical-align: middle;
+}*/
+/*#quickcheckout .block label {
+ width:100%%;
+ display:block;
+ margin:2px;
+ vertical-align: middle;
+}*/
+/*#quickcheckout select{
+ height: 39px;
+ line-height: 1.1;
+ box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ font-size: inherit;
+ font-family: inherit;
+ width: 100%
+}
+*/
+/*#quickcheckout #step_1 input[type=text],
+#quickcheckout #step_1 input[type=password],
+#quickcheckout #step_1 select,
+#quickcheckout #step_2 input[type=text],
+#quickcheckout #step_2 input[type=password],
+#quickcheckout #step_2 select,
+#quickcheckout #step_3 input[type=text],
+#quickcheckout #step_3 input[type=password],
+#quickcheckout #step_3 select {
+ width:53%;
+ display:inline-block !important;
+ zoom:1;
+ *display:inline;
+ box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ margin: 2px 0px;
+}
+#quickcheckout #step_1 .block input[type=text],
+#quickcheckout #step_1 .block input[type=password],
+#quickcheckout #step_1 .block select,
+#quickcheckout #step_3 .block input[type=text],
+#quickcheckout #step_3 .block input[type=password],
+#quickcheckout #step_3 .block select {
+ width:100%;
+ display:block;
+ margin:2px;
+}*/
+/*#quickcheckout select option {
+ background-color:transparent
+}*/
+
+#quickcheckout #confirm_payment .buttons {
+ border:none;
+ background:none;
+ padding:0px;
+ margin:0px;
+}
+#quickcheckout #confirm_payment .button-confirm,
+#quickcheckout #confirm_payment .buttons .button,
+#quickcheckout #confirm_payment .buttons .btn {
+ display:none !important;
+}
+/*#quickcheckout .block-title {
+ color: #636E75;
+ margin-top: 0px;
+ margin-bottom: 20px;
+ font-size: 32px;
+ font-weight: normal;
+ margin-left: 10px;
+ text-shadow: 0 0 1px rgba(0, 0, 0, .01);
+}*/
+/*#quickcheckout .box-content > .description {
+ margin-bottom:5px;
+}*/
+/*#quickcheckout #step_6 {
+ margin-top:7px;
+}
+#quickcheckout #step_6 .buttons {
+ margin-bottom: 0px;
+}
+*/
+#quickcheckout .aqc-column {
+ float:left;
+ min-width: 180px;
+}
+#quickcheckout .aqc-column-0 {
+ float:none
+}
+#quickcheckout #step_1 {
+ margin-bottom: 15px;
+}
+
+#quickcheckout .aqc-column > div {
+ padding: 0px 15px;
+ box-sizing: content-box;
+}
+#quickcheckout .aqc-column-0 > div {
+ margin:0px 0px;
+}
+#quickcheckout #step_4 .radio-input, #quickcheckout #step_5 .radio-input {
+ margin-top:6px;
+}
+#quickcheckout #step_4 .title {
+ margin-top:8px;
+}
+#quickcheckout #step_5 .price,
+#quickcheckout #step_4 .price {
+ float:right;
+}
+#quickcheckout .span1 {
+ width:100%
+}
+#quickcheckout .span2 {
+ width:50%;
+ float:left
+}
+#quickcheckout .span3 {
+ width:33%;
+ float:left
+}
+/*labels*/
+/*#quickcheckout .radio-input label,
+#quickcheckout .checkbox-input label {
+ width: 86% !important;
+ box-sizing: border-box;
+ float: none !important;
+ margin: 0px !important
+}
+#quickcheckout .radio-input ul label {
+ width: 78% !important;
+ float: none !important;
+ line-height: 18px;
+}
+
+#quickcheckout #comment_input label {
+ display:block;
+ color: #4D4D4D;
+ width:100% !important;
+ margin-bottom:5px;
+}
+
+#quickcheckout #agree_input {
+ margin-bottom:10px;
+}*/
+#quickcheckout #comment_input #confirm_comment {
+
+ height:100px;
+}
+
+#quickcheckout label img {
+ float:right;
+ height:20px;
+ margin-bottom:4px;
+}
+
+/*
+* --------------------------------------------- $Step 1 login --------------------------------------------
+*/
+#quickcheckout #option_login_popup_trigger_wrap .radio{
+ padding-right: 10px;
+}
+/*#quickcheckout #login_wrap{
+ width: 100%;
+ clear:both;
+ content: " ";
+ display: table;
+}
+#quickcheckout #step_1{
+ clear:both;
+ content: " ";
+ display: table;
+ width: 100%;
+ padding: 0px;
+}*/
+
+/*#quickcheckout #step_1 input[type=text],
+#quickcheckout #step_1 input[type=password] {
+ max-width:200px;
+}*/
+
+#quickcheckout #step_1 .block-row {
+
+ float:left;
+ margin-right:15px;/*max-width: 285px*/
+}
+#quickcheckout #step_1 .columns-2 #option_login .block-row,
+#quickcheckout #step_1 .columns-3 #option_login .block-row{
+ width: 100%;
+}
+#quickcheckout #step_1 #option_register .block-row,
+#quickcheckout #step_1 #option_guest .block-row {
+ width: 100%;
+}
+#quickcheckout #step_1 #option_register .box-content,
+#quickcheckout #step_1 #option_guest .box-content{
+ clear:both;
+ content: " ";
+ display: table;
+}
+#quickcheckout #step_1 .block-row.button-login {
+ margin-top: 5px;
+}
+#quickcheckout #step_1 .text {
+ margin-top:15px;
+}
+/*
+* --------------------------------------------- $Step 6 cart ---------------------------------------------
+*/
+.qc-checkout-product table {
+ width: 100%;
+ border-collapse: collapse;
+ border-top: 1px solid #DDDDDD;
+ border-left: 1px solid #DDDDDD;
+ border-right: 1px solid #DDDDDD;
+ margin-bottom: 20px;
+}
+#quickcheckout #step_6 #cart_wrap .qc-cart{
+ visibility: visible;;
+ display: table;
+ width: 100%
+}
+#quickcheckout #step_6 .qc-checkout-product thead td {
+ text-align: center;
+}
+/*#quickcheckout #step_6 input.qc-product-qantity {
+ width:30px;
+ min-width:30px;
+ text-align:center
+}*/
+/*#quickcheckout #step_6 .qc-total input {
+ height: auto;
+ width: 80%;
+ margin:0px;
+}
+#quickcheckout #step_6 .qc-stock input {
+ border:1px solid #D20000;
+ height: auto;
+ margin:0px;
+}*/
+#quickcheckout #step_6 .qc-quantity .input-group {
+ max-width: 130px;
+ min-width: 120px;
+ margin: 0 auto;
+}
+
+#quickcheckout #step_6 .qc-cart .qc-name-model,
+#quickcheckout #step_6 .qc-cart .qc-name-price{
+ display: none
+}
+/*#quickcheckout #step_6 .qc-checkout-product table {
+ margin-bottom:-1px;
+ width: 100%;
+ border:1px solid #DDDDDD;
+}
+#quickcheckout #step_6 .qc-checkout-product table td {
+ border-bottom:1px solid #DDDDDD;
+ padding:5px;
+ font-size:14px;
+}*/
+#quickcheckout #step_6 .qc-checkout-product table td img {
+ width:40px;
+}
+/*#quickcheckout #step_6 .qc-quantity{
+ text-align: center;
+}
+
+#quickcheckout #step_6 input.qc-product-qantity {
+ padding:5px 0px;
+ text-align:center;
+ height: auto;
+}
+#quickcheckout #step_6 .qc-quantity span {
+ margin-top: -3px;
+}*/
+
+/* cart totals */
+/*#quickcheckout #step_6 .qc-checkout-product .qc-table{
+ border-left: 1px solid #c9c9c9;
+ border-right: 1px solid #c9c9c9;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-row{
+ border-bottom:1px solid #DDDDDD;
+ *zoom: 1;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-row:after{
+ clear:both;
+ content: " ";
+ display: table;
+}
+
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-row .qc-col{
+ display:inline-block;
+ vertical-align:middle
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ width: 50%;
+ padding: 10px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-row .qc-col.qc-text{
+ font-weight: bold;
+ vertical-align: middle;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-row .qc-col.qc-total{
+ white-space: nowrap;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-table .qc-text {
+ width:80%;
+ text-align:right;
+ vertical-align: middle;
+}*/
+#quickcheckout #step_8 .buttons{
+ border: none
+}
+#quickcheckout #cart_wrap .qc-totals .control-label{
+ font-weight: bold;
+}
+#quickcheckout #cart_wrap .qc-totals:last-child ,
+#quickcheckout #cart_wrap .qc-totals:last-child .control-label{
+ font-size: 16px;
+ font-weight: bold;
+}
+/*#quickcheckout #step_6 .qc-options .qc-icon-check{
+ font-size: 22px;
+ cursor: pointer;
+ padding-left: 5px;
+}
+#quickcheckout .box-heading [class^="qc-icon-"]{
+ font-size: 22px;
+ margin-right: 5px;
+}
+#quickcheckout #payment_wrap .box{
+ margin-top: 0px;
+}*/
+/*tooltips*/
+/*
+.qc.qc-tooltip {
+ width: 200px;
+ position: absolute;
+ padding: 10px;
+ background: #333;
+ background: -webkit-gradient( linear, left top, left bottom, from( rgba( 0, 0, 0, .6 ) ), to( rgba( 0, 0, 0, .8 ) ) );
+ background: -webkit-linear-gradient( top, rgba( 0, 0, 0, .6 ), rgba( 0, 0, 0, .8 ) );
+ background: -moz-linear-gradient( top, rgba( 0, 0, 0, .6 ), rgba( 0, 0, 0, .8 ) );
+ background: -ms-radial-gradient( top, rgba( 0, 0, 0, .6 ), rgba( 0, 0, 0, .8 ) );
+ background: -o-linear-gradient( top, rgba( 0, 0, 0, .6 ), rgba( 0, 0, 0, .8 ) );
+ background: linear-gradient( top, rgba( 0, 0, 0, .6 ), rgba( 0, 0, 0, .8 ) );
+ color: #eee;
+ font: normal normal normal 12px/14px Arial, sans-serif;
+ text-align: justify;
+ z-index: 6000;
+ -webkit-box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ -moz-box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ position: absolute;
+}
+.qc.qc-tooltip:after {
+ width: 0;
+ height: 0;
+ border-left: 10px solid transparent;
+ border-right: 10px solid transparent;
+ border-top: 8px solid #333;
+ border-top-color: rgba( 0, 0, 0, .7 );
+ content: '';
+ position: absolute;
+ left: 50%;
+ bottom: -8px;
+ margin-left: -10px;
+ z-index:10000
+}
+.qc.qc-tooltip.top:after {
+ border-top-color: transparent;
+ border-bottom: 10px solid #111;
+ top: -20px;
+ bottom: auto;
+}
+.qc.qc-tooltip.left:after {
+ left: 10px;
+ margin: 0;
+}
+.qc.qc-tooltip.right:after {
+ right: 10px;
+ left: auto;
+ margin: 0;
+}
+.qc.qc-popup {
+
+ position: absolute;
+ padding: 1px 1px 1px 1px;
+ background: #333;
+ background: -webkit-gradient( linear, left top, left bottom, from( rgba( 0, 0, 0, .2 ) ), to( rgba( 0, 0, 0, .4 ) ) );
+ background: -webkit-linear-gradient( top, rgba( 0, 0, 0, .2 ), rgba( 0, 0, 0, .4 ) );
+ background: -moz-linear-gradient( top, rgba( 0, 0, 0, .2 ), rgba( 0, 0, 0, .4 ) );
+ background: -ms-radial-gradient( top, rgba( 0, 0, 0, .2 ), rgba( 0, 0, 0, .4 ) );
+ background: -o-linear-gradient( top, rgba( 0, 0, 0, .2 ), rgba( 0, 0, 0, .4 ) );
+ background: linear-gradient( top, rgba( 0, 0, 0, .2 ), rgba( 0, 0, 0, .4 ) );
+ color: #eee;
+ font: normal normal normal 12px/14px Arial, sans-serif;
+ text-align: justify;
+ z-index: 6000;
+ -webkit-box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ -moz-box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ box-shadow: 0 3px 5px rgba( 0, 0, 0, .3 );
+ position: absolute;
+}
+
+.qc.qc-popup:after {
+ width: 0;
+ height: 0;
+ border-left: 10px solid transparent;
+ border-right: 10px solid transparent;
+ border-top: 8px solid #333;
+ border-top-color: rgba( 145, 148, 150, 1);
+ content: '';
+ position: absolute;
+ left: 50%;
+ bottom: -7px;
+ margin-left: -10px;
+ z-index:10000
+}
+.qc.qc-popup.top:after {
+ border-top-color: transparent;
+ border-bottom: 10px solid #111;
+ top: -20px;
+ bottom: auto;
+}
+.qc.qc-popup.left:after {
+ left: 10px;
+ margin: 0;
+}
+.qc.qc-popup.right:after {
+ right: 10px;
+ left: auto;
+ margin: 0;
+}
+.qc.qc-popup img{
+ margin-top: 0px;
+ padding:0px;
+}
+#cart_wrap .cart .qc-image a.qc-popup{
+ height: 45px;
+ display: inline-block;
+}*/
+/*Debug*/
+/*#quickcheckout_debug {
+ position: absolute;
+ width:100%;
+ top:0px;
+ left:0px;
+ z-index:100000
+}
+#quickcheckout_debug .button-toggle {
+ position:fixed;
+ border-top: 2px solid #1f8dd6;
+ background-color: #ecf0f3;
+ padding:10px;
+ width:100%;
+ text-align:center;
+ box-shadow: 0 6px 5px -6px #999;
+ cursor:pointer;
+ margin-top:-1px;
+ opacity:0.8;
+ font-weight:bold
+}
+#quickcheckout_debug .button-toggle:hover {
+ box-shadow: 0 6px 5px -6px #333;
+ opacity:1
+}
+#quickcheckout_debug .button-toggle:active {
+ margin-top:0px;
+}
+#quickcheckout_debug .debug-content {
+ margin:0px;
+ margin-top:36px;
+ padding:0px;
+ list-style:none;
+ background: rgba(255, 255, 255, 0.95)
+}
+#quickcheckout_debug .debug-content li {
+ width:28%;
+ padding:2%;
+ float:left;
+ min-width:200px;
+}
+#quickcheckout_debug .debug-content li .heading {
+ margin-top:10px;
+ font-size:18px;
+ font-weight:bold
+}
+#quickcheckout_debug .debug-content li:nth-child(even) {
+ background:rgba(0, 0, 0, 0.05)
+}
+#quickcheckout_debug pre {
+ white-space: pre-wrap; /* css-3 */
+ white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
+ white-space: -pre-wrap; /* Opera 4-6 */
+ white-space: -o-pre-wrap; /* Opera 7 */
+ word-wrap: break-word; /* Internet Explorer 5.5+ */
+}*/
+/*theme fixes*/
+#quickcheckout input[type='text'], #quickcheckout input[type='password'], #quickcheckout textarea {
+ min-width: 50px;
+}
+#quickcheckout img {
+ max-width: inherit;
+}
+#quickcheckout #step_1 .box {
+ clear:none
+}
+#quickcheckout #step_1 .box .box-content {
+ width: auto;
+}
+.Checkout .row {
+ margin-left: 0px;
+}
+#quickcheckout .btn:hover {
+ background-position: 0 0px;
+}
+#quickcheckout #step_6 input.product-qantity {
+ margin-right:0px;
+}
+/*#quickcheckout input[type=radio], #quickcheckout input[type=checkbox]{
+ margin:0px !important}*/
+/*#option_login_popup_trigger_wrap{
+ background:rgba(0,0,0,0) !important;
+ padding-right:8px;
+ padding-left: 8px;
+}*/
+#option_login_popup_trigger_wrap .title{
+ padding:6px 10px 0px 0px;
+ vertical-align:text-top;
+ font-size:18px;
+ }
+/*#option_login_popup_trigger{
+ float:right;
+}*/
+/*.box-popup-wrap{
+ display:none;
+ position: fixed;
+ top:0;
+ left:0;
+ background-color:rgba(0,0,0,0.3) !important;
+ height:100%;
+ width:100%;
+ z-index:1000}
+.box-popup{
+ position:relative;
+ background-color:#fff !important;
+ padding:20px;
+ width:300px;
+ left:50%;
+ margin-left:-170px;
+ top:50%;
+ margin-top:-100px;
+ -webkit-box-shadow: 0px 0px 20px 0px rgba(0, 0, 0, 0.3);
+ -moz-box-shadow: 0px 0px 20px 0px rgba(0, 0, 0, 0.3);
+ box-shadow: 0px 0px 20px 0px rgba(0, 0, 0, 0.3);
+}
+.box-popup .box-heading{
+ background: rgba(0,0,0,0);
+ border: none;
+ border-bottom: 1px solid #ececec;
+ color: #000;
+ font-size: 18px !important;
+ text-transform: none;
+ font-weight: normal;
+ line-height: 22px !important;
+ padding: 10px;
+}
+.box-popup .box-content{
+ padding: 10px;
+}
+.box-popup .close{
+ position: absolute;
+ top: 0px;
+ right: 0px;
+ line-height: 17px !important;
+ padding: 1px 7px 3px 7px;
+ background: #479ccf !important;
+ border: 1px solid #fff;
+ font-weight: bold;
+ border-radius: 15px;
+ color: #FFFFFF !important;
+ cursor: pointer;
+ margin: -10px;
+ box-shadow: 1px 1px 4px rgba(0,0,0,0.1);
+}*/
+/*#quickcheckout #option_login_popup_trigger_wrap label{
+ width:inherit !important;
+}
+#option_register_popup{
+ padding:5px;
+ display:inline-block;
+ height: 22px;
+}
+#option_guest_popup{
+ padding:5px;
+ display:inline-block;
+ height: 22px;
+}
+#option_login_popup_trigger{
+ height:auto !important;
+}*/
+/*#quickcheckout .highlight-error input[type=text],
+#quickcheckout .highlight-error input[type=password],
+#quickcheckout .highlight-error select,
+#quickcheckout .highlight-error textarea{
+ border: 1px solid red !important
+}
+*/
+/* Social login */
+#quickcheckout #d_social_login {
+ margin-left: 5px;
+}
+#quickcheckout #d_social_login .qc-dsl-button{
+ font-size: 16px;
+ text-decoration: none;
+ color: #fff;
+ display: inline-block;
+ box-sizing: border-box;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ box-shadow: 0 1px 0 rgba(0,0,0,0.10);
+ margin: 0px 2px;
+ margin-bottom: 10px;
+ padding:0px;
+}
+#quickcheckout #d_social_login .qc-dsl-button:hover{
+ text-decoration: none;
+ box-shadow: inset 0 -2px 0 rgba(0,0,0,0.20);
+}
+#quickcheckout #d_social_login .dsl-button:active{
+ box-shadow: inset 0 2px 0 rgba(0,0,0,0.20);
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-medium .l-side,
+#quickcheckout #d_social_login .qc-dsl-button .l-side{
+ padding: 5px 5px 0px 5px;
+ border-right: 1px solid rgba(255,255,255,0.3);
+ color: #fff;
+ display: inline-block;
+ font-size: 17px;
+ vertical-align: middle;
+ box-sizing: border-box;
+ text-shadow: 0px -1px 0px rgba(0, 0, 0, 0.3);
+ position: relative;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-medium .r-side,
+#quickcheckout #d_social_login .qc-dsl-button .r-side{
+ padding: 6px 10px 6px 10px;
+ color: #fff;
+ display: inline-block;
+ font-size: 12px;
+ vertical-align: middle;
+ box-sizing: border-box;
+ text-shadow: 0px -1px 0px rgba(0, 0, 0, 0.3);
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-huge .l-side {
+ font-size: 26px;
+ padding: 8px 10px 0px 8px;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-huge .r-side {
+ font-size: 15px;
+ padding: 12px 20px 11px 20px;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-large .l-side {
+ font-size: 20px;
+ padding: 6px 6px 0px 6px;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-large .r-side {
+ font-size: 13px;
+ padding: 8px 16px 7px 16px;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-small .l-side {
+ font-size: 14px;
+ padding: 3px 4px 0px 4px;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-small .r-side {
+ font-size: 10px;
+ padding: 3px 5px 2px 5px;
+}
+
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-icons .l-side {
+ font-size: 17px;
+ padding: 5px 5px 0px 5px;
+ border: none;
+}
+#quickcheckout #d_social_login .qc-dsl-button.qc-dsl-button-icons .r-side {
+ display: none;
+}
+#quickcheckout a [class*="dsl-icon-"],
+#quickcheckout [class*="dsl-icon-"],
+#quickcheckout [class*="dsl-icon-"]:before{
+ margin:0px !important;
+ background-image:none !important;
+ color: #fff;
+}
+#quickcheckout .qc-dsl-label {
+ display: none;
+ vertical-align: middle;
+}
+#quickcheckout .qc-dsl-label-icons{
+ display: inline-block;
+}
+#quickcheckout .qc-dsl-hide-icon{
+ opacity: 0 !important
+}
+::-webkit-input-placeholder {
+ opacity: 0;
+}
+
+:-moz-placeholder { /* Firefox 18- */
+ opacity: 0;
+}
+
+::-moz-placeholder { /* Firefox 19+ */
+ opacity: 0;
+}
+
+:-ms-input-placeholder {
+ opacity: 0;
+}
\ No newline at end of file
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.eot b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.eot
new file mode 100755
index 0000000..3934f63
Binary files /dev/null and b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.eot differ
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.svg b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.svg
new file mode 100755
index 0000000..d4a9eea
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.svg
@@ -0,0 +1,27 @@
+
+
+
+Generated by Fontastic.me
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.ttf b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.ttf
new file mode 100755
index 0000000..34203e5
Binary files /dev/null and b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.ttf differ
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.woff b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.woff
new file mode 100755
index 0000000..cdaa2d1
Binary files /dev/null and b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/fonts/d-quickcheckout.woff differ
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/styles.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/styles.css
new file mode 100755
index 0000000..27828e0
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/icon/styles.css
@@ -0,0 +1,78 @@
+@charset "UTF-8";
+
+@font-face {
+ font-family: "d-quickcheckout";
+ src:url("fonts/d-quickcheckout.eot");
+ src:url("fonts/d-quickcheckout.eot?#iefix") format("embedded-opentype"),
+ url("fonts/d-quickcheckout.woff") format("woff"),
+ url("fonts/d-quickcheckout.ttf") format("truetype"),
+ url("fonts/d-quickcheckout.svg#d-quickcheckout") format("svg");
+ font-weight: normal;
+ font-style: normal;
+
+}
+
+[class^="qc-icon-"]:before,
+[class*=" qc-icon-"]:before {
+ font-family: "d-quickcheckout" !important;
+ font-style: normal !important;
+ font-weight: normal !important;
+ font-variant: normal !important;
+ text-transform: none !important;
+ speak: none;
+ line-height: 1;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+}
+
+.qc-icon-payment-method:before {
+ content: "\e004";
+}
+.qc-icon-plus-circle:before {
+ content: "\e006";
+}
+.qc-icon-minus-circle:before {
+ content: "\e007";
+}
+.qc-icon-payment-address:before {
+ content: "\e008";
+}
+.qc-icon-arrow-left:before {
+ content: "\e009";
+}
+.qc-icon-arrow-down:before {
+ content: "\e00b";
+}
+.qc-icon-arrow-up:before {
+ content: "\e00c";
+}
+.qc-icon-profile-add:before {
+ content: "\e00d";
+}
+.qc-icon-key:before {
+ content: "\e00f";
+}
+.qc-icon-arrow-right:before {
+ content: "\e010";
+}
+.qc-icon-cart:before {
+ content: "\e011";
+}
+.qc-icon-check:before {
+ content: "\e012";
+}
+.qc-icon-cross:before {
+ content: "\e013";
+}
+.qc-icon-shipping-address:before {
+ content: "\e014";
+}
+.qc-icon-profile:before {
+ content: "\e016";
+}
+.qc-icon-shipping-method:before {
+ content: "\e017";
+}
+.qc-icon-profile-guest:before {
+ content: "\e000";
+}
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/mobile.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/mobile.css
new file mode 100755
index 0000000..2b602c6
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/mobile.css
@@ -0,0 +1,75 @@
+
+@media only screen and (max-width: 1000px) {
+ #quickcheckout #step_6 .qc-checkout-product table .qc-price{
+ display:none
+ }
+ #quickcheckout #step_6 .qc-total {
+ min-width: 0px;
+ }
+
+}
+
+@media only screen and (min-width: 0px) and (max-width: 1024px) {
+ #container{
+ width: 100%;
+ }
+ body {
+ font-size:0.8em;
+ }
+ #quickcheckout #step_1 #login_wrap .box{
+ float:none;
+ width:98% !important}
+ #quickcheckout #step_1 .box .box-content{
+ height: inherit !important
+ }
+ #option_login_popup_trigger{
+ float: none;
+ display: block;
+ text-align: center;
+ }
+ #option_login_popup_trigger_wrap{
+ height: auto !important;
+ }
+ #quickcheckout #option_login_popup_trigger{
+ width: 100% !important;
+ margin: 0px 0px 0px 2px !important;
+ box-sizing: border-box;
+ }
+ #quickcheckout #d_social_login {
+ clear: both;
+ float: none !important;
+ margin-top: 10px;
+ }
+ .box-popup .close {
+ padding: 12px 14px 14px 14px;
+ border-radius: 30px;
+ margin: -23px;
+ font-size: 30px !important;
+ }
+ #quickcheckout .aqc-column{
+ float:none;
+ width:100% !important}
+ /*Step 6 Confirm*/
+ #quickcheckout #step_6 .qc-checkout-product table .qc-price{
+ display:none
+ }
+ #quickcheckout #step_6 .qc-checkout-product table .qc-total {
+ min-width: 0px;
+ }
+ #quickcheckout #step_6 .qc-checkout-product table .qc-text{
+ width:50% !important
+ }
+ #quickcheckout #step_8 .buttons,
+ #quickcheckout #step_8 .buttons .right,
+ #quickcheckout #step_8 #confirm_order{
+ width:100%;
+ text-align:center;
+ margin:0px;
+ float:none;
+ overflow: hidden;
+ box-sizing: border-box;}
+
+ #quickcheckout #qc_right{
+ width: 100% !important
+ }
+}
\ No newline at end of file
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/apple.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/apple.css
new file mode 100755
index 0000000..84fe267
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/apple.css
@@ -0,0 +1,238 @@
+@charset "utf-8";
+/*Apple Style
+for Ajax Quick Checkout
+v. 1.0
+Dreamvention.com
+*/
+
+/*Main*/
+#quickcheckout *{
+ color:#000;
+ text-decoration:none;}
+#quickcheckout .block-content {
+ background:url(../../../image/quickcheckout/apple.jpg);
+ border-radius: 10px;
+ padding:15px;
+ padding-bottom:20px;
+ -moz-box-shadow: inset 0 0 3px 3px #888;
+ -webkit-box-shadow: inset 0 0 3px 3px #888;
+ box-shadow: inset 0 0 3px 3px #888;
+}
+#quickcheckout a, #quickcheckout a b {
+ text-decoration:none
+}
+#quickcheckout a:hover, #quickcheckout a b:hover {
+ text-decoration:underline
+}
+/*Box*/
+#quickcheckout .box > div {
+ border: none;
+ background:#fff;
+}
+#quickcheckout .qc-checkout-product thead,
+#quickcheckout .box .box-heading {
+ font-size:14px;
+ text-transform:uppercase;
+ font-weight: normal;
+ line-height:22px;
+ -webkit-border-radius:6px 6px 0px 0px;
+ -moz-border-radius:6px 6px 0px 0px;
+ -khtml-border-radius:6px 6px 0px 0px;
+ border-radius:6px 6px 0px 0px;
+ padding-left:10px;
+ margin:0px;
+ color:#FFFFFF;
+ text-shadow: 0px -1px 1px rgba(0, 0, 0, 0.4);
+ background:#8691AB;
+ background-image: linear-gradient(bottom, rgb(118,130,158) 46%, rgb(138,150,173) 58%, rgb(181,187,201) 100%);
+ background-image: -o-linear-gradient(bottom, rgb(118,130,158) 46%, rgb(138,150,173) 58%, rgb(181,187,201) 100%);
+ background-image: -moz-linear-gradient(bottom, rgb(118,130,158) 46%, rgb(138,150,173) 58%, rgb(181,187,201) 100%);
+ background-image: -webkit-linear-gradient(bottom, rgb(118,130,158) 46%, rgb(138,150,173) 58%, rgb(181,187,201) 100%);
+ background-image: -ms-linear-gradient(bottom, rgb(118,130,158) 46%, rgb(138,150,173) 58%, rgb(181,187,201) 100%);
+ background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0.46, rgb(118,130,158)), color-stop(0.58, rgb(138,150,173)), color-stop(1, rgb(181,187,201)) );
+ font-weight:bold;
+ border:1px solid #8691AB;
+ border-bottom:1px solid #585858;
+ -moz-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+ -webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+ box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+}
+#quickcheckout .box .box-heading span{
+ color:#FFFFFF;
+}
+#quickcheckout .box .box-heading .text{
+ vertical-align: text-bottom;
+}
+#quickcheckout .box .box-content {
+ border: 1px solid #A9A9A9;
+ background:#fff;
+ -webkit-border-radius: 0px 0px 6px 6px;
+ -moz-border-radius: 0px 0px 6px 6px;
+ -khtml-border-radius: 0px 0px 6px 6px;
+ border-radius: 0px 0px 6px 6px;
+ -moz-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+ -webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+ box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1);
+}
+#quickcheckout .box .box-content .description {
+ padding-bottom:10px;
+}
+#quickcheckout .box .sort-item {
+ margin-bottom:4px;
+}
+/*Inputs*/
+#quickcheckout input[type=text], #quickcheckout input[type=password], #quickcheckout select, #quickcheckout textarea {
+ background: #fefefe;
+ transition: border linear 0.2s, box-shadow linear 0.2s;
+ border-radius: 5px;
+ border: 1px solid #d6d6d6;
+ -webkit-box-shadow: inset 0 2px 6px #BBB;
+ -moz-box-shadow: inset 0 2px 6px #BBB;
+ box-shadow: inset 0 2px 6px #BBB;
+ box-sizing: border-box;
+ font-size: 14px;
+ line-height: 20px;
+ padding: 7px 7px 7px 10px;
+ color: rgb(85, 85, 85);
+}
+#quickcheckout select{
+ height: 36px !important;
+}
+#quickcheckout .highlight-error input[type=text],
+#quickcheckout .highlight-error input[type=password],
+#quickcheckout .highlight-error select,
+#quickcheckout .highlight-error textarea{
+ border: solid 1px #bc101c !important
+}
+#quickcheckout .radio-input {
+ margin-bottom:5px;
+}
+#quickcheckout ul {
+ list-style:none;
+ margin:0px;
+ padding:0px;
+ margin-left: 45%;
+}
+#quickcheckout label {
+ opacity: 1;
+ font-weight: bold;
+ color:#000
+}
+/*Steps*/
+/*Step_1*/
+#quickcheckout #step_1 .block-row {
+ width: 100%;
+ float: left;
+ margin-right: 15px;
+ max-width: 270px;
+}
+#quickcheckout #step_1 .block-row.button-login {
+ margin-top: 3px;
+}
+#option_login_popup {
+ border-radius: 10px
+}
+#quickcheckout #d_social_login .dsl-button.dsl-button-small .l-side {
+font-size: 18px;
+padding: 4px 10px 0px 10px;
+}
+#quickcheckout #d_social_login .dsl-button.dsl-button-small .r-side {
+font-size: 14px;
+padding: 10px 12px 10px 12px;
+}
+#quickcheckout #d_social_login .dsl-button {
+ margin-bottom: 0px;
+}
+#option_login_popup_trigger_wrap {
+ height: 36px;
+ padding-right: 0px;
+}
+/*Step_4*/
+#quickcheckout #step_4 .title {
+ font-weight:bold;
+}
+#quickcheckout #step_4 .radio-input {
+ padding-top:5px;
+}
+#quickcheckout #step_4 label .price {
+ float:right
+}
+/*Step_6*/
+#quickcheckout #step_6 .box .box-heading {
+ border:none
+}
+#quickcheckout #step_6 input.qc-product-qantity {
+ padding:5px 0px;
+ text-align:center
+}
+#quickcheckout #cart_wrap .box .qc-icon-confirm{
+ display: none
+}
+/*Icons*/
+#quickcheckout i[class*=icon-] {
+ display:none
+}
+#quickcheckout i.qc-icon-small-plus,
+#quickcheckout i.qc-icon-small-minus,
+#quickcheckout i.qc-icon-confirm,
+#quickcheckout i.icon-help {
+ display:inline-block
+}
+/*table*/
+#quickcheckout .qc-checkout-product table {
+ background:#fff
+}
+#quickcheckout .qc-checkout-product thead td {
+ background:none;
+ color:#fff
+}
+/*Buttons*/
+#quickcheckout .button {
+ background-image:none;
+ background: #117ed2;
+ background-color:#117ed2;
+ background: -webkit-linear-gradient(#37aaea, #117ed2);
+ background: -moz-linear-gradient(#37aaea, #117ed2);
+ background: linear-gradient(#37aaea, #117ed2);
+ background: -ms-linear-gradient(top, #37aaea, #117ed2);
+ -webkit-border-radius: 4px;
+ -moz-border-radius: 4px;
+ border-radius: 4px;
+ border: 1px solid #1992d9;
+ -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
+ -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
+ box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
+ padding:10px 15px;
+ text-shadow:none;
+ height:34px;
+ line-height: 14px;
+ color:#fff
+}
+#quickcheckout .buttons {
+ border:none
+}
+/*Alerts*/
+#quickcheckout .error, #quickcheckout .warning {
+ background:rgb(237,125,136) ;
+ background-image: linear-gradient(bottom, rgb(240,19,23) 33%, rgb(213,11,24) 53%, rgb(237,125,136) 94%);
+ background-image: -o-linear-gradient(bottom, rgb(240,19,23) 33%, rgb(213,11,24) 53%, rgb(237,125,136) 94%);
+ background-image: -moz-linear-gradient(bottom, rgb(240,19,23) 33%, rgb(213,11,24) 53%, rgb(237,125,136) 94%);
+ background-image: -webkit-linear-gradient(bottom, rgb(240,19,23) 33%, rgb(213,11,24) 53%, rgb(237,125,136) 94%);
+ background-image: -ms-linear-gradient(bottom, rgb(240,19,23) 33%, rgb(213,11,24) 53%, rgb(237,125,136) 94%);
+ background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0.33, rgb(240,19,23)), color-stop(0.53, rgb(213,11,24)), color-stop(0.94, rgb(237,125,136)) );
+ text-shadow: 0px -2px 1px rgba(0, 0, 0, 0.2);
+ border: solid 1px #bc101c;
+ padding: 5px;
+ border-radius: 3px;
+ display: block;
+ text-align: center;
+ color: rgb(255, 255, 255);
+ margin: 9px 0px 9px 0px
+}
+#quickcheckout .error a, #quickcheckout .warning a {
+ color:#efefef;
+ font-weight:bold
+}
+#quickcheckout .success{
+ background:#E0F2C0;
+ border:1px solid #5C783B}
\ No newline at end of file
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/classic.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/classic.css
new file mode 100755
index 0000000..14cd65e
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/classic.css
@@ -0,0 +1,188 @@
+@charset "utf-8";
+/*Classic*/
+/*Main*/
+#quickcheckout *{
+ font-family: 'PT Sans', sans-serif;
+ font-size:14px;
+ line-height:20px;
+ color:#000;
+ text-decoration:none;
+}
+
+#quickcheckout .block-title{
+font-size: 30px;
+color: #333333;
+margin-top: 20px;
+margin-bottom: 10px;
+line-height: 34px;
+margin-left: 18px;
+}
+#quickcheckout input[type=text],
+#quickcheckout input[type=password],
+#quickcheckout select,
+#quickcheckout textarea
+{
+ background: radial-gradient(ellipse at center, rgba(246,246,246,1) 0%,rgba(255,255,255,1) 5%);
+ box-shadow: inset 1px 1px 4px rgba(0,0,0,0.1);
+ background: #f2f7fa;
+ border: 1px solid #cecece;
+ border-radius: 0px;
+ border-bottom: 1px solid #ececec;
+ box-sizing: border-box;
+ font-size: 14px;
+ line-height: 20px;
+ padding: 5px;
+ color: #333333;
+}
+
+#quickcheckout .highlight-error input[type=text],
+#quickcheckout .highlight-error input[type=password],
+#quickcheckout .highlight-error select,
+#quickcheckout .highlight-error textarea{
+ border: 1px solid #C09086 !important;
+-webkit-box-shadow: 0px 0px 6px 0px rgba(255, 0, 0, 0.2);
+-moz-box-shadow: 0px 0px 6px 0px rgba(255, 0, 0, 0.2);
+box-shadow: 0px 0px 6px 0px rgba(255, 0, 0, 0.2);
+
+}
+
+#quickcheckout div{
+ font-size:14px
+ }
+#quickcheckout .radio-input {
+ margin-bottom:5px;}
+#quickcheckout ul{
+ list-style:none;
+ margin:0px;
+ padding:0px;
+ margin-left: 45%;}
+#quickcheckout .box {
+ border:none !important;
+ box-shadow: none !important;
+}
+#quickcheckout .box .box-heading {
+ background-image:none;
+ background: rgba(0,0,0,0);
+ border:none;
+ border-bottom: 1px solid #ececec;
+ color: #000;
+ font-size: 18px;
+ text-transform:none;
+ font-weight: normal;
+ line-height:22px;
+ -webkit-border-radius:0px;
+ -moz-border-radius:0px;
+ -khtml-border-radius:0px;
+ border-radius: 0px;
+ padding: 10px;
+ margin:0px;
+}
+#quickcheckout .box .box-heading span{
+ vertical-align:middle;
+ font-size:18px;
+}
+
+#quickcheckout .box .box-content{
+ background: rgba(0,0,0,0);
+ border:none;
+ -webkit-border-radius:0px;
+ -moz-border-radius:0px;
+ -khtml-border-radius:0px;
+ border-radius: 0px;
+}
+#quickcheckout #step_1 ,
+#quickcheckout #step_1 .box .box-content,
+#quickcheckout #step_1 .box .box-heading
+{
+ background: #f2f7fa;
+}
+#quickcheckout #step_1 #login_wrap {
+ border-bottom: 1px solid #E1E1E1;
+ border-top: 1px solid #E1E1E1;
+ display: table;
+}
+#quickcheckout #d_social_login .dsl-button .r-side {
+ padding: 2px 10px 2px 10px;
+}
+#quickcheckout #step_1 input[type=text],
+#quickcheckout #step_1 input[type=password]{
+ background:#fff}
+#quickcheckout .qc-checkout-product .table{
+ background:#fff}
+#quickcheckout .qc-checkout-product thead td{
+ background: #F2F7FA;
+ border:1px solid #E1E1E1;
+ font-weight: 400;
+ font-size: 14px;
+ color: #333333;
+}
+
+#quickcheckout label{
+ font-weight: 400;
+ font-size: 14px;
+ color: #333333;
+}
+
+#quickcheckout .error{
+background: linear-gradient(to bottom, rgba(239,37,58,1) 0%,rgba(232,20,35,1) 100%);
+border: solid 1px #bc101c;
+padding: 5px;
+border-radius: 3px;
+display: block;
+text-align: center;
+color: rgb(255, 255, 255);
+}
+#quickcheckout label .price{
+ float:right;
+}
+#quickcheckout div.radio {
+ margin-top: 0px;
+}
+#quickcheckout #step_4 .title{
+ font-weight:bold;
+}
+#quickcheckout #step_6 .box .box-heading{
+ min-height:0px;
+}
+#quickcheckout .error,
+#quickcheckout .warning{
+ background:#F5E8E6;
+ border:1px solid #C09086;
+ padding:4px;
+ border-radius: 0px;
+ color:#333;
+ font-size:12px;
+ margin:5px 5px;
+}
+#quickcheckout .success {
+ background: #F5F9E4;
+ border: 1px solid #BEC986;
+ padding:4px;
+ border-radius: 0px;
+ color:#333;
+ font-size:12px;
+ margin:5px 5px;
+}
+#quickcheckout #step_8 .buttons{
+ background: #f2f7fa;
+ border: none;
+}
+#quickcheckout .button{
+ background: #479ccf;
+ border:none;
+ font-size:14px;
+ border-radius: 0px;
+ color: #FFFFFF;
+ display: inline-block;
+ text-decoration: none;
+ vertical-align: top;
+ line-height: 25px !important;
+ height: 25px;
+ font-weight:normal;
+ text-shadow:none;
+ padding: 0px 12px 0px 12px;
+ cursor:pointer
+}
+#option_login_popup_trigger_wrap{
+ padding: 10px 4px 2px 0px;
+}
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/dark.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/dark.css
new file mode 100755
index 0000000..ac7b746
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/dark.css
@@ -0,0 +1,116 @@
+@charset "utf-8";
+/*Dark Style*/
+
+#quickcheckout #d_social_login .dsl-button{
+ margin-bottom: 0px;
+}
+#quickcheckout #option_login_popup_trigger {
+ width: 50px;
+ text-align: center;
+}
+#quickcheckout input[type=text],
+#quickcheckout input[type=password],
+#quickcheckout select,
+#quickcheckout textarea
+{
+ background: #fff;
+ transition: border linear 0.2s, box-shadow linear 0.2s;
+ border-radius: 3px;
+ border: 1px solid #e5e5e5;
+ box-sizing: border-box;
+ font-size: 14px;
+ line-height: 20px;
+ padding: 8px 6px;
+ color: rgb(85, 85, 85);
+}
+
+#quickcheckout .highlight-error input[type=text],
+#quickcheckout .highlight-error input[type=password],
+#quickcheckout .highlight-error select,
+#quickcheckout .highlight-error textarea{
+ border: solid 1px #bc101c !important
+}
+#quickcheckout .radio-input {
+ margin-bottom:5px;}
+#quickcheckout ul{
+ list-style:none;
+ margin:0px;
+ padding:0px;
+ margin-left: 45%;}
+#quickcheckout .box .box-heading{
+ background: linear-gradient(to bottom, rgba(48,50,52,0.8) 0%,rgba(30,31,33,1) 100%);
+ color: #efefef;
+ font-weight:bold;
+ font-size:14px;
+ text-transform:uppercase;
+ line-height:22px;
+ -webkit-border-radius:0px;
+ -moz-border-radius:0px;
+ -khtml-border-radius:0px;
+ border-radius: 0px;
+ padding-left:10px;
+ margin:0px;
+}
+
+#quickcheckout .box .box-content{
+ background: linear-gradient(to right, rgba(246,246,246,1) 1%,rgba(251,251,251,1) 5%);
+ border:1px solid #f1f1f2;
+ -webkit-border-radius:0px;
+ -moz-border-radius:0px;
+ -khtml-border-radius:0px;
+ border-radius: 0px;
+}
+#quickcheckout .box .box-content .description {
+ padding-bottom:10px;}
+#quickcheckout #cart_wrap .box .qc-icon-confirm{
+ display: none
+}
+#quickcheckout #cart_wrap .box .qc-checkout-product .qc-icon-confirm{
+ display: inline-block
+}
+#quickcheckout .qc-checkout-product {
+ background:#fff}
+#quickcheckout .qc-checkout-product thead td{
+ background: linear-gradient(to bottom, rgba(191,191,191,1) 1%,rgba(224,224,224,1) 100%);
+ border:1px solid #c3c3c3;
+ color: #252525;
+}
+#quickcheckout #step_4 .title{
+ font-weight:bold;
+ }
+#quickcheckout #step_4 .radio-input{
+ padding-top:5px;}
+#quickcheckout #step_6 .box .box-heading{
+ border:none}
+#quickcheckout label{
+ opacity: 0.7;
+}
+
+#quickcheckout .error,
+#quickcheckout .warning{
+ background:rgba(232,20,35,1) ;
+background: linear-gradient(to bottom, rgba(239,37,58,1) 0%,rgba(232,20,35,1) 100%);
+border: solid 1px #bc101c;
+padding: 5px;
+border-radius: 3px;
+display: block;
+text-align: center;
+color: rgb(255, 255, 255);
+margin: 9px 0px 9px 0px
+}
+#quickcheckout label .price{
+ float:right}
+#quickcheckout .box-heading [class*=icon-]{
+ display:none}
+
+#quickcheckout .qc-icon-small-plus,
+#quickcheckout .qc-icon-small-minus,
+#quickcheckout .qc-icon-confirm,
+#quickcheckout .icon-help{ display:inline-block}
+#quickcheckout .success{
+ background:#E0F2C0;
+ background: linear-gradient(to bottom, rgba(224,242,192,1) 0%,rgba(183,205,185,1) 100%);
+ border:1px solid #5C783B}
+#quickcheckout #step_6 .qc-checkout-product table td {
+ padding: 10px 5px;
+}
\ No newline at end of file
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/default.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/default.css
new file mode 100755
index 0000000..5e5f3b9
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/default.css
@@ -0,0 +1,32 @@
+@charset "utf-8";
+/*Default style*/
+/*#quickcheckout.default i.icon-profile,
+#quickcheckout.default i.icon-payment-address,
+#quickcheckout.default i.icon-shipping-address,
+#quickcheckout.default i.icon-shipping-method,
+#quickcheckout.default i.icon-payment-method{
+ display:none}
+#quickcheckout .box .box-heading{
+ background: linear-gradient(to bottom, rgba(248,248,248,1) 0%,rgba(242,242,242,1) 100%);
+ background: #fff;
+ color: #333333;
+ font-size:14px;
+ text-transform:uppercase;
+ font-weight: normal;
+ line-height: 30px;
+
+}*/
+/*.radio-input ul{
+ list-style:none;
+ padding-left:45%}*/
+/*.box .box-content {
+ border-top: 1px solid #efefef;
+}
+*/
+#quickcheckout .block-title {
+ font-size: 27px;
+ margin-top: 20px;
+ margin-bottom: 10px;
+ font-weight: 500;
+ line-height: 1.1;
+}
diff --git a/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/ios.css b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/ios.css
new file mode 100755
index 0000000..51ebce8
--- /dev/null
+++ b/catalog/view/theme/default/stylesheet/d_quickcheckout/theme/ios.css
@@ -0,0 +1,633 @@
+/**
+ * Ajax Quick Checkout theme: iOS
+ *
+ * author: Dreamvention
+ * support: http://dreamvention.com/support
+ *
+ * contents:
+ * 1. remove default styles
+ * 2. inputs
+ * 3. steps
+ */
+
+/**
+ * remove default styles
+ */
+
+#quickcheckout .buttons{
+ background: none;
+}
+
+#quickcheckout .box,
+#quickcheckout .box .box-heading,
+#quickcheckout .box .box-content{
+ margin:0px;
+ padding: 0px;
+ border-radius: 0px;
+ border: none;
+ background: none;
+ font-weight: normal;
+}
+#quickcheckout .box .box-heading i,
+#quickcheckout .box .box-heading span{
+ vertical-align: middle;
+}
+#quickcheckout .aqc-column > div{
+ padding: 0px
+}
+#quickcheckout a{
+ text-decoration: none;
+}
+/**
+ * main
+ */
+
+#quickcheckout .block-content{
+ background: #F8F8F8;
+ padding: 0px;
+ border-top: 1px solid #c9c9c9
+}
+#quickcheckout .box{
+ /*border-bottom: 1px solid #c9c9c9;*/
+ padding: 20px 0px 30px 0px;
+}
+
+#quickcheckout .box .box-content{
+ padding: 5px 20px;
+}
+
+#quickcheckout .box .box-heading{
+ padding: 5px 20px;
+ text-transform: uppercase;
+}
+#quickcheckout .box .box-heading .wrap{
+ padding: 14px;;
+ border-radius: 15px;
+ background: #fff;
+ display: inline-block;
+ margin-right: 10px;
+ width: 50px;
+ height: 50px;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+}
+
+#quickcheckout .box .box-content .description{
+ margin: -25px 0px 16px 64px;
+ font-size: 11px;
+ color:#777777;
+}
+#quickcheckout #step_1 .box-content .text{
+ font-size: 11px;
+ line-height: 1.5;
+ color:#777777;
+}
+
+/**
+ * inputs
+ */
+#quickcheckout select,
+#quickcheckout input[type=text],
+#quickcheckout input[type=password],
+#quickcheckout textarea
+{
+ height: 39px;
+ border: 1px solid #dbdbdb;
+ padding: 10px;
+ font-size: 14px;
+ background: #fff;
+ border-radius: 15px;
+ -webkit-appearance: none;
+ outline: none;
+ color: #313131;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ box-shadow: none
+}
+#quickcheckout input[type=button],
+#quickcheckout .button{
+ height: 39px;
+ border: 0px;
+ padding: 10px 20px;
+ font-size: 14px;
+ background: #875eaa;
+ color: #fff !important;
+ border-radius: 15px;
+ -webkit-appearance: none;
+ outline: none;
+ color: #313131;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ box-shadow: none
+}
+#quickcheckout input[type=button],
+#quickcheckout .button > #quickcheckout label a b,
+#quickcheckout label a{
+ text-decoration: none;
+}
+#quickcheckout label{
+ vertical-align: middle;
+}
+#quickcheckout .checkbox-input label {
+ font-size: 12px;
+ color: #777;
+ padding: 2px;
+}
+#quickcheckout .error{
+ padding: 13px;
+ font-size: 12px;
+ margin: 2px;
+ background-color: #f2dede;
+ color: #b94a48;
+ border-radius: 15px;
+ line-height: 1.4
+}
+#quickcheckout .highlight-error input[type=text],
+#quickcheckout .highlight-error input[type=password],
+#quickcheckout .highlight-error select,
+#quickcheckout .highlight-error textarea{
+ border: 1px solid #F1BABA !important;
+
+}
+/* radio-input */
+#quickcheckout .radio-input ul{
+ margin:2px 0px;
+ padding: 0px;
+}
+#quickcheckout .radio-input label,
+#quickcheckout .radio-input{
+ margin:0px !important;
+}
+#quickcheckout .radio-input .radio{
+ display: none
+}
+#quickcheckout .radio-input ul label,
+#quickcheckout .radio-input label{
+ padding: 10px;
+ border: 1px solid #dbdbdb;
+ border-bottom: none;
+ background: #fff;
+ font-size: 14px;
+ width: 100% !important;
+}
+#quickcheckout .radio-input ul li:first-child label,
+#quickcheckout .radio-input:first-child label{
+ border-top-right-radius: 15px;
+ border-top-left-radius: 15px;
+}
+#uniform-payment_address_exists_0 label,
+#quickcheckout .radio-input ul li:last-child label,
+#quickcheckout .radio-input:last-child label{
+ border-bottom-right-radius: 15px;
+ border-bottom-left-radius: 15px;
+ border-bottom: 1px solid #dbdbdb;
+}
+#quickcheckout .radio-input ul li.checked label,
+#quickcheckout .radio-input.checked label{
+ color: #875eaa;
+}
+#quickcheckout .radio-input ul li.checked label:before,
+#quickcheckout .radio-input.checked label:before {
+font-family: "d-quickcheckout" !important;
+ content: attr(data-icon);
+ font-style: normal !important;
+ font-weight: normal !important;
+ font-variant: normal !important;
+ text-transform: none !important;
+ speak: none;
+ line-height: 1;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+ content: "\e012";
+ position: relative;
+ float: right;
+ margin-left: 5px;
+}
+::-webkit-input-placeholder {
+ opacity: 1;
+}
+
+:-moz-placeholder { /* Firefox 18- */
+ opacity: 1;
+}
+
+::-moz-placeholder { /* Firefox 19+ */
+ opacity: 1;
+}
+
+:-ms-input-placeholder {
+ opacity: 1;
+}
+#quickcheckout select{
+ margin-bottom: 2px !important;
+ line-height: 1.2;
+}
+#quickcheckout .select-input:after {
+ font-family: "d-quickcheckout" !important;
+ content: attr(data-icon);
+ font-style: normal !important;
+ font-weight: normal !important;
+ font-variant: normal !important;
+ text-transform: none !important;
+ speak: none;
+ line-height: 1;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+ content: "\e010";
+ position: relative;
+ float: right;
+ margin: -27px 10px;
+ background: #fff;
+ box-shadow: -10px 0px 15px 5px #fff;
+}
+
+#quickcheckout .radio-input label.title{
+ text-transform: uppercase;
+ margin: 15px 0px 10px 5px !important;
+ color: #777;
+ display: block;
+ background: none;
+ border:none;
+ padding: 0px;
+ font-size: 12px;
+}
+#quickcheckout input[type=radio]{
+ display: none
+}
+#quickcheckout #option_guest input[type=radio],
+#quickcheckout #option_register input[type=radio]{
+ display: block
+}
+#quickcheckout .checkbox-input{
+ padding: 3px 0px 3px 0px
+}
+
+/* text-input */
+#quickcheckout .password-input label,
+#quickcheckout .textarea-input label,
+#quickcheckout .text-input label {
+ display: none !important
+}
+/* select-input */
+#quickcheckout .select-input label{
+ text-transform: uppercase;
+ margin: 15px 0px 10px 5px !important;
+ color: #777;
+ display: block;
+}
+#quickcheckout .select-input label .required{
+ color: #777
+}
+ /**
+ * Buttons
+ */
+#quickcheckout .button {
+ background: #875eaa;
+ color: #fff;
+ font-weight: normal;
+ border: none;
+ padding: 7px 22px 7px 22px;
+ box-shadow: none;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ line-height: 1;
+ text-shadow: none;
+ border-radius: 15px;
+}
+
+ /**
+ * steps: 1 - login
+ */
+#quickcheckout #option_login_popup_trigger_wrap,
+#quickcheckout #login_wrap{
+ border-bottom: 1px solid #c9c9c9;}
+
+#quickcheckout #option_login_popup .block-row{
+ width: 100%
+}
+#quickcheckout #option_login label{
+ display: none !important
+}
+#quickcheckout #option_login input[type=password],
+#quickcheckout #option_login input[type=text]{
+
+}
+#quickcheckout #option_login_popup_trigger_wrap{
+ clear: both;
+ content: " ";
+ display: table;
+ width: 100%;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ padding: 10px 20px 10px 20px;
+}
+
+#quickcheckout #option_login_popup_trigger_wrap > span {
+ height: 39px;
+ border: 1px solid #dbdbdb;
+ padding: 0px 10px;
+ font-size: 14px;
+ background: #fff;
+ -webkit-appearance: none;
+ outline: none;
+ color: #313131;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ float: left;
+ display: block;
+}
+#quickcheckout #option_login_popup_trigger_wrap > span label{
+ width: 100% !important;
+ height: 37px;
+ padding: 10px 0px;
+ display: inline-block;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+}
+#quickcheckout #option_login_popup_trigger_wrap > span.checked,
+#quickcheckout #option_login_popup_trigger_wrap > span.checked label{
+ color: #fff;
+ background: #875eaa
+}
+#quickcheckout #option_login_popup_trigger_wrap #option_register_popup{
+ border-top-left-radius: 15px;
+ border-bottom-left-radius: 15px;
+}
+#quickcheckout #option_login_popup_trigger_wrap #option_guest_popup{
+ border-top-right-radius: 15px;
+ border-bottom-right-radius: 15px;
+ border-left: 0px;
+}
+
+#quickcheckout #option_login_popup_trigger{
+ height: 39px !important;
+ padding: 12px 20px;
+ font-size: 14px;
+ margin-bottom: 0px !important;
+}
+#quickcheckout #d_social_login{
+ margin-top: 8px;
+}
+#quickcheckout .box-popup .close{
+ background: #875eaa !important;
+ border: 0px;
+}
+#quickcheckout #step_1 input[type=text],
+#quickcheckout #step_1 input[type=password]{
+ width: 100%;
+ max-width: 100%;
+}
+#option_login_popup label{
+ display: none !important;
+}
+#quickcheckout #step_1 .block-row.button-login{
+ margin-top: 3px;
+}
+ /**
+ * steps: 2 - payment address
+ */
+
+ /**
+ * steps: 3 - shipping address
+ */
+
+ /**
+ * steps: 4 - shipping method
+ */
+
+ /**
+ * steps: 5 - payment method
+ */
+
+ /**
+ * steps: 6 - cart
+ */
+#quickcheckout #step_6 .box{
+ border-bottom: none
+}
+#quickcheckout .qc-checkout-product table,
+#quickcheckout .qc-checkout-product table thead,
+#quickcheckout .qc-checkout-product table tbody,
+#quickcheckout .qc-checkout-product table tr,
+#quickcheckout .qc-checkout-product table tr td{
+ border: none !important
+}
+#quickcheckout #step_6 .qc-checkout-product table td{
+ padding: 10px;
+}
+#quickcheckout #step_6 .qc-checkout-product thead td{
+ text-align: left;
+ font-size: 13px;
+ color: #4c4c4c;
+ padding: 15px 10px;
+ border-bottom: 1px solid #c9c9c9 !important
+}
+#quickcheckout #step_6 .qc-checkout-product tbody td{
+ border-bottom: 1px solid #c9c9c9 !important
+}
+
+#quickcheckout .qc-checkout-product .qc-cart{
+ margin: 0px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-image {
+ width: 50px;
+ padding-left: 20px ;
+}
+#quickcheckout .qc-checkout-product .qc-image a{
+
+ border-radius: 15px;
+ display: block;
+ background: #fff;
+ text-align: center;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ margin: 0px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-image a img{
+ width: 50px;
+ height: 50px;
+ border-radius: 15px;
+}
+#quickcheckout .qc-checkout-product .qc-name{
+ vertical-align: top;
+}
+
+#quickcheckout .qc-checkout-product .qc-name a{
+ text-decoration: none;;
+ color: #323232;
+ font-size: 14px;
+}
+#quickcheckout #step_6 input.qc-product-qantity{
+ padding: 5px 0px;
+ text-align: center;
+ width: 40px;
+ height: 40px;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ border-radius: 15px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-price,
+#quickcheckout #step_6 .qc-checkout-product .qc-model{
+ display: none
+}
+
+#quickcheckout #step_6 .qc-checkout-product .qc-name-model{
+ margin-top: 5px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-name-price{
+ margin-top: 3px;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-name-price .title,
+#quickcheckout #step_6 .qc-checkout-product .qc-name-model .title{
+ color: #777777;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-name-model .text{
+ color: #3f3f3f
+}
+#quickcheckout #step_6 .qc-quantity{
+ min-width: 60px;
+ width: 60px;
+}
+#quickcheckout #step_6 .qc-quantity span{
+ display: none
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-options .qc-row .qc-text{
+ display: none
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-options .qc-row
+{
+ text-align: center;
+ border: none;
+
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-options {
+ padding-top: 10px;
+ border-left: none;
+ border-right: none;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-options .qc-row .qc-col.qc-total{
+ width: 100%;
+ padding: 5px 22px 0px 16px;
+}
+#quickcheckout #step_6 .qc-total input{
+ width: 100%;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+}
+#quickcheckout #step_6 .qc-options .qc-icon-check{
+ margin-left: -40px;
+ position: absolute;
+ font-size: 18px;
+ margin-top: 12px;
+
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-summary{
+ text-align: center;
+ padding-top: 10px;
+ border-left: none;
+ border-right: none;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-summary .qc-totals{
+ width: 70%;
+ display: inline-block;
+ color: #333
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-summary .qc-totals .qc-col.qc-text{
+ width: 60%;
+ text-align: left;
+ font-weight: normal;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-summary .qc-totals .qc-col.qc-total{
+ width: 40%;
+ text-align: right;
+}
+
+#quickcheckout #step_6 .qc-checkout-product .qc-summary .qc-totals:last-child{
+ font-size: 20px;
+ font-weight: bold;
+ text-transform: uppercase;
+}
+#quickcheckout #step_6 .qc-checkout-product .qc-summary .qc-totals:last-child .qc-col.qc-total{
+ color: #875eaa;
+}
+
+#quickcheckout #step_6 .error{
+ margin: 10px 20px;
+}
+
+ /**
+ * steps: 7 - payment
+ */
+#quickcheckout #step_7 .box{
+ border-bottom: none;
+ padding: 0px
+}
+ /**
+ * steps: 8 - confirm
+ */
+ #quickcheckout #step_8 .box{
+ border-bottom: none;
+ padding-top: 0px;
+}
+ #quickcheckout .buttons .right {
+ float: none;
+ text-align: center;
+}
+#quickcheckout #step_8 .button {
+ width: 60%;
+ background: #875eaa;
+ color: #fff
+}
+@media only screen and (min-width: 0px) and (max-width: 1024px) {
+ #quickcheckout #login_wrap > .box{
+ margin-left: 0px !important;
+ margin-right: 0px !important;
+ width: 100% !important;
+ }
+ #quickcheckout #login_wrap > div:last-child{
+ border-bottom:none;
+ }
+ #quickcheckout .box{
+ border-bottom: 1px solid #c9c9c9;
+ }
+
+ #option_login_popup_trigger{
+ clear: both;
+ margin-top: 10px;
+ }
+ #quickcheckout #option_register_popup,
+ #quickcheckout #option_guest_popup{
+ width: 40%;
+ margin-bottom: 15px;
+ text-align: center;
+ }
+ #quickcheckout #option_register_popup{
+ margin-left: 10%;
+ }
+ #quickcheckout .box-popup .close{
+ padding: 8px 12px 14px 12px;
+ }
+ #quickcheckout #option_login_popup_trigger{
+ width: 80% !important;
+ margin:0 auto !important;
+ margin-bottom: 12px !important
+ }
+ #quickcheckout #option_login_popup_trigger_wrap{
+ padding-top: 20px;
+ }
+ #quickcheckout #step_8 .button{
+ width: 80% !important;
+ }
+
+
+}
diff --git a/catalog/view/theme/default/template/checkout/d_quickcheckout.tpl b/catalog/view/theme/default/template/checkout/d_quickcheckout.tpl
new file mode 100755
index 0000000..bd485f7
--- /dev/null
+++ b/catalog/view/theme/default/template/checkout/d_quickcheckout.tpl
@@ -0,0 +1,29 @@
+
+
+
+
+
+ ×
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/catalog/view/theme/default/template/d_quickcheckout/cart.tpl b/catalog/view/theme/default/template/d_quickcheckout/cart.tpl
new file mode 100755
index 0000000..f47df45
--- /dev/null
+++ b/catalog/view/theme/default/template/d_quickcheckout/cart.tpl
@@ -0,0 +1,151 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ">:
+ ">:
+ ">:
+ ">:
+ ">:
+ ">:
+
+
+
+
+
+ >
+
+ " />' data-trigger="hover">
+
+
+
+
+
+ \'' : '' ?>>
+
+ ***' : '' ?>
+
+
+ - :
+
+ :
+ :
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/catalog/view/theme/default/template/d_quickcheckout/confirm.tpl b/catalog/view/theme/default/template/d_quickcheckout/confirm.tpl
new file mode 100755
index 0000000..846a780
--- /dev/null
+++ b/catalog/view/theme/default/template/d_quickcheckout/confirm.tpl
@@ -0,0 +1,41 @@
+
+
+
+
diff --git a/catalog/view/theme/default/template/d_quickcheckout/debug.tpl b/catalog/view/theme/default/template/d_quickcheckout/debug.tpl
new file mode 100755
index 0000000..3436bb6
--- /dev/null
+++ b/catalog/view/theme/default/template/d_quickcheckout/debug.tpl
@@ -0,0 +1,33 @@
+
+
+
Show Hide Debug information
+
+
+ General
+
+
+
+ Step settings
+
+
+
+ Session
+
+
+
+
+ Option Register
+
+
+
+ Option Guest
+
+
+
+ Option Logged
+
+
+
+
+
+
\ No newline at end of file
diff --git a/catalog/view/theme/default/template/d_quickcheckout/empty.tpl b/catalog/view/theme/default/template/d_quickcheckout/empty.tpl
new file mode 100755
index 0000000..8913f79
--- /dev/null
+++ b/catalog/view/theme/default/template/d_quickcheckout/empty.tpl
@@ -0,0 +1,8 @@
+
\ No newline at end of file
diff --git a/catalog/view/theme/default/template/d_quickcheckout/field.tpl b/catalog/view/theme/default/template/d_quickcheckout/field.tpl
new file mode 100755
index 0000000..4dfc80c
--- /dev/null
+++ b/catalog/view/theme/default/template/d_quickcheckout/field.tpl
@@ -0,0 +1,201 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+