@taole/dev-helper 0.1.22 → 0.1.23
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.
|
@@ -274,7 +274,13 @@
|
|
|
274
274
|
this._clipboardTextPs = new Promise(async (resolve, reject) => {
|
|
275
275
|
try {
|
|
276
276
|
await resolveTwKit();
|
|
277
|
-
|
|
277
|
+
let urlText = `https://${twKit.isTest ? 'y-test.tuwan.com' : 'y.tuwan.com'}/events/app_transfer_page?extinfo=` + encodeURIComponent(extinfo);
|
|
278
|
+
try {
|
|
279
|
+
const info = JSON.parse(extinfo);
|
|
280
|
+
if (info && info.openType == 3 && info.isPop && info.url) {
|
|
281
|
+
urlText = info.url;
|
|
282
|
+
}
|
|
283
|
+
} catch (e) {}
|
|
278
284
|
const shorUrl = await twKit.genShortUrl(urlText);
|
|
279
285
|
this._clipboardText = `【${this._appInfo.app_name}】 ${shorUrl} `;
|
|
280
286
|
this._log("initClipboardText success", this._clipboardText);
|
package/open-diandian/index.js
CHANGED
|
@@ -269,7 +269,13 @@ function createOpenDiandianElementClass() {
|
|
|
269
269
|
this._clipboardTextPs = new Promise(async (resolve, reject) => {
|
|
270
270
|
try {
|
|
271
271
|
await resolveTwKit();
|
|
272
|
-
|
|
272
|
+
let urlText = `https://${twKit.isTest ? 'y-test.tuwan.com' : 'y.tuwan.com'}/events/app_transfer_page?extinfo=` + encodeURIComponent(extinfo);
|
|
273
|
+
try {
|
|
274
|
+
const info = JSON.parse(extinfo);
|
|
275
|
+
if (info && info.openType == 3 && info.isPop && info.url) {
|
|
276
|
+
urlText = info.url;
|
|
277
|
+
}
|
|
278
|
+
} catch (e) {}
|
|
273
279
|
const shorUrl = await twKit.genShortUrl(urlText);
|
|
274
280
|
this._clipboardText = `【${this._appInfo.app_name}】 ${shorUrl} `;
|
|
275
281
|
this._log("initClipboardText success", this._clipboardText);
|