Parcourir la source

更改组件部分默认属性设置

洪海涛 il y a 8 ans
Parent
commit
88943955eb

+ 5 - 0
www/vue/README.md

@@ -46,3 +46,8 @@ npm test
 │   └── router
 │       └── index.js                    //路由配置
 ```
+
+# 笔记(暂时)
+```angular2html
+暂时没有为用户添加,编辑,选择地址跳转做出页面重定向.后期作调整
+```

+ 3 - 3
www/vue/src/components/CompanyProfile/brand.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="brand">
   <h2>brand</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 3 - 3
www/vue/src/components/CompanyProfile/documents.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="documents">
   <h2>documents</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 3 - 3
www/vue/src/components/CompanyProfile/housekeeper.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="housekeeper">
   <h2>housekeeper</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 3 - 3
www/vue/src/components/CompanyProfile/indemnity.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="Indemnity">
   <h2>Indemnity</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 3 - 3
www/vue/src/components/CompanyProfile/tool.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="tool">
   <h2>tool</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 2 - 2
www/vue/src/components/about.vue

@@ -3,7 +3,7 @@
 	</div>
 </template>
 
-<script>
+<script type="es6">
   import axios from 'axios'
   export default{
     data () {
@@ -25,7 +25,7 @@
     }
   }
 </script>
-<style scoped lang="less">
+<style lang="less" scoped>
 
 	.about-text-align {
 		text-align: left;

+ 62 - 0
www/vue/src/components/activityText.vue

@@ -0,0 +1,62 @@
+<template>
+	<div class="housekeeper">
+		<scroller>
+			<p style="position: absolute;background: #fff;"></p>
+			<h3 style="text-align: center;">充值赠送活动协议</h3>
+			<h4>一、活动内容:</h4>
+			<h5>单笔充值1000元,赠送一挂式空调清洗服务</h5>
+			<h5>单笔充值3000元,赠送一床一沙发除螨服务</h5>
+			<h5>单笔充值5000元,赠送二床一沙发除螨服务</h5>
+			<h5>单笔充值10000元,赠送一冰箱清洗一挂式空调清洗一洗衣机清洗二床一沙发除螨服务</h5>
+			<h4>二、余额构成</h4>
+			<h5>您实际支付的充值本金加上壹管家的返现金额会构成您的账户余额(人民币)。</h5>
+			<h4>三、充值金额有效期</h4>
+			<h5>充值及返现金额有效期为自充值日起至用完即止。</h5>
+			<h4>四、充值金额使用规则</h4>
+			<h5>余额可用于支付壹管家所有家庭保洁和家电保洁服务,但不能用于支付服务中产生的其他第三方费用,也不支持提现、转移、转赠,退款。</h5>
+			<h4>五、发票金额</h4>
+			<h5>
+				根据我们已收到的充值金额开具,充值赠送金额或其他并非您实际支付的费用不能开具发票。</h5>
+			<h4>六、充返活动退款规则</h4>
+			<h5>退款说明:在参与壹管家充返活动后的7天之内(≤7天,即参与活动当天为第一天),您可享受7天退款服务,当您申请退款服务,则视为您自动放弃“充值赠送”活动权益,将不再享受充返折扣,具体退款规则如下:</h5>
+			<h5>1.充值余额:</h5>
+			<h5>a)若未产生服务费用,可退还当期实际充值金额,我们会在您申请退款服务之日起21个工作日内为您办理退款;</h5>
+			<h5>b)若已产生服务费用,可退款扣除您在下单服务中实际产生的用费后的实际剩余充值金额(实际剩余充值金额=实际充值金额-实际服务金额),我们会在您申请退款服务之日起21个工作日内为您办理退款;</h5>
+			<h5>
+				2.活动赠品服务(例:日本游抽奖活动);仅支持奖金兑换码在未发送并兑换使用的情况下享受退款服务,我们需要收回您在参与活动时得到的奖金号,并在您申请退款服务之日起21个工作日内,为您退还实际充值金额;抽奖兑换码及旅游奖金一经兑换使用,则无法享受退款服务。</h5>
+			<h5>3、壹管家返活动的相关问题,您可咨询服务热线400-806-5111(周一至周五,9:00-18:00)</h5>
+			<p></p>
+			<div style="padding-bottom: 15%;width: 100%"></div>
+		</scroller>
+	</div>
+</template>
+
+<script type="es6">
+  export default {}
+</script>
+
+<style lang="less" scoped>
+	h3{
+		font-size: 24px;
+		margin: 15px 0;
+	}
+	h4, h5 {
+		margin-top: 0;
+		margin-bottom: 10px;
+		line-height: 1;
+	}
+	h4{
+		text-align: left;
+		font-size: 18px;
+		padding-left: 15px;
+	}
+	h5 {
+		padding: 0 15px;
+		text-align: left;
+		font-size: 15px;
+		line-height: 25px;
+		font-weight: 400;
+		color: #8f8f94;
+		text-transform: uppercase;
+	}
+</style>

+ 3 - 2
www/vue/src/components/address/addresList.vue

@@ -16,7 +16,7 @@
     <alert v-model="showAlert" :title="(alertTitle)"> {{ (alertContent) }}</alert>
   </div>
 </template>
-<script>
+<script type="es6">
   import config from '../../config/config'
   import axios from 'axios'
   import {Alert} from 'vux'
@@ -83,7 +83,8 @@
     }
   }
 </script>
-<style scoped lang="less">
+
+<style lang="less" scoped>
   .address-body {
     background-color: white;
     h4 {

+ 9 - 5
www/vue/src/components/address/addressAdd.vue

@@ -12,8 +12,12 @@
       </group>
       <!--定位地址-->
       <group>
-        <cell value-align="left" :border-intent="true" :is-link="true" :title="positionName"
-              link="/addressPoisiton"></cell>
+        <cell
+          value-align="left"
+          :border-intent="true"
+          :is-link="true"
+          :title="positionName"
+          link="/addressPoisiton"></cell>
       </group>
       <!--详细地址-->
       <group>
@@ -27,7 +31,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import {XInput, Group, Cell, Alert, TransferDomDirective as TransferDom} from 'vux'
   import config from '../../config/config'
   import axios from 'axios'
@@ -134,8 +138,8 @@
   }
 </script>
 
-<!-- 添加“scoped”属性来限制CSS到此组件 -->
-<style lang="less">
+<!-- 添加“scoped”属性来限制LESS到此组件 -->
+<style lang="less" scoped>
   h4 {
     margin-top: 15px;
   }

+ 3 - 4
www/vue/src/components/address/addressDetail.vue

@@ -30,7 +30,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import {XInput, Group, Cell, Alert, TransferDomDirective as TransferDom} from 'vux'
   import config from '../../config/config'
   import axios from 'axios'
@@ -162,8 +162,8 @@
   }
 </script>
 
-<!-- 添加“scoped”属性来限制CSS到此组件 -->
-<style lang="less">
+<!-- 添加“scoped”属性来限制LESS到此组件 -->
+<style lang="less" scoped>
   h4 {
     margin-top: 15px;
   }
@@ -193,5 +193,4 @@
       }
     }
   }
-
 </style>

+ 2 - 2
www/vue/src/components/address/addressPoisiton.vue

@@ -18,7 +18,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import {Search, Group, Cell, XButton} from 'vux'
   import axios from 'axios'
   import config from '../../config/config'
@@ -86,7 +86,7 @@
   }
 </script>
 
-<style scoped lang="less">
+<style lang="less" scoped>
   h4 {
     margin-top: 15px;
   }

+ 4 - 1
www/vue/src/components/balanceLog.vue

@@ -12,7 +12,7 @@
 					<span class="month-span">{{month}}</span>月
 				</div>
 			</div>
-			<div class="btn-recharge">充值</div>
+			<div class="btn-recharge" @click="recharge">充值</div>
 			<button-tab>
 				<button-tab-item selected @on-item-click="consoleIndex(1)">充值</button-tab-item>
 				<button-tab-item @on-item-click="consoleIndex(2)">取消</button-tab-item>
@@ -141,6 +141,9 @@
         }
         console.log(this.tmp)
       },
+      recharge () {
+        this.$router.push({path: '/recharge'})
+      }
     }
   }
   // let balanceInfo = {id: config.userId, start_time: '2016-11-01', end_time: '2016-11-30'}

+ 2 - 5
www/vue/src/components/completeOrder.vue

@@ -10,12 +10,9 @@
 				立即评价
 		</span>
 	</div>
-
 </template>
 
-
-
-<script>
+<script type="es6">
   export default {
     created () {
 
@@ -34,7 +31,7 @@
     }
   }
 </script>
-<style scoped lang="less">
+<style lang="less" scoped>
 	.complete-order {
 		margin-top: 40px;
 		span {

+ 1 - 1
www/vue/src/components/home.vue

@@ -23,7 +23,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import {mapState, mapActions} from 'vuex'
   import {XSwitch} from 'vux'
   export default {

+ 1 - 1
www/vue/src/components/homeList.vue

@@ -14,7 +14,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import config from '../config/config'
   import product from '../config/product'
   export default {

+ 3 - 3
www/vue/src/components/myCoupon.vue

@@ -1,13 +1,13 @@
-<template lang="html">
+<template>
 <div class="myoupon">
   <h2>myCoupon</h2>
 </div>
 </template>
 
-<script>
+<script type="es6">
 export default {
 }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
 </style>

+ 1 - 1
www/vue/src/components/navTitle.vue

@@ -2,7 +2,7 @@
   <div class="navTitle">{{navTitle}}</div>
 </template>
 
-<script>
+<script type="es6">
 export default {
   name: 'navTitle',
   data () {

+ 1 - 1
www/vue/src/components/navigation.vue

@@ -30,7 +30,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import {Tabbar, TabbarItem, Group, Cell} from 'vux'
   export default {
     name: 'navigation',

+ 2 - 4
www/vue/src/components/order.vue

@@ -67,9 +67,7 @@
 
 </template>
 
-
-
-<script>
+<script type="es6">
   import { ButtonTab, ButtonTabItem, Divider, XDialog, TransferDomDirective as TransferDom } from 'vux'
   import axios from 'axios'
   import qs from 'qs'
@@ -146,7 +144,7 @@
     }
   }
 </script>
-<style scoped lang="less">
+<style lang="less" scoped>
 	.order-block {
 		border-top:1px solid silver;
 		border-bottom:1px solid silver;

+ 2 - 2
www/vue/src/components/orderInfo.vue

@@ -70,7 +70,7 @@
 
 </template>
 
-<script>
+<script type="es6">
   import { Cell, CellBox, CellFormPreview, FormPreview, Group, Badge, XDialog, TransferDomDirective as TransferDom } from 'vux'
   import axios from 'axios'
   import config from '../config/config'
@@ -216,7 +216,7 @@
   }
 </script>
 
-<style scoped lang="less">
+<style lang="less" scoped>
 	.order-info {
 		font-size: .8rem;
 		background-color: #fafafa;

+ 1 - 1
www/vue/src/components/placeOrder.vue

@@ -61,7 +61,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import config from '../config/config'
   import selectTime from '../config/selectTime'
   import {Group, DatetimeRange, TransferDom, Datetime, XNumber, Cell, CellBox, XTextarea, Alert} from 'vux'

+ 1 - 1
www/vue/src/components/product.vue

@@ -16,7 +16,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   import config from '../config/config'
   import {mapState, mapActions} from 'vuex'
   import {XImg} from 'vux'

+ 173 - 8
www/vue/src/components/recharge.vue

@@ -1,13 +1,178 @@
-<template lang="html">
-<div class="recharge">
-  <h2>recharge</h2>
-</div>
+<template>
+	<div class="recharge">
+		<scroller>
+			<img class="ad-hide" src="http://odulvej8l.bkt.clouddn.com/%E5%85%85%E5%80%BC%E5%8D%A1.jpg" style="width: 100%;">
+			<div class="recharge-title">充值余额</div>
+			<group>
+				<cell
+					:title="('充值有好礼')"
+					is-link
+					value-align="left"
+					:border-intent="false"
+					:arrow-direction="isActive ? 'up' : 'down'"
+					@click.native="isActive = !isActive"></cell>
+				<p class="slide" :class="isActive?'animate':''">
+					<span>充值1000--赠送:一挂式空调清洗</span>
+					<span>充值3000--赠送:一床一沙发除螨</span>
+					<span>充值5000--赠送:二床一沙发除螨</span>
+					<span>充值10000--赠送:一冰箱清洗一挂式空调清洗一洗衣机清洗二床一沙发除螨</span>
+				</p>
+			</group>
+			<ul class="ad-hide list-content list-recharge" style="padding-top: 5px;padding-bottom: 5px;padding-left: 10%;">
+				<li class="media" data-id="57f3485d9f5160bf048b4812" data-value="1000" data-index="0">
+					<div>RMB:1000</div>
+				</li>
+				<li class="media on" data-id="57f3486b9f5160c9048b47b2" data-value="3000" data-index="1">
+					<div>RMB:3000</div>
+				</li>
+				<li class="media" data-id="57f3487b9f5160c4048b4713" data-value="5000" data-index="2">
+					<div>RMB:5000</div>
+				</li>
+				<li class="media" data-id="582c38d49f5160ad048b56a1" data-value="10000" data-index="3">
+					<div>RMB:10000</div>
+				</li>
+				<li class="media" data-id="5911c0f89f5160b3048b6be9" data-value="1" data-index="4">
+					<div class="input-title">其他数额</div>
+					<div class="input-rmb">RMB:</div>
+					<input type="text" maxlength="8" name="" value="" class="rechange-input"></li>
+			</ul>
+			<div class="ad-hide" style="text-align: center;clear: both;margin-top: 9rem;"><span style="font-size: 0.6rem">点击立即充值,即表示您已经同意壹管家</span><span
+				style="font-size: 0.6rem;font-weight: 600;display: block;"></span><span style="font-size: 0.6rem;">《<span
+				class="pay-agreement" style="text-decoration: underline;color: #0A246A" @click="activity">充返活动协议</span>》</span></div>
+			<div class="btn-add-recharge">立即去充值</div>
+			<div style="width: 100%;padding-bottom: 13%;"></div>
+		</scroller>
+	</div>
 </template>
 
-<script>
-export default {
-}
+<script type="es6">
+  import {Group, Cell} from 'vux'
+  export default {
+    data () {
+      return {
+        isActive: false
+      }
+    },
+    components: {
+      Group, Cell
+    },
+    methods: {
+      show (e) {
+        if (this.index !== e) {
+          this.isActive = e
+          this.index = e
+        } else {
+          this.isActive = -1
+          this.index = -1
+        }
+      },
+      activity () {
+        this.$router.push({path: '/activityText'})
+      }
+    }
+  }
 </script>
 
-<style lang="css">
+<style lang="less" scoped>
+	img {
+		display: block;
+	}
+	
+	.recharge-title {
+		padding-left: 15px;
+		font-size: 20px;
+		border-bottom: 1px solid rgba(0, 0, 0, 0.4);
+		padding-bottom: 10px;
+		padding-top: 11px;
+		text-align: left;
+		margin-bottom: -20px;
+	}
+	
+	ul {
+		padding-top: 5px;
+		padding-bottom: 5px;
+		padding-left: 10%;
+		align-content: flex-start;
+		li.media.on {
+			border: 2px solid rgba(146, 118, 3, 1);
+			font-size: 12px;
+		}
+		li.media {
+			margin: 2%;
+			float: left;
+			height: 2.5rem;
+			padding: 10px 0;
+			width: 25.33%;
+			cursor: pointer;
+			font-size: 13px;
+			border: 1px solid;
+			text-align: center;
+			div {
+				line-height: 1.5rem;
+			}
+			&:nth-child(5) {
+				padding: 15px;
+				width: 55%;
+				padding-top: 0.4rem;
+			}
+			.input-title {
+				line-height: 1.5rem;
+				font-size: 12px;
+				width: 35%;
+				float: left;
+			}
+			.input-rmb {
+				float: left;
+				width: 25%;
+			}
+			input {
+				margin: 0;
+				padding: 0;
+				width: 40%;
+				height: 25px;
+				margin-top: 2%;
+				text-align: center;
+			}
+		}
+		&, li, div, input {
+			-webkit-box-sizing: border-box;
+			-moz-box-sizing: border-box;
+			box-sizing: border-box;
+			list-style: none;
+			margin: 0;
+			padding: 0;
+		}
+	}
+	
+	.btn-add-recharge {
+		width: 80%;
+		clear: both;
+		color: white;
+		padding: 15px;
+		margin: 0 auto;
+		border: 1px solid;
+		text-align: center;
+		background-color: rgba(146, 118, 3, 1);
+		transition: all 2s;
+		margin-top: 10px;
+	}
+	
+	/*动画*/
+	.slide {
+		padding: 0 20px;
+		overflow: hidden;
+		max-height: 0;
+		transition: max-height .5s cubic-bezier(0, 1, 0, 1) -.1s;
+		span {
+			display: block;
+			text-align: left;
+			font-size: 15px;
+		}
+	}
+	
+	.animate {
+		max-height: 9999px;
+		transition-timing-function: cubic-bezier(0.5, 0, 1, 0);
+		transition-delay: 0s;
+	}
 </style>

+ 1 - 1
www/vue/src/components/selectTime.vue

@@ -17,7 +17,7 @@
   </div>
 </template>
 
-<script>
+<script type="es6">
   export default {
     name: 'selectTime',
     data () {

+ 1 - 1
www/vue/src/components/swiper.vue

@@ -10,7 +10,7 @@
     <!--<div class="swiper-scrollbar"   slot="scrollbar"></div>-->
   </swiper>
 </template>
-<script>
+<script type="es6">
 import { swiper, swiperSlide } from 'vue-awesome-swiper'
 export default {
   name: 'carrousel',

+ 2 - 2
www/vue/src/components/userCoupon.vue

@@ -51,7 +51,7 @@
 	</div>
 </template>
 
-<script>
+<script type="es6">
   import axios from 'axios'
   import config from '../config/config'
   import { XDialog, TransferDomDirective as TransferDom } from 'vux'
@@ -124,7 +124,7 @@
 
   }
 </script>
-<style scoped lang="less">
+<style lang="less" scoped>
 	.user-coupon-background {
 		background-color: #FFFFFF;
 		height: 60px!important;

+ 1 - 0
www/vue/src/main.js

@@ -59,6 +59,7 @@ Vue.component('navTitle', require('./components/navTitle')) // SAP顶部标题
 Vue.component('order', require('./components/order')) // 我的订单
 Vue.component('myCoupon', require('./components/myCoupon')) // 我的代金券
 Vue.component('recharge', require('./components/recharge')) // 充值
+Vue.component('activityText', require('./components/activityText')) // 充值协议
 // 公司形象
 Vue.component('brand', require('./components/CompanyProfile/brand')) // 公司品牌
 Vue.component('housekeeper', require('./components/CompanyProfile/housekeeper')) // 公司管家

+ 2 - 1
www/vue/src/router/index.js

@@ -16,5 +16,6 @@ export default[
   {path: '/addressAdd', name: 'addressAdd', component: require('../components/address/addressAdd.vue')},
   {path: '/addressDetail', name: 'addressDetail', component: require('../components/address/addressDetail.vue')},
   {path: '/addressPoisiton', name: 'addressPoisiton', component: require('../components/address/addressPoisiton.vue')},
-  {path: '/about', name: 'about', component: require('../components/about.vue')}
+  {path: '/about', name: 'about', component: require('../components/about.vue')},
+  {path: '/activityText', name: 'activityText', component: require('../components/activityText.vue')}
 ]