Print Courtesy Car Contract IO-300
This commit is contained in:
@@ -6869,6 +6869,27 @@
|
||||
</translation>
|
||||
</translations>
|
||||
</concept_node>
|
||||
<concept_node>
|
||||
<name>printcontract</name>
|
||||
<definition_loaded>false</definition_loaded>
|
||||
<description></description>
|
||||
<comment></comment>
|
||||
<default_text></default_text>
|
||||
<translations>
|
||||
<translation>
|
||||
<language>en-US</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>es-MX</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>fr-CA</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
</translations>
|
||||
</concept_node>
|
||||
<concept_node>
|
||||
<name>senddltoform</name>
|
||||
<definition_loaded>false</definition_loaded>
|
||||
|
||||
@@ -7,6 +7,8 @@ import ContractCourtesyCarBlock from "../../components/contract-courtesy-car-blo
|
||||
import ContractFormComponent from "../../components/contract-form/contract-form.component";
|
||||
import ContractJobBlock from "../../components/contract-job-block/contract-job-block.component";
|
||||
import { setModalContext } from "../../redux/modals/modals.actions";
|
||||
import { GenerateDocument } from "../../utils/RenderTemplate";
|
||||
import { TemplateList } from "../../utils/TemplateConstants";
|
||||
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
setCourtesyCarReturnModalContext: (context) =>
|
||||
@@ -65,7 +67,25 @@ export function ContractDetailPage({
|
||||
>
|
||||
{t("courtesycars.actions.return")}
|
||||
</Button>
|
||||
|
||||
<Button
|
||||
disabled={
|
||||
!!!contract ||
|
||||
(contract && contract.status !== "contracts.status.out")
|
||||
}
|
||||
onClick={() => {
|
||||
GenerateDocument(
|
||||
{
|
||||
name: TemplateList("courtesycarcontract")
|
||||
.courtesy_car_contract.key,
|
||||
variables: { id: contract.id },
|
||||
},
|
||||
{},
|
||||
"p"
|
||||
);
|
||||
}}
|
||||
>
|
||||
{t("contracts.actions.printcontract")}
|
||||
</Button>
|
||||
<ContractConvertToRo
|
||||
contract={contract}
|
||||
disabled={form.isFieldsTouched()}
|
||||
|
||||
@@ -446,6 +446,7 @@
|
||||
"actions": {
|
||||
"convertoro": "Convert to RO",
|
||||
"decodelicense": "Decode License",
|
||||
"printcontract": "Print Contract",
|
||||
"senddltoform": "Insert Driver's License Information"
|
||||
},
|
||||
"errors": {
|
||||
|
||||
@@ -446,6 +446,7 @@
|
||||
"actions": {
|
||||
"convertoro": "",
|
||||
"decodelicense": "",
|
||||
"printcontract": "",
|
||||
"senddltoform": ""
|
||||
},
|
||||
"errors": {
|
||||
|
||||
@@ -446,6 +446,7 @@
|
||||
"actions": {
|
||||
"convertoro": "",
|
||||
"decodelicense": "",
|
||||
"printcontract": "",
|
||||
"senddltoform": ""
|
||||
},
|
||||
"errors": {
|
||||
|
||||
Reference in New Issue
Block a user