Java 快速開發框架JeeWeb

JeeWeb敏捷開發平臺

JeeWeb是一款基於SpringMVC+Spring+Hibernate的敏捷開發系統;它是一款具備代碼生成功能的智能快速開發平臺;是以Spring Framework爲核心容器,Spring MVC爲模型視圖控制器,Hibernate爲數據訪問層, Apache Shiro爲權限受權層,Ehcahe對經常使用數據進行緩存,Disruptor做爲併發框架,Bootstrap做爲前端框架的優秀 開源 系統。css

JeeWeb是一款 全開源開發平臺 ,特別 代碼生成器模塊也採用開源模式 ,各位開發者能夠根據本身的須要改造出更加適合本身的代碼生成器,無論是作項目、學習、接私活它都將是你的最佳拍檔;html

JeeWeb主要定位於企業快速開發平臺建設,已內置不少優秀的基礎功能和高效的 代碼生成 工具,包括:系統權限組件、數據權限組件、數據字典組件、核心工具組件、視圖操做組件、代碼生成、 UI模版標籤 庫等。前端界面風格採用告終構簡單、性能優良、頁面美觀大氣的Twitter Bootstrap頁面展現框架。採用分層設計、提交數據安全編碼、密碼加密、訪問驗證、數據權限驗證。使用Maven作項目管理,提升項目的易開發性、擴展性。前端

目前功能模塊代碼生成器、權限框架、數據字典、數據緩存、併發框架、數據監控、計劃任務、多數據源管理、附件管理、相似mybatis動態SQL、UI模板標籤、短信發送、郵件發送、統計功能等功能。java

JeeWeb的開發方式採用( 代碼生成器快速設計生成代碼->手工完善邏輯->豐富模板標籤快速前端開發 ),能夠快速協助java開發人員解決60%的重複工做,讓開發人員更多關注業務邏輯的實現,框架使用前端模板標籤,解放JAVA開發人員的開發壓力,提升開發效率,爲企業節省項目研發成本,減小開發週期。mysql

JeeWeb 技術特色

JeeWeb使用目前流程的WEB開發架構技術,如 SpringMVC, Hibernate,Apache Shiro, Disruptor , ehcache, Jquery ,BootStrap 等等,支持多種數據庫MySQL, Oracle, sqlserver等。 分層設計:使用分層設計,分爲dao,service,Controller,view層,層次清楚,低耦合,高內聚。git

安全考慮:嚴格遵循了web安全的規範,先後臺雙重驗證,參數編碼傳輸,密碼md5加密存儲,shiro權限驗證,從根本上避免了SQL注入,XSS攻擊,CSRF攻擊等常見的web攻擊手段。github

JeeWeb 功能特色

  • 採用SpringMVC+Spring+Hibernate+Shiro+ Ehcache+Disruptor+Jquery + Boostrap + Ztree等基礎先後端架構架構
  • 採用面向聲明的開發模式, 基於泛型編寫極少代碼便可實現複雜的數據展現、數據編輯、表單處理等功能,在不使用代碼生成器的狀況下,也只須要不多的代碼就能實現基礎的CURD操做,再配合在線開發與代碼生成器的使用,更加加快了開發的進度,將J2EE的開發效率成本提升,能夠將代碼減小60%以上。
  • 在線開發(經過在線配置實現一個表模型的增刪改查功能,無需一行代碼,支持用戶自定義表單佈局)
  • 代碼生成器,支持多種數據模型,根據表生成對應的Entity,Service,Dao,Controller,JSP等,增刪改查功能生成直接使用
  • UI標籤開發庫,針對前端UI進行標準封裝表,頁面統一採用UI標籤實現功能:數據datagrid,treegrid,FileInput,Editor,GridSelect等,實現JSP頁面零JS,開發維護簡潔高效
  • 查詢過濾器:只需前端配置,後臺動態拼SQL追加查詢條件;支持多種匹配方式(全匹配/模糊查詢/包含查詢/不匹配查詢)
  • 移動平臺支持,對Bootstrap(兼容Html5)進行標準封裝
  • 國際化(支持多語言,國際化的封裝爲多語言作了便捷支持)
  • 多數據源(在線配置數據源,數據源工做類封裝)
  • 數據權限:整合Shiro權限
  • 計劃任務控制(在線配置計劃任務、方便計劃任務的時間調整規劃)
  • 郵件發送(配置郵件模版、郵件賬號的在線配置、郵件異步發送、郵件發送日誌功能統計)
  • 短信發送(配置短信模版、短信賬號的在線配置、短信異步發送、短信發送日誌功能統計、支持短信發送平臺動態切換)
  • 多種首頁風格切換,支持自定義首頁風格。(Inspinia風格|ACE風格)
  • 數據統計報表:豐富的報表統計功能
  • 支持多種瀏覽器: Google, 火狐, IE,360 等
  • 支持數據庫: Mysql,Oracle10g,SqlServer等
  • 基礎權限: 用戶,角色,菜單權限
  • Web容器測試經過的有Jetty和Tomcat,Weblogic
  • 要求JDK1.7+

