internal button vies

This commit is contained in:
blackbelts 2025-07-07 00:21:55 +03:00
parent 099aac4354
commit d6d39ec00c
2 changed files with 29 additions and 17 deletions

View File

@ -161,6 +161,7 @@ class InternalTransaction(models.Model):
record.trace_create_ids('internal_transaction_id', record, sent)
partner_ids = []

View File

@ -99,14 +99,25 @@
confirm="Are you sure you want to approve transaction ?"/>
<button attrs="{'invisible':['|',('current_is_manager','=',False),('state','!=','to_approve')]}"
type="object" name="action_reject_internal" string="Reject" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_manager','=',False),('state','!=','to_approve')]}"
type="object" name="action_return_internal" string="Return" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"
type="object" name="action_forward_internal" string="Forward" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"
type="object" name="action_reply_internal" string="Reply" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"
type="object" name="action_archive_internal" string="Archive" class="oe_highlight"/>
<!-- <button attrs="{'invisible':['|',('current_is_manager','=',False),('state','!=','to_approve')]}"-->
<!-- type="object" name="action_return_internal" string="Return" class="oe_highlight"/>-->
<!-- <button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"-->
<!-- type="object" name="action_forward_internal" string="Forward" class="oe_highlight"/>-->
<!-- <button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"-->
<!-- type="object" name="action_reply_internal" string="Reply" class="oe_highlight"/>-->
<!-- <button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['send','reply'])]}"-->
<!-- type="object" name="action_archive_internal" string="Archive" class="oe_highlight"/>-->
<button attrs="{'invisible':['|',('current_is_manager','=',False),('state','!=','to_approve')]}" type="object" name="action_return_internal" string="Return" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['closed','canceled'])]}" type="object" name="action_forward_internal" string="Forward" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['closed','canceled'])]}" type="object" name="action_reply_internal" string="Reply" class="oe_highlight"/>
<button attrs="{'invisible':['|',('current_is_forward_user','=',False),('state','not in',['closed','canceled'])]}" type="object" name="action_archive_internal" string="Archive" class="oe_highlight"/>
<button states="closed" type="object" name="action_reopen_internal" string="Reopen"
class="oe_highlight" groups="exp_transaction_documents.group_reopen_transaction,exp_transaction_documents.group_transaction_manager" confirm="Are you sure you want to reopen transaction ?"/>
<button states="canceled" type="object" name="set_to_draft" string="Restore"
@ -125,9 +136,9 @@
</xpath>
<xpath expr="//field[@name='tran_tag']" position="after">
<field name="to_delegate" readonly="1" force_save="1"/>
<!-- <field name="delegate_employee_id"/>-->
<!-- <field name="from_date"/>-->
<!-- <field name="to_date"/>-->
<!-- <field name="delegate_employee_id"/>-->
<!-- <field name="from_date"/>-->
<!-- <field name="to_date"/>-->
</xpath>
</field>
</record>
@ -202,9 +213,9 @@
<xpath expr="//field[@name='to_ids']" position="after">
<field name="partner_id"/>
<field name="to_delegate" readonly="1" force_save="1"/>
<!-- <field name="delegate_employee_id"/>-->
<!-- <field name="from_date"/>-->
<!-- <field name="to_date"/>-->
<!-- <field name="delegate_employee_id"/>-->
<!-- <field name="from_date"/>-->
<!-- <field name="to_date"/>-->
</xpath>
<xpath expr="//field[@name='to_ids']" position="before">
<field name="type_sender" attrs="{'readonly':[('state','not in', ['draft'])]}"/>