package storage

import "github.com/break/junhong_cmp_fiber/pkg/constants"

type PresignResult struct {
	URL       string `json:"url"`
	FileKey   string `json:"file_key"`
	ExpiresIn int    `json:"expires_in"`
}

type PurposeMapping struct {
	Prefix      string
	ContentType string
}

var PurposeMappings = map[string]PurposeMapping{
	"iot_import": {Prefix: "imports", ContentType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"},
	"export":     {Prefix: "exports", ContentType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"},
	"attachment": {Prefix: "attachments", ContentType: ""},
	constants.StoragePurposeAssetPackageBatchOrder: {Prefix: constants.AssetPackageBatchOrderStoragePrefix, ContentType: "text/csv"},
	constants.StoragePurposeDeviceBatchAllocation:  {Prefix: constants.DeviceBatchAllocationStoragePrefix, ContentType: "text/csv"},
}