技術選型

一、後端web

  • 核心框架:Spring Framework
  • 安全框架:Apache Shiro
  • 視圖框架:Spring MVC
  • 服務端驗證:Hibernate Validator
  • 佈局框架:SiteMesh
  • 任務調度:Quartz
  • 持久層框架:Hibernate
  • 數據庫鏈接池:Alibaba Druid
  • 緩存框架:Ehcache
  • 併發框架:Disruptor
  • 日誌管理:SLF4J、Log4j
  • 工具類:Apache Commons、Jackson、Xstream、

二、前端ajax

  • JS框架:jQuery。
  • CSS框架:Twitter Bootstrap
  • 客戶端驗證:Validform。
  • 富文本在線編輯:markdown、simditor、Summernote、CodeMirror自由切換
  • 文件上傳工具:Bootstrap fileinput
  • 數據表格:jqGrid
  • 對話框:layer
  • 樹結構控件:jQuery zTree
  • 日期控件: datepicker
  • 代碼高亮: syntaxhighlighter

簡單使用說明

  • 導入sql/jeeweb-mysql-v1.0.sql文件到mysql數據庫
  • 導入項目到Eclipse.
  • 修改數據庫配置文件dbconfig.properties中的帳號密碼.
  • 啓動項目,管理員帳號admin/密碼123456

技術聯繫

平臺目錄結構說明

├─main
│  │  
│  ├─java
│  │   │
│  │   └─cn.jeeweb----------------平臺主代碼
│  │             │
│  │             ├─core----------------平臺核心模塊存放目錄
│  │             │    ├─common----------------項目公用的部分(例如基礎controller、dao、service、以及動態SQL/HQL實現)
│  │             │    │
│  │             │    ├─disruptor-------------併發框架的實現(短信發送模塊、郵件發送模塊)
│  │             │    │
│  │             │    ├─filter、interceptor---安全過濾器、其餘一些公用攔截器
│  │             │    │
│  │             │    ├─mapper----------------各類Object到Xml、Object到Json的映射轉換類
│  │             │    │
│  │             │    ├─model-----------------前段暫時的各類JSON實體
│  │             │    │
│  │             │    ├─quartz----------------quartz定時任務實現
│  │             │    │
│  │             │    ├─query-----------------前端請求,後端自動組裝、以及分頁的查詢模塊
│  │             │    │
│  │             │    ├─repository------------持久層相關類
│  │             │    │
│  │             │    ├─security--------------安全相關類
│  │             │    │
│  │             │    ├─tag-------------------GRID標籤、form標籤、html組件加載標籤等
│  │             │    │
│  │             │    └─utils-----------------一些工具類
│  │             │    
│  │             └─modules----------------內置功能模塊(按照業務模塊分類)
│  │                  ├─charts----------------圖表模塊
│  │                  │
│  │                  └─sys-------------------權限模塊
│  │                     │
│  │                     ├─controller---控制層
│  │                     │
│  │                     ├─entity-------實體層
│  │                     │
│  │                     ├─service------服務層
│  │                     │
│  │                     ├─security-----安全相關
│  │                     │
│  │                     ├─tags----------------標籤
│  │                     │
│  │                     └─utils-----------------一些工具類
│  │   
│  │
│  ├─resources----------------平臺資源文件
│  │     │
│  │     ├─ehcache----------------緩存配置目錄(ehcache.xml緩存配置文件)
│  │     │ 
│  │     ├─i18n-------------------國際化信息所在的文件名文件目錄(messages.properties項目國際化、ValidationMessages.propertieshibernate validator驗證)
│  │     │ 
│  │     ├─mapper----------------一些映射(特別tag/html/中的文件,爲html組件加載包)
│  │     │ 
│  │     ├─statement-------------動態SQL/HQL(是更靈活的操做SQL/HQL)
│  │     │ 
│  │     ├─codegen.properties-----代碼生成配置
│  │     │ 
│  │     ├─dbconfig.properties----數據庫配置
│  │     │ 
│  │     ├─jeeweb.properties------項目的一些配置
│  │     │ 
│  │     ├─shiro.properties-------shiro配置
│  │     │ 
│  │     ├─shiro.properties-------代碼生成器的模板文件,以及其餘模板存放目錄
│  │     │ 
│  │     ├─*.properties----------(其餘配置,能夠查看配置的前綴,對應具體業務的配置,如何:sms.properties短信、email.properties郵件配置)
│  │     │ 
│  │     └─spring-*.xml-----------Spring相關文件
│  │
│  └─webapp----------------web頁面和靜態資源存放的目錄
│      │
│      └─WEB-INF
│            │
│            ├─static----------------靜態資源目錄
│            │    │
│            │    ├─ace----------------ace樣式JS,CSS文件
│            │    ├─vendors----------------第三方的JS,css,按照第三方包名單獨保存
│            │    ├─common-----------------系統的公用JS.CSS文件
│            │    └─modules----------------功能模塊CSS,以及JS,按照模板名單獨存放
│            └─webpage----------------視圖文件目錄
│                 ├─decorators-------------視圖裝飾目錄
│                 ├─error------------------系統異常映射相關頁面
│                 └─modules----------------內置核心功能模塊視圖相關文件(按照模板名單獨存放)

系統演示

[1].多套首頁風格,支持自定義(Inspinia風格|ACE風格)

Inspinia風格輸入圖片說明ACE風格

[2].強大的代碼生成功能

JeeWebJeeWebJeeWeb

代碼示例

[1].GRID列表

<grid:grid id="codegenGrid"  url="${adminPath}/codegen/table/ajaxList">
    <grid:column label="sys.common.key" hidden="true"   name="id"/>
    <grid:column label="codegen.table.tabletype"   width="60" name="tableType"   dict="tabletype"  query="true" queryMode="select"  />
    <grid:column label="codegen.table.table.name"   width="120"  name="tableName"  query="true" />
	<grid:column label="codegen.table.remarks"  name="remarks" />
	<grid:column label="codegen.table.sync.database"  width="80" dict="sf" formatterClass="0:label label-danger;1:label label-success" name="syncDatabase" />
	
	<grid:column label="sys.common.opt"  name="opt" formatter="button" width="300"/>
	<grid:button title="sys.common.remove"  groupname="opt" function="rowConfirm" tipMsg="確認要移除該條記錄嗎?" outclass="btn-warning" innerclass="fa-remove" url="${adminPath}/codegen/table/{id}/remove" />
	<grid:button groupname="opt" function="delete" tipMsg="確認要刪除該條記錄,刪除會刪除對應的表結構,請謹慎操做!" />
	<grid:button title="codegen.table.sync.database"  groupname="opt" function="rowConfirm"  tipMsg="確認要強制同步數據庫嗎?同步數據庫將刪除全部數據從新建表!" outclass="btn-info" innerclass="fa-database"  url="${adminPath}/codegen/table/{id}/syncDatabase" />
	<grid:toolbar  function="create"  winwidth = "1000px"/>
	<grid:toolbar  function="update"  winwidth = "1000px"/>
	<grid:toolbar title="codegen.table.import" icon="fa-database" function="createDialog" url="${adminPath}/codegen/table/importDatabase"  />
	<grid:toolbar title="codegen.table.gen" icon="fa-file-code-o" function="updateDialog" url="${adminPath}/codegen/table/{id}/generateCode"  />
	<grid:toolbar title="codegen.table.createmenu" icon="fa-anchor" function="updateDialog" url="${adminPath}/codegen/table/{id}/createMenu"  />
	
	<grid:toolbar  function="search"/>
	<grid:toolbar  function="reset"/>
</grid:grid>

JSP列表圖片

[2].TREEGRID列表

