Commit Graph

14 Commits

Author SHA1 Message Date
a2nr 860a929da8 fix: perbaiki item dan total pecah baris di struk thermal
Library flutter_esc_pos_utils mengirim ESC a (align) di tengah
     baris
     pada generator.row(), menyebabkan kolom right-aligned tercetak di
     baris baru. Ganti semua row() campuran left+right alignment
     dengan
     text() + _padRow() (manual space padding 32 char) agar tidak ada
     perintah ESC a di tengah baris.

     - Tambah helper _padRow(left, right) untuk padding 32 karakter
     - Item: deskripsi 1 baris (width 12), qty×price + total 1 baris
     - Subtotal, TOTAL, BAYAR, KEMBALI/TIP, KURANG: text() + _padRow()
2026-06-28 21:55:17 +07:00
a2nr 4140af7ba0 feat: multi-grup sumber, batch send, & perbaikan tip
Multi-Grup Sumber & UI:
     - Model ReceiptGroup: satu struk bisa punya banyak grup sumber (
     revenue)
     - Tombol "Tambah Sumber" dengan dashed border (max 10 grup)
     - Hapus label "Dari:" di SourceAccountSelector (chip saja)
     - Default 1 grup kosong di ReceiptProvider constructor &
     _resetState

     Akun Tujuan ke Config:
     - Pindah DestinationAccountSelector dari receipt body ke Config
     screen
     - Persist & load via SharedPreferences (permanen, tidak di-reset)
     - Dropdown auto-load dari cache/mirror saat buka Config
     - Tombol "Sinkronisasi Manual" sekarang simpan ke mirror &
     refresh dropdown

     Batch Send via SubmissionTask:
     - Model SubmissionTask: konteks per-grup (group/tip +
     destination + date)
     - TransactionSubmissionDialog refactor: terima
     List<SubmissionTask>
     - Helper buildTasksFromReceipt &
     buildTasksFromAllUnsubmittedReceipts
     - LocalReceiptsScreen: tombol "Kirim Semua Nota" + post-process
     status

     Bug Fix:
     - copyWith sentinel pattern: field nullable (tipSourceAccount,
       destinationAccount, fireflyUrl, accessToken) kini bisa di-set
     ke null
     - Tip dapat dibersihkan dengan "Batal Tip" & reset antar
     transaksi
     - Hapus tombol "Muat Akun" (redundan dgn Sinkronisasi Manual)

     Lainnya:
     - Date picker untuk tanggal transaksi
     - Font courier prime caching via CourierStyles
     - Perf: compute() untuk decode image, cancel stream bluetooth,
     fix rebuild loop
     - External link: <queries> AndroidManifest + skip canLaunchUrl
     - Layout cetak: hapus Ke:, sederhanakan separator grup, hapus
     TIP: TIDAK
     - Hapus TransactionLinksScreen, ganti inline copy/open di popup
2026-06-27 20:18:51 +07:00
a2nr a12de4e324 bugfix printing 2026-01-12 11:56:55 +07:00
a2nr f1ca6db22c cleaning dan menambahkan pembayaran, kembalian, dan tip di struk cetak 2025-12-28 10:51:15 +07:00
a2nr 631066024c update fitur pembayaran dan tip. 2025-12-27 15:45:41 +07:00
a2nr 4dbf31db3c feat: remove default account mapping and implement offline-first account mirroring
This commit removes the confusing default account mapping feature and implements a more reliable offline-first account mirroring system. The changes include:

BREAKING CHANGES:
- Remove all default account mapping functionality (saveDefaultAccount, getDefaultAccount, etc.)
- Simplify account selection to use direct account choice instead of default mapping

FEATURES:
- Implement account mirroring system that stores all FireFly III accounts locally
- Add offline-first approach: server accounts > mirrored accounts > fallback
- Automatic account sync when connection is available
- Manual sync capability in config screen
- Enhanced offline reliability - app works completely without server connection

IMPROVEMENTS:
- Faster startup times using local account cache
- More predictable account selection behavior
- Reduced confusion about which accounts are being used
- Better error handling for offline scenarios
- Simplified architecture without complex default mapping logic
2025-11-17 12:04:46 +07:00
a2nr d64d3716c3 feat: tambahan fitur swipe untuk hapus item dan tap untuk webview transaksi 2025-11-08 13:38:24 +07:00
a2nr eece292526 tambah fitur cache nota dan submit ketika server sudah aktif 2025-11-08 12:15:38 +07:00
a2nr 77b3f5bb79 feat: update item quantity to support double values
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2025-09-18 11:39:03 +07:00
a2nr b88c301d7d Implement PrintingStatusCard in ReceiptSpeedDial and improve error handling for Bluetooth printer connection 2025-09-05 21:44:38 +07:00
a2nr 3baa17e9a5 Refactor ReceiptScreen: Memindahkan logika kompleks ke service terpisah dan membuat widget terpisah untuk SpeedDial 2025-08-24 11:02:07 +07:00
a2nr 3e1c34d1ce feat: Implement logo printing to thermal printer and add loading indicator
• Replace StrukTextGenerator with EscPosPrintService to support image printing

• Add loading indicator during print process to prevent UI freeze

• Fix Uint8List type issues for printer compatibility

• Improve error handling with proper state management

• Users can now print selected store logo on thermal receipts
2025-08-23 22:44:16 +07:00
a2nr 06b23d61db Perbaiki masalah koneksi printer Bluetooth dan pencetakan struk
- Menambahkan pengecekan koneksi Bluetooth real-time untuk memastikan status koneksi akurat
- Memperbaiki tombol 'Cetak Struk' untuk menggunakan pengecekan koneksi yang benar
- Menambahkan mekanisme koneksi ulang otomatis jika printer terputus
- Meningkatkan fungsi pencetakan dengan penanganan error yang lebih baik dan percobaan ulang
- Menambahkan logging detail di plugin Bluetooth Print (Java) untuk debugging
- Menyesuaikan format struk untuk kompatibilitas printer termal
- Menghapus file yang tidak digunakan (printer_setup_screen.dart, settings_screen.dart)
- Menambahkan fitur WebView untuk menampilkan transaksi Firefly III
2025-08-23 16:29:32 +07:00
a2nr 35c8e65983 Initial commit: Cashumit app with Firefly III integration and Bluetooth printer support 2025-08-20 15:15:20 +07:00