added place to telecommunication, added contract documents, added invoice to other contracts
This commit is contained in:
+8
@@ -138,6 +138,8 @@ async function getContractById(id, decryptPassword = false) {
|
||||
tvDetails: true,
|
||||
carInsuranceDetails: true,
|
||||
stressfreiEmail: true,
|
||||
invoices: { orderBy: { invoiceDate: 'desc' } },
|
||||
documents: { orderBy: { createdAt: 'desc' } },
|
||||
followUpContract: {
|
||||
select: { id: true, contractNumber: true, status: true },
|
||||
},
|
||||
@@ -183,6 +185,9 @@ async function createContract(data) {
|
||||
internetPasswordEncrypted: internetDetails.internetPassword
|
||||
? (0, encryption_js_1.encrypt)(internetDetails.internetPassword)
|
||||
: undefined,
|
||||
propertyType: internetDetails.propertyType,
|
||||
propertyLocation: internetDetails.propertyLocation,
|
||||
connectionLocation: internetDetails.connectionLocation,
|
||||
homeId: internetDetails.homeId,
|
||||
activationCode: internetDetails.activationCode,
|
||||
phoneNumbers: internetDetails.phoneNumbers && internetDetails.phoneNumbers.length > 0
|
||||
@@ -321,6 +326,9 @@ async function updateContract(id, data) {
|
||||
...(internetPassword
|
||||
? { internetPasswordEncrypted: (0, encryption_js_1.encrypt)(internetPassword) }
|
||||
: {}),
|
||||
propertyType: internetData.propertyType,
|
||||
propertyLocation: internetData.propertyLocation,
|
||||
connectionLocation: internetData.connectionLocation,
|
||||
homeId: internetData.homeId,
|
||||
activationCode: internetData.activationCode,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user