From a43fd9003a77f253a78b807d4ecadcd828b936a4 Mon Sep 17 00:00:00 2001 From: Denis Date: Tue, 13 Dec 2016 15:46:29 +0200 Subject: [PATCH] Provide declarative support for Grid. (#7961) Fixes vaadin/framework8-issues#390 --- all/src/main/templates/release-notes.html | 8 +- .../java/com/vaadin/ui/AbstractListing.java | 39 +- .../vaadin/ui/DeclarativeValueProvider.java | 52 ++ server/src/main/java/com/vaadin/ui/Grid.java | 367 ++++++++- .../com/vaadin/ui/components/grid/Footer.java | 29 +- .../com/vaadin/ui/components/grid/Header.java | 63 +- .../grid/MultiSelectionModelImpl.java | 4 +- .../grid/SingleSelectionModelImpl.java | 4 +- .../ui/components/grid/StaticSection.java | 223 +++++- .../tests/design/DeclarativeTestBaseBase.java | 4 +- .../AbstractComponentDeclarativeTestBase.java | 23 +- .../component/grid/GridDeclarativeTest.java | 731 ++++++++++++++++++ .../components/grid/basics/GridBasics.java | 16 +- .../components/grid/GridSelectionTest.java | 2 +- 14 files changed, 1501 insertions(+), 64 deletions(-) create mode 100644 server/src/main/java/com/vaadin/ui/DeclarativeValueProvider.java create mode 100644 server/src/test/java/com/vaadin/tests/server/component/grid/GridDeclarativeTest.java diff --git a/all/src/main/templates/release-notes.html b/all/src/main/templates/release-notes.html index 1daed88508..70f8539e6d 100644 --- a/all/src/main/templates/release-notes.html +++ b/all/src/main/templates/release-notes.html @@ -176,11 +176,13 @@
  • required-indicator-visible attribute replaces the required attribute
  • placeholder attribute replaces the input-prompt attribute for input components
  • multi-select attribute is no longer used for select components
  • -
  • v-option-group with attribute multi-select=true is replaced by v-check-box-group
  • -
  • v-option-group with attribute multi-select=false is replaced by v-radio-button-group
  • +
  • vaadin-option-group with attribute multi-select=true is replaced by v-check-box-group
  • +
  • vaadin-option-group with attribute multi-select=false is replaced by v-radio-button-group
  • immediate attribute is not used for any component
  • read-only attribute is now only used for field components instead of all components
  • -
  • v-upload has a new attribute immediate-mode that replaces the removed immediate attribue
  • +
  • vaadin-upload has a new attribute immediate-mode that replaces the removed immediate attribue
  • +
  • vaadin-grid column elements don't have property-id attribute anymore. Columns aren't addressed by a property anymore but they have an id. So there is column-id attribute instead
  • +
  • vaadin-grid doesn't have readonly attribute anymore. It is replaced by selection-allowed attribute which has special meaning for a Grid