|
@@ -545,9 +545,14 @@ namespace InABox.Core
|
|
|
if (value is string && type == typeof(byte[]))
|
|
|
return Convert.FromBase64String(value as string);
|
|
|
|
|
|
- //if (value is string && type == typeof(Memo))
|
|
|
- // return new Memo(value as String); // { _data = value as string };
|
|
|
-
|
|
|
+ if (value is FilterConstant && type == typeof(DateTime))
|
|
|
+ {
|
|
|
+ if (Equals(FilterConstant.Now, value))
|
|
|
+ return DateTime.Now;
|
|
|
+ if (Equals(FilterConstant.Today, value))
|
|
|
+ return DateTime.Today;
|
|
|
+ }
|
|
|
+
|
|
|
if (!(value is IConvertible))
|
|
|
return value;
|
|
|
|