init
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
---
|
||||
source_files:
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/Properties/AssemblyInfo.cs
|
||||
generated_at: "2026-04-17T16:14:39.113101+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "af0b7b9517767fb2"
|
||||
---
|
||||
|
||||
# Properties
|
||||
|
||||
### Purpose
|
||||
This module contains assembly metadata for the DBImportExportModule assembly. It is a standard .NET Framework AssemblyInfo file that defines version information, COM visibility settings, and a unique GUID for the assembly. It exists solely to provide assembly-level configuration and identification for the DBImportExport module.
|
||||
|
||||
### Public Interface
|
||||
No public types are defined. This file contains only assembly-level attributes:
|
||||
- `AssemblyTitle("DBImportExportModule")` - Sets the assembly title
|
||||
- `AssemblyProduct("DBImportExportModule")` - Sets the product name
|
||||
- `AssemblyCopyright("Copyright © 2016")` - Sets copyright information
|
||||
- `ComVisible(false)` - Disables COM visibility for types in this assembly
|
||||
- `Guid("bc9afa01-e327-4133-8818-141281f9b3a0")` - Unique identifier for COM interop
|
||||
- `AssemblyVersion("1.0.0.0")` - Assembly version
|
||||
- `AssemblyFileVersion("1.0.0.0")` - File version
|
||||
|
||||
### Invariants
|
||||
- The GUID `bc9afa01-e327-4133
|
||||
@@ -0,0 +1,50 @@
|
||||
---
|
||||
source_files:
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/Resources/TranslateExtension.cs
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/Resources/StringResources.Designer.cs
|
||||
generated_at: "2026-04-17T16:12:22.120307+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "87d5f6e196d99a39"
|
||||
---
|
||||
|
||||
# Resources
|
||||
|
||||
### Purpose
|
||||
This module provides localization infrastructure for the DB Import/Export feature. It contains a WPF markup extension for XAML-based string resource lookup and an auto-generated strongly-typed resource class containing localized strings for file dialog filters, button labels, and validation messages used in database import/export workflows.
|
||||
|
||||
### Public Interface
|
||||
|
||||
**`TranslateExtension` class** (`MarkupExtension`):
|
||||
- `TranslateExtension(string key)` - Constructor accepting the resource key to look up.
|
||||
- `object ProvideValue(IServiceProvider serviceProvider)` - Returns the localized string for `_key`, or an error marker if not found.
|
||||
|
||||
**`StringResources` class** (internal, auto-generated):
|
||||
- `static ResourceManager ResourceManager { get; }` - Returns the cached `ResourceManager` instance for the `DBImportExport.Resources.StringResources` resource bundle.
|
||||
- `static CultureInfo Culture { get; set; }` - Gets or sets the current UI culture for resource lookups.
|
||||
- `static string ExportFileBrowse_Filter { get; }` - File dialog filter: `"DataPRO DB XML File (*.dbxml)|*.dbxml|All Files (*.*)|*.*"`.
|
||||
- `static string ExportFileData_Empty { get; }` - Message: `"No data to export"`.
|
||||
- `static string ExportFileName_Empty { get; }` - Message: `"No export file name specified"`.
|
||||
- `static string ExportView_Browse { get; }` - Label: `"Browse"`.
|
||||
- `static string ExportView_File { get; }` - Label: `"File"`.
|
||||
- `static string ImportFileBrowse_Filter { get; }` - File dialog filter: `"DataPRO DB XML File (*.dbxml)|*.dbxml|All Files (*.*)|*.*"`.
|
||||
- `static string ImportView_Browse { get; }` - Label: `"Browse"`.
|
||||
- `static string ImportView_File { get; }` - Label: `"File"`.
|
||||
|
||||
### Invariants
|
||||
- `TranslateExtension._key` is immutable after construction (readonly field).
|
||||
- `ProvideValue` always returns a non-null string; it never returns null.
|
||||
- When `_key` is null or empty, `ProvideValue` returns the constant `"#stringnotfound#"`.
|
||||
- When the resource key is not found in the resource manager, `ProvideValue` returns `"#stringnotfound# "` concatenated with the key name.
|
||||
- `StringResources` is marked `internal` and cannot be accessed outside its assembly.
|
||||
|
||||
### Dependencies
|
||||
- **Depends on**: `System`, `System.Windows.Markup`, `System.Resources`, `System.Globalization`.
|
||||
- **Depended on by**: Unclear from source alone; presumably XAML files in the DBImportExport module.
|
||||
|
||||
### Gotchas
|
||||
- The `TranslateExtension` implementation is nearly identical to the one in `DataPRO/Modules/ISO/ExtraProperties/Resources`. This is code duplication; consider extracting to a shared localization library if maintenance becomes an issue.
|
||||
- The `NotFound` constant value `"#stringnotfound#"` is duplicated verbatim from the ISO ExtraProperties module.
|
||||
- The `StringResources` class is auto-generated; manual edits will be lost when the `.resx` file is regenerated.
|
||||
|
||||
---
|
||||
@@ -0,0 +1,19 @@
|
||||
---
|
||||
source_files:
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/View/DBExportView.xaml.cs
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/View/DBImportView.xaml.cs
|
||||
generated_at: "2026-04-17T16:12:22.121226+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "ceca07e66fc864c9"
|
||||
---
|
||||
|
||||
# View
|
||||
|
||||
### Purpose
|
||||
This module provides the WPF view components for the database import and export functionality. It contains code-behind partial classes for XAML views that implement specific interfaces from the DTS common infrastructure, enabling view composition and dependency injection patterns.
|
||||
|
||||
### Public Interface
|
||||
|
||||
**`DBExportView` class** (partial, implements `IDBExportView`):
|
||||
- `
|
||||
@@ -0,0 +1,35 @@
|
||||
---
|
||||
source_files:
|
||||
- DataPRO/Modules/SystemSettings/DBImportExport/ViewModel/DBViewModel.cs
|
||||
generated_at: "2026-04-17T16:00:15.722645+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "9547fb8cbb8ab859"
|
||||
---
|
||||
|
||||
# Documentation: DBViewModel.cs
|
||||
|
||||
## 1. Purpose
|
||||
|
||||
This module provides the ViewModel for database import/export functionality within the DBImportExport namespace. It serves as a mediator between the import/export views and the underlying data operations, handling file browsing dialogs, XML data transport, and status notifications via Prism's event aggregation system. As noted in the source comments, functionality is currently limited to XML string transport due to DataPRO object dependencies residing in another project.
|
||||
|
||||
## 2. Public Interface
|
||||
|
||||
### Constructor
|
||||
```csharp
|
||||
public DBViewModel(IDBImportView importView, IDBExportView exportView, IRegionManager regionManager, IEventAggregator eventAggregator, IUnityContainer unityContainer)
|
||||
```
|
||||
Initializes the ViewModel, sets DataContext on both views, creates interaction requests, and subscribes to `RaiseNotification` and `BusyIndicatorChangeNotification` events.
|
||||
|
||||
### Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
|----------|------|-------------|
|
||||
| `ImportView` | `IDBImportView` | The import view instance. |
|
||||
| `ExportView` | `IDBExportView` | The export view instance. |
|
||||
| `NotificationRequest` | `InteractionRequest<Notification>` | Request object for showing notifications. |
|
||||
| `ConfirmationRequest` | `InteractionRequest<Confirmation>` | Request object for showing confirmations. |
|
||||
| `IsDirty` | `bool` | Dirty state flag (getter only, private setter). |
|
||||
| `IsBusy` | `bool` | Busy indicator for UI loading states. |
|
||||
| `IsMenuIncluded` | `bool` | Toggle for including menu data. |
|
||||
| `IsNavigationIncluded` | `bool`
|
||||
Reference in New Issue
Block a user