|
|
|
@ -135,7 +135,7 @@ |
|
|
|
v-for="(header, hIndex) in headers" |
|
|
|
@tap.stop="onContentItemTap(cIndex, hIndex)" |
|
|
|
:key="contentItemKey(header, hIndex)" |
|
|
|
:style="{ |
|
|
|
:style="[myAssign({ |
|
|
|
minWidth: (header.width || defaultColWidth) + 'rpx', |
|
|
|
maxWidth: (header.width || defaultColWidth) + 'rpx', |
|
|
|
textAlign: textAlign, |
|
|
|
@ -149,8 +149,7 @@ |
|
|
|
borderRight: hIndex === headers.length - 1 || (!showVertBorder && hIndex !== 0) ? 'none' : '1px solid' + borderColor, |
|
|
|
zIndex: hIndex === 0 ? 20 : 0, |
|
|
|
left: enableCheck ? checkColWidth + 'rpx' : 0, |
|
|
|
position: hIndex === 0 && firstLineFixed ? 'sticky' : 'static', |
|
|
|
...content.searchStyle }"> |
|
|
|
position: hIndex === 0 && firstLineFixed ? 'sticky' : 'static'}, content.searchStyle)]"> |
|
|
|
<input class="lf-w-100" placeholder="请输入.." |
|
|
|
:disabled="content.disabled || false" |
|
|
|
v-if="isObject(autoContentItem(cIndex, hIndex), 'edit')" |
|
|
|
@ -766,6 +765,7 @@ |
|
|
|
if (this.onload) { |
|
|
|
this.contentsSort.forEach(item => { |
|
|
|
this.$set(item, 'checked', false) |
|
|
|
this.$set(item, 'searchStyle', {}) |
|
|
|
}) |
|
|
|
this.oContentsSort = this.contentsSort.slice() |
|
|
|
this.onload = false |
|
|
|
@ -792,6 +792,7 @@ |
|
|
|
}) |
|
|
|
// 处理匹配到item时滚动至第一个item |
|
|
|
if(positionIndex != null){ |
|
|
|
// #ifdef H5 |
|
|
|
let tabView = document.querySelector('.wyb-table-scroll-view'); // 获取第一层大对象,table |
|
|
|
let tabContent = tabView.querySelector('.wyb-table-content'); // 获取第二层,table的content部分 |
|
|
|
let contentLine = tabContent.querySelector('.wyb-table-content-line-'+ positionIndex); // 获取第三层,获取内容列 |
|
|
|
@ -799,6 +800,7 @@ |
|
|
|
let offsetHeight = contentLine.offsetHeight; // table行高度 |
|
|
|
let offsetTop = contentLine.offsetTop; // table行距离页面高度 |
|
|
|
tabView.scrollTop = offsetTop - tabViewTop - offsetHeight; |
|
|
|
// #endif |
|
|
|
}else if(val){ |
|
|
|
this.$msg('该关键字没有搜索到物资哦') |
|
|
|
} |
|
|
|
@ -823,6 +825,10 @@ |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
// 对象拼接 |
|
|
|
myAssign(a, b){ |
|
|
|
return Object.assign(a, b); |
|
|
|
}, |
|
|
|
// 页面初次加载,判断是否自动滚动至input输入框所在的位置 |
|
|
|
autoScrollView(){ |
|
|
|
try{ |
|
|
|
|