I had an interesting issue with Shared Actions in Notes Views today.
I had built a new application (or more accurately a group of features) for a customer, but due to the customer's requirements I had to retro-fit my new code into and existing .NSF. The existing code was to be retained, with a front page for the user's to choose the new features or the existing features (not my choice in implementation, but beyond my control).
The existing application had over 300 views. It was not part of my brief to do anything about this. A template was delivered to the customer with the combinded code. After testing and implementation the customer discovered that a small sub-set of the old views had the wrong action buttons.
The customer sent me back a copy of the database, taken from the production database. What appeared to have happened was this:
Before the new template was applied:
Shared Actions (as they appeared in the Actions list)
- Action A
- Action B
- Action C
View Actions
- Action A (shared action)
- Action B (shared action)
- Action D (standard action)
- Action E (standard action(
After the changes were applied (the database was set to inherit from the new template, and 'Refresh Design' was used to update the database)
Shared Actions (as they appear in the list
- Action 1
- Action 2
- Action 3
- Action A
- Action B
- Action C
View Actions
- Action 1 (shared action)
- Action 2 (shared action)
- Action D (standard action)
- Action E (standard action(
So what seems to have happened is that the view points to the action's offset in the shared actions list, not the action name or some unique identifier.
A further complication was that fixing the views in the template then refreshing the design did NOT fix the production database.
The only solution was to fix the views in the template, then delete the views from the production database then copy and paste them back in directly from the template.
I am not at all comfortable about a solution that involves directly modifying the production database. I also have no idea why this only affected a small group of views, other than these were the only ones that used the shared action that was previously the first action in the list.
No comments:
Post a Comment