|
|
@@ -147,8 +147,6 @@ class Period extends \common\components\ActiveRecord
|
|
|
$this->periodArr = $this->nowPeriodArr;
|
|
|
$periodNum = $this->nowPeriodArr['PERIOD_NUM'];
|
|
|
} else {
|
|
|
- LoggerTool::debug(['calc-11', $periodNum, $this->periodNum]);
|
|
|
-
|
|
|
if($periodNum !== $this->periodNum){
|
|
|
$this->periodArr = static::findOneAsArray(['PERIOD_NUM'=>$periodNum]);
|
|
|
}
|
|
|
@@ -186,8 +184,8 @@ class Period extends \common\components\ActiveRecord
|
|
|
}
|
|
|
|
|
|
public function getTeamsPeriodNum(){
|
|
|
- $teamsPeriodNum = static::find()->where('IS_CLOSED=1 AND IS_SENT=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
|
|
|
- $this->setPeriodNum($teamsPeriodNum['PERIOD_NUM']);
|
|
|
+ $this->periodArr = static::find()->where('IS_CLOSED=1 AND IS_SENT=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
|
|
|
+ $this->setPeriodNum($this->periodArr['PERIOD_NUM']);
|
|
|
if($this->nowPeriodArr){
|
|
|
return $this->nowPeriodArr['PERIOD_NUM'];
|
|
|
} else {
|