class CreateApiSteps
Public Class Methods
down()
click to toggle source
# File lib/generators/starkit_banking/templates/api_step.rb, line 23 def self.down drop_table :api_steps end
up()
click to toggle source
# File lib/generators/starkit_banking/templates/api_step.rb, line 2 def self.up create_table :api_steps, force: true do |table| table.integer :star_id, null: false, comment: 'the id column in the organization table' table.string :step_name, null: false, comment: 'the name of the api step' table.string :auditable_type, null: false, comment: 'the type of the parent for which this api call has been made' table.integer :auditable_id, null:false, comment: 'the id of the parent for which this api call has been made' table.string :status_code, comment: 'the http status code for the api response' table.string :req_reference, comment: 'the reference number for the api request' table.datetime :req_timestamp, comment: 'the timestamp this api request was made' table.text :req_bitstream, comment: 'the xml request for the api call' table.string :rep_reference, comment: 'the reference number in the api response' table.datetime :rep_timestamp, comment: 'the timestamp this api response was received' table.text :rep_bitstream, comment: 'the xml of the api response' table.string :fault_code, comment: 'the fault code for api in case of error' table.string :fault_subcode, comment: 'the fault sub-code for api in case of error' table.string :fault_reason, comment: 'the fault reason for api in case of error' end add_index :api_steps, [:star_id, :auditable_type, :auditable_id], name: 'idx_audits_api_steps' end