Ver Fonte

Merge branch 'test' of git.oschina.net:yiguanjia/php into test

DengTao há 8 anos atrás
pai
commit
87c3b49bbb

+ 1 - 0
www/webapp/o2o/css/ratchetOverloading.css

@@ -97,4 +97,5 @@
 /*双十一*/
 #activitiesScroll img{
 	/*float: left;*/
+	display: block;
 }

Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
www/webapp/o2o/dist/js/build/template.js


Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
www/webapp/o2o/dist/js/main.js


+ 1 - 1
www/webapp/o2o/dist/js/page/activities/day.js

@@ -1 +1 @@
-define(["$","template","IScroll","recharge","native","config","user","product"],function(e,t,n,r,i,s,o,u){function a(t){t.preventDefault(),e(document).trigger("spa:navigate",{hash:"",pushData:{dontNeedReload:!0}})}return{title:"企业服务",body:"",init:function(t,n){var r=this,i=e(document);r.on("swipeRight",function(e){history.go(-1)}),e.newTouch(".back-button",function(e){history.go(-1)},r),r.on("tapBackButton",function(e){history.go(-1)}),e.newTouch(".btn-appliances",function(t){t.preventDefault();var n=parseInt(e(this).attr("data-product-type"));i.trigger("spa:navigate",{hash:"placeOrder",pushData:{product:u.allList[n-1],needReset:!0}})},r),e.newTouch(".btn-home-day",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"activity-day",pushData:{needReset:!0}})},r),e.newTouch(".btn-banner-coupon",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"myCoupon",pushData:{needReload:!0}})},r),e.newTouch(".btn-banner-recharge",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"recharge",pushData:{needReload:!0}})},r),n.resolve()},beforeopen:function(e,t){t.resolve()},afteropen:function(i,o){var u=this,a=e(document);i.pushData.dontNeedReload||(a.trigger("spa:openloader"),r.getRechargeList(function(r){a.trigger("spa:closeloader");if(r.success){var o=t("activities/day",{showNavBar:!s.isWX,recharges:r.data});e(".spa-page-body",u).html(o);var f=e(".btn-add-recharge").attr("data-index");for(var l=f;l<2;l++);setTimeout(function(){i.scroll=new n("#activitiesScroll")},500)}})),o.resolve()},beforeclose:function(e,t){t.resolve()}}});
+define(["$","template","IScroll","recharge","native","config","user","product"],function(e,t,n,r,i,s,o,u){function a(t){t.preventDefault(),e(document).trigger("spa:navigate",{hash:"",pushData:{dontNeedReload:!0}})}return{title:"双十一活动",body:"",init:function(t,n){var r=this,i=e(document);r.on("swipeRight",function(e){a.call(this,e)}),e.newTouch(".back-button",function(e){a.call(this,e)},r),r.on("tapBackButton",function(e){a.call(this,e)}),e.newTouch(".btn-appliances",function(t){t.preventDefault();var n=parseInt(e(this).attr("data-product-type"));i.trigger("spa:navigate",{hash:"placeOrder",pushData:{product:u.allList[n-1],needReset:!0}})},r),e.newTouch(".btn-home-day",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"activity-day",pushData:{needReset:!0}})},r),e.newTouch(".btn-banner-coupon",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"myCoupon",pushData:{needReload:!0}})},r),e.newTouch(".btn-banner-recharge",function(e){e.preventDefault(),i.trigger("spa:navigate",{hash:"recharge",pushData:{needReload:!0}})},r),n.resolve()},beforeopen:function(e,t){t.resolve()},afteropen:function(i,o){var u=this,a=e(document);i.pushData.dontNeedReload||(a.trigger("spa:openloader"),r.getRechargeList(function(r){a.trigger("spa:closeloader");if(r.success){var o=t("activities/day",{showNavBar:!s.isWX,recharges:r.data});e(".spa-page-body",u).html(o),setTimeout(function(){i.scroll=new n("#activitiesScroll")},500)}})),o.resolve()},beforeclose:function(e,t){t.resolve()}}});

