From 31a770ebe46463a9169ef44069bf7619787ca6fc Mon Sep 17 00:00:00 2001 From: Qing Date: Wed, 27 Dec 2023 16:44:51 +0800 Subject: [PATCH] update --- src/components/detail/NavDetail.vue | 55 ++- src/components/home/HomeHeader.vue | 50 +-- src/components/home/HomePage.vue | 27 +- src/components/home/NavList.vue | 65 ++-- src/components/hotNews/HotNews.vue | 233 +++++++++---- src/components/hotNews/NewsCard.vue | 38 +-- src/components/myNav/MyNav.vue | 36 +- .../setting/category/CategoryManage.vue | 10 +- .../setting/home/PersonalHomePage.vue | 14 +- .../setting/home/PersonalInfoCard.vue | 312 +++++++++++++++--- .../setting/importExport/Export.vue | 10 +- .../setting/importExport/Import.vue | 10 +- .../setting/layout/SettingLeftSide.vue | 10 +- .../setting/onsite/BaseSettings.vue | 20 +- .../setting/system/AppearanceSettings.vue | 20 +- .../setting/system/FunctionSettings.vue | 30 +- .../setting/system/InformationSettings.vue | 20 +- src/components/setting/system/Upload.vue | 45 +-- .../setting/website/websiteManage.vue | 10 +- src/views/Index.vue | 2 + 20 files changed, 665 insertions(+), 352 deletions(-) diff --git a/src/components/detail/NavDetail.vue b/src/components/detail/NavDetail.vue index 1418147..29ef49a 100644 --- a/src/components/detail/NavDetail.vue +++ b/src/components/detail/NavDetail.vue @@ -34,8 +34,8 @@ effect="dark" close-delay="2000">
【{{ UrlObj.name }}】手机二维码

