파일이름 재정의

This commit is contained in:
focp212@naver.com
2025-11-12 14:16:50 +09:00
parent ba116aeaf4
commit 21bc8840a1
2 changed files with 5 additions and 2 deletions

View File

@@ -47,7 +47,8 @@ export const CashReceiptSample = ({
const section = document.getElementById('image-section') as HTMLElement;
toPng(section).then((image) => {
const link = document.createElement('a');
link.download = 'downloadImage.png';
let fileName = 'cash-receipt-' + moment().format('YYMMDDHHmmss');
link.download = fileName + '.png';
link.href = image;
link.click();
snackBar(t('common.imageRequested'), function(){