예제 #1
0
        public async Task CreateOtpCodeHistoryRecord(string account, string phoneNumber, string action, DateTime timeStart)
        {
            var entity = new OtpHistoryTableEntity(account, phoneNumber, action, timeStart);

            var client = this.storageAccount.CreateCloudTableClient();

            // tablename change with account
            var tablename = OtpCodeHistoryTableName + account;
            var table     = client.GetTableReference(tablename);
            await OtpHistoryTableEntity.InsertOtpLoginHistoryTableEntity(table, entity);
        }
예제 #2
0
 internal static async Task InsertOtpLoginHistoryTableEntity(CloudTable table, OtpHistoryTableEntity summary)
 {
     var operation  = TableOperation.Insert(summary);
     var tempinvert = table.ExecuteAsync(operation);
     await Task.CompletedTask;
 }