← Back to team overview

dhis2-devs team mailing list archive

Re: ouwt Tree

 

Hi again,
Sorry for the rapid succession of mails but I wanted to report a bug with the multiple selection on the tree where
the orgUnits are not removed correctly when multiple selection is set to true, around line 530:
"dhis2.array.remove(selected, idx, idx);" is not working and could be replaced by "selected.splice(idx, 1);"
I attached a file with the changes on ouwt.js in case you are interested
Cheers!
EricFrom: ericmourin@xxxxxxxxxxx
To: dhis2-devs@xxxxxxxxxxxxxxxxxxx
Subject: ouwt Tree
Date: Fri, 3 Jun 2016 04:53:34 +0200




Hi devs,
I've been working to have the orgUnit tree working on a custom app, but I've seen that on the first line of code that the dhis2 base URL is defined as:
var dhis2BaseUrl = "..";
Could this be changed to var dhis2BaseUrl = dhis2.settings.baseUrl; ? 
Right now I have to change the code of the ouwt.js file if I want the images to load correctly and with every dhis2 update it would need maintenance to keep it working correctly,  using that variable I believe that everything should work correctly and it would be available to any user using the code snippet provided in the documentation:
	<script>		window.dhis2 = window.dhis2 || {};		dhis2.settings = dhis2.settings || {};		dhis2.settings.baseUrl = '';	</script>
Something similar happens with the "treeview-gray-line.gif", but I couldn't find where this image is requested as it seems to  use another baseUrl.
I'm looking forward to hearing from you 
Have a nice day 
Eric  		 	   		   		 	   		  

Attachment: ouwt.zip
Description: Zip archive


Follow ups

References