Skip to content

Commit

Permalink
EC-CUBE#2448 typo修正・ソース整形・ソースコメントの改善 for 2.13.3
Browse files Browse the repository at this point in the history
    Scrutinizer Auto-Fixes

    This patch was automatically generated as part of the following inspection:
    https://scrutinizer-ci.com/g/nobuhiko/EC-CUBE/inspections/d8722894-69a6-4b1b-898d-43618035c60d

    Enabled analysis tools:
     - PHP Analyzer
     - PHP PDepend
     - PHP Similarity Analyzer
     - PHP Change Tracking Analyzer
  • Loading branch information
kimoto committed Aug 27, 2014
1 parent b0f0708 commit ce496f8
Show file tree
Hide file tree
Showing 135 changed files with 601 additions and 197 deletions.
20 changes: 19 additions & 1 deletion data/class/SC_CartSession.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ public function __construct($cartKey = 'cart')
}

// 商品購入処理中のロック

/**
* @param string $key_tmp
* @param integer $productTypeId
*/
public function saveCurrentCart($key_tmp, $productTypeId)
{
$this->key_tmp = 'savecart_' . $key_tmp;
Expand All @@ -71,6 +76,10 @@ public function getCancelPurchase($productTypeId)
}

// 購入処理中に商品に変更がなかったかを判定

/**
* @param integer $productTypeId
*/
public function checkChangeCart($productTypeId)
{
$change = false;
Expand Down Expand Up @@ -110,6 +119,11 @@ public function getNextCartID($productTypeId)
}

// 値のセット

/**
* @param string $key
* @param string $productTypeId
*/
public function setProductValue($id, $key, $val, $productTypeId)
{
$max = $this->getMax($productTypeId);
Expand Down Expand Up @@ -200,6 +214,10 @@ public function getAllProductsTax($productTypeId, $pref_id = 0, $country_id = 0)
}

// 全商品の合計ポイント

/**
* @param integer $productTypeId
*/
public function getAllProductsPoint($productTypeId)
{
// ポイント合計
Expand Down Expand Up @@ -334,7 +352,7 @@ public function adjustSessionProductsClass(&$arrProductsClass)
/**
* getCartList用にcartSession情報をセットする
*
* @param integer $product_type_id 商品種別ID
* @param integer $productTypeId 商品種別ID
* @param integer $key
* @return void
*
Expand Down
5 changes: 4 additions & 1 deletion data/class/SC_CheckError.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ public function __construct($array = '')

}

/**
* @param string[] $arrFunc
*/
public function doFunc($value, $arrFunc)
{
foreach ($arrFunc as $key) {
Expand Down Expand Up @@ -370,7 +373,7 @@ public function GREATER_CHECK($value)
* 最大文字数制限の判定
*
* 入力が指定文字数以上ならエラーを返す
* @param array $value value[0] = 項目名
* @param integer[] $value value[0] = 項目名
* value[1] = 判定対象文字列
* value[2] = 最大文字数(半角も全角も1文字として数える)
* @return void
Expand Down
5 changes: 5 additions & 0 deletions data/class/SC_Cookie.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ public function __construct($day = COOKIE_EXPIRE)
}

// クッキー書き込み

/**
* @param string $key
*/
public function setCookie($key, $val)
{
setcookie($key, $val, $this->expire, ROOT_URLPATH, DOMAIN_NAME);
Expand All @@ -46,6 +50,7 @@ public function setCookie($key, $val)
* クッキー取得
*
* EC-CUBE をURLパスルート以外にインストールしている場合、上位ディレクトリの値も(劣後ではあるが)取得する点に留意。
* @param string $key
*/
public function getCookie($key)
{
Expand Down
13 changes: 12 additions & 1 deletion data/class/SC_Customer.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ class SC_Customer
/** 会員情報 */
public $customer_data;

/**
* @param string $email
*/
public function getCustomerDataFromEmailPass($pass, $email, $mobile = false)
{
// 小文字に変換
Expand Down Expand Up @@ -236,12 +239,20 @@ public function getValue($keyname)
}

// パラメーターのセット

/**
* @param string $keyname
*/
public function setValue($keyname, $val)
{
$_SESSION['customer'][$keyname] = $val;
}

// パラメーターがNULLかどうかの判定

/**
* @param string $keyname
*/
public function hasValue($keyname)
{
if (isset($_SESSION['customer'][$keyname])) {
Expand Down Expand Up @@ -315,7 +326,7 @@ public function updateOrderSummary($customer_id)
*
* @param string $login_email ログインメールアドレス
* @param string $login_pass ログインパスワード
* @return boolean ログインに成功した場合 true; 失敗した場合 false
* @return boolean|null ログインに成功した場合 true; 失敗した場合 false
*/
public function doLogin($login_email, $login_pass)
{
Expand Down
3 changes: 3 additions & 0 deletions data/class/SC_Date.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ public function getStartYear()
return $this->start_year;
}

/**
* @param string $endYear
*/
public function setEndYear($endYear)
{
$this->end_year = $endYear;
Expand Down
3 changes: 3 additions & 0 deletions data/class/SC_Display.php
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,9 @@ public function assign($val1,$val2)
$this->view->assign($val1, $val2);
}

/**
* @param LC_Page $obj
*/
public function assignobj($obj)
{
$this->view->assignobj($obj);
Expand Down
1 change: 1 addition & 0 deletions data/class/SC_FormParam.php
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,7 @@ public function getFormDispArray()
* パラメーターの削除
*
* addParamの逆の関数
* @param string $keyname
*/
public function removeParam($keyname)
{
Expand Down
6 changes: 5 additions & 1 deletion data/class/SC_Fpdf.php
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,6 @@ private function setOrderData()
/**
* 備考の出力を行う
*
* @param string $str 入力文字列
* @return string 変更後の文字列
*/
private function setEtcData()
Expand Down Expand Up @@ -296,6 +295,11 @@ public function createPdf()
}

// PDF_Japanese::Text へのパーサー

/**
* @param integer $x
* @param integer $y
*/
private function lfText($x, $y, $text, $size = 0, $style = '')
{
// 退避
Expand Down
2 changes: 1 addition & 1 deletion data/class/SC_Initial.php
Original file line number Diff line number Diff line change
Expand Up @@ -481,7 +481,7 @@ public function resetSuperglobalsRequest()
* 指定された名前の定数が存在しない場合、指定された値で定義
*
* @param string $name 定数の名前。
* @param mixed $value 定数の値。
* @param string $value 定数の値。
* @return void
*/
public function defineIfNotDefined($name, $value = null)
Expand Down
4 changes: 4 additions & 0 deletions data/class/SC_PageNavi.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ class SC_PageNavi
public $arrPagenavi = array(); // ページ

// コンストラクタ

/**
* @param string $func_name
*/
public function __construct($now_page, $all_row, $page_row, $func_name, $navi_max = NAVI_PMAX, $urlParam = '', $display_number = true)
{
$this->arrPagenavi['mode'] = 'search';
Expand Down
7 changes: 5 additions & 2 deletions data/class/SC_Product.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public function findProductIdsOrder(&$objQuery, $arrVal = array())
*
* @param SC_Query $objQuery SC_Query インスタンス
* @param array $arrVal 検索パラメーターの配列
* @return array 対象商品ID数
* @return integer 対象商品ID数
*/
public function findProductCount(&$objQuery, $arrVal = array())
{
Expand Down Expand Up @@ -606,7 +606,7 @@ public static function setIncTaxToProducts(&$arrProducts)
/**
* 商品情報の配列に税込金額を設定する
*
* @param array $arrProducts 商品情報の配列
* @param array $arrProduct 商品情報の配列
* @return void
*/
public static function setIncTaxToProduct(&$arrProduct)
Expand Down Expand Up @@ -681,6 +681,9 @@ public function prdclsSQL($where = '')
return $sql;
}

/**
* @param string $tablename
*/
public function getProductDispConditions($tablename = null)
{
$tablename = ($tablename) ? $tablename . '.' : null;
Expand Down
4 changes: 4 additions & 0 deletions data/class/SC_Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ public function sendHeader()
}
}

/**
* @param string $contentType
*/
public function setContentType($contentType)
{
$this->header['Content-Type'] = $contentType;
Expand Down Expand Up @@ -338,6 +341,7 @@ public function sendHttpStatus($statusCode)
/**
* ダウンロード用の HTTP ヘッダを出力する
*
* @param string $file_name
* @return void
*/
public static function headerForDownload($file_name) {
Expand Down
19 changes: 19 additions & 0 deletions data/class/SC_SelectSql.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ public function addSearchStr($val)
}

//-- 範囲検索(○ ~ ○ まで)

/**
* @param string $column
*/
public function selectRange($from, $to, $column)
{
// ある単位のみ検索($from = $to)
Expand All @@ -86,6 +90,10 @@ public function selectRange($from, $to, $column)
}

//-- 期間検索(○年○月○日か~○年○月○日まで)

/**
* @param string $column
*/
public function selectTermRange($from_year, $from_month, $from_day, $to_year, $to_month, $to_day, $column)
{
$return = array();
Expand Down Expand Up @@ -126,6 +134,10 @@ public function selectTermRange($from_year, $from_month, $from_day, $to_year, $t
}

// checkboxなどで同一カラム内で単一、もしくは複数選択肢が有る場合 例: AND ( sex = xxx OR sex = xxx OR sex = xxx) AND ...

/**
* @param string $ItemStr
*/
public function setItemTerm($arr, $ItemStr)
{
$return = array();
Expand All @@ -152,6 +164,10 @@ public function setItemTerm($arr, $ItemStr)
}

// NULL値が必要な場合

/**
* @param string $ItemStr
*/
public function setItemTermWithNull($arr, $ItemStr)
{
$return = array();
Expand Down Expand Up @@ -247,6 +263,9 @@ public function setWhere($where)
}
}

/**
* @param string $order
*/
public function setOrder($order)
{
$this->order = 'ORDER BY ' . $order;
Expand Down
24 changes: 22 additions & 2 deletions data/class/SC_SendMail.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ public function __construct()
}

// 送信先の設定

/**
* @param string $key
*/
public function setRecip($key, $recipient)
{
$this->arrRecip[$key] = $recipient;
Expand All @@ -83,6 +87,10 @@ public function setFrom($from, $from_name = '')
}

// CCの設定

/**
* @param string $cc
*/
public function setCc($cc, $cc_name = '')
{
if ($cc != '') {
Expand All @@ -92,6 +100,10 @@ public function setCc($cc, $cc_name = '')
}

// BCCの設定

/**
* @param string $bcc
*/
public function setBCc($bcc)
{
if ($bcc != '') {
Expand All @@ -101,6 +113,10 @@ public function setBCc($bcc)
}

// Reply-Toの設定

/**
* @param string $reply_to
*/
public function setReplyTo($reply_to)
{
if ($reply_to != '') {
Expand Down Expand Up @@ -164,6 +180,10 @@ public function setPort($port)
}

// 名前<メールアドレス>の形式を生成

/**
* @param string $name
*/
public function getNameAddress($name, $mail_address)
{
if ($name != '') {
Expand Down Expand Up @@ -295,7 +315,7 @@ public function getRecip()
*
* 設定された情報を利用して, メールを送信する.
*
* @return void
* @return boolean
*/
public function sendMail($isHtml = false)
{
Expand All @@ -319,7 +339,7 @@ public function sendMail($isHtml = false)
/**
* HTMLメール送信を実行する.
*
* @return void
* @return boolean
*/
public function sendHtmlMail()
{
Expand Down
8 changes: 8 additions & 0 deletions data/class/SC_Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,20 @@ public function IsSuccess()
}

/* セッションの書き込み */

/**
* @param string $key
*/
public function SetSession($key, $val)
{
$_SESSION[$key] = $val;
}

/* セッションの読み込み */

/**
* @param string $key
*/
public function GetSession($key)
{
return $_SESSION[$key];
Expand Down
Loading

0 comments on commit ce496f8

Please sign in to comment.