fix: 相关命名修正
- production -> product
This commit is contained in:
@ -34,18 +34,14 @@
|
||||
:value="type.id"
|
||||
/>
|
||||
</el-select>
|
||||
<el-select
|
||||
v-model="selectedProduct"
|
||||
placeholder="选择系列产品"
|
||||
clearable
|
||||
>
|
||||
<el-sel v-model="selectedProduct" placeholder="选择系列产品" clearable>
|
||||
<el-option
|
||||
v-for="production in productOptions"
|
||||
:key="production.id"
|
||||
:label="production.name"
|
||||
:value="production.id"
|
||||
v-for="product in productOptions"
|
||||
:key="product.id"
|
||||
:label="product.name"
|
||||
:value="product.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-sel>
|
||||
<el-input
|
||||
v-model="keyword"
|
||||
placeholder="输入关键词..."
|
||||
@ -105,7 +101,7 @@
|
||||
|
||||
const filteredQuestions = computed(() => {
|
||||
return questions.value.filter((question: QuestionListView) => {
|
||||
const matchProduction = selectedProduct.value
|
||||
const matchProduct = selectedProduct.value
|
||||
? question.products?.some(
|
||||
(product: QuestionListProduct) =>
|
||||
product.id === selectedProduct.value
|
||||
@ -122,7 +118,7 @@
|
||||
(question.content && question.content.includes(keyword.value))
|
||||
: true;
|
||||
|
||||
return matchProduction && matchKeyword;
|
||||
return matchProduct && matchKeyword;
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user