tx-sider 2.3.32 → 2.3.33

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/lib/TXUI.mjs CHANGED
@@ -54479,7 +54479,18 @@ function useCcflowCall(callBack) {
54479
54479
  newVersionList: []
54480
54480
  });
54481
54481
  const init = () => {
54482
- connection.value = new HubConnectionBuilder().withUrl(`${jumpUrl}/api/basis-management/signalr?Bearer=` + localStorage.getItem("token"), {}).withAutomaticReconnect([1e3, 4e3, 1e3, 4e3]).configureLogging(LogLevel.Error).build();
54482
+ connection.value = new HubConnectionBuilder().withUrl(
54483
+ `${jumpUrl}/api/basis-management/signalr`,
54484
+ {
54485
+ accessTokenFactory: () => {
54486
+ const token = localStorage.getItem("token");
54487
+ if (!token) {
54488
+ throw new Error("No authentication token found");
54489
+ }
54490
+ return token;
54491
+ }
54492
+ }
54493
+ ).withAutomaticReconnect([1e3, 4e3, 1e3, 4e3]).configureLogging(LogLevel.Error).build();
54483
54494
  connection.value.on("GetNum", (res) => {
54484
54495
  ccflowData.todoList = res;
54485
54496
  });