This commit is contained in:
@@ -59,9 +59,9 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
public GroupAssignment Add(Role myRole, Folder myFolder) // One to Many
|
||||
{
|
||||
GroupAssignment assignment = GroupAssignment.New(myRole, myFolder);
|
||||
this.Add(assignment);
|
||||
return assignment;
|
||||
GroupAssignment assignment = GroupAssignment.New(myRole, myFolder);
|
||||
this.Add(assignment);
|
||||
return assignment;
|
||||
}
|
||||
public void Remove(Assignment myAssignment)
|
||||
{
|
||||
@@ -94,8 +94,8 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
get
|
||||
{
|
||||
IVEHasBrokenRules hasBrokenRules=null;
|
||||
foreach(GroupAssignment groupAssignment in this)
|
||||
IVEHasBrokenRules hasBrokenRules = null;
|
||||
foreach (GroupAssignment groupAssignment in this)
|
||||
if ((hasBrokenRules = groupAssignment.HasBrokenRules) != null) return hasBrokenRules;
|
||||
return hasBrokenRules;
|
||||
}
|
||||
@@ -104,8 +104,8 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
get
|
||||
{
|
||||
IVEHasBrokenRules hasBrokenRules = HasBrokenRules;
|
||||
return (hasBrokenRules != null ? hasBrokenRules.BrokenRules : null);
|
||||
IVEHasBrokenRules hasBrokenRules = HasBrokenRules;
|
||||
return (hasBrokenRules != null ? hasBrokenRules.BrokenRules : null);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
@@ -165,7 +165,7 @@ namespace VEPROMS.CSLA.Library
|
||||
private void DataPortal_Fetch(GIDCriteria criteria)
|
||||
{
|
||||
this.RaiseListChangedEvents = false;
|
||||
if(_MyLog.IsDebugEnabled)_MyLog.DebugFormat("[{0}] GroupAssignments.DataPortal_FetchGID", GetHashCode());
|
||||
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] GroupAssignments.DataPortal_FetchGID", GetHashCode());
|
||||
try
|
||||
{
|
||||
using (SqlConnection cn = Database.VEPROMS_SqlConnection)
|
||||
@@ -184,7 +184,7 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
if(_MyLog.IsErrorEnabled)_MyLog.Error("GroupAssignments.DataPortal_FetchGID", ex);
|
||||
if (_MyLog.IsErrorEnabled) _MyLog.Error("GroupAssignments.DataPortal_FetchGID", ex);
|
||||
throw new DbCslaException("GroupAssignments.DataPortal_Fetch", ex);
|
||||
}
|
||||
this.RaiseListChangedEvents = true;
|
||||
@@ -269,8 +269,8 @@ namespace VEPROMS.CSLA.Library
|
||||
/// </summary>
|
||||
public partial class GroupAssignmentsPropertyDescriptor : vlnListPropertyDescriptor
|
||||
{
|
||||
private GroupAssignment Item { get { return (GroupAssignment) _Item;} }
|
||||
public GroupAssignmentsPropertyDescriptor(GroupAssignments collection, int index):base(collection, index){;}
|
||||
private GroupAssignment Item { get { return (GroupAssignment)_Item; } }
|
||||
public GroupAssignmentsPropertyDescriptor(GroupAssignments collection, int index) : base(collection, index) { ;}
|
||||
}
|
||||
#endregion
|
||||
#region Converter
|
||||
@@ -281,7 +281,7 @@ namespace VEPROMS.CSLA.Library
|
||||
if (destType == typeof(string) && value is GroupAssignments)
|
||||
{
|
||||
// Return department and department role separated by comma.
|
||||
return ((GroupAssignments) value).Items.Count.ToString() + " Assignments";
|
||||
return ((GroupAssignments)value).Items.Count.ToString() + " Assignments";
|
||||
}
|
||||
return base.ConvertTo(context, culture, value, destType);
|
||||
}
|
||||
|
Reference in New Issue
Block a user