@x-9lab/xlab 1.5.0 → 1.5.1
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.
|
@@ -18,6 +18,7 @@ _export(exports, {
|
|
|
18
18
|
params: ()=>params,
|
|
19
19
|
responseResult: ()=>responseResult,
|
|
20
20
|
getMD5: ()=>getMD5,
|
|
21
|
+
md5: ()=>md5,
|
|
21
22
|
object2Array: ()=>object2Array,
|
|
22
23
|
formatJson: ()=>formatJson,
|
|
23
24
|
toJsonp: ()=>toJsonp,
|
|
@@ -100,6 +101,11 @@ function checkLogger() {
|
|
|
100
101
|
});
|
|
101
102
|
return _crypto.default.createHash("md5").update(JSON.stringify(conditions), "utf8").digest("hex");
|
|
102
103
|
}
|
|
104
|
+
/**将一个输入字符串转为 md5 */ function md5(str) {
|
|
105
|
+
var md5 = _crypto.default.createHash("md5");
|
|
106
|
+
md5.update(str);
|
|
107
|
+
return md5.digest("hex");
|
|
108
|
+
}
|
|
103
109
|
/**
|
|
104
110
|
* 对象值转化为数组
|
|
105
111
|
* @param obj 待转的对象
|