## 主要改进 - 实现 /api/status/model 接口,返回真实PDMS模型状态信息 - 使用MDB.CurrentMDB、Project.CurrentProject等AVEVA API获取真实数据 - 移除硬编码的CurrentSession、PositionInfo、PdmsSpecific等复杂结构 - 简化数据模型,只保留核心的真实数据字段 ## 技术实现 - 通过DbSession获取真实的用户名、会话开始时间和持续时间 - 通过WorldMembers()获取真实的模型元素统计 - 修复DateTime类型的null合并运算符编译错误 - 清理不使用的方法和类定义 ## API返回数据 现在返回的数据主要包含真实的PDMS信息: - ModelLoaded: MDB连接状态检查 - ProjectName: 真实的设计数据库名称 - MdsName: 真实的MDB名称 - UserName: 真实的数据库会话用户 - StartTime: 真实的会话创建时间 - TotalElements: 真实的模型元素数量统计 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
83 lines
3.8 KiB
XML
83 lines
3.8 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
|
<PropertyGroup>
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
<ProjectGuid>{5E040389-82EF-4A66-942E-A65817CAB55F}</ProjectGuid>
|
|
<OutputType>Library</OutputType>
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
<RootNamespace>TellmePdmsPluging</RootNamespace>
|
|
<AssemblyName>TellmePdmsPluging</AssemblyName>
|
|
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
|
<FileAlignment>512</FileAlignment>
|
|
<Deterministic>true</Deterministic>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
|
<DebugSymbols>true</DebugSymbols>
|
|
<DebugType>full</DebugType>
|
|
<Optimize>false</Optimize>
|
|
<OutputPath>bin\Debug\</OutputPath>
|
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
|
<ErrorReport>prompt</ErrorReport>
|
|
<WarningLevel>4</WarningLevel>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
|
<DebugType>pdbonly</DebugType>
|
|
<Optimize>true</Optimize>
|
|
<OutputPath>bin\Release\</OutputPath>
|
|
<DefineConstants>TRACE</DefineConstants>
|
|
<ErrorReport>prompt</ErrorReport>
|
|
<WarningLevel>4</WarningLevel>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
|
<DebugSymbols>true</DebugSymbols>
|
|
<DebugType>full</DebugType>
|
|
<Optimize>false</Optimize>
|
|
<OutputPath>bin\x86\Debug\</OutputPath>
|
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
|
<ErrorReport>prompt</ErrorReport>
|
|
<WarningLevel>4</WarningLevel>
|
|
<PlatformTarget>x86</PlatformTarget>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
|
<DebugType>pdbonly</DebugType>
|
|
<Optimize>true</Optimize>
|
|
<OutputPath>bin\x86\Release\</OutputPath>
|
|
<DefineConstants>TRACE</DefineConstants>
|
|
<ErrorReport>prompt</ErrorReport>
|
|
<WarningLevel>4</WarningLevel>
|
|
<PlatformTarget>x86</PlatformTarget>
|
|
</PropertyGroup>
|
|
<ItemGroup>
|
|
<Reference Include="Aveva.ApplicationFramework">
|
|
<HintPath>..\..\..\..\..\AVEVA\Plant\PDMS12.1.SP4\Aveva.ApplicationFramework.dll</HintPath>
|
|
</Reference>
|
|
<Reference Include="Aveva.ApplicationFramework.Presentation.Customize">
|
|
<HintPath>..\..\..\..\..\AVEVA\Plant\PDMS12.1.SP4\Aveva.ApplicationFramework.Presentation.Customize.dll</HintPath>
|
|
</Reference>
|
|
<Reference Include="Aveva.Pdms.Database">
|
|
<HintPath>..\..\..\..\..\AVEVA\Plant\PDMS12.1.SP4\Aveva.Pdms.Database.dll</HintPath>
|
|
</Reference>
|
|
<Reference Include="PMLNet">
|
|
<HintPath>..\..\..\..\..\AVEVA\Plant\PDMS12.1.SP4\PMLNet.dll</HintPath>
|
|
</Reference>
|
|
<Reference Include="System" />
|
|
<Reference Include="System.Windows.Forms" />
|
|
<Reference Include="System.Core" />
|
|
<Reference Include="System.Xml.Linq" />
|
|
<Reference Include="System.Data.DataSetExtensions" />
|
|
<Reference Include="System.Data" />
|
|
<Reference Include="System.Xml" />
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<Compile Include="Class1.cs" />
|
|
<Compile Include="Core\ICommand.cs" />
|
|
<Compile Include="Core\ApiResponse.cs" />
|
|
<Compile Include="Core\PdmsManager.cs" />
|
|
<Compile Include="Models\ModelStatusResponse.cs" />
|
|
<Compile Include="Network\HttpServer.cs" />
|
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
|
</ItemGroup>
|
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
|
</Project> |