|
@@ -22,6 +22,7 @@ const ErrorV3 = require('../../models/vo/error-apiv3');
|
|
|
* components:
|
|
* components:
|
|
|
* schemas:
|
|
* schemas:
|
|
|
* CustomizeLayoutTheme:
|
|
* CustomizeLayoutTheme:
|
|
|
|
|
+ * description: CustomizeLayoutTheme
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* layoutType:
|
|
* layoutType:
|
|
@@ -29,11 +30,13 @@ const ErrorV3 = require('../../models/vo/error-apiv3');
|
|
|
* themeType:
|
|
* themeType:
|
|
|
* type: string
|
|
* type: string
|
|
|
* CustomizeBehavior:
|
|
* CustomizeBehavior:
|
|
|
|
|
+ * description: CustomizeBehavior
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* behaviorType:
|
|
* behaviorType:
|
|
|
* type: string
|
|
* type: string
|
|
|
* CustomizeFunction:
|
|
* CustomizeFunction:
|
|
|
|
|
+ * description: CustomizeFunction
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* isEnabledTimeline:
|
|
* isEnabledTimeline:
|
|
@@ -47,6 +50,7 @@ const ErrorV3 = require('../../models/vo/error-apiv3');
|
|
|
* isEnabledStaleNotification:
|
|
* isEnabledStaleNotification:
|
|
|
* type: boolean
|
|
* type: boolean
|
|
|
* CustomizeHighlight:
|
|
* CustomizeHighlight:
|
|
|
|
|
+ * description: CustomizeHighlight
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* styleName:
|
|
* styleName:
|
|
@@ -54,21 +58,25 @@ const ErrorV3 = require('../../models/vo/error-apiv3');
|
|
|
* styleBorder:
|
|
* styleBorder:
|
|
|
* type: boolean
|
|
* type: boolean
|
|
|
* CustomizeTitle:
|
|
* CustomizeTitle:
|
|
|
|
|
+ * description: CustomizeTitle
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* customizeTitle:
|
|
* customizeTitle:
|
|
|
* type: string
|
|
* type: string
|
|
|
* CustomizeHeader:
|
|
* CustomizeHeader:
|
|
|
|
|
+ * description: CustomizeHeader
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* customizeHeader:
|
|
* customizeHeader:
|
|
|
* type: string
|
|
* type: string
|
|
|
* CustomizeCss:
|
|
* CustomizeCss:
|
|
|
|
|
+ * description: CustomizeCss
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* customizeCss:
|
|
* customizeCss:
|
|
|
* type: string
|
|
* type: string
|
|
|
* CustomizeScript:
|
|
* CustomizeScript:
|
|
|
|
|
+ * description: CustomizeScript
|
|
|
* type: object
|
|
* type: object
|
|
|
* properties:
|
|
* properties:
|
|
|
* customizeScript:
|
|
* customizeScript:
|
|
@@ -123,9 +131,11 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting:
|
|
|
* get:
|
|
* get:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: getCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting
|
|
|
* description: Get customize paramators
|
|
* description: Get customize paramators
|
|
|
* responses:
|
|
* responses:
|
|
|
* 200:
|
|
* 200:
|
|
@@ -163,23 +173,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/layoutTheme:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/layoutTheme:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateLayoutThemeCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/layoutTheme
|
|
|
* description: Update layout and theme
|
|
* description: Update layout and theme
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeLayoutTheme'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update layout and theme
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeLayoutTheme'
|
|
* $ref: '#/components/schemas/CustomizeLayoutTheme'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update layout and theme
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeLayoutTheme'
|
|
|
*/
|
|
*/
|
|
|
router.put('/layoutTheme', loginRequiredStrictly, adminRequired, csrf, validator.layoutTheme, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/layoutTheme', loginRequiredStrictly, adminRequired, csrf, validator.layoutTheme, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -205,23 +217,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/behavior:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/behavior:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateBehaviorCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/behavior
|
|
|
* description: Update behavior
|
|
* description: Update behavior
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeBehavior'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update behavior
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeBehavior'
|
|
* $ref: '#/components/schemas/CustomizeBehavior'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update behavior
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeBehavior'
|
|
|
*/
|
|
*/
|
|
|
router.put('/behavior', loginRequiredStrictly, adminRequired, csrf, validator.behavior, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/behavior', loginRequiredStrictly, adminRequired, csrf, validator.behavior, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -245,23 +259,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/function:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/function:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateFunctionCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/function
|
|
|
* description: Update function
|
|
* description: Update function
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeFunction'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update function
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeFunction'
|
|
* $ref: '#/components/schemas/CustomizeFunction'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update function
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeFunction'
|
|
|
*/
|
|
*/
|
|
|
router.put('/function', loginRequiredStrictly, adminRequired, csrf, validator.function, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/function', loginRequiredStrictly, adminRequired, csrf, validator.function, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -293,23 +309,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/highlight:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/highlight:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateHighlightCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/highlight
|
|
|
* description: Update highlight
|
|
* description: Update highlight
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeHighlight'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update highlight
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeHighlight'
|
|
* $ref: '#/components/schemas/CustomizeHighlight'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update highlight
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeHighlight'
|
|
|
*/
|
|
*/
|
|
|
router.put('/highlight', loginRequiredStrictly, adminRequired, csrf, validator.highlight, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/highlight', loginRequiredStrictly, adminRequired, csrf, validator.highlight, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -335,9 +353,11 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/customizeTitle:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/customizeTitle:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateCustomizeTitleCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/customizeTitle
|
|
|
* description: Update customizeTitle
|
|
* description: Update customizeTitle
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
@@ -345,13 +365,13 @@ module.exports = (crowi) => {
|
|
|
* application/json:
|
|
* application/json:
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeTitle'
|
|
* $ref: '#/components/schemas/CustomizeTitle'
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update customizeTitle
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
- * schema:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeTitle'
|
|
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update customizeTitle
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeTitle'
|
|
|
*/
|
|
*/
|
|
|
router.put('/customize-title', loginRequiredStrictly, adminRequired, csrf, validator.customizeTitle, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/customize-title', loginRequiredStrictly, adminRequired, csrf, validator.customizeTitle, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -376,23 +396,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/customizeHeader:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/customizeHeader:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateCustomizeHeaderCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/customizeHeader
|
|
|
* description: Update customizeHeader
|
|
* description: Update customizeHeader
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeHeader'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update customize header
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeHeader'
|
|
* $ref: '#/components/schemas/CustomizeHeader'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update customize header
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeHeader'
|
|
|
*/
|
|
*/
|
|
|
router.put('/customize-header', loginRequiredStrictly, adminRequired, csrf, validator.customizeHeader, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/customize-header', loginRequiredStrictly, adminRequired, csrf, validator.customizeHeader, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -415,23 +437,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/customizeCss:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/customizeCss:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateCustomizeCssCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/customizeCss
|
|
|
* description: Update customizeCss
|
|
* description: Update customizeCss
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeCss'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update customize css
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeCss'
|
|
* $ref: '#/components/schemas/CustomizeCss'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update customize css
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeCss'
|
|
|
*/
|
|
*/
|
|
|
router.put('/customize-css', loginRequiredStrictly, adminRequired, csrf, validator.customizeCss, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/customize-css', loginRequiredStrictly, adminRequired, csrf, validator.customizeCss, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|
|
@@ -455,23 +479,25 @@ module.exports = (crowi) => {
|
|
|
/**
|
|
/**
|
|
|
* @swagger
|
|
* @swagger
|
|
|
*
|
|
*
|
|
|
- * /customize-setting/customizeScript:
|
|
|
|
|
|
|
+ * /_api/v3/customize-setting/customizeScript:
|
|
|
* put:
|
|
* put:
|
|
|
- * tags: [CustomizeSetting]
|
|
|
|
|
|
|
+ * tags: [CustomizeSetting, apiv3]
|
|
|
|
|
+ * operationId: updateCustomizeScriptCustomizeSetting
|
|
|
|
|
+ * summary: /_api/v3/customize-setting/customizeScript
|
|
|
* description: Update customizeScript
|
|
* description: Update customizeScript
|
|
|
* requestBody:
|
|
* requestBody:
|
|
|
* required: true
|
|
* required: true
|
|
|
* content:
|
|
* content:
|
|
|
* application/json:
|
|
* application/json:
|
|
|
- * schama:
|
|
|
|
|
- * $ref: '#/components/schemas/CustomizeScript'
|
|
|
|
|
- * responses:
|
|
|
|
|
- * 200:
|
|
|
|
|
- * description: Succeeded to update customize script
|
|
|
|
|
- * content:
|
|
|
|
|
- * application/json:
|
|
|
|
|
* schema:
|
|
* schema:
|
|
|
* $ref: '#/components/schemas/CustomizeScript'
|
|
* $ref: '#/components/schemas/CustomizeScript'
|
|
|
|
|
+ * responses:
|
|
|
|
|
+ * 200:
|
|
|
|
|
+ * description: Succeeded to update customize script
|
|
|
|
|
+ * content:
|
|
|
|
|
+ * application/json:
|
|
|
|
|
+ * schema:
|
|
|
|
|
+ * $ref: '#/components/schemas/CustomizeScript'
|
|
|
*/
|
|
*/
|
|
|
router.put('/customize-script', loginRequiredStrictly, adminRequired, csrf, validator.customizeScript, ApiV3FormValidator, async(req, res) => {
|
|
router.put('/customize-script', loginRequiredStrictly, adminRequired, csrf, validator.customizeScript, ApiV3FormValidator, async(req, res) => {
|
|
|
const requestParams = {
|
|
const requestParams = {
|