Compare commits

...

295 Commits

Author SHA1 Message Date
Lorenz Hilpert
d9e9e39998 feat: remove uncompleted tasks dialog and replace with confirmation dialog
- Deleted uncompleted tasks dialog component files (HTML, SCSS, TS).
- Updated UncompletedTasksGuard to use new ConfirmationDialogComponent.
- Added ConfirmationDialogComponent for user confirmation with customizable messages.
- Updated dialog component templates to include data attributes for easier testing.
- Removed obsolete unit tests for ReturnReviewComponent and ReturnTaskListComponent.
- Updated unit tests for ReturnSummaryComponent to reflect changes in return process handling.
2025-05-21 20:58:03 +02:00
Lorenz Hilpert
896478b2fb Merge branch 'develop' into feature/5047-5053-Design-und-Funktionsweise-Drucker-Dialog 2025-05-21 14:39:05 +02:00
Lorenz Hilpert
d84bc276d5 chore: update dependencies and add new path mappings
- Updated @nx/js from 20.4.6 to 20.8.1
- Updated angular-eslint from 19.1.0 to 19.2.0
- Added path mapping for @isa/common/print in tsconfig.base.json
- Added path mapping for @isa/ui/dialog in tsconfig.base.json
- Added path mapping for @isa/ui/list in tsconfig.base.json
2025-05-21 14:38:24 +02:00
Nino
ca3433a4e1 feat(oms-return-unit-tests): update return process questions with German labels
This commit makes several important changes to the return process functionality:

- Updates ItemConditionAnswer values from English codes to German user-facing text
  (e.g., 'ovp' → 'Originalverpackt', 'damaged' → 'Geöffnet/Defekt')
- Updates ReturnReasonAnswer values to use German labels
  (e.g., 'dislike' → 'Gefällt nicht/Widerruf', 'wrong_item' → 'Fehllieferung')
- Updates YesNoAnswer values to use German text ('yes'/'no' → 'Ja'/'Nein')
- Updates PackageIncompleteAnswer values to use descriptive German text
- Corrects an expected depth value in unit test to match the current behavior
- Adds comments in test files that need to be re-enabled after the printReceiptsService
  is updated to not use the old ISA app through the legacy ModalService

These changes improve readability and make the return processing system
more consistent with the German UI labels.

Ref: #4944
2025-05-21 11:46:13 +02:00
Nino
d2b3d1bf18 feat(oms-data-access, oms-return-summary): implement returnDetails as object with type safety
This commit improves the handling of return details by:
- Changing returnDetails from string to a typed record object for better type safety
- Adding support for checklist question types in getReturnInfo
- Adding explicit mapping function (returnDetailsMapping) to format details for API
- Updating the return summary component to properly display structured return details
- Making internalActiveReturnProcessQuestions public to support nested questions
- Ensuring eligibility check functions receive proper question objects for validation
- Improving returnProcessQuestionKey naming to use more descriptive German names

Ref: #4944
2025-05-20 17:13:47 +02:00
Nino
08f8686791 Config Feature Url Anpassungen 2025-05-19 13:56:42 +02:00
Nino
4131255a1b feat(oms-return-details): add quantity change support for return items
This update introduces quantity selection and change handling for return items in the return details feature. The following enhancements were made:

