vaadin7

How to make SQLContainer auto refresher in vaadin [closed]

泄露秘密 提交于 2019-12-24 22:26:33
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . i have a vaadin application, and i used SQLContainer to display database records. the issue that i want to make the SQLcontainer update itself when any database change occurs. cam anyone help me please? 回答1: AFAIK you can't register a "listener" on changes in any database systems like MySQL, Oracle or MSSQL. Its

Vaadin table.select(itemId) is not working

断了今生、忘了曾经 提交于 2019-12-24 17:06:15
问题 I have a table bind to a SQLContainer and a insert button (that insert a row in the table) When the button is clicked it execute the below code of the listener: Object itemId = table.addItem(); container.getContainerProperty(itemId, "cedula").setValue(cedulaS); try { container.commit(); table.select(itemId); catch (UnsupportedOperationException e) { //bla } The row is properly inserted BUT I want that automatically the row be selected but the select method is not working any idea? EDIT: The

Vaadin7 Container Updates from Server - To use server push or not

那年仲夏 提交于 2019-12-24 14:17:06
问题 I wanted to implement Vaadin Server push so that changes on the server DB are pushed to users. For example, if User A saves to the server DB, then User B should see the change automatically on his UI. However, the Vaadin book states that: The SQLContainer keeps continuously checking the amount of rows in the connected database table in order to detect external addition or removal of rows. By default, the table row count is assumed to remain valid for 10 seconds. This value can be altered from

Vaadin BrowserFrame not displaying HTTPS sources

我的未来我决定 提交于 2019-12-24 13:33:01
问题 I can't seem to get a Vaadin(7) BrowserFrame to open https sources, and am struggling to understand why that might be. With http:// sources the web page is opened just fine, but I just get a blank page when using a https://www.google.co.uk; tcpdump shows that the a request was served, but it's not displayed in the browser window. class BrowserWindow extends Window { BrowserWindow(URI externalUri) { center() setClosable(false) setDraggable(false) setResizable(false) setSizeFull() setModal(true

java.io.NotSerializableException is thrown while restarting Vaadin application

痞子三分冷 提交于 2019-12-24 02:23:14
问题 When I restart my Tomcat, I get the following error: 2014;10;01; 15;49;47;055; WARN; com.vaadin.event.ListenerMethod;[localhost-startStop-2]; Error in serialization of the application: Class com.aaa.bbb.MyServlet$1 must implement serialization. 2014;10;01; 15;49;47;055; WARN; org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/my-vaadin];[localhost-startStop-2]; Cannot serialize session attribute com.vaadin.server.VaadinSession.MyServlet for session ... java.io

java.io.NotSerializableException is thrown while restarting Vaadin application

风格不统一 提交于 2019-12-24 02:23:05
问题 When I restart my Tomcat, I get the following error: 2014;10;01; 15;49;47;055; WARN; com.vaadin.event.ListenerMethod;[localhost-startStop-2]; Error in serialization of the application: Class com.aaa.bbb.MyServlet$1 must implement serialization. 2014;10;01; 15;49;47;055; WARN; org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/my-vaadin];[localhost-startStop-2]; Cannot serialize session attribute com.vaadin.server.VaadinSession.MyServlet for session ... java.io

Vaadin - How to limit component squishiness and overlap?

早过忘川 提交于 2019-12-24 02:06:56
问题 Vaadin 7.6.2 Consider this example: import com.vaadin.ui.HorizontalLayout; import com.vaadin.ui.Panel; import com.vaadin.ui.TextField; public class MyClass extends Panel { TextField myField = new TextField(); TextField myField2 = new TextField(); HorizontalLayout hLayout = new HorizontalLayout(); public MyClass() { super(); applySettings(); } private void applySettings() { myField.setCaption( "Field1" ); myField.setWidth( 100, Unit.PERCENTAGE ); myField2.setCaption( "Field2" ); myField2

Vaadin Change the default Session Expired Notification?

偶尔善良 提交于 2019-12-23 19:45:51
问题 Vaadin 7.6.2 How to change the default Session Expired Notification; both the message and the type of notification? 回答1: To change session expired message you need to create your own SystemMessagesProvider , where you define it. For example in a servlet deployment, you could do the following: @WebServlet(urlPatterns = "/*", name = "MyUIServlet", asyncSupported = true) @VaadinServletConfiguration(ui = MyUI.class, productionMode = false) public static class MyUIServlet extends VaadinServlet {

Vaadin: open new window with ABSOLUTE url path from a BUTTON

旧巷老猫 提交于 2019-12-23 18:31:38
问题 I have a table with addresses. I have a button you can click which I want to open a google search for the address in a separate window. I have tried this code with BrowserWindowOpener. getUI().getPage().open(url, "_blank") and BrowserWindowOpener opener = new BrowserWindowOpener(url); opener.extend(googleBtn) but both are appending my url to the current path. I want to simply run a search in google in a separate window. I'm sure this is much simpler than I'm making it. It sure should be, at

Vaadin 7 url navigation hashbang

情到浓时终转凉″ 提交于 2019-12-23 04:58:08
问题 I'm trying to fully understand Navigation in Vaadin 7. I read the Navigator Chapter in the Vaadin book but still have some practical questions. Basically it is about using the bang (!). When do I need to set it and why? There is a view (myview) There is a parameter (param=X) The parameter is identifying a displayed label Example for browser history: I need to set the bang (!) or clicking back in the browser does not work, because the parameters is not passed the the views enter function: