优化了Workbench上的操作。

This commit is contained in:
fengjiayi
2025-05-30 23:31:31 +08:00
parent f0eb11c914
commit a19733eff5
35 changed files with 807 additions and 225 deletions

View File

@@ -1048,7 +1048,9 @@ namespace Serein.NodeFlow.Env
return Task.FromResult<NodeInfo>(null);
}
NodeModelBase? nodeModel;
if (methodDetailsInfo is null)
if (methodDetailsInfo is null
|| string.IsNullOrEmpty(methodDetailsInfo.AssemblyName)
|| string.IsNullOrEmpty(methodDetailsInfo.MethodName))
{
nodeModel = FlowNodeExtension.CreateNode(this, nodeControlType); // 加载基础节点
}

View File

@@ -12,6 +12,7 @@ using System.Reflection;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Linq;
using static System.Runtime.InteropServices.JavaScript.JSType;
namespace Serein.NodeFlow.Model
{
@@ -246,12 +247,29 @@ namespace Serein.NodeFlow.Model
{
public static DateTime GetNow() => DateTime.Now;
#region
public static bool BoolOf(object value)
{
return ConvertHelper.ValueParse<bool>(value);
}
public static int IntOf(object value)
{
return ConvertHelper.ValueParse<int>(value);
}
public static int LongOf(object value)
{
return ConvertHelper.ValueParse<int>(value);
}
#endregion
public static Type TypeOf(object type)
{
return type.GetType();
}
public static void Print(object value)
{
SereinEnv.WriteLine(InfoType.INFO, value?.ToString());