@iflyrpa/actions 4.1.3 → 4.1.4
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/dist/actions/shipinhaoPublish/index.d.ts +3 -0
- package/dist/bundle.js +12 -5
- package/dist/bundle.js.map +1 -1
- package/dist/index.js +12 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +12 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4402,7 +4402,7 @@ var __webpack_exports__ = {};
|
|
|
4402
4402
|
const package_json_namespaceObject = require("@iflyrpa/share/package.json");
|
|
4403
4403
|
var package_json_default = /*#__PURE__*/ __webpack_require__.n(package_json_namespaceObject);
|
|
4404
4404
|
var package_namespaceObject = {
|
|
4405
|
-
i8: "4.1.
|
|
4405
|
+
i8: "4.1.4"
|
|
4406
4406
|
};
|
|
4407
4407
|
const share_namespaceObject = require("@iflyrpa/share");
|
|
4408
4408
|
const external_node_fs_namespaceObject = require("node:fs");
|
|
@@ -18719,6 +18719,9 @@ var __webpack_exports__ = {};
|
|
|
18719
18719
|
function mock_getTimeStamp(length) {
|
|
18720
18720
|
return Date.now().toString().substring(0, length);
|
|
18721
18721
|
}
|
|
18722
|
+
function normalizePublishContent(content) {
|
|
18723
|
+
return content.replace(/\r\n/g, "\n").replace(/\n{4,}/g, "\n\n");
|
|
18724
|
+
}
|
|
18722
18725
|
async function mock_getUserInfo(cookies, http) {
|
|
18723
18726
|
const requestBody = {
|
|
18724
18727
|
timestamp: mock_getTimeStamp(13),
|
|
@@ -18858,6 +18861,7 @@ var __webpack_exports__ = {};
|
|
|
18858
18861
|
async function publishDynamic(cookies, uin, fingerPrintDeviceId, aId, proxyHttp, confParams, params) {
|
|
18859
18862
|
const topicList = params.topic || [];
|
|
18860
18863
|
const location = params.address ? buildLocation(params.address) : {};
|
|
18864
|
+
const normalizedContent = normalizePublishContent(params.content);
|
|
18861
18865
|
const publishData = {
|
|
18862
18866
|
clientid: generateUUID(),
|
|
18863
18867
|
timestamp: mock_getTimeStamp(13),
|
|
@@ -18880,7 +18884,7 @@ var __webpack_exports__ = {};
|
|
|
18880
18884
|
handleFlag: 2,
|
|
18881
18885
|
topics: topicList,
|
|
18882
18886
|
objectDesc: {
|
|
18883
|
-
description: buildDescription(
|
|
18887
|
+
description: buildDescription(normalizedContent, topicList),
|
|
18884
18888
|
event: {},
|
|
18885
18889
|
extReading: {
|
|
18886
18890
|
...params.link,
|
|
@@ -18896,7 +18900,7 @@ var __webpack_exports__ = {};
|
|
|
18896
18900
|
shortTitle: "",
|
|
18897
18901
|
finderNewlifeDesc: {
|
|
18898
18902
|
richTextTitle: params.title,
|
|
18899
|
-
richTextJson: buildRichTextJson(params.title,
|
|
18903
|
+
richTextJson: buildRichTextJson(params.title, normalizedContent),
|
|
18900
18904
|
fromRichPublisher: 1
|
|
18901
18905
|
}
|
|
18902
18906
|
}
|
|
@@ -18904,7 +18908,7 @@ var __webpack_exports__ = {};
|
|
|
18904
18908
|
if (params.scheduledPublish) publishData.effectiveTime = params.scheduledPublish;
|
|
18905
18909
|
const objectDesc = publishData.objectDesc;
|
|
18906
18910
|
if (topicList.length) objectDesc.topic = {
|
|
18907
|
-
finderTopicInfo: buildTopicXml(
|
|
18911
|
+
finderTopicInfo: buildTopicXml(normalizedContent, topicList)
|
|
18908
18912
|
};
|
|
18909
18913
|
if (params.collection) objectDesc.topic = {
|
|
18910
18914
|
..."object" == typeof objectDesc.topic && null !== objectDesc.topic ? objectDesc.topic : {},
|
|
@@ -19807,7 +19811,10 @@ var __webpack_exports__ = {};
|
|
|
19807
19811
|
publishType: schemas_enum([
|
|
19808
19812
|
"1",
|
|
19809
19813
|
"2"
|
|
19810
|
-
]).optional()
|
|
19814
|
+
]).optional(),
|
|
19815
|
+
tagInfo: looseObject({
|
|
19816
|
+
tagType: schemas_number().int()
|
|
19817
|
+
}).optional()
|
|
19811
19818
|
});
|
|
19812
19819
|
const shipinhaoPublish = async (task, params)=>{
|
|
19813
19820
|
task.logger.info(`shipinhaoPublish actionType: ${params.actionType}`);
|