Changed TODO comment to CSLATODO

Corrected logic for IsValidList to use IsValidList rather than IsValid
This commit is contained in:
Rich
2010-09-27 16:10:01 +00:00
parent fe23fd84e3
commit fb3ed8d053
49 changed files with 768 additions and 768 deletions

View File

@@ -226,7 +226,7 @@ namespace VEPROMS.CSLA.Library
if (_StartDate != tmp.ToString())
{
_StartDate = tmp.ToString();
// TODO: Any Cross Property Validation
// CSLATODO: Any Cross Property Validation
}
}
catch
@@ -256,7 +256,7 @@ namespace VEPROMS.CSLA.Library
if (_EndDate != tmp.ToString())
{
_EndDate = tmp.ToString();
// TODO: Any Cross Property Validation
// CSLATODO: Any Cross Property Validation
}
}
catch
@@ -332,9 +332,9 @@ namespace VEPROMS.CSLA.Library
if(list.Contains(this))
return (IsNew && !IsDirty) ? true : base.IsValid;
list.Add(this);
return ((IsNew && !IsDirty) ? true : base.IsValid) && (_MyFolder == null ? true : _MyFolder.IsValid) && (_MyGroup == null ? true : _MyGroup.IsValid) && (_MyRole == null ? true : _MyRole.IsValid);
return ((IsNew && !IsDirty) ? true : base.IsValid) && (_MyFolder == null ? true : _MyFolder.IsValidList(list)) && (_MyGroup == null ? true : _MyGroup.IsValidList(list)) && (_MyRole == null ? true : _MyRole.IsValidList(list));
}
// TODO: Replace base Assignment.ToString function as necessary
// CSLATODO: Replace base Assignment.ToString function as necessary
/// <summary>
/// Overrides Base ToString
/// </summary>
@@ -343,7 +343,7 @@ namespace VEPROMS.CSLA.Library
//{
// return base.ToString();
//}
// TODO: Check Assignment.GetIdValue to assure that the ID returned is unique
// CSLATODO: Check Assignment.GetIdValue to assure that the ID returned is unique
/// <summary>
/// Overrides Base GetIdValue - Used internally by CSLA to determine equality
/// </summary>
@@ -402,12 +402,12 @@ namespace VEPROMS.CSLA.Library
new Csla.Validation.CommonRules.MaxLengthRuleArgs("UsrID", 100));
//ValidationRules.AddDependantProperty("x", "y");
_AssignmentExtension.AddValidationRules(ValidationRules);
// TODO: Add other validation rules
// CSLATODO: Add other validation rules
}
protected override void AddInstanceBusinessRules()
{
_AssignmentExtension.AddInstanceValidationRules(ValidationRules);
// TODO: Add other validation rules
// CSLATODO: Add other validation rules
}
private static bool StartDateValid(Assignment target, Csla.Validation.RuleArgs e)
{
@@ -477,7 +477,7 @@ namespace VEPROMS.CSLA.Library
#region Authorization Rules
protected override void AddAuthorizationRules()
{
//TODO: Who can read/write which fields
//CSLATODO: Who can read/write which fields
//AuthorizationRules.AllowRead(AID, "<Role(s)>");
//AuthorizationRules.AllowRead(GID, "<Role(s)>");
//AuthorizationRules.AllowRead(RID, "<Role(s)>");
@@ -497,23 +497,23 @@ namespace VEPROMS.CSLA.Library
}
protected override void AddInstanceAuthorizationRules()
{
//TODO: Who can read/write which fields
//CSLATODO: Who can read/write which fields
_AssignmentExtension.AddInstanceAuthorizationRules(AuthorizationRules);
}
public static bool CanAddObject()
{
// TODO: Can Add Authorization
// CSLATODO: Can Add Authorization
//return Csla.ApplicationContext.User.IsInRole("ProjectManager");
return true;
}
public static bool CanGetObject()
{
// TODO: CanGet Authorization
// CSLATODO: CanGet Authorization
return true;
}
public static bool CanDeleteObject()
{
// TODO: CanDelete Authorization
// CSLATODO: CanDelete Authorization
//bool result = false;
//if (Csla.ApplicationContext.User.IsInRole("ProjectManager"))result = true;
//if (Csla.ApplicationContext.User.IsInRole("Administrator"))result = true;
@@ -522,7 +522,7 @@ namespace VEPROMS.CSLA.Library
}
public static bool CanEditObject()
{
// TODO: CanEdit Authorization
// CSLATODO: CanEdit Authorization
//return Csla.ApplicationContext.User.IsInRole("ProjectManager");
return true;
}
@@ -718,7 +718,7 @@ namespace VEPROMS.CSLA.Library
_AID = aid;
}
}
// TODO: If Create needs to access DB - It should not be marked RunLocal
// CSLATODO: If Create needs to access DB - It should not be marked RunLocal
[RunLocal()]
private new void DataPortal_Create()
{
@@ -727,7 +727,7 @@ namespace VEPROMS.CSLA.Library
_StartDate = _AssignmentExtension.DefaultStartDate;
_DTS = _AssignmentExtension.DefaultDTS;
_UsrID = _AssignmentExtension.DefaultUsrID;
// TODO: Add any defaults that are necessary
// CSLATODO: Add any defaults that are necessary
ValidationRules.CheckRules();
}
private void ReadData(SafeDataReader dr)
@@ -842,7 +842,7 @@ namespace VEPROMS.CSLA.Library
SqlParameter param_LastChanged = new SqlParameter("@newLastChanged", SqlDbType.Timestamp);
param_LastChanged.Direction = ParameterDirection.Output;
cm.Parameters.Add(param_LastChanged);
// TODO: Define any additional output parameters
// CSLATODO: Define any additional output parameters
cm.ExecuteNonQuery();
// Save all values being returned from the Procedure
_AID = (int)cm.Parameters["@newAID"].Value;
@@ -884,7 +884,7 @@ namespace VEPROMS.CSLA.Library
SqlParameter param_LastChanged = new SqlParameter("@newLastChanged", SqlDbType.Timestamp);
param_LastChanged.Direction = ParameterDirection.Output;
cm.Parameters.Add(param_LastChanged);
// TODO: Define any additional output parameters
// CSLATODO: Define any additional output parameters
cm.ExecuteNonQuery();
// Save all values being returned from the Procedure
aid = (int)cm.Parameters["@newAID"].Value;
@@ -951,7 +951,7 @@ namespace VEPROMS.CSLA.Library
SqlParameter param_LastChanged = new SqlParameter("@newLastChanged", SqlDbType.Timestamp);
param_LastChanged.Direction = ParameterDirection.Output;
cm.Parameters.Add(param_LastChanged);
// TODO: Define any additional output parameters
// CSLATODO: Define any additional output parameters
cm.ExecuteNonQuery();
// Save all values being returned from the Procedure
_LastChanged = (byte[])cm.Parameters["@newLastChanged"].Value;
@@ -1004,7 +1004,7 @@ namespace VEPROMS.CSLA.Library
SqlParameter param_LastChanged = new SqlParameter("@newLastChanged", SqlDbType.Timestamp);
param_LastChanged.Direction = ParameterDirection.Output;
cm.Parameters.Add(param_LastChanged);
// TODO: Define any additional output parameters
// CSLATODO: Define any additional output parameters
cm.ExecuteNonQuery();
// Save all values being returned from the Procedure
return (byte[])cm.Parameters["@newLastChanged"].Value;
@@ -1057,7 +1057,7 @@ namespace VEPROMS.CSLA.Library
cm.CommandText = "deleteAssignment";
// Input PK Fields
cm.Parameters.AddWithValue("@AID", aid);
// TODO: Define any additional output parameters
// CSLATODO: Define any additional output parameters
cm.ExecuteNonQuery();
}
}
@@ -1196,7 +1196,7 @@ namespace VEPROMS.CSLA.Library
// {
// partial class AssignmentExtension : extensionBase
// {
// // TODO: Override automatic defaults
// // CSLATODO: Override automatic defaults
// public virtual SmartDate DefaultStartDate
// {
// get { return DateTime.Now.ToShortDateString(); }