V1.49 edit at date 2023-01-13
1.'db_ram_db.tb_fbs9100_state' 新增字段
`fbo4830_is_online` tinyint(4) NOT NULL DEFAULT '0' COMMENT
'FBO4830在离线状态:0:离线;1:在线',
2.新增数据表'web_site.tb_alarm_voice_set'--告警语音设置
CREATE TABLE `tb_alarm_voice_set` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`batt_group_id` int(11) DEFAULT NULL COMMENT '包含电池组id,设备',
`device_id` bigint(20) DEFAULT NULL,
`power_device_id` bigint(20) DEFAULT NULL,
`alarm_type` int(11) DEFAULT NULL,
`next_time_interval` int(11) DEFAULT NULL COMMENT '下次播报间隔时间,单位/分钟',
`user_id` int(11) DEFAULT NULL,
`status` int(11) DEFAULT NULL COMMENT '1:有效\0:无效',
`next_timestamp` bigint(20) DEFAULT NULL COMMENT '下次播放的时间戳',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8
COMMENT='告警语音设置';
| | |
| | | |
| | | |
| | | |
| | | V1.49 edit at date 2023-01-13 |
| | | 1.'db_ram_db.tb_fbs9100_state' 新增字段 |
| | | `fbo4830_is_online` tinyint(4) NOT NULL DEFAULT '0' COMMENT 'FBO4830在离线状态:0:离线;1:在线', |
| | | 2.新增数据表'web_site.tb_alarm_voice_set'--告警语音设置 |
| | | CREATE TABLE `tb_alarm_voice_set` ( |
| | | `id` int(11) NOT NULL AUTO_INCREMENT, |
| | | `batt_group_id` int(11) DEFAULT NULL COMMENT '包含电池组id,设备', |
| | | `device_id` bigint(20) DEFAULT NULL, |
| | | `power_device_id` bigint(20) DEFAULT NULL, |
| | | `alarm_type` int(11) DEFAULT NULL, |
| | | `next_time_interval` int(11) DEFAULT NULL COMMENT '下次播报间隔时间,单位/分钟', |
| | | `user_id` int(11) DEFAULT NULL, |
| | | `status` int(11) DEFAULT NULL COMMENT '1:有效\0:无效', |
| | | `next_timestamp` bigint(20) DEFAULT NULL COMMENT '下次播放的时间戳', |
| | | PRIMARY KEY (`id`) |
| | | ) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8 COMMENT='告警语音设置'; |
| | | |
| | | |
| | | V1.48 edit at date 2022-12-15 |
| | | 杭州锂电BTS |
| | |
| | | + "`load_vol_fromhjq` float NOT NULL DEFAULT '0' COMMENT '负载电压(V)-汇集器'," |
| | | + "`load_curr_fromhjq` float NOT NULL DEFAULT '0' COMMENT '负载电流(A)-汇集器'," |
| | | + "`dev_power` float NOT NULL DEFAULT '0' COMMENT '设备功率(KW)'," |
| | | + "`fbo4830_is_online` tinyint(4) NOT NULL DEFAULT '0' COMMENT 'FBO4830在离线状态:0:离线;1:在线'," |
| | | |
| | | + " UNIQUE INDEX index_dev_id_uniq (`dev_id`), " |
| | | + " PRIMARY KEY (`num`) ) " |
| | |
| | | + " ADD COLUMN `dev_power` float NOT NULL DEFAULT '0' COMMENT '设备功率(KW)';"); |
| | | } |
| | | |
| | | res = null; |
| | | //添加字段fbo4830_is_online - FBO4830在离线状态:0:离线;1:在线 |
| | | res = sql.sqlMysqlQuery("SELECT * FROM information_schema.columns" |
| | | + " WHERE table_schema='db_ram_db'" |
| | | + " AND table_name='tb_fbs9100_state'" |
| | | + " AND column_name='fbo4830_is_online'"); |
| | | if(false == res.next()) { |
| | | sql.sqlMysqlExecute("ALTER TABLE " + Sql_Mysql.FBS9100State_Table |
| | | + " ADD COLUMN `fbo4830_is_online` tinyint(4) NOT NULL DEFAULT '0' COMMENT 'FBO4830在离线状态:0:离线;1:在线';"); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } catch (SQLException e) { |
| | | e.printStackTrace(); |
| | |
| | | |
| | | createTB_Worksheet_Main_Table(pool, recreate); |
| | | |
| | | createTb_Alarm_Voice_Set_Table(pool, recreate); |
| | | |
| | | System.out.println(" DB_web_site init end at " + Com.getDateTimeFormat(new Date(), Com.DTF_YMDhms)); |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 创建数据库备份表 web_site`.`tb_alarm_voice_set |
| | | */ |
| | | public static void createTb_Alarm_Voice_Set_Table(MysqlConnPool pool, boolean recreate) { |
| | | String sql_str01 = " DROP TABLE IF EXISTS "+Sql_Mysql.Tb_Alarm_Voice_Set_Table; |
| | | String sql_str02 = "CREATE TABLE IF NOT EXISTS "+Sql_Mysql.Tb_Alarm_Voice_Set_Table+" (" + |
| | | " `id` int(11) NOT NULL AUTO_INCREMENT," + |
| | | " `batt_group_id` int(11) DEFAULT NULL COMMENT '包含电池组id,设备'," + |
| | | " `device_id` bigint(20) DEFAULT NULL," + |
| | | " `power_device_id` bigint(20) DEFAULT NULL," + |
| | | " `alarm_type` int(11) DEFAULT NULL," + |
| | | " `next_time_interval` int(11) DEFAULT NULL COMMENT '下次播报间隔时间,单位/分钟'," + |
| | | " `user_id` int(11) DEFAULT NULL," + |
| | | " `status` int(11) DEFAULT NULL COMMENT '1:有效\0:无效\'," + |
| | | " `next_timestamp` bigint(20) DEFAULT NULL COMMENT '下次播放的时间戳'," + |
| | | " PRIMARY KEY (`id`)" + |
| | | ") ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8 COMMENT='告警语音设置';"; |
| | | Sql_Mysql sql = new Sql_Mysql(pool.getConn()); |
| | | try { |
| | | if(true == recreate) { |
| | | //sql.sqlMysqlExecute(sql_str01); |
| | | //sql.sqlMysqlExecute(sql_str02); |
| | | } |
| | | sql.sqlMysqlExecute(sql_str02); |
| | | |
| | | } catch (SQLException e) { |
| | | e.printStackTrace(); |
| | | } finally { |
| | | sql.close_con(); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 创建电池组更换记录表 |
| | | */ |
| | |
| | | public static final String TB_Worksheet_Link_Table = WEB_Site +".`tb_worksheet_link`"; //三方接口配置表 |
| | | public static final String TB_Worksheet_Main_Table = WEB_Site +".`tb_worksheet_main`"; //三方接口配置表 |
| | | |
| | | public static final String Tb_Alarm_Voice_Set_Table = WEB_Site +".`tb_alarm_voice_set`"; //告警语音设置 |
| | | |
| | | |
| | | |
| | |
| | | |
| | | |
| | | |
| | | V1.49 edit at date 2023-01-13 |
| | | 1.'db_ram_db.tb_fbs9100_state' 新增字段 |
| | | `fbo4830_is_online` tinyint(4) NOT NULL DEFAULT '0' COMMENT 'FBO4830在离线状态:0:离线;1:在线', |
| | | 2.新增数据表'web_site.tb_alarm_voice_set'--告警语音设置 |
| | | CREATE TABLE `tb_alarm_voice_set` ( |
| | | `id` int(11) NOT NULL AUTO_INCREMENT, |
| | | `batt_group_id` int(11) DEFAULT NULL COMMENT '包含电池组id,设备', |
| | | `device_id` bigint(20) DEFAULT NULL, |
| | | `power_device_id` bigint(20) DEFAULT NULL, |
| | | `alarm_type` int(11) DEFAULT NULL, |
| | | `next_time_interval` int(11) DEFAULT NULL COMMENT '下次播报间隔时间,单位/分钟', |
| | | `user_id` int(11) DEFAULT NULL, |
| | | `status` int(11) DEFAULT NULL COMMENT '1:有效\0:无效', |
| | | `next_timestamp` bigint(20) DEFAULT NULL COMMENT '下次播放的时间戳', |
| | | PRIMARY KEY (`id`) |
| | | ) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8 COMMENT='告警语音设置'; |
| | | |
| | | |
| | | V1.48 edit at date 2022-12-15 |
| | | 杭州锂电BTS |
| | |
| | | /**************************************************************************/ |
| | | /**************************************************************************/ |
| | | public final static boolean app_debug = false; |
| | | public final static float m_VersionNum = (float) 1.47; |
| | | public final static float m_VersionNum = (float) 1.49; |
| | | public final static String m_Version = "Welcome To Use BTS DB BUILDER V" + m_VersionNum + " RC_20180908"; |
| | | /**************************************************************************/ |
| | | /**************************************************************************/ |