@vocollege/app 0.0.113 → 0.0.115

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.
@@ -320,7 +320,8 @@
320
320
  "noGroup": "Ingen grupp är vald",
321
321
  "startPage": "Startsida",
322
322
  "vopagesStatus": "Aktivera VoSida för denna grupp",
323
- "vopage": "VoSida"
323
+ "vopage": "VoSida",
324
+ "educator": "Utbildare"
324
325
  },
325
326
  "errors": {
326
327
  "invalidGroupName": "Ogiltigt gruppnamn. Det måste starta med minst 1 bokstav följd av en eller flera siffror och/eller bokstäver, utan mellanslag, specialtecken eller stora bokstäver. Understreck/bindestreck är tillåtet. Ex: 'nationellt', 'kronoberg', 'projekt2020', 'orebro-lan"
@@ -1092,7 +1093,13 @@
1092
1093
  "numberEducatorVuxVO": "Antal vuxenutbildare, vård och omsorg",
1093
1094
  "numberEducatorVuxBF": "Antal vuxenutbildare, barn och fritid",
1094
1095
  "numberEducatorFolkhogskolor": "Antal folkhögskolor",
1095
- "numberEducatorYrkeshogskolor": "Antal yrkeshögskolor"
1096
+ "numberEducatorYrkeshogskolor": "Antal yrkeshögskolor",
1097
+ "numberOfEducators": "Antal utbildare",
1098
+ "educatorPerType": "Utbildare per typ"
1099
+ },
1100
+ "messages": {
1101
+ "educatorCanAppearMultipleTimes": "Notera att en och samma utbildare kan förekomma flera gånger, under olika rubriker. T ex kan en utbildare vara både 'Kommunal Gymnasium' och 'Kommunal vuxenutbildning'.",
1102
+ "sumOfEducationsCanBeDifferentFromNumberOfEducators": "Notera att summan av utbildningar kan bli annorlunda från 'Antal utbildare', eftersom vissa utbildare kan sakna certfierade utbildningar under vald period och/eller en och samma utbildare kan ha flera utbildningar."
1096
1103
  }
1097
1104
  },
1098
1105
  "voadmin": {
@@ -116,11 +116,16 @@ var GraphClient = /** @class */ (function () {
116
116
  cache: new client_1.InMemoryCache({
117
117
  typePolicies: {
118
118
  Education: {
119
- keyFields: [
120
- "id",
121
- "pivot",
122
- ["education_usage_id", "education_usage_type", "field"],
123
- ],
119
+ keyFields: function (object, context) {
120
+ if (!object.hasOwnProperty("pivot")) {
121
+ return ["id"];
122
+ }
123
+ return [
124
+ "id",
125
+ "pivot",
126
+ ["education_usage_id", "education_usage_type", "field"],
127
+ ];
128
+ },
124
129
  },
125
130
  // PivotEducation: {
126
131
  // // keyFields: ["education_usage_id"],
@@ -6,7 +6,7 @@ var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cook
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
7
  exports.GET_CERTIFICATIONS_STATISTICS = exports.GET_GENERAL_STATISTICS = exports.GET_GROUP_FIELDS = void 0;
8
8
  var client_1 = require("@apollo/client");
9
- exports.GET_GROUP_FIELDS = (0, client_1.gql)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n fragment GroupFields on Group {\n id\n name\n title\n category\n certified\n created_at\n }\n"], ["\n fragment GroupFields on Group {\n id\n name\n title\n category\n certified\n created_at\n }\n"])));
10
- exports.GET_GENERAL_STATISTICS = (0, client_1.gql)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n query GeneralStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n regions {\n ...GroupFields\n }\n localColleges {\n ...GroupFields\n }\n employers {\n ...GroupFields\n }\n educatorsGymVO {\n ...GroupFields\n }\n educatorsGymBF {\n ...GroupFields\n }\n educatorsVuxVO {\n ...GroupFields\n }\n educatorsVuxBF {\n ...GroupFields\n }\n educatorsFolkhogskolor {\n ...GroupFields\n }\n educatorsYrkeshogskolor {\n ...GroupFields\n }\n }\n }\n ", "\n"], ["\n query GeneralStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n regions {\n ...GroupFields\n }\n localColleges {\n ...GroupFields\n }\n employers {\n ...GroupFields\n }\n educatorsGymVO {\n ...GroupFields\n }\n educatorsGymBF {\n ...GroupFields\n }\n educatorsVuxVO {\n ...GroupFields\n }\n educatorsVuxBF {\n ...GroupFields\n }\n educatorsFolkhogskolor {\n ...GroupFields\n }\n educatorsYrkeshogskolor {\n ...GroupFields\n }\n }\n }\n ", "\n"])), exports.GET_GROUP_FIELDS);
9
+ exports.GET_GROUP_FIELDS = (0, client_1.gql)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n fragment GroupFields on Group {\n id\n name\n title\n category\n educator_type\n certified\n created_at\n }\n"], ["\n fragment GroupFields on Group {\n id\n name\n title\n category\n educator_type\n certified\n created_at\n }\n"])));
10
+ exports.GET_GENERAL_STATISTICS = (0, client_1.gql)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n query GeneralStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n regions {\n ...GroupFields\n }\n localColleges {\n ...GroupFields\n }\n employers {\n ...GroupFields\n }\n educators {\n ...GroupFields\n }\n educations {\n id\n title\n total_usages\n # groups {\n # id\n # title\n # educator_type\n # educations {\n # id\n # title\n # pivot {\n # education_id\n # education_usage_id\n # education_usage_type\n # field\n # certified\n # }\n # }\n # }\n }\n # educatorsGymVO {\n # ...GroupFields\n # }\n # educatorsGymBF {\n # ...GroupFields\n # }\n # educatorsVuxVO {\n # ...GroupFields\n # }\n # educatorsVuxBF {\n # ...GroupFields\n # }\n # educatorsFolkhogskolor {\n # ...GroupFields\n # }\n # educatorsYrkeshogskolor {\n # ...GroupFields\n # }\n }\n }\n ", "\n"], ["\n query GeneralStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n regions {\n ...GroupFields\n }\n localColleges {\n ...GroupFields\n }\n employers {\n ...GroupFields\n }\n educators {\n ...GroupFields\n }\n educations {\n id\n title\n total_usages\n # groups {\n # id\n # title\n # educator_type\n # educations {\n # id\n # title\n # pivot {\n # education_id\n # education_usage_id\n # education_usage_type\n # field\n # certified\n # }\n # }\n # }\n }\n # educatorsGymVO {\n # ...GroupFields\n # }\n # educatorsGymBF {\n # ...GroupFields\n # }\n # educatorsVuxVO {\n # ...GroupFields\n # }\n # educatorsVuxBF {\n # ...GroupFields\n # }\n # educatorsFolkhogskolor {\n # ...GroupFields\n # }\n # educatorsYrkeshogskolor {\n # ...GroupFields\n # }\n }\n }\n ", "\n"])), exports.GET_GROUP_FIELDS);
11
11
  exports.GET_CERTIFICATIONS_STATISTICS = (0, client_1.gql)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n query CertificationsStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n certifiedRegions {\n id\n name\n title\n certified\n created_at\n }\n }\n }\n"], ["\n query CertificationsStatistics($filters: StatisticsFilters) {\n statistics(filters: $filters) {\n certifiedRegions {\n id\n name\n title\n certified\n created_at\n }\n }\n }\n"])));
12
12
  var templateObject_1, templateObject_2, templateObject_3;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vocollege/app",
3
- "version": "0.0.113",
3
+ "version": "0.0.115",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -320,7 +320,8 @@
320
320
  "noGroup": "Ingen grupp är vald",
321
321
  "startPage": "Startsida",
322
322
  "vopagesStatus": "Aktivera VoSida för denna grupp",
323
- "vopage": "VoSida"
323
+ "vopage": "VoSida",
324
+ "educator": "Utbildare"
324
325
  },
325
326
  "errors": {
326
327
  "invalidGroupName": "Ogiltigt gruppnamn. Det måste starta med minst 1 bokstav följd av en eller flera siffror och/eller bokstäver, utan mellanslag, specialtecken eller stora bokstäver. Understreck/bindestreck är tillåtet. Ex: 'nationellt', 'kronoberg', 'projekt2020', 'orebro-lan"
@@ -1092,7 +1093,13 @@
1092
1093
  "numberEducatorVuxVO": "Antal vuxenutbildare, vård och omsorg",
1093
1094
  "numberEducatorVuxBF": "Antal vuxenutbildare, barn och fritid",
1094
1095
  "numberEducatorFolkhogskolor": "Antal folkhögskolor",
1095
- "numberEducatorYrkeshogskolor": "Antal yrkeshögskolor"
1096
+ "numberEducatorYrkeshogskolor": "Antal yrkeshögskolor",
1097
+ "numberOfEducators": "Antal utbildare",
1098
+ "educatorPerType": "Utbildare per typ"
1099
+ },
1100
+ "messages": {
1101
+ "educatorCanAppearMultipleTimes": "Notera att en och samma utbildare kan förekomma flera gånger, under olika rubriker. T ex kan en utbildare vara både 'Kommunal Gymnasium' och 'Kommunal vuxenutbildning'.",
1102
+ "sumOfEducationsCanBeDifferentFromNumberOfEducators": "Notera att summan av utbildningar kan bli annorlunda från 'Antal utbildare', eftersom vissa utbildare kan sakna certfierade utbildningar under vald period och/eller en och samma utbildare kan ha flera utbildningar."
1096
1103
  }
1097
1104
  },
1098
1105
  "voadmin": {
@@ -70,11 +70,16 @@ class GraphClient {
70
70
  cache: new InMemoryCache({
71
71
  typePolicies: {
72
72
  Education: {
73
- keyFields: [
74
- "id",
75
- "pivot",
76
- ["education_usage_id", "education_usage_type", "field"],
77
- ],
73
+ keyFields: (object, context) => {
74
+ if (!object.hasOwnProperty("pivot")) {
75
+ return ["id"];
76
+ }
77
+ return [
78
+ "id",
79
+ "pivot",
80
+ ["education_usage_id", "education_usage_type", "field"],
81
+ ];
82
+ },
78
83
  },
79
84
  // PivotEducation: {
80
85
  // // keyFields: ["education_usage_id"],
@@ -6,6 +6,7 @@ export const GET_GROUP_FIELDS = gql`
6
6
  name
7
7
  title
8
8
  category
9
+ educator_type
9
10
  certified
10
11
  created_at
11
12
  }
@@ -23,24 +24,48 @@ export const GET_GENERAL_STATISTICS = gql`
23
24
  employers {
24
25
  ...GroupFields
25
26
  }
26
- educatorsGymVO {
27
+ educators {
27
28
  ...GroupFields
28
29
  }
29
- educatorsGymBF {
30
- ...GroupFields
31
- }
32
- educatorsVuxVO {
33
- ...GroupFields
34
- }
35
- educatorsVuxBF {
36
- ...GroupFields
37
- }
38
- educatorsFolkhogskolor {
39
- ...GroupFields
40
- }
41
- educatorsYrkeshogskolor {
42
- ...GroupFields
30
+ educations {
31
+ id
32
+ title
33
+ total_usages
34
+ # groups {
35
+ # id
36
+ # title
37
+ # educator_type
38
+ # educations {
39
+ # id
40
+ # title
41
+ # pivot {
42
+ # education_id
43
+ # education_usage_id
44
+ # education_usage_type
45
+ # field
46
+ # certified
47
+ # }
48
+ # }
49
+ # }
43
50
  }
51
+ # educatorsGymVO {
52
+ # ...GroupFields
53
+ # }
54
+ # educatorsGymBF {
55
+ # ...GroupFields
56
+ # }
57
+ # educatorsVuxVO {
58
+ # ...GroupFields
59
+ # }
60
+ # educatorsVuxBF {
61
+ # ...GroupFields
62
+ # }
63
+ # educatorsFolkhogskolor {
64
+ # ...GroupFields
65
+ # }
66
+ # educatorsYrkeshogskolor {
67
+ # ...GroupFields
68
+ # }
44
69
  }
45
70
  }
46
71
  ${GET_GROUP_FIELDS}