But I added the Toolbar at the initial call oft he Webpage. Then I can submit 
the AjaxButton and some data is in the table. Why should I add the 
bottomtoolbar again? The no-record-found-toolbar will be rendered after the 
Ajaxcall. Why not the Exporttoolbar?


Mit freundlichen Grüßen
Christoph Manig
Systems Engineer

T-Systems International GmbH
Systems Integration - SC Travel, Transport & Logistics
Hoyerswerdaer Str. 18
01099 Dresden 
tel.:   +49 (0) 351 / 8152 - 188
fax:    +49 (0) 351 / 8152 - 209
email:  [email protected]


-----Ursprüngliche Nachricht-----
Von: Sven Meier [mailto:[email protected]] 
Gesendet: Dienstag, 23. April 2013 15:44
An: [email protected]
Betreff: Re: AW: DefaultDataTable will not render bottomtoolbar for export

Your replaced DataTable doesn't have a bottomtoolbar:

                     
target.add(ProtokollierungPage.this.get("searchTable").replaceWith(
                             new 
DefaultDataTable<ProtocolRecord,String>("searchTable",
                                     getTableHead(),
                                     new 
ProtocolDataSortDataProvider(protocolData),
                                     100)));


Sven


On 04/23/2013 03:29 PM, [email protected] wrote:
> Hello,
>
> here is the code of onSubmit method of the AjaxFallbackButton.
>
> Form<FilterCreatorProtocol> protocollSearchForm = new 
> Form<FilterCreatorProtocol>("protokollierungSucheForm", new 
> CompoundPropertyModel<FilterCreatorProtocol>(new FilterCreatorProtocol()));
>          protocollSearchForm.add(new 
> AjaxFallbackButton("submit",protocollSearchForm) {
>
>              @Override
>              public void onSubmit(AjaxRequestTarget target, Form form) {
>                  target.add(feedback);
>                  FilterCreatorProtocol filter = 
> (FilterCreatorProtocol)form.getModelObject();
>                  
> if(ConsoleDataHandlerImpl.getInstance().queryProtocolRowsByFilter(filter) <= 
> MAX_SEARCH_RESULTS){
>                      List<ProtocolRecord> protocolData = 
> ConsoleDataHandlerImpl.getInstance().queryProtocolDataWithSearchFilter(filter);
>                      
> target.add(ProtokollierungPage.this.get("searchTable").replaceWith(
>                              new 
> DefaultDataTable<ProtocolRecord,String>("searchTable",
>                                      getTableHead(),
>                                      new 
> ProtocolDataSortDataProvider(protocolData),
>                                      100)));
>                  }else{
>                      error("ErrorMessage");
>                  }
>
>
>              }
>          }) ;
>
> Do you need some other informations?
>
>
> Mit freundlichen Grüßen
> Christoph Manig
> Systems Engineer
>
> T-Systems International GmbH
> Systems Integration - SC Travel, Transport & Logistics Hoyerswerdaer 
> Str. 18
> 01099 Dresden
> tel.: +49 (0) 351 / 8152 - 188
> fax:  +49 (0) 351 / 8152 - 209
> email:  [email protected]
>
> -----Ursprüngliche Nachricht-----
> Von: Sven Meier [mailto:[email protected]]
> Gesendet: Dienstag, 23. April 2013 15:16
> An: [email protected]
> Betreff: Re: DefaultDataTable will not render bottomtoolbar for export
>
> Show us your #onSubmit(ART) ... formatted please.
>
> Sven
>
> On 04/23/2013 02:54 PM, [email protected] wrote:
>> Hello,
>>
>> I have a Problem with the DefaultDataTable and the Export csv. Here is my 
>> code:
>>
>> DefaultDataTable<ProtocolSearchData,String> searchTable = new 
>> DefaultDataTable<ProtocolSearchData,
>> String>("searchTable",getTableHead(),new
>> ProtocolDataSortDataProvider(Collections.EMPTY_LIST),10);
>> searchTable.addBottomToolbar(new ExportToolbar(searchTable,new 
>> Model<String>("Export to"),new 
>> Model<String>("export")).addDataExporter(new CSVDataExporter())); 
>> searchTable.setOutputMarkupId(true);
>>
>> add(searchTable);
>>
>> This table will be replaced by submitting an AjaxFallbackButton, so that the 
>> DataProvider gets an list with some data and not an empty list. My Problem 
>> is that the bottomtoolbar for exporting a csv ist not rendered. The 
>> no-records-found toolbar will be rendered.
>>
>> What is the problem here? Can anyone please help me?
>>
>>
>>
>> Mit freundlichen Grüßen
>> Christoph Manig
>> Systems Engineer
>>
>> T-Systems International GmbH
>> Systems Integration - SC Travel, Transport & Logistics Hoyerswerdaer 
>> Str. 18
>> 01099 Dresden
>> tel.:   +49 (0) 351 / 8152 - 188
>> fax:    +49 (0) 351 / 8152 - 209
>> email:  [email protected]
>>
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to