@freelog/tools-lib 0.1.148 → 0.1.151

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.
@@ -122,8 +122,9 @@ var RESOURCE_NAME = /*#__PURE__*/new RegExp(/^(?!.*(\\|\/|:|\*|\?|"|<|>|\||\s|@|
122
122
  // export const RESOURCE_TYPE: RegExp = new RegExp(/^(?!_)[a-z0-9_]{3,20}(?<!_)$/);
123
123
 
124
124
  var RESOURCE_TYPE = /*#__PURE__*/new RegExp(/^[a-z0-9][a-z0-9_]{1,18}[a-z0-9]$/); // 自定义属性键
125
+ // export const CUSTOM_KEY: RegExp = new RegExp(/^[a-zA-Z0-9_]{1,20}$/);
125
126
 
126
- var CUSTOM_KEY = /*#__PURE__*/new RegExp(/^[a-zA-Z0-9_]{1,20}$/); // 节点名称
127
+ var CUSTOM_KEY = /*#__PURE__*/new RegExp(/^[a-zA-Z_][a-zA-Z0-9_]{1,19}$/); // 节点名称
127
128
 
128
129
  var NODE_NAME = /*#__PURE__*/new RegExp(/^[\u4E00-\u9FA5|a-zA-Z0-9]{2,24}$/); // 节点地址
129
130
  // export const NODE_DOMAIN: RegExp = new RegExp(/^(?!-)[a-z0-9-]{4,24}(?<!-)$/);
@@ -996,21 +997,26 @@ function details(params) {
996
997
  });
997
998
  }
998
999
  function nodes(params) {
999
- // return FUtil.Axios.get('/v2/nodes', {
1000
- // params
1001
- // });
1002
1000
  return FUtil.Request({
1003
1001
  method: 'GET',
1004
1002
  url: "/v2/nodes",
1005
1003
  params: params
1006
1004
  });
1007
1005
  }
1006
+ function setNodeInfo(params) {
1007
+ return FUtil.Request({
1008
+ method: 'POST',
1009
+ url: "/v2/nodes/setNodeInfo",
1010
+ data: params
1011
+ });
1012
+ }
1008
1013
 
1009
1014
  var Node = {
1010
1015
  __proto__: null,
1011
1016
  create: create,
1012
1017
  details: details,
1013
- nodes: nodes
1018
+ nodes: nodes,
1019
+ setNodeInfo: setNodeInfo
1014
1020
  };
1015
1021
 
1016
1022
  var _excluded$1 = ["presentableId"],
@@ -1763,6 +1769,53 @@ function availableTags(_ref16) {
1763
1769
  params: params
1764
1770
  });
1765
1771
  }
1772
+ function resourceTypes$1(_temp) {
1773
+ var _ref17 = _temp === void 0 ? {} : _temp,
1774
+ params = _extends({}, _ref17);
1775
+
1776
+ return FUtil.Request({
1777
+ method: 'GET',
1778
+ url: "/v2/resources/types/listSimpleByGroup",
1779
+ params: params
1780
+ });
1781
+ }
1782
+ function ListSimpleByParentCode(_ref18) {
1783
+ var params = _extends({}, _ref18);
1784
+
1785
+ return FUtil.Request({
1786
+ method: 'GET',
1787
+ url: "/v2/resources/types/listSimpleByParentCode",
1788
+ params: params
1789
+ });
1790
+ }
1791
+ function getResourceTypeInfoByCode(_ref19) {
1792
+ var params = _extends({}, _ref19);
1793
+
1794
+ return FUtil.Request({
1795
+ method: 'GET',
1796
+ url: "/v2/resources/types/getInfoByCode",
1797
+ params: params
1798
+ });
1799
+ }
1800
+ function getResourceAttrListSimple(_ref20) {
1801
+ var params = _extends({}, _ref20);
1802
+
1803
+ return FUtil.Request({
1804
+ method: 'GET',
1805
+ url: "/v2/resources/attrs/listSimple",
1806
+ params: params
1807
+ });
1808
+ }
1809
+ function listSimple4Recently(_temp2) {
1810
+ var _ref21 = _temp2 === void 0 ? {} : _temp2,
1811
+ params = _extends({}, _ref21);
1812
+
1813
+ return FUtil.Request({
1814
+ method: 'GET',
1815
+ url: "/v2/resources/types/listSimple4Recently",
1816
+ params: params
1817
+ });
1818
+ }
1766
1819
 
