pub struct RedmineProvider { /* private fields */ }Expand description
Redmine implementation of the TrackerProvider contract.
Constructed once at startup and shared via Arc<dyn TrackerProvider>.
Requires a valid API token and a populated RedmineConfig.
Implementations§
Source§impl RedmineProvider
impl RedmineProvider
Sourcepub fn new(config: RedmineConfig, token: String) -> Self
pub fn new(config: RedmineConfig, token: String) -> Self
Creates a new RedmineProvider from a loaded config and a token.
Trait Implementations§
Source§impl TrackerProvider for RedmineProvider
impl TrackerProvider for RedmineProvider
Source§fn label_colors(&self) -> LabelColorMaps
fn label_colors(&self) -> LabelColorMaps
Exposes the colour maps configured in redmine.yaml to the orchestrator.
The orchestrator converts the raw strings to ratatui::Color values — this
crate stays free of any UI/rendering dependency.
Source§fn fetch_activities<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Vec<Activity>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn fetch_activities<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Vec<Activity>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Fetches all available time-tracking activity categories from Redmine.
Delegates to GET /enumerations/time_entry_activities.json.
Source§fn fetch_time_entries<'life0, 'life1, 'async_trait>(
&'life0 self,
ticket_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Vec<TimeEntry>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn fetch_time_entries<'life0, 'life1, 'async_trait>(
&'life0 self,
ticket_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Vec<TimeEntry>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Fetches all time entries recorded on a Redmine issue.
Delegates to GET /time_entries.json?issue_id={id}.
Source§fn log_time<'life0, 'life1, 'async_trait>(
&'life0 self,
ticket_id: &'life1 str,
entry: TimeEntryRequest,
) -> Pin<Box<dyn Future<Output = Result<(), TrackerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn log_time<'life0, 'life1, 'async_trait>(
&'life0 self,
ticket_id: &'life1 str,
entry: TimeEntryRequest,
) -> Pin<Box<dyn Future<Output = Result<(), TrackerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Submits a new time entry on the given Redmine issue.
Fetches the issue beforehand to attach budget_hours and remaining_hours
(ETC) directly to the time entry payload — as required by the Redmine Budget
plugin. Both fields are omitted when the issue does not expose them (vanilla
Redmine). The fetch failure is non-fatal: submission proceeds without them.
Delegates to POST /time_entries.json.