| | |
| | | public class TableToJsonWeb { |
| | | |
| | | //show create table c_orders 用这个语句获取 |
| | | public static final String createTableSql = "CREATE TABLE `report_custom_component_rel` (\n" + |
| | | " `rel_id` varchar(30) NOT NULL COMMENT '关系编号',\n" + |
| | | " `component_id` varchar(30) NOT NULL COMMENT '组件ID',\n" + |
| | | " `custom_id` varchar(30) NOT NULL COMMENT '报表编号',\n" + |
| | | " `seq` int(11) NOT NULL COMMENT '组件序号',\n" + |
| | | " `create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',\n" + |
| | | public static final String createTableSql = "CREATE TABLE `inspection_item` (\n" + |
| | | " `item_id` varchar(30) NOT NULL COMMENT '主键ID',\n" + |
| | | " `item_name` varchar(256) NOT NULL COMMENT '巡检项目',\n" + |
| | | " `community_id` varchar(30) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL COMMENT '小区ID',\n" + |
| | | " `remark` varchar(512) DEFAULT NULL COMMENT '备注',\n" + |
| | | ")"; |
| | | public static void main(String[] args) { |
| | | String templateName = "报表组件"; //业务名称 |
| | | String templateCode = "reportCustomComponentRel"; //表名大写 |
| | | String templateKey = "relId"; //表主键 |
| | | String templateKeyName = "关系编号";//主键说明 |
| | | String searchCode = "relId"; //分片字段 |
| | | String searchName = "关系编号"; //分片字段说明 |
| | | String directories = "dev"; //前端生成到那个目录下 |
| | | String templateName = "巡检项目"; //业务名称 |
| | | String templateCode = "inspectionItem"; //表名大写 |
| | | String templateKey = "itemId"; //表主键 |
| | | String templateKeyName = "编号";//主键说明 |
| | | String searchCode = "itemId"; //分片字段 |
| | | String searchName = "编号"; //分片字段说明 |
| | | String directories = "property"; //前端生成到那个目录下 |
| | | // templateName 业务名称 业务编码名称生成后文件名 templateCode 主键 templateKey |
| | | // 业务主键名称 templateKeyName=templateName+ID 主机驼峰 searchCode 主键名称 searchName |
| | | // directories 放在前端那个目录下 |