Deploy to Platform

Since we have now added a new expense record using our application we are able to see this record, and the new value on the platform too. We can see this by looking at the MC Object 001 tab. This is our Projects list. By selecting the relevant project (the one we added our expense to) we can see the associated Expense records (these are in MC Object 002).

NOTE: These “MC Object 00X” names are only relevant for our seed applications. Your objects can have much better names.

Here we can see the related expense records when viewing our project;

Screenshot of the expense records relating to our project

And here is the expense record… and note our new field has made it through.

Screenshot of our new expense record, as seen in SFDC

 

Updating the Platform Resources

Our Seed and Shell apps have the functionality to create/update the required platform objects and resources built into them. The assets are created via the configuration in the ~/package.json file. In our initial case we shouldn’t need to change anything here, but here’s a quick overview of the parts of concern;

  • “sf_app_name” & “version : These are used in the naming of the application bundle, Startpage and related Cache Manifest Visualforce pages. The “version” should be used in versioning your application.

Seeing as we want to push a new version to the platform we should change the version entry to “0.1.0”. Do this now.

When you’re happy with the state of your application in Codeflow you can go to the Admin Functions section of the Settings tab and you should see a Deploy to Salesforce option. Clicking this will take your application bundle and upload it to the platform. It will also put together a Cache Manifest page and a Startpage (if needed, this usually won’t change very much).

Animated screenshot showing a deploy to Salesforce from the MobileCaddy app

Notes about caching

  1. If running in the Platform Emulator you will need to clear the browser cache.
  2. If running on the device you will need to re-install the APK.

NOTE: to remove the need to clear cache on the browser or reinstall the APK then the cache can be turned off by removing the relevant entry from the Cache Manifest page. This will DISABLE offline functionality though so should be un-comments/re-added if you want to try out the offline capabilities.