ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 8714


Ignore:
Timestamp:
Oct 19, 2008, 11:53:01 AM (11 years ago)
Author:
ebihara
Message:

#2888:sfOpenPNESecurityUser is now accepting the request parameter is authMode

Location:
OpenPNE3/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE3/trunk/data/sns_config.yml

    r8705 r8714  
    1717  type:         "select"
    1818  choices_type: "AuthMode"
    19   default:      "PCAddress"
     19  default:      ["PCAddress"]
    2020  option:
    2121    required: true
     
    2525  type:         "select"
    2626  choices_type: "AuthMode"
    27   default:      "MobileAddress"
     27  default:      ["MobileAddress"]
    2828  option:
    2929    required: true
  • OpenPNE3/trunk/lib/user/sfOpenPNESecurityUser.class.php

    r8569 r8714  
    2222    parent::initialize($dispatcher, $storage, $options);
    2323
    24     $authMode = OpenPNEConfig::get(sfConfig::get('sf_app') . '_auth_mode');
     24    $request = sfContext::getInstance()->getRequest();
     25    $authModes = OpenPNEConfig::get(sfConfig::get('sf_app') . '_auth_mode');
     26
     27    $authMode = $_REQUEST['authMode'];
     28    if (!in_array($authMode, $authModes)) {
     29      $authMode = array_shift($authModes);
     30    }
     31
    2532    $containerClass = 'sfOpenPNEAuthContainer_' . $authMode;
    2633    $this->authContainer = new $containerClass();
Note: See TracChangeset for help on using the changeset viewer.