Commit a33678ba authored by 潘栩锋's avatar 潘栩锋 🚴

修复 SyncPropServiceClient 当客户端没有 对应 ObjName 时的出错

parent fa1cdf1e
......@@ -141,13 +141,16 @@ namespace FLY.OBJComponents.Client
IsInPushValue = true;
foreach (var Dso in DsDso)
{
INotifyPropertyChanged obj = ObjNames[Dso.Key] as INotifyPropertyChanged;
obj.PropertyChanged -= Data_PropertyChanged;
foreach (var dv in Dso.Value)
if (ObjNames.ContainsKey(Dso.Key))
{
PropertiesManager_JSON.SetValue(obj, dv.Key, dv.Value);
INotifyPropertyChanged obj = ObjNames[Dso.Key] as INotifyPropertyChanged;
obj.PropertyChanged -= Data_PropertyChanged;
foreach (var dv in Dso.Value)
{
PropertiesManager_JSON.SetValue(obj, dv.Key, dv.Value);
}
obj.PropertyChanged += Data_PropertyChanged;
}
obj.PropertyChanged += Data_PropertyChanged;
}
IsInPushValue = false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment