CreateProjectDetails.fromJson constructor

CreateProjectDetails.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory CreateProjectDetails.fromJson(Map<String, Object?> json) {
  return CreateProjectDetails(
    assigneeType: json[r'assigneeType'] != null
        ? CreateProjectDetailsAssigneeType.fromValue(
            json[r'assigneeType']! as String)
        : null,
    avatarId: (json[r'avatarId'] as num?)?.toInt(),
    categoryId: (json[r'categoryId'] as num?)?.toInt(),
    description: json[r'description'] as String?,
    fieldConfigurationScheme:
        (json[r'fieldConfigurationScheme'] as num?)?.toInt(),
    issueSecurityScheme: (json[r'issueSecurityScheme'] as num?)?.toInt(),
    issueTypeScheme: (json[r'issueTypeScheme'] as num?)?.toInt(),
    issueTypeScreenScheme: (json[r'issueTypeScreenScheme'] as num?)?.toInt(),
    key: json[r'key'] as String? ?? '',
    lead: json[r'lead'] as String?,
    leadAccountId: json[r'leadAccountId'] as String?,
    name: json[r'name'] as String? ?? '',
    notificationScheme: (json[r'notificationScheme'] as num?)?.toInt(),
    permissionScheme: (json[r'permissionScheme'] as num?)?.toInt(),
    projectTemplateKey: json[r'projectTemplateKey'] != null
        ? CreateProjectDetailsProjectTemplateKey.fromValue(
            json[r'projectTemplateKey']! as String)
        : null,
    projectTypeKey: json[r'projectTypeKey'] != null
        ? CreateProjectDetailsProjectTypeKey.fromValue(
            json[r'projectTypeKey']! as String)
        : null,
    url: json[r'url'] as String?,
    workflowScheme: (json[r'workflowScheme'] as num?)?.toInt(),
  );
}