module load error handler, router optimizaton, relative paths, fixed add existing module control panel issue

This commit is contained in:
Shaun Walker
2020-03-04 13:22:58 -05:00
parent 061043bd15
commit 4c2007439d
10 changed files with 242 additions and 199 deletions

View File

@ -104,13 +104,9 @@ namespace Oqtane.Modules
public string ContentUrl(int fileid)
{
string apiurl = PageState.Uri.Scheme + "://" + PageState.Alias.Name + "/";
if (PageState.Alias.Path == "")
{
apiurl += "~/";
}
apiurl += "api/File/Download/" + fileid.ToString();
return apiurl;
string url = (PageState.Alias.Path == "") ? "/~" : PageState.Alias.Path;
url += Constants.ContentUrl + fileid.ToString();
return url;
}
// user feedback methods