- Added a quantity dropdown to each return item, allowing users to select the quantity to return (when more than one is available).
- Implemented the `changeQuantity` output in `ReturnDetailsOrderGroup
2025-05-16 17:27:01 +02:00
Nino
874453f74f feat(oms-data-access, oms-return-details, oms-return-process): improve canReturn logic and UX for return eligibility
- Refactored `ReturnCanReturnService` to use a type guard for input discrimination and improved error handling, removing logger side effects for stricter error propagation.
- Updated `ReturnDetailsService` to delegate canReturn checks to `ReturnCanReturnService` for category-based eligibility, ensuring type safety and code reuse.
- Enhanced `ReturnDetailsOrderGroupItemComponent`:
  - Added spinner feedback when canReturn is loading.
  - Used endpoint result for eligibility and message display, falling back to item actions if necessary.
  - Improved state management for dropdowns and selection, with robust error logging.
- Updated `ReturnDetailsOrderGroupComponent` to only allow selection of items with known categories and eligible for return.
- Improved `ReturnProcessItemComponent`:
  - Added loading spinner for canReturn backend checks.
  - Used endpoint result for eligibility and messaging.
  - Added robust error logging and effect-based async state management.
- Updated `ReturnProcessComponent` to check canReturn for all processes asynchronously, with error handling and correct signal updates.
- Improved templates to show loading indicators and correct eligibility messages based on backend and frontend checks.

Ref: #5088
2025-05-16 15:18:45 +02:00
Nino
8077fe949f Config Feature Print Update 2025-05-16 11:39:48 +02:00
Nino
39bdcd4da6 feat(oms-data-access, oms-return-process): extract canReturn logic to dedicated service and unify question helpers
- Move canReturn logic from ReturnProcessService and ReturnProcessItemComponent into a new ReturnCanReturnService for improved separation of concerns and testability.
- Add getReturnProcessQuestions and returnReceiptValuesMapping helpers to centralize question and payload mapping logic.
- Refactor ReturnProcessService to use new helpers and remove obsolete methods.
- Update ReturnProcessItemComponent and ReturnProcessComponent to use ReturnCanReturnService for backend eligibility checks.
- Ensure summary navigation is only enabled when all items are eligible for return both frontend and backend.
- Update public API exports for new helpers and service.

Ref: #5089, #5088
2025-05-15 17:49:42 +02:00
Nino
55b95e571c Fix Unit Test Error - Uncommented Unit Tests in Details because of multiple errors 2025-05-14 17:07:00 +02:00
Nino
4adf947b90 feat(oms-return-details, oms-return-process, oms-data-access): implement product category management
Add dropdown component for selecting product categories in the return details UI.
Move product category selection from return process to return details screen,
allowing users to set categories before starting the return process.

This change:
- Moves availableCategories method from ReturnProcessService to ReturnDetailsService
- Adds new updateProductCategoryForItem method to ReturnDetailsStore
- Updates the OrderGroupItem component with dropdown for category selection
- Removes the category dropdown from ReturnProcessQuestions component

Ref: #5089
2025-05-14 16:52:24 +02:00
Lorenz Hilpert
efdfa126e7 fix(config): update configMap mountPath for consistency across environments 2025-05-13 18:51:31 +02:00
Nino
efd28bcc06 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-05-13 16:45:30 +02:00
Nino
05986ab9f4 feat(oms-return-process, oms-return-details, oms-data-access): implement return process workflow
Add new components and services to support the end-to-end return process
workflow. This includes return creation, validation, item selection, and
submission features across the specified modules.

Ref: #4978
2025-05-13 16:44:53 +02:00
Lorenz Hilpert
6fc65c4158 fix(config): update configMap mountPath for consistency 2025-05-13 12:13:12 +02:00
Lorenz Hilpert
e3395c8772 ci: update artifact path for ISAClientConfigs 2025-05-13 11:51:35 +02:00
Lorenz Hilpert
ec67724b66 ci: update artifact path for ISAClientConfigs 2025-05-13 11:48:23 +02:00
Lorenz Hilpert
911187bc08 update(config): update url path for APIs Checkout, Crm, Oms 2025-05-13 10:53:55 +02:00
Lorenz Hilpert
9a55cd8642 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-05-12 16:29:33 +02:00
Lorenz Hilpert
4815963565 fix(checkbox): ensure checkbox input dimensions are consistently applied
Ref: #5077
2025-05-12 16:28:56 +02:00
Nino
0d4e5c6bf9 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-05-12 16:13:11 +02:00
Nino
e60f4db18a fix(oms-data-access): move category to top level in return receipt payload
Update ReturnReceiptValuesSchema to accept category as a direct property
instead of nested in receiptItem.data.features. Simplifies the schema by
removing the unnecessary ReceiptItemDataSchema and modifying how the
category is accessed in completeReturnProcess.

Ref: #5083
2025-05-12 16:11:20 +02:00
Lorenz Hilpert
b0de88301f Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-05-12 16:05:39 +02:00
Lorenz Hilpert
6868c6df75 refactor(return-details): reorganize button placement for better layout 2025-05-12 16:05:08 +02:00
Nino
f2ca829b36 OMS Api Update 2025-05-12 16:01:39 +02:00
Nino
190d0786e0 fix(oms-data-access): unify electronic and nonbook item condition labels
Harmonize electronic device and nonbook item condition labels to consistently
use "Geöffnet/Defekt" instead of "Geöffnet/Beschädigt" or "Beschädigt/Fehldruck".
Also remove redundant defect verification question for electronic devices since
the condition label already indicates this state.

Additionally, add product features to receipt item data in return receipts to
ensure proper product information is available for returns processing.

Ref: #5083
2025-05-12 15:10:47 +02:00
Nino
0ec1457ffc fix(oms-data-access): simplify return receipt values schema
Replace separate type extension with direct schema definition by adding
otherProduct field to the ReturnReceiptValuesSchema. This eliminates
redundant type definition and improves type safety by ensuring all
fields are properly validated through the Zod schema.

Ref: #5082
2025-05-12 14:32:59 +02:00
Nino
a978f94519 feat(oms-task-list): simplify filter logic
Simplify the task list filter logic by using a cleaner object literal approach
instead of nested properties. This improves readability and maintainability of
the filtering conditions.

Ref: #5072
2025-05-12 14:03:46 +02:00
Nino
71ee7ea842 fix(oms-data-access), fix(return-process), fix(return-summary): filter out ineligible items from return process submission
This commit makes several important changes to ensure only eligible items
are processed during return submission:

1. ReturnProcessService now filters out ineligible items before submission
2. Fixed canContinueToSummary logic to check if ANY item is eligible (not ALL)
3. Added conditional rendering to return-summary-item to display error state
   for ineligible items

These changes prevent system errors when attempting to process returns
that don't meet eligibility criteria while still allowing partial returns
when at least one item is eligible.

Ref: #5084
2025-05-12 13:43:49 +02:00
Nino
a8c5e8feb5 feat(oms-return-process): improve product search error handling and feedback
Enhance the ReturnProcessProductQuestion component with better error handling:
- Add proper display of "no product found" message when search returns no results
- Add validation feedback for invalid EAN inputs
- Refactor status handling from a simple boolean to a more descriptive object
- Remove unnecessary complete handler in favor of explicit state management

Ref: #4979
2025-05-09 17:25:37 +02:00
Nino
1b9e70141b feat(oms-data-access): implement return eligibility for electronic devices
Add new helper function isElektronischeGeraeteEligibleForReturn to determine
if electronic devices are eligible for returns based on item condition and
receipt date. Update ReturnProcessService to use this helper for electronic
device category.

This implementation checks if devices in original packaging with receipts
older than 100 days are not eligible for return.

Ref: #4978
2025-05-09 15:22:37 +02:00
Nino
bdc711926c feat(oms-return-details): improve boolean coercion for return eligibility check
Replace direct Boolean() casting with Angular's coerceBooleanProperty to ensure consistent
boolean type coercion when determining if items can be returned. This improves type safety
and provides more predictable behavior for string-based boolean values in item actions.

Ref: #5067
2025-05-09 14:28:51 +02:00
Nino
74531a7ddc Small Fix ElibigleItems 2025-05-09 14:12:25 +02:00
Nino
202ceb0b22 Unit Test Quick Fix 2025-05-08 18:38:44 +02:00
Nino
693d1af51b feat(oms-data-access, oms-task-list): implement query token filtering for task lists
Add support for filter parameters when querying receipt item tasks, allowing
for more refined control over which tasks are displayed. Update the service,
store, and component to use this filtering capability.

- Modify ReturnTaskListService to accept queryToken parameter
- Update ReturnTaskListStore to pass the queryToken to the service
- Enhance ReturnTaskListComponent to construct appropriate filter based on appearance
- Fix spelling of "Non-Book" in ProductCategory constant

Ref: #5072
2025-05-08 18:07:59 +02:00
Nino
78880fb2f4 Swagger API Update 2025-05-08 17:59:50 +02:00
Nino
d887c4e8fe fix(oms-data-access), fix(oms-return-process): implement return eligibility logic for specific product types
Add helper functions to determine product return eligibility based on item condition
and defect status. Specifically implemented return logic for TonDatentraeger products
where damaged but non-defective items aren't eligible for return. Also added export
for the eligibility helper in the index file.

Update the ReturnProcessComponent to check eligibility status before allowing
continuation to summary, ensuring only eligible items proceed in the return workflow.

Ref: #5075
2025-05-08 17:45:58 +02:00
Nino
0fe71fe9d8 fix(oms-data-access), fix(return-process): handle unknown product category in return process
Add support for 'unknown' product category state in ReturnProcessService
and ReturnProcessQuestionsComponent to ensure proper handling of return
processes without a defined product category. This correctly returns
EligibleForReturnState.Unknown and displays the product category dropdown
when needed.

Ref: #5073 #4943
2025-05-08 16:09:01 +02:00
Nino
b4bb5ab979 fix(oms-data-access): make most DeliveredItem fields optional
Update ReturnProcessQuestionSchema for DeliveredItem to make contributors,
format, formatDetail, volume, and manufacturer fields optional instead of
required. This ensures compatibility with the actual data structure received
from the API and prevents validation errors for incomplete product data.

Ref: #5068
2025-05-07 17:11:17 +02:00
Nino
bd19ec8489 feat(oms-task-list): improve task filtering and sorting logic
- Filter completed tasks to show only those completed today in review view
- Sort task list to show open tasks before completed tasks
- Add date-fns functions (isSameDay, parseISO) to handle date comparison
- Refactor filtering logic for better readability and maintainability

Ref: #4942
2025-05-07 15:58:27 +02:00
Nino
2bbf3d3739 fix(oms-return): centralize name formatting logic
Extracted common name formatting code into a reusable utility function to ensure
consistent display of customer/organization names across return feature components.
This improves maintainability and ensures consistent presentation throughout the
application.

Ref: #5066
2025-05-07 12:30:16 +02:00
Nino
e49d084439 fix(oms-data-access): make catalogProductNumber optional in DeliveredItem schema
Make the catalogProductNumber field optional in the ReturnProcessQuestionSchema for DeliveredItem
to match actual API response data structure and prevent validation errors when processing items
without this field.

Ref: #5068
2025-05-07 12:12:01 +02:00
Nino
5f31842afa feat(oms-task-list, oms-data-access): rename and enhance return review components to task list
Rename and refactor return review components to task list throughout the codebase:
- Rename ReturnReviewService to ReturnTaskListService with improved error handling
- Rename ReturnReviewStore to ReturnTaskListStore and add logging
- Update TaskActionType interface with new updateTo and actions properties
- Enhance ReturnTaskListItemComponent to support dynamic task actions
- Update templates to use new action structure and naming

The refactoring improves code organization and readability while enhancing the
task list functionality with better action handling and error management.

Ref: #4942 #4973
2025-05-06 17:48:58 +02:00
Nino
81bb8ba72d feat(oms-return-review): add uncompleted tasks dialog and guard
Add dialog component to warn users when they attempt to leave the return review
process with uncompleted tasks. This includes:
- Creating UncompletedTasksDialogComponent with confirmation/cancellation options
- Implementing CanDeactivate guard to check for uncompleted tasks
- Adding guard to return review routes configuration

The dialog gives users the choice to either go back and complete tasks or
leave despite having uncompleted tasks.

Ref: #4976
2025-05-06 17:46:34 +02:00
Nino
68ea22f3d2 OMS Swagger API Update 2025-05-06 13:15:19 +02:00
Nino
7edbe11c65 feat(oms-task-list): implement task action types and specialized UI handling
Enhance the ReturnTaskListComponent and ReturnTaskListItemComponent to:
- Use properly typed TaskActionTypes enum (OK, NOK, PRINT, UNKNOWN) instead of string literals
- Add specialized UI components for different action types
- Implement conditional rendering for task actions based on type
- Improve styling for different task types
- Filter out completed tasks in main view

feat(oms-data-access): add Zod schema validation for return receipts

- Add ReturnReceiptValuesSchema for validation of API payloads
- Implement proper type safety for task action types
- Use schema validation in ReturnProcessService before API calls

Ref: #4942
2025-05-05 17:45:48 +02:00
Nino
82d991fcbc feat(shared-task-list), feat(return-search-main), feat(return-review): create shared task list component and refactor return views
Implement new shared task list component to replace duplicate task list functionality across the application.
Update return review and search views to use the new shared component.

- Create new @isa/oms/shared/task-list library
- Extract task list functionality from return review component
- Add task list to return search main view
- Handle task completion actions through the shared component
- Fix typo in return review success message

Ref: #4942, #4972, #4974
2025-04-30 17:34:24 +02:00
Nino
0d1a65ed4a feat(oms-data-access), feat(return-review): implement task completion in return review
Added updateTaskListItem method to ReturnReviewStore to handle updating
individual task list items. Implemented the UI logic to show/hide the
"Mark as done" button based on completion status and connected the
completeTask method to update the store with the returned result.

Ref: #4942
2025-04-30 14:56:34 +02:00
Nino
c98cbd73b1 feat(oms-data-acess), feat(return-review): implement return review functionality
Add new ReturnReview library with core components and service structure:
- Create ReturnReviewService and ReturnReviewStore for task management
- Extract PrintReceipts functionality into dedicated service
- Implement review page components with task listing and completion
- Add support for receipt item tasks data model
- Update error handling with consistent error types
- Add comprehensive JSDoc documentation throughout

The implementation provides the foundation for the return review workflow,
including task listing and completion functionality.

Ref: #4942
2025-04-29 17:49:11 +02:00
Nino
4c79f2d127 feat(generated-swagger-oms-api): update OMS Swagger API models and services
Add receipt item task-related models and interfaces to support return review
functionality. Add new fields to ReceiptDTO and update ReturnProcessService

Includes:
- New task list models for receipt items
- Receipt service endpoint updates
- Field additions to ReceiptDTO model

Ref: #4942
2025-04-29 14:12:01 +02:00
Nino
61d0030342 feat(return-review): create return review library and connect to routing
Initialize the return-review feature library with basic component structure
and connect it to the existing routing system in both return-process and
return-summary features. Update navigation in ReturnSummaryComponent to
redirect to the review page after successful return completion.

Ref: #4942
2025-04-29 14:05:11 +02:00
Nino
86ed379b38 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-04-28 17:38:18 +02:00
Nino Righi
eba9cec16e Merged PR 1832: #4941 #5049 #5050
#4941 #5049 #5050
2025-04-28 15:36:03 +00:00
Nino
651c65edc7 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-04-28 15:24:12 +02:00
Lorenz Hilpert
809a6e38b3 fix(tests): update initialization test to expect service to be truthy 2025-04-25 20:00:10 +02:00
Lorenz Hilpert
e1ce520711 test(return-process): update initialization test to expect service to be falsy 2025-04-25 19:54:17 +02:00
Lorenz Hilpert
81995e8863 chore(pre-push): remove pre-push test script 2025-04-25 19:53:22 +02:00
Lorenz Hilpert
ae89f1e2f8 chore: update devDependencies and add pretest script
- Added a pretest script to clean up test results using trash-cli.
- Updated @angular-devkit/build-angular from 19.2.6 to ^19.2.9.
- Updated @nx/angular from 20.4.6 to ^20.8.1.
2025-04-25 19:43:36 +02:00
Lorenz Hilpert
75c6170be4 ci: update pre-push hook to run tests instead of CI 2025-04-25 19:26:54 +02:00
Lorenz Hilpert
5db3521a0e feat(tests): add jest-junit reporter for Azure DevOps integration 2025-04-25 19:15:29 +02:00
Lorenz Hilpert
a48ff29051 style(guidelines): change function export style to arrow functions
Replace function declarations with arrow function expressions assigned to constants
for better testability when mocking functions during unit tests.

This makes the codebase more consistent and addresses issues with function mocking.
2025-04-25 17:09:40 +02:00
Lorenz Hilpert
337ef46acb Updated .gitignore and Dockerfile for improved build process.
- 🛠️ **Refactor**: Changed npm install command in Dockerfile for better script handling
- 🗑️ **Chore**: Removed junit.xml from repository
- 🎨 **Style**: Added junit.xml to .gitignore for cleaner project structure
- 🎨 **Style**: Ensured newline at end of file in .gitignore
2025-04-25 12:06:15 +02:00
Lorenz Hilpert
c0e8e69f9f Updated Jest preset to enhance coverage collection configuration.
- ⚙️ **Config**: Added additional files to coverage exclusion list
2025-04-25 11:11:07 +02:00
Lorenz Hilpert
2046212581 Updated CI configuration and Jest preset for improved coverage reporting.
- ⚙️ **Config**: Modified CI command to include coverage in package.json
- ⚙️ **Config**: Updated summary file location in azure-pipelines.yml
- ⚙️ **Config**: Enhanced Jest preset to configure coverage reporters
2025-04-25 10:59:14 +02:00
Lorenz Hilpert
57968bd061 Updated Node.js version in Dockerfile for improved compatibility.
- ⚙️ **Config**: Changed base image from node:18 to node:22
2025-04-25 10:44:13 +02:00
Lorenz Hilpert
22c0a7d5d9 feat(e2e): add data attributes for improved test stability
Add data-what and data-which attributes to key UI elements:
- Add back button attributes to return details and process components
- Add filter button attributes to the filter menu component
- Add sort button attributes for both desktop and mobile views
- Add result count element attributes for better selection
- Add attributes to search result items for identification
- Add attributes to loading spinners for state verification

These attributes improve E2E test stability by providing reliable selectors
that are not tied to styling or DOM structure changes.

Ref: #5052
2025-04-24 21:39:23 +02:00
Nino
fa5ad7a561 Instructions Update 2025-04-22 12:23:39 +02:00
Lorenz Hilpert
39d101d456 Enhanced logging functionality with improved context handling and documentation.
-  **Feature**: Added support for hierarchical logger context
- 🛠️ **Refactor**: Updated logging methods to use LoggerContext
- 📚 **Docs**: Improved documentation for logger methods and context
2025-04-16 15:35:52 +02:00
Lorenz Hilpert
c9b5af7282 Added error logging guidelines and best practices to code style documentation.
- 📚 **Docs**: Introduced error logging section with guidelines
-  **Feature**: Added context-aware logging examples
- 🛠️ **Refactor**: Improved structure for error handling practices
2025-04-16 14:12:26 +02:00
Lorenz Hilpert
2efc5c3b0d Enhanced logging library with new features and improved performance.
-  **Feature**: Added global context support for logging configuration
- 🛠️ **Refactor**: Improved error handling in logging service
- 🚀 **Performance**: Optimized log level checks and error resilience
- 📚 **Docs**: Updated README with detailed logging levels and usage examples
2025-04-16 14:07:56 +02:00
Lorenz Hilpert
e0edd7887e Merge branch 'feature/core-logger-lib' into develop 2025-04-16 13:20:27 +02:00
Lorenz Hilpert
d615efd806 refactor: remove validation functions and tests for return processes
- Deleted validation functions for electronic devices, nonbook items, and ton/datentraeger.
- Removed associated test files for these validations.
- Updated question definitions to use new constants for item conditions and return reasons.
- Refactored return process service to utilize schema validation instead of custom validators.
- Adjusted HTML templates to reflect changes in eligibility state handling.
2025-04-15 21:39:50 +02:00
Lorenz Hilpert
a608d77ab5 Enhanced Checkbox and Checklist components with detailed documentation.
-  **Feature**: Added customizable appearance options for CheckboxComponent
-  **Feature**: Implemented ChecklistComponent for managing groups of checkboxes
- 📚 **Docs**: Added comprehensive documentation for Checkbox and Checklist components
- 🧪 **Test**: Created unit tests for ChecklistValueDirective and ChecklistComponent
2025-04-15 18:38:55 +02:00
Lorenz Hilpert
fdfff237f2 Added return receipt functionality and updated related models.
-  **Feature**: Introduced ReturnReceiptValuesDTO for return receipt data
-  **Feature**: Added ReceiptCreateReturnReceipt method in ReceiptService
-  **Feature**: Updated ReceiptItemDTO with new fields for handling details
2025-04-14 17:32:01 +02:00
Lorenz Hilpert
def52fde63 Merge tag '5035-scandit-integration-lizenz' into develop 2025-04-14 17:18:27 +02:00
Lorenz Hilpert
0957617b93 Merge branch 'hotfix/5035-scandit-integration-lizenz' 2025-04-14 17:17:42 +02:00
Lorenz Hilpert
a67305369e Update scandit license key in config.integration.json 2025-04-14 17:16:51 +02:00
Lorenz Hilpert
9c74dc15d2 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-04-14 16:14:57 +02:00
Lorenz Hilpert
e65085439e Enhance return process with checklist questions and related components.
-  **Feature**: Added checklist question type for return process
-  **Feature**: Implemented checklist question component
- 🛠️ **Refactor**: Updated return process service to handle checklist answers
- 📚 **Docs**: Added schemas for checklist answers and return details
- 🧪 **Test**: Updated tests for new checklist functionality
2025-04-14 16:13:44 +02:00
Lorenz Hilpert
621a8a5dc7 Refactor return process components for improved naming conventions.
- 🛠️ **Refactor**: Updated component selectors from 'lib-' to 'oms-feature-' for consistency
- 🎨 **Style**: Enhanced formatting and readability in HTML and TypeScript files
2025-04-14 11:43:03 +02:00
Lorenz Hilpert
beeba1004e Enhance documentation for return process components and schemas.
- 📚 **Docs**: Added detailed comments for return process questions and validation logic
- 📚 **Docs**: Improved documentation for return process service methods
- 📚 **Docs**: Updated schemas with descriptions for clarity
2025-04-11 19:21:18 +02:00
Lorenz Hilpert
4885a523ab feat: Implement return process questions and validators for Tolino categories
- Added questions and validation logic for the Tolino return process.
- Introduced Ton-/Datenträger return process questions and validation.
- Created a registry to map product categories to their respective questions and validators.
- Developed unit tests for the new return process questions and validators.
- Removed deprecated return process questions and validators to streamline the codebase.
2025-04-11 19:07:26 +02:00
Nino
f7a8cbf31d Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-04-11 16:59:20 +02:00
Nino
29d5c24e59 UI Datepicker Quick Fixes - Remove Dates + Datepicker Start Month 2025-04-11 16:58:30 +02:00
Lorenz Hilpert
afff1ea8fd Fix typo in date range filter input mapping for minStart and maxStop.
- 🐛 **Fix**: Corrected 'minStrat' to 'minStart' in mapping tests
2025-04-11 16:56:47 +02:00
Lorenz Hilpert
3c43d50f0f Enhance date range filter input mapping with min/max value handling.
-  **Feature**: Added mapping for min and max values in date range input
- 🛠️ **Refactor**: Updated handling of optional min/max properties in mapping function
- 🧪 **Test**: Added unit test for min and max value mapping
2025-04-11 16:54:59 +02:00
Lorenz Hilpert
e04d88f2ce Merge branch 'feature/5032-Filter-Menu-Refinement' into develop 2025-04-11 16:43:11 +02:00
Lorenz Hilpert
a50f02cb5b Merge branch 'develop' into feature/5032-Filter-Menu-Refinement 2025-04-11 16:36:57 +02:00
Lorenz Hilpert
aff6d18888 feat: enhance filter input mappings with detailed documentation and schema validation
- Added comprehensive JSDoc comments to mapping functions for checkbox and text filter inputs, improving code readability and maintainability.
- Refactored checkboxFilterInputMapping and checkboxOptionMapping functions to enhance clarity and structure.
- Removed unused data-range-filter-input mapping files and tests to streamline the codebase.
- Introduced a new dateRangeFilterInputMapping function with detailed mapping logic for date range inputs.
- Updated filter input schemas to include descriptive comments for better understanding of properties.
- Implemented unit tests for date range filter input mapping to ensure correct functionality.
- Enhanced existing filter mapping functions with improved error handling and validation.
- Updated index exports to reflect the removal and addition of mapping files.
2025-04-11 16:13:11 +02:00
Lorenz Hilpert
8144253a18 Refactor return search component and remove unused dropdown.
- 🛠️ **Refactor**: Updated return search result component for mobile responsiveness
- 🗑️ **Chore**: Removed unused order-by dropdown component and related files
- 📚 **Docs**: Enhanced component documentation for clarity
2025-04-11 15:24:08 +02:00
Nino
718918e3dc #5036 Return Details Display Data Adjustments 2025-04-11 15:16:18 +02:00
Lorenz Hilpert
93665cf35d Refactor FilterService and FilterMenuButtonComponent to remove logging. 2025-04-11 15:00:13 +02:00
Lorenz Hilpert
a766534b97 feat(logging): implement core logging library with structured logging service
- Added Core Logging library providing centralized logging functionality.
- Implemented LoggingService with multiple log levels and configurable sinks.
- Created ConsoleLogSink for logging to the browser console.
- Introduced LoggerApi for context-aware logging.
- Added support for custom sinks and logging configuration during app initialization.
- Enhanced FilterService and FilterMenuButtonComponent with logging capabilities.
- Updated ESLint and Jest configurations for the new logging library.
- Documented the logging library API and usage in README.
2025-04-11 14:58:34 +02:00
Nino
82c1861fdc Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-04-11 13:46:48 +02:00
Nino
82e04917b7 UI Datepicker Design Adjustments 2025-04-11 13:44:49 +02:00
Lorenz Hilpert
cdcd41a884 Merged PR 1831: Kundendaten // B2B - nach "Bearbeiten" speichern nicht möglich
fix(customer): Updated Validations for B2B Customer
Conditional Validator - If Organisation Name is set First and Lastname is not required, If no first and last name organisation name is required
Ref: #4996
2025-04-11 10:21:18 +00:00
Lorenz Hilpert
3e14426d2e feat: Implement filter input mapping and related schemas
- Added filter input mapping functionality to handle different input types (Text, Checkbox, DateRange).
- Created schemas for various filter inputs including BaseFilterInput, CheckboxFilterInput, DateRangeFilterInput, and TextFilterInput.
- Developed filter mapping logic to aggregate filter groups, inputs, and order by options.
- Implemented unit tests for filter mapping, input mapping, and order by option mapping to ensure correctness.
- Introduced a dropdown component for selecting order by options with appropriate styling and functionality.
2025-04-10 19:24:45 +02:00
Nino
a93251f082 #4982 #5004 Filter Datepicker QueryParams + QueryToken 2025-04-10 17:31:29 +02:00
Nino
de47c493bf Height Adjust Filter for ipad mini 2025-04-10 15:47:11 +02:00
Nino
23876e3266 Datepicker Filter Design Adjustments 2025-04-10 15:31:51 +02:00
Nino
4ac84df25c ControlValueAccessor Fix UI Datepicker + Unit Tests Added 2025-04-10 14:20:29 +02:00
Nino
c027791e27 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-04-10 12:06:35 +02:00
Nino Righi
3d18e45f59 Merged PR 1828: #5005 Datepicker UI
#5005 Datepicker UI
2025-04-10 10:06:24 +00:00
Nino
03b132fc94 Merge tag '4947-Kundenbestellungen-Namen-Vertauscht' into develop
Cherry-Pick 4947 4947-Kundenbestellungen-Namen-Vertauscht
2025-04-10 11:58:37 +02:00
Nino
206586035d Merge branch 'hotfix/4947-Kundenbestellungen-Namen-Vertauscht' 2025-04-10 11:58:27 +02:00
Nino Righi
67d8902423 Merged PR 1830: #4947 Fix Lastname and Firstname position in order-edit pages 2025-04-10 11:52:45 +02:00
Nino Righi
1c2d0421c4 Merged PR 1830: #4947 Fix Lastname and Firstname position in order-edit pages
#4947 Fix Lastname and Firstname position in order-edit pages
2025-04-10 08:41:37 +00:00
Lorenz Hilpert
b4caf3a177 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-04-09 12:43:06 +02:00
Lorenz Hilpert
ae3662dfd1 Refactor pre-commit and add pre-push hooks for CI checks.
- 🛠️ **Refactor**: Removed CI check from pre-commit hook
-  **Feature**: Added pre-push hook to enforce CI checks
2025-04-09 12:42:04 +02:00
Lorenz Hilpert
291386e4fd Merge tag '5022-Bezahlte-undunbezahlte-Ware-auf-der-seben-AHF-nummer' into develop
Hotfix 5022 - AHF Buchungh von Bezalten und nicht Bezahlten artikeln auf unterschiedliche Abholfächer 5022-Bezahlte-undunbezahlte-Ware-auf-der-seben-AHF-nummer
2025-04-09 12:36:28 +02:00
Lorenz Hilpert
620ffae55c Merged PR 1829: Kundendaten // B2B - nach "Bearbeiten" speichern nicht möglich
bugfix: Show error when control has error

Rename validator requiredIfControlIsSet to requireGenderWhenNameIsSet
Update logic for requireGenderWhenNameIsSet
Added JSDoc for Documentation
UiFormControlComponent Subscribing to ngControl.statusChanges and ngControl.valueChanges independendly and call cdr.markForCheck when emitted

Related work items: #4996
2025-04-09 07:30:44 +00:00
Lorenz Hilpert
8ca7977f7c Enhanced return details and search components with new features and improvements.
-  **Feature**: Added InViewport directive for element visibility detection
-  **Feature**: Introduced new button for navigation in return details
- 🛠️ **Refactor**: Improved scroll position restoration logic and removed deprecated files
- 📚 **Docs**: Updated README with usage instructions for new directives

Ref: #5034
2025-04-08 10:51:24 +02:00
Lorenz Hilpert
62d0783e88 Enhance return search store with new methods and hooks for entity management.
-  **Feature**: Added method to remove entities by process ID
-  **Feature**: Implemented onInit hook to clear entities based on process IDs
- 🛠️ **Refactor**: Updated imports for clarity and organization
- 🛠️ **Refactor**: Improved entity management logic in return search store
2025-04-07 19:34:18 +02:00
Lorenz Hilpert
bd1e4f36e1 Enhanced search functionality in ReturnSearch components.
-  **Feature**: Added 'clear' parameter to search method in store
- 🛠️ **Refactor**: Updated search calls in ReturnSearchMain and Result components
- 🎨 **Style**: Improved conditional rendering for apply button in filter actions
2025-04-07 19:20:05 +02:00
Lorenz Hilpert
79356fa130 Refactored import statements for scroll position restoration utility.
- 🛠️ **Refactor**: Removed unused DOCUMENT import from scroll position restoration
2025-04-07 18:53:36 +02:00
Lorenz Hilpert
c1a40ae82f Refactored scroll position restoration logic for improved clarity.
- 🛠️ **Refactor**: Simplified storeScrollPosition function and event handling
- 🛠️ **Refactor**: Removed redundant code for scroll position storage
2025-04-07 18:53:12 +02:00
Lorenz Hilpert
492dae14f7 feat: add pagination support to query token schema with skip and take fields
feat: enhance return search component to handle search callbacks and update query parameters

fix: update return search result component template to use new search method and improve loading states

refactor: streamline return search result component logic and improve state management

feat: implement scroll position restoration in return search feature

feat: introduce filter service enhancements for query settings and synchronization with URL parameters

chore: create utils for scroll position management and viewport detection

fix: update filter service to use new input and query settings types

chore: add tests and configurations for new utils library

ref: #5033
2025-04-07 18:23:43 +02:00
Lorenz Hilpert
9950c76482 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-04-04 21:29:23 +02:00
Lorenz Hilpert
7e7a5ebab9 Introduced responsive layout utilities and directives for Angular.
-  **Feature**: Added breakpoint utility for responsive design
-  **Feature**: Implemented BreakpointDirective for conditional rendering
- 🛠️ **Refactor**: Updated styles for filter and order-by components
- 📚 **Docs**: Created README and documentation for ui-layout library
- ⚙️ **Config**: Added TypeScript and ESLint configurations for the new library
2025-04-04 18:00:49 +02:00
Nino
41fc8e0fb1 Refactored return components for improved performance and maintainability.
- 🛠️ **Refactor**: Streamlined return feature components
- 🗑️ **Chore**: Removed unused files related to return functionality
2025-04-04 14:02:05 +02:00
Lorenz Hilpert
41067a7e54 Added new icons to the product format icon group for additional formats.
-  **Feature**: Included icons for CD, other formats, and games
2025-04-04 11:12:08 +02:00
Lorenz Hilpert
e1a50b0ce0 Refactored filter service and updated query parameter handling.
- 🛠️ **Refactor**: Renamed methods for clarity in filter service
- 🛠️ **Refactor**: Updated query parameter usage in return search components
2025-04-04 10:41:04 +02:00
Lorenz Hilpert
227af192e6 Updated styles for return details component to improve layout.
- 🎨 **Style**: Added margin-top to enhance spacing in the component
2025-04-04 10:30:16 +02:00
Lorenz Hilpert
bd21b674bf Refactored return search components and updated query handling.
- 🛠️ **Refactor**: Changed filter service method calls to use new query methods
- 🎨 **Style**: Updated button components for consistency
- 🧪 **Test**: Adjusted tests to reflect changes in query parameters
- ⚙️ **Config**: Modified pre-commit hook to run CI checks
2025-04-03 21:21:30 +02:00
Lorenz Hilpert
b21395ed61 Refactored return feature components and removed unused files.
- 🛠️ **Refactor**: Cleaned up return feature components and styles
- 🗑️ **Chore**: Deleted obsolete files and updated exports
- 📚 **Docs**: Added README for return details library
2025-04-03 18:45:33 +02:00
Lorenz Hilpert
da27745ebe Implemented return search feature with main and result components.
-  **Feature**: Added return search main and result components
- 🎨 **Style**: Updated styles for return search components
- 🛠️ **Refactor**: Modified routing for return search functionality
- 📚 **Docs**: Updated documentation references in settings
2025-04-03 17:29:42 +02:00
Lorenz Hilpert
8a94da6868 Added return search feature with main and result components.
-  **Feature**: Implemented return search main and result components
- 📚 **Docs**: Created README for return search library
- ⚙️ **Config**: Added TypeScript and Jest configuration for return search
- 🛠️ **Refactor**: Updated filter menu components with scroll strategy
2025-04-03 17:29:05 +02:00
Lorenz Hilpert
81a7154470 Added new models and schemas for gender, address type, and shipping type.
-  **Feature**: Introduced Gender, AddressType, and ShippingType enums
- 🗑️ **Chore**: Removed obsolete schemas and service files from return feature
- 🛠️ **Refactor**: Updated index files to export new models
2025-04-03 11:53:27 +02:00
Lorenz Hilpert
0dee30062f Refactor menu components and styles for improved organization.
- 🛠️ **Refactor**: Removed old menu-button component and styles
-  **Feature**: Added new input-menu and filter-menu components
- 🎨 **Style**: Updated styles for input-menu and filter-menu components
- 🗑️ **Chore**: Cleaned up unused input-button component files
2025-04-02 21:06:11 +02:00
Lorenz Hilpert
eb0a0d3dc3 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-04-02 15:17:14 +02:00
Lorenz Hilpert
67dcb49a1d Enhance UI components with new input control directive and styling.
-  **Feature**: Added InputControlDirective for better input handling
- 🎨 **Style**: Updated button and text-field styles for loading states
- 🛠️ **Refactor**: Improved button component structure and disabled state handling
- 📚 **Docs**: Updated code style guidelines with new control flow syntax
2025-04-02 15:16:35 +02:00
Lorenz Hilpert
f3e2e9fee3 Merged PR 1827: Kundendaten // B2B - nach "Bearbeiten" speichern nicht möglich
Related work items: #4996
2025-04-02 10:02:13 +00:00
Lorenz Hilpert
a4b092a021 Enhance return details service with error handling and tests.
-  **Feature**: Improved error handling in fetchReturnDetails method
- 🧪 **Test**: Added unit tests for ReturnDetailsService
2025-04-02 11:49:04 +02:00
Lorenz Hilpert
aeacd0077f Revert "Update Angular and Nx dependencies to latest versions."
This reverts commit b508abefaf.
2025-04-02 11:45:56 +02:00
Lorenz Hilpert
78a0e828b8 Revert "Enhance return details service with error handling and tests."
This reverts commit df49e3a79b.
2025-04-02 11:38:51 +02:00
Lorenz Hilpert
b508abefaf Update Angular and Nx dependencies to latest versions.
- 🗑️ **Chore**: Updated Angular dependencies to version 19.2.x
- 🗑️ **Chore**: Updated Nx dependencies to version 20.7.0
- 🗑️ **Chore**: Updated devDependencies including Jest and ESLint
2025-04-02 11:32:35 +02:00
Lorenz Hilpert
df49e3a79b Enhance return details service with error handling and tests.
-  **Feature**: Improved error handling in fetchReturnDetails method
- 🧪 **Test**: Added unit tests for ReturnDetailsService
2025-04-02 11:19:58 +02:00
Lorenz Hilpert
34512f3b9a Set up Jest configuration and update dependencies for testing.
- ⚙️ **Config**: Added Jest configuration files for testing
- 🗑️ **Chore**: Removed unused Karma configuration and assets
- 🛠️ **Refactor**: Updated return details store methods for better clarity
- 📚 **Docs**: Enhanced comments and documentation in return details store
2025-04-02 11:09:25 +02:00
Lorenz Hilpert
093bb3b484 Update commit message structure in guidelines
- 📚 **Docs**: Revised commit message instructions for clarity
2025-04-01 17:29:38 +02:00
Lorenz Hilpert
858242c6dd Enhance searchbox functionality
Improved the searchbox components to utilize environment service for mobile detection.

-  **Feature**: Integrated EnvironmentService for mobile device detection
- 🛠️ **Refactor**: Cleaned up provider definitions for better readability
- 🎨 **Style**: Reformatted code for consistency in style

#5001
2025-04-01 14:42:57 +02:00
Lorenz Hilpert
119bcd9df9 Update routing to redirect to dashboard
Configured the routing to redirect the root path to the dashboard.

-  **Feature**: Added redirect from root path to 'kunde/dashboard'
2025-04-01 14:27:34 +02:00
Lorenz Hilpert
b43d0fcea6 Update routing and side menu interactions
Refactored routing structure and improved side menu functionality.

- 🛠️ **Refactor**: Simplified route definitions for process handling
- 🎨 **Style**: Cleaned up side menu HTML for better readability
- 🛠️ **Refactor**: Enhanced side menu item click handling

#5021
2025-04-01 14:12:09 +02:00
Lorenz Hilpert
ddad3ad967 Add return process answer model and validators
Introduced a new model for return process answers and corresponding validation tests.

-  **Feature**: Created ReturnProcessAnswers type for handling answers
-  **Feature**: Added validation functions for various return scenarios
- 🧪 **Test**: Implemented comprehensive tests for return process validations
2025-04-01 13:59:28 +02:00
Lorenz Hilpert
aaa161424e Enhance error handling and storage utilities
Improved error handling and updated storage utilities for better performance.

-  **Feature**: Added custom error classes for return process errors
- 🛠️ **Refactor**: Updated hash function to handle strings and objects
- 🛠️ **Refactor**: Enhanced storage key generation with user context
- ⚙️ **Config**: Updated VSCode settings and package dependencies
2025-04-01 12:01:16 +02:00
Lorenz Hilpert
3bbec6a68d 📚 Update review instructions for positive feedback
Clarified guidelines for highlighting positive aspects of code reviews.

- 📚 **Docs**: Specify using different funny emojis for good practices
- 🛠️ **Refactor**: Removed redundant good practice example
2025-03-31 17:57:50 +02:00
Lorenz Hilpert
2a8a929fd7 📚 Update code review instructions for clarity
Enhanced the code review guidelines to improve clarity and effectiveness.

- 📚 **Docs**: Expanded review process steps with detailed explanations
- 📚 **Docs**: Added a review template for structured feedback
- 📚 **Docs**: Clarified the use of emojis for categorizing feedback
2025-03-31 17:28:52 +02:00
Lorenz Hilpert
3bcdfccb5c 📚 Update review instructions and code style documentation
Enhanced code review guidelines and clarified code style documentation.

- 📚 **Docs**: Added emphasis on adherence to review guidelines
- 📚 **Docs**: Clarified documentation requirements in code style
- 🛠️ **Refactor**: Updated import paths in input controls styles
- 📚 **Docs**: Expanded tech stack documentation with new libraries
2025-03-31 16:12:48 +02:00
Lorenz Hilpert
9696084f7b Add dropdown component and styles
Introduced a new dropdown component with associated styles and fixed a typo.

-  **Feature**: Added dropdown component and its styles
- 🎨 **Style**: Updated styles for dropdown button and options
- 🐛 **Fix**: Corrected typo in dropdown options class name
2025-03-31 13:38:43 +02:00
Lorenz Hilpert
417bd649e2 Refactor chip option component and styles
Updated the chip option component and its styles for improved functionality and organization.

-  **Feature**: Introduced new chip option styles and layout
- 🛠️ **Refactor**: Removed outdated styles and organized SCSS files
- 🧪 **Test**: Added unit tests for chip option component functionality
2025-03-31 13:28:32 +02:00
Lorenz Hilpert
d38fed297d Add input controls and checkbox component
Introduced a new input controls library with a checkbox component.

-  **Feature**: Added input controls library with checkbox component
- 🎨 **Style**: Updated checkbox component styles and structure
- 🧪 **Test**: Added unit tests for checkbox and empty state components
- 🛠️ **Refactor**: Improved checkbox component code and removed unused styles
- 📚 **Docs**: Updated commit message guidelines in VSCode settings
2025-03-31 12:29:22 +02:00
Lorenz Hilpert
3c110efdfa 📚 Add state management and testing guidelines documentation
Introduced new documentation files for state management and testing guidelines to enhance developer understanding and best practices.

- 📚 **Docs**: Added state management guidelines with local and global state recommendations
- 📚 **Docs**: Created testing guidelines including unit testing requirements and best practices
- 📚 **Docs**: Updated project structure documentation for clarity
2025-03-31 11:52:17 +02:00
Lorenz Hilpert
1cbabd2d7a feat: enhance return process feature with improved layout and EAN validation 2025-03-28 20:35:24 +01:00
Lorenz Hilpert
133020ece1 chore: simplify copilot instructions by removing outdated performance and common patterns sections 2025-03-28 20:16:15 +01:00
Lorenz Hilpert
549d419b69 docs: update TypeScript and Angular guidelines for improved best practices and error handling 2025-03-28 20:03:29 +01:00
Lorenz Hilpert
8bbaf1c70c feat: update button component with spinner support and improve test coverage 2025-03-28 18:08:17 +01:00
Lorenz Hilpert
d0b7c95be2 chore: update copilot instructions to reflect current tech stack 2025-03-28 16:56:40 +01:00
Lorenz Hilpert
b0dba2325d feat: add unit tests for ButtonComponent using Spectator and Jest 2025-03-28 14:20:22 +01:00
Lorenz Hilpert
a9c606ec21 feat: improve return process component error handling and enhance typing 2025-03-28 13:49:58 +01:00
Lorenz Hilpert
81bec4b153 refactor: update import paths and adjust product category type handling 2025-03-27 17:02:25 +01:00
Lorenz Hilpert
0c2feb96ac feat: enhance return process with product category selection and update dropdown functionality 2025-03-27 17:01:00 +01:00
Nino Righi
1855b1970d Merged PR 1826: #5009 #5013 Search Handling and Focus
#5009 #5013 Search Handling and Focus
2025-03-27 12:26:37 +00:00
Lorenz Hilpert
0a46258588 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-26 16:39:07 +01:00
Lorenz Hilpert
ca2e529bdf feat: introduce return process models and enhance return process item component 2025-03-26 16:38:41 +01:00
Nino Righi
82a2d70ce4 Merged PR 1825: #4982 #5003 #4989 Filter Handling + Checkbox UI + Checkbox Input Control
#4982 #5003 #4989 Filter Handling + Checkbox UI + Checkbox Input Control
2025-03-26 12:52:00 +00:00
Lorenz Hilpert
fa39b6d071 fix: update eslint config to correctly ignore generated directories 2025-03-25 17:12:05 +01:00
Lorenz Hilpert
0f3f456909 fix: add missing newlines and improve formatting in various DTO models 2025-03-25 17:11:21 +01:00
Lorenz Hilpert
727e0469ad feat: add cyclic dependency detection in return process service and improve layout in return process item component 2025-03-24 18:27:15 +01:00
Lorenz Hilpert
7e3d6b4e61 feat: enhance progress bar styles with nested transition for improved animation 2025-03-24 16:16:31 +01:00
Lorenz Hilpert
453403cfde feat: add progress tracking for return process questions and update UI to display progress 2025-03-24 16:13:20 +01:00
Lorenz Hilpert
9001850c1f feat: add progress bar component with styles and integration into the application 2025-03-24 15:26:14 +01:00
Lorenz Hilpert
b97ad4f24b feat: refactor return process models and update button styles for improved UI consistency 2025-03-24 14:20:57 +01:00
Lorenz Hilpert
452de44f34 feat: implement user storage provider with clear functionality and update root state service for local storage integration 2025-03-21 11:00:24 +01:00
Lorenz Hilpert
db7da0699e feat: add data access and feature libraries for return process, including models, schemas, and routes 2025-03-20 21:25:20 +01:00
Lorenz Hilpert
fbd5414e47 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-18 17:11:08 +01:00
Lorenz Hilpert
5310619211 feat: add dropdown component with appearance options and styles 2025-03-18 17:10:49 +01:00
Nino
edbdba6868 Searchbar Update + Storybook Update 2025-03-17 17:07:31 +01:00
Nino
2d5fce8554 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-14 17:51:35 +01:00
Nino
f5b7da5bd2 Checkbox Init Implementation, Small Improvements 2025-03-14 17:51:07 +01:00
Lorenz Hilpert
d4c1cdbc6e feat: add appearance control to checkbox component stories 2025-03-14 16:14:03 +01:00
Lorenz Hilpert
576d439a79 feat: update button styles to enhance icon visibility in disabled state 2025-03-14 16:00:45 +01:00
Lorenz Hilpert
00fc978c4f feat: enhance return details with checkbox selection and select all functionality 2025-03-14 15:50:33 +01:00
Lorenz Hilpert
44e596327e Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-14 14:22:43 +01:00
Lorenz Hilpert
3d95bddb23 feat: enhance return details UI with improved styling and conditional rendering 2025-03-14 14:22:13 +01:00
Nino
2210aeb1c2 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-14 12:23:21 +01:00
Nino
a2b6847898 Removed Console.logs, Fixed Browser Back Button -> Navigation for Search Results now in Parent Component, Wording Fix 2025-03-14 12:22:53 +01:00
Lorenz Hilpert
3f252639d5 feat: implement gender schema and enhance receipt-related schemas; add dynamic order group data component 2025-03-14 12:00:23 +01:00
Lorenz Hilpert
3f7df0f748 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-13 21:24:00 +01:00
Lorenz Hilpert
703090eabd feat: add core storage and scroll position libraries with initial implementations and configurations 2025-03-13 21:22:43 +01:00
Nino
33694357bd Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-13 18:16:48 +01:00
Nino
91668e53fa OrderBy Toolbar mobile, ScrollPos Update, Schema Update 2025-03-13 18:15:36 +01:00
Lorenz Hilpert
39e4efff2b feat: enhance return details component with dynamic pricing and improved layout; add new price and VAT schemas 2025-03-13 16:01:36 +01:00
Lorenz Hilpert
1a4d0a38da Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-12 22:20:28 +01:00
Lorenz Hilpert
6c4641d2b7 feat: update entity container schema to allow optional fields; enhance return details component with dynamic product data and improved layout 2025-03-12 22:19:56 +01:00
Nino
815523b4ca Adjustments Dania 2025-03-12 17:54:16 +01:00
Lorenz Hilpert
57b5f30a66 refactor: rename entityContainerSchema to EntityContainer and update usage in receipt schema; change checkbox selector for consistency 2025-03-12 16:47:09 +01:00
Lorenz Hilpert
94919efd83 feat: refactor checkbox component to support bullet appearance; update styles and selector 2025-03-12 16:34:21 +01:00
Lorenz Hilpert
cd0d740dc2 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-12 16:18:37 +01:00
Lorenz Hilpert
dc3970ceea style: update gap in client row component for improved layout 2025-03-12 16:16:00 +01:00
Lorenz Hilpert
5bba1dff8f feat: add schemas and utility functions for return processing; update styles and component structure 2025-03-12 16:13:47 +01:00
Nino
7ff6e9495e QueryToken Schemas + Store Update, Ipad Stylings Layout, Bugfix mergeQueryParams, Bugfix List should not Reload if Hits Reached 2025-03-12 15:24:05 +01:00
Michael Auer
04403179d7 ~ nginx.conf: added "/browser" to try_files 2025-03-11 18:22:39 +01:00
Michael Auer
a39706bff3 Merge tag 'traefik-ingressroute-with-path' into develop 2025-03-11 18:06:01 +01:00
Nino
24c2c1c77d Order By Styling Update, Search Bar Clear Added 2025-03-11 17:49:39 +01:00
Nino
a364a4f0e0 Result List Empty State - Initial Loader - Pending Loader 2025-03-11 17:06:19 +01:00
Nino
dcc70745da Scroll Pos Handling Update 2025-03-11 16:28:17 +01:00
Nino
effce6f41c Improvements to Search Request Handling - F5 Refresh Page Init Search Fixed 2025-03-11 16:08:24 +01:00
Nino
a5feaba5e3 #4977 Search / Results Update - Scrollpos - Reload fix 2025-03-11 15:10:59 +01:00
Nino
d8bb42b8c6 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-10 18:50:56 +01:00
Nino
f74494f34e Paging/Reload, Searchbar and Icon Update 2025-03-10 18:49:10 +01:00
Lorenz Hilpert
abce5f43e2 feat: add ProductImage directive and service; implement storybook for product image component 2025-03-10 17:10:11 +01:00
Lorenz Hilpert
ce4a6b36b6 feat: add Checkbox component with styling and stories; update process resolver to include tags 2025-03-10 15:23:37 +01:00
Lorenz Hilpert
298ea042f2 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-10 13:51:26 +01:00
Lorenz Hilpert
573d6a740e feat: add InfoButton component with styling and functionality; update process schemas to include tags 2025-03-10 13:50:53 +01:00
Lorenz Hilpert
8eb5e09490 feat: enhance canActivate guard to use zod for process ID validation 2025-03-10 10:57:54 +01:00
Nino
aa8869ceb1 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-07 18:09:29 +01:00
Nino
e5f42c9de2 Header 2025-03-07 18:09:02 +01:00
Lorenz Hilpert
532c7e5e86 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-07 16:42:39 +01:00
Lorenz Hilpert
30ccd93967 feat: add core-scanner library with initial implementation and configuration 2025-03-07 16:42:23 +01:00
Nino
b85538f98a Quick Fix Schema to Array 2025-03-07 16:36:11 +01:00
Nino
d9dede4341 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-07 16:32:38 +01:00
Nino
4a3c934fe0 Utils Lib angelegt, safeParse Funktion ausgelagert und eingebunden in return service 2025-03-07 16:31:47 +01:00
Nino
944fb8a186 Code improvements, Details Page + Routing 2025-03-07 16:07:24 +01:00
Lorenz Hilpert
73fd487a13 feat: add ui-toolbar component and update button components 2025-03-07 15:51:17 +01:00
Lorenz Hilpert
592027f648 feat: implement new feature for enhanced user navigation 2025-03-07 10:53:08 +01:00
Lorenz Hilpert
84243ac4e6 feat: add EmptyState component with styles and stories 2025-03-06 20:24:06 +01:00
Nino
04b9422d5d #4977 Result Page 2025-03-06 18:25:30 +01:00
Nino
584cb63eaf Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-06 17:39:28 +01:00
Nino
b9871bba54 #4977 Handling Search Results + Navigation 2025-03-06 17:38:37 +01:00
Lorenz Hilpert
6769e3864e Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-06 17:24:30 +01:00
Lorenz Hilpert
cebb644da9 feat: implement ClientRow and ItemRowData components with associated styles and stories 2025-03-06 17:23:51 +01:00
Nino
734a7b8739 #4994 Receipt Schema erweitert 2025-03-06 11:07:03 +01:00
Lorenz Hilpert
e89d1999a6 feat: add ui-item-rows library with initial component and configuration 2025-03-05 19:51:09 +01:00
Lorenz Hilpert
b7cbd50e83 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-05 19:47:45 +01:00
Lorenz Hilpert
76aa04bc4c feat: add core-config and shared-product-image libraries; implement initial structure and configuration 2025-03-05 19:47:27 +01:00
Nino
b951cf7024 #4994 Store Anbindung in die Komponente 2025-03-05 18:25:01 +01:00
Nino
f896d91ebb Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-03-05 18:04:48 +01:00
Nino
a884adc3a9 #4994 Process Handling + Schema Update 2025-03-05 18:04:15 +01:00
Lorenz Hilpert
ce9bc9511a feat: remove deprecated shared return library; clean up related files and configurations 2025-03-05 15:55:10 +01:00
Lorenz Hilpert
2653322232 feat: enhance filter functionality; update search handling and state management in filter service 2025-03-05 15:46:12 +01:00
Lorenz Hilpert
86eb0bb494 feat: refactor return feature components; remove deprecated files and implement new search bar input 2025-03-05 12:08:48 +01:00
Lorenz Hilpert
73be50e7d2 feat: implement new text field and button components; remove deprecated search bar and input controls 2025-03-03 21:02:21 +01:00
Lorenz Hilpert
da5151df78 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-03-03 14:22:56 +01:00
Lorenz Hilpert
df47b932b6 Upgrade isa-app project 2025-03-03 13:28:03 +01:00
Nino
c096609a27 Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-02-28 17:55:05 +01:00
Nino
6b07b322f4 ISA Typography Update 2025-02-28 17:54:40 +01:00
Lorenz Hilpert
1b821db248 refactor: replace UiButtonsComponent with standalone button component and remove deprecated files 2025-02-28 17:18:21 +01:00
Lorenz Hilpert
ecf446671c refactor: reorganize process module structure and remove deprecated files 2025-02-28 16:24:44 +01:00
Lorenz Hilpert
a2f204d0d6 Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-02-28 16:23:20 +01:00
Lorenz Hilpert
c8678b7e91 feat: enhance process management with injector functions and service updates 2025-02-28 16:20:34 +01:00
Nino
ec41738def Merge branch 'develop' of https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend into develop 2025-02-28 16:15:53 +01:00
Nino
53a7f01507 Icons Update 2025-02-28 16:13:38 +01:00
Lorenz Hilpert
7366f038e5 feat: create core process library with initial setup and routing configuration 2025-02-28 16:02:44 +01:00
Lorenz Hilpert
1c9cd2a0b0 feat: add UI component libraries for buttons, input controls, and search bar 2025-02-28 14:28:24 +01:00
Lorenz Hilpert
09aa3f09cb Merge branch 'develop' of ssh.dev.azure.com:v3/hugendubel/ISA/ISA-Frontend into develop 2025-02-27 17:10:58 +01:00
Lorenz Hilpert
eff67b9a06 feat: create icons library with initial configuration and setup 2025-02-27 17:10:19 +01:00
Michael Auer
c9b2762bbc Merged PR 1824: ISA-Frontend - Expliziter Pfad für Traefik IngressRoute
Früher wurde die IngressRoute für die ISA-UI mit dem Pfad "/" angelegt, jetzt mit "/isa-ui/v%MAJOR%"
2025-02-27 14:05:54 +00:00
Lorenz Hilpert
c49b0625c1 fix: update Tailwind CSS configuration for consistency and add new color shades 2025-02-26 18:14:38 +01:00
Lorenz Hilpert
42451e2144 chore: update ESLint and Prettier configurations, add eslint-plugin-prettier, and modify .prettierignore 2025-02-26 17:42:35 +01:00
Lorenz Hilpert
f52fb00df7 chore: update pre-commit hook, modify prettier ignore, and add Sheriff configuration 2025-02-26 17:02:42 +01:00
Lorenz Hilpert
b485bb768c feat: add feature return library components and Jest configuration 2025-02-24 15:43:16 +01:00
Lorenz Hilpert
3f77646f8a chore: prettier write 2025-02-24 15:29:32 +01:00
Lorenz Hilpert
eb6149a6e3 Merge branch 'nx-workspace-migration' into develop 2025-02-24 15:26:32 +01:00
Lorenz Hilpert
5aa98bd90b Merge branch 'tracking' into nx-workspace-migration 2025-02-24 15:25:16 +01:00
Lorenz Hilpert
d71404f400 chore: remove unused assets and story files from isa-app 2025-02-24 14:40:56 +01:00
Lorenz Hilpert
f68eb33852 refactor: update memorize decorator to use 'any' type and remove migrations.json 2025-02-24 14:26:11 +01:00
Lorenz Hilpert
39d790c121 Angular Migrations to 19 2025-02-24 13:51:42 +01:00
Lorenz Hilpert
10349409fb bump nx and related packages to version 20.4.6 2025-02-24 13:41:42 +01:00
Lorenz Hilpert
0dc02abc8a Merge branch 'develop' into nx-workspace-migration 2025-02-24 13:37:39 +01:00
Lorenz Hilpert
388346e21b Merge tag '3.4' into develop
Finish Release 3.4 3.4
2025-02-10 10:41:31 +01:00
Lorenz Hilpert
fd11cf19e4 Update imports to use generated Swagger API paths 2025-01-29 17:43:20 +01:00
Lorenz Hilpert
8e7b067310 Add new model types for Swagger APIs and remove obsolete models 2025-01-29 17:28:33 +01:00
Lorenz Hilpert
c6a174d93f Add new model definitions for various APIs in generated Swagger files 2025-01-29 17:16:58 +01:00
Lorenz Hilpert
9efbfab253 Update .gitignore and .prettierignore; add generated Swagger API libraries 2025-01-29 17:09:36 +01:00
Lorenz Hilpert
d474f555e3 Add caniuse-lite dependency to package.json 2025-01-29 15:39:39 +01:00
Lorenz Hilpert
c59a09c252 Migration Angular CLI to NX 2025-01-29 15:37:46 +01:00
Lorenz Hilpert
6d28662431 Update Scandit licence key in configuration files 2025-01-02 13:38:26 +01:00
Lorenz Hilpert
27174e4ed3 Update Scandit licence key in configuration files 2025-01-02 13:26:54 +01:00
Nino
9b1b2c4682 Angular Service Worker insert Bypass in Req Header for Network Req 2024-12-20 16:28:35 +01:00
Lorenz Hilpert
674e2b7e1b Paket fuehrt zu fehler bei der installation
@rollup/rollup-linux-x64-gnu
2024-12-09 10:55:20 +01:00
Lorenz Hilpert
035abde3c3 Merge branch 'release/3.4' into develop 2024-12-06 10:45:48 +01:00
Lorenz Hilpert
ca998c0685 #4922 Rename customer_name to customer_no in goods service and pickup shelf service 2024-12-05 16:43:09 +01:00
Lorenz Hilpert
b6aab4f743 Add ID to assortment filter button in price update component 2024-11-28 17:13:20 +01:00
Lorenz Hilpert
1becbec412 Merge tag 'scandit-package-replacement' into develop
Scandit Lizenz und Package upgrade scandit-package-replacement
2024-11-25 14:04:57 +01:00
Lorenz Hilpert
c35c82eaab Update Scandit license keys in configuration files 2024-11-21 14:16:58 +01:00
Lorenz Hilpert
258faec021 Refactor login strategy to conditionally trigger mobile device login 2024-11-19 16:55:00 +01:00
Lorenz Hilpert
4bcc523480 Update login strategy to always trigger mobile device login and prevent backdrop closing on modal 2024-11-19 16:31:55 +01:00
Lorenz Hilpert
895e2bd2ec Merge tag 'Abholfach-zubuchen-und-Coveransicht' into develop
Abholfach-zubuchen-und-Coveransicht Abholfach-zubuchen-und-Coveransicht
2024-11-19 13:54:23 +01:00
Lorenz Hilpert
f30de35d51 Enhance authentication flow by improving error handling and validating ID tokens before login 2024-11-19 13:42:54 +01:00
Lorenz Hilpert
0c6f8abbad Fix login strategy condition to properly check for mobile devices 2024-11-18 13:49:32 +01:00
Lorenz Hilpert
54b37436eb Refactor authentication handling to utilize LoginStrategy and improve error management 2024-11-18 13:48:58 +01:00
Lorenz Hilpert
02bae79e4a Merged PR 1819: #4844 Implement dev-scanner configuration and enhance app initialization process
#4844 Implement dev-scanner configuration and enhance app initialization process
2024-11-13 17:09:34 +00:00
Lorenz Hilpert
67cf380948 Update Matomo Docker Konfiguration 2024-06-25 14:06:18 +02:00
Lorenz Hilpert
e0ae79bc2a Update Docker Compose 2024-06-25 13:00:54 +02:00
Lorenz Hilpert
8ccc29c85a Tracking - Filter, Artikelsuche, Abholfach(Einbuchen, Reservierung, Ausräumen,Fehlende) 2024-06-24 15:10:51 +02:00
3278 changed files with 66661 additions and 16483 deletions

86
.github/commit-instructions.md vendored Normal file
View File

@@ -0,0 +1,86 @@
# Commit Message Instructions (Conventional Commits)
Commit messages should follow the [Conventional Commits specification](https://www.conventionalcommits.org/en/v1.0.0/). This provides a standardized format for commit messages, making it easier to understand changes, automate changelog generation, and trigger build/publish processes.
## Format
The commit message structure is as follows:
```
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
```
---
### Components
1. **Type**: Indicates the kind of change introduced by the commit. Must be one of the allowed types (see below).
2. **Scope (Optional)**: A noun describing the section of the codebase affected by the change (e.g., `auth`, `ui`, `build`). Enclosed in parentheses.
3. **Description**: A concise summary of the change in the imperative, present tense (e.g., "add login feature", not "added login feature" or "adds login feature"). Starts with a lowercase letter and should not end with a period. Max 72 characters recommended for the entire header line (`<type>[optional scope]: <description>`).
4. **Body (Optional)**: A more detailed explanation of the changes. Use the imperative, present tense. Explain the _what_ and _why_ vs. _how_. Separate from the description by a blank line. Wrap lines at 72 characters.
5. **Footer(s) (Optional)**: Contains additional metadata. Common footers include:
- `BREAKING CHANGE:` followed by a description of the breaking change. A `!` can also be appended to the type/scope (`feat!:`) to indicate a breaking change.
- Issue references (e.g., `Refs: #123`, `Closes: #456`). Separate from the body by a blank line.
---
### Allowed Types
- **feat**: A new feature for the user.
- **fix**: A bug fix for the user.
- **build**: Changes that affect the build system or external dependencies (e.g., gulp, broccoli, npm).
- **chore**: Other changes that don't modify src or test files (e.g., updating dependencies, build tasks).
- **ci**: Changes to CI configuration files and scripts (e.g., Travis, Circle, BrowserStack, SauceLabs).
- **docs**: Documentation only changes.
- **perf**: A code change that improves performance.
- **refactor**: A code change that neither fixes a bug nor adds a feature.
- **style**: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc).
- **test**: Adding missing tests or correcting existing tests.
---
### Examples
**Commit with description only:**
```
fix: correct minor typos in code
```
**Commit with scope:**
```
feat(lang): add polish language
```
**Commit with body and breaking change footer:**
```
refactor: drop support for Node 6
The new implementation relies on async/await and other features
introduced in Node 8+.
BREAKING CHANGE: refactor to use JavaScript features not available in Node 6.
```
**Commit with scope, body, and issue footer:**
```
docs(readme): improve installation instructions
Provide clearer steps for setting up the development environment.
Add links to prerequisite tools.
Closes: #12
```
**Commit with `!` for breaking change:**
```
feat(api)!: send an email to the customer when a product is shipped
```

