ArrHelps.php 448 B

12345678910111213141516171819202122
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: PFG2018
  5. * Date: 2018/12/5
  6. * Time: 9:22
  7. */
  8. namespace common\service;
  9. use yii\helpers\ArrayHelper;
  10. class ArrHelps extends ArrayHelper
  11. {
  12. public static function NotEmptyKeyException($key,$array)
  13. {
  14. if( ArrayHelper::keyExists($key,$array) && !empty($array[$key]))
  15. {
  16. return true;
  17. }
  18. return false;
  19. }
  20. }