Return all data when the search condition is empty?

use the local array as data to realize the search function. Query according to the condition when the condition is available, and return all data when the condition is empty
this.users: local object array

search() {
          console.log("search")
         this.query = this.$refs.search.value;
          if (this.query === "") {
               this.$message({
                    showClose: true,
                    message: "",
                    type: "warning"
                });
                // this.users = this.user
                this.users = Object.assign({},this.user)
          } else {
               this.$message({
                    showClose: true,
                    message: ":",
                    type: "success"
                });
                let result = []
                result = this.users.filter(item => {
                    return item.name === this.query
                })
                this.users = result 
            }
      },
      

clipboard.png
now that the search condition is empty and no data is returned, how to modify it?

Aug.24,2021

if (this.query ='') {

   this.$message({
        showClose: true,
        message: '',
        type: 'warning'
    });
  return 

}


this.users = result this.users has been modified.
this.users = Object.assign ({}, this.user) what is this.user?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eaf04b-47ff8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eaf04b-47ff8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?