| | |
| | | */
|
| | | public static void updateTb_Fgcd_Filedownload_Table(MysqlConnPool pool,FGCD_TestFBOFile fbo) {
|
| | | String sql_str = " UPDATE " + Sql_Mysql.Tb_Fgcd_Filedownload_Table +
|
| | | " SET op_cmd = "+fbo.op_cmd+"," + |
| | | " file_count = " + fbo.file_total;
|
| | | " SET op_cmd = "+fbo.op_cmd + |
| | | " ,file_count = " + fbo.file_count +
|
| | | " ,file_total = " + fbo.file_total;
|
| | | if(fbo.file_count > 0) {
|
| | | //当前文件数大于0
|
| | | for(int i=0;i<fbo.file_count;i++) {
|
| | | for(int i=0;i<fbo.files.length;i++) {
|
| | | FBOFile file = fbo.files[i];
|
| | | sql_str += ",file_name"+(i+1)+"='"+file.filename+"'"
|
| | | + ",file_index"+(i+1)+"="+file.file_index
|
| | |
| | | file.battgroupid = res.getInt("BattGroupId");
|
| | | file.file_index = res.getInt("file_index");
|
| | | file.op_cmd = res.getInt("op_cmd");
|
| | | for(int i=0;i<file.files.length;i++) {
|
| | | file.files[i].setDownload_flag(res.getInt("download_flag"+(i+1)));; |
| | | }
|
| | | }
|
| | | } catch (Exception e) {
|
| | | e.printStackTrace();
|
| | |
| | | e.printStackTrace();
|
| | | }
|
| | | }
|
| | | sql.close_con();
|
| | | }
|
| | | }
|
| | | |
| | | /**
|
| | | * 更新当前下载状态,以及异常结束原因
|
| | | * @param pool
|
| | | * @param file
|
| | | */
|
| | | public static void updateFgcd_Filedownload_TableCmdByDevId(MysqlConnPool pool,FGCD_TestFBOFile file) {
|
| | | String sql_str = " UPDATE " + Sql_Mysql.Tb_Fgcd_Filedownload_Table +
|
| | | " SET op_cmd = " + file.op_cmd +
|
| | | " ,stop_reason = " + file.getStop_reason() +
|
| | | " WHERE dev_id = " + file.dev_id;
|
| | | Sql_Mysql sql = new Sql_Mysql(pool);
|
| | | try {
|
| | | sql.sqlMysqlExecute(sql_str);
|
| | | } catch (SQLException e) {
|
| | | e.printStackTrace();
|
| | | } finally {
|
| | | sql.close_con();
|
| | | }
|
| | | }
|
| | |
| | | + "batt_online_state=" + m_pm.sysState.diode_state+ ", "
|
| | | + "dev_temp=" + m_pm.sysState.devtmp + ", "
|
| | | + "dev_res_test_state=" + m_pm.sysState.tmp_alm_lock + ", "
|
| | | + "dev_testgroupnum=" + m_pm.sysState.hhProgress + ", "
|
| | | + "dev_workstate=" + m_pm.sysState.dev_workstate + ", "
|
| | | + "dev_captest_curr=" + m_pm.sysState.chargeCurr + ", "
|
| | | |
| | | + "dev_restest_monindex=" + m_pm.sysState.hhProgress + ", " //活化进度
|
| | | + "dev_restest_moncount=" + m_pm.sysState.hhCount + ", " //活化次数
|
| | | + "dev_batt_xuhang_tlong=" + m_pm.sysState.hhstate + ", " //活化状态
|
| | | + "dev_captest_timelong=" + m_pm.sysState.test_timelong + ", " //显示屏测试时长
|
| | | + "dev_eachgroup_battsum=" + m_pm.sysState.char_phase + ", " //充电阶段数 |
| | | |
| | | + "dev_last_captest_stop_type=" + m_pm.sysState.dev_captest_stop_type + ", "
|
| | | + "dev_captest_cap=" + m_pm.sysState.testCap + ", "
|
| | | + "dev_data_flowsum=" + m_pm.sysState.dev_data_flowsum+ ", "
|