on 05-04-2016 9:07 AM
Hi,
our goal is, to have a dashboard, that can be called with different URL Parameters for selection and navigation state.
All the startup scripting is doing fine.
We also want to provide a functionality within the dashboard to create the correct URL (with parameters) for the current selection of the user.
For several reasons the bookmark functionality in DS 1.5 is not working sufficient for us.
Is there a way to retrieve the current server for creating the URL, like
https://<server>/BOE/OpenDocument/opendoc/openDocument.jsp?sIDType=CUID&iDocID
Furthermore I would need the UID of the dashboard.
APPLICATION.getInfo() only deliveres the name, but not the UID.
Each example I found (e.g. http://scn.sap.com/thread/3813702) is working with fixed URL strings.
Background for this requirement:
We have a 2 system landscape. Changing the URL string after promoting to productive system is not an option.
From time to time we use a copy of the dashboard for testing and further development.
Working with the UID of the current dashboard (version) would be great. This way we would not 'forget' to change the UID within the URL string.
SDK components are not welcome at the moment. There are some restrictions within the company...
Any hints, ideas and comments are welcome.
If more explanations are needed, just ask.
Regards
Steve
Hello Steve,
maybe this short piece of code can help you:
var S_LV_BOOKMARK = Bookmark.saveBookmark("URL");
S_GV_011__LOCALSERVER = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).substring(7,19);
S_GV_012__DOCID = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).substring(100,123);
Bookmark.deleteBookmark(S_LV_BOOKMARK);
Regards,
Balint
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi again,
I did some small changes to your coding:
// create bookmark
var S_LV_BOOKMARK = Bookmark.saveBookmark("URL");
// 'BOE' should be after the server part of the URL
var lv_BOE = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).indexOf("/BOE/");
var lv_SERVER = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).substring(0,lv_BOE);
// after 'DocID' the CUID starts
var lv_iDOC = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).indexOf("DocID");
// this is after the CUID for bookmarks
var lv_iBOOK = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).indexOf("&BOOKMARK");
var lv_DOCID = Bookmark.getBookmarkUrl(S_LV_BOOKMARK).substring(lv_iDOC+6,lv_iBOOK);
// delete the bookmark again
Bookmark.deleteBookmark(S_LV_BOOKMARK);
This is working perfectly for me.
Thank you very much!
Regards
Steve
Hi Steve,
When opening an application from another you can just use the following syntax.
APPLICATION.openNewWindow("/BOE/OpenDocument/opendoc/openDocument.jsp?sIDType=CUID&iDocID=<CUID_of_the_application_to_be_opened>);
The server name should be added automatically and so, when you promote to the Production system, it should then take the production system server name.
Also, the CUID should remain the same when you promote any application from one system to another. That way, even if you had hard coded the CUID in the URL it will still open the correct application on the same system as long as the target application is available.
We have used the above two methods in many applications and everything works without any issue. If the above two aren't working then you should probably get in touch with your BOE admin to check for changes in settings on the servers.
About passing the parameters from one application to another, you can do that too. Please take a look at this tutorial.
Regards,
Swapnil Koti
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Steve,
A solution to this, as there isn't one currently with SAP delivered functions is to create a table somewhere which will hold the values of the server name and uid or the whole link to the dashboard. And this will be read via a new DataSource. So when development needs to be done, you just update the table. You can be smart about it hold the two full links and filter the returned values on the name of the iDOC which is unique per dashboard.
Regards,
Bogdan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.