Purpose
Rentiva extends standard WordPress tables with a Custom Post Type (CPT) architecture to manage complex business logic.
ποΈ Custom Post Types
The plugin stores data in two main groups: "Operational" (Vehicles/Bookings) and "System" (Payouts/Logs).
π° 1. Financial Post Typesβ
mhm_payout (Payout Requests)β
Manages vendor payment requests within the Model B workflow.
- Usage: Holds off-ledger workflow statuses (Pending, Approved, Processing).
- Security: Only users with
manage_optionsorrentiva_financial_managercapability can view these records. - Relationship: Each payout record maps to
mhm_rentiva_ledgerrows in the database via Transaction ID.
π¬ 2. Communication Post Typesβ
mhm_message (Messages)β
Manages messaging traffic between customers, vendors, and admins.
- Thread Management: Groups messages via the
_mhm_thread_idmeta key. - UUID Support: Thread IDs support both integer and UUID (string) formats.
- Visibility: Hidden from the standard admin menu; managed through a dedicated messaging interface.
πͺ΅ 3. System and Audit Post Typesβ
mhm_app_log (Application Logs)β
Stores system errors, critical API calls, and audit trails.
- Automatic Cleanup (Retention): The
LogRetention::purge()routine deletes records older than 30 days by default, running daily. - Categories: Logs at Error, Info, and Critical severity levels.
4. Operational Post Typesβ
The plugin works with the following CPTs:
vehicle: Rental vehicle portfolio.vehicle_booking: Booking records and calendar.vehicle_addon: Vehicle add-ons (child seat, GPS, insurance, etc.).
5. Vendor Marketplace Post Types (Pro)β
mhm_vendor_app (Vendor Applications)β
Manages vendor applications within the vendor marketplace.
- CPT Slug:
mhm_vendor_app(14 characters β compliant with WordPress's 20-character limit). NOTE: NOTmhm_vendor_application. - Usage: The vendor onboarding process (application, approval, rejection, suspension) runs through this CPT.
- Management: CRUD operations via
VendorApplicationManager; status transitions (approve/reject/suspend) viaVendorOnboardingController. - Security: IBAN data is encrypted with AES-256-CBC (
OPENSSL_RAW_DATAflag). If OpenSSL is unavailable, an empty string is returned β plain text is NEVER stored. - File:
src/Admin/Vendor/PostType/VendorApplication.php
Section Summaryβ
- CPTs are optimized with
no_found_rowsand limited meta queries to reduce database load. - Financial records (
mhm_payout) are never deleted directly from the database; they are archived via status change. - Logs (
mhm_app_log) are purged regularly for performance. - Vendor applications are stored in the
mhm_vendor_appCPT (14 characters, within WP 20-char limit).
Changelogβ
| Date | Version | Note |
|---|---|---|
| 23.04.2026 | 4.27.2 | English translation added. |
| 27.03.2026 | 4.23.0 | vehicle_addon and mhm_vendor_app CPTs and vendor marketplace details added. |
| 19.03.2026 | 4.21.2 | mhm_payout, mhm_message, and LogRetention details added. |