File tree Expand file tree Collapse file tree 5 files changed +29
-5
lines changed Expand file tree Collapse file tree 5 files changed +29
-5
lines changed Original file line number Diff line number Diff line change 1+ ## [ 3.0.4] - 2022-01-28
2+
3+ * Add new variables to woosignal_app
4+ * Update arguments for product review
5+ * Dependency updates
6+
17## [ 3.0.3] - 2022-01-03
28
39* Update coupon property types
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ In your flutter project add the dependency:
1515``` dart
1616dependencies:
1717 ...
18- woosignal: ^3.0.3
18+ woosignal: ^3.0.4
1919```
2020
2121### Usage example #
Original file line number Diff line number Diff line change @@ -26,6 +26,9 @@ class WooSignalApp {
2626 String ? stripeAccount;
2727 int ? wpLoginEnabled;
2828 bool ? couponEnabled;
29+ bool ? showProductReviews;
30+ bool ? showRelatedProducts;
31+ bool ? showUpsellProducts;
2932 String ? wpLoginBaseUrl;
3033 String ? wpLoginForgotPasswordUrl;
3134 String ? wpLoginWpApiPath;
@@ -101,6 +104,21 @@ class WooSignalApp {
101104 } else {
102105 couponEnabled = false ;
103106 }
107+ if (json['show_product_reviews' ] is int && json['show_product_reviews' ] == 1 ) {
108+ showProductReviews = true ;
109+ } else {
110+ showProductReviews = false ;
111+ }
112+ if (json['show_related_products' ] is int && json['show_related_products' ] == 1 ) {
113+ showRelatedProducts = true ;
114+ } else {
115+ showRelatedProducts = false ;
116+ }
117+ if (json['show_upsell_products' ] is int && json['show_upsell_products' ] == 1 ) {
118+ showUpsellProducts = true ;
119+ } else {
120+ showUpsellProducts = false ;
121+ }
104122 wpLoginBaseUrl = json['wp_login_base_url' ];
105123 wpLoginForgotPasswordUrl = json['wp_login_forgot_password_url' ];
106124 wpLoginWpApiPath = json['wp_login_wp_api_path' ];
Original file line number Diff line number Diff line change @@ -428,11 +428,11 @@ class WooSignal {
428428 /// https://woosignal.com/docs/api/1.0/product-reviews
429429 Future <ProductReview ?> createProductReview (
430430 {int ? productId,
431- int ? status,
431+ String ? status,
432432 String ? reviewer,
433433 String ? reviewerEmail,
434434 String ? review,
435- int ? rating,
435+ int ? rating, // Review rating (0 to 5)
436436 bool ? verified}) async {
437437 Map <String , dynamic > payload = {};
438438
Original file line number Diff line number Diff line change 11name : woosignal
22description : WooCommerce REST API for dart, connect a WooCommerce store and start developing with our interface for their API endpoints.
3- version : 3.0.3
3+ version : 3.0.4
44homepage : https://woosignal.com
55repository : https://github.com/woosignal/flutter-woocommerce-api
66issue_tracker : https://github.com/woosignal/flutter-woocommerce-api/issues
@@ -12,7 +12,7 @@ environment:
1212dependencies :
1313 dio : ^4.0.4
1414 device_info : ^2.0.3
15- shared_preferences : ^2.0.11
15+ shared_preferences : ^2.0.12
1616 uuid : ^3.0.5
1717
1818 flutter :
You can’t perform that action at this time.
0 commit comments