Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grad2 3122 #689

Merged
merged 3 commits into from
Nov 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
1 change: 1 addition & 0 deletions frontend/src/components/Batch/Forms/DistrunForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
17 changes: 17 additions & 0 deletions frontend/src/components/Batch/Forms/DistrunUserForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down Expand Up @@ -260,6 +261,7 @@ import DistributionInput from "@/components/Batch/Forms/FormInputs/DistributionI
import { mapActions, mapState } from "pinia";
import BatchProcessingService from "@/services/BatchProcessingService.js";
import { useAccessStore } from "../../../store/modules/access";
import { useAuthStore } from "../../../store/modules/auth";
import { useSnackbarStore } from "../../../store/modules/snackbar";
import { useBatchProcessingStore } from "../../../store/modules/batchprocessing";
import { useBatchRequestFormStore } from "../../../store/modules/batchRequestFormStore";
Expand Down Expand Up @@ -306,6 +308,11 @@ export default {

watch(group, (newValue) => {
batchRequestFormStore.who = newValue;
if (newValue == "Ministry of Advanced Education") {
batchRequestFormStore.distribution = "User";
} else {
batchRequestFormStore.distribution = "BC Mail";
}
});

return {
Expand Down Expand Up @@ -440,6 +447,7 @@ export default {
],
}),
computed: {
...mapState(useAuthStore, ["userFullName"]),
...mapState(useAccessStore, ["hasPermissions"]),
...mapState(useBatchRequestFormStore, [
"getBatchRequest",
Expand Down Expand Up @@ -603,6 +611,15 @@ export default {
this.group == "Ministry of Advanced Education" &&
this.getCredential == "Blank certificate print"
) {
requestPayload.user = this.userFullName;
requestPayload.address = {
streetLine1: "4TH FLOOR 620 SUPERIOR",
streetLine2: "PO BOX 9886 STN PROV GOVT",
city: "VICTORIA",
region: "BRITISH COLUMBIA",
country: "CANADA",
code: "V8W9T6",
};
requestPayload.schoolOfRecords = ["00000000"];
}
let response = await BatchProcessingService.runDISTRUNUSER(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,14 @@
required
variant="outlined"
></v-text-field>
</v-col> </v-row
><v-row>
</v-col>
</v-row>
<v-row v-if="getDistribution !== 'User'">
<v-col sm="2"><strong>Where</strong></v-col>
<v-col sm="10" md="4">
<v-select
v-model="distribution"
:items="[
'BC Mail',
'Download',
{ title: 'User: ' + userFullName, value: 'User' },
]"
v-model="getDistribution"
:items="['BC Mail', 'Download']"
item-title="title"
item-value="value"
label="Where"
Expand All @@ -34,7 +31,11 @@
<template #bottom></template>
</v-col>
</v-row>
<v-card v-if="distribution === 'User'" class="mt-4" title="Mailing Address">
<v-card
v-if="getDistribution === 'User'"
class="mt-4"
title="Mailing Address"
>
<v-card-text>
<strong>{{ userFullName }}</strong
><br />
Expand Down Expand Up @@ -125,6 +126,7 @@ export default {
"getBatchRunTime",
"getBatchRunCustomDate",
"getbatchRunCustomTime",
"getDistribution",
"getGroup",
"getUserDistributionAddress",
]),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down Expand Up @@ -352,6 +353,7 @@ export default {
this.getBatchRequest,
requestTemplate
);
requestPayload.user = "Shaun Lum";
let response = await BatchProcessingService.runREGALG(
requestPayload,
this.getBatchRequestCrontime
Expand Down
1 change: 1 addition & 0 deletions frontend/src/components/Batch/Forms/NongradDistrunForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
1 change: 1 addition & 0 deletions frontend/src/components/Batch/Forms/PSIForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
color="error"
variant="outlined"
class="m-4"
:loading="batchLoading"
>Cancel</v-btn
>
</div>
Expand Down
Loading