@openfn/language-mysql 1.2.0 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -7
- package/configuration-schema.json +44 -0
- package/dist/index.cjs +270 -0
- package/dist/index.js +243 -0
- package/package.json +28 -32
- package/types/Adaptor.d.ts +174 -0
- package/types/index.d.ts +3 -0
- package/lib/Adaptor.js +0 -412
- package/lib/Client.js +0 -78
- package/lib/index.js +0 -19
- package/node_modules/@openfn/language-common/LICENSE +0 -674
- package/node_modules/@openfn/language-common/LICENSE.LESSER +0 -165
- package/node_modules/@openfn/language-common/README.md +0 -14
- package/node_modules/@openfn/language-common/ast.json +0 -1001
- package/node_modules/@openfn/language-common/lib/Adaptor.js +0 -569
- package/node_modules/@openfn/language-common/lib/beta.js +0 -64
- package/node_modules/@openfn/language-common/lib/http.js +0 -233
- package/node_modules/@openfn/language-common/lib/index.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/axios/CHANGELOG.md +0 -685
- package/node_modules/@openfn/language-common/node_modules/axios/LICENSE +0 -19
- package/node_modules/@openfn/language-common/node_modules/axios/README.md +0 -800
- package/node_modules/@openfn/language-common/node_modules/axios/UPGRADE_GUIDE.md +0 -162
- package/node_modules/@openfn/language-common/node_modules/axios/dist/axios.js +0 -1756
- package/node_modules/@openfn/language-common/node_modules/axios/dist/axios.map +0 -1
- package/node_modules/@openfn/language-common/node_modules/axios/dist/axios.min.js +0 -3
- package/node_modules/@openfn/language-common/node_modules/axios/dist/axios.min.map +0 -1
- package/node_modules/@openfn/language-common/node_modules/axios/index.d.ts +0 -161
- package/node_modules/@openfn/language-common/node_modules/axios/index.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/axios/lib/adapters/README.md +0 -37
- package/node_modules/@openfn/language-common/node_modules/axios/lib/adapters/http.js +0 -303
- package/node_modules/@openfn/language-common/node_modules/axios/lib/adapters/xhr.js +0 -179
- package/node_modules/@openfn/language-common/node_modules/axios/lib/axios.js +0 -56
- package/node_modules/@openfn/language-common/node_modules/axios/lib/cancel/Cancel.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/axios/lib/cancel/CancelToken.js +0 -57
- package/node_modules/@openfn/language-common/node_modules/axios/lib/cancel/isCancel.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/Axios.js +0 -95
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/InterceptorManager.js +0 -52
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/README.md +0 -7
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/buildFullPath.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/createError.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/dispatchRequest.js +0 -79
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/enhanceError.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/mergeConfig.js +0 -87
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/settle.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/axios/lib/core/transformData.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/axios/lib/defaults.js +0 -98
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/README.md +0 -7
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/bind.js +0 -11
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/buildURL.js +0 -70
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/combineURLs.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/cookies.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/deprecatedMethod.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/isAbsoluteURL.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/isAxiosError.js +0 -11
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/isURLSameOrigin.js +0 -68
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/normalizeHeaderName.js +0 -12
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/parseHeaders.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/axios/lib/helpers/spread.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/axios/lib/utils.js +0 -351
- package/node_modules/@openfn/language-common/node_modules/axios/package.json +0 -116
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/LICENSE +0 -18
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/README.md +0 -148
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/debug.js +0 -9
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/http.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/https.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/index.js +0 -504
- package/node_modules/@openfn/language-common/node_modules/follow-redirects/package.json +0 -98
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/.babelrc.json +0 -5
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/.editorconfig +0 -16
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/.eslintignore +0 -5
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/.eslintrc.js +0 -93
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/CHANGES.md +0 -252
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/LICENSE-MIT.txt +0 -22
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/README.md +0 -376
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/demo/index.css +0 -19
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/demo/index.html +0 -32
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/demo/index.js +0 -48
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-es.js +0 -1062
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-es.min.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-es.min.js.map +0 -1
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-umd.js +0 -1072
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-umd.min.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/dist/index-umd.min.js.map +0 -1
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/licenseInfo.json +0 -4
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/package.json +0 -170
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/src/jsonpath.d.ts +0 -196
- package/node_modules/@openfn/language-common/node_modules/jsonpath-plus/src/jsonpath.js +0 -796
- package/node_modules/@openfn/language-common/node_modules/lodash/LICENSE +0 -47
- package/node_modules/@openfn/language-common/node_modules/lodash/README.md +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/_DataView.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/_Hash.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_LazyWrapper.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_ListCache.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_LodashWrapper.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_Map.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/_MapCache.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_Promise.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/_Set.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/_SetCache.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/_Stack.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/_Symbol.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_Uint8Array.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_WeakMap.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/_apply.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayAggregator.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayEach.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayEachRight.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayEvery.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayFilter.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayIncludes.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayIncludesWith.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayLikeKeys.js +0 -49
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayMap.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayPush.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayReduce.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayReduceRight.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_arraySample.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_arraySampleSize.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_arrayShuffle.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_arraySome.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_asciiSize.js +0 -12
- package/node_modules/@openfn/language-common/node_modules/lodash/_asciiToArray.js +0 -12
- package/node_modules/@openfn/language-common/node_modules/lodash/_asciiWords.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_assignMergeValue.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_assignValue.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_assocIndexOf.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseAggregator.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseAssign.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseAssignIn.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseAssignValue.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseAt.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseClamp.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseClone.js +0 -166
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseConforms.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseConformsTo.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseCreate.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseDelay.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseDifference.js +0 -67
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseEach.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseEachRight.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseEvery.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseExtremum.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFill.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFilter.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFindIndex.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFindKey.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFlatten.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFor.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseForOwn.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseForOwnRight.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseForRight.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseFunctions.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseGet.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseGetAllKeys.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseGetTag.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseGt.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseHas.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseHasIn.js +0 -13
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseInRange.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIndexOf.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIndexOfWith.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIntersection.js +0 -74
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseInverter.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseInvoke.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsArguments.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsArrayBuffer.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsDate.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsEqual.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsEqualDeep.js +0 -83
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsMap.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsMatch.js +0 -62
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsNaN.js +0 -12
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsNative.js +0 -47
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsRegExp.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsSet.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIsTypedArray.js +0 -60
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseIteratee.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseKeys.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseKeysIn.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseLodash.js +0 -10
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseLt.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMap.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMatches.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMatchesProperty.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMean.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMerge.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseMergeDeep.js +0 -94
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseNth.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseOrderBy.js +0 -49
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePick.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePickBy.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseProperty.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePropertyDeep.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePropertyOf.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePullAll.js +0 -51
- package/node_modules/@openfn/language-common/node_modules/lodash/_basePullAt.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseRandom.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseRange.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseReduce.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseRepeat.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseRest.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSample.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSampleSize.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSet.js +0 -51
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSetData.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSetToString.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseShuffle.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSlice.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSome.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSortBy.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSortedIndex.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSortedIndexBy.js +0 -67
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSortedUniq.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseSum.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseTimes.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseToNumber.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseToPairs.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseToString.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseTrim.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseUnary.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseUniq.js +0 -72
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseUnset.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseUpdate.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseValues.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseWhile.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseWrapperValue.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseXor.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/_baseZipObject.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_cacheHas.js +0 -13
- package/node_modules/@openfn/language-common/node_modules/lodash/_castArrayLikeObject.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_castFunction.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_castPath.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_castRest.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_castSlice.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_charsEndIndex.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_charsStartIndex.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneArrayBuffer.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneBuffer.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneDataView.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneRegExp.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneSymbol.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_cloneTypedArray.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_compareAscending.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/_compareMultiple.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/_composeArgs.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/_composeArgsRight.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/_copyArray.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_copyObject.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/_copySymbols.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_copySymbolsIn.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_coreJsData.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_countHolders.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_createAggregator.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_createAssigner.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/_createBaseEach.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/_createBaseFor.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_createBind.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_createCaseFirst.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/_createCompounder.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_createCtor.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/_createCurry.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/_createFind.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_createFlow.js +0 -78
- package/node_modules/@openfn/language-common/node_modules/lodash/_createHybrid.js +0 -92
- package/node_modules/@openfn/language-common/node_modules/lodash/_createInverter.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_createMathOperation.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/_createOver.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/_createPadding.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/_createPartial.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/_createRange.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_createRecurry.js +0 -56
- package/node_modules/@openfn/language-common/node_modules/lodash/_createRelationalOperation.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_createRound.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/_createSet.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_createToPairs.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_createWrap.js +0 -106
- package/node_modules/@openfn/language-common/node_modules/lodash/_customDefaultsAssignIn.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/_customDefaultsMerge.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_customOmitClone.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_deburrLetter.js +0 -71
- package/node_modules/@openfn/language-common/node_modules/lodash/_defineProperty.js +0 -11
- package/node_modules/@openfn/language-common/node_modules/lodash/_equalArrays.js +0 -84
- package/node_modules/@openfn/language-common/node_modules/lodash/_equalByTag.js +0 -112
- package/node_modules/@openfn/language-common/node_modules/lodash/_equalObjects.js +0 -90
- package/node_modules/@openfn/language-common/node_modules/lodash/_escapeHtmlChar.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_escapeStringChar.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_flatRest.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_freeGlobal.js +0 -4
- package/node_modules/@openfn/language-common/node_modules/lodash/_getAllKeys.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_getAllKeysIn.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_getData.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_getFuncName.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/_getHolder.js +0 -13
- package/node_modules/@openfn/language-common/node_modules/lodash/_getMapData.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_getMatchData.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/_getNative.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_getPrototype.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_getRawTag.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/_getSymbols.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_getSymbolsIn.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_getTag.js +0 -58
- package/node_modules/@openfn/language-common/node_modules/lodash/_getValue.js +0 -13
- package/node_modules/@openfn/language-common/node_modules/lodash/_getView.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/_getWrapDetails.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_hasPath.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/_hasUnicode.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_hasUnicodeWord.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_hashClear.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_hashDelete.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/_hashGet.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_hashHas.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_hashSet.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_initCloneArray.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_initCloneByTag.js +0 -77
- package/node_modules/@openfn/language-common/node_modules/lodash/_initCloneObject.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_insertWrapDetails.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_isFlattenable.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_isIndex.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/_isIterateeCall.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_isKey.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/_isKeyable.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_isLaziable.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_isMaskable.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_isMasked.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_isPrototype.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_isStrictComparable.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_iteratorToArray.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_lazyClone.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_lazyReverse.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_lazyValue.js +0 -69
- package/node_modules/@openfn/language-common/node_modules/lodash/_listCacheClear.js +0 -13
- package/node_modules/@openfn/language-common/node_modules/lodash/_listCacheDelete.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/_listCacheGet.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_listCacheHas.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_listCacheSet.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapCacheClear.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapCacheDelete.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapCacheGet.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapCacheHas.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapCacheSet.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_mapToArray.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_matchesStrictComparable.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_memoizeCapped.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_mergeData.js +0 -90
- package/node_modules/@openfn/language-common/node_modules/lodash/_metaMap.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_nativeCreate.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_nativeKeys.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/_nativeKeysIn.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_nodeUtil.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/_objectToString.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/_overArg.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_overRest.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/_parent.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/_reEscape.js +0 -4
- package/node_modules/@openfn/language-common/node_modules/lodash/_reEvaluate.js +0 -4
- package/node_modules/@openfn/language-common/node_modules/lodash/_reInterpolate.js +0 -4
- package/node_modules/@openfn/language-common/node_modules/lodash/_realNames.js +0 -4
- package/node_modules/@openfn/language-common/node_modules/lodash/_reorder.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/_replaceHolders.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/_root.js +0 -9
- package/node_modules/@openfn/language-common/node_modules/lodash/_safeGet.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_setCacheAdd.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_setCacheHas.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_setData.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/_setToArray.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_setToPairs.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_setToString.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_setWrapToString.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_shortOut.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/_shuffleSelf.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/_stackClear.js +0 -15
- package/node_modules/@openfn/language-common/node_modules/lodash/_stackDelete.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_stackGet.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_stackHas.js +0 -14
- package/node_modules/@openfn/language-common/node_modules/lodash/_stackSet.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/_strictIndexOf.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/_strictLastIndexOf.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_stringSize.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_stringToArray.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/_stringToPath.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/_toKey.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_toSource.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/_trimmedEndIndex.js +0 -19
- package/node_modules/@openfn/language-common/node_modules/lodash/_unescapeHtmlChar.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/_unicodeSize.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/_unicodeToArray.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/_unicodeWords.js +0 -69
- package/node_modules/@openfn/language-common/node_modules/lodash/_updateWrapDetails.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/_wrapperClone.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/add.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/after.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/array.js +0 -67
- package/node_modules/@openfn/language-common/node_modules/lodash/ary.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/assign.js +0 -58
- package/node_modules/@openfn/language-common/node_modules/lodash/assignIn.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/assignInWith.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/assignWith.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/at.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/attempt.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/before.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/bind.js +0 -57
- package/node_modules/@openfn/language-common/node_modules/lodash/bindAll.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/bindKey.js +0 -68
- package/node_modules/@openfn/language-common/node_modules/lodash/camelCase.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/capitalize.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/castArray.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/ceil.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/chain.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/chunk.js +0 -50
- package/node_modules/@openfn/language-common/node_modules/lodash/clamp.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/clone.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/cloneDeep.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/cloneDeepWith.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/cloneWith.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/collection.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/commit.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/compact.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/concat.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/cond.js +0 -60
- package/node_modules/@openfn/language-common/node_modules/lodash/conforms.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/conformsTo.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/constant.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/core.js +0 -3877
- package/node_modules/@openfn/language-common/node_modules/lodash/core.min.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/countBy.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/create.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/curry.js +0 -57
- package/node_modules/@openfn/language-common/node_modules/lodash/curryRight.js +0 -54
- package/node_modules/@openfn/language-common/node_modules/lodash/date.js +0 -3
- package/node_modules/@openfn/language-common/node_modules/lodash/debounce.js +0 -191
- package/node_modules/@openfn/language-common/node_modules/lodash/deburr.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/defaultTo.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/defaults.js +0 -64
- package/node_modules/@openfn/language-common/node_modules/lodash/defaultsDeep.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/defer.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/delay.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/difference.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/differenceBy.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/differenceWith.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/divide.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/drop.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/dropRight.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/dropRightWhile.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/dropWhile.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/each.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/eachRight.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/endsWith.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/entries.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/entriesIn.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/eq.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/escape.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/escapeRegExp.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/every.js +0 -56
- package/node_modules/@openfn/language-common/node_modules/lodash/extend.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/extendWith.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fill.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/filter.js +0 -52
- package/node_modules/@openfn/language-common/node_modules/lodash/find.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/findIndex.js +0 -55
- package/node_modules/@openfn/language-common/node_modules/lodash/findKey.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/findLast.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/findLastIndex.js +0 -59
- package/node_modules/@openfn/language-common/node_modules/lodash/findLastKey.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/first.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/flake.lock +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/flake.nix +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/flatMap.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/flatMapDeep.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/flatMapDepth.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/flatten.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/flattenDeep.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/flattenDepth.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/flip.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/floor.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/flow.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/flowRight.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/forEach.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/forEachRight.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/forIn.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/forInRight.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/forOwn.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/forOwnRight.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/F.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/T.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/__.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/_baseConvert.js +0 -569
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/_convertBrowser.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/_falseOptions.js +0 -7
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/_mapping.js +0 -358
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/_util.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/add.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/after.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/all.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/allPass.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/always.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/any.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/anyPass.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/apply.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/array.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/ary.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assign.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignAllWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignInAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignInAllWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignInWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assignWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assoc.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/assocPath.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/at.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/attempt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/before.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/bind.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/bindAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/bindKey.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/camelCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/capitalize.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/castArray.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/ceil.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/chain.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/chunk.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/clamp.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/clone.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/cloneDeep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/cloneDeepWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/cloneWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/collection.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/commit.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/compact.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/complement.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/compose.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/concat.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/cond.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/conforms.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/conformsTo.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/constant.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/contains.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/convert.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/countBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/create.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/curry.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/curryN.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/curryRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/curryRightN.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/date.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/debounce.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/deburr.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defaultTo.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defaults.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defaultsAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defaultsDeep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defaultsDeepAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/defer.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/delay.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/difference.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/differenceBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/differenceWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dissoc.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dissocPath.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/divide.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/drop.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dropLast.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dropLastWhile.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dropRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dropRightWhile.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/dropWhile.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/each.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/eachRight.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/endsWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/entries.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/entriesIn.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/eq.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/equals.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/escape.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/escapeRegExp.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/every.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/extend.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/extendAll.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/extendAllWith.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/extendWith.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/fill.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/filter.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/find.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findIndex.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findIndexFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findKey.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findLast.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findLastFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findLastIndex.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findLastIndexFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/findLastKey.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/first.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flatMap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flatMapDeep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flatMapDepth.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flatten.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flattenDeep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flattenDepth.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flip.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/floor.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flow.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/flowRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forEach.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forEachRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forInRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forOwn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/forOwnRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/fromPairs.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/function.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/functions.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/functionsIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/get.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/getOr.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/groupBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/gt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/gte.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/has.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/hasIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/head.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/identical.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/identity.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/inRange.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/includes.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/includesFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/indexBy.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/indexOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/indexOfFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/init.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/initial.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/intersection.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/intersectionBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/intersectionWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invert.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invertBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invertObj.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invoke.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invokeArgs.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invokeArgsMap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/invokeMap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isArguments.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isArray.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isArrayBuffer.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isArrayLike.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isArrayLikeObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isBoolean.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isBuffer.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isDate.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isElement.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isEmpty.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isEqual.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isEqualWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isError.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isFinite.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isFunction.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isInteger.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isLength.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isMap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isMatch.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isMatchWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isNaN.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isNative.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isNil.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isNull.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isNumber.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isObjectLike.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isPlainObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isRegExp.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isSafeInteger.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isSet.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isString.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isSymbol.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isTypedArray.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isUndefined.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isWeakMap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/isWeakSet.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/iteratee.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/join.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/juxt.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/kebabCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/keyBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/keys.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/keysIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lang.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/last.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lastIndexOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lastIndexOfFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lowerCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lowerFirst.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/lte.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/map.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mapKeys.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mapValues.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/matches.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/matchesProperty.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/math.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/max.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/maxBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mean.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/meanBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/memoize.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/merge.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mergeAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mergeAllWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mergeWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/method.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/methodOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/min.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/minBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/mixin.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/multiply.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/nAry.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/negate.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/next.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/noop.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/now.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/nth.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/nthArg.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/number.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/object.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/omit.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/omitAll.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/omitBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/once.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/orderBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/over.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/overArgs.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/overEvery.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/overSome.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pad.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/padChars.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/padCharsEnd.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/padCharsStart.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/padEnd.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/padStart.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/parseInt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/partial.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/partialRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/partition.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/path.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pathEq.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pathOr.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/paths.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pick.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pickAll.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pickBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pipe.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/placeholder.js +0 -6
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/plant.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pluck.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/prop.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/propEq.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/propOr.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/property.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/propertyOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/props.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pull.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pullAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pullAllBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pullAllWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/pullAt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/random.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/range.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/rangeRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/rangeStep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/rangeStepRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/rearg.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/reduce.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/reduceRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/reject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/remove.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/repeat.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/replace.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/rest.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/restFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/result.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/reverse.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/round.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sample.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sampleSize.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/seq.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/set.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/setWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/shuffle.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/size.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/slice.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/snakeCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/some.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedIndex.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedIndexBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedIndexOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedLastIndex.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedLastIndexBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedLastIndexOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedUniq.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sortedUniqBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/split.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/spread.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/spreadFrom.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/startCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/startsWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/string.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/stubArray.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/stubFalse.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/stubObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/stubString.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/stubTrue.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/subtract.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sum.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/sumBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/symmetricDifference.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/symmetricDifferenceBy.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/symmetricDifferenceWith.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/tail.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/take.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/takeLast.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/takeLastWhile.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/takeRight.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/takeRightWhile.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/takeWhile.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/tap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/template.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/templateSettings.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/throttle.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/thru.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/times.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toArray.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toFinite.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toInteger.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toIterator.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toJSON.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toLength.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toLower.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toNumber.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toPairs.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toPairsIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toPath.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toPlainObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toSafeInteger.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toString.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/toUpper.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/transform.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trim.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trimChars.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trimCharsEnd.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trimCharsStart.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trimEnd.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/trimStart.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/truncate.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unapply.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unary.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unescape.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/union.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unionBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unionWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/uniq.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/uniqBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/uniqWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/uniqueId.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unnest.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unset.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unzip.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/unzipWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/update.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/updateWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/upperCase.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/upperFirst.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/useWith.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/util.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/value.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/valueOf.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/values.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/valuesIn.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/where.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/whereEq.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/without.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/words.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrap.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrapperAt.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrapperChain.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrapperLodash.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrapperReverse.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/wrapperValue.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/xor.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/xorBy.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/xorWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zip.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zipAll.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zipObj.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zipObject.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zipObjectDeep.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp/zipWith.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/fp.js +0 -2
- package/node_modules/@openfn/language-common/node_modules/lodash/fromPairs.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/function.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/functions.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/functionsIn.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/get.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/groupBy.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/gt.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/gte.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/has.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/hasIn.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/head.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/identity.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/inRange.js +0 -55
- package/node_modules/@openfn/language-common/node_modules/lodash/includes.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/lodash/index.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/indexOf.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/initial.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/intersection.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/intersectionBy.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/intersectionWith.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/invert.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/invertBy.js +0 -56
- package/node_modules/@openfn/language-common/node_modules/lodash/invoke.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/invokeMap.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/isArguments.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/isArray.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/isArrayBuffer.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isArrayLike.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/isArrayLikeObject.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/isBoolean.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/isBuffer.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/isDate.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isElement.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/isEmpty.js +0 -77
- package/node_modules/@openfn/language-common/node_modules/lodash/isEqual.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/isEqualWith.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/isError.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/isFinite.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/isFunction.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/isInteger.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/isLength.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/isMap.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isMatch.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/isMatchWith.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/isNaN.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/isNative.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/isNil.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/isNull.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/isNumber.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/isObject.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/isObjectLike.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/isPlainObject.js +0 -62
- package/node_modules/@openfn/language-common/node_modules/lodash/isRegExp.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isSafeInteger.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/isSet.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isString.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/isSymbol.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/isTypedArray.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/isUndefined.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/isWeakMap.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/isWeakSet.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/iteratee.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/lodash/join.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/kebabCase.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/keyBy.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/keys.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/keysIn.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/lang.js +0 -58
- package/node_modules/@openfn/language-common/node_modules/lodash/last.js +0 -20
- package/node_modules/@openfn/language-common/node_modules/lodash/lastIndexOf.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/lodash.js +0 -17209
- package/node_modules/@openfn/language-common/node_modules/lodash/lodash.min.js +0 -140
- package/node_modules/@openfn/language-common/node_modules/lodash/lowerCase.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/lowerFirst.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/lt.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/lte.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/map.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/lodash/mapKeys.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/mapValues.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/matches.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/matchesProperty.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/math.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/max.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/maxBy.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/mean.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/meanBy.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/memoize.js +0 -73
- package/node_modules/@openfn/language-common/node_modules/lodash/merge.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/mergeWith.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/method.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/methodOf.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/min.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/minBy.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/mixin.js +0 -74
- package/node_modules/@openfn/language-common/node_modules/lodash/multiply.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/negate.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/next.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/noop.js +0 -17
- package/node_modules/@openfn/language-common/node_modules/lodash/now.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/nth.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/nthArg.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/number.js +0 -5
- package/node_modules/@openfn/language-common/node_modules/lodash/object.js +0 -49
- package/node_modules/@openfn/language-common/node_modules/lodash/omit.js +0 -57
- package/node_modules/@openfn/language-common/node_modules/lodash/omitBy.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/once.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/orderBy.js +0 -47
- package/node_modules/@openfn/language-common/node_modules/lodash/over.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/overArgs.js +0 -61
- package/node_modules/@openfn/language-common/node_modules/lodash/overEvery.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/overSome.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/package.json +0 -66
- package/node_modules/@openfn/language-common/node_modules/lodash/pad.js +0 -49
- package/node_modules/@openfn/language-common/node_modules/lodash/padEnd.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/padStart.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/parseInt.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/partial.js +0 -50
- package/node_modules/@openfn/language-common/node_modules/lodash/partialRight.js +0 -49
- package/node_modules/@openfn/language-common/node_modules/lodash/partition.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/pick.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/pickBy.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/plant.js +0 -48
- package/node_modules/@openfn/language-common/node_modules/lodash/property.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/propertyOf.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/pull.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/pullAll.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/pullAllBy.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/pullAllWith.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/pullAt.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/random.js +0 -82
- package/node_modules/@openfn/language-common/node_modules/lodash/range.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/rangeRight.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/rearg.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/reduce.js +0 -51
- package/node_modules/@openfn/language-common/node_modules/lodash/reduceRight.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/reject.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/release.md +0 -48
- package/node_modules/@openfn/language-common/node_modules/lodash/remove.js +0 -53
- package/node_modules/@openfn/language-common/node_modules/lodash/repeat.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/replace.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/rest.js +0 -40
- package/node_modules/@openfn/language-common/node_modules/lodash/result.js +0 -56
- package/node_modules/@openfn/language-common/node_modules/lodash/reverse.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/round.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/sample.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/sampleSize.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/seq.js +0 -16
- package/node_modules/@openfn/language-common/node_modules/lodash/set.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/setWith.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/shuffle.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/size.js +0 -46
- package/node_modules/@openfn/language-common/node_modules/lodash/slice.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/snakeCase.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/some.js +0 -51
- package/node_modules/@openfn/language-common/node_modules/lodash/sortBy.js +0 -48
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedIndex.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedIndexBy.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedIndexOf.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedLastIndex.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedLastIndexBy.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedLastIndexOf.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedUniq.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/sortedUniqBy.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/split.js +0 -52
- package/node_modules/@openfn/language-common/node_modules/lodash/spread.js +0 -63
- package/node_modules/@openfn/language-common/node_modules/lodash/startCase.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/startsWith.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/string.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/stubArray.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/stubFalse.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/stubObject.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/stubString.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/stubTrue.js +0 -18
- package/node_modules/@openfn/language-common/node_modules/lodash/subtract.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/sum.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/sumBy.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/tail.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/take.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/takeRight.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/takeRightWhile.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/takeWhile.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/tap.js +0 -29
- package/node_modules/@openfn/language-common/node_modules/lodash/template.js +0 -272
- package/node_modules/@openfn/language-common/node_modules/lodash/templateSettings.js +0 -67
- package/node_modules/@openfn/language-common/node_modules/lodash/throttle.js +0 -69
- package/node_modules/@openfn/language-common/node_modules/lodash/thru.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/times.js +0 -51
- package/node_modules/@openfn/language-common/node_modules/lodash/toArray.js +0 -58
- package/node_modules/@openfn/language-common/node_modules/lodash/toFinite.js +0 -42
- package/node_modules/@openfn/language-common/node_modules/lodash/toInteger.js +0 -36
- package/node_modules/@openfn/language-common/node_modules/lodash/toIterator.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/toJSON.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/toLength.js +0 -38
- package/node_modules/@openfn/language-common/node_modules/lodash/toLower.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/toNumber.js +0 -64
- package/node_modules/@openfn/language-common/node_modules/lodash/toPairs.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/toPairsIn.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/toPath.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/toPlainObject.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/toSafeInteger.js +0 -37
- package/node_modules/@openfn/language-common/node_modules/lodash/toString.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/toUpper.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/transform.js +0 -65
- package/node_modules/@openfn/language-common/node_modules/lodash/trim.js +0 -47
- package/node_modules/@openfn/language-common/node_modules/lodash/trimEnd.js +0 -41
- package/node_modules/@openfn/language-common/node_modules/lodash/trimStart.js +0 -43
- package/node_modules/@openfn/language-common/node_modules/lodash/truncate.js +0 -111
- package/node_modules/@openfn/language-common/node_modules/lodash/unary.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/unescape.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/union.js +0 -26
- package/node_modules/@openfn/language-common/node_modules/lodash/unionBy.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/unionWith.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/uniq.js +0 -25
- package/node_modules/@openfn/language-common/node_modules/lodash/uniqBy.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/uniqWith.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/uniqueId.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/unset.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/unzip.js +0 -45
- package/node_modules/@openfn/language-common/node_modules/lodash/unzipWith.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/update.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/updateWith.js +0 -33
- package/node_modules/@openfn/language-common/node_modules/lodash/upperCase.js +0 -27
- package/node_modules/@openfn/language-common/node_modules/lodash/upperFirst.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/util.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/value.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/valueOf.js +0 -1
- package/node_modules/@openfn/language-common/node_modules/lodash/values.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/valuesIn.js +0 -32
- package/node_modules/@openfn/language-common/node_modules/lodash/without.js +0 -31
- package/node_modules/@openfn/language-common/node_modules/lodash/words.js +0 -35
- package/node_modules/@openfn/language-common/node_modules/lodash/wrap.js +0 -30
- package/node_modules/@openfn/language-common/node_modules/lodash/wrapperAt.js +0 -48
- package/node_modules/@openfn/language-common/node_modules/lodash/wrapperChain.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/wrapperLodash.js +0 -147
- package/node_modules/@openfn/language-common/node_modules/lodash/wrapperReverse.js +0 -44
- package/node_modules/@openfn/language-common/node_modules/lodash/wrapperValue.js +0 -21
- package/node_modules/@openfn/language-common/node_modules/lodash/xor.js +0 -28
- package/node_modules/@openfn/language-common/node_modules/lodash/xorBy.js +0 -39
- package/node_modules/@openfn/language-common/node_modules/lodash/xorWith.js +0 -34
- package/node_modules/@openfn/language-common/node_modules/lodash/zip.js +0 -22
- package/node_modules/@openfn/language-common/node_modules/lodash/zipObject.js +0 -24
- package/node_modules/@openfn/language-common/node_modules/lodash/zipObjectDeep.js +0 -23
- package/node_modules/@openfn/language-common/node_modules/lodash/zipWith.js +0 -32
- package/node_modules/@openfn/language-common/package.json +0 -86
- package/node_modules/bignumber.js/CHANGELOG.md +0 -266
- package/node_modules/bignumber.js/LICENCE +0 -23
- package/node_modules/bignumber.js/README.md +0 -268
- package/node_modules/bignumber.js/bignumber.d.ts +0 -1829
- package/node_modules/bignumber.js/bignumber.js +0 -2902
- package/node_modules/bignumber.js/bignumber.min.js +0 -1
- package/node_modules/bignumber.js/bignumber.min.js.map +0 -1
- package/node_modules/bignumber.js/bignumber.mjs +0 -2888
- package/node_modules/bignumber.js/doc/API.html +0 -2237
- package/node_modules/bignumber.js/package.json +0 -72
- package/node_modules/core-util-is/LICENSE +0 -19
- package/node_modules/core-util-is/README.md +0 -3
- package/node_modules/core-util-is/float.patch +0 -604
- package/node_modules/core-util-is/lib/util.js +0 -107
- package/node_modules/core-util-is/package.json +0 -65
- package/node_modules/core-util-is/test.js +0 -68
- package/node_modules/inherits/LICENSE +0 -16
- package/node_modules/inherits/README.md +0 -42
- package/node_modules/inherits/inherits.js +0 -9
- package/node_modules/inherits/inherits_browser.js +0 -27
- package/node_modules/inherits/package.json +0 -68
- package/node_modules/isarray/.npmignore +0 -1
- package/node_modules/isarray/.travis.yml +0 -4
- package/node_modules/isarray/Makefile +0 -6
- package/node_modules/isarray/README.md +0 -60
- package/node_modules/isarray/component.json +0 -19
- package/node_modules/isarray/index.js +0 -5
- package/node_modules/isarray/package.json +0 -77
- package/node_modules/isarray/test.js +0 -20
- package/node_modules/json-sql/.jshintrc +0 -19
- package/node_modules/json-sql/.npmignore +0 -5
- package/node_modules/json-sql/LICENSE +0 -22
- package/node_modules/json-sql/README.md +0 -147
- package/node_modules/json-sql/lib/builder.js +0 -127
- package/node_modules/json-sql/lib/dialects/base/blocks.js +0 -430
- package/node_modules/json-sql/lib/dialects/base/index.js +0 -353
- package/node_modules/json-sql/lib/dialects/base/modifiers.js +0 -27
- package/node_modules/json-sql/lib/dialects/base/operators/comparison.js +0 -245
- package/node_modules/json-sql/lib/dialects/base/operators/fetching.js +0 -79
- package/node_modules/json-sql/lib/dialects/base/operators/index.js +0 -13
- package/node_modules/json-sql/lib/dialects/base/operators/logical.js +0 -36
- package/node_modules/json-sql/lib/dialects/base/operators/state.js +0 -15
- package/node_modules/json-sql/lib/dialects/base/templates.js +0 -243
- package/node_modules/json-sql/lib/dialects/mssql/index.js +0 -13
- package/node_modules/json-sql/lib/dialects/mysql/index.js +0 -16
- package/node_modules/json-sql/lib/dialects/postgresql/blocks.js +0 -63
- package/node_modules/json-sql/lib/dialects/postgresql/index.js +0 -44
- package/node_modules/json-sql/lib/dialects/postgresql/operators/comparison.js +0 -58
- package/node_modules/json-sql/lib/dialects/postgresql/operators/fetching.js +0 -10
- package/node_modules/json-sql/lib/dialects/postgresql/operators/index.js +0 -9
- package/node_modules/json-sql/lib/dialects/postgresql/templates.js +0 -49
- package/node_modules/json-sql/lib/dialects/sqlite/blocks.js +0 -15
- package/node_modules/json-sql/lib/dialects/sqlite/index.js +0 -17
- package/node_modules/json-sql/lib/index.js +0 -8
- package/node_modules/json-sql/lib/utils/object.js +0 -27
- package/node_modules/json-sql/lib/utils/templateChecks.js +0 -72
- package/node_modules/json-sql/lib/utils/valuesStore.js +0 -24
- package/node_modules/json-sql/node_modules/underscore/LICENSE +0 -23
- package/node_modules/json-sql/node_modules/underscore/README.md +0 -22
- package/node_modules/json-sql/node_modules/underscore/package.json +0 -76
- package/node_modules/json-sql/node_modules/underscore/underscore-min.js +0 -6
- package/node_modules/json-sql/node_modules/underscore/underscore-min.map +0 -1
- package/node_modules/json-sql/node_modules/underscore/underscore.js +0 -1536
- package/node_modules/json-sql/package.json +0 -66
- package/node_modules/mysql/Changes.md +0 -569
- package/node_modules/mysql/License +0 -19
- package/node_modules/mysql/Readme.md +0 -1548
- package/node_modules/mysql/index.js +0 -161
- package/node_modules/mysql/lib/Connection.js +0 -529
- package/node_modules/mysql/lib/ConnectionConfig.js +0 -209
- package/node_modules/mysql/lib/Pool.js +0 -294
- package/node_modules/mysql/lib/PoolCluster.js +0 -288
- package/node_modules/mysql/lib/PoolConfig.js +0 -32
- package/node_modules/mysql/lib/PoolConnection.js +0 -65
- package/node_modules/mysql/lib/PoolNamespace.js +0 -136
- package/node_modules/mysql/lib/PoolSelector.js +0 -31
- package/node_modules/mysql/lib/protocol/Auth.js +0 -168
- package/node_modules/mysql/lib/protocol/BufferList.js +0 -25
- package/node_modules/mysql/lib/protocol/PacketHeader.js +0 -5
- package/node_modules/mysql/lib/protocol/PacketWriter.js +0 -211
- package/node_modules/mysql/lib/protocol/Parser.js +0 -491
- package/node_modules/mysql/lib/protocol/Protocol.js +0 -463
- package/node_modules/mysql/lib/protocol/ResultSet.js +0 -7
- package/node_modules/mysql/lib/protocol/SqlString.js +0 -1
- package/node_modules/mysql/lib/protocol/Timer.js +0 -33
- package/node_modules/mysql/lib/protocol/constants/charsets.js +0 -262
- package/node_modules/mysql/lib/protocol/constants/client.js +0 -26
- package/node_modules/mysql/lib/protocol/constants/errors.js +0 -2476
- package/node_modules/mysql/lib/protocol/constants/field_flags.js +0 -18
- package/node_modules/mysql/lib/protocol/constants/server_status.js +0 -39
- package/node_modules/mysql/lib/protocol/constants/ssl_profiles.js +0 -1480
- package/node_modules/mysql/lib/protocol/constants/types.js +0 -72
- package/node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js +0 -20
- package/node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js +0 -14
- package/node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js +0 -54
- package/node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js +0 -26
- package/node_modules/mysql/lib/protocol/packets/ComPingPacket.js +0 -12
- package/node_modules/mysql/lib/protocol/packets/ComQueryPacket.js +0 -15
- package/node_modules/mysql/lib/protocol/packets/ComQuitPacket.js +0 -12
- package/node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js +0 -12
- package/node_modules/mysql/lib/protocol/packets/EmptyPacket.js +0 -9
- package/node_modules/mysql/lib/protocol/packets/EofPacket.js +0 -25
- package/node_modules/mysql/lib/protocol/packets/ErrorPacket.js +0 -35
- package/node_modules/mysql/lib/protocol/packets/Field.js +0 -26
- package/node_modules/mysql/lib/protocol/packets/FieldPacket.js +0 -93
- package/node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js +0 -103
- package/node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js +0 -15
- package/node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js +0 -21
- package/node_modules/mysql/lib/protocol/packets/OkPacket.js +0 -44
- package/node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js +0 -14
- package/node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js +0 -14
- package/node_modules/mysql/lib/protocol/packets/RowDataPacket.js +0 -130
- package/node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js +0 -27
- package/node_modules/mysql/lib/protocol/packets/StatisticsPacket.js +0 -20
- package/node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js +0 -14
- package/node_modules/mysql/lib/protocol/packets/index.js +0 -23
- package/node_modules/mysql/lib/protocol/sequences/ChangeUser.js +0 -67
- package/node_modules/mysql/lib/protocol/sequences/Handshake.js +0 -126
- package/node_modules/mysql/lib/protocol/sequences/Ping.js +0 -19
- package/node_modules/mysql/lib/protocol/sequences/Query.js +0 -228
- package/node_modules/mysql/lib/protocol/sequences/Quit.js +0 -40
- package/node_modules/mysql/lib/protocol/sequences/Sequence.js +0 -125
- package/node_modules/mysql/lib/protocol/sequences/Statistics.js +0 -30
- package/node_modules/mysql/lib/protocol/sequences/index.js +0 -7
- package/node_modules/mysql/package.json +0 -100
- package/node_modules/process-nextick-args/index.js +0 -45
- package/node_modules/process-nextick-args/license.md +0 -19
- package/node_modules/process-nextick-args/package.json +0 -53
- package/node_modules/process-nextick-args/readme.md +0 -18
- package/node_modules/readable-stream/.travis.yml +0 -34
- package/node_modules/readable-stream/CONTRIBUTING.md +0 -38
- package/node_modules/readable-stream/GOVERNANCE.md +0 -136
- package/node_modules/readable-stream/LICENSE +0 -47
- package/node_modules/readable-stream/README.md +0 -58
- package/node_modules/readable-stream/doc/wg-meetings/2015-01-30.md +0 -60
- package/node_modules/readable-stream/duplex-browser.js +0 -1
- package/node_modules/readable-stream/duplex.js +0 -1
- package/node_modules/readable-stream/lib/_stream_duplex.js +0 -131
- package/node_modules/readable-stream/lib/_stream_passthrough.js +0 -47
- package/node_modules/readable-stream/lib/_stream_readable.js +0 -1019
- package/node_modules/readable-stream/lib/_stream_transform.js +0 -214
- package/node_modules/readable-stream/lib/_stream_writable.js +0 -687
- package/node_modules/readable-stream/lib/internal/streams/BufferList.js +0 -79
- package/node_modules/readable-stream/lib/internal/streams/destroy.js +0 -74
- package/node_modules/readable-stream/lib/internal/streams/stream-browser.js +0 -1
- package/node_modules/readable-stream/lib/internal/streams/stream.js +0 -1
- package/node_modules/readable-stream/package.json +0 -85
- package/node_modules/readable-stream/passthrough.js +0 -1
- package/node_modules/readable-stream/readable-browser.js +0 -7
- package/node_modules/readable-stream/readable.js +0 -19
- package/node_modules/readable-stream/transform.js +0 -1
- package/node_modules/readable-stream/writable-browser.js +0 -1
- package/node_modules/readable-stream/writable.js +0 -8
- package/node_modules/safe-buffer/LICENSE +0 -21
- package/node_modules/safe-buffer/README.md +0 -584
- package/node_modules/safe-buffer/index.d.ts +0 -187
- package/node_modules/safe-buffer/index.js +0 -62
- package/node_modules/safe-buffer/package.json +0 -69
- package/node_modules/sqlstring/HISTORY.md +0 -43
- package/node_modules/sqlstring/LICENSE +0 -19
- package/node_modules/sqlstring/README.md +0 -206
- package/node_modules/sqlstring/index.js +0 -1
- package/node_modules/sqlstring/lib/SqlString.js +0 -237
- package/node_modules/sqlstring/package.json +0 -101
- package/node_modules/squel/CHANGELOG.md +0 -218
- package/node_modules/squel/CONTRIBUTING.md +0 -28
- package/node_modules/squel/LICENSE.md +0 -27
- package/node_modules/squel/README.md +0 -382
- package/node_modules/squel/RELEASE.md +0 -13
- package/node_modules/squel/dist/squel-basic.js +0 -3067
- package/node_modules/squel/dist/squel-basic.min.js +0 -2
- package/node_modules/squel/dist/squel.d.ts +0 -1750
- package/node_modules/squel/dist/squel.js +0 -3982
- package/node_modules/squel/dist/squel.min.js +0 -2
- package/node_modules/squel/gulpfile.js +0 -117
- package/node_modules/squel/package.json +0 -99
- package/node_modules/squel/performance/select.js +0 -22
- package/node_modules/string-escape/README.md +0 -352
- package/node_modules/string-escape/package.json +0 -60
- package/node_modules/string_decoder/.travis.yml +0 -50
- package/node_modules/string_decoder/LICENSE +0 -48
- package/node_modules/string_decoder/README.md +0 -47
- package/node_modules/string_decoder/lib/string_decoder.js +0 -296
- package/node_modules/string_decoder/package.json +0 -62
- package/node_modules/util-deprecate/History.md +0 -16
- package/node_modules/util-deprecate/LICENSE +0 -24
- package/node_modules/util-deprecate/README.md +0 -53
- package/node_modules/util-deprecate/browser.js +0 -67
- package/node_modules/util-deprecate/node.js +0 -6
- package/node_modules/util-deprecate/package.json +0 -59
|
@@ -1,3067 +0,0 @@
|
|
|
1
|
-
;(function(root, factory) {
|
|
2
|
-
if (typeof define === 'function' && define.amd) {
|
|
3
|
-
define([], factory);
|
|
4
|
-
} else if (typeof exports === 'object') {
|
|
5
|
-
module.exports = factory();
|
|
6
|
-
} else {
|
|
7
|
-
root.squel = factory();
|
|
8
|
-
}
|
|
9
|
-
}(this, function() {
|
|
10
|
-
'use strict';
|
|
11
|
-
|
|
12
|
-
var _get = function get(object, property, receiver) { if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { return get(parent, property, receiver); } } else if ("value" in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } };
|
|
13
|
-
|
|
14
|
-
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
15
|
-
|
|
16
|
-
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
|
|
17
|
-
|
|
18
|
-
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
|
|
19
|
-
|
|
20
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
|
|
21
|
-
|
|
22
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23
|
-
|
|
24
|
-
// append to string if non-empty
|
|
25
|
-
function _pad(str, pad) {
|
|
26
|
-
return str.length ? str + pad : str;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
// Extend given object's with other objects' properties, overriding existing ones if necessary
|
|
30
|
-
function _extend(dst) {
|
|
31
|
-
for (var _len = arguments.length, sources = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
32
|
-
sources[_key - 1] = arguments[_key];
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
if (dst && sources) {
|
|
36
|
-
var _loop = function _loop(src) {
|
|
37
|
-
if ((typeof src === 'undefined' ? 'undefined' : _typeof(src)) === 'object') {
|
|
38
|
-
Object.getOwnPropertyNames(src).forEach(function (key) {
|
|
39
|
-
dst[key] = src[key];
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
|
|
44
|
-
var _iteratorNormalCompletion = true;
|
|
45
|
-
var _didIteratorError = false;
|
|
46
|
-
var _iteratorError = undefined;
|
|
47
|
-
|
|
48
|
-
try {
|
|
49
|
-
for (var _iterator = sources[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
50
|
-
var src = _step.value;
|
|
51
|
-
|
|
52
|
-
_loop(src);
|
|
53
|
-
}
|
|
54
|
-
} catch (err) {
|
|
55
|
-
_didIteratorError = true;
|
|
56
|
-
_iteratorError = err;
|
|
57
|
-
} finally {
|
|
58
|
-
try {
|
|
59
|
-
if (!_iteratorNormalCompletion && _iterator.return) {
|
|
60
|
-
_iterator.return();
|
|
61
|
-
}
|
|
62
|
-
} finally {
|
|
63
|
-
if (_didIteratorError) {
|
|
64
|
-
throw _iteratorError;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
return dst;
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
// get whether object is a plain object
|
|
74
|
-
function _isPlainObject(obj) {
|
|
75
|
-
return obj && obj.constructor.prototype === Object.prototype;
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
// get whether object is an array
|
|
79
|
-
function _isArray(obj) {
|
|
80
|
-
return obj && obj.constructor.prototype === Array.prototype;
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
// clone given item
|
|
84
|
-
function _clone(src) {
|
|
85
|
-
if (!src) {
|
|
86
|
-
return src;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
if (typeof src.clone === 'function') {
|
|
90
|
-
return src.clone();
|
|
91
|
-
} else if (_isPlainObject(src) || _isArray(src)) {
|
|
92
|
-
var ret = new src.constructor();
|
|
93
|
-
|
|
94
|
-
Object.getOwnPropertyNames(src).forEach(function (key) {
|
|
95
|
-
if (typeof src[key] !== 'function') {
|
|
96
|
-
ret[key] = _clone(src[key]);
|
|
97
|
-
}
|
|
98
|
-
});
|
|
99
|
-
|
|
100
|
-
return ret;
|
|
101
|
-
} else {
|
|
102
|
-
return JSON.parse(JSON.stringify(src));
|
|
103
|
-
}
|
|
104
|
-
};
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* Register a value type handler
|
|
108
|
-
*
|
|
109
|
-
* Note: this will override any existing handler registered for this value type.
|
|
110
|
-
*/
|
|
111
|
-
function _registerValueHandler(handlers, type, handler) {
|
|
112
|
-
var typeofType = typeof type === 'undefined' ? 'undefined' : _typeof(type);
|
|
113
|
-
|
|
114
|
-
if (typeofType !== 'function' && typeofType !== 'string') {
|
|
115
|
-
throw new Error("type must be a class constructor or string");
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
if (typeof handler !== 'function') {
|
|
119
|
-
throw new Error("handler must be a function");
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
var _iteratorNormalCompletion2 = true;
|
|
123
|
-
var _didIteratorError2 = false;
|
|
124
|
-
var _iteratorError2 = undefined;
|
|
125
|
-
|
|
126
|
-
try {
|
|
127
|
-
for (var _iterator2 = handlers[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
|
|
128
|
-
var typeHandler = _step2.value;
|
|
129
|
-
|
|
130
|
-
if (typeHandler.type === type) {
|
|
131
|
-
typeHandler.handler = handler;
|
|
132
|
-
|
|
133
|
-
return;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
} catch (err) {
|
|
137
|
-
_didIteratorError2 = true;
|
|
138
|
-
_iteratorError2 = err;
|
|
139
|
-
} finally {
|
|
140
|
-
try {
|
|
141
|
-
if (!_iteratorNormalCompletion2 && _iterator2.return) {
|
|
142
|
-
_iterator2.return();
|
|
143
|
-
}
|
|
144
|
-
} finally {
|
|
145
|
-
if (_didIteratorError2) {
|
|
146
|
-
throw _iteratorError2;
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
handlers.push({
|
|
152
|
-
type: type,
|
|
153
|
-
handler: handler
|
|
154
|
-
});
|
|
155
|
-
};
|
|
156
|
-
|
|
157
|
-
/**
|
|
158
|
-
* Get value type handler for given type
|
|
159
|
-
*/
|
|
160
|
-
function getValueHandler(value, localHandlers, globalHandlers) {
|
|
161
|
-
return _getValueHandler(value, localHandlers) || _getValueHandler(value, globalHandlers);
|
|
162
|
-
};
|
|
163
|
-
|
|
164
|
-
function _getValueHandler(value, handlers) {
|
|
165
|
-
for (var i = 0; i < handlers.length; i++) {
|
|
166
|
-
var typeHandler = handlers[i];
|
|
167
|
-
// if type is a string then use `typeof` or else use `instanceof`
|
|
168
|
-
if ((typeof value === 'undefined' ? 'undefined' : _typeof(value)) === typeHandler.type || typeof typeHandler.type !== 'string' && value instanceof typeHandler.type) {
|
|
169
|
-
return typeHandler.handler;
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
};
|
|
173
|
-
|
|
174
|
-
/**
|
|
175
|
-
* Build base squel classes and methods
|
|
176
|
-
*/
|
|
177
|
-
function _buildSquel() {
|
|
178
|
-
var flavour = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
|
|
179
|
-
|
|
180
|
-
var cls = {
|
|
181
|
-
// Get whether obj is a query builder
|
|
182
|
-
isSquelBuilder: function isSquelBuilder(obj) {
|
|
183
|
-
return obj && !!obj._toParamString;
|
|
184
|
-
}
|
|
185
|
-
};
|
|
186
|
-
|
|
187
|
-
// Get whether nesting should be applied for given item
|
|
188
|
-
var _shouldApplyNesting = function _shouldApplyNesting(obj) {
|
|
189
|
-
return !cls.isSquelBuilder(obj) || !obj.options.rawNesting;
|
|
190
|
-
};
|
|
191
|
-
|
|
192
|
-
// default query builder options
|
|
193
|
-
cls.DefaultQueryBuilderOptions = {
|
|
194
|
-
// If true then table names will be rendered inside quotes. The quote character used is configurable via the nameQuoteCharacter option.
|
|
195
|
-
autoQuoteTableNames: false,
|
|
196
|
-
// If true then field names will rendered inside quotes. The quote character used is configurable via the nameQuoteCharacter option.
|
|
197
|
-
autoQuoteFieldNames: false,
|
|
198
|
-
// If true then alias names will rendered inside quotes. The quote character used is configurable via the `tableAliasQuoteCharacter` and `fieldAliasQuoteCharacter` options.
|
|
199
|
-
autoQuoteAliasNames: true,
|
|
200
|
-
// If true then table alias names will rendered after AS keyword.
|
|
201
|
-
useAsForTableAliasNames: false,
|
|
202
|
-
// The quote character used for when quoting table and field names
|
|
203
|
-
nameQuoteCharacter: '`',
|
|
204
|
-
// The quote character used for when quoting table alias names
|
|
205
|
-
tableAliasQuoteCharacter: '`',
|
|
206
|
-
// The quote character used for when quoting table alias names
|
|
207
|
-
fieldAliasQuoteCharacter: '"',
|
|
208
|
-
// Custom value handlers where key is the value type and the value is the handler function
|
|
209
|
-
valueHandlers: [],
|
|
210
|
-
// Character used to represent a parameter value
|
|
211
|
-
parameterCharacter: '?',
|
|
212
|
-
// Numbered parameters returned from toParam() as $1, $2, etc.
|
|
213
|
-
numberedParameters: false,
|
|
214
|
-
// Numbered parameters prefix character(s)
|
|
215
|
-
numberedParametersPrefix: '$',
|
|
216
|
-
// Numbered parameters start at this number.
|
|
217
|
-
numberedParametersStartAt: 1,
|
|
218
|
-
// If true then replaces all single quotes within strings. The replacement string used is configurable via the `singleQuoteReplacement` option.
|
|
219
|
-
replaceSingleQuotes: false,
|
|
220
|
-
// The string to replace single quotes with in query strings
|
|
221
|
-
singleQuoteReplacement: '\'\'',
|
|
222
|
-
// String used to join individual blocks in a query when it's stringified
|
|
223
|
-
separator: ' ',
|
|
224
|
-
// Function for formatting string values prior to insertion into query string
|
|
225
|
-
stringFormatter: null,
|
|
226
|
-
// Whether to prevent the addition of brackets () when nesting this query builder's output
|
|
227
|
-
rawNesting: false
|
|
228
|
-
};
|
|
229
|
-
|
|
230
|
-
// Global custom value handlers for all instances of builder
|
|
231
|
-
cls.globalValueHandlers = [];
|
|
232
|
-
|
|
233
|
-
/*
|
|
234
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
235
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
236
|
-
# Custom value types
|
|
237
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
238
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
239
|
-
*/
|
|
240
|
-
|
|
241
|
-
// Register a new value handler
|
|
242
|
-
cls.registerValueHandler = function (type, handler) {
|
|
243
|
-
_registerValueHandler(cls.globalValueHandlers, type, handler);
|
|
244
|
-
};
|
|
245
|
-
|
|
246
|
-
/*
|
|
247
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
248
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
249
|
-
# Base classes
|
|
250
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
251
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
252
|
-
*/
|
|
253
|
-
|
|
254
|
-
// Base class for cloneable builders
|
|
255
|
-
cls.Cloneable = function () {
|
|
256
|
-
function _class() {
|
|
257
|
-
_classCallCheck(this, _class);
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
_createClass(_class, [{
|
|
261
|
-
key: 'clone',
|
|
262
|
-
|
|
263
|
-
/**
|
|
264
|
-
* Clone this builder
|
|
265
|
-
*/
|
|
266
|
-
value: function clone() {
|
|
267
|
-
var newInstance = new this.constructor();
|
|
268
|
-
|
|
269
|
-
return _extend(newInstance, _clone(_extend({}, this)));
|
|
270
|
-
}
|
|
271
|
-
}]);
|
|
272
|
-
|
|
273
|
-
return _class;
|
|
274
|
-
}();
|
|
275
|
-
|
|
276
|
-
// Base class for all builders
|
|
277
|
-
cls.BaseBuilder = function (_cls$Cloneable) {
|
|
278
|
-
_inherits(_class2, _cls$Cloneable);
|
|
279
|
-
|
|
280
|
-
/**
|
|
281
|
-
* Constructor.
|
|
282
|
-
* this.param {Object} options Overriding one or more of `cls.DefaultQueryBuilderOptions`.
|
|
283
|
-
*/
|
|
284
|
-
function _class2(options) {
|
|
285
|
-
_classCallCheck(this, _class2);
|
|
286
|
-
|
|
287
|
-
var _this = _possibleConstructorReturn(this, (_class2.__proto__ || Object.getPrototypeOf(_class2)).call(this));
|
|
288
|
-
|
|
289
|
-
var defaults = JSON.parse(JSON.stringify(cls.DefaultQueryBuilderOptions));
|
|
290
|
-
// for function values, etc we need to manually copy
|
|
291
|
-
['stringFormatter'].forEach(function (p) {
|
|
292
|
-
defaults[p] = cls.DefaultQueryBuilderOptions[p];
|
|
293
|
-
});
|
|
294
|
-
|
|
295
|
-
_this.options = _extend({}, defaults, options);
|
|
296
|
-
return _this;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
/**
|
|
300
|
-
* Register a custom value handler for this builder instance.
|
|
301
|
-
*
|
|
302
|
-
* Note: this will override any globally registered handler for this value type.
|
|
303
|
-
*/
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
_createClass(_class2, [{
|
|
307
|
-
key: 'registerValueHandler',
|
|
308
|
-
value: function registerValueHandler(type, handler) {
|
|
309
|
-
_registerValueHandler(this.options.valueHandlers, type, handler);
|
|
310
|
-
return this;
|
|
311
|
-
}
|
|
312
|
-
|
|
313
|
-
/**
|
|
314
|
-
* Sanitize given expression.
|
|
315
|
-
*/
|
|
316
|
-
|
|
317
|
-
}, {
|
|
318
|
-
key: '_sanitizeExpression',
|
|
319
|
-
value: function _sanitizeExpression(expr) {
|
|
320
|
-
// If it's not a base builder instance
|
|
321
|
-
if (!cls.isSquelBuilder(expr)) {
|
|
322
|
-
// It must then be a string
|
|
323
|
-
if (typeof expr !== "string") {
|
|
324
|
-
throw new Error("expression must be a string or builder instance");
|
|
325
|
-
}
|
|
326
|
-
}
|
|
327
|
-
|
|
328
|
-
return expr;
|
|
329
|
-
}
|
|
330
|
-
|
|
331
|
-
/**
|
|
332
|
-
* Sanitize the given name.
|
|
333
|
-
*
|
|
334
|
-
* The 'type' parameter is used to construct a meaningful error message in case validation fails.
|
|
335
|
-
*/
|
|
336
|
-
|
|
337
|
-
}, {
|
|
338
|
-
key: '_sanitizeName',
|
|
339
|
-
value: function _sanitizeName(value, type) {
|
|
340
|
-
if (typeof value !== "string") {
|
|
341
|
-
throw new Error(type + ' must be a string');
|
|
342
|
-
}
|
|
343
|
-
|
|
344
|
-
return value;
|
|
345
|
-
}
|
|
346
|
-
}, {
|
|
347
|
-
key: '_sanitizeField',
|
|
348
|
-
value: function _sanitizeField(item) {
|
|
349
|
-
if (!cls.isSquelBuilder(item)) {
|
|
350
|
-
item = this._sanitizeName(item, "field name");
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
return item;
|
|
354
|
-
}
|
|
355
|
-
}, {
|
|
356
|
-
key: '_sanitizeBaseBuilder',
|
|
357
|
-
value: function _sanitizeBaseBuilder(item) {
|
|
358
|
-
if (cls.isSquelBuilder(item)) {
|
|
359
|
-
return item;
|
|
360
|
-
}
|
|
361
|
-
|
|
362
|
-
throw new Error("must be a builder instance");
|
|
363
|
-
}
|
|
364
|
-
}, {
|
|
365
|
-
key: '_sanitizeTable',
|
|
366
|
-
value: function _sanitizeTable(item) {
|
|
367
|
-
if (typeof item !== "string") {
|
|
368
|
-
try {
|
|
369
|
-
item = this._sanitizeBaseBuilder(item);
|
|
370
|
-
} catch (e) {
|
|
371
|
-
throw new Error("table name must be a string or a builder");
|
|
372
|
-
}
|
|
373
|
-
} else {
|
|
374
|
-
item = this._sanitizeName(item, 'table');
|
|
375
|
-
}
|
|
376
|
-
|
|
377
|
-
return item;
|
|
378
|
-
}
|
|
379
|
-
}, {
|
|
380
|
-
key: '_sanitizeTableAlias',
|
|
381
|
-
value: function _sanitizeTableAlias(item) {
|
|
382
|
-
return this._sanitizeName(item, "table alias");
|
|
383
|
-
}
|
|
384
|
-
}, {
|
|
385
|
-
key: '_sanitizeFieldAlias',
|
|
386
|
-
value: function _sanitizeFieldAlias(item) {
|
|
387
|
-
return this._sanitizeName(item, "field alias");
|
|
388
|
-
}
|
|
389
|
-
|
|
390
|
-
// Sanitize the given limit/offset value.
|
|
391
|
-
|
|
392
|
-
}, {
|
|
393
|
-
key: '_sanitizeLimitOffset',
|
|
394
|
-
value: function _sanitizeLimitOffset(value) {
|
|
395
|
-
value = parseInt(value);
|
|
396
|
-
|
|
397
|
-
if (0 > value || isNaN(value)) {
|
|
398
|
-
throw new Error("limit/offset must be >= 0");
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
return value;
|
|
402
|
-
}
|
|
403
|
-
|
|
404
|
-
// Santize the given field value
|
|
405
|
-
|
|
406
|
-
}, {
|
|
407
|
-
key: '_sanitizeValue',
|
|
408
|
-
value: function _sanitizeValue(item) {
|
|
409
|
-
var itemType = typeof item === 'undefined' ? 'undefined' : _typeof(item);
|
|
410
|
-
|
|
411
|
-
if (null === item) {
|
|
412
|
-
// null is allowed
|
|
413
|
-
} else if ("string" === itemType || "number" === itemType || "boolean" === itemType) {
|
|
414
|
-
// primitives are allowed
|
|
415
|
-
} else if (cls.isSquelBuilder(item)) {
|
|
416
|
-
// Builders allowed
|
|
417
|
-
} else {
|
|
418
|
-
var typeIsValid = !!getValueHandler(item, this.options.valueHandlers, cls.globalValueHandlers);
|
|
419
|
-
|
|
420
|
-
if (!typeIsValid) {
|
|
421
|
-
throw new Error("field value must be a string, number, boolean, null or one of the registered custom value types");
|
|
422
|
-
}
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
return item;
|
|
426
|
-
}
|
|
427
|
-
|
|
428
|
-
// Escape a string value, e.g. escape quotes and other characters within it.
|
|
429
|
-
|
|
430
|
-
}, {
|
|
431
|
-
key: '_escapeValue',
|
|
432
|
-
value: function _escapeValue(value) {
|
|
433
|
-
return this.options.replaceSingleQuotes && value ? value.replace(/\'/g, this.options.singleQuoteReplacement) : value;
|
|
434
|
-
}
|
|
435
|
-
}, {
|
|
436
|
-
key: '_formatTableName',
|
|
437
|
-
value: function _formatTableName(item) {
|
|
438
|
-
if (this.options.autoQuoteTableNames) {
|
|
439
|
-
var quoteChar = this.options.nameQuoteCharacter;
|
|
440
|
-
|
|
441
|
-
item = '' + quoteChar + item + quoteChar;
|
|
442
|
-
}
|
|
443
|
-
|
|
444
|
-
return item;
|
|
445
|
-
}
|
|
446
|
-
}, {
|
|
447
|
-
key: '_formatFieldAlias',
|
|
448
|
-
value: function _formatFieldAlias(item) {
|
|
449
|
-
if (this.options.autoQuoteAliasNames) {
|
|
450
|
-
var quoteChar = this.options.fieldAliasQuoteCharacter;
|
|
451
|
-
|
|
452
|
-
item = '' + quoteChar + item + quoteChar;
|
|
453
|
-
}
|
|
454
|
-
|
|
455
|
-
return item;
|
|
456
|
-
}
|
|
457
|
-
}, {
|
|
458
|
-
key: '_formatTableAlias',
|
|
459
|
-
value: function _formatTableAlias(item) {
|
|
460
|
-
if (this.options.autoQuoteAliasNames) {
|
|
461
|
-
var quoteChar = this.options.tableAliasQuoteCharacter;
|
|
462
|
-
|
|
463
|
-
item = '' + quoteChar + item + quoteChar;
|
|
464
|
-
}
|
|
465
|
-
|
|
466
|
-
return this.options.useAsForTableAliasNames ? 'AS ' + item : item;
|
|
467
|
-
}
|
|
468
|
-
}, {
|
|
469
|
-
key: '_formatFieldName',
|
|
470
|
-
value: function _formatFieldName(item) {
|
|
471
|
-
var formattingOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
472
|
-
|
|
473
|
-
if (this.options.autoQuoteFieldNames) {
|
|
474
|
-
var quoteChar = this.options.nameQuoteCharacter;
|
|
475
|
-
|
|
476
|
-
if (formattingOptions.ignorePeriodsForFieldNameQuotes) {
|
|
477
|
-
// a.b.c -> `a.b.c`
|
|
478
|
-
item = '' + quoteChar + item + quoteChar;
|
|
479
|
-
} else {
|
|
480
|
-
// a.b.c -> `a`.`b`.`c`
|
|
481
|
-
item = item.split('.').map(function (v) {
|
|
482
|
-
// treat '*' as special case (#79)
|
|
483
|
-
return '*' === v ? v : '' + quoteChar + v + quoteChar;
|
|
484
|
-
}).join('.');
|
|
485
|
-
}
|
|
486
|
-
}
|
|
487
|
-
|
|
488
|
-
return item;
|
|
489
|
-
}
|
|
490
|
-
|
|
491
|
-
// Format the given custom value
|
|
492
|
-
|
|
493
|
-
}, {
|
|
494
|
-
key: '_formatCustomValue',
|
|
495
|
-
value: function _formatCustomValue(value, asParam, formattingOptions) {
|
|
496
|
-
// user defined custom handlers takes precedence
|
|
497
|
-
var customHandler = getValueHandler(value, this.options.valueHandlers, cls.globalValueHandlers);
|
|
498
|
-
|
|
499
|
-
// use the custom handler if available
|
|
500
|
-
if (customHandler) {
|
|
501
|
-
value = customHandler(value, asParam, formattingOptions);
|
|
502
|
-
|
|
503
|
-
// custom value handler can instruct caller not to process returned value
|
|
504
|
-
if (value && value.rawNesting) {
|
|
505
|
-
return {
|
|
506
|
-
formatted: true,
|
|
507
|
-
rawNesting: true,
|
|
508
|
-
value: value.value
|
|
509
|
-
};
|
|
510
|
-
}
|
|
511
|
-
}
|
|
512
|
-
|
|
513
|
-
return {
|
|
514
|
-
formatted: !!customHandler,
|
|
515
|
-
value: value
|
|
516
|
-
|
|
517
|
-
};
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
/**
|
|
521
|
-
* Format given value for inclusion into parameter values array.
|
|
522
|
-
*/
|
|
523
|
-
|
|
524
|
-
}, {
|
|
525
|
-
key: '_formatValueForParamArray',
|
|
526
|
-
value: function _formatValueForParamArray(value) {
|
|
527
|
-
var _this2 = this;
|
|
528
|
-
|
|
529
|
-
var formattingOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
530
|
-
|
|
531
|
-
if (_isArray(value)) {
|
|
532
|
-
return value.map(function (v) {
|
|
533
|
-
return _this2._formatValueForParamArray(v, formattingOptions);
|
|
534
|
-
});
|
|
535
|
-
} else {
|
|
536
|
-
return this._formatCustomValue(value, true, formattingOptions).value;
|
|
537
|
-
}
|
|
538
|
-
}
|
|
539
|
-
|
|
540
|
-
/**
|
|
541
|
-
* Format the given field value for inclusion into the query string
|
|
542
|
-
*/
|
|
543
|
-
|
|
544
|
-
}, {
|
|
545
|
-
key: '_formatValueForQueryString',
|
|
546
|
-
value: function _formatValueForQueryString(initialValue) {
|
|
547
|
-
var _this3 = this;
|
|
548
|
-
|
|
549
|
-
var formattingOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
550
|
-
|
|
551
|
-
// maybe we have a cusotm value handler
|
|
552
|
-
var _formatCustomValue2 = this._formatCustomValue(initialValue, false, formattingOptions),
|
|
553
|
-
rawNesting = _formatCustomValue2.rawNesting,
|
|
554
|
-
formatted = _formatCustomValue2.formatted,
|
|
555
|
-
value = _formatCustomValue2.value;
|
|
556
|
-
|
|
557
|
-
// if formatting took place then return it directly
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
if (formatted) {
|
|
561
|
-
if (rawNesting) {
|
|
562
|
-
return value;
|
|
563
|
-
} else {
|
|
564
|
-
return this._applyNestingFormatting(value, _shouldApplyNesting(initialValue));
|
|
565
|
-
}
|
|
566
|
-
}
|
|
567
|
-
|
|
568
|
-
// if it's an array then format each element separately
|
|
569
|
-
if (_isArray(value)) {
|
|
570
|
-
value = value.map(function (v) {
|
|
571
|
-
return _this3._formatValueForQueryString(v);
|
|
572
|
-
});
|
|
573
|
-
|
|
574
|
-
value = this._applyNestingFormatting(value.join(', '), _shouldApplyNesting(value));
|
|
575
|
-
} else {
|
|
576
|
-
var typeofValue = typeof value === 'undefined' ? 'undefined' : _typeof(value);
|
|
577
|
-
|
|
578
|
-
if (null === value) {
|
|
579
|
-
value = "NULL";
|
|
580
|
-
} else if (typeofValue === "boolean") {
|
|
581
|
-
value = value ? "TRUE" : "FALSE";
|
|
582
|
-
} else if (cls.isSquelBuilder(value)) {
|
|
583
|
-
value = this._applyNestingFormatting(value.toString(), _shouldApplyNesting(value));
|
|
584
|
-
} else if (typeofValue !== "number") {
|
|
585
|
-
// if it's a string and we have custom string formatting turned on then use that
|
|
586
|
-
if ('string' === typeofValue && this.options.stringFormatter) {
|
|
587
|
-
return this.options.stringFormatter(value);
|
|
588
|
-
}
|
|
589
|
-
|
|
590
|
-
if (formattingOptions.dontQuote) {
|
|
591
|
-
value = '' + value;
|
|
592
|
-
} else {
|
|
593
|
-
var escapedValue = this._escapeValue(value);
|
|
594
|
-
|
|
595
|
-
value = '\'' + escapedValue + '\'';
|
|
596
|
-
}
|
|
597
|
-
}
|
|
598
|
-
}
|
|
599
|
-
|
|
600
|
-
return value;
|
|
601
|
-
}
|
|
602
|
-
}, {
|
|
603
|
-
key: '_applyNestingFormatting',
|
|
604
|
-
value: function _applyNestingFormatting(str) {
|
|
605
|
-
var nesting = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
606
|
-
|
|
607
|
-
if (str && typeof str === 'string' && nesting && !this.options.rawNesting) {
|
|
608
|
-
// apply brackets if they're not already existing
|
|
609
|
-
var alreadyHasBrackets = '(' === str.charAt(0) && ')' === str.charAt(str.length - 1);
|
|
610
|
-
|
|
611
|
-
if (alreadyHasBrackets) {
|
|
612
|
-
// check that it's the form "((x)..(y))" rather than "(x)..(y)"
|
|
613
|
-
var idx = 0,
|
|
614
|
-
open = 1;
|
|
615
|
-
|
|
616
|
-
while (str.length - 1 > ++idx) {
|
|
617
|
-
var c = str.charAt(idx);
|
|
618
|
-
|
|
619
|
-
if ('(' === c) {
|
|
620
|
-
open++;
|
|
621
|
-
} else if (')' === c) {
|
|
622
|
-
open--;
|
|
623
|
-
if (1 > open) {
|
|
624
|
-
alreadyHasBrackets = false;
|
|
625
|
-
|
|
626
|
-
break;
|
|
627
|
-
}
|
|
628
|
-
}
|
|
629
|
-
}
|
|
630
|
-
}
|
|
631
|
-
|
|
632
|
-
if (!alreadyHasBrackets) {
|
|
633
|
-
str = '(' + str + ')';
|
|
634
|
-
}
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
return str;
|
|
638
|
-
}
|
|
639
|
-
|
|
640
|
-
/**
|
|
641
|
-
* Build given string and its corresponding parameter values into
|
|
642
|
-
* output.
|
|
643
|
-
*
|
|
644
|
-
* @param {String} str
|
|
645
|
-
* @param {Array} values
|
|
646
|
-
* @param {Object} [options] Additional options.
|
|
647
|
-
* @param {Boolean} [options.buildParameterized] Whether to build paramterized string. Default is false.
|
|
648
|
-
* @param {Boolean} [options.nested] Whether this expression is nested within another.
|
|
649
|
-
* @param {Boolean} [options.formattingOptions] Formatting options for values in query string.
|
|
650
|
-
* @return {Object}
|
|
651
|
-
*/
|
|
652
|
-
|
|
653
|
-
}, {
|
|
654
|
-
key: '_buildString',
|
|
655
|
-
value: function _buildString(str, values) {
|
|
656
|
-
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
657
|
-
var nested = options.nested,
|
|
658
|
-
buildParameterized = options.buildParameterized,
|
|
659
|
-
formattingOptions = options.formattingOptions;
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
values = values || [];
|
|
663
|
-
str = str || '';
|
|
664
|
-
|
|
665
|
-
var formattedStr = '',
|
|
666
|
-
curValue = -1,
|
|
667
|
-
formattedValues = [];
|
|
668
|
-
|
|
669
|
-
var paramChar = this.options.parameterCharacter;
|
|
670
|
-
|
|
671
|
-
var idx = 0;
|
|
672
|
-
|
|
673
|
-
while (str.length > idx) {
|
|
674
|
-
// param char?
|
|
675
|
-
if (str.substr(idx, paramChar.length) === paramChar) {
|
|
676
|
-
var value = values[++curValue];
|
|
677
|
-
|
|
678
|
-
if (buildParameterized) {
|
|
679
|
-
if (cls.isSquelBuilder(value)) {
|
|
680
|
-
var ret = value._toParamString({
|
|
681
|
-
buildParameterized: buildParameterized,
|
|
682
|
-
nested: true
|
|
683
|
-
});
|
|
684
|
-
|
|
685
|
-
formattedStr += ret.text;
|
|
686
|
-
ret.values.forEach(function (value) {
|
|
687
|
-
return formattedValues.push(value);
|
|
688
|
-
});
|
|
689
|
-
} else {
|
|
690
|
-
value = this._formatValueForParamArray(value, formattingOptions);
|
|
691
|
-
|
|
692
|
-
if (_isArray(value)) {
|
|
693
|
-
// Array(6) -> "(??, ??, ??, ??, ??, ??)"
|
|
694
|
-
var tmpStr = value.map(function () {
|
|
695
|
-
return paramChar;
|
|
696
|
-
}).join(', ');
|
|
697
|
-
|
|
698
|
-
formattedStr += '(' + tmpStr + ')';
|
|
699
|
-
|
|
700
|
-
value.forEach(function (val) {
|
|
701
|
-
return formattedValues.push(val);
|
|
702
|
-
});
|
|
703
|
-
} else {
|
|
704
|
-
formattedStr += paramChar;
|
|
705
|
-
|
|
706
|
-
formattedValues.push(value);
|
|
707
|
-
}
|
|
708
|
-
}
|
|
709
|
-
} else {
|
|
710
|
-
formattedStr += this._formatValueForQueryString(value, formattingOptions);
|
|
711
|
-
}
|
|
712
|
-
|
|
713
|
-
idx += paramChar.length;
|
|
714
|
-
} else {
|
|
715
|
-
formattedStr += str.charAt(idx);
|
|
716
|
-
|
|
717
|
-
idx++;
|
|
718
|
-
}
|
|
719
|
-
}
|
|
720
|
-
|
|
721
|
-
return {
|
|
722
|
-
text: this._applyNestingFormatting(formattedStr, !!nested),
|
|
723
|
-
values: formattedValues
|
|
724
|
-
};
|
|
725
|
-
}
|
|
726
|
-
|
|
727
|
-
/**
|
|
728
|
-
* Build all given strings and their corresponding parameter values into
|
|
729
|
-
* output.
|
|
730
|
-
*
|
|
731
|
-
* @param {Array} strings
|
|
732
|
-
* @param {Array} strValues array of value arrays corresponding to each string.
|
|
733
|
-
* @param {Object} [options] Additional options.
|
|
734
|
-
* @param {Boolean} [options.buildParameterized] Whether to build paramterized string. Default is false.
|
|
735
|
-
* @param {Boolean} [options.nested] Whether this expression is nested within another.
|
|
736
|
-
* @return {Object}
|
|
737
|
-
*/
|
|
738
|
-
|
|
739
|
-
}, {
|
|
740
|
-
key: '_buildManyStrings',
|
|
741
|
-
value: function _buildManyStrings(strings, strValues) {
|
|
742
|
-
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
743
|
-
|
|
744
|
-
var totalStr = [],
|
|
745
|
-
totalValues = [];
|
|
746
|
-
|
|
747
|
-
for (var idx = 0; strings.length > idx; ++idx) {
|
|
748
|
-
var inputString = strings[idx],
|
|
749
|
-
inputValues = strValues[idx];
|
|
750
|
-
|
|
751
|
-
var _buildString2 = this._buildString(inputString, inputValues, {
|
|
752
|
-
buildParameterized: options.buildParameterized,
|
|
753
|
-
nested: false
|
|
754
|
-
}),
|
|
755
|
-
text = _buildString2.text,
|
|
756
|
-
values = _buildString2.values;
|
|
757
|
-
|
|
758
|
-
totalStr.push(text);
|
|
759
|
-
values.forEach(function (value) {
|
|
760
|
-
return totalValues.push(value);
|
|
761
|
-
});
|
|
762
|
-
}
|
|
763
|
-
|
|
764
|
-
totalStr = totalStr.join(this.options.separator);
|
|
765
|
-
|
|
766
|
-
return {
|
|
767
|
-
text: totalStr.length ? this._applyNestingFormatting(totalStr, !!options.nested) : '',
|
|
768
|
-
values: totalValues
|
|
769
|
-
};
|
|
770
|
-
}
|
|
771
|
-
|
|
772
|
-
/**
|
|
773
|
-
* Get parameterized representation of this instance.
|
|
774
|
-
*
|
|
775
|
-
* @param {Object} [options] Options.
|
|
776
|
-
* @param {Boolean} [options.buildParameterized] Whether to build paramterized string. Default is false.
|
|
777
|
-
* @param {Boolean} [options.nested] Whether this expression is nested within another.
|
|
778
|
-
* @return {Object}
|
|
779
|
-
*/
|
|
780
|
-
|
|
781
|
-
}, {
|
|
782
|
-
key: '_toParamString',
|
|
783
|
-
value: function _toParamString(options) {
|
|
784
|
-
throw new Error('Not yet implemented');
|
|
785
|
-
}
|
|
786
|
-
|
|
787
|
-
/**
|
|
788
|
-
* Get the expression string.
|
|
789
|
-
* @return {String}
|
|
790
|
-
*/
|
|
791
|
-
|
|
792
|
-
}, {
|
|
793
|
-
key: 'toString',
|
|
794
|
-
value: function toString() {
|
|
795
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
796
|
-
|
|
797
|
-
return this._toParamString(options).text;
|
|
798
|
-
}
|
|
799
|
-
|
|
800
|
-
/**
|
|
801
|
-
* Get the parameterized expression string.
|
|
802
|
-
* @return {Object}
|
|
803
|
-
*/
|
|
804
|
-
|
|
805
|
-
}, {
|
|
806
|
-
key: 'toParam',
|
|
807
|
-
value: function toParam() {
|
|
808
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
809
|
-
|
|
810
|
-
return this._toParamString(_extend({}, options, {
|
|
811
|
-
buildParameterized: true
|
|
812
|
-
}));
|
|
813
|
-
}
|
|
814
|
-
}]);
|
|
815
|
-
|
|
816
|
-
return _class2;
|
|
817
|
-
}(cls.Cloneable);
|
|
818
|
-
|
|
819
|
-
/*
|
|
820
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
821
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
822
|
-
# cls.Expressions
|
|
823
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
824
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
825
|
-
*/
|
|
826
|
-
|
|
827
|
-
/**
|
|
828
|
-
* An SQL expression builder.
|
|
829
|
-
*
|
|
830
|
-
* SQL expressions are used in WHERE and ON clauses to filter data by various criteria.
|
|
831
|
-
*
|
|
832
|
-
* Expressions can be nested. Nested expression contains can themselves
|
|
833
|
-
* contain nested expressions. When rendered a nested expression will be
|
|
834
|
-
* fully contained within brackets.
|
|
835
|
-
*
|
|
836
|
-
* All the build methods in this object return the object instance for chained method calling purposes.
|
|
837
|
-
*/
|
|
838
|
-
cls.Expression = function (_cls$BaseBuilder) {
|
|
839
|
-
_inherits(_class3, _cls$BaseBuilder);
|
|
840
|
-
|
|
841
|
-
// Initialise the expression.
|
|
842
|
-
function _class3(options) {
|
|
843
|
-
_classCallCheck(this, _class3);
|
|
844
|
-
|
|
845
|
-
var _this4 = _possibleConstructorReturn(this, (_class3.__proto__ || Object.getPrototypeOf(_class3)).call(this, options));
|
|
846
|
-
|
|
847
|
-
_this4._nodes = [];
|
|
848
|
-
return _this4;
|
|
849
|
-
}
|
|
850
|
-
|
|
851
|
-
// Combine the current expression with the given expression using the intersection operator (AND).
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
_createClass(_class3, [{
|
|
855
|
-
key: 'and',
|
|
856
|
-
value: function and(expr) {
|
|
857
|
-
for (var _len2 = arguments.length, params = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
858
|
-
params[_key2 - 1] = arguments[_key2];
|
|
859
|
-
}
|
|
860
|
-
|
|
861
|
-
expr = this._sanitizeExpression(expr);
|
|
862
|
-
|
|
863
|
-
this._nodes.push({
|
|
864
|
-
type: 'AND',
|
|
865
|
-
expr: expr,
|
|
866
|
-
para: params
|
|
867
|
-
});
|
|
868
|
-
|
|
869
|
-
return this;
|
|
870
|
-
}
|
|
871
|
-
|
|
872
|
-
// Combine the current expression with the given expression using the union operator (OR).
|
|
873
|
-
|
|
874
|
-
}, {
|
|
875
|
-
key: 'or',
|
|
876
|
-
value: function or(expr) {
|
|
877
|
-
for (var _len3 = arguments.length, params = Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
|
|
878
|
-
params[_key3 - 1] = arguments[_key3];
|
|
879
|
-
}
|
|
880
|
-
|
|
881
|
-
expr = this._sanitizeExpression(expr);
|
|
882
|
-
|
|
883
|
-
this._nodes.push({
|
|
884
|
-
type: 'OR',
|
|
885
|
-
expr: expr,
|
|
886
|
-
para: params
|
|
887
|
-
});
|
|
888
|
-
|
|
889
|
-
return this;
|
|
890
|
-
}
|
|
891
|
-
}, {
|
|
892
|
-
key: '_toParamString',
|
|
893
|
-
value: function _toParamString() {
|
|
894
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
895
|
-
|
|
896
|
-
var totalStr = [],
|
|
897
|
-
totalValues = [];
|
|
898
|
-
|
|
899
|
-
var _iteratorNormalCompletion3 = true;
|
|
900
|
-
var _didIteratorError3 = false;
|
|
901
|
-
var _iteratorError3 = undefined;
|
|
902
|
-
|
|
903
|
-
try {
|
|
904
|
-
for (var _iterator3 = this._nodes[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) {
|
|
905
|
-
var node = _step3.value;
|
|
906
|
-
var type = node.type,
|
|
907
|
-
expr = node.expr,
|
|
908
|
-
para = node.para;
|
|
909
|
-
|
|
910
|
-
var _ref = cls.isSquelBuilder(expr) ? expr._toParamString({
|
|
911
|
-
buildParameterized: options.buildParameterized,
|
|
912
|
-
nested: true
|
|
913
|
-
}) : this._buildString(expr, para, {
|
|
914
|
-
buildParameterized: options.buildParameterized
|
|
915
|
-
}),
|
|
916
|
-
text = _ref.text,
|
|
917
|
-
values = _ref.values;
|
|
918
|
-
|
|
919
|
-
if (totalStr.length) {
|
|
920
|
-
totalStr.push(type);
|
|
921
|
-
}
|
|
922
|
-
|
|
923
|
-
totalStr.push(text);
|
|
924
|
-
values.forEach(function (value) {
|
|
925
|
-
return totalValues.push(value);
|
|
926
|
-
});
|
|
927
|
-
}
|
|
928
|
-
} catch (err) {
|
|
929
|
-
_didIteratorError3 = true;
|
|
930
|
-
_iteratorError3 = err;
|
|
931
|
-
} finally {
|
|
932
|
-
try {
|
|
933
|
-
if (!_iteratorNormalCompletion3 && _iterator3.return) {
|
|
934
|
-
_iterator3.return();
|
|
935
|
-
}
|
|
936
|
-
} finally {
|
|
937
|
-
if (_didIteratorError3) {
|
|
938
|
-
throw _iteratorError3;
|
|
939
|
-
}
|
|
940
|
-
}
|
|
941
|
-
}
|
|
942
|
-
|
|
943
|
-
totalStr = totalStr.join(' ');
|
|
944
|
-
|
|
945
|
-
return {
|
|
946
|
-
text: this._applyNestingFormatting(totalStr, !!options.nested),
|
|
947
|
-
values: totalValues
|
|
948
|
-
};
|
|
949
|
-
}
|
|
950
|
-
}]);
|
|
951
|
-
|
|
952
|
-
return _class3;
|
|
953
|
-
}(cls.BaseBuilder);
|
|
954
|
-
|
|
955
|
-
/*
|
|
956
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
957
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
958
|
-
# cls.Case
|
|
959
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
960
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
961
|
-
*/
|
|
962
|
-
|
|
963
|
-
/**
|
|
964
|
-
* An SQL CASE expression builder.
|
|
965
|
-
*
|
|
966
|
-
* SQL cases are used to select proper values based on specific criteria.
|
|
967
|
-
*/
|
|
968
|
-
cls.Case = function (_cls$BaseBuilder2) {
|
|
969
|
-
_inherits(_class4, _cls$BaseBuilder2);
|
|
970
|
-
|
|
971
|
-
function _class4(fieldName) {
|
|
972
|
-
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
973
|
-
|
|
974
|
-
_classCallCheck(this, _class4);
|
|
975
|
-
|
|
976
|
-
var _this5 = _possibleConstructorReturn(this, (_class4.__proto__ || Object.getPrototypeOf(_class4)).call(this, options));
|
|
977
|
-
|
|
978
|
-
if (_isPlainObject(fieldName)) {
|
|
979
|
-
options = fieldName;
|
|
980
|
-
|
|
981
|
-
fieldName = null;
|
|
982
|
-
}
|
|
983
|
-
|
|
984
|
-
if (fieldName) {
|
|
985
|
-
_this5._fieldName = _this5._sanitizeField(fieldName);
|
|
986
|
-
}
|
|
987
|
-
|
|
988
|
-
_this5.options = _extend({}, cls.DefaultQueryBuilderOptions, options);
|
|
989
|
-
|
|
990
|
-
_this5._cases = [];
|
|
991
|
-
_this5._elseValue = null;
|
|
992
|
-
return _this5;
|
|
993
|
-
}
|
|
994
|
-
|
|
995
|
-
_createClass(_class4, [{
|
|
996
|
-
key: 'when',
|
|
997
|
-
value: function when(expression) {
|
|
998
|
-
for (var _len4 = arguments.length, values = Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
|
|
999
|
-
values[_key4 - 1] = arguments[_key4];
|
|
1000
|
-
}
|
|
1001
|
-
|
|
1002
|
-
this._cases.unshift({
|
|
1003
|
-
expression: expression,
|
|
1004
|
-
values: values || []
|
|
1005
|
-
});
|
|
1006
|
-
|
|
1007
|
-
return this;
|
|
1008
|
-
}
|
|
1009
|
-
}, {
|
|
1010
|
-
key: 'then',
|
|
1011
|
-
value: function then(result) {
|
|
1012
|
-
if (this._cases.length == 0) {
|
|
1013
|
-
throw new Error("when() needs to be called first");
|
|
1014
|
-
}
|
|
1015
|
-
|
|
1016
|
-
this._cases[0].result = result;
|
|
1017
|
-
|
|
1018
|
-
return this;
|
|
1019
|
-
}
|
|
1020
|
-
}, {
|
|
1021
|
-
key: 'else',
|
|
1022
|
-
value: function _else(elseValue) {
|
|
1023
|
-
this._elseValue = elseValue;
|
|
1024
|
-
|
|
1025
|
-
return this;
|
|
1026
|
-
}
|
|
1027
|
-
}, {
|
|
1028
|
-
key: '_toParamString',
|
|
1029
|
-
value: function _toParamString() {
|
|
1030
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1031
|
-
|
|
1032
|
-
var totalStr = '',
|
|
1033
|
-
totalValues = [];
|
|
1034
|
-
|
|
1035
|
-
var _iteratorNormalCompletion4 = true;
|
|
1036
|
-
var _didIteratorError4 = false;
|
|
1037
|
-
var _iteratorError4 = undefined;
|
|
1038
|
-
|
|
1039
|
-
try {
|
|
1040
|
-
for (var _iterator4 = this._cases[Symbol.iterator](), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) {
|
|
1041
|
-
var _ref2 = _step4.value;
|
|
1042
|
-
var expression = _ref2.expression;
|
|
1043
|
-
var _values = _ref2.values;
|
|
1044
|
-
var result = _ref2.result;
|
|
1045
|
-
|
|
1046
|
-
totalStr = _pad(totalStr, ' ');
|
|
1047
|
-
|
|
1048
|
-
var ret = this._buildString(expression, _values, {
|
|
1049
|
-
buildParameterized: options.buildParameterized,
|
|
1050
|
-
nested: true
|
|
1051
|
-
});
|
|
1052
|
-
|
|
1053
|
-
totalStr += 'WHEN ' + ret.text + ' THEN ' + this._formatValueForQueryString(result);
|
|
1054
|
-
ret.values.forEach(function (value) {
|
|
1055
|
-
return totalValues.push(value);
|
|
1056
|
-
});
|
|
1057
|
-
}
|
|
1058
|
-
} catch (err) {
|
|
1059
|
-
_didIteratorError4 = true;
|
|
1060
|
-
_iteratorError4 = err;
|
|
1061
|
-
} finally {
|
|
1062
|
-
try {
|
|
1063
|
-
if (!_iteratorNormalCompletion4 && _iterator4.return) {
|
|
1064
|
-
_iterator4.return();
|
|
1065
|
-
}
|
|
1066
|
-
} finally {
|
|
1067
|
-
if (_didIteratorError4) {
|
|
1068
|
-
throw _iteratorError4;
|
|
1069
|
-
}
|
|
1070
|
-
}
|
|
1071
|
-
}
|
|
1072
|
-
|
|
1073
|
-
if (totalStr.length) {
|
|
1074
|
-
totalStr += ' ELSE ' + this._formatValueForQueryString(this._elseValue) + ' END';
|
|
1075
|
-
|
|
1076
|
-
if (this._fieldName) {
|
|
1077
|
-
totalStr = this._fieldName + ' ' + totalStr;
|
|
1078
|
-
}
|
|
1079
|
-
|
|
1080
|
-
totalStr = 'CASE ' + totalStr;
|
|
1081
|
-
} else {
|
|
1082
|
-
totalStr = this._formatValueForQueryString(this._elseValue);
|
|
1083
|
-
}
|
|
1084
|
-
|
|
1085
|
-
return {
|
|
1086
|
-
text: totalStr,
|
|
1087
|
-
values: totalValues
|
|
1088
|
-
};
|
|
1089
|
-
}
|
|
1090
|
-
}]);
|
|
1091
|
-
|
|
1092
|
-
return _class4;
|
|
1093
|
-
}(cls.BaseBuilder);
|
|
1094
|
-
|
|
1095
|
-
/*
|
|
1096
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
1097
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
1098
|
-
# Building blocks
|
|
1099
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
1100
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
1101
|
-
*/
|
|
1102
|
-
|
|
1103
|
-
/*
|
|
1104
|
-
# A building block represents a single build-step within a query building process.
|
|
1105
|
-
#
|
|
1106
|
-
# Query builders consist of one or more building blocks which get run in a particular order. Building blocks can
|
|
1107
|
-
# optionally specify methods to expose through the query builder interface. They can access all the input data for
|
|
1108
|
-
# the query builder and manipulate it as necessary, as well as append to the final query string output.
|
|
1109
|
-
#
|
|
1110
|
-
# If you wish to customize how queries get built or add proprietary query phrases and content then it is recommended
|
|
1111
|
-
# that you do so using one or more custom building blocks.
|
|
1112
|
-
#
|
|
1113
|
-
# Original idea posted in https://github.com/hiddentao/export/issues/10#issuecomment-15016427
|
|
1114
|
-
*/
|
|
1115
|
-
cls.Block = function (_cls$BaseBuilder3) {
|
|
1116
|
-
_inherits(_class5, _cls$BaseBuilder3);
|
|
1117
|
-
|
|
1118
|
-
function _class5(options) {
|
|
1119
|
-
_classCallCheck(this, _class5);
|
|
1120
|
-
|
|
1121
|
-
return _possibleConstructorReturn(this, (_class5.__proto__ || Object.getPrototypeOf(_class5)).call(this, options));
|
|
1122
|
-
}
|
|
1123
|
-
|
|
1124
|
-
/**
|
|
1125
|
-
# Get input methods to expose within the query builder.
|
|
1126
|
-
#
|
|
1127
|
-
# By default all methods except the following get returned:
|
|
1128
|
-
# methods prefixed with _
|
|
1129
|
-
# constructor and toString()
|
|
1130
|
-
#
|
|
1131
|
-
# @return Object key -> function pairs
|
|
1132
|
-
*/
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
_createClass(_class5, [{
|
|
1136
|
-
key: 'exposedMethods',
|
|
1137
|
-
value: function exposedMethods() {
|
|
1138
|
-
var ret = {};
|
|
1139
|
-
|
|
1140
|
-
var obj = this;
|
|
1141
|
-
|
|
1142
|
-
while (obj) {
|
|
1143
|
-
Object.getOwnPropertyNames(obj).forEach(function (prop) {
|
|
1144
|
-
if ('constructor' !== prop && typeof obj[prop] === "function" && prop.charAt(0) !== '_' && !cls.Block.prototype[prop]) {
|
|
1145
|
-
ret[prop] = obj[prop];
|
|
1146
|
-
}
|
|
1147
|
-
});
|
|
1148
|
-
|
|
1149
|
-
obj = Object.getPrototypeOf(obj);
|
|
1150
|
-
};
|
|
1151
|
-
|
|
1152
|
-
return ret;
|
|
1153
|
-
}
|
|
1154
|
-
}]);
|
|
1155
|
-
|
|
1156
|
-
return _class5;
|
|
1157
|
-
}(cls.BaseBuilder);
|
|
1158
|
-
|
|
1159
|
-
// A fixed string which always gets output
|
|
1160
|
-
cls.StringBlock = function (_cls$Block) {
|
|
1161
|
-
_inherits(_class6, _cls$Block);
|
|
1162
|
-
|
|
1163
|
-
function _class6(options, str) {
|
|
1164
|
-
_classCallCheck(this, _class6);
|
|
1165
|
-
|
|
1166
|
-
var _this7 = _possibleConstructorReturn(this, (_class6.__proto__ || Object.getPrototypeOf(_class6)).call(this, options));
|
|
1167
|
-
|
|
1168
|
-
_this7._str = str;
|
|
1169
|
-
return _this7;
|
|
1170
|
-
}
|
|
1171
|
-
|
|
1172
|
-
_createClass(_class6, [{
|
|
1173
|
-
key: '_toParamString',
|
|
1174
|
-
value: function _toParamString() {
|
|
1175
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1176
|
-
|
|
1177
|
-
return {
|
|
1178
|
-
text: this._str,
|
|
1179
|
-
values: []
|
|
1180
|
-
};
|
|
1181
|
-
}
|
|
1182
|
-
}]);
|
|
1183
|
-
|
|
1184
|
-
return _class6;
|
|
1185
|
-
}(cls.Block);
|
|
1186
|
-
|
|
1187
|
-
// A function string block
|
|
1188
|
-
cls.FunctionBlock = function (_cls$Block2) {
|
|
1189
|
-
_inherits(_class7, _cls$Block2);
|
|
1190
|
-
|
|
1191
|
-
function _class7(options) {
|
|
1192
|
-
_classCallCheck(this, _class7);
|
|
1193
|
-
|
|
1194
|
-
var _this8 = _possibleConstructorReturn(this, (_class7.__proto__ || Object.getPrototypeOf(_class7)).call(this, options));
|
|
1195
|
-
|
|
1196
|
-
_this8._strings = [];
|
|
1197
|
-
_this8._values = [];
|
|
1198
|
-
return _this8;
|
|
1199
|
-
}
|
|
1200
|
-
|
|
1201
|
-
_createClass(_class7, [{
|
|
1202
|
-
key: 'function',
|
|
1203
|
-
value: function _function(str) {
|
|
1204
|
-
this._strings.push(str);
|
|
1205
|
-
|
|
1206
|
-
for (var _len5 = arguments.length, values = Array(_len5 > 1 ? _len5 - 1 : 0), _key5 = 1; _key5 < _len5; _key5++) {
|
|
1207
|
-
values[_key5 - 1] = arguments[_key5];
|
|
1208
|
-
}
|
|
1209
|
-
|
|
1210
|
-
this._values.push(values);
|
|
1211
|
-
}
|
|
1212
|
-
}, {
|
|
1213
|
-
key: '_toParamString',
|
|
1214
|
-
value: function _toParamString() {
|
|
1215
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1216
|
-
|
|
1217
|
-
return this._buildManyStrings(this._strings, this._values, options);
|
|
1218
|
-
}
|
|
1219
|
-
}]);
|
|
1220
|
-
|
|
1221
|
-
return _class7;
|
|
1222
|
-
}(cls.Block);
|
|
1223
|
-
|
|
1224
|
-
// value handler for FunctionValueBlock objects
|
|
1225
|
-
cls.registerValueHandler(cls.FunctionBlock, function (value) {
|
|
1226
|
-
var asParam = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
1227
|
-
|
|
1228
|
-
return asParam ? value.toParam() : value.toString();
|
|
1229
|
-
});
|
|
1230
|
-
|
|
1231
|
-
/*
|
|
1232
|
-
# Table specifier base class
|
|
1233
|
-
*/
|
|
1234
|
-
cls.AbstractTableBlock = function (_cls$Block3) {
|
|
1235
|
-
_inherits(_class8, _cls$Block3);
|
|
1236
|
-
|
|
1237
|
-
/**
|
|
1238
|
-
* @param {Boolean} [options.singleTable] If true then only allow one table spec.
|
|
1239
|
-
* @param {String} [options.prefix] String prefix for output.
|
|
1240
|
-
*/
|
|
1241
|
-
function _class8(options, prefix) {
|
|
1242
|
-
_classCallCheck(this, _class8);
|
|
1243
|
-
|
|
1244
|
-
var _this9 = _possibleConstructorReturn(this, (_class8.__proto__ || Object.getPrototypeOf(_class8)).call(this, options));
|
|
1245
|
-
|
|
1246
|
-
_this9._tables = [];
|
|
1247
|
-
return _this9;
|
|
1248
|
-
}
|
|
1249
|
-
|
|
1250
|
-
/**
|
|
1251
|
-
# Update given table.
|
|
1252
|
-
#
|
|
1253
|
-
# An alias may also be specified for the table.
|
|
1254
|
-
#
|
|
1255
|
-
# Concrete subclasses should provide a method which calls this
|
|
1256
|
-
*/
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
_createClass(_class8, [{
|
|
1260
|
-
key: '_table',
|
|
1261
|
-
value: function _table(table) {
|
|
1262
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
1263
|
-
|
|
1264
|
-
alias = alias ? this._sanitizeTableAlias(alias) : alias;
|
|
1265
|
-
table = this._sanitizeTable(table);
|
|
1266
|
-
|
|
1267
|
-
if (this.options.singleTable) {
|
|
1268
|
-
this._tables = [];
|
|
1269
|
-
}
|
|
1270
|
-
|
|
1271
|
-
this._tables.push({
|
|
1272
|
-
table: table,
|
|
1273
|
-
alias: alias
|
|
1274
|
-
});
|
|
1275
|
-
}
|
|
1276
|
-
|
|
1277
|
-
// get whether a table has been set
|
|
1278
|
-
|
|
1279
|
-
}, {
|
|
1280
|
-
key: '_hasTable',
|
|
1281
|
-
value: function _hasTable() {
|
|
1282
|
-
return 0 < this._tables.length;
|
|
1283
|
-
}
|
|
1284
|
-
|
|
1285
|
-
/**
|
|
1286
|
-
* @override
|
|
1287
|
-
*/
|
|
1288
|
-
|
|
1289
|
-
}, {
|
|
1290
|
-
key: '_toParamString',
|
|
1291
|
-
value: function _toParamString() {
|
|
1292
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1293
|
-
|
|
1294
|
-
var totalStr = '',
|
|
1295
|
-
totalValues = [];
|
|
1296
|
-
|
|
1297
|
-
if (this._hasTable()) {
|
|
1298
|
-
// retrieve the parameterised queries
|
|
1299
|
-
var _iteratorNormalCompletion5 = true;
|
|
1300
|
-
var _didIteratorError5 = false;
|
|
1301
|
-
var _iteratorError5 = undefined;
|
|
1302
|
-
|
|
1303
|
-
try {
|
|
1304
|
-
for (var _iterator5 = this._tables[Symbol.iterator](), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) {
|
|
1305
|
-
var _ref3 = _step5.value;
|
|
1306
|
-
var table = _ref3.table;
|
|
1307
|
-
var alias = _ref3.alias;
|
|
1308
|
-
|
|
1309
|
-
totalStr = _pad(totalStr, ', ');
|
|
1310
|
-
|
|
1311
|
-
var tableStr = void 0;
|
|
1312
|
-
|
|
1313
|
-
if (cls.isSquelBuilder(table)) {
|
|
1314
|
-
var _table$_toParamString = table._toParamString({
|
|
1315
|
-
buildParameterized: options.buildParameterized,
|
|
1316
|
-
nested: true
|
|
1317
|
-
}),
|
|
1318
|
-
text = _table$_toParamString.text,
|
|
1319
|
-
values = _table$_toParamString.values;
|
|
1320
|
-
|
|
1321
|
-
tableStr = text;
|
|
1322
|
-
values.forEach(function (value) {
|
|
1323
|
-
return totalValues.push(value);
|
|
1324
|
-
});
|
|
1325
|
-
} else {
|
|
1326
|
-
tableStr = this._formatTableName(table);
|
|
1327
|
-
}
|
|
1328
|
-
|
|
1329
|
-
if (alias) {
|
|
1330
|
-
tableStr += ' ' + this._formatTableAlias(alias);
|
|
1331
|
-
}
|
|
1332
|
-
|
|
1333
|
-
totalStr += tableStr;
|
|
1334
|
-
}
|
|
1335
|
-
} catch (err) {
|
|
1336
|
-
_didIteratorError5 = true;
|
|
1337
|
-
_iteratorError5 = err;
|
|
1338
|
-
} finally {
|
|
1339
|
-
try {
|
|
1340
|
-
if (!_iteratorNormalCompletion5 && _iterator5.return) {
|
|
1341
|
-
_iterator5.return();
|
|
1342
|
-
}
|
|
1343
|
-
} finally {
|
|
1344
|
-
if (_didIteratorError5) {
|
|
1345
|
-
throw _iteratorError5;
|
|
1346
|
-
}
|
|
1347
|
-
}
|
|
1348
|
-
}
|
|
1349
|
-
|
|
1350
|
-
if (this.options.prefix) {
|
|
1351
|
-
totalStr = this.options.prefix + ' ' + totalStr;
|
|
1352
|
-
}
|
|
1353
|
-
}
|
|
1354
|
-
|
|
1355
|
-
return {
|
|
1356
|
-
text: totalStr,
|
|
1357
|
-
values: totalValues
|
|
1358
|
-
};
|
|
1359
|
-
}
|
|
1360
|
-
}]);
|
|
1361
|
-
|
|
1362
|
-
return _class8;
|
|
1363
|
-
}(cls.Block);
|
|
1364
|
-
|
|
1365
|
-
// target table for DELETE queries, DELETE <??> FROM
|
|
1366
|
-
cls.TargetTableBlock = function (_cls$AbstractTableBlo) {
|
|
1367
|
-
_inherits(_class9, _cls$AbstractTableBlo);
|
|
1368
|
-
|
|
1369
|
-
function _class9() {
|
|
1370
|
-
_classCallCheck(this, _class9);
|
|
1371
|
-
|
|
1372
|
-
return _possibleConstructorReturn(this, (_class9.__proto__ || Object.getPrototypeOf(_class9)).apply(this, arguments));
|
|
1373
|
-
}
|
|
1374
|
-
|
|
1375
|
-
_createClass(_class9, [{
|
|
1376
|
-
key: 'target',
|
|
1377
|
-
value: function target(table) {
|
|
1378
|
-
this._table(table);
|
|
1379
|
-
}
|
|
1380
|
-
}]);
|
|
1381
|
-
|
|
1382
|
-
return _class9;
|
|
1383
|
-
}(cls.AbstractTableBlock);
|
|
1384
|
-
|
|
1385
|
-
// Update Table
|
|
1386
|
-
cls.UpdateTableBlock = function (_cls$AbstractTableBlo2) {
|
|
1387
|
-
_inherits(_class10, _cls$AbstractTableBlo2);
|
|
1388
|
-
|
|
1389
|
-
function _class10() {
|
|
1390
|
-
_classCallCheck(this, _class10);
|
|
1391
|
-
|
|
1392
|
-
return _possibleConstructorReturn(this, (_class10.__proto__ || Object.getPrototypeOf(_class10)).apply(this, arguments));
|
|
1393
|
-
}
|
|
1394
|
-
|
|
1395
|
-
_createClass(_class10, [{
|
|
1396
|
-
key: 'table',
|
|
1397
|
-
value: function table(_table2) {
|
|
1398
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
1399
|
-
|
|
1400
|
-
this._table(_table2, alias);
|
|
1401
|
-
}
|
|
1402
|
-
}, {
|
|
1403
|
-
key: '_toParamString',
|
|
1404
|
-
value: function _toParamString() {
|
|
1405
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1406
|
-
|
|
1407
|
-
if (!this._hasTable()) {
|
|
1408
|
-
throw new Error("table() needs to be called");
|
|
1409
|
-
}
|
|
1410
|
-
|
|
1411
|
-
return _get(_class10.prototype.__proto__ || Object.getPrototypeOf(_class10.prototype), '_toParamString', this).call(this, options);
|
|
1412
|
-
}
|
|
1413
|
-
}]);
|
|
1414
|
-
|
|
1415
|
-
return _class10;
|
|
1416
|
-
}(cls.AbstractTableBlock);
|
|
1417
|
-
|
|
1418
|
-
// FROM table
|
|
1419
|
-
cls.FromTableBlock = function (_cls$AbstractTableBlo3) {
|
|
1420
|
-
_inherits(_class11, _cls$AbstractTableBlo3);
|
|
1421
|
-
|
|
1422
|
-
function _class11(options) {
|
|
1423
|
-
_classCallCheck(this, _class11);
|
|
1424
|
-
|
|
1425
|
-
return _possibleConstructorReturn(this, (_class11.__proto__ || Object.getPrototypeOf(_class11)).call(this, _extend({}, options, {
|
|
1426
|
-
prefix: 'FROM'
|
|
1427
|
-
})));
|
|
1428
|
-
}
|
|
1429
|
-
|
|
1430
|
-
_createClass(_class11, [{
|
|
1431
|
-
key: 'from',
|
|
1432
|
-
value: function from(table) {
|
|
1433
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
1434
|
-
|
|
1435
|
-
this._table(table, alias);
|
|
1436
|
-
}
|
|
1437
|
-
}]);
|
|
1438
|
-
|
|
1439
|
-
return _class11;
|
|
1440
|
-
}(cls.AbstractTableBlock);
|
|
1441
|
-
|
|
1442
|
-
// INTO table
|
|
1443
|
-
cls.IntoTableBlock = function (_cls$AbstractTableBlo4) {
|
|
1444
|
-
_inherits(_class12, _cls$AbstractTableBlo4);
|
|
1445
|
-
|
|
1446
|
-
function _class12(options) {
|
|
1447
|
-
_classCallCheck(this, _class12);
|
|
1448
|
-
|
|
1449
|
-
return _possibleConstructorReturn(this, (_class12.__proto__ || Object.getPrototypeOf(_class12)).call(this, _extend({}, options, {
|
|
1450
|
-
prefix: 'INTO',
|
|
1451
|
-
singleTable: true
|
|
1452
|
-
})));
|
|
1453
|
-
}
|
|
1454
|
-
|
|
1455
|
-
_createClass(_class12, [{
|
|
1456
|
-
key: 'into',
|
|
1457
|
-
value: function into(table) {
|
|
1458
|
-
this._table(table);
|
|
1459
|
-
}
|
|
1460
|
-
}, {
|
|
1461
|
-
key: '_toParamString',
|
|
1462
|
-
value: function _toParamString() {
|
|
1463
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1464
|
-
|
|
1465
|
-
if (!this._hasTable()) {
|
|
1466
|
-
throw new Error("into() needs to be called");
|
|
1467
|
-
}
|
|
1468
|
-
|
|
1469
|
-
return _get(_class12.prototype.__proto__ || Object.getPrototypeOf(_class12.prototype), '_toParamString', this).call(this, options);
|
|
1470
|
-
}
|
|
1471
|
-
}]);
|
|
1472
|
-
|
|
1473
|
-
return _class12;
|
|
1474
|
-
}(cls.AbstractTableBlock);
|
|
1475
|
-
|
|
1476
|
-
// (SELECT) Get field
|
|
1477
|
-
cls.GetFieldBlock = function (_cls$Block4) {
|
|
1478
|
-
_inherits(_class13, _cls$Block4);
|
|
1479
|
-
|
|
1480
|
-
function _class13(options) {
|
|
1481
|
-
_classCallCheck(this, _class13);
|
|
1482
|
-
|
|
1483
|
-
var _this14 = _possibleConstructorReturn(this, (_class13.__proto__ || Object.getPrototypeOf(_class13)).call(this, options));
|
|
1484
|
-
|
|
1485
|
-
_this14._fields = [];
|
|
1486
|
-
return _this14;
|
|
1487
|
-
}
|
|
1488
|
-
|
|
1489
|
-
/**
|
|
1490
|
-
# Add the given fields to the final result set.
|
|
1491
|
-
#
|
|
1492
|
-
# The parameter is an Object containing field names (or database functions) as the keys and aliases for the fields
|
|
1493
|
-
# as the values. If the value for a key is null then no alias is set for that field.
|
|
1494
|
-
#
|
|
1495
|
-
# Internally this method simply calls the field() method of this block to add each individual field.
|
|
1496
|
-
#
|
|
1497
|
-
# options.ignorePeriodsForFieldNameQuotes - whether to ignore period (.) when automatically quoting the field name
|
|
1498
|
-
*/
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
_createClass(_class13, [{
|
|
1502
|
-
key: 'fields',
|
|
1503
|
-
value: function fields(_fields) {
|
|
1504
|
-
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
1505
|
-
|
|
1506
|
-
if (_isArray(_fields)) {
|
|
1507
|
-
var _iteratorNormalCompletion6 = true;
|
|
1508
|
-
var _didIteratorError6 = false;
|
|
1509
|
-
var _iteratorError6 = undefined;
|
|
1510
|
-
|
|
1511
|
-
try {
|
|
1512
|
-
for (var _iterator6 = _fields[Symbol.iterator](), _step6; !(_iteratorNormalCompletion6 = (_step6 = _iterator6.next()).done); _iteratorNormalCompletion6 = true) {
|
|
1513
|
-
var field = _step6.value;
|
|
1514
|
-
|
|
1515
|
-
this.field(field, null, options);
|
|
1516
|
-
}
|
|
1517
|
-
} catch (err) {
|
|
1518
|
-
_didIteratorError6 = true;
|
|
1519
|
-
_iteratorError6 = err;
|
|
1520
|
-
} finally {
|
|
1521
|
-
try {
|
|
1522
|
-
if (!_iteratorNormalCompletion6 && _iterator6.return) {
|
|
1523
|
-
_iterator6.return();
|
|
1524
|
-
}
|
|
1525
|
-
} finally {
|
|
1526
|
-
if (_didIteratorError6) {
|
|
1527
|
-
throw _iteratorError6;
|
|
1528
|
-
}
|
|
1529
|
-
}
|
|
1530
|
-
}
|
|
1531
|
-
} else {
|
|
1532
|
-
for (var _field2 in _fields) {
|
|
1533
|
-
var alias = _fields[_field2];
|
|
1534
|
-
|
|
1535
|
-
this.field(_field2, alias, options);
|
|
1536
|
-
}
|
|
1537
|
-
}
|
|
1538
|
-
}
|
|
1539
|
-
|
|
1540
|
-
/**
|
|
1541
|
-
# Add the given field to the final result set.
|
|
1542
|
-
#
|
|
1543
|
-
# The 'field' parameter does not necessarily have to be a fieldname. It can use database functions too,
|
|
1544
|
-
# e.g. DATE_FORMAT(a.started, "%H")
|
|
1545
|
-
#
|
|
1546
|
-
# An alias may also be specified for this field.
|
|
1547
|
-
#
|
|
1548
|
-
# options.ignorePeriodsForFieldNameQuotes - whether to ignore period (.) when automatically quoting the field name
|
|
1549
|
-
*/
|
|
1550
|
-
|
|
1551
|
-
}, {
|
|
1552
|
-
key: 'field',
|
|
1553
|
-
value: function field(_field) {
|
|
1554
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
1555
|
-
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
1556
|
-
|
|
1557
|
-
alias = alias ? this._sanitizeFieldAlias(alias) : alias;
|
|
1558
|
-
_field = this._sanitizeField(_field);
|
|
1559
|
-
|
|
1560
|
-
// if field-alias combo already present then don't add
|
|
1561
|
-
var existingField = this._fields.filter(function (f) {
|
|
1562
|
-
return f.name === _field && f.alias === alias;
|
|
1563
|
-
});
|
|
1564
|
-
if (existingField.length) {
|
|
1565
|
-
return this;
|
|
1566
|
-
}
|
|
1567
|
-
|
|
1568
|
-
this._fields.push({
|
|
1569
|
-
name: _field,
|
|
1570
|
-
alias: alias,
|
|
1571
|
-
options: options
|
|
1572
|
-
});
|
|
1573
|
-
}
|
|
1574
|
-
}, {
|
|
1575
|
-
key: '_toParamString',
|
|
1576
|
-
value: function _toParamString() {
|
|
1577
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1578
|
-
var queryBuilder = options.queryBuilder,
|
|
1579
|
-
buildParameterized = options.buildParameterized;
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
var totalStr = '',
|
|
1583
|
-
totalValues = [];
|
|
1584
|
-
|
|
1585
|
-
var _iteratorNormalCompletion7 = true;
|
|
1586
|
-
var _didIteratorError7 = false;
|
|
1587
|
-
var _iteratorError7 = undefined;
|
|
1588
|
-
|
|
1589
|
-
try {
|
|
1590
|
-
for (var _iterator7 = this._fields[Symbol.iterator](), _step7; !(_iteratorNormalCompletion7 = (_step7 = _iterator7.next()).done); _iteratorNormalCompletion7 = true) {
|
|
1591
|
-
var field = _step7.value;
|
|
1592
|
-
|
|
1593
|
-
totalStr = _pad(totalStr, ", ");
|
|
1594
|
-
|
|
1595
|
-
var name = field.name,
|
|
1596
|
-
alias = field.alias,
|
|
1597
|
-
_options = field.options;
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
if (typeof name === 'string') {
|
|
1601
|
-
totalStr += this._formatFieldName(name, _options);
|
|
1602
|
-
} else {
|
|
1603
|
-
var ret = name._toParamString({
|
|
1604
|
-
nested: true,
|
|
1605
|
-
buildParameterized: buildParameterized
|
|
1606
|
-
});
|
|
1607
|
-
|
|
1608
|
-
totalStr += ret.text;
|
|
1609
|
-
ret.values.forEach(function (value) {
|
|
1610
|
-
return totalValues.push(value);
|
|
1611
|
-
});
|
|
1612
|
-
}
|
|
1613
|
-
|
|
1614
|
-
if (alias) {
|
|
1615
|
-
totalStr += ' AS ' + this._formatFieldAlias(alias);
|
|
1616
|
-
}
|
|
1617
|
-
}
|
|
1618
|
-
} catch (err) {
|
|
1619
|
-
_didIteratorError7 = true;
|
|
1620
|
-
_iteratorError7 = err;
|
|
1621
|
-
} finally {
|
|
1622
|
-
try {
|
|
1623
|
-
if (!_iteratorNormalCompletion7 && _iterator7.return) {
|
|
1624
|
-
_iterator7.return();
|
|
1625
|
-
}
|
|
1626
|
-
} finally {
|
|
1627
|
-
if (_didIteratorError7) {
|
|
1628
|
-
throw _iteratorError7;
|
|
1629
|
-
}
|
|
1630
|
-
}
|
|
1631
|
-
}
|
|
1632
|
-
|
|
1633
|
-
if (!totalStr.length) {
|
|
1634
|
-
// if select query and a table is set then all fields wanted
|
|
1635
|
-
var fromTableBlock = queryBuilder && queryBuilder.getBlock(cls.FromTableBlock);
|
|
1636
|
-
if (fromTableBlock && fromTableBlock._hasTable()) {
|
|
1637
|
-
totalStr = "*";
|
|
1638
|
-
}
|
|
1639
|
-
}
|
|
1640
|
-
|
|
1641
|
-
return {
|
|
1642
|
-
text: totalStr,
|
|
1643
|
-
values: totalValues
|
|
1644
|
-
};
|
|
1645
|
-
}
|
|
1646
|
-
}]);
|
|
1647
|
-
|
|
1648
|
-
return _class13;
|
|
1649
|
-
}(cls.Block);
|
|
1650
|
-
|
|
1651
|
-
// Base class for setting fields to values (used for INSERT and UPDATE queries)
|
|
1652
|
-
cls.AbstractSetFieldBlock = function (_cls$Block5) {
|
|
1653
|
-
_inherits(_class14, _cls$Block5);
|
|
1654
|
-
|
|
1655
|
-
function _class14(options) {
|
|
1656
|
-
_classCallCheck(this, _class14);
|
|
1657
|
-
|
|
1658
|
-
var _this15 = _possibleConstructorReturn(this, (_class14.__proto__ || Object.getPrototypeOf(_class14)).call(this, options));
|
|
1659
|
-
|
|
1660
|
-
_this15._reset();
|
|
1661
|
-
return _this15;
|
|
1662
|
-
}
|
|
1663
|
-
|
|
1664
|
-
_createClass(_class14, [{
|
|
1665
|
-
key: '_reset',
|
|
1666
|
-
value: function _reset() {
|
|
1667
|
-
this._fields = [];
|
|
1668
|
-
this._values = [[]];
|
|
1669
|
-
this._valueOptions = [[]];
|
|
1670
|
-
}
|
|
1671
|
-
|
|
1672
|
-
// Update the given field with the given value.
|
|
1673
|
-
// This will override any previously set value for the given field.
|
|
1674
|
-
|
|
1675
|
-
}, {
|
|
1676
|
-
key: '_set',
|
|
1677
|
-
value: function _set(field, value) {
|
|
1678
|
-
var valueOptions = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
1679
|
-
|
|
1680
|
-
if (this._values.length > 1) {
|
|
1681
|
-
throw new Error("Cannot set multiple rows of fields this way.");
|
|
1682
|
-
}
|
|
1683
|
-
|
|
1684
|
-
if (typeof value !== 'undefined') {
|
|
1685
|
-
value = this._sanitizeValue(value);
|
|
1686
|
-
}
|
|
1687
|
-
|
|
1688
|
-
field = this._sanitizeField(field);
|
|
1689
|
-
|
|
1690
|
-
// Explicity overwrite existing fields
|
|
1691
|
-
var index = this._fields.indexOf(field);
|
|
1692
|
-
|
|
1693
|
-
// if field not defined before
|
|
1694
|
-
if (-1 === index) {
|
|
1695
|
-
this._fields.push(field);
|
|
1696
|
-
index = this._fields.length - 1;
|
|
1697
|
-
}
|
|
1698
|
-
|
|
1699
|
-
this._values[0][index] = value;
|
|
1700
|
-
this._valueOptions[0][index] = valueOptions;
|
|
1701
|
-
}
|
|
1702
|
-
|
|
1703
|
-
// Insert fields based on the key/value pairs in the given object
|
|
1704
|
-
|
|
1705
|
-
}, {
|
|
1706
|
-
key: '_setFields',
|
|
1707
|
-
value: function _setFields(fields) {
|
|
1708
|
-
var valueOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
1709
|
-
|
|
1710
|
-
if ((typeof fields === 'undefined' ? 'undefined' : _typeof(fields)) !== 'object') {
|
|
1711
|
-
throw new Error("Expected an object but got " + (typeof fields === 'undefined' ? 'undefined' : _typeof(fields)));
|
|
1712
|
-
}
|
|
1713
|
-
|
|
1714
|
-
for (var field in fields) {
|
|
1715
|
-
this._set(field, fields[field], valueOptions);
|
|
1716
|
-
}
|
|
1717
|
-
}
|
|
1718
|
-
|
|
1719
|
-
// Insert multiple rows for the given fields. Accepts an array of objects.
|
|
1720
|
-
// This will override all previously set values for every field.
|
|
1721
|
-
|
|
1722
|
-
}, {
|
|
1723
|
-
key: '_setFieldsRows',
|
|
1724
|
-
value: function _setFieldsRows(fieldsRows) {
|
|
1725
|
-
var valueOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
1726
|
-
|
|
1727
|
-
if (!_isArray(fieldsRows)) {
|
|
1728
|
-
throw new Error("Expected an array of objects but got " + (typeof fieldsRows === 'undefined' ? 'undefined' : _typeof(fieldsRows)));
|
|
1729
|
-
}
|
|
1730
|
-
|
|
1731
|
-
// Reset the objects stored fields and values
|
|
1732
|
-
this._reset();
|
|
1733
|
-
|
|
1734
|
-
// for each row
|
|
1735
|
-
for (var i = 0; fieldsRows.length > i; ++i) {
|
|
1736
|
-
var fieldRow = fieldsRows[i];
|
|
1737
|
-
|
|
1738
|
-
// for each field
|
|
1739
|
-
for (var field in fieldRow) {
|
|
1740
|
-
var value = fieldRow[field];
|
|
1741
|
-
|
|
1742
|
-
field = this._sanitizeField(field);
|
|
1743
|
-
value = this._sanitizeValue(value);
|
|
1744
|
-
|
|
1745
|
-
var index = this._fields.indexOf(field);
|
|
1746
|
-
|
|
1747
|
-
if (0 < i && -1 === index) {
|
|
1748
|
-
throw new Error('All fields in subsequent rows must match the fields in the first row');
|
|
1749
|
-
}
|
|
1750
|
-
|
|
1751
|
-
// Add field only if it hasn't been added before
|
|
1752
|
-
if (-1 === index) {
|
|
1753
|
-
this._fields.push(field);
|
|
1754
|
-
index = this._fields.length - 1;
|
|
1755
|
-
}
|
|
1756
|
-
|
|
1757
|
-
// The first value added needs to add the array
|
|
1758
|
-
if (!_isArray(this._values[i])) {
|
|
1759
|
-
this._values[i] = [];
|
|
1760
|
-
this._valueOptions[i] = [];
|
|
1761
|
-
}
|
|
1762
|
-
|
|
1763
|
-
this._values[i][index] = value;
|
|
1764
|
-
this._valueOptions[i][index] = valueOptions;
|
|
1765
|
-
}
|
|
1766
|
-
}
|
|
1767
|
-
}
|
|
1768
|
-
}]);
|
|
1769
|
-
|
|
1770
|
-
return _class14;
|
|
1771
|
-
}(cls.Block);
|
|
1772
|
-
|
|
1773
|
-
// (UPDATE) SET field=value
|
|
1774
|
-
cls.SetFieldBlock = function (_cls$AbstractSetField) {
|
|
1775
|
-
_inherits(_class15, _cls$AbstractSetField);
|
|
1776
|
-
|
|
1777
|
-
function _class15() {
|
|
1778
|
-
_classCallCheck(this, _class15);
|
|
1779
|
-
|
|
1780
|
-
return _possibleConstructorReturn(this, (_class15.__proto__ || Object.getPrototypeOf(_class15)).apply(this, arguments));
|
|
1781
|
-
}
|
|
1782
|
-
|
|
1783
|
-
_createClass(_class15, [{
|
|
1784
|
-
key: 'set',
|
|
1785
|
-
value: function set(field, value, options) {
|
|
1786
|
-
this._set(field, value, options);
|
|
1787
|
-
}
|
|
1788
|
-
}, {
|
|
1789
|
-
key: 'setFields',
|
|
1790
|
-
value: function setFields(fields, valueOptions) {
|
|
1791
|
-
this._setFields(fields, valueOptions);
|
|
1792
|
-
}
|
|
1793
|
-
}, {
|
|
1794
|
-
key: '_toParamString',
|
|
1795
|
-
value: function _toParamString() {
|
|
1796
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1797
|
-
var buildParameterized = options.buildParameterized;
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
if (0 >= this._fields.length) {
|
|
1801
|
-
throw new Error("set() needs to be called");
|
|
1802
|
-
}
|
|
1803
|
-
|
|
1804
|
-
var totalStr = '',
|
|
1805
|
-
totalValues = [];
|
|
1806
|
-
|
|
1807
|
-
for (var i = 0; i < this._fields.length; ++i) {
|
|
1808
|
-
totalStr = _pad(totalStr, ', ');
|
|
1809
|
-
|
|
1810
|
-
var field = this._formatFieldName(this._fields[i]);
|
|
1811
|
-
var value = this._values[0][i];
|
|
1812
|
-
|
|
1813
|
-
// e.g. field can be an expression such as `count = count + 1`
|
|
1814
|
-
if (0 > field.indexOf('=')) {
|
|
1815
|
-
field = field + ' = ' + this.options.parameterCharacter;
|
|
1816
|
-
}
|
|
1817
|
-
|
|
1818
|
-
var ret = this._buildString(field, [value], {
|
|
1819
|
-
buildParameterized: buildParameterized,
|
|
1820
|
-
formattingOptions: this._valueOptions[0][i]
|
|
1821
|
-
});
|
|
1822
|
-
|
|
1823
|
-
totalStr += ret.text;
|
|
1824
|
-
ret.values.forEach(function (value) {
|
|
1825
|
-
return totalValues.push(value);
|
|
1826
|
-
});
|
|
1827
|
-
}
|
|
1828
|
-
|
|
1829
|
-
return {
|
|
1830
|
-
text: 'SET ' + totalStr,
|
|
1831
|
-
values: totalValues
|
|
1832
|
-
};
|
|
1833
|
-
}
|
|
1834
|
-
}]);
|
|
1835
|
-
|
|
1836
|
-
return _class15;
|
|
1837
|
-
}(cls.AbstractSetFieldBlock);
|
|
1838
|
-
|
|
1839
|
-
// (INSERT INTO) ... field ... value
|
|
1840
|
-
cls.InsertFieldValueBlock = function (_cls$AbstractSetField2) {
|
|
1841
|
-
_inherits(_class16, _cls$AbstractSetField2);
|
|
1842
|
-
|
|
1843
|
-
function _class16() {
|
|
1844
|
-
_classCallCheck(this, _class16);
|
|
1845
|
-
|
|
1846
|
-
return _possibleConstructorReturn(this, (_class16.__proto__ || Object.getPrototypeOf(_class16)).apply(this, arguments));
|
|
1847
|
-
}
|
|
1848
|
-
|
|
1849
|
-
_createClass(_class16, [{
|
|
1850
|
-
key: 'set',
|
|
1851
|
-
value: function set(field, value) {
|
|
1852
|
-
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
1853
|
-
|
|
1854
|
-
this._set(field, value, options);
|
|
1855
|
-
}
|
|
1856
|
-
}, {
|
|
1857
|
-
key: 'setFields',
|
|
1858
|
-
value: function setFields(fields, valueOptions) {
|
|
1859
|
-
this._setFields(fields, valueOptions);
|
|
1860
|
-
}
|
|
1861
|
-
}, {
|
|
1862
|
-
key: 'setFieldsRows',
|
|
1863
|
-
value: function setFieldsRows(fieldsRows, valueOptions) {
|
|
1864
|
-
this._setFieldsRows(fieldsRows, valueOptions);
|
|
1865
|
-
}
|
|
1866
|
-
}, {
|
|
1867
|
-
key: '_toParamString',
|
|
1868
|
-
value: function _toParamString() {
|
|
1869
|
-
var _this18 = this;
|
|
1870
|
-
|
|
1871
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1872
|
-
var buildParameterized = options.buildParameterized;
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
var fieldString = this._fields.map(function (f) {
|
|
1876
|
-
return _this18._formatFieldName(f);
|
|
1877
|
-
}).join(', ');
|
|
1878
|
-
|
|
1879
|
-
var valueStrings = [],
|
|
1880
|
-
totalValues = [];
|
|
1881
|
-
|
|
1882
|
-
for (var i = 0; i < this._values.length; ++i) {
|
|
1883
|
-
valueStrings[i] = '';
|
|
1884
|
-
|
|
1885
|
-
for (var j = 0; j < this._values[i].length; ++j) {
|
|
1886
|
-
var ret = this._buildString(this.options.parameterCharacter, [this._values[i][j]], {
|
|
1887
|
-
buildParameterized: buildParameterized,
|
|
1888
|
-
formattingOptions: this._valueOptions[i][j]
|
|
1889
|
-
});
|
|
1890
|
-
|
|
1891
|
-
ret.values.forEach(function (value) {
|
|
1892
|
-
return totalValues.push(value);
|
|
1893
|
-
});
|
|
1894
|
-
|
|
1895
|
-
valueStrings[i] = _pad(valueStrings[i], ', ');
|
|
1896
|
-
valueStrings[i] += ret.text;
|
|
1897
|
-
}
|
|
1898
|
-
}
|
|
1899
|
-
|
|
1900
|
-
return {
|
|
1901
|
-
text: fieldString.length ? '(' + fieldString + ') VALUES (' + valueStrings.join('), (') + ')' : '',
|
|
1902
|
-
values: totalValues
|
|
1903
|
-
};
|
|
1904
|
-
}
|
|
1905
|
-
}]);
|
|
1906
|
-
|
|
1907
|
-
return _class16;
|
|
1908
|
-
}(cls.AbstractSetFieldBlock);
|
|
1909
|
-
|
|
1910
|
-
// (INSERT INTO) ... field ... (SELECT ... FROM ...)
|
|
1911
|
-
cls.InsertFieldsFromQueryBlock = function (_cls$Block6) {
|
|
1912
|
-
_inherits(_class17, _cls$Block6);
|
|
1913
|
-
|
|
1914
|
-
function _class17(options) {
|
|
1915
|
-
_classCallCheck(this, _class17);
|
|
1916
|
-
|
|
1917
|
-
var _this19 = _possibleConstructorReturn(this, (_class17.__proto__ || Object.getPrototypeOf(_class17)).call(this, options));
|
|
1918
|
-
|
|
1919
|
-
_this19._fields = [];
|
|
1920
|
-
_this19._query = null;
|
|
1921
|
-
return _this19;
|
|
1922
|
-
}
|
|
1923
|
-
|
|
1924
|
-
_createClass(_class17, [{
|
|
1925
|
-
key: 'fromQuery',
|
|
1926
|
-
value: function fromQuery(fields, selectQuery) {
|
|
1927
|
-
var _this20 = this;
|
|
1928
|
-
|
|
1929
|
-
this._fields = fields.map(function (v) {
|
|
1930
|
-
return _this20._sanitizeField(v);
|
|
1931
|
-
});
|
|
1932
|
-
|
|
1933
|
-
this._query = this._sanitizeBaseBuilder(selectQuery);
|
|
1934
|
-
}
|
|
1935
|
-
}, {
|
|
1936
|
-
key: '_toParamString',
|
|
1937
|
-
value: function _toParamString() {
|
|
1938
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1939
|
-
|
|
1940
|
-
var totalStr = '',
|
|
1941
|
-
totalValues = [];
|
|
1942
|
-
|
|
1943
|
-
if (this._fields.length && this._query) {
|
|
1944
|
-
var _query$_toParamString = this._query._toParamString({
|
|
1945
|
-
buildParameterized: options.buildParameterized,
|
|
1946
|
-
nested: true
|
|
1947
|
-
}),
|
|
1948
|
-
text = _query$_toParamString.text,
|
|
1949
|
-
values = _query$_toParamString.values;
|
|
1950
|
-
|
|
1951
|
-
totalStr = '(' + this._fields.join(', ') + ') ' + this._applyNestingFormatting(text);
|
|
1952
|
-
totalValues = values;
|
|
1953
|
-
}
|
|
1954
|
-
|
|
1955
|
-
return {
|
|
1956
|
-
text: totalStr,
|
|
1957
|
-
values: totalValues
|
|
1958
|
-
};
|
|
1959
|
-
}
|
|
1960
|
-
}]);
|
|
1961
|
-
|
|
1962
|
-
return _class17;
|
|
1963
|
-
}(cls.Block);
|
|
1964
|
-
|
|
1965
|
-
// DISTINCT
|
|
1966
|
-
cls.DistinctBlock = function (_cls$Block7) {
|
|
1967
|
-
_inherits(_class18, _cls$Block7);
|
|
1968
|
-
|
|
1969
|
-
function _class18() {
|
|
1970
|
-
_classCallCheck(this, _class18);
|
|
1971
|
-
|
|
1972
|
-
return _possibleConstructorReturn(this, (_class18.__proto__ || Object.getPrototypeOf(_class18)).apply(this, arguments));
|
|
1973
|
-
}
|
|
1974
|
-
|
|
1975
|
-
_createClass(_class18, [{
|
|
1976
|
-
key: 'distinct',
|
|
1977
|
-
|
|
1978
|
-
// Add the DISTINCT keyword to the query.
|
|
1979
|
-
value: function distinct() {
|
|
1980
|
-
this._useDistinct = true;
|
|
1981
|
-
}
|
|
1982
|
-
}, {
|
|
1983
|
-
key: '_toParamString',
|
|
1984
|
-
value: function _toParamString() {
|
|
1985
|
-
return {
|
|
1986
|
-
text: this._useDistinct ? "DISTINCT" : "",
|
|
1987
|
-
values: []
|
|
1988
|
-
};
|
|
1989
|
-
}
|
|
1990
|
-
}]);
|
|
1991
|
-
|
|
1992
|
-
return _class18;
|
|
1993
|
-
}(cls.Block);
|
|
1994
|
-
|
|
1995
|
-
// GROUP BY
|
|
1996
|
-
cls.GroupByBlock = function (_cls$Block8) {
|
|
1997
|
-
_inherits(_class19, _cls$Block8);
|
|
1998
|
-
|
|
1999
|
-
function _class19(options) {
|
|
2000
|
-
_classCallCheck(this, _class19);
|
|
2001
|
-
|
|
2002
|
-
var _this22 = _possibleConstructorReturn(this, (_class19.__proto__ || Object.getPrototypeOf(_class19)).call(this, options));
|
|
2003
|
-
|
|
2004
|
-
_this22._groups = [];
|
|
2005
|
-
return _this22;
|
|
2006
|
-
}
|
|
2007
|
-
|
|
2008
|
-
// Add a GROUP BY transformation for the given field.
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
_createClass(_class19, [{
|
|
2012
|
-
key: 'group',
|
|
2013
|
-
value: function group(field) {
|
|
2014
|
-
this._groups.push(this._sanitizeField(field));
|
|
2015
|
-
}
|
|
2016
|
-
}, {
|
|
2017
|
-
key: '_toParamString',
|
|
2018
|
-
value: function _toParamString() {
|
|
2019
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2020
|
-
|
|
2021
|
-
return {
|
|
2022
|
-
text: this._groups.length ? 'GROUP BY ' + this._groups.join(', ') : '',
|
|
2023
|
-
values: []
|
|
2024
|
-
};
|
|
2025
|
-
}
|
|
2026
|
-
}]);
|
|
2027
|
-
|
|
2028
|
-
return _class19;
|
|
2029
|
-
}(cls.Block);
|
|
2030
|
-
|
|
2031
|
-
cls.AbstractVerbSingleValueBlock = function (_cls$Block9) {
|
|
2032
|
-
_inherits(_class20, _cls$Block9);
|
|
2033
|
-
|
|
2034
|
-
/**
|
|
2035
|
-
* @param options.verb The prefix verb string.
|
|
2036
|
-
*/
|
|
2037
|
-
function _class20(options) {
|
|
2038
|
-
_classCallCheck(this, _class20);
|
|
2039
|
-
|
|
2040
|
-
var _this23 = _possibleConstructorReturn(this, (_class20.__proto__ || Object.getPrototypeOf(_class20)).call(this, options));
|
|
2041
|
-
|
|
2042
|
-
_this23._value = null;
|
|
2043
|
-
return _this23;
|
|
2044
|
-
}
|
|
2045
|
-
|
|
2046
|
-
_createClass(_class20, [{
|
|
2047
|
-
key: '_setValue',
|
|
2048
|
-
value: function _setValue(value) {
|
|
2049
|
-
this._value = null !== value ? this._sanitizeLimitOffset(value) : value;
|
|
2050
|
-
}
|
|
2051
|
-
}, {
|
|
2052
|
-
key: '_toParamString',
|
|
2053
|
-
value: function _toParamString() {
|
|
2054
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2055
|
-
|
|
2056
|
-
var expr = null !== this._value ? this.options.verb + ' ' + this.options.parameterCharacter : '';
|
|
2057
|
-
|
|
2058
|
-
var values = null !== this._value ? [this._value] : [];
|
|
2059
|
-
|
|
2060
|
-
return this._buildString(expr, values, options);
|
|
2061
|
-
}
|
|
2062
|
-
}]);
|
|
2063
|
-
|
|
2064
|
-
return _class20;
|
|
2065
|
-
}(cls.Block);
|
|
2066
|
-
|
|
2067
|
-
// OFFSET x
|
|
2068
|
-
cls.OffsetBlock = function (_cls$AbstractVerbSing) {
|
|
2069
|
-
_inherits(_class21, _cls$AbstractVerbSing);
|
|
2070
|
-
|
|
2071
|
-
function _class21(options) {
|
|
2072
|
-
_classCallCheck(this, _class21);
|
|
2073
|
-
|
|
2074
|
-
return _possibleConstructorReturn(this, (_class21.__proto__ || Object.getPrototypeOf(_class21)).call(this, _extend({}, options, {
|
|
2075
|
-
verb: 'OFFSET'
|
|
2076
|
-
})));
|
|
2077
|
-
}
|
|
2078
|
-
|
|
2079
|
-
/**
|
|
2080
|
-
# Set the OFFSET transformation.
|
|
2081
|
-
#
|
|
2082
|
-
# Call this will override the previously set offset for this query. Also note that Passing 0 for 'max' will remove
|
|
2083
|
-
# the offset.
|
|
2084
|
-
*/
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
_createClass(_class21, [{
|
|
2088
|
-
key: 'offset',
|
|
2089
|
-
value: function offset(start) {
|
|
2090
|
-
this._setValue(start);
|
|
2091
|
-
}
|
|
2092
|
-
}]);
|
|
2093
|
-
|
|
2094
|
-
return _class21;
|
|
2095
|
-
}(cls.AbstractVerbSingleValueBlock);
|
|
2096
|
-
|
|
2097
|
-
// LIMIT
|
|
2098
|
-
cls.LimitBlock = function (_cls$AbstractVerbSing2) {
|
|
2099
|
-
_inherits(_class22, _cls$AbstractVerbSing2);
|
|
2100
|
-
|
|
2101
|
-
function _class22(options) {
|
|
2102
|
-
_classCallCheck(this, _class22);
|
|
2103
|
-
|
|
2104
|
-
return _possibleConstructorReturn(this, (_class22.__proto__ || Object.getPrototypeOf(_class22)).call(this, _extend({}, options, {
|
|
2105
|
-
verb: 'LIMIT'
|
|
2106
|
-
})));
|
|
2107
|
-
}
|
|
2108
|
-
|
|
2109
|
-
/**
|
|
2110
|
-
# Set the LIMIT transformation.
|
|
2111
|
-
#
|
|
2112
|
-
# Call this will override the previously set limit for this query. Also note that Passing `null` will remove
|
|
2113
|
-
# the limit.
|
|
2114
|
-
*/
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
_createClass(_class22, [{
|
|
2118
|
-
key: 'limit',
|
|
2119
|
-
value: function limit(_limit) {
|
|
2120
|
-
this._setValue(_limit);
|
|
2121
|
-
}
|
|
2122
|
-
}]);
|
|
2123
|
-
|
|
2124
|
-
return _class22;
|
|
2125
|
-
}(cls.AbstractVerbSingleValueBlock);
|
|
2126
|
-
|
|
2127
|
-
// Abstract condition base class
|
|
2128
|
-
cls.AbstractConditionBlock = function (_cls$Block10) {
|
|
2129
|
-
_inherits(_class23, _cls$Block10);
|
|
2130
|
-
|
|
2131
|
-
/**
|
|
2132
|
-
* @param {String} options.verb The condition verb.
|
|
2133
|
-
*/
|
|
2134
|
-
function _class23(options) {
|
|
2135
|
-
_classCallCheck(this, _class23);
|
|
2136
|
-
|
|
2137
|
-
var _this26 = _possibleConstructorReturn(this, (_class23.__proto__ || Object.getPrototypeOf(_class23)).call(this, options));
|
|
2138
|
-
|
|
2139
|
-
_this26._conditions = [];
|
|
2140
|
-
return _this26;
|
|
2141
|
-
}
|
|
2142
|
-
|
|
2143
|
-
/**
|
|
2144
|
-
# Add a condition.
|
|
2145
|
-
#
|
|
2146
|
-
# When the final query is constructed all the conditions are combined using the intersection (AND) operator.
|
|
2147
|
-
#
|
|
2148
|
-
# Concrete subclasses should provide a method which calls this
|
|
2149
|
-
*/
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
_createClass(_class23, [{
|
|
2153
|
-
key: '_condition',
|
|
2154
|
-
value: function _condition(condition) {
|
|
2155
|
-
condition = this._sanitizeExpression(condition);
|
|
2156
|
-
|
|
2157
|
-
for (var _len6 = arguments.length, values = Array(_len6 > 1 ? _len6 - 1 : 0), _key6 = 1; _key6 < _len6; _key6++) {
|
|
2158
|
-
values[_key6 - 1] = arguments[_key6];
|
|
2159
|
-
}
|
|
2160
|
-
|
|
2161
|
-
this._conditions.push({
|
|
2162
|
-
expr: condition,
|
|
2163
|
-
values: values || []
|
|
2164
|
-
});
|
|
2165
|
-
}
|
|
2166
|
-
}, {
|
|
2167
|
-
key: '_toParamString',
|
|
2168
|
-
value: function _toParamString() {
|
|
2169
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2170
|
-
|
|
2171
|
-
var totalStr = [],
|
|
2172
|
-
totalValues = [];
|
|
2173
|
-
|
|
2174
|
-
var _iteratorNormalCompletion8 = true;
|
|
2175
|
-
var _didIteratorError8 = false;
|
|
2176
|
-
var _iteratorError8 = undefined;
|
|
2177
|
-
|
|
2178
|
-
try {
|
|
2179
|
-
for (var _iterator8 = this._conditions[Symbol.iterator](), _step8; !(_iteratorNormalCompletion8 = (_step8 = _iterator8.next()).done); _iteratorNormalCompletion8 = true) {
|
|
2180
|
-
var _ref4 = _step8.value;
|
|
2181
|
-
var expr = _ref4.expr;
|
|
2182
|
-
var _values2 = _ref4.values;
|
|
2183
|
-
|
|
2184
|
-
var ret = cls.isSquelBuilder(expr) ? expr._toParamString({
|
|
2185
|
-
buildParameterized: options.buildParameterized
|
|
2186
|
-
}) : this._buildString(expr, _values2, {
|
|
2187
|
-
buildParameterized: options.buildParameterized
|
|
2188
|
-
});
|
|
2189
|
-
|
|
2190
|
-
if (ret.text.length) {
|
|
2191
|
-
totalStr.push(ret.text);
|
|
2192
|
-
}
|
|
2193
|
-
|
|
2194
|
-
ret.values.forEach(function (value) {
|
|
2195
|
-
return totalValues.push(value);
|
|
2196
|
-
});
|
|
2197
|
-
}
|
|
2198
|
-
} catch (err) {
|
|
2199
|
-
_didIteratorError8 = true;
|
|
2200
|
-
_iteratorError8 = err;
|
|
2201
|
-
} finally {
|
|
2202
|
-
try {
|
|
2203
|
-
if (!_iteratorNormalCompletion8 && _iterator8.return) {
|
|
2204
|
-
_iterator8.return();
|
|
2205
|
-
}
|
|
2206
|
-
} finally {
|
|
2207
|
-
if (_didIteratorError8) {
|
|
2208
|
-
throw _iteratorError8;
|
|
2209
|
-
}
|
|
2210
|
-
}
|
|
2211
|
-
}
|
|
2212
|
-
|
|
2213
|
-
if (totalStr.length) {
|
|
2214
|
-
totalStr = totalStr.join(') AND (');
|
|
2215
|
-
}
|
|
2216
|
-
|
|
2217
|
-
return {
|
|
2218
|
-
text: totalStr.length ? this.options.verb + ' (' + totalStr + ')' : '',
|
|
2219
|
-
values: totalValues
|
|
2220
|
-
};
|
|
2221
|
-
}
|
|
2222
|
-
}]);
|
|
2223
|
-
|
|
2224
|
-
return _class23;
|
|
2225
|
-
}(cls.Block);
|
|
2226
|
-
|
|
2227
|
-
// WHERE
|
|
2228
|
-
cls.WhereBlock = function (_cls$AbstractConditio) {
|
|
2229
|
-
_inherits(_class24, _cls$AbstractConditio);
|
|
2230
|
-
|
|
2231
|
-
function _class24(options) {
|
|
2232
|
-
_classCallCheck(this, _class24);
|
|
2233
|
-
|
|
2234
|
-
return _possibleConstructorReturn(this, (_class24.__proto__ || Object.getPrototypeOf(_class24)).call(this, _extend({}, options, {
|
|
2235
|
-
verb: 'WHERE'
|
|
2236
|
-
})));
|
|
2237
|
-
}
|
|
2238
|
-
|
|
2239
|
-
_createClass(_class24, [{
|
|
2240
|
-
key: 'where',
|
|
2241
|
-
value: function where(condition) {
|
|
2242
|
-
for (var _len7 = arguments.length, values = Array(_len7 > 1 ? _len7 - 1 : 0), _key7 = 1; _key7 < _len7; _key7++) {
|
|
2243
|
-
values[_key7 - 1] = arguments[_key7];
|
|
2244
|
-
}
|
|
2245
|
-
|
|
2246
|
-
this._condition.apply(this, [condition].concat(values));
|
|
2247
|
-
}
|
|
2248
|
-
}]);
|
|
2249
|
-
|
|
2250
|
-
return _class24;
|
|
2251
|
-
}(cls.AbstractConditionBlock);
|
|
2252
|
-
|
|
2253
|
-
// HAVING
|
|
2254
|
-
cls.HavingBlock = function (_cls$AbstractConditio2) {
|
|
2255
|
-
_inherits(_class25, _cls$AbstractConditio2);
|
|
2256
|
-
|
|
2257
|
-
function _class25(options) {
|
|
2258
|
-
_classCallCheck(this, _class25);
|
|
2259
|
-
|
|
2260
|
-
return _possibleConstructorReturn(this, (_class25.__proto__ || Object.getPrototypeOf(_class25)).call(this, _extend({}, options, {
|
|
2261
|
-
verb: 'HAVING'
|
|
2262
|
-
})));
|
|
2263
|
-
}
|
|
2264
|
-
|
|
2265
|
-
_createClass(_class25, [{
|
|
2266
|
-
key: 'having',
|
|
2267
|
-
value: function having(condition) {
|
|
2268
|
-
for (var _len8 = arguments.length, values = Array(_len8 > 1 ? _len8 - 1 : 0), _key8 = 1; _key8 < _len8; _key8++) {
|
|
2269
|
-
values[_key8 - 1] = arguments[_key8];
|
|
2270
|
-
}
|
|
2271
|
-
|
|
2272
|
-
this._condition.apply(this, [condition].concat(values));
|
|
2273
|
-
}
|
|
2274
|
-
}]);
|
|
2275
|
-
|
|
2276
|
-
return _class25;
|
|
2277
|
-
}(cls.AbstractConditionBlock);
|
|
2278
|
-
|
|
2279
|
-
// ORDER BY
|
|
2280
|
-
cls.OrderByBlock = function (_cls$Block11) {
|
|
2281
|
-
_inherits(_class26, _cls$Block11);
|
|
2282
|
-
|
|
2283
|
-
function _class26(options) {
|
|
2284
|
-
_classCallCheck(this, _class26);
|
|
2285
|
-
|
|
2286
|
-
var _this29 = _possibleConstructorReturn(this, (_class26.__proto__ || Object.getPrototypeOf(_class26)).call(this, options));
|
|
2287
|
-
|
|
2288
|
-
_this29._orders = [];
|
|
2289
|
-
return _this29;
|
|
2290
|
-
}
|
|
2291
|
-
|
|
2292
|
-
/**
|
|
2293
|
-
# Add an ORDER BY transformation for the given field in the given order.
|
|
2294
|
-
#
|
|
2295
|
-
# To specify descending order pass false for the 'dir' parameter.
|
|
2296
|
-
*/
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
_createClass(_class26, [{
|
|
2300
|
-
key: 'order',
|
|
2301
|
-
value: function order(field, dir) {
|
|
2302
|
-
field = this._sanitizeField(field);
|
|
2303
|
-
|
|
2304
|
-
if (!(typeof dir === 'string')) {
|
|
2305
|
-
if (dir === undefined) {
|
|
2306
|
-
dir = 'ASC'; // Default to asc
|
|
2307
|
-
} else if (dir !== null) {
|
|
2308
|
-
dir = dir ? 'ASC' : 'DESC'; // Convert truthy to asc
|
|
2309
|
-
}
|
|
2310
|
-
}
|
|
2311
|
-
|
|
2312
|
-
for (var _len9 = arguments.length, values = Array(_len9 > 2 ? _len9 - 2 : 0), _key9 = 2; _key9 < _len9; _key9++) {
|
|
2313
|
-
values[_key9 - 2] = arguments[_key9];
|
|
2314
|
-
}
|
|
2315
|
-
|
|
2316
|
-
this._orders.push({
|
|
2317
|
-
field: field,
|
|
2318
|
-
dir: dir,
|
|
2319
|
-
values: values || []
|
|
2320
|
-
});
|
|
2321
|
-
}
|
|
2322
|
-
}, {
|
|
2323
|
-
key: '_toParamString',
|
|
2324
|
-
value: function _toParamString() {
|
|
2325
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2326
|
-
|
|
2327
|
-
var totalStr = '',
|
|
2328
|
-
totalValues = [];
|
|
2329
|
-
|
|
2330
|
-
var _iteratorNormalCompletion9 = true;
|
|
2331
|
-
var _didIteratorError9 = false;
|
|
2332
|
-
var _iteratorError9 = undefined;
|
|
2333
|
-
|
|
2334
|
-
try {
|
|
2335
|
-
for (var _iterator9 = this._orders[Symbol.iterator](), _step9; !(_iteratorNormalCompletion9 = (_step9 = _iterator9.next()).done); _iteratorNormalCompletion9 = true) {
|
|
2336
|
-
var _ref5 = _step9.value;
|
|
2337
|
-
var field = _ref5.field;
|
|
2338
|
-
var dir = _ref5.dir;
|
|
2339
|
-
var _values3 = _ref5.values;
|
|
2340
|
-
|
|
2341
|
-
totalStr = _pad(totalStr, ', ');
|
|
2342
|
-
|
|
2343
|
-
var ret = this._buildString(field, _values3, {
|
|
2344
|
-
buildParameterized: options.buildParameterized
|
|
2345
|
-
});
|
|
2346
|
-
|
|
2347
|
-
totalStr += ret.text, _isArray(ret.values) && ret.values.forEach(function (value) {
|
|
2348
|
-
return totalValues.push(value);
|
|
2349
|
-
});
|
|
2350
|
-
|
|
2351
|
-
if (dir !== null) {
|
|
2352
|
-
totalStr += ' ' + dir;
|
|
2353
|
-
}
|
|
2354
|
-
}
|
|
2355
|
-
} catch (err) {
|
|
2356
|
-
_didIteratorError9 = true;
|
|
2357
|
-
_iteratorError9 = err;
|
|
2358
|
-
} finally {
|
|
2359
|
-
try {
|
|
2360
|
-
if (!_iteratorNormalCompletion9 && _iterator9.return) {
|
|
2361
|
-
_iterator9.return();
|
|
2362
|
-
}
|
|
2363
|
-
} finally {
|
|
2364
|
-
if (_didIteratorError9) {
|
|
2365
|
-
throw _iteratorError9;
|
|
2366
|
-
}
|
|
2367
|
-
}
|
|
2368
|
-
}
|
|
2369
|
-
|
|
2370
|
-
return {
|
|
2371
|
-
text: totalStr.length ? 'ORDER BY ' + totalStr : '',
|
|
2372
|
-
values: totalValues
|
|
2373
|
-
};
|
|
2374
|
-
}
|
|
2375
|
-
}]);
|
|
2376
|
-
|
|
2377
|
-
return _class26;
|
|
2378
|
-
}(cls.Block);
|
|
2379
|
-
|
|
2380
|
-
// JOIN
|
|
2381
|
-
cls.JoinBlock = function (_cls$Block12) {
|
|
2382
|
-
_inherits(_class27, _cls$Block12);
|
|
2383
|
-
|
|
2384
|
-
function _class27(options) {
|
|
2385
|
-
_classCallCheck(this, _class27);
|
|
2386
|
-
|
|
2387
|
-
var _this30 = _possibleConstructorReturn(this, (_class27.__proto__ || Object.getPrototypeOf(_class27)).call(this, options));
|
|
2388
|
-
|
|
2389
|
-
_this30._joins = [];
|
|
2390
|
-
return _this30;
|
|
2391
|
-
}
|
|
2392
|
-
|
|
2393
|
-
/**
|
|
2394
|
-
# Add a JOIN with the given table.
|
|
2395
|
-
#
|
|
2396
|
-
# 'table' is the name of the table to join with.
|
|
2397
|
-
#
|
|
2398
|
-
# 'alias' is an optional alias for the table name.
|
|
2399
|
-
#
|
|
2400
|
-
# 'condition' is an optional condition (containing an SQL expression) for the JOIN.
|
|
2401
|
-
#
|
|
2402
|
-
# 'type' must be either one of INNER, OUTER, LEFT or RIGHT. Default is 'INNER'.
|
|
2403
|
-
#
|
|
2404
|
-
*/
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
_createClass(_class27, [{
|
|
2408
|
-
key: 'join',
|
|
2409
|
-
value: function join(table) {
|
|
2410
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2411
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2412
|
-
var type = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'INNER';
|
|
2413
|
-
|
|
2414
|
-
table = this._sanitizeTable(table, true);
|
|
2415
|
-
alias = alias ? this._sanitizeTableAlias(alias) : alias;
|
|
2416
|
-
condition = condition ? this._sanitizeExpression(condition) : condition;
|
|
2417
|
-
|
|
2418
|
-
this._joins.push({
|
|
2419
|
-
type: type,
|
|
2420
|
-
table: table,
|
|
2421
|
-
alias: alias,
|
|
2422
|
-
condition: condition
|
|
2423
|
-
});
|
|
2424
|
-
}
|
|
2425
|
-
}, {
|
|
2426
|
-
key: 'left_join',
|
|
2427
|
-
value: function left_join(table) {
|
|
2428
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2429
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2430
|
-
|
|
2431
|
-
this.join(table, alias, condition, 'LEFT');
|
|
2432
|
-
}
|
|
2433
|
-
}, {
|
|
2434
|
-
key: 'right_join',
|
|
2435
|
-
value: function right_join(table) {
|
|
2436
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2437
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2438
|
-
|
|
2439
|
-
this.join(table, alias, condition, 'RIGHT');
|
|
2440
|
-
}
|
|
2441
|
-
}, {
|
|
2442
|
-
key: 'outer_join',
|
|
2443
|
-
value: function outer_join(table) {
|
|
2444
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2445
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2446
|
-
|
|
2447
|
-
this.join(table, alias, condition, 'OUTER');
|
|
2448
|
-
}
|
|
2449
|
-
}, {
|
|
2450
|
-
key: 'left_outer_join',
|
|
2451
|
-
value: function left_outer_join(table) {
|
|
2452
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2453
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2454
|
-
|
|
2455
|
-
this.join(table, alias, condition, 'LEFT OUTER');
|
|
2456
|
-
}
|
|
2457
|
-
}, {
|
|
2458
|
-
key: 'full_join',
|
|
2459
|
-
value: function full_join(table) {
|
|
2460
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2461
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2462
|
-
|
|
2463
|
-
this.join(table, alias, condition, 'FULL');
|
|
2464
|
-
}
|
|
2465
|
-
}, {
|
|
2466
|
-
key: 'cross_join',
|
|
2467
|
-
value: function cross_join(table) {
|
|
2468
|
-
var alias = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2469
|
-
var condition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
2470
|
-
|
|
2471
|
-
this.join(table, alias, condition, 'CROSS');
|
|
2472
|
-
}
|
|
2473
|
-
}, {
|
|
2474
|
-
key: '_toParamString',
|
|
2475
|
-
value: function _toParamString() {
|
|
2476
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2477
|
-
|
|
2478
|
-
var totalStr = "",
|
|
2479
|
-
totalValues = [];
|
|
2480
|
-
|
|
2481
|
-
var _iteratorNormalCompletion10 = true;
|
|
2482
|
-
var _didIteratorError10 = false;
|
|
2483
|
-
var _iteratorError10 = undefined;
|
|
2484
|
-
|
|
2485
|
-
try {
|
|
2486
|
-
for (var _iterator10 = this._joins[Symbol.iterator](), _step10; !(_iteratorNormalCompletion10 = (_step10 = _iterator10.next()).done); _iteratorNormalCompletion10 = true) {
|
|
2487
|
-
var _ref6 = _step10.value;
|
|
2488
|
-
var type = _ref6.type;
|
|
2489
|
-
var table = _ref6.table;
|
|
2490
|
-
var alias = _ref6.alias;
|
|
2491
|
-
var condition = _ref6.condition;
|
|
2492
|
-
|
|
2493
|
-
totalStr = _pad(totalStr, this.options.separator);
|
|
2494
|
-
|
|
2495
|
-
var tableStr = void 0;
|
|
2496
|
-
|
|
2497
|
-
if (cls.isSquelBuilder(table)) {
|
|
2498
|
-
var ret = table._toParamString({
|
|
2499
|
-
buildParameterized: options.buildParameterized,
|
|
2500
|
-
nested: true
|
|
2501
|
-
});
|
|
2502
|
-
|
|
2503
|
-
ret.values.forEach(function (value) {
|
|
2504
|
-
return totalValues.push(value);
|
|
2505
|
-
});
|
|
2506
|
-
tableStr = ret.text;
|
|
2507
|
-
} else {
|
|
2508
|
-
tableStr = this._formatTableName(table);
|
|
2509
|
-
}
|
|
2510
|
-
|
|
2511
|
-
totalStr += type + ' JOIN ' + tableStr;
|
|
2512
|
-
|
|
2513
|
-
if (alias) {
|
|
2514
|
-
totalStr += ' ' + this._formatTableAlias(alias);
|
|
2515
|
-
}
|
|
2516
|
-
|
|
2517
|
-
if (condition) {
|
|
2518
|
-
totalStr += ' ON ';
|
|
2519
|
-
|
|
2520
|
-
var _ret2 = void 0;
|
|
2521
|
-
|
|
2522
|
-
if (cls.isSquelBuilder(condition)) {
|
|
2523
|
-
_ret2 = condition._toParamString({
|
|
2524
|
-
buildParameterized: options.buildParameterized
|
|
2525
|
-
});
|
|
2526
|
-
} else {
|
|
2527
|
-
_ret2 = this._buildString(condition, [], {
|
|
2528
|
-
buildParameterized: options.buildParameterized
|
|
2529
|
-
});
|
|
2530
|
-
}
|
|
2531
|
-
|
|
2532
|
-
totalStr += this._applyNestingFormatting(_ret2.text);
|
|
2533
|
-
_ret2.values.forEach(function (value) {
|
|
2534
|
-
return totalValues.push(value);
|
|
2535
|
-
});
|
|
2536
|
-
}
|
|
2537
|
-
}
|
|
2538
|
-
} catch (err) {
|
|
2539
|
-
_didIteratorError10 = true;
|
|
2540
|
-
_iteratorError10 = err;
|
|
2541
|
-
} finally {
|
|
2542
|
-
try {
|
|
2543
|
-
if (!_iteratorNormalCompletion10 && _iterator10.return) {
|
|
2544
|
-
_iterator10.return();
|
|
2545
|
-
}
|
|
2546
|
-
} finally {
|
|
2547
|
-
if (_didIteratorError10) {
|
|
2548
|
-
throw _iteratorError10;
|
|
2549
|
-
}
|
|
2550
|
-
}
|
|
2551
|
-
}
|
|
2552
|
-
|
|
2553
|
-
return {
|
|
2554
|
-
text: totalStr,
|
|
2555
|
-
values: totalValues
|
|
2556
|
-
};
|
|
2557
|
-
}
|
|
2558
|
-
}]);
|
|
2559
|
-
|
|
2560
|
-
return _class27;
|
|
2561
|
-
}(cls.Block);
|
|
2562
|
-
|
|
2563
|
-
// UNION
|
|
2564
|
-
cls.UnionBlock = function (_cls$Block13) {
|
|
2565
|
-
_inherits(_class28, _cls$Block13);
|
|
2566
|
-
|
|
2567
|
-
function _class28(options) {
|
|
2568
|
-
_classCallCheck(this, _class28);
|
|
2569
|
-
|
|
2570
|
-
var _this31 = _possibleConstructorReturn(this, (_class28.__proto__ || Object.getPrototypeOf(_class28)).call(this, options));
|
|
2571
|
-
|
|
2572
|
-
_this31._unions = [];
|
|
2573
|
-
return _this31;
|
|
2574
|
-
}
|
|
2575
|
-
|
|
2576
|
-
/**
|
|
2577
|
-
# Add a UNION with the given table/query.
|
|
2578
|
-
#
|
|
2579
|
-
# 'table' is the name of the table or query to union with.
|
|
2580
|
-
#
|
|
2581
|
-
# 'type' must be either one of UNION or UNION ALL.... Default is 'UNION'.
|
|
2582
|
-
*/
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
_createClass(_class28, [{
|
|
2586
|
-
key: 'union',
|
|
2587
|
-
value: function union(table) {
|
|
2588
|
-
var type = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'UNION';
|
|
2589
|
-
|
|
2590
|
-
table = this._sanitizeTable(table);
|
|
2591
|
-
|
|
2592
|
-
this._unions.push({
|
|
2593
|
-
type: type,
|
|
2594
|
-
table: table
|
|
2595
|
-
});
|
|
2596
|
-
}
|
|
2597
|
-
|
|
2598
|
-
// Add a UNION ALL with the given table/query.
|
|
2599
|
-
|
|
2600
|
-
}, {
|
|
2601
|
-
key: 'union_all',
|
|
2602
|
-
value: function union_all(table) {
|
|
2603
|
-
this.union(table, 'UNION ALL');
|
|
2604
|
-
}
|
|
2605
|
-
}, {
|
|
2606
|
-
key: '_toParamString',
|
|
2607
|
-
value: function _toParamString() {
|
|
2608
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2609
|
-
|
|
2610
|
-
var totalStr = '',
|
|
2611
|
-
totalValues = [];
|
|
2612
|
-
|
|
2613
|
-
var _iteratorNormalCompletion11 = true;
|
|
2614
|
-
var _didIteratorError11 = false;
|
|
2615
|
-
var _iteratorError11 = undefined;
|
|
2616
|
-
|
|
2617
|
-
try {
|
|
2618
|
-
for (var _iterator11 = this._unions[Symbol.iterator](), _step11; !(_iteratorNormalCompletion11 = (_step11 = _iterator11.next()).done); _iteratorNormalCompletion11 = true) {
|
|
2619
|
-
var _ref7 = _step11.value;
|
|
2620
|
-
var type = _ref7.type;
|
|
2621
|
-
var table = _ref7.table;
|
|
2622
|
-
|
|
2623
|
-
totalStr = _pad(totalStr, this.options.separator);
|
|
2624
|
-
|
|
2625
|
-
var tableStr = void 0;
|
|
2626
|
-
|
|
2627
|
-
if (table instanceof cls.BaseBuilder) {
|
|
2628
|
-
var ret = table._toParamString({
|
|
2629
|
-
buildParameterized: options.buildParameterized,
|
|
2630
|
-
nested: true
|
|
2631
|
-
});
|
|
2632
|
-
|
|
2633
|
-
tableStr = ret.text;
|
|
2634
|
-
ret.values.forEach(function (value) {
|
|
2635
|
-
return totalValues.push(value);
|
|
2636
|
-
});
|
|
2637
|
-
} else {
|
|
2638
|
-
totalStr = this._formatTableName(table);
|
|
2639
|
-
}
|
|
2640
|
-
|
|
2641
|
-
totalStr += type + ' ' + tableStr;
|
|
2642
|
-
}
|
|
2643
|
-
} catch (err) {
|
|
2644
|
-
_didIteratorError11 = true;
|
|
2645
|
-
_iteratorError11 = err;
|
|
2646
|
-
} finally {
|
|
2647
|
-
try {
|
|
2648
|
-
if (!_iteratorNormalCompletion11 && _iterator11.return) {
|
|
2649
|
-
_iterator11.return();
|
|
2650
|
-
}
|
|
2651
|
-
} finally {
|
|
2652
|
-
if (_didIteratorError11) {
|
|
2653
|
-
throw _iteratorError11;
|
|
2654
|
-
}
|
|
2655
|
-
}
|
|
2656
|
-
}
|
|
2657
|
-
|
|
2658
|
-
return {
|
|
2659
|
-
text: totalStr,
|
|
2660
|
-
values: totalValues
|
|
2661
|
-
};
|
|
2662
|
-
}
|
|
2663
|
-
}]);
|
|
2664
|
-
|
|
2665
|
-
return _class28;
|
|
2666
|
-
}(cls.Block);
|
|
2667
|
-
|
|
2668
|
-
/*
|
|
2669
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
2670
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
2671
|
-
# Query builders
|
|
2672
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
2673
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
2674
|
-
*/
|
|
2675
|
-
|
|
2676
|
-
/**
|
|
2677
|
-
# Query builder base class
|
|
2678
|
-
#
|
|
2679
|
-
# Note that the query builder does not check the final query string for correctness.
|
|
2680
|
-
#
|
|
2681
|
-
# All the build methods in this object return the object instance for chained method calling purposes.
|
|
2682
|
-
*/
|
|
2683
|
-
cls.QueryBuilder = function (_cls$BaseBuilder4) {
|
|
2684
|
-
_inherits(_class29, _cls$BaseBuilder4);
|
|
2685
|
-
|
|
2686
|
-
/**
|
|
2687
|
-
# Constructor
|
|
2688
|
-
#
|
|
2689
|
-
# blocks - array of cls.BaseBuilderBlock instances to build the query with.
|
|
2690
|
-
*/
|
|
2691
|
-
function _class29(options, blocks) {
|
|
2692
|
-
_classCallCheck(this, _class29);
|
|
2693
|
-
|
|
2694
|
-
var _this32 = _possibleConstructorReturn(this, (_class29.__proto__ || Object.getPrototypeOf(_class29)).call(this, options));
|
|
2695
|
-
|
|
2696
|
-
_this32.blocks = blocks || [];
|
|
2697
|
-
|
|
2698
|
-
// Copy exposed methods into myself
|
|
2699
|
-
var _iteratorNormalCompletion12 = true;
|
|
2700
|
-
var _didIteratorError12 = false;
|
|
2701
|
-
var _iteratorError12 = undefined;
|
|
2702
|
-
|
|
2703
|
-
try {
|
|
2704
|
-
for (var _iterator12 = _this32.blocks[Symbol.iterator](), _step12; !(_iteratorNormalCompletion12 = (_step12 = _iterator12.next()).done); _iteratorNormalCompletion12 = true) {
|
|
2705
|
-
var block = _step12.value;
|
|
2706
|
-
|
|
2707
|
-
var exposedMethods = block.exposedMethods();
|
|
2708
|
-
|
|
2709
|
-
for (var methodName in exposedMethods) {
|
|
2710
|
-
var methodBody = exposedMethods[methodName];
|
|
2711
|
-
|
|
2712
|
-
if (undefined !== _this32[methodName]) {
|
|
2713
|
-
throw new Error('Builder already has a builder method called: ' + methodName);
|
|
2714
|
-
}
|
|
2715
|
-
|
|
2716
|
-
(function (block, name, body) {
|
|
2717
|
-
_this32[name] = function () {
|
|
2718
|
-
for (var _len10 = arguments.length, args = Array(_len10), _key10 = 0; _key10 < _len10; _key10++) {
|
|
2719
|
-
args[_key10] = arguments[_key10];
|
|
2720
|
-
}
|
|
2721
|
-
|
|
2722
|
-
body.call.apply(body, [block].concat(args));
|
|
2723
|
-
|
|
2724
|
-
return _this32;
|
|
2725
|
-
};
|
|
2726
|
-
})(block, methodName, methodBody);
|
|
2727
|
-
}
|
|
2728
|
-
}
|
|
2729
|
-
} catch (err) {
|
|
2730
|
-
_didIteratorError12 = true;
|
|
2731
|
-
_iteratorError12 = err;
|
|
2732
|
-
} finally {
|
|
2733
|
-
try {
|
|
2734
|
-
if (!_iteratorNormalCompletion12 && _iterator12.return) {
|
|
2735
|
-
_iterator12.return();
|
|
2736
|
-
}
|
|
2737
|
-
} finally {
|
|
2738
|
-
if (_didIteratorError12) {
|
|
2739
|
-
throw _iteratorError12;
|
|
2740
|
-
}
|
|
2741
|
-
}
|
|
2742
|
-
}
|
|
2743
|
-
|
|
2744
|
-
return _this32;
|
|
2745
|
-
}
|
|
2746
|
-
|
|
2747
|
-
/**
|
|
2748
|
-
# Register a custom value handler for this query builder and all its contained blocks.
|
|
2749
|
-
#
|
|
2750
|
-
# Note: This will override any globally registered handler for this value type.
|
|
2751
|
-
*/
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
_createClass(_class29, [{
|
|
2755
|
-
key: 'registerValueHandler',
|
|
2756
|
-
value: function registerValueHandler(type, handler) {
|
|
2757
|
-
var _iteratorNormalCompletion13 = true;
|
|
2758
|
-
var _didIteratorError13 = false;
|
|
2759
|
-
var _iteratorError13 = undefined;
|
|
2760
|
-
|
|
2761
|
-
try {
|
|
2762
|
-
for (var _iterator13 = this.blocks[Symbol.iterator](), _step13; !(_iteratorNormalCompletion13 = (_step13 = _iterator13.next()).done); _iteratorNormalCompletion13 = true) {
|
|
2763
|
-
var block = _step13.value;
|
|
2764
|
-
|
|
2765
|
-
block.registerValueHandler(type, handler);
|
|
2766
|
-
}
|
|
2767
|
-
} catch (err) {
|
|
2768
|
-
_didIteratorError13 = true;
|
|
2769
|
-
_iteratorError13 = err;
|
|
2770
|
-
} finally {
|
|
2771
|
-
try {
|
|
2772
|
-
if (!_iteratorNormalCompletion13 && _iterator13.return) {
|
|
2773
|
-
_iterator13.return();
|
|
2774
|
-
}
|
|
2775
|
-
} finally {
|
|
2776
|
-
if (_didIteratorError13) {
|
|
2777
|
-
throw _iteratorError13;
|
|
2778
|
-
}
|
|
2779
|
-
}
|
|
2780
|
-
}
|
|
2781
|
-
|
|
2782
|
-
_get(_class29.prototype.__proto__ || Object.getPrototypeOf(_class29.prototype), 'registerValueHandler', this).call(this, type, handler);
|
|
2783
|
-
|
|
2784
|
-
return this;
|
|
2785
|
-
}
|
|
2786
|
-
|
|
2787
|
-
/**
|
|
2788
|
-
# Update query builder options
|
|
2789
|
-
#
|
|
2790
|
-
# This will update the options for all blocks too. Use this method with caution as it allows you to change the
|
|
2791
|
-
# behaviour of your query builder mid-build.
|
|
2792
|
-
*/
|
|
2793
|
-
|
|
2794
|
-
}, {
|
|
2795
|
-
key: 'updateOptions',
|
|
2796
|
-
value: function updateOptions(options) {
|
|
2797
|
-
this.options = _extend({}, this.options, options);
|
|
2798
|
-
|
|
2799
|
-
var _iteratorNormalCompletion14 = true;
|
|
2800
|
-
var _didIteratorError14 = false;
|
|
2801
|
-
var _iteratorError14 = undefined;
|
|
2802
|
-
|
|
2803
|
-
try {
|
|
2804
|
-
for (var _iterator14 = this.blocks[Symbol.iterator](), _step14; !(_iteratorNormalCompletion14 = (_step14 = _iterator14.next()).done); _iteratorNormalCompletion14 = true) {
|
|
2805
|
-
var block = _step14.value;
|
|
2806
|
-
|
|
2807
|
-
block.options = _extend({}, block.options, options);
|
|
2808
|
-
}
|
|
2809
|
-
} catch (err) {
|
|
2810
|
-
_didIteratorError14 = true;
|
|
2811
|
-
_iteratorError14 = err;
|
|
2812
|
-
} finally {
|
|
2813
|
-
try {
|
|
2814
|
-
if (!_iteratorNormalCompletion14 && _iterator14.return) {
|
|
2815
|
-
_iterator14.return();
|
|
2816
|
-
}
|
|
2817
|
-
} finally {
|
|
2818
|
-
if (_didIteratorError14) {
|
|
2819
|
-
throw _iteratorError14;
|
|
2820
|
-
}
|
|
2821
|
-
}
|
|
2822
|
-
}
|
|
2823
|
-
}
|
|
2824
|
-
|
|
2825
|
-
// Get the final fully constructed query param obj.
|
|
2826
|
-
|
|
2827
|
-
}, {
|
|
2828
|
-
key: '_toParamString',
|
|
2829
|
-
value: function _toParamString() {
|
|
2830
|
-
var _this33 = this;
|
|
2831
|
-
|
|
2832
|
-
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
2833
|
-
|
|
2834
|
-
options = _extend({}, this.options, options);
|
|
2835
|
-
|
|
2836
|
-
var blockResults = this.blocks.map(function (b) {
|
|
2837
|
-
return b._toParamString({
|
|
2838
|
-
buildParameterized: options.buildParameterized,
|
|
2839
|
-
queryBuilder: _this33
|
|
2840
|
-
});
|
|
2841
|
-
});
|
|
2842
|
-
|
|
2843
|
-
var blockTexts = blockResults.map(function (b) {
|
|
2844
|
-
return b.text;
|
|
2845
|
-
});
|
|
2846
|
-
var blockValues = blockResults.map(function (b) {
|
|
2847
|
-
return b.values;
|
|
2848
|
-
});
|
|
2849
|
-
|
|
2850
|
-
var totalStr = blockTexts.filter(function (v) {
|
|
2851
|
-
return 0 < v.length;
|
|
2852
|
-
}).join(options.separator);
|
|
2853
|
-
|
|
2854
|
-
var totalValues = [];
|
|
2855
|
-
blockValues.forEach(function (block) {
|
|
2856
|
-
return block.forEach(function (value) {
|
|
2857
|
-
return totalValues.push(value);
|
|
2858
|
-
});
|
|
2859
|
-
});
|
|
2860
|
-
|
|
2861
|
-
if (!options.nested) {
|
|
2862
|
-
if (options.numberedParameters) {
|
|
2863
|
-
var i = undefined !== options.numberedParametersStartAt ? options.numberedParametersStartAt : 1;
|
|
2864
|
-
|
|
2865
|
-
// construct regex for searching
|
|
2866
|
-
var regex = options.parameterCharacter.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
|
|
2867
|
-
|
|
2868
|
-
totalStr = totalStr.replace(new RegExp(regex, 'g'), function () {
|
|
2869
|
-
return '' + options.numberedParametersPrefix + i++;
|
|
2870
|
-
});
|
|
2871
|
-
}
|
|
2872
|
-
}
|
|
2873
|
-
|
|
2874
|
-
return {
|
|
2875
|
-
text: this._applyNestingFormatting(totalStr, !!options.nested),
|
|
2876
|
-
values: totalValues
|
|
2877
|
-
};
|
|
2878
|
-
}
|
|
2879
|
-
|
|
2880
|
-
// Deep clone
|
|
2881
|
-
|
|
2882
|
-
}, {
|
|
2883
|
-
key: 'clone',
|
|
2884
|
-
value: function clone() {
|
|
2885
|
-
var blockClones = this.blocks.map(function (v) {
|
|
2886
|
-
return v.clone();
|
|
2887
|
-
});
|
|
2888
|
-
|
|
2889
|
-
return new this.constructor(this.options, blockClones);
|
|
2890
|
-
}
|
|
2891
|
-
|
|
2892
|
-
// Get a specific block
|
|
2893
|
-
|
|
2894
|
-
}, {
|
|
2895
|
-
key: 'getBlock',
|
|
2896
|
-
value: function getBlock(blockType) {
|
|
2897
|
-
var filtered = this.blocks.filter(function (b) {
|
|
2898
|
-
return b instanceof blockType;
|
|
2899
|
-
});
|
|
2900
|
-
|
|
2901
|
-
return filtered[0];
|
|
2902
|
-
}
|
|
2903
|
-
}]);
|
|
2904
|
-
|
|
2905
|
-
return _class29;
|
|
2906
|
-
}(cls.BaseBuilder);
|
|
2907
|
-
|
|
2908
|
-
// SELECT query builder.
|
|
2909
|
-
cls.Select = function (_cls$QueryBuilder) {
|
|
2910
|
-
_inherits(_class30, _cls$QueryBuilder);
|
|
2911
|
-
|
|
2912
|
-
function _class30(options) {
|
|
2913
|
-
var blocks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2914
|
-
|
|
2915
|
-
_classCallCheck(this, _class30);
|
|
2916
|
-
|
|
2917
|
-
blocks = blocks || [new cls.StringBlock(options, 'SELECT'), new cls.FunctionBlock(options), new cls.DistinctBlock(options), new cls.GetFieldBlock(options), new cls.FromTableBlock(options), new cls.JoinBlock(options), new cls.WhereBlock(options), new cls.GroupByBlock(options), new cls.HavingBlock(options), new cls.OrderByBlock(options), new cls.LimitBlock(options), new cls.OffsetBlock(options), new cls.UnionBlock(options)];
|
|
2918
|
-
|
|
2919
|
-
return _possibleConstructorReturn(this, (_class30.__proto__ || Object.getPrototypeOf(_class30)).call(this, options, blocks));
|
|
2920
|
-
}
|
|
2921
|
-
|
|
2922
|
-
return _class30;
|
|
2923
|
-
}(cls.QueryBuilder);
|
|
2924
|
-
|
|
2925
|
-
// UPDATE query builder.
|
|
2926
|
-
cls.Update = function (_cls$QueryBuilder2) {
|
|
2927
|
-
_inherits(_class31, _cls$QueryBuilder2);
|
|
2928
|
-
|
|
2929
|
-
function _class31(options) {
|
|
2930
|
-
var blocks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2931
|
-
|
|
2932
|
-
_classCallCheck(this, _class31);
|
|
2933
|
-
|
|
2934
|
-
blocks = blocks || [new cls.StringBlock(options, 'UPDATE'), new cls.UpdateTableBlock(options), new cls.SetFieldBlock(options), new cls.WhereBlock(options), new cls.OrderByBlock(options), new cls.LimitBlock(options)];
|
|
2935
|
-
|
|
2936
|
-
return _possibleConstructorReturn(this, (_class31.__proto__ || Object.getPrototypeOf(_class31)).call(this, options, blocks));
|
|
2937
|
-
}
|
|
2938
|
-
|
|
2939
|
-
return _class31;
|
|
2940
|
-
}(cls.QueryBuilder);
|
|
2941
|
-
|
|
2942
|
-
// DELETE query builder.
|
|
2943
|
-
cls.Delete = function (_cls$QueryBuilder3) {
|
|
2944
|
-
_inherits(_class32, _cls$QueryBuilder3);
|
|
2945
|
-
|
|
2946
|
-
function _class32(options) {
|
|
2947
|
-
var blocks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2948
|
-
|
|
2949
|
-
_classCallCheck(this, _class32);
|
|
2950
|
-
|
|
2951
|
-
blocks = blocks || [new cls.StringBlock(options, 'DELETE'), new cls.TargetTableBlock(options), new cls.FromTableBlock(_extend({}, options, {
|
|
2952
|
-
singleTable: true
|
|
2953
|
-
})), new cls.JoinBlock(options), new cls.WhereBlock(options), new cls.OrderByBlock(options), new cls.LimitBlock(options)];
|
|
2954
|
-
|
|
2955
|
-
return _possibleConstructorReturn(this, (_class32.__proto__ || Object.getPrototypeOf(_class32)).call(this, options, blocks));
|
|
2956
|
-
}
|
|
2957
|
-
|
|
2958
|
-
return _class32;
|
|
2959
|
-
}(cls.QueryBuilder);
|
|
2960
|
-
|
|
2961
|
-
// An INSERT query builder.
|
|
2962
|
-
cls.Insert = function (_cls$QueryBuilder4) {
|
|
2963
|
-
_inherits(_class33, _cls$QueryBuilder4);
|
|
2964
|
-
|
|
2965
|
-
function _class33(options) {
|
|
2966
|
-
var blocks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
2967
|
-
|
|
2968
|
-
_classCallCheck(this, _class33);
|
|
2969
|
-
|
|
2970
|
-
blocks = blocks || [new cls.StringBlock(options, 'INSERT'), new cls.IntoTableBlock(options), new cls.InsertFieldValueBlock(options), new cls.InsertFieldsFromQueryBlock(options)];
|
|
2971
|
-
|
|
2972
|
-
return _possibleConstructorReturn(this, (_class33.__proto__ || Object.getPrototypeOf(_class33)).call(this, options, blocks));
|
|
2973
|
-
}
|
|
2974
|
-
|
|
2975
|
-
return _class33;
|
|
2976
|
-
}(cls.QueryBuilder);
|
|
2977
|
-
|
|
2978
|
-
var _squel = {
|
|
2979
|
-
VERSION: '5.13.0',
|
|
2980
|
-
flavour: flavour,
|
|
2981
|
-
expr: function expr(options) {
|
|
2982
|
-
return new cls.Expression(options);
|
|
2983
|
-
},
|
|
2984
|
-
case: function _case(name, options) {
|
|
2985
|
-
return new cls.Case(name, options);
|
|
2986
|
-
},
|
|
2987
|
-
select: function select(options, blocks) {
|
|
2988
|
-
return new cls.Select(options, blocks);
|
|
2989
|
-
},
|
|
2990
|
-
update: function update(options, blocks) {
|
|
2991
|
-
return new cls.Update(options, blocks);
|
|
2992
|
-
},
|
|
2993
|
-
insert: function insert(options, blocks) {
|
|
2994
|
-
return new cls.Insert(options, blocks);
|
|
2995
|
-
},
|
|
2996
|
-
delete: function _delete(options, blocks) {
|
|
2997
|
-
return new cls.Delete(options, blocks);
|
|
2998
|
-
},
|
|
2999
|
-
str: function str() {
|
|
3000
|
-
var inst = new cls.FunctionBlock();
|
|
3001
|
-
inst.function.apply(inst, arguments);
|
|
3002
|
-
return inst;
|
|
3003
|
-
},
|
|
3004
|
-
rstr: function rstr() {
|
|
3005
|
-
var inst = new cls.FunctionBlock({
|
|
3006
|
-
rawNesting: true
|
|
3007
|
-
});
|
|
3008
|
-
inst.function.apply(inst, arguments);
|
|
3009
|
-
return inst;
|
|
3010
|
-
},
|
|
3011
|
-
registerValueHandler: cls.registerValueHandler
|
|
3012
|
-
};
|
|
3013
|
-
|
|
3014
|
-
// aliases
|
|
3015
|
-
_squel.remove = _squel.delete;
|
|
3016
|
-
|
|
3017
|
-
// classes
|
|
3018
|
-
_squel.cls = cls;
|
|
3019
|
-
|
|
3020
|
-
return _squel;
|
|
3021
|
-
}
|
|
3022
|
-
|
|
3023
|
-
/**
|
|
3024
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3025
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3026
|
-
# Exported instance (and for use by flavour definitions further down).
|
|
3027
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3028
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3029
|
-
*/
|
|
3030
|
-
|
|
3031
|
-
var squel = _buildSquel();
|
|
3032
|
-
|
|
3033
|
-
/**
|
|
3034
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3035
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3036
|
-
# Squel SQL flavours
|
|
3037
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3038
|
-
# ---------------------------------------------------------------------------------------------------------
|
|
3039
|
-
*/
|
|
3040
|
-
|
|
3041
|
-
// Available flavours
|
|
3042
|
-
squel.flavours = {};
|
|
3043
|
-
|
|
3044
|
-
// Setup Squel for a particular SQL flavour
|
|
3045
|
-
squel.useFlavour = function () {
|
|
3046
|
-
var flavour = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
|
|
3047
|
-
|
|
3048
|
-
if (!flavour) {
|
|
3049
|
-
return squel;
|
|
3050
|
-
}
|
|
3051
|
-
|
|
3052
|
-
if (squel.flavours[flavour] instanceof Function) {
|
|
3053
|
-
var s = _buildSquel(flavour);
|
|
3054
|
-
|
|
3055
|
-
squel.flavours[flavour].call(null, s);
|
|
3056
|
-
|
|
3057
|
-
// add in flavour methods
|
|
3058
|
-
s.flavours = squel.flavours;
|
|
3059
|
-
s.useFlavour = squel.useFlavour;
|
|
3060
|
-
|
|
3061
|
-
return s;
|
|
3062
|
-
} else {
|
|
3063
|
-
throw new Error('Flavour not available: ' + flavour);
|
|
3064
|
-
}
|
|
3065
|
-
};
|
|
3066
|
-
return squel;
|
|
3067
|
-
}));
|