修改报错问题

This commit is contained in:
hyyy
2025-03-13 17:21:22 +08:00
parent 16dbfc3867
commit 9d84b68525

View File

@@ -20,16 +20,14 @@ export class QualityCheckMeasureLineTree extends X2ManyField {
patch(ListRenderer.prototype, 'custom_measure_line_tree_patch', {
setup() {
this._super.apply(this, arguments);
console.log('custom_measure_line_tree_patch');
console.log(owl);
owl.onMounted(() => {
console.log($(this.__owl__.bdom.el).find('tfoot'));
$(this.__owl__.bdom.el).find('tfoot').hide()
})
owl.onRendered(() => {
setTimeout(() => {
const $dom = $(this.__owl__.bdom.el)
const $dom = $(this.__owl__?.bdom?.el)
if(!$dom || $dom.length) return
const $thead = $dom.find('thead').find('th');
if(!this.props.list.records || this.props.list.records.length == 0) return
const $total_qty = this.props.list.records[0].data.column_nums;