| | |
| | | }, |
| | | mounted() { |
| | | this.arr = this.reportData.products; |
| | | if(this.reportData.length>0){ |
| | | if (this.reportData.products.length < 10) { |
| | | let size = this.reportData.products.length; |
| | | let num = 10 - size |
| | | for (let i = 0; i < num; i++) { |
| | | this.arr.push({ |
| | | code: null, |
| | | ipName: "", |
| | | required: "", |
| | | testState: null, |
| | | testValue: "", |
| | | unit: "" |
| | | }) |
| | | } |
| | | if (this.reportData.products.length < 10) { |
| | | let size = this.reportData.products.length; |
| | | let num = 10 - size |
| | | for (let i = 0; i < num; i++) { |
| | | this.arr.push({ |
| | | code: null, |
| | | ipName: "", |
| | | required: "", |
| | | testState: null, |
| | | testValue: "", |
| | | unit: "" |
| | | }) |
| | | } |
| | | } |
| | | }, |