We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
<unicloud-db ref="udb" :collection="collectionList" field="username,avatar" :where="where" page-data="replace" :orderby="orderby" :getcount="true" :page-size="options.pageSize" :page-current="options.pageCurrent" v-slot:default="{data,pagination,loading,error,options}" :options="options" loadtime="manual" @load="onqueryload"> <uni-table ref="table" :loading="loading" :emptyText="error.message || '没有更多数据'" border stripe type="selection" @selection-change="selectionChange"> <uni-tr> <uni-th align="center" filter-type="search" @filter-change="filterChange($event, 'username')" sortable @sort-change="sortChange($event, 'username')">姓名</uni-th> <uni-th align="center" sortable @sort-change="sortChange($event, 'avatar')">头像</uni-th> <uni-th align="center">操作</uni-th> </uni-tr> <uni-tr v-for="(item,index) in data" :key="index"> <uni-td align="center">{{item.username}}</uni-td> <uni-td align="center"> <uni-file-picker v-if="item.avatar && item.avatar.fileType == 'image'" :value="item.avatar" :file-mediatype="item.avatar && item.avatar.fileType" return-type="object" :imageStyles="imageStyles" readonly></uni-file-picker> <uni-link v-else :href="item.avatar && item.avatar.url" :text="item.avatar && item.avatar.url"></uni-link> </uni-td> <uni-td align="center"> <view class="uni-group"> <button @click="navigateTo('./edit?id='+item._id, false)" class="uni-button" size="mini" type="primary">修改</button> <button @click="confirmDelete(item._id)" class="uni-button" size="mini" type="warn">删除</button> </view> </uni-td> </uni-tr> </uni-table> <view class="uni-pagination-box"> <uni-pagination show-icon :page-size="pagination.size" v-model="pagination.current" :total="pagination.count" @change="onPageChanged" /> </view> </unicloud-db>
:value="item.avatar"传给组件uni-file-picker的值,在uni-file-picker.vue组件中watch监听value和modelValue都是immediate: true。导致连续处理了两次。导致setValue方法处理this.files的数据时,后面的把前面的覆盖了图片无法显示。
The text was updated successfully, but these errors were encountered:
Sorry, something went wrong.
No branches or pull requests
:value="item.avatar"传给组件uni-file-picker的值,在uni-file-picker.vue组件中watch监听value和modelValue都是immediate: true。导致连续处理了两次。导致setValue方法处理this.files的数据时,后面的把前面的覆盖了图片无法显示。
The text was updated successfully, but these errors were encountered: