Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to modify Sample point field in Analysis Request view #240

Merged
merged 1 commit into from
Aug 30, 2017
Merged
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
12 changes: 11 additions & 1 deletion bika/lims/browser/js/bika.lims.analysisrequest.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,17 @@ function AnalysisRequestViewView() {
base_query["getClientUID"] = [data['ClientUID'], setup_uid];
$(spelement).attr("base_query", $.toJSON(base_query));
var options = $.parseJSON($(spelement).attr("combogrid_options"));
options.url = window.location.href.split("/ar")[0] + "/" + options.url;
// Getting the url like that will return the query
// part of it:
// http://localhost:8080/Plone/clients/client17-14/..
// ..OA17-0030-R01?check_edit=1
// In order to create a correct ajax call
// we only need until the pathname of that url:
// http://localhost:8080/Plone/clients/client17-14/..
// ..OA17-0030-R01
var simple_url = window.location.href.split("/ar")[0];
simple_url = simple_url.split('?')[0];
options.url = simple_url + "/" + options.url;
options.url = options.url + "?_authenticator=" + $("input[name='_authenticator']").val();
options.url = options.url + "&catalog_name=" + $(spelement).attr("catalog_name");
options.url = options.url + "&base_query=" + $.toJSON(base_query);
Expand Down