fetch-jsd
Version:
57 lines (56 loc) • 2.69 kB
JavaScript
;
// tslint:disable
/**
* Service Desk Public REST API
* Public REST API for Jira Service Desk
*
* The version of the OpenAPI document: 1001.0.0-SNAPSHOT
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
Object.defineProperty(exports, "__esModule", { value: true });
const runtime_1 = require("../runtime");
const _1 = require("./");
function IssueBeanFromJSON(json) {
return IssueBeanFromJSONTyped(json, false);
}
exports.IssueBeanFromJSON = IssueBeanFromJSON;
function IssueBeanFromJSONTyped(json, ignoreDiscriminator) {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'expand': !runtime_1.exists(json, 'expand') ? undefined : json['expand'],
'id': !runtime_1.exists(json, 'id') ? undefined : json['id'],
'self': !runtime_1.exists(json, 'self') ? undefined : json['self'],
'key': !runtime_1.exists(json, 'key') ? undefined : json['key'],
'renderedFields': !runtime_1.exists(json, 'renderedFields') ? undefined : json['renderedFields'],
'properties': !runtime_1.exists(json, 'properties') ? undefined : json['properties'],
'names': !runtime_1.exists(json, 'names') ? undefined : json['names'],
'schema': !runtime_1.exists(json, 'schema') ? undefined : runtime_1.mapValues(json['schema'], _1.JsonTypeBeanFromJSON),
'transitions': !runtime_1.exists(json, 'transitions') ? undefined : json['transitions'].map(_1.IssueTransitionFromJSON),
'operations': !runtime_1.exists(json, 'operations') ? undefined : _1.OperationsFromJSON(json['operations']),
'editmeta': !runtime_1.exists(json, 'editmeta') ? undefined : _1.IssueUpdateMetadataFromJSON(json['editmeta']),
'changelog': !runtime_1.exists(json, 'changelog') ? undefined : _1.PageOfChangelogsFromJSON(json['changelog']),
'versionedRepresentations': !runtime_1.exists(json, 'versionedRepresentations') ? undefined : json['versionedRepresentations'],
'fieldsToInclude': !runtime_1.exists(json, 'fieldsToInclude') ? undefined : _1.IncludedFieldsFromJSON(json['fieldsToInclude']),
'fields': !runtime_1.exists(json, 'fields') ? undefined : json['fields'],
};
}
exports.IssueBeanFromJSONTyped = IssueBeanFromJSONTyped;
function IssueBeanToJSON(value) {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'fieldsToInclude': _1.IncludedFieldsToJSON(value.fieldsToInclude),
'fields': value.fields,
};
}
exports.IssueBeanToJSON = IssueBeanToJSON;