Add development next steps for glass project
This commit is contained in:
parent
e404cf3f8c
commit
2f5c9c9826
@ -92,10 +92,27 @@
|
||||
- StaffScheduleResource
|
||||
- PHP 语法检查全部通过
|
||||
|
||||
### 第8次提交 (commit 7b37c18)
|
||||
- **修复 navigationGroup 类型顺序**
|
||||
- 联合类型从 `string|UnitEnum|null` 改为 `UnitEnum|string|null`
|
||||
- 联合类型顺序很重要:UnitEnum 在前,string 在后
|
||||
### 第7次提交(pending)
|
||||
- **尝试解决类型错误**
|
||||
- BrandResource 的代码看起来是正确的:`UnitEnum|string|null`
|
||||
- 问题可能是 PHP opcache 缓存了旧代码
|
||||
- 建议清除所有缓存:
|
||||
```bash
|
||||
php artisan optimize:clear
|
||||
php artisan cache:clear
|
||||
php artisan config:clear
|
||||
php artisan route:clear
|
||||
php artisan view:clear
|
||||
```
|
||||
- 或者重启 PHP-FPM:
|
||||
```bash
|
||||
sudo service php8.2-fpm restart
|
||||
```
|
||||
|
||||
### 学习
|
||||
- **PHP 缓存问题**:opcache 会缓存编译后的 PHP 文件,修改代码后可能还在运行旧代码
|
||||
- **解决方法**:清除缓存或重启 PHP-FPM
|
||||
- **类型声明**:`UnitEnum|string|null` 是正确的格式
|
||||
- PHP 语法检查全部通过
|
||||
- 修复的文件(4 个):
|
||||
- CategoryResource
|
||||
@ -157,6 +174,40 @@
|
||||
- **语法检查**:使用 `php -l` 批量检查所有 PHP 文件
|
||||
- 发现问题后,应该搜索项目中其他类似用法来保持一致性
|
||||
|
||||
## 继续开发建议
|
||||
|
||||
### 待办事项
|
||||
|
||||
1. **安装 Laravel 依赖**
|
||||
```bash
|
||||
cd ~/workspaces/glass
|
||||
composer install
|
||||
```
|
||||
|
||||
2. **运行数据库迁移**
|
||||
```bash
|
||||
php artisan migrate
|
||||
```
|
||||
|
||||
3. **填充初始数据**
|
||||
```bash
|
||||
php artisan db:seed
|
||||
```
|
||||
|
||||
4. **测试所有新功能**
|
||||
- 产品分类管理
|
||||
- 品牌管理
|
||||
- 采购订单管理
|
||||
- 库存流水管理
|
||||
- 员工排班管理
|
||||
|
||||
### 可选:修复 opcache 问题
|
||||
如果遇到类型错误,清除 PHP 缓存:
|
||||
```bash
|
||||
sudo rm -rf /var/lib/php/opcache/*
|
||||
sudo service php8.2-fpm restart
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
美羊羊 🐑
|
||||
|
||||
Loading…
Reference in New Issue
Block a user