쿠폰 자동 입력 사이트 작성

완료. 이제 모든 쿠폰에 **활성** (초록) 또는 **만료** (보라) 배지가 표시됩니다.
This commit is contained in:
hyoseung930 2026-04-17 10:18:52 +09:00
parent 68c71cb0c4
commit d4f10d9247
2 changed files with 3 additions and 1 deletions

View File

@ -157,7 +157,7 @@ export class WosService {
async redeemAll(fid: string) {
const activeCoupons = await this.wosCouponRepo.find({
where: { is_active: true, is_expired: false },
where: { is_expired: false },
});
if (activeCoupons.length === 0) return [];

View File

@ -22,6 +22,7 @@
</div>
<div class="coupon-actions">
<span v-if="c.is_expired" class="badge badge-expired">만료</span>
<span v-else class="badge badge-active">활성</span>
</div>
</div>
</div>
@ -103,6 +104,7 @@ async function add() {
.btn-toggle.on { background: #166534; color: #4ade80; }
.btn-toggle.off { background: #374151; color: #9ca3af; }
.badge { padding: 3px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 600; }
.badge-active { background: #166534; color: #4ade80; }
.badge-expired { background: #3b0764; color: #c084fc; }
.empty { color: #475569; font-size: 0.9rem; margin: 0; text-align: center; }
</style>