21
.github/copilot-instructions.md vendored Normal file
View File

@@ -0,0 +1,21 @@
# Mentor Instructions
## Introduction
You are Mentor, an AI assistant focused on ensuring code quality, strict adherence to best practices, and development efficiency. **Your core function is to enforce the coding standards and guidelines established in this workspace.** Your goal is to help me produce professional, maintainable, and high-performing code.
## Tone and Personality
Maintain a professional, objective, and direct tone consistently:
- **Guideline Enforcement & Error Correction:** When code deviates from guidelines or contains errors, provide precise, technical feedback. Clearly state the issue, cite the relevant guideline or principle, and explain the required correction for optimal, maintainable results.
- **Technical Consultation:** In discussions about architecture, best practices, or complex coding inquiries, remain formal and analytical. Provide clear, well-reasoned explanations and recommendations grounded in industry standards and the project's specific guidelines.
## Behavioral Guidelines
- **Actionable Feedback:** Prioritize constructive, actionable feedback aimed at improving code quality, maintainability, and adherence to standards. Avoid rewriting code; focus on explaining the necessary changes and their rationale based on guidelines.
- **Strict Guideline Adherence:** Base _all_ feedback, suggestions, and explanations rigorously on the guidelines documented within this workspace. Cite specific rules and principles consistently.
- **Demand Clarity:** If a query or code snippet lacks sufficient detail for a thorough, professional analysis, request clarification.
- **Professional Framing:** Frame all feedback objectively, focusing on the technical aspects and the importance of meeting project standards for long-term success.
- **Context-Specific Expertise:** Provide specific, context-aware advice tailored to the code or problem, always within the framework of our established guidelines.
- **Enforce Standards:** Actively enforce project preferences for Type safety, Clean Code principles, and thorough documentation, as mandated by the workspace guidelines.

32
.github/instructions/nx.instructions.md vendored Normal file
View File

@@ -0,0 +1,32 @@
---
applyTo: '**'
---
// This file is automatically generated by Nx Console
You are in an nx workspace using Nx 20.4.6 and npm as the package manager.
You have access to the Nx MCP server and the tools it provides. Use them. Follow these guidelines in order to best help the user:
# General Guidelines
- When answering questions, use the nx_workspace tool first to gain an understanding of the workspace architecture
- For questions around nx configuration, best practices or if you're unsure, use the nx_docs tool to get relevant, up-to-date docs!! Always use this instead of assuming things about nx configuration
- If the user needs help with an Nx configuration or project graph error, use the 'nx_workspace' tool to get any errors
- To help answer questions about the workspace structure or simply help with demonstrating how tasks depend on each other, use the 'nx_visualize_graph' tool
# Generation Guidelines
If the user wants to generate something, use the following flow:
- learn about the nx workspace and any specifics the user needs by using the 'nx_workspace' tool and the 'nx_project_details' tool if applicable
- get the available generators using the 'nx_generators' tool
- decide which generator to use. If no generators seem relevant, check the 'nx_available_plugins' tool to see if the user could install a plugin to help them
- get generator details using the 'nx_generator_schema' tool
- you may use the 'nx_docs' tool to learn more about a specific generator or technology if you're unsure
- decide which options to provide in order to best complete the user's request. Don't make any assumptions and keep the options minimalistic
- open the generator UI using the 'nx_open_generate_ui' tool
- wait for the user to finish the generator
- read the generator log file using the 'nx_read_generator_log' tool
- use the information provided in the log file to answer the user's question or continue with what they were doing
undefined

182
.github/review-instructions.md vendored Normal file
View File

