Documentation ¶
Index ¶
- Variables
- func AddFileToZip(zipWriter *zip.Writer, filename string) error
- func EndFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
- func GenUUID() string
- func GetExtFromMime(mimeType string) (rv string)
- func ListFileSetClosure(baseURL, pth string) func(www http.ResponseWriter, req *http.Request)
- func MarkFilesWithTxClosure(pth string) func(www http.ResponseWriter, req *http.Request)
- func Setup(cfg *UploadFileCfg, dbf map[string]bool, lfp *os.File, as *session.Session)
- func StartFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
- func UploadFileClosure(pth string) func(www http.ResponseWriter, req *http.Request)
- func UploadFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
- func ZipFiles(filename string, files []string) error
- type FileListType
- type MetaDataFile
- type UploadFileCfg
Constants ¶
This section is empty.
Variables ¶
View Source
var DbFlags map[string]bool
View Source
var MimeToExtMap = map[string]string{
"image/jpeg": ".jpg",
"image/png": ".png",
"image/webp": ".webp",
"image/heic": ".heic",
"image/heif": ".heic",
"image/gif": ".gif",
"image/svg": ".svg",
"image/svg+xml": ".svg",
"image/apng": ".apng",
"image/avif": ".avif",
"text/plain": ".txt",
"audio/wav": ".wav",
"audio/mp3": ".mp3",
"application/pdf": ".pdf",
"application/json": ".json",
"application/csv": ".csv",
"application/excel": ".xls",
"application/xml": ".xml",
}
------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------
New ¶
------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------
Functions ¶
func EndFileSetClosure ¶
func EndFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
func GetExtFromMime ¶
func ListFileSetClosure ¶
func ListFileSetClosure(baseURL, pth string) func(www http.ResponseWriter, req *http.Request)
func MarkFilesWithTxClosure ¶
func MarkFilesWithTxClosure(pth string) func(www http.ResponseWriter, req *http.Request)
func StartFileSetClosure ¶
func StartFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
func UploadFileClosure ¶
func UploadFileClosure(pth string) func(www http.ResponseWriter, req *http.Request)
func UploadFileSetClosure ¶
func UploadFileSetClosure(pth string) func(www http.ResponseWriter, req *http.Request)
Types ¶
type FileListType ¶
type MetaDataFile ¶
type UploadFileCfg ¶
type UploadFileCfg struct { // Path where files are temporary uploaded to // Also where bulk load will pull input:__file_name__ from UploadPath string `json:"upload_path" default:"./www/files"` URLUploadPath string `json:"url_upload_path" default:"/files"` UploadTable string `json:"upload_table" default:"document"` BaseAwsServerURL string `json:"base_aws_server_url" default:"http://localhost:8080"` // added - replaces debug flag PushToAWS string `json:"push_to_aws" default:"yes"` S3Perms string `json:"s3_perms" defaulit:"private"` }
Click to show internal directories.
Click to hide internal directories.