42 lines
1.2 KiB
JavaScript
42 lines
1.2 KiB
JavaScript
export const searchResultsActionTypes = {
|
|
GETSEARCHRESULTS: "GETSEARCHRESULTS",
|
|
SETSEARCHRESULTS: "SETSEARCHRESULTS",
|
|
UPDATESEARCHRESULTS: "UPDATESEARCHRESULTS",
|
|
SETSEARCHDETAILS: "SETSEARCHDETAILS",
|
|
SETDOCUMENTDETAILS: "SETDOCUMENTDETAILS",
|
|
SETDOCUMENTHISTORY: "SETDOCUMENTHISTORY",
|
|
};
|
|
|
|
export const getSearchResultshObj = () => (dispatch) => {
|
|
return dispatch({
|
|
type: searchResultsActionTypes.GETSEARCHRESULTS,
|
|
});
|
|
};
|
|
|
|
export const setSearchResults = (searchResults) => (dispatch) => {
|
|
return dispatch({
|
|
type: searchResultsActionTypes.SETSEARCHRESULTS,
|
|
searchResultsObj: searchResults,
|
|
});
|
|
};
|
|
|
|
export const setSearchDetails = (searchDetails) => (dispatch) => {
|
|
return dispatch({
|
|
type: searchResultsActionTypes.SETSEARCHDETAILS,
|
|
searchDetailsObj: searchDetails,
|
|
});
|
|
};
|
|
export const setDocumentDetails = (documentDetails) => (dispatch) => {
|
|
return dispatch({
|
|
type: searchResultsActionTypes.SETDOCUMENTDETAILS,
|
|
documentDetailsObj: documentDetails,
|
|
});
|
|
};
|
|
|
|
export const setDocumentHistory = (documentHistory) => (dispatch) => {
|
|
return dispatch({
|
|
type: searchResultsActionTypes.SETDOCUMENTHISTORY,
|
|
documentHistoryObj: documentHistory,
|
|
});
|
|
};
|