This guide provides everything needed to implement the frontend for the leverancier-gemeente gebruik workflow in the SoftwareCatalog Nextcloud app.
✅ Complete API Implementation
- Custom endpoints for cross-organisation access
- Security validation (afnemer-based permissions)
- Comprehensive error handling
- Full CRUD operations for suggestions
✅ Tested Functionality
- Leveranciers can create suggestions for gemeenten
- Gemeenten can view suggestions assigned to them
- Claim workflow (transfer ownership)
- Deny workflow (delete suggestion)
- Security prevents unauthorized access
- Suggestions Dashboard - Main view showing all suggestions
- Suggestion Card - Individual suggestion display with actions
- Confirmation Dialogs - For claim/deny actions
- Loading States - For all async operations
- Error Handling - User-friendly error messages
- Add "Suggestions" section to Software Catalog menu
- Route:
/suggestions - Icon:
mdi-format-list-bulleted
GET /index.php/apps/softwarecatalog/api/aangeboden-gebruik/afnemerReturns all suggestions where current organisation is the afnemer.
PUT /index.php/apps/softwarecatalog/api/aangeboden-gebruik/{id}/set-selfClaims a suggestion (transfers ownership to current organisation).
DELETE /index.php/apps/softwarecatalog/api/aangeboden-gebruik/{id}/deny Denies a suggestion (deletes it completely).
{
id: "uuid-string",
afnemer: "gemeente-uuid",
product: "product-uuid",
status: "voorgesteld",
beschrijving: "Description text",
"@self": {
id: "uuid-string",
organisation: "leverancier-uuid", // Changes to gemeente after claim
register: "1",
schema: "8"
}
}- Use Nextcloud Vue components for consistency
- Follow Nextcloud design guidelines
- Use MDI icons from pictogrammers.com
- Green "Accept" button with
mdi-check-circleicon - Red "Reject" button with
mdi-close-circleicon - Loading spinners during actions
- Success/error notifications
- Confirmation dialogs for destructive actions
- Loading: Show spinners while fetching/updating
- Empty: Message when no suggestions available
- Error: User-friendly error messages
- Success: Confirmation after successful actions
- 200: Success
- 403: Not authorized (not the afnemer)
- 404: Suggestion not found
- 500: Server error
- 403: "You are not authorized to perform this action"
- 404: "This suggestion is no longer available"
- 500: "An error occurred. Please try again later"
- Create suggestions route and view
- Implement API service methods
- Create basic suggestions list component
- Add navigation menu item
- Implement suggestion cards with data display
- Add claim/deny buttons with loading states
- Implement confirmation dialogs
- Add error handling and notifications
- Add empty states and loading indicators
- Implement auto-refresh after actions
- Add comprehensive error handling
- Test all user scenarios
src/
├── views/
│ └── SuggestionsView.vue # Main suggestions page
├── components/
│ ├── SuggestionCard.vue # Individual suggestion display
│ ├── SuggestionActions.vue # Claim/deny buttons
│ └── ConfirmationDialog.vue # Reusable confirmation dialog
├── services/
│ └── suggestionsApi.js # API service methods
└── store/
└── suggestions.js # Vuex store for suggestions
- As a gemeente, I want to see suggestions assigned to me
- As a gemeente, I want to accept a suggestion and take ownership
- As a gemeente, I want to reject a suggestion I don't need
- As a gemeente, I want clear feedback when actions succeed/fail
- As a gemeente, I want to be prevented from unauthorized actions
const mockSuggestions = [
{
id: 'test-uuid-1',
afnemer: 'current-gemeente-uuid',
product: 'product-uuid-1',
status: 'voorgesteld',
beschrijving: 'Document Management System suggestion from Leverancier BV',
'@self': {
id: 'test-uuid-1',
organisation: 'leverancier-uuid',
register: '1',
schema: '8'
}
}
];/website/docs/leverancier-gemeente-workflow.md- Complete workflow documentation/website/docs/aangeboden-gebruik-api.md- Full API documentation
- Nextcloud Vue Components: https://nextcloud-vue-components.netlify.app/
- Design Guidelines: https://docs.nextcloud.com/server/latest/developer_manual/design/
- MDI Icons: https://pictogrammers.com/library/mdi/
- Read the complete workflow documentation in
/website/docs/leverancier-gemeente-workflow.md - Test the API endpoints using the provided curl examples
- Set up the basic component structure following Nextcloud patterns
- Implement incrementally starting with the suggestions list
- Test thoroughly with different user scenarios
The frontend is complete when:
- Gemeenten can view all suggestions assigned to them
- Gemeenten can claim suggestions with confirmation
- Gemeenten can deny suggestions with confirmation
- All loading states and error handling work correctly
- UI follows Nextcloud design guidelines
- Component is integrated into main navigation
- All user scenarios are tested and working
Backend Status: ✅ COMPLETE - All APIs tested and working Frontend Status: 🔄 READY FOR DEVELOPMENT - All requirements documented
The backend implementation is fully complete and tested. The frontend developer has everything needed to build a complete, secure, and user-friendly interface for the leverancier-gemeente workflow!