on 2018 Sep 05 2:09 PM
Hi all,
I have implemented signature functionality in my UI5 app.I have used default Fiori MAster-Detail template available in WEBIDE. I was able to achieve signature pad when i run the app locally. Here's my project structure.
When I run the app from Overview page, I am not able to get that signature functionality.
It throws me an error stating "Uncaught ReferenceError: SignaturePad is not defined".
In my controller page also it shows error.
I have referred various blogs and tried including the code 1."com/work/manager/WorkManager/model/signature_pad.min" in component.js and
2. jQuery.sap.includeScript("https://cdnjs.cloudflare.com/ajax/libs/signature_pad/1.5.3/signature_pad.min.js", "id_signpad", onload, onerror);
3. jQuery.sap.includeScript("com.work.manager.WorkManager.model.signature_pad.min");
But nothing worked for me.. I am not able to call external 'js' files in my application.
Can someone help me with this?
Request clarification before answering.
Is that a custom control or just a JS lib?
If it's a js lib you can include them inside your manifest.js as you would do with CSS file. Just look for the "resources" key and add to it:
"js": [ {"uri": "/your/lib/name.js" } ]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think that you should just need to include inside your manifest file and access them as you would do in a normal web browser. You don't need to require another time that file.
So, just add them to the manifest and use the global variable that reference to the library directly (don't require them in your code).
gt.ramya dont put "./" simple use folder name and file name e.g "model/map.js"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
30 | |
9 | |
8 | |
8 | |
7 | |
7 | |
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.