1767
1820
  var Resource = {
1768
1821
  __proto__: null,
@@ -1792,7 +1845,12 @@ var Resource = {
1792
1845
  resourcesCount: resourcesCount,
1793
1846
  batchAuth: batchAuth$1,
1794
1847
  resourcesRecommend: resourcesRecommend,
1795
- availableTags: availableTags
1848
+ availableTags: availableTags,
1849
+ resourceTypes: resourceTypes$1,
1850
+ ListSimpleByParentCode: ListSimpleByParentCode,
1851
+ getResourceTypeInfoByCode: getResourceTypeInfoByCode,
1852
+ getResourceAttrListSimple: getResourceAttrListSimple,
1853
+ listSimple4Recently: listSimple4Recently
1796
1854
  };
1797
1855
 
1798
1856
  var _excluded$4 = ["loginName"];
@@ -2845,13 +2903,13 @@ function getFilesSha1Info(_x, _x2) {
2845
2903
 
2846
2904
  function _getFilesSha1Info() {
2847
2905
  _getFilesSha1Info = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, cdPartially) {
2848
- var sha1, delay, needHandleSha1, allData, _yield$Storage$filesL, ret, errCode, data, msg, finishedInfo;
2906
+ var sha1, resourceTypeCode, delay, needHandleSha1, allData, _yield$Storage$filesL, ret, errCode, data, msg, finishedInfo;
2849
2907
 
2850
2908
  return _regeneratorRuntime().wrap(function _callee$(_context) {
2851
2909
  while (1) {
2852
2910
  switch (_context.prev = _context.next) {
2853
2911
  case 0:
2854
- sha1 = _ref.sha1;
2912
+ sha1 = _ref.sha1, resourceTypeCode = _ref.resourceTypeCode;
2855
2913
 
2856
2914
  if (cdPartially === void 0) {
2857
2915
  cdPartially = function cdPartially() {
@@ -2878,7 +2936,8 @@ function _getFilesSha1Info() {
2878
2936
 
2879
2937
  _context.next = 10;
2880
2938
  return filesListInfo({
2881
- sha1: needHandleSha1.join(',')
2939
+ sha1: needHandleSha1.join(','),
2940
+ resourceTypeCode: resourceTypeCode
2882
2941
  });
2883
2942
 
2884
2943
  case 10:
@@ -2921,9 +2980,9 @@ function _getFilesSha1Info() {
2921
2980
  state = 'success';
2922
2981
  } else if (d.metaAnalyzeStatus === 3) {
2923
2982
  state = 'fail';
2924
- }
2983
+ } // console.log(d, '90wieojiksdjf;lkasdjf;lksdjflksjdflkjsdlfkjsdlkj');
2984
+
2925
2985
 
2926
- console.log(d, '90wieojiksdjf;lkasdjf;lksdjflksjdflkjsdlfkjsdlkj');
2927
2986
  return {
2928
2987
  sha1: d.sha1,
2929
2988
  state: state,
@@ -2969,6 +3028,22 @@ var recombination = {
2969
3028
  getFilesSha1Info: getFilesSha1Info
2970
3029
  };
2971
3030
 
3031
+ function operationCategories(_temp) {
3032
+ var _ref = _temp === void 0 ? {} : _temp,
3033
+ params = _extends({}, _ref);
3034
+
3035
+ return FUtil.Request({
3036
+ method: 'GET',
3037
+ url: "/v2/resources/operation-categories/listSimpleByGroup",
3038
+ params: params
3039
+ });
3040
+ }
3041
+
3042
+ var Operation = {
3043
+ __proto__: null,
3044
+ operationCategories: operationCategories
3045
+ };
3046
+
2972
3047
  var FServiceAPI = {
2973
3048
  Node: Node,
2974
3049
  Exhibit: Exhibit,
@@ -2986,7 +3061,8 @@ var FServiceAPI = {
2986
3061
  Statistic: Statistic,
2987
3062
  I18n: I18n,
2988
3063
  Policy: Policy,
2989
- recombination: recombination
3064
+ recombination: recombination,
3065
+ Operation: Operation
2990
3066
  };
2991
3067
 
2992
3068
  var codeMessage = {