SELECT 
  ushop_payments.*, 
  ushop_payment_descriptions.*, 
  IF (
    ISNULL(ushop_addons.status), 
    "A", 
    ushop_addons.status
  ) AS processor_status, 
  ushop_payment_processors.type AS processor_type, 
  ushop_payment_processors.processor_script AS processor_script 
FROM 
  ushop_payments 
  LEFT JOIN ushop_payment_descriptions ON ushop_payment_descriptions.payment_id = ushop_payments.payment_id 
  AND ushop_payment_descriptions.lang_code = 'en' 
  LEFT JOIN ushop_payment_processors ON ushop_payment_processors.processor_id = ushop_payments.processor_id 
  LEFT JOIN ushop_addons ON ushop_payment_processors.addon = ushop_addons.addon 
  LEFT JOIN ushop_storefronts_payments AS storefronts_payments ON storefronts_payments.payment_id = ushop_payments.payment_id 
WHERE 
  ushop_payments.status = 'A' 
  AND (
    ushop_payments.usergroup_ids = '' 
    OR FIND_IN_SET(0, ushop_payments.usergroup_ids) 
    OR FIND_IN_SET(1, ushop_payments.usergroup_ids)
  ) 
  AND (
    storefronts_payments.storefront_id = 1 
    OR storefronts_payments.storefront_id IS NULL
  ) 
  AND ushop_payments.company_id IN ('0') 
HAVING 
  processor_status = 'A' 
ORDER BY 
  ushop_payments.position

Query time 0.00385

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "3.29"
    },
    "ordering_operation": {
      "using_filesort": true,
      "cost_info": {
        "sort_cost": "1.00"
      },
      "nested_loop": [
        {
          "table": {
            "table_name": "storefronts_payments",
            "access_type": "system",
            "rows_examined_per_scan": 0,
            "rows_produced_per_join": 1,
            "filtered": "0.00",
            "const_row_not_found": true,
            "cost_info": {
              "read_cost": "0.00",
              "eval_cost": "0.10",
              "prefix_cost": "0.00",
              "data_read_per_join": "16"
            },
            "used_columns": [
              "storefront_id",
              "payment_id"
            ]
          }
        },
        {
          "table": {
            "table_name": "ushop_payments",
            "access_type": "ALL",
            "possible_keys": [
              "c_status"
            ],
            "rows_examined_per_scan": 13,
            "rows_produced_per_join": 0,
            "filtered": "7.69",
            "cost_info": {
              "read_cost": "1.89",
              "eval_cost": "0.10",
              "prefix_cost": "1.99",
              "data_read_per_join": "2K"
            },
            "used_columns": [
              "payment_id",
              "company_id",
              "usergroup_ids",
              "position",
              "status",
              "template",
              "processor_id",
              "processor_params",
              "a_surcharge",
              "p_surcharge",
              "tax_ids",
              "localization",
              "payment_category"
            ],
            "attached_condition": "((`marketplace`.`ushop_payments`.`status` = 'A') and ((`marketplace`.`ushop_payments`.`usergroup_ids` = '') or (0 <> find_in_set(0,`marketplace`.`ushop_payments`.`usergroup_ids`)) or (0 <> find_in_set(1,`marketplace`.`ushop_payments`.`usergroup_ids`))) and (`marketplace`.`ushop_payments`.`company_id` = 0))"
          }
        },
        {
          "table": {
            "table_name": "ushop_payment_descriptions",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "payment_id",
              "lang_code"
            ],
            "key_length": "9",
            "ref": [
              "marketplace.ushop_payments.payment_id",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 0,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "0.00",
              "eval_cost": "0.10",
              "prefix_cost": "2.09",
              "data_read_per_join": "1K"
            },
            "used_columns": [
              "payment_id",
              "payment",
              "description",
              "instructions",
              "surcharge_title",
              "lang_code"
            ]
          }
        },
        {
          "table": {
            "table_name": "ushop_payment_processors",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "processor_id"
            ],
            "key_length": "3",
            "ref": [
              "marketplace.ushop_payments.processor_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 0,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "0.00",
              "eval_cost": "0.10",
              "prefix_cost": "2.19",
              "data_read_per_join": "3K"
            },
            "used_columns": [
              "processor_id",
              "processor_script",
              "type",
              "addon"
            ]
          }
        },
        {
          "table": {
            "table_name": "ushop_addons",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "addon"
            ],
            "key_length": "98",
            "ref": [
              "marketplace.ushop_payment_processors.addon"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 0,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "0.00",
              "eval_cost": "0.10",
              "prefix_cost": "2.29",
              "data_read_per_join": "1K"
            },
            "used_columns": [
              "addon",
              "status"
            ]
          }
        }
      ]
    }
  }
}