<grid:grid id="menuGridId" async="true" treeGrid="true"  expandColumn="name"  sortname="sort" url="${adminPath}/sys/menu/ajaxTreeList">
	<grid:column label="sys.common.key" hidden="true"   name="id" />
	<grid:column label="sys.menu.name"  name="name"  query="true" condition="like"/>
	<grid:column label="sys.menu.url"  name="url"  />
    <grid:column label="sys.menu.permission"  name="permission"  />
    <grid:column label="sys.menu.isshow"  name="isshow" dict="sf"/>
    
    <grid:column label="sys.common.opt"  name="opt" formatter="button" width="100"/>
	<grid:button   groupname="opt" function="delete" />
    
	<grid:toolbar  function="create"/>
	<grid:toolbar  function="update"/>
	<grid:toolbar  function="delete"/>
	<grid:toolbar  function="search"/>
	<grid:toolbar  function="reset"/>
</grid:grid>

TREEGRID

[3].表單代碼

<form:form id="userForm" modelAttribute="data" method="post" class="form-horizontal">
		<form:hidden path="id"/>
		<table  class="table table-bordered  table-condensed dataTables-example dataTable no-footer">
		   <tbody>
		       <tr>
		         <td  class="width-15 active text-right">	<label><font color="red">*</font>用戶名:</label></td>
		         <td  class="width-35" >
		             <form:input path="username" class="form-control" ajaxurl="${adminPath}/sys/user/validate"  validErrorMsg="用戶名重複"  htmlEscape="false"  datatype="*"  nullmsg="請輸入用戶名!"/>
		             <label class="Validform_checktip"></label>
		         </td>
		          <td  class="width-15 active text-right">	
		              <label><font color="red">*</font>姓名:</label>
		         </td>
		         <td class="width-35" >
		             <form:input path="realname" class="form-control " datatype="*" nullmsg="請輸入姓名!" validErrorMsg="用戶名重複" htmlEscape="false" />
		             <label class="Validform_checktip"></label>
		         </td>
		      </tr>
		      <tr>
		         <td  class="width-15 active text-right">	
		              <label><font color="red">*</font>郵箱:</label>
		         </td>
		         <td class="width-35" >
		             <form:input path="email" class="form-control" ajaxurl="${adminPath}/sys/user/validate"   datatype="e" nullmsg="請輸入郵箱!"  htmlEscape="false" />
		             <label class="Validform_checktip"></label>
		         </td>
		         <td  class="width-15 active text-right">	
		           	 <label><font color="red">*</font>聯繫電話:</label>
		         </td>
		         <td  class="width-35" >
		             <form:input path="phone" class="form-control" ajaxurl="${adminPath}/sys/user/validate"  htmlEscape="false"  datatype="m"  nullmsg="請輸入用戶名!"/>
		             <label class="Validform_checktip"></label>
		         </td>
		      </tr>
		      <tr>
		         <td  class="width-15 active text-right">	
		              <label><font color="red">*</font>密碼:</label>
		         </td>
		         <td class="width-35" >
		             <input type="password" value="" name="password"  class="form-control" datatype="*6-16" nullmsg="請設置密碼!" errormsg="密碼範圍在6~16位之間!" />
		             <label class="Validform_checktip"></label>
		         </td>
		         <td  class="width-15 active text-right">	<label><font color="red">*</font>確認密碼:</label></td>
		         <td  class="width-35" >
		             <input type="password" value="" name="userpassword2" class="form-control" datatype="*" recheck="password" nullmsg="請再輸入一次密碼!" errormsg="您兩次輸入的帳號密碼不一致!" />
		             <label class="Validform_checktip"></label>
		         </td>
		      </tr>
		      <tr>
		         <td class="active"><label class="pull-right"><font color="red">*</font>用戶角色:</label></td>
		         <td>
		         	<form:checkboxes path="roleIdList" nested="false" items="${allRoles}" itemLabel="name" itemValue="id" htmlEscape="false" cssClass="i-checks required"/>
		          
		         </td>
		      </tr>
		      <tr>
				<td class="width-15 active"><label class="pull-right">組織機構:</label></td>
				<td colspan="3">
				   <form:treeselect title="請選擇組織機構" path="organizationIds"  nested="false"  dataUrl="${adminPath}/sys/organization/treeData" labelName="parentname" labelValue="${organizationNames}" multiselect="true" />	   
				</td>
		      </tr>
		     
		   </tbody>
		   </table>   
	</form:form>
相關文章
相關標籤/搜索