字段,打印
This commit is contained in:
@@ -45,6 +45,8 @@ class YuthonFixedAssetLoan(models.Model):
|
||||
)
|
||||
active = fields.Boolean(default=True, string='有效')
|
||||
work_end = fields.Boolean(string="结束")
|
||||
loan_date = fields.Date(string='借出时间')
|
||||
return_date = fields.Date(string='归还时间')
|
||||
|
||||
@api.depends('applicant_id')
|
||||
def _compute_department_id(self):
|
||||
|
||||
@@ -47,6 +47,13 @@
|
||||
<td class="header-cell"><strong>申请部门</strong></td>
|
||||
<td><span t-esc="doc.department_id.name"/></td>
|
||||
</tr>
|
||||
<!-- 借出时间/归还时间 -->
|
||||
<tr>
|
||||
<td class="header-cell"><strong>借出时间</strong></td>
|
||||
<td><span t-esc="doc.loan_date and doc.loan_date.strftime('%Y-%m-%d') or ''"/></td>
|
||||
<td class="header-cell"><strong>归还时间</strong></td>
|
||||
<td><span t-esc="doc.return_date and doc.return_date.strftime('%Y-%m-%d') or ''"/></td>
|
||||
</tr>
|
||||
<!-- 借出资产 -->
|
||||
<tr>
|
||||
<td class="header-cell"><strong>借出资产</strong></td>
|
||||
|
||||
@@ -28,6 +28,14 @@
|
||||
<group string="申请内容">
|
||||
<field name="loan_assets" placeholder="请输入借出资产"/>
|
||||
<field name="reason" placeholder="请输入申请事由"/>
|
||||
<group col="2">
|
||||
<group>
|
||||
<field name="loan_date" string="借出时间"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="return_date" string="归还时间"/>
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
</sheet>
|
||||
</form>
|
||||
@@ -45,6 +53,8 @@
|
||||
<field name="department_id"/>
|
||||
<field name="loan_assets"/>
|
||||
<field name="reason"/>
|
||||
<field name="loan_date"/>
|
||||
<field name="return_date"/>
|
||||
<field name="company_id"/>
|
||||
<field name="create_date"/>
|
||||
</tree>
|
||||
|
||||
Reference in New Issue
Block a user