-
+
手机查看 @@ -195,9 +195,7 @@ export default { mounted() { // this.GetAllComment(); - if(this.UrlId && this.UrlObj.icon){ - this.getQR(this.UrlId, this.UrlObj.icon); - } + }, @@ -237,11 +235,11 @@ export default { }).then(function (res) { _this.allcomment = res.data; }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, // 日访问: @@ -260,22 +258,21 @@ export default { _this.initEchart(_this.xTime,_this.YView); } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, // 获取二维码: - getQR(url_id, icon_url) { + getNavQR(url_id) { let _this = this; axios({ method: 'post', url: '/api/qrcode/qrc_return', - data: { + params: { url_id: url_id, - icon_url: icon_url } }).then(function (res) { if (res.data) { @@ -284,11 +281,11 @@ export default { return false; }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error === null ? '' : error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error === null ? '' : error, + // offset: 0 + // }); }) return this.imageCode }, @@ -404,18 +401,18 @@ export default { that.UrlObj = res.data.data; that.UnDate = that.UrlObj.createtime; }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error === null ? '' : error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error === null ? '' : error, + // offset: 0 + // }); }); this.getFormatDate(); }, // 向管理员反馈 WarnToAdmin() { // this.GetAllComment(); - console.log(this.allcomment); + // console.log(this.allcomment); } } } diff --git a/src/components/home/HomeHeader.vue b/src/components/home/HomeHeader.vue index 1d7b298..e0bf92a 100644 --- a/src/components/home/HomeHeader.vue +++ b/src/components/home/HomeHeader.vue @@ -480,11 +480,11 @@ export default { } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error === null ? '' : error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error === null ? '' : error, + // offset: 0 + // }); }) } else { Vue.prototype.$notify.error({ @@ -513,11 +513,11 @@ export default { offset: 0 }); }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) } else { Vue.prototype.$notify.error({ @@ -564,11 +564,11 @@ export default { } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) } else { Vue.prototype.$notify.error({ @@ -620,11 +620,11 @@ export default { }, 1000); } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) } else { @@ -666,11 +666,11 @@ export default { }, 1000); } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) } else { diff --git a/src/components/home/HomePage.vue b/src/components/home/HomePage.vue index a48d747..a239757 100644 --- a/src/components/home/HomePage.vue +++ b/src/components/home/HomePage.vue @@ -81,16 +81,21 @@ export default { } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getPath() { - document.querySelector(this.$route.query.name).scrollIntoView(true) + if(this.$route.query.name){ + document.querySelector(this.$route.query.name).scrollIntoView(true) + }else{ + return false; + } + }, // 获取导航详情列表 @@ -107,11 +112,11 @@ export default { _this.loading=true; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error === null ? '' : error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error === null ? '' : error, + // offset: 0 + // }); }) }, diff --git a/src/components/home/NavList.vue b/src/components/home/NavList.vue index f374556..0b8ad29 100644 --- a/src/components/home/NavList.vue +++ b/src/components/home/NavList.vue @@ -1,6 +1,6 @@ @@ -49,6 +61,7 @@ export default { data() { return { imageCode: '', + dialogVisible:false, } }, mounted() { @@ -59,29 +72,35 @@ export default { }, computed: {}, methods: { - getQR(url_id, icon_url) { + handleClose(){ + this.dialogVisible=false; + }, + openShowQR(id){ + this.dialogVisible=true; + this.getQR(id); + }, + getQR(url_id) { let _this = this; - if(url_id && icon_url){ + if(url_id){ axios({ method: 'post', url: '/api/qrcode/qrc_return', - data: { + params: { url_id: url_id, - icon_url: icon_url } }).then(function (res) { - if (res.data) { + if (res.data!==''){ _this.imageCode = "data:image/jpg;base64," + res.data; } - return false; + + }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error === null ? '' : error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error === null ? '' : error, + // offset: 0 + // }); }) - return this.imageCode }else{ return false } diff --git a/src/components/hotNews/HotNews.vue b/src/components/hotNews/HotNews.vue index b1c1a57..989f053 100644 --- a/src/components/hotNews/HotNews.vue +++ b/src/components/hotNews/HotNews.vue @@ -2,12 +2,47 @@
- - - - - - + +
+ +
+ +
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+ +
+ +
+ +
+
+
+ + +
+ +
+
+ +
+ +
+ +
+
@@ -26,31 +61,36 @@ export default { category: [ { - name:'百度热搜榜', - childUC:[], + name: '百度热搜榜', + childUC: [], }, { - name:'抖音热搜榜', - childUC:[], + name: '抖音热搜榜', + childUC: [], }, { - name:'微博热搜榜', - childUC:[], + name: '微博热搜榜', + childUC: [], }, { - name:'知乎热搜榜', - childUC:[], + name: '知乎热搜榜', + childUC: [], }, { - name:'哔哩哔哩热搜榜', - childUC:[], + name: '哔哩哔哩热搜榜', + childUC: [], }, { - name:'今日头条热搜榜', - childUC:[], + name: '今日头条热搜榜', + childUC: [], }, - ], - loading: true, + ], + loading1: true, + loading2: true, + loading3: true, + loading4: true, + loading5: true, + loading6: true, baidu: { title: "百度热搜榜", hot: [], @@ -100,8 +140,61 @@ export default { }, computed: {}, methods: { + refresh1() { + this.loading1=true; + this.baidu.hot=[]; + setTimeout(()=>{ + this.loading1=false + },3000) + this.getBaiDuHot(); + }, + refresh2() { + this.loading2=true; + this.douying.hot=[]; + setTimeout(()=>{ + this.loading2=false + },3000) + this.getDouyingHot(); + }, + refresh3() { + this.loading3=true; + this.weibo.hot=[]; + setTimeout(()=>{ + this.loading3=false + },3000) + this.getWeiBoHot(); + }, + refresh4() { + this.loading4=true; + this.zhihu.hot=[]; + setTimeout(()=>{ + this.loading4=false + },3000) + this.getZhiHuHot(); + }, + refresh5() { + this.loading5=true; + this.bili.hot=[]; + setTimeout(()=>{ + this.loading5=false + },3000) + this.getBiliHot(); + }, + refresh6() { + this.loading6=true; + this.toutiao.hot=[]; + setTimeout(()=>{ + this.loading6=false + },3000) + this.getTouTiaoHot(); + }, getPath() { - document.querySelector(this.$route.query.name).scrollIntoView(true) + if (this.$route.query.name) { + document.querySelector(this.$route.query.name).scrollIntoView(true) + } else { + return false; + } + }, getBaiDuHot() { let _this = this; @@ -116,16 +209,16 @@ export default { offset: 0 }); } else { - _this.loading = false; + _this.loading1 = false; _this.baidu.hot = res.data.data; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getDouyingHot() { @@ -142,15 +235,15 @@ export default { }); } else { _this.douying.hot = res.data.data; - _this.loading = false; + _this.loading2 = false; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getWeiBoHot() { @@ -167,15 +260,15 @@ export default { }); } else { _this.weibo.hot = res.data.data; - _this.loading = false; + _this.loading3 = false; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getZhiHuHot() { @@ -192,15 +285,15 @@ export default { }); } else { _this.zhihu.hot = res.data.data; - _this.loading = false; + _this.loading4 = false; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getBiliHot() { @@ -217,15 +310,15 @@ export default { }); } else { _this.bili.hot = res.data.data; - _this.loading = false; + _this.loading5 = false; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, getTouTiaoHot() { @@ -242,15 +335,15 @@ export default { }); } else { _this.toutiao.hot = res.data.data; - _this.loading = false; + _this.loading6 = false; } }).catch((error) => { - Vue.prototype.$notify.error({ - title: '错误', - message: error, - offset: 0 - }); + // Vue.prototype.$notify.error({ + // title: '错误', + // message: error, + // offset: 0 + // }); }) }, } @@ -265,4 +358,30 @@ export default { justify-content: flex-start; overflow: scroll; } + + +.widget { + color: var(--theme-color); + background-color: var(--theme-bg-color); + border-radius: 1.0rem; + flex-direction: column; + height: 540px; + position: relative; + width: 300px; + margin-top: 20px; + margin-left: 25px; + flex-wrap: nowrap; + justify-content: space-between; + +} + +.refresh { +//font-weight: bold; font-size: 18px +} + +.refresh:hover { + font-size: 20px; + color: #999ba5; + cursor: pointer; +} \ No newline at end of file diff --git a/src/components/hotNews/NewsCard.vue b/src/components/hotNews/NewsCard.vue index dbe0274..7cca256 100644 --- a/src/components/hotNews/NewsCard.vue +++ b/src/components/hotNews/NewsCard.vue @@ -1,6 +1,6 @@