@royalschedule/maps 4.0.21 → 4.0.24

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.
@@ -1,4 +1,5 @@
1
1
  import { CoreMap } from "../../core/index.js";
2
+ import { COLLECTION_ID } from "./input/util/util.js";
2
3
  import { parseInput } from "./input/input.js";
3
4
  import { makeConnected } from "../make-connected.js";
4
5
  import { initialConfiguration } from "./initial-configuration.js";
@@ -6,6 +7,15 @@ import { structure } from "../types/to.js";
6
7
  import { pick } from "lodash-es";
7
8
 
8
9
  //#region src/RS/to/schedules.ts
10
+ function transformId(id) {
11
+ const indexOfDot = id.indexOf(".");
12
+ if (indexOfDot == -1) return COLLECTION_ID.events + "." + id;
13
+ const prefix = id.substring(0, indexOfDot).toLowerCase();
14
+ const suffix = id.substring(indexOfDot + 1);
15
+ if (prefix == COLLECTION_ID.lockedTimes.toLowerCase()) return COLLECTION_ID.lockedTimes + "." + suffix;
16
+ if (prefix == COLLECTION_ID.events.toLowerCase()) return COLLECTION_ID.events + "." + suffix;
17
+ throw new Error(`(RS::To::transformId) Unknown id prefix "${prefix}" in id "${id}"`);
18
+ }
9
19
  function schedules(data, _options = {}) {
10
20
  const options = (() => {
11
21
  const x = _options.partialScheduleOptions;
@@ -19,10 +29,7 @@ function schedules(data, _options = {}) {
19
29
  partialScheduleOptions
20
30
  };
21
31
  })();
22
- if (options.partialScheduleOptions?.includedEvents?.size) options.partialScheduleOptions.includedEvents = new Set([...options.partialScheduleOptions.includedEvents].map((x) => {
23
- if (x.startsWith("events.") || x.startsWith("lockedTimes.")) return x;
24
- return `events.${x}`;
25
- }));
32
+ if (options.partialScheduleOptions?.includedEvents?.size) options.partialScheduleOptions.includedEvents = new Set([...options.partialScheduleOptions.includedEvents].map((x) => transformId(x)));
26
33
  const connectedData = makeConnected(data);
27
34
  return {
28
35
  meta: {
@@ -1 +1 @@
1
- {"version":3,"file":"schedules.js","names":["partialScheduleOptions: Types.parsedToOptions['partialScheduleOptions']"],"sources":["../../../src/RS/to/schedules.ts"],"sourcesContent":["import { pick } from 'lodash-es';\nimport { parseInput } from './input/input';\nimport { makeConnected } from '../make-connected';\nimport { initialConfiguration } from './initial-configuration';\nimport type { Types } from '../types';\nimport { CoreMap } from '../../core';\nimport { structure } from '../types/to';\n\nexport function schedules (\n data: Types.toInput,\n _options: Types.toOptions = {}\n): Types.toOutput {\n ////\n //// parse the options\n ////\n const options = ((): Types.parsedToOptions => {\n const x = _options.partialScheduleOptions;\n const partialScheduleOptions: Types.parsedToOptions['partialScheduleOptions'] = x\n ? {\n includedEvents: x.includedEvents ? new Set(x.includedEvents) : undefined,\n includedLocations: x.includedLocations ? new Set(x.includedLocations) : undefined,\n omittedEventsHandling: x.omittedEventsHandling\n }\n : undefined;\n\n return { ..._options, partialScheduleOptions };\n })();\n\n ////\n //// for backward compatibility: add default collection to included events set\n ////\n if (options.partialScheduleOptions?.includedEvents?.size) {\n options.partialScheduleOptions.includedEvents = new Set(\n [...options.partialScheduleOptions.includedEvents]\n .map(x => {\n // should start with 'events.' or 'lockedTimes.' prefix\n if (x.startsWith('events.') || x.startsWith('lockedTimes.')) return x;\n return `events.${x}`;\n })\n );\n }\n\n\n // we will work only with connected schedule data\n const connectedData = makeConnected(data);\n\n return {\n meta: {\n structure: structure,\n division: pick(connectedData.division, 'displayName', 'start', 'end'),\n },\n algorithmParameters: {\n weights: options.algorithmWeightParameters,\n computeTimeMultiplier: options.computeTimeMultiplier\n },\n input: parseInput(connectedData, options),\n ...options.appendCoreData && { coreData: CoreMap.to.schedules(data) },\n ...options.appendOutput && { output: initialConfiguration(connectedData.events, connectedData.lockedTimes, options) },\n };\n};"],"mappings":";;;;;;;;AAQA,SAAgB,UACd,MACA,WAA4B,EAAE,EACd;CAIhB,MAAM,iBAAwC;EAC5C,MAAM,IAAI,SAAS;EACnB,MAAMA,yBAA0E,IAC5E;GACA,gBAAuB,EAAE,iBAAoB,IAAI,IAAI,EAAE,eAAe,GAAM;GAC5E,mBAAuB,EAAE,oBAAoB,IAAI,IAAI,EAAE,kBAAkB,GAAG;GAC5E,uBAAuB,EAAE;GAC1B,GACC;AAEJ,SAAO;GAAE,GAAG;GAAU;GAAwB;KAC5C;AAKJ,KAAI,QAAQ,wBAAwB,gBAAgB,KAClD,SAAQ,uBAAuB,iBAAiB,IAAI,IAClD,CAAC,GAAG,QAAQ,uBAAuB,eAAe,CAC/C,KAAI,MAAK;AAER,MAAI,EAAE,WAAW,UAAU,IAAI,EAAE,WAAW,eAAe,CAAE,QAAO;AACpE,SAAO,UAAU;GACjB,CACL;CAKH,MAAM,gBAAgB,cAAc,KAAK;AAEzC,QAAO;EACL,MAAM;GACO;GACX,UAAW,KAAK,cAAc,UAAU,eAAe,SAAS,MAAM;GACvE;EACD,qBAAqB;GACnB,SAAuB,QAAQ;GAC/B,uBAAuB,QAAQ;GAChC;EACD,OAAO,WAAW,eAAe,QAAQ;EACzC,GAAG,QAAQ,kBAAkB,EAAE,UAAU,QAAQ,GAAG,UAAU,KAAK,EAAE;EACrE,GAAG,QAAQ,gBAAkB,EAAE,QAAQ,qBAAqB,cAAc,QAAQ,cAAc,aAAa,QAAQ,EAAE;EACxH"}
1
+ {"version":3,"file":"schedules.js","names":["partialScheduleOptions: Types.parsedToOptions['partialScheduleOptions']"],"sources":["../../../src/RS/to/schedules.ts"],"sourcesContent":["import { pick } from 'lodash-es';\nimport { parseInput } from './input/input';\nimport { makeConnected } from '../make-connected';\nimport { initialConfiguration } from './initial-configuration';\nimport type { Types } from '../types';\nimport { CoreMap } from '../../core';\nimport { structure } from '../types/to';\nimport { COLLECTION_ID } from './input/util/util';\n\nfunction transformId (id: string): string {\n // should be interpreted as event id\n const indexOfDot = id.indexOf('.');\n if (indexOfDot == -1) return COLLECTION_ID.events + '.' + id;\n\n // split on first dot only\n const prefix = id.substring(0, indexOfDot).toLowerCase();\n const suffix = id.substring(indexOfDot + 1);\n\n if (prefix == COLLECTION_ID.lockedTimes.toLowerCase()) return COLLECTION_ID.lockedTimes + '.' + suffix;\n if (prefix == COLLECTION_ID.events .toLowerCase()) return COLLECTION_ID.events + '.' + suffix;\n\n throw new Error(`(RS::To::transformId) Unknown id prefix \"${prefix}\" in id \"${id}\"`);\n}\n\nexport function schedules (\n data: Types.toInput,\n _options: Types.toOptions = {}\n): Types.toOutput {\n ////\n //// parse the options\n ////\n const options = ((): Types.parsedToOptions => {\n const x = _options.partialScheduleOptions;\n const partialScheduleOptions: Types.parsedToOptions['partialScheduleOptions'] = x\n ? {\n includedEvents: x.includedEvents ? new Set(x.includedEvents) : undefined,\n includedLocations: x.includedLocations ? new Set(x.includedLocations) : undefined,\n omittedEventsHandling: x.omittedEventsHandling\n }\n : undefined;\n\n return { ..._options, partialScheduleOptions };\n })();\n\n ////\n //// for backward compatibility: add default collection to included events set\n ////\n if (options.partialScheduleOptions?.includedEvents?.size) {\n options.partialScheduleOptions.includedEvents = new Set(\n [...options.partialScheduleOptions.includedEvents].map(x => transformId(x))\n );\n }\n\n\n // we will work only with connected schedule data\n const connectedData = makeConnected(data);\n\n return {\n meta: {\n structure: structure,\n division: pick(connectedData.division, 'displayName', 'start', 'end'),\n },\n algorithmParameters: {\n weights: options.algorithmWeightParameters,\n computeTimeMultiplier: options.computeTimeMultiplier\n },\n input: parseInput(connectedData, options),\n ...options.appendCoreData && { coreData: CoreMap.to.schedules(data) },\n ...options.appendOutput && { output: initialConfiguration(connectedData.events, connectedData.lockedTimes, options) },\n };\n};"],"mappings":";;;;;;;;;AASA,SAAS,YAAa,IAAoB;CAExC,MAAM,aAAa,GAAG,QAAQ,IAAI;AAClC,KAAI,cAAc,GAAI,QAAO,cAAc,SAAS,MAAM;CAG1D,MAAM,SAAS,GAAG,UAAU,GAAG,WAAW,CAAC,aAAa;CACxD,MAAM,SAAS,GAAG,UAAU,aAAa,EAAE;AAE3C,KAAI,UAAU,cAAc,YAAY,aAAa,CAAE,QAAO,cAAc,cAAc,MAAM;AAChG,KAAI,UAAU,cAAc,OAAY,aAAa,CAAE,QAAO,cAAc,SAAc,MAAM;AAEhG,OAAM,IAAI,MAAM,4CAA4C,OAAO,WAAW,GAAG,GAAG;;AAGtF,SAAgB,UACd,MACA,WAA4B,EAAE,EACd;CAIhB,MAAM,iBAAwC;EAC5C,MAAM,IAAI,SAAS;EACnB,MAAMA,yBAA0E,IAC5E;GACA,gBAAuB,EAAE,iBAAoB,IAAI,IAAI,EAAE,eAAe,GAAM;GAC5E,mBAAuB,EAAE,oBAAoB,IAAI,IAAI,EAAE,kBAAkB,GAAG;GAC5E,uBAAuB,EAAE;GAC1B,GACC;AAEJ,SAAO;GAAE,GAAG;GAAU;GAAwB;KAC5C;AAKJ,KAAI,QAAQ,wBAAwB,gBAAgB,KAClD,SAAQ,uBAAuB,iBAAiB,IAAI,IAClD,CAAC,GAAG,QAAQ,uBAAuB,eAAe,CAAC,KAAI,MAAK,YAAY,EAAE,CAAC,CAC5E;CAKH,MAAM,gBAAgB,cAAc,KAAK;AAEzC,QAAO;EACL,MAAM;GACO;GACX,UAAW,KAAK,cAAc,UAAU,eAAe,SAAS,MAAM;GACvE;EACD,qBAAqB;GACnB,SAAuB,QAAQ;GAC/B,uBAAuB,QAAQ;GAChC;EACD,OAAO,WAAW,eAAe,QAAQ;EACzC,GAAG,QAAQ,kBAAkB,EAAE,UAAU,QAAQ,GAAG,UAAU,KAAK,EAAE;EACrE,GAAG,QAAQ,gBAAkB,EAAE,QAAQ,qBAAqB,cAAc,QAAQ,cAAc,aAAa,QAAQ,EAAE;EACxH"}
@@ -12,8 +12,10 @@ var groups_default = (groups, belongsTo, expand) => {
12
12
  if (!groups.every((group) => isString(group) || isString(get(group, "id")))) throw new Error("(SS12000::To::Groups) Some groups are missing \"id\" values", { cause: "invalid_input" });
13
13
  if (!belongsTo && !groups.every((group) => isString(group) && belongsTo || has(group, "belongsTo"))) throw new Error("(SS12000::To::Groups) Some top layer groups are missing \"belongsTo\" values", { cause: "invalid_input" });
14
14
  return groups.map((group) => {
15
- if (!isString(group) && group.members?.some((member) => isString(member))) throw new Error("(SS12000::To::Groups) Some group members are missing \"id\" values", { cause: "invalid_input" });
16
- const members = !isString(group) && group.members?.length && !isString(group.members[0]) ? group.members : [];
15
+ const members = !isString(group) && Array.isArray(group.members) ? group.members.map((member) => {
16
+ if (isString(member)) return { id: member };
17
+ return member;
18
+ }) : [];
17
19
  const division = belongsTo ?? (!isString(group) ? group.belongsTo : void 0);
18
20
  if (!division || isString(division) || !("id" in division && division.id)) throw new Error("(SS12000::To::Groups) Some group members are missing \"belongsTo\" values", { cause: "invalid_input" });
19
21
  if (!("start" in division && division.start) || !("end" in division && division.end)) throw new Error("(SS12000::To::Groups) Some group members are missing \"belongsTo\" start or end values", { cause: "invalid_input" });
@@ -1 +1 @@
1
- {"version":3,"file":"groups.js","names":["toPerson"],"sources":["../../../src/SS12000/to/groups.ts"],"sourcesContent":["import { isString, has, get, omitBy, isNil } from 'lodash-es';\nimport moment from 'moment';\nimport type { CoreTypes } from '../../core';\nimport type { Group } from '../types/groups';\nimport { getDivisionId, toReference } from './common';\nimport toPerson from './persons';\n\ntype Expand = ('referenceNames' | 'persons')[];\n\n/**\n * @deprecated This is only used for SCS. can be removed when scs use v2\n */\nexport default (\n groups: Exclude<Extract<CoreTypes.Mixed.Group, { id: string }>, { members: string[] }>[],\n belongsTo?: Extract<CoreTypes.Deep.Division, { id: string }>,\n expand?: Expand\n): Group[] => {\n if (!Array.isArray(groups))\n throw new Error('(SS12000::To::Groups) Group input is not of array type', { cause: 'invalid_input' });\n\n if (!groups.every((group) => isString(group) || isString(get(group, 'id'))))\n throw new Error('(SS12000::To::Groups) Some groups are missing \"id\" values', { cause: 'invalid_input' });\n\n if (!belongsTo && !groups.every((group) => (isString(group) && belongsTo) || has(group, 'belongsTo')))\n throw new Error('(SS12000::To::Groups) Some top layer groups are missing \"belongsTo\" values', { cause: 'invalid_input' });\n\n return groups.map((group) => {\n if (! isString(group) && group.members?.some((member) => isString(member))) {\n throw new Error('(SS12000::To::Groups) Some group members are missing \"id\" values', { cause: 'invalid_input' });\n }\n const members = !isString(group) && group.members?.length && !isString(group.members[0])\n ? group.members as Extract<CoreTypes.Mixed.Person, { id: string }>[]\n : [];\n\n const division = belongsTo ?? (!isString(group) ? group.belongsTo : undefined);\n if (!division || isString(division) || !('id' in division && division.id))\n throw new Error('(SS12000::To::Groups) Some group members are missing \"belongsTo\" values', { cause: 'invalid_input' });\n if (!('start' in division && division.start) || !('end' in division && division.end))\n throw new Error('(SS12000::To::Groups) Some group members are missing \"belongsTo\" start or end values', { cause: 'invalid_input' });\n\n return {\n id: `${ getDivisionId(group, belongsTo) }.${ isString(group) ? group : group.id }`,\n groupType: group.species === 'class' ? 'Klass' : 'Undervisning',\n startDate: moment(division.start).toISOString(),\n endDate: moment(division.end).toISOString(),\n ...!isString(group) && {\n meta: {\n created: moment(group.createdAt).toISOString(),\n modified: moment(group.updatedAt).toISOString()\n },\n /*\n Optionally add the following properties\n */\n ...omitBy({\n foreignId: group.ids,\n displayName: group.displayName,\n }, isNil),\n ...group.members && {\n // @ts-ignore\n groupMemberships: toReference(members, division).map(person => ({\n startDate: moment(division.start).toISOString(),\n endDate: moment(division.end).toISOString(),\n person: person\n }))\n },\n ...expand?.some(x => ['persons'].includes(x)) && {\n _embedded: {\n ...expand.includes('persons') && {\n groups: toPerson(members, division as Extract<CoreTypes.Deep.Division, { id: string }>)\n }\n }\n }\n }\n };\n });\n};"],"mappings":";;;;;;;;;AAYA,sBACE,QACA,WACA,WACY;AACZ,KAAI,CAAC,MAAM,QAAQ,OAAO,CACxB,OAAM,IAAI,MAAM,0DAA0D,EAAE,OAAO,iBAAiB,CAAC;AAEvG,KAAI,CAAC,OAAO,OAAO,UAAU,SAAS,MAAM,IAAI,SAAS,IAAI,OAAO,KAAK,CAAC,CAAC,CACzE,OAAM,IAAI,MAAM,+DAA6D,EAAE,OAAO,iBAAiB,CAAC;AAE1G,KAAI,CAAC,aAAa,CAAC,OAAO,OAAO,UAAW,SAAS,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aAAa;KAC/C,SAAW,OAAO,SAAS,IAAI,CAAC,aAAa;KAClC;KACZ,EAAE,EACJ;IACD,GAAG,QAAQ,MAAK,MAAK,CAAC,UAAU,CAAC,SAAS,EAAE,CAAC,IAAI,EAC/C,WAAW,EACT,GAAG,OAAO,SAAS,UAAU,IAAI,EAC/B,QAAQA,gBAAS,SAAS,SAA6D,EACxF,EACF,EACF;IACF;GACF;GACD"}
1
+ {"version":3,"file":"groups.js","names":["toPerson"],"sources":["../../../src/SS12000/to/groups.ts"],"sourcesContent":["import { isString, has, get, omitBy, isNil } from 'lodash-es';\nimport moment from 'moment';\nimport type { CoreTypes } from '../../core';\nimport type { Group } from '../types/groups';\nimport { getDivisionId, toReference } from './common';\nimport toPerson from './persons';\n\ntype Expand = ('referenceNames' | 'persons')[];\n\n/**\n * @deprecated This is only used for SCS. can be removed when scs use v2\n */\nexport default (\n groups: Extract<CoreTypes.Mixed.Group, { id: string }>[],\n belongsTo?: Extract<CoreTypes.Deep.Division, { id: string }>,\n expand?: Expand\n): Group[] => {\n if (!Array.isArray(groups))\n throw new Error('(SS12000::To::Groups) Group input is not of array type', { cause: 'invalid_input' });\n\n if (!groups.every((group) => isString(group) || isString(get(group, 'id'))))\n throw new Error('(SS12000::To::Groups) Some groups are missing \"id\" values', { cause: 'invalid_input' });\n\n if (!belongsTo && !groups.every((group) => (isString(group) && belongsTo) || has(group, 'belongsTo')))\n throw new Error('(SS12000::To::Groups) Some top layer groups are missing \"belongsTo\" values', { cause: 'invalid_input' });\n\n return groups.map((group) => {\n const members = !isString(group) && Array.isArray(group.members)\n ? (group.members).map((member) => {\n if (isString(member)) return { id: member } as Extract<CoreTypes.Mixed.Person, { id: string }>;\n return member as Extract<CoreTypes.Mixed.Person, { id: string }>;\n })\n : [];\n\n const division = belongsTo ?? (!isString(group) ? group.belongsTo : undefined);\n if (!division || isString(division) || !('id' in division && division.id))\n throw new Error('(SS12000::To::Groups) Some group members are missing \"belongsTo\" values', { cause: 'invalid_input' });\n if (!('start' in division && division.start) || !('end' in division && division.end))\n throw new Error('(SS12000::To::Groups) Some group members are missing \"belongsTo\" start or end values', { cause: 'invalid_input' });\n\n return {\n id: `${ getDivisionId(group, belongsTo) }.${ isString(group) ? group : group.id }`,\n groupType: group.species === 'class' ? 'Klass' : 'Undervisning',\n startDate: moment(division.start).toISOString(),\n endDate: moment(division.end).toISOString(),\n ...!isString(group) && {\n meta: {\n created: moment(group.createdAt).toISOString(),\n modified: moment(group.updatedAt).toISOString()\n },\n /*\n Optionally add the following properties\n */\n ...omitBy({\n foreignId: group.ids,\n displayName: group.displayName,\n }, isNil),\n ...group.members && {\n // @ts-ignore\n groupMemberships: toReference(members, division).map(person => ({\n startDate: moment(division.start).toISOString(),\n endDate: moment(division.end).toISOString(),\n person: person\n }))\n },\n ...expand?.some(x => ['persons'].includes(x)) && {\n _embedded: {\n ...expand.includes('persons') && {\n groups: toPerson(members, division as Extract<CoreTypes.Deep.Division, { id: string }>)\n }\n }\n }\n }\n };\n });\n};"],"mappings":";;;;;;;;;AAYA,sBACE,QACA,WACA,WACY;AACZ,KAAI,CAAC,MAAM,QAAQ,OAAO,CACxB,OAAM,IAAI,MAAM,0DAA0D,EAAE,OAAO,iBAAiB,CAAC;AAEvG,KAAI,CAAC,OAAO,OAAO,UAAU,SAAS,MAAM,IAAI,SAAS,IAAI,OAAO,KAAK,CAAC,CAAC,CACzE,OAAM,IAAI,MAAM,+DAA6D,EAAE,OAAO,iBAAiB,CAAC;AAE1G,KAAI,CAAC,aAAa,CAAC,OAAO,OAAO,UAAW,SAAS,MAAM,IAAI,aAAc,IAAI,OAAO,YAAY,CAAC,CACnG,OAAM,IAAI,MAAM,gFAA8E,EAAE,OAAO,iBAAiB,CAAC;AAE3H,QAAO,OAAO,KAAK,UAAU;EAC3B,MAAM,UAAU,CAAC,SAAS,MAAM,IAAI,MAAM,QAAQ,MAAM,QAAQ,GAC3D,MAAM,QAAS,KAAK,WAAW;AAChC,OAAI,SAAS,OAAO,CA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29
29
  id: string;
30
30
  }>, expand?: ("person" | "referenceNames")[]) => Duty[];
31
- static groups: (groups: Exclude<Extract<Types.Mixed.Group, {
31
+ static groups: (groups: Extract<Types.Mixed.Group, {
32
32
  id: string;
33
- }>, {
34
- members: string[];
35
33
  }>[], belongsTo?: Extract<Types.Deep.Division, {
36
34
  id: string;
37
35
  }>, expand?: ("persons" | "referenceNames")[]) => Group[];
@@ -6,7 +6,7 @@ import { Deep } from "../vertices/index.js";
6
6
 
7
7
  //#region src/core/interfaces/other/policies.d.ts
8
8
  interface Action {
9
- targetResourceModel: string;
9
+ targetResourceModel?: string;
10
10
  operation: (Access['CREATE'] | Access['READ'] | Access['UPDATE'] | Access['DELETE'])[];
11
11
  }
12
12
  interface Statement {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@royalschedule/maps",
3
3
  "description": "",
4
- "version": "4.0.21",
4
+ "version": "4.0.24",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",