huskies: merge 1201 story Chat notification when a new work item is filed
This commit is contained in:
@@ -15,7 +15,7 @@ pub(crate) fn tool_create_epic(args: &Value, ctx: &AppContext) -> Result<String,
|
||||
|
||||
// Bug 1102: resolve and validate origin BEFORE creating the epic so a
|
||||
// missing-attribution call leaves no half-state behind.
|
||||
let origin = super::build_origin(args)?;
|
||||
let (origin, origin_label) = super::build_origin(args)?;
|
||||
|
||||
let root = ctx.state.get_project_root()?;
|
||||
let success_criteria = req.success_criteria_strings();
|
||||
@@ -35,6 +35,15 @@ pub(crate) fn tool_create_epic(args: &Value, ctx: &AppContext) -> Result<String,
|
||||
|
||||
crate::crdt_state::set_origin(&epic_id, &origin);
|
||||
|
||||
let _ = ctx
|
||||
.watcher_tx
|
||||
.send(crate::io::watcher::WatcherEvent::NewItemCreated {
|
||||
item_id: epic_id.clone(),
|
||||
item_type: "epic".to_string(),
|
||||
name: req.name.as_ref().to_string(),
|
||||
origin: origin_label,
|
||||
});
|
||||
|
||||
Ok(format!("Created epic: {epic_id}"))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user