@bisondesk/core-sdk 1.0.235 → 1.0.236

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (401) hide show
  1. package/lib/{types/apis → apis}/crm.d.ts +1 -1
  2. package/lib/apis/crm.d.ts.map +1 -0
  3. package/lib/{cjs/apis → apis}/crm.js +2 -2
  4. package/lib/apis/crm.js.map +1 -0
  5. package/lib/apis/documents.d.ts.map +1 -0
  6. package/lib/{cjs/apis → apis}/documents.js +2 -2
  7. package/lib/apis/documents.js.map +1 -0
  8. package/lib/apis/internet-vehicles.d.ts.map +1 -0
  9. package/lib/{cjs/apis → apis}/internet-vehicles.js +1 -1
  10. package/lib/apis/internet-vehicles.js.map +1 -0
  11. package/lib/apis/leasing-administration.d.ts.map +1 -0
  12. package/lib/{cjs/apis → apis}/leasing-administration.js +2 -2
  13. package/lib/apis/leasing-administration.js.map +1 -0
  14. package/lib/apis/leasing.d.ts.map +1 -0
  15. package/lib/{cjs/apis → apis}/leasing.js +2 -2
  16. package/lib/apis/leasing.js.map +1 -0
  17. package/lib/apis/opportunities.d.ts.map +1 -0
  18. package/lib/{cjs/apis → apis}/opportunities.js +2 -2
  19. package/lib/apis/opportunities.js.map +1 -0
  20. package/lib/{types/apis → apis}/picklists.d.ts +1 -1
  21. package/lib/apis/picklists.d.ts.map +1 -0
  22. package/lib/{cjs/apis → apis}/picklists.js +1 -1
  23. package/lib/apis/picklists.js.map +1 -0
  24. package/lib/apis/tenants.d.ts.map +1 -0
  25. package/lib/{cjs/apis → apis}/tenants.js +1 -1
  26. package/lib/apis/tenants.js.map +1 -0
  27. package/lib/apis/users.d.ts.map +1 -0
  28. package/lib/{cjs/apis → apis}/users.js +2 -2
  29. package/lib/apis/users.js.map +1 -0
  30. package/lib/apis/utils.d.ts.map +1 -0
  31. package/lib/{cjs/apis → apis}/utils.js +2 -2
  32. package/lib/apis/utils.js.map +1 -0
  33. package/lib/apis/vehicles.d.ts.map +1 -0
  34. package/lib/{cjs/apis → apis}/vehicles.js +2 -2
  35. package/lib/apis/vehicles.js.map +1 -0
  36. package/lib/{types/constants.d.ts → constants.d.ts} +1 -1
  37. package/lib/constants.d.ts.map +1 -0
  38. package/lib/{cjs/constants.js → constants.js} +33 -1
  39. package/lib/constants.js.map +1 -0
  40. package/lib/ddb-entities.d.ts.map +1 -0
  41. package/lib/ddb-entities.js.map +1 -0
  42. package/lib/types/activities.d.ts.map +1 -0
  43. package/lib/types/activities.js.map +1 -0
  44. package/lib/types/{types/crm.d.ts → crm.d.ts} +3 -1
  45. package/lib/types/crm.d.ts.map +1 -0
  46. package/lib/types/crm.js.map +1 -0
  47. package/lib/types/definitions.d.ts.map +1 -0
  48. package/lib/{cjs/types → types}/definitions.js.map +1 -1
  49. package/lib/types/{types/documents.d.ts → documents.d.ts} +1 -1
  50. package/lib/types/documents.d.ts.map +1 -0
  51. package/lib/{cjs/types → types}/documents.js.map +1 -1
  52. package/lib/types/events.d.ts.map +1 -0
  53. package/lib/{cjs/types → types}/events.js +1 -0
  54. package/lib/types/events.js.map +1 -0
  55. package/lib/types/fields.d.ts.map +1 -0
  56. package/lib/{cjs/types → types}/fields.js +3 -0
  57. package/lib/types/fields.js.map +1 -0
  58. package/lib/types/{types/internet-vehicles.d.ts → internet-vehicles.d.ts} +1 -1
  59. package/lib/types/internet-vehicles.d.ts.map +1 -0
  60. package/lib/types/internet-vehicles.js.map +1 -0
  61. package/lib/types/{types/leads.d.ts → leads.d.ts} +1 -1
  62. package/lib/types/leads.d.ts.map +1 -0
  63. package/lib/{cjs/types → types}/leads.js.map +1 -1
  64. package/lib/types/{types/leasing-administration.d.ts → leasing-administration.d.ts} +1 -1
  65. package/lib/types/leasing-administration.d.ts.map +1 -0
  66. package/lib/types/leasing-administration.js.map +1 -0
  67. package/lib/types/{types/leasing-search.d.ts → leasing-search.d.ts} +2 -2
  68. package/lib/types/leasing-search.d.ts.map +1 -0
  69. package/lib/types/leasing-search.js.map +1 -0
  70. package/lib/types/{types/leasing-settings.d.ts → leasing-settings.d.ts} +4 -2
  71. package/lib/types/leasing-settings.d.ts.map +1 -0
  72. package/lib/types/leasing-settings.js.map +1 -0
  73. package/lib/types/{types/leasing.d.ts → leasing.d.ts} +23 -11
  74. package/lib/types/leasing.d.ts.map +1 -0
  75. package/lib/types/leasing.js.map +1 -0
  76. package/lib/types/machines.d.ts.map +1 -0
  77. package/lib/{cjs/types → types}/machines.js.map +1 -1
  78. package/lib/types/{types/opportunities.d.ts → opportunities.d.ts} +1 -1
  79. package/lib/types/opportunities.d.ts.map +1 -0
  80. package/lib/types/opportunities.js.map +1 -0
  81. package/lib/types/payments.d.ts.map +1 -0
  82. package/lib/types/payments.js.map +1 -0
  83. package/lib/types/{types/picklists.d.ts → picklists.d.ts} +1 -1
  84. package/lib/types/picklists.d.ts.map +1 -0
  85. package/lib/{cjs/types → types}/picklists.js.map +1 -1
  86. package/lib/types/{types/quotes.d.ts → quotes.d.ts} +1 -1
  87. package/lib/types/quotes.d.ts.map +1 -0
  88. package/lib/types/quotes.js.map +1 -0
  89. package/lib/types/{types/recently-viewed.d.ts → recently-viewed.d.ts} +1 -1
  90. package/lib/types/recently-viewed.d.ts.map +1 -0
  91. package/lib/types/recently-viewed.js.map +1 -0
  92. package/lib/types/saved-filters.d.ts.map +1 -0
  93. package/lib/types/saved-filters.js.map +1 -0
  94. package/lib/types/{types/search.d.ts → search.d.ts} +1 -1
  95. package/lib/types/search.d.ts.map +1 -0
  96. package/lib/{cjs/types → types}/search.js +9 -0
  97. package/lib/types/search.js.map +1 -0
  98. package/lib/types/settings.d.ts.map +1 -0
  99. package/lib/{cjs/types → types}/settings.js.map +1 -1
  100. package/lib/types/storage.d.ts +2 -0
  101. package/lib/types/storage.d.ts.map +1 -0
  102. package/lib/{cjs/types → types}/storage.js +1 -1
  103. package/lib/types/storage.js.map +1 -0
  104. package/lib/types/templates.d.ts.map +1 -0
  105. package/lib/types/templates.js.map +1 -0
  106. package/lib/types/{types/tenants.d.ts → tenants.d.ts} +1 -1
  107. package/lib/types/tenants.d.ts.map +1 -0
  108. package/lib/types/tenants.js.map +1 -0
  109. package/lib/types/{types/users.d.ts → users.d.ts} +2 -2
  110. package/lib/types/users.d.ts.map +1 -0
  111. package/lib/{cjs/types → types}/users.js.map +1 -1
  112. package/lib/types/{types/utils.d.ts → utils.d.ts} +1 -1
  113. package/lib/types/utils.d.ts.map +1 -0
  114. package/lib/types/utils.js.map +1 -0
  115. package/lib/types/{types/vehicles.d.ts → vehicles.d.ts} +5 -1
  116. package/lib/types/vehicles.d.ts.map +1 -0
  117. package/lib/types/vehicles.js.map +1 -0
  118. package/lib/types/{types/website.d.ts → website.d.ts} +1 -1
  119. package/lib/types/website.d.ts.map +1 -0
  120. package/lib/{cjs/types → types}/website.js.map +1 -1
  121. package/lib/utils/forms.d.ts.map +1 -0
  122. package/lib/utils/forms.js.map +1 -0
  123. package/lib/utils/leasing.d.ts.map +1 -0
  124. package/lib/{cjs/utils → utils}/leasing.js +4 -2
  125. package/lib/utils/leasing.js.map +1 -0
  126. package/lib/utils/slug.d.ts.map +1 -0
  127. package/lib/utils/slug.js.map +1 -0
  128. package/lib/utils/tenants.d.ts.map +1 -0
  129. package/lib/{cjs/utils → utils}/tenants.js +1 -1
  130. package/lib/utils/tenants.js.map +1 -0
  131. package/lib/utils/vehicles.d.ts.map +1 -0
  132. package/lib/{cjs/utils → utils}/vehicles.js +1 -0
  133. package/lib/utils/vehicles.js.map +1 -0
  134. package/package.json +4 -20
  135. package/src/apis/crm.ts +6 -3
  136. package/src/apis/documents.ts +2 -2
  137. package/src/apis/internet-vehicles.ts +1 -1
  138. package/src/apis/leasing-administration.ts +5 -2
  139. package/src/apis/leasing.ts +5 -2
  140. package/src/apis/opportunities.ts +2 -2
  141. package/src/apis/picklists.ts +2 -2
  142. package/src/apis/tenants.ts +1 -1
  143. package/src/apis/users.ts +2 -2
  144. package/src/apis/utils.ts +2 -2
  145. package/src/apis/vehicles.ts +5 -2
  146. package/src/constants.ts +1 -1
  147. package/src/types/crm.ts +1 -1
  148. package/src/types/documents.ts +1 -1
  149. package/src/types/internet-vehicles.ts +1 -1
  150. package/src/types/leads.ts +1 -1
  151. package/src/types/leasing-administration.ts +1 -1
  152. package/src/types/leasing-search.ts +2 -2
  153. package/src/types/leasing-settings.ts +4 -2
  154. package/src/types/leasing.ts +21 -11
  155. package/src/types/opportunities.ts +1 -1
  156. package/src/types/picklists.ts +1 -1
  157. package/src/types/quotes.ts +1 -1
  158. package/src/types/recently-viewed.ts +1 -1
  159. package/src/types/search.ts +1 -1
  160. package/src/types/storage.ts +1 -1
  161. package/src/types/tenants.ts +1 -1
  162. package/src/types/users.ts +2 -2
  163. package/src/types/utils.ts +1 -1
  164. package/src/types/vehicles.ts +1 -1
  165. package/src/types/website.ts +1 -1
  166. package/src/utils/leasing.ts +1 -1
  167. package/src/utils/tenants.ts +1 -1
  168. package/tsconfig.json +5 -4
  169. package/tsconfig.tsbuildinfo +1 -0
  170. package/lib/cjs/apis/crm.js.map +0 -1
  171. package/lib/cjs/apis/documents.js.map +0 -1
  172. package/lib/cjs/apis/internet-vehicles.js.map +0 -1
  173. package/lib/cjs/apis/leasing-administration.js.map +0 -1
  174. package/lib/cjs/apis/leasing.js.map +0 -1
  175. package/lib/cjs/apis/opportunities.js.map +0 -1
  176. package/lib/cjs/apis/picklists.js.map +0 -1
  177. package/lib/cjs/apis/tenants.js.map +0 -1
  178. package/lib/cjs/apis/users.js.map +0 -1
  179. package/lib/cjs/apis/utils.js.map +0 -1
  180. package/lib/cjs/apis/vehicles.js.map +0 -1
  181. package/lib/cjs/constants.js.map +0 -1
  182. package/lib/cjs/ddb-entities.js.map +0 -1
  183. package/lib/cjs/types/activities.js.map +0 -1
  184. package/lib/cjs/types/crm.js.map +0 -1
  185. package/lib/cjs/types/events.js.map +0 -1
  186. package/lib/cjs/types/fields.js.map +0 -1
  187. package/lib/cjs/types/internet-vehicles.js.map +0 -1
  188. package/lib/cjs/types/leasing-administration.js.map +0 -1
  189. package/lib/cjs/types/leasing-search.js.map +0 -1
  190. package/lib/cjs/types/leasing-settings.js.map +0 -1
  191. package/lib/cjs/types/leasing.js.map +0 -1
  192. package/lib/cjs/types/opportunities.js.map +0 -1
  193. package/lib/cjs/types/payments.js.map +0 -1
  194. package/lib/cjs/types/quotes.js.map +0 -1
  195. package/lib/cjs/types/recently-viewed.js.map +0 -1
  196. package/lib/cjs/types/saved-filters.js.map +0 -1
  197. package/lib/cjs/types/search.js.map +0 -1
  198. package/lib/cjs/types/storage.js.map +0 -1
  199. package/lib/cjs/types/templates.js.map +0 -1
  200. package/lib/cjs/types/tenants.js.map +0 -1
  201. package/lib/cjs/types/utils.js.map +0 -1
  202. package/lib/cjs/types/vehicles.js.map +0 -1
  203. package/lib/cjs/utils/forms.js.map +0 -1
  204. package/lib/cjs/utils/leasing.js.map +0 -1
  205. package/lib/cjs/utils/slug.js.map +0 -1
  206. package/lib/cjs/utils/tenants.js.map +0 -1
  207. package/lib/cjs/utils/vehicles.js.map +0 -1
  208. package/lib/esm/apis/crm.js +0 -184
  209. package/lib/esm/apis/crm.js.map +0 -1
  210. package/lib/esm/apis/documents.js +0 -39
  211. package/lib/esm/apis/documents.js.map +0 -1
  212. package/lib/esm/apis/internet-vehicles.js +0 -20
  213. package/lib/esm/apis/internet-vehicles.js.map +0 -1
  214. package/lib/esm/apis/leasing-administration.js +0 -41
  215. package/lib/esm/apis/leasing-administration.js.map +0 -1
  216. package/lib/esm/apis/leasing.js +0 -152
  217. package/lib/esm/apis/leasing.js.map +0 -1
  218. package/lib/esm/apis/opportunities.js +0 -83
  219. package/lib/esm/apis/opportunities.js.map +0 -1
  220. package/lib/esm/apis/picklists.js +0 -36
  221. package/lib/esm/apis/picklists.js.map +0 -1
  222. package/lib/esm/apis/tenants.js +0 -69
  223. package/lib/esm/apis/tenants.js.map +0 -1
  224. package/lib/esm/apis/users.js +0 -19
  225. package/lib/esm/apis/users.js.map +0 -1
  226. package/lib/esm/apis/utils.js +0 -17
  227. package/lib/esm/apis/utils.js.map +0 -1
  228. package/lib/esm/apis/vehicles.js +0 -144
  229. package/lib/esm/apis/vehicles.js.map +0 -1
  230. package/lib/esm/constants.js +0 -918
  231. package/lib/esm/constants.js.map +0 -1
  232. package/lib/esm/ddb-entities.js +0 -2
  233. package/lib/esm/ddb-entities.js.map +0 -1
  234. package/lib/esm/types/activities.js +0 -13
  235. package/lib/esm/types/activities.js.map +0 -1
  236. package/lib/esm/types/crm.js +0 -16
  237. package/lib/esm/types/crm.js.map +0 -1
  238. package/lib/esm/types/definitions.js +0 -2
  239. package/lib/esm/types/definitions.js.map +0 -1
  240. package/lib/esm/types/documents.js +0 -2
  241. package/lib/esm/types/documents.js.map +0 -1
  242. package/lib/esm/types/events.js +0 -7
  243. package/lib/esm/types/events.js.map +0 -1
  244. package/lib/esm/types/fields.js +0 -26
  245. package/lib/esm/types/fields.js.map +0 -1
  246. package/lib/esm/types/internet-vehicles.js +0 -2
  247. package/lib/esm/types/internet-vehicles.js.map +0 -1
  248. package/lib/esm/types/leads.js +0 -2
  249. package/lib/esm/types/leads.js.map +0 -1
  250. package/lib/esm/types/leasing-administration.js +0 -2
  251. package/lib/esm/types/leasing-administration.js.map +0 -1
  252. package/lib/esm/types/leasing-search.js +0 -2
  253. package/lib/esm/types/leasing-search.js.map +0 -1
  254. package/lib/esm/types/leasing-settings.js +0 -7
  255. package/lib/esm/types/leasing-settings.js.map +0 -1
  256. package/lib/esm/types/leasing.js +0 -21
  257. package/lib/esm/types/leasing.js.map +0 -1
  258. package/lib/esm/types/machines.js +0 -2
  259. package/lib/esm/types/machines.js.map +0 -1
  260. package/lib/esm/types/opportunities.js +0 -65
  261. package/lib/esm/types/opportunities.js.map +0 -1
  262. package/lib/esm/types/payments.js +0 -6
  263. package/lib/esm/types/payments.js.map +0 -1
  264. package/lib/esm/types/picklists.js +0 -2
  265. package/lib/esm/types/picklists.js.map +0 -1
  266. package/lib/esm/types/quotes.js +0 -23
  267. package/lib/esm/types/quotes.js.map +0 -1
  268. package/lib/esm/types/recently-viewed.js +0 -2
  269. package/lib/esm/types/recently-viewed.js.map +0 -1
  270. package/lib/esm/types/saved-filters.js +0 -2
  271. package/lib/esm/types/saved-filters.js.map +0 -1
  272. package/lib/esm/types/search.js +0 -33
  273. package/lib/esm/types/search.js.map +0 -1
  274. package/lib/esm/types/settings.js +0 -2
  275. package/lib/esm/types/settings.js.map +0 -1
  276. package/lib/esm/types/storage.js +0 -2
  277. package/lib/esm/types/storage.js.map +0 -1
  278. package/lib/esm/types/templates.js +0 -6
  279. package/lib/esm/types/templates.js.map +0 -1
  280. package/lib/esm/types/tenants.js +0 -11
  281. package/lib/esm/types/tenants.js.map +0 -1
  282. package/lib/esm/types/users.js +0 -2
  283. package/lib/esm/types/users.js.map +0 -1
  284. package/lib/esm/types/utils.js +0 -6
  285. package/lib/esm/types/utils.js.map +0 -1
  286. package/lib/esm/types/vehicles.js +0 -54
  287. package/lib/esm/types/vehicles.js.map +0 -1
  288. package/lib/esm/types/website.js +0 -2
  289. package/lib/esm/types/website.js.map +0 -1
  290. package/lib/esm/utils/forms.js +0 -26
  291. package/lib/esm/utils/forms.js.map +0 -1
  292. package/lib/esm/utils/leasing.js +0 -4
  293. package/lib/esm/utils/leasing.js.map +0 -1
  294. package/lib/esm/utils/slug.js +0 -16
  295. package/lib/esm/utils/slug.js.map +0 -1
  296. package/lib/esm/utils/tenants.js +0 -11
  297. package/lib/esm/utils/tenants.js.map +0 -1
  298. package/lib/esm/utils/vehicles.js +0 -65
  299. package/lib/esm/utils/vehicles.js.map +0 -1
  300. package/lib/tsconfig.cjs.tsbuildinfo +0 -1
  301. package/lib/tsconfig.esm.tsbuildinfo +0 -1
  302. package/lib/types/apis/crm.d.ts.map +0 -1
  303. package/lib/types/apis/documents.d.ts.map +0 -1
  304. package/lib/types/apis/internet-vehicles.d.ts.map +0 -1
  305. package/lib/types/apis/leasing-administration.d.ts.map +0 -1
  306. package/lib/types/apis/leasing.d.ts.map +0 -1
  307. package/lib/types/apis/opportunities.d.ts.map +0 -1
  308. package/lib/types/apis/picklists.d.ts.map +0 -1
  309. package/lib/types/apis/tenants.d.ts.map +0 -1
  310. package/lib/types/apis/users.d.ts.map +0 -1
  311. package/lib/types/apis/utils.d.ts.map +0 -1
  312. package/lib/types/apis/vehicles.d.ts.map +0 -1
  313. package/lib/types/constants.d.ts.map +0 -1
  314. package/lib/types/ddb-entities.d.ts.map +0 -1
  315. package/lib/types/types/activities.d.ts.map +0 -1
  316. package/lib/types/types/crm.d.ts.map +0 -1
  317. package/lib/types/types/definitions.d.ts.map +0 -1
  318. package/lib/types/types/documents.d.ts.map +0 -1
  319. package/lib/types/types/events.d.ts.map +0 -1
  320. package/lib/types/types/fields.d.ts.map +0 -1
  321. package/lib/types/types/internet-vehicles.d.ts.map +0 -1
  322. package/lib/types/types/leads.d.ts.map +0 -1
  323. package/lib/types/types/leasing-administration.d.ts.map +0 -1
  324. package/lib/types/types/leasing-search.d.ts.map +0 -1
  325. package/lib/types/types/leasing-settings.d.ts.map +0 -1
  326. package/lib/types/types/leasing.d.ts.map +0 -1
  327. package/lib/types/types/machines.d.ts.map +0 -1
  328. package/lib/types/types/opportunities.d.ts.map +0 -1
  329. package/lib/types/types/payments.d.ts.map +0 -1
  330. package/lib/types/types/picklists.d.ts.map +0 -1
  331. package/lib/types/types/quotes.d.ts.map +0 -1
  332. package/lib/types/types/recently-viewed.d.ts.map +0 -1
  333. package/lib/types/types/saved-filters.d.ts.map +0 -1
  334. package/lib/types/types/search.d.ts.map +0 -1
  335. package/lib/types/types/settings.d.ts.map +0 -1
  336. package/lib/types/types/storage.d.ts +0 -2
  337. package/lib/types/types/storage.d.ts.map +0 -1
  338. package/lib/types/types/templates.d.ts.map +0 -1
  339. package/lib/types/types/tenants.d.ts.map +0 -1
  340. package/lib/types/types/users.d.ts.map +0 -1
  341. package/lib/types/types/utils.d.ts.map +0 -1
  342. package/lib/types/types/vehicles.d.ts.map +0 -1
  343. package/lib/types/types/website.d.ts.map +0 -1
  344. package/lib/types/utils/forms.d.ts.map +0 -1
  345. package/lib/types/utils/leasing.d.ts.map +0 -1
  346. package/lib/types/utils/slug.d.ts.map +0 -1
  347. package/lib/types/utils/tenants.d.ts.map +0 -1
  348. package/lib/types/utils/vehicles.d.ts.map +0 -1
  349. package/tsconfig.cjs.json +0 -8
  350. package/tsconfig.esm.json +0 -8
  351. /package/lib/{types/apis → apis}/documents.d.ts +0 -0
  352. /package/lib/{types/apis → apis}/internet-vehicles.d.ts +0 -0
  353. /package/lib/{types/apis → apis}/leasing-administration.d.ts +0 -0
  354. /package/lib/{types/apis → apis}/leasing.d.ts +0 -0
  355. /package/lib/{types/apis → apis}/opportunities.d.ts +0 -0
  356. /package/lib/{types/apis → apis}/tenants.d.ts +0 -0
  357. /package/lib/{types/apis → apis}/users.d.ts +0 -0
  358. /package/lib/{types/apis → apis}/utils.d.ts +0 -0
  359. /package/lib/{types/apis → apis}/vehicles.d.ts +0 -0
  360. /package/lib/{types/ddb-entities.d.ts → ddb-entities.d.ts} +0 -0
  361. /package/lib/{cjs/ddb-entities.js → ddb-entities.js} +0 -0
  362. /package/lib/types/{types/activities.d.ts → activities.d.ts} +0 -0
  363. /package/lib/{cjs/types → types}/activities.js +0 -0
  364. /package/lib/{cjs/types → types}/crm.js +0 -0
  365. /package/lib/types/{types/definitions.d.ts → definitions.d.ts} +0 -0
  366. /package/lib/{cjs/types → types}/definitions.js +0 -0
  367. /package/lib/{cjs/types → types}/documents.js +0 -0
  368. /package/lib/types/{types/events.d.ts → events.d.ts} +0 -0
  369. /package/lib/types/{types/fields.d.ts → fields.d.ts} +0 -0
  370. /package/lib/{cjs/types → types}/internet-vehicles.js +0 -0
  371. /package/lib/{cjs/types → types}/leads.js +0 -0
  372. /package/lib/{cjs/types → types}/leasing-administration.js +0 -0
  373. /package/lib/{cjs/types → types}/leasing-search.js +0 -0
  374. /package/lib/{cjs/types → types}/leasing-settings.js +0 -0
  375. /package/lib/{cjs/types → types}/leasing.js +0 -0
  376. /package/lib/types/{types/machines.d.ts → machines.d.ts} +0 -0
  377. /package/lib/{cjs/types → types}/machines.js +0 -0
  378. /package/lib/{cjs/types → types}/opportunities.js +0 -0
  379. /package/lib/types/{types/payments.d.ts → payments.d.ts} +0 -0
  380. /package/lib/{cjs/types → types}/payments.js +0 -0
  381. /package/lib/{cjs/types → types}/picklists.js +0 -0
  382. /package/lib/{cjs/types → types}/quotes.js +0 -0
  383. /package/lib/{cjs/types → types}/recently-viewed.js +0 -0
  384. /package/lib/types/{types/saved-filters.d.ts → saved-filters.d.ts} +0 -0
  385. /package/lib/{cjs/types → types}/saved-filters.js +0 -0
  386. /package/lib/types/{types/settings.d.ts → settings.d.ts} +0 -0
  387. /package/lib/{cjs/types → types}/settings.js +0 -0
  388. /package/lib/types/{types/templates.d.ts → templates.d.ts} +0 -0
  389. /package/lib/{cjs/types → types}/templates.js +0 -0
  390. /package/lib/{cjs/types → types}/tenants.js +0 -0
  391. /package/lib/{cjs/types → types}/users.js +0 -0
  392. /package/lib/{cjs/types → types}/utils.js +0 -0
  393. /package/lib/{cjs/types → types}/vehicles.js +0 -0
  394. /package/lib/{cjs/types → types}/website.js +0 -0
  395. /package/lib/{types/utils → utils}/forms.d.ts +0 -0
  396. /package/lib/{cjs/utils → utils}/forms.js +0 -0
  397. /package/lib/{types/utils → utils}/leasing.d.ts +0 -0
  398. /package/lib/{types/utils → utils}/slug.d.ts +0 -0
  399. /package/lib/{cjs/utils → utils}/slug.js +0 -0
  400. /package/lib/{types/utils → utils}/tenants.d.ts +0 -0
  401. /package/lib/{types/utils → utils}/vehicles.d.ts +0 -0
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.sortContractClients = void 0;
4
- const dayjs_utils_1 = require("@bisondesk/commons-sdk/dayjs-utils");
4
+ const dayjs_utils_1 = require("@bisondesk/commons-sdk/lib/dayjs-utils");
5
5
  const lodash_1 = require("lodash");
6
- const sortContractClients = (clients) => (0, lodash_1.sortBy)((0, lodash_1.map)((0, lodash_1.uniqBy)(clients, (c) => c.takeoverId), (c) => ({ ...c, since: (0, dayjs_utils_1.utc)(c.since).format('YYYY-MM-DD') })), (cli) => cli.since, (cli) => (cli.takeoverId ? parseInt(cli.takeoverId.replace(/[^0-9]/g, '')) : 0));
6
+ /* sort from oldest to most recent client */
7
+ const sortContractClients = (clients) => (0, lodash_1.sortBy)((0, lodash_1.map)((0, lodash_1.uniqBy)(clients, (c) => c.takeoverId), (c) => ({ ...c, since: (0, dayjs_utils_1.utc)(c.since).format('YYYY-MM-DD') }) // doing a map to also fix legacy data
8
+ ), (cli) => cli.since, (cli) => (cli.takeoverId ? parseInt(cli.takeoverId.replace(/[^0-9]/g, '')) : 0));
7
9
  exports.sortContractClients = sortContractClients;
8
10
  //# sourceMappingURL=leasing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"leasing.js","sourceRoot":"","sources":["../../src/utils/leasing.ts"],"names":[],"mappings":";;;AAAA,wEAA6D;AAC7D,mCAA6C;AAG7C,4CAA4C;AACrC,MAAM,mBAAmB,GAAG,CAAC,OAAgC,EAA2B,EAAE,CAC/F,IAAA,eAAM,EACJ,IAAA,YAAG,EACD,IAAA,eAAM,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EACpC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,IAAA,iBAAG,EAAC,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC,sCAAsC;CACnG,EACD,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,EAClB,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,UAAU,CAAC,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAChF,CAAC;AARS,QAAA,mBAAmB,uBAQ5B"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"slug.d.ts","sourceRoot":"","sources":["../../src/utils/slug.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,eAAO,MAAM,cAAc,YAAa,OAAO,KAAG,MAejD,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"slug.js","sourceRoot":"","sources":["../../src/utils/slug.ts"],"names":[],"mappings":";;;;;;AAAA,sDAA8B;AAGvB,MAAM,cAAc,GAAG,CAAC,OAAgB,EAAU,EAAE;IACzD,OAAO,IAAA,iBAAO,EACZ;QACE,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAC,WAAW,IAAI,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAC,WAAW;QAC1F,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI;QAC7B,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,SAAS;QAClC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,QAAQ;QACjC,GAAG,OAAO,CAAC,QAAQ,CAAC,OAAO,EAAE,eAAe,EAAE;QAC9C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,QAAQ;QACjC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,SAAS;QAClC,OAAO,CAAC,QAAQ,CAAC,UAAU,EAAE,KAAK,EAAE,aAAa;KAClD;SACE,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;SAClB,IAAI,CAAC,GAAG,CAAC,CACb,CAAC;AACJ,CAAC,CAAC;AAfW,QAAA,cAAc,kBAezB"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tenants.d.ts","sourceRoot":"","sources":["../../src/utils/tenants.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAElD,eAAO,MAAM,SAAS,WAAY,MAAM,YAAY,MAAM,KAAG,MAO5D,CAAC;AAEF,eAAO,MAAM,gBAAgB,WAAY,MAAM,KAAG,MAAiC,CAAC"}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getDefaultBranch = exports.getBranch = void 0;
