placementt-core 1.400.970 → 1.400.971

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.
@@ -938,9 +938,12 @@ export type InstituteData = {
938
938
  /** Only meaningful when skillsFramework is "custom": the selected skillsLabels ids
939
939
  * (generic public labels and/or the school's own custom labels). */
940
940
  skills: string[];
941
- /** Staff-defined rules serving specific skills to specific students based on their
942
- * detail fields (studentsFields). Evaluated at assessment view time. */
941
+ /** Staff-defined student groups serving specific skills to specific students based
942
+ * on their detail fields (studentsFields). Evaluated at assessment view time. */
943
943
  skillsMappings?: SkillsMapping[];
944
+ /** Annual survey schedule for the default "All students" group. Auto-provisioned
945
+ * into each academic year by the daily cron. */
946
+ skillsSurveys?: SkillsSurveySlot[];
944
947
  scheduledSkillsAssessments?: {
945
948
  [key in "yearStart" | "yearEnd" | "eachTerm" | "preWorkExperience" | "postWorkExperience" | "employerInteraction"]?: {
946
949
  students?: boolean;
@@ -2876,13 +2879,25 @@ export type SkillLabel = {
2876
2879
  * Absent for platform-wide labels. */
2877
2880
  oId?: string;
2878
2881
  };
2882
+ /** One scheduled skills survey in a group's annual programme. `sendMMDD` is "MM-DD".
2883
+ * Auto-provisioned into each new academic year by the daily cron (mirrors the
2884
+ * aspirations AspirationSurveySlot model). */
2885
+ export type SkillsSurveySlot = {
2886
+ sendMMDD: string;
2887
+ label?: string;
2888
+ students?: boolean;
2889
+ parents?: boolean;
2890
+ };
2879
2891
  /**
2880
- * A staff-defined rule mapping students to the skills they are served on assessments.
2881
- * `filters` keys are student detail field names (from InstituteData.studentsFields);
2882
- * values are the accepted values for that field. A student matches a rule when EVERY
2883
- * filtered field's value is one of the accepted values (values within a field are OR,
2884
- * fields are AND). A student matching multiple rules is served the UNION of their
2885
- * skills. A student matching no rule falls back to the institute's full base set.
2892
+ * A staff-defined student group mapping students to the skills they are served on
2893
+ * assessments. `filters` keys are student detail field names (from
2894
+ * InstituteData.studentsFields); values are the accepted values for that field. A
2895
+ * student matches a group when EVERY filtered field's value is one of the accepted
2896
+ * values (values within a field are OR, fields are AND). A student matching multiple
2897
+ * groups is served the UNION of their skills. A student matching no group falls back
2898
+ * to the institute's "All students" base set (skillsFramework/skills).
2899
+ * Each group carries its own annual survey schedule; the "All students" default
2900
+ * group's schedule lives on InstituteData.skillsSurveys.
2886
2901
  */
2887
2902
  export type SkillsMapping = {
2888
2903
  id: string;
@@ -2891,6 +2906,7 @@ export type SkillsMapping = {
2891
2906
  [field: string]: string[];
2892
2907
  };
2893
2908
  skills: string[];
2909
+ surveys?: SkillsSurveySlot[];
2894
2910
  };
2895
2911
  /** Rater types for skills assessments (mirrors SkillAssessment.userType). */
2896
2912
  export type SkillRater = "students" | "parents" | "employers";
@@ -2982,6 +2998,8 @@ export type SkillAssessmentRequest = {
2982
2998
  oId: string;
2983
2999
  academicYear?: string;
2984
3000
  yearGroup?: number;
3001
+ groupId?: string;
3002
+ preResolved?: boolean;
2985
3003
  sendTime?: string;
2986
3004
  students: string;
2987
3005
  requestParents?: boolean;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "private": false,
3
3
  "name": "placementt-core",
4
4
  "author": "Placementt",
5
- "version": "1.400.970",
5
+ "version": "1.400.971",
6
6
  "main": "lib/index.js",
7
7
  "types": "lib/index.d.ts",
8
8
  "scripts": {
@@ -947,9 +947,12 @@ export type InstituteData = {
947
947
  /** Only meaningful when skillsFramework is "custom": the selected skillsLabels ids
948
948
  * (generic public labels and/or the school's own custom labels). */
949
949
  skills: string[]
950
- /** Staff-defined rules serving specific skills to specific students based on their
951
- * detail fields (studentsFields). Evaluated at assessment view time. */
950
+ /** Staff-defined student groups serving specific skills to specific students based
951
+ * on their detail fields (studentsFields). Evaluated at assessment view time. */
952
952
  skillsMappings?: SkillsMapping[],
953
+ /** Annual survey schedule for the default "All students" group. Auto-provisioned
954
+ * into each academic year by the daily cron. */
955
+ skillsSurveys?: SkillsSurveySlot[],
953
956
  scheduledSkillsAssessments?: {
954
957
  [key in "yearStart" | "yearEnd" | "eachTerm" | "preWorkExperience" | "postWorkExperience" | "employerInteraction"]?: {
955
958
  students?: boolean,
@@ -2797,19 +2800,33 @@ export type SkillLabel = {
2797
2800
  oId?: string,
2798
2801
  }
2799
2802
 
2803
+ /** One scheduled skills survey in a group's annual programme. `sendMMDD` is "MM-DD".
2804
+ * Auto-provisioned into each new academic year by the daily cron (mirrors the
2805
+ * aspirations AspirationSurveySlot model). */
2806
+ export type SkillsSurveySlot = {
2807
+ sendMMDD: string,
2808
+ label?: string,
2809
+ students?: boolean,
2810
+ parents?: boolean,
2811
+ }
2812
+
2800
2813
  /**
2801
- * A staff-defined rule mapping students to the skills they are served on assessments.
2802
- * `filters` keys are student detail field names (from InstituteData.studentsFields);
2803
- * values are the accepted values for that field. A student matches a rule when EVERY
2804
- * filtered field's value is one of the accepted values (values within a field are OR,
2805
- * fields are AND). A student matching multiple rules is served the UNION of their
2806
- * skills. A student matching no rule falls back to the institute's full base set.
2814
+ * A staff-defined student group mapping students to the skills they are served on
2815
+ * assessments. `filters` keys are student detail field names (from
2816
+ * InstituteData.studentsFields); values are the accepted values for that field. A
2817
+ * student matches a group when EVERY filtered field's value is one of the accepted
2818
+ * values (values within a field are OR, fields are AND). A student matching multiple
2819
+ * groups is served the UNION of their skills. A student matching no group falls back
2820
+ * to the institute's "All students" base set (skillsFramework/skills).
2821
+ * Each group carries its own annual survey schedule; the "All students" default
2822
+ * group's schedule lives on InstituteData.skillsSurveys.
2807
2823
  */
2808
2824
  export type SkillsMapping = {
2809
2825
  id: string,
2810
2826
  name?: string,
2811
2827
  filters: {[field: string]: string[]},
2812
2828
  skills: string[],
2829
+ surveys?: SkillsSurveySlot[],
2813
2830
  }
2814
2831
 
2815
2832
  /** Rater types for skills assessments (mirrors SkillAssessment.userType). */
@@ -2903,6 +2920,9 @@ export type SkillAssessmentRequest = {
2903
2920
  // documents stay valid — legacy requests without them surface as "Ungrouped".
2904
2921
  academicYear?: string, // e.g. "2024-25", derived from sendTime/creation
2905
2922
  yearGroup?: number, // the single year group this request targets
2923
+ // ── Auto-provisioned group surveys (set by the daily cron) ──
2924
+ groupId?: string, // SkillsMapping.id, or "all" for the All students group
2925
+ preResolved?: boolean, // per-student assessments created by the cron — onRequestCreated skips fan-out
2906
2926
  sendTime?: string,
2907
2927
  students: string // JSON stringify
2908
2928
  // {