Commit 1bb9df7b by owen

商品中心:修复商品表格选择对话框,在多选时表头内的多选框不显示选中效果的问题

parent e0a731dd
......@@ -20,7 +20,7 @@
</el-tooltip>
</div>
<!-- 商品选择对话框(表格形式) -->
<SpuTableSelect ref="spuTableSelectRef" multiple @change="handleSpuSelected" />
<SpuTableSelect ref="spuTableSelectRef" :multiple="limit != 1" @change="handleSpuSelected" />
</template>
<script lang="ts" setup>
import * as ProductSpuApi from '@/api/mall/product/spu'
......@@ -88,8 +88,8 @@ const openSpuTableSelect = () => {
* 选择商品后触发
* @param spus 选中的商品列表
*/
const handleSpuSelected = (spus: ProductSpuApi.Spu[]) => {
productSpus.value = spus
const handleSpuSelected = (spus: ProductSpuApi.Spu | ProductSpuApi.Spu[]) => {
productSpus.value = isArray(spus) ? spus : [spus]
emitSpuChange()
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment