🚀New lib version v0.4.5 [CI SKIP]
continuous-integration/drone Build is passing Details

This commit is contained in:
Nicolai Ort 2021-02-09 18:28:47 +00:00
parent 95601107e9
commit f7118fcc1f
8 changed files with 42 additions and 9 deletions

View File

@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
exports.OpenAPI = void 0;
exports.OpenAPI = {
BASE: '',
VERSION: '0.4.4',
VERSION: '0.4.5',
WITH_CREDENTIALS: false,
TOKEN: undefined,
USERNAME: undefined,

1
dist/index.d.ts vendored
View File

@ -92,6 +92,7 @@ export type { ResponseTrack } from './models/ResponseTrack';
export type { ResponseTrackScan } from './models/ResponseTrackScan';
export type { ResponseUser } from './models/ResponseUser';
export type { ResponseUserGroup } from './models/ResponseUserGroup';
export type { ResponseUserGroupPermissions } from './models/ResponseUserGroupPermissions';
export type { ResponseUserPermissions } from './models/ResponseUserPermissions';
export type { Runner } from './models/Runner';
export type { RunnerCard } from './models/RunnerCard';

View File

@ -0,0 +1,4 @@
export declare type ResponseUserGroupPermissions = {
directlyGranted?: Array<any>;
inherited?: Array<any>;
};

View File

@ -0,0 +1,5 @@
"use strict";
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
Object.defineProperty(exports, "__esModule", { value: true });

View File

@ -1,6 +1,7 @@
import type { CreateUserGroup } from '../models/CreateUserGroup';
import type { ResponseEmpty } from '../models/ResponseEmpty';
import type { ResponseUserGroup } from '../models/ResponseUserGroup';
import type { ResponseUserGroupPermissions } from '../models/ResponseUserGroupPermissions';
import type { UpdateUserGroup } from '../models/UpdateUserGroup';
import type { UserGroup } from '../models/UserGroup';
import type { UserGroupNotFoundError } from '../models/UserGroupNotFoundError';
@ -8,10 +9,10 @@ export declare class UserGroupService {
/**
* Get all
* Lists all groups. <br> The information provided might change while the project continues to evolve.
* @returns UserGroup
* @returns ResponseUserGroup
* @throws ApiError
*/
static userGroupControllerGetAll(): Promise<Array<UserGroup>>;
static userGroupControllerGetAll(): Promise<Array<ResponseUserGroup>>;
/**
* Post
* Create a new group. <br> If you want to grant permissions to the group you have to create them seperately by posting to /api/permissions after creating the group.
@ -24,10 +25,10 @@ export declare class UserGroupService {
* Get one
* Lists all information about the group whose id got provided. <br> The information provided might change while the project continues to evolve.
* @param id
* @returns UserGroup
* @returns ResponseUserGroup
* @throws ApiError
*/
static userGroupControllerGetOne(id: number): Promise<UserGroup>;
static userGroupControllerGetOne(id: number): Promise<ResponseUserGroup>;
/**
* Put
* Update the group whose id you provided. <br> To change the permissions granted to the group please use /api/permissions instead. <br> Please remember that ids can't be changed.
@ -47,4 +48,12 @@ export declare class UserGroupService {
* @throws ApiError
*/
static userGroupControllerRemove(id: number, force?: boolean): Promise<ResponseUserGroup | ResponseEmpty>;
/**
* Get permissions
* Lists all permissions granted to the group as permission response objects.
* @param id
* @returns ResponseUserGroupPermissions
* @throws ApiError
*/
static userGroupControllerGetPermissions(id: number): Promise<ResponseUserGroupPermissions>;
}

View File

@ -6,7 +6,7 @@ class UserGroupService {
/**
* Get all
* Lists all groups. <br> The information provided might change while the project continues to evolve.
* @returns UserGroup
* @returns ResponseUserGroup
* @throws ApiError
*/
static async userGroupControllerGetAll() {
@ -35,7 +35,7 @@ class UserGroupService {
* Get one
* Lists all information about the group whose id got provided. <br> The information provided might change while the project continues to evolve.
* @param id
* @returns UserGroup
* @returns ResponseUserGroup
* @throws ApiError
*/
static async userGroupControllerGetOne(id) {
@ -80,5 +80,19 @@ class UserGroupService {
});
return result.body;
}
/**
* Get permissions
* Lists all permissions granted to the group as permission response objects.
* @param id
* @returns ResponseUserGroupPermissions
* @throws ApiError
*/
static async userGroupControllerGetPermissions(id) {
const result = await request_1.request({
method: 'GET',
path: `/api/usergroups/${id}/permissions`,
});
return result.body;
}
}
exports.UserGroupService = UserGroupService;

File diff suppressed because one or more lines are too long

View File

@ -1,7 +1,7 @@
{
"name": "@odit/lfk-client-js",
"description": "A lib to interact with https://git.odit.services/lfk/backend. Use this version for native JS applications.",
"version": "0.4.4",
"version": "0.4.5",
"license": "CC-BY-NC-SA-4.0",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",