Login / Register flow done , index resources move to static

This commit is contained in:
Vion 2022-01-14 20:11:10 +08:00
parent c5cabaa65f
commit d15130723a
58 changed files with 1361 additions and 30334 deletions

View File

@ -165,7 +165,6 @@ export const useredit = (mobile, pet,address) => {
storeCode:'',
remark:'',
memberMark:'',
remark:''
}
return fetch('member?type=add', data, 'POST' )

View File

@ -1,4 +1,5 @@
/*Body*/
html,body{height:100%;}
body{
font-family: DINPro,'PingFang SC',miui,'Hiragino Sans GB','Microsoft Yahei',sans-serif;
line-height: 1.5;
@ -235,6 +236,7 @@ img, picture {
max-width: 460px;
margin-left: auto!important;
margin-right: auto!important;
box-shadow:unset;
}
.ts-standard-input{

View File

@ -147,9 +147,10 @@
height:auto;
max-height: 15.68rem;
display: block;
overflow:hidden;
video{
max-width:100%;
max-height:100%;
width:100%;
height:100%;
}
}
}
@ -485,7 +486,7 @@ img{
.rc-ma
{
.rc-margin-y--xl{
margin-bottom: 1.88rem;
//margin-bottom: 1.88rem;
}
// padding:60px 0;

View File

@ -1,3 +1,11 @@
.rc-usermain{
width:100%;
padding-bottom:2.8rem;
ol{
overflow-x:hidden;
overflow-y:auto;
}
}
@media screen and (max-width:768px){
.rc-button{
width: 100%;
@ -27,12 +35,8 @@ span{
}
}
.rc-usermain{
width: 92%;
margin: 0 auto;
ul{
height: 70px;
display: block;
height: 4.375rem;
border-bottom: 1px solid #D8D8D8;
display: flex;
align-items: center;
@ -43,17 +47,15 @@ span{
li{
float: left;
width: 30%;
position:relative;
padding-right:.625rem;
}
li:after{
// height: 2px;
// border: 1px solid red;
// display: block;
content:"|";
color: #707070;
margin-left: 5px;
position:absolute;
top:0;
right:0;
}
li:last-child:after{
content:"";
@ -62,16 +64,14 @@ span{
}
ol{
margin-top:1rem;
max-height:70vh;
li{
font-style: normal;
display: block;
height: 32px;
margin-top: 16px;
height: 2rem;
display: flex;
// justify-content: space-between;
align-items: center;
color: #666666;
font-size: 14px;
font-size: .875rem;
text-align: center;
i{
font-style: normal;
@ -130,10 +130,7 @@ span{
}
}
.rc-usermain{
width: 92%;
margin: 0 auto;
margin-top: 60px;
ul{
height: 64px;
background: #F6F6F6;
@ -150,20 +147,19 @@ border-radius: 3px 3px 0px 0px;
li{
float: left;
width: 42%;
}
}
ol{
max-height:37.5rem;
li{
font-style: normal;
display: block;
height: 48px;
margin-top: 16px;
display: flex;
border: 1px solid #D7D7D7;
border-top:0;
//justify-content: space-between;
align-items: center;
color: #666666;

View File

@ -1,7 +1,9 @@
.container{
min-height:80vh;
height:100%;
background-color:#f6f6f6;
display:flex;
flex-direction: column;
align-items: center;
//background-color:#f6f6f6;
}
.ts-max-width--460{
border-radius: 3px;

View File

@ -8,6 +8,9 @@ ul li ol li em strong i {
.rc-center{
overflow:hidden;
}
.r-block{
border-radius:.25rem;
}
//手机端
@media screen and (max-width: 768px) {
.ts-mypersonal{
@ -140,6 +143,7 @@ ul li ol li em strong i {
}
.rc-cordd{
color:#666666;
position:relative;
span{
display: inline-block;
margin-top: 16px;
@ -249,6 +253,15 @@ ul li ol li em strong i {
width: 440px;
height: 652px;
}
.ts-mypersonal{
margin-left:0;
.rc-column{
padding-left:0;
padding-right:0;
}
}
.online{
margin:40px auto;
}
@ -366,13 +379,25 @@ ul li ol li em strong i {
background: #D7D7D7;
margin-top: 16px;
border-radius: 4px;
position:relative;
margin-top:3.32rem;
.r-block{
width: 0%;
height: 100%;
background: #008900;
}
.ts-point-tag{
background:url("../image/img-pointBg.png") no-repeat center top;
background-size:contain;
height:2.375rem;
width:3.625rem;
text-align:center;
position:absolute;
font-size:.875rem;
line-height:2rem;
left:0;
top:-2.6rem;
}
}
.rc-value{
display: flex;

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@ -392,7 +392,7 @@ export default {
mounted() {
//
let usernot=JSON.parse(localStorage.getItem("userInfo"));
console.log(usernot);
//console.log(usernot);
if(usernot==null ||usernot==undefined){
console.log(usernot);
this.loginornot=true
@ -400,21 +400,19 @@ export default {
this.loginornot=false
this.usermessage=usernot;
}
console.log(this.loginornot);
//console.log(this.loginornot);
},
methods: {
bindTracking: function(){
console.log('bindTracking');
//console.log('bindTracking');
},
//
//
searchturn(){
this.$router.push({ name: "usersearch-search",
})
this.$router.push({ name: "usersearch-search",})
},
//
turnlogin(){

View File

@ -1,288 +0,0 @@
<template>
<div class="magnify">
<div class="left_contaner">
<div class="middle_img" @mouseover="boxMouseOver" @mouseleave="boxMouseLeave">
<img :src="middleImg" alt="" style="width:100%">
<div class="shade" @mouseover="shadeMouseOver" @mousemove="shadeMouseMove" ref="shade" v-show="isShade"></div>
</div>
<div class="carousel">
<div class="left_arrow arrow" @click="leftArrowClick">
<img src="../assets/image/userleft.jpg" alt="">
</div>
<div class="show_box">
<ul class="picture_container" ref="middlePicture">
<li class="picture_item" @click="tabPicture(item,index)" v-for="(item, index) in pictureList" :key="index">
<img :src="item.attachmentPath" class="small_img" alt="">
</li>
</ul>
</div>
<div class="right_arrow arrow" @click="rightArrowClick">
<img src="../assets/image/userright.png" alt="">
</div>
</div>
</div>
<div class="right_contanier" v-show="isBig">
<img :src="middleImg" ref="bigImg" class="big_img" alt="">
</div>
</div>
</template>
<script>
import $ from 'jquery'
export default {
props:['parentmsg'],
props: {
tableLabelTest:Array,
imgList: Array, //
zoom: {
default: 2, // ,
type: Number
}
},
data() {
return {
middleImgWidth:350,
middleImgHeight:350,
thumbnailHeight:100,
tableLabelTest1:this.tableLabelTest,
pictureList: [
{url: require("../assets/four.png")},
{url: require("../assets/cat.png")},
{url: require("../assets/one.png")},
{url: require("../assets/six.png")},
{url: require("../assets/six.png")},
{url: require("../assets/six.png")},
{url: require("../assets/four.png")},
{url: require("../assets/cat.png")},
{url: require("../assets/one.png")},
{url: require("../assets/six.png")},
{url: require("../assets/six.png")},
{url: require("../assets/six.png")},
],
menu:[],
middleImg: '', //
bigImg: '', //
isShade: false, //
isBig: false, //
initX: 0, // clientX
initY: 0, // clientY
leftX: 0, // left
topY: 0, // top
middleLeft: 0, // left,
itemWidth: 80, //
}
},
watch:{
data:'ifadroind',// methods
inputName: function(newValue) {
this.pictureList=newValue;
this.menu=newValue;
console.log(this.newValue);
}
},
created() {
},
mounted() {
let user= JSON.parse(localStorage.getItem("message"));
console.log(user);
if(user!==null){
this.pictureList=user;
}
if (user && user.length) {
this.pictureList = user
}
this.middleImg = this.pictureList[0].attachmentPath;
console.log(this.middleImg);
// ,4,50
// this.itemWidth = (this.middleImgWidth-30) / 2
this.ifadroind();
this.$nextTick(() => {
console.log(this.menu);
//
const imgWidth = this.middleImgHeight + this.thumbnailHeight + 20
//
// $('.magnify').css({
// width: this.middleImgWidth,
// height: imgWidth
// })
//
$('.middle_img .shade').css({
width: this.middleImgWidth/this.zoom,
height: this.middleImgHeight/this.zoom
})
//
$('.carousel').css({
height: this.thumbnailHeight
})
//
// $('.picture_item').css({
// width: this.itemWidth
// })
// ,left
$('.right_contanier').css({
left: this.middleImgWidth,
width: imgWidth,
height: imgWidth
})
// ()
$('.right_contanier .big_img').css({
width: imgWidth * this.zoom,
height: imgWidth * this.zoom
})
})
},
methods: {
//
ifadroind(){
var sUserAgent = navigator.userAgent.toLowerCase();
var bIsIpad = sUserAgent.match(/ipad/i) == "ipad";
var bIsIphoneOs = sUserAgent.match(/iphone os/i) == "iphone os";
var bIsMidp = sUserAgent.match(/midp/i) == "midp";
var bIsUc7 = sUserAgent.match(/rv:1.2.3.4/i) == "rv:1.2.3.4";
var bIsUc = sUserAgent.match(/ucweb/i) == "ucweb";
var bIsAndroid = sUserAgent.match(/android/i) == "android";
var bIsCE = sUserAgent.match(/windows ce/i) == "windows ce";
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
if ((bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
//Mob Screen
}else{
//PC screen size
this.middleImgWidth=560;
this.middleImgHeight=560;
}
$('.middle_img').css({
width: this.middleImgWidth,
height: this.middleImgHeight
})
},
// ,,
boxMouseOver (e) {
e.preventDefault();
e.stopPropagation();
this.isShade = true
this.isBig = true
//
let x = e.offsetX - $('.shade').width()/2
let y = e.offsetY - $('.shade').height()/2
let maxLeft = $('.middle_img').width() - $('.shade').width()
let maxTop = $('.middle_img').height() - $('.shade').height()
x = x <= 0 ? 0 : x
x = x >= maxLeft ? maxLeft : x
y = y <= 0 ? 0 : y
y = y >= maxTop ? maxTop : y
$('.shade').css({
left: x,
top: y
})
},
//
shadeMouseMove (e) {
e.preventDefault();
e.stopPropagation();
//x - offsetLeft -
var x = this.getEventPage(e).pageX - $('.middle_img')[0].offsetParent.offsetLeft - $('.middle_img')[0].offsetParent.clientLeft;
//y - offsetTop -
var y = this.getEventPage(e).pageY - $('.middle_img')[0].offsetParent.offsetTop - $('.middle_img')[0].offsetParent.clientTop;
//
x -= $('.shade').width() / 2;
y -= $('.shade').height() / 2;
//
let maxLeft = $('.middle_img').width() - $('.shade').width()
let maxTop = $('.middle_img').height() - $('.shade').height()
x = x <= 0 ? 0 : x
x = x >= maxLeft ? maxLeft : x
y = y <= 0 ? 0 : y
y = y >= maxTop ? maxTop : y
//
$('.shade').css({
left: x,
top: y
})
// ,
// x:/ y: /,
const xRate = $('.big_img').width() / $('.middle_img').width()
const yRate = $('.big_img').height() / $('.middle_img').height()
$('.big_img').css({
left: -x*xRate,
top: -y*yRate
})
// console.log(e, x, y, xRate, yRate, 66677)
},
// ,
shadeMouseOver (e) {
e.preventDefault();
e.stopPropagation();
// console.log(88888, e)
},
//
boxMouseLeave () {
this.isShade = false
this.isBig = false
},
//
tabPicture (item,index) {
this.middleImg = item.attachmentPath
this.$emit('changeName',item)
console.log(item,index)
},
//
leftArrowClick () {
if (this.middleLeft < 0) {
//
this.middleLeft += this.itemWidth
$('.picture_container').animate({
left: this.middleLeft
}, 500)
}
},
//
rightArrowClick () {
// ,(-1)*
if (this.middleLeft > -this.itemWidth*(this.pictureList.length-1)) {
this.middleLeft -= this.itemWidth
$('.picture_container').animate({
left: this.middleLeft
}, 500)
}
},
/**
* 获取网页滚出去的距离包括上面滚出去的部分和左边滚出去的部分
* @returns {{scrollTop: (Number|number), scrollLeft: (Number|number)}}
*/
getPageScroll() {
return {
scrollTop: window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0,
scrollLeft: window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft || 0
}
},
/**
* 获取事件对象点击的点相对于文档左上角的坐标
* @param e
* @returns {{pageX: *, pageY: *}}
*/
getEventPage(e) {
return {
pageX: e.clientX + this.getPageScroll().scrollLeft,
pageY: e.clientY + this.getPageScroll().scrollTop
}
}
}
}
</script>
<style lang="less" scoped>
@import url("../assets/css/magnifier.less");
</style>

View File

@ -101,11 +101,6 @@
<a href="javascript:;" data-modal-trigger="modal-whereToBuy" onclick='bindTracking(this)' evt-name='页内弹窗' evt-cat='footererBtnClick' evt-val='在哪购买' class="rc-btn rc-btn--inverse rc-btn--icon-label rc-icon rc-bag--xs rc-brand3" title="Where to buy" role="menuitem">
在哪购买
</a>
<!--
<a class="rc-btn rc-btn--inverse rc-btn--icon-label rc-icon rc-language--xs rc-brand3" role="menuitem" data-modal-trigger="country-lang-selector">
Language
</a>
-->
<a class="rc-btn rc-btn--inverse rc-btn--icon-label rc-icon rc-up--xs rc-brand3" role="menuitem" href="#">
回到顶部
</a>
@ -149,15 +144,15 @@
<div class="ts-row-body">
<p>
<a href="https://weibo.com/chinaroyalcanin" target='_blank' class="rc-img--round rc-img--round--sm rc-margin-right--xs">
<img src='#profiles/custom/royal_canin_profile/themes/royal_canin/images/ico-weibo.png'>
<img src='/images/ico-weibo.png'>
</a>
<a href="https://www.zhihu.com/org/huang-jia-chong-wu-shi-pin" target='_blank' class="rc-img--round rc-img--round--sm rc-margin-right--xs">
<img src='#profiles/custom/royal_canin_profile/themes/royal_canin/images/ico-zhihu.png'>
<img src='/images/ico-zhihu.png'>
</a>
<a href="https://space.bilibili.com/2136859062" target='_blank' class="rc-img--round rc-img--round--sm rc-margin-right--xs">
<img src='#profiles/custom/royal_canin_profile/themes/royal_canin/images/ico-bilibili.png'>
<img src='/images/ico-bilibili.png'>
</a>
</p>
</div>
@ -176,7 +171,7 @@
<div class="rc-four-column rc-layout-container">
<div class="rc-column ts-qr-container rc-text--center">
<a href="weixin://dl/business/?t=xjjEG3b5Ycu" target='_blank' onclick='return bindTracking(this,2000)' evt-name='页脚跳转' evt-cat='footerLinkClick' evt-val='产品验证'>
<img src="#profiles/custom/royal_canin_profile/themes/royal_canin/images/qrcode-chanpin.jpg">
<img src="/images/qrcode-chanpin.jpg">
<span>
产品验证
</span>
@ -185,7 +180,7 @@
<div class="rc-column ts-qr-container rc-text--center">
<a href="weixin://dl/business/?t=BE1OA2AngRs" target='_blank' onclick='return bindTracking(this,2000)' evt-name='页脚跳转' evt-cat='footerLinkClick' evt-val='皇家爱宠荟会员中心'>
<img src="#profiles/custom/royal_canin_profile/themes/royal_canin/images/qrcode-aichong.jpg">
<img src="/images/qrcode-aichong.jpg">
<span>
皇家爱宠荟会员中心
</span>
@ -193,7 +188,7 @@
</div>
<div class="rc-column ts-qr-container rc-text--center">
<img src="#profiles/custom/royal_canin_profile/themes/royal_canin/images/qrcode-royal-elite.jpg">
<img src="/images/qrcode-royal-elite.jpg">
<span class='rc-text-center'>
皇家兽医精英荟
</span>
@ -201,7 +196,7 @@
<div class="rc-column ts-qr-container rc-text--center">
<a href="https://v.douyin.com/e12mtGA/" target='_blank'>
<img src="#profiles/custom/royal_canin_profile/themes/royal_canin/images/qrcode-douyin.jpg">
<img src="/images/qrcode-douyin.jpg">
<span>
皇家宠物食品抖音官方账号
</span>

View File

@ -38,6 +38,7 @@ export default {
css: [
'vant/lib/index.css',
'element-ui/lib/theme-chalk/index.css',
{src:'@/assets/css/global.less'},
{src:'@/assets/css/royalcanin-custom.css'},
{ src: "swiper/css/swiper.css" }
@ -76,7 +77,10 @@ export default {
},
// Build Configuration: https://go.nuxtjs.dev/config-build
build: {
analyze: true,
assetFilter: function(assetFilename) {
return assetFilename.endsWith('.js');
}
},
// axios: {
// proxy: true,

File diff suppressed because it is too large Load Diff

View File

@ -16,20 +16,17 @@
},
"dependencies": {
"@nuxtjs/axios": "^5.13.6",
"@vant/touch-emulator": "^1.3.2",
"amfe-flexible": "^2.2.1",
"core-js": "^3.15.1",
"element-ui": "^2.15.6",
"ip": "^1.1.5",
"jquery": "^3.6.0",
"less": "^4.1.2",
"less-loader": "^6.0.0",
"nuxt": "^2.15.7",
"nuxt-tailvue": "^1.0.95",
"qrcodejs2": "^0.0.2",
"swiper": "^5.4.5",
"vant": "^2.12.22",
"vue-awesome-swiper": "^4.1.1",
"vuex-persistedstate": "^4.1.0"
"vuex-persistedstate": "^4.1.0",
"vue-awesome-swiper": "^4.1.1"
},
"devDependencies": {
"@vant/area-data": "^1.1.5",

View File

@ -4,30 +4,22 @@
<div>
<!-- Suppose in header end -->
<Myheader></Myheader>
<div class="rc-top"></div>
<unlogin></unlogin>
<!-- Suppose in header end -->
<van-swipe :autoplay="3000">
<van-swipe-item v-for="(banner, index) in banners" :key="index">
<van-swipe :autoplay="3000" class="rc-padding-bottom--md">
<van-swipe-item v-for="(banner, index) in showingBanners" :key="index">
<img :src="banner.src" class="useraimg"/>
</van-swipe-item>
</van-swipe>
<div class="online bold rc-md-down" id="fixed-catbar-seperator"></div>
<!-- <div v-swiper:mySwiper="swiperOption" class="swiperWrap">
<div class="swiper-wrapper">
<div class="swiper-slide" v-for="(banner,index ) in banners" :key="index">
<img :src="banner.src">
</div>
</div>
<div class="swiper-pagination swiper-pagination-bullets"></div>
</div> -->
<div class="rc-max-width--xl">
<div class="usermain">
<div :class="searchBar?'rc-ma':'rc-ma searchBara'">
<div v-if="!searchBar" class="online bold rc-md-down"></div>
<ul class="ul-zhuan rc-margin-y--xl">
<ul class="ul-zhuan rc-margin-y--md">
<li
v-for="(item, index) in discountlist"
:key="index"
@ -70,7 +62,7 @@
<div class="rc-click" @click="selectproduce(item,index)">
<div class="uservideo">
<video width="300px" height="251" controls="controls">
<source :src= item.video type="video/ogg" autoplay>
<source :src=item.video type="video/ogg">
</video>
</div>
@ -305,7 +297,7 @@
<div class="rc-click" @click="selectproduce(item,index)">
<div class="uservideo">
<video width="300px" height="251" controls="controls">
<source :src= item.video type="video/ogg" autoplay>
<source :src= item.video type="video/ogg">
</video>
</div>
@ -710,11 +702,9 @@
</template>
<script>
let vm=null;
import $ from 'jquery'
import Myheader from "~/components/header.vue";
import Myfooter from "~/components/rc-footer.vue";
import unlogin from "~/components/unlogin.vue";
import '@vant/touch-emulator';
import { userquery,postCourseId,biaomessage,userque,searchchanpin } from "../ajax/getData";
const settings = require("@/config");
export default {
@ -776,7 +766,6 @@ activeInde3:0,
selection:[
{
title: "幼猫",
},
{
title: "成猫",
@ -786,21 +775,24 @@ activeInde3:0,
},
{
title: "品种猫",
},
{
title: "亚健康",
},
],
banners:[
{src:require("../assets/image/one.jpg"),link:""},
{src:require("../assets/image/two.jpg"),link:""},
{src:require("../assets/image/three.jpg"),link:""},
{src:require("../assets/image/four.jpg"),link:""},
banners:{
'mobile':[
{src:"/images/banner/one.jpg",link:""},
{src:"/images/banner/two.jpg",link:""},
{src:"/images/banner/three.jpg",link:""},
{src:"/images/banner/four.jpg",link:""}
],
'pc':[
{src:"/images/banner/pc-banner1.png",link:""},
{src:"/images/banner/pc-banner2.png",link:""}
]
},
showingBanners:[],
userdoglist: [
{
title: "小型犬",
@ -919,29 +911,29 @@ activeInde3:0,
catlistvideo: [
{
title: "明星猫粮",
video:require("../assets/cat/one.mp4"),
catimage: require("../assets/cat/one.jpg"),
video:"/images/cat/one.mp4",
catimage: "/images/cat/one.jpg",
detail:'为10月龄及以上英国短毛猫成猫量身打造的精准营养',
price:'¥123.45',
},
{
title: "猫湿粮",
video:require("../assets/cat/two.mp4"),
catimage: require("../assets/cat/two.jpg"),
video:"/images/cat/two.mp4",
catimage: "/images/cat/two.jpg",
detail:'为10月龄及以上英国短毛猫成猫量身打造的精准营养',
price:'¥123.45',
},
{
title: "猫干粮",
video:require("../assets/cat/three.mp4"),
catimage: require("../assets/cat/three.jpg"),
video:"/images/cat/three.mp4",
catimage: "/images/cat/three.jpg",
detail:'为10月龄及以上英国短毛猫成猫量身打造的精准营养',
price:'¥123.45',
},
{
title: "猫干粮",
video:require("../assets/cat/four.mp4"),
catimage: require("../assets/cat/four.jpg"),
video:"/images/cat/four.mp4",
catimage: "/images/cat/four.jpg",
detail:'为10月龄及以上英国短毛猫成猫量身打造的精准营养',
price:'¥123.45',
},
@ -951,29 +943,29 @@ activeInde3:0,
doglistvideo: [
{
title: "明星狗粮",
video:require("../assets/dog/one.mp4"),
catimage: require("../assets/dog/one.jpg"),
video:"/images/dog/one.mp4",
catimage: "/images/dog/one.jpg",
detail:'为10月龄及以上成犬量身打造的精准营养',
price:'¥123.45',
},
{
title: "狗湿粮",
video:require("../assets/dog/two.mp4"),
catimage: require("../assets/dog/two.jpg"),
video:"/images/dog/two.mp4",
catimage: "/images/dog/two.jpg",
detail:'为10月龄及以上英国成犬量身打造的精准营养',
price:'¥123.45',
},
{
title: "狗干粮",
video:require("../assets/dog/three.mp4"),
catimage: require("../assets/dog/three.jpg"),
video:"/images/dog/three.mp4",
catimage: "/images/dog/three.jpg",
detail:'为10月龄及以上英国犬成犬量身打造的精准营养',
price:'¥123.45',
},
{
title: "狗干粮",
video:require("../assets/dog/four.mp4"),
catimage: require("../assets/dog/four.jpg"),
video:"/images/dog/four.mp4",
catimage: "/images/dog/four.jpg",
detail:'为10月龄及以上英国成犬量身打造的精准营养',
price:'¥123.45',
},
@ -1002,7 +994,6 @@ activeInde3:0,
title: "皇家英国短毛猫全价湿粮",
price:'¥123.45',
ordernum: 1,
catimage: require("../assets/image/rc-cat.png"),
},
@ -1068,12 +1059,12 @@ activeInde3:0,
},
on: {
slideChange(Swiper) {
console.log('onSlideChangeEnd',this);
//console.log('onSlideChangeEnd',this);
// vm.ifadroind('','',this.realIndex);
vm.useraindex=this.realIndex;
},
tap() {
console.log('onTap', this);
//console.log('onTap', this);
}
// slideChange() {
// console.log('onSlideChangeEnd', this);
@ -1093,21 +1084,14 @@ activeInde3:0,
},
created(){
vm=this;
},
watch:{
},
mounted(){
const that = this
this.ifAdoid()
// window.onresize = () => {
// setTimeout(() => {
// this.ifAdoid()
// }, 500);
// }
this.ifAdoid();
this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
if(this.usermessage==null ||this.usermessage==undefined){
this.userunlogin=true
}
@ -1115,19 +1099,13 @@ vm=this;
this.userchufang();//
this.catmessage();//
this.dogmessage();//
// this.usershi();//
// this.userhot();
},
destroyed () {
window.removeEventListener('scroll', this.scrollToTop);
},
methods:{
ifAdoid(item,index){
console.log(index);
//console.log(index);
this.userindex=index;
var sUserAgent = navigator.userAgent.toLowerCase();
var bIsIpad = sUserAgent.match(/ipad/i) == "ipad";
@ -1140,13 +1118,10 @@ vm=this;
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
console.log("当前是电脑打开")
//console.log("")
this.stypechange=false;
console.log(this.usertitle)
//console.log(this.usertitle)
// let catshiid=document.querySelectorAll('.selectionswitch');
// catshiid[this.userindex].style.display='none';
// catshiid[this.userindex].style.display='none';
this.catproduct=true;
this.onemao=false;
this.twomao=false;
@ -1155,9 +1130,12 @@ vm=this;
this.fivemao=false;
this.sixmao=false;
this.dogshow=false
// console.log(catshiid);
}else{
console.log("当前是手机打开")
this.showingBanners=this.banners.pc;
}
else
{
//console.log("")
this.showingBanners=this.banners.mobile;
this.stypechange=true;
this.onemao=true;
this.twomao=true;
@ -1172,7 +1150,7 @@ vm=this;
},
ifadroind(item,index,order){
console.log(item,index,order);
//console.log(item,index,order);
var sUserAgent = navigator.userAgent.toLowerCase();
@ -1186,7 +1164,7 @@ vm=this;
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
console.log("当前是电脑打开啊啊啊")
//console.log("")
if(item.title=='明星猫粮'){
this.catproduct=true;
this.twomao=false;
@ -1202,7 +1180,7 @@ vm=this;
if(item.title=='猫湿粮'){
this.onemao=true;
this.dogshow=false;
console.log(this.onemao);
//console.log(this.onemao);
this.twomao=false;
this.threemao=false;
this.fourmao=false;
@ -1266,11 +1244,11 @@ vm=this;
this.catfood=true;
// this.catproduct=false;
let userindex=index
console.log(item,index);
//console.log(item,index);
let mingxin=document.querySelector('.pageFullScreen');
let dogtop=document.querySelector('.oc-top');
console.log(dogtop);
console.log(mingxin.offsetTop);
//console.log(dogtop);
//console.log(mingxin.offsetTop);
if(item.title=='犬湿粮'||item.title=='犬干粮'||item.title=='处方用粮'){
userindex=userindex-2
}else{
@ -1292,8 +1270,7 @@ dogtop.scrollIntoView(true);
// this.catfood=false;
// }
console.log("当前是手机打开")
//console.log("")
}
},
userdog(item,index){
@ -1305,7 +1282,7 @@ dogtop.scrollIntoView(true);
for(let i =0;i<this.userserachlist.length;i++){
if(!this.userserachlist.includes(petType)){
this.userserachlist.push(petType)
}
}W
}
this.dogmessage(this.userserachlist)
},
@ -1337,6 +1314,10 @@ dogtop.scrollIntoView(true);
handleScroll(e)
{
let fixedCatbarSeperator = document.getElementById("fixed-catbar-seperator");
if(!fixedCatbarSeperator)
{
return;
}
let scrolltop = document.documentElement.scrollTop || document.body.scrollTop;
if((scrolltop-fixedCatbarSeperator.offsetTop)>0)
{
@ -1492,18 +1473,17 @@ dogtop.scrollIntoView(true);
},
selectGoods(item,index){
console.log(item,index);
//console.log(item,index);
this.activeIndex=index;
console.log(item.title);
//console.log(item.title);
this.ifadroind(item,index,this.useraindex)
// this.ifAdoid(item,index);
},
quanshi(item,index){
console.log(item,index);
//console.log(item,index);
this.activeIndex5=index
console.log(this.activeIndex5);
//console.log(this.activeIndex5);
},
userdoghot(item,index){
this.activeIndex6=index
@ -1513,7 +1493,6 @@ selectGo(item,index){
this.activeInde2=index;
},
selectGoo(item,index){
this.activeInde3=index;
}
},

View File

@ -1,7 +1,8 @@
<template>
<div>
<Myheader></Myheader>
<div class="rc-top"></div>
<div class="rc-main rc-layout-container rc-max-width--lg">
<div class="rc-usermain">
<ul>
<li v-for="(item,index) in userrecord" :key="index">
@ -9,29 +10,23 @@
</li>
</ul>
<ol>
<li v-for="(item,index) in usermessage" :key="index">
<span>{{item.startDate}}</span>
<em>{{item.changeValue}}</em>
<i>{{item.remark}}</i>
</li>
</ol>
</div>
<div class="rc-button">
<div class="rc-order">
<span>积分兑换</span>
</div>
</div>
<Myfooter v-on:litentop='showmesg'></Myfooter>
</div>
</template>
<script>
import Myheader from '~/components/header.vue'
import Myfooter from '~/components/rc-footer.vue'
import { memberAccount } from "../../ajax/getData";
export default {
data(){
@ -108,6 +103,7 @@ export default {
},
components:{
Myheader,
Myfooter
},
}
@ -115,6 +111,4 @@ export default {
<style lang="less" scoped>
@import url("../../assets/css/integral.less");
</style>

View File

@ -1,8 +1,8 @@
<template>
<div>
<Myheader></Myheader>
<tabs></tabs>
<div class="rc-top"></div>
<tabs></tabs>
<div class="rc-layout-container rc-one-column rc-full-width ts-mypersonal">
<div class="rc-column">
<!-- <div class="rc-title">
@ -47,9 +47,8 @@
<div class="rc-cordd">
<span>距离升级还差:</span> <span class="lackOfPoint">{{ rcvalue }}</span>
<div class="block">
<div class="ts-point-tag rc-md-up"></div>
<div class="r-block" ref="userblock"></div>
<!-- <el-slider v-model="value" range show-stops :max="10"> </el-slider> -->
</div>
<div class="rc-value">
<span>0</span>
@ -129,7 +128,7 @@
<MyFooter></MyFooter>
</div>
@ -138,6 +137,7 @@
<script>
import Myheader from '~/components/header.vue'
import MyFooter from '~/components/rc-footer.vue'
import tabs from "@/components/tabs.vue";
export default {
middleware: 'metaTitle',
@ -201,6 +201,7 @@ export default {
},
components: {
Myheader,
MyFooter,
tabs,
},
watch:{
@ -312,7 +313,7 @@ obligation(item,index){
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
console.log("当前是电脑打开")
//console.log("")
if(this.userlog==true){
this.usermessage='关注皇家爱宠荟,修改个人资料',
this.dialogInfo1=true;
@ -322,7 +323,7 @@ obligation(item,index){
}
}else{
console.log("当前是手机打开")
//console.log("")
this.dialogInfo1=false;
}
},
@ -342,8 +343,7 @@ obligation(item,index){
this.$router.push({
path: `/useraddress/openaddress/`
})
console.log('这是地址的跳转');
//console.log('');
}
if(index==0){
this.userlog=true
@ -368,20 +368,18 @@ this.$router.push({
}
},
mounted() {
console.log(this.islogin)
console.log(this.userid);
//console.log(this.islogin)
//console.log(this.userid);
let userwidth=0;
this.ifadroind();
let user= JSON.parse(localStorage.getItem("userInfo"));
console.log(user)
//console.log(user)
if(user!==null){
console.log('11')
//console.log('11')
this.userid=user.data;
console.log(this.userid);
this.usertitle=this.userid.memberName;
this.rcrcord=this.userid.availiblePoint;
if(this.userid.memberLevel==1){
let userlength=this.userid.availiblePoint.toString().length;
this.userimage=require('../../assets/image/rc-new.png');
@ -390,7 +388,7 @@ this.$router.push({
this.rcvalue=this.uservalue-this.userid.availiblePoint; //
if(userlength==1||userlength==2||userlength==3||userlength==4){
userwidth=this.userid.availiblePoint/100
console.log(userwidth);
//console.log(userwidth);
}
}
else if(this.userid.memberLevel==2){
@ -406,8 +404,15 @@ this.$router.push({
userwidth=100
}
this.$refs.userblock.style.width=userwidth+'%'
let tagEle=document.querySelector('.ts-point-tag');
if(tagEle){
tagEle.innerText=this.userid.availiblePoint;
let tagEleLeft=userwidth-1;
if(tagEleLeft<=0)
tagEleLeft=0;
tagEle.style.left=tagEleLeft+"%";
}
} else{
console.log('---');
this.userid=[];
}
@ -415,8 +420,6 @@ this.$router.push({
console.log(this.userid)
this.islogin=true;
}
},

View File

@ -2,14 +2,11 @@
<div>
<div class="user" v-for="(item,index) in newlist" :key="index">
<Myheader></Myheader>
<div class="rc-top"></div>
<unlogin></unlogin>
<tabs></tabs>
<div class="online" ></div>
<div class="rc-top"></div>
<div class="rc-usermain ts-product-detail rc-max-width--xl rc-layout-container rc-two-column rc-border-bottom rc-border-colour--brand4">
<!--
<magnifier v-bind:parentmsg="msg" ></magnifier>
-->
<div class="rc-column">
<div data-js-carousel="" data-image-gallery="true">
<div class="rc-carousel rc-carousel__gallery-image" data-zoom-container="328b2e5f-6904-4cac-9709-51ed18d2500f" data-zoom-factor="2">
@ -47,14 +44,14 @@
</div>
<div class="ts-product-header rc-column" id="328b2e5f-6904-4cac-9709-51ed18d2500f">
<div class="usermain">
<div class="usermain fixed-catbar-seperator">
<div class="online bold rc-md-down"></div>
<div class="rc-main">
<div class="rc-title">
<h2>{{ item.productName }}</h2>
</div>
</div>
<div class="online rc-md-down"></div>
<div class="online rc-md-down" id="fixed-catbar-seperator"></div>
<div class="rc-main">
<div class="productdetails">
<div class="rc-productdetail">
@ -223,7 +220,6 @@
<script>
import Myheader from "~/components/header.vue";
import magnifier from "@/components/magnifier.vue";
import tabs from "@/components/tabs.vue";
import unlogin from "~/components/unlogin.vue";
import { mapMutations } from "vuex";
@ -320,7 +316,6 @@ export default {
components: {
Myheader,
tabs,
magnifier,
unlogin,
Myfooter
@ -334,19 +329,14 @@ this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
console.log(this.productCode)
this.userquery(this.productCode);
console.log(this.userlistmenu)
this.$nextTick(()=>{
})
this.$nextTick(()=>{})
if(stype==1){
this.userbuy=true;
}else if(stype==2){
console.log('这是要消失的')
this.$nextTick(() => {
this.userbuy=false;
})
}
}
@ -357,6 +347,10 @@ this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
handleScroll(e)
{
let fixedCatbarSeperator = document.getElementById("fixed-catbar-seperator");
if(!fixedCatbarSeperator)
{
return;
}
let scrolltop = document.documentElement.scrollTop || document.body.scrollTop;
if((scrolltop-fixedCatbarSeperator.offsetTop))
{
@ -549,13 +543,11 @@ if(this.usermessage.data!==''||this.usermessage.data!==undefined){
console.log(data);
},
usertanchu(item,orderm){
let user= localStorage.getItem("userInfo");
if(user==undefined||user==null||user==''){
this.dialogInfo2=true;
return
}else{
this.courseId(item);
if(orderm==0){
this.$message({
@ -569,12 +561,7 @@ usertanchu(item,orderm){
});
}
}
},
userget(){

View File

@ -466,13 +466,27 @@ export default {
openclose(){
this.dialogInfo1=false;
},
selectproduce(){
selectproduce(item){
if(item.productList[0]==undefined){
item.productlist[0].productCode=0;
}
if(item.productList[0]==undefined){
item.productlist[0]=[];
}
this.$router.push({
path: "/productdetails/producted",
query: {
stype: 1,
productCode:item.productList[0].productCode
},
});
// this.$router.push({
// path: "/productdetails/producted",
// query: {
// stype: 1,
// }
// });
},
ifadroind(){
var sUserAgent = navigator.userAgent.toLowerCase();
@ -486,7 +500,7 @@ this.dialogInfo1=false;
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
console.log("当前是电脑打开")
//console.log("")
this.$nextTick(() => {
this.isadrond=false;
@ -498,7 +512,7 @@ this.dialogInfo1=false;
}else{
console.log("当前是手机打开")
//console.log("")
this.$nextTick(() => {
this.isadrond=true;
@ -600,7 +614,6 @@ this.dialogInfo1=false;
this.userserachlist.push(categoryName)
}
}
this.usersearch(this.userserachlist)
},

View File

@ -1,8 +1,7 @@
// <!-- -->
<template>
<div class="container rc-full-width">
<Myheader></Myheader>
<div class="rc-top"></div>
<div class="content ts-max-width--460">
<h2 class="rc-beta rc-text--center">账号注册</h2>
@ -117,12 +116,12 @@ export default {
loading:false,
usertitle:true,
gender: '',
inRank:false
inRank:false,
ifpassword:false
};
},
components: {
// Myheader,
Myheader,
},
computed: {
usertel () {
@ -143,19 +142,6 @@ export default {
return ''
}
},
// test () {
// if (this.sms === ""){
// return ''
// }else if(this.sms.length !== 5){
// return ''
// }else {
// return ''
// }
// }
},
components: {
},
mounted(){
},
@ -165,32 +151,26 @@ export default {
//
async usermsg() {
console.log("-----");
//console.log("-----");
let data = await sendMsg(this.tel);
if(data){
console.log(data);
this.captchadata=data.msgNum;
//console.log(data);
//this.captchadata=data.msgNum;
this.tamp=data.tamp;
this.hash=data.hash;
}
},
//
async vadmsg() {
console.log("-----");
let data = await vadatnmsg(this.captchadata,this.hash,this.tamp);
//console.log("-----");
let data = await vadatnmsg(this.sms,this.hash,this.tamp);
if(data){
console.log(data);
if(!data.code==1){
return false
return data;
}
}
},
checkBox(){
console.log(event.target.checked)
//console.log(event.target.checked)
this.usercheckbox=event.target.checked
},
@ -201,7 +181,7 @@ export default {
if(data){
console.log(data);
}
console.log(data);
//console.log(data);
},
//
sendCode () {
@ -242,13 +222,13 @@ export default {
return
}
if(this.sms!==this.captchadata){
this.$message({
type: 'warning',
message: '验证码输入有误请重新输入'
});
return
}
// if(this.sms!==this.captchadata){
// this.$message({
// type: 'warning',
// message: ''
// });
// return
// }
if(this.sms==''){
this.$message({
type: 'warning',
@ -261,7 +241,7 @@ export default {
console.log('----');
this.$message({
type: 'warning',
message: '请先勾选'
message: '请先同意隐私声明和账号使用协议'
});
if (!/^[1][3,4,5,7,8][0-9]{9}$/.test(this.tel) || this.tel === "") {
this.$message({
@ -273,30 +253,31 @@ export default {
}
}
else{
let user= JSON.parse(localStorage.getItem("userInfo"));
console.log(this.tel);
let data=await useredit(this.tel);
this.vadmsg();
//let user= JSON.parse(localStorage.getItem("userInfo"));
let data = await this.vadmsg();
if(data.code=="1")
{
data=await useredit(this.tel);
if(data.code=='1'){
let couponId='0000000123';
this.serdiscount(this.tel,couponId);
setTimeout(() => {
this.serdiscount(this.tel,"0000000140");
}, 100);
setTimeout(() => {
this.serdiscount(this.tel,"0000000122");
}, 500);
this.$router.push({
path: "/",
});
return;
}
}
this.$message({
type: 'warning',
message: data.msg
});
if(data){
let couponId='0000000123';
this.serdiscount(user.data.mobile,couponId);
setTimeout(() => {
this.serdiscount(user.data.mobile,"0000000140");
}, 100);
setTimeout(() => {
this.serdiscount(user.data.mobile,"0000000122");
}, 500);
}
return
}

View File

@ -1,7 +1,7 @@
<template>
<div class="container rc-full-width">
<Myheader></Myheader>
<div class="rc-top"></div>
<div class="content ts-max-width--460">
<h2 class="rc-beta rc-text--center">{{ usertitle ? "账号登录" : "" }}</h2>
<!-- Deprecated : No tab switching as no password
@ -15,7 +15,6 @@
>
</div>
-->
<div class="rc-layout-container rc-one-column">
<div class="rc-column">
<input
@ -146,7 +145,7 @@ export default {
swiperData: [
// { index: 1 ,title:''},
// { index: 2 ,title:''},
],
]
};
},
components: {
@ -181,10 +180,8 @@ export default {
}
},
},
components: {},
mounted() {
console.log(this.$route.params);
//console.log(this.$route.params);
},
// watch: function () {
// console.log(this.inRank);
@ -195,16 +192,15 @@ export default {
checkBox(){
console.log(event.target.checked)
this.usercheckbox=event.target.checked
},
//
async usermsg() {
console.log("-----");
//console.log("-----");
let data = await sendMsg(this.tel);
if(data){
console.log(data);
this.captchadata=data.msgNum;
//this.captchadata=data.msgNum;
this.tamp=data.tamp;
this.hash=data.hash;
}
@ -213,16 +209,11 @@ export default {
//
async vadmsg() {
console.log("-----");
let data = await vadatnmsg(this.captchadata,this.hash,this.tamp);
//console.log("-----");
let data = await vadatnmsg(this.sms,this.hash,this.tamp);
if(data){
console.log(data.code);
if(!data.code==1){
return false
return data;
}
}
},
onClickHander(e) {
console.log(e);
@ -239,7 +230,7 @@ export default {
},
//
useredd() {
console.log("---注册账户");
//console.log("---");
this.usertitle = false;
},
@ -287,15 +278,6 @@ export default {
message: '手机号码输入有误'
});
return
}
if(this.sms!==this.captchadata){
this.$message({
type: 'warning',
message: '验证码输入有误请重新输入'
});
return
}
if(this.sms==''){
this.$message({
@ -304,12 +286,11 @@ export default {
});
return
}
console.log(this.usercheckbox);
if(this.usercheckbox==false){
console.log('----');
//console.log('----');
this.$message({
type: 'warning',
message: '请先勾选'
message: '请先同意隐私声明和账号使用协议'
});
if (!/^[1][3,4,5,7,8][0-9]{9}$/.test(this.tel) || this.tel === "") {
this.$message({
@ -321,61 +302,33 @@ export default {
}
}
else{
console.log(this.tel);
let data = await userLongin(this.tel);
console.log(data);
this.vadmsg();
let data=await this.vadmsg();
if(data.code=="1")
{
data = await userLongin(this.tel);
if(data.msg=='SUCCESS'){
this.$message({
type: 'warning',
message: '登录成功'
});
if(data.msg=='SUCCESS'){
this.$router.push({
path: "/",
});
let token=JSON.stringify(data);
this.changeClod({ cloud: token });
}else{
return;
}
}
this.$message({
type: 'warning',
message: data.msg
});
}
return
}
},
// reallR () {
// this.zhud=true
// this.loading=true
// axios.post('https://www.daxunxun.com/users/register', {
// username: this.tel,
// password: this.password
// }).then(res=>{
// this.zhud=false
// this.loading=false
// if (res.data === 2) {
// Toast('')
// } else if (res.data === 0) {
// Toast('')
// } else {
// Toast('')
// }
// })
// }
}},
},
};
</script>
<style lang="less" scoped>
@import url("../../assets/css/global.less");
@import url("../../assets/css/login.less");
</style>

View File

Before

Width:  |  Height:  |  Size: 85 KiB

After

Width:  |  Height:  |  Size: 85 KiB

View File

Before

Width:  |  Height:  |  Size: 170 KiB

After

Width:  |  Height:  |  Size: 170 KiB

View File

Before

Width:  |  Height:  |  Size: 117 KiB

After

Width:  |  Height:  |  Size: 117 KiB

View File

Before

Width:  |  Height:  |  Size: 136 KiB

After

Width:  |  Height:  |  Size: 136 KiB

View File

Before

Width:  |  Height:  |  Size: 1.0 MiB

After

Width:  |  Height:  |  Size: 1.0 MiB

View File

Before

Width:  |  Height:  |  Size: 286 KiB

After

Width:  |  Height:  |  Size: 286 KiB

View File

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

View File

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 31 KiB

View File

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

View File

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 25 KiB

View File

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 31 KiB

View File

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

View File

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

View File

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 25 KiB

View File

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 23 KiB

View File

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 20 KiB

View File

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 24 KiB

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

View File

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

View File

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 31 KiB

View File

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

View File

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 25 KiB