diff options
| author | soryu <soryu@soryu.co> | 2026-03-09 16:31:31 +0000 |
|---|---|---|
| committer | soryu <soryu@soryu.co> | 2026-03-09 16:31:31 +0000 |
| commit | e11e7225861c3063f08461ac01005f3315d41be5 (patch) | |
| tree | 81c17946d8f0347c7cebf83ecd731d205983cfc7 /makima/src/db/models.rs | |
| parent | 76566d32a88aa88e5b22e5209f9beb025ab6c299 (diff) | |
| parent | ef643072234477685614ed281e34ef77e45caad4 (diff) | |
| download | soryu-e11e7225861c3063f08461ac01005f3315d41be5.tar.gz soryu-e11e7225861c3063f08461ac01005f3315d41be5.zip | |
fix: resolve merge conflicts with master (integrate DOG features into compact header)makima/soryu-co-soryu---makima--resolve-merge-conflicts-i-f750d00d
- Resolved conflict in OrderDetail.tsx: kept PR compact header layout
with inline badges while adding DOG badge from master
- DOG selector in Actions section preserved from master
- orders.tsx correctly passes dogs prop to OrderDetail (auto-merged correctly)
- directives.tsx auto-merged correctly with DOG props for DirectiveDetail
- Frontend builds successfully with no TypeScript errors
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'makima/src/db/models.rs')
| -rw-r--r-- | makima/src/db/models.rs | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/makima/src/db/models.rs b/makima/src/db/models.rs index 32e55f0..97657dc 100644 --- a/makima/src/db/models.rs +++ b/makima/src/db/models.rs @@ -2925,6 +2925,8 @@ pub struct Order { pub directive_name: Option<String>, /// Repository context pub repository_url: Option<String>, + /// Optional DOG (Directive Order Group) this order belongs to + pub dog_id: Option<Uuid>, pub created_at: DateTime<Utc>, pub updated_at: DateTime<Utc>, } @@ -2943,6 +2945,8 @@ pub struct CreateOrderRequest { /// Directive ID is required for new orders. pub directive_id: Uuid, pub repository_url: Option<String>, + /// Optional DOG (Directive Order Group) to assign this order to. + pub dog_id: Option<Uuid>, } /// Default empty JSON array for labels. @@ -2963,6 +2967,8 @@ pub struct UpdateOrderRequest { pub directive_id: Option<Uuid>, pub directive_step_id: Option<Uuid>, pub repository_url: Option<String>, + /// Optional DOG (Directive Order Group) to assign/reassign this order to. + pub dog_id: Option<Uuid>, } /// Response for order list endpoint. @@ -2986,6 +2992,8 @@ pub struct OrderListQuery { pub priority: Option<String>, /// Filter by linked directive ID pub directive_id: Option<Uuid>, + /// Filter by DOG (Directive Order Group) ID + pub dog_id: Option<Uuid>, /// Text search across title, description, and directive_name (case-insensitive) pub search: Option<String>, } @@ -2997,4 +3005,49 @@ pub struct LinkDirectiveRequest { pub directive_id: Uuid, } +// ============================================================================= +// Directive Order Group (DOG) Types +// ============================================================================= + +/// A Directive Order Group (DOG) — an epic-like grouping of orders within a directive. +/// DOGs allow organizing related orders under a common theme or goal. +#[derive(Debug, Clone, FromRow, Serialize, Deserialize, ToSchema)] +#[serde(rename_all = "camelCase")] +pub struct DirectiveOrderGroup { + pub id: Uuid, + pub directive_id: Uuid, + pub owner_id: Uuid, + pub name: String, + pub description: Option<String>, + /// Status: open, in_progress, done, archived + pub status: String, + pub created_at: DateTime<Utc>, + pub updated_at: DateTime<Utc>, +} + +/// Request to create a new Directive Order Group (DOG). +#[derive(Debug, Deserialize, ToSchema)] +#[serde(rename_all = "camelCase")] +pub struct CreateDirectiveOrderGroupRequest { + pub name: String, + pub description: Option<String>, +} + +/// Request to update a Directive Order Group (DOG). +#[derive(Debug, Default, Deserialize, ToSchema)] +#[serde(rename_all = "camelCase")] +pub struct UpdateDirectiveOrderGroupRequest { + pub name: Option<String>, + pub description: Option<String>, + pub status: Option<String>, +} + +/// Response for DOG list endpoint. +#[derive(Debug, Serialize, ToSchema)] +#[serde(rename_all = "camelCase")] +pub struct DirectiveOrderGroupListResponse { + pub dogs: Vec<DirectiveOrderGroup>, + pub total: i64, +} + |
