Sha256: 566e7d9e60e87b91c781de6445321e9cab1db7ca9ed19fc3f251182d7450c6dd
Contents?: true
Size: 1.77 KB
Versions: 16
Compression:
Stored size: 1.77 KB
Contents
# frozen_string_literal: true module Cryptum # This plugin is used to Reload the Bot Conf When the "C" Key is Pressed module Event module Cancel # Supported Method Parameters:: # Cryptum::Event::Cancel.open_orders( # ) public_class_method def self.open_orders(opts = {}) terminal_win = opts[:terminal_win] option_choice = opts[:option_choice] env = opts[:env] # event_history = opts[:event_history] # order_type = opts[:order_type] # order_action = opts[:order_action] # Consume Latest Order History Justification from # Order Book & cancel orders tagged as pie # event_history = Cryptum::API.cancel_synced_oj_and_oh( # option_choice: option_choice, # env: env, # event_history: event_history, # order_type: order_type, # order_action: order_action # ) # event_history # event_history.order_canceled = true # event_history.event_notes = "{ \"event_type\": \"#{event_history.event_type}\", \"cancel\": \"#{event_history.order_canceled}\", \"submitted\": \"#{event_history.order_submitted}\" }" if option_choice.proxy # Cryptum::API.cancel_all_open_orders( # env: env, # option_choice: option_choice, # order_type: order_type, # event_notes: event_history.event_notes # ) terminal_win.key_press_event.key_c = false Cryptum::API.cancel_all_open_orders( env: env, option_choice: option_choice ) rescue StandardError => e raise e end # Display Usage for this Module public_class_method def self.help puts "USAGE: #{self}.open_orders() " end end end end
Version data entries
16 entries across 16 versions & 1 rubygems