Solved

help needed when adding value from popup to grid

  • 15 February 2022
  • 2 replies
  • 355 views

Userlevel 2
Badge


hi, hoping someone can help me figure out how to resolve this issue  

We created a new action button in customer screen, on that button action, we are showing user a popup with input control to enter some value and two button either to Submit the data or to Cancel. The issue is, we are only able to get the value on Submit button action if the user tabs out after entering the value (or clicks out of the input field before clicking on submit. If  the  user doesn’t hit tab (or click out) then this entered value is not getting passed with the submission. We also have commit changes for the input control. Below is sample code.

Any help would be much appreciated.

 

```

<px:PXSmartPanel runat="server" Height="150px" Width="400px" ID="PXSmartPanel" LoadOnDemand="True" AutoRepaint="True" ShowAfterLoad="True" CaptionVisible="True" Caption="Apply Tiara Points" Key="Filter">
        <px:PXFormView runat="server" ID="PXFormViewFilter" Width="100%" DataSourceID="ds" DataMember="Filter">
            <Template>
                <px:PXLayoutRule runat="server" ID="CstPXLayoutRule9CTS" StartColumn="True" ColumnWidth="XL" />
                <px:PXNumberEdit runat="server" CommitChanges="True" DataField="DataField11" ID="edDataField11" />
                <px:PXPanel runat="server" ID="SerialPanelCTS" SkinID="Buttons2" Height="30px">
                    <px:PXButton runat="server" ID="edSubmitData" DialogResult="OK" CommandSourceID="ds" CommandName="SubmitData" />
                    <px:PXButton runat="server" ID="edCancelData" Text="Cancel" DialogResult="Cancel" CommandSourceID="ds" CommandName="CancelData" /></px:PXPanel></Template></px:PXFormView></px:PXSmartPanel>

icon

Best answer by jinin 15 February 2022, 16:11

View original

2 replies

Userlevel 7
Badge +11

Hi @ckwiat46 

I’ve added extra property on the smart panel. Please try like below. This code is working for me.

Sample code:

  <px:PXSmartPanel ID="pnlClearLog" runat="server" Caption="Clear Text" CaptionVisible="true" DesignView="Hidden" LoadOnDemand="true" Key="Filter" CreateOnDemand="false" AutoCallBack-Enabled="true" AutoCallBack-Target="formClearText" AutoCallBack-Command="Refresh" CallBackMode-CommitChanges="True" CallBackMode-PostData="Page" AcceptButtonID="btnOK" AutoReload="true">
        <px:PXFormView ID="formCleartext" runat="server" DataSourceID="ds" Style="z-index: 100" Width="100%" CaptionVisible="False" DataMember="ClearLogFilter">
            <ContentStyle BackColor="Transparent" BorderStyle="None" />
            <Template>
                <px:PXLayoutRule ID="PXLayoutRule44" runat="server" StartColumn="True" LabelsWidth="S" ControlSize="M" Merge="true" />                
                <px:PXDropDown ID="PXDropDownLevel" runat="server" CommitChanges="True" DataField="Level" LabelWidth="130px"></px:PXDropDown>
            </Template>
        </px:PXFormView>
        <px:PXPanel ID="PXPanel5" runat="server" SkinID="Buttons">
            <px:PXButton ID="btnOK" runat="server" DialogResult="OK" Text="OK"></px:PXButton>
            <px:PXButton ID="btnCancel" runat="server" DialogResult="Cancel" Text="Cancel"></px:PXButton>
        </px:PXPanel>
    </px:PXSmartPanel>

Userlevel 7
Badge +17

Hi @ckwiat46  I just modified your code and hope this helps!!

<px:PXSmartPanel runat="server" Height="150px" Width="400px" ID="PXSmartPanel" LoadOnDemand="True" AutoRepaint="True" 
ShowAfterLoad="True" CaptionVisible="True" Caption="Apply Tiara Points" Key="Filter"
AutoCallBack-Target="formGetSchema" AutoCallBack-Command="Refresh" CallBackMode-CommitChanges="True" CallBackMode-PostData="Page">
<px:PXFormView runat="server" ID="PXFormViewFilter" Width="100%" DataSourceID="ds" DataMember="Filter">
<Template>
<px:PXLayoutRule runat="server" ID="CstPXLayoutRule9CTS" StartColumn="True" ColumnWidth="XL" />
<px:PXNumberEdit runat="server" CommitChanges="True" DataField="DataField11" ID="edDataField11" />
</Template>
</px:PXFormView>

<px:PXPanel runat="server" ID="SerialPanelCTS" SkinID="Buttons" Height="30px">
<px:PXButton ID="edSubmitData" runat="server" DialogResult="OK" Text="OK">
<AutoCallBack Target="formGetSchema" Command="Save" />
</px:PXButton>

<px:PXButton ID="edCancelData" runat="server" DialogResult="Cancel" Text="Cancel">
<AutoCallBack Target="formGetSchema" Command="Cancel" />
</px:PXButton>
</px:PXPanel></Template></px:PXFormView></px:PXSmartPanel>

 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved