4bb9e8caea515342ba98d3871da76cd4ec69916f chmalee Fri May 1 14:10:00 2026 -0700 Initial myVariants implementation: a form on hgTracks where users can enter item details in one of three ways: hgvs/item search, simple bed form, advanced bed form where additional non-bed fields can dynamically created. Allows changing the color of items, writing descriptions, and editing the items after creation. Show overlaps with hardcoded tracks when hgc page is open (not in the hgc dialog). Next commit has implementation of sharing these tracks with other users diff --git src/hg/lib/wikiLink.c src/hg/lib/wikiLink.c index b6bbcadad42..bd393d75758 100644 --- src/hg/lib/wikiLink.c +++ src/hg/lib/wikiLink.c @@ -389,30 +389,36 @@ return cloneString(getLoginUserName()); } else if (wikiLinkEnabled()) { char *wikiUserName = findCookieData(wikiLinkUserNameCookie()); char *wikiLoggedIn = findCookieData(wikiLinkLoggedInCookie()); if (isNotEmpty(wikiLoggedIn) && isNotEmpty(wikiUserName)) return cloneString(wikiUserName); } else errAbort("wikiLinkUserName called when wiki is not enabled (specified " "in hg.conf)."); return NULL; } +char *getUserName() +{ +return (loginSystemEnabled() || wikiLinkEnabled()) ? wikiLinkUserName() : NULL; +} + + char *wikiLinkUserId() /* Return the user ID specified in cookies from the browser. Does not check if user is logged in. * To make sure that the ID is valid, call this only after you have checked with wikiLinkUserName() that the user is logged in. */ { return findCookieData(wikiLinkLoggedInCookie()); } char *wikiLinkEncodeReturnUrl(char *hgsid, char *cgiName, char* urlSuffix) /* Return a CGI-encoded URL with hgsid to a CGI. Free when done. */ { char retBuf[1024]; safef(retBuf, sizeof(retBuf), "%s%s?hgsid=%s%s", hLocalHostCgiBinUrl(), cgiName, hgsid, urlSuffix); return cgiEncode(retBuf); }