1. # 🚀 COMPLETE APP DEVELOPMENT PROMPT - CLIENT & PROJECT MANAGEMENT SYSTEM
  2.  
  3. ## 📱 **APP OVERVIEW**
  4.  
  5. **App Name:** ClientFlow Pro / DevManage Hub
  6.  
  7. **Purpose:** A personal project and client management app for developers/freelancers to manage projects, clients, versions, tasks, payments, and revenue tracking.
  8.  
  9. **Target User:** Individual developers, freelancers, small agencies
  10.  
  11. **Platform:** Mobile App (iOS & Android)
  12.  
  13. **Languages:** English (India), Hinglish
  14.  
  15. **Default Currency:** Indian Rupee (₹), with support for USD ($)
  16.  
  17. ---
  18.  
  19. ## 🎨 **UI/UX DESIGN REQUIREMENTS**
  20.  
  21. The app design should be: **MODERN, PROFESSIONAL, UNIQUE, HIGHLY DESIGNED, WELL ORGANISED**
  22.  
  23. ### **THEMES:**
  24.  
  25. Provide **5 THEMES** in Settings. Each theme must be:
  26. - MODERN
  27. - PROFESSIONAL
  28. - UNIQUE
  29. - HIGHLY DESIGNED
  30. - WELL ORGANISED
  31. - COMPLETELY DIFFERENT FROM EACH OTHER IN ALL ASPECTS (colors, style, feel, layout)
  32.  
  33. **Important:** One theme MUST have **multiple color-changing effects in the background with smooth transitions** to give an amazing, phenomenon experience.
  34.  
  35. ---
  36.  
  37. ## 🗄️ **BACKEND ARCHITECTURE**
  38.  
  39. ### **Technology Stack:**
  40.  
  41. 1. **Database (Structured Data - Small):** Firebase Firestore
  42. 2. **Storage (Large Files/Data):** Google Cloud Storage
  43. 3. **File Storage & Sync:** Google Drive
  44. 4. **Authentication:** Firebase Authentication
  45. 5. **Cloud Functions:** Supabase Functions
  46. 6. **Crash Reporting:** Firebase Crashlytics
  47. 7. **Remote Configuration:** Firebase Remote Config
  48. 8. **Analytics:** Firebase Analytics
  49.  
  50. ### **Data Structure Guidelines:**
  51.  
  52. - Use Firebase Firestore for: user profiles, projects, clients, versions, tasks, revenue records, settings
  53. - Use Google Cloud Storage for: large files, attachments, documents, images, backups
  54. - Use Google Drive for: user data sync and cloud storage
  55. - Implement real-time sync across all devices
  56. - Auto-backup to cloud daily
  57.  
  58. ---
  59.  
  60. # 📋 **PHASE 1: CORE FEATURES & MODULES**
  61.  
  62. ## **MODULE 1: DASHBOARD (Home Screen)**
  63.  
  64. ### **Dashboard Components:**
  65.  
  66. **Quick Stats Cards:**
  67. - Total Revenue (this month with percentage change)
  68. - Active Projects (count)
  69. - Total Clients (count)
  70. - Pending Tasks (count with badge)
  71.  
  72. **Revenue Graph:**
  73. - Monthly revenue bar chart (last 6 months)
  74. - Tap to expand for detailed view
  75. - Color-coded by project
  76.  
  77. **Recent Activity Feed:**
  78. - Last 10 activities with timestamps
  79. - Types: Project created, Payment received, Task completed, Client added
  80. - Filter option: All / Projects / Payments / Tasks
  81.  
  82. **Quick Action Button (Floating):**
  83. - Add New Project
  84. - Add New Client
  85. - Add Revenue Entry
  86. - Quick Add Task
  87.  
  88. ### **Navigation:**
  89. Bottom tab bar with:
  90. - 🏠 Dashboard
  91. - 📱 Projects
  92. - 💰 Revenue
  93. - 👥 Clients
  94. - ⋯ More
  95.  
  96. ---
  97.  
  98. ## **MODULE 2: PROJECTS MANAGEMENT**
  99.  
  100. ### **Add Project Flow:**
  101.  
  102. **Create Project Screen - Fields:**
  103. - Project Name* (required)
  104. - Project Type: Website / App / Both / Other (dropdown)
  105. - Project Icon (image picker or icon library)
  106. - Start Date* (date picker)
  107. - Expected End Date (date picker)
  108. - Project Status: Active / On Hold / Completed / Cancelled (dropdown)
  109. - Base Price (number input with currency)
  110. - Project Description (multi-line text)
  111. - Attach Files (documents, designs, contracts)
  112.  
  113. **Save & Continue to Versions**
  114.  
  115. ### **Project Detail Screen:**
  116.  
  117. **Header:**
  118. - Project icon + name
  119. - Status badge (color-coded)
  120. - Edit / Delete / Share buttons
  121.  
  122. **Tabs:**
  123. 1. **Versions** - List of all versions for this project
  124. 2. **Files** - All attached files
  125. 3. **Notes** - Project notes
  126. 4. **Timeline** - Visual timeline of project
  127.  
  128. ### **Versions Tab - Most Important:**
  129.  
  130. **Version List Display:**
  131. Each version card shows:
  132. - Version number/name (e.g., v1.0 - Basic)
  133. - Client name (tappable)
  134. - Revenue badge: ₹XX,XXX (color: Green=Paid, Orange=Partial, Red=Unpaid)
  135. - Features count (e.g., "8 features")
  136. - Task progress bar (e.g., "5/8 completed")
  137. - Quick actions: View / Edit / Duplicate
  138.  
  139. **Add New Version Button**
  140.  
  141. ---
  142.  
  143. ## **MODULE 3: VERSION MANAGEMENT (CRITICAL FEATURE)**
  144.  
  145. ### **Create Version Screen - Sections:**
  146.  
  147. **1. VERSION DETAILS:**
  148. - Version Number/Name* (e.g., v1.0)
  149. - Version Type: Free / Basic / Premium / Custom
  150.  
  151. **2. CLIENT INFORMATION:**
  152. - Select Existing Client (dropdown with search)
  153. - OR Add New Client:
  154. - Client Name*
  155. - Company Name
  156. - Email
  157. - Phone
  158. - Address
  159. - Client Avatar
  160.  
  161. **3. REVENUE DETAILS:**
  162. - Total Project Cost* (number input)
  163. - Amount Received (number input)
  164. - Remaining Amount (auto-calculated, red if pending)
  165. - Payment Status: Paid / Partial / Unpaid / Pending
  166. - Payment Method: Bank Transfer / Cash / UPI / PayPal / Other
  167. - Payment Date (date picker)
  168. - Next Payment Date (for partial payments)
  169. - Invoice Number (text input)
  170. - Payment reminder toggle
  171.  
  172. **4. FEATURES INCLUDED:**
  173. - Add Feature button
  174. - Each feature has:
  175. - Feature name*
  176. - Description
  177. - Status: Planned / In Progress / Completed / Dropped
  178. - Priority: Low / Medium / High / Critical
  179. - Delete option
  180.  
  181. **Feature Templates Library:**
  182. Pre-defined features user can quickly add:
  183. - User Authentication
  184. - Admin Panel
  185. - Payment Integration
  186. - Push Notifications
  187. - Responsive Design
  188. - SEO Optimization
  189. - Database Integration
  190. - API Development
  191. - (User can customize this library)
  192.  
  193. **5. TASKS & REMINDERS:**
  194. - Add Task button
  195. - Each task has:
  196. - Task Title*
  197. - Description
  198. - Due Date & Time
  199. - Priority: Low / Medium / High / Urgent
  200. - Status: To Do / In Progress / Done
  201. - Reminder: 15 min / 1 hour / 1 day / Custom before due
  202. - Checklist items (sub-tasks with checkboxes)
  203. - Attach files
  204.  
  205. **Task Views:**
  206. - List View
  207. - Board View (To Do | In Progress | Done)
  208. - Calendar View
  209.  
  210. **6. TIMELINE:**
  211. - Version Start Date*
  212. - Expected Delivery Date*
  213. - Actual Delivery Date
  214.  
  215. **7. DEPLOYMENT LINKS:**
  216. - Development URL
  217. - Staging URL
  218. - Production/Live URL
  219. - GitHub Repo Link
  220. - Quick copy & open buttons for each
  221.  
  222. **8. ATTACHMENTS:**
  223. - Upload documents, designs, contracts
  224. - File preview support
  225. - Stored in Google Cloud Storage
  226.  
  227. **Buttons:** Cancel / Save as Draft / Create Version
  228.  
  229. ---
  230.  
  231. ## **MODULE 4: REVENUE SECTION**
  232.  
  233. ### **Revenue Dashboard:**
  234.  
  235. **Summary Cards:**
  236. - Total Revenue (All Time)
  237. - This Month Revenue (with % change)
  238. - This Quarter Revenue
  239. - Pending Payments (amount + client count)
  240. - Average Project Value
  241.  
  242. **Filter Section:**
  243. - Date Range: Custom / This Week / Month / Quarter / Year / All Time
  244. - Project Filter (multi-select)
  245. - Client Filter (multi-select)
  246. - Payment Status Filter
  247. - Export Button (Excel / CSV / PDF)
  248.  
  249. **Visual Analytics:**
  250.  
  251. 1. **Revenue Trend Graph**
  252. - Line/Bar chart
  253. - Monthly/Quarterly/Yearly toggle
  254. - Interactive (tap for exact values)
  255.  
  256. 2. **Revenue by Project (Pie Chart)**
  257. - Color-coded
  258. - Percentage contribution
  259. - Tap to drill down
  260.  
  261. 3. **Revenue by Client (Bar Chart)**
  262. - Top 10 clients ranked
  263. - Total revenue per client
  264.  
  265. 4. **Payment Status Distribution (Donut Chart)**
  266. - Paid (Green)
  267. - Partial (Orange)
  268. - Unpaid (Red)
  269. - Pending (Yellow)
  270.  
  271. 5. **Monthly Comparison Table**
  272. - Month | Revenue | Projects | Avg/Project | Growth %
  273.  
  274. **Revenue Transactions List:**
  275. Sortable/Filterable table with:
  276. - Date
  277. - Client Name
  278. - Project Name
  279. - Version
  280. - Amount
  281. - Payment Method
  282. - Status
  283. - Invoice (download/view)
  284. - Actions: Edit / Delete / Mark Paid
  285.  
  286. **Swipe Actions:**
  287. - Swipe right: Mark as Paid
  288. - Swipe left: Delete
  289.  
  290. **Insights Summary Cards:**
  291. Auto-generated insights like:
  292. - "Best month: March 2024 - ₹XX,XXX"
  293. - "Revenue up 45% vs last quarter"
  294. - "3 pending payments: ₹XX,XXX total"
  295. - "Average project value: ₹XX,XXX"
  296. - "Top client: [Name] - ₹XX,XXX"
  297.  
  298. ---
  299.  
  300. ## **MODULE 5: CLIENTS MANAGEMENT**
  301.  
  302. ### **Clients List Screen:**
  303.  
  304. **Search & Sort:**
  305. - Search by name/company/email
  306. - Sort by: Revenue / Alphabetical / Recent / Projects Count
  307.  
  308. **Client Card Display:**
  309. - Avatar/Logo
  310. - Client Name
  311. - Company Name
  312. - Projects Count | Total Revenue
  313. - Email
  314. - Phone
  315. - Quick Actions: View / Contact / Invoice
  316.  
  317. ### **Client Detail Screen - Tabs:**
  318.  
  319. **1. Overview:**
  320. - Contact information (editable)
  321. - Total revenue
  322. - Active/Completed projects count
  323. - Payment history summary
  324. - Quick contact: Call / Email / WhatsApp buttons
  325.  
  326. **2. Projects:**
  327. - List all projects/versions for this client
  328. - Add New Project button
  329.  
  330. **3. Invoices:**
  331. - All invoices list
  332. - Generate new invoice
  333. - Send via email
  334.  
  335. **4. Notes:**
  336. - Meeting notes
  337. - Requirements
  338. - Communication log
  339. - Voice notes support
  340.  
  341. **5. Activity:**
  342. - Timeline of all interactions
  343. - Payments, projects, messages
  344.  
  345. ---
  346.  
  347. ## **MODULE 6: TASKS & REMINDERS**
  348.  
  349. ### **Tasks Screen:**
  350.  
  351. **View Modes:**
  352. - List View
  353. - Kanban Board (To Do | In Progress | Done)
  354. - Calendar View
  355. - Priority View
  356.  
  357. **Filters:**
  358. - All Tasks
  359. - By Project
  360. - By Client
  361. - By Priority
  362. - By Due Date
  363. - Overdue Only
  364. - Completed
  365.  
  366. **Task Card Elements:**
  367. - Priority indicator (color-coded)
  368. - Task title
  369. - Project name
  370. - Client name
  371. - Due date & time
  372. - Progress bar (if has sub-tasks)
  373. - Sub-tasks checklist
  374. - Buttons: Mark Done / Edit / Delete / Snooze
  375.  
  376. **Notification System:**
  377. Push notifications for:
  378. - Task due soon
  379. - Payment due
  380. - Project deadline approaching
  381. - Payment received
  382. - Custom reminders
  383.  
  384. ---
  385.  
  386. # 📋 **PHASE 2: ADDITIONAL FEATURES**
  387.  
  388. ## **FEATURE 1: Invoice Generator**
  389.  
  390. - Professional invoice templates
  391. - Auto-populate from version/payment data
  392. - Customizable fields
  393. - Add discounts
  394. - Show payment method info from settings
  395. - Preview before generating
  396. - Download as PDF
  397. - Send via email directly
  398. - Track status: Draft / Sent / Viewed / Paid
  399.  
  400. ## **FEATURE 2: Expense Tracker**
  401.  
  402. Track project-related expenses:
  403. - Hosting costs
  404. - Domain purchases
  405. - API costs
  406. - Software subscriptions
  407. - Freelancer payments
  408.  
  409. **Categories:**
  410. - Infrastructure
  411. - Development Tools
  412. - Marketing
  413. - Outsourcing
  414. - Miscellaneous
  415.  
  416. **Show:**
  417. - Total expenses
  418. - Net Profit = Revenue - Expenses
  419. - Expense breakdown charts
  420.  
  421. ## **FEATURE 3: Time Tracker**
  422.  
  423. - Built-in timer for tasks
  424. - Manual time entry
  425. - Time logged per project/version
  426. - Hourly rate calculator
  427. - Generate timesheets
  428. - Export time reports
  429.  
  430. ## **FEATURE 4: Document Vault**
  431.  
  432. - Store contracts, NDAs, agreements
  433. - Organize by client/project
  434. - Quick search
  435. - Tag system
  436. - Secure with app lock
  437. - Store in Google Drive
  438.  
  439. ## **FEATURE 5: Templates Library**
  440.  
  441. User can save and reuse:
  442. - Project templates
  443. - Feature sets
  444. - Pricing packages
  445. - Email templates
  446. - Proposal templates
  447. - Contract templates
  448.  
  449. ## **FEATURE 6: Goals & Targets**
  450.  
  451. Set and track:
  452. - Monthly revenue goal
  453. - Quarterly revenue goal
  454. - Annual revenue goal
  455. - Project count target
  456. - Client acquisition target
  457.  
  458. Show:
  459. - Progress bars
  460. - Achievement percentage
  461. - Notifications when goals achieved
  462.  
  463. ## **FEATURE 7: Reports Generator**
  464.  
  465. Generate and export:
  466.  
  467. 1. **Monthly Business Report:**
  468. - Revenue summary
  469. - Project summary
  470. - Client summary
  471. - Top performers
  472.  
  473. 2. **Client Report:**
  474. - Per-client analysis
  475. - Project history
  476. - Payment history
  477.  
  478. 3. **Project Performance:**
  479. - Time vs estimate
  480. - Profitability
  481. - Completion rate
  482.  
  483. Export as: PDF / Excel
  484. Schedule: Auto-generate monthly
  485.  
  486. ## **FEATURE 8: Search & Filter**
  487.  
  488. - Global search across all modules
  489. - Search: projects, clients, tasks, payments
  490. - Advanced filters
  491. - Recent searches
  492. - Search suggestions
  493.  
  494. ## **FEATURE 9: Backup & Sync**
  495.  
  496. - Auto-backup to Google Drive (daily)
  497. - Manual backup option
  498. - Restore from backup
  499. - Export all data (JSON / Excel)
  500. - Sync across devices in real-time
  501.  
  502. ---
  503.  
  504. # 📋 **PHASE 3: SETTINGS MODULE**
  505.  
  506. ## **SETTINGS STRUCTURE**
  507.  
  508. Create organized settings with these sections:
  509.  
  510. ### **1. BUSINESS PROFILE**
  511.  
  512. Fields to save:
  513. - Business logo (upload/change/remove)
  514. - Business name*
  515. - Tagline
  516. - Email*
  517. - Phone number
  518. - WhatsApp number (checkbox: same as phone)
  519. - Website URL
  520. - Address: Street, City, State, PIN, Country (dropdown for country)
  521. - Digital signature (upload / draw / clear)
  522.  
  523. Simple form layout with save button.
  524.  
  525. ---
  526.  
  527. ### **2. REGION & FORMAT**
  528.  
  529. **Language:**
  530. - English (India) - Default
  531. - Hinglish
  532.  
  533. **Currency:**
  534. - Indian Rupee (₹) - Default
  535. - US Dollar ($)
  536. - Euro (€)
  537. - British Pound (£)
  538.  
  539. **Currency Display:**
  540. - Symbol format: ₹1,234.56
  541. - Code format: INR 1,234.56
  542.  
  543. **Thousand Separator:**
  544. - Comma (1,234,567)
  545. - None (1234567)
  546.  
  547. **Indian Numbering System:**
  548. - Toggle ON/OFF
  549. - When ON: 12,34,567
  550. - When OFF: 1,234,567
  551.  
  552. **Date Format:**
  553. - DD/MM/YYYY (default for India)
  554. - MM/DD/YYYY
  555. - YYYY-MM-DD
  556.  
  557. **Time Format:**
  558. - 12-hour (AM/PM) - default
  559. - 24-hour
  560.  
  561. **Week Starts On:**
  562. - Sunday (default)
  563. - Monday
  564.  
  565. **Preview Section:**
  566. Show preview of selected formats:
  567. - Currency: ₹12,34,567
  568. - Date: 28/12/2024
  569. - Time: 05:30 PM
  570.  
  571. ---
  572.  
  573. ### **3. PROJECT DEFAULTS**
  574.  
  575. Default settings for new projects:
  576.  
  577. **Project Settings:**
  578. - Default project type: Website / Mobile App / Both
  579. - Default status: Active / Planning / On Hold
  580. - Default duration: 7 / 15 / 30 / 60 / 90 days
  581.  
  582. **Version Settings:**
  583. - Version naming: v1.0, v2.0 / v1, v2 / Basic, Premium
  584. - Auto-increment version: ON/OFF
  585.  
  586. **Sorting Preferences:**
  587. - Default project sort: Recently Updated / Name / Date
  588. - Default client sort: Revenue / Name / Recent
  589. - Default task sort: Due Date / Priority / Recent
  590.  
  591. Simple dropdowns and toggles.
  592.  
  593. ---
  594.  
  595. ### **4. PAYMENT METHODS**
  596.  
  597. Store payment information (displayed on invoices):
  598.  
  599. **Bank Transfer:**
  600. - Enable/Disable toggle
  601. - Bank name
  602. - Account holder name
  603. - Account number (with show/hide)
  604. - IFSC/Routing code
  605. - Account type: Savings / Current
  606.  
  607. **UPI:**
  608. - Enable/Disable toggle
  609. - UPI ID
  610. - Generate QR code button
  611.  
  612. **Cash:**
  613. - Enable/Disable toggle
  614.  
  615. **PayPal:**
  616. - Enable/Disable toggle
  617. - PayPal email
  618.  
  619. **Invoice Settings:**
  620. - Invoice prefix (text: e.g., "INV")
  621. - Starting number (e.g., "001")
  622. - Preview display: INV-001
  623. - Payment terms: Due immediately / 7 days / 15 days / 30 days / 60 days
  624.  
  625. ---
  626.  
  627. ### **5. NOTIFICATIONS**
  628.  
  629. **Master Control:**
  630. - Enable all notifications: ON/OFF
  631.  
  632. **Notify me for:**
  633. - Task reminders ☐
  634. - Payment due ☐
  635. - Project deadlines ☐
  636. - Payment received ☐
  637. - Daily summary ☐
  638. - Weekly report ☐
  639.  
  640. **Notification Style:**
  641. - Sound: ON/OFF
  642. - Vibration: ON/OFF
  643. - Show on lock screen: ON/OFF
  644.  
  645. **Quiet Hours:**
  646. - Enable: ON/OFF
  647. - From: (time picker) 11:00 PM
  648. - To: (time picker) 08:00 AM
  649.  
  650. **Reminder Defaults:**
  651. - Remind before: 15 min / 1 hour / 1 day / At due time
  652.  
  653. **Calendar Sync:**
  654. - Sync with device calendar: ON/OFF
  655. - What to sync:
  656. - Task deadlines ☐
  657. - Project deadlines ☐
  658. - Payment due dates ☐
  659. - "Sync Now" button
  660.  
  661. ---
  662.  
  663. ### **6. BACKUP & DATA**
  664.  
  665. **Cloud Backup:**
  666. - Auto backup: ON/OFF
  667. - Backup frequency: Daily / Weekly / Manual only
  668. - Backup only on WiFi: ON/OFF
  669. - Last backup: (show date & time)
  670. - Backup size: (show in MB)
  671. - "Backup Now" button
  672.  
  673. **Restore:**
  674. - List of available backups (show date)
  675. - Each has: "Restore" button / "Delete" button
  676.  
  677. **Export Data:**
  678. - Export format: Excel / CSV / PDF
  679. - "Export All Data" button
  680. - Saves to device downloads folder
  681.  
  682. **Storage:**
  683. - Show storage used (in MB)
  684. - "Clear Cache" button
  685.  
  686. ---
  687.  
  688. ### **7. SECURITY**
  689.  
  690. **App Lock:**
  691. - Enable app lock: ON/OFF
  692. - Lock method: Biometric (Fingerprint/Face) / PIN / Password
  693. - "Change PIN/Password" button
  694. - Auto-lock after: Immediately / 1 min / 5 min / 15 min (slider)
  695.  
  696. **Account:**
  697. - Show email with verification status
  698. - "Change Password" button
  699.  
  700. **Privacy:**
  701. - Hide app content in app switcher: ON/OFF
  702. (Blurs app preview when switching apps)
  703.  
  704. Keep it simple and secure.
  705.  
  706. ---
  707.  
  708. ### **8. PERMISSIONS**
  709.  
  710. Display list of permissions with status:
  711.  
  712. Show each permission:
  713. - Icon + Name
  714. - Status: Allowed / Denied
  715. - Purpose/Usage
  716.  
  717. **Permissions:**
  718. - 🎤 Microphone - For voice notes
  719. - 🌐 Internet - For sync & backup
  720. - 💾 Storage - For saving files
  721. - 🔔 Notifications - For reminders
  722. - 📅 Calendar - For syncing deadlines
  723. - 📷 Camera - For scanning documents
  724. - 🖼️ Photos - For uploading images
  725. - 📁 Files - For attaching documents
  726.  
  727. "Manage in System Settings" button
  728.  
  729. ---
  730.  
  731. ### **9. HELP & ABOUT**
  732.  
  733. **Help Section:**
  734. - View tutorials
  735. - FAQs (Frequently Asked Questions)
  736. - Contact support (email button)
  737. - Report bug
  738. - Send feedback
  739.  
  740. **About Section:**
  741. - App icon
  742. - App name
  743. - Version number (e.g., v1.0.0)
  744. - Developer name
  745. - Developer email
  746. - "Check for Updates" button
  747. - Privacy Policy link
  748. - Terms of Service link
  749.  
  750. **App Info:**
  751. - App size (in MB)
  752. - Cache size (in MB)
  753. - Firebase connection status (Connected ✅ / Disconnected ❌)
  754.  
  755. Footer: "Made with ❤️ for Developers"
  756.  
  757. ---
  758.  
  759. # 📋 **PHASE 4: TECHNICAL SPECIFICATIONS**
  760.  
  761. ## **FIREBASE FIRESTORE STRUCTURE**
  762.  
  763. ### **Collections:**
  764.  
  765. ```
  766. users/
  767. {userId}/
  768. - profile (name, email, businessName, phone, createdAt)
  769. - settings (theme, currency, language, preferences)
  770.  
  771. projects/
  772. {projectId}/
  773. - userId (owner)
  774. - projectName
  775. - projectType
  776. - projectIcon
  777. - startDate
  778. - endDate
  779. - status
  780. - basePrice
  781. - description
  782. - files[] (Google Cloud Storage URLs)
  783. - createdAt
  784. - updatedAt
  785.  
  786. versions/
  787. {versionId}/
  788. - projectId (reference)
  789. - userId (owner)
  790. - versionName
  791. - versionType
  792. - clientId (reference)
  793. - totalCost
  794. - amountReceived
  795. - remainingAmount
  796. - paymentStatus
  797. - paymentMethod
  798. - paymentDate
  799. - nextPaymentDate
  800. - invoiceNumber
  801. - startDate
  802. - expectedDeliveryDate
  803. - actualDeliveryDate
  804. - deploymentLinks {dev, staging, prod, repo}
  805. - features[] {name, description, status, priority}
  806. - createdAt
  807. - updatedAt
  808.  
  809. clients/
  810. {clientId}/
  811. - userId (owner)
  812. - clientName
  813. - companyName
  814. - email
  815. - phone
  816. - address
  817. - avatar (Google Cloud Storage URL)
  818. - totalRevenue (calculated)
  819. - projectsCount (calculated)
  820. - createdAt
  821. - updatedAt
  822.  
  823. tasks/
  824. {taskId}/
  825. - userId (owner)
  826. - projectId (reference)
  827. - versionId (reference)
  828. - clientId (reference)
  829. - title
  830. - description
  831. - dueDate
  832. - priority
  833. - status
  834. - reminderTime
  835. - reminderSent (boolean)
  836. - subTasks[] {title, completed}
  837. - attachments[] (Google Cloud Storage URLs)
  838. - createdAt
  839. - updatedAt
  840.  
  841. revenue/
  842. {revenueId}/
  843. - userId (owner)
  844. - projectId (reference)
  845. - versionId (reference)
  846. - clientId (reference)
  847. - amount
  848. - paymentDate
  849. - paymentMethod
  850. - invoiceNumber
  851. - status
  852. - notes
  853. - createdAt
  854.  
  855. expenses/
  856. {expenseId}/
  857. - userId (owner)
  858. - projectId (reference)
  859. - category
  860. - amount
  861. - description
  862. - date
  863. - receipt (Google Cloud Storage URL)
  864. - createdAt
  865.  
  866. invoices/
  867. {invoiceId}/
  868. - userId (owner)
  869. - clientId (reference)
  870. - versionId (reference)
  871. - invoiceNumber
  872. - invoiceDate
  873. - dueDate
  874. - items[]
  875. - subtotal
  876. - discount
  877. - total
  878. - status
  879. - pdfUrl (Google Cloud Storage URL)
  880. - sentDate
  881. - paidDate
  882. - createdAt
  883.  
  884. notifications/
  885. {notificationId}/
  886. - userId (owner)
  887. - type
  888. - title
  889. - message
  890. - read (boolean)
  891. - relatedId
  892. - createdAt
  893. - actionUrl
  894.  
  895. activityLog/
  896. {activityId}/
  897. - userId (owner)
  898. - type
  899. - description
  900. - relatedId
  901. - metadata {}
  902. - timestamp
  903. ```
  904.  
  905. ---
  906.  
  907. ## **GOOGLE CLOUD STORAGE STRUCTURE**
  908.  
  909. ```
  910. /users/{userId}/
  911. /profile/
  912. - avatar.jpg
  913. /projects/{projectId}/
  914. /documents/
  915. /designs/
  916. /contracts/
  917. /versions/{versionId}/
  918. /attachments/
  919. /tasks/{taskId}/
  920. /files/
  921. /invoices/
  922. - {invoiceId}.pdf
  923. /expenses/
  924. /receipts/
  925. /backups/
  926. - backup_YYYY-MM-DD.json
  927. ```
  928.  
  929. ---
  930.  
  931. ## **SUPABASE FUNCTIONS**
  932.  
  933. Create cloud functions for:
  934.  
  935. 1. **onVersionCreate**
  936. - Auto-create revenue entry
  937. - Update client totalRevenue
  938. - Create activity log
  939.  
  940. 2. **onRevenueUpdate**
  941. - Update client totalRevenue
  942. - Update dashboard stats
  943. - Check if payment complete
  944.  
  945. 3. **onTaskCreate**
  946. - Schedule notification reminder
  947. - Add to calendar if sync enabled
  948.  
  949. 4. **onTaskUpdate**
  950. - Notify when marked done
  951. - Update version progress
  952.  
  953. 5. **scheduledDailyReminders** (Cron job)
  954. - Check tasks due today/tomorrow
  955. - Send notifications
  956. - Check pending payments
  957.  
  958. 6. **generateMonthlyReport** (Cron job - 1st of month)
  959. - Generate business report
  960. - Send email if configured
  961.  
  962. 7. **calculateAnalytics** (Callable)
  963. - Process revenue data
  964. - Generate chart data
  965. - Return analytics
  966.  
  967. 8. **generateInvoicePDF** (Callable)
  968. - Create PDF from template
  969. - Upload to Google Cloud Storage
  970. - Return URL
  971.  
  972. 9. **aggregateData** (Scheduled)
  973. - Update summary stats
  974. - Optimize query performance
  975.  
  976. ---
  977.  
  978. ## **FIREBASE SECURITY RULES**
  979.  
  980. ### **Firestore Rules:**
  981.  
  982. ```javascript
  983. rules_version = '2';
  984. service cloud.firestore {
  985. match /databases/{database}/documents {
  986. // Users can only access their own data
  987. match /{collection}/{document} {
  988. allow read, write: if request.auth != null &&
  989. resource.data.userId == request.auth.uid;
  990. }
  991. }
  992. }
  993. ```
  994.  
  995. ### **Storage Rules:**
  996.  
  997. ```javascript
  998. rules_version = '2';
  999. service firebase.storage {
  1000. match /b/{bucket}/o {
  1001. match /users/{userId}/{allPaths=**} {
  1002. allow read, write: if request.auth != null &&
  1003. request.auth.uid == userId;
  1004. }
  1005. }
  1006. }
  1007. ```
  1008.  
  1009. ---
  1010.  
  1011. # 📋 **PHASE 5: USER FLOWS & NAVIGATION**
  1012.  
  1013. ## **USER FLOW DIAGRAM**
  1014.  
  1015. ```
  1016. App Launch
  1017. Firebase Authentication
  1018. Dashboard (Home)
  1019. ├─→ Projects → Project Details → Versions → Version Details → Edit
  1020. ├─→ Add Project → Create → Add Versions → Create Version → Save
  1021. ├─→ Revenue → Analytics → Filter → Export
  1022. ├─→ Clients → Client Details → Projects/Invoices/Notes
  1023. ├─→ Tasks → Task Details → Edit/Complete
  1024. ├─→ More → Settings / Help / Reports
  1025. └─→ Quick Actions (FAB) → Add Project/Client/Revenue/Task
  1026. ```
  1027.  
  1028. ## **NAVIGATION STRUCTURE**
  1029.  
  1030. **Bottom Tab Navigation:**
  1031. 1. Dashboard - Home screen with overview
  1032. 2. Projects - All projects list
  1033. 3. Revenue - Analytics & tracking
  1034. 4. Clients - Client management
  1035. 5. More - Tasks, Settings, Reports, Help
  1036.  
  1037. **Floating Action Button (FAB):**
  1038. Available on all screens for quick actions
  1039.  
  1040. ---
  1041.  
  1042. # 📋 **PHASE 6: IMPORTANT NOTES & GUIDELINES**
  1043.  
  1044. ## **DESIGN GUIDELINES**
  1045.  
  1046. 1. **Keep It Simple:**
  1047. - Clean, uncluttered interface
  1048. - Easy navigation
  1049. - Clear labels and buttons
  1050. - Intuitive user experience
  1051.  
  1052. 2. **Color Coding:**
  1053. - Green: Completed, Paid, Success
  1054. - Orange: Partial, In Progress, Warning
  1055. - Red: Unpaid, Overdue, Error
  1056. - Blue: Information, Links
  1057. - Gray: Inactive, Cancelled
  1058.  
  1059. 3. **Responsive:**
  1060. - Work on all screen sizes
  1061. - Support both portrait and landscape
  1062. - Optimize for tablets
  1063.  
  1064. 4. **Accessibility:**
  1065. - Proper contrast ratios
  1066. - Readable font sizes
  1067. - Support for screen readers
  1068. - Clear touch targets (minimum 44x44px)
  1069.  
  1070. 5. **Performance:**
  1071. - Fast loading times
  1072. - Smooth animations (300ms transitions)
  1073. - Efficient data loading
  1074. - Offline mode support
  1075. - Image optimization
  1076.  
  1077. ## **DATA VALIDATION**
  1078.  
  1079. **Required Fields:**
  1080. - Mark with asterisk (*)
  1081. - Show error if empty on submit
  1082. - Red border on invalid fields
  1083.  
  1084. **Input Validation:**
  1085. - Email: proper email format
  1086. - Phone: valid phone number
  1087. - URLs: valid URL format
  1088. - Numbers: only numeric input
  1089. - Dates: valid date selection
  1090.  
  1091. **Error Handling:**
  1092. - Show clear error messages
  1093. - Suggest corrections
  1094. - Don't lose user data on errors
  1095. - Implement auto-save for long forms
  1096.  
  1097. ## **NOTIFICATIONS**
  1098.  
  1099. **Push Notifications:**
  1100. - Ask permission on first launch
  1101. - Send at appropriate times (not during quiet hours)
  1102. - Clear, actionable messages
  1103. - Deep links to relevant screens
  1104.  
  1105. **In-App Notifications:**
  1106. - Toast messages for quick feedback
  1107. - Banner notifications for important updates
  1108. - Persistent notifications for critical actions
  1109.  
  1110. ## **OFFLINE MODE**
  1111.  
  1112. - Cache data locally
  1113. - Allow basic operations offline
  1114. - Sync when connection restored
  1115. - Show sync status indicator
  1116. - Handle conflicts intelligently
  1117.  
  1118. ## **SECURITY**
  1119.  
  1120. - All data encrypted in transit and at rest
  1121. - Secure authentication with Firebase Auth
  1122. - App lock with biometric/PIN
  1123. - Session management
  1124. - Secure API calls
  1125. - No sensitive data in logs
  1126.  
  1127. ---
  1128.  
  1129. # 📋 **PHASE 7: TESTING & LAUNCH**
  1130.  
  1131. ## **TESTING REQUIREMENTS**
  1132.  
  1133. **Functional Testing:**
  1134. - All CRUD operations work
  1135. - Data syncs correctly
  1136. - Calculations accurate (revenue, expenses, etc.)
  1137. - Search and filters work
  1138. - Notifications sent properly
  1139. - Export functions work
  1140.  
  1141. **UI/UX Testing:**
  1142. - All screens display correctly
  1143. - Navigation smooth
  1144. - Buttons respond
  1145. - Forms validate
  1146. - Loading states show
  1147. - Error states handled
  1148.  
  1149. **Performance Testing:**
  1150. - App launches in <3 seconds
  1151. - Screens load in <1 second
  1152. - Smooth scrolling (60fps)
  1153. - No memory leaks
  1154. - Efficient battery usage
  1155.  
  1156. **Security Testing:**
  1157. - Data encrypted
  1158. - Authentication secure
  1159. - Authorization working
  1160. - No data leaks
  1161. - App lock functional
  1162.  
  1163. **Cross-Device Testing:**
  1164. - Test on different screen sizes
  1165. - Test on iOS and Android
  1166. - Test different OS versions
  1167. - Test with slow internet
  1168. - Test offline mode
  1169.  
  1170. ## **LAUNCH CHECKLIST**
  1171.  
  1172. - [ ] All features implemented
  1173. - [ ] All bugs fixed
  1174. - [ ] Performance optimized
  1175. - [ ] Security verified
  1176. - [ ] Privacy policy ready
  1177. - [ ] Terms of service ready
  1178. - [ ] App store assets prepared
  1179. - [ ] Screenshots taken
  1180. - [ ] Description written
  1181. - [ ] Testing completed
  1182. - [ ] Backup system verified
  1183. - [ ] Analytics configured
  1184. - [ ] Crashlytics setup
  1185.  
  1186. ---
  1187.  
  1188. # 🎯 **FINAL REQUIREMENTS SUMMARY**
  1189.  
  1190. ## **MUST HAVE:**
  1191. ✅ Project management with versions
  1192. ✅ Client management
  1193. ✅ Revenue tracking with analytics
  1194. ✅ Task management with reminders
  1195. ✅ Invoice generation
  1196. ✅ Expense tracking
  1197. ✅ Document storage
  1198. ✅ Cloud backup & sync
  1199. ✅ Search & filters
  1200. ✅ Reports generation
  1201. ✅ Multiple themes (5 total, 1 with dynamic background)
  1202. ✅ Settings with all specified sections
  1203. ✅ Notifications system
  1204. ✅ Calendar sync
  1205.  
  1206. ## **MUST NOT HAVE:**
  1207. ❌ Tax calculations/configuration
  1208. ❌ Payment gateway integrations (Stripe, Razorpay, etc.)
  1209. ❌ Real-time payment processing
  1210. ❌ Over-complicated features
  1211. ❌ Unnecessary animations
  1212. ❌ Cluttered interface
  1213.  
  1214. ## **BACKEND STACK (CONFIRMED):**
  1215. ✅ Firebase Firestore - Structured data
  1216. ✅ Google Cloud Storage - Large files
  1217. ✅ Google Drive - File storage & sync
  1218. ✅ Firebase Authentication - User auth
  1219. ✅ Supabase Functions - Cloud functions
  1220. ✅ Firebase Crashlytics - Crash reporting
  1221. ✅ Firebase Remote Config - Feature flags
  1222. ✅ Firebase Analytics - Usage tracking
  1223.  
  1224. ## **LANGUAGE & CURRENCY:**
  1225. ✅ Languages: English (India), Hinglish
  1226. ✅ Default Currency: Indian Rupee (₹)
  1227. ✅ Supported: INR, USD
  1228.  
  1229. ---
  1230.  
  1231. # 🚀 **BUILD INSTRUCTIONS FOR AI STUDIO**
  1232.  
  1233. **You are tasked with building this complete application. Follow these guidelines:**
  1234.  
  1235. 1. **Architecture First:**
  1236. - Set up backend (Firebase, Google Cloud Storage, Supabase)
  1237. - Implement authentication
  1238. - Create database structure
  1239. - Set up security rules
  1240.  
  1241. 2. **Core Features:**
  1242. - Build dashboard first
  1243. - Implement project management
  1244. - Add version management (most critical)
  1245. - Implement client management
  1246. - Add revenue tracking
  1247. - Build task system
  1248.  
  1249. 3. **Additional Features:**
  1250. - Invoice generator
  1251. - Expense tracker
  1252. - Document vault
  1253. - Reports
  1254. - Search
  1255.  
  1256. 4. **Settings & Customization:**
  1257. - Implement all 9 settings sections
  1258. - Create 5 unique themes (1 with dynamic background)
  1259. - Add preferences
  1260.  
  1261. 5. **Polish:**
  1262. - Optimize performance
  1263. - Test thoroughly
  1264. - Fix bugs
  1265. - Ensure smooth UX
  1266.  
  1267. 6. **Think Intelligently:**
  1268. - Make smart decisions where specifications are not detailed
  1269. - Implement best practices
  1270. - Optimize for mobile
  1271. - Ensure data integrity
  1272. - Handle edge cases
  1273. - Provide great user experience
  1274.  
  1275. **Build a production-ready, professional app that developers will love to use!** 🎯
  1276.  
  1277. ---
  1278.  
  1279. **END OF PROMPT**