public string SOA_Misc_Credit(string source_chanel, string contract_number, string amount, string desc, string in_SS) { try { string result = ""; TTTWebService.TrungTamThe soa = new TTTWebService.TrungTamThe ( ); result = soa.SOA_Misc_Credit ( source_chanel, contract_number, amount, desc, in_SS ); return result; } catch (Exception ex) { return ex.ToString ( ); } }
public string SOA_UPDATE_CONTRACT_STATUS( string source_channel, string contract_number, string type, string desc, string in_SS ) { try { string result = ""; TTTWebService.TrungTamThe soa = new TTTWebService.TrungTamThe ( ); result = soa.SOA_Contract_Status ( source_channel, contract_number, type, desc, in_SS ); return result; } catch (Exception ex) { return ex.ToString ( ); } }
public string SOA_Migr_Autho( ) { try { string result = ""; TTTWebService.TrungTamThe soa = new TTTWebService.TrungTamThe ( ); result = soa.SOA_Migra_Autho_Activity ( ); return result; } catch (Exception ex) { return ex.ToString ( ); } }
public string SOA_ISSUING_CARD(string source_channel, string in_param, string in_type) { try { string result = ""; TTTWebService.TrungTamThe soa = new TTTWebService.TrungTamThe ( ); result = soa.SOA_Issuing_Card ( source_channel, in_param, in_type ); return result; } catch (Exception ex) { return ex.ToString ( ); } }
public string SOA_Change_Contr_Status( string source_chanel, string contract_number, string status_code, string status_name, string in_SS ) { try { string result = ""; TTTWebService.TrungTamThe soa = new TTTWebService.TrungTamThe ( ); result = soa.SOA_Change_Contr_Status ( source_chanel, contract_number, status_code, status_name, in_SS ); return result; } catch (Exception ex) { return ex.ToString ( ); } }
private void btn_active_Click ( object sender, EventArgs e ) { try { this.Cursor = Cursors.WaitCursor; TTTWebService.TrungTamThe SOA = new TTTWebService.TrungTamThe ( ); for (int i = 0; i < dgv_data.Rows.Count; i++) { sothe = dgv_data.Rows[i].Cells[2].Value.ToString ( ).Trim ( ); result = ""; result = SOA.SOA_Delivery_Card ( "WEB", sothe, "82" ); int s_rs = 8, e_rs = result.IndexOf ( "</result>" ), s_msg = result.IndexOf ( "<msg>" ), e_msg = result.IndexOf ( "</msg>" ); if (result.Substring ( s_rs, e_rs - 8 ) == "0") { success++; dgv_data.Rows[i].Cells[0].Value = result.Substring ( s_msg + 5, e_msg - s_msg - 6 ).Trim ( ); dgv_data.Rows[i].Cells[1].Value = "Card OK"; } else { fail++; dgv_data.Rows[i].Cells[0].Value = result.Substring ( s_msg + 5, e_msg - s_msg - 6 ).Trim ( ); if (!dgv_data.Rows[i].Cells[1].Value.ToString ( ).Contains ( "OK" )) dgv_data.Rows[i].Cells[1].Value = "Card Active Fail"; } } lbS.Visible = true; lbF.Visible = true; lbSuccess.Text = success.ToString ( ); lbFail.Text = fail.ToString ( ); this.Cursor = Cursors.Default; } catch (Exception ex) { MessageBox.Show ( "SOA Error /n ------------------------- /n " + ex.Message ); } }
private void Authorize_MiscCredit_Prepaid ( string batch_id ) { #region new string xml = ""; string sql = "", err = ""; TTTWebService.TrungTamThe ttt = new TTTWebService.TrungTamThe ( ); try { for (int i = 0; i < dgv_authorize_data.Rows.Count; i++) { xml = ttt.SOA_Misc_Credit ( "FORM", dgv_authorize_data.Rows[i].Cells["account_number"].Value.ToString ( ).Trim ( ), dgv_authorize_data.Rows[i].Cells["amount"].Value.ToString ( ).Trim ( ), "IBPS", "83" ); ArrayList result = getxmlvalue ( xml ); if (result[0].ToString ( ) != "0") { sql = " update NAB_BATCH_MICS t "; sql += " set t.processing_flag = 'Z', t.msg_error = '" + result[1].ToString ( ) + "'"; sql += " ,t.user_modify= '" + Businessbp.executedb.Usrid + "'"; sql += " ,t.date_modify = sysdate"; sql += " where t.batch_number = '" + batch_id + "'"; sql += " and t.date_create = to_date('" + dgv_authorize_data.Rows[i].Cells["date_create"].Value.ToString ( ).Trim ( ) + "','dd/mm/yyyy')"; sql += " and t.card_number = '" + dgv_authorize_data.Rows[i].Cells["card_number"].Value.ToString ( ).Trim ( ) + "'"; sql += " and t.trn_ref_no = '" + dgv_authorize_data.Rows[i].Cells["trn_ref_no"].Value.ToString ( ).Trim ( ) + "'"; if (!Businessbp.executedb.ExecuteDML ( sql, ref err )) { MessageBox.Show ( " Update Mics To Z Fail" + err ); return; }; } if (result[0].ToString ( ) == "0") { sql = " update NAB_BATCH_MICS t "; sql += " set t.processing_flag = 'Y', t.msg_error = '" + result[1].ToString ( ) + "'"; sql += " ,t.user_modify= '" + Businessbp.executedb.Usrid + "'"; sql += " ,t.date_modify = sysdate"; sql += " where t.batch_number = '" + cb_src_batch_id.Text.Trim ( ) + "'"; sql += " and trunc(t.date_create) = to_date('" + dgv_authorize_data.Rows[i].Cells["date_create"].Value.ToString ( ).Trim ( ) + "','dd/mm/yyyy')"; sql += " and t.card_number = '" + dgv_authorize_data.Rows[i].Cells["card_number"].Value.ToString ( ).Trim ( ) + "'"; sql += " and t.trn_ref_no = '" + dgv_authorize_data.Rows[i].Cells["trn_ref_no"].Value.ToString ( ).Trim ( ) + "'"; if (!Businessbp.executedb.ExecuteDML ( sql, ref err )) { MessageBox.Show ( " Update Mics To Y Fail " + err ); return; }; } } sql = "update nab_balance_batch u "; sql += " set u.status='Y' "; sql += " where u.batch_id= '" + cb_src_batch_id.Text.Trim ( ) + "'"; sql += " and u.type_code= '3' "; sql += " and u.type = 'PREPAID' "; if (!Businessbp.executedb.ExecuteDML ( sql, ref err )) { MessageBox.Show ( " Cannot Close Batch " + err ); return; }; MessageBox.Show ( "Authorize Successful" ); #endregion } catch (Exception ex) { MessageBox.Show ( ex.ToString ( ) ); } }