module Ecoportal module API class GraphQL module Payload module LocationStructure class ApplyCommands < Ecoportal::API::GraphQL::Base::Model passthrough :clientMutationId embeds_one :structure, klass: Ecoportal::API::GraphQL::Model::LocationStructure embeds_one :errors, klass: Ecoportal::API::GraphQL::Error::ValidationErrors, nullable: true embeds_one :error, klass: Ecoportal::API::GraphQL::Error::LocationsError, nullable: true embeds_many :results, read_only: true, klass: Ecoportal::API::GraphQL::Payload::LocationStructure::CommandExecutionResult def success? !errors? end def errors? errors && !errors.empty? end end end end end end end