Commit 83ad9cf9 authored by 吴冠's avatar 吴冠

更新功能

parent 3af00e40
This diff is collapsed.
......@@ -105,6 +105,8 @@ import {getSecond} from '@/common/list.js'
left:1000px;
cursor:pointer;
font-size: 10px;
color:blue;
background: none;
}
.header-line {
......
......@@ -26,11 +26,12 @@
methods:{
toSearch(){
sessionStorage.setItem("content",this.input)
sessionStorage.setItem("contentStatus",1)
if(window.location.pathname !=="/notice/all"){
this.$router.push('/notice/all')
this.input = null
}else{
/* location.reload() */
location.reload()
console.log("请在下面进行查询")
this.input = null
}
......@@ -51,7 +52,7 @@
.images{
width:100px;
height:20px;
margin-left:20px;
margin-left:0px;
margin-top:-20px
}
.images>img{
......@@ -72,7 +73,7 @@
}
.head-input-title{
margin-top: 0px;
margin-left: -580px;
margin-left: -610px;
font-size:.28rem;
color:rgba(0,0,0,1);
font-weight: bold;
......
......@@ -47,9 +47,34 @@ import inDex from '@/pages/index.vue'
},
mounted(){
console.log("1")
/* if(window.location.pathname =="/notice/all"){
this.nav = "4"
} */
let path = this.$route.path;
/* if(path=="/"){
this.nav = "0";
}else if(path.indexOf("/message")==0){
this.nav = "5";
}else if(path.indexOf("/notice")==0){
this.nav = "4";
} */
switch (path) {
case '/':
this.nav = "0";
break;
case '/notice/inquiry':
this.nav = "1";
break;
case "/notice/bid":
this.nav = "2";
break;
case "/notice/biding":
this.nav = "3";
break;
case "/notice/all":
this.nav = "4";
break;
case "/message/news":
this.nav = "5";
break;
}
},
methods: {
change(index, path) {
......
<template>
<div class="home">
<Head></Head>
<Homeinput></Homeinput>
<Nav></Nav>
<nuxt ></nuxt>
<Footer></Footer>
<div class="home">
<Head></Head>
<Homeinput></Homeinput>
<Nav></Nav>
<nuxt></nuxt>
<Footer></Footer>
<div class="imagesList" >
<img src="../assets/images/phone.png" alt="电话">
<img src="../assets/images/QQ.png" alt="QQ">
<img src="../assets/images/email.png" alt="邮箱">
<img src="../assets/images/weixin.png" alt="微信" class="weixin" @mouseover="enter" @mouseout="leave">
<div>
<img src="../assets/images/qrcode.png" alt="二维码" class="qrcode" v-if="isshowqrcode">
</div>
</div>
</div>
</template>
<script>
import Head from '~/components/header'
import Nav from '~/components/nav'
import Footer from '~/components/footer'
import Homeinput from '~/components/homeinput'
export default {
name: "homePage",
data () {
return {
}
},
components: {
Head,
Nav,
Footer
},
}
import Head from "~/components/header";
import Nav from "~/components/nav";
import Footer from "~/components/footer";
import Homeinput from "~/components/homeinput";
export default {
name: "homePage",
data() {
return {
isshowqrcode:false
};
},
components: {
Head,
Nav,
Footer,
},
methods:{
enter(){
this.isshowqrcode = true
},
leave(){
this.isshowqrcode = false
}
}
};
</script>
<style scoped>
.home{
width : 100%;
min-width: 810px;
height: 100%;
min-height: 600px;
.home {
width: 100%;
min-width: 810px;
height: 100%;
min-height: 600px;
}
.imagesList{
position: fixed;
/* flex-direction: column; */
width:30px;
right:10px;
top:35%;
}
.imagesList>img{
margin-top:5px;
margin-bottom: 5px;
width:30px;
}
.qrcode{
width:100px;
height:100px;
position: absolute;
right:40px;
top:58px;
}
</style>
......@@ -10,7 +10,7 @@
</div>
<div class="login" @mouseover="changeOver" >
<div class="author" >
<img src="~/assets/css/7.png" v-show="!showDefault">
<img src="~/assets/css/7.png">
</div>
<div class="login-title">{{userName}}</div>
<div class="login-button" @click="loginuser" v-show="showDefault">用户登录</div>
......@@ -90,9 +90,6 @@ import {getSecond,getListSite,getListSite1,getListSite2} from '@/common/list.js'
this.getListSite()
this.getListSite1()
this.getListSite2()
/* if(window.location.pathname =="/notice/all"){
this.nav = "4"
} */
},
methods:{
latformDynamics(){
......
......@@ -26,7 +26,7 @@
</div>
</div>
<ul v-if="isshow">
<ul >
<li v-for="item in priceList" :key="item.id">
<nuxt-link :to='`/notice/${item.noticeType}details?id=${item.noticeId}`'>
<div class="time">{{getTimer(item.createTime)}}</div>
......@@ -46,12 +46,12 @@
</div>
</nuxt-link>
</li>
<div class="pagination flex-center" >
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="getData.currentPage" :page-size ="getData.size" :page-sizes="[10, 20, 30, 40]"
layout="total, sizes,prev, pager, next, jumper" :total="total">
</el-pagination >
</div>
</ul>
<div class="pagination flex-center">
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="getData.currentPage" :page-size ="getData.size" :page-sizes="[10, 20, 30, 40]"
layout="total, sizes,prev, pager, next, jumper" :total="total">
</el-pagination >
</div>
</div>
</template>
......@@ -76,7 +76,6 @@ import {getAllList,getNoticeType} from '@/common/list.js'
},
data() {
return {
isshow:true,
allList:[],
total:0,
getData:{
......@@ -143,10 +142,17 @@ import {getAllList,getNoticeType} from '@/common/list.js'
async getAllList(params){
const {data,total} = await getAllList(params)
this.priceList = data
if(total ===null||0){
this.isshow = false
}
this.total = total
let contentStatus = sessionStorage.getItem("contentStatus")
if(contentStatus =='1'){
if(this.total!==0){
this.$message.success("查询成功!")
}else{
this.$message.error("请输入正确的公告名称!")
this.getAllList(this.getData)
}
sessionStorage.removeItem("contentStatus")
}
},
async getNoticeType(){
const {data} = await getNoticeType()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment