Files
suite/project_acceptance/views/project_portal_templates.xml

89 lines
5.9 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<template id="portal_my_task_inherit" inherit_id="project.portal_my_task">
<xpath expr="//div[@class='mt32']" position="before">
<!-- modal relative to the actions accept -->
<!-- <div role="dialog" class="modal fade" id="modalaccept">
<div class="modal-dialog">
<form id="accept" method="POST" t-att-data-order-id="task.id" t-att-data-token="task.access_token" class="js_accept_json modal-content js_website_submit_form">
<input type="hidden" name="csrf_token" t-att-value="request.csrf_token()"/>
<header class="modal-header">
<h4 class="modal-title">Validate Task</h4>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>
</header>
<main class="modal-body" id="sign-dialog">
<p>
<span>By signing this proposal, I agree to the task description:</span>
<ul>
<li><span>Accepted on the behalf of:</span> <b t-field="task.partner_id.commercial_partner_id"/></li>
</ul>
</p>
<t t-call="portal.signature_form">
<t t-set="call_url" t-value="task.get_portal_url(suffix='/accept')"/>
<t t-set="default_name" t-value="task.partner_id.name"/>
</t>
</main>
</form>
</div>
</div> -->
<!-- modal relative to the action reject -->
<!-- <div role="dialog" class="modal fade" id="modaldecline">
<div class="modal-dialog">
<form id="decline" method="POST" t-attf-action="/my/task/#{task.id}/decline?access_token=#{task.access_token}" class="modal-content">
<input type="hidden" name="csrf_token" t-att-value="request.csrf_token()"/>
<header class="modal-header">
<h4 class="modal-title">Decline This Task</h4>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>
</header>
<main class="modal-body">
<p>
Tell us why you are refusing this task, this will help us improve our services.
</p>
<textarea rows="4" name="decline_message" required="" placeholder="Your feedback..." class="form-control" />
</main>
<footer class="modal-footer">
<button type="submit" t-att-id="task.id" class="btn btn-danger"><i class="fa fa-times"></i> Decline</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">Cancel</button>
</footer>
</form>
</div>
</div> -->
<!-- <div t-if="task.stage_id.name == 'cancelled'" class="alert alert-danger alert-dismissable d-print-none" role="alert">
<button type="button" class="close" data-dismiss="alert" aria-label="close">×</button>
<strong>This task has been canceled.</strong> <a role="button" href="#discussion"><i class="fa fa-comment"/> Contact us to get.</a>
</div> -->
<div t-if="task.stage_id.requires_acceptance">
<div class="row justify-content-center text-center d-print-none pt-1 pb-4">
<div class="col-sm-auto mt8">
<form id="accept" method="POST" t-attf-action="/my/task/#{task.id}/accept" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" t-att-value="request.csrf_token()"/>
<button class="btn btn-primary" t-attf-href="#" style="color: #ffffff"><i class="fa fa-check"/> Accept</button>
<!-- <a role="button" class="btn btn-primary" data-toggle="modal" data-target="#modalaccept" href="#" style="color: #ffffff"><i class="fa fa-check"/> Accepted</a> -->
</form>
</div>
<div class="col-sm-auto mt8">
<form id="decline" method="POST" t-attf-action="/my/task/#{task.id}/decline" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" t-att-value="request.csrf_token()"/>
<button class="btn btn-danger" t-attf-href="#" style="color: #ffffff"> <i class="fa fa-stop-circle"/> Declined</button>
<!-- <a role="button" class="btn btn-danger" data-toggle="modal" data-target="#modaldecline" href="#" style="color: #ffffff"> <i class="fa fa-stop-circle"/> Declined</a> -->
</form>
</div>
<div class="col-sm-auto mt8">
<!-- <form id="decline" method="POST" t-attf-action="/my/task/#{task.id}/feedback" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" t-att-value="request.csrf_token()"/> -->
<a role="button" class="btn btn-warning" href="#discussion" style="color: #ffffff"><i class="fa fa-comment"/> Feedback</a>
<!-- <a t-attf-href="#discussion">
<button class="btn btn-warning" style="color: #ffffff"><i class="fa fa-comment"/> Feedback</button>
</a>
</form> -->
</div>
</div>
</div>
</xpath>
</template>
</odoo>