Class: OLE_QA::Framework::OLEFS::New_Copies_Line

Inherits:
Subline_Object show all
Defined in:
lib/olefs/subobjects/new_copies_line.rb

Overview

A new Copies Line on an OLE Financial System PURAP Line Object

Instance Attribute Summary

Attributes inherited from Subline_Object

#line_id, #line_number, #subline_id, #subline_number

Attributes inherited from Common_Object

#elements, #functions, #ole

Instance Method Summary collapse

Methods inherited from Common_Object

#set_functions

Methods included from Helpers

#browser, #load_yml, #set_element, #set_function

Constructor Details

#initialize(ole_session, line_number, which) ⇒ New_Copies_Line

Initialize as a subclass of Subline_Object with a subline_number of 0.



19
20
21
# File 'lib/olefs/subobjects/new_copies_line.rb', line 19

def initialize(ole_session, line_number, which)
  super(ole_session, line_number, 0)
end

Instance Method Details

#set_elementsObject

Note:

Line_Object @line_number and @line_id will be used to perform substitutions in identifiers.

Note:

Subline_Object @line_number and @line_id will not be need in finding element IDs, as there will only ever be one new subline object on each line object.

Set elements on a New Copies Line object.



29
30
31
32
33
34
35
# File 'lib/olefs/subobjects/new_copies_line.rb', line 29

def set_elements
  super
  element(:copies_field)                      {b.text_field(:id => "document.item[#{@line_id}].itemCopies")}
  element(:location_copies_selector)          {b.select_list(:id => "document.item[#{@line_id}].locationCopies")}
  element(:starting_copy_field)               {b.text_field(:id => "document.item[#{@line_id}].startingCopyNumber")}
  element(:add_button)                        {b.input(:name => "methodToCall.addCopy.line#{@line_id}")}
end