IO-1697 Remove acct path popup if not qbd.
This commit is contained in:
@@ -6,9 +6,11 @@ import { useTranslation } from "react-i18next";
|
||||
import { connect } from "react-redux";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import { setPartnerVersion } from "../../redux/application/application.actions";
|
||||
import { selectBodyshop } from "../../redux/user/user.selectors";
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
//currentUser: selectCurrentUser
|
||||
bodyshop: selectBodyshop,
|
||||
});
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
//setUserLanguage: language => dispatch(setUserLanguage(language))
|
||||
@@ -19,7 +21,7 @@ export default connect(
|
||||
mapDispatchToProps
|
||||
)(PartnerPingComponent);
|
||||
|
||||
export function PartnerPingComponent({ setPartnerVersion }) {
|
||||
export function PartnerPingComponent({ bodyshop, setPartnerVersion }) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
useEffect(() => {
|
||||
@@ -32,7 +34,14 @@ export function PartnerPingComponent({ setPartnerVersion }) {
|
||||
|
||||
setPartnerVersion(appver);
|
||||
console.log({ appver, qbpath });
|
||||
if (!qbpath) {
|
||||
if (
|
||||
!qbpath &&
|
||||
!(
|
||||
bodyshop.cdk_dealerid ||
|
||||
bodyshop.pbs_serialnumber ||
|
||||
bodyshop.accountingconfig.qbo
|
||||
)
|
||||
) {
|
||||
notification["error"]({
|
||||
title: "",
|
||||
message: t("general.messages.noacctfilepath"),
|
||||
|
||||
Reference in New Issue
Block a user