feat: 钉钉机器人支持加签安全设置
All checks were successful
continuous-integration/drone/push Build is passing

- 通知渠道增加 sign_secret 字段存储加签密钥
- 发送钉钉消息时自动计算签名
- 前端增加加签密钥输入框(仅钉钉机器人显示)
This commit is contained in:
2026-01-28 17:19:53 +08:00
parent 8430f9dbaa
commit 333bbe57eb
4 changed files with 66 additions and 2 deletions

View File

@@ -25,6 +25,7 @@ const form = reactive({
channel_name: '',
channel_type: 'dingtalk_bot',
webhook_url: '',
sign_secret: '',
description: ''
})
@@ -78,6 +79,7 @@ function handleCreate() {
channel_name: '',
channel_type: 'dingtalk_bot',
webhook_url: '',
sign_secret: '',
description: ''
})
dialogVisible.value = true
@@ -91,6 +93,7 @@ function handleEdit(row) {
channel_name: row.channel_name,
channel_type: row.channel_type,
webhook_url: row.webhook_url,
sign_secret: row.sign_secret || '',
description: row.description || ''
})
dialogVisible.value = true
@@ -258,6 +261,12 @@ onMounted(() => {
</template>
</div>
</el-form-item>
<el-form-item v-if="form.channel_type === 'dingtalk_bot'" label="加签密钥">
<el-input v-model="form.sign_secret" placeholder="SEC开头的密钥可选" />
<div class="form-tip">
如果创建机器人时选择了加签安全设置请填写密钥 SEC 开头
</div>
</el-form-item>
<el-form-item label="描述">
<el-input v-model="form.description" type="textarea" :rows="2" placeholder="渠道描述(可选)" />
</el-form-item>