{"id":17981160,"url":"https://github.com/sah4ez/erp_vaadin_framework","last_synced_at":"2026-02-18T09:40:33.716Z","repository":{"id":57722561,"uuid":"76938755","full_name":"sah4ez/erp_vaadin_framework","owner":"sah4ez","description":"Simple ERP FrameWork on Vaadin","archived":false,"fork":false,"pushed_at":"2017-03-05T14:45:58.000Z","size":351,"stargazers_count":3,"open_issues_count":4,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-28T20:14:44.333Z","etag":null,"topics":["cross-table","entity","erp","erp-framework","framework","java-8","vaadin7"],"latest_commit_sha":null,"homepage":"https://sah4ez.github.io/erp_vaadin_framework/","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sah4ez.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-20T08:37:29.000Z","updated_at":"2017-11-07T13:43:02.000Z","dependencies_parsed_at":"2022-09-14T01:14:11.865Z","dependency_job_id":null,"html_url":"https://github.com/sah4ez/erp_vaadin_framework","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sah4ez/erp_vaadin_framework","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sah4ez%2Ferp_vaadin_framework","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sah4ez%2Ferp_vaadin_framework/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sah4ez%2Ferp_vaadin_framework/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sah4ez%2Ferp_vaadin_framework/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sah4ez","download_url":"https://codeload.github.com/sah4ez/erp_vaadin_framework/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sah4ez%2Ferp_vaadin_framework/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29574969,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T08:38:15.585Z","status":"ssl_error","status_checked_at":"2026-02-18T08:38:14.917Z","response_time":162,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cross-table","entity","erp","erp-framework","framework","java-8","vaadin7"],"created_at":"2024-10-29T18:08:24.632Z","updated_at":"2026-02-18T09:40:28.707Z","avatar_url":"https://github.com/sah4ez.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"erp-vaadin-framework\n==============\n\nFramework ERP UI on Vaadin.\n\n\n[![Build Status](https://travis-ci.org/sah4ez/erp_vaadin_framework.svg?branch=master)](https://travis-ci.org/sah4ez/erp_vaadin_framework)\n[![Coverage Status](https://coveralls.io/repos/github/sah4ez/erp_vaadin_framework/badge.svg?branch=master)](https://coveralls.io/github/sah4ez/erp_vaadin_framework?branch=master)\n[![Code Climate](https://codeclimate.com/github/sah4ez/erp_vaadin_framework/badges/gpa.svg)](https://codeclimate.com/github/sah4ez/erp_vaadin_framework)\n\n\n\nINSTALL\n==========\n\n```xml\n    \u003cdependency\u003e\n      \u003cgroupId\u003ecom.github.sah4ez\u003c/groupId\u003e\n      \u003cartifactId\u003ecore\u003c/artifactId\u003e\n      \u003cversion\u003e1.0.14\u003c/version\u003e\n    \u003c/dependency\u003e\n\n```\n\nINSTALL SNAPSHOT\n========\n\nFor SNAPSHOT version.\nYou need add repository to your pom.xml:\n```xml\n\n\u003crepositories\u003e\n  \u003crepository\u003e\n    \u003cidEntity\u003eoss-sonatype\u003c/idEntity\u003e\n    \u003cname\u003eoss-sonatype\u003c/name\u003e\n    \u003curl\u003e\n      https://oss.sonatype.org/content/repositories/snapshots/\n    \u003c/url\u003e\n    \u003csnapshots\u003e\n      \u003cenabled\u003etrue\u003c/enabled\u003e\n    \u003c/snapshots\u003e\n  \u003c/repository\u003e\n\u003c/repositories\u003e\n```\n\nAnd add dependency:\n\n```xml\n    \u003cdependency\u003e\n      \u003cgroupId\u003ecom.github.sah4ez\u003c/groupId\u003e\n      \u003cartifactId\u003ecore\u003c/artifactId\u003e\n      \u003cversion\u003e1.0.12-SNAPSHOT\u003c/version\u003e\n    \u003c/dependency\u003e\n\n```\nWHAT NEW\n==========\n*v 1.0.13*:\n\n- added interface `Entity` and changed signature to `DataContainer\u003c? extends Entity\u003e`;\n- added interface `TreeEntity` and changed signature to `TreeDataContainer\u003c? extends TreeEntity\u003e`;\n- added implementation for `Entity` and `TreeEntity`;\n\n**DataContainer**:\n\n- added method `getByIdEntity(Integer)`, which find all items in container with this id;\n\n*v 1.0.12*\n\n**BottomPage**:\n\n- added method `public void addComponent(Component component, Consumer\u003cComponent.Event\u003e action)`;\n- changed method to `public void action()`;\n- changed class from `pbulic abstract class` to `pbulic class`;\n- changed constructor `public BottomPage(Component externalComponent, Cpation caption, Resource resource)`;\n\n**CrossTable**:\n\n- added method change CellCondition for selected cell;\n\n*v 1.0.11*\n\n**BottomPage**:\n\n- added constructor `BottomPage(T1 component, T2 externalComponent, String caption, Resource resource)`;\n- rename method listeners for `T1 component` from `listener()` to `action()`;\n\n**Logic**:\n\n- add method `CommonView getView()`;\n\n**BottomTabs**:\n\n- remove abstract method `void initTabs()`;\n\n**Workspace**:\n\n- added `public abstract void clearLayout()`;\n\n\nFixed example.\n\n*v 1.0.10*\n\n**BottomPage**:\n\n- add class `abstract public class BottomTabs`, need for interaction with components inherited from class Component\n\n**BottomTabs**:\n\n- add method `public void addPage(BottomPage page)` for add bottom pages\n\n**CrossTable**:\n\n- add `CellStyleGenerator` that used method `getCssStyle()` from `CellCondition`.\n- add selection mode for cross table: Single selection cell, Multi selection cell in row, Multi selection cell in column and Multi selection cell.\n\n**SelectionModeCrossTable**:\n\n- add enum `SelectionModeCrossTable`:\n    - `SINGLE_CELL`;\n    - `MULTI_CELL_IN_ROW`;\n    - `MULTI_CELL_IN_COLUMNT`;\n    - `MULTI_CELL`.\n\n**Condition**:\n\n- add `CSS` for condition to jar.\n\n*v 1.0.9*\n\n**BottomTabs**:\n\n- added `public abstract void clear()`, need for cleaning components added to tab in TabSheet.\n\n**CrossTable**:\n\n- add class `public abstract class CrossTable`, class with two inner `DataContainer`, where first container used for created rows and second container used for created columns;\n- add method `createData(String idFirst, String captionFirst, String idSecond, String captionSecond, String value)`, `idFirst, idSecond` - idEntity property of entity, which use for generate query. `captionFirst, captionSecodn` - property of entity, which input in first column and headers other columns. And `valueProperty` - property elements from `firstContainer`. This method used data from two containers and create table.\n- add method `public abstract CellCondition getCell(Object idRow, Object idColumn)` that `return` data from DB for each cell in cross table;\n\n**Condition**:\n\n- add enum `Condition` implementation `CellCodition`, with conditions: `EDIT`, `NOT_USE`, `USE`, `USE_EDIT`, `USE_NOT_EDIT`;\n    - `EDIT` - this Object are edited;\n    - `NOT_USE` - this Object not used;\n    - `USE` - this Object are used and wasn't edited; \n    - `USE_EDIT` - this Object are used and was edited;\n    - `USE_NOT_EDIT` - this Object must be edited and used.\n\n\n*v 1.0.8*\n\n**FilterPanel**:\n\n- refactoring code, for better testing code.\n\n**BottomTabs**:\n\n- added `Logic` to constructor `abstract class`, and added *getter* and *setter*.\n\n*v 1.0.7*\n\n**PermissionAccessUI**:\n\n- added property `String identity` for insert into instances of `Map` all component `CommonView`.\n    \n\nHOW TO\n========\n\nThis framework has next structure:\n```\n  core\n  |--data\n  |  |--CellCondition(I)\n  |  |--Condition(E)\n  |  |--DataContainer(A)\n  |  +--TreeBeanContainer(C)\n  |--elements\n  |  |--BottomPage(A)\n  |  |--ButtomTabs(A)\n  |  |--CommonLogic(A)\n  |  |--CommonView(A)\n  |  |--CrossTable(A)\n  |  |--FilterPanel(A)\n  |  |--Logic(I)\n  |  |--Menu(A)\n  |  |--MenuNavigator(A)\n  |  |--Mode(E)\n  |  |--SelectionModeCrossTable(E)\n  |  +--Workspace(A)\n  +--permission\n     |--ModifierAccess(A)\n     |--PermissionAccess(F)\n     +--PermissionAccessUI(I)\n```\n\n(A) - abstract class, (C) - class, (I) - interface, (E) - enum, (F) - final class. \n\nThis framework extend **Demo Vaadin CRUD**. \n\nQUICK START\n==========\n\nYou need create **UI** Vaadin:\n```java\n@Theme(\"mytheme\")\npublic class MyUI extends UI {\n    \n    @Override\n    protected void init(VaadinRequest vaadinRequest) {\n        Responsive.makeResponsive(this);\n        Locale locale = new Locale(\"ru\", \"RU\");\n        this.setLocale(locale);\n        this.getSession().setLocale(locale);\n        getPage().setTitle(\"Example\");\n        showMainView();\n    }\n\n    private void showMainView() {\n        addStyleName(ValoTheme.UI_WITH_MENU);\n        setContent(new MainScreen(this));\n        String view = getNavigator().getState();\n        getNavigator().navigateTo(view);\n    }\n\n    @WebServlet(urlPatterns = \"/*\", name = \"MyUIServlet\", asyncSupported = true)\n    @VaadinServletConfiguration(ui = MyUI.class, productionMode = false)\n    public static class MyUIServlet extends VaadinServlet {\n    }\n}\n```\n\nIn MyUI create class MainScreen, example:\n\n\n```java\n\npublic class MainScreen extends HorizontalLayout{\n\n    private MyMenu menu;\n\n    public MainScreen(MyUI ui){\n        CssLayout viewContainer = new CssLayout();\n        viewContainer.addStyleName(\"valo-content\");\n        viewContainer.setSizeFull();\n\n        final Navigator navigator = new Navigator(ui, viewContainer);\n        navigator.setErrorView(ErrorView.class);\n\n        menu = new MyMenu(navigator);\n        menu.setMenuCaption(\"This Example\");\n\n        menu.addView(new MyView(), \"MyView\", \"MyView\", null);\n\n        navigator.addViewChangeListener(viewChangeListener);\n\n        addComponent(menu);\n        addComponent(viewContainer);\n        setExpandRatio(viewContainer, 1);\n        setSizeFull();\n    }\n\n    ViewChangeListener viewChangeListener = new ViewChangeListener() {\n\n        @Override\n        public boolean beforeViewChange(ViewChangeEvent event) {\n            return true;\n        }\n\n        @Override\n        public void afterViewChange(ViewChangeEvent event) {\n            menu.setActiveView(event.getViewName());\n        }\n\n    };\n}\n\n```\n\nWhere MyMenu - extend Menu from Framework. MyView extend from CommonView, MyLogic extend from CommonLogic.\n\nFor UI create package **layout** where need make: \n```java\n\npublic class MyLayout extends Workspace {\n    \n    private ElementContainer container = new ElementContainer();\n    private MyTabSheet tabSheet;\n    private MyMenu menu;\n\n    public MyLayout(Logic logic) {\n        super(logic);\n        tabSheet = new MyTabSheet();\n        menu = new MyMenu(\"myMenu\", this);\n        logic.setDataToTable(container.loadAllData(), getTable());\n        setBottomTabs(tabSheet);\n        setNavigator(menu);\n    }\n    \n    @Override\n    protected ItemClickEvent.ItemClickListener editTableItemClick() {\n        return itemClickEvent -\u003e {\n        };\n    }\n\n    @Override\n    protected ItemClickEvent.ItemClickListener selectTableItemClick() {\n        return itemClickEvent -\u003e {\n        };\n    }\n\n    @Override\n    protected ItemClickEvent.ItemClickListener editTableAllItemClick() {\n        return itemClickEvent -\u003e {\n        };\n    }\n\n    @Override\n    protected ItemClickEvent.ItemClickListener selectTableAllItemClick() {\n        return itemClickEvent -\u003e {\n        };\n    }\n}\n```\n\nNot forget return from ItemClickEven.ClickListener, if this return null and will result to NullPointerException.\n\nExample instance of MenuNavigator with mode for MenuItem:\n```java\n\npublic class MyMenu extends MenuNavigator {\n\n    public MyMenu(String caption, Workspace parent) {\n        super(caption, parent);\n    }\n\n    @Override\n    public void add() {\n        if (getAdd().getStyleName() == null)\n            getAdd().setStyleName(ENABLE_BUTTON_STYLE);\n        else\n            getAdd().setStyleName(null);\n    }\n\n    @Override\n    public void delete() {\n        if (getDelete().getStyleName() == null)\n            getDelete().setStyleName(ENABLE_BUTTON_STYLE);\n        else\n            getDelete().setStyleName(null);\n    }\n\n    @Override\n    public void print() {\n        if (getPrint().getStyleName() == null)\n            getPrint().setStyleName(ENABLE_BUTTON_STYLE);\n        else\n            getPrint().setStyleName(null);\n\n    }\n}\n```\nExample instance of BottomTabs:\n```java\n\npublic class MyTabSheet extends BottomTabs {\n    public MyTabSheet() {\n        super();\n    }\n\n    @Override\n    public void initTabs() {\n        addCaption(\"Tab1\",\n                \"Tab2\",\n                \"Tab3\",\n                \"Tab4\");\n\n        addComponent(new Label(\"label1\"),\n                new Label(\"label2\"),\n                new Label(\"label3\"),\n                new Label(\"label4\"));\n\n        addResource(FontAwesome.AMAZON,\n                FontAwesome.AMAZON,\n                FontAwesome.AMAZON,\n                FontAwesome.AMAZON\n        );\n    }\n}\n```\nFor add Tab to **TabSheet**, you need add **caption** to method *addCaption(String ... caption)*,\nadd **component** to method *addComponent(Component ... component)*, and **icon** to method *addResource(Resource ... res)*.\n\nThen create instance *MyLayout* in *class MyView*.\n\nRUN\n==========\nFor run this example you need change directory with **pom.xml** and execute command:\n```\nmvn clear install jetty:run\n```\nand on **localhost:8080** start your application.\n\n![Example](https://raw.githubusercontent.com/sah4ez/erp_vaadin_framework/master/picture/screen-01.png)\n\nDATA STRUCTURE\n==========\nFor structure data use JPA with implement **Serializable** interface:\n```java\npublic class Element implements Serializable {\n    private Integer idEntity = 0;\n    private String name = \"treeElement\";\n    private Float price = 0.0F;\n\n    public Element(Integer idEntity, String name, Float price) {\n        this.idEntity = idEntity;\n        this.name = name;\n        this.price = price;\n    }\n\n    public Integer getId() {\n        return idEntity;\n    }\n\n    public void setId(Integer idEntity) {\n        this.idEntity = idEntity;\n    }\n\n    public String getName() {\n        return name;\n    }\n\n    public void setName(String name) {\n        this.name = name;\n    }\n\n    public Float getPrice() {\n        return price;\n    }\n\n    public void setPrice(Float price) {\n        this.price = price;\n    }\n}\n```\nAnd create class Container:\n```java\npublic class ElementContainer extends DataContainer\u003cElement\u003e {\n    public ElementContainer() {\n        super(Element.class);\n    }\n\n    @Override\n    protected void initHeaders() {\n        addCaptionColumn(\"idEntity\", \"name\", \"price\"); //set property from Entity\n        addHeaderColumn(\"ID\", \"Название\", \"Цена\"); //set Caption for table\n        addCollapsedColumn(true, false, false); //set collapsed column\n    }\n\n    @Override\n    public DataContainer loadAllData() {\n        add(new Element(1, \"name1\", 1.0f));\n        add(new Element(2, \"name2\", 2.0f));\n        add(new Element(3, \"name3\", 3.0f));\n        add(new Element(4, \"name4\", 4.0f));\n        add(new Element(5, \"name5\", 5.0f));\n        add(new Element(6, \"name6\", 6.0f));\n        add(new Element(7, \"name7\", 7.0f));\n        add(new Element(8, \"name8\", 8.0f));\n        add(new Element(9, \"name9\", 9.0f));\n        add(new Element(10, \"name10\", 10.0f));\n        add(new Element(11, \"name11\", 11.0f));\n        //or you may load data from your DB.\n        return this;\n    }\n}\n```\n\nFor binding data to table (or treeTable) you might use this method:\n` CommonLogic.setDataToTalbe(DataContainer container, CustomTable table);`\n\n### License ###\n## [**GPL**](http://www.gnu.org/licenses/gpl.txt) ##\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsah4ez%2Ferp_vaadin_framework","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsah4ez%2Ferp_vaadin_framework","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsah4ez%2Ferp_vaadin_framework/lists"}