phx-react 1.3.1630 → 1.3.1631

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,5 +1,5 @@
1
1
  import { IQueryBuilderProps } from '../type/target';
2
- export declare const GET_SELECT_QUERY = "\n query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {\n educational_level(\n order_by: {id: asc}\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n code\n }\n grade(\n order_by: {id: asc}\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n code\n educational_level_id\n }\n classroom(\n order_by: {id: asc}\n where: {\n deleted_at: {_is_null: true}\n school_id: {_eq: $schoolId}\n school_year_id: {_eq: $schoolYearId}\n }\n ) {\n id\n name\n code\n grade {\n id\n educational_level_id\n }\n }\n\n department(\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n }\n }\n";
2
+ export declare const GET_SELECT_QUERY = "\n query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {\n educational_level(order_by: { id: asc }, where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {\n id\n name\n code\n }\n grade(\n order_by: { id: asc }\n where: {\n deleted_at: { _is_null: true }\n school_id: { _eq: $schoolId }\n educational_level: { deleted_at: { _is_null: true } }\n }\n ) {\n id\n name\n code\n educational_level_id\n }\n classroom(\n order_by: { id: asc }\n where: {\n deleted_at: { _is_null: true }\n school_id: { _eq: $schoolId }\n grade: { educational_level: { deleted_at: { _is_null: true } } }\n school_year_id: { _eq: $schoolYearId }\n }\n ) {\n id\n name\n code\n grade {\n id\n educational_level_id\n }\n }\n\n department(where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {\n id\n name\n }\n }\n";
3
3
  export declare const queryListUserBuilder: ({ schoolId, schoolYearId, target }: IQueryBuilderProps) => string;
4
4
  export declare const getTargetByIdQuery = "\n query getTargetByIdQuery($id: uuid!) {\n target_inform_target_by_pk(id: $id) {\n target_by_roles(where: {deleted_at: {_is_null: true}}) {\n role_code\n target_educational_levels {\n educational_level {\n id\n name\n code\n }\n }\n target_grades {\n grade {\n id\n name\n code\n }\n }\n target_classrooms {\n classroom {\n id\n name\n code\n }\n }\n target_users {\n user {\n id\n name: full_name\n phone: phone_number\n email\n profile_teacher {\n user_code\n } \n profile_staff {\n user_code\n }\n }\n }\n }\n }\n }\n";
5
5
  export declare const GET_TARGET_BY_ROLE_QUERY = "\n query getTargetByRoleQuery($id: uuid!) {\n user_segment_target_by_pk(id: $id) {\n school_year_id\n target_by_roles(where: {deleted_at: {_is_null: true}}) {\n role {\n role_code\n }\n is_all\n notify_with\n target_educational_levels {\n educational_level {\n id\n name\n code\n }\n }\n target_grades {\n grade {\n id\n name\n code\n }\n }\n target_classrooms {\n classroom {\n id\n name\n code\n }\n }\n target_departments {\n department {\n id\n name\n }\n }\n target_users {\n user {\n id\n name: full_name\n phone: phone_number\n email\n profile_student {\n user_code\n grade {\n id\n name\n }\n program_map_educational_level {\n educational_level {\n code\n name\n id\n }\n }\n }\n\n profile_teacher {\n user_code\n }\n profile_staff {\n user_code\n }\n relationshipUsersByStudentId(\n order_by: {created_at: desc}\n where: {\n deleted_at: {_is_null: true}\n user: {deleted_at: {_is_null: true}}\n userByStudentId: {deleted_at: {_is_null: true}}\n }\n ) {\n parent_id\n relationship_code\n user {\n gender\n full_name\n phone_number\n }\n }\n }\n }\n }\n }\n }\n";
@@ -5,17 +5,18 @@ const constant_1 = require("../constant");
5
5
  const target_1 = require("../type/target");
6
6
  exports.GET_SELECT_QUERY = `
7
7
  query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {
8
- educational_level(
9
- order_by: {id: asc}
10
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
11
- ) {
8
+ educational_level(order_by: { id: asc }, where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {
12
9
  id
13
10
  name
14
11
  code
15
12
  }
16
13
  grade(
17
- order_by: {id: asc}
18
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
14
+ order_by: { id: asc }
15
+ where: {
16
+ deleted_at: { _is_null: true }
17
+ school_id: { _eq: $schoolId }
18
+ educational_level: { deleted_at: { _is_null: true } }
19
+ }
19
20
  ) {
20
21
  id
21
22
  name
@@ -23,11 +24,12 @@ exports.GET_SELECT_QUERY = `
23
24
  educational_level_id
24
25
  }
