二楼料箱下到一楼生成ctu任务和空载具入库单
This commit is contained in:
@@ -252,7 +252,7 @@ namespace Tnb.Common.Redis
|
||||
string data = await GetHash(key, field);
|
||||
Dictionary<String, String> json = JsonConvert.DeserializeObject<Dictionary<String, String>>(data);
|
||||
Type type = typeof(T);
|
||||
if (!type.IsValueType || (type.IsGenericType && type.GetGenericTypeDefinition() == typeof(Nullable<>)))
|
||||
if ((!type.IsValueType && type.GetGenericArguments().Length > 0) || (type.IsGenericType && type.GetGenericTypeDefinition() == typeof(Nullable<>)))
|
||||
{
|
||||
return (T)Convert.ChangeType(json["Value"],type.GetGenericArguments()[0]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user