From 26a6ef8c03393c7e3c0331cf40e1e3eecbbb1f07 Mon Sep 17 00:00:00 2001 From: mm21 <8033134+mm21@users.noreply.github.com> Date: Fri, 5 May 2023 18:27:26 +0000 Subject: [PATCH] Allow etapi to update attribute fields isInheritable, position --- src/etapi/attributes.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/etapi/attributes.js b/src/etapi/attributes.js index 74d3dbfa9..751166858 100644 --- a/src/etapi/attributes.js +++ b/src/etapi/attributes.js @@ -17,7 +17,8 @@ function register(router) { 'type': [v.mandatory, v.notNull, v.isAttributeType], 'name': [v.mandatory, v.notNull, v.isString], 'value': [v.notNull, v.isString], - 'isInheritable': [v.notNull, v.isBoolean] + 'isInheritable': [v.notNull, v.isBoolean], + 'position': [v.notNull, v.isInteger] }; eu.route(router, 'post' ,'/etapi/attributes', (req, res, next) => { @@ -40,7 +41,9 @@ function register(router) { }); const ALLOWED_PROPERTIES_FOR_PATCH = { - 'value': [v.notNull, v.isString] + 'value': [v.notNull, v.isString], + 'isInheritable': [v.notNull, v.isBoolean], + 'position': [v.notNull, v.isInteger] }; eu.route(router, 'patch' ,'/etapi/attributes/:attributeId', (req, res, next) => {