a4ec09b5bbfbaf7c4f40053b24f42f075a5b6b85 chmalee Tue Nov 12 14:23:32 2024 -0800 Lots of changes after meeting, mostly to accomadate hubtools uploads: allow parentDir in upload request, make batch change dropdowns have the right options. TODO: remove type selection all together from UI, make hub name generation not be hardcoded in ui diff --git src/hg/inc/userdata.h src/hg/inc/userdata.h index d1a1d5b..bd6d0bf 100644 --- src/hg/inc/userdata.h +++ src/hg/inc/userdata.h @@ -41,38 +41,37 @@ // path to hg.conf file that has a list of hubspace.quota.userName entries // for special per user quotas: #define HUB_SPACE_QUOTA_LIST_VAR "hubspace.quotaList" char *webDataDir(char *userName); /* Return a web accesible path to the userDataDir, this is different from the full path tusd uses */ char *getDataDir(char *userName); /* Return the full path to the user specific data directory, can be configured via hg.conf * on hgwdev, this is /data/apache/userdata/userStore/hash/userName/ * on the RR, this is /userdata/userStore/hash/userName/ */ char *prefixUserFile(char *userName, char *fname); /* Allocate a new string that contains the full per-user path to fname, NULL otherwise */ -char *writeHubText(char *path, char *userName, char *encodedHubName, char *hubName, char *db); +char *writeHubText(char *path, char *userName, char *hubName, char *db); /* Create a hub.txt file, optionally creating the directory holding it. For convenience, return * the file name of the created hub, which can be freed. */ -char *createNewTempHubForUpload(char *requestId, char *userName, char *db, char *trackFileName, char *trackType, char *reqHubName, char *parentDir); +void createNewTempHubForUpload(char *requestId, char *userName, char *db, char *trackFileName, char *trackType, char *parentDir); /* Creates a hub.txt for this upload with a random hub name. Returns the full path to the hub - * for convenience. If the reqHubName argument is non-NULL, use that as the hub name instead of - * a random string AND do not create a hub.txt, only for use from hubtools up command */ + * for convenience. */ void addHubSpaceRowForFile(struct hubSpace *row); /* We created a file for a user, now add an entry to the hubSpace table for it */ void removeFileForUser(char *fname, char *userName); /* Remove a file for this user if it exists */ void removeHubForUser(char *path, char *userName); /* Remove a hub directory for this user (and all files in the directory), if it exists */ struct userHubs *listHubsForUser(char *userName); /* Lists the directories for a particular user */ time_t getHubLatestTime(struct userHubs *hub); /* Return the latest access time of the files in a hub */