Logic to inhibit registration permanently

1

I have a "problem" and I can not think of anything to solve it so I would like your help. I have a desktop system that is the intermediary between the server and my web system. This desktop system makes two queries in the database every hour and writes this data to a .xml

In the Web system I read these files and load the data into tables.

Asyoucansee,ithascommandButtononeachline,thisbuttonopensDialogandloadsotherdatafromthesecond.xml

The problem is as follows. Every time I click on enviar auditoria or concluir auditoria Client has to stop appearing on the first screen. But how do I do this if xml is updated every 1 hour, if I edit the pro client does not appear more then 1 hour the xml will be updated and it will appear.

Can anyone help?

Code: I get the data from xml on Get on List

@ManagedBean(name = "dtBasicView")
@ViewScoped
public class SolicitacoesBean {
    private List<Solicitacoes> list;
    private List<Solicitacoes> listaFiltrada;
    private Solicitacoes solicitacoes;



    public List<Solicitacoes> getList() {
        // pega a lista com os dados do .xml
        try {
            list = XmlParserSolicitacoes
                    .realizaLeituraXML("C:\Solicitacoes.xml");

        } catch (ParserConfigurationException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (SAXException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
        return list;
    }

My DataTable :

<p:dataTable emptyMessage="Nenhum registro encontrado" var="lista"
                value="#{dtBasicView.list}"
                filteredValue="#{dtBasicView.listaFiltrada}" rows="10"
                paginator="true" style="margin-top: 5px;"
                rowKey="#{lista.codigoBeneficiario}">

                <p:column headerText="Código" filterBy="#{lista.codigoBeneficiario}" style="width:20%" >
                    <h:outputText value="#{lista.codigoBeneficiario}" />
                </p:column>

                <p:column headerText="Nome" filterBy="#{lista.nomePessoa}" style="width:45%;"
                    sortBy="#{lista.nomePessoa}">
                    <h:outputText value="#{lista.nomePessoa}" />
                </p:column>

                <p:column headerText="Senha" style="width:10%">
                    <h:outputText value="#{lista.senha}" />
                </p:column>

                <p:column headerText="Data Solic." style="width:20%">
                    <h:outputText value="#{lista.dataSolicitacao}" />
                </p:column>

                <p:column headerText="Status" style="width:22%" sortBy="#{lista.status}" filterBy="#{lista.status}">
                    <h:outputText value="#{lista.status}" />
                </p:column>

                <p:column headerText="Opções" style="width:7%">
                    <p:commandButton  icon="ui-icon-search"
                        action="#{dtBasicView.abrirDialogo}" process="@this">
                        <!--                Mandar informação para outra página -->
                        <f:setPropertyActionListener target="#{dtBasicView.solicitacoes}" value="#{lista}" />
                    </p:commandButton>
                </p:column>
            </p:dataTable>
    
asked by anonymous 09.06.2015 / 13:41

1 answer

2

If you are also writing this data to a database you can do the verification by name.

You have a routine that reads the XML and extracts the data on the screen, correct?

Create a table in a database, type, Audit Clients . Each time you click Send Audit you save a record with the name of the customer.

And in the routine that reads the XML you check:

pseudo-code

Select * From Cliente_Auditoria Where Nome = Campo_Nome_XML
Count(Select)

    If Count == 0
        Mostra
    End If

Show only the ones you do not have in the table yet.

    
09.06.2015 / 13:55