4
- const errors_1 = require("@bisondesk/commons-sdk/errors");
4
+ const errors_1 = require("@bisondesk/commons-sdk/lib/errors");
5
5
  const lodash_1 = require("lodash");
6
6
  const getBranch = (tenant, branchId) => {
7
7
  const branch = tenant.branches.find((branch) => branch.id === branchId);
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tenants.js","sourceRoot":"","sources":["../../src/utils/tenants.ts"],"names":[],"mappings":";;;AAAA,8DAA2D;AAC3D,mCAA+B;AAGxB,MAAM,SAAS,GAAG,CAAC,MAAc,EAAE,QAAgB,EAAU,EAAE;IACpE,MAAM,MAAM,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,MAAc,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,KAAK,QAAQ,CAAC,CAAC;IAChF,IAAI,MAAM,IAAI,IAAI,EAAE;QAClB,MAAM,IAAI,eAAM,CAAC,0BAA0B,EAAE,EAAE,QAAQ,EAAE,MAAM,CAAC,EAAE,EAAE,QAAQ,EAAE,CAAC,CAAC;KACjF;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AAPW,QAAA,SAAS,aAOpB;AAEK,MAAM,gBAAgB,GAAG,CAAC,MAAc,EAAU,EAAE,CAAC,IAAA,cAAK,EAAC,MAAM,CAAC,QAAQ,CAAE,CAAC;AAAvE,QAAA,gBAAgB,oBAAuD"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vehicles.d.ts","sourceRoot":"","sources":["../../src/utils/vehicles.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAEpF,eAAO,MAAM,kBAAkB,YAAa,OAAO,KAAG,iBAAiB,EAYtE,CAAC;AAEF,eAAO,MAAM,qBAAqB,YAAa,mBAAmB,KAAG,MAAM,EA+B1E,CAAC;AAEF,eAAO,MAAM,gBAAgB;UAOrB,MAAM;cACF,MAAM;;;;MAId,MAcH,CAAC;AAGF,eAAO,MAAM,sBAAsB,QAAS,MAAM,KAAG,MAYpD,CAAC"}
@@ -58,6 +58,7 @@ const getInternalTitle = ({ make, category, modelName, bodywork, modelTypeName,
58
58
  .trim();
59
59
  };
60
60
  exports.getInternalTitle = getInternalTitle;
61
+ // example: 1 -> A, 2 -> B, 26 -> Z, 27 -> AA, 28 -> AB, 52 -> AZ, 53 -> BA, 54 -> BB, 702 -> ZZ, 703 -> AAA
61
62
  const convertNumberToLetters = (num) => {
62
63
  const letters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
63
64
  const lettersLength = letters.length;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vehicles.js","sourceRoot":"","sources":["../../src/utils/vehicles.ts"],"names":[],"mappings":"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"}
package/package.json CHANGED
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "@bisondesk/core-sdk",
3
- "version": "1.0.235",
3
+ "version": "1.0.236",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "clean": "rm -rf build dist lib *.tsbuildinfo",
7
7
  "unittest": "echo \"No test specified\"",
8
8
  "integrationtest": "echo \"No test specified\"",
9
- "build": "npx tsc --build tsconfig.cjs.json & npx tsc --build tsconfig.esm.json",
9
+ "build": "npx tsc --build",
10
10
  "watch": "npx tsc --build --watch"
11
11
  },
12
12
  "author": "TheTruckCompany",
13
13
  "dependencies": {
14
- "@bisondesk/commons-sdk": "1.0.235",
14
+ "@bisondesk/commons-sdk": "1.0.236",
15
15
  "joi": "17.4.0",
16
16
  "decimal.js": "10.3.1",
17
17
  "slugify": "1.6.5"
@@ -19,21 +19,5 @@
19
19
  "devDependencies": {
20
20
  "@types/node": "16.11.7",
21
21
  "typescript": "4.7.4"
22
- },
23
-
24
- "main": "./lib/cjs/*",
25
- "module": "./lib/esm/*",
26
- "exports": {
27
- "./*": {
28
- "import": ["./lib/esm/*.js", "./lib/esm/*/*.js"],
29
- "require": ["./lib/cjs/*.js", "./lib/cjs/*/*.js"]
30
- }
31
- },
32
- "typesVersions": {
33
- "*": {
34
- "*": [
35
- "lib/types/*"
36
- ]
37
- }
38
22
  }
39
- }
23
+ }
package/src/apis/crm.ts CHANGED
@@ -1,6 +1,9 @@
1
- import { SERVICE_ID_ADMIN_HEADER, TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
3
- import { PaginatedList } from '@bisondesk/commons-sdk/types';
1
+ import {
2
+ SERVICE_ID_ADMIN_HEADER,
3
+ TENANT_ID_ADMIN_HEADER,
4
+ } from '@bisondesk/commons-sdk/lib/constants';
5
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
6
+ import { PaginatedList } from '@bisondesk/commons-sdk/lib/types';
4
7
  import type { Patch } from 'immer';
5
8
  import fetch, { Response } from 'node-fetch';
6
9
  import {
@@ -1,5 +1,5 @@
1
- import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/lib/constants';
2
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
3
  import fetch, { Response } from 'node-fetch';
4
4
  import { FinanceBooking, FinanceDocument } from '../types/documents';
5
5
  import { getAdminAuth } from './utils';
@@ -1,4 +1,4 @@
1
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
2
2
  import fetch, { Response } from 'node-fetch';
3
3
  import { SearchInternetVehicle } from '../types/internet-vehicles';
4
4
  import { getAdminAuth } from './utils';
@@ -1,5 +1,8 @@
1
- import { SERVICE_ID_ADMIN_HEADER, TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import {
2
+ SERVICE_ID_ADMIN_HEADER,
3
+ TENANT_ID_ADMIN_HEADER,
4
+ } from '@bisondesk/commons-sdk/lib/constants';
5
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
6
  import fetch, { Response } from 'node-fetch';
4
7
  import {
5
8
  LeasingAdminUpload,
@@ -1,5 +1,8 @@
1
- import { SERVICE_ID_ADMIN_HEADER, TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import {
2
+ SERVICE_ID_ADMIN_HEADER,
3
+ TENANT_ID_ADMIN_HEADER,
4
+ } from '@bisondesk/commons-sdk/lib/constants';
5
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
6
  import fetch, { Response } from 'node-fetch';
4
7
  import {
5
8
  AmortizationDocs,
@@ -1,5 +1,5 @@
1
- import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/lib/constants';
2
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
3
  import fetch, { Response } from 'node-fetch';
4
4
  import { AmortizationTable, AmortizationTableRequest } from '../types/leasing';
5
5
  import { LeasingQuoteParams } from '../types/leasing-settings';
@@ -1,5 +1,5 @@
1
- import { XError } from '@bisondesk/commons-sdk/errors';
2
- import { Option } from '@bisondesk/commons-sdk/types';
1
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
2
+ import { Option } from '@bisondesk/commons-sdk/lib/types';
3
3
  import fetch, { Response } from 'node-fetch';
4
4
  import {
5
5
  AdHocPicklistRequest,
@@ -1,4 +1,4 @@
1
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
2
2
  import fetch, { Response } from 'node-fetch';
3
3
  import { Tenant, TenantSyncSettings } from '../types/tenants';
4
4
  import { getAdminAuth } from './utils';
package/src/apis/users.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/lib/constants';
2
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
3
  import fetch, { Response } from 'node-fetch';
4
4
  import { User } from '../types/users';
5
5
  import { cleanHeaders, getAdminAuth } from './utils';
package/src/apis/utils.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { InvalidArgumentsError } from '@bisondesk/commons-sdk/errors';
1
+ import { TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/lib/constants';
2
+ import { InvalidArgumentsError } from '@bisondesk/commons-sdk/lib/errors';
3
3
  import type { HeadersInit } from 'node-fetch';
4
4
 
5
5
  export const getAdminAuth = async (): Promise<string> => {
@@ -1,5 +1,8 @@
1
- import { SERVICE_ID_ADMIN_HEADER, TENANT_ID_ADMIN_HEADER } from '@bisondesk/commons-sdk/constants';
2
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import {
2
+ SERVICE_ID_ADMIN_HEADER,
3
+ TENANT_ID_ADMIN_HEADER,
4
+ } from '@bisondesk/commons-sdk/lib/constants';
5
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
3
6
  import fetch, { Response } from 'node-fetch';
4
7
  import { DataRecord } from '../types/utils';
5
8
  import { NewVehicle, Vehicle, VehicleMarketing, VehiclePurchase } from '../types/vehicles';
package/src/constants.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { VehicleAxle } from './types/vehicles';
2
2
 
3
- export { BusinessEntityIds } from '@bisondesk/commons-sdk/constants';
3
+ export { BusinessEntityIds } from '@bisondesk/commons-sdk/lib/constants';
4
4
 
5
5
  //
6
6
  // STATIC PICKLIST IDS
package/src/types/crm.ts CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  PhoneNumberRawValue,
4
4
  PhoneNumberValue,
5
5
  SearchPermissions,
6
- } from '@bisondesk/commons-sdk/types';
6
+ } from '@bisondesk/commons-sdk/lib/types';
7
7
  import { PublicSearchDefinition } from './definitions';
8
8
  import { LeasingContract } from './leasing';
9
9
  import { ReferenceData } from './utils';
@@ -1,4 +1,4 @@
1
- import { AttachmentValue, SearchPermissions } from '@bisondesk/commons-sdk/types';
1
+ import { AttachmentValue, SearchPermissions } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { Organization } from './crm';
3
3
  import { PublicSearchDefinition } from './definitions';
4
4
 
@@ -1,4 +1,4 @@
1
- import { LocationValue, PhoneNumberValue } from '@bisondesk/commons-sdk/types';
1
+ import { LocationValue, PhoneNumberValue } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { PublicSearchDefinition } from './definitions';
3
3
  import { AggregationRequest } from './search';
4
4
  import { Vehicle } from './vehicles';
@@ -2,7 +2,7 @@ import {
2
2
  PhoneNumberRawValue,
3
3
  PhoneNumberValue,
4
4
  SearchPermissions,
5
- } from '@bisondesk/commons-sdk/types';
5
+ } from '@bisondesk/commons-sdk/lib/types';
6
6
  import { PublicSearchDefinition } from './definitions';
7
7
  import { ReferenceData } from './utils';
8
8
  import { SearchVehicle } from './vehicles';
@@ -1,4 +1,4 @@
1
- import { AttachmentValue } from '@bisondesk/commons-sdk/types';
1
+ import { AttachmentValue } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { LeasingAdminUploadHandlers } from '../constants';
3
3
 
4
4
  export type LeasingAdminUploadStatus = 'success' | 'processing' | 'error';
@@ -1,5 +1,5 @@
1
- import { InsuranceEntry } from '@bisondesk/commons-sdk/insurance';
2
- import { SearchPermissions } from '@bisondesk/commons-sdk/types';
1
+ import { InsuranceEntry } from '@bisondesk/commons-sdk/lib/insurance';
2
+ import { SearchPermissions } from '@bisondesk/commons-sdk/lib/types';
3
3
  import { Organization } from './crm';
4
4
  import { PublicSearchDefinition } from './definitions';
5
5
  import { LeasingContract } from './leasing';
@@ -1,5 +1,5 @@
1
- import { MultiLangValue } from '@bisondesk/commons-sdk/types';
2
- import { Categories } from '../constants';
1
+ import { MultiLangValue } from '@bisondesk/commons-sdk/lib/types';
2
+ import { Categories, OpportunityType } from '../constants';
3
3
  import { SortFilter } from './search';
4
4
 
5
5
  export type LeasingQuoteParams = { id: string; name: string; modifiedAt: string } & {
@@ -55,6 +55,7 @@ type BaseLeasingQuoteExtraSettings = {
55
55
  vehicleCategoryRestrictions: Categories[];
56
56
  departments: string[];
57
57
  departmentTitles?: { [department: string]: string };
58
+ opportunityTypeRestrictions: OpportunityType[];
58
59
  };
59
60
 
60
61
  export type BaseLeasingQuoteExtraInput = {
@@ -106,4 +107,5 @@ export type LeasingQuoteExtrasRequest = {
106
107
  offset?: number;
107
108
  limit?: number;
108
109
  sortBy?: SortFilter;
110
+ opportunityType?: OpportunityType;
109
111
  };
@@ -1,5 +1,10 @@
1
- import { EmailMessage } from '@bisondesk/commons-sdk/messages';
2
- import { AttachmentValue, Document, LinkValue, PaginatedList } from '@bisondesk/commons-sdk/types';
1
+ import { EmailMessage } from '@bisondesk/commons-sdk/lib/messages';
2
+ import {
3
+ AttachmentValue,
4
+ Document,
5
+ LinkValue,
6
+ PaginatedList,
7
+ } from '@bisondesk/commons-sdk/lib/types';
3
8
  import { SortFilter } from './search';
4
9
  import { ReferenceData } from './utils';
5
10
 
@@ -82,7 +87,7 @@ export type LeasingContractBisondesk = {
82
87
  opportunities: OpportunityRef[];
83
88
  };
84
89
 
85
- export type LeasingContract = {
90
+ export type LeasingContract<T = LeasingContractHyperportal | LeasingContractBisondesk> = {
86
91
  id: string;
87
92
  createdAt: string;
88
93
  updatedAt: string;
@@ -101,21 +106,26 @@ export type LeasingContract = {
101
106
  };
102
107
  status: LeasingContractStatus;
103
108
  documents: Document[];
104
- } & (LeasingContractHyperportal | LeasingContractBisondesk);
109
+ } & T;
105
110
 
106
- export type ConditionsRef = {
111
+ type BaseRef = {
107
112
  id: string;
108
- validSince: string;
113
+ depositAmount: string;
114
+ durationInMonths: number;
115
+ saleAmount: string; // includes the extras
116
+ interestRate: string;
117
+ residualAmount: string;
109
118
  leasingMonthlyAmount: string; //Value excluding VAT
119
+ otherMonthlyAmounts: string; //Value excluding VAT
110
120
  totalMonthlyAmount: string; //Value excluding VAT
111
121
  };
112
122
 
113
- export type OpportunityRef = {
114
- id: string;
123
+ export type ConditionsRef = BaseRef & {
124
+ validSince: string;
125
+ };
126
+
127
+ export type OpportunityRef = BaseRef & {
115
128
  createdAt: string;
116
- leasingMonthlyAmount: string; //Value excluding VAT
117
- otherAmounts: string; //Value excluding VAT
118
- totalMonthlyAmount: string; //Value excluding VAT
119
129
  quoteId: string;
120
130
  //Since VAT is client specific and contracts can be transferred between clients, we always handle values without VAT
121
131
  };
@@ -1,4 +1,4 @@
1
- import { Document } from '@bisondesk/commons-sdk/types';
1
+ import { Document } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { OpportunityType } from '../constants';
3
3
  import { Contact, Organization } from './crm';
4
4
  import { Interest } from './leads';
@@ -1,4 +1,4 @@
1
- import { MultiLangValue } from '@bisondesk/commons-sdk/types';
1
+ import { MultiLangValue } from '@bisondesk/commons-sdk/lib/types';
2
2
 
3
3
  export type PicklistValueUpdateRequest = {
4
4
  picklistId: string;
@@ -1,4 +1,4 @@
1
- import { AttachmentValue } from '@bisondesk/commons-sdk/types';
1
+ import { AttachmentValue } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { OpportunityType } from '../constants';
3
3
  import {
4
4
  CustomLeasingQuoteExtraInput,
@@ -1,4 +1,4 @@
1
- import { AttachmentValue, Requester } from '@bisondesk/commons-sdk/types';
1
+ import { AttachmentValue, Requester } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { BusinessEntityIds } from '../constants';
3
3
 
4
4
  export type ViewedItemsRequest = {
@@ -2,7 +2,7 @@
2
2
  // Generic stuff
3
3
  ///////////////////////////////////////////////////////
4
4
 
5
- import { MultiLangValue } from '@bisondesk/commons-sdk/types';
5
+ import { MultiLangValue } from '@bisondesk/commons-sdk/lib/types';
6
6
  import { FieldTypes, NumberMeta } from './fields';
7
7
 
8
8
  export enum ConditionType {
@@ -1 +1 @@
1
- export * from '@bisondesk/commons-sdk/storage';
1
+ export * from '@bisondesk/commons-sdk/lib/storage';
@@ -1,4 +1,4 @@
1
- import { Region } from '@bisondesk/commons-sdk/types';
1
+ import { Region } from '@bisondesk/commons-sdk/lib/types';
2
2
 
3
3
  export type PublicTenant = {
4
4
  defaultCountry: string;
@@ -1,9 +1,9 @@
1
- import { AppRoles } from '@bisondesk/commons-sdk/constants';
1
+ import { AppRoles } from '@bisondesk/commons-sdk/lib/constants';
2
2
  import {
3
3
  AttachmentValue,
4
4
  PhoneNumberRawValue,
5
5
  PhoneNumberValue,
6
- } from '@bisondesk/commons-sdk/types';
6
+ } from '@bisondesk/commons-sdk/lib/types';
7
7
 
8
8
  export type NewUserRequest = {
9
9
  email: string;
@@ -1,4 +1,4 @@
1
- import { MultiLangValue } from '@bisondesk/commons-sdk/types';
1
+ import { MultiLangValue } from '@bisondesk/commons-sdk/lib/types';
2
2
  import { AdHocPicklistValueDisplay } from './picklists';
3
3
 
4
4
  export type CountryInfo = {
@@ -4,7 +4,7 @@ import {
4
4
  LocationValue,
5
5
  MultiLangValue,
6
6
  SearchPermissions,
7
- } from '@bisondesk/commons-sdk/types';
7
+ } from '@bisondesk/commons-sdk/lib/types';
8
8
 
9
9
  type BaseVehicleEvent = {
10
10
  id: string;
@@ -1,4 +1,4 @@
1
- import { PhoneNumberRawValue, PhoneNumberValue } from '@bisondesk/commons-sdk/types';
1
+ import { PhoneNumberRawValue, PhoneNumberValue } from '@bisondesk/commons-sdk/lib/types';
2
2
 
3
3
  export type ContactFormRequest = {
4
4
  email: string;
@@ -1,4 +1,4 @@
1
- import { utc } from '@bisondesk/commons-sdk/dayjs-utils';
1
+ import { utc } from '@bisondesk/commons-sdk/lib/dayjs-utils';
2
2
  import { map, sortBy, uniqBy } from 'lodash';
3
3
  import { LeasingContractClient } from '../types/leasing';
4
4
 
@@ -1,4 +1,4 @@
1
- import { XError } from '@bisondesk/commons-sdk/errors';
1
+ import { XError } from '@bisondesk/commons-sdk/lib/errors';
2
2
  import { first } from 'lodash';
3
3
  import { Branch, Tenant } from '../types/tenants';
4
4
 
package/tsconfig.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "extends": "../../tsconfig.json",
3
+ "include": ["src"],
3
4
  "compilerOptions": {
5
+ "composite": true,
4
6
  "declaration": true,
5
7
  "declarationMap": true,
6
- "sourceMap": true,
7
- "composite": true,
8
+ "outDir": "lib",
8
9
  "rootDir": "src",
9
- "declarationDir": "lib/types"
10
+ "sourceMap": true
10
11
  },
11
- "include": ["src"]
12
+ "references": [{ "path": "../commons-sdk" }]
12
13
  }