public RbacColumn(string name, RbacDataTypes dataType, bool create = false, bool read = false, bool update = false) { this.Name = name; this.DataType = dataType; //this.IsFilterColumn = isFilterColumn; this.AllowedOperations = Rbac.ParseOperations(create, read, update, false); }
public RbacTable(string objectId, string name, string create = "False", string read = "False", string update = "False", string delete = "False") { this.ObjectId = objectId; this.Name = name; this.Columns = new List <RbacColumn>(); this.Conditions = new List <RbacCondition>(); this.Relations = new List <RbacRelation>(); this.Parameters = new List <RbacParameter>(); this.AllowedOperations = Rbac.ParseOperations(create, read, update, delete); }
public RbacColumn(string name, string dataType, string create = "False", string read = "False", string update = "False") { switch (dataType) { case "numeric": dataType = "Decimal"; break; } this.Name = name; this.DataType = (RbacDataTypes)Enum.Parse(typeof(RbacDataTypes), dataType, true); this.AllowedOperations = Rbac.ParseOperations(create, read, update, "False"); }