diff --git a/src/components/ConfirmCancelModal.vue b/src/components/ConfirmCancelModal.vue new file mode 100644 index 000000000..4eeda2c2f --- /dev/null +++ b/src/components/ConfirmCancelModal.vue @@ -0,0 +1,199 @@ + + + \ No newline at end of file diff --git a/src/components/ReportAnIssuePopover.vue b/src/components/ReportAnIssuePopover.vue new file mode 100644 index 000000000..7e5dee84f --- /dev/null +++ b/src/components/ReportAnIssuePopover.vue @@ -0,0 +1,60 @@ + + + \ No newline at end of file diff --git a/src/locales/en.json b/src/locales/en.json index a37d286d1..84244b307 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -5,6 +5,7 @@ "Allow partial rejection": "Allow partial rejection", "An email notification will be sent to that their order is ready for pickup. This order will also be moved to the packed orders tab.": "An email notification will be sent to { customerName } that their order is ready for pickup.{ space } This order will also be moved to the packed orders tab.", "An email notification will be sent to that their order is ready for pickup.": "An email notification will be sent to { customerName } that their order is ready for pickup.", + "Approved for fulfillment": "Approved for fulfillment", "Are you sure you want to change the time zone to?": "Are you sure you want to change the time zone to?", "Are you sure you want to update the notification preferences?": "Are you sure you want to update the notification preferences?", "Arrived": "Arrived", @@ -12,11 +13,18 @@ "Available to promise": "Available to promise", "Authenticating": "Authenticating", "Assign Pickers": "Assign Pickers", + "Assigned for fulfillment": "Assigned for fulfillment", + "Authorized": "Authorized", "Browser TimeZone": "Browser TimeZone", "Browser time zone": "Browser time zone", "Catalog": "Catalog", "Cancel": "Cancel", + "Cancel items": "Cancel items", "Cancel order before fulfillment": "Cancel order before fulfillment", + "Cancelation and refund sync to Shopify is enabled.": "Cancelation and refund sync to Shopify is enabled.", + "Cancelation and refund sync to Shopify is not enabled.": "Cancelation and refund sync to Shopify is not enabled.", + "Cancelation not syncing to Shopify": "Cancelation not syncing to Shopify", + "Cancelation sync to Shopify is enabled. Refund processing is disabled.": "Cancelation sync to Shopify is enabled. Refund processing is disabled.", "canceled from the order": "canceled from the order", "Control what your customers are allowed to edit on their order when they are editing their order on Re-route Fulfillment.": "Control what your customers are allowed to edit on their order when they are editing their order on Re-route Fulfillment.", "Change": "Change", @@ -25,6 +33,7 @@ "Click the backdrop to dismiss.": "Click the backdrop to dismiss.", "Color:": "Color: {color}", "Colors": "Colors", + "Confirm Cancelation": "Confirm Cancelation", "Complete": "Complete", "Completed": "Completed", "Configuration updated": "Configuration updated", @@ -32,6 +41,7 @@ "Copied": "Copied { text }", "Copied to clipboard": "Copied to clipboard", "Copy": "Copy", + "Created in Shopify": "Created in Shopify", "Depending on the reason you select for not fulfulling an item, an inventory variance will be recorded and all sales channels will be updated with new inventory levels. For example, by selecting “Not in stock” HotWax Commerce will stop routing orders for it to your store and customers will not be able to place BOPIS orders for it at your store on Shopify.": "Depending on the reason you select for not fulfulling an item, an inventory variance will be recorded and all sales channels will be updated with new inventory levels.{ space } For example, by selecting “Not in stock” HotWax Commerce will stop routing orders for it to your store and customers will not be able to place BOPIS orders for it at your store on Shopify.", "Delivery address": "Delivery address", "Delivery method": "Delivery method", @@ -41,6 +51,8 @@ "Edit pickers": "Edit pickers", "Email sent successfully": "Email sent successfully", "Enable tracking": "Enable tracking", + "Estimated time to cancelation on Shopify": "Estimated time to cancelation on Shopify", + "Estimated time to refund customer on Shopify": "Estimated time to refund customer on Shopify", "Facility": "Facility", "Failed to load packing slip": "Failed to load packing slip", "Failed to update configuration": "Failed to update configuration", @@ -56,6 +68,7 @@ "Handover": "Handover", "Handling Instructions": "Handling Instructions", "If you cannot fulfill this order, will be sent an email with alternate fulfillment options and this order will be removed from your dashboard.": "If you cannot fulfill this order, {customerName} will be sent an email with alternate fulfillment options and this order will be removed from your dashboard.", + "Imported from Shopify": "Imported from Shopify", "Inactive store": "Inactive store", "in stock": "in stock", "Incoming": "Incoming", @@ -65,8 +78,10 @@ "Inventory": "Inventory", "Inventory computation": "Inventory computation", "Item has been rejected successfully.": "Item has been rejected successfully.", + "Kit": "Kit", "Language": "Language", "Last name": "Last name", + "Latest": "Latest", "Learn more about unfillable items": "Learn more about unfillable items", "Loading": "Loading", "Login": "Login", @@ -79,6 +94,7 @@ "No facilities found": "No facilities found", "No items found": "No items found", "No inventory details found": "No inventory details found", + "No payments found": "No payments found", "No products found": "No products found", "No notifications to show": "No notifications to show", "No picker assigned.": "No picker assigned.", @@ -99,6 +115,7 @@ "on hand": "{ count } on hand", "Other stores inventory": "Other stores inventory", "Order": "Order", + "Order completed": "Order completed", "Order delivered to": "Order delivered to { customerName }", "Order details": "Order details", "Order edit permissions": "Order edit permissions", @@ -127,10 +144,14 @@ "Packing slips help customer reconcile their order against the delivered items.": "Packing slips help customer reconcile their order against the delivered items.", "Partial Order rejection": "Partial Order rejection", "Password": "Password", + "Payment": "Payment", "Pending allocation": "Pending allocation", "pending approval": "pending approval", "Picked by": "Picked by { pickers }", + "Picked up": "Picked up", + "Pickup remainder": "Pickup remainder", "Pick up location": "Pick up location", + "Picker assigned": "Picker assigned", "Pickers successfully replaced in the picklist with the new selections.": "Pickers successfully replaced in the picklist with the new selections.", "pieces in stock": "pieces in stock", "Print picklists": "Print picklists", @@ -144,6 +165,8 @@ "Ready to create an app?": "Ready to create an app?", "Ready to ship": "Ready to ship", "Reject": "Reject", + "Rejected": "Rejected", + "Reject Items": "Reject Items", "Reject Order": "Reject Order", "Reject Order Item": "Reject Order Item", "Reason": "Reason", @@ -179,6 +202,7 @@ "Ship to this address": "Ship to this address", "Shop": "Shop", "Show shipping orders": "Show shipping orders", + "Showing the next estimated time to sync cancelation to Shopify": "Showing the next estimated time to sync cancelation to Shopify", "Size:": "Size: {size}", "Sizes": "Sizes", "Something went wrong": "Something went wrong", @@ -193,13 +217,16 @@ "Staff": "Staff", "Street": "Street", "Store": "Store", + "Summary": "Summary", "Timezone": "Timezone", + "Timeline": "Timeline", "Time zone updated successfully": "Time zone updated successfully", "The timezone you select is used to ensure automations you schedule are always accurate to the time you select.": "The timezone you select is used to ensure automations you schedule are always accurate to the time you select.", "This is the name of the OMS you are connected to right now. Make sure that you are connected to the right instance before proceeding.": "This is the name of the OMS you are connected to right now. Make sure that you are connected to the right instance before proceeding.", "Selected variant not available": "Selected variant not available", "This order cannot be split. If you cannot fulfill any item, will be sent an email with alternate fulfillment options and this order will be removed from your dashboard.": "This order cannot be split. If you cannot fulfill any item, { customerName } will be sent an email with alternate fulfillment options and this order will be removed from your dashboard.", "This order will be rejected from this store with the selected reason and shipped to the address that has been inputed.Please make sure the address you have entered is correct.": "This order will be rejected from this store with the selected reason and shipped to the address that has been inputed. { space } Please make sure the address you have entered is correct.", + "Total": "Total", "Track Pickers": "Track Pickers", "Track who picked orders by entering picker IDs when packing an order.": "Track who picked orders by entering picker IDs when packing an order.", "Unable to open as browser is blocking pop-ups.": "Unable to open { documentName } as browser is blocking pop-ups.", @@ -213,6 +240,7 @@ "Update notification preferences": "Update notification preferences", "units": "{ item } units", "unit": "{ item } unit", + "Verify that the items in the package are valid and the customer has received their order. Once the order is handed over to the customer it cannot be undone.": "Verify that the items in the package are valid and the customer has received their order.{ space }Once the order is handed over to the customer it cannot be undone.", "View shipping orders along with pickup orders.": "View shipping orders along with pickup orders.", "You do not have permission to access this page": "You do not have permission to access this page", "Zipcode": "Zipcode" diff --git a/src/locales/es.json b/src/locales/es.json index b1ae18b54..fb7da14a9 100644 --- a/src/locales/es.json +++ b/src/locales/es.json @@ -5,6 +5,7 @@ "Allow partial rejection": "Permitir rechazo parcial", "An email notification will be sent to that their order is ready for pickup. This order will also be moved to the packed orders tab.": "Se enviará una notificación por correo electrónico a {customerName} de que su pedido está listo para recoger.{ space } Este pedido también se moverá a la pestaña de pedidos empacados.", "An email notification will be sent to that their order is ready for pickup.": "Se enviará una notificación por correo electrónico a {customerName} de que su pedido está listo para recoger.", + "Approved for fulfillment": "Approved for fulfillment", "Are you sure you want to change the time zone to?": "¿Estás seguro de que quieres cambiar la zona horaria a?", "Are you sure you want to update the notification preferences?": "¿Estás seguro de que deseas actualizar las preferencias de notificación?", "Arrived": "Llegó", @@ -12,11 +13,18 @@ "Available to promise": "Available to promise", "Authenticating": "Autenticación", "Assign Pickers": "Asignar recolectores", + "Assigned for fulfillment": "Assigned for fulfillment", + "Authorized": "Authorized", "Browser TimeZone": "Browser TimeZone", "Browser time zone": "Browser time zone", "Catalog": "Catálogo", "Cancel": "Cancelar", + "Cancel items": "Cancel items", "Cancel order before fulfillment": "Cancelar pedido antes del cumplimiento", + "Cancelation and refund sync to Shopify is enabled.": "Cancelation and refund sync to Shopify is enabled.", + "Cancelation and refund sync to Shopify is not enabled.": "Cancelation and refund sync to Shopify is not enabled.", + "Cancelation not syncing to Shopify": "Cancelation not syncing to Shopify", + "Cancelation sync to Shopify is enabled. Refund processing is disabled.": "Cancelation sync to Shopify is enabled. Refund processing is disabled.", "canceled from the order": "cancelado del pedido", "Control what your customers are allowed to edit on their order when they are editing their order on Re-route Fulfillment.": "Controle lo que sus clientes pueden editar en su pedido cuando editan su pedido en Reenrutar el cumplimiento.", "Change": "Cambiar", @@ -24,6 +32,7 @@ "City": "Ciudad", "Click the backdrop to dismiss.": "Haz clic en el fondo para cerrar.", "Colors": "Colores", + "Confirm Cancelation": "Confirm Cancelation", "Complete": "Completar", "Completed": "Completado", "Configuration updated": "Configuración actualizada", @@ -31,6 +40,7 @@ "Copied": "Copiado { text }", "Copied to clipboard": "Copiado al portapapeles", "Copy": "Copiar", + "Created in Shopify": "Created in Shopify", "Depending on the reason you select for not fulfilling an item, an inventory variance will be recorded and all sales channels will be updated with new inventory levels. For example, by selecting “Not in stock” HotWax Commerce will stop routing orders for it to your store and customers will not be able to place BOPIS orders for it at your store on Shopify.": "Dependiendo de la razón que selecciones para no cumplir con un artículo, se registrará una variación de inventario y se actualizarán todos los canales de ventas con nuevos niveles de inventario. { space } Por ejemplo, al seleccionar “No disponible en el inventario” HotWax Commerce dejará de dirigir los pedidos para él a tu tienda y los clientes no podrán hacer pedidos BOPIS para él en tu tienda en Shopify.", "Delivery address": "Dirección de entrega", "Delivery method": "Método de entrega", @@ -39,6 +49,8 @@ "Edit pickers": "Editar recolectores", "Email sent successfully": "Correo enviado satisfactoriamente", "Enable tracking": "Habilitar seguimiento", + "Estimated time to cancelation on Shopify": "Estimated time to cancelation on Shopify", + "Estimated time to refund customer on Shopify": "Estimated time to refund customer on Shopify", "Facility": "Instalación", "Failed to load packing slip": "Error al cargar el documento de embalaje", "Failed to update configuration": "No se pudo actualizar la configuración", @@ -53,6 +65,7 @@ "Go to Launchpad": "Ir a la plataforma de lanzamiento", "Handover": "Entregar", "Handling Instructions": "Instrucciones de manejo", + "Imported from Shopify": "Imported from Shopify", "Inactive store": "Tienda inactiva", "in stock": "en stock", "Incoming": "Entrante", @@ -62,8 +75,10 @@ "Inventory": "Inventario", "Inventory computation": "Inventory computation", "Item has been rejected successfully.": "El artículo ha sido rechazado exitosamente.", + "Kit": "Kit", "Language": "Idioma", "Last name": "Apellido", + "Latest": "Latest", "Learn more about unfillable items": "Obtenga más información sobre artículos que no se pueden cumplir", "Loading": "Cargando", "Login": "Iniciar sesión", @@ -76,6 +91,7 @@ "No facilities found": "No facilities found", "No items found": "No se encontraron artículos", "No inventory details found": "No se encontraron detalles de inventario", + "No payments found": "No payments found", "No products found": "No se encontraron productos", "No notifications to show": "No hay notificaciones para mostrar", "No picker assigned.": "No hay recolector asignado.", @@ -96,6 +112,7 @@ "on hand": "{ count } on hand", "Other stores inventory": "Inventario de otras tiendas", "Order": "Orden", + "Order completed": "Order completed", "Order delivered to": "Orden entregada a {customerName}", "Order details": "Detalles de la orden", "Order edit permissions": "Permisos de edición de la orden", @@ -124,10 +141,14 @@ "Packing slips help customer reconcile their order against the delivered items.": "Las remisiones de embalaje ayudan al cliente a conciliar su orden con los artículos entregados.", "Partial Order rejection": "Rechazo parcial del pedido", "Password": "Contraseña", + "Payment": "Payment", "Pending allocation": "Pending allocation", "pending approval": "pendiente de aprobación", "Picked by": "Recogido por { pickers }", + "Picked up": "Picked up", + "Pickup remainder": "Pickup remainder", "Pick up location": "Ubicación de recogida", + "Picker assigned": "Picker assigned", "Pickers successfully replaced in the picklist with the new selections.": "Los recolectores fueron reemplazados exitosamente en la lista de selección con las nuevas selecciones.", "pieces in stock": "piezas en inventario", "Print picklists": "Print picklists", @@ -141,6 +162,8 @@ "Ready to create an app?": "¿Listo para crear una aplicación?", "Ready to ship": "Listo para enviar", "Reject": "Rechazar", + "Rejected": "Rejected", + "Reject Items": "Reject Items", "Reject Order": "Rechazar pedido", "Reject Order Item": "Rechazar artículo de pedido", "Reason": "Razón", @@ -176,6 +199,7 @@ "Ship to this address": "Enviar a esta dirección", "Shop": "Comprar", "Show shipping orders": "Mostrar órdenes de envío", + "Showing the next estimated time to sync cancelation to Shopify": "Showing the next estimated time to sync cancelation to Shopify", "Sizes": "Tamaños", "Something went wrong": "Algo salió mal", "Something went wrong, could not edit picker.": "Algo salió mal, no se pudo editar el recolector.", @@ -190,6 +214,8 @@ "Staff": "Personal", "Street": "Calle", "Store": "Tienda", + "Summary": "Summary", + "Timeline": "Timeline", "Timezone": "Zona horaria", "Time zone updated successfully": "Zona horaria actualizada exitosamente", "The timezone you select is used to ensure automations you schedule are always accurate to the time you select.": "La zona horaria que selecciones se utiliza para garantizar que las automatizaciones que programaste siempre sean precisas en la hora que seleccionaste.", @@ -197,6 +223,7 @@ "Selected variant not available": "Variante seleccionada no disponible", "This order cannot be split. If you cannot fulfill any item, an email will be sent with alternate fulfillment options, and this order will be removed from your dashboard.": "Este pedido no se puede dividir. Si no puedes cumplir con algún artículo, { customerName } se enviará un correo electrónico con opciones de cumplimiento alternativas y este pedido se eliminará de tu panel de control.", "This order will be rejected from this store with the selected reason and shipped to the address that has been inputted. Please make sure the address you have entered is correct.": "Este pedido será rechazado en esta tienda con la razón seleccionada y se enviará a la dirección que se ha ingresado.{ space } Por favor, asegúrate de que la dirección que has ingresado sea correcta.", + "Total": "Total", "Track Pickers": "Seguimiento de recolectores", "Track who picked orders by entering picker IDs when packing an order.": "Realiza un seguimiento de quién recogió los pedidos ingresando los ID de los recolectores al empacar un pedido.", "Unable to open as browser is blocking pop-ups.": "No se puede abrir {documentName} porque el navegador bloquea las ventanas emergentes.", @@ -210,6 +237,7 @@ "Update notification preferences": "Actualizar preferencias de notificación", "units": "{ item } units", "unit": "{ item } unit", + "Verify that the items in the package are valid and the customer has received their order. Once the order is handed over to the customer it cannot be undone.": "Verify that the items in the package are valid and the customer has received their order.{ space }Once the order is handed over to the customer it cannot be undone.", "View shipping orders along with pickup orders.": "Ver órdenes de envío junto con órdenes de recogida.", "You do not have permission to access this page": "No tienes permiso para acceder a esta página", "Zipcode": "Código postal", diff --git a/src/locales/ja.json b/src/locales/ja.json index 053f46d0d..b1b420a48 100644 --- a/src/locales/ja.json +++ b/src/locales/ja.json @@ -5,6 +5,7 @@ "Allow partial rejection": "部分的な拒否を許可します", "An email notification will be sent to that their order is ready for pickup. This order will also be moved to the packed orders tab.": "{ customerName }様宛に注文の受け取り準備が完了したことをお知らするメールが送信されます。{ space } この注文は「梱包済み注文」タブに移動されます.", "An email notification will be sent to that their order is ready for pickup.": "{ customerName }様宛に注文の受け取り準備が完了したことをお知らするメールが送信されます。", + "Approved for fulfillment": "Approved for fulfillment", "Are you sure you want to change the time zone to?": "タイムゾーンを変更してもよろしいですか?", "Are you sure you want to update the notification preferences?": "通知設定を更新してもよろしいですか?", "Arrived": "到着", @@ -12,18 +13,26 @@ "Available to promise": "引当可能在庫", "Authenticating": "認証中", "Assign Pickers": "受け取り人の割当", + "Assigned for fulfillment": "Assigned for fulfillment", + "Authorized": "Authorized", "Browser TimeZone": "ブラウザーのタイムゾーン", "Browser time zone": "ブラウザーのタイムゾーン", "Catalog": "カタログ", "Cancel": "キャンセル", + "Cancel items": "Cancel items", "Cancel order before fulfillment": "注文のキャンセル", "canceled from the order": "注文がキャンセルされました", + "Cancelation and refund sync to Shopify is enabled.": "Cancelation and refund sync to Shopify is enabled.", + "Cancelation and refund sync to Shopify is not enabled.": "Cancelation and refund sync to Shopify is not enabled.", + "Cancelation not syncing to Shopify": "Cancelation not syncing to Shopify", + "Cancelation sync to Shopify is enabled. Refund processing is disabled.": "Cancelation sync to Shopify is enabled. Refund processing is disabled.", "Control what your customers are allowed to edit on their order when they are editing their order on Re-route Fulfillment.": "お客様がリルート(受取方法や受取場所の変更)で注文を編集する際に、注文の編集を許可する内容を制御します。", "Change": "変更", "Choose language": "言語を選択", "City": "街", "Click the backdrop to dismiss.": "背景をクリックして閉じます。", "Colors": "色", + "Confirm Cancelation": "Confirm Cancelation", "Complete": "完了", "Completed": "完了", "Configuration updated": "設定の更新", @@ -31,6 +40,7 @@ "Copied": "コピーされた{ text }", "Copied to clipboard": "クリップボードにコピーしました", "Copy": "コピー", + "Created in Shopify": "Created in Shopify", "Depending on the reason you select for not fulfulling an item, an inventory variance will be recorded and all sales channels will be updated with new inventory levels. For example, by selecting “Not in stock” HotWax Commerce will stop routing orders for it to your store and customers will not be able to place BOPIS orders for it at your store on Shopify.": "アイテムをフルフィルメントしないために選択した理由に応じて、在庫差異が記録され、すべての販売チャネルが新しい在庫レベルで更新されます。{ space } たとえば、[在庫なし] を選択すると、HotWax Commerce はストアへの注文のルーティングを停止し、顧客は 貴方の Shopify のストアで BOPIS 注文を行うことができなくなります。", "Delivery address": "お届け先住所", "Delivery method": "配送方法", @@ -39,6 +49,8 @@ "Edit pickers": "編集ピッカー", "Email sent successfully": "メールの送信が完了しました。", "Enable tracking": "追跡を有効", + "Estimated time to cancelation on Shopify": "Estimated time to cancelation on Shopify", + "Estimated time to refund customer on Shopify": "Estimated time to refund customer on Shopify", "Facility": "拠点", "Failed to load packing slip": "納品書の読み込みに失敗しました", "Failed to update configuration": "設定の更新に失敗しました", @@ -53,6 +65,7 @@ "Go to Launchpad": "Launchpadへ移動", "Handover": "引き継ぐ", "Handling Instructions": "取扱説明", + "Imported from Shopify": "Imported from Shopify", "Inactive store": "休止店舗", "in stock": "在庫あり", "Incoming": "移動中", @@ -62,8 +75,10 @@ "Inventory": "在庫", "Inventory computation": "在庫計算", "Item has been rejected successfully.": "商品は正常に拒否されました。", + "Kit": "Kit", "Language": "言語", "Last name": "姓", + "Latest": "Latest", "Learn more about unfillable items": "記入できない項目の詳細", "Loading": "読み込み中", "Login": "ログイン", @@ -76,6 +91,7 @@ "No facilities found": "No facilities found", "No items found": "アイテムが見つかりませんでした", "No inventory details found": "在庫の詳細が見つかりません", + "No payments found": "No payments found", "No products found": "商品が見つかりません", "No notifications to show": "表示する通知はありません", "No picker assigned.": "ピッカーが割り当てられていません。", @@ -96,6 +112,7 @@ "on hand": "{count} 在庫あり", "Other stores inventory": "その他店舗在庫", "Order": "注文", + "Order completed": "Order completed", "Order delivered to": "注文は { customerName }様 に配達されました", "Order details": "注文詳細", "Order edit permissions": "注文の編集権限", @@ -123,10 +140,14 @@ "Packing slips help customer reconcile their order against the delivered items.": "内容明細票はお客様が注文と配送された商品を確認(照合)する際に役立ちます。", "Partial Order rejection": "部分的な注文拒否", "Password": "パスワード", + "Payment": "Payment", "Pending allocation": "Pending allocation", "pending approval": "承認待ち", "Picked by": "{pickers} によってピックアップされました", + "Picked up": "Picked up", + "Pickup remainder": "Pickup remainder", "Pick up location": "受取場所", + "Picker assigned": "Picker assigned", "Pickers successfully replaced in the picklist with the new selections.": "ピッカーは新しい選択によりピックリストで正常に置き換えられました。", "pieces in stock": "在庫あり", "Print picklists": "Print picklists", @@ -140,6 +161,8 @@ "Ready to create an app?": "アプリを作成する準備はできましたか?", "Ready to ship": "出荷する準備ができました", "Reject": "Reject", + "Rejected": "Rejected", + "Reject Items": "Reject Items", "Reject Order": "注文を拒否", "Reject Order Item": "Reject Order Item", "Reason": "理由", @@ -175,6 +198,7 @@ "Ship to this address": "この住所に配送", "Shop": "ショップ", "Show shipping orders": "出荷オーダーの表示", + "Showing the next estimated time to sync cancelation to Shopify": "Showing the next estimated time to sync cancelation to Shopify", "Sizes": "サイズ", "Something went wrong": "エラーが発生しました", "Something went wrong, could not edit picker.": "問題が発生しました。ピッカーを編集できませんでした。", @@ -188,6 +212,8 @@ "Staff": "スタッフ", "Street": "市区町村", "Store": "ストア", + "Summary": "Summary", + "Timeline": "Timeline", "Timezone": "タイムゾーン", "Time zone updated successfully": "タイムゾーンの更新成功", "The timezone you select is used to ensure automations you schedule are always accurate to the time you select.": "あなたが選択したタイムゾーンは、あなたがスケジュールしたオートメーション(自動操作)が常にあなたが選択した時間に正確であることを保証するために使用されます。", @@ -195,6 +221,7 @@ "Selected variant not available": "選択したバリアントは利用できません", "This order cannot be split. If you cannot fulfill any item, will be sent an email with alternate fulfillment options and this order will be removed from your dashboard.": "この注文は分割できません。どのアイテムもフィフィルできない場合、{ customerName } に別の発送オプションを記載したメールが送信され、ダッシュボードから注文が削除されます。", "This order will be rejected from this store with the selected reason and shipped to the address that has been inputed.Please make sure the address you have entered is correct.": "この注文は、選択された理由によりこのストアから拒否され、入力された住所に発送されます。{ space } 入力したアドレスが正しいことを確認してください。", + "Total": "Total", "Track Pickers": "受取人の追跡", "Track who picked orders by entering picker IDs when packing an order.": "注文を梱包する際に受取人IDを入力することで、誰が注文を受け取ったかを追跡できます。", "Unable to open as browser is blocking pop-ups.": "ブラウザーがポップアップをブロックしているため、{documentName} を開くことができません。", @@ -208,6 +235,7 @@ "Update notification preferences": "Update notification preferences", "units": "{ item }個", "unit": "{ item }個", + "Verify that the items in the package are valid and the customer has received their order. Once the order is handed over to the customer it cannot be undone.": "Verify that the items in the package are valid and the customer has received their order.{ space }Once the order is handed over to the customer it cannot be undone.", "View shipping orders along with pickup orders.": "店舗受取の注文と一緒に配送注文を表示します", "You do not have permission to access this page": "このページにアクセスする権限がありません", "Zipcode": "郵便番号" diff --git a/src/router/index.ts b/src/router/index.ts index 61bb86b32..fb9bc9898 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -15,6 +15,7 @@ import { translate } from '@hotwax/dxp-components' import 'vue-router' import { DxpLogin, useAuthStore } from '@hotwax/dxp-components'; import { loader } from '@/utils/user'; +import OrderDetailUpdated from '@/views/OrderDetailUpdated.vue'; // Defining types for the meta values declare module 'vue-router' { @@ -89,7 +90,7 @@ const routes: Array = [ { path: "/orderdetail/:orderType/:orderId/:orderPartSeqId", name: "OrderDetail", - component: OrderDetail, + component: OrderDetailUpdated, beforeEnter: authGuard, props: true, meta: { diff --git a/src/services/OrderService.ts b/src/services/OrderService.ts index fcc947714..d0290c4c5 100644 --- a/src/services/OrderService.ts +++ b/src/services/OrderService.ts @@ -1,4 +1,4 @@ -import { api, client, hasError } from '@/adapter'; +import { api, hasError } from '@/adapter'; import emitter from '@/event-bus'; import { translate } from '@hotwax/dxp-components'; import store from '@/store'; @@ -347,7 +347,24 @@ const packOrder = async (payload: any): Promise => { }) } +const performFind = async (payload: any): Promise => { + return api({ + url: "performFind", + method: "post", + data: payload + }); +} + +const cancelItem = async (payload: any): Promise => { + return api({ + url: "cancelOrderItem", + method: "post", + data: payload + }); +} + export const OrderService = { + cancelItem, fetchOrderItems, fetchOrderPaymentPreferences, fetchTrackingCodes, @@ -368,6 +385,7 @@ export const OrderService = { getCustomerContactDetails, getShippingPhoneNumber, packOrder, + performFind, printPicklist, printShippingLabelAndPackingSlip } \ No newline at end of file diff --git a/src/services/UtilService.ts b/src/services/UtilService.ts index fc5877bec..319677eb5 100644 --- a/src/services/UtilService.ts +++ b/src/services/UtilService.ts @@ -115,14 +115,32 @@ const isEnumExists = async (enumId: string): Promise => { } } +const fetchJobInformation = async (payload: any): Promise => { + return api({ + url: "/findJobs", + method: "get", + params: payload + }); +} + +const getProcessRefundStatus = async (payload: any): Promise => { + return api({ + url: "performFind", + method: "post", + data: payload + }); +} + export const UtilService = { createEnumeration, createProductStoreSetting, fetchFacilityTypeInformation, + fetchJobInformation, fetchPartyInformation, fetchPaymentMethodTypeDesc, fetchRejectReasons, fetchStatusDesc, + getProcessRefundStatus, getProductStoreSettings, isEnumExists, resetPicker, diff --git a/src/store/modules/order/actions.ts b/src/store/modules/order/actions.ts index 1e0393504..24802e596 100644 --- a/src/store/modules/order/actions.ts +++ b/src/store/modules/order/actions.ts @@ -159,7 +159,8 @@ const actions: ActionTree ={ productId: item.productId, facilityId: item.facilityId, quantity: item.itemQuantity, - inventoryItemId: item.inventoryItemId + inventoryItemId: item.inventoryItemId, + showKitComponents: false }] }) } else { @@ -170,7 +171,8 @@ const actions: ActionTree ={ productId: item.productId, facilityId: item.facilityId, quantity: item.itemQuantity, - inventoryItemId: item.inventoryItemId + inventoryItemId: item.inventoryItemId, + showKitComponents: false }) } @@ -180,6 +182,14 @@ const actions: ActionTree ={ shippingInstructions: orderItem.shippingInstructions, shipGroupSeqId: orderItem.shipGroupSeqId, isPicked: orderItem.isPicked, + pickers: orderItem.pickers ? (orderItem.pickers.reduce((names: any, picker: string) => { + names.push(picker.split('/')[1]); + return names; + }, [])).join(', ') : "", + pickerIds: orderItem.pickers ? (orderItem.pickers.reduce((ids: any, picker: string) => { + ids.push(picker.split('/')[0]); + return ids; + }, [])) : "", picklistId: orderItem.picklistId, picklistBinId: orderItem.picklistBinId } @@ -203,10 +213,196 @@ const actions: ActionTree ={ return resp; }, - async getOrderDetail({ dispatch, state }, { payload, orderType }) { + async fetchAdditionalOrderInformation({ dispatch }, orderDetails) { + let order = orderDetails; + const orderId = order.orderId + + try { + const apiPayload = [{ + inputFields: { + orderId + }, + viewSize: 50, + filterByDate: "Y", + entityName: "OrderHeaderAndRoles" + }, { + inputFields: { + orderId, + contactMechPurposeTypeId: ["BILLING_LOCATION", "BILLING_EMAIL", "PHONE_BILLING"], + contactMechPurposeTypeId_op: "in" + }, + viewSize: 50, + fieldList: ["contactMechPurposeTypeId", "contactMechId"], + entityName: "OrderContactMech" + }, { + inputFields: { + orderId + }, + viewSize: 50, + filterByDate: "Y", + fieldList: ["orderIdentificationTypeId", "orderId", "idValue"], + entityName: "OrderIdentification" + }, { + inputFields: { + orderId, + attrName: ["customerId", "municipio"], + attrName_op: "in", + attrName_ic: "Y" + }, + viewSize: 50, + fieldList: ["attrName", "attrValue"], + entityName: "OrderAttribute" + }, { + inputFields: { + orderId, + statusId: ["ORDER_COMPLETED", "ORDER_APPROVED"], + statusId_op: "in" + }, + viewSize: 2, + entityName: "OrderStatus" + }, { + inputFields: { + orderId, + statusId: "PAYMENT_CANCELLED", + statusId_op: "notEqual" + }, + orderBy: "createdDate DESC", + viewSize: 50, + fieldList: ["paymentMethodTypeId", "maxAmount", "statusId"], + entityName: "OrderPaymentPreference" + }, { + inputFields: { + orderId + }, + viewSize: 50, + entityName: "OrderItemShipGroupAndFacility" + }] + + const [orderHeader, orderContactMech, orderIdentifications, orderAttributes, orderStatusInfo, orderPaymentPreference] = await Promise.allSettled(apiPayload.map((payload: any) => OrderService.performFind(payload))) + + if(orderHeader.status === "fulfilled" && !hasError(orderHeader.value) && orderHeader.value.data.count > 0) { + order = { + ...order, + ...orderHeader.value.data.docs[0] + } + + if(!order.orderId) { + throw "Failed to fetch order information" + } + } + if(orderContactMech.status === "fulfilled" && !hasError(orderContactMech.value) && orderContactMech.value.data.count > 0) { + const orderContactMechTypes: any = orderContactMech.value.data.docs.reduce((contactMechTypes: any, contactMech: any) => { + contactMechTypes[contactMech.contactMechPurposeTypeId] = contactMech.contactMechId + + return contactMechTypes; + }, {}) + + const postalAddress = await OrderService.performFind({ + inputFields: { + contactMechId: Object.keys(orderContactMechTypes).filter((mechType: string) => mechType === "BILLING_LOCATION").map((mechType: string) => orderContactMechTypes[mechType]), + contactMechId_op: "in" + }, + viewSize: 20, + entityName: "PostalAddressAndGeo" + }) + + if(!hasError(postalAddress) && postalAddress.data.count > 0) { + postalAddress.data.docs.map((address: any) => { + if(address.contactMechId === orderContactMechTypes["BILLING_LOCATION"]) { + order["billingAddress"] = address + } + }) + } + + const customerInfo = await OrderService.performFind({ + inputFields: { + contactMechId: Object.keys(orderContactMechTypes).filter((mechType: string) => mechType === "BILLING_EMAIL" || mechType === "PHONE_BILLING").map((mechType: string) => orderContactMechTypes[mechType]), + contactMechId_op: "in" + }, + viewSize: 20, + fieldList: ["infoString", "contactMechId", "tnContactNumber"], + entityName: "ContactMechDetail" + }) + + if(!hasError(customerInfo) && customerInfo.data.count > 0) { + customerInfo.data.docs.map((info: any) => { + if(info.contactMechId === orderContactMechTypes["BILLING_EMAIL"]) { + order["billingEmail"] = info.infoString + } + + if(info.contactMechId === orderContactMechTypes["PHONE_BILLING"]) { + order["billingPhone"] = info.tnContactNumber + } + }) + } + } + + // Fetching order identifications + if(orderIdentifications.status === "fulfilled" && !hasError(orderIdentifications.value) && orderIdentifications.value.data.count > 0) { + order["shopifyOrderId"] = orderIdentifications.value.data.docs.find((identification: any) => identification.orderIdentificationTypeId === "SHOPIFY_ORD_ID")?.idValue + } + + // Fetching order attributes + order["orderAttributes"] = {} + if(orderAttributes.status === "fulfilled" && !hasError(orderAttributes.value) && orderAttributes.value.data.count > 0) { + orderAttributes.value.data.docs.map((attribute: any) => { + // For some attbiutes we get casing difference, like customerId, CustomerId, so adding ic in performFind, but to display it correctly on UI, converting it into lowerCase + order["orderAttributes"][attribute.attrName.toLowerCase()] = attribute.attrValue + }) + } + + // Fetching brokering information for order + if(orderStatusInfo.status === "fulfilled" && !hasError(orderStatusInfo.value) && orderStatusInfo.value.data.count > 0) { + order["approvedDate"] = orderStatusInfo.value.data.docs.find((info: any) => info.statusId === "ORDER_APPROVED")?.statusDatetime + order["completedDate"] = orderStatusInfo.value.data.docs.find((info: any) => info.statusId === "ORDER_COMPLETED")?.statusDatetime + } + + // Fetching payment preference for order + if(orderPaymentPreference.status === "fulfilled" && !hasError(orderPaymentPreference.value) && orderPaymentPreference.value.data.count > 0) { + const paymentMethodTypeIds: Array = []; + const statusIds: Array = []; + order["orderPayments"] = orderPaymentPreference.value.data.docs.map((paymentPreference: any) => { + paymentMethodTypeIds.push(paymentPreference.paymentMethodTypeId) + statusIds.push(paymentPreference.statusId) + return { + amount: paymentPreference["maxAmount"], + methodTypeId: paymentPreference["paymentMethodTypeId"], + paymentStatus: paymentPreference["statusId"] + } + }) + + this.dispatch("util/fetchStatusDesc", statusIds) + + if(paymentMethodTypeIds.length) { + this.dispatch("util/fetchPaymentMethodTypeDesc", paymentMethodTypeIds) + } + } + + if(order.picklistId) { + const picklistInfo = await OrderService.performFind({ + inputFields: { + picklistId: order.picklistId, + }, + viewSize: 1, + entityName: "Picklist", + fieldList: ["picklistId", "picklistDate"] + }) + + if(!hasError(picklistInfo) && picklistInfo.data.count > 0) { + order["picklistDate"] = picklistInfo.data.docs[0].picklistDate + } + } + } catch(err) { + logger.error(err) + } + + await dispatch('updateCurrent', { order }) + }, + + async getOrderDetail({ dispatch }, { payload, orderType }) { if(orderType === 'open') { payload['orderStatusId'] = "ORDER_APPROVED" - payload['-shipmentStatusId'] = "*" + payload['-shipmentStatusId'] = "(SHIPMENT_PACKED OR SHIPMENT_SHIPPED)" payload['-fulfillmentStatus'] = '(Cancelled OR Rejected)' } else if(orderType === 'packed') { payload['shipmentStatusId'] = "SHIPMENT_PACKED" @@ -219,24 +415,24 @@ const actions: ActionTree ={ return; } - const current = state.current as any - const orders = JSON.parse(JSON.stringify(state.open.list)) as any - // As one order can have multiple parts thus checking orderId and partSeq as well before making any api call - if(current.orderId === payload.orderId && current.orderType === orderType && current.part?.orderPartSeqId === payload.orderPartSeqId) { - await this.dispatch('product/getProductInformation', { orders: [ current ] }) - await dispatch('fetchShipGroupForOrder'); - return current - } - if(orders.length) { - const order = orders.find((order: any) => { - return order.orderId === payload.orderId; - }) - if(order) { - await dispatch('updateCurrent', { order }) - return order; - } - } - + // const current = state.current as any + // const orders = JSON.parse(JSON.stringify(state.open.list)) as any + // // As one order can have multiple parts thus checking orderId and partSeq as well before making any api call + // if(current.orderId === payload.orderId && current.orderType === orderType && current.part?.orderPartSeqId === payload.orderPartSeqId) { + // await this.dispatch('product/getProductInformation', { orders: [ current ] }) + // // TODO: if we can store additional order information and just fetch shipGroup info as it was previously + // await dispatch("fetchAdditionalOrderInformation", current) + // return current + // } + // if(orders.length) { + // const order = orders.find((order: any) => { + // return order.orderId === payload.orderId; + // }) + // if(order) { + // await dispatch("fetchAdditionalOrderInformation", order) + // return order; + // } + // } const orderQueryPayload = prepareOrderQuery({ ...payload, @@ -254,6 +450,7 @@ const actions: ActionTree ={ return { orderId: orderItem.orderId, orderName: orderItem.orderName, + shipmentId: orderItem.shipmentId, customer: { partyId: orderItem.customerId, name: orderItem.customerName @@ -272,7 +469,11 @@ const actions: ActionTree ={ orderItemSeqId: item.orderItemSeqId, productId: item.productId, facilityId: item.facilityId, - quantity: item.itemQuantity + quantity: item.itemQuantity, + showKitComponents: false, + shipGroupSeqId: item.shipGroupSeqId, + orderId: orderItem.orderId, + inventoryItemId: item.inventoryItemId }] }) } else { @@ -280,13 +481,18 @@ const actions: ActionTree ={ orderItemSeqId: item.orderItemSeqId, productId: item.productId, facilityId: item.facilityId, - quantity: item.itemQuantity + quantity: item.itemQuantity, + showKitComponents: false, + shipGroupSeqId: item.shipGroupSeqId, + orderId: orderItem.orderId, + inventoryItemId: item.inventoryItemId }) } return arr }, [])), placedDate: orderItem.orderDate, + entryDate: orderItem.entryDate, shippingInstructions: orderItem.shippingInstructions, orderType: orderType, pickers: orderItem.pickers ? (orderItem.pickers.reduce((names: any, picker: string) => { @@ -297,7 +503,8 @@ const actions: ActionTree ={ ids.push(picker.split('/')[0]); return ids; }, [])) : "", - picklistId: orderItem.picklistId + picklistId: orderItem.picklistId, + shipGroupSeqId: orderItem.shipGroupSeqId } }) @@ -313,14 +520,21 @@ const actions: ActionTree ={ logger.error(err) } - await dispatch('updateCurrent', { order: currentOrder }) + await dispatch("fetchAdditionalOrderInformation", currentOrder) }, - + async updateCurrent ({ commit, dispatch }, payload) { commit(types.ORDER_CURRENT_UPDATED, { order: payload.order }) await dispatch('fetchShipGroupForOrder'); }, + // This action is added mainly to toggle the showKitComponent property for item from the order detail page + // TODO: check whether we can use this action instead of calling updateCurrent on order info update + // as calling update current again fetches the shipGroup info which is not required in all the cases. + async updateCurrentOrderInfo ({ commit }, order) { + commit(types.ORDER_CURRENT_UPDATED, { order }) + }, + async updateOrderItemFetchingStatus ({ commit, state }, payload) { const order = state.current ? JSON.parse(JSON.stringify(state.current)) : {}; @@ -380,14 +594,16 @@ const actions: ActionTree ={ items: [{ orderItemSeqId: item.orderItemSeqId, productId: item.productId, - facilityId: item.facilityId + facilityId: item.facilityId, + showKitComponents: false }] }) } else { currentOrderPart.items.push({ orderItemSeqId: item.orderItemSeqId, productId: item.productId, - facilityId: item.facilityId + facilityId: item.facilityId, + showKitComponents: false }) } @@ -462,24 +678,39 @@ const actions: ActionTree ={ if (!currentOrderPart) { arr.push({ orderPartSeqId: item.shipGroupSeqId, + shipmentMethodEnum: { + shipmentMethodEnumId: item.shipmentMethodTypeId, + shipmentMethodEnumDesc: item.shipmentMethodTypeDesc + }, items: [{ orderItemSeqId: item.orderItemSeqId, productId: item.productId, - facilityId: item.facilityId + facilityId: item.facilityId, + showKitComponents: false }] }) } else { currentOrderPart.items.push({ orderItemSeqId: item.orderItemSeqId, productId: item.productId, - facilityId: item.facilityId + facilityId: item.facilityId, + showKitComponents: false }) } return arr }, [])), placedDate: orderItem.orderDate, - shipGroupSeqId: orderItem.shipGroupSeqId + shipGroupSeqId: orderItem.shipGroupSeqId, + pickers: orderItem.pickers ? (orderItem.pickers.reduce((names: any, picker: string) => { + names.push(picker.split('/')[1]); + return names; + }, [])).join(', ') : "", + pickerIds: orderItem.pickers ? (orderItem.pickers.reduce((ids: any, picker: string) => { + ids.push(picker.split('/')[0]); + return ids; + }, [])) : "", + picklistId: orderItem.picklistId } }) @@ -528,7 +759,7 @@ const actions: ActionTree ={ if(order.part.shipmentMethodEnum.shipmentMethodEnumId === 'STOREPICKUP'){ order = { ...order, handovered: true } - }else { + } else { order = { ...order, shipped: true } } diff --git a/src/store/modules/user/actions.ts b/src/store/modules/user/actions.ts index 127f07e11..0f3323356 100644 --- a/src/store/modules/user/actions.ts +++ b/src/store/modules/user/actions.ts @@ -151,6 +151,7 @@ const actions: ActionTree = { dispatch('clearNotificationState') dispatch('clearPartialOrderRejectionConfig'); this.dispatch('util/updateRejectReasons', []) + this.dispatch('util/updateCancelReasons', []) this.dispatch('order/clearOrders') commit(types.USER_END_SESSION) resetPermissions(); diff --git a/src/store/modules/util/UtilState.ts b/src/store/modules/util/UtilState.ts index fa86a09d2..b251751c6 100644 --- a/src/store/modules/util/UtilState.ts +++ b/src/store/modules/util/UtilState.ts @@ -4,4 +4,5 @@ export default interface UtilState { statusDesc: any; facilityTypeDesc: any; partyNames: any; + cancelReasons: Array; } \ No newline at end of file diff --git a/src/store/modules/util/actions.ts b/src/store/modules/util/actions.ts index 200bdd2e7..fb1336216 100644 --- a/src/store/modules/util/actions.ts +++ b/src/store/modules/util/actions.ts @@ -6,6 +6,7 @@ import { UtilService } from '@/services/UtilService' import { hasError } from '@/adapter' import logger from '@/logger' import store from '@/store' +import { OrderService } from '@/services/OrderService' const actions: ActionTree = { async fetchRejectReasons({ commit }) { @@ -86,10 +87,42 @@ const actions: ActionTree = { commit(types.UTIL_REJECT_REASONS_UPDATED, rejectReasons) }, + async fetchCancelReasons({ commit }) { + let cancelReasons = []; + const payload = { + "inputFields": { + "enumTypeId": "ODR_ITM_CH_REASON" + }, + "fieldList": ["enumId", "description"], + "entityName": "Enumeration", + "distinct": "Y", + "viewSize": 100, + "orderBy": "sequenceNum" + } + + try { + const resp = await OrderService.performFind(payload) + + if(!hasError(resp) && resp.data.count > 0) { + cancelReasons = resp.data.docs + } else { + throw resp.data + } + } catch (err) { + logger.error('Failed to fetch cancel reasons', err) + } + + commit(types.UTIL_CANCEL_REASONS_UPDATED, cancelReasons) + }, + async updateRejectReasons({ commit }, payload) { commit(types.UTIL_REJECT_REASONS_UPDATED, payload) }, + async updateCancelReasons({ commit }, payload) { + commit(types.UTIL_CANCEL_REASONS_UPDATED, payload) + }, + async fetchPaymentMethodTypeDesc({ commit, state }, paymentMethodTypeIds) { let paymentMethodTypeDesc = JSON.parse(JSON.stringify(state.paymentMethodTypeDesc)) const cachedPaymentMethodTypeIds = Object.keys(paymentMethodTypeDesc); diff --git a/src/store/modules/util/getters.ts b/src/store/modules/util/getters.ts index cdd2e3064..717c702aa 100644 --- a/src/store/modules/util/getters.ts +++ b/src/store/modules/util/getters.ts @@ -18,5 +18,8 @@ const getters: GetterTree = { getPartyName: (state) => (partyId: string) => { return state.partyNames[partyId] ? state.partyNames[partyId] : '' }, + getCancelReasons(state) { + return state.cancelReasons ? state.cancelReasons : [] + }, } export default getters; \ No newline at end of file diff --git a/src/store/modules/util/index.ts b/src/store/modules/util/index.ts index 7228f9efc..d7b43fe4e 100644 --- a/src/store/modules/util/index.ts +++ b/src/store/modules/util/index.ts @@ -13,6 +13,7 @@ const utilModule: Module = { statusDesc: {}, facilityTypeDesc: {}, partyNames: {}, + cancelReasons: [] }, getters, actions, diff --git a/src/store/modules/util/mutation-types.ts b/src/store/modules/util/mutation-types.ts index 10114d9eb..f455f9bd7 100644 --- a/src/store/modules/util/mutation-types.ts +++ b/src/store/modules/util/mutation-types.ts @@ -3,4 +3,5 @@ export const UTIL_REJECT_REASONS_UPDATED = SN_UTIL + '/REJECT_REASONS_UPDATED' export const UTIL_STATUS_UPDATED = SN_UTIL + '/STATUS_UPDATED' export const UTIL_PAYMENT_METHODS_UPDATED = SN_UTIL + '/PAYMENT_METHODS_UPDATED' export const UTIL_FACILITY_TYPE_UPDATED = SN_UTIL + '/FACILITY_TYPE_UPDATED' -export const UTIL_PARTY_NAMES_UPDATED = SN_UTIL + '/PARTY_NAMES_UPDATED' \ No newline at end of file +export const UTIL_PARTY_NAMES_UPDATED = SN_UTIL + '/PARTY_NAMES_UPDATED' +export const UTIL_CANCEL_REASONS_UPDATED = SN_UTIL + '/CANCEL_REASONS_UPDATED' diff --git a/src/store/modules/util/mutations.ts b/src/store/modules/util/mutations.ts index d2c275e1c..262b67cc1 100644 --- a/src/store/modules/util/mutations.ts +++ b/src/store/modules/util/mutations.ts @@ -18,5 +18,8 @@ const mutations: MutationTree = { [types.UTIL_PARTY_NAMES_UPDATED](state, payload) { state.partyNames = payload }, + [types.UTIL_CANCEL_REASONS_UPDATED] (state, payload) { + state.cancelReasons = payload + }, } export default mutations; \ No newline at end of file diff --git a/src/utils/index.ts b/src/utils/index.ts index 2ec41f243..4d0fcc87b 100644 --- a/src/utils/index.ts +++ b/src/utils/index.ts @@ -78,4 +78,35 @@ const getCurrentFacilityId = () => { return currentFacility?.facilityId } -export { copyToClipboard, showToast, handleDateTimeInput, getFeature, formatPhoneNumber, getCurrentFacilityId } +const getColorByDesc = (desc: string) => ({ + "Approved": "primary", + "Authorized": "medium", + "Cancelled": "danger", + "Completed": "success", + "Created": "medium", + "Declined": "danger", + "Held": "warning", + "Not-Authorized": "warning", + "Not-Received": "warning", + "Pending": "warning", + "Picked up": "success", + "Picking": "dark", + "Ready for pickup": "primary", + "Received": "success", + "Refunded": "success", + "Reserved": "medium", + "Settled": "success", + "default": "medium" +} as any)[desc] + +const currentSymbol: any = { + "USD": "$", + "EUR": "€", + "JPY": "¥" +} + +const formatCurrency = (amount: any, code: string) => { + return `${currentSymbol[code] || code} ${amount || 0}` +} + +export { copyToClipboard, showToast, handleDateTimeInput, getFeature, formatPhoneNumber, getCurrentFacilityId, getColorByDesc, formatCurrency } diff --git a/src/utils/order.ts b/src/utils/order.ts index ceec35c45..6b43cfa1a 100644 --- a/src/utils/order.ts +++ b/src/utils/order.ts @@ -124,9 +124,21 @@ const removeKitComponents = (parts: any) => { return updatedParts; }; +const getOrderStatus = (order: any, part: any, orderRouteSegment: any) => { + if(order.statusId === "ORDER_COMPLETED") { + return part.shipmentMethodEnum.shipmentMethodEnumId === "STOREPICKUP" ? "Picked up" : "Completed" + } + + if(orderRouteSegment?.length) { + return orderRouteSegment[0]?.shipmentStatusId === "SHIPMENT_PACKED" ? "Ready for pickup" : orderRouteSegment[0]?.shipmentStatusId === "SHIPMENT_APPROVED" && order.pickers ? "Picking" : "Reserved" + } + + return "Reserved" +} export { getOrderCategory, + getOrderStatus, isKit, removeKitComponents } \ No newline at end of file diff --git a/src/views/AssignPickerModal.vue b/src/views/AssignPickerModal.vue index c356925d0..04cc0e5c5 100644 --- a/src/views/AssignPickerModal.vue +++ b/src/views/AssignPickerModal.vue @@ -133,7 +133,8 @@ export default defineComponent({ }, readyForPickup () { if (this.selectedPicker) { - modalController.dismiss({ dismissed: true, selectedPicker: this.selectedPicker }); + const picker = this.availablePickers.find((picker) => picker.id == this.selectedPicker); + modalController.dismiss({ dismissed: true, selectedPicker: this.selectedPicker, picker }); } else { showToast(translate('Select a picker')) } diff --git a/src/views/OrderDetailUpdated.vue b/src/views/OrderDetailUpdated.vue new file mode 100644 index 000000000..4bc818704 --- /dev/null +++ b/src/views/OrderDetailUpdated.vue @@ -0,0 +1,1329 @@ + + + + + \ No newline at end of file