인재탐색 추가. gencount, npc_id 관련 수정

This commit is contained in:
2018-10-21 21:53:34 +09:00
parent ff87555eba
commit 39db811361
16 changed files with 877 additions and 268 deletions
+4 -7
View File
@@ -309,16 +309,13 @@ class Util extends \utilphp\util
if (is_string($key)) {
return true;
}
$jmp = $key - $idx - 1;
if(!$idx + 1 == $key){
return false;
}
$idx = $key;
}
if ($jmp * 5 >= count($array)) {
//빈칸이 많으면 dictionary인걸로.
return true;
} else {
return false;
}
return true;
}
/**
+20
View File
@@ -33,4 +33,24 @@ class Validator extends \Valitron\Validator
}
/**
* Validate that a field is an integer array
*
* @param string $field
* @param mixed $value
* @return bool
*/
protected function validateIntegerArray($field, $value)
{
if(!is_array($value)){
return false;
}
foreach($value as $subItem){
if(!is_int($subItem)){
return false;
}
}
return true;
}
}