lrf 2 سال پیش
والد
کامیت
5ebda91b4e
2فایلهای تغییر یافته به همراه3 افزوده شده و 2 حذف شده
  1. 2 2
      app/controller/system/config/.config.js
  2. 1 0
      app/model/system/config.js

+ 2 - 2
app/controller/system/config/.config.js

@@ -1,6 +1,6 @@
 module.exports = {
   create: {
-    requestBody: ['title', 'config'],
+    requestBody: ['title', 'config', 'agreement'],
   },
   destroy: {
     params: ['!id'],
@@ -8,7 +8,7 @@ module.exports = {
   },
   update: {
     params: ['!id'],
-    requestBody: ['title', 'config'],
+    requestBody: ['title', 'config', 'agreement'],
   },
   show: {
     parameters: {

+ 1 - 0
app/model/system/config.js

@@ -11,6 +11,7 @@ const configProp = {
 const config = {
   title: { type: String, required: false, zh: '系统名称' }, //
   config: { type: Object, required: false, zh: '设置' }, //
+  agreement: { type: String, required: false, zh: '用户协议' }, // 富文本
 };
 const schema = new Schema(config, { toJSON: { getters: true, virtuals: true } });
 schema.index({ id: 1 });