简体   繁体   中英

Enabling WL.JSONStore in Worklight project from Eclipse?

I have a project in eclipse and using IBM Worklight but on my js file where i have placed this code

WL.JSONStore.init(JSONStoreCollections).then(
            function(res) {
                WL.Logger.info('Response is :', res);
                WL.JSONStore.get(chekVodafoneData).findAll()

I am getting a red mark under WL.JSON and it show JSONStore is not enabled ? I have already refered How to enable WL.JSONStore in Worklight project? , but it didn't helped much ?

The reason you are getting the error that JSONStore is not enabled is because it is an "optional feature" and must be enabled in the application-descriptor.xml file. Open this file in Eclipse, and in the "Design" tab simply right click "Optional Features" and select JSONStore. This should remove any errors stating that JSONStore is not enabled.

For implementation details of a JSONStore, see: JSONStore Infocenter (6.1)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM