Exemple #1
0
        public void AddModel()
        {
            var modelService = ServiceLocator.GetInstance <IModelService>();

            using (var unitofWork = ResolveUnitOfWork())
            {
                var model = FixtureData.Build <Model>()
                            .With(x => x.ModelFields, null)
                            .With(x => x.Categories, null)
                            .With(x => x.Contents, null)
                            .Create();

                var id = modelService.AddModelGetId(model);
                unitofWork.Complate();
            }
        }