No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    q-uploader - how to reset file upload after successful upload

    Help
    4
    6
    2578
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • B
      bulbul last edited by

      My file upload has been uploaded successfully it’s ok. But when i click form close button then it close perfectly but no empty/reset q-uploader. When i again click on the add button then showing before image in q-uplader.
      I need reset file upload after successful upload.
      Please Help Me

      1 Reply Last reply Reply Quote 0
      • S
        splender99 last edited by

        Need this feature also, a reset component method, or any way to clear the list programmatically without clicking on the check icons manually.

        1 Reply Last reply Reply Quote 0
        • SB
          SB last edited by

          Need this feature as well. There is the @finish() event and methods called reset() / removeUploadedFiles(). How can I call this methods from @finish()?

          SB 1 Reply Last reply Reply Quote 0
          • SB
            SB @SB last edited by

            I found a solution:

            Add ref and @finish to QUploader:

            <q-uploader
                :factory="getUploadFactory"
                @uploaded="uploaded"
                @finish="finished"
                ref="uploader"
                label="Add new picture"
                accept=".jpg, .png, .gif, image/*"
                class="slide-image"
                square
                dark
            />
            

            Reset QUploader:

            finished () {
                this.$refs.uploader.reset()
            }
            
            1 Reply Last reply Reply Quote 0
            • B
              BugFixer last edited by

              Hello every one I’m new here. I’m using q-uploader to upload images.
              but i would like to trigge the pickFiles method when the user click on a button but not on the uploader + button.
              I use this

              this.$refs.uploader.pickFiles()
              but I get an error

              Error in v-on handler: “TypeError: this.$refs.uploader is undefined”

              Help please.

              1 Reply Last reply Reply Quote 0
              • B
                BugFixer last edited by

                I solved the problem
                The problem was the q-uploader was not visible. the v-if was false

                1 Reply Last reply Reply Quote 0
                • First post
                  Last post