인사부 버그 수정
메인 페이지에서 재야 인사 에러 안나게 수정
This commit is contained in:
@@ -205,7 +205,10 @@ if($meLevel >= 5 && $nation['l11set'] == 0) {
|
|||||||
$query = "select name,city from general where nation='{$me['nation']}' and level='11'";
|
$query = "select name,city from general where nation='{$me['nation']}' and level='11'";
|
||||||
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
||||||
$general = MYDB_fetch_array($result);
|
$general = MYDB_fetch_array($result);
|
||||||
echo "{$general['name']} 【".CityConst::byID($general['city'])->name."】";
|
if($general){
|
||||||
|
echo "{$general['name']} 【".CityConst::byID($general['city'])->name."】";
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
echo "
|
echo "
|
||||||
</td>
|
</td>
|
||||||
@@ -257,7 +260,9 @@ for($i=10; $i >= $lv; $i--) {
|
|||||||
$query = "select name,city from general where nation='{$me['nation']}' and level={$i}";
|
$query = "select name,city from general where nation='{$me['nation']}' and level={$i}";
|
||||||
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
||||||
$general = MYDB_fetch_array($result);
|
$general = MYDB_fetch_array($result);
|
||||||
echo "{$general['name']} 【".CityConst::byID($general['city'])->name."】";
|
if($general){
|
||||||
|
echo "{$general['name']} 【".CityConst::byID($general['city'])->name."】";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
echo "</td></form>";
|
echo "</td></form>";
|
||||||
if($i % 2 == 1) { echo "</tr>"; }
|
if($i % 2 == 1) { echo "</tr>"; }
|
||||||
|
|||||||
@@ -101,10 +101,12 @@ function commandButton() {
|
|||||||
$db = DB::db();
|
$db = DB::db();
|
||||||
$me = $db->queryFirstRow("select no,nation,level,belong from general where owner=%i", $userID);
|
$me = $db->queryFirstRow("select no,nation,level,belong from general where owner=%i", $userID);
|
||||||
|
|
||||||
$nation = $db->queryFirstRow("select nation,level,color,secretlimit from nation where nation=%i",$me['nation']);
|
$nation = $db->queryFirstRow("select nation,level,color,secretlimit from nation where nation=%i",$me['nation'])??[
|
||||||
|
'nation'=>0,
|
||||||
if($nation['color'] == "") { $nation['color'] = "#000000"; }
|
'level'=>0,
|
||||||
|
'secretlimit'=>99,
|
||||||
|
'color'=>'#000000'
|
||||||
|
];
|
||||||
|
|
||||||
$bgColor = Util::array_get($nation['color'])?:'#000000';
|
$bgColor = Util::array_get($nation['color'])?:'#000000';
|
||||||
$fgColor = newColor($bgColor);
|
$fgColor = newColor($bgColor);
|
||||||
|
|||||||
Reference in New Issue
Block a user