Merge branch 'preprod_odex25_donation' into ENS-3085

This commit is contained in:
abdurrahman-saber 2025-05-06 00:01:06 +03:00 committed by GitHub
commit 430bc6a2eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 12 additions and 7 deletions

View File

@ -23,6 +23,7 @@ on:
- dev_odex25_website - dev_odex25_website
- dev_openeducat_erp-14.0.1.0 - dev_openeducat_erp-14.0.1.0
- dev_odex25_ensan - dev_odex25_ensan
- dev_odex25_donation
- preprod_odex-event - preprod_odex-event
- preprod_odex25_accounting - preprod_odex25_accounting
- preprod_odex25_base - preprod_odex25_base
@ -43,6 +44,7 @@ on:
- preprod_odex25_website - preprod_odex25_website
- preprod_openeducat_erp-14.0.1.0 - preprod_openeducat_erp-14.0.1.0
- preprod_odex25_ensan - preprod_odex25_ensan
- preprod_odex25_donation
workflow_dispatch: workflow_dispatch:
inputs: inputs:
@ -60,13 +62,13 @@ jobs:
deploy_preprod_server: deploy_preprod_server:
name: Deploy to Preprod Servers name: Deploy to Preprod Servers
runs-on: app-sever-project-runner runs-on: app-sever-project-runner
if: (github.ref == 'refs/heads/preprod_odex-event' || github.ref == 'refs/heads/preprod_odex25_accounting' || github.ref == 'refs/heads/preprod_odex25_base' || github.ref == 'refs/heads/preprod_odex25_dms' || github.ref == 'refs/heads/preprod_odex25_fleet' || github.ref == 'refs/heads/preprod_odex25_ENSAN' || github.ref == 'refs/heads/preprod_odex25_hr' || github.ref == 'refs/heads/preprod_odex25_inventory' || github.ref == 'refs/heads/preprod_odex25_maintenance' || github.ref == 'refs/heads/preprod_odex25_mobile' || github.ref == 'refs/heads/preprod_odex25_pos' || github.ref == 'refs/heads/preprod_odex25_project' || github.ref == 'refs/heads/preprod_odex25_purchase' || github.ref == 'refs/heads/preprod_odex25_realstate' || github.ref == 'refs/heads/preprod_odex25_sales' || github.ref == 'refs/heads/preprod_odex25_survey' || github.ref == 'refs/heads/preprod_odex25_transactions' || github.ref == 'refs/heads/preprod_odex25_website' || github.ref == 'refs/heads/preprod_openeducat_erp-14.0.1.0' || github.ref == 'refs/heads/preprod_odex25_ensan') || (github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'preprod') if: (github.ref == 'refs/heads/preprod_odex-event' || github.ref == 'refs/heads/preprod_odex25_accounting' || github.ref == 'refs/heads/preprod_odex25_base' || github.ref == 'refs/heads/preprod_odex25_dms' || github.ref == 'refs/heads/preprod_odex25_fleet' || github.ref == 'refs/heads/preprod_odex25_ENSAN' || github.ref == 'refs/heads/preprod_odex25_hr' || github.ref == 'refs/heads/preprod_odex25_inventory' || github.ref == 'refs/heads/preprod_odex25_maintenance' || github.ref == 'refs/heads/preprod_odex25_mobile' || github.ref == 'refs/heads/preprod_odex25_pos' || github.ref == 'refs/heads/preprod_odex25_project' || github.ref == 'refs/heads/preprod_odex25_purchase' || github.ref == 'refs/heads/preprod_odex25_realstate' || github.ref == 'refs/heads/preprod_odex25_sales' || github.ref == 'refs/heads/preprod_odex25_survey' || github.ref == 'refs/heads/preprod_odex25_transactions' || github.ref == 'refs/heads/preprod_odex25_website' || github.ref == 'refs/heads/preprod_openeducat_erp-14.0.1.0' || github.ref == 'refs/heads/preprod_odex25_ensan' || github.ref == 'refs/heads/preprod_odex25_donation') || (github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'preprod')
steps: steps:
- name: Checkout And Restart Project - name: Checkout And Restart Project
run: | run: |
sudo chmod +x /home/${{ secrets.CLIENT_USER }}/scripts/pull/preprod_pull_standard_code.sh sudo chmod +x /home/${{ secrets.CLIENT_USER }}/scripts/pull/preprod_pull_standard_code.sh
sudo /home/${{ secrets.CLIENT_USER }}/scripts/pull/preprod_pull_standard_code.sh sudo /home/${{ secrets.CLIENT_USER }}/scripts/pull/preprod_pull_standard_code.sh
sudo systemctl restart ${{ secrets.ENSAN_APP_PREPROD_SERVICE }} ${{ secrets.ODEX25_GENERAL_PREPROD_SERVICE }} ${{ secrets.ODEX25_STANDARD_PREPROD_SERVICE }} ${{ secrets.TWAHOD_APP_PREPROD_SERVICE }} ${{ secrets.ODEX25_DEMO_PREPROD_SERVICE }} ${{ secrets.HELPDESK_PREPROD_SERVICE }} ${{ secrets.CYBER_APP_PREPROD_SERVICE }} sudo systemctl restart ${{ secrets.ENSAN_APP_PREPROD_SERVICE }} ${{ secrets.ODEX25_GENERAL_PREPROD_SERVICE }} ${{ secrets.ODEX25_STANDARD_PREPROD_SERVICE }} ${{ secrets.TWAHOD_APP_PREPROD_SERVICE }} ${{ secrets.ODEX25_DEMO_PREPROD_SERVICE }} ${{ secrets.HELPDESK_PREPROD_SERVICE }} ${{ secrets.TRAHUM_PREPROD_SERVICE }} ${{ secrets.CYBER_APP_PREPROD_SERVICE }}
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
echo "** [INFO] "PREPROD" services have been restarted." echo "** [INFO] "PREPROD" services have been restarted."
else else
@ -76,13 +78,13 @@ jobs:
deploy_test_server: deploy_test_server:
name: Deploy to Dev Servers name: Deploy to Dev Servers
runs-on: app-sever-project-runner runs-on: app-sever-project-runner
if: (github.ref == 'refs/heads/dev_odex-event' || github.ref == 'refs/heads/dev_odex25_accounting' || github.ref == 'refs/heads/dev_odex25_base' || github.ref == 'refs/heads/dev_odex25_dms' || github.ref == 'refs/heads/dev_odex25_fleet' || github.ref == 'refs/heads/dev_odex25_ENSAN' || github.ref == 'refs/heads/dev_odex25_hr' || github.ref == 'refs/heads/dev_odex25_inventory' || github.ref == 'refs/heads/dev_odex25_maintenance' || github.ref == 'refs/heads/dev_odex25_mobile' || github.ref == 'refs/heads/dev_odex25_pos' || github.ref == 'refs/heads/dev_odex25_project' || github.ref == 'refs/heads/dev_odex25_purchase' || github.ref == 'refs/heads/dev_odex25_realstate' || github.ref == 'refs/heads/dev_odex25_sales' || github.ref == 'refs/heads/dev_odex25_survey' || github.ref == 'refs/heads/dev_odex25_transactions' || github.ref == 'refs/heads/dev_odex25_website' || github.ref == 'refs/heads/dev_openeducat_erp-14.0.1.0' || github.ref == 'refs/heads/dev_odex25_ensan') || (github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'dev') if: (github.ref == 'refs/heads/dev_odex-event' || github.ref == 'refs/heads/dev_odex25_accounting' || github.ref == 'refs/heads/dev_odex25_base' || github.ref == 'refs/heads/dev_odex25_dms' || github.ref == 'refs/heads/dev_odex25_fleet' || github.ref == 'refs/heads/dev_odex25_ENSAN' || github.ref == 'refs/heads/dev_odex25_hr' || github.ref == 'refs/heads/dev_odex25_inventory' || github.ref == 'refs/heads/dev_odex25_maintenance' || github.ref == 'refs/heads/dev_odex25_mobile' || github.ref == 'refs/heads/dev_odex25_pos' || github.ref == 'refs/heads/dev_odex25_project' || github.ref == 'refs/heads/dev_odex25_purchase' || github.ref == 'refs/heads/dev_odex25_realstate' || github.ref == 'refs/heads/dev_odex25_sales' || github.ref == 'refs/heads/dev_odex25_survey' || github.ref == 'refs/heads/dev_odex25_transactions' || github.ref == 'refs/heads/dev_odex25_website' || github.ref == 'refs/heads/dev_openeducat_erp-14.0.1.0' || github.ref == 'refs/heads/dev_odex25_ensan' || github.ref == 'refs/heads/dev_odex25_donation') || (github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'dev')
steps: steps:
- name: Checkout And Restart Project - name: Checkout And Restart Project
run: | run: |
sudo chmod +x /home/${{ secrets.CLIENT_USER }}/scripts/pull/dev_pull_standard_code.sh sudo chmod +x /home/${{ secrets.CLIENT_USER }}/scripts/pull/dev_pull_standard_code.sh
sudo /home/${{ secrets.CLIENT_USER }}/scripts/pull/dev_pull_standard_code.sh sudo /home/${{ secrets.CLIENT_USER }}/scripts/pull/dev_pull_standard_code.sh
sudo systemctl restart ${{ secrets.ENSAN_APP_TEST_SERVICE }} ${{ secrets.ODEX25_GENERAL_TEST_SERVICE }} ${{ secrets.ODEX25_STANDARD_TEST_SERVICE }} ${{ secrets.TWAHOD_APP_TEST_SERVICE }} ${{ secrets.HELPDESK_TEST_SERVICE }} ${{ secrets.KAZ_LIBRARY_TEST_SERVICE }} ${{ secrets.CYBER_APP_TEST_SERVICE }} sudo systemctl restart ${{ secrets.ENSAN_APP_TEST_SERVICE }} ${{ secrets.ODEX25_GENERAL_TEST_SERVICE }} ${{ secrets.ODEX25_STANDARD_TEST_SERVICE }} ${{ secrets.TWAHOD_APP_TEST_SERVICE }} ${{ secrets.HELPDESK_TEST_SERVICE }} ${{ secrets.KAZ_LIBRARY_TEST_SERVICE }} ${{ secrets.TRAHUM_TEST_SERVICE }} ${{ secrets.CYBER_APP_TEST_SERVICE }}
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
echo "** [INFO] "DEV" services have been restarted." echo "** [INFO] "DEV" services have been restarted."
else else

