update pos consumer module

This commit is contained in:
2026-03-29 18:06:41 +03:30
parent 63fa2bc67e
commit c870a43e35
53 changed files with 2145 additions and 671 deletions
+1
View File
@@ -31,6 +31,7 @@
"@nestjs/schematics": "^11.0.0", "@nestjs/schematics": "^11.0.0",
"@nestjs/testing": "^11.0.1", "@nestjs/testing": "^11.0.1",
"@prisma/client": "^7.2.0", "@prisma/client": "^7.2.0",
"@types/cookie-parser": "^1.4.10",
"@types/express": "^5.0.0", "@types/express": "^5.0.0",
"@types/jest": "^30.0.0", "@types/jest": "^30.0.0",
"@types/node": "^22.10.7", "@types/node": "^22.10.7",
+79 -59
View File
@@ -90,6 +90,9 @@ importers:
'@prisma/client': '@prisma/client':
specifier: ^7.2.0 specifier: ^7.2.0
version: 7.2.0(prisma@7.2.0(@types/react@19.2.7)(react-dom@19.2.1(react@19.2.1))(react@19.2.1)(typescript@5.9.3))(typescript@5.9.3) version: 7.2.0(prisma@7.2.0(@types/react@19.2.7)(react-dom@19.2.1(react@19.2.1))(react@19.2.1)(typescript@5.9.3))(typescript@5.9.3)
'@types/cookie-parser':
specifier: ^1.4.10
version: 1.4.10(@types/express@5.0.6)
'@types/express': '@types/express':
specifier: ^5.0.0 specifier: ^5.0.0
version: 5.0.6 version: 5.0.6
@@ -368,7 +371,7 @@ packages:
resolution: {integrity: sha512-hBzuU5+JjB2cqNZyszkDHZgOSrUUT8V3dhgRl8Q9Gp6dAj/H5+KILGjbhDpc3Iy9qmqlm/akuOI2ut9VUtzJxQ==} resolution: {integrity: sha512-hBzuU5+JjB2cqNZyszkDHZgOSrUUT8V3dhgRl8Q9Gp6dAj/H5+KILGjbhDpc3Iy9qmqlm/akuOI2ut9VUtzJxQ==}
'@colors/colors@1.5.0': '@colors/colors@1.5.0':
resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==, tarball: https://hub.megan.ir/repository/npm/@colors/colors/-/colors-1.5.0.tgz}
engines: {node: '>=0.1.90'} engines: {node: '>=0.1.90'}
'@cspotcode/source-map-support@0.8.1': '@cspotcode/source-map-support@0.8.1':
@@ -390,166 +393,166 @@ packages:
resolution: {integrity: sha512-zfWWa+V2ViDCY/cmUfRqeWY1yLto+EpxjXnZzenB1TyxsTiXaTWeZFIZw6mac52BsuQm0RjCnisjBtdBaXOI6w==} resolution: {integrity: sha512-zfWWa+V2ViDCY/cmUfRqeWY1yLto+EpxjXnZzenB1TyxsTiXaTWeZFIZw6mac52BsuQm0RjCnisjBtdBaXOI6w==}
'@emnapi/core@1.7.1': '@emnapi/core@1.7.1':
resolution: {integrity: sha512-o1uhUASyo921r2XtHYOHy7gdkGLge8ghBEQHMWmyJFoXlpU58kIrhhN3w26lpQb6dspetweapMn2CSNwQ8I4wg==} resolution: {integrity: sha512-o1uhUASyo921r2XtHYOHy7gdkGLge8ghBEQHMWmyJFoXlpU58kIrhhN3w26lpQb6dspetweapMn2CSNwQ8I4wg==, tarball: https://hub.megan.ir/repository/npm/@emnapi/core/-/core-1.7.1.tgz}
'@emnapi/runtime@1.7.1': '@emnapi/runtime@1.7.1':
resolution: {integrity: sha512-PVtJr5CmLwYAU9PZDMITZoR5iAOShYREoR45EyyLrbntV50mdePTgUn4AmOw90Ifcj+x2kRjdzr1HP3RrNiHGA==} resolution: {integrity: sha512-PVtJr5CmLwYAU9PZDMITZoR5iAOShYREoR45EyyLrbntV50mdePTgUn4AmOw90Ifcj+x2kRjdzr1HP3RrNiHGA==, tarball: https://hub.megan.ir/repository/npm/@emnapi/runtime/-/runtime-1.7.1.tgz}
'@emnapi/wasi-threads@1.1.0': '@emnapi/wasi-threads@1.1.0':
resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==} resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==, tarball: https://hub.megan.ir/repository/npm/@emnapi/wasi-threads/-/wasi-threads-1.1.0.tgz}
'@esbuild/aix-ppc64@0.27.1': '@esbuild/aix-ppc64@0.27.1':
resolution: {integrity: sha512-HHB50pdsBX6k47S4u5g/CaLjqS3qwaOVE5ILsq64jyzgMhLuCuZ8rGzM9yhsAjfjkbgUPMzZEPa7DAp7yz6vuA==} resolution: {integrity: sha512-HHB50pdsBX6k47S4u5g/CaLjqS3qwaOVE5ILsq64jyzgMhLuCuZ8rGzM9yhsAjfjkbgUPMzZEPa7DAp7yz6vuA==, tarball: https://hub.megan.ir/repository/npm/@esbuild/aix-ppc64/-/aix-ppc64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [ppc64] cpu: [ppc64]
os: [aix] os: [aix]
'@esbuild/android-arm64@0.27.1': '@esbuild/android-arm64@0.27.1':
resolution: {integrity: sha512-45fuKmAJpxnQWixOGCrS+ro4Uvb4Re9+UTieUY2f8AEc+t7d4AaZ6eUJ3Hva7dtrxAAWHtlEFsXFMAgNnGU9uQ==} resolution: {integrity: sha512-45fuKmAJpxnQWixOGCrS+ro4Uvb4Re9+UTieUY2f8AEc+t7d4AaZ6eUJ3Hva7dtrxAAWHtlEFsXFMAgNnGU9uQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/android-arm64/-/android-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [android] os: [android]
'@esbuild/android-arm@0.27.1': '@esbuild/android-arm@0.27.1':
resolution: {integrity: sha512-kFqa6/UcaTbGm/NncN9kzVOODjhZW8e+FRdSeypWe6j33gzclHtwlANs26JrupOntlcWmB0u8+8HZo8s7thHvg==} resolution: {integrity: sha512-kFqa6/UcaTbGm/NncN9kzVOODjhZW8e+FRdSeypWe6j33gzclHtwlANs26JrupOntlcWmB0u8+8HZo8s7thHvg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/android-arm/-/android-arm-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm] cpu: [arm]
os: [android] os: [android]
'@esbuild/android-x64@0.27.1': '@esbuild/android-x64@0.27.1':
resolution: {integrity: sha512-LBEpOz0BsgMEeHgenf5aqmn/lLNTFXVfoWMUox8CtWWYK9X4jmQzWjoGoNb8lmAYml/tQ/Ysvm8q7szu7BoxRQ==} resolution: {integrity: sha512-LBEpOz0BsgMEeHgenf5aqmn/lLNTFXVfoWMUox8CtWWYK9X4jmQzWjoGoNb8lmAYml/tQ/Ysvm8q7szu7BoxRQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/android-x64/-/android-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [android] os: [android]
'@esbuild/darwin-arm64@0.27.1': '@esbuild/darwin-arm64@0.27.1':
resolution: {integrity: sha512-veg7fL8eMSCVKL7IW4pxb54QERtedFDfY/ASrumK/SbFsXnRazxY4YykN/THYqFnFwJ0aVjiUrVG2PwcdAEqQQ==} resolution: {integrity: sha512-veg7fL8eMSCVKL7IW4pxb54QERtedFDfY/ASrumK/SbFsXnRazxY4YykN/THYqFnFwJ0aVjiUrVG2PwcdAEqQQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/darwin-arm64/-/darwin-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [darwin] os: [darwin]
'@esbuild/darwin-x64@0.27.1': '@esbuild/darwin-x64@0.27.1':
resolution: {integrity: sha512-+3ELd+nTzhfWb07Vol7EZ+5PTbJ/u74nC6iv4/lwIU99Ip5uuY6QoIf0Hn4m2HoV0qcnRivN3KSqc+FyCHjoVQ==} resolution: {integrity: sha512-+3ELd+nTzhfWb07Vol7EZ+5PTbJ/u74nC6iv4/lwIU99Ip5uuY6QoIf0Hn4m2HoV0qcnRivN3KSqc+FyCHjoVQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/darwin-x64/-/darwin-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [darwin] os: [darwin]
'@esbuild/freebsd-arm64@0.27.1': '@esbuild/freebsd-arm64@0.27.1':
resolution: {integrity: sha512-/8Rfgns4XD9XOSXlzUDepG8PX+AVWHliYlUkFI3K3GB6tqbdjYqdhcb4BKRd7C0BhZSoaCxhv8kTcBrcZWP+xg==} resolution: {integrity: sha512-/8Rfgns4XD9XOSXlzUDepG8PX+AVWHliYlUkFI3K3GB6tqbdjYqdhcb4BKRd7C0BhZSoaCxhv8kTcBrcZWP+xg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [freebsd] os: [freebsd]
'@esbuild/freebsd-x64@0.27.1': '@esbuild/freebsd-x64@0.27.1':
resolution: {integrity: sha512-GITpD8dK9C+r+5yRT/UKVT36h/DQLOHdwGVwwoHidlnA168oD3uxA878XloXebK4Ul3gDBBIvEdL7go9gCUFzQ==} resolution: {integrity: sha512-GITpD8dK9C+r+5yRT/UKVT36h/DQLOHdwGVwwoHidlnA168oD3uxA878XloXebK4Ul3gDBBIvEdL7go9gCUFzQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/freebsd-x64/-/freebsd-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [freebsd] os: [freebsd]
'@esbuild/linux-arm64@0.27.1': '@esbuild/linux-arm64@0.27.1':
resolution: {integrity: sha512-W9//kCrh/6in9rWIBdKaMtuTTzNj6jSeG/haWBADqLLa9P8O5YSRDzgD5y9QBok4AYlzS6ARHifAb75V6G670Q==} resolution: {integrity: sha512-W9//kCrh/6in9rWIBdKaMtuTTzNj6jSeG/haWBADqLLa9P8O5YSRDzgD5y9QBok4AYlzS6ARHifAb75V6G670Q==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-arm64/-/linux-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [linux] os: [linux]
'@esbuild/linux-arm@0.27.1': '@esbuild/linux-arm@0.27.1':
resolution: {integrity: sha512-ieMID0JRZY/ZeCrsFQ3Y3NlHNCqIhTprJfDgSB3/lv5jJZ8FX3hqPyXWhe+gvS5ARMBJ242PM+VNz/ctNj//eA==} resolution: {integrity: sha512-ieMID0JRZY/ZeCrsFQ3Y3NlHNCqIhTprJfDgSB3/lv5jJZ8FX3hqPyXWhe+gvS5ARMBJ242PM+VNz/ctNj//eA==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-arm/-/linux-arm-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm] cpu: [arm]
os: [linux] os: [linux]
'@esbuild/linux-ia32@0.27.1': '@esbuild/linux-ia32@0.27.1':
resolution: {integrity: sha512-VIUV4z8GD8rtSVMfAj1aXFahsi/+tcoXXNYmXgzISL+KB381vbSTNdeZHHHIYqFyXcoEhu9n5cT+05tRv13rlw==} resolution: {integrity: sha512-VIUV4z8GD8rtSVMfAj1aXFahsi/+tcoXXNYmXgzISL+KB381vbSTNdeZHHHIYqFyXcoEhu9n5cT+05tRv13rlw==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-ia32/-/linux-ia32-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [ia32] cpu: [ia32]
os: [linux] os: [linux]
'@esbuild/linux-loong64@0.27.1': '@esbuild/linux-loong64@0.27.1':
resolution: {integrity: sha512-l4rfiiJRN7sTNI//ff65zJ9z8U+k6zcCg0LALU5iEWzY+a1mVZ8iWC1k5EsNKThZ7XCQ6YWtsZ8EWYm7r1UEsg==} resolution: {integrity: sha512-l4rfiiJRN7sTNI//ff65zJ9z8U+k6zcCg0LALU5iEWzY+a1mVZ8iWC1k5EsNKThZ7XCQ6YWtsZ8EWYm7r1UEsg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-loong64/-/linux-loong64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [loong64] cpu: [loong64]
os: [linux] os: [linux]
'@esbuild/linux-mips64el@0.27.1': '@esbuild/linux-mips64el@0.27.1':
resolution: {integrity: sha512-U0bEuAOLvO/DWFdygTHWY8C067FXz+UbzKgxYhXC0fDieFa0kDIra1FAhsAARRJbvEyso8aAqvPdNxzWuStBnA==} resolution: {integrity: sha512-U0bEuAOLvO/DWFdygTHWY8C067FXz+UbzKgxYhXC0fDieFa0kDIra1FAhsAARRJbvEyso8aAqvPdNxzWuStBnA==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-mips64el/-/linux-mips64el-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [mips64el] cpu: [mips64el]
os: [linux] os: [linux]
'@esbuild/linux-ppc64@0.27.1': '@esbuild/linux-ppc64@0.27.1':
resolution: {integrity: sha512-NzdQ/Xwu6vPSf/GkdmRNsOfIeSGnh7muundsWItmBsVpMoNPVpM61qNzAVY3pZ1glzzAxLR40UyYM23eaDDbYQ==} resolution: {integrity: sha512-NzdQ/Xwu6vPSf/GkdmRNsOfIeSGnh7muundsWItmBsVpMoNPVpM61qNzAVY3pZ1glzzAxLR40UyYM23eaDDbYQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-ppc64/-/linux-ppc64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [ppc64] cpu: [ppc64]
os: [linux] os: [linux]
'@esbuild/linux-riscv64@0.27.1': '@esbuild/linux-riscv64@0.27.1':
resolution: {integrity: sha512-7zlw8p3IApcsN7mFw0O1Z1PyEk6PlKMu18roImfl3iQHTnr/yAfYv6s4hXPidbDoI2Q0pW+5xeoM4eTCC0UdrQ==} resolution: {integrity: sha512-7zlw8p3IApcsN7mFw0O1Z1PyEk6PlKMu18roImfl3iQHTnr/yAfYv6s4hXPidbDoI2Q0pW+5xeoM4eTCC0UdrQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-riscv64/-/linux-riscv64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [riscv64] cpu: [riscv64]
os: [linux] os: [linux]
'@esbuild/linux-s390x@0.27.1': '@esbuild/linux-s390x@0.27.1':
resolution: {integrity: sha512-cGj5wli+G+nkVQdZo3+7FDKC25Uh4ZVwOAK6A06Hsvgr8WqBBuOy/1s+PUEd/6Je+vjfm6stX0kmib5b/O2Ykw==} resolution: {integrity: sha512-cGj5wli+G+nkVQdZo3+7FDKC25Uh4ZVwOAK6A06Hsvgr8WqBBuOy/1s+PUEd/6Je+vjfm6stX0kmib5b/O2Ykw==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-s390x/-/linux-s390x-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [s390x] cpu: [s390x]
os: [linux] os: [linux]
'@esbuild/linux-x64@0.27.1': '@esbuild/linux-x64@0.27.1':
resolution: {integrity: sha512-z3H/HYI9MM0HTv3hQZ81f+AKb+yEoCRlUby1F80vbQ5XdzEMyY/9iNlAmhqiBKw4MJXwfgsh7ERGEOhrM1niMA==} resolution: {integrity: sha512-z3H/HYI9MM0HTv3hQZ81f+AKb+yEoCRlUby1F80vbQ5XdzEMyY/9iNlAmhqiBKw4MJXwfgsh7ERGEOhrM1niMA==, tarball: https://hub.megan.ir/repository/npm/@esbuild/linux-x64/-/linux-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [linux] os: [linux]
'@esbuild/netbsd-arm64@0.27.1': '@esbuild/netbsd-arm64@0.27.1':
resolution: {integrity: sha512-wzC24DxAvk8Em01YmVXyjl96Mr+ecTPyOuADAvjGg+fyBpGmxmcr2E5ttf7Im8D0sXZihpxzO1isus8MdjMCXQ==} resolution: {integrity: sha512-wzC24DxAvk8Em01YmVXyjl96Mr+ecTPyOuADAvjGg+fyBpGmxmcr2E5ttf7Im8D0sXZihpxzO1isus8MdjMCXQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [netbsd] os: [netbsd]
'@esbuild/netbsd-x64@0.27.1': '@esbuild/netbsd-x64@0.27.1':
resolution: {integrity: sha512-1YQ8ybGi2yIXswu6eNzJsrYIGFpnlzEWRl6iR5gMgmsrR0FcNoV1m9k9sc3PuP5rUBLshOZylc9nqSgymI+TYg==} resolution: {integrity: sha512-1YQ8ybGi2yIXswu6eNzJsrYIGFpnlzEWRl6iR5gMgmsrR0FcNoV1m9k9sc3PuP5rUBLshOZylc9nqSgymI+TYg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/netbsd-x64/-/netbsd-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [netbsd] os: [netbsd]
'@esbuild/openbsd-arm64@0.27.1': '@esbuild/openbsd-arm64@0.27.1':
resolution: {integrity: sha512-5Z+DzLCrq5wmU7RDaMDe2DVXMRm2tTDvX2KU14JJVBN2CT/qov7XVix85QoJqHltpvAOZUAc3ndU56HSMWrv8g==} resolution: {integrity: sha512-5Z+DzLCrq5wmU7RDaMDe2DVXMRm2tTDvX2KU14JJVBN2CT/qov7XVix85QoJqHltpvAOZUAc3ndU56HSMWrv8g==, tarball: https://hub.megan.ir/repository/npm/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [openbsd] os: [openbsd]
'@esbuild/openbsd-x64@0.27.1': '@esbuild/openbsd-x64@0.27.1':
resolution: {integrity: sha512-Q73ENzIdPF5jap4wqLtsfh8YbYSZ8Q0wnxplOlZUOyZy7B4ZKW8DXGWgTCZmF8VWD7Tciwv5F4NsRf6vYlZtqg==} resolution: {integrity: sha512-Q73ENzIdPF5jap4wqLtsfh8YbYSZ8Q0wnxplOlZUOyZy7B4ZKW8DXGWgTCZmF8VWD7Tciwv5F4NsRf6vYlZtqg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/openbsd-x64/-/openbsd-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [openbsd] os: [openbsd]
'@esbuild/openharmony-arm64@0.27.1': '@esbuild/openharmony-arm64@0.27.1':
resolution: {integrity: sha512-ajbHrGM/XiK+sXM0JzEbJAen+0E+JMQZ2l4RR4VFwvV9JEERx+oxtgkpoKv1SevhjavK2z2ReHk32pjzktWbGg==} resolution: {integrity: sha512-ajbHrGM/XiK+sXM0JzEbJAen+0E+JMQZ2l4RR4VFwvV9JEERx+oxtgkpoKv1SevhjavK2z2ReHk32pjzktWbGg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [openharmony] os: [openharmony]
'@esbuild/sunos-x64@0.27.1': '@esbuild/sunos-x64@0.27.1':
resolution: {integrity: sha512-IPUW+y4VIjuDVn+OMzHc5FV4GubIwPnsz6ubkvN8cuhEqH81NovB53IUlrlBkPMEPxvNnf79MGBoz8rZ2iW8HA==} resolution: {integrity: sha512-IPUW+y4VIjuDVn+OMzHc5FV4GubIwPnsz6ubkvN8cuhEqH81NovB53IUlrlBkPMEPxvNnf79MGBoz8rZ2iW8HA==, tarball: https://hub.megan.ir/repository/npm/@esbuild/sunos-x64/-/sunos-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [sunos] os: [sunos]
'@esbuild/win32-arm64@0.27.1': '@esbuild/win32-arm64@0.27.1':
resolution: {integrity: sha512-RIVRWiljWA6CdVu8zkWcRmGP7iRRIIwvhDKem8UMBjPql2TXM5PkDVvvrzMtj1V+WFPB4K7zkIGM7VzRtFkjdg==} resolution: {integrity: sha512-RIVRWiljWA6CdVu8zkWcRmGP7iRRIIwvhDKem8UMBjPql2TXM5PkDVvvrzMtj1V+WFPB4K7zkIGM7VzRtFkjdg==, tarball: https://hub.megan.ir/repository/npm/@esbuild/win32-arm64/-/win32-arm64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [arm64] cpu: [arm64]
os: [win32] os: [win32]
'@esbuild/win32-ia32@0.27.1': '@esbuild/win32-ia32@0.27.1':
resolution: {integrity: sha512-2BR5M8CPbptC1AK5JbJT1fWrHLvejwZidKx3UMSF0ecHMa+smhi16drIrCEggkgviBwLYd5nwrFLSl5Kho96RQ==} resolution: {integrity: sha512-2BR5M8CPbptC1AK5JbJT1fWrHLvejwZidKx3UMSF0ecHMa+smhi16drIrCEggkgviBwLYd5nwrFLSl5Kho96RQ==, tarball: https://hub.megan.ir/repository/npm/@esbuild/win32-ia32/-/win32-ia32-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [ia32] cpu: [ia32]
os: [win32] os: [win32]
'@esbuild/win32-x64@0.27.1': '@esbuild/win32-x64@0.27.1':
resolution: {integrity: sha512-d5X6RMYv6taIymSk8JBP+nxv8DQAMY6A51GPgusqLdK9wBz5wWIXy1KjTck6HnjE9hqJzJRdk+1p/t5soSbCtw==} resolution: {integrity: sha512-d5X6RMYv6taIymSk8JBP+nxv8DQAMY6A51GPgusqLdK9wBz5wWIXy1KjTck6HnjE9hqJzJRdk+1p/t5soSbCtw==, tarball: https://hub.megan.ir/repository/npm/@esbuild/win32-x64/-/win32-x64-0.27.1.tgz}
engines: {node: '>=18'} engines: {node: '>=18'}
cpu: [x64] cpu: [x64]
os: [win32] os: [win32]
@@ -893,7 +896,7 @@ packages:
engines: {node: '>=16'} engines: {node: '>=16'}
'@napi-rs/wasm-runtime@0.2.12': '@napi-rs/wasm-runtime@0.2.12':
resolution: {integrity: sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==} resolution: {integrity: sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==, tarball: https://hub.megan.ir/repository/npm/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz}
'@nestjs/cli@11.0.14': '@nestjs/cli@11.0.14':
resolution: {integrity: sha512-YwP03zb5VETTwelXU+AIzMVbEZKk/uxJL+z9pw0mdG9ogAtqZ6/mpmIM4nEq/NU8D0a7CBRLcMYUmWW/55pfqw==} resolution: {integrity: sha512-YwP03zb5VETTwelXU+AIzMVbEZKk/uxJL+z9pw0mdG9ogAtqZ6/mpmIM4nEq/NU8D0a7CBRLcMYUmWW/55pfqw==}
@@ -1011,7 +1014,7 @@ packages:
resolution: {integrity: sha512-XO7cAxhnTZl0Yggq6jOgjiOHhbgcO4NqFqwSmQpjK3b6TEE6Uj/jfSk6wzYyemh3+I0sHirKSetjQwn5cZktFw==} resolution: {integrity: sha512-XO7cAxhnTZl0Yggq6jOgjiOHhbgcO4NqFqwSmQpjK3b6TEE6Uj/jfSk6wzYyemh3+I0sHirKSetjQwn5cZktFw==}
'@pkgjs/parseargs@0.11.0': '@pkgjs/parseargs@0.11.0':
resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==, tarball: https://hub.megan.ir/repository/npm/@pkgjs/parseargs/-/parseargs-0.11.0.tgz}
engines: {node: '>=14'} engines: {node: '>=14'}
'@pkgr/core@0.2.9': '@pkgr/core@0.2.9':
@@ -1117,7 +1120,7 @@ packages:
resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==} resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==}
'@tybys/wasm-util@0.10.1': '@tybys/wasm-util@0.10.1':
resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==} resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==, tarball: https://hub.megan.ir/repository/npm/@tybys/wasm-util/-/wasm-util-0.10.1.tgz}
'@types/babel__core@7.20.5': '@types/babel__core@7.20.5':
resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==} resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==}
@@ -1140,6 +1143,11 @@ packages:
'@types/connect@3.4.38': '@types/connect@3.4.38':
resolution: {integrity: sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==} resolution: {integrity: sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==}
'@types/cookie-parser@1.4.10':
resolution: {integrity: sha512-B4xqkqfZ8Wek+rCOeRxsjMS9OgvzebEzzLYw7NHYuvzb7IdxOkI0ZHGgeEBX4PUM7QGVvNSK60T3OvWj3YfBRg==, tarball: https://hub.megan.ir/repository/npm/@types/cookie-parser/-/cookie-parser-1.4.10.tgz}
peerDependencies:
'@types/express': '*'
'@types/cookiejar@2.1.5': '@types/cookiejar@2.1.5':
resolution: {integrity: sha512-he+DHOWReW0nghN24E1WUqM0efK4kI9oTqDm6XmK8ZPe2djZ90BSNdGnIyCLzCPw7/pogPlGbzI2wHGGmi4O/Q==} resolution: {integrity: sha512-he+DHOWReW0nghN24E1WUqM0efK4kI9oTqDm6XmK8ZPe2djZ90BSNdGnIyCLzCPw7/pogPlGbzI2wHGGmi4O/Q==}
@@ -1204,7 +1212,7 @@ packages:
resolution: {integrity: sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==} resolution: {integrity: sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==}
'@types/react@19.2.7': '@types/react@19.2.7':
resolution: {integrity: sha512-MWtvHrGZLFttgeEj28VXHxpmwYbor/ATPYbBfSFZEIRK0ecCFLl2Qo55z52Hss+UV9CRN7trSeq1zbgx7YDWWg==} resolution: {integrity: sha512-MWtvHrGZLFttgeEj28VXHxpmwYbor/ATPYbBfSFZEIRK0ecCFLl2Qo55z52Hss+UV9CRN7trSeq1zbgx7YDWWg==, tarball: https://hub.megan.ir/repository/npm/@types/react/-/react-19.2.7.tgz}
'@types/send@1.2.1': '@types/send@1.2.1':
resolution: {integrity: sha512-arsCikDvlU99zl1g69TcAB3mzZPpxgw0UQnaHeC1Nwb015xp8bknZv5rIfri9xTOcMuaVgvabfIRA7PSZVuZIQ==} resolution: {integrity: sha512-arsCikDvlU99zl1g69TcAB3mzZPpxgw0UQnaHeC1Nwb015xp8bknZv5rIfri9xTOcMuaVgvabfIRA7PSZVuZIQ==}
@@ -1293,97 +1301,105 @@ packages:
resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==}
'@unrs/resolver-binding-android-arm-eabi@1.11.1': '@unrs/resolver-binding-android-arm-eabi@1.11.1':
resolution: {integrity: sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==} resolution: {integrity: sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-android-arm-eabi/-/resolver-binding-android-arm-eabi-1.11.1.tgz}
cpu: [arm] cpu: [arm]
os: [android] os: [android]
'@unrs/resolver-binding-android-arm64@1.11.1': '@unrs/resolver-binding-android-arm64@1.11.1':
resolution: {integrity: sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==} resolution: {integrity: sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-android-arm64/-/resolver-binding-android-arm64-1.11.1.tgz}
cpu: [arm64] cpu: [arm64]
os: [android] os: [android]
'@unrs/resolver-binding-darwin-arm64@1.11.1': '@unrs/resolver-binding-darwin-arm64@1.11.1':
resolution: {integrity: sha512-gPVA1UjRu1Y/IsB/dQEsp2V1pm44Of6+LWvbLc9SDk1c2KhhDRDBUkQCYVWe6f26uJb3fOK8saWMgtX8IrMk3g==} resolution: {integrity: sha512-gPVA1UjRu1Y/IsB/dQEsp2V1pm44Of6+LWvbLc9SDk1c2KhhDRDBUkQCYVWe6f26uJb3fOK8saWMgtX8IrMk3g==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-darwin-arm64/-/resolver-binding-darwin-arm64-1.11.1.tgz}
cpu: [arm64] cpu: [arm64]
os: [darwin] os: [darwin]
'@unrs/resolver-binding-darwin-x64@1.11.1': '@unrs/resolver-binding-darwin-x64@1.11.1':
resolution: {integrity: sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==} resolution: {integrity: sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-darwin-x64/-/resolver-binding-darwin-x64-1.11.1.tgz}
cpu: [x64] cpu: [x64]
os: [darwin] os: [darwin]
'@unrs/resolver-binding-freebsd-x64@1.11.1': '@unrs/resolver-binding-freebsd-x64@1.11.1':
resolution: {integrity: sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==} resolution: {integrity: sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-freebsd-x64/-/resolver-binding-freebsd-x64-1.11.1.tgz}
cpu: [x64] cpu: [x64]
os: [freebsd] os: [freebsd]
'@unrs/resolver-binding-linux-arm-gnueabihf@1.11.1': '@unrs/resolver-binding-linux-arm-gnueabihf@1.11.1':
resolution: {integrity: sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==} resolution: {integrity: sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-arm-gnueabihf/-/resolver-binding-linux-arm-gnueabihf-1.11.1.tgz}
cpu: [arm] cpu: [arm]
os: [linux] os: [linux]
'@unrs/resolver-binding-linux-arm-musleabihf@1.11.1': '@unrs/resolver-binding-linux-arm-musleabihf@1.11.1':
resolution: {integrity: sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==} resolution: {integrity: sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-arm-musleabihf/-/resolver-binding-linux-arm-musleabihf-1.11.1.tgz}
cpu: [arm] cpu: [arm]
os: [linux] os: [linux]
'@unrs/resolver-binding-linux-arm64-gnu@1.11.1': '@unrs/resolver-binding-linux-arm64-gnu@1.11.1':
resolution: {integrity: sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==} resolution: {integrity: sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-arm64-gnu/-/resolver-binding-linux-arm64-gnu-1.11.1.tgz}
cpu: [arm64] cpu: [arm64]
os: [linux] os: [linux]
libc: [glibc]
'@unrs/resolver-binding-linux-arm64-musl@1.11.1': '@unrs/resolver-binding-linux-arm64-musl@1.11.1':
resolution: {integrity: sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==} resolution: {integrity: sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-arm64-musl/-/resolver-binding-linux-arm64-musl-1.11.1.tgz}
cpu: [arm64] cpu: [arm64]
os: [linux] os: [linux]
libc: [musl]
'@unrs/resolver-binding-linux-ppc64-gnu@1.11.1': '@unrs/resolver-binding-linux-ppc64-gnu@1.11.1':
resolution: {integrity: sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==} resolution: {integrity: sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-ppc64-gnu/-/resolver-binding-linux-ppc64-gnu-1.11.1.tgz}
cpu: [ppc64] cpu: [ppc64]
os: [linux] os: [linux]
libc: [glibc]
'@unrs/resolver-binding-linux-riscv64-gnu@1.11.1': '@unrs/resolver-binding-linux-riscv64-gnu@1.11.1':
resolution: {integrity: sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==} resolution: {integrity: sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-riscv64-gnu/-/resolver-binding-linux-riscv64-gnu-1.11.1.tgz}
cpu: [riscv64] cpu: [riscv64]
os: [linux] os: [linux]
libc: [glibc]
'@unrs/resolver-binding-linux-riscv64-musl@1.11.1': '@unrs/resolver-binding-linux-riscv64-musl@1.11.1':
resolution: {integrity: sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==} resolution: {integrity: sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-riscv64-musl/-/resolver-binding-linux-riscv64-musl-1.11.1.tgz}
cpu: [riscv64] cpu: [riscv64]
os: [linux] os: [linux]
libc: [musl]
'@unrs/resolver-binding-linux-s390x-gnu@1.11.1': '@unrs/resolver-binding-linux-s390x-gnu@1.11.1':
resolution: {integrity: sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==} resolution: {integrity: sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-s390x-gnu/-/resolver-binding-linux-s390x-gnu-1.11.1.tgz}
cpu: [s390x] cpu: [s390x]
os: [linux] os: [linux]
libc: [glibc]
'@unrs/resolver-binding-linux-x64-gnu@1.11.1': '@unrs/resolver-binding-linux-x64-gnu@1.11.1':
resolution: {integrity: sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==} resolution: {integrity: sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-x64-gnu/-/resolver-binding-linux-x64-gnu-1.11.1.tgz}
cpu: [x64] cpu: [x64]
os: [linux] os: [linux]
libc: [glibc]
'@unrs/resolver-binding-linux-x64-musl@1.11.1': '@unrs/resolver-binding-linux-x64-musl@1.11.1':
resolution: {integrity: sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==} resolution: {integrity: sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-linux-x64-musl/-/resolver-binding-linux-x64-musl-1.11.1.tgz}
cpu: [x64] cpu: [x64]
os: [linux] os: [linux]
libc: [musl]
'@unrs/resolver-binding-wasm32-wasi@1.11.1': '@unrs/resolver-binding-wasm32-wasi@1.11.1':
resolution: {integrity: sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==} resolution: {integrity: sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-wasm32-wasi/-/resolver-binding-wasm32-wasi-1.11.1.tgz}
engines: {node: '>=14.0.0'} engines: {node: '>=14.0.0'}
cpu: [wasm32] cpu: [wasm32]
'@unrs/resolver-binding-win32-arm64-msvc@1.11.1': '@unrs/resolver-binding-win32-arm64-msvc@1.11.1':
resolution: {integrity: sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==} resolution: {integrity: sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.11.1.tgz}
cpu: [arm64] cpu: [arm64]
os: [win32] os: [win32]
'@unrs/resolver-binding-win32-ia32-msvc@1.11.1': '@unrs/resolver-binding-win32-ia32-msvc@1.11.1':
resolution: {integrity: sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==} resolution: {integrity: sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-win32-ia32-msvc/-/resolver-binding-win32-ia32-msvc-1.11.1.tgz}
cpu: [ia32] cpu: [ia32]
os: [win32] os: [win32]
'@unrs/resolver-binding-win32-x64-msvc@1.11.1': '@unrs/resolver-binding-win32-x64-msvc@1.11.1':
resolution: {integrity: sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==} resolution: {integrity: sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==, tarball: https://hub.megan.ir/repository/npm/@unrs/resolver-binding-win32-x64-msvc/-/resolver-binding-win32-x64-msvc-1.11.1.tgz}
cpu: [x64] cpu: [x64]
os: [win32] os: [win32]
@@ -1832,7 +1848,7 @@ packages:
engines: {node: '>= 8'} engines: {node: '>= 8'}
csstype@3.2.3: csstype@3.2.3:
resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==} resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==, tarball: https://hub.megan.ir/repository/npm/csstype/-/csstype-3.2.3.tgz}
dayjs@1.11.19: dayjs@1.11.19:
resolution: {integrity: sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw==} resolution: {integrity: sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw==}
@@ -2196,7 +2212,7 @@ packages:
resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==}
fsevents@2.3.3: fsevents@2.3.3:
resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==, tarball: https://hub.megan.ir/repository/npm/fsevents/-/fsevents-2.3.3.tgz}
engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0}
os: [darwin] os: [darwin]
@@ -3087,7 +3103,7 @@ packages:
resolution: {integrity: sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg==} resolution: {integrity: sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg==}
react-dom@19.2.1: react-dom@19.2.1:
resolution: {integrity: sha512-ibrK8llX2a4eOskq1mXKu/TGZj9qzomO+sNfO98M6d9zIPOEhlBkMkBUBLd1vgS0gQsLDBzA+8jJBVXDnfHmJg==} resolution: {integrity: sha512-ibrK8llX2a4eOskq1mXKu/TGZj9qzomO+sNfO98M6d9zIPOEhlBkMkBUBLd1vgS0gQsLDBzA+8jJBVXDnfHmJg==, tarball: https://hub.megan.ir/repository/npm/react-dom/-/react-dom-19.2.1.tgz}
peerDependencies: peerDependencies:
react: ^19.2.1 react: ^19.2.1
@@ -3095,7 +3111,7 @@ packages:
resolution: {integrity: sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==} resolution: {integrity: sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==}
react@19.2.1: react@19.2.1:
resolution: {integrity: sha512-DGrYcCWK7tvYMnWh79yrPHt+vdx9tY+1gPZa7nJQtO/p8bLTDaHp4dzwEhQB7pZ4Xe3ok4XKuEPrVuc+wlpkmw==} resolution: {integrity: sha512-DGrYcCWK7tvYMnWh79yrPHt+vdx9tY+1gPZa7nJQtO/p8bLTDaHp4dzwEhQB7pZ4Xe3ok4XKuEPrVuc+wlpkmw==, tarball: https://hub.megan.ir/repository/npm/react/-/react-19.2.1.tgz}
engines: {node: '>=0.10.0'} engines: {node: '>=0.10.0'}
readable-stream@3.6.2: readable-stream@3.6.2:
@@ -3163,7 +3179,7 @@ packages:
resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==}
scheduler@0.27.0: scheduler@0.27.0:
resolution: {integrity: sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==} resolution: {integrity: sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==, tarball: https://hub.megan.ir/repository/npm/scheduler/-/scheduler-0.27.0.tgz}
schema-utils@3.3.0: schema-utils@3.3.0:
resolution: {integrity: sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==} resolution: {integrity: sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==}
@@ -3506,7 +3522,7 @@ packages:
hasBin: true hasBin: true
uglify-js@3.19.3: uglify-js@3.19.3:
resolution: {integrity: sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ==} resolution: {integrity: sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ==, tarball: https://hub.megan.ir/repository/npm/uglify-js/-/uglify-js-3.19.3.tgz}
engines: {node: '>=0.8.0'} engines: {node: '>=0.8.0'}
hasBin: true hasBin: true
@@ -4779,6 +4795,10 @@ snapshots:
dependencies: dependencies:
'@types/node': 22.19.1 '@types/node': 22.19.1
'@types/cookie-parser@1.4.10(@types/express@5.0.6)':
dependencies:
'@types/express': 5.0.6
'@types/cookiejar@2.1.5': {} '@types/cookiejar@2.1.5': {}
'@types/eslint-scope@3.7.7': '@types/eslint-scope@3.7.7':
@@ -0,0 +1,26 @@
/*
Warnings:
- You are about to drop the column `complex_id` on the `customers` table. All the data in the column will be lost.
- You are about to drop the column `complex_id` on the `sales_invoices` table. All the data in the column will be lost.
- Added the required column `pos_id` to the `sales_invoices` table without a default value. This is not possible if the table is not empty.
*/
-- AlterTable
ALTER TABLE `customers` DROP COLUMN `complex_id`;
-- AlterTable
ALTER TABLE `sales_invoices` DROP COLUMN `complex_id`,
ADD COLUMN `pos_id` VARCHAR(191) NOT NULL;
-- AddForeignKey
ALTER TABLE `customer_individuals` ADD CONSTRAINT `customer_individuals_complex_id_fkey` FOREIGN KEY (`complex_id`) REFERENCES `complexes`(`id`) ON DELETE RESTRICT ON UPDATE CASCADE;
-- AddForeignKey
ALTER TABLE `customer_legal` ADD CONSTRAINT `customer_legal_complex_id_fkey` FOREIGN KEY (`complex_id`) REFERENCES `complexes`(`id`) ON DELETE RESTRICT ON UPDATE CASCADE;
-- AddForeignKey
ALTER TABLE `sales_invoices` ADD CONSTRAINT `sales_invoices_pos_id_fkey` FOREIGN KEY (`pos_id`) REFERENCES `poses`(`id`) ON DELETE RESTRICT ON UPDATE CASCADE;
-- AddForeignKey
ALTER TABLE `sales_invoices` ADD CONSTRAINT `sales_invoices_account_id_fkey` FOREIGN KEY (`account_id`) REFERENCES `consumer_accounts`(`id`) ON DELETE RESTRICT ON UPDATE CASCADE;
+4
View File
@@ -28,6 +28,7 @@ model ConsumerAccount {
account Account @relation(fields: [account_id], references: [id]) account Account @relation(fields: [account_id], references: [id])
permissions PermissionConsumer[] permissions PermissionConsumer[]
salesInvoices SalesInvoice[]
@@map("consumer_accounts") @@map("consumer_accounts")
} }
@@ -67,6 +68,8 @@ model Complex {
goods Good[] goods Good[]
good_categories GoodCategory[] good_categories GoodCategory[]
permissionComplexes PermissionComplex[] permissionComplexes PermissionComplex[]
customerIndividuals CustomerIndividual[]
customerLegals CustomerLegal[]
@@map("complexes") @@map("complexes")
} }
@@ -92,6 +95,7 @@ model Pos {
licenses License[] licenses License[]
permissionPos PermissionPos[] permissionPos PermissionPos[]
salesInvoices SalesInvoice[]
@@map("poses") @@map("poses")
} }
+7 -5
View File
@@ -1,15 +1,15 @@
model Customer { model Customer {
id String @id @default(uuid()) id String @id @default(uuid())
type CustomerType
is_favorite Boolean? @default(false)
created_at DateTime @default(now()) @db.Timestamp(0) created_at DateTime @default(now()) @db.Timestamp(0)
updated_at DateTime @updatedAt @db.Timestamp(0) updated_at DateTime @updatedAt @db.Timestamp(0)
deleted_at DateTime? @db.Timestamp(0) deleted_at DateTime? @db.Timestamp(0)
type CustomerType
complex_id String
is_favorite Boolean? @default(false)
sales_invoices SalesInvoice[] sales_invoices SalesInvoice[]
customerIndividuals CustomerIndividual? customer_individuals CustomerIndividual?
customerLegals CustomerLegal? customer_legals CustomerLegal?
@@map("customers") @@map("customers")
} }
@@ -24,6 +24,7 @@ model CustomerIndividual {
complex_id String complex_id String
customer Customer @relation(fields: [customer_id], references: [id]) customer Customer @relation(fields: [customer_id], references: [id])
complex Complex @relation(fields: [complex_id], references: [id])
@@unique([complex_id, national_id]) @@unique([complex_id, national_id])
@@map("customer_individuals") @@map("customer_individuals")
@@ -38,6 +39,7 @@ model CustomerLegal {
complex_id String complex_id String
customer Customer @relation(fields: [customer_id], references: [id]) customer Customer @relation(fields: [customer_id], references: [id])
complex Complex @relation(fields: [complex_id], references: [id])
@@unique([complex_id, registration_number]) @@unique([complex_id, registration_number])
@@map("customer_legal") @@map("customer_legal")
+3 -1
View File
@@ -10,9 +10,11 @@ model SalesInvoice {
customer_id String? customer_id String?
account_id String account_id String
complex_id String pos_id String
customer Customer? @relation(fields: [customer_id], references: [id]) customer Customer? @relation(fields: [customer_id], references: [id])
pos Pos @relation(fields: [pos_id], references: [id])
account ConsumerAccount @relation(fields: [account_id], references: [id])
items SalesInvoiceItem[] items SalesInvoiceItem[]
payments SalesInvoicePayment[] payments SalesInvoicePayment[]
Vendored
+4 -1
View File
@@ -1,12 +1,15 @@
import { AccessTokenPayload } from '@/modules/auth/models' import { IPosPayload } from '@/common/models/posPayload.model'
import { AccessTokenPayload } from '@/common/models/tokenPayload.model'
declare global { declare global {
interface Request { interface Request {
decodedToken: AccessTokenPayload decodedToken: AccessTokenPayload
posData: IPosPayload
} }
namespace Express { namespace Express {
interface Request { interface Request {
decodedToken: AccessTokenPayload decodedToken: AccessTokenPayload
posData: IPosPayload
} }
} }
} }
-2
View File
@@ -9,7 +9,6 @@ import { EnumsModule } from './modules/enums/enums.module'
import { PosModule } from './modules/pos/pos.module' import { PosModule } from './modules/pos/pos.module'
import { SalesInvoiceItemsModule } from './modules/pos/sales-invoices/sales-invoice-items/sales-invoice-items.module' import { SalesInvoiceItemsModule } from './modules/pos/sales-invoices/sales-invoice-items/sales-invoice-items.module'
import { SalesInvoicePaymentsModule } from './modules/pos/sales-invoices/sales-invoice-payments/sales-invoice-payments.module' import { SalesInvoicePaymentsModule } from './modules/pos/sales-invoices/sales-invoice-payments/sales-invoice-payments.module'
import { ProfileModule } from './modules/profile/profile.module'
import { ServiceCategoriesModule } from './modules/service-categories/service-categories.module' import { ServiceCategoriesModule } from './modules/service-categories/service-categories.module'
import { ServicesModule } from './modules/services/services.module' import { ServicesModule } from './modules/services/services.module'
import { TriggerLogsModule } from './modules/trigger-logs/trigger-logs.module' import { TriggerLogsModule } from './modules/trigger-logs/trigger-logs.module'
@@ -31,7 +30,6 @@ import { PrismaModule } from './prisma/prisma.module'
ServicesModule, ServicesModule,
TriggerLogsModule, TriggerLogsModule,
UploadersModule, UploadersModule,
ProfileModule,
], ],
controllers: [AppController], controllers: [AppController],
providers: [AppService], providers: [AppService],
@@ -0,0 +1,29 @@
import {
BadRequestException,
createParamDecorator,
ExecutionContext,
UnauthorizedException,
} from '@nestjs/common'
import { Request } from 'express'
import { IPosPayload } from '../models/posPayload.model'
export const PosInfo = createParamDecorator(
(data: keyof IPosPayload | undefined, ctx: ExecutionContext) => {
try {
const request = ctx.switchToHttp().getRequest<Request>()
const posInfo = request.posData
if (!posInfo) {
throw new UnauthorizedException('شما به این بخش دسترسی ندارید')
}
if (data) {
return posInfo[data]
}
return posInfo
} catch (err) {
throw new BadRequestException('مشکلی در ساختار درخواست شما وجود دارد.')
}
},
)
+3 -1
View File
@@ -1,4 +1,4 @@
import { AccessTokenPayload } from '@/modules/auth/models' import { AccessTokenPayload } from '@/common/models/tokenPayload.model'
import { import {
BadRequestException, BadRequestException,
createParamDecorator, createParamDecorator,
@@ -29,6 +29,8 @@ export const TokenAccount = createParamDecorator(
// ✅ if called with no param — return full account object // ✅ if called with no param — return full account object
return account return account
} catch (err) { } catch (err) {
console.log(err)
throw new BadRequestException('مشکلی در ساختار درخواست شما وجود دارد.') throw new BadRequestException('مشکلی در ساختار درخواست شما وجود دارد.')
} }
}, },
@@ -8,15 +8,11 @@ import { Response } from 'express'
@Catch(BadRequestException) @Catch(BadRequestException)
export class ValidationExceptionFilter implements ExceptionFilter { export class ValidationExceptionFilter implements ExceptionFilter {
constructor() {
console.log('ValidationExceptionFilter initialized')
}
catch(exception: BadRequestException, host: ArgumentsHost) { catch(exception: BadRequestException, host: ArgumentsHost) {
const ctx = host.switchToHttp() const ctx = host.switchToHttp()
const response = ctx.getResponse<Response>() const response = ctx.getResponse<Response>()
const status = exception.getStatus() const status = exception.getStatus()
const exceptionResponse = exception.getResponse() const exceptionResponse = exception.getResponse()
console.log(exception)
response.status(status).json({ response.status(status).json({
statusCode: status, statusCode: status,
-57
View File
@@ -1,57 +0,0 @@
import {
CanActivate,
ExecutionContext,
Injectable,
UnauthorizedException,
} from '@nestjs/common'
import { Reflector } from '@nestjs/core'
import { JwtService } from '@nestjs/jwt'
import { IS_PUBLIC_KEY } from '../decorators/public.decorator'
import { IWithJWTPayloadRequest } from '../models/token-model'
@Injectable()
export class JwtAuthGuard implements CanActivate {
constructor(
private jwt: JwtService,
private reflector: Reflector,
) {}
async canActivate(context: ExecutionContext): Promise<boolean> {
const isPublic = this.reflector.getAllAndOverride<boolean>(IS_PUBLIC_KEY, [
context.getHandler(),
context.getClass(),
])
if (isPublic) return true
const req = context.switchToHttp().getRequest<IWithJWTPayloadRequest>()
let token: string | undefined = req.cookies?.accessToken
if (!token) {
const authHeader = (req.headers.authorization || req.headers.Authorization) as
| string
| undefined
if (authHeader && authHeader.startsWith('Bearer ')) {
token = authHeader.slice(7)
}
}
if (!token) throw new UnauthorizedException('Missing access token')
try {
const payload = this.jwt.verify(token, {
secret: process.env.JWT_SECRET || 'secret',
})
if (payload.type !== 'POS')
throw new UnauthorizedException('Invalid or expired token')
// Set the typed dataPayload to the request
req.dataPayload = payload
return true
} catch (err) {
console.log(err)
throw new UnauthorizedException('Invalid or expired token')
}
}
}
+5 -5
View File
@@ -6,8 +6,8 @@ import {
} from '@nestjs/common' } from '@nestjs/common'
import { Reflector } from '@nestjs/core' import { Reflector } from '@nestjs/core'
import { JwtService } from '@nestjs/jwt' import { JwtService } from '@nestjs/jwt'
import { Request as ExpressRequest } from 'express'
import { IS_PUBLIC_KEY } from '../decorators/public.decorator' import { IS_PUBLIC_KEY } from '../decorators/public.decorator'
import { IWithJWTPayloadRequest } from '../models/token-model'
@Injectable() @Injectable()
export class JwtAuthGuard implements CanActivate { export class JwtAuthGuard implements CanActivate {
@@ -23,7 +23,7 @@ export class JwtAuthGuard implements CanActivate {
]) ])
if (isPublic) return true if (isPublic) return true
const req = context.switchToHttp().getRequest<IWithJWTPayloadRequest>() const req = context.switchToHttp().getRequest<ExpressRequest>()
let token: string | undefined = req.cookies?.accessToken let token: string | undefined = req.cookies?.accessToken
if (!token) { if (!token) {
@@ -38,15 +38,15 @@ export class JwtAuthGuard implements CanActivate {
if (!token) throw new UnauthorizedException('Missing access token') if (!token) throw new UnauthorizedException('Missing access token')
try { try {
const payload = this.jwt.verify(token, { this.jwt.verify(token, {
secret: process.env.JWT_SECRET || 'secret', secret: process.env.JWT_SECRET,
}) })
// if (payload.type !== 'POS') // if (payload.type !== 'POS')
// throw new UnauthorizedException('Invalid or expired token') // throw new UnauthorizedException('Invalid or expired token')
// Set the typed dataPayload to the request // Set the typed dataPayload to the request
req.dataPayload = payload // req.dataPayload = payload
return true return true
} catch (err) { } catch (err) {
+130
View File
@@ -0,0 +1,130 @@
// src/common/guards/permissions.guard.ts
import { PrismaService } from '@/prisma/prisma.service'
import {
CanActivate,
ExecutionContext,
ForbiddenException,
Injectable,
} from '@nestjs/common'
import { Reflector } from '@nestjs/core'
import { JwtService } from '@nestjs/jwt'
import { Request as ExpressRequest } from 'express'
import { IS_PUBLIC_KEY } from '../decorators/public.decorator'
import { checkAndDecodeJwtToken } from '../utils/jwt-user.util'
@Injectable()
export class PosGuard implements CanActivate {
constructor(
private jwt: JwtService,
private reflector: Reflector,
private prisma: PrismaService,
) {}
async canActivate(context: ExecutionContext): Promise<boolean> {
const isPublic = this.reflector.getAllAndOverride<boolean>(IS_PUBLIC_KEY, [
context.getHandler(),
context.getClass(),
])
if (isPublic) return true
// const requiredPermissions = this.reflector.get<string[]>(
// 'permissions',
// context.getHandler(),
// )
// if (!requiredPermissions || requiredPermissions.length === 0) return true
const req = context.switchToHttp().getRequest<ExpressRequest>()
const account = checkAndDecodeJwtToken(req, this.jwt)
// const account = req.decodedToken
if (!req.url.startsWith('/api/v1/pos/')) {
return true
}
if (!account || account.type !== 'CONSUMER')
throw new ForbiddenException('شما دسترسی لازم را ندارید.')
const cookie = req.cookies
const { posId, accessToken } = cookie
if (!posId || !accessToken) {
return false
}
const pos = await this.prisma.pos.findUnique({
where: {
id: posId,
complex: {
business_activity: {
user: {
accounts: {
some: {
account_id: account.account_id,
},
},
},
},
},
},
select: {
complex: {
select: {
id: true,
business_activity_id: true,
},
},
},
})
if (!pos) {
throw new ForbiddenException('شما دسترسی لازم را ندارید.')
}
const foundedAccount = await this.prisma.account.findUnique({
where: {
id: account.account_id,
},
select: {
consumer_account: {
select: {
role: true,
},
},
},
})
if (foundedAccount?.consumer_account?.role === 'OWNER') {
return true
}
const accountPermissions = await this.prisma.permissionConsumer.findUnique({
where: {
account_id: account.account_id,
},
select: {
posPermissions: true,
businessPermissions: true,
complexPermissions: true,
},
})
if (accountPermissions?.posPermissions.some(p => p.pos_id === posId)) {
return true
}
if (
accountPermissions?.complexPermissions.some(p => p.complex_id === pos.complex.id)
) {
return true
}
if (
accountPermissions?.businessPermissions.some(
p => p.business_id === pos.complex.business_activity_id,
)
) {
return true
}
throw new ForbiddenException('شما دسترسی لازم را ندارید.')
}
}
@@ -6,3 +6,5 @@ export interface SaleInvoiceGoldTypePayload {
profit: number profit: number
} }
export interface SaleInvoiceStandardPayload {} export interface SaleInvoiceStandardPayload {}
export type SaleInvoiceType = SaleInvoiceGoldTypePayload | SaleInvoiceStandardPayload
+7
View File
@@ -0,0 +1,7 @@
export interface IPosPayload {
pos_id: string
complex_id: string
guild_id: string
business_id: string
consumer_account_id: string
}
-29
View File
@@ -1,29 +0,0 @@
import { Request as ExpressRequest } from 'express'
import { AccountType } from '../enums/enums'
export interface IWithJWTPayloadRequest extends ExpressRequest {
dataPayload?: AccessTokenPayload
}
export interface AccessTokenPayload {
userId: string
mobile_number: string
type: AccountType
username: string
pos_id: number
pos_name: string
complex_id: string
license_id: string
license_expired_at: string
// complex: {
// id: string
// name: string
// }
// license: {
// id: string
// starts_at: string
// expires_at: string
// status: string
// }
}
@@ -1,9 +1,4 @@
import { Request as ExpressRequest } from 'express' import { AccountType } from '../../generated/prisma/enums'
import { AccountType } from '../../../generated/prisma/enums'
export interface IWithJWTPayloadRequest extends ExpressRequest {
dataPayload?: AccessTokenPayload
}
export interface AccessTokenPayload { export interface AccessTokenPayload {
account_id: string account_id: string
+1 -1
View File
@@ -1,8 +1,8 @@
import { AccessTokenPayload } from '@/common/models/tokenPayload.model'
import { ITokenPayload } from '@/modules/auth/auth.utils' import { ITokenPayload } from '@/modules/auth/auth.utils'
import { UnauthorizedException } from '@nestjs/common' import { UnauthorizedException } from '@nestjs/common'
import { JwtService } from '@nestjs/jwt' import { JwtService } from '@nestjs/jwt'
import { Request } from 'express' import { Request } from 'express'
import { AccessTokenPayload } from 'modules/auth/models'
export function checkAndDecodeJwtToken( export function checkAndDecodeJwtToken(
req: Request, req: Request,
+32 -32
View File
@@ -385,17 +385,6 @@ export type IntWithAggregatesFilter<$PrismaModel = never> = {
_max?: Prisma.NestedIntFilter<$PrismaModel> _max?: Prisma.NestedIntFilter<$PrismaModel>
} }
export type DateTimeNullableFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null
notIn?: Date[] | string[] | null
lt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
}
export type EnumCustomerTypeFilter<$PrismaModel = never> = { export type EnumCustomerTypeFilter<$PrismaModel = never> = {
equals?: $Enums.CustomerType | Prisma.EnumCustomerTypeFieldRefInput<$PrismaModel> equals?: $Enums.CustomerType | Prisma.EnumCustomerTypeFieldRefInput<$PrismaModel>
in?: $Enums.CustomerType[] in?: $Enums.CustomerType[]
@@ -408,7 +397,7 @@ export type BoolNullableFilter<$PrismaModel = never> = {
not?: Prisma.NestedBoolNullableFilter<$PrismaModel> | boolean | null not?: Prisma.NestedBoolNullableFilter<$PrismaModel> | boolean | null
} }
export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = { export type DateTimeNullableFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null in?: Date[] | string[] | null
notIn?: Date[] | string[] | null notIn?: Date[] | string[] | null
@@ -416,10 +405,7 @@ export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
_min?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
} }
export type EnumCustomerTypeWithAggregatesFilter<$PrismaModel = never> = { export type EnumCustomerTypeWithAggregatesFilter<$PrismaModel = never> = {
@@ -440,6 +426,20 @@ export type BoolNullableWithAggregatesFilter<$PrismaModel = never> = {
_max?: Prisma.NestedBoolNullableFilter<$PrismaModel> _max?: Prisma.NestedBoolNullableFilter<$PrismaModel>
} }
export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null
notIn?: Date[] | string[] | null
lt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
_min?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
}
export type BoolFilter<$PrismaModel = never> = { export type BoolFilter<$PrismaModel = never> = {
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel> equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
@@ -997,17 +997,6 @@ export type NestedFloatFilter<$PrismaModel = never> = {
not?: Prisma.NestedFloatFilter<$PrismaModel> | number not?: Prisma.NestedFloatFilter<$PrismaModel> | number
} }
export type NestedDateTimeNullableFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null
notIn?: Date[] | string[] | null
lt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
}
export type NestedEnumCustomerTypeFilter<$PrismaModel = never> = { export type NestedEnumCustomerTypeFilter<$PrismaModel = never> = {
equals?: $Enums.CustomerType | Prisma.EnumCustomerTypeFieldRefInput<$PrismaModel> equals?: $Enums.CustomerType | Prisma.EnumCustomerTypeFieldRefInput<$PrismaModel>
in?: $Enums.CustomerType[] in?: $Enums.CustomerType[]
@@ -1020,7 +1009,7 @@ export type NestedBoolNullableFilter<$PrismaModel = never> = {
not?: Prisma.NestedBoolNullableFilter<$PrismaModel> | boolean | null not?: Prisma.NestedBoolNullableFilter<$PrismaModel> | boolean | null
} }
export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = { export type NestedDateTimeNullableFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null in?: Date[] | string[] | null
notIn?: Date[] | string[] | null notIn?: Date[] | string[] | null
@@ -1028,10 +1017,7 @@ export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
_min?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
} }
export type NestedEnumCustomerTypeWithAggregatesFilter<$PrismaModel = never> = { export type NestedEnumCustomerTypeWithAggregatesFilter<$PrismaModel = never> = {
@@ -1052,6 +1038,20 @@ export type NestedBoolNullableWithAggregatesFilter<$PrismaModel = never> = {
_max?: Prisma.NestedBoolNullableFilter<$PrismaModel> _max?: Prisma.NestedBoolNullableFilter<$PrismaModel>
} }
export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel> | null
in?: Date[] | string[] | null
notIn?: Date[] | string[] | null
lt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
lte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gt?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
gte?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
not?: Prisma.NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
_min?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
}
export type NestedBoolFilter<$PrismaModel = never> = { export type NestedBoolFilter<$PrismaModel = never> = {
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel> equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
File diff suppressed because one or more lines are too long
@@ -2842,12 +2842,11 @@ export type UserDevicesScalarFieldEnum = (typeof UserDevicesScalarFieldEnum)[key
export const CustomerScalarFieldEnum = { export const CustomerScalarFieldEnum = {
id: 'id', id: 'id',
type: 'type',
is_favorite: 'is_favorite',
created_at: 'created_at', created_at: 'created_at',
updated_at: 'updated_at', updated_at: 'updated_at',
deleted_at: 'deleted_at', deleted_at: 'deleted_at'
type: 'type',
complex_id: 'complex_id',
is_favorite: 'is_favorite'
} as const } as const
export type CustomerScalarFieldEnum = (typeof CustomerScalarFieldEnum)[keyof typeof CustomerScalarFieldEnum] export type CustomerScalarFieldEnum = (typeof CustomerScalarFieldEnum)[keyof typeof CustomerScalarFieldEnum]
@@ -2937,7 +2936,7 @@ export const SalesInvoiceScalarFieldEnum = {
updated_at: 'updated_at', updated_at: 'updated_at',
customer_id: 'customer_id', customer_id: 'customer_id',
account_id: 'account_id', account_id: 'account_id',
complex_id: 'complex_id' pos_id: 'pos_id'
} as const } as const
export type SalesInvoiceScalarFieldEnum = (typeof SalesInvoiceScalarFieldEnum)[keyof typeof SalesInvoiceScalarFieldEnum] export type SalesInvoiceScalarFieldEnum = (typeof SalesInvoiceScalarFieldEnum)[keyof typeof SalesInvoiceScalarFieldEnum]
@@ -3239,8 +3238,7 @@ export type UserDevicesOrderByRelevanceFieldEnum = (typeof UserDevicesOrderByRel
export const CustomerOrderByRelevanceFieldEnum = { export const CustomerOrderByRelevanceFieldEnum = {
id: 'id', id: 'id'
complex_id: 'complex_id'
} as const } as const
export type CustomerOrderByRelevanceFieldEnum = (typeof CustomerOrderByRelevanceFieldEnum)[keyof typeof CustomerOrderByRelevanceFieldEnum] export type CustomerOrderByRelevanceFieldEnum = (typeof CustomerOrderByRelevanceFieldEnum)[keyof typeof CustomerOrderByRelevanceFieldEnum]
@@ -3329,7 +3327,7 @@ export const SalesInvoiceOrderByRelevanceFieldEnum = {
notes: 'notes', notes: 'notes',
customer_id: 'customer_id', customer_id: 'customer_id',
account_id: 'account_id', account_id: 'account_id',
complex_id: 'complex_id' pos_id: 'pos_id'
} as const } as const
export type SalesInvoiceOrderByRelevanceFieldEnum = (typeof SalesInvoiceOrderByRelevanceFieldEnum)[keyof typeof SalesInvoiceOrderByRelevanceFieldEnum] export type SalesInvoiceOrderByRelevanceFieldEnum = (typeof SalesInvoiceOrderByRelevanceFieldEnum)[keyof typeof SalesInvoiceOrderByRelevanceFieldEnum]
@@ -357,12 +357,11 @@ export type UserDevicesScalarFieldEnum = (typeof UserDevicesScalarFieldEnum)[key
export const CustomerScalarFieldEnum = { export const CustomerScalarFieldEnum = {
id: 'id', id: 'id',
type: 'type',
is_favorite: 'is_favorite',
created_at: 'created_at', created_at: 'created_at',
updated_at: 'updated_at', updated_at: 'updated_at',
deleted_at: 'deleted_at', deleted_at: 'deleted_at'
type: 'type',
complex_id: 'complex_id',
is_favorite: 'is_favorite'
} as const } as const
export type CustomerScalarFieldEnum = (typeof CustomerScalarFieldEnum)[keyof typeof CustomerScalarFieldEnum] export type CustomerScalarFieldEnum = (typeof CustomerScalarFieldEnum)[keyof typeof CustomerScalarFieldEnum]
@@ -452,7 +451,7 @@ export const SalesInvoiceScalarFieldEnum = {
updated_at: 'updated_at', updated_at: 'updated_at',
customer_id: 'customer_id', customer_id: 'customer_id',
account_id: 'account_id', account_id: 'account_id',
complex_id: 'complex_id' pos_id: 'pos_id'
} as const } as const
export type SalesInvoiceScalarFieldEnum = (typeof SalesInvoiceScalarFieldEnum)[keyof typeof SalesInvoiceScalarFieldEnum] export type SalesInvoiceScalarFieldEnum = (typeof SalesInvoiceScalarFieldEnum)[keyof typeof SalesInvoiceScalarFieldEnum]
@@ -754,8 +753,7 @@ export type UserDevicesOrderByRelevanceFieldEnum = (typeof UserDevicesOrderByRel
export const CustomerOrderByRelevanceFieldEnum = { export const CustomerOrderByRelevanceFieldEnum = {
id: 'id', id: 'id'
complex_id: 'complex_id'
} as const } as const
export type CustomerOrderByRelevanceFieldEnum = (typeof CustomerOrderByRelevanceFieldEnum)[keyof typeof CustomerOrderByRelevanceFieldEnum] export type CustomerOrderByRelevanceFieldEnum = (typeof CustomerOrderByRelevanceFieldEnum)[keyof typeof CustomerOrderByRelevanceFieldEnum]
@@ -844,7 +842,7 @@ export const SalesInvoiceOrderByRelevanceFieldEnum = {
notes: 'notes', notes: 'notes',
customer_id: 'customer_id', customer_id: 'customer_id',
account_id: 'account_id', account_id: 'account_id',
complex_id: 'complex_id' pos_id: 'pos_id'
} as const } as const
export type SalesInvoiceOrderByRelevanceFieldEnum = (typeof SalesInvoiceOrderByRelevanceFieldEnum)[keyof typeof SalesInvoiceOrderByRelevanceFieldEnum] export type SalesInvoiceOrderByRelevanceFieldEnum = (typeof SalesInvoiceOrderByRelevanceFieldEnum)[keyof typeof SalesInvoiceOrderByRelevanceFieldEnum]
+308
View File
@@ -203,6 +203,8 @@ export type ComplexWhereInput = {
goods?: Prisma.GoodListRelationFilter goods?: Prisma.GoodListRelationFilter
good_categories?: Prisma.GoodCategoryListRelationFilter good_categories?: Prisma.GoodCategoryListRelationFilter
permissionComplexes?: Prisma.PermissionComplexListRelationFilter permissionComplexes?: Prisma.PermissionComplexListRelationFilter
customerIndividuals?: Prisma.CustomerIndividualListRelationFilter
customerLegals?: Prisma.CustomerLegalListRelationFilter
} }
export type ComplexOrderByWithRelationInput = { export type ComplexOrderByWithRelationInput = {
@@ -218,6 +220,8 @@ export type ComplexOrderByWithRelationInput = {
goods?: Prisma.GoodOrderByRelationAggregateInput goods?: Prisma.GoodOrderByRelationAggregateInput
good_categories?: Prisma.GoodCategoryOrderByRelationAggregateInput good_categories?: Prisma.GoodCategoryOrderByRelationAggregateInput
permissionComplexes?: Prisma.PermissionComplexOrderByRelationAggregateInput permissionComplexes?: Prisma.PermissionComplexOrderByRelationAggregateInput
customerIndividuals?: Prisma.CustomerIndividualOrderByRelationAggregateInput
customerLegals?: Prisma.CustomerLegalOrderByRelationAggregateInput
_relevance?: Prisma.ComplexOrderByRelevanceInput _relevance?: Prisma.ComplexOrderByRelevanceInput
} }
@@ -237,6 +241,8 @@ export type ComplexWhereUniqueInput = Prisma.AtLeast<{
goods?: Prisma.GoodListRelationFilter goods?: Prisma.GoodListRelationFilter
good_categories?: Prisma.GoodCategoryListRelationFilter good_categories?: Prisma.GoodCategoryListRelationFilter
permissionComplexes?: Prisma.PermissionComplexListRelationFilter permissionComplexes?: Prisma.PermissionComplexListRelationFilter
customerIndividuals?: Prisma.CustomerIndividualListRelationFilter
customerLegals?: Prisma.CustomerLegalListRelationFilter
}, "id"> }, "id">
export type ComplexOrderByWithAggregationInput = { export type ComplexOrderByWithAggregationInput = {
@@ -277,6 +283,8 @@ export type ComplexCreateInput = {
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateInput = { export type ComplexUncheckedCreateInput = {
@@ -291,6 +299,8 @@ export type ComplexUncheckedCreateInput = {
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexUpdateInput = { export type ComplexUpdateInput = {
@@ -305,6 +315,8 @@ export type ComplexUpdateInput = {
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateInput = { export type ComplexUncheckedUpdateInput = {
@@ -319,6 +331,8 @@ export type ComplexUncheckedUpdateInput = {
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexCreateManyInput = { export type ComplexCreateManyInput = {
@@ -476,6 +490,34 @@ export type ComplexUpdateOneRequiredWithoutPermissionComplexesNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.ComplexUpdateToOneWithWhereWithoutPermissionComplexesInput, Prisma.ComplexUpdateWithoutPermissionComplexesInput>, Prisma.ComplexUncheckedUpdateWithoutPermissionComplexesInput> update?: Prisma.XOR<Prisma.XOR<Prisma.ComplexUpdateToOneWithWhereWithoutPermissionComplexesInput, Prisma.ComplexUpdateWithoutPermissionComplexesInput>, Prisma.ComplexUncheckedUpdateWithoutPermissionComplexesInput>
} }
export type ComplexCreateNestedOneWithoutCustomerIndividualsInput = {
create?: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedCreateWithoutCustomerIndividualsInput>
connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutCustomerIndividualsInput
connect?: Prisma.ComplexWhereUniqueInput
}
export type ComplexUpdateOneRequiredWithoutCustomerIndividualsNestedInput = {
create?: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedCreateWithoutCustomerIndividualsInput>
connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutCustomerIndividualsInput
upsert?: Prisma.ComplexUpsertWithoutCustomerIndividualsInput
connect?: Prisma.ComplexWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.ComplexUpdateToOneWithWhereWithoutCustomerIndividualsInput, Prisma.ComplexUpdateWithoutCustomerIndividualsInput>, Prisma.ComplexUncheckedUpdateWithoutCustomerIndividualsInput>
}
export type ComplexCreateNestedOneWithoutCustomerLegalsInput = {
create?: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedCreateWithoutCustomerLegalsInput>
connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutCustomerLegalsInput
connect?: Prisma.ComplexWhereUniqueInput
}
export type ComplexUpdateOneRequiredWithoutCustomerLegalsNestedInput = {
create?: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedCreateWithoutCustomerLegalsInput>
connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutCustomerLegalsInput
upsert?: Prisma.ComplexUpsertWithoutCustomerLegalsInput
connect?: Prisma.ComplexWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.ComplexUpdateToOneWithWhereWithoutCustomerLegalsInput, Prisma.ComplexUpdateWithoutCustomerLegalsInput>, Prisma.ComplexUncheckedUpdateWithoutCustomerLegalsInput>
}
export type ComplexCreateNestedOneWithoutGoodsInput = { export type ComplexCreateNestedOneWithoutGoodsInput = {
create?: Prisma.XOR<Prisma.ComplexCreateWithoutGoodsInput, Prisma.ComplexUncheckedCreateWithoutGoodsInput> create?: Prisma.XOR<Prisma.ComplexCreateWithoutGoodsInput, Prisma.ComplexUncheckedCreateWithoutGoodsInput>
connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutGoodsInput connectOrCreate?: Prisma.ComplexCreateOrConnectWithoutGoodsInput
@@ -519,6 +561,8 @@ export type ComplexCreateWithoutBusiness_activityInput = {
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateWithoutBusiness_activityInput = { export type ComplexUncheckedCreateWithoutBusiness_activityInput = {
@@ -532,6 +576,8 @@ export type ComplexUncheckedCreateWithoutBusiness_activityInput = {
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexCreateOrConnectWithoutBusiness_activityInput = { export type ComplexCreateOrConnectWithoutBusiness_activityInput = {
@@ -584,6 +630,8 @@ export type ComplexCreateWithoutPos_listInput = {
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateWithoutPos_listInput = { export type ComplexUncheckedCreateWithoutPos_listInput = {
@@ -597,6 +645,8 @@ export type ComplexUncheckedCreateWithoutPos_listInput = {
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexCreateOrConnectWithoutPos_listInput = { export type ComplexCreateOrConnectWithoutPos_listInput = {
@@ -626,6 +676,8 @@ export type ComplexUpdateWithoutPos_listInput = {
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateWithoutPos_listInput = { export type ComplexUncheckedUpdateWithoutPos_listInput = {
@@ -639,6 +691,8 @@ export type ComplexUncheckedUpdateWithoutPos_listInput = {
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexCreateWithoutPermissionComplexesInput = { export type ComplexCreateWithoutPermissionComplexesInput = {
@@ -652,6 +706,8 @@ export type ComplexCreateWithoutPermissionComplexesInput = {
pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateWithoutPermissionComplexesInput = { export type ComplexUncheckedCreateWithoutPermissionComplexesInput = {
@@ -665,6 +721,8 @@ export type ComplexUncheckedCreateWithoutPermissionComplexesInput = {
pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexCreateOrConnectWithoutPermissionComplexesInput = { export type ComplexCreateOrConnectWithoutPermissionComplexesInput = {
@@ -694,6 +752,8 @@ export type ComplexUpdateWithoutPermissionComplexesInput = {
pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateWithoutPermissionComplexesInput = { export type ComplexUncheckedUpdateWithoutPermissionComplexesInput = {
@@ -707,6 +767,160 @@ export type ComplexUncheckedUpdateWithoutPermissionComplexesInput = {
pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
}
export type ComplexCreateWithoutCustomerIndividualsInput = {
id?: string
name: string
address?: string | null
tax_id?: string | null
created_at?: Date | string
updated_at?: Date | string
business_activity: Prisma.BusinessActivityCreateNestedOneWithoutComplexesInput
pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
}
export type ComplexUncheckedCreateWithoutCustomerIndividualsInput = {
id?: string
name: string
address?: string | null
tax_id?: string | null
created_at?: Date | string
updated_at?: Date | string
business_activity_id: string
pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
}
export type ComplexCreateOrConnectWithoutCustomerIndividualsInput = {
where: Prisma.ComplexWhereUniqueInput
create: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedCreateWithoutCustomerIndividualsInput>
}
export type ComplexUpsertWithoutCustomerIndividualsInput = {
update: Prisma.XOR<Prisma.ComplexUpdateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedUpdateWithoutCustomerIndividualsInput>
create: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedCreateWithoutCustomerIndividualsInput>
where?: Prisma.ComplexWhereInput
}
export type ComplexUpdateToOneWithWhereWithoutCustomerIndividualsInput = {
where?: Prisma.ComplexWhereInput
data: Prisma.XOR<Prisma.ComplexUpdateWithoutCustomerIndividualsInput, Prisma.ComplexUncheckedUpdateWithoutCustomerIndividualsInput>
}
export type ComplexUpdateWithoutCustomerIndividualsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
tax_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
business_activity?: Prisma.BusinessActivityUpdateOneRequiredWithoutComplexesNestedInput
pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
}
export type ComplexUncheckedUpdateWithoutCustomerIndividualsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
tax_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
business_activity_id?: Prisma.StringFieldUpdateOperationsInput | string
pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
}
export type ComplexCreateWithoutCustomerLegalsInput = {
id?: string
name: string
address?: string | null
tax_id?: string | null
created_at?: Date | string
updated_at?: Date | string
business_activity: Prisma.BusinessActivityCreateNestedOneWithoutComplexesInput
pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
}
export type ComplexUncheckedCreateWithoutCustomerLegalsInput = {
id?: string
name: string
address?: string | null
tax_id?: string | null
created_at?: Date | string
updated_at?: Date | string
business_activity_id: string
pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
}
export type ComplexCreateOrConnectWithoutCustomerLegalsInput = {
where: Prisma.ComplexWhereUniqueInput
create: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedCreateWithoutCustomerLegalsInput>
}
export type ComplexUpsertWithoutCustomerLegalsInput = {
update: Prisma.XOR<Prisma.ComplexUpdateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedUpdateWithoutCustomerLegalsInput>
create: Prisma.XOR<Prisma.ComplexCreateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedCreateWithoutCustomerLegalsInput>
where?: Prisma.ComplexWhereInput
}
export type ComplexUpdateToOneWithWhereWithoutCustomerLegalsInput = {
where?: Prisma.ComplexWhereInput
data: Prisma.XOR<Prisma.ComplexUpdateWithoutCustomerLegalsInput, Prisma.ComplexUncheckedUpdateWithoutCustomerLegalsInput>
}
export type ComplexUpdateWithoutCustomerLegalsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
tax_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
business_activity?: Prisma.BusinessActivityUpdateOneRequiredWithoutComplexesNestedInput
pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
}
export type ComplexUncheckedUpdateWithoutCustomerLegalsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
tax_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
business_activity_id?: Prisma.StringFieldUpdateOperationsInput | string
pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexCreateWithoutGoodsInput = { export type ComplexCreateWithoutGoodsInput = {
@@ -720,6 +934,8 @@ export type ComplexCreateWithoutGoodsInput = {
pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateWithoutGoodsInput = { export type ComplexUncheckedCreateWithoutGoodsInput = {
@@ -733,6 +949,8 @@ export type ComplexUncheckedCreateWithoutGoodsInput = {
pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput
good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput good_categories?: Prisma.GoodCategoryUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexCreateOrConnectWithoutGoodsInput = { export type ComplexCreateOrConnectWithoutGoodsInput = {
@@ -762,6 +980,8 @@ export type ComplexUpdateWithoutGoodsInput = {
pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateWithoutGoodsInput = { export type ComplexUncheckedUpdateWithoutGoodsInput = {
@@ -775,6 +995,8 @@ export type ComplexUncheckedUpdateWithoutGoodsInput = {
pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexCreateWithoutGood_categoriesInput = { export type ComplexCreateWithoutGood_categoriesInput = {
@@ -788,6 +1010,8 @@ export type ComplexCreateWithoutGood_categoriesInput = {
pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodCreateNestedManyWithoutComplexInput goods?: Prisma.GoodCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalCreateNestedManyWithoutComplexInput
} }
export type ComplexUncheckedCreateWithoutGood_categoriesInput = { export type ComplexUncheckedCreateWithoutGood_categoriesInput = {
@@ -801,6 +1025,8 @@ export type ComplexUncheckedCreateWithoutGood_categoriesInput = {
pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput pos_list?: Prisma.PosUncheckedCreateNestedManyWithoutComplexInput
goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput goods?: Prisma.GoodUncheckedCreateNestedManyWithoutComplexInput
permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput permissionComplexes?: Prisma.PermissionComplexUncheckedCreateNestedManyWithoutComplexInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedManyWithoutComplexInput
} }
export type ComplexCreateOrConnectWithoutGood_categoriesInput = { export type ComplexCreateOrConnectWithoutGood_categoriesInput = {
@@ -830,6 +1056,8 @@ export type ComplexUpdateWithoutGood_categoriesInput = {
pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateWithoutGood_categoriesInput = { export type ComplexUncheckedUpdateWithoutGood_categoriesInput = {
@@ -843,6 +1071,8 @@ export type ComplexUncheckedUpdateWithoutGood_categoriesInput = {
pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput pos_list?: Prisma.PosUncheckedUpdateManyWithoutComplexNestedInput
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexCreateManyBusiness_activityInput = { export type ComplexCreateManyBusiness_activityInput = {
@@ -865,6 +1095,8 @@ export type ComplexUpdateWithoutBusiness_activityInput = {
goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateWithoutBusiness_activityInput = { export type ComplexUncheckedUpdateWithoutBusiness_activityInput = {
@@ -878,6 +1110,8 @@ export type ComplexUncheckedUpdateWithoutBusiness_activityInput = {
goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput goods?: Prisma.GoodUncheckedUpdateManyWithoutComplexNestedInput
good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput good_categories?: Prisma.GoodCategoryUncheckedUpdateManyWithoutComplexNestedInput
permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput permissionComplexes?: Prisma.PermissionComplexUncheckedUpdateManyWithoutComplexNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput
} }
export type ComplexUncheckedUpdateManyWithoutBusiness_activityInput = { export type ComplexUncheckedUpdateManyWithoutBusiness_activityInput = {
@@ -899,6 +1133,8 @@ export type ComplexCountOutputType = {
goods: number goods: number
good_categories: number good_categories: number
permissionComplexes: number permissionComplexes: number
customerIndividuals: number
customerLegals: number
} }
export type ComplexCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type ComplexCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
@@ -906,6 +1142,8 @@ export type ComplexCountOutputTypeSelect<ExtArgs extends runtime.Types.Extension
goods?: boolean | ComplexCountOutputTypeCountGoodsArgs goods?: boolean | ComplexCountOutputTypeCountGoodsArgs
good_categories?: boolean | ComplexCountOutputTypeCountGood_categoriesArgs good_categories?: boolean | ComplexCountOutputTypeCountGood_categoriesArgs
permissionComplexes?: boolean | ComplexCountOutputTypeCountPermissionComplexesArgs permissionComplexes?: boolean | ComplexCountOutputTypeCountPermissionComplexesArgs
customerIndividuals?: boolean | ComplexCountOutputTypeCountCustomerIndividualsArgs
customerLegals?: boolean | ComplexCountOutputTypeCountCustomerLegalsArgs
} }
/** /**
@@ -946,6 +1184,20 @@ export type ComplexCountOutputTypeCountPermissionComplexesArgs<ExtArgs extends r
where?: Prisma.PermissionComplexWhereInput where?: Prisma.PermissionComplexWhereInput
} }
/**
* ComplexCountOutputType without action
*/
export type ComplexCountOutputTypeCountCustomerIndividualsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
where?: Prisma.CustomerIndividualWhereInput
}
/**
* ComplexCountOutputType without action
*/
export type ComplexCountOutputTypeCountCustomerLegalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
where?: Prisma.CustomerLegalWhereInput
}
export type ComplexSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type ComplexSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
id?: boolean id?: boolean
@@ -960,6 +1212,8 @@ export type ComplexSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs
goods?: boolean | Prisma.Complex$goodsArgs<ExtArgs> goods?: boolean | Prisma.Complex$goodsArgs<ExtArgs>
good_categories?: boolean | Prisma.Complex$good_categoriesArgs<ExtArgs> good_categories?: boolean | Prisma.Complex$good_categoriesArgs<ExtArgs>
permissionComplexes?: boolean | Prisma.Complex$permissionComplexesArgs<ExtArgs> permissionComplexes?: boolean | Prisma.Complex$permissionComplexesArgs<ExtArgs>
customerIndividuals?: boolean | Prisma.Complex$customerIndividualsArgs<ExtArgs>
customerLegals?: boolean | Prisma.Complex$customerLegalsArgs<ExtArgs>
_count?: boolean | Prisma.ComplexCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.ComplexCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["complex"]> }, ExtArgs["result"]["complex"]>
@@ -982,6 +1236,8 @@ export type ComplexInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs
goods?: boolean | Prisma.Complex$goodsArgs<ExtArgs> goods?: boolean | Prisma.Complex$goodsArgs<ExtArgs>
good_categories?: boolean | Prisma.Complex$good_categoriesArgs<ExtArgs> good_categories?: boolean | Prisma.Complex$good_categoriesArgs<ExtArgs>
permissionComplexes?: boolean | Prisma.Complex$permissionComplexesArgs<ExtArgs> permissionComplexes?: boolean | Prisma.Complex$permissionComplexesArgs<ExtArgs>
customerIndividuals?: boolean | Prisma.Complex$customerIndividualsArgs<ExtArgs>
customerLegals?: boolean | Prisma.Complex$customerLegalsArgs<ExtArgs>
_count?: boolean | Prisma.ComplexCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.ComplexCountOutputTypeDefaultArgs<ExtArgs>
} }
@@ -993,6 +1249,8 @@ export type $ComplexPayload<ExtArgs extends runtime.Types.Extensions.InternalArg
goods: Prisma.$GoodPayload<ExtArgs>[] goods: Prisma.$GoodPayload<ExtArgs>[]
good_categories: Prisma.$GoodCategoryPayload<ExtArgs>[] good_categories: Prisma.$GoodCategoryPayload<ExtArgs>[]
permissionComplexes: Prisma.$PermissionComplexPayload<ExtArgs>[] permissionComplexes: Prisma.$PermissionComplexPayload<ExtArgs>[]
customerIndividuals: Prisma.$CustomerIndividualPayload<ExtArgs>[]
customerLegals: Prisma.$CustomerLegalPayload<ExtArgs>[]
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
id: string id: string
@@ -1347,6 +1605,8 @@ export interface Prisma__ComplexClient<T, Null = never, ExtArgs extends runtime.
goods<T extends Prisma.Complex$goodsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$goodsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$GoodPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> goods<T extends Prisma.Complex$goodsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$goodsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$GoodPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
good_categories<T extends Prisma.Complex$good_categoriesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$good_categoriesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$GoodCategoryPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> good_categories<T extends Prisma.Complex$good_categoriesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$good_categoriesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$GoodCategoryPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
permissionComplexes<T extends Prisma.Complex$permissionComplexesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$permissionComplexesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionComplexPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> permissionComplexes<T extends Prisma.Complex$permissionComplexesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$permissionComplexesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionComplexPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
customerIndividuals<T extends Prisma.Complex$customerIndividualsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$customerIndividualsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$CustomerIndividualPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
customerLegals<T extends Prisma.Complex$customerLegalsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Complex$customerLegalsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$CustomerLegalPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
@@ -1821,6 +2081,54 @@ export type Complex$permissionComplexesArgs<ExtArgs extends runtime.Types.Extens
distinct?: Prisma.PermissionComplexScalarFieldEnum | Prisma.PermissionComplexScalarFieldEnum[] distinct?: Prisma.PermissionComplexScalarFieldEnum | Prisma.PermissionComplexScalarFieldEnum[]
} }
/**
* Complex.customerIndividuals
*/
export type Complex$customerIndividualsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerIndividual
*/
select?: Prisma.CustomerIndividualSelect<ExtArgs> | null
/**
* Omit specific fields from the CustomerIndividual
*/
omit?: Prisma.CustomerIndividualOmit<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: Prisma.CustomerIndividualInclude<ExtArgs> | null
where?: Prisma.CustomerIndividualWhereInput
orderBy?: Prisma.CustomerIndividualOrderByWithRelationInput | Prisma.CustomerIndividualOrderByWithRelationInput[]
cursor?: Prisma.CustomerIndividualWhereUniqueInput
take?: number
skip?: number
distinct?: Prisma.CustomerIndividualScalarFieldEnum | Prisma.CustomerIndividualScalarFieldEnum[]
}
/**
* Complex.customerLegals
*/
export type Complex$customerLegalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerLegal
*/
select?: Prisma.CustomerLegalSelect<ExtArgs> | null
/**
* Omit specific fields from the CustomerLegal
*/
omit?: Prisma.CustomerLegalOmit<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: Prisma.CustomerLegalInclude<ExtArgs> | null
where?: Prisma.CustomerLegalWhereInput
orderBy?: Prisma.CustomerLegalOrderByWithRelationInput | Prisma.CustomerLegalOrderByWithRelationInput[]
cursor?: Prisma.CustomerLegalWhereUniqueInput
take?: number
skip?: number
distinct?: Prisma.CustomerLegalScalarFieldEnum | Prisma.CustomerLegalScalarFieldEnum[]
}
/** /**
* Complex without action * Complex without action
*/ */
@@ -193,6 +193,7 @@ export type ConsumerAccountWhereInput = {
user?: Prisma.XOR<Prisma.ConsumerScalarRelationFilter, Prisma.ConsumerWhereInput> user?: Prisma.XOR<Prisma.ConsumerScalarRelationFilter, Prisma.ConsumerWhereInput>
account?: Prisma.XOR<Prisma.AccountScalarRelationFilter, Prisma.AccountWhereInput> account?: Prisma.XOR<Prisma.AccountScalarRelationFilter, Prisma.AccountWhereInput>
permissions?: Prisma.PermissionConsumerListRelationFilter permissions?: Prisma.PermissionConsumerListRelationFilter
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
} }
export type ConsumerAccountOrderByWithRelationInput = { export type ConsumerAccountOrderByWithRelationInput = {
@@ -205,6 +206,7 @@ export type ConsumerAccountOrderByWithRelationInput = {
user?: Prisma.ConsumerOrderByWithRelationInput user?: Prisma.ConsumerOrderByWithRelationInput
account?: Prisma.AccountOrderByWithRelationInput account?: Prisma.AccountOrderByWithRelationInput
permissions?: Prisma.PermissionConsumerOrderByRelationAggregateInput permissions?: Prisma.PermissionConsumerOrderByRelationAggregateInput
salesInvoices?: Prisma.SalesInvoiceOrderByRelationAggregateInput
_relevance?: Prisma.ConsumerAccountOrderByRelevanceInput _relevance?: Prisma.ConsumerAccountOrderByRelevanceInput
} }
@@ -221,6 +223,7 @@ export type ConsumerAccountWhereUniqueInput = Prisma.AtLeast<{
user?: Prisma.XOR<Prisma.ConsumerScalarRelationFilter, Prisma.ConsumerWhereInput> user?: Prisma.XOR<Prisma.ConsumerScalarRelationFilter, Prisma.ConsumerWhereInput>
account?: Prisma.XOR<Prisma.AccountScalarRelationFilter, Prisma.AccountWhereInput> account?: Prisma.XOR<Prisma.AccountScalarRelationFilter, Prisma.AccountWhereInput>
permissions?: Prisma.PermissionConsumerListRelationFilter permissions?: Prisma.PermissionConsumerListRelationFilter
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
}, "id" | "account_id"> }, "id" | "account_id">
export type ConsumerAccountOrderByWithAggregationInput = { export type ConsumerAccountOrderByWithAggregationInput = {
@@ -255,6 +258,7 @@ export type ConsumerAccountCreateInput = {
user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput
account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput
permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountUncheckedCreateInput = { export type ConsumerAccountUncheckedCreateInput = {
@@ -265,6 +269,7 @@ export type ConsumerAccountUncheckedCreateInput = {
user_id: string user_id: string
account_id: string account_id: string
permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountUpdateInput = { export type ConsumerAccountUpdateInput = {
@@ -275,6 +280,7 @@ export type ConsumerAccountUpdateInput = {
user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput
account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput
permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountUncheckedUpdateInput = { export type ConsumerAccountUncheckedUpdateInput = {
@@ -285,6 +291,7 @@ export type ConsumerAccountUncheckedUpdateInput = {
user_id?: Prisma.StringFieldUpdateOperationsInput | string user_id?: Prisma.StringFieldUpdateOperationsInput | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountCreateManyInput = { export type ConsumerAccountCreateManyInput = {
@@ -457,6 +464,20 @@ export type ConsumerAccountUpdateOneRequiredWithoutPermissionsNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.ConsumerAccountUpdateToOneWithWhereWithoutPermissionsInput, Prisma.ConsumerAccountUpdateWithoutPermissionsInput>, Prisma.ConsumerAccountUncheckedUpdateWithoutPermissionsInput> update?: Prisma.XOR<Prisma.XOR<Prisma.ConsumerAccountUpdateToOneWithWhereWithoutPermissionsInput, Prisma.ConsumerAccountUpdateWithoutPermissionsInput>, Prisma.ConsumerAccountUncheckedUpdateWithoutPermissionsInput>
} }
export type ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput = {
create?: Prisma.XOR<Prisma.ConsumerAccountCreateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedCreateWithoutSalesInvoicesInput>
connectOrCreate?: Prisma.ConsumerAccountCreateOrConnectWithoutSalesInvoicesInput
connect?: Prisma.ConsumerAccountWhereUniqueInput
}
export type ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput = {
create?: Prisma.XOR<Prisma.ConsumerAccountCreateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedCreateWithoutSalesInvoicesInput>
connectOrCreate?: Prisma.ConsumerAccountCreateOrConnectWithoutSalesInvoicesInput
upsert?: Prisma.ConsumerAccountUpsertWithoutSalesInvoicesInput
connect?: Prisma.ConsumerAccountWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.ConsumerAccountUpdateToOneWithWhereWithoutSalesInvoicesInput, Prisma.ConsumerAccountUpdateWithoutSalesInvoicesInput>, Prisma.ConsumerAccountUncheckedUpdateWithoutSalesInvoicesInput>
}
export type ConsumerAccountCreateWithoutAccountInput = { export type ConsumerAccountCreateWithoutAccountInput = {
id?: string id?: string
role: $Enums.ConsumerRole role: $Enums.ConsumerRole
@@ -464,6 +485,7 @@ export type ConsumerAccountCreateWithoutAccountInput = {
updated_at?: Date | string updated_at?: Date | string
user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput
permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountUncheckedCreateWithoutAccountInput = { export type ConsumerAccountUncheckedCreateWithoutAccountInput = {
@@ -473,6 +495,7 @@ export type ConsumerAccountUncheckedCreateWithoutAccountInput = {
updated_at?: Date | string updated_at?: Date | string
user_id: string user_id: string
permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountCreateOrConnectWithoutAccountInput = { export type ConsumerAccountCreateOrConnectWithoutAccountInput = {
@@ -498,6 +521,7 @@ export type ConsumerAccountUpdateWithoutAccountInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput
permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountUncheckedUpdateWithoutAccountInput = { export type ConsumerAccountUncheckedUpdateWithoutAccountInput = {
@@ -507,6 +531,7 @@ export type ConsumerAccountUncheckedUpdateWithoutAccountInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user_id?: Prisma.StringFieldUpdateOperationsInput | string user_id?: Prisma.StringFieldUpdateOperationsInput | string
permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountCreateWithoutUserInput = { export type ConsumerAccountCreateWithoutUserInput = {
@@ -516,6 +541,7 @@ export type ConsumerAccountCreateWithoutUserInput = {
updated_at?: Date | string updated_at?: Date | string
account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput
permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountUncheckedCreateWithoutUserInput = { export type ConsumerAccountUncheckedCreateWithoutUserInput = {
@@ -525,6 +551,7 @@ export type ConsumerAccountUncheckedCreateWithoutUserInput = {
updated_at?: Date | string updated_at?: Date | string
account_id: string account_id: string
permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountCreateOrConnectWithoutUserInput = { export type ConsumerAccountCreateOrConnectWithoutUserInput = {
@@ -572,6 +599,7 @@ export type ConsumerAccountCreateWithoutPermissionsInput = {
updated_at?: Date | string updated_at?: Date | string
user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput
account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountUncheckedCreateWithoutPermissionsInput = { export type ConsumerAccountUncheckedCreateWithoutPermissionsInput = {
@@ -581,6 +609,7 @@ export type ConsumerAccountUncheckedCreateWithoutPermissionsInput = {
updated_at?: Date | string updated_at?: Date | string
user_id: string user_id: string
account_id: string account_id: string
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutAccountInput
} }
export type ConsumerAccountCreateOrConnectWithoutPermissionsInput = { export type ConsumerAccountCreateOrConnectWithoutPermissionsInput = {
@@ -606,6 +635,7 @@ export type ConsumerAccountUpdateWithoutPermissionsInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput
account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountUncheckedUpdateWithoutPermissionsInput = { export type ConsumerAccountUncheckedUpdateWithoutPermissionsInput = {
@@ -615,6 +645,63 @@ export type ConsumerAccountUncheckedUpdateWithoutPermissionsInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user_id?: Prisma.StringFieldUpdateOperationsInput | string user_id?: Prisma.StringFieldUpdateOperationsInput | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutAccountNestedInput
}
export type ConsumerAccountCreateWithoutSalesInvoicesInput = {
id?: string
role: $Enums.ConsumerRole
created_at?: Date | string
updated_at?: Date | string
user: Prisma.ConsumerCreateNestedOneWithoutAccountsInput
account: Prisma.AccountCreateNestedOneWithoutConsumer_accountInput
permissions?: Prisma.PermissionConsumerCreateNestedManyWithoutAccountInput
}
export type ConsumerAccountUncheckedCreateWithoutSalesInvoicesInput = {
id?: string
role: $Enums.ConsumerRole
created_at?: Date | string
updated_at?: Date | string
user_id: string
account_id: string
permissions?: Prisma.PermissionConsumerUncheckedCreateNestedManyWithoutAccountInput
}
export type ConsumerAccountCreateOrConnectWithoutSalesInvoicesInput = {
where: Prisma.ConsumerAccountWhereUniqueInput
create: Prisma.XOR<Prisma.ConsumerAccountCreateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedCreateWithoutSalesInvoicesInput>
}
export type ConsumerAccountUpsertWithoutSalesInvoicesInput = {
update: Prisma.XOR<Prisma.ConsumerAccountUpdateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedUpdateWithoutSalesInvoicesInput>
create: Prisma.XOR<Prisma.ConsumerAccountCreateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedCreateWithoutSalesInvoicesInput>
where?: Prisma.ConsumerAccountWhereInput
}
export type ConsumerAccountUpdateToOneWithWhereWithoutSalesInvoicesInput = {
where?: Prisma.ConsumerAccountWhereInput
data: Prisma.XOR<Prisma.ConsumerAccountUpdateWithoutSalesInvoicesInput, Prisma.ConsumerAccountUncheckedUpdateWithoutSalesInvoicesInput>
}
export type ConsumerAccountUpdateWithoutSalesInvoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
role?: Prisma.EnumConsumerRoleFieldUpdateOperationsInput | $Enums.ConsumerRole
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user?: Prisma.ConsumerUpdateOneRequiredWithoutAccountsNestedInput
account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput
permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput
}
export type ConsumerAccountUncheckedUpdateWithoutSalesInvoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
role?: Prisma.EnumConsumerRoleFieldUpdateOperationsInput | $Enums.ConsumerRole
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
user_id?: Prisma.StringFieldUpdateOperationsInput | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string
permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountCreateManyUserInput = { export type ConsumerAccountCreateManyUserInput = {
@@ -632,6 +719,7 @@ export type ConsumerAccountUpdateWithoutUserInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput account?: Prisma.AccountUpdateOneRequiredWithoutConsumer_accountNestedInput
permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountUncheckedUpdateWithoutUserInput = { export type ConsumerAccountUncheckedUpdateWithoutUserInput = {
@@ -641,6 +729,7 @@ export type ConsumerAccountUncheckedUpdateWithoutUserInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput permissions?: Prisma.PermissionConsumerUncheckedUpdateManyWithoutAccountNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutAccountNestedInput
} }
export type ConsumerAccountUncheckedUpdateManyWithoutUserInput = { export type ConsumerAccountUncheckedUpdateManyWithoutUserInput = {
@@ -658,10 +747,12 @@ export type ConsumerAccountUncheckedUpdateManyWithoutUserInput = {
export type ConsumerAccountCountOutputType = { export type ConsumerAccountCountOutputType = {
permissions: number permissions: number
salesInvoices: number
} }
export type ConsumerAccountCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type ConsumerAccountCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
permissions?: boolean | ConsumerAccountCountOutputTypeCountPermissionsArgs permissions?: boolean | ConsumerAccountCountOutputTypeCountPermissionsArgs
salesInvoices?: boolean | ConsumerAccountCountOutputTypeCountSalesInvoicesArgs
} }
/** /**
@@ -681,6 +772,13 @@ export type ConsumerAccountCountOutputTypeCountPermissionsArgs<ExtArgs extends r
where?: Prisma.PermissionConsumerWhereInput where?: Prisma.PermissionConsumerWhereInput
} }
/**
* ConsumerAccountCountOutputType without action
*/
export type ConsumerAccountCountOutputTypeCountSalesInvoicesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
where?: Prisma.SalesInvoiceWhereInput
}
export type ConsumerAccountSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type ConsumerAccountSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
id?: boolean id?: boolean
@@ -692,6 +790,7 @@ export type ConsumerAccountSelect<ExtArgs extends runtime.Types.Extensions.Inter
user?: boolean | Prisma.ConsumerDefaultArgs<ExtArgs> user?: boolean | Prisma.ConsumerDefaultArgs<ExtArgs>
account?: boolean | Prisma.AccountDefaultArgs<ExtArgs> account?: boolean | Prisma.AccountDefaultArgs<ExtArgs>
permissions?: boolean | Prisma.ConsumerAccount$permissionsArgs<ExtArgs> permissions?: boolean | Prisma.ConsumerAccount$permissionsArgs<ExtArgs>
salesInvoices?: boolean | Prisma.ConsumerAccount$salesInvoicesArgs<ExtArgs>
_count?: boolean | Prisma.ConsumerAccountCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.ConsumerAccountCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["consumerAccount"]> }, ExtArgs["result"]["consumerAccount"]>
@@ -711,6 +810,7 @@ export type ConsumerAccountInclude<ExtArgs extends runtime.Types.Extensions.Inte
user?: boolean | Prisma.ConsumerDefaultArgs<ExtArgs> user?: boolean | Prisma.ConsumerDefaultArgs<ExtArgs>
account?: boolean | Prisma.AccountDefaultArgs<ExtArgs> account?: boolean | Prisma.AccountDefaultArgs<ExtArgs>
permissions?: boolean | Prisma.ConsumerAccount$permissionsArgs<ExtArgs> permissions?: boolean | Prisma.ConsumerAccount$permissionsArgs<ExtArgs>
salesInvoices?: boolean | Prisma.ConsumerAccount$salesInvoicesArgs<ExtArgs>
_count?: boolean | Prisma.ConsumerAccountCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.ConsumerAccountCountOutputTypeDefaultArgs<ExtArgs>
} }
@@ -720,6 +820,7 @@ export type $ConsumerAccountPayload<ExtArgs extends runtime.Types.Extensions.Int
user: Prisma.$ConsumerPayload<ExtArgs> user: Prisma.$ConsumerPayload<ExtArgs>
account: Prisma.$AccountPayload<ExtArgs> account: Prisma.$AccountPayload<ExtArgs>
permissions: Prisma.$PermissionConsumerPayload<ExtArgs>[] permissions: Prisma.$PermissionConsumerPayload<ExtArgs>[]
salesInvoices: Prisma.$SalesInvoicePayload<ExtArgs>[]
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
id: string id: string
@@ -1071,6 +1172,7 @@ export interface Prisma__ConsumerAccountClient<T, Null = never, ExtArgs extends
user<T extends Prisma.ConsumerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerDefaultArgs<ExtArgs>>): Prisma.Prisma__ConsumerClient<runtime.Types.Result.GetResult<Prisma.$ConsumerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions> user<T extends Prisma.ConsumerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerDefaultArgs<ExtArgs>>): Prisma.Prisma__ConsumerClient<runtime.Types.Result.GetResult<Prisma.$ConsumerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
account<T extends Prisma.AccountDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.AccountDefaultArgs<ExtArgs>>): Prisma.Prisma__AccountClient<runtime.Types.Result.GetResult<Prisma.$AccountPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions> account<T extends Prisma.AccountDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.AccountDefaultArgs<ExtArgs>>): Prisma.Prisma__AccountClient<runtime.Types.Result.GetResult<Prisma.$AccountPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
permissions<T extends Prisma.ConsumerAccount$permissionsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerAccount$permissionsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionConsumerPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> permissions<T extends Prisma.ConsumerAccount$permissionsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerAccount$permissionsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionConsumerPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
salesInvoices<T extends Prisma.ConsumerAccount$salesInvoicesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerAccount$salesInvoicesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
@@ -1472,6 +1574,30 @@ export type ConsumerAccount$permissionsArgs<ExtArgs extends runtime.Types.Extens
distinct?: Prisma.PermissionConsumerScalarFieldEnum | Prisma.PermissionConsumerScalarFieldEnum[] distinct?: Prisma.PermissionConsumerScalarFieldEnum | Prisma.PermissionConsumerScalarFieldEnum[]
} }
/**
* ConsumerAccount.salesInvoices
*/
export type ConsumerAccount$salesInvoicesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SalesInvoice
*/
select?: Prisma.SalesInvoiceSelect<ExtArgs> | null
/**
* Omit specific fields from the SalesInvoice
*/
omit?: Prisma.SalesInvoiceOmit<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: Prisma.SalesInvoiceInclude<ExtArgs> | null
where?: Prisma.SalesInvoiceWhereInput
orderBy?: Prisma.SalesInvoiceOrderByWithRelationInput | Prisma.SalesInvoiceOrderByWithRelationInput[]
cursor?: Prisma.SalesInvoiceWhereUniqueInput
take?: number
skip?: number
distinct?: Prisma.SalesInvoiceScalarFieldEnum | Prisma.SalesInvoiceScalarFieldEnum[]
}
/** /**
* ConsumerAccount without action * ConsumerAccount without action
*/ */
+161 -199
View File
@@ -26,64 +26,58 @@ export type AggregateCustomer = {
export type CustomerMinAggregateOutputType = { export type CustomerMinAggregateOutputType = {
id: string | null id: string | null
type: $Enums.CustomerType | null
is_favorite: boolean | null
created_at: Date | null created_at: Date | null
updated_at: Date | null updated_at: Date | null
deleted_at: Date | null deleted_at: Date | null
type: $Enums.CustomerType | null
complex_id: string | null
is_favorite: boolean | null
} }
export type CustomerMaxAggregateOutputType = { export type CustomerMaxAggregateOutputType = {
id: string | null id: string | null
type: $Enums.CustomerType | null
is_favorite: boolean | null
created_at: Date | null created_at: Date | null
updated_at: Date | null updated_at: Date | null
deleted_at: Date | null deleted_at: Date | null
type: $Enums.CustomerType | null
complex_id: string | null
is_favorite: boolean | null
} }
export type CustomerCountAggregateOutputType = { export type CustomerCountAggregateOutputType = {
id: number id: number
type: number
is_favorite: number
created_at: number created_at: number
updated_at: number updated_at: number
deleted_at: number deleted_at: number
type: number
complex_id: number
is_favorite: number
_all: number _all: number
} }
export type CustomerMinAggregateInputType = { export type CustomerMinAggregateInputType = {
id?: true id?: true
type?: true
is_favorite?: true
created_at?: true created_at?: true
updated_at?: true updated_at?: true
deleted_at?: true deleted_at?: true
type?: true
complex_id?: true
is_favorite?: true
} }
export type CustomerMaxAggregateInputType = { export type CustomerMaxAggregateInputType = {
id?: true id?: true
type?: true
is_favorite?: true
created_at?: true created_at?: true
updated_at?: true updated_at?: true
deleted_at?: true deleted_at?: true
type?: true
complex_id?: true
is_favorite?: true
} }
export type CustomerCountAggregateInputType = { export type CustomerCountAggregateInputType = {
id?: true id?: true
type?: true
is_favorite?: true
created_at?: true created_at?: true
updated_at?: true updated_at?: true
deleted_at?: true deleted_at?: true
type?: true
complex_id?: true
is_favorite?: true
_all?: true _all?: true
} }
@@ -161,12 +155,11 @@ export type CustomerGroupByArgs<ExtArgs extends runtime.Types.Extensions.Interna
export type CustomerGroupByOutputType = { export type CustomerGroupByOutputType = {
id: string id: string
type: $Enums.CustomerType
is_favorite: boolean | null
created_at: Date created_at: Date
updated_at: Date updated_at: Date
deleted_at: Date | null deleted_at: Date | null
type: $Enums.CustomerType
complex_id: string
is_favorite: boolean | null
_count: CustomerCountAggregateOutputType | null _count: CustomerCountAggregateOutputType | null
_min: CustomerMinAggregateOutputType | null _min: CustomerMinAggregateOutputType | null
_max: CustomerMaxAggregateOutputType | null _max: CustomerMaxAggregateOutputType | null
@@ -192,28 +185,26 @@ export type CustomerWhereInput = {
OR?: Prisma.CustomerWhereInput[] OR?: Prisma.CustomerWhereInput[]
NOT?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[] NOT?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[]
id?: Prisma.StringFilter<"Customer"> | string id?: Prisma.StringFilter<"Customer"> | string
type?: Prisma.EnumCustomerTypeFilter<"Customer"> | $Enums.CustomerType
is_favorite?: Prisma.BoolNullableFilter<"Customer"> | boolean | null
created_at?: Prisma.DateTimeFilter<"Customer"> | Date | string created_at?: Prisma.DateTimeFilter<"Customer"> | Date | string
updated_at?: Prisma.DateTimeFilter<"Customer"> | Date | string updated_at?: Prisma.DateTimeFilter<"Customer"> | Date | string
deleted_at?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null deleted_at?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null
type?: Prisma.EnumCustomerTypeFilter<"Customer"> | $Enums.CustomerType
complex_id?: Prisma.StringFilter<"Customer"> | string
is_favorite?: Prisma.BoolNullableFilter<"Customer"> | boolean | null
sales_invoices?: Prisma.SalesInvoiceListRelationFilter sales_invoices?: Prisma.SalesInvoiceListRelationFilter
customerIndividuals?: Prisma.XOR<Prisma.CustomerIndividualNullableScalarRelationFilter, Prisma.CustomerIndividualWhereInput> | null customer_individuals?: Prisma.XOR<Prisma.CustomerIndividualNullableScalarRelationFilter, Prisma.CustomerIndividualWhereInput> | null
customerLegals?: Prisma.XOR<Prisma.CustomerLegalNullableScalarRelationFilter, Prisma.CustomerLegalWhereInput> | null customer_legals?: Prisma.XOR<Prisma.CustomerLegalNullableScalarRelationFilter, Prisma.CustomerLegalWhereInput> | null
} }
export type CustomerOrderByWithRelationInput = { export type CustomerOrderByWithRelationInput = {
id?: Prisma.SortOrder id?: Prisma.SortOrder
type?: Prisma.SortOrder
is_favorite?: Prisma.SortOrderInput | Prisma.SortOrder
created_at?: Prisma.SortOrder created_at?: Prisma.SortOrder
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
deleted_at?: Prisma.SortOrderInput | Prisma.SortOrder deleted_at?: Prisma.SortOrderInput | Prisma.SortOrder
type?: Prisma.SortOrder
complex_id?: Prisma.SortOrder
is_favorite?: Prisma.SortOrderInput | Prisma.SortOrder
sales_invoices?: Prisma.SalesInvoiceOrderByRelationAggregateInput sales_invoices?: Prisma.SalesInvoiceOrderByRelationAggregateInput
customerIndividuals?: Prisma.CustomerIndividualOrderByWithRelationInput customer_individuals?: Prisma.CustomerIndividualOrderByWithRelationInput
customerLegals?: Prisma.CustomerLegalOrderByWithRelationInput customer_legals?: Prisma.CustomerLegalOrderByWithRelationInput
_relevance?: Prisma.CustomerOrderByRelevanceInput _relevance?: Prisma.CustomerOrderByRelevanceInput
} }
@@ -222,25 +213,23 @@ export type CustomerWhereUniqueInput = Prisma.AtLeast<{
AND?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[] AND?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[]
OR?: Prisma.CustomerWhereInput[] OR?: Prisma.CustomerWhereInput[]
NOT?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[] NOT?: Prisma.CustomerWhereInput | Prisma.CustomerWhereInput[]
type?: Prisma.EnumCustomerTypeFilter<"Customer"> | $Enums.CustomerType
is_favorite?: Prisma.BoolNullableFilter<"Customer"> | boolean | null
created_at?: Prisma.DateTimeFilter<"Customer"> | Date | string created_at?: Prisma.DateTimeFilter<"Customer"> | Date | string
updated_at?: Prisma.DateTimeFilter<"Customer"> | Date | string updated_at?: Prisma.DateTimeFilter<"Customer"> | Date | string
deleted_at?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null deleted_at?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null
type?: Prisma.EnumCustomerTypeFilter<"Customer"> | $Enums.CustomerType
complex_id?: Prisma.StringFilter<"Customer"> | string
is_favorite?: Prisma.BoolNullableFilter<"Customer"> | boolean | null
sales_invoices?: Prisma.SalesInvoiceListRelationFilter sales_invoices?: Prisma.SalesInvoiceListRelationFilter
customerIndividuals?: Prisma.XOR<Prisma.CustomerIndividualNullableScalarRelationFilter, Prisma.CustomerIndividualWhereInput> | null customer_individuals?: Prisma.XOR<Prisma.CustomerIndividualNullableScalarRelationFilter, Prisma.CustomerIndividualWhereInput> | null
customerLegals?: Prisma.XOR<Prisma.CustomerLegalNullableScalarRelationFilter, Prisma.CustomerLegalWhereInput> | null customer_legals?: Prisma.XOR<Prisma.CustomerLegalNullableScalarRelationFilter, Prisma.CustomerLegalWhereInput> | null
}, "id"> }, "id">
export type CustomerOrderByWithAggregationInput = { export type CustomerOrderByWithAggregationInput = {
id?: Prisma.SortOrder id?: Prisma.SortOrder
type?: Prisma.SortOrder
is_favorite?: Prisma.SortOrderInput | Prisma.SortOrder
created_at?: Prisma.SortOrder created_at?: Prisma.SortOrder
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
deleted_at?: Prisma.SortOrderInput | Prisma.SortOrder deleted_at?: Prisma.SortOrderInput | Prisma.SortOrder
type?: Prisma.SortOrder
complex_id?: Prisma.SortOrder
is_favorite?: Prisma.SortOrderInput | Prisma.SortOrder
_count?: Prisma.CustomerCountOrderByAggregateInput _count?: Prisma.CustomerCountOrderByAggregateInput
_max?: Prisma.CustomerMaxOrderByAggregateInput _max?: Prisma.CustomerMaxOrderByAggregateInput
_min?: Prisma.CustomerMinOrderByAggregateInput _min?: Prisma.CustomerMinOrderByAggregateInput
@@ -251,94 +240,86 @@ export type CustomerScalarWhereWithAggregatesInput = {
OR?: Prisma.CustomerScalarWhereWithAggregatesInput[] OR?: Prisma.CustomerScalarWhereWithAggregatesInput[]
NOT?: Prisma.CustomerScalarWhereWithAggregatesInput | Prisma.CustomerScalarWhereWithAggregatesInput[] NOT?: Prisma.CustomerScalarWhereWithAggregatesInput | Prisma.CustomerScalarWhereWithAggregatesInput[]
id?: Prisma.StringWithAggregatesFilter<"Customer"> | string id?: Prisma.StringWithAggregatesFilter<"Customer"> | string
type?: Prisma.EnumCustomerTypeWithAggregatesFilter<"Customer"> | $Enums.CustomerType
is_favorite?: Prisma.BoolNullableWithAggregatesFilter<"Customer"> | boolean | null
created_at?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string created_at?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string
updated_at?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string updated_at?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string
deleted_at?: Prisma.DateTimeNullableWithAggregatesFilter<"Customer"> | Date | string | null deleted_at?: Prisma.DateTimeNullableWithAggregatesFilter<"Customer"> | Date | string | null
type?: Prisma.EnumCustomerTypeWithAggregatesFilter<"Customer"> | $Enums.CustomerType
complex_id?: Prisma.StringWithAggregatesFilter<"Customer"> | string
is_favorite?: Prisma.BoolNullableWithAggregatesFilter<"Customer"> | boolean | null
} }
export type CustomerCreateInput = { export type CustomerCreateInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput customer_individuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput customer_legals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput
} }
export type CustomerUncheckedCreateInput = { export type CustomerUncheckedCreateInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput customer_individuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput customer_legals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput
} }
export type CustomerUpdateInput = { export type CustomerUpdateInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput customer_individuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput customer_legals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput
} }
export type CustomerUncheckedUpdateInput = { export type CustomerUncheckedUpdateInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput customer_individuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput customer_legals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput
} }
export type CustomerCreateManyInput = { export type CustomerCreateManyInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
} }
export type CustomerUpdateManyMutationInput = { export type CustomerUpdateManyMutationInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
} }
export type CustomerUncheckedUpdateManyInput = { export type CustomerUncheckedUpdateManyInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
} }
export type CustomerOrderByRelevanceInput = { export type CustomerOrderByRelevanceInput = {
@@ -349,32 +330,29 @@ export type CustomerOrderByRelevanceInput = {
export type CustomerCountOrderByAggregateInput = { export type CustomerCountOrderByAggregateInput = {
id?: Prisma.SortOrder id?: Prisma.SortOrder
type?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
created_at?: Prisma.SortOrder created_at?: Prisma.SortOrder
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
deleted_at?: Prisma.SortOrder deleted_at?: Prisma.SortOrder
type?: Prisma.SortOrder
complex_id?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
} }
export type CustomerMaxOrderByAggregateInput = { export type CustomerMaxOrderByAggregateInput = {
id?: Prisma.SortOrder id?: Prisma.SortOrder
type?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
created_at?: Prisma.SortOrder created_at?: Prisma.SortOrder
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
deleted_at?: Prisma.SortOrder deleted_at?: Prisma.SortOrder
type?: Prisma.SortOrder
complex_id?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
} }
export type CustomerMinOrderByAggregateInput = { export type CustomerMinOrderByAggregateInput = {
id?: Prisma.SortOrder id?: Prisma.SortOrder
type?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
created_at?: Prisma.SortOrder created_at?: Prisma.SortOrder
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
deleted_at?: Prisma.SortOrder deleted_at?: Prisma.SortOrder
type?: Prisma.SortOrder
complex_id?: Prisma.SortOrder
is_favorite?: Prisma.SortOrder
} }
export type CustomerScalarRelationFilter = { export type CustomerScalarRelationFilter = {
@@ -387,10 +365,6 @@ export type CustomerNullableScalarRelationFilter = {
isNot?: Prisma.CustomerWhereInput | null isNot?: Prisma.CustomerWhereInput | null
} }
export type NullableDateTimeFieldUpdateOperationsInput = {
set?: Date | string | null
}
export type EnumCustomerTypeFieldUpdateOperationsInput = { export type EnumCustomerTypeFieldUpdateOperationsInput = {
set?: $Enums.CustomerType set?: $Enums.CustomerType
} }
@@ -399,32 +373,36 @@ export type NullableBoolFieldUpdateOperationsInput = {
set?: boolean | null set?: boolean | null
} }
export type CustomerCreateNestedOneWithoutCustomerIndividualsInput = { export type NullableDateTimeFieldUpdateOperationsInput = {
create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedCreateWithoutCustomerIndividualsInput> set?: Date | string | null
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomerIndividualsInput }
export type CustomerCreateNestedOneWithoutCustomer_individualsInput = {
create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_individualsInput>
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomer_individualsInput
connect?: Prisma.CustomerWhereUniqueInput connect?: Prisma.CustomerWhereUniqueInput
} }
export type CustomerUpdateOneRequiredWithoutCustomerIndividualsNestedInput = { export type CustomerUpdateOneRequiredWithoutCustomer_individualsNestedInput = {
create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedCreateWithoutCustomerIndividualsInput> create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_individualsInput>
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomerIndividualsInput connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomer_individualsInput
upsert?: Prisma.CustomerUpsertWithoutCustomerIndividualsInput upsert?: Prisma.CustomerUpsertWithoutCustomer_individualsInput
connect?: Prisma.CustomerWhereUniqueInput connect?: Prisma.CustomerWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutCustomerIndividualsInput, Prisma.CustomerUpdateWithoutCustomerIndividualsInput>, Prisma.CustomerUncheckedUpdateWithoutCustomerIndividualsInput> update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutCustomer_individualsInput, Prisma.CustomerUpdateWithoutCustomer_individualsInput>, Prisma.CustomerUncheckedUpdateWithoutCustomer_individualsInput>
} }
export type CustomerCreateNestedOneWithoutCustomerLegalsInput = { export type CustomerCreateNestedOneWithoutCustomer_legalsInput = {
create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedCreateWithoutCustomerLegalsInput> create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_legalsInput>
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomerLegalsInput connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomer_legalsInput
connect?: Prisma.CustomerWhereUniqueInput connect?: Prisma.CustomerWhereUniqueInput
} }
export type CustomerUpdateOneRequiredWithoutCustomerLegalsNestedInput = { export type CustomerUpdateOneRequiredWithoutCustomer_legalsNestedInput = {
create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedCreateWithoutCustomerLegalsInput> create?: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_legalsInput>
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomerLegalsInput connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutCustomer_legalsInput
upsert?: Prisma.CustomerUpsertWithoutCustomerLegalsInput upsert?: Prisma.CustomerUpsertWithoutCustomer_legalsInput
connect?: Prisma.CustomerWhereUniqueInput connect?: Prisma.CustomerWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutCustomerLegalsInput, Prisma.CustomerUpdateWithoutCustomerLegalsInput>, Prisma.CustomerUncheckedUpdateWithoutCustomerLegalsInput> update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutCustomer_legalsInput, Prisma.CustomerUpdateWithoutCustomer_legalsInput>, Prisma.CustomerUncheckedUpdateWithoutCustomer_legalsInput>
} }
export type CustomerCreateNestedOneWithoutSales_invoicesInput = { export type CustomerCreateNestedOneWithoutSales_invoicesInput = {
@@ -443,156 +421,146 @@ export type CustomerUpdateOneWithoutSales_invoicesNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutSales_invoicesInput, Prisma.CustomerUpdateWithoutSales_invoicesInput>, Prisma.CustomerUncheckedUpdateWithoutSales_invoicesInput> update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutSales_invoicesInput, Prisma.CustomerUpdateWithoutSales_invoicesInput>, Prisma.CustomerUncheckedUpdateWithoutSales_invoicesInput>
} }
export type CustomerCreateWithoutCustomerIndividualsInput = { export type CustomerCreateWithoutCustomer_individualsInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput customer_legals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput
} }
export type CustomerUncheckedCreateWithoutCustomerIndividualsInput = { export type CustomerUncheckedCreateWithoutCustomer_individualsInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput customer_legals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput
} }
export type CustomerCreateOrConnectWithoutCustomerIndividualsInput = { export type CustomerCreateOrConnectWithoutCustomer_individualsInput = {
where: Prisma.CustomerWhereUniqueInput where: Prisma.CustomerWhereUniqueInput
create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedCreateWithoutCustomerIndividualsInput> create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_individualsInput>
} }
export type CustomerUpsertWithoutCustomerIndividualsInput = { export type CustomerUpsertWithoutCustomer_individualsInput = {
update: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedUpdateWithoutCustomerIndividualsInput> update: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedUpdateWithoutCustomer_individualsInput>
create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedCreateWithoutCustomerIndividualsInput> create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_individualsInput>
where?: Prisma.CustomerWhereInput where?: Prisma.CustomerWhereInput
} }
export type CustomerUpdateToOneWithWhereWithoutCustomerIndividualsInput = { export type CustomerUpdateToOneWithWhereWithoutCustomer_individualsInput = {
where?: Prisma.CustomerWhereInput where?: Prisma.CustomerWhereInput
data: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomerIndividualsInput, Prisma.CustomerUncheckedUpdateWithoutCustomerIndividualsInput> data: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomer_individualsInput, Prisma.CustomerUncheckedUpdateWithoutCustomer_individualsInput>
} }
export type CustomerUpdateWithoutCustomerIndividualsInput = { export type CustomerUpdateWithoutCustomer_individualsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput customer_legals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput
} }
export type CustomerUncheckedUpdateWithoutCustomerIndividualsInput = { export type CustomerUncheckedUpdateWithoutCustomer_individualsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput customer_legals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput
} }
export type CustomerCreateWithoutCustomerLegalsInput = { export type CustomerCreateWithoutCustomer_legalsInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
customerIndividuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput customer_individuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput
} }
export type CustomerUncheckedCreateWithoutCustomerLegalsInput = { export type CustomerUncheckedCreateWithoutCustomer_legalsInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType
complex_id: string
is_favorite?: boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput sales_invoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput customer_individuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput
} }
export type CustomerCreateOrConnectWithoutCustomerLegalsInput = { export type CustomerCreateOrConnectWithoutCustomer_legalsInput = {
where: Prisma.CustomerWhereUniqueInput where: Prisma.CustomerWhereUniqueInput
create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedCreateWithoutCustomerLegalsInput> create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_legalsInput>
} }
export type CustomerUpsertWithoutCustomerLegalsInput = { export type CustomerUpsertWithoutCustomer_legalsInput = {
update: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedUpdateWithoutCustomerLegalsInput> update: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedUpdateWithoutCustomer_legalsInput>
create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedCreateWithoutCustomerLegalsInput> create: Prisma.XOR<Prisma.CustomerCreateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedCreateWithoutCustomer_legalsInput>
where?: Prisma.CustomerWhereInput where?: Prisma.CustomerWhereInput
} }
export type CustomerUpdateToOneWithWhereWithoutCustomerLegalsInput = { export type CustomerUpdateToOneWithWhereWithoutCustomer_legalsInput = {
where?: Prisma.CustomerWhereInput where?: Prisma.CustomerWhereInput
data: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomerLegalsInput, Prisma.CustomerUncheckedUpdateWithoutCustomerLegalsInput> data: Prisma.XOR<Prisma.CustomerUpdateWithoutCustomer_legalsInput, Prisma.CustomerUncheckedUpdateWithoutCustomer_legalsInput>
} }
export type CustomerUpdateWithoutCustomerLegalsInput = { export type CustomerUpdateWithoutCustomer_legalsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
customerIndividuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput customer_individuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput
} }
export type CustomerUncheckedUpdateWithoutCustomerLegalsInput = { export type CustomerUncheckedUpdateWithoutCustomer_legalsInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput sales_invoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput customer_individuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput
} }
export type CustomerCreateWithoutSales_invoicesInput = { export type CustomerCreateWithoutSales_invoicesInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType customer_individuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput
complex_id: string customer_legals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput
is_favorite?: boolean | null
customerIndividuals?: Prisma.CustomerIndividualCreateNestedOneWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalCreateNestedOneWithoutCustomerInput
} }
export type CustomerUncheckedCreateWithoutSales_invoicesInput = { export type CustomerUncheckedCreateWithoutSales_invoicesInput = {
id?: string id?: string
type: $Enums.CustomerType
is_favorite?: boolean | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
deleted_at?: Date | string | null deleted_at?: Date | string | null
type: $Enums.CustomerType customer_individuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput
complex_id: string customer_legals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput
is_favorite?: boolean | null
customerIndividuals?: Prisma.CustomerIndividualUncheckedCreateNestedOneWithoutCustomerInput
customerLegals?: Prisma.CustomerLegalUncheckedCreateNestedOneWithoutCustomerInput
} }
export type CustomerCreateOrConnectWithoutSales_invoicesInput = { export type CustomerCreateOrConnectWithoutSales_invoicesInput = {
@@ -613,26 +581,24 @@ export type CustomerUpdateToOneWithWhereWithoutSales_invoicesInput = {
export type CustomerUpdateWithoutSales_invoicesInput = { export type CustomerUpdateWithoutSales_invoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType customer_individuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput
complex_id?: Prisma.StringFieldUpdateOperationsInput | string customer_legals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
customerIndividuals?: Prisma.CustomerIndividualUpdateOneWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUpdateOneWithoutCustomerNestedInput
} }
export type CustomerUncheckedUpdateWithoutSales_invoicesInput = { export type CustomerUncheckedUpdateWithoutSales_invoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string id?: Prisma.StringFieldUpdateOperationsInput | string
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null deleted_at?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
type?: Prisma.EnumCustomerTypeFieldUpdateOperationsInput | $Enums.CustomerType customer_individuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput
complex_id?: Prisma.StringFieldUpdateOperationsInput | string customer_legals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput
is_favorite?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
customerIndividuals?: Prisma.CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput
customerLegals?: Prisma.CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput
} }
@@ -668,15 +634,14 @@ export type CustomerCountOutputTypeCountSales_invoicesArgs<ExtArgs extends runti
export type CustomerSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type CustomerSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
id?: boolean id?: boolean
type?: boolean
is_favorite?: boolean
created_at?: boolean created_at?: boolean
updated_at?: boolean updated_at?: boolean
deleted_at?: boolean deleted_at?: boolean
type?: boolean
complex_id?: boolean
is_favorite?: boolean
sales_invoices?: boolean | Prisma.Customer$sales_invoicesArgs<ExtArgs> sales_invoices?: boolean | Prisma.Customer$sales_invoicesArgs<ExtArgs>
customerIndividuals?: boolean | Prisma.Customer$customerIndividualsArgs<ExtArgs> customer_individuals?: boolean | Prisma.Customer$customer_individualsArgs<ExtArgs>
customerLegals?: boolean | Prisma.Customer$customerLegalsArgs<ExtArgs> customer_legals?: boolean | Prisma.Customer$customer_legalsArgs<ExtArgs>
_count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["customer"]> }, ExtArgs["result"]["customer"]>
@@ -684,19 +649,18 @@ export type CustomerSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs
export type CustomerSelectScalar = { export type CustomerSelectScalar = {
id?: boolean id?: boolean
type?: boolean
is_favorite?: boolean
created_at?: boolean created_at?: boolean
updated_at?: boolean updated_at?: boolean
deleted_at?: boolean deleted_at?: boolean
type?: boolean
complex_id?: boolean
is_favorite?: boolean
} }
export type CustomerOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "created_at" | "updated_at" | "deleted_at" | "type" | "complex_id" | "is_favorite", ExtArgs["result"]["customer"]> export type CustomerOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "type" | "is_favorite" | "created_at" | "updated_at" | "deleted_at", ExtArgs["result"]["customer"]>
export type CustomerInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type CustomerInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
sales_invoices?: boolean | Prisma.Customer$sales_invoicesArgs<ExtArgs> sales_invoices?: boolean | Prisma.Customer$sales_invoicesArgs<ExtArgs>
customerIndividuals?: boolean | Prisma.Customer$customerIndividualsArgs<ExtArgs> customer_individuals?: boolean | Prisma.Customer$customer_individualsArgs<ExtArgs>
customerLegals?: boolean | Prisma.Customer$customerLegalsArgs<ExtArgs> customer_legals?: boolean | Prisma.Customer$customer_legalsArgs<ExtArgs>
_count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs>
} }
@@ -704,17 +668,16 @@ export type $CustomerPayload<ExtArgs extends runtime.Types.Extensions.InternalAr
name: "Customer" name: "Customer"
objects: { objects: {
sales_invoices: Prisma.$SalesInvoicePayload<ExtArgs>[] sales_invoices: Prisma.$SalesInvoicePayload<ExtArgs>[]
customerIndividuals: Prisma.$CustomerIndividualPayload<ExtArgs> | null customer_individuals: Prisma.$CustomerIndividualPayload<ExtArgs> | null
customerLegals: Prisma.$CustomerLegalPayload<ExtArgs> | null customer_legals: Prisma.$CustomerLegalPayload<ExtArgs> | null
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
id: string id: string
type: $Enums.CustomerType
is_favorite: boolean | null
created_at: Date created_at: Date
updated_at: Date updated_at: Date
deleted_at: Date | null deleted_at: Date | null
type: $Enums.CustomerType
complex_id: string
is_favorite: boolean | null
}, ExtArgs["result"]["customer"]> }, ExtArgs["result"]["customer"]>
composites: {} composites: {}
} }
@@ -1056,8 +1019,8 @@ readonly fields: CustomerFieldRefs;
export interface Prisma__CustomerClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> { export interface Prisma__CustomerClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise" readonly [Symbol.toStringTag]: "PrismaPromise"
sales_invoices<T extends Prisma.Customer$sales_invoicesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$sales_invoicesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> sales_invoices<T extends Prisma.Customer$sales_invoicesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$sales_invoicesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
customerIndividuals<T extends Prisma.Customer$customerIndividualsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$customerIndividualsArgs<ExtArgs>>): Prisma.Prisma__CustomerIndividualClient<runtime.Types.Result.GetResult<Prisma.$CustomerIndividualPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> customer_individuals<T extends Prisma.Customer$customer_individualsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$customer_individualsArgs<ExtArgs>>): Prisma.Prisma__CustomerIndividualClient<runtime.Types.Result.GetResult<Prisma.$CustomerIndividualPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
customerLegals<T extends Prisma.Customer$customerLegalsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$customerLegalsArgs<ExtArgs>>): Prisma.Prisma__CustomerLegalClient<runtime.Types.Result.GetResult<Prisma.$CustomerLegalPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> customer_legals<T extends Prisma.Customer$customer_legalsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$customer_legalsArgs<ExtArgs>>): Prisma.Prisma__CustomerLegalClient<runtime.Types.Result.GetResult<Prisma.$CustomerLegalPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
@@ -1088,12 +1051,11 @@ export interface Prisma__CustomerClient<T, Null = never, ExtArgs extends runtime
*/ */
export interface CustomerFieldRefs { export interface CustomerFieldRefs {
readonly id: Prisma.FieldRef<"Customer", 'String'> readonly id: Prisma.FieldRef<"Customer", 'String'>
readonly type: Prisma.FieldRef<"Customer", 'CustomerType'>
readonly is_favorite: Prisma.FieldRef<"Customer", 'Boolean'>
readonly created_at: Prisma.FieldRef<"Customer", 'DateTime'> readonly created_at: Prisma.FieldRef<"Customer", 'DateTime'>
readonly updated_at: Prisma.FieldRef<"Customer", 'DateTime'> readonly updated_at: Prisma.FieldRef<"Customer", 'DateTime'>
readonly deleted_at: Prisma.FieldRef<"Customer", 'DateTime'> readonly deleted_at: Prisma.FieldRef<"Customer", 'DateTime'>
readonly type: Prisma.FieldRef<"Customer", 'CustomerType'>
readonly complex_id: Prisma.FieldRef<"Customer", 'String'>
readonly is_favorite: Prisma.FieldRef<"Customer", 'Boolean'>
} }
@@ -1461,9 +1423,9 @@ export type Customer$sales_invoicesArgs<ExtArgs extends runtime.Types.Extensions
} }
/** /**
* Customer.customerIndividuals * Customer.customer_individuals
*/ */
export type Customer$customerIndividualsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type Customer$customer_individualsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/** /**
* Select specific fields to fetch from the CustomerIndividual * Select specific fields to fetch from the CustomerIndividual
*/ */
@@ -1480,9 +1442,9 @@ export type Customer$customerIndividualsArgs<ExtArgs extends runtime.Types.Exten
} }
/** /**
* Customer.customerLegals * Customer.customer_legals
*/ */
export type Customer$customerLegalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type Customer$customer_legalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/** /**
* Select specific fields to fetch from the CustomerLegal * Select specific fields to fetch from the CustomerLegal
*/ */
@@ -199,6 +199,7 @@ export type CustomerIndividualWhereInput = {
economic_code?: Prisma.StringNullableFilter<"CustomerIndividual"> | string | null economic_code?: Prisma.StringNullableFilter<"CustomerIndividual"> | string | null
complex_id?: Prisma.StringFilter<"CustomerIndividual"> | string complex_id?: Prisma.StringFilter<"CustomerIndividual"> | string
customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput> customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
complex?: Prisma.XOR<Prisma.ComplexScalarRelationFilter, Prisma.ComplexWhereInput>
} }
export type CustomerIndividualOrderByWithRelationInput = { export type CustomerIndividualOrderByWithRelationInput = {
@@ -210,6 +211,7 @@ export type CustomerIndividualOrderByWithRelationInput = {
economic_code?: Prisma.SortOrderInput | Prisma.SortOrder economic_code?: Prisma.SortOrderInput | Prisma.SortOrder
complex_id?: Prisma.SortOrder complex_id?: Prisma.SortOrder
customer?: Prisma.CustomerOrderByWithRelationInput customer?: Prisma.CustomerOrderByWithRelationInput
complex?: Prisma.ComplexOrderByWithRelationInput
_relevance?: Prisma.CustomerIndividualOrderByRelevanceInput _relevance?: Prisma.CustomerIndividualOrderByRelevanceInput
} }
@@ -226,6 +228,7 @@ export type CustomerIndividualWhereUniqueInput = Prisma.AtLeast<{
economic_code?: Prisma.StringNullableFilter<"CustomerIndividual"> | string | null economic_code?: Prisma.StringNullableFilter<"CustomerIndividual"> | string | null
complex_id?: Prisma.StringFilter<"CustomerIndividual"> | string complex_id?: Prisma.StringFilter<"CustomerIndividual"> | string
customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput> customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
complex?: Prisma.XOR<Prisma.ComplexScalarRelationFilter, Prisma.ComplexWhereInput>
}, "customer_id" | "complex_id_national_id"> }, "customer_id" | "complex_id_national_id">
export type CustomerIndividualOrderByWithAggregationInput = { export type CustomerIndividualOrderByWithAggregationInput = {
@@ -260,8 +263,8 @@ export type CustomerIndividualCreateInput = {
national_id: string national_id: string
postal_code: string postal_code: string
economic_code?: string | null economic_code?: string | null
complex_id: string customer: Prisma.CustomerCreateNestedOneWithoutCustomer_individualsInput
customer: Prisma.CustomerCreateNestedOneWithoutCustomerIndividualsInput complex: Prisma.ComplexCreateNestedOneWithoutCustomerIndividualsInput
} }
export type CustomerIndividualUncheckedCreateInput = { export type CustomerIndividualUncheckedCreateInput = {
@@ -280,8 +283,8 @@ export type CustomerIndividualUpdateInput = {
national_id?: Prisma.StringFieldUpdateOperationsInput | string national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
complex_id?: Prisma.StringFieldUpdateOperationsInput | string customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomer_individualsNestedInput
customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomerIndividualsNestedInput complex?: Prisma.ComplexUpdateOneRequiredWithoutCustomerIndividualsNestedInput
} }
export type CustomerIndividualUncheckedUpdateInput = { export type CustomerIndividualUncheckedUpdateInput = {
@@ -310,7 +313,6 @@ export type CustomerIndividualUpdateManyMutationInput = {
national_id?: Prisma.StringFieldUpdateOperationsInput | string national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerIndividualUncheckedUpdateManyInput = { export type CustomerIndividualUncheckedUpdateManyInput = {
@@ -323,6 +325,16 @@ export type CustomerIndividualUncheckedUpdateManyInput = {
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerIndividualListRelationFilter = {
every?: Prisma.CustomerIndividualWhereInput
some?: Prisma.CustomerIndividualWhereInput
none?: Prisma.CustomerIndividualWhereInput
}
export type CustomerIndividualOrderByRelationAggregateInput = {
_count?: Prisma.SortOrder
}
export type CustomerIndividualNullableScalarRelationFilter = { export type CustomerIndividualNullableScalarRelationFilter = {
is?: Prisma.CustomerIndividualWhereInput | null is?: Prisma.CustomerIndividualWhereInput | null
isNot?: Prisma.CustomerIndividualWhereInput | null isNot?: Prisma.CustomerIndividualWhereInput | null
@@ -369,6 +381,48 @@ export type CustomerIndividualMinOrderByAggregateInput = {
complex_id?: Prisma.SortOrder complex_id?: Prisma.SortOrder
} }
export type CustomerIndividualCreateNestedManyWithoutComplexInput = {
create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput> | Prisma.CustomerIndividualCreateWithoutComplexInput[] | Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput | Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput[]
createMany?: Prisma.CustomerIndividualCreateManyComplexInputEnvelope
connect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
}
export type CustomerIndividualUncheckedCreateNestedManyWithoutComplexInput = {
create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput> | Prisma.CustomerIndividualCreateWithoutComplexInput[] | Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput | Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput[]
createMany?: Prisma.CustomerIndividualCreateManyComplexInputEnvelope
connect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
}
export type CustomerIndividualUpdateManyWithoutComplexNestedInput = {
create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput> | Prisma.CustomerIndividualCreateWithoutComplexInput[] | Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput | Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput[]
upsert?: Prisma.CustomerIndividualUpsertWithWhereUniqueWithoutComplexInput | Prisma.CustomerIndividualUpsertWithWhereUniqueWithoutComplexInput[]
createMany?: Prisma.CustomerIndividualCreateManyComplexInputEnvelope
set?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
disconnect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
delete?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
connect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
update?: Prisma.CustomerIndividualUpdateWithWhereUniqueWithoutComplexInput | Prisma.CustomerIndividualUpdateWithWhereUniqueWithoutComplexInput[]
updateMany?: Prisma.CustomerIndividualUpdateManyWithWhereWithoutComplexInput | Prisma.CustomerIndividualUpdateManyWithWhereWithoutComplexInput[]
deleteMany?: Prisma.CustomerIndividualScalarWhereInput | Prisma.CustomerIndividualScalarWhereInput[]
}
export type CustomerIndividualUncheckedUpdateManyWithoutComplexNestedInput = {
create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput> | Prisma.CustomerIndividualCreateWithoutComplexInput[] | Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput | Prisma.CustomerIndividualCreateOrConnectWithoutComplexInput[]
upsert?: Prisma.CustomerIndividualUpsertWithWhereUniqueWithoutComplexInput | Prisma.CustomerIndividualUpsertWithWhereUniqueWithoutComplexInput[]
createMany?: Prisma.CustomerIndividualCreateManyComplexInputEnvelope
set?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
disconnect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
delete?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
connect?: Prisma.CustomerIndividualWhereUniqueInput | Prisma.CustomerIndividualWhereUniqueInput[]
update?: Prisma.CustomerIndividualUpdateWithWhereUniqueWithoutComplexInput | Prisma.CustomerIndividualUpdateWithWhereUniqueWithoutComplexInput[]
updateMany?: Prisma.CustomerIndividualUpdateManyWithWhereWithoutComplexInput | Prisma.CustomerIndividualUpdateManyWithWhereWithoutComplexInput[]
deleteMany?: Prisma.CustomerIndividualScalarWhereInput | Prisma.CustomerIndividualScalarWhereInput[]
}
export type CustomerIndividualCreateNestedOneWithoutCustomerInput = { export type CustomerIndividualCreateNestedOneWithoutCustomerInput = {
create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutCustomerInput, Prisma.CustomerIndividualUncheckedCreateWithoutCustomerInput> create?: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutCustomerInput, Prisma.CustomerIndividualUncheckedCreateWithoutCustomerInput>
connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutCustomerInput connectOrCreate?: Prisma.CustomerIndividualCreateOrConnectWithoutCustomerInput
@@ -401,13 +455,70 @@ export type CustomerIndividualUncheckedUpdateOneWithoutCustomerNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerIndividualUpdateToOneWithWhereWithoutCustomerInput, Prisma.CustomerIndividualUpdateWithoutCustomerInput>, Prisma.CustomerIndividualUncheckedUpdateWithoutCustomerInput> update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerIndividualUpdateToOneWithWhereWithoutCustomerInput, Prisma.CustomerIndividualUpdateWithoutCustomerInput>, Prisma.CustomerIndividualUncheckedUpdateWithoutCustomerInput>
} }
export type CustomerIndividualCreateWithoutComplexInput = {
first_name: string
last_name: string
national_id: string
postal_code: string
economic_code?: string | null
customer: Prisma.CustomerCreateNestedOneWithoutCustomer_individualsInput
}
export type CustomerIndividualUncheckedCreateWithoutComplexInput = {
customer_id: string
first_name: string
last_name: string
national_id: string
postal_code: string
economic_code?: string | null
}
export type CustomerIndividualCreateOrConnectWithoutComplexInput = {
where: Prisma.CustomerIndividualWhereUniqueInput
create: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput>
}
export type CustomerIndividualCreateManyComplexInputEnvelope = {
data: Prisma.CustomerIndividualCreateManyComplexInput | Prisma.CustomerIndividualCreateManyComplexInput[]
skipDuplicates?: boolean
}
export type CustomerIndividualUpsertWithWhereUniqueWithoutComplexInput = {
where: Prisma.CustomerIndividualWhereUniqueInput
update: Prisma.XOR<Prisma.CustomerIndividualUpdateWithoutComplexInput, Prisma.CustomerIndividualUncheckedUpdateWithoutComplexInput>
create: Prisma.XOR<Prisma.CustomerIndividualCreateWithoutComplexInput, Prisma.CustomerIndividualUncheckedCreateWithoutComplexInput>
}
export type CustomerIndividualUpdateWithWhereUniqueWithoutComplexInput = {
where: Prisma.CustomerIndividualWhereUniqueInput
data: Prisma.XOR<Prisma.CustomerIndividualUpdateWithoutComplexInput, Prisma.CustomerIndividualUncheckedUpdateWithoutComplexInput>
}
export type CustomerIndividualUpdateManyWithWhereWithoutComplexInput = {
where: Prisma.CustomerIndividualScalarWhereInput
data: Prisma.XOR<Prisma.CustomerIndividualUpdateManyMutationInput, Prisma.CustomerIndividualUncheckedUpdateManyWithoutComplexInput>
}
export type CustomerIndividualScalarWhereInput = {
AND?: Prisma.CustomerIndividualScalarWhereInput | Prisma.CustomerIndividualScalarWhereInput[]
OR?: Prisma.CustomerIndividualScalarWhereInput[]
NOT?: Prisma.CustomerIndividualScalarWhereInput | Prisma.CustomerIndividualScalarWhereInput[]
customer_id?: Prisma.StringFilter<"CustomerIndividual"> | string
first_name?: Prisma.StringFilter<"CustomerIndividual"> | string
last_name?: Prisma.StringFilter<"CustomerIndividual"> | string
national_id?: Prisma.StringFilter<"CustomerIndividual"> | string
postal_code?: Prisma.StringFilter<"CustomerIndividual"> | string
economic_code?: Prisma.StringNullableFilter<"CustomerIndividual"> | string | null
complex_id?: Prisma.StringFilter<"CustomerIndividual"> | string
}
export type CustomerIndividualCreateWithoutCustomerInput = { export type CustomerIndividualCreateWithoutCustomerInput = {
first_name: string first_name: string
last_name: string last_name: string
national_id: string national_id: string
postal_code: string postal_code: string
economic_code?: string | null economic_code?: string | null
complex_id: string complex: Prisma.ComplexCreateNestedOneWithoutCustomerIndividualsInput
} }
export type CustomerIndividualUncheckedCreateWithoutCustomerInput = { export type CustomerIndividualUncheckedCreateWithoutCustomerInput = {
@@ -441,7 +552,7 @@ export type CustomerIndividualUpdateWithoutCustomerInput = {
national_id?: Prisma.StringFieldUpdateOperationsInput | string national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex?: Prisma.ComplexUpdateOneRequiredWithoutCustomerIndividualsNestedInput
} }
export type CustomerIndividualUncheckedUpdateWithoutCustomerInput = { export type CustomerIndividualUncheckedUpdateWithoutCustomerInput = {
@@ -453,6 +564,42 @@ export type CustomerIndividualUncheckedUpdateWithoutCustomerInput = {
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerIndividualCreateManyComplexInput = {
customer_id: string
first_name: string
last_name: string
national_id: string
postal_code: string
economic_code?: string | null
}
export type CustomerIndividualUpdateWithoutComplexInput = {
first_name?: Prisma.StringFieldUpdateOperationsInput | string
last_name?: Prisma.StringFieldUpdateOperationsInput | string
national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomer_individualsNestedInput
}
export type CustomerIndividualUncheckedUpdateWithoutComplexInput = {
customer_id?: Prisma.StringFieldUpdateOperationsInput | string
first_name?: Prisma.StringFieldUpdateOperationsInput | string
last_name?: Prisma.StringFieldUpdateOperationsInput | string
national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}
export type CustomerIndividualUncheckedUpdateManyWithoutComplexInput = {
customer_id?: Prisma.StringFieldUpdateOperationsInput | string
first_name?: Prisma.StringFieldUpdateOperationsInput | string
last_name?: Prisma.StringFieldUpdateOperationsInput | string
national_id?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}
export type CustomerIndividualSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type CustomerIndividualSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
@@ -464,6 +611,7 @@ export type CustomerIndividualSelect<ExtArgs extends runtime.Types.Extensions.In
economic_code?: boolean economic_code?: boolean
complex_id?: boolean complex_id?: boolean
customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs> customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
complex?: boolean | Prisma.ComplexDefaultArgs<ExtArgs>
}, ExtArgs["result"]["customerIndividual"]> }, ExtArgs["result"]["customerIndividual"]>
@@ -481,12 +629,14 @@ export type CustomerIndividualSelectScalar = {
export type CustomerIndividualOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"customer_id" | "first_name" | "last_name" | "national_id" | "postal_code" | "economic_code" | "complex_id", ExtArgs["result"]["customerIndividual"]> export type CustomerIndividualOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"customer_id" | "first_name" | "last_name" | "national_id" | "postal_code" | "economic_code" | "complex_id", ExtArgs["result"]["customerIndividual"]>
export type CustomerIndividualInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type CustomerIndividualInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs> customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
complex?: boolean | Prisma.ComplexDefaultArgs<ExtArgs>
} }
export type $CustomerIndividualPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type $CustomerIndividualPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
name: "CustomerIndividual" name: "CustomerIndividual"
objects: { objects: {
customer: Prisma.$CustomerPayload<ExtArgs> customer: Prisma.$CustomerPayload<ExtArgs>
complex: Prisma.$ComplexPayload<ExtArgs>
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
customer_id: string customer_id: string
@@ -837,6 +987,7 @@ readonly fields: CustomerIndividualFieldRefs;
export interface Prisma__CustomerIndividualClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> { export interface Prisma__CustomerIndividualClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise" readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends Prisma.CustomerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.CustomerDefaultArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions> customer<T extends Prisma.CustomerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.CustomerDefaultArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
complex<T extends Prisma.ComplexDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ComplexDefaultArgs<ExtArgs>>): Prisma.Prisma__ComplexClient<runtime.Types.Result.GetResult<Prisma.$ComplexPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
+151 -7
View File
@@ -191,6 +191,7 @@ export type CustomerLegalWhereInput = {
postal_code?: Prisma.StringFilter<"CustomerLegal"> | string postal_code?: Prisma.StringFilter<"CustomerLegal"> | string
complex_id?: Prisma.StringFilter<"CustomerLegal"> | string complex_id?: Prisma.StringFilter<"CustomerLegal"> | string
customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput> customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
complex?: Prisma.XOR<Prisma.ComplexScalarRelationFilter, Prisma.ComplexWhereInput>
} }
export type CustomerLegalOrderByWithRelationInput = { export type CustomerLegalOrderByWithRelationInput = {
@@ -201,6 +202,7 @@ export type CustomerLegalOrderByWithRelationInput = {
postal_code?: Prisma.SortOrder postal_code?: Prisma.SortOrder
complex_id?: Prisma.SortOrder complex_id?: Prisma.SortOrder
customer?: Prisma.CustomerOrderByWithRelationInput customer?: Prisma.CustomerOrderByWithRelationInput
complex?: Prisma.ComplexOrderByWithRelationInput
_relevance?: Prisma.CustomerLegalOrderByRelevanceInput _relevance?: Prisma.CustomerLegalOrderByRelevanceInput
} }
@@ -216,6 +218,7 @@ export type CustomerLegalWhereUniqueInput = Prisma.AtLeast<{
postal_code?: Prisma.StringFilter<"CustomerLegal"> | string postal_code?: Prisma.StringFilter<"CustomerLegal"> | string
complex_id?: Prisma.StringFilter<"CustomerLegal"> | string complex_id?: Prisma.StringFilter<"CustomerLegal"> | string
customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput> customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
complex?: Prisma.XOR<Prisma.ComplexScalarRelationFilter, Prisma.ComplexWhereInput>
}, "customer_id" | "complex_id_registration_number"> }, "customer_id" | "complex_id_registration_number">
export type CustomerLegalOrderByWithAggregationInput = { export type CustomerLegalOrderByWithAggregationInput = {
@@ -247,8 +250,8 @@ export type CustomerLegalCreateInput = {
economic_code: string economic_code: string
registration_number: string registration_number: string
postal_code: string postal_code: string
complex_id: string customer: Prisma.CustomerCreateNestedOneWithoutCustomer_legalsInput
customer: Prisma.CustomerCreateNestedOneWithoutCustomerLegalsInput complex: Prisma.ComplexCreateNestedOneWithoutCustomerLegalsInput
} }
export type CustomerLegalUncheckedCreateInput = { export type CustomerLegalUncheckedCreateInput = {
@@ -265,8 +268,8 @@ export type CustomerLegalUpdateInput = {
economic_code?: Prisma.StringFieldUpdateOperationsInput | string economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomer_legalsNestedInput
customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomerLegalsNestedInput complex?: Prisma.ComplexUpdateOneRequiredWithoutCustomerLegalsNestedInput
} }
export type CustomerLegalUncheckedUpdateInput = { export type CustomerLegalUncheckedUpdateInput = {
@@ -292,7 +295,6 @@ export type CustomerLegalUpdateManyMutationInput = {
economic_code?: Prisma.StringFieldUpdateOperationsInput | string economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerLegalUncheckedUpdateManyInput = { export type CustomerLegalUncheckedUpdateManyInput = {
@@ -304,6 +306,16 @@ export type CustomerLegalUncheckedUpdateManyInput = {
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerLegalListRelationFilter = {
every?: Prisma.CustomerLegalWhereInput
some?: Prisma.CustomerLegalWhereInput
none?: Prisma.CustomerLegalWhereInput
}
export type CustomerLegalOrderByRelationAggregateInput = {
_count?: Prisma.SortOrder
}
export type CustomerLegalNullableScalarRelationFilter = { export type CustomerLegalNullableScalarRelationFilter = {
is?: Prisma.CustomerLegalWhereInput | null is?: Prisma.CustomerLegalWhereInput | null
isNot?: Prisma.CustomerLegalWhereInput | null isNot?: Prisma.CustomerLegalWhereInput | null
@@ -347,6 +359,48 @@ export type CustomerLegalMinOrderByAggregateInput = {
complex_id?: Prisma.SortOrder complex_id?: Prisma.SortOrder
} }
export type CustomerLegalCreateNestedManyWithoutComplexInput = {
create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput> | Prisma.CustomerLegalCreateWithoutComplexInput[] | Prisma.CustomerLegalUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutComplexInput | Prisma.CustomerLegalCreateOrConnectWithoutComplexInput[]
createMany?: Prisma.CustomerLegalCreateManyComplexInputEnvelope
connect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
}
export type CustomerLegalUncheckedCreateNestedManyWithoutComplexInput = {
create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput> | Prisma.CustomerLegalCreateWithoutComplexInput[] | Prisma.CustomerLegalUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutComplexInput | Prisma.CustomerLegalCreateOrConnectWithoutComplexInput[]
createMany?: Prisma.CustomerLegalCreateManyComplexInputEnvelope
connect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
}
export type CustomerLegalUpdateManyWithoutComplexNestedInput = {
create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput> | Prisma.CustomerLegalCreateWithoutComplexInput[] | Prisma.CustomerLegalUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutComplexInput | Prisma.CustomerLegalCreateOrConnectWithoutComplexInput[]
upsert?: Prisma.CustomerLegalUpsertWithWhereUniqueWithoutComplexInput | Prisma.CustomerLegalUpsertWithWhereUniqueWithoutComplexInput[]
createMany?: Prisma.CustomerLegalCreateManyComplexInputEnvelope
set?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
disconnect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
delete?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
connect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
update?: Prisma.CustomerLegalUpdateWithWhereUniqueWithoutComplexInput | Prisma.CustomerLegalUpdateWithWhereUniqueWithoutComplexInput[]
updateMany?: Prisma.CustomerLegalUpdateManyWithWhereWithoutComplexInput | Prisma.CustomerLegalUpdateManyWithWhereWithoutComplexInput[]
deleteMany?: Prisma.CustomerLegalScalarWhereInput | Prisma.CustomerLegalScalarWhereInput[]
}
export type CustomerLegalUncheckedUpdateManyWithoutComplexNestedInput = {
create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput> | Prisma.CustomerLegalCreateWithoutComplexInput[] | Prisma.CustomerLegalUncheckedCreateWithoutComplexInput[]
connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutComplexInput | Prisma.CustomerLegalCreateOrConnectWithoutComplexInput[]
upsert?: Prisma.CustomerLegalUpsertWithWhereUniqueWithoutComplexInput | Prisma.CustomerLegalUpsertWithWhereUniqueWithoutComplexInput[]
createMany?: Prisma.CustomerLegalCreateManyComplexInputEnvelope
set?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
disconnect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
delete?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
connect?: Prisma.CustomerLegalWhereUniqueInput | Prisma.CustomerLegalWhereUniqueInput[]
update?: Prisma.CustomerLegalUpdateWithWhereUniqueWithoutComplexInput | Prisma.CustomerLegalUpdateWithWhereUniqueWithoutComplexInput[]
updateMany?: Prisma.CustomerLegalUpdateManyWithWhereWithoutComplexInput | Prisma.CustomerLegalUpdateManyWithWhereWithoutComplexInput[]
deleteMany?: Prisma.CustomerLegalScalarWhereInput | Prisma.CustomerLegalScalarWhereInput[]
}
export type CustomerLegalCreateNestedOneWithoutCustomerInput = { export type CustomerLegalCreateNestedOneWithoutCustomerInput = {
create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutCustomerInput, Prisma.CustomerLegalUncheckedCreateWithoutCustomerInput> create?: Prisma.XOR<Prisma.CustomerLegalCreateWithoutCustomerInput, Prisma.CustomerLegalUncheckedCreateWithoutCustomerInput>
connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutCustomerInput connectOrCreate?: Prisma.CustomerLegalCreateOrConnectWithoutCustomerInput
@@ -379,12 +433,66 @@ export type CustomerLegalUncheckedUpdateOneWithoutCustomerNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerLegalUpdateToOneWithWhereWithoutCustomerInput, Prisma.CustomerLegalUpdateWithoutCustomerInput>, Prisma.CustomerLegalUncheckedUpdateWithoutCustomerInput> update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerLegalUpdateToOneWithWhereWithoutCustomerInput, Prisma.CustomerLegalUpdateWithoutCustomerInput>, Prisma.CustomerLegalUncheckedUpdateWithoutCustomerInput>
} }
export type CustomerLegalCreateWithoutComplexInput = {
company_name: string
economic_code: string
registration_number: string
postal_code: string
customer: Prisma.CustomerCreateNestedOneWithoutCustomer_legalsInput
}
export type CustomerLegalUncheckedCreateWithoutComplexInput = {
customer_id: string
company_name: string
economic_code: string
registration_number: string
postal_code: string
}
export type CustomerLegalCreateOrConnectWithoutComplexInput = {
where: Prisma.CustomerLegalWhereUniqueInput
create: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput>
}
export type CustomerLegalCreateManyComplexInputEnvelope = {
data: Prisma.CustomerLegalCreateManyComplexInput | Prisma.CustomerLegalCreateManyComplexInput[]
skipDuplicates?: boolean
}
export type CustomerLegalUpsertWithWhereUniqueWithoutComplexInput = {
where: Prisma.CustomerLegalWhereUniqueInput
update: Prisma.XOR<Prisma.CustomerLegalUpdateWithoutComplexInput, Prisma.CustomerLegalUncheckedUpdateWithoutComplexInput>
create: Prisma.XOR<Prisma.CustomerLegalCreateWithoutComplexInput, Prisma.CustomerLegalUncheckedCreateWithoutComplexInput>
}
export type CustomerLegalUpdateWithWhereUniqueWithoutComplexInput = {
where: Prisma.CustomerLegalWhereUniqueInput
data: Prisma.XOR<Prisma.CustomerLegalUpdateWithoutComplexInput, Prisma.CustomerLegalUncheckedUpdateWithoutComplexInput>
}
export type CustomerLegalUpdateManyWithWhereWithoutComplexInput = {
where: Prisma.CustomerLegalScalarWhereInput
data: Prisma.XOR<Prisma.CustomerLegalUpdateManyMutationInput, Prisma.CustomerLegalUncheckedUpdateManyWithoutComplexInput>
}
export type CustomerLegalScalarWhereInput = {
AND?: Prisma.CustomerLegalScalarWhereInput | Prisma.CustomerLegalScalarWhereInput[]
OR?: Prisma.CustomerLegalScalarWhereInput[]
NOT?: Prisma.CustomerLegalScalarWhereInput | Prisma.CustomerLegalScalarWhereInput[]
customer_id?: Prisma.StringFilter<"CustomerLegal"> | string
company_name?: Prisma.StringFilter<"CustomerLegal"> | string
economic_code?: Prisma.StringFilter<"CustomerLegal"> | string
registration_number?: Prisma.StringFilter<"CustomerLegal"> | string
postal_code?: Prisma.StringFilter<"CustomerLegal"> | string
complex_id?: Prisma.StringFilter<"CustomerLegal"> | string
}
export type CustomerLegalCreateWithoutCustomerInput = { export type CustomerLegalCreateWithoutCustomerInput = {
company_name: string company_name: string
economic_code: string economic_code: string
registration_number: string registration_number: string
postal_code: string postal_code: string
complex_id: string complex: Prisma.ComplexCreateNestedOneWithoutCustomerLegalsInput
} }
export type CustomerLegalUncheckedCreateWithoutCustomerInput = { export type CustomerLegalUncheckedCreateWithoutCustomerInput = {
@@ -416,7 +524,7 @@ export type CustomerLegalUpdateWithoutCustomerInput = {
economic_code?: Prisma.StringFieldUpdateOperationsInput | string economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string postal_code?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex?: Prisma.ComplexUpdateOneRequiredWithoutCustomerLegalsNestedInput
} }
export type CustomerLegalUncheckedUpdateWithoutCustomerInput = { export type CustomerLegalUncheckedUpdateWithoutCustomerInput = {
@@ -427,6 +535,38 @@ export type CustomerLegalUncheckedUpdateWithoutCustomerInput = {
complex_id?: Prisma.StringFieldUpdateOperationsInput | string complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type CustomerLegalCreateManyComplexInput = {
customer_id: string
company_name: string
economic_code: string
registration_number: string
postal_code: string
}
export type CustomerLegalUpdateWithoutComplexInput = {
company_name?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
customer?: Prisma.CustomerUpdateOneRequiredWithoutCustomer_legalsNestedInput
}
export type CustomerLegalUncheckedUpdateWithoutComplexInput = {
customer_id?: Prisma.StringFieldUpdateOperationsInput | string
company_name?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
}
export type CustomerLegalUncheckedUpdateManyWithoutComplexInput = {
customer_id?: Prisma.StringFieldUpdateOperationsInput | string
company_name?: Prisma.StringFieldUpdateOperationsInput | string
economic_code?: Prisma.StringFieldUpdateOperationsInput | string
registration_number?: Prisma.StringFieldUpdateOperationsInput | string
postal_code?: Prisma.StringFieldUpdateOperationsInput | string
}
export type CustomerLegalSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type CustomerLegalSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
@@ -437,6 +577,7 @@ export type CustomerLegalSelect<ExtArgs extends runtime.Types.Extensions.Interna
postal_code?: boolean postal_code?: boolean
complex_id?: boolean complex_id?: boolean
customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs> customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
complex?: boolean | Prisma.ComplexDefaultArgs<ExtArgs>
}, ExtArgs["result"]["customerLegal"]> }, ExtArgs["result"]["customerLegal"]>
@@ -453,12 +594,14 @@ export type CustomerLegalSelectScalar = {
export type CustomerLegalOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"customer_id" | "company_name" | "economic_code" | "registration_number" | "postal_code" | "complex_id", ExtArgs["result"]["customerLegal"]> export type CustomerLegalOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"customer_id" | "company_name" | "economic_code" | "registration_number" | "postal_code" | "complex_id", ExtArgs["result"]["customerLegal"]>
export type CustomerLegalInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type CustomerLegalInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs> customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
complex?: boolean | Prisma.ComplexDefaultArgs<ExtArgs>
} }
export type $CustomerLegalPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type $CustomerLegalPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
name: "CustomerLegal" name: "CustomerLegal"
objects: { objects: {
customer: Prisma.$CustomerPayload<ExtArgs> customer: Prisma.$CustomerPayload<ExtArgs>
complex: Prisma.$ComplexPayload<ExtArgs>
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
customer_id: string customer_id: string
@@ -808,6 +951,7 @@ readonly fields: CustomerLegalFieldRefs;
export interface Prisma__CustomerLegalClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> { export interface Prisma__CustomerLegalClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise" readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends Prisma.CustomerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.CustomerDefaultArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions> customer<T extends Prisma.CustomerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.CustomerDefaultArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
complex<T extends Prisma.ComplexDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ComplexDefaultArgs<ExtArgs>>): Prisma.Prisma__ComplexClient<runtime.Types.Result.GetResult<Prisma.$ComplexPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
+158
View File
@@ -235,6 +235,7 @@ export type PosWhereInput = {
provider?: Prisma.XOR<Prisma.ProviderNullableScalarRelationFilter, Prisma.ProviderWhereInput> | null provider?: Prisma.XOR<Prisma.ProviderNullableScalarRelationFilter, Prisma.ProviderWhereInput> | null
licenses?: Prisma.LicenseListRelationFilter licenses?: Prisma.LicenseListRelationFilter
permissionPos?: Prisma.PermissionPosListRelationFilter permissionPos?: Prisma.PermissionPosListRelationFilter
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
} }
export type PosOrderByWithRelationInput = { export type PosOrderByWithRelationInput = {
@@ -254,6 +255,7 @@ export type PosOrderByWithRelationInput = {
provider?: Prisma.ProviderOrderByWithRelationInput provider?: Prisma.ProviderOrderByWithRelationInput
licenses?: Prisma.LicenseOrderByRelationAggregateInput licenses?: Prisma.LicenseOrderByRelationAggregateInput
permissionPos?: Prisma.PermissionPosOrderByRelationAggregateInput permissionPos?: Prisma.PermissionPosOrderByRelationAggregateInput
salesInvoices?: Prisma.SalesInvoiceOrderByRelationAggregateInput
_relevance?: Prisma.PosOrderByRelevanceInput _relevance?: Prisma.PosOrderByRelevanceInput
} }
@@ -277,6 +279,7 @@ export type PosWhereUniqueInput = Prisma.AtLeast<{
provider?: Prisma.XOR<Prisma.ProviderNullableScalarRelationFilter, Prisma.ProviderWhereInput> | null provider?: Prisma.XOR<Prisma.ProviderNullableScalarRelationFilter, Prisma.ProviderWhereInput> | null
licenses?: Prisma.LicenseListRelationFilter licenses?: Prisma.LicenseListRelationFilter
permissionPos?: Prisma.PermissionPosListRelationFilter permissionPos?: Prisma.PermissionPosListRelationFilter
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
}, "id" | "serial"> }, "id" | "serial">
export type PosOrderByWithAggregationInput = { export type PosOrderByWithAggregationInput = {
@@ -327,6 +330,7 @@ export type PosCreateInput = {
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateInput = { export type PosUncheckedCreateInput = {
@@ -343,6 +347,7 @@ export type PosUncheckedCreateInput = {
provider_id?: string | null provider_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosUpdateInput = { export type PosUpdateInput = {
@@ -359,6 +364,7 @@ export type PosUpdateInput = {
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateInput = { export type PosUncheckedUpdateInput = {
@@ -375,6 +381,7 @@ export type PosUncheckedUpdateInput = {
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosCreateManyInput = { export type PosCreateManyInput = {
@@ -641,6 +648,20 @@ export type PosUncheckedUpdateManyWithoutProviderNestedInput = {
deleteMany?: Prisma.PosScalarWhereInput | Prisma.PosScalarWhereInput[] deleteMany?: Prisma.PosScalarWhereInput | Prisma.PosScalarWhereInput[]
} }
export type PosCreateNestedOneWithoutSalesInvoicesInput = {
create?: Prisma.XOR<Prisma.PosCreateWithoutSalesInvoicesInput, Prisma.PosUncheckedCreateWithoutSalesInvoicesInput>
connectOrCreate?: Prisma.PosCreateOrConnectWithoutSalesInvoicesInput
connect?: Prisma.PosWhereUniqueInput
}
export type PosUpdateOneRequiredWithoutSalesInvoicesNestedInput = {
create?: Prisma.XOR<Prisma.PosCreateWithoutSalesInvoicesInput, Prisma.PosUncheckedCreateWithoutSalesInvoicesInput>
connectOrCreate?: Prisma.PosCreateOrConnectWithoutSalesInvoicesInput
upsert?: Prisma.PosUpsertWithoutSalesInvoicesInput
connect?: Prisma.PosWhereUniqueInput
update?: Prisma.XOR<Prisma.XOR<Prisma.PosUpdateToOneWithWhereWithoutSalesInvoicesInput, Prisma.PosUpdateWithoutSalesInvoicesInput>, Prisma.PosUncheckedUpdateWithoutSalesInvoicesInput>
}
export type PosCreateWithoutComplexInput = { export type PosCreateWithoutComplexInput = {
id?: string id?: string
name: string name: string
@@ -654,6 +675,7 @@ export type PosCreateWithoutComplexInput = {
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateWithoutComplexInput = { export type PosUncheckedCreateWithoutComplexInput = {
@@ -669,6 +691,7 @@ export type PosUncheckedCreateWithoutComplexInput = {
provider_id?: string | null provider_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosCreateOrConnectWithoutComplexInput = { export type PosCreateOrConnectWithoutComplexInput = {
@@ -727,6 +750,7 @@ export type PosCreateWithoutDeviceInput = {
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateWithoutDeviceInput = { export type PosUncheckedCreateWithoutDeviceInput = {
@@ -742,6 +766,7 @@ export type PosUncheckedCreateWithoutDeviceInput = {
provider_id?: string | null provider_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosCreateOrConnectWithoutDeviceInput = { export type PosCreateOrConnectWithoutDeviceInput = {
@@ -783,6 +808,7 @@ export type PosCreateWithoutLicensesInput = {
device?: Prisma.DeviceCreateNestedOneWithoutPosesInput device?: Prisma.DeviceCreateNestedOneWithoutPosesInput
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateWithoutLicensesInput = { export type PosUncheckedCreateWithoutLicensesInput = {
@@ -798,6 +824,7 @@ export type PosUncheckedCreateWithoutLicensesInput = {
device_id?: string | null device_id?: string | null
provider_id?: string | null provider_id?: string | null
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosCreateOrConnectWithoutLicensesInput = { export type PosCreateOrConnectWithoutLicensesInput = {
@@ -829,6 +856,7 @@ export type PosUpdateWithoutLicensesInput = {
device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateWithoutLicensesInput = { export type PosUncheckedUpdateWithoutLicensesInput = {
@@ -844,6 +872,7 @@ export type PosUncheckedUpdateWithoutLicensesInput = {
device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosCreateWithoutPermissionPosInput = { export type PosCreateWithoutPermissionPosInput = {
@@ -859,6 +888,7 @@ export type PosCreateWithoutPermissionPosInput = {
device?: Prisma.DeviceCreateNestedOneWithoutPosesInput device?: Prisma.DeviceCreateNestedOneWithoutPosesInput
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateWithoutPermissionPosInput = { export type PosUncheckedCreateWithoutPermissionPosInput = {
@@ -874,6 +904,7 @@ export type PosUncheckedCreateWithoutPermissionPosInput = {
device_id?: string | null device_id?: string | null
provider_id?: string | null provider_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosCreateOrConnectWithoutPermissionPosInput = { export type PosCreateOrConnectWithoutPermissionPosInput = {
@@ -905,6 +936,7 @@ export type PosUpdateWithoutPermissionPosInput = {
device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateWithoutPermissionPosInput = { export type PosUncheckedUpdateWithoutPermissionPosInput = {
@@ -920,6 +952,7 @@ export type PosUncheckedUpdateWithoutPermissionPosInput = {
device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosCreateWithoutProviderInput = { export type PosCreateWithoutProviderInput = {
@@ -935,6 +968,7 @@ export type PosCreateWithoutProviderInput = {
device?: Prisma.DeviceCreateNestedOneWithoutPosesInput device?: Prisma.DeviceCreateNestedOneWithoutPosesInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutPosInput
} }
export type PosUncheckedCreateWithoutProviderInput = { export type PosUncheckedCreateWithoutProviderInput = {
@@ -950,6 +984,7 @@ export type PosUncheckedCreateWithoutProviderInput = {
device_id?: string | null device_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutPosInput
} }
export type PosCreateOrConnectWithoutProviderInput = { export type PosCreateOrConnectWithoutProviderInput = {
@@ -978,6 +1013,86 @@ export type PosUpdateManyWithWhereWithoutProviderInput = {
data: Prisma.XOR<Prisma.PosUpdateManyMutationInput, Prisma.PosUncheckedUpdateManyWithoutProviderInput> data: Prisma.XOR<Prisma.PosUpdateManyMutationInput, Prisma.PosUncheckedUpdateManyWithoutProviderInput>
} }
export type PosCreateWithoutSalesInvoicesInput = {
id?: string
name: string
serial: string
model?: string | null
status?: $Enums.POSStatus
pos_type: $Enums.POSType
created_at?: Date | string
updated_at?: Date | string
complex: Prisma.ComplexCreateNestedOneWithoutPos_listInput
device?: Prisma.DeviceCreateNestedOneWithoutPosesInput
provider?: Prisma.ProviderCreateNestedOneWithoutPos_listInput
licenses?: Prisma.LicenseCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosCreateNestedManyWithoutPosInput
}
export type PosUncheckedCreateWithoutSalesInvoicesInput = {
id?: string
name: string
serial: string
model?: string | null
status?: $Enums.POSStatus
pos_type: $Enums.POSType
created_at?: Date | string
updated_at?: Date | string
complex_id: string
device_id?: string | null
provider_id?: string | null
licenses?: Prisma.LicenseUncheckedCreateNestedManyWithoutPosInput
permissionPos?: Prisma.PermissionPosUncheckedCreateNestedManyWithoutPosInput
}
export type PosCreateOrConnectWithoutSalesInvoicesInput = {
where: Prisma.PosWhereUniqueInput
create: Prisma.XOR<Prisma.PosCreateWithoutSalesInvoicesInput, Prisma.PosUncheckedCreateWithoutSalesInvoicesInput>
}
export type PosUpsertWithoutSalesInvoicesInput = {
update: Prisma.XOR<Prisma.PosUpdateWithoutSalesInvoicesInput, Prisma.PosUncheckedUpdateWithoutSalesInvoicesInput>
create: Prisma.XOR<Prisma.PosCreateWithoutSalesInvoicesInput, Prisma.PosUncheckedCreateWithoutSalesInvoicesInput>
where?: Prisma.PosWhereInput
}
export type PosUpdateToOneWithWhereWithoutSalesInvoicesInput = {
where?: Prisma.PosWhereInput
data: Prisma.XOR<Prisma.PosUpdateWithoutSalesInvoicesInput, Prisma.PosUncheckedUpdateWithoutSalesInvoicesInput>
}
export type PosUpdateWithoutSalesInvoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
serial?: Prisma.StringFieldUpdateOperationsInput | string
model?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
status?: Prisma.EnumPOSStatusFieldUpdateOperationsInput | $Enums.POSStatus
pos_type?: Prisma.EnumPOSTypeFieldUpdateOperationsInput | $Enums.POSType
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
complex?: Prisma.ComplexUpdateOneRequiredWithoutPos_listNestedInput
device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
}
export type PosUncheckedUpdateWithoutSalesInvoicesInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
name?: Prisma.StringFieldUpdateOperationsInput | string
serial?: Prisma.StringFieldUpdateOperationsInput | string
model?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
status?: Prisma.EnumPOSStatusFieldUpdateOperationsInput | $Enums.POSStatus
pos_type?: Prisma.EnumPOSTypeFieldUpdateOperationsInput | $Enums.POSType
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
}
export type PosCreateManyComplexInput = { export type PosCreateManyComplexInput = {
id?: string id?: string
name: string name: string
@@ -1004,6 +1119,7 @@ export type PosUpdateWithoutComplexInput = {
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateWithoutComplexInput = { export type PosUncheckedUpdateWithoutComplexInput = {
@@ -1019,6 +1135,7 @@ export type PosUncheckedUpdateWithoutComplexInput = {
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateManyWithoutComplexInput = { export type PosUncheckedUpdateManyWithoutComplexInput = {
@@ -1060,6 +1177,7 @@ export type PosUpdateWithoutDeviceInput = {
provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput provider?: Prisma.ProviderUpdateOneWithoutPos_listNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateWithoutDeviceInput = { export type PosUncheckedUpdateWithoutDeviceInput = {
@@ -1075,6 +1193,7 @@ export type PosUncheckedUpdateWithoutDeviceInput = {
provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null provider_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateManyWithoutDeviceInput = { export type PosUncheckedUpdateManyWithoutDeviceInput = {
@@ -1116,6 +1235,7 @@ export type PosUpdateWithoutProviderInput = {
device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput device?: Prisma.DeviceUpdateOneWithoutPosesNestedInput
licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateWithoutProviderInput = { export type PosUncheckedUpdateWithoutProviderInput = {
@@ -1131,6 +1251,7 @@ export type PosUncheckedUpdateWithoutProviderInput = {
device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null device_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput licenses?: Prisma.LicenseUncheckedUpdateManyWithoutPosNestedInput
permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput permissionPos?: Prisma.PermissionPosUncheckedUpdateManyWithoutPosNestedInput
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput
} }
export type PosUncheckedUpdateManyWithoutProviderInput = { export type PosUncheckedUpdateManyWithoutProviderInput = {
@@ -1154,11 +1275,13 @@ export type PosUncheckedUpdateManyWithoutProviderInput = {
export type PosCountOutputType = { export type PosCountOutputType = {
licenses: number licenses: number
permissionPos: number permissionPos: number
salesInvoices: number
} }
export type PosCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type PosCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
licenses?: boolean | PosCountOutputTypeCountLicensesArgs licenses?: boolean | PosCountOutputTypeCountLicensesArgs
permissionPos?: boolean | PosCountOutputTypeCountPermissionPosArgs permissionPos?: boolean | PosCountOutputTypeCountPermissionPosArgs
salesInvoices?: boolean | PosCountOutputTypeCountSalesInvoicesArgs
} }
/** /**
@@ -1185,6 +1308,13 @@ export type PosCountOutputTypeCountPermissionPosArgs<ExtArgs extends runtime.Typ
where?: Prisma.PermissionPosWhereInput where?: Prisma.PermissionPosWhereInput
} }
/**
* PosCountOutputType without action
*/
export type PosCountOutputTypeCountSalesInvoicesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
where?: Prisma.SalesInvoiceWhereInput
}
export type PosSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{ export type PosSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
id?: boolean id?: boolean
@@ -1203,6 +1333,7 @@ export type PosSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = ru
provider?: boolean | Prisma.Pos$providerArgs<ExtArgs> provider?: boolean | Prisma.Pos$providerArgs<ExtArgs>
licenses?: boolean | Prisma.Pos$licensesArgs<ExtArgs> licenses?: boolean | Prisma.Pos$licensesArgs<ExtArgs>
permissionPos?: boolean | Prisma.Pos$permissionPosArgs<ExtArgs> permissionPos?: boolean | Prisma.Pos$permissionPosArgs<ExtArgs>
salesInvoices?: boolean | Prisma.Pos$salesInvoicesArgs<ExtArgs>
_count?: boolean | Prisma.PosCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.PosCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["pos"]> }, ExtArgs["result"]["pos"]>
@@ -1229,6 +1360,7 @@ export type PosInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = r
provider?: boolean | Prisma.Pos$providerArgs<ExtArgs> provider?: boolean | Prisma.Pos$providerArgs<ExtArgs>
licenses?: boolean | Prisma.Pos$licensesArgs<ExtArgs> licenses?: boolean | Prisma.Pos$licensesArgs<ExtArgs>
permissionPos?: boolean | Prisma.Pos$permissionPosArgs<ExtArgs> permissionPos?: boolean | Prisma.Pos$permissionPosArgs<ExtArgs>
salesInvoices?: boolean | Prisma.Pos$salesInvoicesArgs<ExtArgs>
_count?: boolean | Prisma.PosCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.PosCountOutputTypeDefaultArgs<ExtArgs>
} }
@@ -1240,6 +1372,7 @@ export type $PosPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs =
provider: Prisma.$ProviderPayload<ExtArgs> | null provider: Prisma.$ProviderPayload<ExtArgs> | null
licenses: Prisma.$LicensePayload<ExtArgs>[] licenses: Prisma.$LicensePayload<ExtArgs>[]
permissionPos: Prisma.$PermissionPosPayload<ExtArgs>[] permissionPos: Prisma.$PermissionPosPayload<ExtArgs>[]
salesInvoices: Prisma.$SalesInvoicePayload<ExtArgs>[]
} }
scalars: runtime.Types.Extensions.GetPayloadResult<{ scalars: runtime.Types.Extensions.GetPayloadResult<{
id: string id: string
@@ -1598,6 +1731,7 @@ export interface Prisma__PosClient<T, Null = never, ExtArgs extends runtime.Type
provider<T extends Prisma.Pos$providerArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$providerArgs<ExtArgs>>): Prisma.Prisma__ProviderClient<runtime.Types.Result.GetResult<Prisma.$ProviderPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> provider<T extends Prisma.Pos$providerArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$providerArgs<ExtArgs>>): Prisma.Prisma__ProviderClient<runtime.Types.Result.GetResult<Prisma.$ProviderPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
licenses<T extends Prisma.Pos$licensesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$licensesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$LicensePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> licenses<T extends Prisma.Pos$licensesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$licensesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$LicensePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
permissionPos<T extends Prisma.Pos$permissionPosArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$permissionPosArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionPosPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> permissionPos<T extends Prisma.Pos$permissionPosArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$permissionPosArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionPosPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
salesInvoices<T extends Prisma.Pos$salesInvoicesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Pos$salesInvoicesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
/** /**
* Attaches callbacks for the resolution and/or rejection of the Promise. * Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved. * @param onfulfilled The callback to execute when the Promise is resolved.
@@ -2066,6 +2200,30 @@ export type Pos$permissionPosArgs<ExtArgs extends runtime.Types.Extensions.Inter
distinct?: Prisma.PermissionPosScalarFieldEnum | Prisma.PermissionPosScalarFieldEnum[] distinct?: Prisma.PermissionPosScalarFieldEnum | Prisma.PermissionPosScalarFieldEnum[]
} }
/**
* Pos.salesInvoices
*/
export type Pos$salesInvoicesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SalesInvoice
*/
select?: Prisma.SalesInvoiceSelect<ExtArgs> | null
/**
* Omit specific fields from the SalesInvoice
*/
omit?: Prisma.SalesInvoiceOmit<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: Prisma.SalesInvoiceInclude<ExtArgs> | null
where?: Prisma.SalesInvoiceWhereInput
orderBy?: Prisma.SalesInvoiceOrderByWithRelationInput | Prisma.SalesInvoiceOrderByWithRelationInput[]
cursor?: Prisma.SalesInvoiceWhereUniqueInput
take?: number
skip?: number
distinct?: Prisma.SalesInvoiceScalarFieldEnum | Prisma.SalesInvoiceScalarFieldEnum[]
}
/** /**
* Pos without action * Pos without action
*/ */
+387 -67
View File
@@ -44,7 +44,7 @@ export type SalesInvoiceMinAggregateOutputType = {
updated_at: Date | null updated_at: Date | null
customer_id: string | null customer_id: string | null
account_id: string | null account_id: string | null
complex_id: string | null pos_id: string | null
} }
export type SalesInvoiceMaxAggregateOutputType = { export type SalesInvoiceMaxAggregateOutputType = {
@@ -57,7 +57,7 @@ export type SalesInvoiceMaxAggregateOutputType = {
updated_at: Date | null updated_at: Date | null
customer_id: string | null customer_id: string | null
account_id: string | null account_id: string | null
complex_id: string | null pos_id: string | null
} }
export type SalesInvoiceCountAggregateOutputType = { export type SalesInvoiceCountAggregateOutputType = {
@@ -71,7 +71,7 @@ export type SalesInvoiceCountAggregateOutputType = {
updated_at: number updated_at: number
customer_id: number customer_id: number
account_id: number account_id: number
complex_id: number pos_id: number
_all: number _all: number
} }
@@ -94,7 +94,7 @@ export type SalesInvoiceMinAggregateInputType = {
updated_at?: true updated_at?: true
customer_id?: true customer_id?: true
account_id?: true account_id?: true
complex_id?: true pos_id?: true
} }
export type SalesInvoiceMaxAggregateInputType = { export type SalesInvoiceMaxAggregateInputType = {
@@ -107,7 +107,7 @@ export type SalesInvoiceMaxAggregateInputType = {
updated_at?: true updated_at?: true
customer_id?: true customer_id?: true
account_id?: true account_id?: true
complex_id?: true pos_id?: true
} }
export type SalesInvoiceCountAggregateInputType = { export type SalesInvoiceCountAggregateInputType = {
@@ -121,7 +121,7 @@ export type SalesInvoiceCountAggregateInputType = {
updated_at?: true updated_at?: true
customer_id?: true customer_id?: true
account_id?: true account_id?: true
complex_id?: true pos_id?: true
_all?: true _all?: true
} }
@@ -222,7 +222,7 @@ export type SalesInvoiceGroupByOutputType = {
updated_at: Date updated_at: Date
customer_id: string | null customer_id: string | null
account_id: string account_id: string
complex_id: string pos_id: string
_count: SalesInvoiceCountAggregateOutputType | null _count: SalesInvoiceCountAggregateOutputType | null
_avg: SalesInvoiceAvgAggregateOutputType | null _avg: SalesInvoiceAvgAggregateOutputType | null
_sum: SalesInvoiceSumAggregateOutputType | null _sum: SalesInvoiceSumAggregateOutputType | null
@@ -259,8 +259,10 @@ export type SalesInvoiceWhereInput = {
updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
account_id?: Prisma.StringFilter<"SalesInvoice"> | string account_id?: Prisma.StringFilter<"SalesInvoice"> | string
complex_id?: Prisma.StringFilter<"SalesInvoice"> | string pos_id?: Prisma.StringFilter<"SalesInvoice"> | string
customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null
pos?: Prisma.XOR<Prisma.PosScalarRelationFilter, Prisma.PosWhereInput>
account?: Prisma.XOR<Prisma.ConsumerAccountScalarRelationFilter, Prisma.ConsumerAccountWhereInput>
items?: Prisma.SalesInvoiceItemListRelationFilter items?: Prisma.SalesInvoiceItemListRelationFilter
payments?: Prisma.SalesInvoicePaymentListRelationFilter payments?: Prisma.SalesInvoicePaymentListRelationFilter
} }
@@ -276,8 +278,10 @@ export type SalesInvoiceOrderByWithRelationInput = {
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
customer_id?: Prisma.SortOrderInput | Prisma.SortOrder customer_id?: Prisma.SortOrderInput | Prisma.SortOrder
account_id?: Prisma.SortOrder account_id?: Prisma.SortOrder
complex_id?: Prisma.SortOrder pos_id?: Prisma.SortOrder
customer?: Prisma.CustomerOrderByWithRelationInput customer?: Prisma.CustomerOrderByWithRelationInput
pos?: Prisma.PosOrderByWithRelationInput
account?: Prisma.ConsumerAccountOrderByWithRelationInput
items?: Prisma.SalesInvoiceItemOrderByRelationAggregateInput items?: Prisma.SalesInvoiceItemOrderByRelationAggregateInput
payments?: Prisma.SalesInvoicePaymentOrderByRelationAggregateInput payments?: Prisma.SalesInvoicePaymentOrderByRelationAggregateInput
_relevance?: Prisma.SalesInvoiceOrderByRelevanceInput _relevance?: Prisma.SalesInvoiceOrderByRelevanceInput
@@ -297,8 +301,10 @@ export type SalesInvoiceWhereUniqueInput = Prisma.AtLeast<{
updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
account_id?: Prisma.StringFilter<"SalesInvoice"> | string account_id?: Prisma.StringFilter<"SalesInvoice"> | string
complex_id?: Prisma.StringFilter<"SalesInvoice"> | string pos_id?: Prisma.StringFilter<"SalesInvoice"> | string
customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null
pos?: Prisma.XOR<Prisma.PosScalarRelationFilter, Prisma.PosWhereInput>
account?: Prisma.XOR<Prisma.ConsumerAccountScalarRelationFilter, Prisma.ConsumerAccountWhereInput>
items?: Prisma.SalesInvoiceItemListRelationFilter items?: Prisma.SalesInvoiceItemListRelationFilter
payments?: Prisma.SalesInvoicePaymentListRelationFilter payments?: Prisma.SalesInvoicePaymentListRelationFilter
}, "id" | "code"> }, "id" | "code">
@@ -314,7 +320,7 @@ export type SalesInvoiceOrderByWithAggregationInput = {
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
customer_id?: Prisma.SortOrderInput | Prisma.SortOrder customer_id?: Prisma.SortOrderInput | Prisma.SortOrder
account_id?: Prisma.SortOrder account_id?: Prisma.SortOrder
complex_id?: Prisma.SortOrder pos_id?: Prisma.SortOrder
_count?: Prisma.SalesInvoiceCountOrderByAggregateInput _count?: Prisma.SalesInvoiceCountOrderByAggregateInput
_avg?: Prisma.SalesInvoiceAvgOrderByAggregateInput _avg?: Prisma.SalesInvoiceAvgOrderByAggregateInput
_max?: Prisma.SalesInvoiceMaxOrderByAggregateInput _max?: Prisma.SalesInvoiceMaxOrderByAggregateInput
@@ -336,7 +342,7 @@ export type SalesInvoiceScalarWhereWithAggregatesInput = {
updated_at?: Prisma.DateTimeWithAggregatesFilter<"SalesInvoice"> | Date | string updated_at?: Prisma.DateTimeWithAggregatesFilter<"SalesInvoice"> | Date | string
customer_id?: Prisma.StringNullableWithAggregatesFilter<"SalesInvoice"> | string | null customer_id?: Prisma.StringNullableWithAggregatesFilter<"SalesInvoice"> | string | null
account_id?: Prisma.StringWithAggregatesFilter<"SalesInvoice"> | string account_id?: Prisma.StringWithAggregatesFilter<"SalesInvoice"> | string
complex_id?: Prisma.StringWithAggregatesFilter<"SalesInvoice"> | string pos_id?: Prisma.StringWithAggregatesFilter<"SalesInvoice"> | string
} }
export type SalesInvoiceCreateInput = { export type SalesInvoiceCreateInput = {
@@ -348,9 +354,9 @@ export type SalesInvoiceCreateInput = {
invoice_date?: Date | string | null invoice_date?: Date | string | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string
complex_id: string
customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput
pos: Prisma.PosCreateNestedOneWithoutSalesInvoicesInput
account: Prisma.ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
} }
@@ -366,7 +372,7 @@ export type SalesInvoiceUncheckedCreateInput = {
updated_at?: Date | string updated_at?: Date | string
customer_id?: string | null customer_id?: string | null
account_id: string account_id: string
complex_id: string pos_id: string
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
} }
@@ -380,9 +386,9 @@ export type SalesInvoiceUpdateInput = {
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput
pos?: Prisma.PosUpdateOneRequiredWithoutSalesInvoicesNestedInput
account?: Prisma.ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
} }
@@ -398,7 +404,7 @@ export type SalesInvoiceUncheckedUpdateInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
} }
@@ -414,7 +420,7 @@ export type SalesInvoiceCreateManyInput = {
updated_at?: Date | string updated_at?: Date | string
customer_id?: string | null customer_id?: string | null
account_id: string account_id: string
complex_id: string pos_id: string
} }
export type SalesInvoiceUpdateManyMutationInput = { export type SalesInvoiceUpdateManyMutationInput = {
@@ -426,8 +432,6 @@ export type SalesInvoiceUpdateManyMutationInput = {
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type SalesInvoiceUncheckedUpdateManyInput = { export type SalesInvoiceUncheckedUpdateManyInput = {
@@ -441,7 +445,7 @@ export type SalesInvoiceUncheckedUpdateManyInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
export type SalesInvoiceListRelationFilter = { export type SalesInvoiceListRelationFilter = {
@@ -471,7 +475,7 @@ export type SalesInvoiceCountOrderByAggregateInput = {
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
customer_id?: Prisma.SortOrder customer_id?: Prisma.SortOrder
account_id?: Prisma.SortOrder account_id?: Prisma.SortOrder
complex_id?: Prisma.SortOrder pos_id?: Prisma.SortOrder
} }
export type SalesInvoiceAvgOrderByAggregateInput = { export type SalesInvoiceAvgOrderByAggregateInput = {
@@ -488,7 +492,7 @@ export type SalesInvoiceMaxOrderByAggregateInput = {
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
customer_id?: Prisma.SortOrder customer_id?: Prisma.SortOrder
account_id?: Prisma.SortOrder account_id?: Prisma.SortOrder
complex_id?: Prisma.SortOrder pos_id?: Prisma.SortOrder
} }
export type SalesInvoiceMinOrderByAggregateInput = { export type SalesInvoiceMinOrderByAggregateInput = {
@@ -501,7 +505,7 @@ export type SalesInvoiceMinOrderByAggregateInput = {
updated_at?: Prisma.SortOrder updated_at?: Prisma.SortOrder
customer_id?: Prisma.SortOrder customer_id?: Prisma.SortOrder
account_id?: Prisma.SortOrder account_id?: Prisma.SortOrder
complex_id?: Prisma.SortOrder pos_id?: Prisma.SortOrder
} }
export type SalesInvoiceSumOrderByAggregateInput = { export type SalesInvoiceSumOrderByAggregateInput = {
@@ -513,6 +517,90 @@ export type SalesInvoiceScalarRelationFilter = {
isNot?: Prisma.SalesInvoiceWhereInput isNot?: Prisma.SalesInvoiceWhereInput
} }
export type SalesInvoiceCreateNestedManyWithoutAccountInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput> | Prisma.SalesInvoiceCreateWithoutAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput[]
createMany?: Prisma.SalesInvoiceCreateManyAccountInputEnvelope
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
}
export type SalesInvoiceUncheckedCreateNestedManyWithoutAccountInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput> | Prisma.SalesInvoiceCreateWithoutAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput[]
createMany?: Prisma.SalesInvoiceCreateManyAccountInputEnvelope
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
}
export type SalesInvoiceUpdateManyWithoutAccountNestedInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput> | Prisma.SalesInvoiceCreateWithoutAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput[]
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutAccountInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutAccountInput[]
createMany?: Prisma.SalesInvoiceCreateManyAccountInputEnvelope
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutAccountInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutAccountInput[]
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutAccountInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutAccountInput[]
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
}
export type SalesInvoiceUncheckedUpdateManyWithoutAccountNestedInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput> | Prisma.SalesInvoiceCreateWithoutAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutAccountInput[]
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutAccountInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutAccountInput[]
createMany?: Prisma.SalesInvoiceCreateManyAccountInputEnvelope
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutAccountInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutAccountInput[]
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutAccountInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutAccountInput[]
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
}
export type SalesInvoiceCreateNestedManyWithoutPosInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput> | Prisma.SalesInvoiceCreateWithoutPosInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosInput[]
createMany?: Prisma.SalesInvoiceCreateManyPosInputEnvelope
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
}
export type SalesInvoiceUncheckedCreateNestedManyWithoutPosInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput> | Prisma.SalesInvoiceCreateWithoutPosInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosInput[]
createMany?: Prisma.SalesInvoiceCreateManyPosInputEnvelope
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
}
export type SalesInvoiceUpdateManyWithoutPosNestedInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput> | Prisma.SalesInvoiceCreateWithoutPosInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosInput[]
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosInput[]
createMany?: Prisma.SalesInvoiceCreateManyPosInputEnvelope
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosInput[]
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosInput[]
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
}
export type SalesInvoiceUncheckedUpdateManyWithoutPosNestedInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput> | Prisma.SalesInvoiceCreateWithoutPosInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosInput[]
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosInput[]
createMany?: Prisma.SalesInvoiceCreateManyPosInputEnvelope
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosInput[]
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosInput[]
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
}
export type SalesInvoiceCreateNestedManyWithoutCustomerInput = { export type SalesInvoiceCreateNestedManyWithoutCustomerInput = {
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutCustomerInput, Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput> | Prisma.SalesInvoiceCreateWithoutCustomerInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput[] create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutCustomerInput, Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput> | Prisma.SalesInvoiceCreateWithoutCustomerInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput | Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput[] connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput | Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput[]
@@ -591,6 +679,135 @@ export type SalesInvoiceUpdateOneRequiredWithoutPaymentsNestedInput = {
update?: Prisma.XOR<Prisma.XOR<Prisma.SalesInvoiceUpdateToOneWithWhereWithoutPaymentsInput, Prisma.SalesInvoiceUpdateWithoutPaymentsInput>, Prisma.SalesInvoiceUncheckedUpdateWithoutPaymentsInput> update?: Prisma.XOR<Prisma.XOR<Prisma.SalesInvoiceUpdateToOneWithWhereWithoutPaymentsInput, Prisma.SalesInvoiceUpdateWithoutPaymentsInput>, Prisma.SalesInvoiceUncheckedUpdateWithoutPaymentsInput>
} }
export type SalesInvoiceCreateWithoutAccountInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput
pos: Prisma.PosCreateNestedOneWithoutSalesInvoicesInput
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
}
export type SalesInvoiceUncheckedCreateWithoutAccountInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer_id?: string | null
pos_id: string
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
}
export type SalesInvoiceCreateOrConnectWithoutAccountInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput>
}
export type SalesInvoiceCreateManyAccountInputEnvelope = {
data: Prisma.SalesInvoiceCreateManyAccountInput | Prisma.SalesInvoiceCreateManyAccountInput[]
skipDuplicates?: boolean
}
export type SalesInvoiceUpsertWithWhereUniqueWithoutAccountInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
update: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutAccountInput, Prisma.SalesInvoiceUncheckedUpdateWithoutAccountInput>
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutAccountInput>
}
export type SalesInvoiceUpdateWithWhereUniqueWithoutAccountInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
data: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutAccountInput, Prisma.SalesInvoiceUncheckedUpdateWithoutAccountInput>
}
export type SalesInvoiceUpdateManyWithWhereWithoutAccountInput = {
where: Prisma.SalesInvoiceScalarWhereInput
data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutAccountInput>
}
export type SalesInvoiceScalarWhereInput = {
AND?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
OR?: Prisma.SalesInvoiceScalarWhereInput[]
NOT?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
id?: Prisma.StringFilter<"SalesInvoice"> | string
code?: Prisma.StringFilter<"SalesInvoice"> | string
total_amount?: Prisma.DecimalFilter<"SalesInvoice"> | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
unknown_customer?: Prisma.JsonNullableFilter<"SalesInvoice">
invoice_date?: Prisma.DateTimeNullableFilter<"SalesInvoice"> | Date | string | null
created_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
account_id?: Prisma.StringFilter<"SalesInvoice"> | string
pos_id?: Prisma.StringFilter<"SalesInvoice"> | string
}
export type SalesInvoiceCreateWithoutPosInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput
account: Prisma.ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
}
export type SalesInvoiceUncheckedCreateWithoutPosInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer_id?: string | null
account_id: string
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
}
export type SalesInvoiceCreateOrConnectWithoutPosInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput>
}
export type SalesInvoiceCreateManyPosInputEnvelope = {
data: Prisma.SalesInvoiceCreateManyPosInput | Prisma.SalesInvoiceCreateManyPosInput[]
skipDuplicates?: boolean
}
export type SalesInvoiceUpsertWithWhereUniqueWithoutPosInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
update: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutPosInput, Prisma.SalesInvoiceUncheckedUpdateWithoutPosInput>
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosInput>
}
export type SalesInvoiceUpdateWithWhereUniqueWithoutPosInput = {
where: Prisma.SalesInvoiceWhereUniqueInput
data: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutPosInput, Prisma.SalesInvoiceUncheckedUpdateWithoutPosInput>
}
export type SalesInvoiceUpdateManyWithWhereWithoutPosInput = {
where: Prisma.SalesInvoiceScalarWhereInput
data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosInput>
}
export type SalesInvoiceCreateWithoutCustomerInput = { export type SalesInvoiceCreateWithoutCustomerInput = {
id?: string id?: string
code: string code: string
@@ -600,8 +817,8 @@ export type SalesInvoiceCreateWithoutCustomerInput = {
invoice_date?: Date | string | null invoice_date?: Date | string | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string pos: Prisma.PosCreateNestedOneWithoutSalesInvoicesInput
complex_id: string account: Prisma.ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
} }
@@ -616,7 +833,7 @@ export type SalesInvoiceUncheckedCreateWithoutCustomerInput = {
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string account_id: string
complex_id: string pos_id: string
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
} }
@@ -647,23 +864,6 @@ export type SalesInvoiceUpdateManyWithWhereWithoutCustomerInput = {
data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerInput> data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerInput>
} }
export type SalesInvoiceScalarWhereInput = {
AND?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
OR?: Prisma.SalesInvoiceScalarWhereInput[]
NOT?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
id?: Prisma.StringFilter<"SalesInvoice"> | string
code?: Prisma.StringFilter<"SalesInvoice"> | string
total_amount?: Prisma.DecimalFilter<"SalesInvoice"> | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
unknown_customer?: Prisma.JsonNullableFilter<"SalesInvoice">
invoice_date?: Prisma.DateTimeNullableFilter<"SalesInvoice"> | Date | string | null
created_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
updated_at?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
customer_id?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
account_id?: Prisma.StringFilter<"SalesInvoice"> | string
complex_id?: Prisma.StringFilter<"SalesInvoice"> | string
}
export type SalesInvoiceCreateWithoutItemsInput = { export type SalesInvoiceCreateWithoutItemsInput = {
id?: string id?: string
code: string code: string
@@ -673,9 +873,9 @@ export type SalesInvoiceCreateWithoutItemsInput = {
invoice_date?: Date | string | null invoice_date?: Date | string | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string
complex_id: string
customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput
pos: Prisma.PosCreateNestedOneWithoutSalesInvoicesInput
account: Prisma.ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput
payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
} }
@@ -690,7 +890,7 @@ export type SalesInvoiceUncheckedCreateWithoutItemsInput = {
updated_at?: Date | string updated_at?: Date | string
customer_id?: string | null customer_id?: string | null
account_id: string account_id: string
complex_id: string pos_id: string
payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput payments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
} }
@@ -719,9 +919,9 @@ export type SalesInvoiceUpdateWithoutItemsInput = {
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput
pos?: Prisma.PosUpdateOneRequiredWithoutSalesInvoicesNestedInput
account?: Prisma.ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
} }
@@ -736,7 +936,7 @@ export type SalesInvoiceUncheckedUpdateWithoutItemsInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
} }
@@ -749,9 +949,9 @@ export type SalesInvoiceCreateWithoutPaymentsInput = {
invoice_date?: Date | string | null invoice_date?: Date | string | null
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string
complex_id: string
customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput customer?: Prisma.CustomerCreateNestedOneWithoutSales_invoicesInput
pos: Prisma.PosCreateNestedOneWithoutSalesInvoicesInput
account: Prisma.ConsumerAccountCreateNestedOneWithoutSalesInvoicesInput
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
} }
@@ -766,7 +966,7 @@ export type SalesInvoiceUncheckedCreateWithoutPaymentsInput = {
updated_at?: Date | string updated_at?: Date | string
customer_id?: string | null customer_id?: string | null
account_id: string account_id: string
complex_id: string pos_id: string
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
} }
@@ -795,9 +995,9 @@ export type SalesInvoiceUpdateWithoutPaymentsInput = {
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string
customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput
pos?: Prisma.PosUpdateOneRequiredWithoutSalesInvoicesNestedInput
account?: Prisma.ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
} }
@@ -812,10 +1012,122 @@ export type SalesInvoiceUncheckedUpdateWithoutPaymentsInput = {
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
} }
export type SalesInvoiceCreateManyAccountInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer_id?: string | null
pos_id: string
}
export type SalesInvoiceUpdateWithoutAccountInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput
pos?: Prisma.PosUpdateOneRequiredWithoutSalesInvoicesNestedInput
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
}
export type SalesInvoiceUncheckedUpdateWithoutAccountInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
pos_id?: Prisma.StringFieldUpdateOperationsInput | string
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
}
export type SalesInvoiceUncheckedUpdateManyWithoutAccountInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
pos_id?: Prisma.StringFieldUpdateOperationsInput | string
}
export type SalesInvoiceCreateManyPosInput = {
id?: string
code: string
total_amount: runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Date | string | null
created_at?: Date | string
updated_at?: Date | string
customer_id?: string | null
account_id: string
}
export type SalesInvoiceUpdateWithoutPosInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer?: Prisma.CustomerUpdateOneWithoutSales_invoicesNestedInput
account?: Prisma.ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
}
export type SalesInvoiceUncheckedUpdateWithoutPosInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
}
export type SalesInvoiceUncheckedUpdateManyWithoutPosInput = {
id?: Prisma.StringFieldUpdateOperationsInput | string
code?: Prisma.StringFieldUpdateOperationsInput | string
total_amount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
notes?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
unknown_customer?: Prisma.NullableJsonNullValueInput | runtime.InputJsonValue
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
customer_id?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
account_id?: Prisma.StringFieldUpdateOperationsInput | string
}
export type SalesInvoiceCreateManyCustomerInput = { export type SalesInvoiceCreateManyCustomerInput = {
id?: string id?: string
code: string code: string
@@ -826,7 +1138,7 @@ export type SalesInvoiceCreateManyCustomerInput = {
created_at?: Date | string created_at?: Date | string
updated_at?: Date | string updated_at?: Date | string
account_id: string account_id: string
complex_id: string pos_id: string
} }
export type SalesInvoiceUpdateWithoutCustomerInput = { export type SalesInvoiceUpdateWithoutCustomerInput = {
@@ -838,8 +1150,8 @@ export type SalesInvoiceUpdateWithoutCustomerInput = {
invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null invoice_date?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string pos?: Prisma.PosUpdateOneRequiredWithoutSalesInvoicesNestedInput
complex_id?: Prisma.StringFieldUpdateOperationsInput | string account?: Prisma.ConsumerAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
} }
@@ -854,7 +1166,7 @@ export type SalesInvoiceUncheckedUpdateWithoutCustomerInput = {
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput payments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
} }
@@ -869,7 +1181,7 @@ export type SalesInvoiceUncheckedUpdateManyWithoutCustomerInput = {
created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string created_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updated_at?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
account_id?: Prisma.StringFieldUpdateOperationsInput | string account_id?: Prisma.StringFieldUpdateOperationsInput | string
complex_id?: Prisma.StringFieldUpdateOperationsInput | string pos_id?: Prisma.StringFieldUpdateOperationsInput | string
} }
@@ -923,8 +1235,10 @@ export type SalesInvoiceSelect<ExtArgs extends runtime.Types.Extensions.Internal
updated_at?: boolean updated_at?: boolean
customer_id?: boolean customer_id?: boolean
account_id?: boolean account_id?: boolean
complex_id?: boolean pos_id?: boolean
customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs> customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs>
pos?: boolean | Prisma.PosDefaultArgs<ExtArgs>
account?: boolean | Prisma.ConsumerAccountDefaultArgs<ExtArgs>
items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs> items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs>
payments?: boolean | Prisma.SalesInvoice$paymentsArgs<ExtArgs> payments?: boolean | Prisma.SalesInvoice$paymentsArgs<ExtArgs>
_count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs>
@@ -943,12 +1257,14 @@ export type SalesInvoiceSelectScalar = {
updated_at?: boolean updated_at?: boolean
customer_id?: boolean customer_id?: boolean
account_id?: boolean account_id?: boolean
complex_id?: boolean pos_id?: boolean
} }
export type SalesInvoiceOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "code" | "total_amount" | "notes" | "unknown_customer" | "invoice_date" | "created_at" | "updated_at" | "customer_id" | "account_id" | "complex_id", ExtArgs["result"]["salesInvoice"]> export type SalesInvoiceOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "code" | "total_amount" | "notes" | "unknown_customer" | "invoice_date" | "created_at" | "updated_at" | "customer_id" | "account_id" | "pos_id", ExtArgs["result"]["salesInvoice"]>
export type SalesInvoiceInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = { export type SalesInvoiceInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs> customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs>
pos?: boolean | Prisma.PosDefaultArgs<ExtArgs>
account?: boolean | Prisma.ConsumerAccountDefaultArgs<ExtArgs>
items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs> items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs>
payments?: boolean | Prisma.SalesInvoice$paymentsArgs<ExtArgs> payments?: boolean | Prisma.SalesInvoice$paymentsArgs<ExtArgs>
_count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs> _count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs>
@@ -958,6 +1274,8 @@ export type $SalesInvoicePayload<ExtArgs extends runtime.Types.Extensions.Intern
name: "SalesInvoice" name: "SalesInvoice"
objects: { objects: {
customer: Prisma.$CustomerPayload<ExtArgs> | null customer: Prisma.$CustomerPayload<ExtArgs> | null
pos: Prisma.$PosPayload<ExtArgs>
account: Prisma.$ConsumerAccountPayload<ExtArgs>
items: Prisma.$SalesInvoiceItemPayload<ExtArgs>[] items: Prisma.$SalesInvoiceItemPayload<ExtArgs>[]
payments: Prisma.$SalesInvoicePaymentPayload<ExtArgs>[] payments: Prisma.$SalesInvoicePaymentPayload<ExtArgs>[]
} }
@@ -972,7 +1290,7 @@ export type $SalesInvoicePayload<ExtArgs extends runtime.Types.Extensions.Intern
updated_at: Date updated_at: Date
customer_id: string | null customer_id: string | null
account_id: string account_id: string
complex_id: string pos_id: string
}, ExtArgs["result"]["salesInvoice"]> }, ExtArgs["result"]["salesInvoice"]>
composites: {} composites: {}
} }
@@ -1314,6 +1632,8 @@ readonly fields: SalesInvoiceFieldRefs;
export interface Prisma__SalesInvoiceClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> { export interface Prisma__SalesInvoiceClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise" readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends Prisma.SalesInvoice$customerArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$customerArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> customer<T extends Prisma.SalesInvoice$customerArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$customerArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
pos<T extends Prisma.PosDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.PosDefaultArgs<ExtArgs>>): Prisma.Prisma__PosClient<runtime.Types.Result.GetResult<Prisma.$PosPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
account<T extends Prisma.ConsumerAccountDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ConsumerAccountDefaultArgs<ExtArgs>>): Prisma.Prisma__ConsumerAccountClient<runtime.Types.Result.GetResult<Prisma.$ConsumerAccountPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
items<T extends Prisma.SalesInvoice$itemsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoiceItemPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> items<T extends Prisma.SalesInvoice$itemsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoiceItemPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
payments<T extends Prisma.SalesInvoice$paymentsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$paymentsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePaymentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null> payments<T extends Prisma.SalesInvoice$paymentsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$paymentsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePaymentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
/** /**
@@ -1355,7 +1675,7 @@ export interface SalesInvoiceFieldRefs {
readonly updated_at: Prisma.FieldRef<"SalesInvoice", 'DateTime'> readonly updated_at: Prisma.FieldRef<"SalesInvoice", 'DateTime'>
readonly customer_id: Prisma.FieldRef<"SalesInvoice", 'String'> readonly customer_id: Prisma.FieldRef<"SalesInvoice", 'String'>
readonly account_id: Prisma.FieldRef<"SalesInvoice", 'String'> readonly account_id: Prisma.FieldRef<"SalesInvoice", 'String'>
readonly complex_id: Prisma.FieldRef<"SalesInvoice", 'String'> readonly pos_id: Prisma.FieldRef<"SalesInvoice", 'String'>
} }
+12 -4
View File
@@ -6,13 +6,15 @@ import { AppModule } from './app.module'
import { PrismaExceptionFilter } from './common/filters/prisma-exception.filter' import { PrismaExceptionFilter } from './common/filters/prisma-exception.filter'
import { ValidationExceptionFilter } from './common/filters/validation-exception.filter' import { ValidationExceptionFilter } from './common/filters/validation-exception.filter'
import { JwtAuthGuard } from './common/guards/jwt-auth.guard' import { JwtAuthGuard } from './common/guards/jwt-auth.guard'
import { PosGuard } from './common/guards/pos.gaurd'
import { LoggingInterceptor } from './common/interceptors/logging.interceptor' import { LoggingInterceptor } from './common/interceptors/logging.interceptor'
import { ResponseMappingInterceptor } from './common/interceptors/response-mapping.interceptor' import { ResponseMappingInterceptor } from './common/interceptors/response-mapping.interceptor'
import { PrismaService } from './prisma/prisma.service'
const cookieParser = require('cookie-parser')
async function bootstrap() { async function bootstrap() {
const app = await NestFactory.create(AppModule) const app = await NestFactory.create(AppModule)
const cookieParser = (await import('cookie-parser')).default
app.use(cookieParser()) app.use(cookieParser())
const config = new DocumentBuilder() const config = new DocumentBuilder()
@@ -53,18 +55,21 @@ async function bootstrap() {
// Enable CORS. You can set `CORS_ORIGINS` to a comma-separated list of allowed origins. // Enable CORS. You can set `CORS_ORIGINS` to a comma-separated list of allowed origins.
// Defaults include common localhost origins used by front-end dev servers. // Defaults include common localhost origins used by front-end dev servers.
const defaultOrigins = ['*', 'http://localhost:5000'] const defaultOrigins = ['http://localhost:5000', 'http://127.0.0.1:5000']
const envOrigins = process.env.CORS_ORIGINS const envOrigins = process.env.CORS_ORIGINS
? process.env.CORS_ORIGINS.split(',') ? process.env.CORS_ORIGINS.split(',')
.map(s => s.trim()) .map(s => s.trim())
.filter(Boolean) .filter(Boolean)
: [] : []
const allowedOrigins = envOrigins.length ? envOrigins : defaultOrigins const allowedOrigins = (envOrigins.length ? envOrigins : defaultOrigins).filter(
origin => origin !== '*',
)
app.enableCors({ app.enableCors({
origin: allowedOrigins, origin: allowedOrigins,
credentials: true, credentials: true,
methods: 'GET,HEAD,PUT,PATCH,POST,DELETE,OPTIONS', methods: 'GET,HEAD,PUT,PATCH,POST,DELETE,OPTIONS',
allowedHeaders: 'Content-Type, Accept, Authorization, X-Requested-With, X-CSRF-Token', allowedHeaders:
'Content-Type, Accept, Authorization, X-Requested-With, X-CSRF-Token, pos_id',
}) })
// Register global logging and response mapping interceptors // Register global logging and response mapping interceptors
@@ -77,6 +82,9 @@ async function bootstrap() {
app.useGlobalFilters(new ValidationExceptionFilter(), new PrismaExceptionFilter()) app.useGlobalFilters(new ValidationExceptionFilter(), new PrismaExceptionFilter())
app.useGlobalGuards(new JwtAuthGuard(app.get(JwtService), app.get(Reflector))) app.useGlobalGuards(new JwtAuthGuard(app.get(JwtService), app.get(Reflector)))
app.useGlobalGuards(
new PosGuard(app.get(JwtService), app.get(Reflector), app.get(PrismaService)),
)
await app.listen(process.env.PORT ?? 5002) await app.listen(process.env.PORT ?? 5002)
} }
+1 -1
View File
@@ -11,7 +11,7 @@ import { AuthUtils } from './auth.utils'
imports: [ imports: [
PrismaModule, PrismaModule,
JwtModule.register({ JwtModule.register({
secret: env('JWT_SECRET') || 'secret', secret: env('JWT_SECRET'),
signOptions: { expiresIn: Number(env('JWT_EXPIRES_IN')) || '48h' }, signOptions: { expiresIn: Number(env('JWT_EXPIRES_IN')) || '48h' },
}), }),
], ],
+1 -1
View File
@@ -6,7 +6,7 @@ import { Injectable, NotFoundException } from '@nestjs/common'
import { JwtService } from '@nestjs/jwt' import { JwtService } from '@nestjs/jwt'
import { randomBytes } from 'crypto' import { randomBytes } from 'crypto'
import { env } from 'prisma/config' import { env } from 'prisma/config'
import { AccessTokenPayload } from './models' import { AccessTokenPayload } from '../../common/models/tokenPayload.model'
export interface ITokenPayload { export interface ITokenPayload {
type: AccountType type: AccountType
+1 -2
View File
@@ -1,9 +1,8 @@
import { createParamDecorator, ExecutionContext } from '@nestjs/common' import { createParamDecorator, ExecutionContext } from '@nestjs/common'
import { AccessTokenPayload } from 'common/models/token-model'
export const reqTokenPayload = createParamDecorator( export const reqTokenPayload = createParamDecorator(
(data: unknown, ctx: ExecutionContext) => { (data: unknown, ctx: ExecutionContext) => {
const req = ctx.switchToHttp().getRequest() const req = ctx.switchToHttp().getRequest()
return req.dataPayload as AccessTokenPayload return req.dataPayload
}, },
) )
@@ -1,3 +1,4 @@
import { TokenAccount } from '@/common/decorators/tokenInfo.decorator'
import { Body, Controller, Get, Param, Patch, Post } from '@nestjs/common' import { Body, Controller, Get, Param, Patch, Post } from '@nestjs/common'
import { ApiTags } from '@nestjs/swagger' import { ApiTags } from '@nestjs/swagger'
import { AccountsService } from './accounts.service' import { AccountsService } from './accounts.service'
@@ -9,7 +10,7 @@ export class AccountsController {
constructor(private readonly accountsService: AccountsService) {} constructor(private readonly accountsService: AccountsService) {}
@Get() @Get()
async findAll(@Param('consumerId') consumerId: string) { async findAll(@TokenAccount('userId') consumerId: string) {
return this.accountsService.findAll(consumerId) return this.accountsService.findAll(consumerId)
} }
@@ -20,7 +21,7 @@ export class AccountsController {
@Post() @Post()
async create( async create(
@Param('consumerId') consumerId: string, @TokenAccount('userId') consumerId: string,
@Body() data: CreateConsumerAccountDto, @Body() data: CreateConsumerAccountDto,
) { ) {
return this.accountsService.create(consumerId, data) return this.accountsService.create(consumerId, data)
@@ -72,8 +72,8 @@ export class AccountsService {
return ResponseMapper.update(account) return ResponseMapper.update(account)
} }
async delete(id: string) { // async delete(id: string) {
await this.prisma.account.delete({ where: { id } }) // await this.prisma.account.delete({ where: { id } })
return ResponseMapper.delete() // return ResponseMapper.delete()
} // }
} }
@@ -15,8 +15,6 @@ export class ConsumerComplexGoodsController {
@Param('businessActivityId') businessActivityId: string, @Param('businessActivityId') businessActivityId: string,
@Param('complexId') complexId: string, @Param('complexId') complexId: string,
) { ) {
console.log(userId, businessActivityId, complexId)
return this.service.findAll(userId, businessActivityId, complexId) return this.service.findAll(userId, businessActivityId, complexId)
} }
@@ -1,6 +1,6 @@
import { Body, Controller, Get, Param, Post } from '@nestjs/common' import { PosInfo } from '@/common/decorators/posInfo.decorator'
import { reqTokenPayload } from '../../auth/current-user.decorator' import type { IPosPayload } from '@/common/models/posPayload.model'
import { CreateGoodCategoryDto } from './dto/create-good-category.dto' import { Controller, Get } from '@nestjs/common'
import { GoodCategoriesService } from './good-categories.service' import { GoodCategoriesService } from './good-categories.service'
@Controller('pos/good_categories') @Controller('pos/good_categories')
@@ -8,17 +8,17 @@ export class GoodCategoriesController {
constructor(private readonly goodCategoriesService: GoodCategoriesService) {} constructor(private readonly goodCategoriesService: GoodCategoriesService) {}
@Get() @Get()
findAll(@reqTokenPayload() account) { findAll(@PosInfo() { complex_id, guild_id }: IPosPayload) {
return this.goodCategoriesService.findAll(account.complex_id) return this.goodCategoriesService.findAll(complex_id, guild_id)
} }
@Get(':id') // @Get(':id')
findOne(@Param('id') id: string, @reqTokenPayload() account) { // findOne(@Param('id') id: string, @PosInfo() { complex_id, guild_id }: IPosPayload) {
return this.goodCategoriesService.findOne(id, account.complex_id) // return this.goodCategoriesService.findOne(id, account.complex_id)
} // }
@Post() // @Post()
create(@Body() data: CreateGoodCategoryDto, @reqTokenPayload() account) { // create(@Body() data: CreateGoodCategoryDto, @reqTokenPayload() account) {
return this.goodCategoriesService.create(data, account.complex_id) // return this.goodCategoriesService.create(data, account.complex_id)
} // }
} }
@@ -1,25 +1,39 @@
import { GoodCategorySelect } from '@/generated/prisma/models'
import { Injectable } from '@nestjs/common' import { Injectable } from '@nestjs/common'
import { ResponseMapper } from '../../../common/response/response-mapper' import { ResponseMapper } from '../../../common/response/response-mapper'
import { PrismaService } from '../../../prisma/prisma.service' import { PrismaService } from '../../../prisma/prisma.service'
import { CreateGoodCategoryDto } from './dto/create-good-category.dto'
@Injectable() @Injectable()
export class GoodCategoriesService { export class GoodCategoriesService {
constructor(private prisma: PrismaService) {} constructor(private prisma: PrismaService) {}
async findAll(complex_id: string) {
private readonly defaultSelect: GoodCategorySelect = {
id: true,
name: true,
image_url: true,
}
async findAll(complex_id: string, guild_id: string) {
const categories = await this.prisma.goodCategory.findMany({ const categories = await this.prisma.goodCategory.findMany({
where: { where: {
complex_id, guild_id,
}, },
include: { select: {
...this.defaultSelect,
_count: { _count: {
select: { select: {
goods: true, goods: {
where: {
OR: [
{ is_default_guild_good: true },
{
complex_id,
},
],
},
}, },
}, },
}, },
omit: {
complex_id: true,
}, },
}) })
@@ -34,18 +48,18 @@ export class GoodCategoriesService {
) )
} }
findOne(categoryId: string, complex_id: string) { // findOne(categoryId: string, complex_id: string) {
return {} // return {}
} // }
create(data: CreateGoodCategoryDto, complex_id: string) { // create(data: CreateGoodCategoryDto, complex_id: string) {
const category = this.prisma.goodCategory.create({ // const category = this.prisma.goodCategory.create({
data: { // data: {
...data, // ...data,
complex_id, // complex_id,
}, // },
}) // })
return ResponseMapper.create(category) // return ResponseMapper.create(category)
} // }
} }
+11 -11
View File
@@ -1,6 +1,6 @@
import { Body, Controller, Get, Param, Post } from '@nestjs/common' import { PosInfo } from '@/common/decorators/posInfo.decorator'
import { reqTokenPayload } from '../../auth/current-user.decorator' import type { IPosPayload } from '@/common/models/posPayload.model'
import { CreateGoodDto } from './dto/create-good.dto' import { Controller, Get, Param } from '@nestjs/common'
import { GoodsService } from './goods.service' import { GoodsService } from './goods.service'
@Controller('pos/goods') @Controller('pos/goods')
@@ -8,17 +8,17 @@ export class GoodsController {
constructor(private readonly goodsService: GoodsService) {} constructor(private readonly goodsService: GoodsService) {}
@Get() @Get()
findAll(@reqTokenPayload() account) { findAll(@PosInfo() { complex_id, guild_id }: IPosPayload) {
return this.goodsService.findAll(account.complex_id) return this.goodsService.findAll(complex_id, guild_id)
} }
@Get(':id') @Get(':id')
findOne(@Param('id') goodId: string, @reqTokenPayload() account) { findOne(@PosInfo() { complex_id, guild_id }: IPosPayload, @Param('id') goodId: string) {
return this.goodsService.findOne(goodId, account.complex_id) return this.goodsService.findOne(goodId, complex_id, guild_id)
} }
@Post() // @Post()
create(@Body() data: CreateGoodDto, @reqTokenPayload() account) { // create(@Body() data: CreateGoodDto, @PosInfo() { complex_id, guild_id }: IPosPayload) {
return this.goodsService.create(data, account.complex_id) // return this.goodsService.create(data, complex_id, guild_id)
} // }
} }
+40 -14
View File
@@ -1,3 +1,4 @@
import { GoodSelect } from '@/generated/prisma/models'
import { Injectable } from '@nestjs/common' import { Injectable } from '@nestjs/common'
import { ResponseMapper } from '../../../common/response/response-mapper' import { ResponseMapper } from '../../../common/response/response-mapper'
import { PrismaService } from '../../../prisma/prisma.service' import { PrismaService } from '../../../prisma/prisma.service'
@@ -7,31 +8,59 @@ import { CreateGoodDto } from './dto/create-good.dto'
export class GoodsService { export class GoodsService {
constructor(private prisma: PrismaService) {} constructor(private prisma: PrismaService) {}
async findAll(complex_id: string) { private readonly defaultSelect: GoodSelect = {
id: true,
name: true,
barcode: true,
created_at: true,
description: true,
sku: true,
local_sku: true,
is_default_guild_good: true,
pricing_model: true,
unit_type: true,
category: {
select: {
id: true,
name: true,
image_url: true,
},
},
}
async findAll(complex_id: string, guild_id: string) {
const goods = await this.prisma.good.findMany({ const goods = await this.prisma.good.findMany({
where: { where: {
OR: [
{
is_default_guild_good: true,
category: {
guild_id,
},
},
{
complex_id, complex_id,
}, },
omit: { ],
complex_id: true,
deleted_at: true,
}, },
select: this.defaultSelect,
}) })
return ResponseMapper.list(goods) return ResponseMapper.list(goods)
} }
async findOne(good_id: string, complex_id: string) { async findOne(good_id: string, complex_id: string, guild_id: string) {
const good = await this.prisma.good.findUnique({ const good = await this.prisma.good.findUnique({
where: { where: {
complex_id,
id: good_id, id: good_id,
complex: {
id: complex_id,
business_activity: {
guild_id,
}, },
omit: {
complex_id: true,
deleted_at: true,
}, },
},
select: this.defaultSelect,
}) })
return ResponseMapper.single(good) return ResponseMapper.single(good)
@@ -64,10 +93,7 @@ export class GoodsService {
}, },
}, },
}, },
omit: { select: this.defaultSelect,
complex_id: true,
deleted_at: true,
},
}) })
return ResponseMapper.create(good) return ResponseMapper.create(good)
+15
View File
@@ -0,0 +1,15 @@
import { PosInfo } from '@/common/decorators/posInfo.decorator'
import { Controller, Get } from '@nestjs/common'
import { ApiTags } from '@nestjs/swagger'
import { PosService } from './pos.service'
@ApiTags('Pos')
@Controller('pos')
export class PosController {
constructor(private service: PosService) {}
@Get()
async getInfo(@PosInfo('pos_id') pos_id: string) {
return await this.service.getInfo(pos_id)
}
}
+88 -12
View File
@@ -1,21 +1,97 @@
import { Injectable, NestMiddleware, UnauthorizedException } from '@nestjs/common' import { checkAndDecodeJwtToken } from '@/common/utils/jwt-user.util'
import { PrismaService } from '@/prisma/prisma.service'
import { ForbiddenException, Injectable, NestMiddleware } from '@nestjs/common'
import { JwtService } from '@nestjs/jwt'
import { NextFunction, Request, Response } from 'express' import { NextFunction, Request, Response } from 'express'
@Injectable() @Injectable()
export class PosMiddleware implements NestMiddleware { export class PosMiddleware implements NestMiddleware {
use(req: Request, _res: Response, next: NextFunction) { constructor(
// const a = reqTokenPayload() private prisma: PrismaService,
// console.log(a) private jwtService: JwtService,
) {}
// Middleware-based admin check (replace with real auth logic) async use(req: Request, _res: Response, next: NextFunction) {
const isAdminHeader = req.headers['x-admin'] const doForbidden = () => {
throw new ForbiddenException('شما دسترسی لازم را ندارید')
if (isAdminHeader === 'true') {
// mark request if needed downstream
req['isAdminRequest'] = true
} }
return next() try {
const tokenAccount = checkAndDecodeJwtToken(req, this.jwtService)
throw new UnauthorizedException('Admin access required') // const posId = req.cookies['posId']
const posId = req.headers.pos_id as string
if (tokenAccount?.type !== 'CONSUMER' || !posId || typeof posId !== 'string') {
return doForbidden()
}
const consumerAccount = await this.prisma.consumerAccount.findUnique({
where: {
account_id: tokenAccount.account_id,
},
})
if (!consumerAccount) {
return doForbidden()
}
const complex = await this.prisma.complex.findFirst({
where: {
pos_list: {
some: {
id: posId,
},
},
},
include: {
business_activity: {
include: {
guild: true,
},
},
},
})
if (!complex) {
return doForbidden()
}
// if (account?.role !== ConsumerRole.OWNER) {
// const accountPermissions = await this.prisma.permissionConsumer.findUnique({
// where: {
// account_id: account?.id,
// },
// include: {
// posPermissions: true,
// businessPermissions: true,
// complexPermissions: true,
// },
// })
// if (
// !(
// accountPermissions?.businessPermissions.some(
// permission => permission.business_id,
// ) ||
// accountPermissions?.complexPermissions.some(
// permission => permission.complex_id,
// ) ||
// accountPermissions?.posPermissions.some(permission => permission.pos_id)
// )
// ) {
// return doForbidden()
// }
// }
req.posData = {
pos_id: posId,
complex_id: complex.id,
business_id: complex.business_activity_id,
guild_id: complex.business_activity.guild_id,
consumer_account_id: consumerAccount.id,
}
req.decodedToken = tokenAccount
return next()
} catch (error) {
return doForbidden()
}
} }
} }
+10 -1
View File
@@ -1,12 +1,17 @@
import { MiddlewareConsumer, Module, NestModule, RequestMethod } from '@nestjs/common' import { MiddlewareConsumer, Module, NestModule, RequestMethod } from '@nestjs/common'
import { JwtService } from '@nestjs/jwt'
import { PosConfigModule } from './config/config.module' import { PosConfigModule } from './config/config.module'
import { PosCustomersModule } from './customers/customers.module' import { PosCustomersModule } from './customers/customers.module'
import { PosGoodCategoriesModule } from './good-categories/good-categories.module' import { PosGoodCategoriesModule } from './good-categories/good-categories.module'
import { PosGoodsModule } from './goods/goods.module' import { PosGoodsModule } from './goods/goods.module'
import { PosController } from './pos.controller'
import { PosMiddleware } from './pos.middleware' import { PosMiddleware } from './pos.middleware'
import { PosService } from './pos.service'
import { PosSalesInvoicesModule } from './sales-invoices/sales-invoices.module' import { PosSalesInvoicesModule } from './sales-invoices/sales-invoices.module'
@Module({ @Module({
controllers: [PosController],
providers: [PosService, JwtService],
imports: [ imports: [
PosConfigModule, PosConfigModule,
PosCustomersModule, PosCustomersModule,
@@ -17,11 +22,15 @@ import { PosSalesInvoicesModule } from './sales-invoices/sales-invoices.module'
}) })
export class PosModule implements NestModule { export class PosModule implements NestModule {
configure(consumer: MiddlewareConsumer) { configure(consumer: MiddlewareConsumer) {
// apply middleware to all routes within this module (scoped under /admin)
consumer.apply(PosMiddleware).forRoutes({ consumer.apply(PosMiddleware).forRoutes({
path: '/pos*path', path: '/pos*path',
method: RequestMethod.ALL, method: RequestMethod.ALL,
version: '1', version: '1',
}) })
consumer.apply(PosMiddleware).forRoutes({
path: '/pos',
method: RequestMethod.ALL,
version: '1',
})
} }
} }
+56
View File
@@ -0,0 +1,56 @@
import { PrismaService } from '@/prisma/prisma.service'
import { Injectable } from '@nestjs/common'
import { ResponseMapper } from 'common/response/response-mapper'
@Injectable()
export class PosService {
constructor(private readonly prisma: PrismaService) {}
async getInfo(pos_id: string) {
const pos = await this.prisma.pos.findUniqueOrThrow({
where: {
id: pos_id,
},
select: {
name: true,
complex: {
select: {
id: true,
name: true,
tax_id: true,
business_activity: {
select: {
id: true,
name: true,
guild: {
select: {
id: true,
name: true,
code: true,
},
},
},
},
},
},
},
})
const { name, complex } = pos
const { name: complexName, id: complexId, tax_id, business_activity } = complex
const { name: businessName, id: businessId, guild } = business_activity
return ResponseMapper.single({
name,
complex: {
id: complexId,
name: complexName,
tax_id,
},
businessActivity: {
id: businessId,
name: businessName,
},
guild,
})
}
}
@@ -13,6 +13,7 @@ import { CustomerType } from 'generated/prisma/enums'
import { CreateSalesInvoiceItemDto } from '../sales-invoice-items/dto/create-sales-invoice-item.dto' import { CreateSalesInvoiceItemDto } from '../sales-invoice-items/dto/create-sales-invoice-item.dto'
export class CreateSalesInvoiceDto { export class CreateSalesInvoiceDto {
// @TODO: totalAmount must calculated instead of get from api
@IsNumber() @IsNumber()
@ApiProperty({ required: true, default: 0 }) @ApiProperty({ required: true, default: 0 })
total_amount: number total_amount: number
@@ -1,21 +1,33 @@
import { ApiProperty, PartialType } from '@nestjs/swagger' import { ApiProperty, PartialType } from '@nestjs/swagger'
import { IsEnum, IsNumber, IsObject, IsOptional, IsString } from 'class-validator' import { IsEnum, IsNumber, IsObject, IsOptional, IsString } from 'class-validator'
import type { SaleInvoiceStandardPayload } from 'common/interfaces/sale-invoice-payload' import type { SaleInvoiceType } from 'common/interfaces/sale-invoice-payload'
import { UnitType } from 'generated/prisma/enums' import { UnitType } from 'generated/prisma/enums'
export class CreateSalesInvoiceItemDto { export class CreateSalesInvoiceItemDto {
@IsNumber() @IsNumber()
@ApiProperty() @ApiProperty({ required: true })
unit_price: number unit_price: number
@IsNumber() @IsNumber()
@ApiProperty() @ApiProperty({ required: true, default: 1 })
quantity: number
@IsNumber()
@ApiProperty({ required: true })
total_amount: number total_amount: number
@IsNumber()
@ApiProperty({ required: true })
discount_amount: number
@IsString() @IsString()
@ApiProperty() @ApiProperty({ required: true })
invoice_id: string invoice_id: string
@IsEnum(UnitType)
@ApiProperty({ enum: Object.values(UnitType) })
unit_type: UnitType
@IsOptional() @IsOptional()
@IsString() @IsString()
@ApiProperty({ required: false }) @ApiProperty({ required: false })
@@ -26,14 +38,6 @@ export class CreateSalesInvoiceItemDto {
@ApiProperty({ required: false }) @ApiProperty({ required: false })
service_id?: string service_id?: string
@IsNumber()
@ApiProperty({ required: true, default: 1 })
quantity: number
@IsEnum(UnitType)
@ApiProperty({ enum: Object.values(UnitType) })
unit_type: UnitType
// @IsEnum(SalesInvoiceItemPricingModel) // @IsEnum(SalesInvoiceItemPricingModel)
// @ApiProperty({ enum: Object.values(SalesInvoiceItemPricingModel) }) // @ApiProperty({ enum: Object.values(SalesInvoiceItemPricingModel) })
// @IsOptional() // @IsOptional()
@@ -42,7 +46,7 @@ export class CreateSalesInvoiceItemDto {
@IsOptional() @IsOptional()
@IsObject() @IsObject()
@ApiProperty({ required: false, default: {} }) @ApiProperty({ required: false, default: {} })
payload?: SaleInvoiceStandardPayload payload: SaleInvoiceType
@IsOptional() @IsOptional()
@IsString() @IsString()
@@ -1,6 +1,7 @@
import { Body, Controller, Get, Param, Post } from '@nestjs/common' import { Body, Controller, Get, Param, Post } from '@nestjs/common'
import { reqTokenPayload } from '@/modules/auth/current-user.decorator' import { PosInfo } from '@/common/decorators/posInfo.decorator'
import type { IPosPayload } from '@/common/models/posPayload.model'
import { CreateSalesInvoiceDto } from './dto/create-sales-invoice.dto' import { CreateSalesInvoiceDto } from './dto/create-sales-invoice.dto'
import { SalesInvoicesService } from './sales-invoices.service' import { SalesInvoicesService } from './sales-invoices.service'
@@ -19,7 +20,7 @@ export class SalesInvoicesController {
} }
@Post() @Post()
create(@Body() data: CreateSalesInvoiceDto, @reqTokenPayload() account) { create(@Body() data: CreateSalesInvoiceDto, @PosInfo() posInfo: IPosPayload) {
return this.salesInvoicesService.create(data, account) return this.salesInvoicesService.create(data, posInfo)
} }
} }
@@ -1,3 +1,4 @@
import { IPosPayload } from '@/common/models/posPayload.model'
import { PrismaService } from '@/prisma/prisma.service' import { PrismaService } from '@/prisma/prisma.service'
import { Injectable } from '@nestjs/common' import { Injectable } from '@nestjs/common'
import { ResponseMapper } from 'common/response/response-mapper' import { ResponseMapper } from 'common/response/response-mapper'
@@ -7,12 +8,6 @@ import { CreateSalesInvoiceDto } from './dto/create-sales-invoice.dto'
// Define type guard for CustomerIndividual // Define type guard for CustomerIndividual
function isCustomerIndividual(customer: any): customer is CustomerIndividual { function isCustomerIndividual(customer: any): customer is CustomerIndividual {
console.log(
customer &&
typeof customer.first_name === 'string' &&
typeof customer.last_name === 'string',
)
return ( return (
customer && customer &&
typeof customer.first_name === 'string' && typeof customer.first_name === 'string' &&
@@ -43,9 +38,11 @@ export class SalesInvoicesService {
return {} return {}
} }
async create(data: CreateSalesInvoiceDto, account) { async create(data: CreateSalesInvoiceDto, posInfo: IPosPayload) {
data.invoice_date = new Date(data.invoice_date).toISOString() as any data.invoice_date = new Date(data.invoice_date).toISOString() as any
const { complex_id, pos_id, consumer_account_id } = posInfo
const salesInvoice = await this.prisma.$transaction(async $tx => { const salesInvoice = await this.prisma.$transaction(async $tx => {
const payments = Object.entries(data.payments) const payments = Object.entries(data.payments)
.filter(([_, value]) => value > 0 && PaymentMethodType[_.toUpperCase()]) .filter(([_, value]) => value > 0 && PaymentMethodType[_.toUpperCase()])
@@ -58,6 +55,7 @@ export class SalesInvoicesService {
}) })
const totalPayments = payments.reduce((sum, payment) => sum + payment.amount, 0) const totalPayments = payments.reduce((sum, payment) => sum + payment.amount, 0)
if (totalPayments !== data.total_amount) { if (totalPayments !== data.total_amount) {
throw new Error('مبلغ پرداختی باید برابر با مبلغ کل فاکتور باشد.') throw new Error('مبلغ پرداختی باید برابر با مبلغ کل فاکتور باشد.')
} }
@@ -72,7 +70,7 @@ export class SalesInvoicesService {
let customerIndividual = await $tx.customerIndividual.findUnique({ let customerIndividual = await $tx.customerIndividual.findUnique({
where: { where: {
complex_id_national_id: { complex_id_national_id: {
complex_id: account.complex_id, complex_id,
national_id: customer.national_id, national_id: customer.national_id,
}, },
}, },
@@ -82,7 +80,7 @@ export class SalesInvoicesService {
await $tx.customerIndividual.update({ await $tx.customerIndividual.update({
where: { where: {
complex_id_national_id: { complex_id_national_id: {
complex_id: account.complex_id, complex_id,
national_id: customer.national_id, national_id: customer.national_id,
}, },
}, },
@@ -99,8 +97,7 @@ export class SalesInvoicesService {
const createdCustomer = await $tx.customer.create({ const createdCustomer = await $tx.customer.create({
data: { data: {
type: CustomerType.INDIVIDUAL, type: CustomerType.INDIVIDUAL,
complex_id: account.complex_id, customer_individuals: {
customerIndividuals: {
connect: { connect: {
customer_id: customerIndividual.customer_id, customer_id: customerIndividual.customer_id,
}, },
@@ -116,7 +113,7 @@ export class SalesInvoicesService {
let customerLegal = await $tx.customerLegal.findUnique({ let customerLegal = await $tx.customerLegal.findUnique({
where: { where: {
complex_id_registration_number: { complex_id_registration_number: {
complex_id: account.complex_id, complex_id,
registration_number: customer.registration_number, registration_number: customer.registration_number,
}, },
}, },
@@ -126,7 +123,7 @@ export class SalesInvoicesService {
await $tx.customerLegal.update({ await $tx.customerLegal.update({
where: { where: {
complex_id_registration_number: { complex_id_registration_number: {
complex_id: account.complex_id, complex_id,
registration_number: customer.registration_number, registration_number: customer.registration_number,
}, },
}, },
@@ -143,8 +140,8 @@ export class SalesInvoicesService {
const createdCustomer = await $tx.customer.create({ const createdCustomer = await $tx.customer.create({
data: { data: {
type: CustomerType.LEGAL, type: CustomerType.LEGAL,
complex_id: account.complex_id,
customerIndividuals: { customer_individuals: {
connect: { connect: {
customer_id: customerLegal.customer_id, customer_id: customerLegal.customer_id,
}, },
@@ -156,16 +153,15 @@ export class SalesInvoicesService {
newCustomerId = createdCustomer.id newCustomerId = createdCustomer.id
} }
} }
} else if (data.customer_type === CustomerType.UNKNOWN) {
} }
const salesInvoice = await $tx.salesInvoice.create({ const salesInvoice = await $tx.salesInvoice.create({
data: { data: {
...invoiceData, ...invoiceData,
account_id: account.account_id,
customer_id: newCustomerId,
total_amount: data.total_amount, total_amount: data.total_amount,
code: 'INV-' + Date.now(), code: 'INV-' + Date.now(),
complex_id: account.complex_id,
items: { items: {
createMany: { createMany: {
data: data.items.map(item => ({ data: data.items.map(item => ({
@@ -173,17 +169,33 @@ export class SalesInvoicesService {
quantity: item.quantity, quantity: item.quantity,
unit_price: item.unit_price, unit_price: item.unit_price,
total_amount: item.total_amount, total_amount: item.total_amount,
payload: item.payload, payload: JSON.parse(JSON.stringify(item.payload)),
unit_type: item.unit_type, unit_type: item.unit_type,
// pricing_model: item.pricingModel, // pricing_model: item.pricingModel,
})), })),
}, },
}, },
unknown_customer: {},
payments: { payments: {
createMany: { createMany: {
data: payments, data: payments,
}, },
}, },
// customer: {
// connect: {
// id: newCustomerId,
// },
// },
account: {
connect: {
id: consumer_account_id,
},
},
pos: {
connect: {
id: pos_id,
},
},
}, },
}) })
@@ -1,5 +0,0 @@
import { PartialType } from '@nestjs/swagger'
export class CreateProfileDto {}
export class UpdateProfileDto extends PartialType(CreateProfileDto) {}
-13
View File
@@ -1,13 +0,0 @@
import { Controller, Get } from '@nestjs/common'
import { reqTokenPayload } from '../auth/current-user.decorator'
import { ProfileService } from './profile.service'
@Controller('profile')
export class ProfileController {
constructor(private readonly profileService: ProfileService) {}
@Get('me')
findOne(@reqTokenPayload() account) {
return this.profileService.findOne(account)
}
}
-9
View File
@@ -1,9 +0,0 @@
import { Module } from '@nestjs/common'
import { ProfileController } from './profile.controller'
import { ProfileService } from './profile.service'
@Module({
controllers: [ProfileController],
providers: [ProfileService],
})
export class ProfileModule {}
-15
View File
@@ -1,15 +0,0 @@
import { PrismaService } from '@/prisma/prisma.service'
import { Injectable } from '@nestjs/common'
import { Public } from 'common/decorators/public.decorator'
import type { AccessTokenPayload } from 'common/models/token-model'
import { ResponseMapper } from 'common/response/response-mapper'
@Injectable()
export class ProfileService {
constructor(private prisma: PrismaService) {}
@Public()
async findOne(account: AccessTokenPayload) {
return ResponseMapper.single(account)
}
}