+ 1 - 1
www/webapp/o2o/dist/js/page/homeenterprise.js

@@ -1 +1 @@
-define(["$","template","IScroll","recharge","native","config","user"],function(e,t,n,r,i,s,o){function u(t){t.preventDefault(),e(document).trigger("spa:navigate",{hash:"",pushData:{dontNeedReload:!0}})}return{title:"企业服务",body:"",init:function(t,n){var r=this,i=e(document);r.on("swipeRight",function(e){u.call(this,e)}),e.newTouch(".back-button",function(e){u.call(this,e)},r),r.on("tapBackButton",function(e){u.call(this,e)}),e.newTouch(".o2o-btn-homestay",function(e){e.preventDefault(),window.location.href="/index.php?r=o2o/advisory/enterprise"},r),n.resolve()},beforeopen:function(e,t){t.resolve()},afteropen:function(i,o){var u=this,a=e(document);i.pushData.dontNeedReload||(a.trigger("spa:openloader"),r.getRechargeList(function(r){a.trigger("spa:closeloader");if(r.success){var o=t("homeenterprise/index",{showNavBar:!s.isWX,recharges:r.data});e(".spa-page-body",u).html(o);var f=e(".btn-add-recharge").attr("data-index");for(var l=f;l<2;l++);setTimeout(function(){i.scroll=new n("#homeenterpriseScroll")},500)}})),o.resolve()},beforeclose:function(e,t){t.resolve()}}});
+define(["$","template","IScroll","recharge","native","config","user"],function(e,t,n,r,i,s,o){function u(t){t.preventDefault(),e(document).trigger("spa:navigate",{hash:"",pushData:{dontNeedReload:!0}})}return{title:"企业服务",body:"",init:function(t,n){var r=this,i=e(document);r.on("swipeRight",function(e){u.call(this,e)}),e.newTouch(".back-button",function(e){u.call(this,e)},r),r.on("tapBackButton",function(e){u.call(this,e)}),e.newTouch(".o2o-btn-homestay",function(e){e.preventDefault(),window.location.href="/index.php?r=o2o/advisory/enterprise"},r),n.resolve()},beforeopen:function(e,t){t.resolve()},afteropen:function(i,o){var u=this,a=e(document);i.pushData.dontNeedReload||(a.trigger("spa:openloader"),r.getRechargeList(function(r){a.trigger("spa:closeloader");if(r.success){var o=t("homeenterprise/index",{showNavBar:!s.isWX,recharges:r.data});e(".spa-page-body",u).html(o),setTimeout(function(){i.scroll=new n("#homeenterpriseScroll")},500)}})),o.resolve()},beforeclose:function(e,t){t.resolve()}}});

Diff do ficheiro suprimidas por serem muito extensas
+ 1 - 2
www/webapp/o2o/js/build/template.js


+ 7 - 15
www/webapp/o2o/js/page/activities/day.js

