File tree Expand file tree Collapse file tree 6 files changed +46
-3
lines changed
Expand file tree Collapse file tree 6 files changed +46
-3
lines changed Original file line number Diff line number Diff line change @@ -135,4 +135,17 @@ public function get_item_schema() {
135135
136136 return $ this ->add_additional_fields_schema ( $ schema );
137137 }
138+
139+ /**
140+ * Check whether a given request has permission to view order statuses.
141+ *
142+ * @param WP_REST_Request $request Full details about the request.
143+ * @return WP_Error|boolean
144+ */
145+ public function get_items_permissions_check ( $ request ) {
146+ if ( is_user_logged_in () ) {
147+ return true ;
148+ }
149+ return parent ::get_items_permissions_check ( $ request );
150+ }
138151}
Original file line number Diff line number Diff line change @@ -24,4 +24,17 @@ class Shipping_Methods_Controller extends WC_REST_Shipping_Methods_Controller {
2424 * @var string
2525 */
2626 protected $ namespace = 'wcpos/v1 ' ;
27+
28+ /**
29+ * Check whether a given request has permission to view shipping methods.
30+ *
31+ * @param WP_REST_Request $request Full details about the request.
32+ * @return WP_Error|boolean
33+ */
34+ public function get_items_permissions_check ( $ request ) {
35+ if ( is_user_logged_in () ) {
36+ return true ;
37+ }
38+ return parent ::get_items_permissions_check ( $ request );
39+ }
2740}
Original file line number Diff line number Diff line change @@ -24,4 +24,17 @@ class Tax_Classes_Controller extends WC_REST_Tax_Classes_Controller {
2424 * @var string
2525 */
2626 protected $ namespace = 'wcpos/v1 ' ;
27+
28+ /**
29+ * Check whether a given request has permission to view tax classes.
30+ *
31+ * @param WP_REST_Request $request Full details about the request.
32+ * @return WP_Error|boolean
33+ */
34+ public function get_items_permissions_check ( $ request ) {
35+ if ( is_user_logged_in () ) {
36+ return true ;
37+ }
38+ return parent ::get_items_permissions_check ( $ request );
39+ }
2740}
Original file line number Diff line number Diff line change 11{
22 "name" : " @wcpos/woocommerce-pos" ,
3- "version" : " 1.5.0 " ,
3+ "version" : " 1.5.1 " ,
44 "description" : " A simple front-end for taking WooCommerce orders at the Point of Sale." ,
55 "main" : " index.js" ,
66 "workspaces" : {
Original file line number Diff line number Diff line change @@ -79,6 +79,10 @@ There is more information on our website at [https://wcpos.com](https://wcpos.co
7979
8080== Changelog ==
8181
82+ = 1.5.1 - 2024/06/03 =
83+ * Fix: "Sorry, you cannot list resources." error for cashier role
84+
85+
8286= 1.5.0 - 2024/06/03 =
8387* Fix: the POS will now correctly sync stock quantity after each sale
8488* Fix: cart tax logic has been improved to fix rounding issues
Original file line number Diff line number Diff line change 33 * Plugin Name: WooCommerce POS
44 * Plugin URI: https://wordpress.org/plugins/woocommerce-pos/
55 * Description: A simple front-end for taking WooCommerce orders at the Point of Sale. Requires <a href="http://wordpress.org/plugins/woocommerce/">WooCommerce</a>.
6- * Version: 1.5.0
6+ * Version: 1.5.1
77 * Author: kilbot
88 * Author URI: http://wcpos.com
99 * Text Domain: woocommerce-pos
2626namespace WCPOS \WooCommercePOS ;
2727
2828// Define plugin constants.
29- const VERSION = '1.5.0 ' ;
29+ const VERSION = '1.5.1 ' ;
3030const PLUGIN_NAME = 'woocommerce-pos ' ;
3131const SHORT_NAME = 'wcpos ' ;
3232\define ( __NAMESPACE__ . '\PLUGIN_FILE ' , plugin_basename ( __FILE__ ) ); // 'woocommerce-pos/woocommerce-pos.php'
You can’t perform that action at this time.
0 commit comments