<?php

class ProxySettingsForm extends PhonalisaRecord
{
    public $httpProxy;
    public $httpProxyPort;
    public $httpProxyUser;
    public $httpProxyPassword;
    public $httpsProxy;
    public $httpsProxyPort;
    public $httpsProxyUser;
    public $httpsProxyPassword;

    public static function myAttributes()
    {
        return array(
            'httpProxy' => 'httpProxy',
            'httpProxyPort' => 'httpProxyPort',
            'httpProxyUser' => 'httpProxyUser',
            'httpProxyPassword' => 'httpProxyPassword',
            'httpsProxy' => 'httpsProxy',
            'httpsProxyPort' => 'httpsProxyPort',
            'httpsProxyUser' => 'httpsProxyUser',
            'httpsProxyPassword' => 'httpsProxyPassword',
        );
    }

    public static function model($className = __CLASS__)
    {
        return parent::model($className);
    }

    public function rules()
    {
        return array(
            array(
                'subnetMask,
                httpProxy,
                httpProxyPort,
                httpProxyUser,
                httpProxyPassword,
                httpsProxy,
                httpsProxyPort,
                httpsProxyUser,
                httpsProxyPassword',
                'safe'
            ),
        );
    }
    
    public function attributeLabels()
    {
        return array(
            'httpProxy' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTP_PROXY_IP_ADDRESS_SHORT'),
            'httpProxyPort' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTP_PROXY_PORT_SHORT'),
            'httpProxyUser' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTP_PROXY_USERNAME_SHORT'),
            'httpProxyPassword' =>__('SYSTEM_GLOBAL_CONFIG_KEY_HTTP_PROXY_PASSWORD_SHORT'),
            'httpsProxy' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTPS_PROXY_IP_ADDRESS_SHORT'),
            'httpsProxyPort' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTPS_PROXY_PORT_SHORT'),
            'httpsProxyUser' => __('SYSTEM_GLOBAL_CONFIG_KEY_HTTPS_PROXY_USERNAME_SHORT'),
            'httpsProxyPassword' =>__('SYSTEM_GLOBAL_CONFIG_KEY_HTTPS_PROXY_PASSWORD_SHORT'),
        );
    }
}