Result

payment_id company_id usergroup_ids position status template processor_id processor_params a_surcharge p_surcharge tax_ids localization payment_category payment description instructions surcharge_title lang_code processor_status processor_type processor_script
17 0 0 0 A addons/wk_dlocal_payment/views/orders/components/payments/dlocal.tpl 105 a:11:{s:17:"dlocal_public_key";s:32:"KWyoZdydwzBYMYjXWuHvFOmlKuHMTrwE";s:19:"dlocal_access_token";s:40:"FyCZLjvZbgOYWpqcYiPJ0m10uiaHTi0OJnRqfbF1";s:20:"success_order_status";s:1:"P";s:20:"pending_order_status";s:1:"O";s:19:"failed_order_status";s:1:"F";s:11:"installment";s:6:"enable";s:14:"dlocal_country";s:2:"UY";s:8:"currency";s:3:"uyu";s:15:"dlocal_back_url";s:55:"https://ushop.shopping/index.php?dispatch=checkout.cart";s:18:"dlocal_success_url";s:59:"https://ushop.shopping/index.php?dispatch=checkout.complete";s:4:"mode";s:7:"sandbox";} 0.000 0.000 tab1 Tarjeta de crédito <p style="font-size: 12px;"><strong style="font-size: 12px;">Podrás pagar con Visa, Mastercard y más.</strong></p> <p style="font-size: 11px; color: rgb(165,165,165);">Todos tus datos están seguros y encriptados.</p> en A P dlocal_go.php
13 0 0 1 A addons/wk_dlocal_payment/views/orders/components/payments/dlocal.tpl 105 a:11:{s:17:"dlocal_public_key";s:32:"KWyoZdydwzBYMYjXWuHvFOmlKuHMTrwE";s:19:"dlocal_access_token";s:40:"FyCZLjvZbgOYWpqcYiPJ0m10uiaHTi0OJnRqfbF1";s:20:"success_order_status";s:1:"P";s:20:"pending_order_status";s:1:"O";s:19:"failed_order_status";s:1:"F";s:11:"installment";s:6:"enable";s:14:"dlocal_country";s:2:"UY";s:8:"currency";s:3:"uyu";s:15:"dlocal_back_url";s:55:"https://ushop.shopping/index.php?dispatch=checkout.cart";s:18:"dlocal_success_url";s:59:"https://ushop.shopping/index.php?dispatch=checkout.complete";s:4:"mode";s:7:"sandbox";} 0.000 0.000 tab1 dLocal Go Payment Gateway (Inline) en A P dlocal_go.php
15 0 0 2 A addons/wk_dlocal_payment/views/orders/components/payments/dlocal.tpl 105 a:11:{s:17:"dlocal_public_key";s:32:"KWyoZdydwzBYMYjXWuHvFOmlKuHMTrwE";s:19:"dlocal_access_token";s:40:"FyCZLjvZbgOYWpqcYiPJ0m10uiaHTi0OJnRqfbF1";s:20:"success_order_status";s:1:"P";s:20:"pending_order_status";s:1:"O";s:19:"failed_order_status";s:1:"F";s:11:"installment";s:6:"enable";s:14:"dlocal_country";s:2:"UY";s:8:"currency";s:3:"uyu";s:15:"dlocal_back_url";s:55:"https://ushop.shopping/index.php?dispatch=checkout.cart";s:18:"dlocal_success_url";s:59:"https://ushop.shopping/index.php?dispatch=checkout.complete";s:4:"mode";s:7:"sandbox";} 0.000 0.000 tab1 Transferencia bancaria en A P dlocal_go.php
16 0 0 3 A views/orders/components/payments/empty.tpl 0 0.000 0.000 tab1 Red de confianza en A
12 0 0 4 A addons/wk_mercado_payment/views/orders/components/payments/mercado.tpl 104 a:5:{s:18:"mercado_public_key";s:41:"TEST-cb038eae-527e-4f8f-a143-692ba9398b28";s:20:"mercado_access_token";s:71:"TEST-8232051132582381-092510-3c63128a6941f0e69ddb2b0b1fd6a40d-541160506";s:20:"success_order_status";s:1:"P";s:20:"failure_order_status";s:1:"F";s:11:"installment";s:6:"enable";} 0.000 0.000 tab1 Mercado Payment Gateways(Inline) <p></p><p>Payment instructions:</p> en A P mercado_inline.php
6 0 0 8 A views/orders/components/payments/cod.tpl 0 0.000 0.000 tab3 C.O.D Cashiers Check or Cash Only Type instructions to pay by visiting your retail store in here. en A