feat: Init credential library creation

This commit is contained in:
Susmitha Girumala committed 2021-07-18 14:31:45 -04:00
1 parent 2212c7dd9e
commit 45fc58fe75
16 files changed
+316 -5

No files matched your search

+12 -1
View File
@@ -2,13 +2,24 @@ import GeneratedCredentialLibraryModel from '../generated/models/credential-libr
import { attr } from '@ember-data/model';
import { fragment } from 'ember-data-model-fragments/attributes';
/**
* Enum options for credential library.
*/
export const options = {
http_methods: ['GET', 'POST'],
};
export default class CredentialLibraryModel extends GeneratedCredentialLibraryModel {
// =error attributes
// These attributes exist solely to capture errors on nested fields.
// See the application adapter's error normalization method for
// more information.
@attr('string', { readOnly: true }) attributes_http_method;
@attr('string', {
readOnly: true,
defaultValue: options.http_methods[0],
})
attributes_http_method;
@attr('string', { readOnly: true }) attributes_http_request_body;
@attr('string', { readOnly: true }) attributes_path;