Skip to content

Commit

Permalink
Merge pull request #37 from bashu22tiwari/#1xx2h84
Browse files Browse the repository at this point in the history
Improved code to get orderName if it is present and removed the code for order Identification (1xx2h84)
  • Loading branch information
adityasharma7 authored Jan 6, 2022
2 parents 9a51855 + 16ddea4 commit 668a80d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 10 deletions.
1 change: 0 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ VUE_APP_RESOURCE_URL=
VUE_APP_I18N_LOCALE=en
VUE_APP_I18N_FALLBACK_LOCALE=en
VUE_APP_VIEW_SIZE=10
VUE_APP_ORD_IDENT_TYPE_ID=SHOPIFY_ORD_NAME
VUE_APP_CUST_LOYALTY_OPTIONS={"LoyaltyCustomer":"Pass", "LoyaltyPlusOrder":"Pass +"}
VUE_APP_POLL_TIME=10000
VUE_APP_ORDER_FILTERS=["orderTypeId: SALES_ORDER", "facilityId:PRE_ORDER_PARKING OR facilityId:BACKORDER_PARKING", "orderStatusId: ORDER_APPROVED", "!orderItemStatusId: ITEM_CANCELLED" ]
Expand Down
6 changes: 6 additions & 0 deletions changelogs/unreleased/-1xx2h84.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: Improved code to get orderName if present and removed the code for order Identification
ticket_id: "#1xx2h84"
merge_request: 37
author: Bashu Tiwari
type: changed
9 changes: 1 addition & 8 deletions src/views/orders.vue
Original file line number Diff line number Diff line change
Expand Up @@ -94,19 +94,13 @@
<div class="order-id">
<ion-item lines="none">
<ion-label>
<h1>{{ order.doclist.docs[0].orderId }}</h1>
<h1>{{ order.doclist.docs[0].orderName ? order.doclist.docs[0].orderName : order.doclist.docs[0].orderId }}</h1>
<p>{{ order.doclist.docs[0].customerPartyName }}</p>
</ion-label>
</ion-item>
</div>

<div class="order-tags">
<!-- TODO Fix this. We need to call same filter twice -->
<ion-chip @click="copyToClipboard($filters.getOrderIdentificationId(order.doclist.docs[0].orderIdentifications, orderIdentificationTypeId))" outline v-if="$filters.getOrderIdentificationId(order.doclist.docs[0].orderIdentifications, orderIdentificationTypeId)">
<ion-icon :icon="pricetag" />
<ion-label>{{ $filters.getOrderIdentificationId(order.doclist.docs[0].orderIdentifications, orderIdentificationTypeId) }}</ion-label>
</ion-chip>

<ion-chip outline v-if="$filters.getCustomerLoyalty(order.doclist.docs[0].orderNotes, cusotmerLoyaltyOptions)">
<ion-icon :icon="ribbon" />
<ion-label>{{ $filters.getCustomerLoyalty(order.doclist.docs[0].orderNotes, cusotmerLoyaltyOptions) }}</ion-label>
Expand Down Expand Up @@ -264,7 +258,6 @@ export default defineComponent({
},
data() {
return {
orderIdentificationTypeId: process.env.VUE_APP_ORD_IDENT_TYPE_ID,
cusotmerLoyaltyOptions : JSON.parse(process.env?.VUE_APP_CUST_LOYALTY_OPTIONS),
}
},
Expand Down
1 change: 0 additions & 1 deletion src/views/products.vue
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ export default defineComponent({
data() {
return {
queryString: '',
orderIdentificationTypeId: process.env.VUE_APP_ORD_IDENT_TYPE_ID,
orderedAfter: '',
orderedBefore: '',
selectedItems: [] as any,
Expand Down

0 comments on commit 668a80d

Please sign in to comment.