View File

@ -11,6 +11,7 @@ class DonationRequest(models.Model):
name = fields.Char(string="Donation Name", required=True, tracking=True, copy=False, default=_('New')) name = fields.Char(string="Donation Name", required=True, tracking=True, copy=False, default=_('New'))
request_number = fields.Char(string="Request Number", readonly=True, default=lambda self: _('New'), copy=False) request_number = fields.Char(string="Request Number", readonly=True, default=lambda self: _('New'), copy=False)
user_id = fields.Many2one('res.users', string="Responsible/Submitter", default=lambda self: self.env.user) user_id = fields.Many2one('res.users', string="Responsible/Submitter", default=lambda self: self.env.user)
partner_id = fields.Many2one('res.partner', related='user_id.partner_id', store=True) partner_id = fields.Many2one('res.partner', related='user_id.partner_id', store=True)
partner_name = fields.Char(string="Beneficiary Name", related='partner_id.name') partner_name = fields.Char(string="Beneficiary Name", related='partner_id.name')
@ -89,6 +90,7 @@ class DonationRequest(models.Model):
sms_numbers=[record.partner_mobile] sms_numbers=[record.partner_mobile]
) )
def action_open_product(self): def action_open_product(self):
self.ensure_one() self.ensure_one()
return { return {
@ -154,3 +156,4 @@ class DonationRequest(models.Model):
# # notification_ids=notification_ids # # notification_ids=notification_ids
# ) # )

View File

@ -164,6 +164,7 @@
<!-- <div> <!-- <div>
<field name="beneficiary_name"/> <field name="beneficiary_name"/>
</div> --> </div> -->
<div class="text-muted"> <div class="text-muted">
Amount: <field name="total_amount"/> Amount: <field name="total_amount"/>
</div> </div>

View File

@ -16,7 +16,6 @@
groups="ensan_donation_request.group_donations_manager" groups="ensan_donation_request.group_donations_manager"
sequence="30"> sequence="30">
<menuitem id="menu_donation_config" name="Settings" action="action_donation_request_config" sequence="0"/> <menuitem id="menu_donation_config" name="Settings" action="action_donation_request_config" sequence="0"/>
<menuitem id="menu_donation_stage" name="Donation Stages" <menuitem id="menu_donation_stage" name="Donation Stages"
action="action_donation_stage" sequence="10"/> action="action_donation_stage" sequence="10"/>
<menuitem id="menu_donation_priority" name="Donation Priorities" <menuitem id="menu_donation_priority" name="Donation Priorities"