쿠폰 자동 입력 사이트 작성
완료. 이제 모든 쿠폰에 **활성** (초록) 또는 **만료** (보라) 배지가 표시됩니다.
This commit is contained in:
parent
68c71cb0c4
commit
d4f10d9247
@ -157,7 +157,7 @@ export class WosService {
|
|||||||
|
|
||||||
async redeemAll(fid: string) {
|
async redeemAll(fid: string) {
|
||||||
const activeCoupons = await this.wosCouponRepo.find({
|
const activeCoupons = await this.wosCouponRepo.find({
|
||||||
where: { is_active: true, is_expired: false },
|
where: { is_expired: false },
|
||||||
});
|
});
|
||||||
if (activeCoupons.length === 0) return [];
|
if (activeCoupons.length === 0) return [];
|
||||||
|
|
||||||
|
|||||||
@ -22,6 +22,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="coupon-actions">
|
<div class="coupon-actions">
|
||||||
<span v-if="c.is_expired" class="badge badge-expired">만료</span>
|
<span v-if="c.is_expired" class="badge badge-expired">만료</span>
|
||||||
|
<span v-else class="badge badge-active">활성</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -103,6 +104,7 @@ async function add() {
|
|||||||
.btn-toggle.on { background: #166534; color: #4ade80; }
|
.btn-toggle.on { background: #166534; color: #4ade80; }
|
||||||
.btn-toggle.off { background: #374151; color: #9ca3af; }
|
.btn-toggle.off { background: #374151; color: #9ca3af; }
|
||||||
.badge { padding: 3px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 600; }
|
.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; }
|
.badge-expired { background: #3b0764; color: #c084fc; }
|
||||||
.empty { color: #475569; font-size: 0.9rem; margin: 0; text-align: center; }
|
.empty { color: #475569; font-size: 0.9rem; margin: 0; text-align: center; }
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user