[Python] Python Textual Input "Submitted question"

Discussão em 'Python' iniciado por Stack, Abril 16, 2025.

  1. Stack

    Stack Membro Participativo

    I'm using textualize for a small program and in it I have two @on(Input.Submitted) that point to each one to a different id, but when I return the submitted input I only receive the return of one of the inputs, what could I be doing wrong?

    @on(Input.Submitted, "#inputseguradora")
    async def handle_inputseguradora(self, event: Input.Submitted) -> None:
    rich_log = self.query_one(RichLog)
    rich_log.write(self.query_one(Input).id)
    rich_log.write(self.query_one(Input).value)

    @on(Input.Submitted, "#inputanomes")
    async def handle_inputanomes(self, event: Input.Submitted) -> None:
    rich_log = self.query_one(RichLog)
    rich_log.write(self.query_one(Input).id)
    rich_log.write(self.query_one(Input).value)


    return

    Continue reading...

Compartilhe esta Página