Skip to content

Adds tagged code for cash management tutorial #3104

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 5 commits into
base: unstable
Choose a base branch
from

Conversation

Profilist
Copy link

@Profilist Profilist commented Jul 23, 2025

https://github.com/shop/issues-retail/issues/16100

Background

Added example components for a cash management extension in the Point of Sale UI Extensions documentation.

Linked to the tutorial in this PR.

Solution

Created a comprehensive cash management example for the Point of Sale UI Extensions documentation with the following components:

  1. BannerAlert.tsx - A component that displays alert banners when business rules are violated (e.g., cash drawer amount outside of thresholds)
  2. SafeModal.tsx - A modal interface for managing safe deposits and withdrawals with transaction history
  3. useBusinessRules.ts - A custom hook that checks if cash drawer amounts violate business rules
  4. InStoreCashInfo.tsx - A component that displays the total cash on hand in store
  5. shopify.extension.toml - Configuration file that defines the extension targets

The example demonstrates how to implement cash management extensions that:

  • Track safe balance, deposits and withdrawals
  • Implement business rules to monitor cash drawer thresholds
  • Use an alert system that displays banner warnings when business rules are violated
  • Display total cash on hand at the location

🎩

  • Run the example in a development environment to verify the cash management UI works correctly
  • Test deposit and withdrawal operations to ensure balance updates properly
  • Verify business rule alerts display correctly when thresholds are violated

Checklist

  • I have 🎩'd these changes
  • I have updated relevant documentation

Copy link
Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@Profilist Profilist changed the title Adds shopify.extension.toml for cash management tutorial Adds tagged code for cash management tutorial Jul 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant