Hi,

In my app I have datagrid component with data from Employee tabele, name of datasource is Employee_1. That table have column Ind_Active which is represented in grid with CheckBox (alowed values are 0 and 1). For detail view of some record I had created I new dialog and in that dialog I show data from selected row from grid. In that dialog I show data from same datasoure as I use in datagrid, Employee_1. All data are OK except Ind_Active which is checkbox on that dialog too. When I run app for the first time and when I go to show data in that dialog checkbox Ind_Active is always unchecked no matter what is value of that column, but every other time when I open that dialog state of check box is OK and it represent correct value of that column. It work until I don't restart application and again when I open that dialog for the firs time after restart value is unchecked and again when I close dialog and open again value is OK.

asked 08 Jan '16, 09:23

Zigfrid's gravatar image

Zigfrid
111
accept rate: 0%


Hi Zigfrid,

I did a quick test and everything seems to be working correctly for me. Can you please copy and paste your panel XML and SQL and PL/SQL code here?

Kind Regards, Yalim

link

answered 11 Jan '16, 06:59

Yalim's gravatar image

Yalim ♦♦
2.8k5
accept rate: 21%

Yes, of course. Here is XML for panel where is grid:

<panel bordertitle="Radnici"> <tablelayout cellspacing="2"> <row height="30"> <cell halign="Left"> <include panelname="sifarnikRadnikTopPanel"/> </cell> </row> <row> <cell halign="Full" valign="Full"> <grid editable="N" datasource="EMPLOYEE1" scrollbarpolicy="Always"> <column headerlabel="#{lang.empid}" width="60" headertextalign="Center"> <textlabel name="radnik_id" text-align="Right" column="RADNIK_ID"/> </column> <column headerlabel="#{lang.empname}" headertextalign="Center" sortable="Y"> <textfield enable="#{sec.keyruk}" text-align="Left" column="IME_PREZIME"/> </column> <column headerlabel="#{lang.username}" headertextalign="Center"> <textfield name="username" enable="#{sec.keyruk}" text-align="Left" column="USERNAME"/> </column> <column visible="N" headerlabel="#{lang.password}" headertextalign="Center"> <textfield visible="N" enable="#{sec.keyruk}" text-align="Right" column="PASSWORD"/> </column> <column headerlabel="#{lang.leader}" headertextalign="Center"> <combobox enable="#{sec.keyruk}" displaycolumn="IME_PREZIME" valuecolumn="RADNIK_ID" column="RUKOVODILAC_ID" listdatasource="RUKOVODILAC_CBOX1"/> </column> <column headerlabel="#{lang.active}" width="50" headertextalign="Center"> <checkbox name="indakt" column="IND_ACTIVE" checkedvalue="1" uncheckedvalue="0"/> </column> <column headerlabel="#{lang.empisleader}" width="70" headertextalign="Center"> <checkbox name="indruk" column="IND_RUKOVODILAC" checkedvalue="1" uncheckedvalue="0"/> </column> <column headerlabel="#{lang.companipart}" headertextalign="Center" sortable="Y"> <combobox name="deopred" displaycolumn="NAZIV" valuecolumn="ID" column="DELOVI_PREDUZECA_ID" listdatasource="DELOVI_PREDUZECA1"/> </column> <column headerlabel="#{lang.sector}" headertextalign="Center" sortable="Y"> <combobox name="sektor" displaycolumn="NAZIV" valuecolumn="SEKTOR_ID" column="SEKTOR_ID" listdatasource="SEKTORI1"/> </column> </grid> </cell> </row> </tablelayout> </panel>

I've Edit button whitch call this action

procedure editEmployee is begin
radni.kreirajSessVarRadnik(api_component.getvaluenr('sifarnikRadnikPanel.radnik_id')); -- this create some sesion var

api_component.setvalue('radnikIzmeniSinglePanel.pass', api_session.getvaluetx('PASSWORD'));
api_component.setvalue('radnikIzmeniSinglePanel.ponovljenpass', api_session.getvaluetx('PASSWORD'));

api_panel.addpanel('employeeDialogCenterPanel', 'dialog_center_cell', 'empEditSinglePanel'); -- same dilog I use for insert and edit, this is why I do this api_dialog.settitle('radnikDialog', '#{lang.changeempdata}'); api_dialog.setVisible('radnikDialog','Y');

