镜像自地址
https://github.com/ialley-workshop-open/uni-halo.git
已同步 2026-06-12 13:19:31 +08:00
!25 支持文章自定义验证码获取方式、优化友链提交页面
* fix(提交链接): 修复博客 logo 显示问题 * feat(plugin): 重构友链提交插件配置 * feat(api): 为 restrict-read 请求添加微信会话 ID 并支持自定义验证码类型
这个提交包含在:
@@ -194,6 +194,7 @@ export default {
|
||||
return HttpHandler.Get(`/apis/tools.muyin.site/v1alpha1/restrict-read/create`, null, {
|
||||
header: {
|
||||
'Authorization': getAppConfigs().pluginConfig.toolsPlugin?.Authorization,
|
||||
'Wechat-Session-Id': uni.getStorageSync('openid'),
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
+4
-1
@@ -8,7 +8,10 @@ export const DefaultAppConfigs = {
|
||||
imagesConfig: {},
|
||||
authorConfig: {},
|
||||
appConfig: {},
|
||||
pluginConfig: {},
|
||||
pluginConfig: {
|
||||
toolsPlugin: {},
|
||||
linksSubmitPlugin: {},
|
||||
},
|
||||
pageConfig: {}
|
||||
}
|
||||
|
||||
|
||||
@@ -483,7 +483,11 @@ export default {
|
||||
const restrictRead = checkPostRestrictRead(this.result);
|
||||
|
||||
if (restrictRead && toolsPluginEnabled) {
|
||||
const verifyCodeType = getAppConfigs().pluginConfig.toolsPlugin?.verifyCodeType;
|
||||
let verifyCodeType = getAppConfigs().pluginConfig.toolsPlugin?.verifyCodeType;
|
||||
const postVerifyCodeType = this.result?.metadata?.annotations?.verifyCodeType;
|
||||
if (postVerifyCodeType) {
|
||||
verifyCodeType = postVerifyCodeType;
|
||||
}
|
||||
if (verifyCodeType === 'scan') {
|
||||
const scanCodeUrl = getAppConfigs().pluginConfig.toolsPlugin?.scanCodeUrl;
|
||||
this.verificationCodeModal.type = 'scan';
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
|
||||
<!-- 返回顶部 -->
|
||||
<tm-flotbutton color="light-blue" @click="fnToTopPage" size="m" icon="icon-angle-up"></tm-flotbutton>
|
||||
<tm-flotbutton v-if="haloPluginConfigs.submitLink.enabled" :offset="[16,80]" label="申请"
|
||||
<tm-flotbutton v-if="haloPluginConfigs.linksSubmitPlugin.enabled" :offset="[16,80]" label="申请"
|
||||
actions-pos="left" :show-text="true" color="bg-gradient-orange-accent"
|
||||
@click="toSubmitLinkPage"></tm-flotbutton>
|
||||
<!-- 详情弹窗 -->
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
<view class="poup pa-36" scroll-y="auto">
|
||||
<view class="info flex">
|
||||
<view class="poup-logo pa-4 shadow-24">
|
||||
<image :src="blogDetail.blogLogo" class="poup-logo_img" mode="aspectFill"></image>
|
||||
<image :src="$utils.checkAvatarUrl(blogDetail.blogLogo)" class="poup-logo_img" mode="aspectFill"></image>
|
||||
</view>
|
||||
<view class="pl-24 info-detail">
|
||||
<view class="poup-name text-size-lg text-weight-b">{{ blogDetail.blogName }}</view>
|
||||
@@ -97,6 +97,7 @@ import tmPoup from '@/tm-vuetify/components/tm-poup/tm-poup.vue'
|
||||
import tmImages from '@/tm-vuetify/components/tm-images/tm-images.vue'
|
||||
import tmTags from '@/tm-vuetify/components/tm-tags/tm-tags.vue'
|
||||
import tmCoupon from '@/tm-vuetify/components/tm-coupon/tm-coupon.vue'
|
||||
import $utils from "@/utils";
|
||||
|
||||
export default {
|
||||
components: {
|
||||
@@ -128,11 +129,14 @@ export default {
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
$utils() {
|
||||
return $utils
|
||||
},
|
||||
haloPluginConfigs(){
|
||||
return this.$tm.vx.getters().getConfigs.pluginConfig;
|
||||
},
|
||||
blogDetail() {
|
||||
return this.haloPluginConfigs.submitLink;
|
||||
return this.haloPluginConfigs.linksSubmitPlugin;
|
||||
},
|
||||
calcSiteThumbnail(val) {
|
||||
return val => {
|
||||
@@ -147,13 +151,13 @@ export default {
|
||||
return `
|
||||
博客名称:${this.blogDetail.blogName}
|
||||
博客地址:${this.blogDetail.blogUrl}
|
||||
博客logo:${this.blogDetail.blogLogo}
|
||||
博客logo:${$utils.checkAvatarUrl(this.blogDetail.blogLogo)}
|
||||
博客简介:${this.blogDetail.blogDesc}
|
||||
`
|
||||
},
|
||||
calcBlogCoupon() {
|
||||
return {
|
||||
img: this.blogDetail.blogLogo,
|
||||
img: $utils.checkAvatarUrl(this.blogDetail.blogLogo),
|
||||
title: this.blogDetail.blogName,
|
||||
time: this.blogDetail.blogDesc,
|
||||
btnText: '友链详情'
|
||||
|
||||
在新工单中引用
屏蔽一个用户