shareneus 1.7.360 → 1.7.361
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -43,6 +43,7 @@ export declare class ROTotalsService {
|
|
|
43
43
|
static GetCustPartCGSTTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
44
44
|
static GetCustPartIGSTTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
45
45
|
static GetCustPartSGSTTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
46
|
+
static GetCustPartCESSTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
46
47
|
static GetInsLaborCGSTTaxTotal(opCodesList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
47
48
|
static GetInsLaborIGSTTaxTotal(opCodesList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
48
49
|
static GetInsLaborSGSTTaxTotal(opCodesList: any, IsTaxable: boolean, isWorkOrder: boolean): any;
|
|
@@ -686,6 +686,7 @@ class ROTotalsService {
|
|
|
686
686
|
argRecordData.CustPartCGST = this.GetCustPartCGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, tr_utils_1.TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
687
687
|
argRecordData.CustPartIGST = this.GetCustPartIGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, tr_utils_1.TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
688
688
|
argRecordData.CustPartSGST = this.GetCustPartSGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, tr_utils_1.TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
689
|
+
argRecordData.CustPartCESS = this.GetCustPartCESSTaxTotal(dupRecordData.Ops, dupRecordData.Parts, tr_utils_1.TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
689
690
|
argRecordData.CustLaborLDiscAmount = this.GetLaborLDiscAmount(argRecordData.CustLaborTotalAfterDisc, argRecordData.LDisc);
|
|
690
691
|
argRecordData.CustPartsPDiscAmount = this.GetPartsPDiscAmount(argRecordData.CustPartsTotalAfterDisc, argRecordData.PDisc);
|
|
691
692
|
argRecordData.CustLaborAfterLDisc = argRecordData.CustLaborTotalAfterDisc;
|
|
@@ -925,6 +926,50 @@ class ROTotalsService {
|
|
|
925
926
|
}
|
|
926
927
|
return TotalTaxAmt;
|
|
927
928
|
}
|
|
929
|
+
static GetCustPartCESSTaxTotal(OpsList, PartsList, IsTaxable, isWorkOrder) {
|
|
930
|
+
let TotalTaxAmt = 0;
|
|
931
|
+
if (IsTaxable) {
|
|
932
|
+
PartsList.forEach((Part) => {
|
|
933
|
+
if (!tr_utils_1.TrUtils.IsNull(Part.CollId)) {
|
|
934
|
+
if (isWorkOrder) {
|
|
935
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.CCESS);
|
|
936
|
+
}
|
|
937
|
+
else {
|
|
938
|
+
if (Part.Sts !== enums_1.LaborStatusEnum.New && Part.Sts !== enums_1.LaborStatusEnum.WtngForAppr) {
|
|
939
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.CCESS);
|
|
940
|
+
}
|
|
941
|
+
else {
|
|
942
|
+
if (Part.PBy === enums_1.PayTypeEnum.Customer) {
|
|
943
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.ECESS);
|
|
944
|
+
}
|
|
945
|
+
}
|
|
946
|
+
}
|
|
947
|
+
}
|
|
948
|
+
else {
|
|
949
|
+
if (isWorkOrder) {
|
|
950
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.CCESS);
|
|
951
|
+
}
|
|
952
|
+
else {
|
|
953
|
+
let Index = OpsList.findIndex((labor) => {
|
|
954
|
+
return labor._id === Part.OpId;
|
|
955
|
+
});
|
|
956
|
+
if (Index !== -1) {
|
|
957
|
+
if (OpsList[Index].Sts !== enums_1.LaborStatusEnum.New && OpsList[Index].Sts !== enums_1.LaborStatusEnum.WtngForAppr) {
|
|
958
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.CCESS);
|
|
959
|
+
}
|
|
960
|
+
else {
|
|
961
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.ECESS);
|
|
962
|
+
}
|
|
963
|
+
}
|
|
964
|
+
else {
|
|
965
|
+
TotalTaxAmt = (0, math_operations_1.Add)(TotalTaxAmt, Part.CCESS);
|
|
966
|
+
}
|
|
967
|
+
}
|
|
968
|
+
}
|
|
969
|
+
});
|
|
970
|
+
}
|
|
971
|
+
return TotalTaxAmt;
|
|
972
|
+
}
|
|
928
973
|
static GetInsLaborCGSTTaxTotal(opCodesList, IsTaxable, isWorkOrder) {
|
|
929
974
|
let TotalTaxAmt = 0;
|
|
930
975
|
if (IsTaxable) {
|
package/package.json
CHANGED
|
@@ -713,9 +713,10 @@ export class ROTotalsService {
|
|
|
713
713
|
argRecordData.CustLaborIGST = this.GetCustLaborIGSTTaxTotal(dupRecordData.Ops, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
714
714
|
|
|
715
715
|
argRecordData.CustPartITax = this.GetCustPartsTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
716
|
-
argRecordData.CustPartCGST = this.GetCustPartCGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
717
|
-
argRecordData.CustPartIGST = this.GetCustPartIGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
718
|
-
argRecordData.CustPartSGST = this.GetCustPartSGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
716
|
+
argRecordData.CustPartCGST = this.GetCustPartCGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
717
|
+
argRecordData.CustPartIGST = this.GetCustPartIGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
718
|
+
argRecordData.CustPartSGST = this.GetCustPartSGSTTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
719
|
+
argRecordData.CustPartCESS = this.GetCustPartCESSTaxTotal(dupRecordData.Ops, dupRecordData.Parts, TrUtils.isTaxable(dupRecordData.Settings.Tax), isWorkOrder);
|
|
719
720
|
|
|
720
721
|
|
|
721
722
|
argRecordData.CustLaborLDiscAmount = this.GetLaborLDiscAmount(argRecordData.CustLaborTotalAfterDisc, argRecordData.LDisc);
|
|
@@ -910,11 +911,11 @@ export class ROTotalsService {
|
|
|
910
911
|
return TotalTaxAmt;
|
|
911
912
|
}
|
|
912
913
|
|
|
913
|
-
static GetCustPartSGSTTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean) {
|
|
914
|
-
let TotalTaxAmt: any = 0;
|
|
915
|
-
if (IsTaxable) {
|
|
916
|
-
PartsList.forEach((Part: any) => {
|
|
917
|
-
if (!TrUtils.IsNull(Part.CollId)) {
|
|
914
|
+
static GetCustPartSGSTTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean) {
|
|
915
|
+
let TotalTaxAmt: any = 0;
|
|
916
|
+
if (IsTaxable) {
|
|
917
|
+
PartsList.forEach((Part: any) => {
|
|
918
|
+
if (!TrUtils.IsNull(Part.CollId)) {
|
|
918
919
|
if (isWorkOrder) {
|
|
919
920
|
TotalTaxAmt = Add(TotalTaxAmt, Part.CSGST);
|
|
920
921
|
} else {
|
|
@@ -945,9 +946,48 @@ export class ROTotalsService {
|
|
|
945
946
|
}
|
|
946
947
|
}
|
|
947
948
|
});
|
|
948
|
-
}
|
|
949
|
-
return TotalTaxAmt;
|
|
950
|
-
}
|
|
949
|
+
}
|
|
950
|
+
return TotalTaxAmt;
|
|
951
|
+
}
|
|
952
|
+
|
|
953
|
+
static GetCustPartCESSTaxTotal(OpsList: any, PartsList: any, IsTaxable: boolean, isWorkOrder: boolean) {
|
|
954
|
+
let TotalTaxAmt: any = 0;
|
|
955
|
+
if (IsTaxable) {
|
|
956
|
+
PartsList.forEach((Part: any) => {
|
|
957
|
+
if (!TrUtils.IsNull(Part.CollId)) {
|
|
958
|
+
if (isWorkOrder) {
|
|
959
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.CCESS);
|
|
960
|
+
} else {
|
|
961
|
+
if (Part.Sts !== LaborStatusEnum.New && Part.Sts !== LaborStatusEnum.WtngForAppr) {
|
|
962
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.CCESS);
|
|
963
|
+
} else {
|
|
964
|
+
if (Part.PBy === PayTypeEnum.Customer) {
|
|
965
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.ECESS);
|
|
966
|
+
}
|
|
967
|
+
}
|
|
968
|
+
}
|
|
969
|
+
} else {
|
|
970
|
+
if (isWorkOrder) {
|
|
971
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.CCESS);
|
|
972
|
+
} else {
|
|
973
|
+
let Index: any = OpsList.findIndex((labor: any) => {
|
|
974
|
+
return labor._id === Part.OpId;
|
|
975
|
+
});
|
|
976
|
+
if (Index !== -1) {
|
|
977
|
+
if (OpsList[Index].Sts !== LaborStatusEnum.New && OpsList[Index].Sts !== LaborStatusEnum.WtngForAppr) {
|
|
978
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.CCESS);
|
|
979
|
+
} else {
|
|
980
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.ECESS);
|
|
981
|
+
}
|
|
982
|
+
} else {
|
|
983
|
+
TotalTaxAmt = Add(TotalTaxAmt, Part.CCESS);
|
|
984
|
+
}
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
});
|
|
988
|
+
}
|
|
989
|
+
return TotalTaxAmt;
|
|
990
|
+
}
|
|
951
991
|
|
|
952
992
|
static GetInsLaborCGSTTaxTotal(opCodesList: any, IsTaxable: boolean, isWorkOrder: boolean) {
|
|
953
993
|
let TotalTaxAmt: any = 0;
|