majordomo icon indicating copy to clipboard operation
majordomo copied to clipboard

Местоположение и названия комнат

Open kirush0280 opened this issue 4 years ago • 1 comments

При изменении названия комнаты, не производится замена linkedRooms в свойствах объекта которые привязаны к этой комнате.

kirush0280 avatar Mar 06 '20 09:03 kirush0280

Можно извлекать название "реально привязанной" комнаты не зависимо от свойства linkedRooms так: function getLocationById($location_id) { $res = sqlselectone("select * from locations where id=".$location_id); //Array ( [ID] => 4 [TITLE] => Livingroom [PRIORITY] => 0 ) $room = $res['TITLE']; return $room; }

$obj = getobject("название обьекта"); $location_id = $curobj->location_id; $linkedRoom = getLocationById($location_id);

SergMicar avatar Feb 09 '22 14:02 SergMicar