コード例 #1
0
        public ResultModel <string> Modify(TunnelInfo model)
        {
            var result = new ResultModel <string>();

            result.Success = tunnelInfoService.Modify(model);
            if (result.Success)
            {
                result.Msg = "修改成功";
            }
            else
            {
                result.Msg = "修改失败";
            }
            return(result);
        }
コード例 #2
0
        public void Modify()
        {
            TunnelInfo model = new TunnelInfo()
            {
                Id                  = new Guid("2801AF69-57DD-4AF0-8206-CDEE68ACE2F1"),
                TunnelCode          = "111",
                EntranceStation     = "111",
                TunnelLength        = "212",
                TunnelHeight        = "12",
                HoleType            = "212",
                HighwayGrade        = "121",
                CompletionTime      = DateTime.Now,
                RodeType            = "666",
                TunnelVentilation   = "666",
                ConstructionCompany = "66",
                DesignSpeed         = "66",
                TunnelName          = "66",
                TunnelType          = 3,
                TunnelWidth         = "66",
                AddTime             = DateTime.Now
            };
            var result = tunnelInfoService.Modify(model);

            Assert.True(result);
        }