feat: add configurable points rules

This commit is contained in:
hajimi
2026-08-03 00:32:23 +08:00
parent 79e9ee2790
commit 7f7dd71c15
4 changed files with 29 additions and 6 deletions
+17 -1
View File
@@ -25,6 +25,18 @@
<editor class="mb-10" v-model="formData.privacy_content" height="500"></editor>
</el-card>
</div>
<el-card class="!border-none mb-4" shadow="never">
<template #header>
<span class="font-medium">积分规则</span>
</template>
<el-form :model="formData" label-width="80px">
<el-form-item label="规则名称">
<el-input v-model="formData.points_rule_title" />
</el-form-item>
</el-form>
<editor class="mb-10" v-model="formData.points_rule_content" height="500"></editor>
</el-card>
<footer-btns v-perms="['setting.web.web_setting/setAgreement']">
<el-button type="primary" @click="handleProtocolEdit">保存</el-button>
</footer-btns>
@@ -38,12 +50,16 @@ interface formDataObj {
service_content: string
privacy_title: string
privacy_content: string
points_rule_title: string
points_rule_content: string
}
const formData = ref<formDataObj>({
service_title: '',
service_content: '',
privacy_title: '',
privacy_content: ''
privacy_content: '',
points_rule_title: '积分规则',
points_rule_content: ''
})
const protocolGet = async () => {
formData.value = await getProtocol()