- bag_price, bag_price_history 테이블 생성 - BagPriceModel, BagPriceHistoryModel - BagPrice 컨트롤러 (목록/등록/수정/삭제/이력) - 단가 변경 시 자동 이력 기록 (트랜잭션) - 기간 필터 조회 (적용시작일/종료일) - 봉투코드(O) 드롭다운 연동 - E2E 테스트 5개 전체 통과 - 스크린샷 2개 추가 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
35 lines
1.4 KiB
PHP
35 lines
1.4 KiB
PHP
<section class="border-b border-gray-300 p-2 shrink-0 bg-control-panel">
|
|
<div class="flex items-center gap-2">
|
|
<a href="<?= base_url('admin/bag-prices') ?>" class="text-blue-600 hover:underline text-sm">← 단가 목록</a>
|
|
<span class="text-gray-400">|</span>
|
|
<span class="text-sm font-bold text-gray-700">단가 변경 이력 — <?= esc($item->bp_bag_name) ?> (<?= esc($item->bp_bag_code) ?>)</span>
|
|
</div>
|
|
</section>
|
|
<div class="border border-gray-300 overflow-auto mt-2">
|
|
<table class="w-full data-table">
|
|
<thead>
|
|
<tr>
|
|
<th class="w-16">번호</th>
|
|
<th>변경 필드</th>
|
|
<th>이전 값</th>
|
|
<th>변경 값</th>
|
|
<th>변경일시</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody class="text-right">
|
|
<?php foreach ($list as $row): ?>
|
|
<tr>
|
|
<td class="text-center"><?= esc($row->bph_idx) ?></td>
|
|
<td class="text-left pl-2"><?= esc($row->bph_field) ?></td>
|
|
<td><?= number_format((float) $row->bph_old_value) ?></td>
|
|
<td><?= number_format((float) $row->bph_new_value) ?></td>
|
|
<td class="text-center"><?= esc($row->bph_changed_at) ?></td>
|
|
</tr>
|
|
<?php endforeach; ?>
|
|
<?php if (empty($list)): ?>
|
|
<tr><td colspan="5" class="text-center text-gray-400 py-4">변경 이력이 없습니다.</td></tr>
|
|
<?php endif; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|