feat(微信订阅): 接入歌曲排期模板并加固部署流程
订阅消息(小程序侧唯一能主动触达用户的通道): - 新增 server/utils/wechatSubscribeFields.ts:按微信字段类型裁剪值(thing≤20、 phrase 必须 5 个汉字、time/date/character_string 各自上限),空白压成一行, 北京时间 time 由 playTime 的开始时间生成,解析不出退化为当天 00:00。 - wechatSubscribeService 内置 SONG_SELECTED 模板(站长新给的那个模板 ID), 并转发上述纯函数;notificationService.createSongSelectedNotification 现在会带上 playDate/playTime/sequence,三个排期接口(schedule / publish / bulk-publish)补传 sequence。 - 新增 test/wechatSubscribeFields.test.mjs(10 例,node --test 全绿)。 - test-subscribe 管理接口支持 vars 覆盖并返回真实发送值,方便站长核对字段名。 部署流程(Gitea Actions 容器里没有 buildx 插件,旧流程在此硬失败): - 每个 job 各自安装/探测 docker-buildx(v0.19.3,走 gh-proxy 再退直连), 不把 `buildx version` 当唯一依据;装不上时降级为普通 `docker build` 继续发布, 不再因为缺插件整条流水线失败。 注意:SONG_SELECTED 的字段名(thing2/date4/time1/character_string3/phrase5)是按常见 命名推断的,需在公众平台后台核对;不一致时用环境变量覆盖,模板 ID 变更后老用户需重新授权。
This commit is contained in:
@@ -75,7 +75,7 @@
|
||||
</div>
|
||||
<h3 class="text-lg font-bold text-zinc-700">暂无API密钥</h3>
|
||||
<p class="text-xs text-zinc-500 mt-2 max-w-xs leading-relaxed">
|
||||
您还没有创建任何访问密钥。创建密钥后,您可以安全地将 VoiceHub 集成到第三方应用程序中。
|
||||
您还没有创建任何访问密钥。创建密钥后,您可以安全地将宝一外校园点歌系统集成到第三方应用程序中。
|
||||
</p>
|
||||
<button
|
||||
class="mt-8 flex items-center gap-2 px-6 py-3 bg-white border border-zinc-200 hover:border-zinc-200 text-zinc-600 text-xs font-bold rounded-2xl transition-all"
|
||||
|
||||
@@ -185,7 +185,7 @@
|
||||
{{ selectedFile ? selectedFile.name : '点击选择或拖拽备份文件' }}
|
||||
</h5>
|
||||
<p class="text-[10px] text-zinc-600 font-bold uppercase mt-1 tracking-widest">
|
||||
仅支持 VoiceHub 导出的 .json 格式
|
||||
仅支持宝一外校园点歌系统导出的 .json 格式
|
||||
</p>
|
||||
<input
|
||||
ref="fileInput"
|
||||
|
||||
@@ -208,7 +208,7 @@
|
||||
<h4 class="text-zinc-900 font-bold flex items-center gap-1.5 text-sm">
|
||||
<Icon name="info" :size="14" /> 如何启动酷狗 sidecar?
|
||||
</h4>
|
||||
<p>推荐方式 B:部署开源 KuGouMusicApi 项目到本机 3000 端口(与 VoiceHub 同一台机器即可)。</p>
|
||||
<p>推荐方式 B:部署开源 KuGouMusicApi 项目到本机 3000 端口(与宝一外校园点歌系统同一台机器即可)。</p>
|
||||
<pre class="bg-zinc-900 text-zinc-100 text-[11px] rounded-xl p-3 overflow-x-auto font-mono"><code>git clone https://github.com/MakcRe/KuGouMusicApi
|
||||
cd KuGouMusicApi
|
||||
npm install
|
||||
|
||||
@@ -344,7 +344,7 @@
|
||||
<Bell :size="14" />
|
||||
</div>
|
||||
<span class="text-[10px] font-black text-zinc-600 uppercase tracking-widest"
|
||||
>VoiceHub 系统</span
|
||||
>宝一外校园点歌系统</span
|
||||
>
|
||||
</div>
|
||||
<span class="text-[9px] text-zinc-700 font-bold uppercase tracking-wider"
|
||||
|
||||
@@ -284,7 +284,7 @@ const drawCanvas = () => {
|
||||
}
|
||||
ctx.font = '12px "Inter", "system-ui", sans-serif'
|
||||
ctx.textAlign = 'center'
|
||||
ctx.fillText('Generated by VoiceHub', 200, height - 20)
|
||||
ctx.fillText('Generated by 宝一外校园点歌系统', 200, height - 20)
|
||||
}
|
||||
|
||||
const downloadCard = () => {
|
||||
|
||||
Binary file not shown.
@@ -260,7 +260,7 @@
|
||||
<!-- 页面头部 -->
|
||||
<div class="page-header">
|
||||
<div class="logo-section">
|
||||
<img :src="logoUrl" alt="VoiceHub Logo" class="logo" >
|
||||
<img :src="logoUrl" alt="宝一外校园点歌系统 Logo" class="logo" >
|
||||
<!-- 竖线分割 -->
|
||||
<div class="logo-divider" />
|
||||
<!-- 学校logo -->
|
||||
@@ -356,7 +356,7 @@
|
||||
>备注:{{ settings.remark }}</span
|
||||
>
|
||||
</div>
|
||||
<span class="footer-right">Generated by VoiceHub | 广播管理系统</span>
|
||||
<span class="footer-right">Generated by 宝一外校园点歌系统 | 广播管理系统</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<div class="flex-shrink-0 group-hover:scale-110 transition-all duration-300">
|
||||
<img
|
||||
:src="logo"
|
||||
alt="VoiceHub Logo"
|
||||
alt="宝一外校园点歌系统 Logo"
|
||||
class="w-8 h-8 object-contain"
|
||||
width="32"
|
||||
height="32"
|
||||
@@ -24,7 +24,7 @@
|
||||
</div>
|
||||
<!-- 品牌文字 -->
|
||||
<div class="flex flex-col justify-center">
|
||||
<h1 class="font-bold text-lg text-zinc-900 leading-none tracking-tight">VoiceHub</h1>
|
||||
<h1 class="font-bold text-lg text-zinc-900 leading-none tracking-tight">宝一外校园点歌系统</h1>
|
||||
<p
|
||||
class="text-[10px] text-zinc-500 mt-1.5 uppercase tracking-widest font-bold leading-none"
|
||||
>
|
||||
|
||||
@@ -467,7 +467,7 @@ const saveConfig = async () => {
|
||||
saving.value = true
|
||||
const configToSave = {
|
||||
...formData.value,
|
||||
siteTitle: (formData.value.siteTitle || '').trim() || '校园广播站点歌系统',
|
||||
siteTitle: (formData.value.siteTitle || '').trim() || '宝一外校园点歌系统',
|
||||
siteLogoUrl: (formData.value.siteLogoUrl || '').trim() || '/images/site-logo.png',
|
||||
siteVersion: (formData.value.siteVersion || '').trim() || null,
|
||||
submissionGuidelines:
|
||||
|
||||
Reference in New Issue
Block a user