|
@@ -17,8 +17,12 @@ using MBIEquipItem = SAGA.Models.EquipmentItem;
|
|
|
|
|
|
namespace SAGA.GplotRelationComputerManage
|
|
|
{
|
|
|
- public class ObjectControlRelationshipHandler
|
|
|
+ public class ObjectControlRelationshipHandler : IElectricalRelationHandler
|
|
|
{
|
|
|
+ public string ElectricalRelationType
|
|
|
+ {
|
|
|
+ get { return "ControlRelation"; }
|
|
|
+ }
|
|
|
/// <summary>
|
|
|
/// 获取解析数据源
|
|
|
/// </summary>
|
|
@@ -68,7 +72,7 @@ namespace SAGA.GplotRelationComputerManage
|
|
|
//孤立节点
|
|
|
var orphanNodes = eqs.Where(t => t.Childrens.Count == 0 && t.Parent == null).ToList();
|
|
|
|
|
|
- DrawDataServer.SaveAsFile<DataNode>(new DataNode("root") { Childrens = incomingCabinet }, "ControlRelation");
|
|
|
+ //DrawDataServer.SaveAsFile<DataNode>(new DataNode("root") { Childrens = incomingCabinet }, "ControlRelation");
|
|
|
List<DataNode> nodes = new List<DataNode>();
|
|
|
nodes.Add(new DataNode() { Childrens = incomingCabinet });
|
|
|
nodes.Add(new DataNode() { Childrens = orphanNodes });
|
|
@@ -80,9 +84,9 @@ namespace SAGA.GplotRelationComputerManage
|
|
|
/// </summary>
|
|
|
/// <param name="context"></param>
|
|
|
/// <returns></returns>
|
|
|
- public List<string> GetComputeData(PowerComputerContext context)
|
|
|
+ public List<DataNode> GetComputeData(PowerComputerContext context)
|
|
|
{
|
|
|
- return null;
|
|
|
+ return GetViewData(context);
|
|
|
}
|
|
|
|
|
|
private DataNode ConvertToDataNode(PowerComputerContext context,MBIEquipItem item)
|