Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions LDK/resources/web/LDK/Utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -365,16 +365,16 @@ LDK.Utils = new function(){
},

/**
* Returns the current URL, encoded, minus the origin, which is suitable to use as a srcURL param.
* Returns the current URL, encoded, minus the origin, which is suitable to use as a returnUrl param.
*/
getSrcURL: function(){
getReturnUrl: function(){
var re = new RegExp('^' + window.location.origin);
return encodeURIComponent(window.location.href.replace(re, ''));
},

/**
* Create immutable object. Usage:
* var sealedObj = new LABKEU.Utils.sealed(obj);
* var sealedObj = new LABKEY.Utils.sealed(obj);
*
* @param obj The object to seal
* @returns The sealed object
Expand Down
4 changes: 2 additions & 2 deletions LDK/resources/web/LDK/panel/NavPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ Ext4.define('LDK.panel.NavPanel', {
if (!item.assayRunTemplateUrl || LABKEY.Utils.isEmptyObj(item.assayRunTemplateUrl)){
cfg.items.push(this.getImportItemCfg(item, {
urlConfig: {
params: Ext4.apply({srcURL: LABKEY.ActionURL.buildURL('project', 'begin')}, item.importUrl.params),
params: Ext4.apply({returnUrl: LABKEY.ActionURL.buildURL('project', 'begin')}, item.importUrl.params),
action: item.importUrl.action,
controller: item.importUrl.controller
},
Expand Down Expand Up @@ -336,7 +336,7 @@ Ext4.define('LDK.panel.NavPanel', {
urlConfig: {
action: 'importData',
controller: 'query',
params: {schemaName: item.schemaName, queryName: item.queryName, srcURL: LABKEY.ActionURL.buildURL('project', 'begin')}
params: {schemaName: item.schemaName, queryName: item.queryName, returnUrl: LABKEY.ActionURL.buildURL('project', 'begin')}
}
})
]
Expand Down
4 changes: 2 additions & 2 deletions laboratory/resources/web/laboratory/panel/AssayImportPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ Ext4.define('Laboratory.panel.AssayImportPanel', {
text: 'Cancel',
itemId: 'cancelBtn',
scope: this,
href: LABKEY.ActionURL.getParameter('srcURL') || LABKEY.ActionURL.buildURL('project', 'begin'),
href: LABKEY.ActionURL.getParameter('returnUrl') || LABKEY.ActionURL.buildURL('project', 'begin'),
hrefTarget: '_self'
}]
}],
Expand Down Expand Up @@ -404,7 +404,7 @@ Ext4.define('Laboratory.panel.AssayImportPanel', {
Ext4.Msg.hide();
Ext4.Msg.alert('Success', 'Your upload was successful!', function(){
function doLoad(){
//NOTE: always return to the project root, ignoring srcURL
//NOTE: always return to the project root, ignoring returnUrl
window.location = LABKEY.ActionURL.buildURL('project', 'begin');
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ public boolean handlePost(EnsureAssayFieldsForm form, BindException errors) thro
url.addParameter("renameConflicts", true);
url.addParameter("providerName", form.getProviderName());
if (form.getReturnActionURL() != null)
url.addReturnURL(form.getReturnActionURL());
url.addReturnUrl(form.getReturnActionURL());
form.setReturnUrl(url.getLocalURIString());
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ public static List<String> ensureAssayFields(User user, String providerName, boo
url.addParameter("providerName", ap.getName());

ActionURL returnUrl = new ActionURL("laboratory", "synchronizeAssayFields.view", ContainerManager.getSharedContainer());
url.addReturnURL(returnUrl);
url.addReturnUrl(returnUrl);
msg += "This will not be changed automatically. If do you want to correct this, <a href=\"" + url + "\">CLICK HERE</a>.";
}
else
Expand Down