tsv2-library 1.1.4 → 1.1.6
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.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AxiosResponse } from 'axios';
|
|
2
2
|
import { DropdownOption, MultiSelectOption } from './options';
|
|
3
3
|
import { QueryParams } from '../components/v2/DataTable/DataTable.vue.d';
|
|
4
|
-
export type FilterFieldTypes = 'dropdown' | 'multiselect' | 'calendar' | 'rangenumber';
|
|
4
|
+
export type FilterFieldTypes = 'dropdown' | 'multiselect' | 'calendar' | 'calendartime' | 'rangenumber';
|
|
5
5
|
export type FilterOptions<Opt = Record<string, boolean>> = Record<keyof Opt, DropdownOption[] | MultiSelectOption[]>;
|
|
6
6
|
export interface FilterField<OptionsQueryParams extends QueryParams = QueryParams> {
|
|
7
7
|
/**
|
package/dist/tsv2-library.es.js
CHANGED
|
@@ -26280,7 +26280,12 @@ const useLoadingStore = () => {
|
|
|
26280
26280
|
};
|
|
26281
26281
|
};
|
|
26282
26282
|
const _hoisted_1$2g = { key: 1 };
|
|
26283
|
-
const _hoisted_2$1N =
|
|
26283
|
+
const _hoisted_2$1N = {
|
|
26284
|
+
key: 1,
|
|
26285
|
+
class: "text-general-800 text-body-medium break-words max-w-[85%]",
|
|
26286
|
+
"data-ts-section": "field-value"
|
|
26287
|
+
};
|
|
26288
|
+
const _hoisted_3$Q = ["href"];
|
|
26284
26289
|
const _sfc_main$1P = /* @__PURE__ */ defineComponent({
|
|
26285
26290
|
__name: "UrlFormat",
|
|
26286
26291
|
props: {
|
|
@@ -26329,13 +26334,13 @@ const _sfc_main$1P = /* @__PURE__ */ defineComponent({
|
|
|
26329
26334
|
"data-ts-section": "field-value",
|
|
26330
26335
|
href: "#"
|
|
26331
26336
|
}, " View Document ")) : (openBlock(), createElementBlock("span", _hoisted_1$2g, "-"))
|
|
26332
|
-
], 64)) : (openBlock(), createElementBlock("a", {
|
|
26333
|
-
key:
|
|
26337
|
+
], 64)) : value.value === "-" ? (openBlock(), createElementBlock("span", _hoisted_2$1N, toDisplayString$1(value.value), 1)) : (openBlock(), createElementBlock("a", {
|
|
26338
|
+
key: 2,
|
|
26334
26339
|
href: _ctx.dataType === "URL" ? ((_a = value.value) == null ? void 0 : _a.startsWith("http")) ? value.value : `http://${value.value}` : `mailto:${value.value}`,
|
|
26335
26340
|
class: "text-primary text-body-medium break-words max-w-[85%]",
|
|
26336
26341
|
"data-ts-section": "field-value",
|
|
26337
26342
|
target: "_blank"
|
|
26338
|
-
}, toDisplayString$1(_ctx.dataType === "URL" ? (_b = value.value) == null ? void 0 : _b.slice(0, 60).concat("...") : value.value), 9,
|
|
26343
|
+
}, toDisplayString$1(_ctx.dataType === "URL" ? (_b = value.value) == null ? void 0 : _b.slice(0, 60).concat("...") : value.value), 9, _hoisted_3$Q));
|
|
26339
26344
|
};
|
|
26340
26345
|
}
|
|
26341
26346
|
});
|
|
@@ -26384,7 +26389,7 @@ const CustomFieldFilterMap = {
|
|
|
26384
26389
|
Dropdown: "dropdown",
|
|
26385
26390
|
MultiDropdown: "multiselect",
|
|
26386
26391
|
Date: "calendar",
|
|
26387
|
-
Datetime: "
|
|
26392
|
+
Datetime: "calendartime",
|
|
26388
26393
|
Currency: "rangenumber"
|
|
26389
26394
|
};
|
|
26390
26395
|
const getBodyTemplate = (customField) => {
|
|
@@ -26405,7 +26410,7 @@ const getBodyTemplate = (customField) => {
|
|
|
26405
26410
|
case "Datetime":
|
|
26406
26411
|
formattedValue2 = formatDate(
|
|
26407
26412
|
dataValue,
|
|
26408
|
-
customField.dataType === "Datetime"
|
|
26413
|
+
customField.dataType === "Datetime" ? true : void 0
|
|
26409
26414
|
);
|
|
26410
26415
|
break;
|
|
26411
26416
|
case "MultiDropdown":
|
|
@@ -26435,7 +26440,7 @@ const getBodyComponent = (customField) => {
|
|
|
26435
26440
|
component: _sfc_main$1P,
|
|
26436
26441
|
props: {
|
|
26437
26442
|
dataType: customField.dataType,
|
|
26438
|
-
|
|
26443
|
+
rawValue: dataValue
|
|
26439
26444
|
}
|
|
26440
26445
|
};
|
|
26441
26446
|
};
|
|
@@ -30893,6 +30898,7 @@ const CUSTOM_FIELD_MATCH_MODE = {
|
|
|
30893
30898
|
dropdown: FilterMatchMode.IN,
|
|
30894
30899
|
multiselect: "ONE_OF_STRINGIFIED_ARRAY",
|
|
30895
30900
|
calendar: "IN_UNIX_EPOCH_RANGE",
|
|
30901
|
+
calendartime: "IN_UNIX_EPOCH_RANGE",
|
|
30896
30902
|
rangenumber: "IN_CURRENCY_RANGE"
|
|
30897
30903
|
};
|
|
30898
30904
|
const parseAssetStaticFilter = (filter4) => {
|
|
@@ -62613,6 +62619,14 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent({
|
|
|
62613
62619
|
modelValue: filter4.value[`customFields[${field2.field}]`],
|
|
62614
62620
|
"onUpdate:modelValue": ($event) => filter4.value[`customFields[${field2.field}]`] = $event,
|
|
62615
62621
|
mode: "range"
|
|
62622
|
+
}), null, 16, ["modelValue", "onUpdate:modelValue"])) : field2.type === "calendartime" ? (openBlock(), createBlock(_sfc_main$$, mergeProps({
|
|
62623
|
+
key: 3,
|
|
62624
|
+
ref_for: true
|
|
62625
|
+
}, field2, {
|
|
62626
|
+
modelValue: filter4.value[`customFields[${field2.field}]`],
|
|
62627
|
+
"onUpdate:modelValue": ($event) => filter4.value[`customFields[${field2.field}]`] = $event,
|
|
62628
|
+
mode: "range",
|
|
62629
|
+
"show-time": ""
|
|
62616
62630
|
}), null, 16, ["modelValue", "onUpdate:modelValue"])) : createCommentVNode("", true)
|
|
62617
62631
|
], 64);
|
|
62618
62632
|
}), 128)) : createCommentVNode("", true)
|