feat(produce): 完善统计、菜单与扫码搜索

This commit is contained in:
2026-09-01 20:45:40 +08:00
parent 32f1486f5e
commit 793f140a45
26 changed files with 591 additions and 41 deletions
@@ -41,14 +41,13 @@ class ScanDataDao extends BaseDao
{
$query = $this->query();
if (($where['keyword'] ?? '') !== '') {
$query->where(function (Builder $builder) use ($where) {
$keyword = '%' . $where['keyword'] . '%';
$builder->where('order_no', 'like', $keyword)
->orWhere('user_code', 'like', $keyword)
->orWhere('operator', 'like', $keyword)
->orWhere('remark', 'like', $keyword);
});
foreach (['order_no', 'user_code', 'operator', 'remark'] as $field) {
$value = trim((string) ($where['LIKE_' . $field] ?? ''));
if ($value === '') {
continue;
}
$query->where($field, 'like', '%' . $value . '%');
}
if (($where['process_id'] ?? '') !== '') {