diff --git a/.env.example b/.env.example index aa97581d..cfcf6146 100644 --- a/.env.example +++ b/.env.example @@ -9,5 +9,5 @@ VUE_APP_PERMISSION_ID= VUE_APP_ALIAS={} VUE_APP_DEFAULT_ALIAS="" VUE_APP_DEFAULT_LOG_LEVEL="error" -VUE_APP_LOGIN_URL="http://launchpad.hotwax.io/login" VUE_APP_CRON_EXPRESSIONS={"Every 5 minutes":"0 */5 * ? * *","Every 15 minutes":"0 */15 * ? * *","Every 30 minutes":"0 */30 * ? * *","Hourly":"0 0 * ? * *","Every six hours":"0 0 */6 ? * *","Every day at midnight":"0 0 0 * * ?"} +VUE_APP_LOGIN_URL="https://launchpad.hotwax.io/login" diff --git a/.firebaserc b/.firebaserc index 4ae76f8c..3796fa5d 100644 --- a/.firebaserc +++ b/.firebaserc @@ -1,23 +1,23 @@ { "projects": { - "default": "hotwax-digital-commerce", + "default": "hotwax-digital-commerce-uat", "production": "digital-commerce-71eb8" }, "targets": { - "hotwax-digital-commerce": { + "hotwax-digital-commerce-uat": { "hosting": { "dev": [ - "dev-threshold-management" + "hotwax-atp-dev" ], "uat": [ - "threshold-management-uat" + "hotwax-atp-uat" ] } }, "digital-commerce-71eb8": { "hosting": { "prod": [ - "threshold-management" + "hotwax-atp" ] } } diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index b9ef0fbb..5189d59b 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,7 +1,7 @@ ### Related Issues - Closes # + # ### Short Description and Why It's Useful @@ -11,10 +11,7 @@ - **IMPORTANT NOTICE** - Remember to add changelog entry - - ### Contribution and Currently Important Rules Acceptance - - [ ] I read and followed [contribution rules](https://github.com/hotwax/threshold-management#contribution-guideline) \ No newline at end of file + - [ ] I read and followed [contribution rules](https://github.com/hotwax/available-to-promise#contribution-guideline) \ No newline at end of file diff --git a/README.md b/README.md index b5375c3d..9d633bd1 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,11 @@ -Threshold Management App +Available to Promise App # Prerequisite Ionic CLI - If you don't have the ionic CLI installed refer [official documentation](https://ionicframework.com/docs/intro/cli) for the installation instructions. # Build Notes (Users) -1. Download the app from [release](https://github.com/hotwax/threshold-management/releases) page and extract it. +1. Download the app from [release](https://github.com/hotwax/available-to-promise/releases) page and extract it. 2. Go to the app directory. 3. Run following command to download dependencies `npm i` @@ -16,7 +16,7 @@ Ionic CLI - If you don't have the ionic CLI installed refer [official documentat # Build Notes (Contributors) 1. Open a Terminal window -2. Clone app using the command: `git clone https://github.com/hotwax/threshold-management.git ` +2. Clone app using the command: `git clone https://github.com/hotwax/available-to-promise.git ` 3. Go to the directory using command: `cd ` 4. Run following command to download dependencies `npm i` @@ -27,11 +27,11 @@ Ionic CLI - If you don't have the ionic CLI installed refer [official documentat # Contribution Guideline 1. Fork the repository and clone it locally from the `main` branch. Before starting your work make sure it's up to date with current `main` branch. -2. Pick an issue from [here](https://github.com/hotwax/threshold-management/issues). Write in the issue comment that you want to pick it, if you can't assign yourself. **Please stay assigned to one issue at a time to not block others**. -3. Create a branch for your edits. Use the following branch naming conventions: **threshold-management/issue-number**. +2. Pick an issue from [here](https://github.com/hotwax/available-to-promise/issues). Write in the issue comment that you want to pick it, if you can't assign yourself. **Please stay assigned to one issue at a time to not block others**. +3. Create a branch for your edits. Use the following branch naming conventions: **available-to-promise/issue-number**. 4. Please add issue number to your commit message. 5. Propose a Pull Request to `main` branch containing issue number and issue title. -6. Use [Pull Request template](https://github.com/hotwax/threshold-management/blob/main/.github/PULL_REQUEST_TEMPLATE.md) (it's automatically added to each PR) and fill as much fields as possible to describe your solution. +6. Use [Pull Request template](https://github.com/hotwax/available-to-promise/blob/main/.github/PULL_REQUEST_TEMPLATE.md) (it's automatically added to each PR) and fill as much fields as possible to describe your solution. 7. Reference any relevant issues or other information in your PR. 8. Wait for review and adjust your PR according to it. 9. Congrats! Your PR should now be merged in! @@ -55,4 +55,4 @@ If you have any questions or ideas feel free to join our LICENSE for more details. +Available to Promise app is completely free and released under the Apache v2.0 License. Check LICENSE for more details. diff --git a/capacitor.config.json b/capacitor.config.json index 028deb7d..4e62e57e 100644 --- a/capacitor.config.json +++ b/capacitor.config.json @@ -1,6 +1,6 @@ { - "appId": "co.hotwax.thresholdmanagement", - "appName": "Threshold Management", + "appId": "co.hotwax.availabletopromise", + "appName": "Available to Promise", "bundledWebRuntime": false, "npmClient": "npm", "webDir": "dist", diff --git a/manifest.json b/manifest.json index 14851ddb..4d86cec1 100644 --- a/manifest.json +++ b/manifest.json @@ -1,6 +1,6 @@ { - "name": "HotWax Commerce Threshold Management", - "short_name": "Threshold Management", + "name": "HotWax Commerce Available to Promise", + "short_name": "Available to Promise", "theme_color": "#FFFFFF", "icons": [{ "src": "public/img/icons/favicon-16x16.png", diff --git a/package-lock.json b/package-lock.json index 9faea759..a6ba0c70 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { - "name": "threshold-management", - "version": "2.8.0", + "name": "available-to-promise", + "version": "3.0.2", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "threshold-management", - "version": "2.8.0", + "name": "available-to-promise", + "version": "3.0.2", "dependencies": { "@capacitor/android": "^2.4.7", "@capacitor/core": "^2.4.7", @@ -16,6 +16,7 @@ "@hotwax/app-version-info": "^1.0.0", "@hotwax/apps-theme": "^1.2.6", "@hotwax/dxp-components": "^1.13.0", + "@hotwax/oms-api": "^1.14.0", "@ionic/core": "7.6.0", "@ionic/vue": "7.6.0", "@ionic/vue-router": "7.6.0", @@ -9665,20 +9666,6 @@ "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", "dev": true }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "dev": true, - "hasInstallScript": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, "node_modules/function-bind": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", diff --git a/package.json b/package.json index e11a3758..399facbe 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { - "name": "threshold-management", - "version": "2.8.0", + "name": "available-to-promise", + "version": "3.0.2", "private": true, - "description": "Threshold Management", + "description": "Available to Promise", "scripts": { "serve": "vue-cli-service serve", "build": "vue-cli-service build", @@ -19,6 +19,7 @@ "@hotwax/app-version-info": "^1.0.0", "@hotwax/apps-theme": "^1.2.6", "@hotwax/dxp-components": "^1.13.0", + "@hotwax/oms-api": "^1.14.0", "@ionic/core": "7.6.0", "@ionic/vue": "7.6.0", "@ionic/vue-router": "7.6.0", diff --git a/public/index.html b/public/index.html index f8506117..fe8ea8d3 100644 --- a/public/index.html +++ b/public/index.html @@ -2,7 +2,7 @@ - Threshold Management - HotWax Commerce + Available to Promise - HotWax Commerce diff --git a/src/App.vue b/src/App.vue index c0a04213..0634a9da 100644 --- a/src/App.vue +++ b/src/App.vue @@ -9,16 +9,35 @@ \ No newline at end of file diff --git a/src/components/ScheduleActionsPopover.vue b/src/components/ScheduleActionsPopover.vue index 5b3ad0ce..95288991 100644 --- a/src/components/ScheduleActionsPopover.vue +++ b/src/components/ScheduleActionsPopover.vue @@ -89,6 +89,8 @@ async function runNow() { const payload = { ruleGroupId: ruleGroup.value.ruleGroupId, paused: "Y", // passing Y as we just need to configure the scheduler and do not need to schedule it in active state + // Hardcoding for now, need to fetch system message remote id for the ftp server config. + systemMessageRemoteId: "RemoteSftp" } try { @@ -107,6 +109,7 @@ async function runNow() { const resp = await RuleService.runNow(ruleGroup.value.ruleGroupId) if(!hasError(resp) && resp.data.jobRunId) { showToast(translate("Service has been scheduled")) + await store.dispatch('rule/fetchRules', { groupTypeEnumId: ruleGroup.value.groupTypeEnumId, pageSize: 50 }) popoverController.dismiss(); } else { throw resp.data @@ -121,6 +124,7 @@ async function runNow() { ] }); - return scheduleAlert.present(); + await scheduleAlert.present(); + popoverController.dismiss() } \ No newline at end of file diff --git a/src/components/ScheduleRuleItem.vue b/src/components/ScheduleRuleItem.vue index a8043efc..09608abc 100644 --- a/src/components/ScheduleRuleItem.vue +++ b/src/components/ScheduleRuleItem.vue @@ -1,35 +1,40 @@ + + \ No newline at end of file diff --git a/src/views/CreateUpdateShippingRule.vue b/src/views/CreateUpdateShippingRule.vue new file mode 100644 index 00000000..0bd3645d --- /dev/null +++ b/src/views/CreateUpdateShippingRule.vue @@ -0,0 +1,362 @@ + + + + + \ No newline at end of file diff --git a/src/views/CreateUpdateStorePickupRule.vue b/src/views/CreateUpdateStorePickupRule.vue new file mode 100644 index 00000000..928c5325 --- /dev/null +++ b/src/views/CreateUpdateStorePickupRule.vue @@ -0,0 +1,363 @@ + + + + + \ No newline at end of file diff --git a/src/views/CreateUpdateThresholdRule.vue b/src/views/CreateUpdateThresholdRule.vue new file mode 100644 index 00000000..b490b1f7 --- /dev/null +++ b/src/views/CreateUpdateThresholdRule.vue @@ -0,0 +1,276 @@ + + + + + \ No newline at end of file diff --git a/src/views/InventoryChannels.vue b/src/views/InventoryChannels.vue index f13cec9a..004311df 100644 --- a/src/views/InventoryChannels.vue +++ b/src/views/InventoryChannels.vue @@ -3,15 +3,14 @@ - {{ translate("Inventory channels") }} - + {{ translate("Inventory channels") }} - - + {{ translate("Channels") }} - + + {{ translate("Publish") }} @@ -21,53 +20,59 @@
- - -
- {{ channel.facilityGroupId }} - {{ channel.facilityGroupName }} - {{ channel.description }} -
-
- - - - - {{ channel.selectedConfigFacility?.facilityName }} -

{{ channel.selectedConfigFacility?.facilityId }}

-
- - - -
- - - - {{ translate("Facilities") }} - + + +
+

{{ translate("No inventory channel found.") }}

+
@@ -114,7 +119,7 @@
- + @@ -123,8 +128,8 @@ @@ -205,4 +229,9 @@ ion-card-header { justify-content: space-between; align-items: center; } + +.actions { + display: flex; + justify-content: space-between; +} \ No newline at end of file diff --git a/src/views/SafetyStock.vue b/src/views/SafetyStock.vue index f9b7bde0..89893325 100644 --- a/src/views/SafetyStock.vue +++ b/src/views/SafetyStock.vue @@ -8,21 +8,26 @@
-
+
- + + +
-

{{ translate("No threshold rules found") }}

+

{{ translate("No safety stock rule found.") }}

- - + + + + + @@ -30,27 +35,76 @@ diff --git a/src/views/Shipping.vue b/src/views/Shipping.vue index d28da361..52b85c88 100644 --- a/src/views/Shipping.vue +++ b/src/views/Shipping.vue @@ -3,18 +3,16 @@ - {{ translate("Shipping") }} - + {{ translate("Shipping") }} - - + {{ translate("Product and facility") }} {{ translate("Product and channel") }} - + {{ translate("Facility") }} @@ -22,14 +20,18 @@ -
- +
+
-

{{ translate("No shipping rules found") }}

+

{{ translate("No shipping rule found.") }}

@@ -43,7 +45,7 @@ - - + + + + + @@ -62,9 +67,9 @@ \ No newline at end of file diff --git a/src/views/StorePickup.vue b/src/views/StorePickup.vue index 5d0e47a3..0d921546 100644 --- a/src/views/StorePickup.vue +++ b/src/views/StorePickup.vue @@ -3,18 +3,16 @@ - {{ translate("Store pickup") }} - + {{ translate("Store pickup") }} - - + {{ translate("Product and facility") }} {{ translate("Product and channel") }} - + {{ translate("Facility") }} @@ -22,14 +20,18 @@ -
- - -
- -
+
+
-

{{ translate("No store pickup rules found") }}

+

{{ translate("No store pickup rule found.") }}

@@ -44,7 +46,7 @@ - - + + + + + @@ -63,9 +68,9 @@ \ No newline at end of file diff --git a/src/views/Threshold.vue b/src/views/Threshold.vue index bf9089f1..902e228c 100644 --- a/src/views/Threshold.vue +++ b/src/views/Threshold.vue @@ -8,20 +8,25 @@ -
+
- + + +
-

{{ translate("No threshold rules found") }}

+

{{ translate("No threshold rule found.") }}

- - + + + + + @@ -30,29 +35,79 @@ diff --git a/src/views/TimezoneModal.vue b/src/views/TimezoneModal.vue index 722d2084..e415fe53 100644 --- a/src/views/TimezoneModal.vue +++ b/src/views/TimezoneModal.vue @@ -29,8 +29,7 @@ - {{ timeZone.label }} ({{ timeZone.id }}) - + {{ timeZone.label }} ({{ timeZone.id }}) @@ -54,7 +53,6 @@ import { IonHeader, IonItem, IonIcon, - IonLabel, IonRadioGroup, IonRadio, IonList, @@ -65,7 +63,7 @@ import { modalController, } from "@ionic/vue"; import { onBeforeMount, ref } from "vue"; -import { saveOutline } from "ionicons/icons"; +import { closeOutline, saveOutline } from "ionicons/icons"; import { useStore } from "@/store"; import { UserService } from "@/services/UserService"; import { hasError } from "@/utils"