def METHOD_NAME(self):
    for room in self:
        tasks = self.env["pms.housekeeping.task"].search(
            [("clean_type", "=", room.clean_status)]
        )
        for task in tasks:
            new_task = self.env["pms.housekeeping"]
            employee = (
                task.def_employee_id.id
                if len(task.def_employee_id) > 0
                else room.clean_employee_id.id
            )
            new_task.create(
                {
                    "room_id": room.id,
                    "employee_id": employee,
                    "task_id": task.id,
                    "state": "draft",
                    "color": kanban_card_color(room.clean_status),
                }
            )
    return