@@ -0,0 +1,182 @@
# Code Review Instructions
## Summary
When conducting a code review, follow these steps to ensure a thorough and constructive process.
**Ensure that all review guidelines are followed. If any guideline is not adhered to, make it explicitly clear which guideline needs to be followed.**
## Review Process
1. 🎯 **Key Issues**
Identify critical issues in the code such as bugs, security vulnerabilities, or violations of the project's coding standards.
_Include specific links to files and line numbers (e.g., file.js#L10) where applicable._
2. 💡 **Suggestions for Improvement**
Highlight areas where the code can be enhanced in terms of readability, performance, maintainability, or adherence to best practices.
_Clarify what constitutes a "Critical" versus a "Minor" issue to avoid ambiguity._
3.**Code Examples**
Provide specific, concise code snippets that illustrate your suggestions.
_Include both a "Before" (problematic code) and an "After" (improved version) example where beneficial._
4. 📚 **Relevant Documentation Links**
Attach links to useful resources or official documentation to support the suggested changes.
_For example, link to ESLint, Jest, or Angular Style Guide pages when relevant._
## Tone and Feedback
- Be constructive and supportive.
Frame suggestions as opportunities for growth rather than criticism.
- Use the following emojis to categorize your feedback:
- 🚨 **Critical issues**
-**Minor Issues**
- ⚠️ **Warnings**
- 💡 **Suggestions**
-**Good practices**
## Additional Informations
- Missing tests and JSDocs are minor issues
- Missing unit test are minor issues
- Missing End-to-End (E2E) Testing Attributes (`data-what`, `data-which`) are warnings
### Review Template
````markdown
# Code Review
## Summary
A brief overview of the codes overall quality, highlighting key strengths and areas needing attention. This sets the stage for the detailed feedback below.
---
## 🚨 Critical Issues
High-priority issues that must be addressed immediately due to their potential to severely impact functionality, performance, or security.
### 1. High Priority: [Issue Title]
#### 🚨 Issue
Describe the issue clearly, including links to specific files and lines (e.g., file.js#L10). Explain why its critical—highlight crashes, security risks, or significant performance issues.
#### 💡 Suggestions for Improvement
Provide specific steps or alternative approaches to resolve the issue.
#### ✨ Code Example
**Current**: [file](file.js#L10) Problematic code with path to the file and line of the code
```typescript
// Code...
```
**Improvement**: Improved version
```typescript
// Code...
```
#### 📚 Relevant Documentation
Include URLs for further research (e.g., [Jest Documentation](https://jestjs.io/docs/getting-started)).
---
## ❗ Minor Issues
Issues that can improve code quality, maintainability, or adherence to best practices when resolved.
### 1. Medium Priority: [Issue Title]
#### ❗ Issue
Describe the issue clearly, including file and line references (e.g., file.js#L10). Explain the impact on the project.
#### 💡 Suggestions for Improvement
Offer concrete steps or alternative approaches to mitigate the issue.
#### ✨ Code Example
**Current**: [file](file.js#L10) Problematic code with path to the file and line of the code
```typescript
// Code...
```
**Improvement**: Improved version
```typescript
// Code...
```
#### 📚 Relevant Documentation
Provide links to further resources.
---
## ⚠️ Warnings
Low-priority issues or suggestions that could help prevent future problems or improve the code quality over time.
### 1. Low Priority: [Issue Title]
#### ⚠️ Issue
Describe the issue clearly with references (e.g., file.js#L10). Explain the potential impact if left unaddressed.
#### 💡 Suggestions for Improvement
Provide suggestions or alternative implementations to mitigate the issue.
#### ✨ Code Example
**Current**: [file](file.js#L10) Problematic code with path to the file and line of the code
```typescript
// Code...
```
**Improvement**: Improved version
```typescript
// Code...
```
#### 📚 Relevant Documentation
Include relevant resources for more information.
---
## 🛑 Bad Practices
Highlight up to five bad aspects of the code to reinforce improvements and encourage good practices. Use different funny emoji at the beginning of each bad practice.
- Emoji **Bad Practice 1**:
Describe a specific weakness (e.g., clear code structure) with an example reference (e.g., file.js#L20). Explain why its bad.
- Emoji **Bad Practice 2**:
Outline another negative feature (e.g., effective error handling) with a snippet reference.
---
## ✅ Good Practices
Highlight up to five positive aspects of the code to reinforce well-implemented patterns and encourage good practices. Use different funny emoji at the beginning of each good practice.
- Emoji **Good Practice 1**:
Describe a specific strength (e.g., clear code structure) with an example reference (e.g., file.js#L20). Explain why its commendable.
- Emoji **Good Practice 2**:
Outline another positive feature (e.g., effective error handling) with a snippet reference.
---
## 📓 Additional Notes
- **General Feedback**: Optional thoughts regarding the overall quality or potential areas for future improvement.
- **Next Steps**: Outline follow-up actions or further examination areas as needed.
````

66
.github/testing-instructions.md vendored Normal file
View File

@@ -0,0 +1,66 @@
# Testing Instructions
## Framework and Tools
- Use **Jest** as the testing framework.
- For unit tests, utilize **Spectator** to simplify Angular component testing.
## Guidelines
1. **Error Case Testing**: Ensure all edge cases and error scenarios are thoroughly tested.
2. **Arrange-Act-Assert Pattern**: Follow the Arrange-Act-Assert pattern for structuring your tests:
- **Arrange**: Set up the testing environment and initialize required variables.
- **Act**: Execute the functionality being tested.
- **Assert**: Verify the expected outcomes.
## Best Practices
- Write clear and descriptive test names.
- Ensure tests are isolated and do not depend on each other.
- Mock external dependencies to avoid side effects.
- Aim for high code coverage without compromising test quality.
## Example Test Structure
```typescript
// Example using Jest and Spectator
import { createComponentFactory, Spectator } from '@ngneat/spectator';
import { MyComponent } from './my-component.component';
describe('MyComponent', () => {
let spectator: Spectator<MyComponent>;
const createComponent = createComponentFactory(MyComponent);
beforeEach(() => {
spectator = createComponent();
});
it('should display the correct title', () => {
// Arrange
const expectedTitle = 'Hello World';
// Act
spectator.component.title = expectedTitle;
spectator.detectChanges();
// Assert
expect(spectator.query('h1')).toHaveText(expectedTitle);
});
it('should handle error cases gracefully', () => {
// Arrange
const invalidInput = null;
// Act
spectator.component.input = invalidInput;
// Assert
expect(() => spectator.component.processInput()).toThrowError('Invalid input');
});
});
```
## Additional Resources
- [Jest Documentation](https://jestjs.io/docs/getting-started)
- [Spectator Documentation](https://ngneat.github.io/spectator/)

16
.gitignore vendored
View File

@@ -1,5 +1,8 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.
.matomo
junit.xml
# compiled output
/dist
/tmp
@@ -50,4 +53,15 @@ testem.log
Thumbs.db
libs/swagger/src/lib/*
*storybook.log
*storybook.log
.nx/cache
.nx/workspace-data
.angular
storybook-static
.cursor\rules\nx-rules.mdc
.github\instructions\nx.instructions.md

View File

@@ -1 +1 @@
npm run pretty-quick
npx lint-staged

7
.lintstagedrc.json Normal file
View File

@@ -0,0 +1,7 @@
{
"*.ts": "npx eslint --fix --config eslint.config.mjs",
"*.tsx": "npx eslint --fix --config eslint.config.mjs",
"*.js": "npx eslint --fix --config eslint.config.mjs",
"*.jsx": "npx eslint --fix --config eslint.config.mjs",
"*.html": "npx eslint --fix --config eslint.config.mjs"
}

View File

@@ -1,10 +1,8 @@
# Add files here to ignore them from prettier formatting
/dist
/coverage
/helmvalues
/apps/swagger
/ng-swagger-gen
*.json
*.yml
/.nx/cache
/.nx/workspace-data
/node_modules
.angular
.vscode

View File

@@ -1,5 +0,0 @@
{
"singleQuote": true,
"printWidth": 140
}

View File

@@ -1,7 +1,10 @@
{
"recommendations": [
"johnpapa.angular2",
"esbenp.prettier-vscode",
"angular.ng-template",
]
}
"recommendations": [
"johnpapa.angular2",
"esbenp.prettier-vscode",
"angular.ng-template",
"nrwl.angular-console",
"dbaeumer.vscode-eslint",
"firsttris.vscode-jest-runner"
]
}

88
.vscode/settings.json vendored
View File

@@ -1,15 +1,93 @@
{
"editor.accessibilitySupport": "off",
"typescript.tsdk": "node_modules/typescript/lib",
"exportall.config.exclude": [".test.", ".spec.", ".stories."],
"editor.formatOnSave": true,
"typescriptHero.imports.insertSemicolons": false,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"[javascript]": {
"eslint.validate": [
"json"
],
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"css.validate": false,
"less.validate": false,
"scss.validate": false
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"exportall.config.folderListener": [
"/libs/oms/data-access/src/lib/models",
"/libs/oms/data-access/src/lib/schemas",
"/libs/catalogue/data-access/src/lib/models",
"/libs/common/data-access/src/lib/models",
"/libs/common/data-access/src/lib/error",
"/libs/oms/data-access/src/lib/errors/return-process"
],
"github.copilot.chat.commitMessageGeneration.instructions": [
{
"file": ".github/commit-instructions.md"
}
],
"github.copilot.chat.codeGeneration.instructions": [
{
"file": ".github/copilot-instructions.md"
},
{
"file": "docs/tech-stack.md"
},
{
"file": "docs/guidelines/code-style.md"
},
{
"file": "docs/guidelines/project-structure.md"
},
{
"file": "docs/guidelines/state-management.md"
},
{
"file": "docs/guidelines/testing.md"
}
],
"github.copilot.chat.testGeneration.instructions": [
{
"file": ".github/copilot-instructions.md"
},
{
"file": ".github/testing-instructions.md"
},
{
"file": "docs/tech-stack.md"
},
{
"file": "docs/guidelines/code-style.md"
},
{
"file": "docs/guidelines/testing.md"
}
],
"github.copilot.chat.reviewSelection.instructions": [
{
"file": ".github/copilot-instructions.md"
},
{
"file": ".github/review-instructions.md"
},
{
"file": "docs/tech-stack.md"
},
{
"file": "docs/guidelines/code-style.md"
},
{
"file": "docs/guidelines/project-structure.md"
},
{
"file": "docs/guidelines/state-management.md"
},
{
"file": "docs/guidelines/testing.md"
}
],
"nxConsole.generateAiAgentRules": true,
}

View File

@@ -1,5 +1,5 @@
#stage 1
FROM node:18 as base
FROM node:22 as base
ARG IS_PRODUCTION=false
ARG SEMVERSION=1.0.0
ARG BuildUniqueID
@@ -8,7 +8,7 @@ WORKDIR /app
COPY . .
RUN umask 0022
RUN npm version ${SEMVERSION}
RUN npm install --always-auth=false
RUN npm install --foreground-scripts
RUN if [ "${IS_PRODUCTION}" = "true" ] ; then npm run-script build-prod ; else npm run-script build ; fi
# stage final

View File

@@ -1,164 +0,0 @@
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"newProjectRoot": "apps",
"projects": {
"isa-app": {
"projectType": "application",
"schematics": {
"@schematics/angular:component": {
"style": "scss"
},
"@schematics/angular:application": {
"strict": true
}
},
"root": "apps/isa-app",
"sourceRoot": "apps/isa-app/src",
"prefix": "app",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"allowedCommonJsDependencies": [
"lodash",
"moment",
"jsrsasign",
"pdfjs-dist/build/pdf",
"pdfjs-dist/web/pdf_viewer",
"pdfjs-dist/es5/build/pdf",
"pdfjs-dist/es5/web/pdf_viewer"
],
"outputPath": "dist/isa-app",
"index": "apps/isa-app/src/index.html",
"main": "apps/isa-app/src/main.ts",
"polyfills": "apps/isa-app/src/polyfills.ts",
"tsConfig": "apps/isa-app/tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
"apps/isa-app/src/favicon.ico",
"apps/isa-app/src/assets",
"apps/isa-app/src/config",
"apps/isa-app/src/silent-refresh.html",
"apps/isa-app/src/manifest.webmanifest",
{
"glob": "**/*",
"input": "node_modules/scandit-web-datacapture-barcode/build/engine",
"output": "scandit"
}
],
"styles": [
"apps/isa-app/src/styles.scss"
],
"scripts": [],
"serviceWorker": true,
"ngswConfigPath": "apps/isa-app/ngsw-config.json"
},
"configurations": {
"production": {
"budgets": [
{
"type": "initial",
"maximumWarning": "2mb",
"maximumError": "5mb"
},
{
"type": "anyComponentStyle",
"maximumWarning": "25kb"
}
],
"fileReplacements": [
{
"replace": "apps/isa-app/src/environments/environment.ts",
"with": "apps/isa-app/src/environments/environment.prod.ts"
}
],
"outputHashing": "all"
},
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
}
},
"defaultConfiguration": "production"
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"buildTarget": "isa-app:build:production"
},
"development": {
"buildTarget": "isa-app:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"buildTarget": "isa-app:build"
}
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"tsConfig": "apps/isa-app/tsconfig.spec.json",
"karmaConfig": "karma.conf.js",
"polyfills": [
"zone.js",
"zone.js/testing"
],
"inlineStyleLanguage": "scss",
"assets": [
"apps/isa-app/src/favicon.ico",
"apps/isa-app/src/assets",
"apps/isa-app/src/manifest.webmanifest"
],
"styles": [
"apps/isa-app/src/styles.scss"
],
"scripts": []
}
},
"storybook": {
"builder": "@storybook/angular:start-storybook",
"options": {
"configDir": "apps/isa-app/.storybook",
"browserTarget": "isa-app:build",
"compodoc": true,
"compodocArgs": [
"-e",
"json",
"-d",
"apps/isa-app"
],
"port": 6006
}
},
"build-storybook": {
"builder": "@storybook/angular:build-storybook",
"options": {
"configDir": "apps/isa-app/.storybook",
"browserTarget": "isa-app:build",
"compodoc": true,
"compodocArgs": [
"-e",
"json",
"-d",
"apps/isa-app"
],
"outputDir": "storybook-static"
}
}
}
}
},
"cli": {
"analytics": false
}
}

View File

@@ -1,17 +1,21 @@
import type { StorybookConfig } from '@storybook/angular';
const config: StorybookConfig = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
'@storybook/addon-onboarding',
'@storybook/addon-links',
'@storybook/addon-essentials',
'@chromatic-com/storybook',
'@storybook/addon-interactions',
],
stories: ['../stories/**/*.@(mdx|stories.@(js|jsx|ts|tsx))'],
addons: ['@storybook/addon-essentials', '@storybook/addon-interactions'],
staticDirs: ['../src/assets'],
previewHead: (head) => `
${head}
<link href="/assets/fonts/fonts.css" rel="stylesheet" />
`,
framework: {
name: '@storybook/angular',
options: {},
},
};
export default config;
// To customize your webpack configuration you can use the webpackFinal field.
// Check https://storybook.js.org/docs/react/builders/webpack#extending-storybooks-webpack-config
// and https://nx.dev/recipes/storybook/custom-builder-configs

View File

@@ -1,17 +1,7 @@
import type { Preview } from '@storybook/angular';
import { setCompodocJson } from '@storybook/addon-docs/angular';
import docJson from '../documentation.json';
setCompodocJson(docJson);
const preview: Preview = {
parameters: {
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/i,
},
},
},
tags: ['autodocs'],
};
export default preview;

View File

@@ -1,10 +0,0 @@
// This tsconfig is used by Compodoc to generate the documentation for the project.
// If Compodoc is not used, this file can be deleted.
{
"extends": "./tsconfig.json",
// Exclude all files that are not needed for documentation generation.
"exclude": ["../src/test.ts", "../src/**/*.spec.ts", "../src/**/*.stories.ts"],
// Please make sure to include all files from which Compodoc should generate documentation.
"include": ["../src/**/*"],
"files": ["./typings.d.ts"]
}

View File

@@ -1,11 +1,21 @@
{
"extends": "../tsconfig.app.json",
"extends": "../tsconfig.json",
"compilerOptions": {
"types": ["node"],
"allowSyntheticDefaultImports": true,
"resolveJsonModule": true
"emitDecoratorMetadata": true
},
"exclude": ["../src/test.ts", "../src/**/*.spec.ts"],
"include": ["../src/**/*.stories.*", "./preview.ts", "../src/polyfills.ts"],
"files": ["./typings.d.ts"]
"exclude": ["../**/*.spec.ts"],
"include": [
// "../src/**/*.stories.ts",
// "../src/**/*.stories.js",
// "../src/**/*.stories.jsx",
// "../src/**/*.stories.tsx",
// "../src/**/*.stories.mdx",
"../stories/**/*.stories.ts",
"../stories/**/*.stories.js",
"../stories/**/*.stories.jsx",
"../stories/**/*.stories.tsx",
"../stories/**/*.stories.mdx",
"*.js",
"*.ts"
]
}

View File

@@ -1,4 +0,0 @@
declare module '*.md' {
const content: string;
export default content;
}

View File

@@ -0,0 +1,55 @@
import nx from '@nx/eslint-plugin';
import baseConfig from '../../eslint.config.mjs';
export default [
...baseConfig,
...nx.configs['flat/angular'],
...nx.configs['flat/angular-template'],
{
files: ['**/*.ts'],
rules: {
'@angular-eslint/directive-selector': [
'error',
{
type: 'attribute',
prefix: 'app',
style: 'camelCase',
},
],
'@angular-eslint/component-selector': [
'error',
{
type: 'element',
prefix: 'app',
style: 'kebab-case',
},
],
},
},
{
files: ['**/*.ts'],
rules: {
'@typescript-eslint/no-unused-expressions': 'warn',
'prefer-const': 'warn',
'@angular-eslint/contextual-lifecycle': 'warn',
'@typescript-eslint/no-explicit-any': 'warn',
'@angular-eslint/no-empty-lifecycle-method': 'warn',
'@typescript-eslint/no-inferrable-types': 'warn',
'@angular-eslint/component-selector': 'warn',
'@angular-eslint/prefer-standalone': 'warn',
'@typescript-eslint/no-inferrable-types': 'warn',
'no-empty-function': 'warn',
'@typescript-eslint/no-empty-function': 'warn',
'@typescript-eslint/no-unused-vars': 'warn',
'@angular-eslint/directive-selector': 'warn',
},
},
{
files: ['**/*.html'],
// Override or add rules here
rules: {
'@angular-eslint/template/elements-content': 'warn',
'@angular-eslint/template/no-autofocus': 'warn',
},
},
];

View File

@@ -0,0 +1,21 @@
export default {
displayName: 'isa-app',
preset: '../../jest.preset.js',
setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'],
coverageDirectory: '../../coverage/apps/prj',
transform: {
'^.+\\.(ts|mjs|js|html)$': [
'jest-preset-angular',
{
tsconfig: '<rootDir>/tsconfig.spec.json',
stringifyContentPathRegex: '\\.(html|svg)$',
},
],
},
transformIgnorePatterns: ['node_modules/(?!.*\\.mjs$)'],
snapshotSerializers: [
'jest-preset-angular/build/serializers/no-ng-attributes',
'jest-preset-angular/build/serializers/ng-snapshot',
'jest-preset-angular/build/serializers/html-comment',
],
};

View File

@@ -29,4 +29,4 @@
}
}
]
}
}

164
apps/isa-app/project.json Normal file
View File

@@ -0,0 +1,164 @@
{
"name": "isa-app",
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"projectType": "application",
"prefix": "app",
"sourceRoot": "apps/isa-app/src",
"tags": [],
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:application",
"options": {
"allowedCommonJsDependencies": [
"lodash",
"moment",
"jsrsasign",
"pdfjs-dist/build/pdf",
"pdfjs-dist/web/pdf_viewer",
"pdfjs-dist/es5/build/pdf",
"pdfjs-dist/es5/web/pdf_viewer"
],
"outputPath": "dist/isa-app",
"index": "apps/isa-app/src/index.html",
"browser": "apps/isa-app/src/main.ts",
"polyfills": ["zone.js"],
"tsConfig": "apps/isa-app/tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
"apps/isa-app/src/favicon.ico",
"apps/isa-app/src/assets",
"apps/isa-app/src/config",
"apps/isa-app/src/silent-refresh.html",
"apps/isa-app/src/manifest.webmanifest",
{
"glob": "**/*",
"input": "node_modules/scandit-web-datacapture-barcode/build/engine",
"output": "scandit"
}
],
"styles": [
"@angular/cdk/overlay-prebuilt.css",
"apps/isa-app/src/ui.scss",
"apps/isa-app/src/styles.scss"
],
"scripts": []
},
"configurations": {
"production": {
"budgets": [
{
"type": "initial",
"maximumWarning": "2mb",
"maximumError": "5mb"
},
{
"type": "anyComponentStyle",
"maximumWarning": "25kb"
}
],
"fileReplacements": [
{
"replace": "apps/isa-app/src/environments/environment.ts",
"with": "apps/isa-app/src/environments/environment.prod.ts"
}
],
"outputHashing": "all",
"serviceWorker": "apps/isa-app/ngsw-config.json"
},
"development": {
"optimization": false,
"extractLicenses": false,
"sourceMap": true
}
},
"defaultConfiguration": "production",
"outputs": ["{options.outputPath}"]
},
"serve": {
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"buildTarget": "isa-app:build:production"
},
"development": {
"buildTarget": "isa-app:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
"buildTarget": "isa-app:build"
}
},
"lint": {
"executor": "@nx/eslint:lint"
},
"test": {
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
"jestConfig": "apps/isa-app/jest.config.ts"
}
},
"serve-static": {
"executor": "@nx/web:file-server",
"options": {
"buildTarget": "isa-app:build",
"staticFilePath": "dist/apps/isa-app/browser",
"spa": true
}
},
"storybook": {
"executor": "@storybook/angular:start-storybook",
"options": {
"port": 4400,
"configDir": "apps/isa-app/.storybook",
"browserTarget": "isa-app:build",
"compodoc": false,
"styles": ["apps/isa-app/src/ui.scss", "apps/isa-app/src/styles.scss"]
},
"configurations": {
"ci": {
"quiet": true
}
}
},
"build-storybook": {
"executor": "@storybook/angular:build-storybook",
"outputs": ["{options.outputDir}"],
"options": {
"outputDir": "dist/storybook/isa-app",
"configDir": "apps/isa-app/.storybook",
"browserTarget": "isa-app:build",
"compodoc": false
},
"configurations": {
"ci": {
"quiet": true
}
}
},
"test-storybook": {
"executor": "nx:run-commands",
"options": {
"command": "test-storybook -c apps/isa-app/.storybook --url=http://localhost:4400"
}
},
"static-storybook": {
"executor": "@nx/web:file-server",
"dependsOn": ["build-storybook"],
"options": {
"buildTarget": "isa-app:build-storybook",
"staticFilePath": "dist/storybook/isa-app",
"spa": true
},
"configurations": {
"ci": {
"buildTarget": "isa-app:build-storybook:ci"
}
}
}
}
}

View File

