Merge pull request !1254 from 李鹏宇/dev
This commit is contained in:
李鹏宇
2025-01-09 10:16:32 +00:00
committed by Gitee
2 changed files with 36 additions and 11 deletions
@@ -76,7 +76,7 @@ class PropertyLeaseContract(models.Model):
cycle_dict =fields.Selection([('monthly','月度'), ('quarter','季度'), ('half','半年'),('year','年度')],string='付款方式', default='monthly', help="应收")
cycle_mode = fields.Selection([('fixed_monthly','合同月'), ('floating_monthly','自然月'), ('fixed_quarter', '合同季'), ('floating_quarter', '自然季'),
('fixed_year', '合同年'), ('floating_year', '自然年')], string='周期方式', default='fixed_monthly')
expected_reminders = fields.Char(string="逾期提醒")
expected_reminders = fields.Char(string="逾期提醒", default=25)
increment_method = fields.Selection([('percentage','百分比'),('increment_price','递增单价'),('increment_amount','递增金额')], string='每月递增', default='percentage')
increment_percentage = fields.Float(string="递增百分比")
@@ -84,7 +84,7 @@ class PropertyLeaseContract(models.Model):
increment_amount = fields.Float(string="递增金额")
increment_value = fields.Float(string="递增值")
first_years_begin = fields.Integer(string="第几年开始")
first_years_begin = fields.Integer(string="第几年开始", default=2)
increments_every_few_years = fields.Integer(string="每几年递增")
rent_free_period = fields.Datetime(string="免租期")
@@ -1051,12 +1051,16 @@ class PropertyRentBreakdownLine(models.Model):
breakdown_id = fields.Many2one('property.lease.contract', string="关联租赁合同审批")
charges = fields.Char(string="收费项")
unit_price = fields.Float(string="单价")
monthly_amount = fields.Float(string="月租金", digits=(16, 0))
monthly_amount = fields.Float(string="月租金", digits=(16, 2))
start_data = fields.Date(string="开始日期")
end_data = fields.Date(string="结束日期")
month_number = fields.Integer(string="期间月数")
period_rent = fields.Float(string="期间租金", digits=(16, 0))
@api.onchange('monthly_amount')
def _onchange_monthly_amount(self):
if self.monthly_amount:
self.period_rent = self.monthly_amount * self.month_number
class PropertyWaterFeeLine(models.Model):
_name = 'property.water.fee.line'
@@ -188,7 +188,6 @@
<field name="increment_value"
class="me-2" style="max-width: 5rem !important;"/>
</div>
<field name="tax_rate"/>
<label for="deposit_type"/>
<div class="d-inline-flex w-100">
<field name="deposit_type" string="押金/履约保证金" class="me-2"
@@ -205,10 +204,7 @@
<field name="percentage_liquidated_damages" class="me-2"
style="max-width: 11rem !important;"/>
</div>
<field name="tax" readonly="1" force_save="1"/>
<field name="not_tax_amount" readonly="1" force_save="1"/>
<field name="first_year_rent"/>
<field name="total_contract_receivables" style="font-size: 1.2rem; font-weight: bold;"/>
<field name="tax_rate"/>
</group>
</group>
<group col="3">
@@ -280,6 +276,20 @@
</field>
</page>
</notebook>
<group col="4">
<group>
<field name="tax" readonly="1" force_save="1"/>
</group>
<group>
<field name="not_tax_amount" readonly="1" force_save="1"/>
</group>
<group>
<field name="first_year_rent" readonly="1" force_save="1"/>
</group>
<group>
<field name="total_contract_receivables" style="font-size: 1.2rem; font-weight: bold;"/>
</group>
</group>
</sheet>
</form>
</field>
@@ -494,9 +504,6 @@
<field name="percentage_liquidated_damages" class="me-2"
style="max-width: 11rem !important;"/>
</div>
<field name="tax" readonly="1" force_save="1"/>
<field name="not_tax_amount" readonly="1" force_save="1"/>
<field name="first_year_rent"/>
<field name="actual_receivable"/>
<field name="now_receivable"/>
<field name="total_receivable"/>
@@ -571,6 +578,20 @@
</field>
</page>
</notebook>
<group col="4">
<group>
<field name="tax" readonly="1" force_save="1"/>
</group>
<group>
<field name="not_tax_amount" readonly="1" force_save="1"/>
</group>
<group>
<field name="first_year_rent" readonly="1" force_save="1"/>
</group>
<group>
<field name="total_contract_receivables" style="font-size: 1.2rem; font-weight: bold;"/>
</group>
</group>
</sheet>
</form>
</field>