中文译文
使用 FIFO 和报告功能的综合 POS 应用程序开发
担任软件开发人员。你的任务是创建一个功能齐全的销售点(POS)应用程序,并集成每日销售报告功能。
你的任务是开发:
核心 POS 功能:
- 产品库存管理,跟踪买入价和卖出价
- 销售交易处理
- 实时库存更新
- 收银员友好的用户界面
FIFO 实现:
- 实现先进先出库存管理
- 跟踪带有采购日期的产品批次
- 自动优先销售最旧的库存
- 基于 FIFO 方法维护准确的成本计算
每日销售报告功能:
- 生成全面的每日销售报告,包括:
- 每日总销售收入
- 每日总利润(计算方式为:卖出价 - 买入价,使用 FIFO 成本法)
- 交易数量
- 最畅销产品
- 销售后的库存水平
- 生成全面的每日销售报告,包括:
技术规格:
- 使用现代编程语言(${language:next js})
- 包含用于存储产品、交易和库存批次的数据库设计
- 实现适当的错误处理和数据验证
- 创建简洁、直观的用户界面
- 包含用于演示的示例数据
交付物:
- 带注释的完整源代码
- 数据库模式/结构
- 安装和设置说明
- 关键功能的示例截图或演示
- 解释 FIFO 实现的简要文档
确保应用程序具备生产就绪能力,具有适当的数据持久化,并能高效处理每日多笔交易。
English original
Comprehensive POS Application Development with FIFO and Reporting
Act as a Software Developer. You are tasked with creating a comprehensive Point of Sales (POS) application with integrated daily sales reporting functionality.
Your task is to develop:
Core POS Features:
- Product inventory management with buy price and sell price tracking
- Sales transaction processing
- Real-time inventory updates
- User-friendly interface for cashiers
FIFO Implementation:
- Implement First-In-First-Out inventory management
- Track product batches with purchase dates
- Automatically sell oldest stock first
- Maintain accurate cost calculations based on FIFO methodology
Daily Sales Report Features:
- Generate comprehensive daily sales reports including:
- Total daily sales revenue
- Total daily profit (calculated as: sell price - buy price using FIFO costing)
- Number of transactions
- Best-selling products
- Inventory levels after sales
- Generate comprehensive daily sales reports including:
Technical Specifications:
- Use a modern programming language (${language:next js})
- Include a database design for storing products, transactions, and inventory batches
- Implement proper error handling and data validation
- Create a clean, intuitive user interface
- Include sample data for demonstration
Deliverables:
- Complete source code with comments
- Database schema/structure
- Installation and setup instructions
- Sample screenshots or demo of key features
- Brief documentation explaining the FIFO implementation
Ensure the application is production-ready with proper data persistence and can handle multiple daily transactions efficiently.