优化界面展示

This commit is contained in:
mgw
2023-08-16 09:42:51 +08:00
parent 4a5fb0c6e4
commit 06ed10bd5e
2 changed files with 28 additions and 6 deletions

View File

@@ -27,8 +27,14 @@
<form string="坯料预制计划">
<header>
<button string="执行排程" name="get_plan_end_time" type="object" class="oe_highlight"/>
<field name="state" widget="statusbar" statusbar_visible="draft,produce"/>
</header>
<sheet>
<div class="oe_title">
<h1>
<field name="pl_no" readonly="1"/>
</h1>
</div>
<group>
<group string="基本信息">
<field name="pl_no"/>
@@ -38,12 +44,25 @@
<field name="plan_end_time"/>
<field name="state"/>
</group>
<group string="规格信息">
<field name="length"/>
<field name="width"/>
<field name="thickness"/>
<field name="diameter"/>
<field name="material"/>
<group string="规格信息" col="1">
<group col="3">
<group>
<field name="length"/>
</group>
<group>
<field name="width"/>
</group>
<group>
<field name="thickness"/>
</group>
</group>
<!-- <field name="length"/> -->
<!-- <field name="width"/> -->
<!-- <field name="thickness"/> -->
<group>
<field name="diameter"/>
<field name="material"/>
</group>
</group>
<group string="绑定订单">
<field name="customer_name"/>

View File

@@ -20,6 +20,7 @@ import { Component, onWillUpdateProps, useState, useRef, useEffect } from "@odoo
export class StepViewer extends Component {
setup() {
console.log('setup')
this.props.url = this.formatUrl();
}
@@ -33,9 +34,11 @@ export class StepViewer extends Component {
id: JSON.stringify(this.props.record.data['id']),
field: this.props.name}
url = url_props['base_url']+'/web/content/'+url_props['model']+'/'+url_props['id']+'/'+url_props['field']+'?download=true'
console.log('url', url)
} else {
url = "data:model/gltf-binary;base64," + this.props.value;
console.log('url222', url)
}
}
return url