Merge remote-tracking branch 'origin/master'

zhc4dev
赵玉瑞 2 years ago
commit 95246a5541
  1. 8
      ant-design-vue-jeecg/src/config/router.config.js
  2. 2
      ant-design-vue-jeecg/src/permission.js
  3. 4
      ant-design-vue-jeecg/src/views/shopping/components/Header/HeaderView.vue
  4. 518
      ant-design-vue-jeecg/src/views/shopping/pages/chengyi.vue
  5. 28
      ant-design-vue-jeecg/src/views/shopping/pages/gerenzhongxin.vue
  6. 34
      ant-design-vue-jeecg/src/views/shopping/pages/news.vue
  7. 149
      ant-design-vue-jeecg/src/views/shopping/shopHome.vue

@ -652,4 +652,12 @@ export const constantRouterMap = [
path: '/shopping/order',//这里是你需要设置新窗口打开的页面的路径s
component: () => import('@/views/shopping/pages/orderDetails'),
},
{
path: '/shopping/chengyi',//这里是你需要设置新窗口打开的页面的路径s
component: () => import('@/views/shopping/pages/chengyi'),
},
{
path: '/shopping/news',//这里是你需要设置新窗口打开的页面的路径s
component: () => import('@/views/shopping/pages/news'),
},
]

