コード例 #1
0
        /// <summary>
        /// Gets the application.
        /// </summary>
        /// <param name="id">The identifier.</param>
        /// <returns></returns>
        public async Task <ModelApplication> GetApplication(string id)
        {
            using (var db = new MancobaLocalDataApi(_connectionFactory, _platformCapabilities))
            {
                var response = await db.GetApplication(id);

                if (response == null)
                {
                    var tempTestList = await TestData.GetSentApplications().ConfigureAwait(false);

                    response = tempTestList.FirstOrDefault();
                }
                return(response.ToModel());
            }
        }