@artisan-commerce/types 0.14.0-canary.25 → 0.14.0-canary.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,24 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [0.14.0-canary.27](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.26...@artisan-commerce/types@0.14.0-canary.27) (2021-12-13)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **global:** fix types and builder for order store ([35286a9](https://bitbucket.org/tradesystem/artisn_sdk/commit/35286a92e5e3df2fe5b3cfa5f289a0e321a24128))
12
+
13
+
14
+
15
+ ## [0.14.0-canary.26](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.25...@artisan-commerce/types@0.14.0-canary.26) (2021-12-01)
16
+
17
+
18
+ ### Features
19
+
20
+ * **global:** update and add types and builders for notifications ([5d6902b](https://bitbucket.org/tradesystem/artisn_sdk/commit/5d6902ba54a84d14a783b5bcda3381ec68a1e636))
21
+
22
+
23
+
6
24
  ## [0.14.0-canary.25](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.24...@artisan-commerce/types@0.14.0-canary.25) (2021-11-05)
7
25
 
8
26
 
package/dist/bundle.d.ts CHANGED
@@ -2076,28 +2076,6 @@ interface Rule {
2076
2076
  min: number;
2077
2077
  }
2078
2078
 
2079
- /**
2080
- * Notification object.
2081
- *
2082
- * @interface Notification
2083
- * @since 0.5.15
2084
- */
2085
- interface Notification {
2086
- /** Notification unique identifier */
2087
- id: number;
2088
- /** Notification title */
2089
- title: string;
2090
- /** Notification description */
2091
- description: string;
2092
- /**
2093
- * Whether or not the notification was read. Purposefully
2094
- * has a string type.
2095
- */
2096
- read: string;
2097
- /** Notification creation date */
2098
- creationDate: string;
2099
- }
2100
-
2101
2079
  /**
2102
2080
  * Representation of a basic Shipping Address.
2103
2081
  *
@@ -2443,10 +2421,9 @@ interface OrderCommonFields {
2443
2421
  *
2444
2422
  * @interface OrderStore
2445
2423
  * @since 0.1.0
2446
- * @extends {{@link Store}
2447
2424
  */
2448
- interface OrderStore extends Store {
2449
- /** Order store id */
2425
+ interface OrderStore {
2426
+ /** Suborder unique identifier */
2450
2427
  id: number;
2451
2428
  /** Order unique identifier */
2452
2429
  orderId: number;
@@ -2462,6 +2439,70 @@ interface OrderStore extends Store {
2462
2439
  billStoreTotal: OrderBillTotal;
2463
2440
  /** An array of OrderProducts, see {@link OrderProduct} */
2464
2441
  products: OrderProduct[];
2442
+ /** Store unique identifier */
2443
+ storeId: Store["storeId"];
2444
+ /** Store name */
2445
+ storeName: Store["storeName"];
2446
+ /** Additional information for the store, see {@link OrderStoreAdditionalInfo} */
2447
+ additionalInfo: OrderStoreAdditionalInfo;
2448
+ }
2449
+ /**
2450
+ * Order store additional information.
2451
+ *
2452
+ * @interface OrderStoreAdditionalInfo
2453
+ * @since 0.1.0
2454
+ */
2455
+ interface OrderStoreAdditionalInfo {
2456
+ /** Store address */
2457
+ address: string;
2458
+ /** Store channel name */
2459
+ channel_name: string;
2460
+ /** Whether or not the store is within coverage */
2461
+ coverage: boolean;
2462
+ /** Store delivery information, see {@link OrderStoreDelivery} */
2463
+ delivery: OrderStoreDelivery;
2464
+ /** Store external identifier */
2465
+ external_id: string;
2466
+ /** Whether or not the store has a dedicated drinks store */
2467
+ is_drinks_store: boolean;
2468
+ /** Store latitude */
2469
+ latitude: number;
2470
+ /** Store longitude */
2471
+ longitude: number;
2472
+ /** Order maximum amount allowed */
2473
+ max_order_amount: number;
2474
+ /** Order minimum amount allowed */
2475
+ min_order_amount: number;
2476
+ /** Order currency's symbol */
2477
+ order_symbol: string;
2478
+ /** Store phone */
2479
+ phone: string;
2480
+ /** Store schedules, see {@link Schedule} */
2481
+ schedules: Schedule[];
2482
+ /** Whether or not to show the drinks store */
2483
+ show_drinks_store: boolean;
2484
+ /** Whether or not the store is sponsored */
2485
+ sponsored: boolean;
2486
+ /** Store external code */
2487
+ store_external_code: string;
2488
+ /** Store timezone */
2489
+ timezone: string;
2490
+ }
2491
+ /**
2492
+ * The delivery information associated with the order store.
2493
+ *
2494
+ * @interface OrderStoreDelivery
2495
+ * @since 0.1.0
2496
+ */
2497
+ interface OrderStoreDelivery {
2498
+ /** Whether or not the store has free delivery */
2499
+ free_delivery: Delivery["freeDelivery"];
2500
+ /** Whether or not the store has a express delivery */
2501
+ express: Delivery["express"];
2502
+ /** Time value for delivery as string */
2503
+ delivery_time_value: Delivery["deliveryTimeValue"];
2504
+ /** Time unit for delivery, see {@link DeliveryTimeUnit} */
2505
+ delivery_time_unit: Delivery["deliveryTimeUnit"];
2465
2506
  }
2466
2507
  /**
2467
2508
  * The product associated with the order.
@@ -3068,6 +3109,161 @@ interface OrderPaymentMethod {
3068
3109
  */
3069
3110
  declare type OrderStatus = "APPROVED" | "REJECTED" | "PENDING";
3070
3111
 
3112
+ /**
3113
+ * Notification object.
3114
+ *
3115
+ * @interface Notification
3116
+ * @since 0.1.0
3117
+ */
3118
+ interface Notification {
3119
+ /** Notification unique identifier */
3120
+ id: number;
3121
+ /** Notification title */
3122
+ title: string;
3123
+ /** Notification description */
3124
+ description: string;
3125
+ /** Notification list title */
3126
+ listTitle: string;
3127
+ /** Notification list items */
3128
+ listItems: NotificationListItem[];
3129
+ /** Notification creation date */
3130
+ creationDate: string;
3131
+ /** Notification priority, see {@link NotificationPriority} */
3132
+ priority: NotificationPriority;
3133
+ /**
3134
+ * Whether or not the notification was read. Purposefully
3135
+ * has a string type.
3136
+ */
3137
+ read: ReadValue;
3138
+ /** Notification extra data, see {@link NotificationExtraData} */
3139
+ extra_data: NotificationExtraData;
3140
+ }
3141
+ /**
3142
+ * Possible priority values for notifications.
3143
+ *
3144
+ * @typedef NotificationPriority
3145
+ * @since 0.1.0
3146
+ */
3147
+ declare type NotificationPriority = "HIGH" | "LOW";
3148
+ /**
3149
+ * Possible read values for notifications.
3150
+ *
3151
+ * @typedef ReadValue
3152
+ * @since 0.1.0
3153
+ */
3154
+ declare type ReadValue = "YES" | "NO";
3155
+ /**
3156
+ * Notification extra data.
3157
+ *
3158
+ * @interface NotificationExtraData
3159
+ * @since 0.1.0
3160
+ */
3161
+ interface NotificationExtraData {
3162
+ /** The id of the notification extra data */
3163
+ id: number;
3164
+ /** Sequential value */
3165
+ seqVal: string;
3166
+ /** Unique identifier */
3167
+ uid: string;
3168
+ /** Notification user, see {@link NotificationUser} */
3169
+ user: NotificationUser;
3170
+ /** The provided account id of the application */
3171
+ accountId: Account["accountId"];
3172
+ /** Vendor related to the notification, see {@link NotificationVendor} */
3173
+ vendor: NotificationVendor;
3174
+ /** City of the store related to the notification, see {@link BaseField} */
3175
+ city: BaseField;
3176
+ /** Store related to the notification, see {@link NotificationStore} */
3177
+ store: NotificationStore;
3178
+ /** Channel unique identifier */
3179
+ channel_id: number;
3180
+ /** Provided country id */
3181
+ countryId: number;
3182
+ /** Notification step, see {@link NotificationStep} */
3183
+ step: NotificationStep;
3184
+ /** Allocation options, see {@link Allocation} */
3185
+ allocation: Allocation;
3186
+ /** Payment Method of the order related to the notification */
3187
+ paymentMethod: string;
3188
+ /** Total price of the order */
3189
+ total: string;
3190
+ /** Notification additional information, see {@link NotificationAdditionalInfo} */
3191
+ additionalInfo: NotificationAdditionalInfo;
3192
+ /** Notification creation Date */
3193
+ created_at: string;
3194
+ }
3195
+ /**
3196
+ * Notification vendor.
3197
+ *
3198
+ * @interface NotificationVendor
3199
+ * @since 0.1.0
3200
+ * @extends Vendor
3201
+ */
3202
+ interface NotificationVendor extends Omit<Vendor, "images" | "maxPurchaseValue" | "description" | "sponsored" | "active"> {
3203
+ }
3204
+ /**
3205
+ * Notification store.
3206
+ *
3207
+ * @interface NotificationStore
3208
+ * @since 0.1.0
3209
+ * @extends BaseField
3210
+ */
3211
+ interface NotificationStore extends BaseField {
3212
+ /** Store's address */
3213
+ address: string;
3214
+ }
3215
+ /**
3216
+ * Notification user.
3217
+ *
3218
+ * @interface NotificationUser
3219
+ * @since 0.1.0
3220
+ */
3221
+ interface NotificationUser {
3222
+ /** Notification user name */
3223
+ name: string;
3224
+ /** Notification user address */
3225
+ address: string;
3226
+ /** Notification user email */
3227
+ email: string;
3228
+ }
3229
+ /**
3230
+ * Notification step.
3231
+ *
3232
+ * @interface NotificationStep
3233
+ * @since 0.1.0
3234
+ * @extends StepWorkflow
3235
+ */
3236
+ interface NotificationStep extends Omit<StepWorkflow, "additional_info" | "color" | "description" | "description_frontend" | "subtitle_frontend" | "title_frontend" | "transitions" | "notification"> {
3237
+ }
3238
+ /**
3239
+ * Notification additional information.
3240
+ *
3241
+ * @interface NotificationAdditionalInfo
3242
+ * @since 0.1.0
3243
+ */
3244
+ interface NotificationAdditionalInfo {
3245
+ /** Whether or not notification has parent shopping cart*/
3246
+ parent_shopping_cart: boolean;
3247
+ /** Order metadata shipping, see {@link MetadataShipping} */
3248
+ metadata_shipping: MetadataShipping;
3249
+ /** Project unique identifier */
3250
+ aud: string;
3251
+ /** Unique identifier of workflowId */
3252
+ workflowId: number;
3253
+ }
3254
+ /**
3255
+ * Notification list item.
3256
+ *
3257
+ * @interface NotificationListItem
3258
+ * @since 0.1.0
3259
+ */
3260
+ interface NotificationListItem {
3261
+ /** Notification list item title */
3262
+ title: string;
3263
+ /** Notification list item description */
3264
+ description: string;
3265
+ }
3266
+
3071
3267
  /**
3072
3268
  * Basic payment method object.
3073
3269
  *
@@ -3168,4 +3364,4 @@ interface CardInscription {
3168
3364
  createdAt?: string;
3169
3365
  }
3170
3366
 
3171
- export { ARDocumentType, Account, AdditionalInfo, AdditionalStoreInformation, Alert, Allocation, ArtisnApp, ArtisnDB, ArtisnDBCollectionReference, ArtisnDBDocumentData, ArtisnDBQueryDocumentSnapshot, ArtisnHeaders, ArtisnHints, ArtisnParams, ArtisnPlatform, ArtisnQuery, ArtisnRNApp, ArtisnRNAuth, ArtisnRNAuthInstance, ArtisnRNSettings, ArtisnRequest, ArtisnRequestBody, ArtisnRequestHeaders, ArtisnRequestMethod, ArtisnRestrictedHeaders, ArtisnWebApp, ArtisnWebAuth, ArtisnWebAuthInstance, ArtisnWebSettings, Award, BODocumentType, BRDocumentType, Banner, BannerImage, BannerScope, BannerType, BaseBillingData, BaseField, BaseLivingPlace, BaseOrder, BasePaymentMethod, BaseProduct, BaseShippingAddress, BaseUser, BaseWeekDay, Benefit, BenefitData, BenefitTypes, BenefitsByUserNode, BenefitsByUserNodes, BillTotal, BillTotalCategory, BillingData, CDNImage, CLDocumentType, CODocumentType, CardInscription, CardName, CartProduct, CartProductAnswer, CartProductQuestion, CartStore, CartTotals, Catalogue, Category, CategoryWithProducts, Code, CommonDocumentType, Country, CountryCode, CountryCurrency, CountrySummary, Coupon, CouponCategory, CouponType, CreditCardMapping, CurrencyCodes, DayOfWeek, Days, Delivery, DeliveryTimeUnit, DocumentType, ECDocumentType, Field, FieldRecord, Gender, GenericStoreLocation, Image, ImageFit, ImageManipulationConfig, ImageToFormat, Injection, InjectionDetail, IntegrationMessage, Issue, IssueAdditionalInfo, IssueHistory, LivingPlace, LivingPlaceToSave, MaritalStatus, Message, MetadataShipping, NewShippingAddress, Notification, Objectify, OperatorInformation, Order, OrderAdditionalInfo, OrderBillProduct, OrderBillProductAdditionalInfo, OrderBillTotal, OrderCommonFields, OrderDetailShippingCost, OrderDetails, OrderPaymentMethod, OrderProduct, OrderProductAdditionalInfo, OrderProductAttributes, OrderProductImage, OrderProductPriceCategory, OrderRetry, OrderRetryPaymentMethod, OrderShoppingCart, OrderStatus, OrderStep, OrderStepAdditionalInfo, OrderStepAdditionalInfoGroup, OrderStore, OrderUser, PEDocumentType, PYDocumentType, PaymentMethod, PaymentMethodByOrder, PaymentMethodName, PaymentProvider, Phone, PriceCategory, PriceCategoryTax, PriceCategoryType, Product, ProductAnswer, ProductAttributes, ProductCoupon, ProductDetails, ProductPrices, ProductQuestion, ProductStatus, ProductType, RandomImageConfig, Rule, Schedule, Service, Settings, ShippingAddress, ShippingCost, ShippingCostTax, ShoppingCart, ShoppingCartBenefits, ShoppingCartNode, ShoppingCartNodes, Status, StepCategory, StepCode, StepNotification, StepWorkflow, StepWorkflowAdditionalInfo, StepWorkflowGroup, Store, StoreCoupon, StoreCouponDetail, StoreLocation, StorePolygons, Suborder, TaxCalculation, TaxCalculations, TaxType, Token, TransitionWorkflow, URLImage, USDocumentType, UYDocumentType, UpdatedShippingAddress, User, UserCountry, UserSettings, UserType, VEDocumentType, Vendor, Wallet, WebhookWorkflow, Workflow, ZipCodeField };
3367
+ export { ARDocumentType, Account, AdditionalInfo, AdditionalStoreInformation, Alert, Allocation, ArtisnApp, ArtisnDB, ArtisnDBCollectionReference, ArtisnDBDocumentData, ArtisnDBQueryDocumentSnapshot, ArtisnHeaders, ArtisnHints, ArtisnParams, ArtisnPlatform, ArtisnQuery, ArtisnRNApp, ArtisnRNAuth, ArtisnRNAuthInstance, ArtisnRNSettings, ArtisnRequest, ArtisnRequestBody, ArtisnRequestHeaders, ArtisnRequestMethod, ArtisnRestrictedHeaders, ArtisnWebApp, ArtisnWebAuth, ArtisnWebAuthInstance, ArtisnWebSettings, Award, BODocumentType, BRDocumentType, Banner, BannerImage, BannerScope, BannerType, BaseBillingData, BaseField, BaseLivingPlace, BaseOrder, BasePaymentMethod, BaseProduct, BaseShippingAddress, BaseUser, BaseWeekDay, Benefit, BenefitData, BenefitTypes, BenefitsByUserNode, BenefitsByUserNodes, BillTotal, BillTotalCategory, BillingData, CDNImage, CLDocumentType, CODocumentType, CardInscription, CardName, CartProduct, CartProductAnswer, CartProductQuestion, CartStore, CartTotals, Catalogue, Category, CategoryWithProducts, Code, CommonDocumentType, Country, CountryCode, CountryCurrency, CountrySummary, Coupon, CouponCategory, CouponType, CreditCardMapping, CurrencyCodes, DayOfWeek, Days, Delivery, DeliveryTimeUnit, DocumentType, ECDocumentType, Field, FieldRecord, Gender, GenericStoreLocation, Image, ImageFit, ImageManipulationConfig, ImageToFormat, Injection, InjectionDetail, IntegrationMessage, Issue, IssueAdditionalInfo, IssueHistory, LivingPlace, LivingPlaceToSave, MaritalStatus, Message, MetadataShipping, NewShippingAddress, Notification, NotificationAdditionalInfo, NotificationExtraData, NotificationListItem, NotificationPriority, NotificationStep, NotificationStore, NotificationUser, NotificationVendor, Objectify, OperatorInformation, Order, OrderAdditionalInfo, OrderBillProduct, OrderBillProductAdditionalInfo, OrderBillTotal, OrderCommonFields, OrderDetailShippingCost, OrderDetails, OrderPaymentMethod, OrderProduct, OrderProductAdditionalInfo, OrderProductAttributes, OrderProductImage, OrderProductPriceCategory, OrderRetry, OrderRetryPaymentMethod, OrderShoppingCart, OrderStatus, OrderStep, OrderStepAdditionalInfo, OrderStepAdditionalInfoGroup, OrderStore, OrderStoreAdditionalInfo, OrderStoreDelivery, OrderUser, PEDocumentType, PYDocumentType, PaymentMethod, PaymentMethodByOrder, PaymentMethodName, PaymentProvider, Phone, PriceCategory, PriceCategoryTax, PriceCategoryType, Product, ProductAnswer, ProductAttributes, ProductCoupon, ProductDetails, ProductPrices, ProductQuestion, ProductStatus, ProductType, RandomImageConfig, ReadValue, Rule, Schedule, Service, Settings, ShippingAddress, ShippingCost, ShippingCostTax, ShoppingCart, ShoppingCartBenefits, ShoppingCartNode, ShoppingCartNodes, Status, StepCategory, StepCode, StepNotification, StepWorkflow, StepWorkflowAdditionalInfo, StepWorkflowGroup, Store, StoreCoupon, StoreCouponDetail, StoreLocation, StorePolygons, Suborder, TaxCalculation, TaxCalculations, TaxType, Token, TransitionWorkflow, URLImage, USDocumentType, UYDocumentType, UpdatedShippingAddress, User, UserCountry, UserSettings, UserType, VEDocumentType, Vendor, Wallet, WebhookWorkflow, Workflow, ZipCodeField };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@artisan-commerce/types",
3
3
  "description": "Artisn's types and interfaces library",
4
- "version": "0.14.0-canary.25",
4
+ "version": "0.14.0-canary.27",
5
5
  "main": "./dist/bundle.d.ts",
6
6
  "module": "./dist/bundle.d.ts",
7
7
  "types": "./dist/bundle.d.ts",
@@ -34,5 +34,5 @@
34
34
  "@react-native-firebase/firestore": "^12.8.0",
35
35
  "firebase": "^8.1.1"
36
36
  },
37
- "gitHead": "b388e92c72e306a3f446181f11d0cb05ca55bbf3"
37
+ "gitHead": "3f1273ea8d92b7f1e350b1c5fd41882fd0a9e969"
38
38
  }