Add option to bind staff availability rules to specific product.

Issue #386 resolved
Željan Topić created an issue

No description provided.

Comments (22)

  1. mattias @ refine.digital

    Hi Željan, I think it is time to find a way to enhance the booking functionality in this direction. Going in this direction would also speed up loading times significantly from what I can see in today's code base.

    However, I'm pretty sure I would keep the user level rules ( for staff to manage their own schedule ) and add the capability to add availability to Staff Tab under Products tied with additional cost and quantity.

    This way you have additional benefits for both role capability. Shop_Staff can manage their schedule Show_Manager can managed assigning staff, pricing, quantity, etc.

    This would solve scheduling for small/medium sized fitness companies with multiple staff and products.

  2. Željan Topić reporter

    We would add this in a snap, but we're still finding a way to reduce complexity. If you have some ideas how this could be add with reduced complexity, let me know. Also share an example for fitness companies and I'll see how this could be implemented.

  3. mattias @ refine.digital

    I'm happy to present a proposal to how to

    1) New feature - Add Staff Availability Rules By Product. Primary goals must be to be backwards compatible AND NOT slow down page load any further.

    2) Reduced Complexity - More difficult to achieve with backwards compatibility so it should be targeted for next major release

    3) Speed Optimization - Can possibly be done in two step. Step 1 - Migrate to Custom tables and USE SQL queries instead of foreach and switch loops. Step 2 - When complexity is solved additional speed Optimization should be possible in frontend/backend but I'm not sure if this is possible until you try.

    Let's collaborate on achieving this! It would benefit us both. I'll get started on some detailed ideas for Step 1. Where should I send the detailed ideas?

    Initial ideas for comments here: https://docs.google.com/spreadsheets/d/1ir-MW3xAouCf-4AyuZgT2SEFg7WIisr4ZslxpEKOCwM/edit?usp=sharing

  4. Željan Topić reporter

    I agree on the DB split idea, but we need to make the structure right to avoid additional meta tables.

  5. Željan Topić reporter

    Thank, you're the best. Just one more thing to consider: take into account that Google Calendar sync works through rules and there can be as much as 1000 events synced back to the site.

  6. mattias @ refine.digital

    I believe that once we can run real SQL queries on availability data instead of using meta tables the number events won't really matter so much.

  7. mattias @ refine.digital

    Additional thoughts on GCal as I now test this feature thoroughly

    I believe a future addition to a better UX for Admins is to ALSO be able to also view Blocked Times from GCal imports on both Global and Staff levels. Preferably in Admin Calendar but also near the Availability Rules.

    At the moment they are imported but not visible Backend for Admins. At the Frontend the slots are removed from availability as they should but as an Admin it may not be obvious to know WHY some slots are missing even though they've been set-up correctly.

  8. Željan Topić reporter

    I agree on gcal availability rules visibility. This is being developed and will be available very soon.

  9. Željan Topić reporter

    Just to let you know that this feature will be available shortly as I'm currently implementing new CRUD class and custom table for availability rules.

  10. Željan Topić reporter

    We just released 4.3.0 we plan to add CRUD availability rules with 4.4.0, when Google Calendar sync will also get an overhaul.

  11. mattias @ refine.digital

    @biznis86 Any update on the progress for 4.4.0?

    I still haven't been able to solve the issue with Availability for WPML hourly products. Availability calculation is ONLY correct if booked from Original Product ID. If you book from Translated Product ID ut shows NO availability for the Original Product ID. As I've mentioned before there is a problem with logic in current code which says - if you have booked a product with Staff X for a specific hour than there should be no more availability for this staff for this specific hour. THIS is not always true since 1) a translated product is ALSO then showing NO availability (current issue)

    Any thoughts?

  12. Željan Topić reporter

    4.4.0 is in beta and if you're interested send us an email and I'll ship the beta version to you for testing. In includes heavy updates to availability rules structure - it has it's own CRUD.

    The issue you highlighted should not happen as there is a function in WPML integration class for this purpose.

  13. Log in to comment