# Gravity Forms Redsys Integration

- [x] Project Setup
- [x] Core Implementation
- [x] Advanced Features (Synced from T: Drive)
- [x] Refactor to PayPal-style Popup Flow
- [x] Fix Dynamic Logic & Feed Detection
- [x] Fix AJAX & Order ID
- [x] Refine User Experience
- [x] Integrate with Gravity Forms "Sales" Dashboard
    - [x] Ensure `transaction_type` is set to '1' (Sale)
    - [x] Ensure `payment_amount`, `payment_date`, `transaction_id` are populated
    - [x] Use `add_payment_transaction` (via `complete_payment`) to register stats
    - [x] Link transaction to the active Redsys Feed ID
    - [ ] Update Entry with Payment Details in IPN <!-- id: 493 -->
- [x] Quick Pay Shortcode Enhancements
    - [x] Add `lang` attribute (es/en) for multilingual label support
- [x] Add Admin Dashboard & Documentation Menu
    - [x] Create top-level "Redsys" menu
    - [x] Add "Gravity Forms" info page (General usage + Settings link)
    - [x] Add "Quick Pay" info page (Shortcode Generator)
- [x] Configurable OK/KO URLs
    - [x] Add URL OK/KO fields to Gravity Forms Feed Settings
    - [x] Create Settings DB option for Quick Pay Defaults
    - [x] Add Settings Form to "Redsys > Quick Pay" Admin Page
    - [x] Update Quick Pay logic to use saved URLs
    - [x] Add "Redsys Parameters" documentation helper
- [x] Refine Plugin UI & Feed Settings
    - [x] Change Plugin Icon to 'credit-card' (Gravity Forms: gform-icon--credit-card via get_menu_icon, Admin Menu: dashicons-money-alt)
    - [x] Fix "No mapping fields available" in Feed Settings
    - [x] Move/Add Billing Fields (Name, Surname, ID) to correct section
    - [x] Ensure proper field type mapping support
- [x] Extended Billing Information (Address, City, Zip, Country)
    - [x] Add fields to `billing_info_fields` in `class-gf-redsys.php`
- [x] Fix Sales Stats & Feed Triggering
    - [x] Override `complete_payment` to include `trigger_payment_delayed_feeds`
    - [x] Refactor `save_redsys_meta` to use `complete_payment` instead of manual update
    - [x] Explicitly set `transaction_type` and `payment_status` in `complete_payment`
    - [x] Use `parent::entry_post_save` to generate Order Meta (Standard GF Flow)
- [ ] Verification
