예제 #1
0
        /// <summary>
        /// Creates a new Code List with provided values and sets proper authority for each value.
        /// </summary>
        /// <param name="codeListCofinguration">Configuration model of the new code list</param>
        /// <returns></returns>
        private async Task <CodeListCreateARM> CodeListCreate(CodeListFileContent codeListCofinguration)
        {
            var newCodeList = new CodeListCreateAM
            {
                Name          = codeListCofinguration.Name,
                Title         = codeListCofinguration.Title,
                AllowedValues = codeListCofinguration.Values.Select(x => x.Name).ToArray()
            };

            var result = await _alfrescoHttpClient.CodeListCreate(newCodeList);

            await UpdateValueWithAuthority(codeListCofinguration);

            return(result);
        }