@@ -1,8 +1,9 @@
import { inject, Injectable } from '@angular/core';
import { EnvironmentService } from '@core/environment';
import { PromptModalData, UiModalService, UiPromptModalComponent } from '@ui/modal';
import { Observable } from 'rxjs';
import { ScanAdapter } from './scan-adapter';
import { Config } from '@core/config';
import { coerceBooleanProperty } from '@angular/cdk/coercion';
@Injectable()
export class DevScanAdapter implements ScanAdapter {
@@ -10,11 +11,12 @@ export class DevScanAdapter implements ScanAdapter {
private _modal = inject(UiModalService);
private _config = inject(Config);
async init(): Promise<boolean> {
return Promise.resolve(false);
// return new Promise((resolve, reject) => {
// resolve(isDevMode());
// });
return new Promise((resolve, reject) => {
resolve(coerceBooleanProperty(this._config.get('dev-scanner')));
});
}
scan(): Observable<string> {

View File

@@ -37,7 +37,7 @@ export class ScanAdapterService {
for (const name of adapterOrder) {
adapter = this.getAdapter(name);
console.log('adapter', adapter);
if (adapter) {
break;
}

View File

@@ -1,4 +1,12 @@
import { Component, ChangeDetectionStrategy, ElementRef, ViewChild, NgZone, AfterViewInit, OnDestroy, OnInit } from '@angular/core';
import {
Component,
ChangeDetectionStrategy,
ElementRef,
ViewChild,
NgZone,
AfterViewInit,
OnDestroy, OnInit,
} from '@angular/core';
import { BarcodeCapture, BarcodeCaptureSettings, Symbology } from 'scandit-web-datacapture-barcode';
import { Camera, DataCaptureContext, DataCaptureView, FrameSourceState } from 'scandit-web-datacapture-core';
@@ -7,8 +15,9 @@ import { Camera, DataCaptureContext, DataCaptureView, FrameSourceState } from 's
templateUrl: 'scandit-overlay.component.html',
styleUrls: ['scandit-overlay.component.css'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class ScanditOverlayComponent implements OnInit, AfterViewInit, OnDestroy {
export class ScanditOverlayComponent implements AfterViewInit, OnDestroy, OnInit {
private dataCaptureContext: DataCaptureContext;
private dataCaptureView: DataCaptureView;
private barcodeCapture: BarcodeCapture;

View File

@@ -21,9 +21,16 @@ import { PreviewComponent } from './preview';
import { BranchSectionResolver, CustomerSectionResolver, ProcessIdResolver } from './resolvers';
import { TokenLoginComponent, TokenLoginModule } from './token-login';
import { ProcessIdGuard } from './guards/process-id.guard';
import { ActivateProcessIdGuard, ActivateProcessIdWithConfigKeyGuard } from './guards/activate-process-id.guard';
import {
ActivateProcessIdGuard,
ActivateProcessIdWithConfigKeyGuard,
} from './guards/activate-process-id.guard';
import { MatomoRouteData } from 'ngx-matomo-client';
import { processResolverFn } from '@isa/core/process';
import { provideScrollPositionRestoration } from '@isa/utils/scroll-position';
const routes: Routes = [
{ path: '', redirectTo: 'kunde/dashboard', pathMatch: 'full' },
{
path: 'login',
children: [
@@ -42,6 +49,11 @@ const routes: Routes = [
{
path: 'dashboard',
loadChildren: () => import('@page/dashboard').then((m) => m.DashboardModule),
data: {
matomo: {
title: 'Dashboard',
} as MatomoRouteData,
},
},
{
path: 'product',
@@ -128,7 +140,8 @@ const routes: Routes = [
},
{
path: 'package-inspection',
loadChildren: () => import('@page/package-inspection').then((m) => m.PackageInspectionModule),
loadChildren: () =>
import('@page/package-inspection').then((m) => m.PackageInspectionModule),
canActivate: [CanActivatePackageInspectionGuard],
},
{
@@ -140,7 +153,18 @@ const routes: Routes = [
],
resolve: { section: BranchSectionResolver },
},
{ path: '**', redirectTo: 'kunde', pathMatch: 'full' },
],
},
{
path: ':processId',
component: MainComponent,
resolve: { process: processResolverFn },
canActivate: [IsAuthenticatedGuard],
children: [
{
path: 'return',
loadChildren: () => import('@isa/oms/feature/return-search').then((m) => m.routes),
},
],
},
];
@@ -155,5 +179,6 @@ if (isDevMode()) {
@NgModule({
imports: [RouterModule.forRoot(routes), TokenLoginModule],
exports: [RouterModule],
providers: [provideScrollPositionRestoration()],
})
export class AppRoutingModule {}

View File

@@ -2,7 +2,6 @@ import { NgModule } from '@angular/core';
import { EffectsModule } from '@ngrx/effects';
import { ActionReducer, MetaReducer, StoreModule } from '@ngrx/store';
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
import { storeFreeze } from 'ngrx-store-freeze';
import packageInfo from 'packageJson';
import { environment } from '../environments/environment';
import { RootStateService } from './store/root-state.service';
@@ -22,7 +21,9 @@ export function storeInLocalStorage(reducer: ActionReducer<any>): ActionReducer<
};
}
export const metaReducers: MetaReducer<RootState>[] = !environment.production ? [storeFreeze, storeInLocalStorage] : [storeInLocalStorage];
export const metaReducers: MetaReducer<RootState>[] = !environment.production
? [storeInLocalStorage]
: [storeInLocalStorage];
@NgModule({
imports: [

View File

@@ -1,15 +1,16 @@
import { HttpInterceptorFn, provideHttpClient, withInterceptors } from '@angular/common/http';
import { NgModule } from '@angular/core';
import { Config } from '@core/config';
import { AvConfiguration } from '@swagger/availability';
import { CatConfiguration } from '@swagger/cat';
import { CheckoutConfiguration } from '@swagger/checkout';
import { CrmConfiguration } from '@swagger/crm';
import { EisConfiguration } from '@swagger/eis';
import { IsaConfiguration } from '@swagger/isa';
import { OmsConfiguration } from '@swagger/oms';
import { PrintConfiguration } from '@swagger/print';
import { RemiConfiguration } from '@swagger/remi';
import { WwsConfiguration } from '@swagger/wws';
import { AvConfiguration } from '@generated/swagger/availability-api';
import { CatConfiguration } from '@generated/swagger/cat-search-api';
import { CheckoutConfiguration } from '@generated/swagger/checkout-api';
import { CrmConfiguration } from '@generated/swagger/crm-api';
import { EisConfiguration } from '@generated/swagger/eis-api';
import { IsaConfiguration } from '@generated/swagger/isa-api';
import { OmsConfiguration } from '@generated/swagger/oms-api';
import { PrintConfiguration } from '@generated/swagger/print-api';
import { RemiConfiguration } from '@generated/swagger/inventory-api';
import { WwsConfiguration } from '@generated/swagger/wws-api';
export function createConfigurationFactory(name: string) {
return function (config: Config): { rootUrl: string } {
@@ -17,8 +18,13 @@ export function createConfigurationFactory(name: string) {
};
}
const serviceWorkerInterceptor: HttpInterceptorFn = (req, next) => {
return next(req.clone({ setHeaders: { 'ngsw-bypass': 'true' } }));
};
@NgModule({
providers: [
provideHttpClient(withInterceptors([serviceWorkerInterceptor])),
{ provide: AvConfiguration, useFactory: createConfigurationFactory('av'), deps: [Config] },
{ provide: CatConfiguration, useFactory: createConfigurationFactory('cat'), deps: [Config] },
{ provide: CheckoutConfiguration, useFactory: createConfigurationFactory('checkout'), deps: [Config] },

View File

@@ -8,7 +8,7 @@ import { Renderer2 } from '@angular/core';
import { CommonModule } from '@angular/common';
import { SwUpdate } from '@angular/service-worker';
import { NotificationsHub } from '@hub/notifications';
import { UserStateService } from '@swagger/isa';
import { UserStateService } from '@generated/swagger/isa-api';
import { UiModalService } from '@ui/modal';
import { AuthService } from '@core/auth';

View File

@@ -1,5 +1,16 @@
import { DOCUMENT } from '@angular/common';
import { Component, effect, HostListener, Inject, OnInit, Renderer2, signal, untracked } from '@angular/core';
import {
Component,
effect,
HostListener,
inject,
Inject,
Injector,
OnInit,
Renderer2,
signal,
untracked,
} from '@angular/core';
import { Title } from '@angular/platform-browser';
import { SwUpdate } from '@angular/service-worker';
import { ApplicationService } from '@core/application';
@@ -7,10 +18,10 @@ import { Config } from '@core/config';
import { NotificationsHub } from '@hub/notifications';
import packageInfo from 'packageJson';
import { asapScheduler, interval, Subscription } from 'rxjs';
import { UserStateService } from '@swagger/isa';
import { UserStateService } from '@generated/swagger/isa-api';
import { IsaLogProvider } from './providers';
import { EnvironmentService } from '@core/environment';
import { AuthService } from '@core/auth';
import { AuthService, LoginStrategy } from '@core/auth';
import { UiMessageModalComponent, UiModalService } from '@ui/modal';
import { injectOnline$ } from './services/network-status.service';
import { toSignal } from '@angular/core/rxjs-interop';
@@ -33,8 +44,11 @@ import { animate, style, transition, trigger } from '@angular/animations';
]),
]),
],
standalone: false,
})
export class AppComponent implements OnInit {
readonly injector = inject(Injector);
$online = toSignal(injectOnline$());
$offlineBannerVisible = signal(false);
@@ -118,7 +132,10 @@ export class AppComponent implements OnInit {
}
logVersion() {
console.log(`%c${this._config.get('title')}\r\nVersion: ${packageInfo.version}`, 'font-weight: bold; font-size: 20px;');
console.log(
`%c${this._config.get('title')}\r\nVersion: ${packageInfo.version}`,
'font-weight: bold; font-size: 20px;',
);
}
determinePlatform() {
@@ -180,15 +197,9 @@ export class AppComponent implements OnInit {
if (this._document.hidden && this._authService.isAuthenticated()) {
this._authService.refresh();
} else if (!this._authService.isAuthenticated()) {
return this._modal
.open({
content: UiMessageModalComponent,
title: 'Sie sind nicht mehr angemeldet',
data: { message: 'Sie werden neu angemeldet' },
})
.afterClosed$.subscribe(() => {
this._authService.login();
});
const strategy = this.injector.get(LoginStrategy);
return strategy.login('Sie sind nicht mehr angemeldet');
}
}
}

View File

@@ -1,11 +1,22 @@
import { HTTP_INTERCEPTORS, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
import { APP_INITIALIZER, ErrorHandler, Injector, LOCALE_ID, NgModule } from '@angular/core';
import {
HTTP_INTERCEPTORS,
provideHttpClient,
withInterceptorsFromDi,
} from '@angular/common/http';
import {
ErrorHandler,
Injector,
LOCALE_ID,
NgModule,
inject,
provideAppInitializer,
} from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { PlatformModule } from '@angular/cdk/platform';
import { Config, ConfigModule, JsonConfigLoader } from '@core/config';
import { AuthModule, AuthService } from '@core/auth';
import { Config } from '@core/config';
import { AuthModule, AuthService, LoginStrategy } from '@core/auth';
import { CoreCommandModule } from '@core/command';
import { AppRoutingModule } from './app-routing.module';
@@ -17,7 +28,10 @@ import { environment } from '../environments/environment';
import { AppSwaggerModule } from './app-swagger.module';
import { AppDomainModule } from './app-domain.module';
import { UiModalModule } from '@ui/modal';
import { NotificationsHubModule, NOTIFICATIONS_HUB_OPTIONS } from '@hub/notifications';
import {
NotificationsHubModule,
NOTIFICATIONS_HUB_OPTIONS,
} from '@hub/notifications';
import { SignalRHubOptions } from '@core/signalr';
import { CoreBreadcrumbModule } from '@core/breadcrumb';
import { UiCommonModule } from '@ui/common';
@@ -29,7 +43,11 @@ import { HttpErrorInterceptor } from './interceptors';
import { CoreLoggerModule, LOG_PROVIDER } from '@core/logger';
import { IsaLogProvider } from './providers';
import { IsaErrorHandler } from './providers/isa.error-handler';
import { ScanAdapterModule, ScanAdapterService, ScanditScanAdapterModule } from '@adapter/scan';
import {
ScanAdapterModule,
ScanAdapterService,
ScanditScanAdapterModule,
} from '@adapter/scan';
import { RootStateService } from './store/root-state.service';
import * as Commands from './commands';
import { PreviewComponent } from './preview';
@@ -38,28 +56,34 @@ import { ShellModule } from '@shared/shell';
import { MainComponent } from './main.component';
import { IconModule } from '@shared/components/icon';
import { NgIconsModule } from '@ng-icons/core';
import { matClose, matWifi, matWifiOff } from '@ng-icons/material-icons/baseline';
import {
matClose,
matWifi,
matWifiOff,
} from '@ng-icons/material-icons/baseline';
import { NetworkStatusService } from './services/network-status.service';
import { firstValueFrom } from 'rxjs';
import { provideMatomo } from 'ngx-matomo-client';
import { withRouter, withRouteData } from 'ngx-matomo-client';
import {
provideLogging,
withLogLevel,
LogLevel,
withSink,
ConsoleLogSink,
} from '@isa/core/logging';
registerLocaleData(localeDe, localeDeExtra);
registerLocaleData(localeDe, 'de', localeDeExtra);
export function _appInitializerFactory(
config: Config,
auth: AuthService,
injector: Injector,
scanAdapter: ScanAdapterService,
nativeContainer: NativeContainerService,
networkStatus: NetworkStatusService,
) {
export function _appInitializerFactory(config: Config, injector: Injector) {
return async () => {
const statusElement = document.querySelector('#init-status');
const laoderElement = document.querySelector('#init-loader');
try {
let online = false;
const networkStatus = injector.get(NetworkStatusService);
while (!online) {
online = await firstValueFrom(networkStatus.online$);
@@ -71,20 +95,29 @@ export function _appInitializerFactory(
}
statusElement.innerHTML = 'Konfigurationen werden geladen...';
await config.init();
statusElement.innerHTML = 'Authentifizierung wird geprüft...';
await auth.init();
if (auth.isAuthenticated()) {
statusElement.innerHTML = 'App wird initialisiert...';
const state = injector.get(RootStateService);
await state.init();
statusElement.innerHTML = 'Scanner wird initialisiert...';
const scanAdapter = injector.get(ScanAdapterService);
await scanAdapter.init();
statusElement.innerHTML = 'Authentifizierung wird geprüft...';
const auth = injector.get(AuthService);
try {
await auth.init();
} catch (error) {
statusElement.innerHTML = 'Authentifizierung wird durchgeführt...';
const strategy = injector.get(LoginStrategy);
await strategy.login();
}
statusElement.innerHTML = 'App wird initialisiert...';
const state = injector.get(RootStateService);
await state.init();
statusElement.innerHTML = 'Native Container wird initialisiert...';
const nativeContainer = injector.get(NativeContainerService);
await nativeContainer.init();
statusElement.innerHTML = 'Scanner wird initialisiert...';
await scanAdapter.init();
} catch (error) {
laoderElement.remove();
statusElement.classList.add('text-xl');
@@ -92,7 +125,13 @@ export function _appInitializerFactory(
'⚡<br><br><b>Fehler bei der Initialisierung</b><br><br>Bitte prüfen Sie die Netzwerkverbindung (WLAN).<br><br>';
const reload = document.createElement('button');
reload.classList.add('bg-brand', 'text-white', 'p-2', 'rounded', 'cursor-pointer');
reload.classList.add(
'bg-brand',
'text-white',
'p-2',
'rounded',
'cursor-pointer',
);
reload.innerHTML = 'App neu laden';
reload.onclick = () => window.location.reload();
statusElement.appendChild(reload);
@@ -115,7 +154,10 @@ export function _appInitializerFactory(
};
}
export function _notificationsHubOptionsFactory(config: Config, auth: AuthService): SignalRHubOptions {
export function _notificationsHubOptionsFactory(
config: Config,
auth: AuthService,
): SignalRHubOptions {
const options = { ...config.get('hubs').notifications };
options.httpOptions.accessTokenFactory = () => auth.getToken();
return options;
@@ -132,10 +174,6 @@ export function _notificationsHubOptionsFactory(config: Config, auth: AuthServic
AppSwaggerModule,
AppDomainModule,
CoreBreadcrumbModule.forRoot(),
ConfigModule.forRoot({
useConfigLoader: JsonConfigLoader,
jsonConfigLoaderUrl: '/config/config.json',
}),
CoreCommandModule.forRoot(Object.values(Commands)),
CoreLoggerModule.forRoot(),
AppStoreModule,
@@ -156,12 +194,13 @@ export function _notificationsHubOptionsFactory(config: Config, auth: AuthServic
NgIconsModule.withIcons({ matWifiOff, matClose, matWifi }),
],
providers: [
{
provide: APP_INITIALIZER,
useFactory: _appInitializerFactory,
multi: true,
deps: [Config, AuthService, Injector, ScanAdapterService, NativeContainerService, NetworkStatusService],
},
provideAppInitializer(() => {
const initializerFn = _appInitializerFactory(
inject(Config),
inject(Injector),
);
return initializerFn();
}),
{
provide: NOTIFICATIONS_HUB_OPTIONS,
useFactory: _notificationsHubOptionsFactory,
@@ -183,6 +222,12 @@ export function _notificationsHubOptionsFactory(config: Config, auth: AuthServic
},
{ provide: LOCALE_ID, useValue: 'de-DE' },
provideHttpClient(withInterceptorsFromDi()),
provideMatomo(
{ trackerUrl: 'https://matomo.paragon-data.net', siteId: '1' },
withRouter(),
withRouteData(),
),
provideLogging(withLogLevel(LogLevel.Debug), withSink(ConsoleLogSink)),
],
})
export class AppModule {}

View File

@@ -3,11 +3,14 @@ import { Router } from '@angular/router';
import { ApplicationService } from '@core/application';
import { ActionHandler } from '@core/command';
import { Result } from '@domain/defs';
import { CustomerInfoDTO } from '@swagger/crm';
import { CustomerInfoDTO } from '@generated/swagger/crm-api';
@Injectable()
export class CreateCustomerCommand extends ActionHandler<Result<CustomerInfoDTO[]>> {
constructor(private _router: Router, private _application: ApplicationService) {
constructor(
private _router: Router,
private _application: ApplicationService,
) {
super('CREATE_CUSTOMER');
}

View File

@@ -4,7 +4,7 @@ import { ApplicationService } from '@core/application';
import { ActionHandler } from '@core/command';
import { Result } from '@domain/defs';
import { encodeFormData, mapCustomerInfoDtoToCustomerCreateFormData } from '@page/customer';
import { CustomerInfoDTO } from '@swagger/crm';
import { CustomerInfoDTO } from '@generated/swagger/crm-api';
@Injectable()
export class CreateKubiCustomerCommand extends ActionHandler<Result<CustomerInfoDTO[]>> {
@@ -40,9 +40,12 @@ export class CreateKubiCustomerCommand extends ActionHandler<Result<CustomerInfo
customerType = 'store';
}
await this._router.navigate(['/kunde', this._application.activatedProcessId, 'customer', 'create', `${customerType}-p4m`], {
queryParams: { formData },
});
await this._router.navigate(
['/kunde', this._application.activatedProcessId, 'customer', 'create', `${customerType}-p4m`],
{
queryParams: { formData },
},
);
return data;
}
}

View File

@@ -3,12 +3,15 @@ import { ActionHandler } from '@core/command';
import { Result } from '@domain/defs';
import { DomainPrinterService } from '@domain/printer';
import { PrintModalComponent, PrintModalData } from '@modal/printer';
import { CustomerInfoDTO } from '@swagger/crm';
import { CustomerInfoDTO } from '@generated/swagger/crm-api';
import { UiModalService } from '@ui/modal';
@Injectable()
export class PrintKubiCustomerCommand extends ActionHandler<Result<CustomerInfoDTO[]>> {
constructor(private _uiModal: UiModalService, private _printerService: DomainPrinterService) {
constructor(
private _uiModal: UiModalService,
private _printerService: DomainPrinterService,
) {
super('PRINT_KUBI_AGB');
}

View File

@@ -4,7 +4,10 @@ import { ApplicationService } from '@core/application';
import { Config } from '@core/config';
import { take } from 'rxjs/operators';
export const ActivateProcessIdGuard: CanActivateFn = async (route: ActivatedRouteSnapshot, state: RouterStateSnapshot) => {
export const ActivateProcessIdGuard: CanActivateFn = async (
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot,
) => {
const application = inject(ApplicationService);
const processIdStr = route.params.processId;
@@ -27,20 +30,18 @@ export const ActivateProcessIdGuard: CanActivateFn = async (route: ActivatedRout
return true;
};
export const ActivateProcessIdWithConfigKeyGuard: (key: string) => CanActivateFn = (key) => async (
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot
) => {
const application = inject(ApplicationService);
const config = inject(Config);
export const ActivateProcessIdWithConfigKeyGuard: (key: string) => CanActivateFn =
(key) => async (route: ActivatedRouteSnapshot, state: RouterStateSnapshot) => {
const application = inject(ApplicationService);
const config = inject(Config);
const processId = config.get(`process.ids.${key}`);
const processId = config.get(`process.ids.${key}`);
if (isNaN(processId)) {
return false;
}
if (isNaN(processId)) {
return false;
}
application.activateProcess(processId);
application.activateProcess(processId);
return true;
};
return true;
};

View File

@@ -6,10 +6,16 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateAssortmentGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _config: Config) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _config: Config,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService.getProcessById$(this._config.get('process.ids.assortment')).pipe(first()).toPromise();
const process = await this._applicationService
.getProcessById$(this._config.get('process.ids.assortment'))
.pipe(first())
.toPromise();
if (!process) {
await this._applicationService.createProcess({
id: this._config.get('process.ids.assortment'),

View File

@@ -8,10 +8,7 @@ export class CanActivateCartWithProcessIdGuard {
constructor(private readonly _applicationService: ApplicationService) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService
.getProcessById$(+route.params.processId)
.pipe(first())
.toPromise();
const process = await this._applicationService.getProcessById$(+route.params.processId).pipe(first()).toPromise();
// if (!(process?.type === 'cart')) {
// // TODO:

View File

@@ -14,7 +14,10 @@ export class CanActivateCartGuard {
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
let lastActivatedProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart')
.pipe(first())
.toPromise()
)?.id;
if (!lastActivatedProcessId) {
lastActivatedProcessId = Date.now();

View File

@@ -6,13 +6,13 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateCustomerOrdersWithProcessIdGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _breadcrumbService: BreadcrumbService) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _breadcrumbService: BreadcrumbService,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService
.getProcessById$(+route.params.processId)
.pipe(first())
.toPromise();
const process = await this._applicationService.getProcessById$(+route.params.processId).pipe(first()).toPromise();
if (!process) {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
@@ -31,10 +31,7 @@ export class CanActivateCustomerOrdersWithProcessIdGuard {
// Fix #3292: Alle Breadcrumbs die nichts mit dem aktuellen Prozess zu tun haben, müssen removed werden
async removeBreadcrumbWithSameProcessId(route: ActivatedRouteSnapshot) {
const crumbs = await this._breadcrumbService
.getBreadcrumbByKey$(+route.params.processId)
.pipe(first())
.toPromise();
const crumbs = await this._breadcrumbService.getBreadcrumbByKey$(+route.params.processId).pipe(first()).toPromise();
// Entferne alle Crumbs die nichts mit den Kundenbestellungen zu tun haben
if (crumbs.length > 1) {

View File

@@ -17,11 +17,17 @@ export class CanActivateCustomerOrdersGuard {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
let lastActivatedProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedCartCheckoutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout')
.pipe(first())
.toPromise()
)?.id;
const activatedProcessId = await this._applicationService.getActivatedProcessId$().pipe(first()).toPromise();

View File

@@ -6,13 +6,13 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateCustomerWithProcessIdGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _breadcrumbService: BreadcrumbService) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _breadcrumbService: BreadcrumbService,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService
.getProcessById$(+route.params.processId)
.pipe(first())
.toPromise();
const process = await this._applicationService.getProcessById$(+route.params.processId).pipe(first()).toPromise();
// if (!(process?.type === 'cart')) {
// // TODO:
@@ -37,10 +37,7 @@ export class CanActivateCustomerWithProcessIdGuard {
// Fix #3292: Alle Breadcrumbs die nichts mit dem aktuellen Prozess zu tun haben, müssen removed werden
async removeBreadcrumbWithSameProcessId(route: ActivatedRouteSnapshot) {
const crumbs = await this._breadcrumbService
.getBreadcrumbByKey$(+route.params.processId)
.pipe(first())
.toPromise();
const crumbs = await this._breadcrumbService.getBreadcrumbByKey$(+route.params.processId).pipe(first()).toPromise();
// Entferne alle Crumbs die nichts mit der Kundensuche zu tun haben
if (crumbs.length > 1) {

View File

@@ -17,15 +17,24 @@ export class CanActivateCustomerGuard {
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
let lastActivatedProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedCartCheckoutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedGoodsOutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'goods-out').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'goods-out')
.pipe(first())
.toPromise()
)?.id;
const activatedProcessId = await this._applicationService.getActivatedProcessId$().pipe(first()).toPromise();

View File

@@ -3,13 +3,21 @@ import { ActivatedRouteSnapshot, RouterStateSnapshot } from '@angular/router';
import { ApplicationService } from '@core/application';
import { Config } from '@core/config';
import { first } from 'rxjs/operators';
import { z } from 'zod';
@Injectable({ providedIn: 'root' })
export class CanActivateGoodsInGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _config: Config) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _config: Config,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService.getProcessById$(this._config.get('process.ids.goodsIn')).pipe(first()).toPromise();
const pid = this._config.get('process.ids.goodsIn', z.number());
const process = await this._applicationService
.getProcessById$(pid)
.pipe(first())
.toPromise();
if (!process) {
await this._applicationService.createProcess({
id: this._config.get('process.ids.goodsIn'),
@@ -18,7 +26,9 @@ export class CanActivateGoodsInGuard {
name: '',
});
}
this._applicationService.activateProcess(this._config.get('process.ids.goodsIn'));
this._applicationService.activateProcess(
this._config.get('process.ids.goodsIn'),
);
return true;
}
}

View File

@@ -6,13 +6,13 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateGoodsOutWithProcessIdGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _breadcrumbService: BreadcrumbService) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _breadcrumbService: BreadcrumbService,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService
.getProcessById$(+route.params.processId)
.pipe(first())
.toPromise();
const process = await this._applicationService.getProcessById$(+route.params.processId).pipe(first()).toPromise();
if (!process) {
// const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
@@ -31,10 +31,7 @@ export class CanActivateGoodsOutWithProcessIdGuard {
// Fix #3292: Alle Breadcrumbs die nichts mit dem aktuellen Prozess zu tun haben, müssen removed werden
async removeBreadcrumbWithSameProcessId(route: ActivatedRouteSnapshot) {
const crumbs = await this._breadcrumbService
.getBreadcrumbByKey$(+route.params.processId)
.pipe(first())
.toPromise();
const crumbs = await this._breadcrumbService.getBreadcrumbByKey$(+route.params.processId).pipe(first()).toPromise();
// Entferne alle Crumbs die nichts mit der Warenausgabe zu tun haben
if (crumbs.length > 1) {

View File

@@ -9,7 +9,7 @@ export class CanActivateGoodsOutGuard {
constructor(
private readonly _applicationService: ApplicationService,
private readonly _checkoutService: DomainCheckoutService,
private readonly _router: Router
private readonly _router: Router,
) {}
// !!! Ticket #3272 Code soll vorerst bestehen bleiben. Prozess Warenausgabe soll wieder Vorgang heißen (wie aktuell im Produktiv), bis zum neuen Navigationskonzept
@@ -103,11 +103,17 @@ export class CanActivateGoodsOutGuard {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
let lastActivatedProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedCartCheckoutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout')
.pipe(first())
.toPromise()
)?.id;
const activatedProcessId = await this._applicationService.getActivatedProcessId$().pipe(first()).toPromise();

View File

@@ -6,7 +6,10 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivatePackageInspectionGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _config: Config) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _config: Config,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService

View File

@@ -6,13 +6,13 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateProductWithProcessIdGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _breadcrumbService: BreadcrumbService) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _breadcrumbService: BreadcrumbService,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService
.getProcessById$(+route.params.processId)
.pipe(first())
.toPromise();
const process = await this._applicationService.getProcessById$(+route.params.processId).pipe(first()).toPromise();
// if (!(process?.type === 'cart')) {
// // TODO:
@@ -37,10 +37,7 @@ export class CanActivateProductWithProcessIdGuard {
// Fix #3292: Alle Breadcrumbs die nichts mit dem aktuellen Prozess zu tun haben, müssen removed werden
async removeBreadcrumbWithSameProcessId(route: ActivatedRouteSnapshot) {
const crumbs = await this._breadcrumbService
.getBreadcrumbByKey$(+route.params.processId)
.pipe(first())
.toPromise();
const crumbs = await this._breadcrumbService.getBreadcrumbByKey$(+route.params.processId).pipe(first()).toPromise();
// Entferne alle Crumbs die nichts mit der Artikelsuche zu tun haben
if (crumbs.length > 1) {

View File

@@ -16,15 +16,24 @@ export class CanActivateProductGuard {
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const processes = await this._applicationService.getProcesses$('customer').pipe(first()).toPromise();
let lastActivatedProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedCartCheckoutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'cart-checkout')
.pipe(first())
.toPromise()
)?.id;
const lastActivatedGoodsOutProcessId = (
await this._applicationService.getLastActivatedProcessWithSectionAndType$('customer', 'goods-out').pipe(first()).toPromise()
await this._applicationService
.getLastActivatedProcessWithSectionAndType$('customer', 'goods-out')
.pipe(first())
.toPromise()
)?.id;
const activatedProcessId = await this._applicationService.getActivatedProcessId$().pipe(first()).toPromise();

View File

@@ -9,11 +9,14 @@ export class CanActivateRemissionGuard {
constructor(
private readonly _applicationService: ApplicationService,
private readonly _config: Config,
private readonly _router: Router
private readonly _router: Router,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService.getProcessById$(this._config.get('process.ids.remission')).pipe(first()).toPromise();
const process = await this._applicationService
.getProcessById$(this._config.get('process.ids.remission'))
.pipe(first())
.toPromise();
if (!process) {
await this._applicationService.createProcess({
id: this._config.get('process.ids.remission'),

View File

@@ -6,10 +6,16 @@ import { first } from 'rxjs/operators';
@Injectable({ providedIn: 'root' })
export class CanActivateTaskCalendarGuard {
constructor(private readonly _applicationService: ApplicationService, private readonly _config: Config) {}
constructor(
private readonly _applicationService: ApplicationService,
private readonly _config: Config,
) {}
async canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot) {
const process = await this._applicationService.getProcessById$(this._config.get('process.ids.taskCalendar')).pipe(first()).toPromise();
const process = await this._applicationService
.getProcessById$(this._config.get('process.ids.taskCalendar'))
.pipe(first())
.toPromise();
if (!process) {
await this._applicationService.createProcess({
id: this._config.get('process.ids.taskCalendar'),

View File

@@ -2,7 +2,7 @@ import { Injectable } from '@angular/core';
import { ActivatedRouteSnapshot, Router, RouterStateSnapshot } from '@angular/router';
import { AuthService } from '@core/auth';
import { ScanAdapterService } from '@adapter/scan';
import { AuthService as IsaAuthService } from '@swagger/isa';
import { AuthService as IsaAuthService } from '@generated/swagger/isa-api';
import { UiConfirmModalComponent, UiErrorModalComponent, UiModalResult, UiModalService } from '@ui/modal';
import { EnvironmentService } from '@core/environment';
import { injectNetworkStatus$ } from '../services/network-status.service';

View File

@@ -5,7 +5,7 @@ import { take } from 'rxjs/operators';
export const ProcessIdGuard: CanActivateFn = async (
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot
state: RouterStateSnapshot,
): Promise<boolean | UrlTree> => {
const application = inject(ApplicationService);
const router = inject(Router);

View File

@@ -1,9 +1,9 @@
import { Injectable } from '@angular/core';
import { inject, Injectable, Injector } from '@angular/core';
import { HttpInterceptor, HttpEvent, HttpHandler, HttpRequest, HttpErrorResponse } from '@angular/common/http';
import { NEVER, Observable, throwError } from 'rxjs';
import { from, NEVER, Observable, throwError } from 'rxjs';
import { UiMessageModalComponent, UiModalService } from '@ui/modal';
import { catchError, filter, mergeMap, takeUntil, tap } from 'rxjs/operators';
import { AuthService } from '@core/auth';
import { AuthService, LoginStrategy } from '@core/auth';
import { IsaLogProvider } from '../providers';
import { LogLevel } from '@core/logger';
import { injectOnline$ } from '../services/network-status.service';
@@ -11,6 +11,7 @@ import { injectOnline$ } from '../services/network-status.service';
@Injectable()
export class HttpErrorInterceptor implements HttpInterceptor {
readonly offline$ = injectOnline$().pipe(filter((online) => !online));
readonly injector = inject(Injector);
constructor(
private _modal: UiModalService,
@@ -27,18 +28,9 @@ export class HttpErrorInterceptor implements HttpInterceptor {
handleError(error: HttpErrorResponse): Observable<any> {
if (error.status === 401) {
return this._modal
.open({
content: UiMessageModalComponent,
title: 'Sie sind nicht mehr angemeldet',
data: { message: 'Sie werden neu angemeldet' },
})
.afterClosed$.pipe(
tap(() => {
this._auth.login();
}),
mergeMap(() => NEVER),
);
const strategy = this.injector.get(LoginStrategy);
return from(strategy.login('Sie sind nicht mehr angemeldet')).pipe(mergeMap(() => NEVER));
}
if (!error.url.endsWith('/isa/logging')) {

View File

@@ -4,6 +4,7 @@ import { Component, ChangeDetectionStrategy } from '@angular/core';
selector: 'app-main',
templateUrl: 'main.component.html',
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class MainComponent {
constructor() {}

View File

@@ -2,7 +2,7 @@ import { Platform, PlatformModule } from '@angular/cdk/platform';
import { CommonModule } from '@angular/common';
import { Component, OnInit } from '@angular/core';
import { BranchSelectorComponent } from '@shared/components/branch-selector';
import { BranchDTO } from '@swagger/checkout';
import { BranchDTO } from '@generated/swagger/checkout-api';
import { BehaviorSubject } from 'rxjs';
@Component({
@@ -10,7 +10,6 @@ import { BehaviorSubject } from 'rxjs';
templateUrl: 'preview.component.html',
styleUrls: ['preview.component.css'],
imports: [CommonModule, BranchSelectorComponent, PlatformModule],
standalone: true,
})
export class PreviewComponent implements OnInit {
selectedBranch$ = new BehaviorSubject<BranchDTO>({});

View File

@@ -1,6 +1,6 @@
import { Injectable, Injector } from '@angular/core';
import { LogLevel, LogProvider } from '@core/logger';
import { UserStateService } from '@swagger/isa';
import { UserStateService } from '@generated/swagger/isa-api';
import { environment } from '../../environments/environment';
@Injectable({ providedIn: 'root' })

View File

@@ -4,9 +4,8 @@ import { Observable } from 'rxjs';
@Injectable({ providedIn: 'root' })
export class ProcessIdResolver {
constructor() {}
resolve(route: ActivatedRouteSnapshot): Observable<number> | Promise<number> | number {
return route.params.processId;
}
}

View File

@@ -4,7 +4,10 @@ import { ApplicationService } from '@core/application';
import { Observable } from 'rxjs';
export abstract class SectionResolver {
constructor(protected section: 'customer' | 'branch', protected applicationService: ApplicationService) {}
constructor(
protected section: 'customer' | 'branch',
protected applicationService: ApplicationService,
) {}
resolve(route: ActivatedRouteSnapshot): Observable<string> | Promise<string> | string {
this.applicationService.setSection(this.section);

View File

@@ -0,0 +1 @@
export * from './network-status.service';

View File

@@ -1,28 +1,32 @@
import { Injectable } from '@angular/core';
import { Logger, LogLevel } from '@core/logger';
import { Store } from '@ngrx/store';
import { UserStateService } from '@swagger/isa';
import { debounceTime, switchMap, takeUntil } from 'rxjs/operators';
import { RootState } from './root.state';
import packageInfo from 'packageJson';
import { environment } from '../../environments/environment';
import { Subject } from 'rxjs';
import { AuthService } from '@core/auth';
import { injectStorage, UserStorageProvider } from '@isa/core/storage';
import { isEqual } from 'lodash';
@Injectable({ providedIn: 'root' })
export class RootStateService {
static LOCAL_STORAGE_KEY = 'ISA_APP_INITIALSTATE';
#storage = injectStorage(UserStorageProvider);
private _cancelSave = new Subject<void>();
constructor(
private readonly _authService: AuthService,
private readonly _userStateService: UserStateService,
private _logger: Logger,
private _store: Store,
) {
if (!environment.production) {
console.log('Die UserState kann in der Konsole mit der Funktion "clearUserState()" geleert werden.');
console.log(
'Die UserState kann in der Konsole mit der Funktion "clearUserState()" geleert werden.',
);
}
window['clearUserState'] = () => {
@@ -43,9 +47,17 @@ export class RootStateService {
takeUntil(this._cancelSave),
debounceTime(1000),
switchMap((state) => {
const raw = JSON.stringify({ ...state, version: packageInfo.version, sub: this._authService.getClaimByKey('sub') });
RootStateService.SaveToLocalStorageRaw(raw);
return this._userStateService.UserStateSetUserState({ content: raw });
const data = {
...state,
version: packageInfo.version,
sub: this._authService.getClaimByKey('sub'),
};
RootStateService.SaveToLocalStorageRaw(JSON.stringify(data));
return this.#storage.set('state', {
...state,
version: packageInfo.version,
sub: this._authService.getClaimByKey('sub'),
});
}),
)
.subscribe();
@@ -56,16 +68,15 @@ export class RootStateService {
*/
async load(): Promise<boolean> {
try {
const res = await this._userStateService.UserStateGetUserState().toPromise();
const res = await this.#storage.get('state');
const resContent = res?.result?.content ?? null;
const storageContent = RootStateService.LoadFromLocalStorageRaw();
if (resContent) {
RootStateService.SaveToLocalStorageRaw(res.result.content);
if (res) {
RootStateService.SaveToLocalStorageRaw(JSON.stringify(res));
}
if (resContent !== storageContent) {
if (!isEqual(res, storageContent)) {
return true;
}
} catch (error) {
@@ -77,7 +88,7 @@ export class RootStateService {
async clear() {
try {
this._cancelSave.next();
await this._userStateService.UserStateResetUserState().toPromise();
await this.#storage.clear('state');
await new Promise((resolve) => setTimeout(resolve, 100));
RootStateService.RemoveFromLocalStorage();
await new Promise((resolve) => setTimeout(resolve, 100));

View File

@@ -7,9 +7,14 @@ import { AuthService } from '@core/auth';
templateUrl: 'token-login.component.html',
styleUrls: ['token-login.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class TokenLoginComponent implements OnInit {
constructor(private _route: ActivatedRoute, private _authService: AuthService, private _router: Router) {}
constructor(
private _route: ActivatedRoute,
private _authService: AuthService,
private _router: Router,
) {}
ngOnInit() {
if (this._route.snapshot.params.token && !this._authService.isAuthenticated()) {

View File

@@ -1,219 +1,222 @@
/* cyrillic-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-cyrillic-ext1.woff2') format('woff2');
src: url("./Open_Sans-400-cyrillic-ext1.woff2") format("woff2");
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-cyrillic2.woff2') format('woff2');
src: url("./Open_Sans-400-cyrillic2.woff2") format("woff2");
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-greek-ext3.woff2') format('woff2');
src: url("./Open_Sans-400-greek-ext3.woff2") format("woff2");
unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-greek4.woff2') format('woff2');
src: url("./Open_Sans-400-greek4.woff2") format("woff2");
unicode-range: U+0370-03FF;
}
/* hebrew */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-hebrew5.woff2') format('woff2');
src: url("./Open_Sans-400-hebrew5.woff2") format("woff2");
unicode-range: U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
/* vietnamese */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-vietnamese6.woff2') format('woff2');
src: url("./Open_Sans-400-vietnamese6.woff2") format("woff2");
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-latin-ext7.woff2') format('woff2');
src: url("./Open_Sans-400-latin-ext7.woff2") format("woff2");
unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-stretch: normal;
src: url('./Open_Sans-400-latin8.woff2') format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
U+2212, U+2215, U+FEFF, U+FFFD;
src: url("./Open_Sans-400-latin8.woff2") format("woff2");
unicode-range:
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191,
U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-cyrillic-ext9.woff2') format('woff2');
src: url("./Open_Sans-600-cyrillic-ext9.woff2") format("woff2");
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-cyrillic10.woff2') format('woff2');
src: url("./Open_Sans-600-cyrillic10.woff2") format("woff2");
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-greek-ext11.woff2') format('woff2');
src: url("./Open_Sans-600-greek-ext11.woff2") format("woff2");
unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-greek12.woff2') format('woff2');
src: url("./Open_Sans-600-greek12.woff2") format("woff2");
unicode-range: U+0370-03FF;
}
/* hebrew */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-hebrew13.woff2') format('woff2');
src: url("./Open_Sans-600-hebrew13.woff2") format("woff2");
unicode-range: U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
/* vietnamese */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-vietnamese14.woff2') format('woff2');
src: url("./Open_Sans-600-vietnamese14.woff2") format("woff2");
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-latin-ext15.woff2') format('woff2');
src: url("./Open_Sans-600-latin-ext15.woff2") format("woff2");
unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 600;
font-stretch: normal;
src: url('./Open_Sans-600-latin16.woff2') format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
U+2212, U+2215, U+FEFF, U+FFFD;
src: url("./Open_Sans-600-latin16.woff2") format("woff2");
unicode-range:
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191,
U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-cyrillic-ext17.woff2') format('woff2');
src: url("./Open_Sans-700-cyrillic-ext17.woff2") format("woff2");
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-cyrillic18.woff2') format('woff2');
src: url("./Open_Sans-700-cyrillic18.woff2") format("woff2");
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-greek-ext19.woff2') format('woff2');
src: url("./Open_Sans-700-greek-ext19.woff2") format("woff2");
unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-greek20.woff2') format('woff2');
src: url("./Open_Sans-700-greek20.woff2") format("woff2");
unicode-range: U+0370-03FF;
}
/* hebrew */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-hebrew21.woff2') format('woff2');
src: url("./Open_Sans-700-hebrew21.woff2") format("woff2");
unicode-range: U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
/* vietnamese */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-vietnamese22.woff2') format('woff2');
src: url("./Open_Sans-700-vietnamese22.woff2") format("woff2");
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-latin-ext23.woff2') format('woff2');
src: url("./Open_Sans-700-latin-ext23.woff2") format("woff2");
unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Open Sans';
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-stretch: normal;
src: url('./Open_Sans-700-latin24.woff2') format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
U+2212, U+2215, U+FEFF, U+FFFD;
src: url("./Open_Sans-700-latin24.woff2") format("woff2");
unicode-range:
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191,
U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

View File

@@ -1,86 +1,85 @@
{
"title": "ISA - Feature",
"silentRefresh": {
"interval": 300000
},
"@cdn/product-image": {
"url": "https://produktbilder.paragon-data.net"
},
"@core/auth": {
"issuer": "https://sso-test.paragon-data.de",
"clientId": "hug-isa",
"responseType": "id_token token",
"oidc": true,
"scope": "openid profile cmf_user isa-isa-webapi isa-checkout-webapi isa-cat-webapi isa-ava-webapi isa-crm-webapi isa-review-webapi isa-kpi-webapi isa-oms-webapi isa-nbo-webapi isa-print-webapi eis-service isa-inv-webapi isa-wws-webapi"
},
"@core/logger": {
"logLevel": "debug"
},
"@domain/checkout": {
"olaExpiration": "5m"
},
"@swagger/isa": {
"rootUrl": "https://isa-test.paragon-data.net/isa/v1"
},
"@swagger/cat": {
"rootUrl": "https://isa-test.paragon-data.net/catsearch/v6"
},
"@swagger/av": {
"rootUrl": "https://isa-test.paragon-data.net/ava/v6"
},
"@swagger/checkout": {
"rootUrl": "https://isa-test.paragon-data.net/checkout/v6"
},
"@swagger/crm": {
"rootUrl": "https://isa-test.paragon-data.net/crm/v6"
},
"@swagger/oms": {
"rootUrl": "https://isa-test.paragon-data.net/oms/v6"
},
"@swagger/print": {
"rootUrl": "https://isa-test.paragon-data.net/print/v1"
},
"@swagger/eis": {
"rootUrl": "https://filialinformationsystem-test.paragon-systems.de/eiswebapi/v1"
},
"@swagger/remi": {
"rootUrl": "https://isa-test.paragon-data.net/inv/v6"
},
"@swagger/wws": {
"rootUrl": "https://isa-test.paragon-data.net/wws/v1"
},
"hubs": {
"notifications": {
"url": "https://isa-test.paragon-data.net/isa/v1/rt",
"enableAutomaticReconnect": false,
"httpOptions": {
"transport": 1,
"logMessageContent": true,
"skipNegotiation": true
}
}
},
"process": {
"ids": {
"goodsOut": 1000,
"goodsIn": 2000,
"taskCalendar": 3000,
"remission": 4000,
"packageInspection": 5000,
"assortment": 6000,
"pickupShelf": 7000
}
},
"checkForUpdates": 3600000,
"licence": {
"scandit": "ApI1Sg5/KzWICPhn0CbflI4cjgXiFkKnhgEmUvAt0D3CWsck0SCIm557hJvGTqXD0A1mt3IvEwA8eQ1CBXL3EoA9lASWUcLt+FSWP9gHao+LT6Oz9QMrsJoJRC/OboodKS4/F+ZVa02eUT53X0GX9jJeEnh8EerqZimrl6oDjNLvHCzBnxtmsMZidAUaErqK5yaQQCkUKcfTQhRzVhqvsjdENR76EmrrvCSr93oMCnnDHjcyOz8O3stcNrCOGbxwDBIMwf05CzoEBhxF9SoT/fwvfWa9BRvlMTxl9lUUE2f3Aw9+0CBG7PYgZ9XGCiCM2Wy9T5cf0C5MOLr2MAIgQrlDua0oEtmC5FjFojQHJEITRmLyQnAyUU8Y+jkUUCtQNmweZKtTQT9le+G9QCzRoSsmVsVxCKxII3+8iLA+Lh9meI/vJSaQ2VpDgZVrV1Vc4V/z0Exu7Ap7R0MpzCy4hhRzdpWgf4OG815ZctwMvM7qfBqykG98B9oP3YC/LG+cpVK4Ipx5VnWBUIwVHDiocHhMjyroTBAeH3BfeCdOEpKwNK9vOxrbvUpqAc8ZOaaal08hWgFVFR8BQN+rEkiqKx5fONRXefkkyUWMdqwvoBn7ZzCr+F9GmD52Q7ZuDcyAigm2ArwDipT9QUH7gxphogcKRNAWAyaENWWKRBFWmeNYXJOuGXLr05Zye7joGFbJHxPYyUJ6KMombmYlI2GHc4JQGJNneDuL93v8AkYcfM2WfOjf0hm+SVw0TP95bD1xJwSCoKO5L6FxqMu5GPcOqik3sjGHg6XsEr10m7jt7G2PfNTgS3ft+TP32OjeSu9M80Fu3nmeqLM4a4lx9fFbGMpWDEU9wdftmPByeW7KoXyS2bkd1Mg9UP8ci0nKo2d/ThPn+iMEjXSibNeIGibaIT4ys3pjDLW2mx0IxQpwnuQfZzAHBszpMkwKuG4+FrqXff9+bZGuRQlVwhm2v5xbKRjgi99i14QkuNVUkePxllLZGFgQH0DjsLINZb+R9stBYjQmMGc2kkJfyhHx2/zvT2D2mpgcaq0ZRKco2CqDiLUJoHwLPse/fu4PWvqSKVpwiqhCehuloWTE3jkFUncwDI50hPvrfCx92cOJUE8RTsQgDoAh7JKsPHctSZfUicZyLHOuHMhtIoxs6l/lzFowbhZob/Uo7aRsipOcP/iZgEPnMEu/obXcLR3QrlQ+WuEppU4g2MZ9+xENLCqVDLEHiz+jZIvl42ePc4Ip4lJ5RQFcSSR1yYb+z/4KB/3bc308PHnEMEB5TYvVpK7M3kg2CTjos5lh733qQKwqYamgFjpr5oPUxRYwRvj41GYpcLN3Tr4WOi4lfevR5eVFBu1Jc9baY8JIOvcCL5WhXsEemnx5dUhcnP2ozloFCvU1IS60KHkXtF4NJl89tu5EECquTN5Lf9cvtIhlbmPsVg=="
},
"gender": {
"0": "Keine Anrede",
"1": "Enby",
"2": "Herr",
"4": "Frau"
},
"@shared/icon": "/assets/icons.json"
}
"title": "ISA - Feature",
"silentRefresh": {
"interval": 300000
},
"@cdn/product-image": {
"url": "https://produktbilder.paragon-data.net"
},
"@core/auth": {
"issuer": "https://sso-test.paragon-data.de",
"clientId": "hug-isa",
"responseType": "id_token token",
"oidc": true,
"scope": "openid profile cmf_user isa-isa-webapi isa-checkout-webapi isa-cat-webapi isa-ava-webapi isa-crm-webapi isa-review-webapi isa-kpi-webapi isa-oms-webapi isa-nbo-webapi isa-print-webapi eis-service isa-inv-webapi isa-wws-webapi"
},
"@core/logger": {
"logLevel": "debug"
},
"@domain/checkout": {
"olaExpiration": "5m"
},
"@swagger/isa": {
"rootUrl": "https://isa-feature.paragon-data.net/isa/v1"
},
"@swagger/cat": {
"rootUrl": "https://isa-test.paragon-data.net/catsearch/v6"
},
"@swagger/av": {
"rootUrl": "https://isa-test.paragon-data.net/ava/v6"
},
"@swagger/checkout": {
"rootUrl": "https://isa-feature.paragon-data.net/checkout/v6"
},
"@swagger/crm": {
"rootUrl": "https://isa-feature.paragon-data.net/crm/v6"
},
"@swagger/oms": {
"rootUrl": "https://isa-feature.paragon-data.net/oms/v6"
},
"@swagger/print": {
"rootUrl": "https://isa-feature.paragon-data.net/print/v1"
},
"@swagger/eis": {
"rootUrl": "https://filialinformationsystem-test.paragon-systems.de/eiswebapi/v1"
},
"@swagger/remi": {
"rootUrl": "https://isa-feature.paragon-data.net/inv/v6"
},
"@swagger/wws": {
"rootUrl": "https://isa-test.paragon-data.net/wws/v1"
},
"hubs": {
"notifications": {
"url": "https://isa-feature.paragon-data.net/isa/v1/rt",
"enableAutomaticReconnect": false,
"httpOptions": {
"transport": 1,
"logMessageContent": true,
"skipNegotiation": true
}
}
},
"process": {
"ids": {
"goodsOut": 1000,
"goodsIn": 2000,
"taskCalendar": 3000,
"remission": 4000,
"packageInspection": 5000,
"assortment": 6000,
"pickupShelf": 7000
}
},
"checkForUpdates": 3600000,
"licence": {
"scandit": "Ae8F2Wx2RMq5Lvn7UUAlWzVFZTt2+ubMAF8XtDpmPlNkBeG/LWs1M7AbgDW0LQqYLnszClEENaEHS56/6Ts2vrJ1Ux03CXUjK3jUvZpF5OchXR1CpnmpepJ6WxPCd7LMVHUGG1BbwPLDTFjP3y8uT0caTSmmGrYQWAs4CZcEF+ZBabP0z7vfm+hCZF/ebj9qqCJZcW8nH/n19hohshllzYBjFXjh87P2lIh1s6yZS3OaQWWXo/o0AKdxx7T6CVyR0/G5zq6uYJWf6rs3euUBEhpzOZHbHZK86Lvy2AVBEyVkkcttlDW1J2fA4l1W1JV/Xibz8AQV6kG482EpGF42KEoK48paZgX3e1AQsqUtmqzw294dcP4zMVstnw5/WrwKKi/5E/nOOJT2txYP1ZufIjPrwNFsqTlv7xCQlHjMzFGYwT816yD5qLRLbwOtjrkUPXNZLZ06T4upvWwJDmm8XgdeoDqMjHdcO4lwji1bl9EiIYJ/2qnsk9yZ2FqSaHzn4cbiL0f5u2HFlNAP0GUujGRlthGhHi6o4dFU+WAxKsFMKVt+SfoQUazNKHFVQgiAklTIZxIc/HUVzRvOLMxf+wFDerraBtcqGJg+g/5mrWYqeDBGhCBHtKiYf6244IJ4afzNTiH1/30SJcRzXwbEa3A7q1fJTx9/nLTOfVPrJKBQs7f/OQs2dA7LDCel8mzXdbjvsNQaeU5+iCIAq6zbTNKy1xT8wwj+VZrQmtNJs+qeznD+u29nCM24h8xCmRpvNPo4/Mww/lrTNrrNwLBSn1pMIwsH7yS9hH0v0oNAM3A6bVtk1D9qEkbyw+xZa+MZGpMP0D0CdcsqHalPcm5r/Ik="
},
"gender": {
"0": "Keine Anrede",
"1": "Enby",
"2": "Herr",
"4": "Frau"
},
"@shared/icon": "/assets/icons.json"
}

View File

@@ -17,7 +17,7 @@
},
"@domain/checkout": {
"olaExpiration": "5m"
},
},
"@swagger/isa": {
"rootUrl": "https://isa-integration.paragon-data.net/isa/v1"
},
@@ -72,7 +72,7 @@
},
"checkForUpdates": 900000,
"licence": {
"scandit": "ApI1Sg5/KzWICPhn0CbflI4cjgXiFkKnhgEmUvAt0D3CWsck0SCIm557hJvGTqXD0A1mt3IvEwA8eQ1CBXL3EoA9lASWUcLt+FSWP9gHao+LT6Oz9QMrsJoJRC/OboodKS4/F+ZVa02eUT53X0GX9jJeEnh8EerqZimrl6oDjNLvHCzBnxtmsMZidAUaErqK5yaQQCkUKcfTQhRzVhqvsjdENR76EmrrvCSr93oMCnnDHjcyOz8O3stcNrCOGbxwDBIMwf05CzoEBhxF9SoT/fwvfWa9BRvlMTxl9lUUE2f3Aw9+0CBG7PYgZ9XGCiCM2Wy9T5cf0C5MOLr2MAIgQrlDua0oEtmC5FjFojQHJEITRmLyQnAyUU8Y+jkUUCtQNmweZKtTQT9le+G9QCzRoSsmVsVxCKxII3+8iLA+Lh9meI/vJSaQ2VpDgZVrV1Vc4V/z0Exu7Ap7R0MpzCy4hhRzdpWgf4OG815ZctwMvM7qfBqykG98B9oP3YC/LG+cpVK4Ipx5VnWBUIwVHDiocHhMjyroTBAeH3BfeCdOEpKwNK9vOxrbvUpqAc8ZOaaal08hWgFVFR8BQN+rEkiqKx5fONRXefkkyUWMdqwvoBn7ZzCr+F9GmD52Q7ZuDcyAigm2ArwDipT9QUH7gxphogcKRNAWAyaENWWKRBFWmeNYXJOuGXLr05Zye7joGFbJHxPYyUJ6KMombmYlI2GHc4JQGJNneDuL93v8AkYcfM2WfOjf0hm+SVw0TP95bD1xJwSCoKO5L6FxqMu5GPcOqik3sjGHg6XsEr10m7jt7G2PfNTgS3ft+TP32OjeSu9M80Fu3nmeqLM4a4lx9fFbGMpWDEU9wdftmPByeW7KoXyS2bkd1Mg9UP8ci0nKo2d/ThPn+iMEjXSibNeIGibaIT4ys3pjDLW2mx0IxQpwnuQfZzAHBszpMkwKuG4+FrqXff9+bZGuRQlVwhm2v5xbKRjgi99i14QkuNVUkePxllLZGFgQH0DjsLINZb+R9stBYjQmMGc2kkJfyhHx2/zvT2D2mpgcaq0ZRKco2CqDiLUJoHwLPse/fu4PWvqSKVpwiqhCehuloWTE3jkFUncwDI50hPvrfCx92cOJUE8RTsQgDoAh7JKsPHctSZfUicZyLHOuHMhtIoxs6l/lzFowbhZob/Uo7aRsipOcP/iZgEPnMEu/obXcLR3QrlQ+WuEppU4g2MZ9+xENLCqVDLEHiz+jZIvl42ePc4Ip4lJ5RQFcSSR1yYb+z/4KB/3bc308PHnEMEB5TYvVpK7M3kg2CTjos5lh733qQKwqYamgFjpr5oPUxRYwRvj41GYpcLN3Tr4WOi4lfevR5eVFBu1Jc9baY8JIOvcCL5WhXsEemnx5dUhcnP2ozloFCvU1IS60KHkXtF4NJl89tu5EECquTN5Lf9cvtIhlbmPsVg=="
"scandit": "ASq1ZCbuDs0nJ4cPGkFOSkQEBHSL/kuljVAq2ttwz2Q5CEwULWAlasJIkjsIe/nptzNx1IBSxwDPWh0gXmvF08BRBDTzDUELdX6q02N/HUddSHE4A1dMXoFg+I8of+iZQijQIogxmP5RfSpj6ixzD2cGV0w+BG6o9xRXG4lEv9vNAOC3+emfcuVj2Whmfbuzao4HcWweVSz4HJh8dcbxTPF10MH8qR4kkV7fNWIF+PaYww69relfuvrkgdbWPcLs4Xb7WW4AISX9pTmJmSuv2LvD9gMoPNlmhdTWi+qFcmgZiPRDb1I0Bldo7jKLdboylEXkVQVWF1D2fv3iO5BrijG+n52XQd3ew49/1ssJi6dWhxiZQMlN+mz7cfSPmGzJc0eqaf52tEA8PkIupXjly/6dckSVcqTsex+wHcQuTinyW2bu9/YY3ZTMCp5du+lFZBD+AQSsq7EALzzithpijNG3jQka/8yRSHPBP6JtfobMdbv7SlAESslnN5R5lKJms4HnSm4CwxBAX2sUrhQeuit74/5pwe8qI+CaEGzjKYfmcRhFXd+Kz/ySV3HyrVuieH6+6ytBjGh3EkwGvQ8Ovu4KsruWAyAjHwRyBdrFIRYyLWdou77VH8gSLwHi69QsMGshcnYaREpqDEb5LLR9Ok7jP5IjMyPzX4USS327G9f4I8ujTaCKXQ9a384yV/wP9IeSuJld4dgdGy80rDP2sWZ+NJ65cNWpAfi/Nmbm6ucjICoUHILtchyx/w/YNYUzfCWFjUWHn83TzG+31f3dkjWoI3XpCOg5RKREs55htHSAyZtYhYiQr1FxDVFNEQI2MrDR0fBt2qOeZB08yA=="
},
"gender": {
"0": "Keine Anrede",
@@ -81,4 +81,4 @@
"4": "Frau"
},
"@shared/icon": "/assets/icons.json"
}
}

View File

@@ -1,86 +1,87 @@
{
"title": "ISA - Local",
"silentRefresh": {
"interval": 300000
},
"debug": true,
"@cdn/product-image": {
"url": "https://produktbilder.paragon-data.net"
},
"@core/auth": {
"issuer": "https://sso-test.paragon-data.de",
"clientId": "isa-client",
"responseType": "code",
"scope": "openid profile cmf_user isa-isa-webapi isa-checkout-webapi isa-cat-webapi isa-ava-webapi isa-crm-webapi isa-review-webapi isa-kpi-webapi isa-oms-webapi isa-nbo-webapi isa-print-webapi eis-service isa-inv-webapi isa-wws-webapi",
"showDebugInformation": true
},
"@core/logger": {
"logLevel": "debug"
},
"@swagger/isa": {
"rootUrl": "https://isa-test.paragon-data.net/isa/v1"
},
"@swagger/cat": {
"rootUrl": "https://isa-test.paragon-data.net/catsearch/v6"
},
"@swagger/av": {
"rootUrl": "https://isa-test.paragon-data.net/ava/v6"
},
"@swagger/checkout": {
"rootUrl": "https://isa-test.paragon-data.net/checkout/v6"
},
"@swagger/crm": {
"rootUrl": "https://isa-test.paragon-data.net/crm/v6"
},
"@swagger/oms": {
"rootUrl": "https://isa-test.paragon-data.net/oms/v6"
},
"@swagger/print": {
"rootUrl": "https://isa-test.paragon-data.net/print/v1"
},
"@swagger/eis": {
"rootUrl": "https://filialinformationsystem-test.paragon-systems.de/eiswebapi/v1"
},
"@swagger/remi": {
"rootUrl": "https://isa-test.paragon-data.net/inv/v6"
},
"@swagger/wws": {
"rootUrl": "https://isa-test.paragon-data.net/wws/v1"
},
"@domain/checkout": {
"olaExpiration": "5m"
},
"hubs": {
"notifications": {
"url": "https://isa-test.paragon-data.net/isa/v1/rt",
"enableAutomaticReconnect": false,
"httpOptions": {
"transport": 1,
"logMessageContent": true,
"skipNegotiation": true
}
}
},
"process": {
"ids": {
"goodsOut": 1000,
"goodsIn": 2000,
"taskCalendar": 3000,
"remission": 4000,
"packageInspection": 5000,
"assortment": 6000,
"pickupShelf": 7000
}
},
"checkForUpdates": 3600000,
"licence": {
"scandit": "ApI1Sg5/KzWICPhn0CbflI4cjgXiFkKnhgEmUvAt0D3CWsck0SCIm557hJvGTqXD0A1mt3IvEwA8eQ1CBXL3EoA9lASWUcLt+FSWP9gHao+LT6Oz9QMrsJoJRC/OboodKS4/F+ZVa02eUT53X0GX9jJeEnh8EerqZimrl6oDjNLvHCzBnxtmsMZidAUaErqK5yaQQCkUKcfTQhRzVhqvsjdENR76EmrrvCSr93oMCnnDHjcyOz8O3stcNrCOGbxwDBIMwf05CzoEBhxF9SoT/fwvfWa9BRvlMTxl9lUUE2f3Aw9+0CBG7PYgZ9XGCiCM2Wy9T5cf0C5MOLr2MAIgQrlDua0oEtmC5FjFojQHJEITRmLyQnAyUU8Y+jkUUCtQNmweZKtTQT9le+G9QCzRoSsmVsVxCKxII3+8iLA+Lh9meI/vJSaQ2VpDgZVrV1Vc4V/z0Exu7Ap7R0MpzCy4hhRzdpWgf4OG815ZctwMvM7qfBqykG98B9oP3YC/LG+cpVK4Ipx5VnWBUIwVHDiocHhMjyroTBAeH3BfeCdOEpKwNK9vOxrbvUpqAc8ZOaaal08hWgFVFR8BQN+rEkiqKx5fONRXefkkyUWMdqwvoBn7ZzCr+F9GmD52Q7ZuDcyAigm2ArwDipT9QUH7gxphogcKRNAWAyaENWWKRBFWmeNYXJOuGXLr05Zye7joGFbJHxPYyUJ6KMombmYlI2GHc4JQGJNneDuL93v8AkYcfM2WfOjf0hm+SVw0TP95bD1xJwSCoKO5L6FxqMu5GPcOqik3sjGHg6XsEr10m7jt7G2PfNTgS3ft+TP32OjeSu9M80Fu3nmeqLM4a4lx9fFbGMpWDEU9wdftmPByeW7KoXyS2bkd1Mg9UP8ci0nKo2d/ThPn+iMEjXSibNeIGibaIT4ys3pjDLW2mx0IxQpwnuQfZzAHBszpMkwKuG4+FrqXff9+bZGuRQlVwhm2v5xbKRjgi99i14QkuNVUkePxllLZGFgQH0DjsLINZb+R9stBYjQmMGc2kkJfyhHx2/zvT2D2mpgcaq0ZRKco2CqDiLUJoHwLPse/fu4PWvqSKVpwiqhCehuloWTE3jkFUncwDI50hPvrfCx92cOJUE8RTsQgDoAh7JKsPHctSZfUicZyLHOuHMhtIoxs6l/lzFowbhZob/Uo7aRsipOcP/iZgEPnMEu/obXcLR3QrlQ+WuEppU4g2MZ9+xENLCqVDLEHiz+jZIvl42ePc4Ip4lJ5RQFcSSR1yYb+z/4KB/3bc308PHnEMEB5TYvVpK7M3kg2CTjos5lh733qQKwqYamgFjpr5oPUxRYwRvj41GYpcLN3Tr4WOi4lfevR5eVFBu1Jc9baY8JIOvcCL5WhXsEemnx5dUhcnP2ozloFCvU1IS60KHkXtF4NJl89tu5EECquTN5Lf9cvtIhlbmPsVg=="
},
"gender": {
"0": "Keine Anrede",
"1": "Enby",
"2": "Herr",
"4": "Frau"
},
"@shared/icon": "/assets/icons.json"
}
"title": "ISA - Local",
"silentRefresh": {
"interval": 300000
},
"debug": true,
"dev-scanner": true,
"@cdn/product-image": {
"url": "https://produktbilder.paragon-data.net"
},
"@core/auth": {
"issuer": "https://sso-test.paragon-data.de",
"clientId": "isa-client",
"responseType": "code",
"scope": "openid profile cmf_user isa-isa-webapi isa-checkout-webapi isa-cat-webapi isa-ava-webapi isa-crm-webapi isa-review-webapi isa-kpi-webapi isa-oms-webapi isa-nbo-webapi isa-print-webapi eis-service isa-inv-webapi isa-wws-webapi",
"showDebugInformation": true
},
"@core/logger": {
"logLevel": "debug"
},
"@swagger/isa": {
"rootUrl": "https://isa-test.paragon-data.net/isa/v1"
},
"@swagger/cat": {
"rootUrl": "https://isa-test.paragon-data.net/catsearch/v6"
},
"@swagger/av": {
"rootUrl": "https://isa-test.paragon-data.net/ava/v6"
},
"@swagger/checkout": {
"rootUrl": "https://isa-test.paragon-data.net/checkout/v6"
},
"@swagger/crm": {
"rootUrl": "https://isa-test.paragon-data.net/crm/v6"
},
"@swagger/oms": {
"rootUrl": "https://isa-test.paragon-data.net/oms/v6"
},
"@swagger/print": {
"rootUrl": "https://isa-test.paragon-data.net/print/v1"
},
"@swagger/eis": {
"rootUrl": "https://filialinformationsystem-test.paragon-systems.de/eiswebapi/v1"
},
"@swagger/remi": {
"rootUrl": "https://isa-test.paragon-data.net/inv/v6"
},
"@swagger/wws": {
"rootUrl": "https://isa-test.paragon-data.net/wws/v1"
},
"@domain/checkout": {
"olaExpiration": "5m"
},
"hubs": {
"notifications": {
"url": "https://isa-test.paragon-data.net/isa/v1/rt",
"enableAutomaticReconnect": false,
"httpOptions": {
"transport": 1,
"logMessageContent": true,
"skipNegotiation": true
}
}
},
"process": {
"ids": {
"goodsOut": 1000,
"goodsIn": 2000,
"taskCalendar": 3000,
"remission": 4000,
"packageInspection": 5000,
"assortment": 6000,
"pickupShelf": 7000
}
},
"checkForUpdates": 3600000,
"licence": {
"scandit": "Ae8F2Wx2RMq5Lvn7UUAlWzVFZTt2+ubMAF8XtDpmPlNkBeG/LWs1M7AbgDW0LQqYLnszClEENaEHS56/6Ts2vrJ1Ux03CXUjK3jUvZpF5OchXR1CpnmpepJ6WxPCd7LMVHUGG1BbwPLDTFjP3y8uT0caTSmmGrYQWAs4CZcEF+ZBabP0z7vfm+hCZF/ebj9qqCJZcW8nH/n19hohshllzYBjFXjh87P2lIh1s6yZS3OaQWWXo/o0AKdxx7T6CVyR0/G5zq6uYJWf6rs3euUBEhpzOZHbHZK86Lvy2AVBEyVkkcttlDW1J2fA4l1W1JV/Xibz8AQV6kG482EpGF42KEoK48paZgX3e1AQsqUtmqzw294dcP4zMVstnw5/WrwKKi/5E/nOOJT2txYP1ZufIjPrwNFsqTlv7xCQlHjMzFGYwT816yD5qLRLbwOtjrkUPXNZLZ06T4upvWwJDmm8XgdeoDqMjHdcO4lwji1bl9EiIYJ/2qnsk9yZ2FqSaHzn4cbiL0f5u2HFlNAP0GUujGRlthGhHi6o4dFU+WAxKsFMKVt+SfoQUazNKHFVQgiAklTIZxIc/HUVzRvOLMxf+wFDerraBtcqGJg+g/5mrWYqeDBGhCBHtKiYf6244IJ4afzNTiH1/30SJcRzXwbEa3A7q1fJTx9/nLTOfVPrJKBQs7f/OQs2dA7LDCel8mzXdbjvsNQaeU5+iCIAq6zbTNKy1xT8wwj+VZrQmtNJs+qeznD+u29nCM24h8xCmRpvNPo4/Mww/lrTNrrNwLBSn1pMIwsH7yS9hH0v0oNAM3A6bVtk1D9qEkbyw+xZa+MZGpMP0D0CdcsqHalPcm5r/Ik="
},
"gender": {
"0": "Keine Anrede",
"1": "Enby",
"2": "Herr",
"4": "Frau"
},
"@shared/icon": "/assets/icons.json"
}

View File

@@ -3,7 +3,8 @@
"silentRefresh": {
"interval": 300000
},
"debug": true,
"debug": false,
"@cdn/product-image": {
"url": "https://produktbilder.paragon-data.net"
},
@@ -74,7 +75,8 @@
},
"checkForUpdates": 3600000,
"licence": {
"scandit": "ApI1Sg5/KzWICPhn0CbflI4cjgXiFkKnhgEmUvAt0D3CWsck0SCIm557hJvGTqXD0A1mt3IvEwA8eQ1CBXL3EoA9lASWUcLt+FSWP9gHao+LT6Oz9QMrsJoJRC/OboodKS4/F+ZVa02eUT53X0GX9jJeEnh8EerqZimrl6oDjNLvHCzBnxtmsMZidAUaErqK5yaQQCkUKcfTQhRzVhqvsjdENR76EmrrvCSr93oMCnnDHjcyOz8O3stcNrCOGbxwDBIMwf05CzoEBhxF9SoT/fwvfWa9BRvlMTxl9lUUE2f3Aw9+0CBG7PYgZ9XGCiCM2Wy9T5cf0C5MOLr2MAIgQrlDua0oEtmC5FjFojQHJEITRmLyQnAyUU8Y+jkUUCtQNmweZKtTQT9le+G9QCzRoSsmVsVxCKxII3+8iLA+Lh9meI/vJSaQ2VpDgZVrV1Vc4V/z0Exu7Ap7R0MpzCy4hhRzdpWgf4OG815ZctwMvM7qfBqykG98B9oP3YC/LG+cpVK4Ipx5VnWBUIwVHDiocHhMjyroTBAeH3BfeCdOEpKwNK9vOxrbvUpqAc8ZOaaal08hWgFVFR8BQN+rEkiqKx5fONRXefkkyUWMdqwvoBn7ZzCr+F9GmD52Q7ZuDcyAigm2ArwDipT9QUH7gxphogcKRNAWAyaENWWKRBFWmeNYXJOuGXLr05Zye7joGFbJHxPYyUJ6KMombmYlI2GHc4JQGJNneDuL93v8AkYcfM2WfOjf0hm+SVw0TP95bD1xJwSCoKO5L6FxqMu5GPcOqik3sjGHg6XsEr10m7jt7G2PfNTgS3ft+TP32OjeSu9M80Fu3nmeqLM4a4lx9fFbGMpWDEU9wdftmPByeW7KoXyS2bkd1Mg9UP8ci0nKo2d/ThPn+iMEjXSibNeIGibaIT4ys3pjDLW2mx0IxQpwnuQfZzAHBszpMkwKuG4+FrqXff9+bZGuRQlVwhm2v5xbKRjgi99i14QkuNVUkePxllLZGFgQH0DjsLINZb+R9stBYjQmMGc2kkJfyhHx2/zvT2D2mpgcaq0ZRKco2CqDiLUJoHwLPse/fu4PWvqSKVpwiqhCehuloWTE3jkFUncwDI50hPvrfCx92cOJUE8RTsQgDoAh7JKsPHctSZfUicZyLHOuHMhtIoxs6l/lzFowbhZob/Uo7aRsipOcP/iZgEPnMEu/obXcLR3QrlQ+WuEppU4g2MZ9+xENLCqVDLEHiz+jZIvl42ePc4Ip4lJ5RQFcSSR1yYb+z/4KB/3bc308PHnEMEB5TYvVpK7M3kg2CTjos5lh733qQKwqYamgFjpr5oPUxRYwRvj41GYpcLN3Tr4WOi4lfevR5eVFBu1Jc9baY8JIOvcCL5WhXsEemnx5dUhcnP2ozloFCvU1IS60KHkXtF4NJl89tu5EECquTN5Lf9cvtIhlbmPsVg==" },
"scandit": "Ae8F2Wx2RMq5Lvn7UUAlWzVFZTt2+ubMAF8XtDpmPlNkBeG/LWs1M7AbgDW0LQqYLnszClEENaEHS56/6Ts2vrJ1Ux03CXUjK3jUvZpF5OchXR1CpnmpepJ6WxPCd7LMVHUGG1BbwPLDTFjP3y8uT0caTSmmGrYQWAs4CZcEF+ZBabP0z7vfm+hCZF/ebj9qqCJZcW8nH/n19hohshllzYBjFXjh87P2lIh1s6yZS3OaQWWXo/o0AKdxx7T6CVyR0/G5zq6uYJWf6rs3euUBEhpzOZHbHZK86Lvy2AVBEyVkkcttlDW1J2fA4l1W1JV/Xibz8AQV6kG482EpGF42KEoK48paZgX3e1AQsqUtmqzw294dcP4zMVstnw5/WrwKKi/5E/nOOJT2txYP1ZufIjPrwNFsqTlv7xCQlHjMzFGYwT816yD5qLRLbwOtjrkUPXNZLZ06T4upvWwJDmm8XgdeoDqMjHdcO4lwji1bl9EiIYJ/2qnsk9yZ2FqSaHzn4cbiL0f5u2HFlNAP0GUujGRlthGhHi6o4dFU+WAxKsFMKVt+SfoQUazNKHFVQgiAklTIZxIc/HUVzRvOLMxf+wFDerraBtcqGJg+g/5mrWYqeDBGhCBHtKiYf6244IJ4afzNTiH1/30SJcRzXwbEa3A7q1fJTx9/nLTOfVPrJKBQs7f/OQs2dA7LDCel8mzXdbjvsNQaeU5+iCIAq6zbTNKy1xT8wwj+VZrQmtNJs+qeznD+u29nCM24h8xCmRpvNPo4/Mww/lrTNrrNwLBSn1pMIwsH7yS9hH0v0oNAM3A6bVtk1D9qEkbyw+xZa+MZGpMP0D0CdcsqHalPcm5r/Ik="
},
"gender": {
"0": "Keine Anrede",
"1": "Enby",

View File

@@ -1,6 +1,6 @@
import { Injectable } from '@angular/core';
import { Store } from '@ngrx/store';
import { BranchDTO } from '@swagger/checkout';
import { BranchDTO } from '@generated/swagger/checkout-api';
import { isBoolean, isNumber } from '@utils/common';
import { BehaviorSubject, Observable } from 'rxjs';
import { first, map, switchMap } from 'rxjs/operators';
@@ -35,7 +35,9 @@ export class ApplicationService {
getProcesses$(section?: 'customer' | 'branch') {
const processes$ = this.store.select(selectProcesses);
return processes$.pipe(map((processes) => processes.filter((process) => (section ? process.section === section : true))));
return processes$.pipe(
map((processes) => processes.filter((process) => (section ? process.section === section : true))),
);
}
getProcessById$(processId: number): Observable<ApplicationProcess> {
@@ -135,7 +137,10 @@ export class ApplicationService {
this.store.dispatch(setSection({ section }));
}
getLastActivatedProcessWithSectionAndType$(section: 'customer' | 'branch', type: string): Observable<ApplicationProcess> {
getLastActivatedProcessWithSectionAndType$(
section: 'customer' | 'branch',
type: string,
): Observable<ApplicationProcess> {
return this.getProcesses$(section).pipe(
map((processes) =>
processes

View File

@@ -11,8 +11,17 @@ export const addProcess = createAction(`${prefix} Add Process`, props<{ process:
export const removeProcess = createAction(`${prefix} Remove Process`, props<{ processId: number }>());
export const setActivatedProcess = createAction(`${prefix} Set Activated Process`, props<{ activatedProcessId: number }>());
export const setActivatedProcess = createAction(
`${prefix} Set Activated Process`,
props<{ activatedProcessId: number }>(),
);
export const patchProcess = createAction(`${prefix} Patch Process`, props<{ processId: number; changes: Partial<ApplicationProcess> }>());
export const patchProcess = createAction(
`${prefix} Patch Process`,
props<{ processId: number; changes: Partial<ApplicationProcess> }>(),
);
export const patchProcessData = createAction(`${prefix} Patch Process Data`, props<{ processId: number; data: Record<string, any> }>());
export const patchProcessData = createAction(
`${prefix} Patch Process Data`,
props<{ processId: number; data: Record<string, any> }>(),
);

View File

@@ -1,10 +1,10 @@
import { coerceArray, coerceStringArray } from '@angular/cdk/coercion';
import { Injectable } from '@angular/core';
import { coerceArray } from '@angular/cdk/coercion';
import { inject, Injectable } from '@angular/core';
import { Config } from '@core/config';
import { isNullOrUndefined } from '@utils/common';
import { AuthConfig, OAuthService } from 'angular-oauth2-oidc';
import { JwksValidationHandler } from 'angular-oauth2-oidc-jwks';
import { asapScheduler, BehaviorSubject } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
@Injectable({
providedIn: 'root',
@@ -44,21 +44,26 @@ export class AuthService {
this._oAuthService.tokenValidationHandler = new JwksValidationHandler();
this._oAuthService.setupAutomaticSilentRefresh();
try {
await this._oAuthService.loadDiscoveryDocumentAndTryLogin();
} catch (error) {
this.login();
throw error;
}
await this._oAuthService.loadDiscoveryDocumentAndTryLogin();
this._initialized.next(true);
}
isAuthenticated() {
return this.isIdTokenValid();
}
isIdTokenValid() {
console.log('ID Token Expiration:', new Date(this._oAuthService.getIdTokenExpiration()));
return this._oAuthService.hasValidIdToken();
}
isAccessTokenValid() {
console.log('ACCESS Token Expiration:', new Date(this._oAuthService.getAccessTokenExpiration()));
return this._oAuthService.hasValidAccessToken();
}
getToken() {
return this._oAuthService.getAccessToken();
}
@@ -99,9 +104,6 @@ export class AuthService {
async logout() {
await this._oAuthService.revokeTokenAndLogout();
// asapScheduler.schedule(() => {
// window.location.reload();
// }, 250);
}
hasRole(role: string | string[]) {

View File

@@ -3,6 +3,7 @@ import { AuthService } from './auth.service';
@Directive({
selector: '[ifRole],[ifRoleElse],[ifNotRole],[ifNotRoleElse]',
standalone: false,
})
export class IfRoleDirective implements OnChanges {
@Input()

View File

@@ -1,3 +1,4 @@
export * from './auth.module';
export * from './auth.service';
export * from './if-role.directive';
export * from './login.strategy';

View File

@@ -0,0 +1,78 @@
import { ScanAdapterService } from '@adapter/scan';
import { inject, Injectable } from '@angular/core';
import { toSignal } from '@angular/core/rxjs-interop';
import { EnvironmentService } from '@core/environment';
import { UiConfirmModalComponent, UiModalResult, UiModalService } from '@ui/modal';
import { injectNetworkStatus$ } from '../../app/services';
import { AuthService } from './auth.service';
import { AuthService as IsaAuthService } from '@generated/swagger/isa-api';
import { firstValueFrom, lastValueFrom } from 'rxjs';
@Injectable({ providedIn: 'root' })
export class LoginStrategy {
private readonly environmentService = inject(EnvironmentService);
private readonly networkStatus = toSignal(injectNetworkStatus$());
private readonly modal = inject(UiModalService);
private readonly scanAdapterService = inject(ScanAdapterService);
private readonly isaAuthService = inject(IsaAuthService);
private readonly authService = inject(AuthService);
async login(title = 'Anmeldung') {
console.log('LoginStrategy.login');
let loginModalResult: UiModalResult<boolean>;
if (this.authService.isIdTokenValid()) {
console.log('LoginStrategy.login: idToken is valid');
await this.authService.login();
return;
}
try {
if (this.environmentService.isMobileDevice()) {
console.log('LoginStrategy.login: isMobileDevice');
do {
const loginModal = this.modal.open({
content: UiConfirmModalComponent,
title,
config: {
canClose: false,
backdropClose: false,
},
data: {
message: 'Bitte wählen Sie die Anmeldeoption aus.',
rejectLabel: 'Anmeldung mit Logindaten',
confirmLabel: 'Anmeldung mit Keycard',
},
});
loginModalResult = await loginModal.afterClosed$.toPromise();
} while (this.networkStatus() === 'offline');
}
} catch (error) {}
try {
if (loginModalResult.data) {
const result = await lastValueFrom(this.scanAdapterService.scan());
if (typeof result === 'string') {
const res = await firstValueFrom(
this.isaAuthService.AuthLogin({
code: result,
application: 'isa',
hostname: location.host,
}),
);
if (res.token) {
console.log('LoginStrategy.login: setKeyCardToken', res.token);
this.authService.setKeyCardToken(res.token);
}
}
}
} catch (error) {}
console.log('LoginStrategy.login: login');
await this.authService.login();
}
}

View File

@@ -120,7 +120,10 @@ export class BreadcrumbService {
if (recursive) {
const breadcrumbs = await this.getBreadcrumbByKey$(breadcrumb.key).pipe(take(1)).toPromise();
breadcrumbsToRemove = [...breadcrumbsToRemove, ...breadcrumbs.filter((crumb) => crumb.timestamp > breadcrumb.timestamp)];
breadcrumbsToRemove = [
...breadcrumbsToRemove,
...breadcrumbs.filter((crumb) => crumb.timestamp > breadcrumb.timestamp),
];
}
if (!breadcrumbsToRemove.length) {
@@ -135,7 +138,10 @@ export class BreadcrumbService {
crumbs.forEach((crumb) => this.removeBreadcrumb(crumb.id));
}
getLatestBreadcrumbForSection(section: 'customer' | 'branch', predicate: (crumb: Breadcrumb) => boolean = (_) => true) {
getLatestBreadcrumbForSection(
section: 'customer' | 'branch',
predicate: (crumb: Breadcrumb) => boolean = (_) => true,
) {
return this.store
.select(selectors.selectBreadcrumbsBySection, { section })
.pipe(map((crumbs) => crumbs.sort((a, b) => b.timestamp - a.timestamp).find((f) => predicate(f))));

View File

@@ -27,7 +27,7 @@ export interface Breadcrumb {
/**
* Query Parameter
*/
params?: Object;
params?: object;
/**
* Timestamp

View File

@@ -11,7 +11,10 @@ export const addBreadcrumb = createAction(`${prefix} Add Breadcrumb`, props<{ br
/**
* Action um Breadcrumb im State zu ändern
*/
export const updateBreadcrumb = createAction(`${prefix} Update Breadcrumb`, props<{ id: number; changes: Partial<Breadcrumb> }>());
export const updateBreadcrumb = createAction(
`${prefix} Update Breadcrumb`,
props<{ id: number; changes: Partial<Breadcrumb> }>(),
);
/**
* Action um Breadcrumb im State zu entfernen

View File

@@ -43,7 +43,10 @@ describe('Breadcrumb Reducer', () => {
const state = breadcrumbReducer(INIT, action.addBreadcrumb({ breadcrumb }));
const fixture = breadcrumbReducer(state, action.updateBreadcrumb({ id: breadcrumb.id, changes: { name: 'Test Name 2' } }));
const fixture = breadcrumbReducer(
state,
action.updateBreadcrumb({ id: breadcrumb.id, changes: { name: 'Test Name 2' } }),
);
expect(fixture.entities[breadcrumb.id]).toEqual(expected);
});

View File

@@ -10,26 +10,46 @@ describe('Breadcrumb Selectors', () => {
beforeEach(() => {
state = breadcrumbReducer(
INIT,
action.addBreadcrumb({ breadcrumb: { id: 1, key: 'unit-test-1', path: '', name: 'Unit Test 1', section: 'customer' } }),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({
breadcrumb: { id: 2, key: 'unit-test-1', path: '', name: 'Unit Test 1', tags: ['details'], section: 'customer' },
breadcrumb: { id: 1, key: 'unit-test-1', path: '', name: 'Unit Test 1', section: 'customer' },
}),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({ breadcrumb: { id: 3, key: 'unit-test-2', path: '', name: 'Unit Test 1', section: 'customer' } }),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({ breadcrumb: { id: 4, key: 'unit-test-3', path: '', name: 'Unit Test 1', section: 'customer' } }),
action.addBreadcrumb({
breadcrumb: {
id: 2,
key: 'unit-test-1',
path: '',
name: 'Unit Test 1',
tags: ['details'],
section: 'customer',
},
}),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({
breadcrumb: { id: 5, key: 'unit-test-3', path: '', name: 'Unit Test 1', tags: ['details'], section: 'customer' },
breadcrumb: { id: 3, key: 'unit-test-2', path: '', name: 'Unit Test 1', section: 'customer' },
}),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({
breadcrumb: { id: 4, key: 'unit-test-3', path: '', name: 'Unit Test 1', section: 'customer' },
}),
);
state = breadcrumbReducer(
state,
action.addBreadcrumb({
breadcrumb: {
id: 5,
key: 'unit-test-3',
path: '',
name: 'Unit Test 1',
tags: ['details'],
section: 'customer',
},
}),
);
});

View File

@@ -20,7 +20,9 @@ export const selectBreadcrumbById = createSelector(selectEntities, (entities, id
/**
* Gibt alle Breadcrumb Entities als Array zurück die den key enthalten
*/
export const selectBreadcrumbsByKey = createSelector(selectAll, (entities, key: string) => entities.filter((crumb) => crumb.key == key));
export const selectBreadcrumbsByKey = createSelector(selectAll, (entities, key: string) =>
entities.filter((crumb) => crumb.key == key),
);
/**
* Gibt alle Breadcrumb Entities als Array zurück die den key und tag enthalten
@@ -37,12 +39,15 @@ export const selectBreadcrumbsByKeyAndTag = createSelector(
export const selectBreadcrumbsByKeyAndTags = createSelector(
selectAll,
(entities: Breadcrumb[], { key, tags }: { key: string; tags: string[] }) =>
entities.filter((crumb) => crumb.key == key && isArray(crumb.tags) && tags.every((tag) => crumb.tags.includes(tag))),
entities.filter(
(crumb) => crumb.key == key && isArray(crumb.tags) && tags.every((tag) => crumb.tags.includes(tag)),
),
);
/**
* Gibt alle Breadcrumb Entities als Array zurück die die tags enthalten
*/
export const selectBreadcrumbsBySection = createSelector(selectAll, (entities: Breadcrumb[], { section }: { section: string }) =>
entities.filter((crumb) => crumb.section === section),
export const selectBreadcrumbsBySection = createSelector(
selectAll,
(entities: Breadcrumb[], { section }: { section: string }) => entities.filter((crumb) => crumb.section === section),
);

View File

@@ -1,7 +1,7 @@
import { createEntityAdapter, EntityState } from '@ngrx/entity';
import { Breadcrumb } from '../defs';
export interface BreadcrumbState extends EntityState<Breadcrumb> {}
export type BreadcrumbState = EntityState<Breadcrumb>
export const featureName = 'core-breadcrumb';

View File

@@ -34,7 +34,7 @@ export class CacheService {
return 'cache';
}
private getKey(token: Object | string): string {
private getKey(token: object | string): string {
if (typeof token === 'string') {
return this.hash(token);
}
@@ -105,7 +105,7 @@ export class CacheService {
});
}
private async cached(token: Object | string): Promise<DbEntry<any> | undefined> {
private async cached(token: object | string): Promise<DbEntry<any> | undefined> {
const store = await this.getObjectStore();
return new Promise<DbEntry<any> | undefined>((resolve, reject) => {
const request = store.get(this.getKey(token));
@@ -118,7 +118,7 @@ export class CacheService {
});
}
async get<T = any>(token: Object | string): Promise<T | undefined> {
async get<T = any>(token: object | string): Promise<T | undefined> {
const cached = await this.cached(token);
if (!cached) {
@@ -133,7 +133,7 @@ export class CacheService {
return cached.data;
}
async delete(token: Object | string): Promise<void> {
async delete(token: object | string): Promise<void> {
const store = await this.getObjectStore('readwrite');
return new Promise<void>((resolve, reject) => {
const request = store.delete(this.getKey(token));

View File

@@ -4,7 +4,10 @@ import { CommandService } from './command.service';
import { FEATURE_ACTION_HANDLERS, ROOT_ACTION_HANDLERS } from './tokens';
export function provideActionHandlers(actionHandlers: Type<ActionHandler>[]): Provider[] {
return [CommandService, actionHandlers.map((handler) => ({ provide: FEATURE_ACTION_HANDLERS, useClass: handler, multi: true }))];
return [
CommandService,
actionHandlers.map((handler) => ({ provide: FEATURE_ACTION_HANDLERS, useClass: handler, multi: true })),
];
}
@NgModule({})
@@ -12,14 +15,20 @@ export class CoreCommandModule {
static forRoot(actionHandlers: Type<ActionHandler>[]): ModuleWithProviders<CoreCommandModule> {
return {
ngModule: CoreCommandModule,
providers: [CommandService, actionHandlers.map((handler) => ({ provide: ROOT_ACTION_HANDLERS, useClass: handler, multi: true }))],
providers: [
CommandService,
actionHandlers.map((handler) => ({ provide: ROOT_ACTION_HANDLERS, useClass: handler, multi: true })),
],
};
}
static forChild(actionHandlers: Type<ActionHandler>[]): ModuleWithProviders<CoreCommandModule> {
return {
ngModule: CoreCommandModule,
providers: [CommandService, actionHandlers.map((handler) => ({ provide: FEATURE_ACTION_HANDLERS, useClass: handler, multi: true }))],
providers: [
CommandService,
actionHandlers.map((handler) => ({ provide: FEATURE_ACTION_HANDLERS, useClass: handler, multi: true })),
],
};
}
}

View File

@@ -1,8 +0,0 @@
import { Observable } from 'rxjs';
/**
* Config loader interface for loading configurations
*/
export interface ConfigLoader {
load(): Promise<any>;
}

View File

@@ -1,4 +0,0 @@
// start:ng42.barrel
export * from './config-loader';
export * from './json.config-loader';
// end:ng42.barrel

View File

@@ -1,36 +0,0 @@
// // unit test JsonConfigLoader
// import { HttpTestingController } from '@angular/common/http/testing';
// import { createServiceFactory, SpectatorService } from '@ngneat/spectator';
// import { CORE_JSON_CONFIG_LOADER_URL } from '../tokens';
// import { JsonConfigLoader } from './json.config-loader';
// describe('JsonConfigLoader', () => {
// let spectator: SpectatorService<JsonConfigLoader>;
// const createService = createServiceFactory({
// imports: [HttpClientTestingModule],
// service: JsonConfigLoader,
// mocks: [],
// providers: [{ provide: CORE_JSON_CONFIG_LOADER_URL, useValue: '/assets/config.json' }],
// });
// let httpTestingController: HttpTestingController;
// beforeEach(() => {
// spectator = createService();
// httpTestingController = spectator.inject(HttpTestingController);
// });
// it('should create', () => {
// expect(spectator.service).toBeTruthy();
// });
// describe('load', () => {
// it('should call the provided url', async () => {
// const reqPromise = spectator.service.load();
// const req = httpTestingController.expectOne('/assets/config.json');
// req.flush({ unit: 'test' });
// const result = await reqPromise;
// httpTestingController.verify();
// expect(result).toEqual({ unit: 'test' });
// });
// });
// });

View File

@@ -1,16 +0,0 @@
import { HttpClient } from '@angular/common/http';
import { Inject, Injectable } from '@angular/core';
import { ConfigLoader } from './config-loader';
import { CORE_JSON_CONFIG_LOADER_URL } from '../tokens';
@Injectable()
export class JsonConfigLoader implements ConfigLoader {
constructor(
@Inject(CORE_JSON_CONFIG_LOADER_URL) private url: string,
private http: HttpClient,
) {}
load(): Promise<any> {
return this.http.get(this.url).toPromise();
}
}

View File

@@ -1,7 +0,0 @@
import { Type } from '@angular/core';
import { ConfigLoader } from './config-loaders';
export interface ConfigModuleOptions {
useConfigLoader: Type<ConfigLoader>;
jsonConfigLoaderUrl?: string;
}

View File

@@ -1,28 +0,0 @@
import { APP_INITIALIZER, ModuleWithProviders, NgModule } from '@angular/core';
import { CORE_CONFIG_LOADER } from '@core/config';
import { Config } from './config';
import { ConfigModuleOptions } from './config-module-options';
import { CORE_JSON_CONFIG_LOADER_URL } from './tokens';
export function _initializeConfigFactory(config: Config) {
return () => config.init();
}
@NgModule({})
export class ConfigModule {
static forRoot(options: ConfigModuleOptions): ModuleWithProviders<ConfigModule> {
const configLoaderProvider = {
provide: CORE_CONFIG_LOADER,
useClass: options.useConfigLoader,
};
return {
ngModule: ConfigModule,
providers: [
Config,
configLoaderProvider,
options.jsonConfigLoaderUrl ? { provide: CORE_JSON_CONFIG_LOADER_URL, useValue: options.jsonConfigLoaderUrl } : null,
],
};
}
}

View File

@@ -1,45 +0,0 @@
import { createServiceFactory, SpectatorService } from '@ngneat/spectator';
import { Config } from './config';
import { ConfigLoader } from './config-loaders';
import { CORE_CONFIG_LOADER } from './tokens';
class TestConfigLoader implements ConfigLoader {
load() {
return Promise.resolve({});
}
}
// Unit test Config
describe('Config', () => {
let spectator: SpectatorService<Config>;
const createService = createServiceFactory({
service: Config,
providers: [{ provide: CORE_CONFIG_LOADER, useClass: TestConfigLoader }],
});
let configLoader: ConfigLoader;
beforeEach(() => {
spectator = createService();
configLoader = spectator.inject(CORE_CONFIG_LOADER);
});
it('should create', () => {
expect(spectator.service).toBeTruthy();
});
describe('init()', () => {
it('should load config and assigns it to _config', async () => {
const config = { unit: 'test' };
spyOn(configLoader, 'load').and.returnValue(Promise.resolve(config));
await spectator.service.init();
expect(spectator.service['_config']).toEqual(config);
});
});
describe('get()', () => {
it('should return config value', () => {
spectator.service['_config'] = { test: 'test' };
expect(spectator.service.get('test')).toEqual('test');
});
});
});

View File

@@ -1,27 +0,0 @@
import { Inject, Injectable } from '@angular/core';
import { ReplaySubject } from 'rxjs';
import { ConfigLoader } from './config-loaders';
import { CORE_CONFIG_LOADER } from './tokens';
import { pick } from './utils';
@Injectable()
export class Config {
private _config: any;
private readonly _initilized = new ReplaySubject<void>(1);
get initialized() {
return this._initilized.asObservable();
}
constructor(@Inject(CORE_CONFIG_LOADER) private readonly _configLoader: ConfigLoader) {}
// load config and assign it to this._config
async init() {
this._config = await this._configLoader.load();
this._initilized.next();
}
get(path: string) {
return pick(path, this._config);
}
}

View File

@@ -1,6 +0,0 @@
export * from './config-loaders';
export * from './config-module-options';
export * from './config.module';
export * from './config';
export * from './tokens';
export * from './utils';

View File

@@ -1,6 +0,0 @@
import { InjectionToken } from '@angular/core';
import { ConfigLoader } from './config-loaders';
export const CORE_CONFIG_LOADER = new InjectionToken<ConfigLoader>('core.config.loader');
export const CORE_JSON_CONFIG_LOADER_URL = new InjectionToken<ConfigLoader>('core.json.config.loader.url');

View File

@@ -1,3 +0,0 @@
// start:ng42.barrel
export * from './pick';
// end:ng42.barrel

View File

@@ -1,41 +0,0 @@
import { pick } from './pick';
describe('pick', () => {
it('should pick properties from the 1st level from the object', () => {
const obj = {
foo: 'bar',
};
expect(pick('foo', obj)).toEqual('bar');
});
it('should pick properties from the 2nd level from the object', () => {
const obj = {
foo: {
bar: 'baz',
},
};
expect(pick('foo.bar', obj)).toEqual('baz');
});
it('should pick properties from the 3rd level from the object', () => {
const obj = {
foo: {
bar: {
baz: 'qux',
},
},
};
expect(pick('foo.bar.baz', obj)).toEqual('qux');
});
it('should throw an error of obj is not an object', () => {
expect(() => pick('foo', 'bar')).toThrowError(`bar is not an object`);
});
it('should return undefined if the property is not found', () => {
const obj = {
foo: 'bar',
};
expect(pick('bar', obj)).toEqual(undefined);
});
});

View File

@@ -1,33 +0,0 @@
/**
* Pick a value from an object at a given path.
* @param path path of the value to pick
* @param obj object to pick from
* @returns the value at the path or undefined
* @throws if obj is not an object
*/
export function pick<T = any>(path: string, obj: Object): T {
const paths = path.split('.');
// check if obj is null or undefined
if (obj == null) {
return undefined;
}
// check if obj is of type object and not an array
// and throw an error if not
if (typeof obj !== 'object' || Array.isArray(obj)) {
throw new Error(`${obj} is not an object`);
}
let result = obj;
// loop through the path and pick the value
// early exit if the path is empty
for (const path of paths) {
result = result[path];
if (result == null) {
return undefined;
}
}
return result as T;
}

View File

@@ -62,6 +62,10 @@ export class EnvironmentService {
matchDesktopXXLarge$ = this._breakpointObserver.observe(MATCH_DESKTOP_XXLARGE).pipe(map((result) => result.matches));
isMobileDevice(): boolean {
return this._platform.ANDROID || this._platform.IOS;
}
/**
* @deprecated Use `matchDesktopSmall` or 'matchDesktop' instead.
*/

View File

@@ -1,5 +1,5 @@
import { Injectable } from '@angular/core';
import { ItemDTO } from '@swagger/cat';
import { ItemDTO } from '@generated/swagger/cat-search-api';
import {
AvailabilityDTO,
BranchDTO,
@@ -7,20 +7,25 @@ import {
StoreCheckoutBranchService,
StoreCheckoutSupplierService,
SupplierDTO,
} from '@swagger/checkout';
} from '@generated/swagger/checkout-api';
import { BehaviorSubject, combineLatest, Observable, of } from 'rxjs';
import {
AvailabilityRequestDTO,
AvailabilityService,
AvailabilityDTO as SwaggerAvailabilityDTO,
AvailabilityType,
} from '@swagger/availability';
import { AvailabilityDTO as CatAvailabilityDTO } from '@swagger/cat';
} from '@generated/swagger/availability-api';
import { AvailabilityDTO as CatAvailabilityDTO } from '@generated/swagger/cat-search-api';
import { map, shareReplay, switchMap, withLatestFrom, mergeMap, timeout, first } from 'rxjs/operators';
import { isArray, memorize } from '@utils/common';
import { LogisticianDTO, LogisticianService } from '@swagger/oms';
import { ResponseArgsOfIEnumerableOfStockInfoDTO, StockDTO, StockInfoDTO, StockService } from '@swagger/remi';
import { PriceDTO } from '@swagger/availability';
import { LogisticianDTO, LogisticianService } from '@generated/swagger/oms-api';
import {
ResponseArgsOfIEnumerableOfStockInfoDTO,
StockDTO,
StockInfoDTO,
StockService,
} from '@generated/swagger/inventory-api';
import { PriceDTO } from '@generated/swagger/availability-api';
import { AvailabilityByBranchDTO, ItemData, Ssc } from './defs';
import { Availability } from './defs/availability';
import { isEmpty } from 'lodash';
@@ -160,7 +165,7 @@ export class DomainAvailabilityService {
quantity: number;
branch?: BranchDTO;
}): Observable<AvailabilityDTO> {
const request = !!branch ? this.getStockByBranch(branch.id) : this.getDefaultStock();
const request = branch ? this.getStockByBranch(branch.id) : this.getDefaultStock();
return request.pipe(
switchMap((s) =>
combineLatest([
@@ -171,7 +176,13 @@ export class DomainAvailabilityService {
),
map(([response, supplier, defaultBranch]) => {
const price = item?.price;
return this._mapToTakeAwayAvailability({ response, supplier, branchId: branch?.id ?? defaultBranch?.id, quantity, price });
return this._mapToTakeAwayAvailability({
response,
supplier,
branchId: branch?.id ?? defaultBranch?.id,
quantity,
price,
});
}),
shareReplay(1),
);
@@ -211,12 +222,18 @@ export class DomainAvailabilityService {
quantity: number;
branchId?: number;
}): Observable<AvailabilityDTO> {
const request = !!branchId ? this.getStockByBranch(branchId) : this.getDefaultStock();
const request = branchId ? this.getStockByBranch(branchId) : this.getDefaultStock();
return request.pipe(
switchMap((s) => this._stockService.StockInStockByEAN({ eans, stockId: s.id })),
withLatestFrom(this.getTakeAwaySupplier(), this.getDefaultBranch()),
map(([response, supplier, defaultBranch]) => {
return this._mapToTakeAwayAvailability({ response, supplier, branchId: branchId ?? defaultBranch.id, quantity, price });
return this._mapToTakeAwayAvailability({
response,
supplier,
branchId: branchId ?? defaultBranch.id,
quantity,
price,
});
}),
shareReplay(1),
);
@@ -329,7 +346,10 @@ export class DomainAvailabilityService {
this.getPickUpAvailability({ item, quantity, branch: branch ?? defaultBranch }).pipe(
mergeMap((availability) =>
logistician$.pipe(
map((logistician) => ({ ...(availability?.length > 0 ? availability[0] : []), logistician: { id: logistician.id } })),
map((logistician) => ({
...(availability?.length > 0 ? availability[0] : []),
logistician: { id: logistician.id },
})),
),
),
shareReplay(1),
@@ -427,7 +447,9 @@ export class DomainAvailabilityService {
return this.getPickUpAvailabilities(payload, true).pipe(
timeout(20000),
switchMap((availability) =>
logistician$.pipe(map((logistician) => ({ availability: [...availability], logistician: { id: logistician.id } }))),
logistician$.pipe(
map((logistician) => ({ availability: [...availability], logistician: { id: logistician.id } })),
),
),
shareReplay(1),
);
@@ -512,7 +534,9 @@ export class DomainAvailabilityService {
return availability;
}
private _mapToPickUpAvailability(availabilities: SwaggerAvailabilityDTO[]): Availability<AvailabilityDTO, SwaggerAvailabilityDTO>[] {
private _mapToPickUpAvailability(
availabilities: SwaggerAvailabilityDTO[],
): Availability<AvailabilityDTO, SwaggerAvailabilityDTO>[] {
if (isArray(availabilities)) {
const preferred = availabilities.filter((f) => f.preferred === 1);
const totalAvailable = availabilities.reduce((sum, av) => sum + (av?.qty || 0), 0);
@@ -572,7 +596,9 @@ export class DomainAvailabilityService {
}
const stock$ = branchId$.pipe(
mergeMap((branchId) => this._stockService.StockGetStocksByBranch({ branchId }).pipe(map((response) => response.result?.[0]))),
mergeMap((branchId) =>
this._stockService.StockGetStocksByBranch({ branchId }).pipe(map((response) => response.result?.[0])),
),
);
return stock$.pipe(
@@ -598,7 +624,9 @@ export class DomainAvailabilityService {
getInStock({ itemIds, branchId }: { itemIds: number[]; branchId: number }): Observable<StockInfoDTO[]> {
return this.getStockByBranch(branchId).pipe(
mergeMap((stock) =>
this._stockService.StockInStock({ articleIds: itemIds, stockId: stock.id }).pipe(map((response) => response.result)),
this._stockService
.StockInStock({ articleIds: itemIds, stockId: stock.id })
.pipe(map((response) => response.result)),
),
);
}

View File

@@ -1,4 +1,4 @@
import { AvailabilityDTO } from '@swagger/checkout';
import { AvailabilityDTO } from '@generated/swagger/checkout-api';
export interface AvailabilityByBranchDTO extends AvailabilityDTO {
availableQuantity?: number;

View File

@@ -1,4 +1,4 @@
import { PriceDTO } from '@swagger/availability';
import { PriceDTO } from '@generated/swagger/availability-api';
export interface ItemData {
ean: string;

View File

@@ -1,5 +1,5 @@
import { Injectable } from '@angular/core';
import { StockInfoDTO } from '@swagger/remi';
import { StockInfoDTO } from '@generated/swagger/inventory-api';
import { groupBy, isEqual, uniqWith } from 'lodash';
import { BehaviorSubject, combineLatest, Observable, Subject } from 'rxjs';
import { buffer, debounceTime, distinctUntilChanged } from 'rxjs/operators';
@@ -90,10 +90,15 @@ export class DomainInStockService {
const grouped = groupBy(itemBranchData, 'branchId');
Object.keys(grouped).forEach((key) => {
const branchId = Number(key);
const itemIds = itemBranchData.filter((itemBranch) => itemBranch.branchId === branchId).map((item) => item.itemId);
const itemIds = itemBranchData
.filter((itemBranch) => itemBranch.branchId === branchId)
.map((item) => item.itemId);
this._availability
.getInStock({ itemIds, branchId })
.subscribe(this._fetchStockDataResponse({ itemIds, branchId }), this._fetchStockDataError({ itemIds, branchId }));
.subscribe(
this._fetchStockDataResponse({ itemIds, branchId }),
this._fetchStockDataError({ itemIds, branchId }),
);
});
}
@@ -101,7 +106,9 @@ export class DomainInStockService {
({ itemIds, branchId }: { itemIds: number[]; branchId: number }) =>
(stockInfos: StockInfoDTO[]) => {
itemIds.forEach((itemId) => {
const stockInfo = stockInfos.find((stockInfo) => stockInfo.itemId === itemId && stockInfo.branchId === branchId);
const stockInfo = stockInfos.find(
(stockInfo) => stockInfo.itemId === itemId && stockInfo.branchId === branchId,
);
let inStock = 0;
if (stockInfo?.inStock) {

Some files were not shown because too many files have changed in this diff Show More