Skip to content

Releases: BetterCorp/service-base-plugin-betterportal

v1.10.1

08 Apr 20:29
Compare
Choose a tag to compare
chore(package.json): update devDependencies and dependencies

refactor(service-betterportal/plugin.ts): remove unused import and type definition, remove MyPluginConfig from generic type definition

v1.10.0

07 Apr 14:07
Compare
Choose a tag to compare
chore(package.json): update dependencies and bump version to 2.0.0

refactor(service-betterportal): reorganize imports and remove unused imports
feat(service-betterportal): add FieldPermission import from index
feat(service-betterportal): add Tools import from @bettercorp/tools
fix(service-betterportal): fix import of EJWTTokenType from @bettercorp/service-base-plugin-web-server/lib/plugins/service-webjwt/sec.config

feat(plugin.ts): add new method to rewrite object based on permissions

refactor(index.ts): remove unused imports and variables, reorganize types and interfaces

feat(service-betterportal): add support for configurable BetterPortal capabilities

This commit adds support for configurable BetterPortal capabilities. The
`addCapability` method has been updated to accept a generic type `Capability`
and a generic type `key` to define the capability and its key. The method also
accepts a `capabilityHandler` function to handle the capability and a
`permission` parameter to define the permission required to access the
capability.

Additionally, the commit adds a new capability `BetterPortalCapabilityInternal`
and a new method `initBPUI` to initialize the BetterPortal UI. The method
accepts a `serviceName` and a `path` parameter to define the service name and
the path to the UI.

The commit also includes some refactoring and code cleanup.

feat(plugin.ts): add support for permissionRequired parameter in get and post methods of Service class.

refactor(plugin.ts): simplify put, delete, and patch methods by removing unnecessary parameters and code
feat(plugin.ts): add support for permissionRequired object instead of string in put, delete, and patch methods
feat(plugin.ts): add capability for permissionRequired in put, delete, and patch methods

refactor(service-betterportal): improve logging and permission checking

- Add more information to the log message when a client request is invalid
- Change the return type of _userHasPermission method to include the fields that the user has permission to access
- Add support for permission fields in _userHasPermission method
- Improve the permission checking in _userHasPermission method
- Change the return type of _userHasPermission method to include a boolean indicating if the user has permission or not
- Change the return type of getTokenInfo method to include a message indicating if the token is invalid or not
- Change the message of the return object when the token is invalid in getTokenInfo method
- Remove unused variables in getTokenInfo method

v1.9.3

30 Mar 11:59
Compare
Choose a tag to compare
I think I need a coffee. Updated hash to use from buffer to make up t…

…he capabilities hash

v1.9.2

30 Mar 11:56
Compare
Choose a tag to compare

Fix capabilities hash issue

v1.9.1

30 Mar 03:02
Compare
Choose a tag to compare
feat(service-betterportal): add capability support

Add support for adding new capabilities to the BetterPortal service. The
`addCapability` method was added to the `BetterPortalCallable` interface and
implemented in the `Service` class. The `BetterPortalCapabilityConfigurable`
enum was added to the `index.ts` file to define the configurable capabilities.
The `BetterPortalCapabilityInternal` enum was also added to define the internal
capabilities. The `BetterPortalCapability` type was added to define the
capabilities that can be used. The `capabilities` array was added to the
`Service` class to store the added capabilities. The `/bp/capabilities/` and
`/bp/capabilities/:capability/:optionalparam?/` routes were added to the
`Service` class to handle the capabilities.

v1.9.0

28 Mar 18:33
Compare
Choose a tag to compare
Updates and fixed

v1.8.7

12 Mar 12:08
Compare
Choose a tag to compare
Updated web-server deps

v1.8.6

11 Mar 21:09
Compare
Choose a tag to compare
Dep updates - for web-server bugfix

v1.8.5

10 Mar 18:04
Compare
Choose a tag to compare
Deps updated

v1.8.4

10 Mar 17:40
Compare
Choose a tag to compare
Bugfixes and updates for flow