Example #1
0
 /// <summary>
 /// ���캯��
 /// </summary>
 private PayMode()
 {
     title = String.Empty;
     mode = PaymentModeEnum.PostOffice;
     isActive = false;
     details = null;
 }
 private string GetPayModeInfo(PaymentModeEnum mode, PaymentModeDetails details)
 {
     switch (mode)
     {
         case PaymentModeEnum.PostOffice:
             return details.ToString("������{0}<br/>�绰��{1}<br/>��ַ��{2}<br/>�ʱࣺ{3}");
         case PaymentModeEnum.Online:
             return details.ToString("ƽ̨��{0}<br/>�ʺţ�{1}");
         case PaymentModeEnum.ElectricityBill:
             return details.ToString("���У�{0}<br/>�����У�{1}<br/>������{2}<br/>�ʺţ�{3}");
     }
     return "---------";
 }
Example #3
0
 /// <summary>
 /// ���캯��
 /// </summary>
 /// <param name="m">֧����ʽö��</param>
 /// <param name="uid">�û�ID</param>
 public PayMode(PaymentModeEnum m,int uid,string _title)
     : this()
 {
     mode = m;
     userId = uid;
     title = _title;
     switch (mode)
     {
         case PaymentModeEnum.PostOffice:
             details = new PaymentModePostOffice();
             break;
         case PaymentModeEnum.ElectricityBill:
             details = new PaymentModeElectricityBill();
             break;
         case PaymentModeEnum.Online:
             details = new PaymentModeOnline();
             break;
     }
 }
Example #4
0
 private void InitDetails(string xmlString)
 {
     switch (mode)
     {
         case PaymentModeEnum.PostOffice:
             details = new PaymentModePostOffice();
             break;
         case PaymentModeEnum.Online:
             details = new PaymentModeOnline();
             break;
         case PaymentModeEnum.ElectricityBill:
             details = new PaymentModeElectricityBill();
             break;
         default:
             details = new PaymentModeUnKnown();
             break;
     }
     details.FromXmlString(xmlString);
 }