zzz-pc-view 0.0.86 → 0.0.88

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zzz-pc-view",
3
- "version": "0.0.86",
3
+ "version": "0.0.88",
4
4
  "main": "src/index.umd.js",
5
5
  "module": "src/index.es.js",
6
6
  "types": "src/index.d.ts",
package/src/index.es.js CHANGED
@@ -15,7 +15,7 @@ const fn = () => {
15
15
  };
16
16
  const object = Object.freeze({});
17
17
  const list$1 = Object.freeze([]);
18
- const index$g = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
18
+ const index$h = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19
19
  __proto__: null,
20
20
  fn,
21
21
  list: list$1,
@@ -1665,7 +1665,7 @@ const tree = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty
1665
1665
  sortTree,
1666
1666
  toFlat
1667
1667
  }, Symbol.toStringTag, { value: "Module" }));
1668
- const index$f = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1668
+ const index$g = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1669
1669
  __proto__: null,
1670
1670
  completeByDate,
1671
1671
  formatValue,
@@ -1748,7 +1748,7 @@ const createDataTimesByLength = (beginTime, length, interval, dateUnit, repeat)
1748
1748
  endDate[setMethodName](endDate[getMethodName]() + length - 1);
1749
1749
  return createDataTimesByRange([new ZDate(beginTime), endDate], interval, dateUnit, repeat);
1750
1750
  };
1751
- const index$e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1751
+ const index$f = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1752
1752
  __proto__: null,
1753
1753
  HttpResponse,
1754
1754
  createDataTimesByLength,
@@ -1834,7 +1834,7 @@ const create = (option) => {
1834
1834
  return request;
1835
1835
  };
1836
1836
  };
1837
- const index$d = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1837
+ const index$e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1838
1838
  __proto__: null,
1839
1839
  ABORTED_CODE,
1840
1840
  HttpRequestError,
@@ -1911,11 +1911,41 @@ const useHttpRequestInterval = (request, ms) => {
1911
1911
  abort
1912
1912
  };
1913
1913
  };
1914
- const index$c = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1914
+ const index$d = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1915
1915
  __proto__: null,
1916
1916
  useHttpRequestInterval,
1917
1917
  useInterval
1918
1918
  }, Symbol.toStringTag, { value: "Module" }));
1919
+ const selectCtrlByAll = (param) => {
1920
+ const { keyProp } = param;
1921
+ let response2 = param.list.map((item) => item[keyProp]);
1922
+ if (param.toMap) {
1923
+ response2 = toTrue(response2);
1924
+ }
1925
+ return response2;
1926
+ };
1927
+ const selectCtrlByInvert = (param) => {
1928
+ const { keyProp, selected, defaultBoolean } = param;
1929
+ return param.toMap ? param.list.reduce(
1930
+ (map2, item) => {
1931
+ const key2 = item[keyProp];
1932
+ map2[key2] = Object.prototype.hasOwnProperty.call(selected, key2) ? !selected[key2] : defaultBoolean;
1933
+ return map2;
1934
+ },
1935
+ {}
1936
+ ) : param.list.reduce((list2, item) => {
1937
+ const key2 = item[keyProp];
1938
+ if (Object.prototype.hasOwnProperty.call(selected, key2) ? !selected[key2] : defaultBoolean) {
1939
+ list2.push(key2);
1940
+ }
1941
+ return list2;
1942
+ }, []);
1943
+ };
1944
+ const index$c = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1945
+ __proto__: null,
1946
+ selectCtrlByAll,
1947
+ selectCtrlByInvert
1948
+ }, Symbol.toStringTag, { value: "Module" }));
1919
1949
  const ZUtils = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1920
1950
  __proto__: null,
1921
1951
  WithNew,
@@ -1924,13 +1954,14 @@ const ZUtils = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProper
1924
1954
  addCommasToNumber,
1925
1955
  combine,
1926
1956
  decrypt,
1927
- empty: index$g,
1957
+ empty: index$h,
1928
1958
  encrypt,
1929
- httpRequest: index$d,
1930
- interval: index$c,
1931
- mock: index$e,
1959
+ httpRequest: index$e,
1960
+ interval: index$d,
1961
+ mock: index$f,
1962
+ operator: index$c,
1932
1963
  parse,
1933
- reduce: index$f,
1964
+ reduce: index$g,
1934
1965
  related,
1935
1966
  stringify,
1936
1967
  toFixed,