Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/hotwax/job-manager into #2e…
Browse files Browse the repository at this point in the history
…bg32y
  • Loading branch information
adityasharma7 committed Oct 27, 2022
2 parents ab17e8d + e0dd7b9 commit 2f9fe6d
Showing 1 changed file with 8 additions and 25 deletions.
33 changes: 8 additions & 25 deletions src/store/modules/job/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,9 @@ const actions: ActionTree<JobState, RootState> = {
}

if (payload.queryString) {
params.inputFields["enumName_value"] = "%"+ payload.queryString + "%"
params.inputFields["enumName_op"] = "like"
params.inputFields["enumName_ic"] = "Y"
params.inputFields["enumName_ic"] = "Y"
params.inputFields["enumName_grp"] = "1"
params.inputFields["description_value"] = "%"+ payload.queryString + "%"
params.inputFields["description_op"] = "like"
params.inputFields["description_value"] = payload.queryString
params.inputFields["description_op"] = "contains"
params.inputFields["description_ic"] = "Y"
params.inputFields["description_grp"] = "2"
}

await JobService.fetchJobInformation(params).then((resp) => {
Expand Down Expand Up @@ -145,15 +139,9 @@ const actions: ActionTree<JobState, RootState> = {
}

if (payload.queryString) {
params.inputFields["enumName_value"] = "%"+ payload.queryString + "%"
params.inputFields["jobName_op"] = "like"
params.inputFields["jobName_ic"] = "Y"
params.inputFields["enumName_ic"] = "Y"
params.inputFields["enumName_grp"] = "1"
params.inputFields["description_value"] = "%"+ payload.queryString + "%"
params.inputFields["description_op"] = "like"
params.inputFields["description_value"] = payload.queryString
params.inputFields["description_op"] = "contains"
params.inputFields["description_ic"] = "Y"
params.inputFields["description_grp"] = "2"
}

await JobService.fetchJobInformation(params).then((resp) => {
Expand Down Expand Up @@ -218,15 +206,10 @@ const actions: ActionTree<JobState, RootState> = {
}

if (payload.queryString) {
params.inputFields["enumName_value"] = "%"+ payload.queryString + "%"
params.inputFields["enumName_op"] = "like"
params.inputFields["enumName_ic"] = "Y"
params.inputFields["enumName_grp"] = "1"
params.inputFields["description_value"] = "%"+ payload.queryString + "%"
params.inputFields["description_op"] = "like"
params.inputFields["description_value"] = payload.queryString
params.inputFields["description_op"] = "contains"
params.inputFields["description_ic"] = "Y"
params.inputFields["description_grp"] = "2"
}
}
await JobService.fetchJobInformation(params).then((resp) => {
if (resp.status === 200 && resp.data.docs?.length > 0 && !hasError(resp)) {
if (resp.data.docs) {
Expand Down Expand Up @@ -753,4 +736,4 @@ const actions: ActionTree<JobState, RootState> = {
}
}
}
export default actions;
export default actions;

0 comments on commit 2f9fe6d

Please sign in to comment.