lml-main
Version:
This is now a mono repository published into many standalone packages.
90 lines (89 loc) • 2.52 kB
TypeScript
import { RxHttpActionTypes, RxHttpRequestAction } from 'redux-rx-http';
import { JobModel } from '@lml/cosmo-ts-data';
export declare const FETCH_JOB_BY_ID: RxHttpActionTypes;
export declare const FETCH_JOBS_BY_ID_BATCH: RxHttpActionTypes;
export declare const FETCH_JOB_BY_JOB_NUMBER: RxHttpActionTypes;
export declare const FETCH_JOBS_BY_JOB_NUMBER: RxHttpActionTypes;
export declare const POST_JOB: RxHttpActionTypes;
export declare const PUT_JOB: RxHttpActionTypes;
export declare const DELETE_JOB: RxHttpActionTypes;
export declare const SET_JOB_BY_ID = "SET_JOB_BY_ID";
export declare const SET_JOBS_BY_ID_BATCH = "SET_JOBS_BY_ID_BATCH";
export interface SetJobByIdAction {
type: 'SET_JOB_BY_ID';
job: JobModel;
}
export interface SetJobsByIdBatchAction {
type: 'SET_JOBS_BY_ID_BATCH';
jobs: {
[refId: string]: JobModel;
};
}
export declare type JobDataAction = SetJobByIdAction | SetJobsByIdBatchAction;
/**
* Fetch a single job by refId
*
* @param refId
* @param showData
* @param args
*/
export declare const fetchJobById: (refId: string, showData?: string, args?: any) => RxHttpRequestAction;
/**
* Fetch a batch of jobs by refId
*
* @param refIds
* @param showData
* @param args
*/
export declare const fetchJobsByIdBatch: (refIds: string[], showData?: string, args?: any) => RxHttpRequestAction;
/**
* Fetch a job by job number
*
* @param jobNumber
* @param showData
* @param args
*/
export declare const fetchJobByJobNumber: (jobNumber: string, showData?: string, args?: any) => RxHttpRequestAction;
/**
* Fetch a jobs by order number
*
* @param jobNumber
* @param showData
* @param args
*/
export declare const fetchJobsByJobNumber: (jobNumber: string, partner: string, showData?: string, args?: any) => RxHttpRequestAction;
/**
* Create a new job
*
* @param job
* @param args
*/
export declare const postJob: (job: JobModel, args?: any) => RxHttpRequestAction;
/**
* Update a job
*
* @param job
* @param args
*/
export declare const putJob: (job: JobModel, args?: any) => RxHttpRequestAction;
/**
* Delete a job
*
* @param refId
* @param args
*/
export declare const deleteJob: (refId: string, args?: any) => RxHttpRequestAction;
/**
* Update the store with a single job by id
*
* @param job
*/
export declare const setJobById: (job: JobModel) => SetJobByIdAction;
/**
* Update a batch of jobs by id
*
* @param jobs
*/
export declare const setJobsByIdBatch: (jobs: {
[refId: string]: JobModel;
}) => SetJobsByIdBatchAction;