odant-work 1.0.39 → 1.0.41
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/#system/package-manifest.json +29 -29
- package/$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/chat.js +212 -72
- package/$server/$folder/$file/$task/class.js +3 -0
- package/$server/$folder/$file/$task/handlers/pages/form/file/$handler/file.js +33 -1
- package/$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/feed.js +65 -1
- package/$server/$folder/lib/consultant/consultant.js +9 -0
- package/MODELS/$ai/$folder/$class/$ai/handlers/pages/form/trainer/$handler/trainer.js +27 -7
- package/MODELS/$ai/$folder/$class/$provider/handlers/pages/form/trainer/$handler/trainer.js +2 -2
- package/package.json +1 -1
- package/sources/data/progress.md +11 -0
- package/sources/modules/agent/loop.js +39 -4
- package/sources/modules/agent/permissions.js +271 -111
- package/sources/modules/agent/session.js +89 -2
- package/sources/modules/agent/system.js +10 -3
- package/sources/modules/agent/tools/chrome.js +25 -4
- package/sources/modules/agent/tools/desktop.js +184 -170
- package/sources/modules/agent/tools/dev/checks.js +160 -160
- package/sources/modules/agent/tools/dev/git.js +276 -276
- package/sources/modules/agent/tools/net.js +45 -45
- package/sources/modules/agent/tools/os-proc.js +179 -169
- package/sources/modules/agent/tools/services.js +280 -275
- package/sources/modules/trainer/index.js +1 -0
- package/sources/modules/trainer/local-engine.js +321 -55
- package/sources/modules/trainer/worker/local_infer_worker.py +34 -12
- package/sources/reactor.js +8 -0
- package/sources/server/class/feed.js +21 -12
- package/sources/server/logs.js +50 -8
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"packageName": "odant-work",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.41",
|
|
4
4
|
"createdAt": 1794916599757,
|
|
5
|
-
"updatedAt":
|
|
5
|
+
"updatedAt": 1794928249512,
|
|
6
6
|
"files": {
|
|
7
7
|
"run.mjs": "f8918c612e8641e9beee06221be6680aa6fd21f25468451f2ac857fd51772266",
|
|
8
|
-
"package.json": "
|
|
9
|
-
"package-lock.json": "
|
|
8
|
+
"package.json": "7e0a770e32c87fdfa3213694b380bb3bc458b497a90556d57038b794ec034784",
|
|
9
|
+
"package-lock.json": "1ca73ad7e453d902d18b754d7110a782ad321284af39b6010c41f84f6ae8f8e5",
|
|
10
10
|
"sources/client/class.js": "c3fb8f143fc83aaa2df1ddeddd412d2d4dfe88656578095babe2df34fb3b3922",
|
|
11
11
|
"sources/client/field.js": "ffdd50fa8b6ec515cc42da5fca96658ff2b20e274601a1f926e0031372467a19",
|
|
12
12
|
"sources/client/file.js": "667101d75fa30840370d5be232e518aaac7c1fd52ca05a12da560eef6c0848b0",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"sources/data/objects.js": "23f51d5b00cd766fe27879b874738bc9bd9056bd6e27285fb7a52926c0dbc6a8",
|
|
27
27
|
"sources/data/posting.js": "6595bb9ec632539ae7629504db327d25a491e61c1cdc598bb43d08ea0d45548d",
|
|
28
28
|
"sources/data/print.js": "704f0f2fc80c6466a4196e4650d763150cf9b592eab14ea67ece85d51100107c",
|
|
29
|
-
"sources/data/progress.md": "
|
|
29
|
+
"sources/data/progress.md": "d7e89a4313cbc4b16bf10b5800e6f292e0bba39390395a0e03817f26308636fc",
|
|
30
30
|
"sources/data/readme.md": "593fa2ae07aa91bc26d7542275da6953a9cd419240a9a49e00cb62fb9d5d8e36",
|
|
31
31
|
"sources/data/reports.js": "0330f404860fe2589a7d46a2f0fe690ca23249bd841a062a26718742d4fd11d6",
|
|
32
32
|
"sources/data/schema.js": "1c994f9adb76c156dc86601dd6b1046376b66549b041e1a58aa1727b5476bdbe",
|
|
@@ -67,39 +67,39 @@
|
|
|
67
67
|
"sources/modules/agent/hooks.js": "b74e9d8f4b491b6d16d979891de69941955e50852289f55589c82997405c9048",
|
|
68
68
|
"sources/modules/agent/index.js": "eeb1f34f9ca36e13749389ea544f23e385891d355f6050206bff3f6bd106ceeb",
|
|
69
69
|
"sources/modules/agent/log.js": "03ae1979e2b00459178deda49847c30ed75937fc4f3eea9b778ca6c0f8c4ded0",
|
|
70
|
-
"sources/modules/agent/loop.js": "
|
|
70
|
+
"sources/modules/agent/loop.js": "efff4ddb13b77468c662a966fa4d6e3c8acf060d30d94f4b0132bcc9d30fba12",
|
|
71
71
|
"sources/modules/agent/mcp-pool.js": "aa4e75e2fcfe07883f9b721b33cee642fbbe11b8f416f8cd6a81f9c1ab39edde",
|
|
72
|
-
"sources/modules/agent/permissions.js": "
|
|
72
|
+
"sources/modules/agent/permissions.js": "b3a3b73feea646eb765a4c0b71f8c63ecb36c0d616cf237a9fb040fb19590fbc",
|
|
73
73
|
"sources/modules/agent/plugins.js": "9aed13c2d7bbf66dcd165f23b3969874561aea470dc16dac1435d183696cfda5",
|
|
74
74
|
"sources/modules/agent/readme.md": "c8d461218b8b552be58697f154c5bc4dba9858e6387aff6acfbc794c1286b89d",
|
|
75
75
|
"sources/modules/agent/recovery.js": "7a61dfdb2aef10b5049aee85d579379fdf98af3524f8509428ebc5a613bad92d",
|
|
76
76
|
"sources/modules/agent/resources.js": "2a52a31b2a96e17c713a6e311cbf0fe31a6debf8cd596e8e8067c722e6299eb2",
|
|
77
77
|
"sources/modules/agent/scheduler.js": "26cc6fffb9f570d501dbef5261b274323fe8e8165d1598097ff8f77d32cdd9cf",
|
|
78
|
-
"sources/modules/agent/session.js": "
|
|
79
|
-
"sources/modules/agent/system.js": "
|
|
78
|
+
"sources/modules/agent/session.js": "1f5e9f224e4f1db8fc486861eb9f95478b5010a557db09f9af057d98ba3970d3",
|
|
79
|
+
"sources/modules/agent/system.js": "ec1d0cf29c490b164b4adb0025a138bd12e037276d6286676a085eff2e29ec9b",
|
|
80
80
|
"sources/modules/agent/taint.js": "bf6aee5cc7e8b15ac365525fa74645d4a92da5ce1bdbcdba012e80767b5c7063",
|
|
81
81
|
"sources/modules/agent/tools/branch.js": "1ac9ccafcf292801575e8205ec7b63ab7dd6d53b03ad2a67cc3571092b716bcf",
|
|
82
82
|
"sources/modules/agent/tools/browse.js": "86179a951e82017e17a434b0a4e7678a9211693bf10d614c4c03113d219c0ca4",
|
|
83
83
|
"sources/modules/agent/tools/browser.js": "39db0658cd9bdc1ace994d39ce74c8f601aec576a2a208405bccac58b762c4af",
|
|
84
|
-
"sources/modules/agent/tools/chrome.js": "
|
|
84
|
+
"sources/modules/agent/tools/chrome.js": "ed865bd089bf1ca79bdc2403ac5bc4a26e5b5ac9811ddf841e2d9b9d27ab1aba",
|
|
85
85
|
"sources/modules/agent/tools/computer.js": "2f45ae558ca0a71c14673fb9d598217a7705ef6833e7321ad2e3f5cfc6368e3f",
|
|
86
86
|
"sources/modules/agent/tools/connect.js": "29424fdf9b93d4bf5e81b37e82d5a9d0f76680ea332bf5d4b44580a138cedc5e",
|
|
87
|
-
"sources/modules/agent/tools/desktop.js": "
|
|
88
|
-
"sources/modules/agent/tools/dev/checks.js": "
|
|
89
|
-
"sources/modules/agent/tools/dev/git.js": "
|
|
87
|
+
"sources/modules/agent/tools/desktop.js": "425f21331dcc30325bb692b69d20ebab90e0353fe6325919d062f2b72e3edaa8",
|
|
88
|
+
"sources/modules/agent/tools/dev/checks.js": "1010523c5e9a79c5309507061c39d03d2fa881a0ef0420790df800c86a53dd11",
|
|
89
|
+
"sources/modules/agent/tools/dev/git.js": "0344191dab24553fdaa6414b59a931424542f9a1c0412f9ac071fe3f1f835ec8",
|
|
90
90
|
"sources/modules/agent/tools/dev/lsp.js": "9451a4dae048198bc3ec11d24063ef653e37b5d537606f00ec21c53c9f4a4516",
|
|
91
91
|
"sources/modules/agent/tools/dev/patch.js": "12c4398db554040e424b625ab1dc2aa584685af8973b55ef17d22464a893c60e",
|
|
92
92
|
"sources/modules/agent/tools/dev/search.js": "182a0137f858c97aa4c854c7185ba84a453d1eb9659e3fc831e78b6cc99d675f",
|
|
93
93
|
"sources/modules/agent/tools/docs.js": "3a2d9b07a79371424b9911a755e272b446d8f0940e7312a51a1d9cbf531d9ffa",
|
|
94
94
|
"sources/modules/agent/tools/memory.js": "48df8fa4c323eef62ea541e8c633fca4e2f49bdb7a4f744bbc5a397ebe156779",
|
|
95
95
|
"sources/modules/agent/tools/meta.js": "d3a50b81a1849920fadf114776802a88dd7bf1b8845f64a3d6358ca6a49436c3",
|
|
96
|
-
"sources/modules/agent/tools/net.js": "
|
|
96
|
+
"sources/modules/agent/tools/net.js": "6e2fe4753c5fd0334127d4d286a8b87defbc0f469a6e1b192e30c555675a583f",
|
|
97
97
|
"sources/modules/agent/tools/os-files.js": "7b27de7ca02f35635e6aa61b65c602ec5b9fa0eb656b703907c1ad93ef48f9f8",
|
|
98
|
-
"sources/modules/agent/tools/os-proc.js": "
|
|
98
|
+
"sources/modules/agent/tools/os-proc.js": "2247ac5e3c215325512572d9f7edf17e2a3b13c9f6aa162c1868330d6ef545f7",
|
|
99
99
|
"sources/modules/agent/tools/plugins.js": "1faca1c51259956e4c43c4b18bd4c0b4e573d10c1db9a66cd7f58236c1714ff8",
|
|
100
100
|
"sources/modules/agent/tools/sandbox.js": "bed67cb26f78c6128936902333d408705639441fb0ebe1154139ec1a2924c9da",
|
|
101
101
|
"sources/modules/agent/tools/schedule.js": "a93834b72fcf96f6bfee3d1763119b53dc218db6de0b8c901682bee2001313c8",
|
|
102
|
-
"sources/modules/agent/tools/services.js": "
|
|
102
|
+
"sources/modules/agent/tools/services.js": "e7558df700d6933819754e122e4ba9c68081855d0cc41b1dad27d34d080ce616",
|
|
103
103
|
"sources/modules/agent/tools/work/access.js": "a84468a3f7264a5ce6bd7588422277571f2c77a153bde572e981230661260751",
|
|
104
104
|
"sources/modules/agent/tools/work/classes.js": "fb6ae199f2b7d01613ea55d2447ba1c5fccd473cc377f85e06931f6114c44a03",
|
|
105
105
|
"sources/modules/agent/tools/work/common.js": "b0deead4550694601121d43cd524151c87b464f318a5581b6758018a7665cdf0",
|
|
@@ -178,20 +178,20 @@
|
|
|
178
178
|
"sources/modules/trainer/downloader.js": "d9e96cb07e7bf64386558be8c2265c482af35a513f42954250add6d5fc87bdc4",
|
|
179
179
|
"sources/modules/trainer/halogen.js": "eddc61b4acf5494703d599e4dc5811ce27aa34d60abe24fddadc1755d460c9fe",
|
|
180
180
|
"sources/modules/trainer/huggingface.js": "91878bb2975981e02dd21d2a587d7c345ef65cd2d7032c5769a63c9dba21f982",
|
|
181
|
-
"sources/modules/trainer/index.js": "
|
|
182
|
-
"sources/modules/trainer/local-engine.js": "
|
|
181
|
+
"sources/modules/trainer/index.js": "20809764a1bb4fd9334f741056c44dc8016459c1d362493f9bdab332b9411460",
|
|
182
|
+
"sources/modules/trainer/local-engine.js": "5dbdf6e1a222aa3710d84f16c263095c35b64cd32208d0453981399f710ab037",
|
|
183
183
|
"sources/modules/trainer/paths.js": "86d12a1f3a79127c2284a5e0eaf4f523fbf0f3aa8e13b92d8889ebf4fa5400f4",
|
|
184
184
|
"sources/modules/trainer/providers.js": "56ffd2de03449ecaa13751a7e82c615cf5f84e6f02bb0b34c4432c3d85db28da",
|
|
185
185
|
"sources/modules/trainer/runner.js": "328843672fe0c1bd7e8c35c2e25285c31a9f749e04814e64c32e8cae74086024",
|
|
186
186
|
"sources/modules/trainer/tar-stream.js": "52f1739579a01818b53d04a93fd05a91c49a0716019f309a6fca951ba112794f",
|
|
187
187
|
"sources/modules/trainer/transfer.js": "2c603d538e0f85e1794e2f304081fac136f0ff72f85d8b00c2141c7402b3a1fb",
|
|
188
|
-
"sources/modules/trainer/worker/local_infer_worker.py": "
|
|
188
|
+
"sources/modules/trainer/worker/local_infer_worker.py": "b9e63ff5f45d387c83c80450e47fb360d6cbc4250b5c10fdd7323f632a0c26e7",
|
|
189
189
|
"sources/modules/trainer/worker/unsloth_train.py": "7774d94ffa6f60eed20c57a8dfdc12621d5d9f74d594c605dff32ff70e321e33",
|
|
190
190
|
"sources/modules/user-profile/user-profile.js": "5c8fd002809848b204aee83a44161375e8144bffcc048fde748f4f778162bbef",
|
|
191
191
|
"sources/modules/user-profile/user-token.js": "3797685232684e9e80261a2e63f70cbff4ef1bcc3ded6f755800804e9848d7d9",
|
|
192
192
|
"sources/odant.png": "b0c0d28bb28125dac7e1305bca10569fb055d856261455d336931bc57a4705c1",
|
|
193
193
|
"sources/page.html": "18ec691a53f9be9611e7be665e138ca5490fb15e16ce42a1b47f79b8fe2310d3",
|
|
194
|
-
"sources/reactor.js": "
|
|
194
|
+
"sources/reactor.js": "fa132f59bac51e0d7b05a109b83100046eacddfc84576bef6115c2605b57ebf6",
|
|
195
195
|
"sources/readme.md": "045fa4d63779731d4c535deefa7bfb2956b021ab25a4d86b8dc41d6f964386f2",
|
|
196
196
|
"sources/server/access/audit.js": "b3e2cf891faf4ce97f7e8eb96a8482727ed1ad25d0ed5d6cc4e30eb922917952",
|
|
197
197
|
"sources/server/access/gateway.js": "6bb36197fc0b3fbae425a676d308b58c7c6391999f429ac277e32a13b2298283",
|
|
@@ -203,7 +203,7 @@
|
|
|
203
203
|
"sources/server/assert-class-id.js": "92b76c399487e54f935bc470ebbe61ef7897d7f79d4e6234fe42294e35d705d4",
|
|
204
204
|
"sources/server/class/archive.js": "1e8e3b47e1408934ce19f9ff77aae4a107b475c3f11f49e214f409f70eef1893",
|
|
205
205
|
"sources/server/class/base-template.js": "c868f497b8d7a3fd20e38563e8e99ab147ba1e3a1bfed35bcd2a0c3fdb6e9dbe",
|
|
206
|
-
"sources/server/class/feed.js": "
|
|
206
|
+
"sources/server/class/feed.js": "a318a9e5f7c065dffc3944a1194846ca0d70d12fc4481aa5cab2ce82f99e8edb",
|
|
207
207
|
"sources/server/class/scaffold.js": "cf389c91f88e52142a723a5b29df590a1920a09933565948aff91b8bd82f6344",
|
|
208
208
|
"sources/server/class/script.js": "146ef61b5a55201c34f80de4bbfcb116922f03348773548c041bdba0e53aba64",
|
|
209
209
|
"sources/server/class/search.js": "c3d50a82769d65cfabdc0b83c73c289cec212ac5feb685aec4b1489b206546dd",
|
|
@@ -214,7 +214,7 @@
|
|
|
214
214
|
"sources/server/folder.js": "c92a9872e214942a3b89ece192691295ec4c9576b5806b8050a62cb12ec1f970",
|
|
215
215
|
"sources/server/handler.js": "94a9d37075475cb7f1254eeb18b4706210a4d995a4139608ab0d1d3509ec5f3d",
|
|
216
216
|
"sources/server/index.js": "d2af9533f9bacdc6fb6c98412cc1e857f0750cca4c0a0560185c6f746f3d0c51",
|
|
217
|
-
"sources/server/logs.js": "
|
|
217
|
+
"sources/server/logs.js": "78fb5b2bd65e0694ecf253ca0d3c7b5f420a47802604546833d6650140ce6170",
|
|
218
218
|
"sources/server/memory-mark.js": "0db217ffd58d8212d8ad8d53ed90bf3c95c105586273fdfebf1dc27b6e99ab6c",
|
|
219
219
|
"sources/server/node.js": "c1aba780ddaa077ffcd63cd3387d1a5b96d67396651badfd39c5e65382f3a94d",
|
|
220
220
|
"sources/server/readme.md": "171ab173184008c748d8062f2473e8630b53ebc6a76b220a2547d5ae8bbd4999",
|
|
@@ -597,7 +597,7 @@
|
|
|
597
597
|
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/beep-start.mp3": "24004a82dd5274b852de766ef2b2ac035ca2d6b2aefc72086800968b4a98e77d",
|
|
598
598
|
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/chat-pending.js": "4ba4dd3d0b88c480336810e39b9e356ea209378b199430b8ecb2994efeb8ed69",
|
|
599
599
|
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/chat-task.js": "2cf4c5b6f7d4d96c585f0dd77253f67adef3d4e1dfebcbb9dcd06b9999cee869",
|
|
600
|
-
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/chat.js": "
|
|
600
|
+
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/chat.js": "b9b5121d598f1cd07d786ff6fb1c58f76d39a9add218d3ba16c3eaa2ce665f56",
|
|
601
601
|
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/class.js": "683e36e786d4587d1e2dfb166bd010fd48a8206790a97a4f4d8d39b57e9522bf",
|
|
602
602
|
"$server/$folder/$class/$structure/handlers/pages/form/chat/$handler/video.html": "91875653a9e988d18c19f9833200b9360eebd1df333137927b5440fcf61d5fd3",
|
|
603
603
|
"$server/$folder/$class/$structure/handlers/pages/form/database/$handler/class.js": "2b19ec5ff0c488f5d673ceab41421f8a8dc2f0536ba4e629ec8d3014dadda9e5",
|
|
@@ -733,13 +733,13 @@
|
|
|
733
733
|
"$server/$folder/$file/$office/handlers/preview/$handler/preview.js": "6c5d5bbbc20988794b817c6db526a014efcc502ad2e90cc95dbe3c67f5784596",
|
|
734
734
|
"$server/$folder/$file/$office/methods/onlyoffice_callback/$handler/class.js": "a0e07f8683bc33502434c634d37d3397bb5be014912d9b28c1c4bf7fcb5c8bd6",
|
|
735
735
|
"$server/$folder/$file/$office/methods/save/$handler/class.js": "88c7f2c6779ec77cba043558956a9892dd4e1802f12e8554dbd21e1afff03f4a",
|
|
736
|
-
"$server/$folder/$file/$task/class.js": "
|
|
736
|
+
"$server/$folder/$file/$task/class.js": "648dc3ee23d242e8193c351a2f3ca465ea88c87a6b37ca2c78db88ce68f36bc1",
|
|
737
737
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/class.js": "67034be6dc54c7116f9f7e4ac83e0bf62de02ca7af7498f3b0e19fee50bf0875",
|
|
738
|
-
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/file.js": "
|
|
738
|
+
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/file.js": "10acaf3e9a5b523a7638627ec900e72db17c6f999b1de98383b821169decb447",
|
|
739
739
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/readme.md": "c9ef3c69af48b7f2437c06b45e9fc7d08da1676663514cc963a9860abf89c3d3",
|
|
740
740
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/dock.js": "28f4ceebb28a87a5b3c287103a9c06d5728f04afc1b97f599211cb1d242a0a1c",
|
|
741
741
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/docs.js": "85dbc8d304b79dd917213b93d837f7882e5453dcdffa0c3f3176a0034da4cf72",
|
|
742
|
-
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/feed.js": "
|
|
742
|
+
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/feed.js": "826de311b1b243d83cb6e4ee624eff3941bff949074b16c91e7f4fec3786ef6f",
|
|
743
743
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/panel.js": "8a158cf43e87a6a70b4e0631a98a48fbd0aa977dd541cfb8308ad6d59ea431c9",
|
|
744
744
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/segments.js": "165030064982dc162586f368a8b0531afc297c401debf665def4e73ea6a8e32b",
|
|
745
745
|
"$server/$folder/$file/$task/handlers/pages/form/file/$handler/ui/util.js": "db0dca0c9d447034461dd94a408c9efff37999816a7df9acb505ceb4fdb703c0",
|
|
@@ -773,7 +773,7 @@
|
|
|
773
773
|
"$server/$folder/lib/calendar-form/calendar-form.js": "3035cab0a489c891d7dd7ed52ae5c475068b97361a1f7c855d500a0823614d1c",
|
|
774
774
|
"$server/$folder/lib/chat-item/chat-item.js": "6af09b84e5ef31c7e22007ba763bccf874d642afeff359414400ec36d4d5c560",
|
|
775
775
|
"$server/$folder/lib/class-picker/class-picker.js": "b166f0852b38bf91e2576931c62d2d54f27ce259e2e9f8f998e81cb17c6f153b",
|
|
776
|
-
"$server/$folder/lib/consultant/consultant.js": "
|
|
776
|
+
"$server/$folder/lib/consultant/consultant.js": "081f3b83040e0e5f1b4191541f01d571f362c38879420b2a240f9d0fbdb6a3c2",
|
|
777
777
|
"$server/$folder/lib/dialogs/confirm/confirm.js": "dea87a6fc521df05c79aa469bfb060bbb5056105758ef708fd058c6cb2c0d109",
|
|
778
778
|
"$server/$folder/lib/dialogs/input/input.js": "59f57a2514059d76529aa6fd062a6e0ac833f1d8b7a71dda7b8dcc07658df746",
|
|
779
779
|
"$server/$folder/lib/dialogs/popover/popover.js": "f845067f0db0f1851dcea596772aeb45d9916b37dd7de44a753033e5f14ede79",
|
|
@@ -976,13 +976,13 @@
|
|
|
976
976
|
"MODULES/Register/STRUCTS/Паспорт/$struct/class.js": "4a50808e4db7741b0384a775177545d71686a680ccda7ef0ec68bf81f9c988b5",
|
|
977
977
|
"MODELS/$ai/$folder/$class/$ai/class.js": "633d6226576af4ea9731a79fb3d1018a57b50e8e3c4e90464532ae30e39de5de",
|
|
978
978
|
"MODELS/$ai/$folder/$class/$ai/handlers/pages/form/trainer/$handler/class.js": "fe5ba834156495c28a34acd4b70a6b6b3bdfccb67ec7bf99e92a292afbb66d19",
|
|
979
|
-
"MODELS/$ai/$folder/$class/$ai/handlers/pages/form/trainer/$handler/trainer.js": "
|
|
979
|
+
"MODELS/$ai/$folder/$class/$ai/handlers/pages/form/trainer/$handler/trainer.js": "11072a2ac8ba6e842316ec03593d64c433bb3b965353bacb9cab08929f23449f",
|
|
980
980
|
"MODELS/$ai/$folder/$class/$ai/methods/chat/$method/class.js": "02fbb40d8ce93fbf568a6a8036c199e2af815be3d63d81f815aeb1da999db717",
|
|
981
981
|
"MODELS/$ai/$folder/$class/$provider/class.js": "069073501b93a95bb9d77e59ce71e53c7a8bcab2564c391b551f68a2453ac486",
|
|
982
982
|
"MODELS/$ai/$folder/$class/$provider/handlers/pages/form/provider/$handler/class.js": "8d327820cefd696d351ac4fa7998994039e4d57ef7a9f8ae297209e4dd1b0a9e",
|
|
983
983
|
"MODELS/$ai/$folder/$class/$provider/handlers/pages/form/provider/$handler/provider.js": "b9ddf0040a9cd12e0dacd2dd3a61a1f0e62686cc664d02ef446326bc3991f4ce",
|
|
984
984
|
"MODELS/$ai/$folder/$class/$provider/handlers/pages/form/trainer/$handler/class.js": "06b279a1c053deb37dd7401c84df7f9370309b8dfbd35b368ab1bab4f635cb3f",
|
|
985
|
-
"MODELS/$ai/$folder/$class/$provider/handlers/pages/form/trainer/$handler/trainer.js": "
|
|
985
|
+
"MODELS/$ai/$folder/$class/$provider/handlers/pages/form/trainer/$handler/trainer.js": "1ab10009c57d9ef962981d3b8da2a63746e8cb5e56f45234860209f9a45b207b",
|
|
986
986
|
"MODELS/$ai/$folder/$class/$provider/readme.md": "d6ceef2010231ab121510c3d3f35630dd7009a069c7723f6673a0e264799b227",
|
|
987
987
|
"MODELS/$ai/class.js": "54e1bbbde88f8b1f272ff7f5cad87243407591748a44719b7ec90ae2b4962de7",
|
|
988
988
|
"MODELS/$ai/readme.md": "90d70305a2c85312282cf67cc468a0f0b417495cb3d5b3d2ca60c6f44b81cb77",
|
|
@@ -309,6 +309,44 @@ ODA({is: 'oda-chat',
|
|
|
309
309
|
.mover>oda-button{
|
|
310
310
|
border-radius: 50%;
|
|
311
311
|
}
|
|
312
|
+
.feed-mode-bar {
|
|
313
|
+
position: absolute;
|
|
314
|
+
top: 8px;
|
|
315
|
+
right: 12px;
|
|
316
|
+
z-index: 8;
|
|
317
|
+
display: inline-flex;
|
|
318
|
+
align-items: center;
|
|
319
|
+
gap: 2px;
|
|
320
|
+
padding: 2px;
|
|
321
|
+
border-radius: 999px;
|
|
322
|
+
background: var(--content-background, #ffffff);
|
|
323
|
+
border: 1px solid var(--border-color, #cbd5e1);
|
|
324
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
|
|
325
|
+
opacity: 0.92;
|
|
326
|
+
}
|
|
327
|
+
.feed-mode-bar:hover {
|
|
328
|
+
opacity: 1;
|
|
329
|
+
}
|
|
330
|
+
.feed-mode-btn {
|
|
331
|
+
border: none;
|
|
332
|
+
background: transparent;
|
|
333
|
+
color: var(--content-color, inherit);
|
|
334
|
+
font: inherit;
|
|
335
|
+
font-size: 11px;
|
|
336
|
+
font-weight: 600;
|
|
337
|
+
padding: 4px 10px;
|
|
338
|
+
border-radius: 999px;
|
|
339
|
+
cursor: pointer;
|
|
340
|
+
white-space: nowrap;
|
|
341
|
+
transition: background 0.15s ease, color 0.15s ease;
|
|
342
|
+
}
|
|
343
|
+
.feed-mode-btn:hover:not(.active) {
|
|
344
|
+
background: var(--subtle-background, rgba(0, 0, 0, 0.05));
|
|
345
|
+
}
|
|
346
|
+
.feed-mode-btn.active {
|
|
347
|
+
background: var(--accent-color, #2563eb);
|
|
348
|
+
color: var(--accent-back, #ffffff);
|
|
349
|
+
}
|
|
312
350
|
</style>
|
|
313
351
|
|
|
314
352
|
<style>
|
|
@@ -327,6 +365,10 @@ ODA({is: 'oda-chat',
|
|
|
327
365
|
}
|
|
328
366
|
</style>
|
|
329
367
|
<div class="back"></div>
|
|
368
|
+
<div class="feed-mode-bar" ~if="showFeedModeToggle">
|
|
369
|
+
<button type="button" class="feed-mode-btn" ~class="{ active: feedMode === 'own' }" @tap="setFeedMode('own')" title="Мои записи из личного кабинета (/USERS)">Мои записи</button>
|
|
370
|
+
<button type="button" class="feed-mode-btn" ~class="{ active: feedMode === 'local' }" @tap="setFeedMode('local')" title="Местный лог открытой точки (доступно только BOSS)">Местный лог</button>
|
|
371
|
+
</div>
|
|
330
372
|
<chat-ribbon id="ribbon" :$item @chat-item-expanded="onCardExpanded($event)"></chat-ribbon>
|
|
331
373
|
<div class="mover" vertical hidden>
|
|
332
374
|
<oda-button :hidden="$('#ribbon').scrollTop < 0" content shadow icon="icons:chevron-right:270" @tap="$('#ribbon').scrollTop = -($('#ribbon').scrollHeight)"></oda-button>
|
|
@@ -515,7 +557,77 @@ ODA({is: 'oda-chat',
|
|
|
515
557
|
this.$('work-prompt-bar')?.focusInput();
|
|
516
558
|
},
|
|
517
559
|
focusedItem: null,
|
|
518
|
-
|
|
560
|
+
feedMode: 'own',
|
|
561
|
+
_canLocalFeed: false,
|
|
562
|
+
get showFeedModeToggle() {
|
|
563
|
+
return Boolean(this.$item && this.$item.type !== '$user' && this._canLocalFeed);
|
|
564
|
+
},
|
|
565
|
+
async _refreshCanLocalFeed(item = this.$item) {
|
|
566
|
+
if (!item || item.type === '$user') {
|
|
567
|
+
this._canLocalFeed = false;
|
|
568
|
+
return;
|
|
569
|
+
}
|
|
570
|
+
if (globalThis.WORK?.DEV_MODE) {
|
|
571
|
+
this._canLocalFeed = true;
|
|
572
|
+
return;
|
|
573
|
+
}
|
|
574
|
+
const key = (item.path || '') + '|' + (item.id || '');
|
|
575
|
+
try {
|
|
576
|
+
const cached = item.myRoles;
|
|
577
|
+
const roles = await Promise.resolve(cached !== undefined ? cached : item.fetch?.('roles')).catch(() => []);
|
|
578
|
+
const curKey = (this.$item?.path || '') + '|' + (this.$item?.id || '');
|
|
579
|
+
if (curKey !== key)
|
|
580
|
+
return;
|
|
581
|
+
this._canLocalFeed = Array.isArray(roles) && roles.includes('BOSS');
|
|
582
|
+
}
|
|
583
|
+
catch {
|
|
584
|
+
const curKey = (this.$item?.path || '') + '|' + (this.$item?.id || '');
|
|
585
|
+
if (curKey === key)
|
|
586
|
+
this._canLocalFeed = false;
|
|
587
|
+
}
|
|
588
|
+
},
|
|
589
|
+
setFeedMode(mode) {
|
|
590
|
+
const next = mode === 'local' && this.showFeedModeToggle ? 'local' : 'own';
|
|
591
|
+
if (this.feedMode === next)
|
|
592
|
+
return;
|
|
593
|
+
this.feedMode = next;
|
|
594
|
+
this.$('#ribbon')?.refreshFeed?.();
|
|
595
|
+
},
|
|
596
|
+
async _ownCabinet() {
|
|
597
|
+
const uid = globalThis.WORK?.uid;
|
|
598
|
+
if (!uid || typeof globalThis.WORK?.get_item !== 'function')
|
|
599
|
+
return null;
|
|
600
|
+
return globalThis.WORK.get_item('/USERS//' + uid).catch(() => null);
|
|
601
|
+
},
|
|
602
|
+
_isAccessError(err) {
|
|
603
|
+
return /доступ запрещ|forbidden|\b403\b/i.test(String(err?.message || err || ''));
|
|
604
|
+
},
|
|
605
|
+
async _runWithCabinetFallback(fn) {
|
|
606
|
+
const primary = this.$pdp?.$item || this.$item;
|
|
607
|
+
try {
|
|
608
|
+
return { target: primary, result: await fn(primary) };
|
|
609
|
+
}
|
|
610
|
+
catch (err) {
|
|
611
|
+
if (this.feedMode !== 'own' || primary?.type === '$user' || !this._isAccessError(err))
|
|
612
|
+
throw err;
|
|
613
|
+
const cab = await this._ownCabinet();
|
|
614
|
+
if (!cab)
|
|
615
|
+
throw err;
|
|
616
|
+
return { target: cab, result: await fn(cab) };
|
|
617
|
+
}
|
|
618
|
+
},
|
|
619
|
+
$item: {
|
|
620
|
+
$def: null,
|
|
621
|
+
set(n) {
|
|
622
|
+
const changed = Boolean(this._prevItem && this._prevItem !== n);
|
|
623
|
+
this._prevItem = n;
|
|
624
|
+
this.feedMode = 'own';
|
|
625
|
+
this._canLocalFeed = false;
|
|
626
|
+
this._refreshCanLocalFeed(n);
|
|
627
|
+
if (changed)
|
|
628
|
+
this.$('#ribbon')?.refreshFeed?.();
|
|
629
|
+
}
|
|
630
|
+
},
|
|
519
631
|
taskItem: null,
|
|
520
632
|
data: null,
|
|
521
633
|
streams: {},
|
|
@@ -618,25 +730,31 @@ ODA({is: 'oda-chat',
|
|
|
618
730
|
else if (this.$pdp.receivers.length)
|
|
619
731
|
params.receivers = this.$pdp.receivers.map(u => u.id);
|
|
620
732
|
const uploadedPaths = [];
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
733
|
+
const runWrite = typeof this._runWithCabinetFallback === 'function'
|
|
734
|
+
? fn => this._runWithCabinetFallback(fn)
|
|
735
|
+
: async fn => ({ target: this.$pdp.$item, result: await fn(this.$pdp.$item) });
|
|
736
|
+
await runWrite(async target => {
|
|
737
|
+
uploadedPaths.length = 0;
|
|
738
|
+
if (list.length) {
|
|
739
|
+
const formData = new FormData();
|
|
740
|
+
for (const file of list)
|
|
741
|
+
formData.append('file', file, file.name);
|
|
742
|
+
const fileParams = text ? { ...params, ignore_save_logs: true } : params;
|
|
743
|
+
const savedLogs = await target.save_files(formData, fileParams);
|
|
744
|
+
const arr = Array.isArray(savedLogs) ? savedLogs : (savedLogs ? [savedLogs] : []);
|
|
745
|
+
for (const l of arr) {
|
|
746
|
+
const p = await pathOfLog(l);
|
|
747
|
+
if (p)
|
|
748
|
+
uploadedPaths.push(p.startsWith('/') ? p : '/' + p);
|
|
749
|
+
}
|
|
632
750
|
}
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
}
|
|
751
|
+
if (text) {
|
|
752
|
+
const msgParams = { ...params, message: text };
|
|
753
|
+
if (uploadedPaths.length)
|
|
754
|
+
msgParams.includes = JSON.stringify(uploadedPaths);
|
|
755
|
+
await target.fetch('save_message', msgParams);
|
|
756
|
+
}
|
|
757
|
+
});
|
|
640
758
|
this.clear();
|
|
641
759
|
this.$('#ribbon')?.refreshFeed?.();
|
|
642
760
|
}
|
|
@@ -677,7 +795,7 @@ ODA({is: 'oda-chat',
|
|
|
677
795
|
this._awaitingLogExpand = false;
|
|
678
796
|
this._awaitTaskPath = '';
|
|
679
797
|
this._awaitTaskKey = '';
|
|
680
|
-
this._awaitKnown = this._collectKnownLogKeys();
|
|
798
|
+
this._awaitKnown = this._collectKnownLogKeys?.() || new Set();
|
|
681
799
|
clearTimeout(this._awaitTimer);
|
|
682
800
|
const item = this.$pdp.$item;
|
|
683
801
|
try {
|
|
@@ -718,27 +836,33 @@ ODA({is: 'oda-chat',
|
|
|
718
836
|
if (globalThis.WORK?.uid)
|
|
719
837
|
params.sender = globalThis.WORK.uid;
|
|
720
838
|
const canLookupTask = typeof globalThis.WORK?.get_item === 'function';
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
839
|
+
const runWrite = typeof this._runWithCabinetFallback === 'function'
|
|
840
|
+
? fn => this._runWithCabinetFallback(fn)
|
|
841
|
+
: async fn => ({ target: item, result: await fn(item) });
|
|
842
|
+
const { target: writeTarget, result: log } = await runWrite(async targetItem => {
|
|
843
|
+
const saveParams = { ...params };
|
|
844
|
+
if (files.length && !canLookupTask) {
|
|
845
|
+
const preAttachments = [];
|
|
846
|
+
await Promise.all(files.map(async file => {
|
|
847
|
+
const fLog = await targetItem.save_file(file, { encoding: 'utf-8', ignore_save_logs: true });
|
|
848
|
+
const fPath = await pathOfLog(fLog);
|
|
849
|
+
if (fPath)
|
|
850
|
+
preAttachments.push({ path: fPath.startsWith('/') ? fPath : '/' + fPath, name: file.name });
|
|
851
|
+
}));
|
|
852
|
+
if (preAttachments.length) {
|
|
853
|
+
saveParams.includes = JSON.stringify(preAttachments.map(a => a.path));
|
|
854
|
+
saveParams.attachments = JSON.stringify(preAttachments);
|
|
855
|
+
}
|
|
732
856
|
}
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
857
|
+
// Сначала создаём саму задачу, чтобы прикреплённые и создаваемые файлы размещались в папке этого таска
|
|
858
|
+
if (files.length && canLookupTask)
|
|
859
|
+
saveParams.skip_file_handler = true;
|
|
860
|
+
return targetItem.save_file(new File([JSON.stringify(body, null, 2)], name + '.task', { type: 'application/json' }), saveParams);
|
|
861
|
+
});
|
|
738
862
|
const path = await pathOfLog(log);
|
|
739
863
|
if (path && files.length && canLookupTask) {
|
|
740
864
|
const createdTask = await globalThis.WORK.get_item(path).catch(() => null);
|
|
741
|
-
const targetHolder = createdTask || item;
|
|
865
|
+
const targetHolder = createdTask || writeTarget || item;
|
|
742
866
|
const attachments = [];
|
|
743
867
|
await Promise.all(files.map(async file => {
|
|
744
868
|
const fLog = await targetHolder.save_file(file, { encoding: 'utf-8', ignore_save_logs: true, mainContext: path });
|
|
@@ -748,7 +872,7 @@ ODA({is: 'oda-chat',
|
|
|
748
872
|
}));
|
|
749
873
|
if (attachments.length && createdTask) {
|
|
750
874
|
const includePaths = attachments.map(a => a.path);
|
|
751
|
-
await item.fetch?.('append_log_includes', { entryPath: path, includePaths })?.catch?.(() => {});
|
|
875
|
+
await (writeTarget || item).fetch?.('append_log_includes', { entryPath: path, includePaths })?.catch?.(() => {});
|
|
752
876
|
await createdTask.fetch?.('prompt', {}, JSON.stringify({ prompt: text, attachments }))?.catch?.(() => {});
|
|
753
877
|
}
|
|
754
878
|
}
|
|
@@ -1076,29 +1200,46 @@ ODA({is: 'chat-ribbon',
|
|
|
1076
1200
|
dateList: [],
|
|
1077
1201
|
_datesWatch: null,
|
|
1078
1202
|
_lastRole: '',
|
|
1203
|
+
_listenedSource: null,
|
|
1079
1204
|
get activeRole() {
|
|
1080
1205
|
return this.$item?.role || 'USER';
|
|
1081
1206
|
},
|
|
1207
|
+
get isLocalFeed() {
|
|
1208
|
+
return this.$pdp?.feedMode === 'local';
|
|
1209
|
+
},
|
|
1082
1210
|
async _resolveLogsSource() {
|
|
1083
1211
|
if (!this.$item)
|
|
1084
1212
|
return null;
|
|
1085
1213
|
try {
|
|
1086
|
-
const path = await this.$item.fetch('chatSource', {
|
|
1214
|
+
const path = await this.$item.fetch('chatSource', {
|
|
1215
|
+
role: this.activeRole,
|
|
1216
|
+
uid: WORK.uid || '',
|
|
1217
|
+
...(this.isLocalFeed ? { local: 1 } : {}),
|
|
1218
|
+
});
|
|
1087
1219
|
if (path && typeof path === 'string')
|
|
1088
1220
|
return (await WORK.get_item(path)) || this.$item;
|
|
1089
1221
|
}
|
|
1090
1222
|
catch { /* fallback */ }
|
|
1091
1223
|
return this.$item;
|
|
1092
1224
|
},
|
|
1225
|
+
_syncSourceListeners(source) {
|
|
1226
|
+
if (this._listenedSource === source)
|
|
1227
|
+
return;
|
|
1228
|
+
if (this._listenedSource && this._listenedSource !== this.$item)
|
|
1229
|
+
this._listenedSource.unlisten?.('changed', this.onChanged);
|
|
1230
|
+
this._listenedSource = source || null;
|
|
1231
|
+
if (source && source !== this.$item)
|
|
1232
|
+
source.listen?.('changed', this.onChanged);
|
|
1233
|
+
},
|
|
1093
1234
|
async refreshFeed() {
|
|
1094
1235
|
this.dateList = [];
|
|
1095
|
-
await this.refreshDates();
|
|
1236
|
+
await this.refreshDates(true);
|
|
1096
1237
|
for (const dayEl of this.$$('chat-day') || []) {
|
|
1097
1238
|
dayEl._logsInit = false;
|
|
1098
1239
|
dayEl._ensureLogsInit?.();
|
|
1099
1240
|
}
|
|
1100
1241
|
},
|
|
1101
|
-
async refreshDates(){
|
|
1242
|
+
async refreshDates(force = false){
|
|
1102
1243
|
if (!this.$item)
|
|
1103
1244
|
return false;
|
|
1104
1245
|
const curRole = this.activeRole;
|
|
@@ -1106,23 +1247,26 @@ ODA({is: 'chat-ribbon',
|
|
|
1106
1247
|
this.dateList = [];
|
|
1107
1248
|
}
|
|
1108
1249
|
this._lastRole = curRole;
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1250
|
+
const source = (await this._resolveLogsSource()) || this.$item;
|
|
1251
|
+
this._syncSourceListeners(source);
|
|
1252
|
+
source.invalidate?.('logs_dates');
|
|
1253
|
+
let dates = await source.fetch('logs', {
|
|
1254
|
+
mode: 'dates',
|
|
1255
|
+
nonEmpty: 1,
|
|
1256
|
+
...(this.isLocalFeed ? { local: 1 } : {}),
|
|
1257
|
+
role: curRole,
|
|
1258
|
+
uid: WORK.uid || '',
|
|
1259
|
+
});
|
|
1260
|
+
// dates на сервере — по убыванию; в ленте дни — от старых к новым.
|
|
1261
|
+
dates = (Array.isArray(dates) ? dates : []).slice().reverse();
|
|
1262
|
+
// Пока создаётся новая задача (awaitTask), не сбрасываем локально добавленный _openCreated день
|
|
1263
|
+
if (!force && this.$pdp?.awaitTask && Array.isArray(this.dateList)) {
|
|
1264
|
+
for (const d of this.dateList) {
|
|
1265
|
+
if (d && !dates.includes(d))
|
|
1266
|
+
dates.push(d);
|
|
1267
|
+
}
|
|
1268
|
+
dates.sort();
|
|
1123
1269
|
}
|
|
1124
|
-
if (!dates.includes(today))
|
|
1125
|
-
dates = [...dates, today].sort();
|
|
1126
1270
|
const prevDates = Array.isArray(this.dateList) ? this.dateList : [];
|
|
1127
1271
|
if (prevDates.length !== dates.length || prevDates.some((d, i) => d !== dates[i])) {
|
|
1128
1272
|
this.dateList = dates;
|
|
@@ -1142,6 +1286,7 @@ ODA({is: 'chat-ribbon',
|
|
|
1142
1286
|
if (!this._rolePollTimer) {
|
|
1143
1287
|
this._rolePollTimer = setInterval(() => {
|
|
1144
1288
|
if (this.$item && this._lastRole && this.activeRole !== this._lastRole) {
|
|
1289
|
+
this.$pdp?._refreshCanLocalFeed?.();
|
|
1145
1290
|
this.refreshFeed();
|
|
1146
1291
|
}
|
|
1147
1292
|
}, 400);
|
|
@@ -1154,6 +1299,9 @@ ODA({is: 'chat-ribbon',
|
|
|
1154
1299
|
},
|
|
1155
1300
|
detached() {
|
|
1156
1301
|
this.$item?.unlisten?.('changed', this.onChanged);
|
|
1302
|
+
if (this._listenedSource && this._listenedSource !== this.$item)
|
|
1303
|
+
this._listenedSource.unlisten?.('changed', this.onChanged);
|
|
1304
|
+
this._listenedSource = null;
|
|
1157
1305
|
if (this._rolePollTimer) {
|
|
1158
1306
|
clearInterval(this._rolePollTimer);
|
|
1159
1307
|
this._rolePollTimer = 0;
|
|
@@ -1190,16 +1338,6 @@ ODA({is: 'chat-day',
|
|
|
1190
1338
|
align-items: center;
|
|
1191
1339
|
width: -webkit-fill-available;
|
|
1192
1340
|
}
|
|
1193
|
-
.date-line::before{
|
|
1194
|
-
content: '';
|
|
1195
|
-
display: block;
|
|
1196
|
-
position: absolute;
|
|
1197
|
-
left: 0px;
|
|
1198
|
-
right: 0px;
|
|
1199
|
-
height: 0px;
|
|
1200
|
-
border-top: 1px dashed;
|
|
1201
|
-
opacity: .5;
|
|
1202
|
-
}
|
|
1203
1341
|
.day-ribbon{
|
|
1204
1342
|
gap: 8px;
|
|
1205
1343
|
padding: 8px;
|
|
@@ -1408,12 +1546,13 @@ ODA({is: 'chat-day',
|
|
|
1408
1546
|
return [];
|
|
1409
1547
|
const role = this.$pdp?.$item?.role || 'USER';
|
|
1410
1548
|
const uid = WORK.uid || '';
|
|
1549
|
+
const local = this.$pdp?.isLocalFeed ? { local: 1 } : {};
|
|
1411
1550
|
let rows = [];
|
|
1412
1551
|
try {
|
|
1413
1552
|
if (typeof source.fetch === 'function')
|
|
1414
|
-
rows = await source.fetch('logs', { mode: 'bodies', day: this.day, role, uid });
|
|
1553
|
+
rows = await source.fetch('logs', { mode: 'bodies', day: this.day, role, uid, ...local });
|
|
1415
1554
|
else if (typeof source.logs === 'function')
|
|
1416
|
-
rows = await source.logs({ mode: 'bodies', day: this.day, role, uid });
|
|
1555
|
+
rows = await source.logs({ mode: 'bodies', day: this.day, role, uid, ...local });
|
|
1417
1556
|
}
|
|
1418
1557
|
catch {
|
|
1419
1558
|
rows = [];
|
|
@@ -1563,11 +1702,12 @@ ODA({is: 'chat-day',
|
|
|
1563
1702
|
}
|
|
1564
1703
|
},
|
|
1565
1704
|
get logsSource(){
|
|
1566
|
-
//
|
|
1567
|
-
//
|
|
1705
|
+
// По умолчанию всегда показывается личный кабинет (/USERS/<uid>);
|
|
1706
|
+
// местный лог точки (this.$pdp.$item) — только при явном включении режима local для BOSS.
|
|
1568
1707
|
const role = this.$pdp?.$item?.role || 'USER';
|
|
1569
1708
|
const uid = WORK.uid || '';
|
|
1570
|
-
|
|
1709
|
+
const local = this.$pdp?.isLocalFeed ? { local: 1 } : {};
|
|
1710
|
+
return Promise.resolve(this.$pdp.$item?.fetch?.('chatSource', { role, uid, ...local })).then(path => {
|
|
1571
1711
|
if (path && typeof path === 'string')
|
|
1572
1712
|
return WORK.get_item(path);
|
|
1573
1713
|
return this.$pdp.$item;
|
|
@@ -50,6 +50,9 @@ export default {
|
|
|
50
50
|
async approve(params = {}) {
|
|
51
51
|
return (await WORK_AGENT()).approve(this, params);
|
|
52
52
|
},
|
|
53
|
+
async explain_call(params = {}) {
|
|
54
|
+
return (await WORK_AGENT()).explainCall(this, params);
|
|
55
|
+
},
|
|
53
56
|
/** Карточка подключения: данные вводит человек → { auth_url } окна входа или { ok } (токен). Не пишется в ленту. */
|
|
54
57
|
async connect_start(params = {}) {
|
|
55
58
|
return (await WORK_AGENT()).connectStart(this, params);
|