@ -19,7 +19,7 @@ const whiteList = ['/user/login','/userequip/loginequip','/user/sgin',
'/sckz/sckzzxt','/sbjm/sbjmsjkzxt','/jxgl/jxglsjkzxt','/szls/szlssjkzxt','/jxdsj/jxdsjzszxt',
'/ybgl/ybglsjkzxt','/mflgl/mflglsjkzxt','/ddcl/ddclzxt','/ddgl/ddglzxt','/dyhsc/dyhsczxt','/znyy/znyysczhgkzzrj',
'/znyyjc/znyycjrjxt','/gdgz/gdgzzxt','/shopping/shopHome','/shopping/clothType','/shopping/sirendingzhi',
'/shopping/ClothDetail','/shopping/person','/shopping/person','/shopping/order'] // no redirect whitelist
'/shopping/ClothDetail','/shopping/person','/shopping/person','/shopping/order','/shopping/chengyi','/shopping/news'] // no redirect whitelist
router.beforeEach((to, from, next) => {
NProgress.start() // start progress bar

@ -12,10 +12,10 @@
<router-link to="/shopping/sirendingzhi" :style="{ color: fontColor }"
>私人定制</router-link
>
<router-link to="cytj" :style="{ color: fontColor }"
<router-link to="/shopping/chengyi" :style="{ color: fontColor }"
>成衣推荐</router-link
>
<router-link to="about" :style="{ color: fontColor }"
<router-link to="/shopping/news" :style="{ color: fontColor }"
>关于我们</router-link
>
</div>

@ -0,0 +1,518 @@
<template>
<!-- 服装类型-->
<div class="chengyi">
<Header fontColor="#000"></Header>
<div class="main">
<div class="jz d-flex">
<el-menu
class="el-menu-vertical-demo"
@select="handleSelet"
style="width: 10%; min-width: 140px"
:unique-opened="true"
>
<el-submenu v-for="(item, i) in typeData" :key="i" :index="item.id">
<template slot="title">
<i class="el-icon-male"></i>
<span>{{ item.name }}</span>
</template>
<el-submenu v-for="(j, i2) in item.childrens" :key="i2" :index="j.id">
<template slot="title">{{ j.name }}</template>
<el-menu-item v-for="(k, i3) in j.childrens" :key="i3" :index="k.id">{{ k.name }}</el-menu-item>
</el-submenu>
</el-submenu>
</el-menu>
<div class="right">
<div class="name d-flex">
<span>{{this.current.name}}</span>
<div class="d-flex">
<el-dropdown @command="handleCommand">
<span class="el-dropdown-link">
排序<i class="el-icon-arrow-down el-icon--right"></i>
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="heat">热度</el-dropdown-item>
<!-- <el-dropdown-item command="esteem">评分</el-dropdown-item>-->
<el-dropdown-item command="high">价格降序</el-dropdown-item>
<el-dropdown-item command="low">价格升序</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<!-- <div class="iconDiv d-flex">-->
<!-- <span>价格</span>-->
<!-- <div class="icon d-flex">-->
<!-- <i class="el-icon-arrow-up"></i>-->
<!-- <i class="el-icon-arrow-down"></i>-->
<!-- </div>-->
<!-- </div>-->
</div>
</div>
<div class="clothDiv d-flex">
<div
class="item"
v-for="(item, index) in clothsList"
:key="index"
@click="clothDetails(item)"
>
<div class="imgDiv">
<img :src="item.imgUrl" alt="" />
</div>
<div class="clothTitle">
<p class="price d-flex">
<span class="f_16 c_333">{{ item.currentPrice }}</span>
<span class="f_12 c_999">{{ item.historicalPrice }}</span>
</p>
<p class="f_12 c_333">{{ item.title }}</p>
<p class="f_12 c_9a9b9b">热度{{ item.heat }}</p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import Header from '../components/Header/HeaderView'
let compareDown = function (prop) {
return function (obj1, obj2) {
var val1 = obj1[prop];
var val2 = obj2[prop];
if (val1 < val2) {
return 1;
} else if (val1 > val2) {
return -1;
} else {
return 0;
}
}
}
let compareUp = function (prop) {
return function (obj1, obj2) {
var val1 = obj1[prop];
var val2 = obj2[prop];
if (val1 < val2) {
return -1;
} else if (val1 > val2) {
return 1;
} else {
return 0;
}
}
}
export default {
name:"chengyi",
components: {Header},
data() {
return {
//
clothsList: [
{
id: 1,
imgUrl: require("../assets/cloth.png"),
currentPrice: 199,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3100,
},
{
id: 2,
imgUrl: require("../assets/cloth.png"),
currentPrice: 299,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3200,
},
{
id: 3,
imgUrl: require("../assets/cloth.png"),
currentPrice: 399,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3300,
},
{
id: 4,
imgUrl: require("../assets/cloth.png"),
currentPrice: 499,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3400,
},
{
id: 5,
imgUrl: require("../assets/cloth.png"),
currentPrice: 599,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3500,
},
{
id: 6,
imgUrl: require("../assets/cloth.png"),
currentPrice: 699,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3600,
},
{
id: 7,
imgUrl: require("../assets/cloth.png"),
currentPrice: 599,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3700,
},
{
id: 8,
imgUrl: require("../assets/cloth.png"),
currentPrice: 599,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3800,
},
{
id: 9,
imgUrl: require("../assets/cloth.png"),
currentPrice: 599,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat: 3900,
},
{
id: 10,
imgUrl: require("../assets/cloth.png"),
currentPrice: 599,
historicalPrice: 799,
title: "HOODIE 运动长袖连帽卫衣套头衫",
heat:4000,
},
],
//
typeData: [
{
id: '1',
name: "男装",
childrens: [
{
id: '11',
name: "上衣",
childrens: [
{
id: '111',
name: "衬衫",
},
{
id: '112',
name: "卫衣",
},
{
id: '113',
name: "Polo衫",
},
{
id: '114',
name: "针织衫",
},
],
},
{
id: '12',
name: "外套",
childrens: [
{
id: '121',
name: "夹克",
},
{
id: '122',
name: "羽绒服",
},
{
id: '123',
name: "风衣",
},
],
},
{
id: '13',
name: "裤子",
childrens: [
{
id: '131',
name: "休闲裤",
},
{
id: '132',
name: "西裤",
},
{
id: '133',
name: "工装裤",
},
{
id: '134',
name: "运动裤",
},
{
id: '135',
name: "卫裤",
},
{
id: '136',
name: "九分裤",
},
{
id: '137',
name: "短裤",
},
{
id: '138',
name: "哈伦裤",
},
],
},
],
},
{
id: '2',
name: "女装",
childrens: [
{
id: '21',
name: "上衣",
childrens: [
{
id: '211',
name: "衬衫",
},
{
id: '212',
name: "卫衣",
},
{
id: '213',
name: "Polo衫",
},
{
id: '214',
name: "针织衫",
},
],
},
{
id: '22',
name: "外套",
childrens: [
{
id: '221',
name: "夹克",
},
{
id: '222',
name: "羽绒服",
},
{
id: '223',
name: "风衣",
},
],
},
{
id: '23',
name: "裤子",
childrens: [
{
id: '231',
name: "休闲裤",
},
{
id: '232',
name: "西裤",
},
{
id: '233',
name: "工装裤",
},
{
id: '234',
name: "运动裤",
},
{
id: '235',
name: "卫裤",
},
{
id: '236',
name: "九分裤",
},
{
id: '237',
name: "短裤",
},
{
id: '238',
name: "哈伦裤",
},
],
},
],
},
],
//
current:{
id:'',
name:''
}
};
},
methods: {
findIndex(indexPath){
const indexa = this.typeData.findIndex((value, keys, arr) => {
return value.id == indexPath[0]
})
const indexb = this.typeData[indexa].childrens.findIndex((value, keys, arr) => {
return value.id == indexPath[1]
})
const indexc = this.typeData[indexa].childrens[indexb].childrens.findIndex((value, keys, arr) => {
return value.id == indexPath[2]
})
this.current.name = this.typeData[indexa].childrens[indexb].childrens[indexc].name
this.current.id = this.typeData[indexa].childrens[indexb].childrens[indexc].id
},
handleSelet(index,indexPath){
this.findIndex(indexPath)
},
clothDetails(item) {
this.$router.push({
path: "/shopping/ClothDetail",
query: { id: item.id, title: item.title },
});
},
handleCommand(command){
if(command == 'heat'){//
this.clothsList.sort(compareDown("heat"))
}
else if(command == 'high'){//
this.clothsList.sort(compareDown("currentPrice"))
}
// else if(command == 'esteem'){//
// this.clothsList.sort(compare("heat"))
// }
else if(command == 'low'){//
this.clothsList.sort(compareUp("currentPrice"))
}
}
},
}
</script>
<style scoped>
@import '../assets/common.css';
</style>
<style>
.chengyi .top .middle .router-link-exact-active.router-link-active {
border-bottom: 2px solid #000;
}
</style>
<style lang="less" scoped>
.chengyi {
.main {
padding-top: 100px;
.right {
width: 90%;
padding-left: 20px;
min-width: 1290px;
box-sizing: border-box;
.name {
height: 22px;
font-size: 22px;
line-height: 22px;
justify-content: space-between;
align-items: center;
color: #000;
margin-bottom: 20px;
.d-flex {
align-items: center;
.el-dropdown {
margin-right: 20px;
.el-dropdown-link {
color: #000;
cursor: pointer;
}
}
.iconDiv {
justify-content: space-between;
align-items: center;
font-size: 14px;
span {
margin-right: 5px;
}
.icon {
flex-direction: column;
align-items: center;
justify-content: center;
i {
font-size: 7px;
}
}
}
}
}
.clothDiv {
flex-wrap: wrap;
align-items: center;
.item {
width: 308px;
height: 562px;
margin-bottom: 30px;
margin-right: 10px;
.imgDiv {
position: relative;
img {
width: 308px;
height: 462px;
}
&:hover .button {
opacity: 1;
color: #fff;
}
.button {
position: absolute;
opacity: 0;
transition: all 0.3s linear;
width: 152px;
height: 51px;
line-height: 51px;
background: #000000;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
text-align: center;
}
}
.clothTitle {
width: 100%;
height: 100px;
.price {
align-items: center;
padding-left: 6px;
.f_16 {
margin-right: 10px;
}
.f_12 {
text-decoration: line-through;
}
}
& > .f_12 {
font-weight: 600;
}
}
}
}
}
}
}
</style>

@ -13,24 +13,27 @@
<a-menu-item key="mail"> 我的账户 </a-menu-item>
<a-menu-item key="collect"> 我的收藏 </a-menu-item>
<a-menu-item key="addr"> 地址管理 </a-menu-item>
<a-sub-menu>
<a-sub-menu key="invoice">
<span slot="title" class="submenu-title-wrapper">发票管理<a-icon type="down" /></span>
<a-menu-item key="invoice:1">
<a-menu-item key="invoice1">
Option 1
</a-menu-item>
<a-menu-item key="invoice:2">
<a-menu-item key="invoice2">
Option 2
</a-menu-item>
<a-menu-item key="invoice:3">
<a-menu-item key="invoice3">
Option 3
</a-menu-item>
<a-menu-item key="invoice:4">
<a-menu-item key="invoice4">
Option 4
</a-menu-item>
</a-sub-menu>
<a-sub-menu>
<span slot="title" class="submenu-title-wrapper">全部订单<a-icon type="down" /></span>
<a-menu-item key="allorders">
全部订单
</a-menu-item>
<a-menu-item key="daizhifu">
待支付
</a-menu-item>
@ -46,7 +49,7 @@
</a-sub-menu>
</a-menu>
<div class="orderList">
<div class="orderList" >
<div class="item" v-for="(item,index) in allOrders" :key="index">
<div class="top d-flex">
<span>订单编号{{item.orderNum}}</span>
@ -91,7 +94,7 @@
data() {
return {
current: ['mail'],
allOrders:[
allOrders1:[
{
id:1,
orderNum:'CN172839729',
@ -119,6 +122,7 @@
total:5912
}
],
allOrders:[],
};
},
@ -127,8 +131,14 @@
console.log(key);
},
menuChange(key){
if(key == daizhifu){
// this.allOrders.forEach()
this.current.shift()
this.current.push(key.key)
console.log(this.allOrders)
if(key.key == 'allorders'){
console.log('----')
this.allOrders = this.allOrders1
console.log(this.allOrders)
}
}
},

@ -0,0 +1,34 @@
<template>
<div class="news">
<Header fontColor="#000"></Header>
<div style="padding-top: 88px">
新闻页面
</div>
<Footer></Footer>
</div>
</template>
<script>
import Header from "../components/Header/HeaderView";
import Footer from "../components/Footer/FooterView"
export default {
name: "news",
components: { Header,Footer },
data() {
return {
};
},
methods: {
},
};
</script>
<!--<style>-->
<!-- .news .top .middle .router-link-exact-active.router-link-active {-->
<!-- border-bottom: 2px solid #000;-->
<!-- }-->
<!--</style>-->
<style lang="less" scoped>
@import '../assets/common.css';
</style>

@ -87,6 +87,10 @@
<p class="box2">15分钟前定制</p>
</div>
</a-carousel>
<div class="more d-flex" style="padding-top: 20px">
<a href="#">更多西装</a>
<img src="./assets/youjiantou.png" alt="" />
</div>
<!-- <el-carousel type="card" arrow="always">-->
<!-- <el-carousel-item v-for="(item, index) in clothList2" :key="index">-->
<!-- <div class="box">-->
@ -110,7 +114,7 @@
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in nanzhuang1"
v-for="(item, index) in nanzhuang"
:key="index"
>
<img :src="item.imgUrl" alt="" />
@ -129,32 +133,7 @@
</div>
</div>
<div class="more d-flex">
<a href="#">更多衬衫</a>
<img src="./assets/youjiantou.png" alt="" />
</div>
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in nanzhuang2"
:key="index"
>
<img :src="item.imgUrl" alt="" />
<p>
{{ item.title1 }}<span class="line">|</span>{{ item.title1 }}
</p>
<div>
<el-tag type="warning" size="small">{{ item.tag1 }}</el-tag
><el-tag type="warning" size="small">{{ item.tag2 }}</el-tag>
</div>
<p class="priceDiv d-flex">
<span class="f_18"
><span class="f_24">{{ item.price }}</span></span
><span class="f_12">已售{{ item.sold }}</span>
</p>
</div>
</div>
<div class="more d-flex">
<a href="#">更多西装</a>
<router-link to="/shopping/clothType">更多西装</router-link>
<img src="./assets/youjiantou.png" alt="" />
</div>
</el-tab-pane>
@ -162,32 +141,7 @@
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in nvzhuang1"
:key="index"
>
<img :src="item.imgUrl" alt="" />
<p>
{{ item.title1 }}<span class="line">|</span>{{ item.title1 }}
</p>
<div>
<el-tag type="warning" size="small">{{ item.tag1 }}</el-tag
><el-tag type="warning" size="small">{{ item.tag2 }}</el-tag>
</div>
<p class="priceDiv d-flex">
<span class="f_18"
><span class="f_24">{{ item.price }}</span></span
><span class="f_12">已售{{ item.sold }}</span>
</p>
</div>
</div>
<div class="more d-flex">
<a href="#">更多衬衫</a>
<img src="./assets/youjiantou.png" alt="" />
</div>
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in nvzhuang1"
v-for="(item, index) in nvzhuang"
:key="index"
>
<img :src="item.imgUrl" alt="" />
@ -206,7 +160,7 @@
</div>
</div>
<div class="more d-flex">
<a href="#">更多西装</a>
<router-link to="/shopping/clothType">更多西装</router-link>
<img src="./assets/youjiantou.png" alt="" />
</div>
</el-tab-pane>
@ -214,7 +168,7 @@
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in tongzhuang1"
v-for="(item, index) in tongzhuang"
:key="index"
>
<img :src="item.imgUrl" alt="" />
@ -233,45 +187,22 @@
</div>
</div>
<div class="more d-flex">
<a href="#">更多衬衫</a>
<img src="./assets/youjiantou.png" alt="" />
</div>
<div class="jz d-flex">
<div
class="item d-flex"
v-for="(item, index) in tongzhuang2"
:key="index"
>
<img :src="item.imgUrl" alt="" />
<p>
{{ item.title1 }}<span class="line">|</span>{{ item.title1 }}
</p>
<div>
<el-tag type="warning" size="small">{{ item.tag1 }}</el-tag
><el-tag type="warning" size="small">{{ item.tag2 }}</el-tag>
</div>
<p class="priceDiv d-flex">
<span class="f_18"
><span class="f_24">{{ item.price }}</span></span
><span class="f_12">已售{{ item.sold }}</span>
</p>
</div>
</div>
<div class="more d-flex">
<a href="#">更多西装</a>
<router-link to="/shopping/clothType">更多西装</router-link>
<img src="./assets/youjiantou.png" alt="" />
</div>
</el-tab-pane>
</el-tabs>
</div>
</div>
<Footer></Footer>
</div>
</template>
<script>
import Header from './components/Header/HeaderView'
import Footer from './components/Footer/FooterView'
export default {
name: "shopHome",
components: { Header },
components: { Header ,Footer},
data() {
return {
vh: 0,
@ -367,7 +298,7 @@
time: 15,
},
],
nanzhuang1: [
nanzhuang: [
{
id: 1,
imgUrl: require("./assets/cloth002.png"),
@ -418,10 +349,8 @@
price: "1xx0.00",
sold: 200,
},
],
nanzhuang2: [
{
id: 1,
id: 6,
imgUrl: require("./assets/cloth002.png"),
title1: "男装",
title2: "衬衫",
@ -431,7 +360,7 @@
sold: 200,
},
{
id: 2,
id: 7,
imgUrl: require("./assets/cloth002.png"),
title1: "男装",
title2: "衬衫",
@ -441,7 +370,7 @@
sold: 200,
},
{
id: 3,
id: 8,
imgUrl: require("./assets/cloth002.png"),
title1: "男装",
title2: "衬衫",
@ -451,7 +380,7 @@
sold: 200,
},
{
id: 4,
id: 9,
imgUrl: require("./assets/cloth002.png"),
title1: "男装",
title2: "衬衫",
@ -461,7 +390,7 @@
sold: 200,
},
{
id: 5,
id: 10,
imgUrl: require("./assets/cloth002.png"),
title1: "男装",
title2: "衬衫",
@ -471,7 +400,7 @@
sold: 200,
},
],
nvzhuang1: [
nvzhuang: [
{
id: 1,
imgUrl: require("./assets/cloth002.png"),
@ -522,10 +451,8 @@
price: "1xx0.00",
sold: 200,
},
],
nvzhuang2: [
{
id: 1,
id: 6,
imgUrl: require("./assets/cloth002.png"),
title1: "女装",
title2: "衬衫",
@ -535,7 +462,7 @@
sold: 200,
},
{
id: 2,
id: 7,
imgUrl: require("./assets/cloth002.png"),
title1: "女装",
title2: "衬衫",
@ -545,7 +472,7 @@
sold: 200,
},
{
id: 3,
id: 8,
imgUrl: require("./assets/cloth002.png"),
title1: "女装",
title2: "衬衫",
@ -555,7 +482,7 @@
sold: 200,
},
{
id: 4,
id: 9,
imgUrl: require("./assets/cloth002.png"),
title1: "女装",
title2: "衬衫",
@ -565,7 +492,7 @@
sold: 200,
},
{
id: 5,
id: 10,
imgUrl: require("./assets/cloth002.png"),
title1: "女装",
title2: "衬衫",
@ -575,7 +502,7 @@
sold: 200,
},
],
tongzhuang1: [
tongzhuang: [
{
id: 1,
imgUrl: require("./assets/cloth002.png"),
@ -626,10 +553,8 @@
price: "1xx0.00",
sold: 200,
},
],
tongzhuang2: [
{
id: 1,
id: 6,
imgUrl: require("./assets/cloth002.png"),
title1: "童装",
title2: "衬衫",
@ -639,7 +564,7 @@
sold: 200,
},
{
id: 2,
id: 7,
imgUrl: require("./assets/cloth002.png"),
title1: "童装",
title2: "衬衫",
@ -649,7 +574,7 @@
sold: 200,
},
{
id: 3,
id: 8,
imgUrl: require("./assets/cloth002.png"),
title1: "童装",
title2: "衬衫",
@ -659,7 +584,7 @@
sold: 200,
},
{
id: 4,
id: 9,
imgUrl: require("./assets/cloth002.png"),
title1: "童装",
title2: "衬衫",
@ -669,7 +594,7 @@
sold: 200,
},
{
id: 5,
id: 10,
imgUrl: require("./assets/cloth002.png"),
title1: "童装",
title2: "衬衫",
@ -808,6 +733,14 @@
.section2 .itemDiv .item {
flex-direction: column;
align-items: center;
justify-content: center;
width: 336px;
height: 336px;
transition: all 0.2s;
}
.section2 .itemDiv .item:hover{
background: #EEE6D9;
border: 1px dashed #919190;
}
.section2 .itemDiv .item .title_3 {
margin: 20px 0;
@ -877,7 +810,7 @@
}
.section5 .more {
margin-bottom: 50px;
margin-top: 50px;
/*margin-top: 50px;*/
}
.section5 .tabs >>> .el-tabs__item.is-top {
font-size: 26px;
@ -887,6 +820,7 @@
}
.section5 .tabs .jz {
justify-content: space-between;
flex-wrap: wrap;
}
.section5 .tabs .jz .item {
background-color: #fff;
@ -894,6 +828,7 @@
flex-direction: column;
align-items: center;
padding-bottom: 30px;
margin-bottom: 30px;
}
.section5 .tabs .jz .item img {
width: 80%;

Loading…
Cancel
Save