@@ -11,31 +11,27 @@ define(['$', 'template', 'IScroll', 'recharge', 'native', 'config', 'user','prod
 	}
 
 	return {
-		title: '企业服务',
+		title: '双十一活动',
 		body: '',
 		init: function (pageData, dtd) {
 			/* this是什么? */
 			var $view = this;
 			var $doc = $(document);
 
-			/* 定义按钮事件。
-			 * 为什么不是$(selector).onclick(function)呢?
-			 */
-
 			// 返回
 			$view.on('swipeRight', function (event) {
-				//back.call(this, event);
-				history.go(-1);
+				back.call(this, event);
+				// history.go(-1);
 			});
 
 			$.newTouch('.back-button', function (event) {
-				//back.call(this, event);
-				history.go(-1);
+				back.call(this, event);
+				// history.go(-1);
 			}, $view);
 
 			$view.on('tapBackButton', function (event) {
-				//back.call(this, event);
-				history.go(-1);
+				back.call(this, event);
+				// history.go(-1);
 			});
 			//跳转下单页面
 			$.newTouch('.btn-appliances', function (event) {
@@ -99,10 +95,6 @@ define(['$', 'template', 'IScroll', 'recharge', 'native', 'config', 'user','prod
 							recharges: res.data
 						});
 						$('.spa-page-body', $view).html(tpl);
-						//var value = $(this).attr('data-value');
-						var value = $('.btn-add-recharge').attr('data-index');
-						for (var i = value; i < 2; i++) {
-						}
 						setTimeout(function () {
 							pageData.scroll = new IScroll('#activitiesScroll');
 						}, 500);

+ 68 - 72
www/webapp/o2o/js/page/homeenterprise.js

@@ -1,83 +1,79 @@
 define(['$', 'template', 'IScroll', 'recharge', 'native', 'config', 'user'], function ($, template, IScroll, recharge, native, config, user) {
 
-    function back(event) {
-        event.preventDefault();
-        $(document).trigger('spa:navigate', {
-            hash: '',
-            pushData: {
-                dontNeedReload: true
-            }
-        });
-    }
+	function back(event) {
+		event.preventDefault();
+		$(document).trigger('spa:navigate', {
+			hash: '',
+			pushData: {
+				dontNeedReload: true
+			}
+		});
+	}
 
-    return {
-        title: '企业服务',
-        body: '',
-        init: function (pageData, dtd) {
-            /* this是什么? */
-            var $view = this;
-            var $doc = $(document);
+	return {
+		title: '企业服务',
+		body: '',
+		init: function (pageData, dtd) {
+			/* this是什么? */
+			var $view = this;
+			var $doc = $(document);
 
-            /* 定义按钮事件。
-             * 为什么不是$(selector).onclick(function)呢?
-             */
+			/* 定义按钮事件。
+			 * 为什么不是$(selector).onclick(function)呢?
+			 */
 
-            // 返回
-            $view.on('swipeRight', function (event) {
-                back.call(this, event);
-                // history.go(-1);
-            });
+			// 返回
+			$view.on('swipeRight', function (event) {
+				back.call(this, event);
+				// history.go(-1);
+			});
 
-            $.newTouch('.back-button', function (event) {
-                back.call(this, event);
-                // history.go(-1);
-            }, $view);
+			$.newTouch('.back-button', function (event) {
+				back.call(this, event);
+				// history.go(-1);
+			}, $view);
 
-            $view.on('tapBackButton', function (event) {
-                back.call(this, event);
-                // history.go(-1);
-            });
-            $.newTouch('.o2o-btn-homestay',function (event) {
-                event.preventDefault();
-                window.location.href='/index.php?r=o2o/advisory/enterprise';
-                // window.location.href='http://commontest.yiguanjia.me/index.php?r=common/activity/Enterprise';
-                // console.log('测试')
-            },$view);
+			$view.on('tapBackButton', function (event) {
+				back.call(this, event);
+				// history.go(-1);
+			});
+			$.newTouch('.o2o-btn-homestay', function (event) {
+				event.preventDefault();
+				window.location.href = '/index.php?r=o2o/advisory/enterprise';
+				// window.location.href='http://commontest.yiguanjia.me/index.php?r=common/activity/Enterprise';
+				// console.log('测试')
+			}, $view);
 
-            dtd.resolve();
-        },
-        beforeopen: function (pageData, dtd) {
-            dtd.resolve();
-        },
-        afteropen: function (pageData, dtd) {
-            var $view = this;
-            var $doc = $(document);
+			dtd.resolve();
+		},
+		beforeopen: function (pageData, dtd) {
+			dtd.resolve();
+		},
+		afteropen: function (pageData, dtd) {
+			var $view = this;
+			var $doc = $(document);
 
-            if (!pageData.pushData.dontNeedReload) {
-                $doc.trigger('spa:openloader');
-                recharge.getRechargeList(function (res) {
-                    $doc.trigger('spa:closeloader');
-                    if (res.success) {
-                        var tpl = template('homeenterprise/index', {
-                            showNavBar: !config.isWX,
-                            recharges: res.data
-                        });
-                        $('.spa-page-body', $view).html(tpl);
-                        //var value = $(this).attr('data-value');
-                        var value = $('.btn-add-recharge').attr('data-index');
-                        for (var i = value; i < 2; i++) {
-                        }
-                        setTimeout(function () {
-                            pageData.scroll = new IScroll('#homeenterpriseScroll');
-                        }, 500);
-                    }
-                });
-            }
+			if (!pageData.pushData.dontNeedReload) {
+				$doc.trigger('spa:openloader');
+				recharge.getRechargeList(function (res) {
+					$doc.trigger('spa:closeloader');
+					if (res.success) {
+						var tpl = template('homeenterprise/index', {
+							showNavBar: !config.isWX,
+							recharges: res.data
+						});
+						$('.spa-page-body', $view).html(tpl);
+						setTimeout(function () {
+							pageData.scroll = new IScroll('#homeenterpriseScroll');
+						}, 500);
+					}
+				});
+			}
 
-            dtd.resolve();
-        },
-        beforeclose: function (pageData, dtd) {
-            dtd.resolve();
-        }
-    }
+			dtd.resolve();
+		},
+		beforeclose: function (pageData, dtd) {
+			dtd.resolve();
+		}
+	}
 })

+ 96 - 35
www/webapp/o2o/tpl/activities/day.html

@@ -3,46 +3,107 @@
 	<a class="left-button back-button">
 		<div class="icon icon-left-nav"></div>
 	</a>
-	<h1 class="title">双十一活动</h1>
+	<h1 class="title">企业服务</h1>
 </header>
 {{ /if }}
-<div id="activitiesScroll" class="content">
-	<div class="scroller">
-		<div class="box-container">
-			<div class="box-container box box-vertical" style="background: #fff">
-				<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%801-%E7%AC%AC%E4%B8%80%E9%83%A8%E5%88%86.jpg" alt="">
-				<!--下单-->
-				<!--<span style="position: relative;margin-top: -0.22rem;margin-bottom: -0.22rem;">-->
-					<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%801.jpg" alt="">
-					<span style="    width: 32.7%;
+
+<div class="content">
+	<div class="box-container">
+		<div class="box-container box box-vertical">
+			<div id="activitiesScroll" class="scroll-container box-flex-1">
+				<div class="scroller">
+					<div class="box-container">
+						<div class="box-container box box-vertical" style="background: #fff">
+							<img style="width: 100%;"
+							     src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%801-%E7%AC%AC%E4%B8%80%E9%83%A8%E5%88%86.jpg"
+							     alt="">
+							<!--下单-->
+							<div style="position: relative;">
+							<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E7%82%B9%E5%87%BB%E6%8A%A2%E8%B4%AD.jpg"
+							     alt="">
+							<div style="
+							width: 32.7%;
+							padding-bottom: 10.5%;
+							position: absolute;
+							left: 35.6%;
+							top: 0;" class="btn-appliances" data-product-type="9"></div>
+							</div>
+							<img style="width: 100%;"
+							     src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%803-%E7%AC%AC%E4%BA%8C%E9%83%A8%E5%88%86.jpg"
+							     alt="">
+							<!--优惠券-->
+							<div style="position: relative;">
+								<img style="width: 100%;"
+								     src="http://odulvej8l.bkt.clouddn.com/%E7%82%B9%E5%87%BB%E9%A2%86%E5%8F%96.jpg" alt="">
+								<div style="    width: 32.7%;
     padding-bottom: 10.5%;
     position: absolute;
     left: 35.6%;
-    <!--top: 0;" class="btn-appliances" data-product-type="9" ></span>-->
-				<!--</span>-->
-				<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%803-%E7%AC%AC%E4%BA%8C%E9%83%A8%E5%88%86.jpg" alt="">
-				<!--优惠券-->
-				<!--<div style="position: relative;margin-top: -0.22rem;margin-bottom: -0.22rem;">-->
-					<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%802.jpg" alt="">
-					<div style="    width: 32.7%;
-    padding-bottom: 10.5%;
-    position: absolute;
-    left: 35.6%;
-    <!--top: 0;" class="btn-banner-coupon"></div>-->
-				<!--</div>-->
-				<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%805-%E7%AC%AC%E4%B8%89%E9%83%A8%E5%88%86.jpg" alt="">
-				<!--充值卡-->
-				<!--<div style="position: relative;margin-top: -0.22rem;margin-bottom: -0.22rem;">-->
-					<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%803.jpg" alt="">
-					<!--<div style="    width: 32.7%;-->
-    <!--padding-bottom: 10.5%;-->
-    <!--position: absolute;-->
-    <!--left: 35.6%;-->
-    <!--&lt;!&ndash;top: 0;" class="btn-banner-recharge"></div>&ndash;&gt;-->
-				<!--</div>-->
-				<img style="width: 100%;" src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%807-%E7%AC%AC%E5%9B%9B%E9%83%A8%E5%88%86.jpg" alt="">
+    top: 0;" class="btn-banner-coupon"></div>
+							</div>
+							<img style="width: 100%;"
+							     src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%805-%E7%AC%AC%E4%B8%89%E9%83%A8%E5%88%86.jpg"
+							     alt="">
+							<!--充值卡-->
+							<div style="position: relative;">
+								<img style="width: 100%;"
+								     src="http://odulvej8l.bkt.clouddn.com/%E7%82%B9%E5%87%BB%E6%9F%A5%E7%9C%8B.jpg" alt="">
+								<div style="    width: 32.7%;
+							padding-bottom: 10.5%;
+							position: absolute;
+							left: 35.6%;
+							top: 0;" class="btn-banner-recharge"></div>
+							</div>
+							<img style="width: 100%;"
+							     src="http://odulvej8l.bkt.clouddn.com/%E5%8F%8C%E5%8D%81%E4%B8%807-%E7%AC%AC%E5%9B%9B%E9%83%A8%E5%88%86.jpg"
+							     alt="">
+						</div>
+					</div>
+					<div style="width: 100%;padding-bottom:13%; "></div>
+				</div>
+				<div class="prevent-scroll">
+					<!--<div class="o2o-btn-homestay" style="
+					    text-align: center;
+              background: rgb(219,199,67);
+              color: #fff;
+              position: absolute;
+              right: 0;
+              width: 25%;
+              top: -1.65rem;
+              border: 0px solid rgba(0,0,0,0.14);
+              border-radius: 14px;
+              line-height: 1.5rem;">点击咨询
+					</div>-->
+					<div class="box my-action">
+						<!--首页-->
+						<div class="width-percent-33">
+							<div class="title-container-square">
+								<a class="btn-home-action btn-action-my-order">
+									<div class="logo logo-my-order"></div>
+									<div class="name">首页</div>
+								</a>
+							</div>
+						</div>
+						<!--LOGO-->
+						<div class="width-percent-33">
+							<div class="title-container-square">
+								<a class="btn-home-action btn-action-logo" href="weixin://contacts/profile/honghaitzz">
+									<div class="logo logo-my-logo"></div>
+								</a>
+							</div>
+						</div>
+						<!--我的-->
+						<div class="width-percent-33">
+							<div class="title-container-square">
+								<a class="btn-home-action btn-action-coupon">
+									<div class="logo logo-coupon"></div>
+									<div class="name">我的</div>
+								</a>
+							</div>
+						</div>
+					</div>
+				</div>
 			</div>
 		</div>
 	</div>
-</div>
-</div>
+</div>

Alguns ficheiros não foram mostrados porque muitos ficheiros mudaram neste diff