Page 1 of 1

2.1.0 dataTable editMode="cell" input is not shown

Posted: 27 Dec 2019, 08:20
by vanuatoo
Hello,

I've upgraded to 2.1.0 and I'm having a problem.

Code: Select all

			    <p:remoteCommand name="onCellEdit" update="items"/>
                            <p:dataTable id="items" var="obj" value="#{mbean.items}" selectionMode="single"
                                         selection="#{mbean.selectedItem}" rowKey="#{obj.rowKey}" resizableColumns = "true"
                                         editable="true" editMode="cell" scrollWidth="100%">
                                <p:ajax event="cellEdit" oncomplete="onCellEdit()"/>
                                <p:column headerText="item" width="15%">
                                    <p:cellEditor>
                                        <f:facet name="output"><h:outputText value="#{obj.item.name}"/></f:facet>
                                        <f:facet name="input">
                                            <p:autoComplete id="itemsItem" value="#{obj.item}" completeMethod="#{mbean.completeItem}"
                                                            var="objitem" itemValue="#{objitem}" converter="itemConverter" 
                                                            minQueryLength="1" dropdown="true" forceSelection="true" panelStyle="width: auto" style="width: 100%">
                                                <p:column headerText="name">
                                                    <h:outputText value="#{objitem.name}"/>
                                                </p:column>
                                                <p:column headerText="code">
                                                    <h:outputText value="#{objitem.code}"/>
                                                </p:column>
                                                <p:column headerText="category">
                                                    <h:outputText value="#{msg['item.category.'.concat(objitem.itemType)]}"/>
                                                </p:column>
                                            </p:autoComplete>
                                        </f:facet>
                                    </p:cellEditor>
                                </p:column>
                                .....
When I click on the cell, it enters the edit mode, but when I type it does not show what I'm typing.

Re: 2.1.0 dataTable editMode="cell" input is not shown

Posted: 27 Dec 2019, 08:37
by aragorn
I couldn't replicate it. Do you get an error on console? Also, could you please try it without Ultima?

Best Regards,

Re: 2.1.0 dataTable editMode="cell" input is not shown

Posted: 27 Dec 2019, 09:37
by vanuatoo
I've got some error in the Console:

Code: Select all

core.js.xhtml?ln=primefaces&v=6.2.27:1 TypeError: Cannot read property 'undefined' of undefined
    at c.setCache (components.js.xhtml?ln=primefaces&v=6.2.27:3)
    at c.handle (components.js.xhtml?ln=primefaces&v=6.2.27:3)
    at Object.doUpdate (core.js.xhtml?ln=primefaces&v=6.2.27:3)
    at Object.handle (core.js.xhtml?ln=primefaces&v=6.2.27:3)
    at Object.onsuccess (components.js.xhtml?ln=primefaces&v=6.2.27:3)
    at Object.<anonymous> (core.js.xhtml?ln=primefaces&v=6.2.27:3)
    at i (jquery.js.xhtml?ln=primefaces&v=6.2.27:2)
    at Object.fireWith [as resolveWith] (jquery.js.xhtml?ln=primefaces&v=6.2.27:2)
    at A (jquery.js.xhtml?ln=primefaces&v=6.2.27:4)
    at XMLHttpRequest.<anonymous> (jquery.js.xhtml?ln=primefaces&v=6.2.27:4)
I tried without Ultima and it works fine.

Re: 2.1.0 dataTable editMode="cell" input is not shown

Posted: 31 Dec 2019, 14:45
by aragorn
This issue can be related to 6.2.27. Could you please try it with 7.0 version? I'll check this issue again.

Re: 2.1.0 dataTable editMode="cell" input is not shown

Posted: 31 Dec 2019, 15:02
by aragorn
Could you please try the following scss style for the first issue?

Code: Select all

/* Add your customizations of theme here */
body {
    .ui-datatable {
        tbody {
            tr {
                td {
                    &.ui-state-highlight {
                        .ui-inputfield {
                            color: $accentTextColor;
                        }
                    } 
                }
            }

            tr.ui-state-highlight {
                .ui-inputfield {
                    color: $accentColor;
                }
            }
        }
    }
}
You can add it into _theme_styles.scss and then provide new theme.css files using SASS command.

Best Regards,