2 Star 13 Fork 0

小黑/QuickBuild

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
Apache-2.0

QuickBuild

介绍

低代码平台,适合从零代码到高代码的渐进式开发。支持快速系统构建,提供可视化表单和界面设计工具,帮助用户轻松搭建应用。平台支持单点登录,简化用户身份管理;同时提供强大的接口对接与开放能力,方便与其他系统集成。此外,平台支持自定义调度,满足复杂业务需求;内置Groovy代码引擎,方便开发者实现复杂逻辑;还提供在线调试功能,助力高效开发。

在线示例

  1. http://106.14.154.74:8080/quick-build/
  2. 用户名:superadmin,密码:123456
  3. 每天0点重置

源码安装教程

源码安装前置,需要安装maven, nodejs

  1. 支持 mysql,postgresql,需要安装 mysql 或 postgresql 数据库

  2. quick-build-vue 打包,quick-build-vue 在运行 yarn build 或者 npm run build

  3. 将 quick-build-vue 打包后的 dist 下文件复制到 quick-build-web/src/main/resources/static

  4. 在 quick-build-web 根目录进行 mavn 打包:mvn clean -Pprod package -f pom.xml

  5. 将 target/quick-build-web.jar,quick-build-web/src/main/resources/application-prod.properties 复制到同一目录,并将 application-prod.properties 重命名为 application.properties

  6. 使用脚本运行:java -jar quick-build-web.jar --spring.config.location=file:./application.properties

  7. 注意修改配置application.properties,
    postgresql数据库配置方式:
    spring.datasource.druid.url=jdbc:postgresql://数据库IP:数据库端口/数据库名称?currentSchema=数据库schema
    spring.datasource.druid.driver-class-name=org.postgresql.Driver
    spring.datasource.druid.username=数据库用户名
    spring.datasource.druid.password=数据库密码

    mysql数据库配置方式:
    spring.datasource.druid.url=jdbc:mysql://数据库IP:数据库端口/数据库名称?autoReconnect=true&serverTimezone=GMT%2B8
    spring.datasource.druid.driver-class-name=com.mysql.cj.jdbc.Driver
    spring.datasource.druid.username=数据库用户名
    spring.datasource.druid.password=数据库密码

非源码安装教程

  1. QuickBuild下载

  2. 安装 mysql 或 postgresql 数据库

  3. 修改 application.properties 中的数据库配置
    postgresql 数据库配置方式:
    spring.datasource.druid.url=jdbc:postgresql://数据库IP:数据库端口/数据库名称?currentSchema=数据库schema
    spring.datasource.druid.driver-class-name=org.postgresql.Driver
    spring.datasource.druid.username=数据库用户名
    spring.datasource.druid.password=数据库密码

    mysql 数据库配置方式:
    spring.datasource.druid.url=jdbc:mysql://数据库IP:数据库端口/数据库名称?autoReconnect=true&serverTimezone=GMT%2B8
    spring.datasource.druid.driver-class-name=com.mysql.cj.jdbc.Driver
    spring.datasource.druid.username=数据库用户名
    spring.datasource.druid.password=数据库密码

  4. 使用脚本运行:java -jar quick-build-web.jar --spring.config.location=file:./application.properties

访问方式

  1. 打开浏览器访问:http://127.0.0.1/
  2. 默认端口为80,可通过 application.properties server.port 修改访问端口
  3. 默认用户名:superadmin,默认密码:123456

使用文档

1 数据模型

1.1 功能介绍

配置表格/表单有哪些字段。
表格:数据查询时显示的表格。 表单:编辑/显示明细数据的表单。

1.2 模型类型

库表:根据【字段管理】中配置的字段在数据库中建表。
视图:【视图名称】来源于【视图配置】中根据sql生成的视图。

1.3 字段管理

配置表格/表单有哪些字段。配置保存后自动生成【表格设计 -> 默认表格】【表单设计 -> 默认表单】

1.3.1 字段类型:

字符:【自动生成】为【是】时,【自动生成序】来源于【系统配置 -> 序号配置】,需要手动添加序配置
联动:与其它数据模型/人员/组织机构/字典表关联,查出特定字段信息
派生:必须与联动字段同时出现,派生配置中的【来源字段】指联动字段关联表中的字段

1.4 表格设计

添加表格:新增一张表格。
基础信息:配置表格显示的字段。
数据排序:配置表格数据的默认排序。
权限过滤:根据角色进行数据过滤。
提示信息:表格顶部/底部显示提示信息。

1.5 表单设计

1.5.1 基础信息

批量编辑:【是】时,打开的表单为批量信息录入。 初始化脚本:来源于【脚本配置】中配置的脚本,脚本语言为【groovy】。

1.5.2 表单字段

添加分段:将表单分成不同的段,每段前显示段名称。

1.5.3 自动填充

根据【触发字段】的内容匹配【来源数据模型】中的【匹配字段】并将【来源数据模型】中的【来源字段】数据填充到【填充字段】。

1.5.4 显隐禁用

配置字段根据特定条件显示显示、隐藏或者禁用(不允许修改)。

1.5.5 页面脚本

为js脚本,可参照脚本说明进行编写,脚本中的【字段名称】使用的是【数据模型】字段管理中的【字段名称】。

1.6 索引管理

配置数据库表的索引(仅【模型类型】为库表时有效)。索引名称一致时为联合索引。

1.7 触发器

当数据显示时根据不同的触发条件,调用不同的【触发脚本】。

2 脚本配置

脚本语言为 groovy 语言,可到 w3cschool 了解基本语法,语法比较简单、入门快、学习成本低。
通用参数:args,脚本中可通过 println args 打印 args 的内容。
当保存的数据为表单时,args 为表单的数据,如表单中有【姓名】字段时,【姓名】的取值为【args.姓名】。
当提交的数据为批量数据时,数据列表取值为:args.dataList。
当导入excel数据时,数据列表取值为:args.importList。
脚本编写可参考【在线示例】里面的脚本。
脚本执行日志查看可以通过管理后台顶部的【查看日志】查看服务日志信息。

3 视图配置

配置sql作为视图,可作为数据模型的视图来源,并配置相应的显示表格/页面。

4 数据对接

4.1 接口令牌

配置接入本系统接口的【应用标识】、【应用密钥】,根据【应用标识】、【应用密钥】获取接口访问【令牌】。
令牌获取方式:

public static void main(String[] args) {
    String url = "http://网站地址/v1/token"; // 网站地址替换为真实的API地址
    String json = "{\"appKey\":\"应用标识\", \"appSecret\":\"应用密钥\"}"; // 替换为真实的【应用标识】、【应用密钥】

    URL url = new URL(url);
    HttpURLConnection connection = (HttpURLConnection) url.openConnection();
    connection.setRequestMethod("POST");
    connection.setRequestProperty("Content-Type", "application/json; utf-8");
    connection.setRequestProperty("Accept", "application/json");
    connection.setDoOutput(true);

    OutputStream outputStream = connection.getOutputStream();
    outputStream.write(json.getBytes());
    outputStream.flush();
    outputStream.close();

    BufferedReader reader = new BufferedReader(new InputStreamReader(connection.getInputStream()));
    String line;
    StringBuilder response = new StringBuilder();
    while ((line = reader.readLine()) != null) {
        response.append(line);
    }
    reader.close();
}
// 结果:{"code": "1", "data": {"token": "...", "expires_in": 3600}}
// code 为 1 时,获取成功,data.token 为令牌, data.expires_in 为有效时间,单位为秒。

4.2 接口配置

所有接口使用的请求方式为 POST 方式,请求数据格式为 json 格式,响应格式同为 json 格式。
路径:接口对外开放的路径,访问地址为:/v1/路径。
请求示例:

public static void main(String[] args) {
    String url = "http://网站地址/v1/路径"; // 网站地址替换为真实的API地址,路径替换成接口配置的路径
    String authorization = "Bearer token"; // token替换根据【应用标识】、【应用密钥】获取接口访问的【令牌】
    String json = "{}"; // 请求提交的参数,json 格式
    
    URL url = new URL(url);
    HttpURLConnection connection = (HttpURLConnection) url.openConnection();
    connection.setRequestMethod("POST");
    connection.setRequestProperty("Content-Type", "application/json; utf-8");
    connection.setRequestProperty("Accept", "application/json");
    connection.setRequestProperty("Authorization", authorization);
    connection.setDoOutput(true);

    OutputStream outputStream = connection.getOutputStream();
    outputStream.write(json.getBytes());
    outputStream.flush();
    outputStream.close();

    BufferedReader reader = new BufferedReader(new InputStreamReader(connection.getInputStream()));
    String line;
    StringBuilder response = new StringBuilder();
    while ((line = reader.readLine()) != null) {
        response.append(line);
    }
    reader.close();
}
// 结果:{"code": "1", "data": {}}
// code 为 1 时,获取成功,data 为接口返回的数据。

4.3 数据源配置

配置数据库连接信息,用于做数据同步,从来源数据源同步到目标数据源。

4.4 采集任务配置

数据采集,从来源数据源同步到目标数据源。

5 菜单管理

5.1 系统配置

配置系统分成多少个子系统,在首页中就显示多少个可切换的子系统。
徽标数脚本:首页选择页面中子系统右上角显示的数值。
首页显示图标:首页显示此子系统的图标。
子系统样式:为 css 格式,用于配置此子系统的页面样式。

5.2 页面配置

配置一些常规页面无法满足需求的页面,支持拖拽、可视化(所见即所得)的方式配置页面。

5.3 菜单配置

配置子系统有哪些菜单。

6 用户管理

6.1 组织管理

类型:区划、单位、部门
单位为划分一组织机构的基本单位。显示组织机构时,只能显示自己的单位的组织机构信息,无法跨单位显示所有组织机构。

6.2 员工管理

可登录系统的人员信息。
默认部门:默认登录的部门。
归属部门:一个人可以归属多个部门。

6.3 角色管理

可配置系统拥有哪些角色,角色可拥有哪些权限。 角色名称右侧按钮【权限配置】可配置角色的权限。

7 系统配置

7.1 环境配置

配置系统配置信息:登录配置、密码配置、首页配置、门户配置

7.2 变量配置

配置变量,脚本中可通过 SystemUtil.getVariable(变量名) 获取变量内容。

7.3 模板管理

上传 word、excel 模板,在上传、下载中可直接使用这些脚本,脚本中可通过 OfficeUtil.exportExcel(模板编码, data) 导出数据,具体导出示例可查看脚本编辑右侧【工具 -> Office类】中的示例。

7.4 字典配置

配置字典,用于【数据模型 -> 字段管理 -> 字段类型(联动/字典*) -> 联动字典】。
脚本中也可通过 DictionaryUtil 工具类获取字典内容。

7.5 调度配置

配置定时调度器执行相应的脚本。

7.6 序号配置

配置字典,用于【数据模型 -> 字段管理 -> 字段类型(字符/自动生成为是) -> 自动生成序】。

7.7 图标库

提供大量可用的图标,也可以手动上传图标。建议上传 svg 等体量小的图标。

7.8 按钮配置

系统内置基础按钮,不建议删除,可对按钮图标、字体颜色、背景颜色、边框颜色、提交确认语、排序字段进行修改,不建议对名称、类型、数据数量进行修改。

7.9 工具列表

系统内置数据,提供给脚本编辑 -> 工具的辅助数据,不建议删除,可新增数据作脚本编辑参考,新增后注意数据备份。

8 运维管理

8.1 数据备份

备份类型:
系统配置:系统内置的表结构以数据。
子系统配置:非系统内置的表结构,不包含数据。
子系统数据:非系统内置的表数据,不包含结构。

8.2 数据恢复

使用数据备份中下载的备份文件进行数据恢复,恢复方式来覆盖恢复,请注意做数据备份。

Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

简介

低代码平台,适合从零代码到高代码的渐进式开发。支持快速系统构建,提供可视化表单和界面设计工具,帮助用户轻松搭建应用。平台支持单点登录,简化用户身份管理;同时提供强大的接口对接与开放能力,方便与其他系统集成。此外,平台支持自定义调度,满足复杂业务需求;内置Groovy代码引擎,方便开发者实现复杂逻辑;还提供在线调试功能,助力高效开发。 展开 收起
Java 等 5 种语言
Apache-2.0
取消

发行版 (5)

全部
12天前

贡献者

全部

近期动态

不能加载更多了
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/gitslipper/quick-build.git
git@gitee.com:gitslipper/quick-build.git
gitslipper
quick-build
QuickBuild
master

搜索帮助