コード例 #1
0
 public void submitinfoCancelledPnr(string content, string fakeEtno)
 {
     try
     {
         string   NULL = "NULL";
         etStatic es   = new etStatic();
         es.Bunk1       = bunk1;
         es.Bunk2       = bunk2;
         es.CityPair1   = cp1;
         es.CityPair2   = cp2;
         es.Date1       = date1;
         es.Date2       = date2;
         es.DecFeeState = "";
         es.etNumber    = etnumbers;
         if (etnumbers.Trim() == "")
         {
             es.etNumber = "No TktNum When Submit";
         }
         es.FlightNumber1 = fn1;
         es.FlightNumber2 = fn2;
         es.Passengers    = passengers;
         es.Pnr           = pnr;
         es.State         = "0";
         es.TotalFC       = "0"; // string.Format("{0}", float.Parse(totalfc) * etnumbers.Split(';').Length);
         //if (tb.IndexOf("CNY") >= 0)
         es.TotalTaxBuild = "0"; // = string.Format("{0}", float.Parse(tb.Substring(3)) * etnumbers.Split(';').Length);
         //else
         es.TotalTaxBuild = "0"; // string.Format("{0}", float.Parse(tb.Substring(0)) * etnumbers.Split(';').Length);
         //if (tf.IndexOf("CNY") >= 0)
         es.TotalTaxFuel = "0";  // string.Format("{0}", float.Parse(tf.Substring(3)) * etnumbers.Split(';').Length);
         //else
         es.TotalTaxFuel = "0";  // string.Format("{0}", float.Parse(tf.Substring(0)) * etnumbers.Split(';').Length);
         if (es.SubmitInfo())
         {
             EagleAPI.LogWrite(pnr + "PNRCANCELLED提交成功!" + content + "\r\n\r\n");
         }
         return;
     }
     catch
     {
     }
     EagleAPI.LogWrite(pnr + "PNRCANCELLED提交失败!" + content + "\r\n\r\n");
 }
コード例 #2
0
 public void submitinfo()
 {
     if (!isEticket)
     {
         ePlus.eTicket.etCreateFailed etcf = new ePlus.eTicket.etCreateFailed();
         etcf.Pnr = pnr;
         if (etcf.submitinfo())
         {
             EagleAPI.LogWrite("取消电子客票行!");
         }
         return;
     }
     try
     {
         etStatic es = new etStatic();
         es.Bunk1         = bunk1;
         es.Bunk2         = bunk2;
         es.CityPair1     = cp1;
         es.CityPair2     = cp2;
         es.Date1         = date1;
         es.Date2         = date2;
         es.DecFeeState   = "";
         es.etNumber      = (etnumbers.Trim() == "" ? " si" : etnumbers.Trim());
         es.FlightNumber1 = fn1;
         es.FlightNumber2 = fn2;
         es.Passengers    = passengers;
         es.Pnr           = pnr;
         es.State         = "0";
         try
         {
             es.TotalFC = string.Format("{0}", float.Parse(totalfc) * etnumbers.Split(';').Length);
         }
         catch
         {
             es.TotalFC = "0";
         }
         try
         {
             if (tb.IndexOf("CNY") >= 0)
             {
                 es.TotalTaxBuild = string.Format("{0}", float.Parse(tb.Substring(3)) * etnumbers.Split(';').Length);
             }
             else
             {
                 es.TotalTaxBuild = string.Format("{0}", float.Parse(tb.Substring(0)) * etnumbers.Split(';').Length);
             }
         }
         catch
         {
             es.TotalTaxBuild = "0";
         }
         try
         {
             if (tf.IndexOf("CNY") >= 0)
             {
                 es.TotalTaxFuel = string.Format("{0}", float.Parse(tf.Substring(3)) * etnumbers.Split(';').Length);
             }
             else
             {
                 es.TotalTaxFuel = string.Format("{0}", float.Parse(tf.Substring(0)) * etnumbers.Split(';').Length);
             }
         }
         catch
         {
             es.TotalTaxFuel = "0";
         }
         if (es.SubmitInfo())
         {
             EagleAPI.LogWrite(pnr + "提交成功!");
         }
         return;
     }
     catch
     {
     }
     EagleAPI.LogWrite(pnr + "提交失败!");
 }