@byu-oit/vue-decision-processing-components 8.35.13 → 8.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -64,8 +64,8 @@
64
64
  ...mapState({
65
65
  env: 'environment',
66
66
  applicantId: state => state.application.applicantId,
67
- applicantFirstName: state => state.application.preferredFirstName,
68
- applicantSurname: state => state.application.surname,
67
+ applicantFirstName: state => state.application.basic.preferredFirstName,
68
+ applicantSurname: state => state.application.basic.surname,
69
69
  applicantDob: state => state.application.personalRecords.dateOfBirth
70
70
  }),
71
71
  spinner () { return faSpinner },
@@ -76,12 +76,12 @@
76
76
  methods: {
77
77
  getByuId: async function () {
78
78
  try {
79
- const surname = this.applicantSurname
80
- const preferredFirstName = this.applicantFirstName
81
- const applicantDob = new Date(this.applicantDob).toISOString().split('T')[0].trim()
79
+ const surname = this.applicantSurname ? this.applicantSurname.trim() : ''
80
+ const preferredFirstName = this.applicantFirstName ? this.applicantFirstName.trim() : ''
81
+ const applicantDob = this.applicantDob ? new Date(this.applicantDob).toISOString().split('T')[0].trim() : ''
82
82
  const url = this.env === 'production'
83
- ? `https://api.byu.edu/byuapi/persons/v4/?preferred_first_name=${preferredFirstName.trim()}&surname=${surname.trim()}&vital_record.date_of_birth=${applicantDob.trim()}`
84
- : `https://api-sandbox.byu.edu/byuapi/persons/v4/?preferred_first_name=${preferredFirstName.trim()}&surname=${surname.trim()}&vital_record.date_of_birth=${applicantDob.trim()}`
83
+ ? `https://api.byu.edu/byuapi/persons/v4/?preferred_first_name=${preferredFirstName}&surname=${surname}&vital_record.date_of_birth=${applicantDob}`
84
+ : `https://api-sandbox.byu.edu/byuapi/persons/v4/?preferred_first_name=${preferredFirstName}&surname=${surname}&vital_record.date_of_birth=${applicantDob}`
85
85
 
86
86
  const { body, status } = await window.byu.auth.request({ url })
87
87
  if (status >= 400) {
package/README.md CHANGED
@@ -1,2 +1,24 @@
1
1
  # vue-decision-processing-components
2
+
3
+ ## Overview
2
4
  Vue.js components to be shared between the decision processing applications for the various CES Schools.
5
+
6
+ ## How to Use This
7
+
8
+ - All Decision Processing Clients use various components from this npm package.
9
+
10
+ ## How to Build Locally
11
+
12
+ - Currently no way to run/build locally
13
+ - installation: npm install @byu-oit/vue-decision-processing-components
14
+
15
+ ## How to Publish
16
+ - Bump version number in [package.json](./package.json#L3) using the following command in bash
17
+ - `npm version [patch|minor|major]`
18
+ - then change the commit message to follow the conventional commit message standard `git commit --amend` to something like `chore: bump version x.y.z`
19
+ This automatically creates a git tag if you run `git push --follow-tags` (which labels commits with the exact version that was published to npm).
20
+ - PR to main
21
+ - GHA publishes to npm
22
+
23
+ ## How to Test
24
+ - vue-decision-processing-components can be tested by making changes to node modules in any decision-processing client and then copied to this repo to push the changes to prd.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@byu-oit/vue-decision-processing-components",
3
- "version": "8.35.13",
3
+ "version": "8.36.0",
4
4
  "description": "Vue components shared between decision processing systems for the CES schools.",
5
5
  "dependencies": {
6
6
  "@fortawesome/fontawesome-free": "^5.15.4",
@@ -40,7 +40,6 @@ const parseTotal = json => {
40
40
 
41
41
  const parseStats = json => {
42
42
  const stats = get(json, 'stats', [])
43
- console.log(`api/packetList::parseStats::stats=${JSON.stringify(stats)}`)
44
43
  const admitPeriods = stats.map(s => s.key).filter(s => /^[0-9]{5}$/.test(s))
45
44
  return stats.reduce((acc, curr) => {
46
45
  const { key, value } = curr
@@ -52,6 +51,5 @@ export default (json) => {
52
51
  const data = parseValues(json)
53
52
  const total = parseTotal(json)
54
53
  const stats = parseStats(json)
55
- console.log(`api/packetList::parseResponse::stats=${JSON.stringify(stats)}`)
56
54
  return { data, total, stats }
57
55
  }
@@ -24,7 +24,6 @@ export const getters = {
24
24
 
25
25
  export const mutations = {
26
26
  setUsers (state, { users = [] }) {
27
- console.log(`store::users::setUsers::users=${JSON.stringify(users)}`)
28
27
  state.list = users
29
28
  },
30
29
  setUserAssignmentCount (state, { byuId, count }) {