Пример #1
0
        public void GetTrainmanNotReturnLendingInfoTest()
        {
            //string ConnectionString = string.Empty; // TODO: 初始化为适当的值
            DBLendingInfoDetail target = new DBLendingInfoDetail(connstr); // TODO: 初始化为适当的值
            string TrainmanGUID        = string.Empty;                     // TODO: 初始化为适当的值

            TrainmanGUID = "07B9BD80-150C-4E62-9973-FF6E35D4CC8D";
            int state = 0;                            // TODO: 初始化为适当的值
            List <LendingInfoDetail> expected = null; // TODO: 初始化为适当的值
            List <LendingInfoDetail> actual;

            actual = target.GetTrainmanNotReturnLendingInfo(TrainmanGUID, state);
            // Assert.AreEqual(expected, actual);
            Assert.IsNotNull(actual);
            //Assert.Inconclusive("验证此测试方法的正确性。");
        }
Пример #2
0
        public Get_OutGetTrainmanNotReturnLendingInfo GetTrainmanNotReturnLendingInfo(string data)
        {
            Get_OutGetTrainmanNotReturnLendingInfo json = new Get_OutGetTrainmanNotReturnLendingInfo();

            try
            {
                Get_InGetTrainmanNotReturnLendingInfo input = Newtonsoft.Json.JsonConvert.DeserializeObject <Get_InGetTrainmanNotReturnLendingInfo>(data);

                LendingDetailList   l  = new LendingDetailList();
                DBLendingInfoDetail db = new DBLendingInfoDetail(ConData.WebSiteConnectionString);
                l.lendingDetailList = db.GetTrainmanNotReturnLendingInfo(input.TrainmanGUID, input.state);
                json.data           = l;
                json.result         = "0";
                json.resultStr      = "返回成功";
            }
            catch (Exception ex)
            {
                json.result    = "1";
                json.resultStr = "提交失败:" + ex.Message;
            }
            return(json);
        }