feat(server): add storage template variable assetId (#4555)
* Added assetId as template Co-authored-by: Jason Rasmussen <jrasm91@gmail.com> Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> * styling * styling --------- Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> Co-authored-by: Jason Rasmussen <jrasm91@gmail.com> Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
This commit is contained in:
committed by
GitHub
parent
383f11019a
commit
ab3f82cfe4
@@ -191,6 +191,7 @@ export class StorageTemplateService {
|
||||
fileCreatedAt: new Date(),
|
||||
originalPath: '/upload/test/IMG_123.jpg',
|
||||
type: AssetType.IMAGE,
|
||||
id: 'd587e44b-f8c0-4832-9ba3-43268bbf5d4e',
|
||||
} as AssetEntity;
|
||||
try {
|
||||
this.render(this.compile(config.storageTemplate.template), testAsset, 'IMG_123', 'jpg');
|
||||
@@ -218,6 +219,7 @@ export class StorageTemplateService {
|
||||
ext,
|
||||
filetype: asset.type == AssetType.IMAGE ? 'IMG' : 'VID',
|
||||
filetypefull: asset.type == AssetType.IMAGE ? 'IMAGE' : 'VIDEO',
|
||||
assetId: asset.id,
|
||||
};
|
||||
|
||||
const systemTimeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
||||
|
||||
Reference in New Issue
Block a user