Ejemplo n.º 1
0
        public R.ResourceGroup CreateResourceGroup(string name, R.Mode mode, ICollection <R.SingleResource> resources)
        {
            R.ResourceGroup resourceGroup = new R.ResourceGroup()
            {
                Name            = name,
                GroupMode       = mode,
                SingleResources = resources
            };

            using (IUnitOfWork uow = this.GetUnitOfWork())
            {
                IRepository <R.ResourceGroup> repo = uow.GetRepository <R.ResourceGroup>();
                repo.Put(resourceGroup);
                uow.Commit();
            }

            return(resourceGroup);
        }
Ejemplo n.º 2
0
 public ResourceGroupModel()
 {
     Name           = "";
     ClassifierMode = new R.Mode();
     Resources      = new List <ResourceModel>();
 }