コード例 #1
0
        public void GetAllCategoriesTest()
        {
            var ops = new PolicyDocumentsOperations();
            var folderPath = @"C:\Users\Apprentice\Desktop\GitHub\KileyDowling\SGCorpHRV2\SGCorpHR\SGCorpHR.TEST\PolicyDocuments";
            var response = ops.GetAllCategories(folderPath);
            Assert.IsTrue(response.Success);
            Assert.AreEqual(3,response.Data.Count);

        }
コード例 #2
0
        public ActionResult SelectPolicyDocCategory()
        {
            var fullPath = Server.MapPath(@"~/PolicyDocuments");
            var ops = new PolicyDocumentsOperations();
            var model = new CategoryVM()
            {
                PolicyDocumentToAdd = new PolicyDocument()
                {
                    Category = new Category()
                }
            };

            var response = ops.GetAllCategories(fullPath);

            model.CreateCategoryList(response.Data);

            return View(model);
        }