law-common 12.2.1-beta.7 → 12.3.0
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.
- package/dist/src/api/interface/billing.create.dto.interface.d.ts +3 -2
- package/dist/src/api/interface/billing.entity.response.d.ts +1 -2
- package/dist/src/api/interface/billing.update.dto.interface.d.ts +0 -2
- package/dist/src/entities/index.d.ts +7 -11
- package/dist/src/entities/index.js +7 -12
- package/dist/src/entities/interface/entity.utils.interface.d.ts +3 -6
- package/dist/src/entities/interface/entity.utils.interface.js +0 -2
- package/dist/src/entities/interface/project.entity.interface.d.ts +4 -4
- package/dist/src/entities/model/billing.entity.model.d.ts +1 -12
- package/dist/src/entities/model/billing.entity.model.js +0 -55
- package/dist/src/entities/model/entity.model.interface.js +0 -2
- package/package.json +56 -56
- package/dist/src/entities/enums/billing-particular-line-item.changed-status.enum.d.ts +0 -6
- package/dist/src/entities/enums/billing-particular-line-item.changed-status.enum.js +0 -10
- package/dist/src/entities/enums/billing-particular-line-item.source.enum.d.ts +0 -5
- package/dist/src/entities/enums/billing-particular-line-item.source.enum.js +0 -10
- package/dist/src/entities/interface/billing_particular_line_item.entity.interface.d.ts +0 -19
- package/dist/src/entities/interface/billing_particular_line_item.entity.interface.js +0 -2
- package/dist/src/entities/model/billing-particular-line-item.entity.model.d.ts +0 -19
- package/dist/src/entities/model/billing-particular-line-item.entity.model.js +0 -34
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BillingImpactEnum, BillingReimbursementExpenseChangedStatusEnum, BillingStatusEnum, IBillingEntity,
|
|
1
|
+
import { BillingImpactEnum, BillingReimbursementExpenseChangedStatusEnum, BillingStatusEnum, IBillingEntity, IBillingProfileEntity, IBillingTimesheetEntity, IEntityCreateDto, IProjectEntity, ITimesheetEntity, Nullable } from "../../entities";
|
|
2
2
|
import { IAppFileConfig } from "../../misc";
|
|
3
3
|
export type IBillingCreateExclude = "paymentStatus" | "status" | "writeoffAmount" | "tdsAmount" | "totalAmountPaid" | "creditNoteAmount" | "refundAmount" | "invoicePdfUrl" | "startDate" | "endDate" | "invoiceNumber" | "draftInvoiceNumber";
|
|
4
4
|
export interface IBillingCreateDto extends Omit<IEntityCreateDto<IBillingEntity>, IBillingCreateExclude | "particulars"> {
|
|
@@ -6,12 +6,13 @@ export interface IBillingCreateDto extends Omit<IEntityCreateDto<IBillingEntity>
|
|
|
6
6
|
status?: BillingStatusEnum;
|
|
7
7
|
reimbursementExpenses?: IBillingReimbursementExpenseCreateDtoDetails[];
|
|
8
8
|
particulars: IBillingParticulars;
|
|
9
|
-
billingParticularLineItems?: IBillingParticularLineItemCreateDto[];
|
|
10
9
|
startDate?: string;
|
|
11
10
|
endDate?: string;
|
|
12
11
|
}
|
|
13
12
|
export interface IBillingParticulars {
|
|
14
13
|
invoiceDescription: string;
|
|
14
|
+
invoiceText?: string;
|
|
15
|
+
opeText?: string;
|
|
15
16
|
includeOpeSummary: boolean;
|
|
16
17
|
includePONumber: 0 | 1;
|
|
17
18
|
includeGSTNumber: 0 | 1;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { BillingActionsEnum, BillingStatusEnum, EntityModelRelationHelper, IBillingEntity,
|
|
1
|
+
import { BillingActionsEnum, BillingStatusEnum, EntityModelRelationHelper, IBillingEntity, IBillingReimbursementExpenseEntity, IBillingTimesheetEntity, IProjectEntity, IUserEntity } from "../../entities";
|
|
2
2
|
import { IUpdateBillingDto } from "./billing.update.dto.interface";
|
|
3
3
|
export type IBillingEntityResponse = {
|
|
4
4
|
billing: IBillingEntity;
|
|
5
5
|
billingReimbursementExpenses?: IBillingReimbursementExpenseEntity[];
|
|
6
6
|
billingTimesheets?: IBillingTimesheetEntity[];
|
|
7
|
-
billingParticularLineItems?: IBillingParticularLineItemEntity[];
|
|
8
7
|
};
|
|
9
8
|
export interface IUserEntityRelation {
|
|
10
9
|
users?: IUserEntity[];
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { BillingActionsEnum, IBillingEntity, IBillingProfileEntity, IBillingReimbursementExpenseUpdateDto, IBillingTimesheetUpdateDto, IEntityUpdateDto } from "../../entities";
|
|
2
|
-
import { IBillingParticularLineItemUpdateDto } from "../../entities/interface/billing_particular_line_item.entity.interface";
|
|
3
2
|
import { IBillingEntityCreateDtoValidationData, IBillingParticulars } from "./billing.create.dto.interface";
|
|
4
3
|
export type IBillingUpdateDtoExclude = "draftInvoiceNumber" | "invoiceNumber";
|
|
5
4
|
export interface IBillingUpdateDto extends Omit<IEntityUpdateDto<IBillingEntity>, IBillingUpdateDtoExclude> {
|
|
@@ -9,7 +8,6 @@ export interface IUpdateBillingDto extends Omit<IBillingUpdateDto, "particulars"
|
|
|
9
8
|
timesheets?: IBillingTimesheetUpdateDto[];
|
|
10
9
|
reimbursementExpenses?: IBillingReimbursementExpenseUpdateDto[];
|
|
11
10
|
particulars?: IBillingParticulars;
|
|
12
|
-
billingParticularLineItems?: IBillingParticularLineItemUpdateDto[];
|
|
13
11
|
}
|
|
14
12
|
export interface IBillingUpdateDtoValidationData extends IBillingEntityCreateDtoValidationData {
|
|
15
13
|
billingEntity: IBillingEntity;
|
|
@@ -38,8 +38,8 @@ export * from "./interface/billing_history.entity.interface";
|
|
|
38
38
|
export * from "./interface/billing_timesheet_history.entity.interface";
|
|
39
39
|
export * from "./enums/history_operation.enum";
|
|
40
40
|
export * from "./enums/timesheet.action.enum";
|
|
41
|
-
export * from "./enums/timesheet.classification.status.enum";
|
|
42
41
|
export * from "./enums/timesheet.status.enum";
|
|
42
|
+
export * from "./enums/timesheet.classification.status.enum";
|
|
43
43
|
export * from "./enums/billing.action.enum";
|
|
44
44
|
export * from "./enums/configuration.type.enum";
|
|
45
45
|
export * from "./enums/project_user_status.enum";
|
|
@@ -224,32 +224,28 @@ export * from "./interface/entity_history.entity.interface";
|
|
|
224
224
|
export * from "./model/entity_history.entity.model";
|
|
225
225
|
export * from "./enums/vendor_invoice_payment_mode_enum";
|
|
226
226
|
export * from "./enums/vendor_invoice_payment_status_enum";
|
|
227
|
-
export * from "./flow-configs/vendor_invoice_payment_flow.config";
|
|
228
227
|
export * from "./interface/vendor_invoice_payment.entity.interface";
|
|
229
228
|
export * from "./model/vendor_invoice_payment.entity.model";
|
|
229
|
+
export * from "./flow-configs/vendor_invoice_payment_flow.config";
|
|
230
230
|
export * from "./enums/leave_approval_status_enum";
|
|
231
231
|
export * from "./flow-configs/leave_approval_flow.config";
|
|
232
232
|
export * from "./interface/leave_approval.entity.interface";
|
|
233
233
|
export * from "./model/leave_approval.entity.model";
|
|
234
234
|
export * from "./enums/vendor_tds_liability_paid_status_enum";
|
|
235
235
|
export * from "./enums/vendor_tds_liability_status_enum";
|
|
236
|
-
export * from "./flow-configs/vendor_tds_liability_flow.config";
|
|
237
236
|
export * from "./interface/vendor_tds_liability.entity.interface";
|
|
238
237
|
export * from "./model/vendor_tds_liability.entity.model";
|
|
238
|
+
export * from "./flow-configs/vendor_tds_liability_flow.config";
|
|
239
239
|
export * from "./enums/vendor_tds_challan_status_enum";
|
|
240
|
-
export * from "./flow-configs/vendor_tds_challan_flow.config";
|
|
241
240
|
export * from "./interface/vendor_tds_challan.entity.interface";
|
|
242
241
|
export * from "./model/vendor_tds_challan.entity.model";
|
|
243
|
-
export * from "./
|
|
242
|
+
export * from "./flow-configs/vendor_tds_challan_flow.config";
|
|
244
243
|
export * from "./enums/vendor_advance_status_enum";
|
|
245
|
-
export * from "./
|
|
244
|
+
export * from "./enums/vendor_advance_payment_mode";
|
|
246
245
|
export * from "./interface/vendor_advance.entity.interface";
|
|
247
246
|
export * from "./model/vendor_advance.entity.model";
|
|
247
|
+
export * from "./flow-configs/vendor_advance_flow.config";
|
|
248
248
|
export * from "./enums/vendor_invoice_advance_status_enum";
|
|
249
|
-
export * from "./flow-configs/vendor_invoice_advance_flow.config";
|
|
250
249
|
export * from "./interface/vendor_invoice_advance.entity.interface";
|
|
251
250
|
export * from "./model/vendor_invoice_advance.entity.model";
|
|
252
|
-
export * from "./
|
|
253
|
-
export * from "./enums/billing-particular-line-item.source.enum";
|
|
254
|
-
export * from "./interface/billing_particular_line_item.entity.interface";
|
|
255
|
-
export * from "./model/billing-particular-line-item.entity.model";
|
|
251
|
+
export * from "./flow-configs/vendor_invoice_advance_flow.config";
|
|
@@ -54,8 +54,8 @@ __exportStar(require("./interface/billing_history.entity.interface"), exports);
|
|
|
54
54
|
__exportStar(require("./interface/billing_timesheet_history.entity.interface"), exports);
|
|
55
55
|
__exportStar(require("./enums/history_operation.enum"), exports);
|
|
56
56
|
__exportStar(require("./enums/timesheet.action.enum"), exports);
|
|
57
|
-
__exportStar(require("./enums/timesheet.classification.status.enum"), exports);
|
|
58
57
|
__exportStar(require("./enums/timesheet.status.enum"), exports);
|
|
58
|
+
__exportStar(require("./enums/timesheet.classification.status.enum"), exports);
|
|
59
59
|
__exportStar(require("./enums/billing.action.enum"), exports);
|
|
60
60
|
__exportStar(require("./enums/configuration.type.enum"), exports);
|
|
61
61
|
__exportStar(require("./enums/project_user_status.enum"), exports);
|
|
@@ -240,33 +240,28 @@ __exportStar(require("./interface/entity_history.entity.interface"), exports);
|
|
|
240
240
|
__exportStar(require("./model/entity_history.entity.model"), exports);
|
|
241
241
|
__exportStar(require("./enums/vendor_invoice_payment_mode_enum"), exports);
|
|
242
242
|
__exportStar(require("./enums/vendor_invoice_payment_status_enum"), exports);
|
|
243
|
-
__exportStar(require("./flow-configs/vendor_invoice_payment_flow.config"), exports);
|
|
244
243
|
__exportStar(require("./interface/vendor_invoice_payment.entity.interface"), exports);
|
|
245
244
|
__exportStar(require("./model/vendor_invoice_payment.entity.model"), exports);
|
|
245
|
+
__exportStar(require("./flow-configs/vendor_invoice_payment_flow.config"), exports);
|
|
246
246
|
__exportStar(require("./enums/leave_approval_status_enum"), exports);
|
|
247
247
|
__exportStar(require("./flow-configs/leave_approval_flow.config"), exports);
|
|
248
248
|
__exportStar(require("./interface/leave_approval.entity.interface"), exports);
|
|
249
249
|
__exportStar(require("./model/leave_approval.entity.model"), exports);
|
|
250
250
|
__exportStar(require("./enums/vendor_tds_liability_paid_status_enum"), exports);
|
|
251
251
|
__exportStar(require("./enums/vendor_tds_liability_status_enum"), exports);
|
|
252
|
-
__exportStar(require("./flow-configs/vendor_tds_liability_flow.config"), exports);
|
|
253
252
|
__exportStar(require("./interface/vendor_tds_liability.entity.interface"), exports);
|
|
254
253
|
__exportStar(require("./model/vendor_tds_liability.entity.model"), exports);
|
|
254
|
+
__exportStar(require("./flow-configs/vendor_tds_liability_flow.config"), exports);
|
|
255
255
|
__exportStar(require("./enums/vendor_tds_challan_status_enum"), exports);
|
|
256
|
-
__exportStar(require("./flow-configs/vendor_tds_challan_flow.config"), exports);
|
|
257
256
|
__exportStar(require("./interface/vendor_tds_challan.entity.interface"), exports);
|
|
258
257
|
__exportStar(require("./model/vendor_tds_challan.entity.model"), exports);
|
|
259
|
-
__exportStar(require("./
|
|
258
|
+
__exportStar(require("./flow-configs/vendor_tds_challan_flow.config"), exports);
|
|
260
259
|
__exportStar(require("./enums/vendor_advance_status_enum"), exports);
|
|
261
|
-
__exportStar(require("./
|
|
260
|
+
__exportStar(require("./enums/vendor_advance_payment_mode"), exports);
|
|
262
261
|
__exportStar(require("./interface/vendor_advance.entity.interface"), exports);
|
|
263
262
|
__exportStar(require("./model/vendor_advance.entity.model"), exports);
|
|
263
|
+
__exportStar(require("./flow-configs/vendor_advance_flow.config"), exports);
|
|
264
264
|
__exportStar(require("./enums/vendor_invoice_advance_status_enum"), exports);
|
|
265
|
-
__exportStar(require("./flow-configs/vendor_invoice_advance_flow.config"), exports);
|
|
266
265
|
__exportStar(require("./interface/vendor_invoice_advance.entity.interface"), exports);
|
|
267
266
|
__exportStar(require("./model/vendor_invoice_advance.entity.model"), exports);
|
|
268
|
-
|
|
269
|
-
__exportStar(require("./enums/billing-particular-line-item.changed-status.enum"), exports);
|
|
270
|
-
__exportStar(require("./enums/billing-particular-line-item.source.enum"), exports);
|
|
271
|
-
__exportStar(require("./interface/billing_particular_line_item.entity.interface"), exports);
|
|
272
|
-
__exportStar(require("./model/billing-particular-line-item.entity.model"), exports);
|
|
267
|
+
__exportStar(require("./flow-configs/vendor_invoice_advance_flow.config"), exports);
|
|
@@ -78,7 +78,6 @@ import { WebsiteLeadEntityModel } from "../model/website_lead.entity.model";
|
|
|
78
78
|
import { WebsiteNewsletterSubscriptionEntityModel } from "../model/website_newsletter_subscription.entity.model";
|
|
79
79
|
import { WorkFromHomeEntityModel } from "../model/work-from-home.entity.model";
|
|
80
80
|
import { WorkFromHomeHistoryEntityModel } from "../model/work_from_home_history.entity.model";
|
|
81
|
-
import { BillingParticularLineItemEntityModel } from "../model/billing-particular-line-item.entity.model";
|
|
82
81
|
import { IAddressBookEntity } from "./address-book.entity.interface";
|
|
83
82
|
import { AggregationFields, IEntityAggregationConfig } from "./aggregation.utils";
|
|
84
83
|
import { IBankEntity } from "./bank.entity.interface";
|
|
@@ -151,7 +150,6 @@ import { IWebsiteLeadEntity } from "./website_lead.entity.interface";
|
|
|
151
150
|
import { IWebsiteNewsletterSubscriptionEntity } from "./website_newsletter_subscription.entity.interface";
|
|
152
151
|
import { IWorkFromHomeEntity } from "./work_from_home.entity.interface";
|
|
153
152
|
import { IWorkFromHomeHistoryEntity } from "./work_from_home_history.entity.interface";
|
|
154
|
-
import { IBillingParticularLineItemEntity } from "./billing_particular_line_item.entity.interface";
|
|
155
153
|
export type IApiEntity<T> = Modify<T, {
|
|
156
154
|
createdOn: string;
|
|
157
155
|
updatedOn: string;
|
|
@@ -263,8 +261,7 @@ export declare enum EntityEnum {
|
|
|
263
261
|
VENDOR_TDS_LIABILITY = "vendor_tds_liability",
|
|
264
262
|
VENDOR_TDS_CHALLAN = "vendor_tds_challan",
|
|
265
263
|
VENDOR_ADVANCE = "vendor_advance",
|
|
266
|
-
VENDOR_INVOICE_ADVANCE = "vendor_invoice_advance"
|
|
267
|
-
BILLING_PARTICULAR_LINE_ITEM = "billing_particular_line_item"
|
|
264
|
+
VENDOR_INVOICE_ADVANCE = "vendor_invoice_advance"
|
|
268
265
|
}
|
|
269
266
|
export type EntityRelations = {
|
|
270
267
|
[K in EntityEnum | VirtualEntityEnum]: K;
|
|
@@ -289,7 +286,7 @@ export type IBaseEntityApiResponse<T> = {
|
|
|
289
286
|
[key in EntityEnum | VirtualEntityEnum]?: AggregationFields<EnumToModel<key>>[];
|
|
290
287
|
};
|
|
291
288
|
};
|
|
292
|
-
export type EnumEntityType<T extends EntityEnum | VirtualEntityEnum> = (T extends EntityEnum.BILLING ? IBillingEntity : T extends EntityEnum.BILLING_HISTORY ? IBillingHistoryEntity : T extends EntityEnum.MOVING_TIMESHEET ? IMovingTimesheetEntity : T extends EntityEnum.BILLING_TIMESHEET ? IBillingTimesheetEntity : T extends EntityEnum.BILLING_REIMBURSEMENT_EXPENSE ? IBillingReimbursementExpenseEntity : T extends EntityEnum.BILLING_TIMESHEET_HISTORY ? IBillingTimesheetHistoryEntity : T extends EntityEnum.BILLING_REIMBURESMENT_EXPENSE_HISTORY ? IBillingReimbursementExpenseHistoryEntity : T extends EntityEnum.
|
|
289
|
+
export type EnumEntityType<T extends EntityEnum | VirtualEntityEnum> = (T extends EntityEnum.BILLING ? IBillingEntity : T extends EntityEnum.BILLING_HISTORY ? IBillingHistoryEntity : T extends EntityEnum.MOVING_TIMESHEET ? IMovingTimesheetEntity : T extends EntityEnum.BILLING_TIMESHEET ? IBillingTimesheetEntity : T extends EntityEnum.BILLING_REIMBURSEMENT_EXPENSE ? IBillingReimbursementExpenseEntity : T extends EntityEnum.BILLING_TIMESHEET_HISTORY ? IBillingTimesheetHistoryEntity : T extends EntityEnum.BILLING_REIMBURESMENT_EXPENSE_HISTORY ? IBillingReimbursementExpenseHistoryEntity : T extends EntityEnum.TIMESHEET ? ITimesheetEntity : T extends EntityEnum.USER ? IUserEntity : T extends EntityEnum.PROJECT ? IProjectEntity : T extends EntityEnum.CLIENT ? IClientEntity : T extends EntityEnum.LEAVE ? ILeaveEntity : T extends EntityEnum.BANK ? IBankEntity : T extends EntityEnum.BILLING_TRANSACTION ? IBillingTransactionEntity : T extends EntityEnum.BILLING_TRANSACTION_HISTORY ? IBillingTransactionHistoryEntity : T extends EntityEnum.CLIENT_AFFILIATE ? IClientAffiliateEntity : T extends EntityEnum.CONFIGURATION ? IConfigurationEntity : T extends EntityEnum.HOLIDAY ? IHolidayEntity : T extends EntityEnum.HOLIDAY_LIST ? IHolidayListEntity : T extends EntityEnum.COUNTRY ? ICountryEntity : T extends EntityEnum.EXPENSE_TYPE ? IExpenseTypeEntity : T extends EntityEnum.INDUSTRY ? IIndustryEntity : T extends EntityEnum.INTERMEDIARY_BANK ? IIntermediaryBankEntity : T extends EntityEnum.OFFICE_LOCATION ? IOfficeLocationEntity : T extends EntityEnum.PERMISSION ? IPermissionEntity : T extends EntityEnum.ROLE ? IRoleEntity : T extends EntityEnum.TASK ? ITaskEntity : T extends EntityEnum.DESIGNATION ? IDesignationEntity : T extends EntityEnum.RATE ? IRateEntity : T extends EntityEnum.REIMBURSEMENT ? IReimbursementEntity : T extends EntityEnum.REIMBURSEMENT_EXPENSE ? IReimbursementExpenseEntity : T extends EntityEnum.REIMBURSEMENT_HISTORY ? IReimbursementHistoryEntity : T extends EntityEnum.WORK_FROM_HOME ? IWorkFromHomeEntity : T extends EntityEnum.ORGANIZATION ? IOrganizationEntity : T extends EntityEnum.PROJECT_USER_MAPPING ? IProjectUserMappingEntity : T extends EntityEnum.CLIENT_USER_MAPPING ? IClientUserMappingEntity : T extends EntityEnum.CLIENT_INTRODUCING_MAPPING ? IClientIntroducingMappingEntity : T extends EntityEnum.TO_DO_LIST ? IToDoListEntity : T extends EntityEnum.CRON_JOBS ? ICronJobsEntity : T extends EntityEnum.ROLE_PERMISSION_MAPPING ? IRolePermissionMappingEntity : T extends EntityEnum.BANK_HISTORY ? IBankHistoryEntity : T extends VirtualEntityEnum.LEAVE_COUNT ? ILeaveCountVirtualEntity : T extends EntityEnum.LEAVE_HISTORY ? ILeaveHistoryEntity : T extends EntityEnum.WORK_FROM_HOME_HISTORY ? IWorkFromHomeHistoryEntity : T extends EntityEnum.TIMESHEET_HISTORY ? ITimesheetHistoryEntity : T extends EntityEnum.ADDRESS_BOOK ? IAddressBookEntity : T extends EntityEnum.STATE ? IStateEntity : T extends EntityEnum.GST_RATE ? IGstRateEntity : T extends EntityEnum.ORGANIZATION_TYPE ? IOrganizationTypeEntity : T extends EntityEnum.TDS_RATE ? ITdsRateEntity : T extends EntityEnum.ORGANIZATION_TYPE_TDS_RATE_MAPPING ? IOrganizationTypeTdsRateMappingEntity : T extends EntityEnum.VOUCHER_TYPE ? IVoucherTypeEntity : T extends EntityEnum.TDS_RATE_VOUCHER_TYPE_MAPPING ? ITdsRateVoucherTypeMappingEntity : T extends EntityEnum.EXPENSE_HEAD ? IExpenseHeadEntity : T extends EntityEnum.DOCUMENT_UPLOAD ? IDocumentUploadEntity : T extends EntityEnum.VENDOR ? IVendorEntity : T extends EntityEnum.VENDOR_INVOICE ? IVendorInvoiceEntity : T extends EntityEnum.VENDOR_INVOICE_HISTORY ? IVendorInvoiceHistoryEntity : T extends EntityEnum.VENDOR_INVOICE_HISTORY ? IVendorInvoiceHistoryEntity : T extends EntityEnum.VENDOR_INVOICE_ITEM ? IVendorInvoiceItemEntity : T extends EntityEnum.VENDOR_INVOICE_ITEM_HISTORY ? IVendorInvoiceItemHistoryEntity : T extends EntityEnum.VENDOR_HISTORY ? IVendorHistoryEntity : T extends EntityEnum.WEBSITE_LEAD ? IWebsiteLeadEntity : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? IWebsiteNewsletterSubscriptionEntity : T extends EntityEnum.CLIENT_QUOTE ? IClientQuoteEntity : T extends EntityEnum.CLIENT_QUOTE_RATE ? IClientQuoteRateEntity : T extends EntityEnum.BILLING_PROFILE ? IBillingProfileEntity : T extends EntityEnum.PROJECT_REVENUE_SPLIT_MAPPING ? IProjectRevenueSplitMappingEntity : T extends EntityEnum.VENDOR_INVOICE_ITEM_HISTORY ? IVendorInvoiceItemHistoryEntity : T extends EntityEnum.VENDOR_HISTORY ? IVendorHistoryEntity : T extends EntityEnum.WEBSITE_LEAD ? IWebsiteLeadEntity : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? IWebsiteNewsletterSubscriptionEntity : T extends EntityEnum.CLIENT_QUOTE ? IClientQuoteEntity : T extends EntityEnum.CLIENT_QUOTE_RATE ? IClientQuoteRateEntity : T extends EntityEnum.ENTITY_HISTORY ? IEntityHistoryEntity : T extends EntityEnum.LEAVE_APPROVAL ? ILeaveApprovalEntity : T extends EntityEnum.VENDOR_INVOICE_PAYMENT ? IVendorInvoicePaymentEntity : T extends EntityEnum.VENDOR_TDS_LIABILITY ? IVendorTdsLiabilityEntity : T extends EntityEnum.VENDOR_TDS_CHALLAN ? IVendorTdsChallanEntity : T extends EntityEnum.VENDOR_ADVANCE ? IVendorAdvanceEntity : T extends EntityEnum.VENDOR_INVOICE_ADVANCE ? IVendorInvoiceAdvanceEntity : never) & {
|
|
293
290
|
id: number;
|
|
294
291
|
};
|
|
295
292
|
export type EntityRelationConfig<T extends EntityEnum | VirtualEntityEnum> = {
|
|
@@ -421,7 +418,7 @@ export declare enum VirtualEntityEnum {
|
|
|
421
418
|
}
|
|
422
419
|
export type IHistoryConstraintSearchResponse<T> = IBaseResponse<IHistoryEntitySearchByConstraintResponse<T>[]>;
|
|
423
420
|
export type IHistoryConstraintSearchServiceResponse<T> = IHistoryEntitySearchByConstraintResponse<T>[];
|
|
424
|
-
export type EnumToModel<T extends EntityEnum | VirtualEntityEnum> = T extends EntityEnum.BILLING ? BillingEntityModel : T extends EntityEnum.BILLING_HISTORY ? BillingHistoryEntityModel : T extends EntityEnum.CLIENT ? ClientEntityModel : T extends EntityEnum.INTERMEDIARY_BANK ? IntermediaryBankEntityModel : T extends EntityEnum.PROJECT ? ProjectEntityModel : T extends EntityEnum.PROJECT_USER_MAPPING ? ProjectUserMappingEntityModel : T extends EntityEnum.REIMBURSEMENT ? ReimbursementEntityModel : T extends EntityEnum.REIMBURSEMENT_EXPENSE ? ReimbursementExpenseEntityModel : T extends EntityEnum.BILLING_REIMBURSEMENT_EXPENSE ? BillingReimbursementExpneseEntityModel : T extends EntityEnum.BILLING_REIMBURESMENT_EXPENSE_HISTORY ? BillingReimbursementExpenseHistoryEntityModel : T extends EntityEnum.LEAVE ? LeaveEntityModel : T extends EntityEnum.WORK_FROM_HOME ? WorkFromHomeEntityModel : T extends EntityEnum.HOLIDAY ? HolidayEntityModel : T extends VirtualEntityEnum.LEAVE_COUNT ? LeaveCountVirtualEntityModel : T extends EntityEnum.CLIENT_AFFILIATE ? ClientAffiliateEntityModel : T extends EntityEnum.BANK ? BankEntityModel : T extends EntityEnum.CONFIGURATION ? ConfigurationEntityModel : T extends EntityEnum.TASK ? TaskEntityModel : T extends EntityEnum.BILLING_TIMESHEET ? BillingTimesheetEntityModel : T extends EntityEnum.BILLING_TIMESHEET_HISTORY ? BillingTimesheetHistoryEntityModel : T extends EntityEnum.TIMESHEET ? TimesheetEntityModel : T extends EntityEnum.MOVING_TIMESHEET ? MovingTimesheetEntityModel : T extends EntityEnum.TIMESHEET_HISTORY ? TimesheetHistoryEntityModel : T extends EntityEnum.COUNTRY ? CountryEntityModel : T extends EntityEnum.BILLING_TRANSACTION ? BillingTransactionEntityModel : T extends EntityEnum.BILLING_TRANSACTION_HISTORY ? BillingTransactionHistoryEntityModel : T extends EntityEnum.ADDRESS_BOOK ? AddressBookEntityModel : T extends EntityEnum.STATE ? StateEntityModel : T extends EntityEnum.GST_RATE ? GstRateEntityModel : T extends EntityEnum.ORGANIZATION_TYPE ? OrganizationTypeEntityModel : T extends EntityEnum.TDS_RATE ? TdsRateEntityModel : T extends EntityEnum.ORGANIZATION_TYPE_TDS_RATE_MAPPING ? OrganizationTypeTdsRateMappingEntityModel : T extends EntityEnum.VOUCHER_TYPE ? VoucherTypeEntityModel : T extends EntityEnum.TDS_RATE_VOUCHER_TYPE_MAPPING ? TdsRateVoucherTypeMappingEntityModel : T extends EntityEnum.ORGANIZATION ? OrganizationEntityModel : T extends EntityEnum.INDUSTRY ? IndustryEntityModel : T extends EntityEnum.EXPENSE_TYPE ? ExpenseTypeEntityModel : T extends EntityEnum.DESIGNATION ? DesignationEntityModel : T extends EntityEnum.RATE ? RateEntityModel : T extends EntityEnum.ROLE ? RoleEntityModel : T extends EntityEnum.ROLE_PERMISSION_MAPPING ? RolePermissionMappingEntityModel : T extends EntityEnum.PERMISSION ? PermissionEntityModel : T extends EntityEnum.EXPENSE_HEAD ? ExpenseHeadEntityModel : T extends EntityEnum.DOCUMENT_UPLOAD ? DocumentUploadEntityModel : T extends EntityEnum.VENDOR ? VendorEntityModel : T extends EntityEnum.VENDOR_INVOICE ? VendorInvoiceEntityModel : T extends EntityEnum.VENDOR_INVOICE_HISTORY ? VendorInvoiceHistoryEntityModel : T extends EntityEnum.OFFICE_LOCATION ? OfficeLocationEntityModel : T extends EntityEnum.VENDOR_INVOICE_ITEM ? VendorInvoiceItemEntityModel : T extends EntityEnum.VENDOR_INVOICE_ITEM_HISTORY ? VendorInvoiceItemHistoryEntityModel : T extends EntityEnum.VENDOR_HISTORY ? VendorHistoryEntityModel : T extends EntityEnum.WEBSITE_LEAD ? WebsiteLeadEntityModel : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? WebsiteNewsletterSubscriptionEntityModel : T extends EntityEnum.WORK_FROM_HOME_HISTORY ? WorkFromHomeHistoryEntityModel : T extends EntityEnum.LEAVE_HISTORY ? LeaveHistoryEntityModel : T extends EntityEnum.BANK_HISTORY ? BankHistoryEntityModel : T extends EntityEnum.REIMBURSEMENT_HISTORY ? ReimbursementHistoryEntityModel : T extends EntityEnum.CLIENT_USER_MAPPING ? ClientUserMappingEntityModel : T extends EntityEnum.CLIENT_INTRODUCING_MAPPING ? ClientIntroducingMappingEntityModel : T extends EntityEnum.HOLIDAY_LIST ? HolidayListEntityModel : T extends EntityEnum.CRON_JOBS ? CronJobsEntityModel : T extends EntityEnum.TO_DO_LIST ? ToDoListEntityModel : T extends EntityEnum.CLIENT_QUOTE ? ClientQuoteEntityModel : T extends EntityEnum.CLIENT_QUOTE_RATE ? ClientQuoteRateEntityModel : T extends EntityEnum.BILLING_PROFILE ? BillingProfileEntityModel : T extends EntityEnum.PROJECT_REVENUE_SPLIT_MAPPING ? ProjectRevenueSplitMappingEntityModel : T extends EntityEnum.WEBSITE_LEAD ? WebsiteLeadEntityModel : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? WebsiteNewsletterSubscriptionEntityModel : T extends EntityEnum.CLIENT_QUOTE ? ClientQuoteEntityModel : T extends EntityEnum.CLIENT_QUOTE_RATE ? ClientQuoteRateEntityModel : T extends EntityEnum.DESIGNATION ? DesignationEntityModel : T extends EntityEnum.RATE ? RateEntityModel : T extends EntityEnum.ENTITY_HISTORY ? EntityHistoryEntityModel : T extends EntityEnum.LEAVE_APPROVAL ? LeaveApprovalEntityModel : T extends EntityEnum.VENDOR_INVOICE_PAYMENT ? VendorInvoicePaymentEntityModel : T extends EntityEnum.VENDOR_TDS_LIABILITY ? VendorTdsLiabilityEntityModel : T extends EntityEnum.VENDOR_TDS_CHALLAN ? VendorTdsChallanEntityModel : T extends EntityEnum.VENDOR_ADVANCE ? VendorAdvanceEntityModel : T extends EntityEnum.VENDOR_INVOICE_ADVANCE ? VendorInvoiceAdvanceEntityModel :
|
|
421
|
+
export type EnumToModel<T extends EntityEnum | VirtualEntityEnum> = T extends EntityEnum.BILLING ? BillingEntityModel : T extends EntityEnum.BILLING_HISTORY ? BillingHistoryEntityModel : T extends EntityEnum.CLIENT ? ClientEntityModel : T extends EntityEnum.INTERMEDIARY_BANK ? IntermediaryBankEntityModel : T extends EntityEnum.PROJECT ? ProjectEntityModel : T extends EntityEnum.PROJECT_USER_MAPPING ? ProjectUserMappingEntityModel : T extends EntityEnum.REIMBURSEMENT ? ReimbursementEntityModel : T extends EntityEnum.REIMBURSEMENT_EXPENSE ? ReimbursementExpenseEntityModel : T extends EntityEnum.BILLING_REIMBURSEMENT_EXPENSE ? BillingReimbursementExpneseEntityModel : T extends EntityEnum.BILLING_REIMBURESMENT_EXPENSE_HISTORY ? BillingReimbursementExpenseHistoryEntityModel : T extends EntityEnum.LEAVE ? LeaveEntityModel : T extends EntityEnum.WORK_FROM_HOME ? WorkFromHomeEntityModel : T extends EntityEnum.HOLIDAY ? HolidayEntityModel : T extends VirtualEntityEnum.LEAVE_COUNT ? LeaveCountVirtualEntityModel : T extends EntityEnum.CLIENT_AFFILIATE ? ClientAffiliateEntityModel : T extends EntityEnum.BANK ? BankEntityModel : T extends EntityEnum.CONFIGURATION ? ConfigurationEntityModel : T extends EntityEnum.TASK ? TaskEntityModel : T extends EntityEnum.BILLING_TIMESHEET ? BillingTimesheetEntityModel : T extends EntityEnum.BILLING_TIMESHEET_HISTORY ? BillingTimesheetHistoryEntityModel : T extends EntityEnum.TIMESHEET ? TimesheetEntityModel : T extends EntityEnum.MOVING_TIMESHEET ? MovingTimesheetEntityModel : T extends EntityEnum.TIMESHEET_HISTORY ? TimesheetHistoryEntityModel : T extends EntityEnum.COUNTRY ? CountryEntityModel : T extends EntityEnum.BILLING_TRANSACTION ? BillingTransactionEntityModel : T extends EntityEnum.BILLING_TRANSACTION_HISTORY ? BillingTransactionHistoryEntityModel : T extends EntityEnum.ADDRESS_BOOK ? AddressBookEntityModel : T extends EntityEnum.STATE ? StateEntityModel : T extends EntityEnum.GST_RATE ? GstRateEntityModel : T extends EntityEnum.ORGANIZATION_TYPE ? OrganizationTypeEntityModel : T extends EntityEnum.TDS_RATE ? TdsRateEntityModel : T extends EntityEnum.ORGANIZATION_TYPE_TDS_RATE_MAPPING ? OrganizationTypeTdsRateMappingEntityModel : T extends EntityEnum.VOUCHER_TYPE ? VoucherTypeEntityModel : T extends EntityEnum.TDS_RATE_VOUCHER_TYPE_MAPPING ? TdsRateVoucherTypeMappingEntityModel : T extends EntityEnum.ORGANIZATION ? OrganizationEntityModel : T extends EntityEnum.INDUSTRY ? IndustryEntityModel : T extends EntityEnum.EXPENSE_TYPE ? ExpenseTypeEntityModel : T extends EntityEnum.DESIGNATION ? DesignationEntityModel : T extends EntityEnum.RATE ? RateEntityModel : T extends EntityEnum.ROLE ? RoleEntityModel : T extends EntityEnum.ROLE_PERMISSION_MAPPING ? RolePermissionMappingEntityModel : T extends EntityEnum.PERMISSION ? PermissionEntityModel : T extends EntityEnum.EXPENSE_HEAD ? ExpenseHeadEntityModel : T extends EntityEnum.DOCUMENT_UPLOAD ? DocumentUploadEntityModel : T extends EntityEnum.VENDOR ? VendorEntityModel : T extends EntityEnum.VENDOR_INVOICE ? VendorInvoiceEntityModel : T extends EntityEnum.VENDOR_INVOICE_HISTORY ? VendorInvoiceHistoryEntityModel : T extends EntityEnum.OFFICE_LOCATION ? OfficeLocationEntityModel : T extends EntityEnum.VENDOR_INVOICE_ITEM ? VendorInvoiceItemEntityModel : T extends EntityEnum.VENDOR_INVOICE_ITEM_HISTORY ? VendorInvoiceItemHistoryEntityModel : T extends EntityEnum.VENDOR_HISTORY ? VendorHistoryEntityModel : T extends EntityEnum.WEBSITE_LEAD ? WebsiteLeadEntityModel : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? WebsiteNewsletterSubscriptionEntityModel : T extends EntityEnum.WORK_FROM_HOME_HISTORY ? WorkFromHomeHistoryEntityModel : T extends EntityEnum.LEAVE_HISTORY ? LeaveHistoryEntityModel : T extends EntityEnum.BANK_HISTORY ? BankHistoryEntityModel : T extends EntityEnum.REIMBURSEMENT_HISTORY ? ReimbursementHistoryEntityModel : T extends EntityEnum.CLIENT_USER_MAPPING ? ClientUserMappingEntityModel : T extends EntityEnum.CLIENT_INTRODUCING_MAPPING ? ClientIntroducingMappingEntityModel : T extends EntityEnum.HOLIDAY_LIST ? HolidayListEntityModel : T extends EntityEnum.CRON_JOBS ? CronJobsEntityModel : T extends EntityEnum.TO_DO_LIST ? ToDoListEntityModel : T extends EntityEnum.CLIENT_QUOTE ? ClientQuoteEntityModel : T extends EntityEnum.CLIENT_QUOTE_RATE ? ClientQuoteRateEntityModel : T extends EntityEnum.BILLING_PROFILE ? BillingProfileEntityModel : T extends EntityEnum.PROJECT_REVENUE_SPLIT_MAPPING ? ProjectRevenueSplitMappingEntityModel : T extends EntityEnum.WEBSITE_LEAD ? WebsiteLeadEntityModel : T extends EntityEnum.WEBSITE_NEWSLETTER_SUBSCRIPTION ? WebsiteNewsletterSubscriptionEntityModel : T extends EntityEnum.CLIENT_QUOTE ? ClientQuoteEntityModel : T extends EntityEnum.CLIENT_QUOTE_RATE ? ClientQuoteRateEntityModel : T extends EntityEnum.DESIGNATION ? DesignationEntityModel : T extends EntityEnum.RATE ? RateEntityModel : T extends EntityEnum.ENTITY_HISTORY ? EntityHistoryEntityModel : T extends EntityEnum.LEAVE_APPROVAL ? LeaveApprovalEntityModel : T extends EntityEnum.VENDOR_INVOICE_PAYMENT ? VendorInvoicePaymentEntityModel : T extends EntityEnum.VENDOR_TDS_LIABILITY ? VendorTdsLiabilityEntityModel : T extends EntityEnum.VENDOR_TDS_CHALLAN ? VendorTdsChallanEntityModel : T extends EntityEnum.VENDOR_ADVANCE ? VendorAdvanceEntityModel : T extends EntityEnum.VENDOR_INVOICE_ADVANCE ? VendorInvoiceAdvanceEntityModel : UserEntityModel;
|
|
425
422
|
export type EntityMap = {
|
|
426
423
|
[key in EntityEnum | VirtualEntityEnum]: EnumToModel<key>[];
|
|
427
424
|
} & {
|
|
@@ -106,8 +106,6 @@ var EntityEnum;
|
|
|
106
106
|
EntityEnum["VENDOR_TDS_CHALLAN"] = "vendor_tds_challan";
|
|
107
107
|
EntityEnum["VENDOR_ADVANCE"] = "vendor_advance";
|
|
108
108
|
EntityEnum["VENDOR_INVOICE_ADVANCE"] = "vendor_invoice_advance";
|
|
109
|
-
// LW-773-billing-particular-line-item
|
|
110
|
-
EntityEnum["BILLING_PARTICULAR_LINE_ITEM"] = "billing_particular_line_item";
|
|
111
109
|
})(EntityEnum || (exports.EntityEnum = EntityEnum = {}));
|
|
112
110
|
var VirtualEntityEnum;
|
|
113
111
|
(function (VirtualEntityEnum) {
|
|
@@ -54,13 +54,13 @@ export interface IProjectHourlyRate {
|
|
|
54
54
|
export interface IProjectFixedTypeRate {
|
|
55
55
|
rate: number;
|
|
56
56
|
unit: TimeUnitEnum;
|
|
57
|
-
maxEstimatedHours
|
|
58
|
-
extraHoursRate
|
|
57
|
+
maxEstimatedHours?: number;
|
|
58
|
+
extraHoursRate?: number;
|
|
59
59
|
}
|
|
60
60
|
export interface IProjectAdhocRate {
|
|
61
61
|
rate: number;
|
|
62
|
-
maxEstimatedHours
|
|
63
|
-
extraHoursRate
|
|
62
|
+
maxEstimatedHours?: number;
|
|
63
|
+
extraHoursRate?: number;
|
|
64
64
|
}
|
|
65
65
|
export interface IProjectCreateDtoExtra {
|
|
66
66
|
projectBillingRate: IProjectHourlyRate[] | IProjectFixedTypeRate | IProjectAdhocRate;
|
|
@@ -17,7 +17,6 @@ import { EntityEnum, Nullable } from "../interface/entity.utils.interface";
|
|
|
17
17
|
import { RelationConfigs } from "../interface/relation-config.interface";
|
|
18
18
|
import { BankEntityModel } from "./bank.entity.model";
|
|
19
19
|
import { BaseEntityModel } from "./base.entity.model";
|
|
20
|
-
import { BillingParticularLineItemEntityModel } from "./billing-particular-line-item.entity.model";
|
|
21
20
|
import { BillingProfileEntityModel } from "./billing-profile.entity.model";
|
|
22
21
|
import { BillingReimbursementExpneseEntityModel } from "./billing-reimbursement-expense.entity.model";
|
|
23
22
|
import { BillingTimesheetEntityModel } from "./billing-timesheet.entity.model";
|
|
@@ -68,7 +67,6 @@ export declare class BillingEntityModel extends BaseEntityModel<EntityEnum.BILLI
|
|
|
68
67
|
bank?: BankEntityModel[];
|
|
69
68
|
billingTimesheets?: BillingTimesheetEntityModel[];
|
|
70
69
|
billingTransactions?: BillingTransactionEntityModel[];
|
|
71
|
-
billingParticularLineItems?: BillingParticularLineItemEntityModel[];
|
|
72
70
|
isProjectComplete?: boolean;
|
|
73
71
|
static readonly BILLING_ENTITY_DOCUMENT_TYPES: readonly ["invoice"];
|
|
74
72
|
static validateDocumentNoDocumentFile(data: DocumentFields<typeof BillingEntityModel.BILLING_ENTITY_DOCUMENT_TYPES>, deleteDetails?: DeleteDocumentDetails<typeof BillingEntityModel.BILLING_ENTITY_DOCUMENT_TYPES>): Result<void, IDtoValidationError[]>;
|
|
@@ -83,20 +81,11 @@ export declare class BillingEntityModel extends BaseEntityModel<EntityEnum.BILLI
|
|
|
83
81
|
EntityEnum.BILLING_REIMBURSEMENT_EXPENSE,
|
|
84
82
|
EntityEnum.BILLING_TIMESHEET,
|
|
85
83
|
EntityEnum.BANK,
|
|
86
|
-
EntityEnum.BILLING_TRANSACTION
|
|
87
|
-
EntityEnum.BILLING_PARTICULAR_LINE_ITEM
|
|
84
|
+
EntityEnum.BILLING_TRANSACTION
|
|
88
85
|
], EntityEnum.BILLING>;
|
|
89
86
|
static fromEntity(entity: IBillingEntity): BillingEntityModel;
|
|
90
87
|
get nonDeletedBillingTimesheets(): BillingTimesheetEntityModel[];
|
|
91
88
|
get nonDeletedBillingReimbursementExpenses(): BillingReimbursementExpneseEntityModel[];
|
|
92
|
-
private groupParticularLineItemsByStatus;
|
|
93
|
-
get activeBillingParticularLineItems(): BillingParticularLineItemEntityModel[];
|
|
94
|
-
get inactiveBillingParticularLineItems(): BillingParticularLineItemEntityModel[];
|
|
95
|
-
groupParticularLineItemsBySource(): {
|
|
96
|
-
invoice: BillingParticularLineItemEntityModel[];
|
|
97
|
-
ope: BillingParticularLineItemEntityModel[];
|
|
98
|
-
custom: BillingParticularLineItemEntityModel[];
|
|
99
|
-
};
|
|
100
89
|
getStatusCategory(): BillingStatusCategoryEnum;
|
|
101
90
|
getStatusLabel(): string;
|
|
102
91
|
getTotalAmountInINR(): string;
|
|
@@ -7,10 +7,6 @@ const error_key_enum_1 = require("../../enums/error.key.enum");
|
|
|
7
7
|
const exceptions_1 = require("../../exceptions");
|
|
8
8
|
const utils_1 = require("../../utils");
|
|
9
9
|
const billing_reimbursement_expense_change_status_enum_1 = require("../enums/billing-reimbursement-expense-change-status.enum");
|
|
10
|
-
// LW-773-billing-particular-line-item-status-import
|
|
11
|
-
const billing_particular_line_item_changed_status_enum_1 = require("../enums/billing-particular-line-item.changed-status.enum");
|
|
12
|
-
// LW-773-billing-particular-line-item-source-import
|
|
13
|
-
const billing_particular_line_item_source_enum_1 = require("../enums/billing-particular-line-item.source.enum");
|
|
14
10
|
const billing_status_category_enum_1 = require("../enums/billing-status-category.enum");
|
|
15
11
|
const billing_transaction_status_enum_1 = require("../enums/billing-transaction-status.enum");
|
|
16
12
|
const billing_type_enum_1 = require("../enums/billing-type.enum");
|
|
@@ -89,47 +85,6 @@ class BillingEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
|
89
85
|
var _a, _b;
|
|
90
86
|
return (_b = (_a = this.billingReimbursementExpenses) === null || _a === void 0 ? void 0 : _a.filter((ts) => ts.changedStatus !== billing_reimbursement_expense_change_status_enum_1.BillingReimbursementExpenseChangedStatusEnum.DELETED)) !== null && _b !== void 0 ? _b : [];
|
|
91
87
|
}
|
|
92
|
-
// LW-773-group-particulars-by-status
|
|
93
|
-
groupParticularLineItemsByStatus() {
|
|
94
|
-
var _a;
|
|
95
|
-
const active = [];
|
|
96
|
-
const inactive = [];
|
|
97
|
-
for (const item of (_a = this.billingParticularLineItems) !== null && _a !== void 0 ? _a : []) {
|
|
98
|
-
if (item.changedStatus === billing_particular_line_item_changed_status_enum_1.BillingParticularLineItemChangedStatusEnum.DELETED) {
|
|
99
|
-
inactive.push(item);
|
|
100
|
-
}
|
|
101
|
-
else {
|
|
102
|
-
active.push(item);
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
return { active, inactive };
|
|
106
|
-
}
|
|
107
|
-
// LW-773-active-particular-line-items
|
|
108
|
-
get activeBillingParticularLineItems() {
|
|
109
|
-
return this.groupParticularLineItemsByStatus().active;
|
|
110
|
-
}
|
|
111
|
-
// LW-773-inactive-particular-line-items
|
|
112
|
-
get inactiveBillingParticularLineItems() {
|
|
113
|
-
return this.groupParticularLineItemsByStatus().inactive;
|
|
114
|
-
}
|
|
115
|
-
// LW-773-group-particular-line-items-by-source
|
|
116
|
-
groupParticularLineItemsBySource() {
|
|
117
|
-
const invoice = [];
|
|
118
|
-
const ope = [];
|
|
119
|
-
const custom = [];
|
|
120
|
-
for (const item of this.activeBillingParticularLineItems) {
|
|
121
|
-
if (item.source === billing_particular_line_item_source_enum_1.BillingParticularLineItemSourceEnum.INVOICE) {
|
|
122
|
-
invoice.push(item);
|
|
123
|
-
}
|
|
124
|
-
else if (item.source === billing_particular_line_item_source_enum_1.BillingParticularLineItemSourceEnum.OPE) {
|
|
125
|
-
ope.push(item);
|
|
126
|
-
}
|
|
127
|
-
else {
|
|
128
|
-
custom.push(item);
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
return { invoice, ope, custom };
|
|
132
|
-
}
|
|
133
88
|
getStatusCategory() {
|
|
134
89
|
return this.mapStatusCategory(this.status);
|
|
135
90
|
}
|
|
@@ -621,14 +576,4 @@ BillingEntityModel.relationConfigs = [
|
|
|
621
576
|
key: "id",
|
|
622
577
|
},
|
|
623
578
|
},
|
|
624
|
-
// LW-773-billing-particular-line-item-relation-config
|
|
625
|
-
{
|
|
626
|
-
name: entity_utils_interface_1.EntityEnum.BILLING_PARTICULAR_LINE_ITEM,
|
|
627
|
-
relation: relation_type_enum_1.RelationType.MANY,
|
|
628
|
-
key: "billingParticularLineItems",
|
|
629
|
-
mapKeyConfig: {
|
|
630
|
-
relationKey: "billingId",
|
|
631
|
-
key: "id",
|
|
632
|
-
},
|
|
633
|
-
},
|
|
634
579
|
];
|
|
@@ -14,7 +14,6 @@ const address_book_model_1 = require("./address_book.model");
|
|
|
14
14
|
const bank_entity_model_1 = require("./bank.entity.model");
|
|
15
15
|
const bank_history_entity_model_1 = require("./bank_history.entity.model");
|
|
16
16
|
const base_entity_model_1 = require("./base.entity.model");
|
|
17
|
-
const billing_particular_line_item_entity_model_1 = require("./billing-particular-line-item.entity.model");
|
|
18
17
|
const billing_profile_entity_model_1 = require("./billing-profile.entity.model");
|
|
19
18
|
const billing_reimbursement_expense_history_entity_model_1 = require("./billing-reimbursement-expense-history.entity.model");
|
|
20
19
|
const billing_reimbursement_expense_entity_model_1 = require("./billing-reimbursement-expense.entity.model");
|
|
@@ -189,7 +188,6 @@ exports.entityEnumToEntityModel = {
|
|
|
189
188
|
[entity_utils_interface_1.EntityEnum.VENDOR_TDS_CHALLAN]: vendor_tds_challan_entity_model_1.VendorTdsChallanEntityModel.fromEntity,
|
|
190
189
|
[entity_utils_interface_1.EntityEnum.VENDOR_ADVANCE]: vendor_advance_entity_model_1.VendorAdvanceEntityModel.fromEntity,
|
|
191
190
|
[entity_utils_interface_1.EntityEnum.VENDOR_INVOICE_ADVANCE]: vendor_invoice_advance_entity_model_1.VendorInvoiceAdvanceEntityModel.fromEntity,
|
|
192
|
-
[entity_utils_interface_1.EntityEnum.BILLING_PARTICULAR_LINE_ITEM]: billing_particular_line_item_entity_model_1.BillingParticularLineItemEntityModel.fromEntity,
|
|
193
191
|
};
|
|
194
192
|
function entityMapToModels(entityMap) {
|
|
195
193
|
for (const entityName in entityMap) {
|
package/package.json
CHANGED
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "law-common",
|
|
3
|
-
"version": "12.
|
|
4
|
-
"description": "",
|
|
5
|
-
"main": "dist/index.js",
|
|
6
|
-
"files": [
|
|
7
|
-
"dist/**/*"
|
|
8
|
-
],
|
|
9
|
-
"scripts": {
|
|
10
|
-
"clean": "rm -rf dist",
|
|
11
|
-
"build": "npm run clean && tsc",
|
|
12
|
-
"publish:beta": "npm run build && npm version prerelease --preid beta && git push && npm publish --tag beta",
|
|
13
|
-
"publish:beta:link": "npm run build && npm version prerelease --preid beta && git push && npm publish --tag beta && npm run link",
|
|
14
|
-
"publish:patch": "npm version patch && git push && npm run build && npm publish",
|
|
15
|
-
"publish:minor": "npm version minor && git push && npm run build && npm publish",
|
|
16
|
-
"publish:major": "npm verYsion major && git push && npm run build && npm publish",
|
|
17
|
-
"link": "npm run build && npm link",
|
|
18
|
-
"link:backend": "npm run build && npm link && cd ../law-backend && npm link law-common && cd ../law-common",
|
|
19
|
-
"link:frontend": "npm run build && npm link && cd ../law-admin-web && npm link law-common && cd ../law-common",
|
|
20
|
-
"link:both": "npm run build && npm link && cd ../law-backend && npm link law-common && cd ../law-admin-web && npm link law-common && cd ../law-common",
|
|
21
|
-
"test": "jest",
|
|
22
|
-
"format": "prettier --write .",
|
|
23
|
-
"check-format": "prettier --check .",
|
|
24
|
-
"pull:link": "git pull && npm run link",
|
|
25
|
-
"check-version": "npm view law-common versions --json | jq -r '.[-1]'",
|
|
26
|
-
"script:publish": "node scripts/publish.js",
|
|
27
|
-
"script:publish:latest:beta": "npm run build && node scripts/publish.js prerelease beta && git push",
|
|
28
|
-
"script:publish:latest:patch": "npm run build && node scripts/publish.js patch && git push",
|
|
29
|
-
"script:nobuild:publish:latest:beta": "node scripts/publish.js prerelease beta && git push",
|
|
30
|
-
"install:version": "node scripts/install-version.js",
|
|
31
|
-
"script:publish:install:beta": "node scripts/publish-and-install.js prerelease beta",
|
|
32
|
-
"script:publish:install:patch": "node scripts/publish-and-install.js patch",
|
|
33
|
-
"script:publish:install:minor": "node scripts/publish-and-install.js minor",
|
|
34
|
-
"script:publish:install:major": "node scripts/publish-and-install.js major"
|
|
35
|
-
},
|
|
36
|
-
"keywords": [],
|
|
37
|
-
"author": "",
|
|
38
|
-
"license": "ISC",
|
|
39
|
-
"devDependencies": {
|
|
40
|
-
"@types/jest": "^29.5.13",
|
|
41
|
-
"@types/lodash": "^4.17.21",
|
|
42
|
-
"@types/node": "^22.6.1",
|
|
43
|
-
"jest": "^29.7.0",
|
|
44
|
-
"prettier": "3.8.1",
|
|
45
|
-
"semver": "^7.8.1",
|
|
46
|
-
"ts-jest": "^29.2.5",
|
|
47
|
-
"ts-node": "^10.9.2",
|
|
48
|
-
"typescript": "^5.6.2"
|
|
49
|
-
},
|
|
50
|
-
"dependencies": {
|
|
51
|
-
"@types/express": "^5.0.0",
|
|
52
|
-
"@types/multer": "^1.4.12",
|
|
53
|
-
"date-fns": "^4.1.0",
|
|
54
|
-
"lodash": "4.17.21"
|
|
55
|
-
}
|
|
56
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "law-common",
|
|
3
|
+
"version": "12.3.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist/**/*"
|
|
8
|
+
],
|
|
9
|
+
"scripts": {
|
|
10
|
+
"clean": "rm -rf dist",
|
|
11
|
+
"build": "npm run clean && tsc",
|
|
12
|
+
"publish:beta": "npm run build && npm version prerelease --preid beta && git push && npm publish --tag beta",
|
|
13
|
+
"publish:beta:link": "npm run build && npm version prerelease --preid beta && git push && npm publish --tag beta && npm run link",
|
|
14
|
+
"publish:patch": "npm version patch && git push && npm run build && npm publish",
|
|
15
|
+
"publish:minor": "npm version minor && git push && npm run build && npm publish",
|
|
16
|
+
"publish:major": "npm verYsion major && git push && npm run build && npm publish",
|
|
17
|
+
"link": "npm run build && npm link",
|
|
18
|
+
"link:backend": "npm run build && npm link && cd ../law-backend && npm link law-common && cd ../law-common",
|
|
19
|
+
"link:frontend": "npm run build && npm link && cd ../law-admin-web && npm link law-common && cd ../law-common",
|
|
20
|
+
"link:both": "npm run build && npm link && cd ../law-backend && npm link law-common && cd ../law-admin-web && npm link law-common && cd ../law-common",
|
|
21
|
+
"test": "jest",
|
|
22
|
+
"format": "prettier --write .",
|
|
23
|
+
"check-format": "prettier --check .",
|
|
24
|
+
"pull:link": "git pull && npm run link",
|
|
25
|
+
"check-version": "npm view law-common versions --json | jq -r '.[-1]'",
|
|
26
|
+
"script:publish": "node scripts/publish.js",
|
|
27
|
+
"script:publish:latest:beta": "npm run build && node scripts/publish.js prerelease beta && git push",
|
|
28
|
+
"script:publish:latest:patch": "npm run build && node scripts/publish.js patch && git push",
|
|
29
|
+
"script:nobuild:publish:latest:beta": "node scripts/publish.js prerelease beta && git push",
|
|
30
|
+
"install:version": "node scripts/install-version.js",
|
|
31
|
+
"script:publish:install:beta": "node scripts/publish-and-install.js prerelease beta",
|
|
32
|
+
"script:publish:install:patch": "node scripts/publish-and-install.js patch",
|
|
33
|
+
"script:publish:install:minor": "node scripts/publish-and-install.js minor",
|
|
34
|
+
"script:publish:install:major": "node scripts/publish-and-install.js major"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [],
|
|
37
|
+
"author": "",
|
|
38
|
+
"license": "ISC",
|
|
39
|
+
"devDependencies": {
|
|
40
|
+
"@types/jest": "^29.5.13",
|
|
41
|
+
"@types/lodash": "^4.17.21",
|
|
42
|
+
"@types/node": "^22.6.1",
|
|
43
|
+
"jest": "^29.7.0",
|
|
44
|
+
"prettier": "3.8.1",
|
|
45
|
+
"semver": "^7.8.1",
|
|
46
|
+
"ts-jest": "^29.2.5",
|
|
47
|
+
"ts-node": "^10.9.2",
|
|
48
|
+
"typescript": "^5.6.2"
|
|
49
|
+
},
|
|
50
|
+
"dependencies": {
|
|
51
|
+
"@types/express": "^5.0.0",
|
|
52
|
+
"@types/multer": "^1.4.12",
|
|
53
|
+
"date-fns": "^4.1.0",
|
|
54
|
+
"lodash": "4.17.21"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BillingParticularLineItemChangedStatusEnum = void 0;
|
|
4
|
-
var BillingParticularLineItemChangedStatusEnum;
|
|
5
|
-
(function (BillingParticularLineItemChangedStatusEnum) {
|
|
6
|
-
BillingParticularLineItemChangedStatusEnum["UNCHANGED"] = "unchanged";
|
|
7
|
-
BillingParticularLineItemChangedStatusEnum["UPDATED"] = "updated";
|
|
8
|
-
BillingParticularLineItemChangedStatusEnum["DELETED"] = "deleted";
|
|
9
|
-
BillingParticularLineItemChangedStatusEnum["NEW"] = "new";
|
|
10
|
-
})(BillingParticularLineItemChangedStatusEnum || (exports.BillingParticularLineItemChangedStatusEnum = BillingParticularLineItemChangedStatusEnum = {}));
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BillingParticularLineItemSourceEnum = void 0;
|
|
4
|
-
// LW-773-billing-particular-line-item-source-enum
|
|
5
|
-
var BillingParticularLineItemSourceEnum;
|
|
6
|
-
(function (BillingParticularLineItemSourceEnum) {
|
|
7
|
-
BillingParticularLineItemSourceEnum["INVOICE"] = "invoice";
|
|
8
|
-
BillingParticularLineItemSourceEnum["OPE"] = "ope";
|
|
9
|
-
BillingParticularLineItemSourceEnum["NEW"] = "new";
|
|
10
|
-
})(BillingParticularLineItemSourceEnum || (exports.BillingParticularLineItemSourceEnum = BillingParticularLineItemSourceEnum = {}));
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { BillingParticularLineItemChangedStatusEnum } from "../enums/billing-particular-line-item.changed-status.enum";
|
|
2
|
-
import { BillingParticularLineItemSourceEnum } from "../enums/billing-particular-line-item.source.enum";
|
|
3
|
-
import { IEntityAuditColumn } from "./entity-audit-columns.interface";
|
|
4
|
-
import { IEntityCreateDto, IEntityFilterData, IEntityUpdateDto } from "./entity.utils.interface";
|
|
5
|
-
export interface IBillingParticularLineItemEntity extends IEntityAuditColumn {
|
|
6
|
-
id: number;
|
|
7
|
-
billingId: number;
|
|
8
|
-
description: string;
|
|
9
|
-
amount: number;
|
|
10
|
-
source: BillingParticularLineItemSourceEnum;
|
|
11
|
-
changedStatus: BillingParticularLineItemChangedStatusEnum;
|
|
12
|
-
}
|
|
13
|
-
export type IBillingParticularsLineItemsExclude = "billingId";
|
|
14
|
-
export interface IBillingParticularLineItemCreateDto extends Omit<IEntityCreateDto<IBillingParticularLineItemEntity>, IBillingParticularsLineItemsExclude> {
|
|
15
|
-
}
|
|
16
|
-
export interface IBillingParticularLineItemUpdateDto extends IEntityUpdateDto<IBillingParticularLineItemEntity> {
|
|
17
|
-
}
|
|
18
|
-
export interface IBillingParticularLineItemEntityFilterData extends IEntityFilterData<IBillingParticularLineItemEntity> {
|
|
19
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { BillingParticularLineItemChangedStatusEnum } from "../enums/billing-particular-line-item.changed-status.enum";
|
|
2
|
-
import { BillingParticularLineItemSourceEnum } from "../enums/billing-particular-line-item.source.enum";
|
|
3
|
-
import { IBillingParticularLineItemEntity } from "../interface/billing_particular_line_item.entity.interface";
|
|
4
|
-
import { EntityEnum } from "../interface/entity.utils.interface";
|
|
5
|
-
import { BaseEntityModel } from "./base.entity.model";
|
|
6
|
-
export declare class BillingParticularLineItemEntityModel extends BaseEntityModel<EntityEnum.BILLING_PARTICULAR_LINE_ITEM> implements IBillingParticularLineItemEntity {
|
|
7
|
-
id: number;
|
|
8
|
-
billingId: number;
|
|
9
|
-
description: string;
|
|
10
|
-
amount: number;
|
|
11
|
-
source: BillingParticularLineItemSourceEnum;
|
|
12
|
-
changedStatus: BillingParticularLineItemChangedStatusEnum;
|
|
13
|
-
createdOn: number;
|
|
14
|
-
updatedOn: number;
|
|
15
|
-
createdBy: number;
|
|
16
|
-
updatedBy: number;
|
|
17
|
-
getRelationConfigs(): any;
|
|
18
|
-
static fromEntity(entity: IBillingParticularLineItemEntity): BillingParticularLineItemEntityModel;
|
|
19
|
-
}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BillingParticularLineItemEntityModel = void 0;
|
|
4
|
-
const billing_particular_line_item_changed_status_enum_1 = require("../enums/billing-particular-line-item.changed-status.enum");
|
|
5
|
-
const billing_particular_line_item_source_enum_1 = require("../enums/billing-particular-line-item.source.enum");
|
|
6
|
-
const entity_utils_interface_1 = require("../interface/entity.utils.interface");
|
|
7
|
-
const base_entity_model_1 = require("./base.entity.model");
|
|
8
|
-
// LW-773-billing-particular-line-item-model
|
|
9
|
-
class BillingParticularLineItemEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
10
|
-
constructor() {
|
|
11
|
-
super(...arguments);
|
|
12
|
-
this.id = 0;
|
|
13
|
-
this.billingId = 0;
|
|
14
|
-
this.description = "";
|
|
15
|
-
this.amount = 0;
|
|
16
|
-
this.source = billing_particular_line_item_source_enum_1.BillingParticularLineItemSourceEnum.NEW;
|
|
17
|
-
this.changedStatus = billing_particular_line_item_changed_status_enum_1.BillingParticularLineItemChangedStatusEnum.UNCHANGED;
|
|
18
|
-
this.createdOn = 0;
|
|
19
|
-
this.updatedOn = 0;
|
|
20
|
-
this.createdBy = 0;
|
|
21
|
-
this.updatedBy = 0;
|
|
22
|
-
}
|
|
23
|
-
// LW-773-get-relation-configs
|
|
24
|
-
getRelationConfigs() {
|
|
25
|
-
return this.constructor.prototype.constructor.relationConfigs;
|
|
26
|
-
}
|
|
27
|
-
// LW-773-from-entity
|
|
28
|
-
static fromEntity(entity) {
|
|
29
|
-
const result = new BillingParticularLineItemEntityModel(entity_utils_interface_1.EntityEnum.BILLING_PARTICULAR_LINE_ITEM);
|
|
30
|
-
Object.assign(result, entity);
|
|
31
|
-
return result;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
exports.BillingParticularLineItemEntityModel = BillingParticularLineItemEntityModel;
|