pub struct SqliteProductionBatchRepository { /* private fields */ }Available on crate feature
sqlite only.Implementations§
Source§impl SqliteProductionBatchRepository
impl SqliteProductionBatchRepository
pub const fn new(pool: Pool<SqliteConnectionManager>) -> Self
Trait Implementations§
Source§impl ProductionBatchRepository for SqliteProductionBatchRepository
impl ProductionBatchRepository for SqliteProductionBatchRepository
Source§fn create(&self, input: CreateProductionBatch) -> Result<ProductionBatch>
fn create(&self, input: CreateProductionBatch) -> Result<ProductionBatch>
Create a new production batch.
Source§fn get(&self, id: ProductionBatchId) -> Result<Option<ProductionBatch>>
fn get(&self, id: ProductionBatchId) -> Result<Option<ProductionBatch>>
Get a production batch by ID.
Source§fn update(
&self,
id: ProductionBatchId,
input: UpdateProductionBatch,
) -> Result<ProductionBatch>
fn update( &self, id: ProductionBatchId, input: UpdateProductionBatch, ) -> Result<ProductionBatch>
Update a production batch (partial).
Source§fn list(&self, filter: ProductionBatchFilter) -> Result<Vec<ProductionBatch>>
fn list(&self, filter: ProductionBatchFilter) -> Result<Vec<ProductionBatch>>
List production batches with filter.
Source§fn add_work_orders(
&self,
id: ProductionBatchId,
work_order_ids: Vec<Uuid>,
) -> Result<ProductionBatch>
fn add_work_orders( &self, id: ProductionBatchId, work_order_ids: Vec<Uuid>, ) -> Result<ProductionBatch>
Link work orders to a batch. Returns the updated batch.
Source§fn remove_work_order(
&self,
id: ProductionBatchId,
work_order_id: Uuid,
) -> Result<ProductionBatch>
fn remove_work_order( &self, id: ProductionBatchId, work_order_id: Uuid, ) -> Result<ProductionBatch>
Remove a work order from a batch. Returns the updated batch.
Auto Trait Implementations§
impl !RefUnwindSafe for SqliteProductionBatchRepository
impl !UnwindSafe for SqliteProductionBatchRepository
impl Freeze for SqliteProductionBatchRepository
impl Send for SqliteProductionBatchRepository
impl Sync for SqliteProductionBatchRepository
impl Unpin for SqliteProductionBatchRepository
impl UnsafeUnpin for SqliteProductionBatchRepository
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more