【问题标题】:After payment success how to store payment success page in sqlite支付成功后如何在sqlite中存储支付成功页面
【发布时间】:2021-10-07 11:55:11
【问题描述】:

如何在 SQLite 中存储支付成功页面,以便我可以将登录页面链接到 SQLite

【问题讨论】:

    标签: android sqlite payu


    【解决方案1】:

    以下是我们将执行的步骤:

    1. 为 3 个页面创建 UI 设计 - SignUp.axml(用于用户注册)、Main.axml(用于登录用户)和 Welcome.axml(用于登录后的屏幕)。
    2. UserDetails.cs(强类型 DTO)
    3. Helper.cs(Helper 类 - 用于 DB 操作)
    4. 活动 w.r.t. UI 页面 - SignUp.cs(用于用户注册活动)、MainActivity.cs(用于用户登录活动)和 Welcome.cs(用于登录后的欢迎屏幕活动)。

    对于注册和登录,我们需要用户信息,因此我们将创建一个名为 UserDetails 的强类型类。我们将使用相同的方法将详细信息存储在 SQLite 数据库中。

    public class UserDetails    
        {    
            public string ID { get; set; }    
            public string Username { get; set; }    
            public string FirstName { get; set; }    
            public string LastName { get; set; }    
            public string Address { get; set; }    
            public string Country { get; set; }    
            public string Email { get; set; }    
            public string Password { get; set; }    
            public string Mobile { get; set; }    
            public UserDetails() { }    
            public UserDetails(string Id, string username, string fname,string lname,string address,string country, string email, string password, string mobile) //Constructor with all parameters    
            {    
                ID = Id;    
                Username = username;    
                FirstName = fname;    
                LastName = lname;    
                Address = address;    
                Country = country;    
                Email = email;    
                Password = password;    
                Mobile = mobile;    
            }    
            public UserDetails(string Password) //Constructor with one parameter    
            {    
                this.Password = Password;    
            }    
               
        }     
    

    检查这个:-https://developer.android.com/training/data-storage

    【讨论】:

    • 我需要在 SQLite 中存储诸如金额、订单成功等付款详细信息,以便只有付费用户才能在 android 应用中访问该页面
    猜你喜欢
    • 2013-01-24
    • 2012-01-20
    • 2021-10-11
    • 2015-04-14
    • 1970-01-01
    • 2013-03-21
    • 1970-01-01
    • 1970-01-01
    • 2017-08-04
    相关资源
    最近更新 更多