Plugin Directory

Changeset 3311721


Ignore:
Timestamp:
06/14/2025 11:10:31 PM (10 months ago)
Author:
sjvision
Message:

Forgot Custom API LLM configuration structure

Location:
ai-tool-center
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • ai-tool-center/tags/1.2.0/admin/class-aitoce-admin-model-page.php

    r3311710 r3311721  
    132132            'Check this if you want to use a Custom API Model.'
    133133        );
     134       
     135        $this->options->aitoce_add_select_field(
     136            'custom_llm_config',
     137            __('LLM API Structure', 'ai-tool-center'),
     138            [
     139                'messages' => 'Open WebUI',
     140                'input' => 'OpenAI',
     141            ],
     142            esc_attr(AITOCE_OPTION_NAME_MODEL_CUSTOM),
     143            esc_attr(AITOCE_OPTION_SLUG_MODEL_CUSTOM),
     144            esc_attr(AITOCE_OPTION_SECTION_MODEL_CUSTOM),
     145        );
    134146
    135147        // Text field for the custom LLM base URL
     
    184196        return [
    185197            'custom_llm' => isset($input['custom_llm']) ? 1 : 0,
     198            'custom_llm_config' => sanitize_text_field($input['custom_llm_config'] ?? ''),
    186199            'custom_api_url' => sanitize_text_field($input['custom_api_url'] ?? ''),
    187200            'custom_api_key' => sanitize_text_field($input['custom_api_key'] ?? ''),
  • ai-tool-center/tags/1.2.0/public/js/aitoce-public-nimbot-draggable.js

    r3311710 r3311721  
    11jQuery(document).ready(function($) {
    2     //$( "#aitoce-popup-container" ).draggable();
     2    $( "#aitoce-popup-container" ).draggable({ handle: "#aitoce-chat-header" });
    33});
  • ai-tool-center/trunk/admin/class-aitoce-admin-model-page.php

    r3311192 r3311721  
    132132            'Check this if you want to use a Custom API Model.'
    133133        );
     134       
     135        $this->options->aitoce_add_select_field(
     136            'custom_llm_config',
     137            __('LLM API Structure', 'ai-tool-center'),
     138            [
     139                'messages' => 'Open WebUI',
     140                'input' => 'OpenAI',
     141            ],
     142            esc_attr(AITOCE_OPTION_NAME_MODEL_CUSTOM),
     143            esc_attr(AITOCE_OPTION_SLUG_MODEL_CUSTOM),
     144            esc_attr(AITOCE_OPTION_SECTION_MODEL_CUSTOM),
     145        );
    134146
    135147        // Text field for the custom LLM base URL
     
    184196        return [
    185197            'custom_llm' => isset($input['custom_llm']) ? 1 : 0,
     198            'custom_llm_config' => sanitize_text_field($input['custom_llm_config'] ?? ''),
    186199            'custom_api_url' => sanitize_text_field($input['custom_api_url'] ?? ''),
    187200            'custom_api_key' => sanitize_text_field($input['custom_api_key'] ?? ''),
  • ai-tool-center/trunk/public/js/aitoce-public-nimbot-draggable.js

    r3311710 r3311721  
    11jQuery(document).ready(function($) {
    2     //$( "#aitoce-popup-container" ).draggable();
     2    $( "#aitoce-popup-container" ).draggable({ handle: "#aitoce-chat-header" });
    33});
Note: See TracChangeset for help on using the changeset viewer.