ICEfaces
  1. ICEfaces
  2. ICE-9869

New mobi:dataView, dataViewColumn(s), and dataViewDetails components

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0.BETA, 4.0
    • Component/s: MOBI-Components
    • Labels:
      None
    • Environment:
      ICEfaces 4
    • Assignee Priority:
      P1
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial

      Description

      mobi:dataView component renders a table region for iterative output using columns defined with the required DataViewColumns component child, and a detail region for extensive viewing (and editing) of the row objects of the table model. The detail region is defined with the DataViewDetails child component and it's contents are displayed when a row of table region is activated, typically by a row tap.

      mobi:dataViewColumns defines a column in the table region of the DataView component.

      mobi:dataViewColumns component defines the table region of the DataView component either by its DataViewColumn child components or by attaching an implementationof DataViewColumnsModel to the 'value' attribute of this component.

      mobi:dataViewDetail - The child components of this component define the region to be displayed when a row object of DataView table region is activated. When DataView 'activationMode' is set to 'server' the child components of this region may be arbitrary JSF components. When 'activationMode' is set to 'client' the child components of this region are prerendered and have their dynamic attributes cached on the client to allow instantaneous activation. Client activation mode is restricted to particular components and only particular attributes of these components may be dynamic, the specifics are documented on our wiki.

        Activity

        Ken Fyten created issue -
        Ken Fyten made changes -
        Field Original Value New Value
        Summary New mobi:dataView components New mobi:dataView, dataViewColumn(s), and dataViewDetails components
        Description mobi:smallView will include and render the child components when the client is a handheld.

        mobi:largeView will include and render the child components when the client is a desktop or tablet view.
        mobi:dataView component renders a table region for iterative output using columns defined with the required DataViewColumns component child, and a detail region for extensive viewing (and editing) of the row objects of the table model. The detail region is defined with the DataViewDetails child component and it's contents are displayed when a row of table region is activated, typically by a row tap.

        mobi:dataViewColumns defines a column in the table region of the DataView component.

        mobi:dataViewColumns component defines the table region of the DataView component either by its DataViewColumn child components or by attaching an implementationof DataViewColumnsModel to the 'value' attribute of this component.

        mobi:dataViewDetail - The child components of this component define the region to be displayed when a row object of DataView table region is activated. When DataView 'activationMode' is set to 'server' the child components of this region may be arbitrary JSF components. When 'activationMode' is set to 'client' the child components of this region are prerendered and have their dynamic attributes cached on the client to allow instantaneous activation. Client activation mode is restricted to particular components and only particular attributes of these components may be dynamic, the specifics are documented on our wiki.

        Ken Fyten made changes -
        Link This issue depends on MOBI-876 [ MOBI-876 ]
        Ken Fyten made changes -
        Component/s MOBI-Components [ 10270 ]
        Component/s ACE-Components [ 10050 ]
        Hide
        Cruz Miraback added a comment -

        Test Results

        ICEfaces4 trunk revision# 40043

        General:
        1) The rowIndexVar attribute doesn't seem to do anything, I tried printing it out in a dataViewColumn and in the dataViewDetails region but it is always empty.

        2) Trying to use the markup attribute just throws a NullPointerException. This is probably because getMarkup() in org.icefaces.mobi.component.dataview.DataViewColumn.java is just returning null and not the actual value from the page. Currently the attribute is unusable.

        3) The reactivePriority attribute isn't always respected. A column of type boolean with low priority will remain visible while columns with higher priority are hidden.

        4) There are JS errors when changing reactiveColumnVisibility, reactivePriority and activationMode attributes dynamically:

        Error when changing reactiveColumnVisibility or activationMode dynamically:
        [window] Error [status: malformedXML code: 200]: During update: form:dataView_js not found

        Error when changing reactivePriority dynamically:
        [window] Error [status: malformedXML code: 200]: Argument 1 of Node.replaceChild is not an object.

        5) Setting activeRowIndex to null displays the first row in the detail region (same results as 0). It seems null should display nothing in the detail region because currently a row always appears active/selected if using this attribute.

        Styling issues:
        1) There is no styling (incl. header/footer) on the dataView unless using rowStripe and rowStroke attributes.

        2) When using a column with the "bool" type no checkbox is rendered because the styling is missing.

        3) The rows cannot be selected in the desktop view like they can be in showcase, think this might be something related to the styling? They can be selected on a mobile device.

        Doc issues:
        1) Rendered attribute not listed in the tlddoc for dataViewColumn component but attribute is functional and used in showcase demo.

        2) tlddoc for dataViewColumn type attribute reads "..f:dateTimeConverter..", but it should be "..f:convertDateTime..".

        Not tested:
        1) I haven't created a test for the value attribute of dataViewColumns because there is no documentation when implementing DataViewColumnsModel. It's difficult to understand the implemented methods.

        2) Uncertain best way to test the "client" activationMode.

        Show
        Cruz Miraback added a comment - Test Results ICEfaces4 trunk revision# 40043 General: 1) The rowIndexVar attribute doesn't seem to do anything, I tried printing it out in a dataViewColumn and in the dataViewDetails region but it is always empty. 2) Trying to use the markup attribute just throws a NullPointerException. This is probably because getMarkup() in org.icefaces.mobi.component.dataview.DataViewColumn.java is just returning null and not the actual value from the page. Currently the attribute is unusable. 3) The reactivePriority attribute isn't always respected. A column of type boolean with low priority will remain visible while columns with higher priority are hidden. 4) There are JS errors when changing reactiveColumnVisibility, reactivePriority and activationMode attributes dynamically: Error when changing reactiveColumnVisibility or activationMode dynamically: [window] Error [status: malformedXML code: 200] : During update: form:dataView_js not found Error when changing reactivePriority dynamically: [window] Error [status: malformedXML code: 200] : Argument 1 of Node.replaceChild is not an object. 5) Setting activeRowIndex to null displays the first row in the detail region (same results as 0). It seems null should display nothing in the detail region because currently a row always appears active/selected if using this attribute. Styling issues: 1) There is no styling (incl. header/footer) on the dataView unless using rowStripe and rowStroke attributes. 2) When using a column with the "bool" type no checkbox is rendered because the styling is missing. 3) The rows cannot be selected in the desktop view like they can be in showcase, think this might be something related to the styling? They can be selected on a mobile device. Doc issues: 1) Rendered attribute not listed in the tlddoc for dataViewColumn component but attribute is functional and used in showcase demo. 2) tlddoc for dataViewColumn type attribute reads "..f:dateTimeConverter..", but it should be "..f:convertDateTime..". Not tested: 1) I haven't created a test for the value attribute of dataViewColumns because there is no documentation when implementing DataViewColumnsModel. It's difficult to understand the implemented methods. 2) Uncertain best way to test the "client" activationMode.
        Show
        Cruz Miraback added a comment - Test application is located at: http://dev.icesoft.com/svn/repo/qa/trunk/Regression-Icefaces4/Sparkle/Manual/dataView
        Hide
        Arturo Zambrano added a comment - - edited

        Indirectly fixed the missing styling issue at revision 40097.

        At revision 40101, removed IDataView interface and added font awesome resource dependency to display columns of type bool.

        Show
        Arturo Zambrano added a comment - - edited Indirectly fixed the missing styling issue at revision 40097. At revision 40101, removed IDataView interface and added font awesome resource dependency to display columns of type bool.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40101 Thu Feb 27 14:56:20 MST 2014 art.zambrano ICE-9869 removed IDataView interface; added font awesome resource dependency to display columns of type bool
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataView.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewMeta.java
        Commit graph DEL /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/IDataView.java
        Hide
        Arturo Zambrano added a comment -

        Fixed documentation issues at revision 40103.

        Show
        Arturo Zambrano added a comment - Fixed documentation issues at revision 40103.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40102 Thu Feb 27 15:03:42 MST 2014 art.zambrano ICE-9869 made Meta classes extend UIComponentBaseMeta for TLD doc purposes
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumnMeta.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumnsMeta.java
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40103 Thu Feb 27 15:05:55 MST 2014 art.zambrano ICE-9869 fixed tlddoc detail
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumnMeta.java
        Hide
        Arturo Zambrano added a comment -

        Added support for 'rowIndexVar' at revision 40112.

        Show
        Arturo Zambrano added a comment - Added support for 'rowIndexVar' at revision 40112.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40112 Mon Mar 03 10:18:56 MST 2014 art.zambrano ICE-9869 added support for rowIndexVar
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewRenderer.java
        Hide
        Arturo Zambrano added a comment -

        As for issue #5, it seems that the same situation happens with any property of Integer type. If the attribute doesn't appear in the component tag, then the value is null, and things work as expected, but when the attribute appears in the tab, it is automatically made non-null and the default Integer object is created, which has a value of 0. This happens even if you explicitly set the value of the property to null.

        It is not clear if this is a problem with the generator or if it simply has to do with generics converting to the native int type at some point. It's not possible to compare with the stock JSF components, since none of their properties is of Integer type. Only the property 'tabindex' is handled as an Integer type, but in the documentation it is actually a String, which is converted to Integer.

        As is common in many different areas of Java, when dealing with indexes, a value of -1 (or any negative value) will be treated as the index not being set or not being valid. So the DataView code was modified to handle negative values of 'activeRowIndex' as no index specified. The TLD documentation was also updated to describe this behaviour.

        Committed fix to trunk at revision 40115.

        Show
        Arturo Zambrano added a comment - As for issue #5, it seems that the same situation happens with any property of Integer type. If the attribute doesn't appear in the component tag, then the value is null, and things work as expected, but when the attribute appears in the tab, it is automatically made non-null and the default Integer object is created, which has a value of 0. This happens even if you explicitly set the value of the property to null. It is not clear if this is a problem with the generator or if it simply has to do with generics converting to the native int type at some point. It's not possible to compare with the stock JSF components, since none of their properties is of Integer type. Only the property 'tabindex' is handled as an Integer type, but in the documentation it is actually a String, which is converted to Integer. As is common in many different areas of Java, when dealing with indexes, a value of -1 (or any negative value) will be treated as the index not being set or not being valid. So the DataView code was modified to handle negative values of 'activeRowIndex' as no index specified. The TLD documentation was also updated to describe this behaviour. Committed fix to trunk at revision 40115.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40115 Tue Mar 04 09:55:05 MST 2014 art.zambrano ICE-9869 modification to interpret a negative activeRowIndex as no row being active; updated TLD documentation
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewRenderer.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewMeta.java
        Hide
        Arturo Zambrano added a comment -

        Fixed issue #4 at revision 40116 by removing the client id from the <script> element, in order to avoid domdiff trying to update that node, which is usually removed from the markup; the wrapping span element will be used instead.

        Show
        Arturo Zambrano added a comment - Fixed issue #4 at revision 40116 by removing the client id from the <script> element, in order to avoid domdiff trying to update that node, which is usually removed from the markup; the wrapping span element will be used instead.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40116 Tue Mar 04 10:01:19 MST 2014 art.zambrano ICE-9869 fixed JS errors by removing client id from <script> element, in order to avoid domdiff trying to update that node, which is usually removed from the markup; the wrapping span element will be used instead
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewRenderer.java
        Hide
        Arturo Zambrano added a comment -

        As for issue #2, removed 'markup' attribute and its related handling at revision 40117, because it's not applicable to the facelet case, since we can't define arbitrary HTML in a facelet attribute.

        Show
        Arturo Zambrano added a comment - As for issue #2, removed 'markup' attribute and its related handling at revision 40117, because it's not applicable to the facelet case, since we can't define arbitrary HTML in a facelet attribute.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40117 Tue Mar 04 10:15:56 MST 2014 art.zambrano ICE-9869 removed 'markup' attribute and its related handling, because it's not applicable to the facelet case, since we can't define arbitrary html in a facelet attribute
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumn.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumnMeta.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewRenderer.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/model/dataview/DataViewColumnModel.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/ColumnType.java
        Hide
        Arturo Zambrano added a comment -

        As for issue #3, it seems like the reactive priority feature wasn't implemented at all in the client. There's no code that reads the array of column priorities in the Javascript code of dataView.

        Show
        Arturo Zambrano added a comment - As for issue #3, it seems like the reactive priority feature wasn't implemented at all in the client. There's no code that reads the array of column priorities in the Javascript code of dataView.
        Hide
        Arturo Zambrano added a comment -

        Removed reactive column visibility functionality at revision 40274, since it was incomplete. Created ICE-9893 to completely implement such functionality.

        Show
        Arturo Zambrano added a comment - Removed reactive column visibility functionality at revision 40274, since it was incomplete. Created ICE-9893 to completely implement such functionality.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40274 Wed Mar 05 14:00:32 MST 2014 art.zambrano ICE-9869 removed code related to reactive column visibility, since it's incomplete
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumn.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewColumnMeta.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataView.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewRenderer.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/component/dataview/DataViewMeta.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/src/org/icefaces/mobi/model/dataview/DataViewColumnModel.java
        Hide
        Ken Fyten added a comment -

        DataView row selection via single click on the row isn't working. This should highlight the selected row and populate the editable region in the dataView with that rows contents. Seems to work in ICEmobile 1.3 on Safari, but not FF for some reason.

        Show
        Ken Fyten added a comment - DataView row selection via single click on the row isn't working. This should highlight the selected row and populate the editable region in the dataView with that rows contents. Seems to work in ICEmobile 1.3 on Safari, but not FF for some reason.
        Hide
        Cruz Miraback added a comment - - edited

        ICEfaces4 trunk revision# 40274

        #1 - confirmed fixed, the rowIndexVar attribute is now functioning.
        #2 - nothing to confirm, removed markup attribute from tests since it is not valid.
        #3 - nothing to confirm, will leave reactivePriority in tests so it is there when ICE-9893 is complete.
        #4 - confiremd fixed, JS errors are no longer present.
        #5 - confirmed new behaviour is working as expected.

        All styling issues (#1,#2,#3) are confirmed fixed.
        All doc issues (#1,#2) are confirmed fixed.

        No issues remaining from initial report.

        Show
        Cruz Miraback added a comment - - edited ICEfaces4 trunk revision# 40274 #1 - confirmed fixed, the rowIndexVar attribute is now functioning. #2 - nothing to confirm, removed markup attribute from tests since it is not valid. #3 - nothing to confirm, will leave reactivePriority in tests so it is there when ICE-9893 is complete. #4 - confiremd fixed, JS errors are no longer present. #5 - confirmed new behaviour is working as expected. All styling issues (#1,#2,#3) are confirmed fixed. All doc issues (#1,#2) are confirmed fixed. No issues remaining from initial report.
        Hide
        Cruz Miraback added a comment -

        Row selection issue reported by Ken can be reproduced in Firefox27. In Chrome and IE11 the rows can be selected and the dataViewDetails region shown but they cannot be de-selected.

        Show
        Cruz Miraback added a comment - Row selection issue reported by Ken can be reproduced in Firefox27. In Chrome and IE11 the rows can be selected and the dataViewDetails region shown but they cannot be de-selected.
        Hide
        Arturo Zambrano added a comment - - edited

        Committed fix that solves activation issues (except in Firefox) at revision 40339. The Firefox issue is a JS error in the bridge-support code.

        To reproduce simply load dataViewDynAttribute.jsf in the test app, activate the 'rendered' checkbox to display the table, and try clicking on any (unselected) row a few times. An error will appear in the console, which occurs in the brdige-support code and seems to be related to logging.

        Show
        Arturo Zambrano added a comment - - edited Committed fix that solves activation issues (except in Firefox) at revision 40339. The Firefox issue is a JS error in the bridge-support code. To reproduce simply load dataViewDynAttribute.jsf in the test app, activate the 'rendered' checkbox to display the table, and try clicking on any (unselected) row a few times. An error will appear in the console, which occurs in the brdige-support code and seems to be related to logging.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40339 Thu Mar 13 15:25:30 MDT 2014 art.zambrano ICE-9869 fix for issue with not being able to select rows in Chrome
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/resources/org.icefaces.component.util/component.js
        Ken Fyten made changes -
        Assignee Arturo Zambrano [ artzambrano ] Mircea Toma [ mircea.toma ]
        Assignee Priority P1 [ 10010 ]
        Hide
        Mircea Toma added a comment -

        Modified isRowEvent function to alternatively use Event.target property in browsers where the equivalent Event.srcElement property is not available.

        Show
        Mircea Toma added a comment - Modified isRowEvent function to alternatively use Event.target property in browsers where the equivalent Event.srcElement property is not available.
        Mircea Toma made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40366 Tue Mar 18 16:59:55 MDT 2014 mircea.toma ICE-9869 Modified isRowEvent function to alternatively use Event.target property in browsers where the equivalent Event.srcElement property is not available.
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/mobi/component/resources/org.icefaces.component.util/component.js
        Hide
        Cruz Miraback added a comment -

        ICEfaces4 trunk revision# 40400

        Confirmed JS error in Firefox no longer occurs and that the rows can be selected.

        Show
        Cruz Miraback added a comment - ICEfaces4 trunk revision# 40400 Confirmed JS error in Firefox no longer occurs and that the rows can be selected.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #41504 Tue Jun 24 10:09:53 MDT 2014 philip.breau ICE-9869 mobi:dataView
        - update dataView for font awesome 4.1
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/resources/org.icefaces.component.util/component.js
        Ken Fyten made changes -
        Fix Version/s 4.0 [ 11382 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Mircea Toma
            Reporter:
            Ken Fyten
          • Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: