I'm having trouble making a button inside a Classic report. It's quite simple, I have a Classic Report and inside it there is a Select-list and a Button, follow the code below.
select a.COD_TAG_ITEM
, a.NOM_ITEM,a.CLIENTE
, a.SIG_UNI_MEDIDA
, a.nro_pedido
, a.NRO_ITEM
, sum(a.QTD_VENDIDA)
, apex_item.select_list(
p_idx => 1,
p_list_values => 'Programado;1,Executando;2,Encerrado;3',
p_show_null => 'YES',
p_null_value => 0,
p_null_text => 'Selecione',
p_attributes => 'style="color:red;"',
p_show_extra => 'NO') as SITUACAO --SELECT!
, 3 ALTERAR
from v_pedido_venda a
where a.NRO_EMPRESA = 1
and a.NRO_FILIAL = 3
and a.DAT_OCORRENCIA = trunc(sysdate)
and a.nro_item = :P3_ITEM
group by a.COD_TAG_ITEM,a.NOM_ITEM, a.SIG_UNI_MEDIDA,a.CLIENTE, a.nro_pedido, a.NRO_ITEM
order by 2,1,3
I would like that by pressing the ALTERAR
button, it picks up the value that was selected in the Select-list and executes a javascript or a Dynamic Action, where an Update will be done in the database by changing the value of the table with that Select- List
I've also tried pressing the button, throwing that Select-list value into an input, but it returns all options, not just the one selected.
Example image of my project: