This commit is contained in:
parent
f3b289d16c
commit
6ff32be2bb
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
|
@ -359,7 +359,14 @@
|
|||
@dragover.prevent
|
||||
@drop="onHeaderDrop(index)"
|
||||
>
|
||||
<span v-if="item.isLatest" class="new-tag">
|
||||
<span
|
||||
v-if="
|
||||
item.isLatest &&
|
||||
displayCompareList &&
|
||||
displayCompareList.length > 1
|
||||
"
|
||||
class="new-tag"
|
||||
>
|
||||
<img
|
||||
src="/images/cars/new.png"
|
||||
alt="最新品号"
|
||||
|
|
@ -1358,7 +1365,7 @@ const handleInput = (value, options = {}) => {
|
|||
|
||||
// 重新解析条件,确保使用最新的条件顺序
|
||||
parsedConditions.value = parseConditions(newValue);
|
||||
|
||||
|
||||
// 清理精准查询条件:如果原条件有精准查询标记,需要移除或更新
|
||||
if (preciseConditions.value.length > 0) {
|
||||
// 找到引用原索引的精准查询条件
|
||||
|
|
@ -1463,7 +1470,7 @@ const handleInput = (value, options = {}) => {
|
|||
// 同步更新 parsedConditions,确保 tag 显示与输入框内容一致
|
||||
const newConditions = parseConditions(normalizedValue);
|
||||
parsedConditions.value = newConditions;
|
||||
|
||||
|
||||
// 清理不再存在的精准查询条件
|
||||
if (preciseConditions.value.length > 0) {
|
||||
preciseConditions.value = preciseConditions.value.filter((preciseCond) => {
|
||||
|
|
@ -1477,7 +1484,7 @@ const handleInput = (value, options = {}) => {
|
|||
return exists;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
// 同步精准查询条件的索引
|
||||
syncPreciseConditionsIndex();
|
||||
|
||||
|
|
@ -1510,16 +1517,14 @@ const fetchSearchHints = async (keyword) => {
|
|||
// 如果正在编辑中间的条件,需要重新排序:将正在编辑的条件移到最后一个位置
|
||||
let conditionsToProcess = [...parsedConditions.value];
|
||||
let reorderedInputWord = currentInput.value.trim();
|
||||
|
||||
|
||||
if (activeIndex >= 0 && activeIndex < conditionsToProcess.length - 1) {
|
||||
// 正在编辑中间的条件,需要重新排序
|
||||
const [editedCondition] = conditionsToProcess.splice(activeIndex, 1);
|
||||
conditionsToProcess.push(editedCondition);
|
||||
|
||||
|
||||
// 重新构建 inputWord,将被编辑的条件移到最后一个位置
|
||||
const reorderedParts = parts
|
||||
.map((p) => p.trim())
|
||||
.filter((p) => p);
|
||||
const reorderedParts = parts.map((p) => p.trim()).filter((p) => p);
|
||||
if (activeIndex < reorderedParts.length) {
|
||||
const [editedPart] = reorderedParts.splice(activeIndex, 1);
|
||||
reorderedParts.push(editedPart);
|
||||
|
|
@ -1560,7 +1565,7 @@ const fetchSearchHints = async (keyword) => {
|
|||
const isValueFromSuggestion = allValues.value.some(
|
||||
(item) => String(item.value) === String(condition.value)
|
||||
);
|
||||
|
||||
|
||||
if (isValueFromSuggestion) {
|
||||
// 从下拉框选择的值,放在 fieldValue 里
|
||||
return {
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue