catchup-library-web 2.2.21 → 2.2.23

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.
package/dist/index.js CHANGED
@@ -7921,76 +7921,88 @@ var retrieveCurrencyTypeOptionList = () => {
7921
7921
  var retrieveBrandDTOByUserProfileOptionList = (userProfile) => {
7922
7922
  const brandDTOOptionList = [];
7923
7923
  if (userProfile) {
7924
- for (const branchDTO of userProfile.branchDTOList) {
7925
- const currentBrand = branchDTO.gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO;
7926
- if (brandDTOOptionList.findIndex(
7927
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7928
- ) === -1) {
7929
- brandDTOOptionList.push({
7930
- value: currentBrand.id,
7931
- fullValue: currentBrand,
7932
- text: currentBrand.name
7933
- });
7924
+ if (userProfile.branchDTOList) {
7925
+ for (const branchDTO of userProfile.branchDTOList) {
7926
+ const currentBrand = branchDTO.gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO;
7927
+ if (brandDTOOptionList.findIndex(
7928
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7929
+ ) === -1) {
7930
+ brandDTOOptionList.push({
7931
+ value: currentBrand.id,
7932
+ fullValue: currentBrand,
7933
+ text: currentBrand.name
7934
+ });
7935
+ }
7934
7936
  }
7935
7937
  }
7936
- for (const gradeDTO of userProfile.gradeDTOList) {
7937
- const currentBrand = gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO;
7938
- if (brandDTOOptionList.findIndex(
7939
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7940
- ) === -1) {
7941
- brandDTOOptionList.push({
7942
- value: currentBrand.id,
7943
- fullValue: currentBrand,
7944
- text: currentBrand.name
7945
- });
7938
+ if (userProfile.gradeDTOList) {
7939
+ for (const gradeDTO of userProfile.gradeDTOList) {
7940
+ const currentBrand = gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO;
7941
+ if (brandDTOOptionList.findIndex(
7942
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7943
+ ) === -1) {
7944
+ brandDTOOptionList.push({
7945
+ value: currentBrand.id,
7946
+ fullValue: currentBrand,
7947
+ text: currentBrand.name
7948
+ });
7949
+ }
7946
7950
  }
7947
7951
  }
7948
- for (const seasonDTO of userProfile.seasonDTOList) {
7949
- const currentBrand = seasonDTO.institutionDTO.campusDTO.brandDTO;
7950
- if (brandDTOOptionList.findIndex(
7951
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7952
- ) === -1) {
7953
- brandDTOOptionList.push({
7954
- value: currentBrand.id,
7955
- fullValue: currentBrand,
7956
- text: currentBrand.name
7957
- });
7952
+ if (userProfile.seasonDTOList) {
7953
+ for (const seasonDTO of userProfile.seasonDTOList) {
7954
+ const currentBrand = seasonDTO.institutionDTO.campusDTO.brandDTO;
7955
+ if (brandDTOOptionList.findIndex(
7956
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7957
+ ) === -1) {
7958
+ brandDTOOptionList.push({
7959
+ value: currentBrand.id,
7960
+ fullValue: currentBrand,
7961
+ text: currentBrand.name
7962
+ });
7963
+ }
7958
7964
  }
7959
7965
  }
7960
- for (const institutionDTO of userProfile.institutionDTOList) {
7961
- const currentBrand = institutionDTO.campusDTO.brandDTO;
7962
- if (brandDTOOptionList.findIndex(
7963
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7964
- ) === -1) {
7965
- brandDTOOptionList.push({
7966
- value: currentBrand.id,
7967
- fullValue: currentBrand,
7968
- text: currentBrand.name
7969
- });
7966
+ if (userProfile.institutionDTOList) {
7967
+ for (const institutionDTO of userProfile.institutionDTOList) {
7968
+ const currentBrand = institutionDTO.campusDTO.brandDTO;
7969
+ if (brandDTOOptionList.findIndex(
7970
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7971
+ ) === -1) {
7972
+ brandDTOOptionList.push({
7973
+ value: currentBrand.id,
7974
+ fullValue: currentBrand,
7975
+ text: currentBrand.name
7976
+ });
7977
+ }
7970
7978
  }
7971
7979
  }
7972
- for (const campusDTO of userProfile.campusDTOList) {
7973
- const currentBrand = campusDTO.brandDTO;
7974
- if (brandDTOOptionList.findIndex(
7975
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7976
- ) === -1) {
7977
- brandDTOOptionList.push({
7978
- value: currentBrand.id,
7979
- fullValue: currentBrand,
7980
- text: currentBrand.name
7981
- });
7980
+ if (userProfile.campusDTOList) {
7981
+ for (const campusDTO of userProfile.campusDTOList) {
7982
+ const currentBrand = campusDTO.brandDTO;
7983
+ if (brandDTOOptionList.findIndex(
7984
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7985
+ ) === -1) {
7986
+ brandDTOOptionList.push({
7987
+ value: currentBrand.id,
7988
+ fullValue: currentBrand,
7989
+ text: currentBrand.name
7990
+ });
7991
+ }
7982
7992
  }
7983
7993
  }
7984
- for (const brandDTO of userProfile.brandDTOList) {
7985
- const currentBrand = brandDTO;
7986
- if (brandDTOOptionList.findIndex(
7987
- (brandDTOOption) => brandDTOOption.value === currentBrand.id
7988
- ) === -1) {
7989
- brandDTOOptionList.push({
7990
- value: currentBrand.id,
7991
- fullValue: currentBrand,
7992
- text: currentBrand.name
7993
- });
7994
+ if (userProfile.brandDTOList) {
7995
+ for (const brandDTO of userProfile.brandDTOList) {
7996
+ const currentBrand = brandDTO;
7997
+ if (brandDTOOptionList.findIndex(
7998
+ (brandDTOOption) => brandDTOOption.value === currentBrand.id
7999
+ ) === -1) {
8000
+ brandDTOOptionList.push({
8001
+ value: currentBrand.id,
8002
+ fullValue: currentBrand,
8003
+ text: currentBrand.name
8004
+ });
8005
+ }
7994
8006
  }
7995
8007
  }
7996
8008
  }
@@ -8045,64 +8057,74 @@ var retrieveCampusDTOByUserProfileOptionList = (userProfile, selectedBrandId) =>
8045
8057
  const campusDTOOptionList = [];
8046
8058
  if (userProfile) {
8047
8059
  if (selectedBrandId) {
8048
- for (const branchDTO of userProfile.branchDTOList) {
8049
- const currentCampus = branchDTO.gradeDTO.seasonDTO.institutionDTO.campusDTO;
8050
- if (campusDTOOptionList.findIndex(
8051
- (campusDTOOption) => campusDTOOption.value === currentCampus.id
8052
- ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8053
- campusDTOOptionList.push({
8054
- value: currentCampus.id,
8055
- fullValue: currentCampus,
8056
- text: currentCampus.name
8057
- });
8060
+ if (userProfile.branchDTOList) {
8061
+ for (const branchDTO of userProfile.branchDTOList) {
8062
+ const currentCampus = branchDTO.gradeDTO.seasonDTO.institutionDTO.campusDTO;
8063
+ if (campusDTOOptionList.findIndex(
8064
+ (campusDTOOption) => campusDTOOption.value === currentCampus.id
8065
+ ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8066
+ campusDTOOptionList.push({
8067
+ value: currentCampus.id,
8068
+ fullValue: currentCampus,
8069
+ text: currentCampus.name
8070
+ });
8071
+ }
8058
8072
  }
8059
8073
  }
8060
- for (const gradeDTO of userProfile.gradeDTOList) {
8061
- const currentCampus = gradeDTO.seasonDTO.institutionDTO.campusDTO;
8062
- if (campusDTOOptionList.findIndex(
8063
- (campusDTOOption) => campusDTOOption.value === currentCampus.id
8064
- ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8065
- campusDTOOptionList.push({
8066
- value: currentCampus.id,
8067
- fullValue: currentCampus,
8068
- text: currentCampus.name
8069
- });
8074
+ if (userProfile.gradeDTOList) {
8075
+ for (const gradeDTO of userProfile.gradeDTOList) {
8076
+ const currentCampus = gradeDTO.seasonDTO.institutionDTO.campusDTO;
8077
+ if (campusDTOOptionList.findIndex(
8078
+ (campusDTOOption) => campusDTOOption.value === currentCampus.id
8079
+ ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8080
+ campusDTOOptionList.push({
8081
+ value: currentCampus.id,
8082
+ fullValue: currentCampus,
8083
+ text: currentCampus.name
8084
+ });
8085
+ }
8070
8086
  }
8071
8087
  }
8072
- for (const seasonDTO of userProfile.seasonDTOList) {
8073
- const currentCampus = seasonDTO.institutionDTO.campusDTO;
8074
- if (campusDTOOptionList.findIndex(
8075
- (campusDTOOption) => campusDTOOption.value === currentCampus.id
8076
- ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8077
- campusDTOOptionList.push({
8078
- value: currentCampus.id,
8079
- fullValue: currentCampus,
8080
- text: currentCampus.name
8081
- });
8088
+ if (userProfile.seasonDTOList) {
8089
+ for (const seasonDTO of userProfile.seasonDTOList) {
8090
+ const currentCampus = seasonDTO.institutionDTO.campusDTO;
8091
+ if (campusDTOOptionList.findIndex(
8092
+ (campusDTOOption) => campusDTOOption.value === currentCampus.id
8093
+ ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8094
+ campusDTOOptionList.push({
8095
+ value: currentCampus.id,
8096
+ fullValue: currentCampus,
8097
+ text: currentCampus.name
8098
+ });
8099
+ }
8082
8100
  }
8083
8101
  }
8084
- for (const institutionDTO of userProfile.institutionDTOList) {
8085
- const currentCampus = institutionDTO.campusDTO;
8086
- if (campusDTOOptionList.findIndex(
8087
- (campusDTOOption) => campusDTOOption.value === currentCampus.id
8088
- ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8089
- campusDTOOptionList.push({
8090
- value: currentCampus.id,
8091
- fullValue: currentCampus,
8092
- text: currentCampus.name
8093
- });
8102
+ if (userProfile.institutionDTOList) {
8103
+ for (const institutionDTO of userProfile.institutionDTOList) {
8104
+ const currentCampus = institutionDTO.campusDTO;
8105
+ if (campusDTOOptionList.findIndex(
8106
+ (campusDTOOption) => campusDTOOption.value === currentCampus.id
8107
+ ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8108
+ campusDTOOptionList.push({
8109
+ value: currentCampus.id,
8110
+ fullValue: currentCampus,
8111
+ text: currentCampus.name
8112
+ });
8113
+ }
8094
8114
  }
8095
8115
  }
8096
- for (const campusDTO of userProfile.campusDTOList) {
8097
- const currentCampus = campusDTO;
8098
- if (campusDTOOptionList.findIndex(
8099
- (campusDTOOption) => campusDTOOption.value === currentCampus.id
8100
- ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8101
- campusDTOOptionList.push({
8102
- value: currentCampus.id,
8103
- fullValue: currentCampus,
8104
- text: currentCampus.name
8105
- });
8116
+ if (userProfile.campusDTOList) {
8117
+ for (const campusDTO of userProfile.campusDTOList) {
8118
+ const currentCampus = campusDTO;
8119
+ if (campusDTOOptionList.findIndex(
8120
+ (campusDTOOption) => campusDTOOption.value === currentCampus.id
8121
+ ) === -1 && currentCampus.brandDTO.id === parseFloat(selectedBrandId)) {
8122
+ campusDTOOptionList.push({
8123
+ value: currentCampus.id,
8124
+ fullValue: currentCampus,
8125
+ text: currentCampus.name
8126
+ });
8127
+ }
8106
8128
  }
8107
8129
  }
8108
8130
  return campusDTOOptionList;
@@ -8114,52 +8136,60 @@ var retrieveInstitutionDTOByUserProfileOptionList = (userProfile, selectedBrandI
8114
8136
  const institutionDTOOptionList = [];
8115
8137
  if (userProfile) {
8116
8138
  if (selectedCampusId) {
8117
- for (const branchDTO of userProfile.branchDTOList) {
8118
- const currentInstitution = branchDTO.gradeDTO.seasonDTO.institutionDTO;
8119
- if (institutionDTOOptionList.findIndex(
8120
- (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8121
- ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8122
- institutionDTOOptionList.push({
8123
- value: currentInstitution.id,
8124
- fullValue: currentInstitution,
8125
- text: currentInstitution.name
8126
- });
8139
+ if (userProfile.branchDTOList) {
8140
+ for (const branchDTO of userProfile.branchDTOList) {
8141
+ const currentInstitution = branchDTO.gradeDTO.seasonDTO.institutionDTO;
8142
+ if (institutionDTOOptionList.findIndex(
8143
+ (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8144
+ ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8145
+ institutionDTOOptionList.push({
8146
+ value: currentInstitution.id,
8147
+ fullValue: currentInstitution,
8148
+ text: currentInstitution.name
8149
+ });
8150
+ }
8127
8151
  }
8128
8152
  }
8129
- for (const gradeDTO of userProfile.gradeDTOList) {
8130
- const currentInstitution = gradeDTO.seasonDTO.institutionDTO;
8131
- if (institutionDTOOptionList.findIndex(
8132
- (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8133
- ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8134
- institutionDTOOptionList.push({
8135
- value: currentInstitution.id,
8136
- fullValue: currentInstitution,
8137
- text: currentInstitution.name
8138
- });
8153
+ if (userProfile.gradeDTOList) {
8154
+ for (const gradeDTO of userProfile.gradeDTOList) {
8155
+ const currentInstitution = gradeDTO.seasonDTO.institutionDTO;
8156
+ if (institutionDTOOptionList.findIndex(
8157
+ (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8158
+ ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8159
+ institutionDTOOptionList.push({
8160
+ value: currentInstitution.id,
8161
+ fullValue: currentInstitution,
8162
+ text: currentInstitution.name
8163
+ });
8164
+ }
8139
8165
  }
8140
8166
  }
8141
- for (const seasonDTO of userProfile.seasonDTOList) {
8142
- const currentInstitution = seasonDTO.institutionDTO;
8143
- if (institutionDTOOptionList.findIndex(
8144
- (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8145
- ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8146
- institutionDTOOptionList.push({
8147
- value: currentInstitution.id,
8148
- fullValue: currentInstitution,
8149
- text: currentInstitution.name
8150
- });
8167
+ if (userProfile.seasonDTOList) {
8168
+ for (const seasonDTO of userProfile.seasonDTOList) {
8169
+ const currentInstitution = seasonDTO.institutionDTO;
8170
+ if (institutionDTOOptionList.findIndex(
8171
+ (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8172
+ ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8173
+ institutionDTOOptionList.push({
8174
+ value: currentInstitution.id,
8175
+ fullValue: currentInstitution,
8176
+ text: currentInstitution.name
8177
+ });
8178
+ }
8151
8179
  }
8152
8180
  }
8153
- for (const institutionDTO of userProfile.institutionDTOList) {
8154
- const currentInstitution = institutionDTO;
8155
- if (institutionDTOOptionList.findIndex(
8156
- (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8157
- ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8158
- institutionDTOOptionList.push({
8159
- value: currentInstitution.id,
8160
- fullValue: currentInstitution,
8161
- text: currentInstitution.name
8162
- });
8181
+ if (userProfile.institutionDTOList) {
8182
+ for (const institutionDTO of userProfile.institutionDTOList) {
8183
+ const currentInstitution = institutionDTO;
8184
+ if (institutionDTOOptionList.findIndex(
8185
+ (institutionDTOOption) => institutionDTOOption.value === currentInstitution.id
8186
+ ) === -1 && currentInstitution.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentInstitution.campusDTO.id === parseFloat(selectedCampusId)) {
8187
+ institutionDTOOptionList.push({
8188
+ value: currentInstitution.id,
8189
+ fullValue: currentInstitution,
8190
+ text: currentInstitution.name
8191
+ });
8192
+ }
8163
8193
  }
8164
8194
  }
8165
8195
  }
@@ -8170,40 +8200,46 @@ var retrieveSeasonDTOByUserProfileOptionList = (userProfile, selectedBrandId, se
8170
8200
  const seasonDTOOptionList = [];
8171
8201
  if (userProfile) {
8172
8202
  if (selectedInstitutionId) {
8173
- for (const branchDTO of userProfile.branchDTOList) {
8174
- const currentSeason = branchDTO.gradeDTO.seasonDTO;
8175
- if (seasonDTOOptionList.findIndex(
8176
- (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8177
- ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8178
- seasonDTOOptionList.push({
8179
- value: currentSeason.id,
8180
- fullValue: currentSeason,
8181
- text: currentSeason.name
8182
- });
8203
+ if (userProfile.branchDTOList) {
8204
+ for (const branchDTO of userProfile.branchDTOList) {
8205
+ const currentSeason = branchDTO.gradeDTO.seasonDTO;
8206
+ if (seasonDTOOptionList.findIndex(
8207
+ (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8208
+ ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8209
+ seasonDTOOptionList.push({
8210
+ value: currentSeason.id,
8211
+ fullValue: currentSeason,
8212
+ text: currentSeason.name
8213
+ });
8214
+ }
8183
8215
  }
8184
8216
  }
8185
- for (const gradeDTO of userProfile.gradeDTOList) {
8186
- const currentSeason = gradeDTO.seasonDTO;
8187
- if (seasonDTOOptionList.findIndex(
8188
- (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8189
- ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8190
- seasonDTOOptionList.push({
8191
- value: currentSeason.id,
8192
- fullValue: currentSeason,
8193
- text: currentSeason.name
8194
- });
8217
+ if (userProfile.gradeDTOList) {
8218
+ for (const gradeDTO of userProfile.gradeDTOList) {
8219
+ const currentSeason = gradeDTO.seasonDTO;
8220
+ if (seasonDTOOptionList.findIndex(
8221
+ (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8222
+ ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8223
+ seasonDTOOptionList.push({
8224
+ value: currentSeason.id,
8225
+ fullValue: currentSeason,
8226
+ text: currentSeason.name
8227
+ });
8228
+ }
8195
8229
  }
8196
8230
  }
8197
- for (const seasonDTO of userProfile.seasonDTOList) {
8198
- const currentSeason = seasonDTO;
8199
- if (seasonDTOOptionList.findIndex(
8200
- (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8201
- ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8202
- seasonDTOOptionList.push({
8203
- value: currentSeason.id,
8204
- fullValue: currentSeason,
8205
- text: currentSeason.name
8206
- });
8231
+ if (userProfile.seasonDTOList) {
8232
+ for (const seasonDTO of userProfile.seasonDTOList) {
8233
+ const currentSeason = seasonDTO;
8234
+ if (seasonDTOOptionList.findIndex(
8235
+ (seasonDTOOption) => seasonDTOOption.value === currentSeason.id
8236
+ ) === -1 && currentSeason.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentSeason.institutionDTO.id === parseFloat(selectedInstitutionId)) {
8237
+ seasonDTOOptionList.push({
8238
+ value: currentSeason.id,
8239
+ fullValue: currentSeason,
8240
+ text: currentSeason.name
8241
+ });
8242
+ }
8207
8243
  }
8208
8244
  }
8209
8245
  }
@@ -8214,28 +8250,32 @@ var retrieveGradeDTOByUserProfileOptionList = (userProfile, selectedBrandId, sel
8214
8250
  const gradeDTOOptionList = [];
8215
8251
  if (userProfile) {
8216
8252
  if (selectedSeasonId) {
8217
- for (const branchDTO of userProfile.branchDTOList) {
8218
- const currentGrade = branchDTO.gradeDTO;
8219
- if (gradeDTOOptionList.findIndex(
8220
- (gradeDTOOption) => gradeDTOOption.value === currentGrade.id
8221
- ) === -1 && currentGrade.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentGrade.seasonDTO.id === parseFloat(selectedSeasonId)) {
8222
- gradeDTOOptionList.push({
8223
- value: currentGrade.id,
8224
- fullValue: currentGrade,
8225
- text: currentGrade.name
8226
- });
8253
+ if (userProfile.branchDTOList) {
8254
+ for (const branchDTO of userProfile.branchDTOList) {
8255
+ const currentGrade = branchDTO.gradeDTO;
8256
+ if (gradeDTOOptionList.findIndex(
8257
+ (gradeDTOOption) => gradeDTOOption.value === currentGrade.id
8258
+ ) === -1 && currentGrade.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentGrade.seasonDTO.id === parseFloat(selectedSeasonId)) {
8259
+ gradeDTOOptionList.push({
8260
+ value: currentGrade.id,
8261
+ fullValue: currentGrade,
8262
+ text: currentGrade.name
8263
+ });
8264
+ }
8227
8265
  }
8228
8266
  }
8229
- for (const gradeDTO of userProfile.gradeDTOList) {
8230
- const currentGrade = gradeDTO;
8231
- if (gradeDTOOptionList.findIndex(
8232
- (gradeDTOOption) => gradeDTOOption.value === currentGrade.id
8233
- ) === -1 && currentGrade.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentGrade.seasonDTO.id === parseFloat(selectedSeasonId)) {
8234
- gradeDTOOptionList.push({
8235
- value: currentGrade.id,
8236
- fullValue: currentGrade,
8237
- text: currentGrade.name
8238
- });
8267
+ if (userProfile.gradeDTOList) {
8268
+ for (const gradeDTO of userProfile.gradeDTOList) {
8269
+ const currentGrade = gradeDTO;
8270
+ if (gradeDTOOptionList.findIndex(
8271
+ (gradeDTOOption) => gradeDTOOption.value === currentGrade.id
8272
+ ) === -1 && currentGrade.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentGrade.seasonDTO.id === parseFloat(selectedSeasonId)) {
8273
+ gradeDTOOptionList.push({
8274
+ value: currentGrade.id,
8275
+ fullValue: currentGrade,
8276
+ text: currentGrade.name
8277
+ });
8278
+ }
8239
8279
  }
8240
8280
  }
8241
8281
  }
@@ -8246,16 +8286,18 @@ var retrieveBranchDTOByUserProfileOptionList = (userProfile, selectedBrandId, se
8246
8286
  const branchDTOOptionList = [];
8247
8287
  if (userProfile) {
8248
8288
  if (selectedGradeId) {
8249
- for (const branchDTO of userProfile.branchDTOList) {
8250
- const currentBranch = branchDTO;
8251
- if (branchDTOOptionList.findIndex(
8252
- (branchDTOOption) => branchDTOOption.value === currentBranch.id
8253
- ) === -1 && currentBranch.gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentBranch.gradeDTO.id === parseFloat(selectedGradeId)) {
8254
- branchDTOOptionList.push({
8255
- value: currentBranch.id,
8256
- fullValue: currentBranch,
8257
- text: currentBranch.name
8258
- });
8289
+ if (userProfile.branchDTOList) {
8290
+ for (const branchDTO of userProfile.branchDTOList) {
8291
+ const currentBranch = branchDTO;
8292
+ if (branchDTOOptionList.findIndex(
8293
+ (branchDTOOption) => branchDTOOption.value === currentBranch.id
8294
+ ) === -1 && currentBranch.gradeDTO.seasonDTO.institutionDTO.campusDTO.brandDTO.id === parseFloat(selectedBrandId) && currentBranch.gradeDTO.id === parseFloat(selectedGradeId)) {
8295
+ branchDTOOptionList.push({
8296
+ value: currentBranch.id,
8297
+ fullValue: currentBranch,
8298
+ text: currentBranch.name
8299
+ });
8300
+ }
8259
8301
  }
8260
8302
  }
8261
8303
  }