api_component.setvalue('radnikIzmeniSinglePanel.ponovljenpass', api_component.getvaluetx('radnikIzmeniSinglePanel.pass') ); end;

Panel "empEditSinglePanel" which is in this dialog is here:

<panel> <tablelayout cellspacing="3"> <row> <cell width="120" halign="Right"> <textlabel label="#{lang.empid}" text-align="Right"/> </cell> <cell width="200" halign="Full"> <textfield enable="N" text-align="Left" column="RADNIK_ID" datasource="EMPLOYEE1"/> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.empname}" text-align="Right"/> </cell> <cell halign="Full"> <textfield name="imeprezime" text-align="Left" column="IME_PREZIME" datasource="EMPLOYEE1"/> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.username}" text-align="Right"/> </cell> <cell halign="Full"> <textfield name="username" enable="Y" text-align="Left" domain="userNameDomain" column="USERNAME" datasource="EMPLOYEE1"> <events> <valuechanged action="desilaSePromenaUsername"/> </events> </textfield> </cell> </row> <row> <cell halign="Right"> <textlabel enable="N" label="#{lang.password}" text-align="Right"/> </cell> <cell halign="Full"> <passwordfield name="pass" text-align="Left" domain="passwordDomain"/> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.repassword}" text-align="Right"/> </cell> <cell halign="Full"> <passwordfield name="ponovljenpass" text-align="Left" domain="passwordDomain"> <events> <focuslost action="kontrolaIzmenepodataRadnika"/> </events> </passwordfield> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.leader}" text-align="Right"/> </cell> <cell halign="Full"> <combobox displaycolumn="IME_PREZIME" valuecolumn="RADNIK_ID" column="RUKOVODILAC_ID" datasource="EMPLOYEE1" listdatasource="RUKOVODILAC_CBOX1"/> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.empisleader}" text-align="Right"/> </cell> <cell halign="Left"> <checkbox name="indrukchk" column="IND_RUKOVODILAC" datasource="EMPLOYEE1" checkedvalue="1" uncheckedvalue="0"/> </cell> </row> <row> <cell halign="Right"> <textlabel label="#{lang.active}" text-align="Right"/> </cell> <cell halign="Left"> <checkbox name="indaktchk" column="IND_ACTIVE" datasource="EMPLOYEE1" checkedvalue="1" uncheckedvalue="0"/> </cell> </row> <row> <cell> <textlabel label="#{lang.companipart}" text-align="Right"/> </cell> <cell halign="Left"> <combobox name="deopred" displaycolumn="NAZIV" valuecolumn="ID" column="DELOVI_PREDUZECA_ID" datasource="EMPLOYEE1" listdatasource="DELOVI_PREDUZECA1"/> </cell> </row> <row> <cell> <textlabel label="#{lang.sector}" text-align="Right"/> </cell> <cell halign="Left"> <combobox name="sektor" displaycolumn="NAZIV" valuecolumn="SEKTOR_ID" column="SEKTOR_ID" datasource="EMPLOYEE1" listdatasource="SEKTORI1"/> </cell> </row> <row> <cell halign="Right"> <button label="#{lang.savesave}"> <events> <buttonpress action="sacuvajIzmenuRadnikSlog"/> </events> </button> </cell> <cell halign="Left"> <button label="#{lang.cancel}"> <events> <buttonpress action="btnZatvoriRadnikDialog"/> </events> </button> </cell> </row> </tablelayout> </panel>

link

answered 11 Jan '16, 08:13

Zigfrid's gravatar image

Zigfrid
111
accept rate: 0%

Thanks. I'll take a look at this soon.

(13 Jan '16, 08:21) Yalim ♦♦

Hi Zigfrid,

I still cannot replicate the issue. Could you please email us your entire application as an export file along with the table DDL scripts and the PL/SQl code associated with it?

Kind Regards,
Yalim

link

answered 14 Jan '16, 06:31

Yalim's gravatar image

Yalim ♦♦
2.8k5
accept rate: 21%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×10

Asked: 08 Jan '16, 09:23

Seen: 662 times

Last updated: 14 Jan '16, 06:31


© Copyright Gerger 2017