@duvdu-v1/duvdu 1.1.106 → 1.1.107
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.
|
@@ -27,6 +27,7 @@ import { Iuser } from '../types/User';
|
|
|
27
27
|
export declare enum ContractStatus {
|
|
28
28
|
canceled = "canceled",
|
|
29
29
|
pending = "pending",
|
|
30
|
+
waitingForPayment = "waiting for payment",
|
|
30
31
|
ongoing = "ongoing",
|
|
31
32
|
completed = "completed",
|
|
32
33
|
rejected = "rejected"
|
|
@@ -42,6 +43,7 @@ export interface Icontract {
|
|
|
42
43
|
sourceUser: Iuser | Types.ObjectId;
|
|
43
44
|
targetUser: Iuser | Types.ObjectId;
|
|
44
45
|
project: Types.ObjectId;
|
|
46
|
+
details: string;
|
|
45
47
|
book: Types.ObjectId;
|
|
46
48
|
ref: RefModels;
|
|
47
49
|
startDate: Date;
|
|
@@ -7,6 +7,7 @@ var ContractStatus;
|
|
|
7
7
|
(function (ContractStatus) {
|
|
8
8
|
ContractStatus["canceled"] = "canceled";
|
|
9
9
|
ContractStatus["pending"] = "pending";
|
|
10
|
+
ContractStatus["waitingForPayment"] = "waiting for payment";
|
|
10
11
|
ContractStatus["ongoing"] = "ongoing";
|
|
11
12
|
ContractStatus["completed"] = "completed";
|
|
12
13
|
ContractStatus["rejected"] = "rejected";
|
|
@@ -23,9 +23,24 @@
|
|
|
23
23
|
/// <reference types="mongoose/types/virtuals" />
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
import { Types } from 'mongoose';
|
|
26
|
+
import { Icategory } from '../types/Category';
|
|
26
27
|
import { Iuser } from '../types/User';
|
|
27
28
|
export interface Iproducer {
|
|
28
29
|
user: Types.ObjectId | Iuser;
|
|
30
|
+
category: Types.ObjectId | Icategory;
|
|
31
|
+
subCategories?: {
|
|
32
|
+
title: {
|
|
33
|
+
en: string;
|
|
34
|
+
ar: string;
|
|
35
|
+
};
|
|
36
|
+
tags: {
|
|
37
|
+
en: string;
|
|
38
|
+
ar: string;
|
|
39
|
+
}[];
|
|
40
|
+
}[];
|
|
41
|
+
maxBudget: number;
|
|
42
|
+
minBudget: number;
|
|
43
|
+
searchKeywords: string[];
|
|
29
44
|
}
|
|
30
45
|
export interface IproducerBooking {
|
|
31
46
|
producer: Types.ObjectId | Iuser;
|
|
@@ -77,5 +77,13 @@ exports.Producer = (0, mongoose_1.model)(model_names_1.MODELS.producer, new mong
|
|
|
77
77
|
user: {
|
|
78
78
|
type: mongoose_1.Schema.Types.ObjectId,
|
|
79
79
|
ref: model_names_1.MODELS.user
|
|
80
|
-
}
|
|
80
|
+
},
|
|
81
|
+
category: {
|
|
82
|
+
type: mongoose_1.Schema.Types.ObjectId,
|
|
83
|
+
ref: model_names_1.MODELS.category
|
|
84
|
+
},
|
|
85
|
+
subCategories: [{ title: { ar: { type: String, default: null }, en: { type: String, default: null } }, tags: [{ en: { type: String, default: null }, ar: { type: String, default: null } }] }],
|
|
86
|
+
minBudget: { type: Number, default: null },
|
|
87
|
+
maxBudget: { type: Number, default: null },
|
|
88
|
+
searchKeywords: [String]
|
|
81
89
|
}, { timestamps: true, collection: model_names_1.MODELS.producer }));
|