Sha256: 26430c9f41395302e3d9aeeb7d964ba179dcef5c449f213a245600f4bfaa7fee
Contents?: true
Size: 1.18 KB
Versions: 66
Compression:
Stored size: 1.18 KB
Contents
## # source_gp_id string The source feature id # new_gp_id string New feature id # name string New Feature Plan name # description boolean New Feature Plan description # # Method: featurePlans.clone module Alula class FeaturePlanCloneProc < Alula::RpcResource class Response < Alula::RpcResponse def initialize(response) super(response) # # This RPC response gives a new FeaturePlan item data = response.data['result'][0] attributes = { id: data['id'], gp_id: data['gp_id'], name: data['name'], description: data['description'], } @data = Alula::FeaturePlan.new(data['id'], attributes) end def ok? @result.is_a?(Array) || (@result['errors'].nil? && @result['error'].nil?) end end def self.call(source_gp_id:, new_gp_id:, name:, description: "") payload = { sourceGpId: source_gp_id, newGpId: new_gp_id, name: name, description: description } request( http_method: :post, path: '/rpc/v1/features/clone', payload: payload, handler: Response ) end end end
Version data entries
66 entries across 66 versions & 1 rubygems