MCPcopy
hub / github.com/ocsjs/ocsjs / callback

Function callback

packages/scripts/src/projects/cx.ts:2091–2114  ·  view source on GitHub ↗
(finishedRate, uploadable)

Source from the content-addressed store, hash-verified

2089 type: upload,
2090 results,
2091 async callback(finishedRate, uploadable) {
2092 const msg = `完成率 ${finishedRate.toFixed(2)}% : ${uploadable ? '3秒后将自动提交' : '3秒后将自动保存'} `;
2093 $console.info(msg);
2094 $message.success({ content: msg, duration: 3 });
2095
2096 await $.sleep(3000);
2097
2098 if (uploadable) {
2099 // @ts-ignore 提交
2100 frameWindow.btnBlueSubmit();
2101
2102 await $.sleep(3000);
2103 /** 确定按钮 */
2104 // @ts-ignore 确定
2105 frameWindow.submitCheckTimes();
2106 // @ts-ignore 2024/4 更新后上方函数无法关闭弹窗,需要手动关闭确定弹窗
2107 top.$('#workpop').hide();
2108 } else {
2109 // @ts-ignore 禁止弹窗
2110 frameWindow.alert = () => {};
2111 // @ts-ignore 暂时保存
2112 frameWindow.noSubmit();
2113 }
2114 }
2115 });
2116
2117 // 还原尺寸状态

Callers 1

uploadHandlerMethod · 0.50

Calls 1

hideMethod · 0.80

Tested by

no test coverage detected