ImEX and App Improvements.
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
import {useMutation} from "@apollo/client";
|
||||
import {Button, Form, notification, Popover, Tooltip} from "antd";
|
||||
import {t} from "i18next";
|
||||
import React, {useState} from "react";
|
||||
import {UPDATE_LINE_PPC} from "../../graphql/jobs-lines.queries";
|
||||
import { useMutation } from "@apollo/client";
|
||||
import { Button, Form, notification, Popover, Tooltip } from "antd";
|
||||
import axios from "axios";
|
||||
import { t } from "i18next";
|
||||
import React, { useState } from "react";
|
||||
import { UPDATE_LINE_PPC } from "../../graphql/jobs-lines.queries";
|
||||
import CurrencyFormatter from "../../utils/CurrencyFormatter";
|
||||
import InstanceRenderManager from "../../utils/instanceRenderMgr";
|
||||
import CurrencyFormItemComponent from "../form-items-formatted/currency-form-item.component";
|
||||
import JobLineConvertToLabor from "../job-line-convert-to-labor/job-line-convert-to-labor.component";
|
||||
import axios from "axios";
|
||||
import InstanceRenderManager from "../../utils/instanceRenderMgr";
|
||||
|
||||
export default function JobLinesPartPriceChange({job, line, refetch}) {
|
||||
const [loading, setLoading] = useState(false);
|
||||
@@ -54,7 +54,9 @@ export default function JobLinesPartPriceChange({job, line, refetch}) {
|
||||
}
|
||||
};
|
||||
|
||||
const popcontent = (
|
||||
const popcontent = InstanceRenderManager({
|
||||
imex: null,
|
||||
rome: (
|
||||
<Form layout="vertical" onFinish={handleFinish} initialValues={{act_price: line.act_price}}>
|
||||
<Form.Item
|
||||
name="act_price"
|
||||
@@ -63,15 +65,18 @@ export default function JobLinesPartPriceChange({job, line, refetch}) {
|
||||
>
|
||||
<CurrencyFormItemComponent/>
|
||||
</Form.Item>
|
||||
<Button loading={loading} htmlType="primary">
|
||||
<Button disabled={InstanceRenderManager({imex:true, rome: false, promanager: true})} loading={loading} htmlType="primary">
|
||||
{t("general.actions.save")}
|
||||
</Button>
|
||||
</Form>
|
||||
);
|
||||
),
|
||||
promanager: null
|
||||
}) ;
|
||||
|
||||
return (
|
||||
<JobLineConvertToLabor jobline={line} job={job}>
|
||||
<Popover trigger="click" disabled={line.manual_line || InstanceRenderManager({imex:false, rome:true})} content={popcontent}>
|
||||
<Popover trigger="click"
|
||||
disabled={true || line.manual_line} content={popcontent}>
|
||||
<CurrencyFormatter>
|
||||
{line.db_ref === "900510" || line.db_ref === "900511"
|
||||
? line.prt_dsmk_m
|
||||
|
||||
@@ -8,9 +8,9 @@ import {
|
||||
SyncOutlined,
|
||||
WarningFilled,
|
||||
} from '@ant-design/icons';
|
||||
import { useMutation } from '@apollo/client';
|
||||
import { Button, Checkbox, Dropdown, Input, Space, Table, Tag } from 'antd';
|
||||
import { PageHeader } from '@ant-design/pro-layout';
|
||||
import { useMutation } from '@apollo/client';
|
||||
import { Button, Dropdown, Input, Space, Table, Tag } from 'antd';
|
||||
import axios from 'axios';
|
||||
import React, { useState } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
@@ -29,19 +29,19 @@ import JobLinesBillRefernece from '../job-lines-bill-reference/job-lines-bill-re
|
||||
// import AllocationsAssignmentContainer from "../allocations-assignment/allocations-assignment.container";
|
||||
// import AllocationsBulkAssignmentContainer from "../allocations-bulk-assignment/allocations-bulk-assignment.container";
|
||||
// import AllocationsEmployeeLabelContainer from "../allocations-employee-label/allocations-employee-label.container";
|
||||
import { useSplitTreatments } from '@splitsoftware/splitio-react';
|
||||
import _ from 'lodash';
|
||||
import { selectBodyshop } from '../../redux/user/user.selectors';
|
||||
import dayjs from '../../utils/day';
|
||||
import { HasFeatureAccess } from '../feature-wrapper/feature-wrapper.component';
|
||||
import JobCreateIOU from '../job-create-iou/job-create-iou.component';
|
||||
import JobLineBulkAssignComponent from '../job-line-bulk-assign/job-line-bulk-assign.component';
|
||||
import JobLineDispatchButton from '../job-line-dispatch-button/job-line-dispatch-button.component';
|
||||
import JoblineTeamAssignment from '../job-line-team-assignment/job-line-team-assignmnent.component';
|
||||
import JobSendPartPriceChangeComponent from '../job-send-parts-price-change/job-send-parts-price-change.component';
|
||||
import PartsOrderModalContainer from '../parts-order-modal/parts-order-modal.container';
|
||||
import JobLinesExpander from './job-lines-expander.component';
|
||||
import { selectBodyshop } from '../../redux/user/user.selectors';
|
||||
import dayjs from '../../utils/day';
|
||||
import JobLinesPartPriceChange from './job-lines-part-price-change.component';
|
||||
import JoblineTeamAssignment from '../job-line-team-assignment/job-line-team-assignmnent.component';
|
||||
import JobLineDispatchButton from '../job-line-dispatch-button/job-line-dispatch-button.component';
|
||||
import JobLineBulkAssignComponent from '../job-line-bulk-assign/job-line-bulk-assign.component';
|
||||
import { useSplitTreatments } from '@splitsoftware/splitio-react';
|
||||
import { HasFeatureAccess } from '../feature-wrapper/feature-wrapper.component';
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
bodyshop: selectBodyshop,
|
||||
@@ -219,12 +219,12 @@ export function JobLinesComponent({
|
||||
key: 'part_qty',
|
||||
},
|
||||
|
||||
{
|
||||
title: t('joblines.fields.tax_part'),
|
||||
dataIndex: 'tax_part',
|
||||
key: 'tax_part',
|
||||
render: (text, record) => <Checkbox checked={record.tax_part} />,
|
||||
},
|
||||
// {
|
||||
// title: t('joblines.fields.tax_part'),
|
||||
// dataIndex: 'tax_part',
|
||||
// key: 'tax_part',
|
||||
// render: (text, record) => <Checkbox checked={record.tax_part} />,
|
||||
// },
|
||||
// {
|
||||
// title: t("joblines.fields.total"),
|
||||
// dataIndex: "total",
|
||||
|
||||
Reference in New Issue
Block a user