Skip to content

Commit

Permalink
update upload: if maxed then hidden upload btn
Browse files Browse the repository at this point in the history
  • Loading branch information
dolymood committed Jan 19, 2018
1 parent ab7be9d commit 5624d81
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/upload/upload.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<slot>
<div class="cube-upload-def clear-fix">
<upload-file v-for="(file, i) in files" :file="file" :key="i" @click="fileClick"></upload-file>
<upload-btn></upload-btn>
<upload-btn v-show="isShowBtn"></upload-btn>
</div>
</slot>
</div>
Expand Down Expand Up @@ -72,6 +72,9 @@
} else {
return action
}
},
isShowBtn() {
return this.files.length < this.max
}
},
methods: {
Expand Down

0 comments on commit 5624d81

Please sign in to comment.