@7365admin1/core 3.50.2-staging.224 → 3.51.1-staging.225

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.
@@ -0,0 +1,10 @@
1
+ ---
2
+ "@7365admin1/core": patch
3
+ ---
4
+
5
+ Visitor list: decide the Guests tab by "every requested status is pre-arrival"
6
+ instead of matching one specific status set, so the tab keeps filtering on the
7
+ expected arrival date for both the approved+pending request sent by
8
+ layer-common `main` and the approved+pending+rejected request sent by
9
+ layer-common `staging` (DV-0080). Extracted as `isPreCheckInStatusOnly` with
10
+ tests pinning each case.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @iservice365/core
2
2
 
3
+ ## 3.51.0
4
+
5
+ ### Minor Changes
6
+
7
+ - d8480d6: Resident Invite contractor and guest list modification endpoints
8
+
3
9
  ## 3.50.1
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -19944,6 +19944,17 @@ async function sendEmail({ to, subject, text: text2, html }) {
19944
19944
  }
19945
19945
  }
19946
19946
 
19947
+ // src/utils/visitor-status.util.ts
19948
+ var PRE_CHECK_IN_STATUSES = [
19949
+ "approved" /* APPROVED */,
19950
+ "pending" /* PENDING */,
19951
+ "rejected" /* REJECTED */
19952
+ ];
19953
+ function isPreCheckInStatusOnly(status) {
19954
+ const requested = Array.isArray(status) ? status : status ? [status] : [];
19955
+ return requested.length > 0 && requested.every((s) => PRE_CHECK_IN_STATUSES.includes(s));
19956
+ }
19957
+
19947
19958
  // src/repositories/visitor-transaction.repo.ts
19948
19959
  var visitors_namespace_collection = "visitor.transactions";
19949
19960
  function useVisitorTransactionRepo() {
@@ -20018,7 +20029,7 @@ function useVisitorTransactionRepo() {
20018
20029
  }) {
20019
20030
  page = page > 0 ? page - 1 : 0;
20020
20031
  const skip = page * limit;
20021
- const isGuest = Array.isArray(status) && status.includes("approved") && status.includes("pending") && status.includes("rejected");
20032
+ const isGuest = isPreCheckInStatusOnly(status);
20022
20033
  const checkInFilter = {};
20023
20034
  const expectedCheckInFilter = {};
20024
20035
  if (!isGuest) {