This object is the base class that can be
used to build a widget that shows lists of data from any source via the DataListSource object. It fetches/builds/gets its data from the DataListSource object, which can be written to support any data source (MySQL, Oracle, comma delimited file, xml, etc.)
This base class MUST be extended by a child to actually render the list. The job of the DataList class is to provide the basic API and abstraction mechanism to handling searching, showing, sorting lists of data.
Each column of data is associated with a title and a name. The title is what is shown to the user for that column. The name is the mapping between the column and the DataListSource. Each column can be marked as sortable and searchable. If a column is sortable, the title is a link that can be clicked on to sort. The sorting is done in the DataListSource object ( via the sql query, or sort() functions depending on the data source itself)
The DataList object will build the title, the search block (if any), the datalist controls (the links/imges for first, prev, next, last, all). Then the data columns/labels. Then it will fetch each of the rows of data to display from the DataListSource.
The logic of the output calls follows in the order:
title search table/block datalist controls (first, prev, next, last, all) data columns/labels data rows x through y
REQUIREMENTS: You must use/define a DataListSource object. You MUST override/extend the following methods:
* get_data_source() - used to set the DataListSource by this class. * user_setup() - used to set the columns to show and any options used by the DataList class and DataListSource object.
UI ABSTRACTION METHODS These methods allow for some level of abstraction for the layout/look/feel of the actual list of data.
* gui_init() - the function gives the child class a chance to do any building of the objects that will hold the search area, column headers and the rows of data.
* child_build_column_header() - This method is responsible for building and inserting the column header title into the UI object.
* child_add_row_cell() - This function is responsible for adding the cell in the current row. The method is responsible for keeping track of the location in its UI object for the current row.
* child_get_gui() - This method returns the entire UI in 1 object or container. At this point the entire UI has been constructed, the entire list of data has been walked and inserted.
Located in /widgets/data_list/SimpleGUIDataList.inc (line 15)
Container | --BaseWidget | --DataList | --SimpleGUIDataList
Inherited from DataList
DataList::$_advanced_search_flag
DataList::$_clean_string
DataList::$_columns
DataList::$_datasource
DataList::$_debug
DataList::$_default_orderby
DataList::$_default_reverseorder
DataList::$_default_rows_per_page
DataList::$_form_attributes
DataList::$_form_render_flag
DataList::$_global_prefix
DataList::$_image_path
DataList::$_max_rows
DataList::$_not_found_message
DataList::$_num_columns
DataList::$_num_pages
DataList::$_save_vars
DataList::$_search_flag
DataList::$_search_table
DataList::$_show_all_rows
DataList::$_show_results_flag
DataList::$_simple_search_modifier
DataList::$_vars
Inherited from BaseWidget
BaseWidget::$title
BaseWidget::$width
BaseWidget::$_image_prefix
This function builds the object/text
to be used for a column header. It can either be an href because its sortable, or it can just be text, because its not sortable.
Initialize the gui layout
This function ensures that the data we place in a column is aligned according to what the user wants.
Inherited From DataList
DataList::DataList()
DataList::add_header_item()
DataList::advanced_search_disable()
DataList::advanced_search_enable()
DataList::build_base_url()
DataList::build_column_item()
DataList::build_column_url()
DataList::build_gui()
DataList::build_orderby_querystring()
DataList::build_reverseorder_querystring()
DataList::build_searchfield_querystring()
DataList::build_searchvalue_querystring()
DataList::build_state_vars_query_string()
DataList::build_tool_link()
DataList::child_add_row_cell()
DataList::child_build_column_header()
DataList::child_build_search_table()
DataList::child_get_gui()
DataList::data_prefetch()
DataList::do_action()
DataList::expandrows()
DataList::filter_column_string()
DataList::get_cleanstring()
DataList::get_current_page()
DataList::get_data_source()
DataList::get_default_num_rows()
DataList::get_form_action()
DataList::get_form_method()
DataList::get_form_name()
DataList::get_form_render()
DataList::get_form_target()
DataList::get_global_prefix()
DataList::get_image_path()
DataList::get_last_page()
DataList::get_max_rows()
DataList::get_not_found_message()
DataList::get_num_pages()
DataList::get_page_info()
DataList::get_showall()
DataList::get_simple_search_modifier()
DataList::gui_init()
DataList::is_advanced_search_enabled()
DataList::is_search_enabled()
DataList::numrows()
DataList::offset()
DataList::orderby()
DataList::pre_query_sanity_check()
DataList::render()
DataList::reverseorder()
DataList::search_disable()
DataList::search_enable()
DataList::search_field()
DataList::search_type()
DataList::search_value()
DataList::search_value_filter()
DataList::setup_columns()
DataList::set_cleanstring()
DataList::set_data_source()
DataList::set_debug()
DataList::set_default_num_rows()
DataList::set_expandrows()
DataList::set_form_action()
DataList::set_form_method()
DataList::set_form_name()
DataList::set_form_render()
DataList::set_form_target()
DataList::set_global_prefix()
DataList::set_image_path()
DataList::set_max_rows()
DataList::set_not_found_message()
DataList::set_numrows()
DataList::set_offset()
DataList::set_orderby()
DataList::set_reverseorder()
DataList::set_save_vars()
DataList::set_search_type()
DataList::set_showall()
DataList::set_show_results()
DataList::set_simple_search_modifier()
DataList::simple_search_modifier_value()
DataList::user_setup()
DataList::_build_default_vars()
DataList::_build_save_vars()
DataList::_build_simple_search_modifier()
DataList::_build_tool_url()
DataList::_check_datasource()
DataList::_clean_string()
DataList::_filter_column_string()
DataList::_get()
DataList::_get_searchable_fields()
DataList::_javascript()
DataList::_save_mozilla_nav_link()
DataList::_set()
DataList::_show_results()
Inherited From BaseWidget
BaseWidget::get_align()
BaseWidget::get_css()
BaseWidget::get_javascript()
BaseWidget::get_title()
BaseWidget::get_width()
BaseWidget::set_align()
BaseWidget::set_image_path_prefix()
BaseWidget::set_title()
BaseWidget::set_width()
Inherited From Container
Container::Container()
Container::add()
Container::add_reference()
Container::count_content()
Container::get_element()
Container::get_indent_flag()
Container::push()
Container::push_reference()
Container::render()
Container::reset_content()
Container::set_collapse()
Container::set_indent_flag()
Documentation generated on Fri, 28 Jan 2011 08:53:12 -0500 by phpDocumentor 1.4.3