littel javascript doku + restructuring the view code from roomPlan