添加功能
This commit is contained in:
@@ -43,8 +43,8 @@
|
||||
<page string="关联流程">
|
||||
<field name="soong_record_ids" style="width:100%; margin-top: 10px;">
|
||||
<tree edit="true" delete="False" editable="bottom" type="object">
|
||||
<field name="workflow_record_id" domain="[('users_ids', 'in', uid)]" options="{'no_open': True}"/>
|
||||
<field name="code"/>
|
||||
<field name="workflow_record_id" domain="[('users_ids', 'in', uid)]" options="{'no_open': True}" column_invisible="1"/>
|
||||
<field name="approvals_group_id" column_invisible="1"/>
|
||||
<field name="create_uid"/>
|
||||
<field name="write_date2"/>
|
||||
|
||||
@@ -115,10 +115,10 @@
|
||||
</div>
|
||||
<group col="4">
|
||||
<group>
|
||||
<field name="leave" string="剩余年假"/>
|
||||
<field name="leave" string="剩余年假" force_save="1"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="working_overtime" string="剩余补休"/>
|
||||
<field name="working_overtime" string="剩余补休" force_save="1"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="meal_fee" string="剩余误餐费"/>
|
||||
|
||||
@@ -862,7 +862,11 @@ class PropertyRentList(models.Model):
|
||||
rec.unlink()
|
||||
|
||||
def push_rent(self):
|
||||
current_user = self.env.user
|
||||
is_admin = current_user.has_group('base.group_system') or current_user.has_group('base.group_admin')
|
||||
for rec in self:
|
||||
if not is_admin and rec.admin_id.id != current_user.id:
|
||||
raise UserError(f"您只能推送自己记录")
|
||||
management_type = self.env['yuthon.management.type'].search([('name', '=', '租金')], limit=1)
|
||||
if not management_type:
|
||||
management_type = self.env['yuthon.management.type'].create({'name': '租金'})
|
||||
|
||||
@@ -334,7 +334,7 @@
|
||||
<field name="name">管理费列表</field>
|
||||
<field name="res_model">property.management.list</field>
|
||||
<field name="view_mode">tree,search</field>
|
||||
<field name="domain">[('is_push', '=', False), '|', ('area', '!=', 0), '|', ('contract_id.property_type', '=', 'guanggao'), ('contract_id.property_type', '=', 'guanzi')]</field>
|
||||
<field name="domain">[('is_push', '=', False), '|', ('area', '!=', 0), '|', ('contract_id.contract_sort', '=', 'guanggao'), ('contract_id.contract_sort', '=', 'guanzi')]</field>
|
||||
<field name="context">{'search_default_group_admin_id': True, 'search_default_group_due_date': True}</field>
|
||||
</record>
|
||||
<!--应收账单 -->
|
||||
|
||||
@@ -170,6 +170,7 @@ class PropertyRentalWizard(models.Model):
|
||||
records = self.env['property.lease.contract'].search([
|
||||
('actual_start_time', '<', next_month_first_day),
|
||||
('actual_end_time', '>=', first_day),
|
||||
('contract_code', '=', '租(2025)001')
|
||||
])
|
||||
|
||||
for record in records:
|
||||
|
||||
@@ -20,7 +20,6 @@ class YuthonContractAddition(models.Model):
|
||||
issues_result = fields.Html(string="会议结果")
|
||||
related_issues_id = fields.Many2one('issue.library', string="关联议题")
|
||||
reason = fields.Text(string="正文")
|
||||
workflow_id = fields.Many2one('soong.workflow.record', string="流程")
|
||||
document_ids = fields.Many2many('ir.attachment', string="附件")
|
||||
|
||||
active = fields.Boolean('Active', default=True, tracking=True)
|
||||
@@ -40,7 +39,6 @@ class YuthonContractAddition(models.Model):
|
||||
self.env['issue.library.approval.line'].create({
|
||||
'issue_library_id': issue_id.id,
|
||||
'workflow_name': self.name,
|
||||
'approval_type': self.workflow_id.name,
|
||||
'res_model': self._name,
|
||||
'res_id': self.id,
|
||||
'code': self.code,
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
<field name="name"/>
|
||||
<field name="users_id"/>
|
||||
<field name="reason"/>
|
||||
<field name="workflow_id"/>
|
||||
<field name="document_ids" widget="preview_many2many"/>
|
||||
<field name="department_id" invisible="1"/>
|
||||
</group>
|
||||
|
||||
Reference in New Issue
Block a user