25
26
  classroom(
26
- order_by: {id: asc}
27
+ order_by: { id: asc }
27
28
  where: {
28
- deleted_at: {_is_null: true}
29
- school_id: {_eq: $schoolId}
30
- school_year_id: {_eq: $schoolYearId}
29
+ deleted_at: { _is_null: true }
30
+ school_id: { _eq: $schoolId }
31
+ grade: { educational_level: { deleted_at: { _is_null: true } } }
32
+ school_year_id: { _eq: $schoolYearId }
31
33
  }
32
34
  ) {
33
35
  id
@@ -39,9 +41,7 @@ exports.GET_SELECT_QUERY = `
39
41
  }
40
42
  }
41
43
 
42
- department(
43
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
44
- ) {
44
+ department(where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {
45
45
  id
46
46
  name
47
47
  }
@@ -1,5 +1,5 @@
1
1
  import { IQueryBuilderProps } from '../type/target';
2
- export declare const GET_SELECT_QUERY = "\n query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {\n educational_level(\n order_by: {id: asc}\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n code\n }\n grade(\n order_by: {id: asc}\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n code\n educational_level_id\n }\n classroom(\n order_by: {id: asc}\n where: {\n deleted_at: {_is_null: true}\n school_id: {_eq: $schoolId}\n school_year_id: {_eq: $schoolYearId}\n }\n ) {\n id\n name\n code\n grade {\n id\n educational_level_id\n }\n }\n\n department(\n where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}\n ) {\n id\n name\n }\n }\n";
2
+ export declare const GET_SELECT_QUERY = "\n query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {\n educational_level(order_by: { id: asc }, where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {\n id\n name\n code\n }\n grade(\n order_by: { id: asc }\n where: {\n deleted_at: { _is_null: true }\n school_id: { _eq: $schoolId }\n educational_level: { deleted_at: { _is_null: true } }\n }\n ) {\n id\n name\n code\n educational_level_id\n }\n classroom(\n order_by: { id: asc }\n where: {\n deleted_at: { _is_null: true }\n school_id: { _eq: $schoolId }\n grade: { educational_level: { deleted_at: { _is_null: true } } }\n school_year_id: { _eq: $schoolYearId }\n }\n ) {\n id\n name\n code\n grade {\n id\n educational_level_id\n }\n }\n\n department(where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {\n id\n name\n }\n }\n";
3
3
  export declare const queryListUserBuilder: ({ schoolId, schoolYearId, target }: IQueryBuilderProps) => string;
4
4
  export declare const getTargetByIdQuery = "\n query getTargetByIdQuery($id: uuid!) {\n target_inform_target_by_pk(id: $id) {\n target_by_roles(where: {deleted_at: {_is_null: true}}) {\n role_code\n target_educational_levels {\n educational_level {\n id\n name\n code\n }\n }\n target_grades {\n grade {\n id\n name\n code\n }\n }\n target_classrooms {\n classroom {\n id\n name\n code\n }\n }\n target_users {\n user {\n id\n name: full_name\n phone: phone_number\n email\n profile_teacher {\n user_code\n } \n profile_staff {\n user_code\n }\n }\n }\n }\n }\n }\n";
5
5
  export declare const GET_TARGET_BY_ROLE_QUERY = "\n query getTargetByRoleQuery($id: uuid!) {\n user_segment_target_by_pk(id: $id) {\n school_year_id\n target_by_roles(where: {deleted_at: {_is_null: true}}) {\n role {\n role_code\n }\n is_all\n notify_with\n target_educational_levels {\n educational_level {\n id\n name\n code\n }\n }\n target_grades {\n grade {\n id\n name\n code\n }\n }\n target_classrooms {\n classroom {\n id\n name\n code\n }\n }\n target_departments {\n department {\n id\n name\n }\n }\n target_users {\n user {\n id\n name: full_name\n phone: phone_number\n email\n profile_student {\n user_code\n grade {\n id\n name\n }\n program_map_educational_level {\n educational_level {\n code\n name\n id\n }\n }\n }\n\n profile_teacher {\n user_code\n }\n profile_staff {\n user_code\n }\n relationshipUsersByStudentId(\n order_by: {created_at: desc}\n where: {\n deleted_at: {_is_null: true}\n user: {deleted_at: {_is_null: true}}\n userByStudentId: {deleted_at: {_is_null: true}}\n }\n ) {\n parent_id\n relationship_code\n user {\n gender\n full_name\n phone_number\n }\n }\n }\n }\n }\n }\n }\n";
@@ -2,17 +2,18 @@ import { ERoleCode } from '../constant';
2
2
  import { EStudentStatus } from '../type/target';
3
3
  export const GET_SELECT_QUERY = `
4
4
  query getSelectQuery($schoolId: Int!, $schoolYearId: Int!) {
5
- educational_level(
6
- order_by: {id: asc}
7
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
8
- ) {
5
+ educational_level(order_by: { id: asc }, where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {
9
6
  id
10
7
  name
11
8
  code
12
9
  }
13
10
  grade(
14
- order_by: {id: asc}
15
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
11
+ order_by: { id: asc }
12
+ where: {
13
+ deleted_at: { _is_null: true }
14
+ school_id: { _eq: $schoolId }
15
+ educational_level: { deleted_at: { _is_null: true } }
16
+ }
16
17
  ) {
17
18
  id
18
19
  name
@@ -20,11 +21,12 @@ export const GET_SELECT_QUERY = `
20
21
  educational_level_id
21
22
  }
22
23
  classroom(
23
- order_by: {id: asc}
24
+ order_by: { id: asc }
24
25
  where: {
25
- deleted_at: {_is_null: true}
26
- school_id: {_eq: $schoolId}
27
- school_year_id: {_eq: $schoolYearId}
26
+ deleted_at: { _is_null: true }
27
+ school_id: { _eq: $schoolId }
28
+ grade: { educational_level: { deleted_at: { _is_null: true } } }
29
+ school_year_id: { _eq: $schoolYearId }
28
30
  }
29
31
  ) {
30
32
  id
@@ -36,9 +38,7 @@ export const GET_SELECT_QUERY = `
36
38
  }
37
39
  }
38
40
 
39
- department(
40
- where: {deleted_at: {_is_null: true}, school_id: {_eq: $schoolId}}
41
- ) {
41
+ department(where: { deleted_at: { _is_null: true }, school_id: { _eq: $schoolId } }) {
42
42
  id
43
43
  name
44
44
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "phx-react",
3
- "version": "1.3.1630",
3
+ "version": "1.3.1631",
4
4
  "description": "PHX REACT",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",