83 lines
2.6 KiB
Markdown
83 lines
2.6 KiB
Markdown
# 2026-02-02 - 每日记忆
|
||
|
||
## 项目初始化
|
||
|
||
- 初始化了 Git 仓库
|
||
- 完成了首次提交(commit 9f2b862)
|
||
- 创建了 README.md 文件
|
||
- 设置了记忆系统目录
|
||
- 删除了 BOOTSTRAP.md
|
||
|
||
## Gitea 集成
|
||
|
||
- 通过 Gitea API 创建了仓库:`gouki/openclaw`
|
||
- 成功推送代码到远程仓库(commit e0490bf)
|
||
- 使用 ~/.netrc 文件进行 API 认证
|
||
- 创建了 3 个 Issues:
|
||
1. #1 配置 Git 用户信息
|
||
2. #2 填充 USER.md 用户档案
|
||
3. #3 添加 .gitignore 文件
|
||
|
||
## glass 项目迁移工作
|
||
|
||
### 第1次提交 (commit fa321b4)
|
||
- 更新 Category 和 Brand 模型
|
||
- 添加 icon, color, slug, sort_order 字段
|
||
- 添加自动生成 slug 的 boot 逻辑
|
||
- 添加新模型:
|
||
- PurchaseOrder(采购订单,带状态流转和收货逻辑)
|
||
- PurchaseOrderItem(采购订单明细)
|
||
- InventoryTransaction(库存流水)
|
||
- StaffSchedule(员工排班,带班次类型和调班功能)
|
||
- 添加数据库迁移:
|
||
- add_icon_and_color_to_categories_table
|
||
- add_slug_and_sort_order_to_brands_table
|
||
- create_purchase_orders_table
|
||
- create_purchase_order_items_table
|
||
- create_inventory_transactions_table
|
||
- create_staff_schedules_table
|
||
- 添加 Filament Resources:
|
||
- CategoryResource(产品分类管理,37个图标选项)
|
||
- BrandResource(品牌管理)
|
||
- 所有模型使用 BelongsToTenant trait 支持多租户
|
||
|
||
### 第2次提交 (commit 47106f1)
|
||
- 添加 Filament Resources:
|
||
- PurchaseOrderResource(采购订单,带收货入库和补入库操作)
|
||
- InventoryTransactionResource(库存交易记录,只读,支持日期过滤)
|
||
- StaffScheduleResource(员工排班,支持复制到明天)
|
||
- 添加所有对应 Pages 文件
|
||
|
||
### 代码质量
|
||
- 每完成一个功能模块立即提交到 git
|
||
- 所有代码遵循 glass 项目的现有规范
|
||
- 使用 Filament 4.x Schema API
|
||
- 适配多租户架构和权限系统
|
||
|
||
## glass-v2 分析文档
|
||
|
||
- 创建了详细的迁移分析文档:`projects/glass-v2-migration-analysis.md`
|
||
- 创建了详细的迁移计划:`projects/glass-v2-migration-detailed-plan.md`
|
||
- 5 个功能模块全部完成代码迁移
|
||
|
||
## PHP 8.2 安装
|
||
|
||
- 添加了 ondrej/php PPA
|
||
- 安装了 PHP 8.2.30 (CLI + FPM)
|
||
- 安装的扩展:
|
||
- bcmath, curl, gd, intl
|
||
- mbstring, mysql, xml, zip
|
||
- opcache, readline
|
||
- Laravel 项目现在可以使用 `php artisan` 命令
|
||
|
||
## 学习
|
||
|
||
- Gitea API 需要 ~/.netrc 文件或 API token 认证(Git 凭证存储不适用于 API)
|
||
- Gitea 禁止通过 git push 自动创建仓库
|
||
- curl -n 选项可以自动读取 .netrc 文件
|
||
- Ubuntu 安装多版本 PHP 需要使用 ondrej/php PPA
|
||
|
||
---
|
||
|
||
美羊羊 🐑
|