A new constructor that will be used to create a participationManager object as soon as the user lands on the participate page.
This will be populated by list generated from {T224467}
This will include:
**Properties**
- images - complete list of all images in session
- currentImage - index of current loaded image
- existingData - will be used to compare on form submission to find actual changes. Use "depicts" and "captions" properties to store each
- countrySubcategory - updated on page load from ?country url parameter
**methods** and functions** - All Bold are public methods
- - **Next image()**
- - **Previous image()**
- getImageFileName() - uses current index to return the filename of the image- **imageChanged()**
- populateImageData() --- updates image src, gets all data and renders on the page.Image
- get-- updateUnstructuredData()
- get-- updateStructuredData()
- getDepictsEdits(existingData,ImageFileName() - uses currentData)
- getCaptionsEdits(existingData, currentData) index to return the filename of the image
- generateContributionData(type, action, content) - to be used for populating hidden fields for storing contributions (for both depicts and captions)
- send-- getDepictsEdits(editxistingData) - make API calls to write changes to commons., currentData)
-- getCaptionsEdits(existingData, currentData)
- sendCaption- writeDepictsEdits(editData) - make API calls to write changes to commons.
- mak- writeCaptionsEditEdits(editData) - make API calls to write changes to commons.
Note: When the either contributions forms are submitted, we need to use generateContributionData function to {T224505}