@petercjl/omni-desktop-app 0.1.8 → 0.1.10
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/INSTALL.md +9 -0
- package/README.md +4 -4
- package/UPDATE.md +7 -0
- package/app/assets/{CartesianChart-Bwf4u0Tg.js → CartesianChart-CP7p2vlm.js} +2 -2
- package/app/assets/{CollaborationWorkspace-Bd6Sjj31.js → CollaborationWorkspace-Cnp5PNn_.js} +3 -3
- package/app/assets/CompetitorAnalysis-Cujy_a2L.js +1 -0
- package/app/assets/CompetitorAnalysis-h1zdt0F2.css +1 -0
- package/app/assets/EmptyState-CUHuNsaV.js +1 -0
- package/app/assets/ErrorBarContext-BJE5-ljg.js +1 -0
- package/app/assets/{EvidenceSourceGuide-CwfB7Z6T.js → EvidenceSourceGuide-B1AJCZm2.js} +1 -1
- package/app/assets/FavoritePicker-XD1a_uOa.js +1 -0
- package/app/assets/Favorites-B5_fdEvZ.js +1 -0
- package/app/assets/{HelpTip-CX2LFdwD.js → HelpTip-BqRBO41J.js} +1 -1
- package/app/assets/LineChart-Ckvg5wfQ.js +4 -0
- package/app/assets/{Opportunities-a5IpRN6k.js → Opportunities-BvH64-dz.js} +1 -1
- package/app/assets/{ProgressiveRows-ByxDeTyy.js → ProgressiveRows-NojOUgmr.js} +1 -1
- package/app/assets/ShopLayoutPage-CCrRwaAx.js +1 -0
- package/app/assets/TrendChart-BF4JgwxH.js +1 -0
- package/app/assets/arrow-down-B1nil3T4.js +1 -0
- package/app/assets/arrow-left-BhFSpYzK.js +1 -0
- package/app/assets/arrow-up-right-IBQoN72x.js +1 -0
- package/app/assets/{book-open-C0B9Pao9.js → book-open-Cqdn6s-H.js} +1 -1
- package/app/assets/chart-column-DCwNhXki.js +1 -0
- package/app/assets/{chart-no-axes-combined-XDy9u9SV.js → chart-no-axes-combined-DVgKs36j.js} +1 -1
- package/app/assets/check-DBnlZFEo.js +1 -0
- package/app/assets/chevron-down-DO6RUQm8.js +1 -0
- package/app/assets/chevron-right-e65CaeL6.js +1 -0
- package/app/assets/{clock-3-TH35nOP-.js → clock-3-CDHtQwAe.js} +1 -1
- package/app/assets/competitor-analysis-D6eM9ugQ.js +1 -0
- package/app/assets/{components-C2-vHJtu.js → components-B5Xyjfpi.js} +2 -2
- package/app/assets/{download-BlJN0Lg8.js → download-DfM49VvV.js} +1 -1
- package/app/assets/entry-Bq7tA83b.js +1 -0
- package/app/assets/{entry-OcErMaMp.css → entry-CMur_AE7.css} +1 -1
- package/app/assets/entry-DC4oDjzU.js +2 -0
- package/app/assets/{entry-DM3aLe2I.js → entry-DM64sJfS.js} +1 -1
- package/app/assets/entry-DbqMDIJi.js +1 -0
- package/app/assets/{entry-CdLi3Z9F.js → entry-N8bfKXTF.js} +2 -2
- package/app/assets/{entry-CYGrMJuR.js → entry-kAWoaIsV.js} +2 -2
- package/app/assets/favorites.module-CHYv-Z8y.js +1 -0
- package/app/assets/{file-text-Hd45wNTe.js → file-text-DKAT5fzJ.js} +1 -1
- package/app/assets/getRadiusAndStrokeWidthFromDot-bv_ksZ7y.js +1 -0
- package/app/assets/{grid-2x2-C0aJVeyS.js → grid-2x2-DB6zRPIV.js} +1 -1
- package/app/assets/index-BgJNmU0Z.css +1 -0
- package/app/assets/{index-BguiS02-.js → index-DLSVWUSu.js} +2 -2
- package/app/assets/{layers-Dj9z2et6.js → layers-CjsT_HGi.js} +1 -1
- package/app/assets/{layout-dashboard-DS537D8b.js → layout-dashboard-sgUrlApv.js} +1 -1
- package/app/assets/{link-2-CCKUDMV6.js → link-2-VLti-YG9.js} +1 -1
- package/app/assets/{list-LZcXKWKD.js → list-Dfzc0sXQ.js} +1 -1
- package/app/assets/market-SuD7x_Hf.css +1 -0
- package/app/assets/market.module-VpU4XmGg.js +1 -0
- package/app/assets/{module-host-C4vqZw2y.js → module-host-DNtiV4gZ.js} +1 -1
- package/app/assets/{orbit-G4ZspWKB.js → orbit-CrQs6cpl.js} +1 -1
- package/app/assets/play-BxTFlaQX.js +1 -0
- package/app/assets/plus-D78h7lrw.js +1 -0
- package/app/assets/{products-BAKFF--e.js → products-B5vjXM_b.js} +1 -1
- package/app/assets/{project-public-HdtYycKS.js → project-public-CgW1u7BI.js} +1 -1
- package/app/assets/{project-public-BCoD2Anq.js → project-public-DWTt808B.js} +1 -1
- package/app/assets/public-C-PBMVOQ.js +1 -0
- package/app/assets/{refresh-cw-dsQ_f-9j.js → refresh-cw-CxbRf97c.js} +1 -1
- package/app/assets/search-DFdSppzm.js +1 -0
- package/app/assets/{triangle-alert-l-Mfj0iE.js → triangle-alert-C7qiylOf.js} +1 -1
- package/app/assets/{ui-public-BPe2GJZ-.css → ui-public-DHoRDp5_.css} +1 -1
- package/app/assets/{ui-public-DWkIf658.js → ui-public-Dt5dHt-8.js} +1 -1
- package/app/assets/workbench-DIKJZNJQ.js +2 -0
- package/app/assets/{workspace-view-state-BJMX6vWb.js → workspace-view-state-D0ujRczW.js} +1 -1
- package/app/desktop/main.mjs +7719 -0
- package/app/desktop/preload.cjs +30 -0
- package/app/index.html +2 -2
- package/app/package.json +1 -0
- package/app/public/omni-icon.png +0 -0
- package/app/tools/bootstrap.bin +0 -0
- package/app/tools/omni-desktop.mjs +526 -0
- package/package.json +7 -2
- package/release.json +1 -1
- package/release.sig +1 -1
- package/app/assets/EmptyState-CE7obISq.js +0 -1
- package/app/assets/Favorites-4oU1mgEb.js +0 -1
- package/app/assets/LineChart-B6igYupv.js +0 -4
- package/app/assets/ShopLayoutPage-D7KKJVEq.js +0 -1
- package/app/assets/TrendChart-BdRXaz4z.js +0 -1
- package/app/assets/arrow-down-DSjucZgz.js +0 -1
- package/app/assets/arrow-left-DmIga4jN.js +0 -1
- package/app/assets/arrow-up-right-DzAKT3cL.js +0 -1
- package/app/assets/check-BB89tIU6.js +0 -1
- package/app/assets/chevron-down-BiokgLxD.js +0 -1
- package/app/assets/chevron-right-CZlQQ5gV.js +0 -1
- package/app/assets/entry-Bxc-KNuY.js +0 -1
- package/app/assets/entry-ZwyGbRek.js +0 -1
- package/app/assets/entry-ffP7X21A.js +0 -2
- package/app/assets/index-D1qZkLPg.css +0 -1
- package/app/assets/market-DqV9l-vR.css +0 -1
- package/app/assets/market.module-BSrEp5Ak.js +0 -1
- package/app/assets/package-BFlv-jYw.js +0 -1
- package/app/assets/play-DxbesM66.js +0 -1
- package/app/assets/plus-QakkcxdA.js +0 -1
- package/app/assets/public-JUGpS2z7.js +0 -1
- package/app/assets/search-Cisx0wBF.js +0 -1
- package/app/assets/use-favorites-ALxrDxDW.js +0 -1
- package/app/assets/workbench-DZTf1DRZ.js +0 -2
- /package/app/assets/{api-hjUd9Skg.js → api-KZa8CR8X.js} +0 -0
- /package/app/assets/{use-favorites-_eKBQGeF.css → favorites-_eKBQGeF.css} +0 -0
- /package/app/assets/{format-BCxMsVJh.js → format-DL7i7_eV.js} +0 -0
- /package/app/assets/{graphicalItemSelectors-Hc730Dd1.js → graphicalItemSelectors-CJfZ6cht.js} +0 -0
- /package/app/assets/{group-CjIFQYrJ.js → group-Ed305HyG.js} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./index-
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`layers`,[[`path`,{d:`M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z`,key:`zw3jo`}],[`path`,{d:`M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12`,key:`1wduqc`}],[`path`,{d:`M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17`,key:`kqbvx6`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./index-
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`git-branch`,[[`path`,{d:`M15 6a9 9 0 0 0-9 9V3`,key:`1cii5b`}],[`circle`,{cx:`18`,cy:`6`,r:`3`,key:`1h7g24`}],[`circle`,{cx:`6`,cy:`18`,r:`3`,key:`fqmcym`}]]),n=e(`layout-dashboard`,[[`rect`,{width:`7`,height:`9`,x:`3`,y:`3`,rx:`1`,key:`10lvy0`}],[`rect`,{width:`7`,height:`5`,x:`14`,y:`3`,rx:`1`,key:`16une8`}],[`rect`,{width:`7`,height:`9`,x:`14`,y:`12`,rx:`1`,key:`1hutg5`}],[`rect`,{width:`7`,height:`5`,x:`3`,y:`16`,rx:`1`,key:`ldoo1y`}]]);export{t as n,n as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./index-
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),n=e(`link-2`,[[`path`,{d:`M9 17H7A5 5 0 0 1 7 7h2`,key:`8i5ue5`}],[`path`,{d:`M15 7h2a5 5 0 1 1 0 10h-2`,key:`1b9ql8`}],[`line`,{x1:`8`,x2:`16`,y1:`12`,y2:`12`,key:`1jonct`}]]);export{t as n,n as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./index-
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`list`,[[`path`,{d:`M3 5h.01`,key:`18ugdj`}],[`path`,{d:`M3 12h.01`,key:`nlz23k`}],[`path`,{d:`M3 19h.01`,key:`noohij`}],[`path`,{d:`M8 5h13`,key:`1pao27`}],[`path`,{d:`M8 12h13`,key:`1za7za`}],[`path`,{d:`M8 19h13`,key:`m83p4d`}]]);export{t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._page_1gmkh_1{--omni-category-leaf-tint:#6fb9ad;--omni-category-branch-tint:#7494bf;box-sizing:border-box;background:var(--omni-paint-surface-0a1524,#0a1524);min-width:0;min-height:100vh;color:var(--omni-paint-ink-dbe8f5,#dbe8f5);padding:0 0 28px;font:13px/1.5 -apple-system,BlinkMacSystemFont,Segoe UI,PingFang SC,sans-serif;display:block;container-type:inline-size}._page_1gmkh_1 *{box-sizing:border-box}._page_1gmkh_1 button,._page_1gmkh_1 input,._page_1gmkh_1 select{font:inherit;color:inherit;border:1px solid var(--omni-paint-line-30465e,#30465e);background:var(--omni-paint-surface-102239,#102239);border-radius:5px;width:auto;min-width:0;margin:0;padding:6px 10px}._page_1gmkh_1 button{cursor:pointer;justify-content:center;align-items:center;gap:5px;display:inline-flex}._page_1gmkh_1 button:hover{background:var(--omni-paint-surface-193852,#193852);border-color:var(--omni-paint-line-4b92b9,#4b92b9)}._page_1gmkh_1 button:disabled{opacity:.32;cursor:default}._page_1gmkh_1 button:focus-visible,._page_1gmkh_1 a:focus-visible,._page_1gmkh_1 summary:focus-visible,._page_1gmkh_1 input:focus-visible,._page_1gmkh_1 select:focus-visible{outline:2px solid var(--omni-paint-line-60d2f6,#60d2f6);outline-offset:2px}._page_1gmkh_1 a{color:var(--omni-paint-ink-69c9f1,#69c9f1);text-decoration:none}._page_1gmkh_1 a:hover{text-decoration:underline}._page_1gmkh_1 ._primary_1gmkh_69{background:var(--omni-paint-surface-187da7,#187da7);border-color:var(--omni-paint-line-298fac,#298fac);color:var(--omni-paint-ink-f1fbff,#f1fbff)}._stickyHeader_1gmkh_74{top:var(--workspace-sticky-top,0px);z-index:30;background:var(--omni-paint-surface-0a1524,#0a1524);border-bottom:1px solid var(--omni-paint-line-263d55,#263d55);margin:0;padding:8px 24px;position:sticky}._stickyHeader_1gmkh_74 ._breadcrumb_1gmkh_83{margin-bottom:6px}._stickyHeader_1gmkh_74 ._filterBar_1gmkh_86{gap:8px 16px;margin-bottom:0}._stickyHeader_1gmkh_74 ._toolbar_1gmkh_90{margin-top:8px;padding-bottom:0}._stickyHeader_1gmkh_74 ._tabs_1gmkh_94{border:0;gap:18px;margin:0 0 0 12px;padding:0}._page_1gmkh_1 ._stickyHeader_1gmkh_74 ._tabs_1gmkh_94 button{white-space:nowrap;padding:6px 0}._breadcrumb_1gmkh_83{min-height:24px;color:var(--omni-paint-ink-829ab3,#829ab3);border:0;flex-wrap:wrap;justify-content:flex-start;align-items:center;gap:9px;margin-bottom:23px;padding:0;font-size:12px;display:flex}._breadcrumb_1gmkh_83>a{color:var(--omni-paint-ink-91a8be,#91a8be)}._breadcrumb_1gmkh_83>span{align-items:center;gap:8px;display:inline-flex}._page_1gmkh_1 ._breadcrumb_1gmkh_83 button{color:var(--omni-paint-ink-93abc0,#93abc0);background:0 0;border:0;padding:0}._filterBar_1gmkh_86{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:15px;margin-bottom:15px;display:flex}._categoryControl_1gmkh_139,._dateControl_1gmkh_140{align-items:center;gap:8px;display:flex}._categoryControl_1gmkh_139{min-width:0}._count_1gmkh_148{white-space:nowrap;color:var(--omni-paint-ink-74c8ec,#74c8ec);background:var(--omni-paint-surface-112d43,#112d43);border:1px solid var(--omni-paint-line-2a6386,#2a6386);border-radius:3px;padding:2px 6px;font-size:11px}._dateControl_1gmkh_140{flex-wrap:wrap;justify-content:flex-end;margin-left:auto;font-size:12px}._period_1gmkh_163{color:var(--omni-paint-ink-6e87a0,#6e87a0);margin-right:10px;font-size:11px}._page_1gmkh_1 ._yearButton_1gmkh_168{color:var(--omni-paint-ink-9dbcd7,#9dbcd7);background:0 0;border:0;padding:5px}._page_1gmkh_1 ._yearButton_1gmkh_168[aria-pressed=true]{color:var(--omni-paint-ink-61d3f7,#61d3f7);font-weight:600}._dateControl_1gmkh_140 select{color:var(--omni-paint-ink-65ccf0,#65ccf0);background:0 0;border:0;max-width:150px;padding:6px;font-weight:600}._dateControl_1gmkh_140>button:not(._yearButton_1gmkh_168){background:var(--omni-paint-surface-14273c,#14273c);border:0;padding:5px}._segment_1gmkh_191{background:var(--omni-paint-surface-101f32,#101f32);border:1px solid var(--omni-paint-line-283e56,#283e56);border-radius:5px;align-items:center;gap:0;padding:2px;display:flex}._segment_1gmkh_191 button{color:var(--omni-paint-ink-7e97b0,#7e97b0);background:0 0;border:0;padding:5px 11px;font-size:12px}._page_1gmkh_1 ._segment_1gmkh_191 button[aria-pressed=true]{background:var(--omni-paint-surface-1b3b55,#1b3b55);color:var(--omni-paint-ink-a6e7fc,#a6e7fc);box-shadow:0 1px 3px var(--omni-paint-shadow-020b1633,#020b1633)}._dateControl_1gmkh_140 ._segment_1gmkh_191{margin-left:10px}._message_1gmkh_215{color:var(--omni-paint-ink-b8d8ea,#b8d8ea);border:1px solid var(--omni-paint-line-345b72,#345b72);background:var(--omni-paint-surface-133049,#133049);border-radius:5px;justify-content:space-between;align-items:center;margin-bottom:10px;padding:8px 12px;display:flex}._page_1gmkh_1 ._message_1gmkh_215 button{background:0 0;border:0;padding:0 5px}._categoryList_1gmkh_231{min-width:0;max-height:max(160px, calc(100dvh - var(--workspace-sticky-top,0px) - var(--market-controls-height,180px) - 2px));padding-inline:12px;overflow:auto}._categoryLegend_1gmkh_237,._categoryLegend_1gmkh_237>span{align-items:center;gap:5px;display:flex}._categoryLegend_1gmkh_237{color:var(--omni-paint-ink-829ab3,#829ab3);white-space:nowrap;gap:10px;font-size:10px}._categoryLegend_1gmkh_237 i{opacity:.8;background:var(--omni-category-branch-tint);border-radius:2px;width:7px;height:7px}._categoryLegend_1gmkh_237 i[data-leaf=true]{background:var(--omni-category-leaf-tint)}._categoryHeaders_1gmkh_259,._categoryRows_1gmkh_260{grid-template-columns:repeat(3,minmax(0,1fr));column-gap:16px;min-width:1020px;display:grid}._categoryHeaders_1gmkh_259{background:var(--omni-paint-surface-0a1524,#0a1524);z-index:1;margin-bottom:8px;position:sticky;top:0}._categoryHeaders_1gmkh_259>div,._categoryRow_1gmkh_260{grid-template-columns:minmax(90px,1fr) 72px 58px 48px 22px;align-items:center;gap:5px;display:grid;position:relative}._categoryHeaders_1gmkh_259>div{color:var(--omni-paint-ink-718ca6,#718ca6);padding:7px 8px;font-size:11px}._categoryHeaders_1gmkh_259 span:not(:first-child){text-align:right}._categoryRows_1gmkh_260{row-gap:12px}._categoryRow_1gmkh_260{border:1px solid var(--omni-paint-line-29425b,#29425b);background:var(--omni-paint-surface-102239,#102239);border-radius:4px;min-height:54px;padding:8px;transition:background .15s}._categoryRow_1gmkh_260:hover,._categoryRow_1gmkh_260:focus-within{background:var(--omni-paint-surface-153049,#153049);border-color:var(--omni-paint-line-397391,#397391)}._categoryRow_1gmkh_260[data-leaf=false]{background:var(--omni-panel,var(--omni-paint-surface-102235,#102235));border-inline-start:2px solid color-mix(in srgb, var(--omni-line,var(--omni-paint-line-2c435b,#2c435b)) 75%, var(--omni-category-branch-tint))}._categoryRow_1gmkh_260[data-leaf=true]{background:color-mix(in srgb, var(--omni-panel,var(--omni-paint-surface-102235,#102235)) 90%, var(--omni-category-leaf-tint));border-inline-start:2px solid color-mix(in srgb, var(--omni-line,var(--omni-paint-line-2c435b,#2c435b)) 55%, var(--omni-category-leaf-tint))}._categoryRow_1gmkh_260:is(:hover,:focus-within){background:color-mix(in srgb, var(--omni-panel,var(--omni-paint-surface-102235,#102235)) 85%, var(--omni-accent,var(--omni-paint-surface-61d3df,#61d3df)))}._categoryName_1gmkh_334{flex-wrap:wrap;align-items:center;gap:6px;min-width:0;display:flex;position:relative}._page_1gmkh_1 ._categoryOpen_1gmkh_342,._page_1gmkh_1 ._categoryOpen_1gmkh_342:hover{z-index:1;background:0 0;border:0;width:100%;height:100%;padding:0;position:absolute;inset:0}._categoryRow_1gmkh_260>button:not(._categoryOpen_1gmkh_342){z-index:2;position:relative}._page_1gmkh_1 ._categoryName_1gmkh_334>span{text-align:left;min-width:0;color:var(--omni-paint-ink-d5e6f5,#d5e6f5);background:0 0;border:0;flex:90px;justify-content:flex-start;align-items:center;gap:5px;padding:0;font-size:12px;display:flex}._categoryName_1gmkh_334>span>svg{vertical-align:middle;flex-shrink:0;margin-left:4px;display:inline-block}._page_1gmkh_1 ._categoryName_1gmkh_334>span{white-space:normal;overflow-wrap:anywhere;display:block}._categoryRow_1gmkh_260:hover ._categoryName_1gmkh_334>span{color:var(--omni-paint-ink-78d6f6,#78d6f6)}._categoryRow_1gmkh_260>strong{color:var(--omni-paint-ink-70cfff,#70cfff);text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums;font-size:12px;font-weight:500}._categoryRow_1gmkh_260>span{text-align:right;color:var(--omni-paint-ink-9cb5cc,#9cb5cc);font-variant-numeric:tabular-nums;font-size:11px}._page_1gmkh_1 ._iconButton_1gmkh_399{color:var(--omni-paint-ink-688ba8,#688ba8);background:0 0;border:0;padding:3px}._page_1gmkh_1 ._iconButton_1gmkh_399[aria-pressed=true]{color:var(--omni-paint-ink-68d3f4,#68d3f4)}._rowActions_1gmkh_408{z-index:3;flex-shrink:0;gap:5px;min-height:22px;margin:0;display:none;position:relative}._categoryRow_1gmkh_260:is(:hover,:focus-within) ._rowActions_1gmkh_408{display:flex}._page_1gmkh_1 ._rowActions_1gmkh_408>button{background:var(--omni-paint-surface-1c3c56,#1c3c56);border-color:var(--omni-paint-line-335a73,#335a73);min-height:22px;color:var(--omni-paint-ink-89cae7,#89cae7);border-radius:3px;padding:2px 6px;font-size:10px;line-height:1.4}._tabs_1gmkh_94{border-bottom:1px solid var(--omni-paint-line-263d55,#263d55);align-items:center;gap:28px;margin:8px -24px 0;padding:0 24px;display:flex}._page_1gmkh_1 ._tabs_1gmkh_94 button{color:var(--omni-paint-ink-9fb3c7,#9fb3c7);background:0 0;border:0;border-bottom:2px solid #0000;border-radius:0;padding:13px 0 12px;font-size:13px}._page_1gmkh_1 ._tabs_1gmkh_94 button[aria-selected=true]{border-bottom-color:var(--omni-paint-line-47c5ee,#47c5ee);color:var(--omni-paint-ink-75d6f5,#75d6f5)}._toolbar_1gmkh_90{flex-wrap:wrap;align-items:center;gap:12px;padding:8px 0;display:flex}._toolbar_1gmkh_90>button{font-size:12px}._search_1gmkh_461{border:1px solid var(--omni-paint-line-30465e,#30465e);background:var(--omni-paint-surface-0d1d30,#0d1d30);min-height:33px;color:var(--omni-paint-ink-6e8fa9,#6e8fa9);border-radius:4px;align-items:center;gap:7px;display:flex}._search_1gmkh_461>span{border-right:1px solid var(--omni-paint-line-30465e,#30465e);color:var(--omni-paint-ink-adc4d9,#adc4d9);padding:6px 10px}._search_1gmkh_461>svg{flex-shrink:0;margin-left:10px}._page_1gmkh_1 ._search_1gmkh_461 input{background:0 0;border:0;width:270px;min-width:0;padding:6px 8px;font-size:12px}._page_1gmkh_1 input::placeholder{color:var(--omni-paint-ink-526d87,#526d87)}._price_1gmkh_491{color:var(--omni-paint-ink-91abc4,#91abc4);align-items:center;gap:7px;font-size:12px;display:flex}._price_1gmkh_491 label{border:1px solid var(--omni-paint-line-30465e,#30465e);border-radius:4px;align-items:center;gap:0;padding-right:8px;display:flex}._page_1gmkh_1 ._price_1gmkh_491 input{background:0 0;border:0;width:66px;padding:6px 8px}._toolbar_1gmkh_90>._segment_1gmkh_191{margin-left:auto}._page_1gmkh_1 ._configButton_1gmkh_515{color:var(--omni-paint-ink-cce3f4,#cce3f4);border-color:var(--omni-paint-line-6185a1,#6185a1);margin-left:auto}._toolbar_1gmkh_90>._segment_1gmkh_191+._configButton_1gmkh_515{margin-left:0}._tableScroll_1gmkh_523{min-height:min(260px, calc(100dvh - var(--workspace-sticky-top,0px) - var(--market-controls-height,180px)));max-height:max(160px, calc(100dvh - var(--workspace-sticky-top,0px) - var(--market-controls-height,180px) - 2px));border:1px solid var(--omni-paint-line-233d55,#233d55);background:var(--omni-paint-surface-0d1e31,#0d1e31);scrollbar-color:var(--omni-selected-border,var(--omni-paint-ink-375572,#375572)) var(--omni-bg,var(--omni-paint-ink-102138,#102138));overflow:auto}._page_1gmkh_1 table{border-collapse:separate;border-spacing:0;text-align:left;white-space:nowrap;width:100%;font-size:12px}._page_1gmkh_1 th{background:var(--omni-paint-surface-162b40,#162b40);color:var(--omni-paint-ink-a8bfd4,#a8bfd4);border-bottom:1px solid var(--omni-paint-line-334c65,#334c65);z-index:1;padding:10px 12px;font-size:11px;font-weight:550;position:sticky;top:0}._page_1gmkh_1 th button{color:inherit;background:0 0;border:0;justify-content:space-between;width:100%;min-width:80px;padding:0;font-size:11px}._page_1gmkh_1 td{border-bottom:1px solid var(--omni-paint-line-22384e,#22384e);color:var(--omni-paint-ink-acc1d4,#acc1d4);vertical-align:middle;font-variant-numeric:tabular-nums;padding:10px 12px}._page_1gmkh_1 tr:hover td{background:var(--omni-paint-surface-132b41,#132b41)}._sort_1gmkh_570{color:var(--omni-paint-ink-4b6782,#4b6782);margin-left:15px}._activeSort_1gmkh_574{color:var(--omni-paint-accent-6acdf7,#6acdf7);margin-left:15px}._productTable_1gmkh_578{min-width:2200px}._shopTable_1gmkh_581{min-width:2100px}._productTable_1gmkh_578 th:first-child,._shopTable_1gmkh_581 th:first-child{min-width:55px}._productTable_1gmkh_578 th:nth-child(2){width:300px;min-width:300px}._shopTable_1gmkh_581 th:nth-child(2){min-width:150px}._shopTable_1gmkh_581 th:nth-child(3){width:250px;min-width:250px}._shopName_1gmkh_599{text-overflow:ellipsis;min-width:170px;max-width:270px;overflow:hidden}._sales_1gmkh_605{background:var(--omni-paint-surface-10263c,#10263c);color:var(--omni-paint-ink-a2d7f2,#a2d7f2)!important}._identity_1gmkh_609{align-items:center;gap:9px;min-width:240px;max-width:300px;display:flex}._identity_1gmkh_609>._imageButton_1gmkh_616{flex-shrink:0}._page_1gmkh_1 ._imageButton_1gmkh_616{cursor:zoom-in;background:0 0;border:0;justify-content:center;align-items:center;width:42px;height:42px;padding:0;display:flex}._productTitleRow_1gmkh_630{align-items:flex-start;gap:4px;display:flex}._productTitleRow_1gmkh_630>:first-child{flex:1;min-width:0}._productTitleRow_1gmkh_630>:last-child{flex-shrink:0}._productId_1gmkh_642{white-space:nowrap;align-items:center;gap:4px;font-size:10px;display:inline-flex}._imageHoverPreview_1gmkh_649{z-index:1000;box-sizing:border-box;background:var(--omni-panel,var(--omni-paint-surface-102235,#102235));border:1px solid var(--omni-line,var(--omni-paint-line-2c435b,#2c435b));box-shadow:0 12px 35px var(--omni-paint-shadow-0008,#0008);pointer-events:none;border-radius:6px;padding:6px;position:fixed}._imageHoverPreview_1gmkh_649 img{object-fit:contain;width:100%;height:100%}._imageViewer_1gmkh_665{box-sizing:border-box;background:var(--omni-paint-surface-030914ed,#030914ed);width:100vw;max-width:none;height:100dvh;max-height:none;color:var(--omni-paint-ink-e1edfa,#e1edfa);border:0;margin:0;padding:48px;position:fixed;inset:0}._imageViewer_1gmkh_665[open]{justify-content:center;align-items:center;display:flex}._imageViewer_1gmkh_665>img{object-fit:contain;width:100%;max-width:100%;height:100%;max-height:100%;display:block}._imageViewer_1gmkh_665 ._imageViewerClose_1gmkh_692{border:1px solid var(--omni-paint-line-63768c,#63768c);background:var(--omni-paint-surface-102235,#102235);color:var(--omni-paint-ink-e1edfa,#e1edfa);cursor:pointer;border-radius:6px;padding:8px;display:flex;position:absolute;top:12px;right:12px}._identity_1gmkh_609 img,._noImage_1gmkh_705{object-fit:contain;border-radius:3px;width:42px;height:42px}._noImage_1gmkh_705{background:var(--omni-paint-surface-18344b,#18344b);color:var(--omni-paint-ink-507b99,#507b99);flex-shrink:0;justify-content:center;align-items:center;display:flex}._identity_1gmkh_609>div{flex:1;min-width:0}._page_1gmkh_1 ._productTitle_1gmkh_630{-webkit-line-clamp:2;white-space:normal;color:var(--omni-paint-ink-6ecdf4,#6ecdf4);text-align:left;cursor:pointer;background:0 0;border:0;-webkit-box-orient:vertical;max-width:250px;padding:0;font-size:12px;line-height:1.45;display:-webkit-box;overflow:hidden}._identity_1gmkh_609 small{color:var(--omni-paint-ink-6d8ba7,#6d8ba7);white-space:nowrap;align-items:center;gap:5px;margin-top:4px;font-size:10px;display:flex}._copyControl_1gmkh_748 ._copyButton_1gmkh_748{background:var(--omni-paint-surface-1b344a,#1b344a);color:var(--omni-paint-ink-91b3cc,#91b3cc);border:0;border-radius:2px;padding:2px 3px}._copyControl_1gmkh_748{flex-shrink:0;align-items:center;display:inline-flex;position:relative}._copyControl_1gmkh_748 ._copyButton_1gmkh_748[data-copied=true]{color:var(--omni-success,var(--omni-paint-ink-65d8b4,#65d8b4));background:var(--omni-selected,var(--omni-paint-surface-163d37,#163d37))}._copyFeedback_1gmkh_765{background:var(--omni-panel,var(--omni-paint-surface-102235,#102235));border:1px solid var(--omni-line,var(--omni-paint-line-2c435b,#2c435b));color:var(--omni-text,var(--omni-paint-ink-daebff,#daebff));white-space:nowrap;pointer-events:none;z-index:3;border-radius:4px;padding:3px 6px;font-size:11px;line-height:1.4;position:absolute;bottom:calc(100% + 4px);right:0}._shopId_1gmkh_780{align-items:center;gap:6px;font-size:11px;display:flex}._page_1gmkh_1 ._linkButton_1gmkh_786{color:var(--omni-paint-ink-85bfdd,#85bfdd);background:0 0;border:0;padding:2px 0;font-size:12px}._anomaly_1gmkh_793{color:var(--omni-paint-ink-f3b583,#f3b583)}._pagination_1gmkh_796{color:var(--omni-paint-ink-7f9ab3,#7f9ab3);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:15px;padding:16px 0 8px;font-size:11px;display:flex}._pagination_1gmkh_796>div{flex-wrap:wrap;align-items:center;gap:7px;display:flex}._pagination_1gmkh_796 button{background:0 0;border-color:#0000;min-width:29px;padding:5px 9px}._pagination_1gmkh_796 button[aria-current=page]{color:var(--omni-paint-accent-70d0f5,#70d0f5);border-color:var(--omni-paint-line-3a94bb,#3a94bb);background:var(--omni-paint-surface-16364d,#16364d)}._pagination_1gmkh_796 select{padding:5px 8px;font-size:11px}._pagination_1gmkh_796 label{align-items:center;gap:7px;display:flex}._pagination_1gmkh_796 input{width:50px;padding:5px}._ellipsis_1gmkh_836{color:var(--omni-paint-ink-546f88,#546f88);margin:0 9px}._notice_1gmkh_840{color:var(--omni-paint-ink-bcae88,#bcae88);background:var(--omni-paint-surface-2b281f,#2b281f);border:1px solid var(--omni-paint-line-5b4d31,#5b4d31);border-radius:4px;margin:12px 0;padding:9px 12px;font-size:11px;line-height:1.7}._sources_1gmkh_850{color:var(--omni-paint-ink-647f98,#647f98);margin-top:18px;font-size:11px;line-height:1.9}._sources_1gmkh_850 summary{cursor:pointer;width:fit-content;color:var(--omni-paint-ink-86a6c0,#86a6c0);align-items:center;gap:5px;display:flex}._sources_1gmkh_850 p{overflow-wrap:anywhere}._empty_1gmkh_867{text-align:center;color:var(--omni-paint-ink-7f9bb4,#7f9bb4);white-space:normal;padding:45px 20px;font-size:12px}._emptyState_1gmkh_874{text-align:center;border:1px solid var(--omni-paint-line-28455f,#28455f);background:var(--omni-paint-surface-0d2135,#0d2135);border-radius:8px;margin-top:24px;padding:100px 20px}._emptyState_1gmkh_874>svg{color:var(--omni-paint-ink-5db3d6,#5db3d6)}._emptyState_1gmkh_874 h2{font-size:18px;font-weight:550}._emptyState_1gmkh_874 p{color:var(--omni-paint-ink-7899b5,#7899b5);font-size:12px}._emptyState_1gmkh_874 button{margin-top:15px}._seasonBoard_1gmkh_896{overflow:auto}._seasonBoard_1gmkh_896 td:first-child{min-width:200px}._hot_1gmkh_902,._cold_1gmkh_903,._neutral_1gmkh_904{text-align:center;border-radius:6px;padding:12px 20px;display:block}._hot_1gmkh_902{background:var(--omni-paint-surface-633c31,#633c31);color:var(--omni-paint-ink-f2c0ab,#f2c0ab)}._cold_1gmkh_903{background:var(--omni-paint-surface-1d4778,#1d4778);color:var(--omni-paint-ink-b0d7ff,#b0d7ff)}._neutral_1gmkh_904{background:var(--omni-paint-surface-2c3a49,#2c3a49);color:var(--omni-paint-ink-b7c9dc,#b7c9dc)}._yearBoards_1gmkh_922{align-items:stretch;gap:16px;min-height:400px;padding-bottom:10px;display:flex;overflow:auto}._yearBoards_1gmkh_922>article{border:1px solid var(--omni-paint-line-29445f,#29445f);background:var(--omni-paint-surface-0d2033,#0d2033);width:420px;min-width:420px}._yearBoards_1gmkh_922 h2{text-align:center;background:var(--omni-paint-surface-142d44,#142d44);z-index:2;margin:0;padding:9px;font-size:13px;font-weight:600;position:sticky;top:0}._yearBoards_1gmkh_922 th{top:37px}._yearBoards_1gmkh_922 ._identity_1gmkh_609{min-width:230px;max-width:250px}._yearBoards_1gmkh_922 ._productTitle_1gmkh_630{-webkit-line-clamp:1}._yearBoards_1gmkh_922 ._identity_1gmkh_609 small{display:none}._yearBoards_1gmkh_922 td>small{color:var(--omni-paint-ink-6384a1,#6384a1);margin-top:3px;font-size:10px;display:block}._productGrid_1gmkh_966{grid-template-columns:repeat(5,minmax(0,1fr));gap:14px;padding-inline:12px;display:grid;overflow:visible}._productGrid_1gmkh_966 article{border:1px solid var(--omni-paint-line-29455e,#29455e);background:var(--omni-paint-surface-10243a,#10243a);border-radius:5px;min-width:0;padding:12px;position:relative}._productGrid_1gmkh_966 article:hover,._productGrid_1gmkh_966 article:focus-within{z-index:20}._gridDetails_1gmkh_985{border:1px solid var(--omni-line,var(--omni-paint-line-29455e,#29455e));background:var(--omni-panel,var(--omni-paint-surface-10243a,#10243a));max-height:min(420px,60vh);box-shadow:0 12px 24px var(--omni-paint-shadow-0006,#0006);visibility:hidden;opacity:0;pointer-events:none;border-radius:0 0 5px 5px;padding:12px;position:absolute;top:100%;left:-1px;right:-1px;overflow:auto}._productGrid_1gmkh_966 article:hover ._gridDetails_1gmkh_985,._productGrid_1gmkh_966 article:focus-within ._gridDetails_1gmkh_985{visibility:visible;opacity:1;pointer-events:auto}._largeImage_1gmkh_1007{aspect-ratio:1;background:var(--omni-paint-surface-112b40,#112b40);height:auto;color:var(--omni-paint-ink-4c7897,#4c7897);justify-content:center;align-items:center;margin-bottom:0;display:flex;position:relative}._largeImage_1gmkh_1007 img{object-fit:contain;width:100%;height:100%}._page_1gmkh_1 ._largeImage_1gmkh_1007>._imageButton_1gmkh_616{width:100%;height:100%}._largeImage_1gmkh_1007>span{background:var(--omni-paint-surface-0a192cba,#0a192cba);color:var(--omni-paint-ink-8bb6d0,#8bb6d0);border-radius:3px;padding:2px 5px;font-size:10px;position:absolute;top:6px;left:6px}._largeImage_1gmkh_1007>._iconButton_1gmkh_399{position:absolute;top:5px;right:5px}._productGrid_1gmkh_966 ._identity_1gmkh_609{min-width:0}._productGrid_1gmkh_966 ._identity_1gmkh_609>._imageButton_1gmkh_616,._productGrid_1gmkh_966 ._noImage_1gmkh_705{display:none}._gridDetails_1gmkh_985>p{color:var(--omni-paint-ink-7094af,#7094af);font-size:11px}._productGrid_1gmkh_966 dl{margin:10px 0;font-size:11px}._productGrid_1gmkh_966 dl>div{border-top:1px solid var(--omni-paint-line-233e55,#233e55);justify-content:space-between;padding:5px 0;display:flex}._page_1gmkh_1 dt{color:var(--omni-paint-ink-7395b0,#7395b0)}._page_1gmkh_1 dd{color:var(--omni-paint-ink-b3cde1,#b3cde1);font-variant-numeric:tabular-nums;margin:0}._gridDetails_1gmkh_985>button{width:100%;font-size:11px}._picker_1gmkh_1075{min-width:180px;max-width:400px;position:relative}._picker_1gmkh_1075 summary{cursor:pointer;border:1px solid var(--omni-paint-line-36516b,#36516b);background:var(--omni-paint-surface-10243a,#10243a);border-radius:4px;justify-content:space-between;align-items:center;gap:14px;min-height:33px;padding:6px 10px;font-size:12px;list-style:none;display:flex}._picker_1gmkh_1075 summary::-webkit-details-marker{display:none}._picker_1gmkh_1075 summary[aria-disabled=true]{opacity:.45;cursor:default}._picker_1gmkh_1075 summary>svg{flex-shrink:0}._pickerPanel_1gmkh_1104{z-index:10;background:var(--omni-paint-surface-10283e,#10283e);border:1px solid var(--omni-paint-line-3c6381,#3c6381);width:max-content;min-width:300px;max-width:min(900px,100vw - 70px);box-shadow:0 12px 35px var(--omni-paint-shadow-0008,#0008);border-radius:6px;padding:12px;position:absolute;top:40px;left:0}._pickerPanel_1gmkh_1104>label{align-items:center;gap:8px;margin-bottom:10px;display:flex}._pickerPanel_1gmkh_1104 input{background:var(--omni-paint-surface-0a1b2d,#0a1b2d);width:100%;font-size:12px}._pickerModes_1gmkh_1129{gap:6px;margin-bottom:8px;display:flex}._page_1gmkh_1 ._pickerModes_1gmkh_1129 button{border:1px solid var(--omni-line,var(--omni-paint-line-2c435b,#2c435b));background:0 0;font-size:12px}._page_1gmkh_1 ._pickerModes_1gmkh_1129 button[aria-pressed=true]{background:var(--omni-panel,var(--omni-paint-surface-102235,#102235));color:var(--omni-accent,var(--omni-paint-ink-61d3f7,#61d3f7));border-color:currentColor}._pickerEmpty_1gmkh_1144{color:var(--omni-muted,var(--omni-paint-ink-829ab3,#829ab3));padding:12px 8px;font-size:12px}._page_1gmkh_1 ._pickerPanel_1gmkh_1104>button{color:var(--omni-paint-ink-75c6ed,#75c6ed);background:0 0;border:0;padding:5px 8px;font-size:12px}._cascade_1gmkh_1156{max-height:350px;margin-top:6px;display:flex;overflow:auto}._cascade_1gmkh_1156>div{border-right:1px solid var(--omni-paint-line-2c4861,#2c4861);width:225px;min-width:225px;max-height:340px;overflow:auto}._cascade_1gmkh_1156>div:last-child{border-right:0}._cascade_1gmkh_1156>div>div{justify-content:space-between;align-items:center;padding:2px 5px;display:flex}._page_1gmkh_1 ._cascade_1gmkh_1156 button{white-space:normal;text-align:left;background:0 0;border:0;justify-content:flex-start;padding:6px;font-size:11px}._cascade_1gmkh_1156>div>div>button:first-child{flex:1}._selectedCategory_1gmkh_1190{background:var(--omni-paint-surface-1b405c,#1b405c)}._pickerResults_1gmkh_1193{min-width:300px;max-width:700px;max-height:350px;overflow:auto}._page_1gmkh_1 ._pickerResults_1gmkh_1193 button{text-align:left;background:0 0;border:0;width:100%;font-size:12px;display:block}._dialog_1gmkh_1207{background:var(--omni-paint-surface-10263c,#10263c);border:1px solid var(--omni-paint-line-436987,#436987);width:min(790px,100vw - 30px);max-height:85vh;color:var(--omni-paint-ink-dbeaf8,#dbeaf8);box-shadow:0 25px 80px var(--omni-paint-shadow-0008,#0008);border-radius:10px;margin:auto;padding:22px;position:fixed;inset:0;overflow:auto}._dialog_1gmkh_1207::backdrop{background:var(--omni-paint-overlay-020b15b0,#020b15b0);-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}._dialog_1gmkh_1207>header{justify-content:space-between;align-items:center;gap:20px;margin-bottom:20px;display:flex}._dialog_1gmkh_1207 h2{margin:0;font-size:17px;font-weight:550;line-height:1.6}._dialog_1gmkh_1207 h3{color:var(--omni-paint-ink-96b4cc,#96b4cc);margin:12px 0;font-size:12px}._dialog_1gmkh_1207>header button{background:0 0;border:0;padding:2px}._fieldLayout_1gmkh_1248{grid-template-columns:1fr 1.2fr;gap:25px;display:grid}._fieldLayout_1gmkh_1248>section:first-child{border-right:1px solid var(--omni-paint-line-32536d,#32536d);padding-right:20px}._fieldLayout_1gmkh_1248 label{align-items:center;gap:9px;margin:14px 0;font-size:12px;display:flex}._page_1gmkh_1 input[type=checkbox]{accent-color:var(--omni-paint-ink-2caddb,#2caddb)}._fieldTools_1gmkh_1267{color:var(--omni-paint-ink-84a5bf,#84a5bf);align-items:center;gap:8px;font-size:11px;display:flex}._fieldTools_1gmkh_1267>span{margin-right:auto}._fieldTools_1gmkh_1267 button{padding:3px 6px;font-size:10px}._fieldLayout_1gmkh_1248 ol{padding:0;list-style:none}._fieldLayout_1gmkh_1248 li{border:1px solid var(--omni-paint-line-2e526c,#2e526c);background:var(--omni-paint-surface-112d45,#112d45);border-radius:4px;align-items:center;gap:5px;margin:6px 0;padding:7px 9px;font-size:12px;display:flex}._fieldLayout_1gmkh_1248 li>span{margin-right:auto}._fieldLayout_1gmkh_1248 li>button{padding:1px 6px;font-size:11px}._dialogActions_1gmkh_1303{border-top:1px solid var(--omni-paint-line-2e4e68,#2e4e68);justify-content:flex-end;gap:10px;margin-top:22px;padding-top:16px;display:flex}._chart_1gmkh_1311{min-width:0;height:260px;overflow:hidden}._detailScope_1gmkh_1316{color:var(--omni-paint-ink-81a2bd,#81a2bd);overflow-wrap:anywhere;font-size:11px}._detailMetrics_1gmkh_1321{grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;font-size:11px;display:grid}._detailMetrics_1gmkh_1321>div{background:var(--omni-paint-surface-0c1e31,#0c1e31);border-radius:5px;padding:12px}._detailMetrics_1gmkh_1321 dd{margin-top:7px;font-size:15px}@media (width<=1500px){._productGrid_1gmkh_966{grid-template-columns:repeat(4,minmax(0,1fr))}._period_1gmkh_163{display:none}._toolbar_1gmkh_90{gap:8px}._search_1gmkh_461 input{width:230px!important}}@media (width<=1050px){._categoryRows_1gmkh_260{row-gap:8px}._categoryRow_1gmkh_260{min-height:61px}._dateControl_1gmkh_140{justify-content:flex-start;margin-left:0}._filterBar_1gmkh_86{gap:12px}._productGrid_1gmkh_966{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (width<=650px){._page_1gmkh_1{padding:0 0 24px}._stickyHeader_1gmkh_74{padding-left:12px;padding-right:12px}._tabs_1gmkh_94{margin-left:-12px;margin-right:-12px;padding:0 12px}._picker_1gmkh_1075{max-width:calc(100vw - 110px)}._categoryName_1gmkh_334>span{font-size:11px!important}._categoryHeaders_1gmkh_259>div{font-size:10px}._categoryRow_1gmkh_260>strong,._categoryRow_1gmkh_260>span{font-size:11px}._dateControl_1gmkh_140{gap:6px}._dateControl_1gmkh_140 ._segment_1gmkh_191{margin-left:0}._search_1gmkh_461{width:100%}._page_1gmkh_1 ._search_1gmkh_461 input{width:100%!important}._toolbar_1gmkh_90>._segment_1gmkh_191{margin-left:auto}._price_1gmkh_491{flex-wrap:wrap}._productGrid_1gmkh_966{grid-template-columns:repeat(2,minmax(0,1fr))}._largeImage_1gmkh_1007{height:140px}._pickerPanel_1gmkh_1104{min-width:280px;max-width:calc(100vw - 26px)}._cascade_1gmkh_1156>div{width:160px;min-width:160px}._fieldLayout_1gmkh_1248{grid-template-columns:1fr 1.2fr;gap:12px}._fieldTools_1gmkh_1267{flex-wrap:wrap}._fieldTools_1gmkh_1267>span{width:100%}._fieldLayout_1gmkh_1248>section:first-child{padding-right:8px}._dialog_1gmkh_1207{padding:16px}._detailMetrics_1gmkh_1321{grid-template-columns:repeat(2,minmax(0,1fr))}._pagination_1gmkh_796>span{width:100%}._yearBoards_1gmkh_922>article{width:340px;min-width:340px}._count_1gmkh_148{font-size:10px}._productGrid_1gmkh_966 article{padding:8px}}@media (prefers-reduced-motion:reduce){._categoryRow_1gmkh_260{transition:none}}._competitorTray_1gmkh_1465{border:1px solid var(--omni-line,var(--omni-paint-line-294052,#294052));background:color-mix(in srgb,var(--omni-accent,var(--omni-paint-surface-28b9bf,#28b9bf)) 8%,transparent);border-radius:6px;justify-content:space-between;align-items:center;gap:12px;margin:10px 0;padding:10px 18px;font-size:12px;display:flex}._competitorTray_1gmkh_1465 button{color:var(--omni-accent,var(--omni-paint-ink-28b9bf,#28b9bf));cursor:pointer;font:inherit;background:0 0;border:0}._competitorActions_1gmkh_1467{align-items:center;gap:12px;margin-top:6px;display:flex}:root[data-omni-theme=light]{--omni-paint-surface-0a1524:#f5f6fa;--omni-paint-ink-dbe8f5:#252831;--omni-paint-line-30465e:#dde1eb;--omni-paint-surface-102239:#fff;--omni-paint-surface-193852:#fff;--omni-paint-line-4b92b9:#dde1eb;--omni-paint-line-60d2f6:#dde1eb;--omni-paint-ink-69c9f1:#626e80;--omni-paint-surface-187da7:#eef0ff;--omni-paint-line-298fac:#dde1eb;--omni-paint-ink-f1fbff:#252831;--omni-paint-line-263d55:#dde1eb;--omni-paint-ink-829ab3:#626e80;--omni-paint-ink-91a8be:#626e80;--omni-paint-ink-93abc0:#626e80;--omni-paint-ink-74c8ec:#626e80;--omni-paint-surface-112d43:#fff;--omni-paint-line-2a6386:#dde1eb;--omni-paint-ink-6e87a0:#626e80;--omni-paint-ink-9dbcd7:#626e80;--omni-paint-ink-61d3f7:#626e80;--omni-paint-ink-65ccf0:#626e80;--omni-paint-surface-14273c:#fff;--omni-paint-surface-101f32:#fff;--omni-paint-line-283e56:#dde1eb;--omni-paint-ink-7e97b0:#626e80;--omni-paint-surface-1b3b55:#fff;--omni-paint-ink-a6e7fc:#626e80;--omni-paint-shadow-020b1633:#0000000d;--omni-paint-ink-b8d8ea:#626e80;--omni-paint-line-345b72:#dde1eb;--omni-paint-surface-133049:#fff;--omni-paint-ink-718ca6:#626e80;--omni-paint-line-29425b:#dde1eb;--omni-paint-surface-153049:#fff;--omni-paint-line-397391:#dde1eb;--omni-paint-surface-102235:#fff;--omni-paint-line-2c435b:#dde1eb;--omni-paint-surface-61d3df:#eef0ff;--omni-paint-ink-d5e6f5:#252831;--omni-paint-ink-78d6f6:#626e80;--omni-paint-ink-70cfff:#626e80;--omni-paint-ink-9cb5cc:#626e80;--omni-paint-ink-688ba8:#626e80;--omni-paint-ink-68d3f4:#626e80;--omni-paint-surface-1c3c56:#fff;--omni-paint-line-335a73:#dde1eb;--omni-paint-ink-89cae7:#626e80;--omni-paint-ink-9fb3c7:#626e80;--omni-paint-line-47c5ee:#dde1eb;--omni-paint-ink-75d6f5:#626e80;--omni-paint-surface-0d1d30:#f5f6fa;--omni-paint-ink-6e8fa9:#626e80;--omni-paint-ink-adc4d9:#626e80;--omni-paint-ink-526d87:#626e80;--omni-paint-ink-91abc4:#626e80;--omni-paint-ink-cce3f4:#252831;--omni-paint-line-6185a1:#dde1eb;--omni-paint-line-233d55:#dde1eb;--omni-paint-surface-0d1e31:#fff;--omni-paint-ink-375572:#626e80;--omni-paint-ink-102138:#252831;--omni-paint-surface-162b40:#fff;--omni-paint-ink-a8bfd4:#626e80;--omni-paint-line-334c65:#dde1eb;--omni-paint-line-22384e:#dde1eb;--omni-paint-ink-acc1d4:#626e80;--omni-paint-surface-132b41:#fff;--omni-paint-ink-4b6782:#626e80;--omni-paint-accent-6acdf7:#4055db;--omni-paint-ink-a2d7f2:#626e80;--omni-paint-surface-10263c:#fff;--omni-paint-shadow-0008:#0000001f;--omni-paint-surface-030914ed:#f5f6faed;--omni-paint-ink-e1edfa:#252831;--omni-paint-line-63768c:#dde1eb;--omni-paint-surface-18344b:#fff;--omni-paint-ink-507b99:#626e80;--omni-paint-ink-6ecdf4:#626e80;--omni-paint-ink-6d8ba7:#626e80;--omni-paint-surface-1b344a:#fff;--omni-paint-ink-91b3cc:#626e80;--omni-paint-ink-65d8b4:#626e80;--omni-paint-surface-163d37:#fff;--omni-paint-ink-daebff:#252831;--omni-paint-ink-85bfdd:#626e80;--omni-paint-ink-f3b583:#626e80;--omni-paint-ink-7f9ab3:#626e80;--omni-paint-accent-70d0f5:#4055db;--omni-paint-line-3a94bb:#dde1eb;--omni-paint-surface-16364d:#fff;--omni-paint-ink-546f88:#626e80;--omni-paint-ink-bcae88:#626e80;--omni-paint-surface-2b281f:#fff;--omni-paint-line-5b4d31:#dde1eb;--omni-paint-ink-647f98:#626e80;--omni-paint-ink-86a6c0:#626e80;--omni-paint-ink-7f9bb4:#626e80;--omni-paint-line-28455f:#dde1eb;--omni-paint-surface-0d2135:#fff;--omni-paint-ink-5db3d6:#626e80;--omni-paint-ink-7899b5:#626e80;--omni-paint-surface-633c31:#fff;--omni-paint-ink-f2c0ab:#626e80;--omni-paint-surface-1d4778:#fff;--omni-paint-ink-b0d7ff:#252831;--omni-paint-surface-2c3a49:#fff;--omni-paint-ink-b7c9dc:#626e80;--omni-paint-line-29445f:#dde1eb;--omni-paint-surface-0d2033:#fff;--omni-paint-surface-142d44:#fff;--omni-paint-ink-6384a1:#626e80;--omni-paint-line-29455e:#dde1eb;--omni-paint-surface-10243a:#fff;--omni-paint-shadow-0006:#0000001a;--omni-paint-surface-112b40:#fff;--omni-paint-ink-4c7897:#626e80;--omni-paint-surface-0a192cba:#f5f6faba;--omni-paint-ink-8bb6d0:#626e80;--omni-paint-ink-7094af:#626e80;--omni-paint-line-233e55:#dde1eb;--omni-paint-ink-7395b0:#626e80;--omni-paint-ink-b3cde1:#626e80;--omni-paint-line-36516b:#dde1eb;--omni-paint-surface-10283e:#fff;--omni-paint-line-3c6381:#dde1eb;--omni-paint-surface-0a1b2d:#f5f6fa;--omni-paint-ink-75c6ed:#626e80;--omni-paint-line-2c4861:#dde1eb;--omni-paint-surface-1b405c:#fff;--omni-paint-line-436987:#dde1eb;--omni-paint-ink-dbeaf8:#252831;--omni-paint-overlay-020b15b0:#020a1580;--omni-paint-ink-96b4cc:#626e80;--omni-paint-line-32536d:#dde1eb;--omni-paint-ink-2caddb:#626e80;--omni-paint-ink-84a5bf:#626e80;--omni-paint-line-2e526c:#dde1eb;--omni-paint-surface-112d45:#fff;--omni-paint-line-2e4e68:#dde1eb;--omni-paint-ink-81a2bd:#626e80;--omni-paint-surface-0c1e31:#f5f6fa;--omni-paint-line-294052:#dde1eb;--omni-paint-surface-28b9bf:#eef0ff;--omni-paint-ink-28b9bf:#626e80}:root[data-omni-theme=dark]{--omni-paint-surface-0a1524:#0b1727;--omni-paint-ink-dbe8f5:#dceaf7;--omni-paint-line-30465e:#2c435b;--omni-paint-surface-102239:#102235;--omni-paint-surface-193852:#102235;--omni-paint-line-4b92b9:#2c435b;--omni-paint-line-60d2f6:#2c435b;--omni-paint-ink-69c9f1:#91a9bd;--omni-paint-surface-187da7:#193954;--omni-paint-line-298fac:#2c435b;--omni-paint-ink-f1fbff:#dceaf7;--omni-paint-line-263d55:#2c435b;--omni-paint-ink-829ab3:#91a9bd;--omni-paint-ink-91a8be:#91a9bd;--omni-paint-ink-93abc0:#91a9bd;--omni-paint-ink-74c8ec:#91a9bd;--omni-paint-surface-112d43:#102235;--omni-paint-line-2a6386:#2c435b;--omni-paint-ink-6e87a0:#91a9bd;--omni-paint-ink-9dbcd7:#91a9bd;--omni-paint-ink-61d3f7:#91a9bd;--omni-paint-ink-65ccf0:#91a9bd;--omni-paint-surface-14273c:#102235;--omni-paint-surface-101f32:#102235;--omni-paint-line-283e56:#2c435b;--omni-paint-ink-7e97b0:#91a9bd;--omni-paint-surface-1b3b55:#102235;--omni-paint-ink-a6e7fc:#91a9bd;--omni-paint-shadow-020b1633:#0000000d;--omni-paint-ink-b8d8ea:#91a9bd;--omni-paint-line-345b72:#2c435b;--omni-paint-surface-133049:#102235;--omni-paint-ink-718ca6:#91a9bd;--omni-paint-line-29425b:#2c435b;--omni-paint-surface-153049:#102235;--omni-paint-line-397391:#2c435b;--omni-paint-surface-102235:#102235;--omni-paint-line-2c435b:#2c435b;--omni-paint-surface-61d3df:#193954;--omni-paint-ink-d5e6f5:#dceaf7;--omni-paint-ink-78d6f6:#91a9bd;--omni-paint-ink-70cfff:#91a9bd;--omni-paint-ink-9cb5cc:#91a9bd;--omni-paint-ink-688ba8:#91a9bd;--omni-paint-ink-68d3f4:#91a9bd;--omni-paint-surface-1c3c56:#102235;--omni-paint-line-335a73:#2c435b;--omni-paint-ink-89cae7:#91a9bd;--omni-paint-ink-9fb3c7:#91a9bd;--omni-paint-line-47c5ee:#2c435b;--omni-paint-ink-75d6f5:#91a9bd;--omni-paint-surface-0d1d30:#0b1727;--omni-paint-ink-6e8fa9:#91a9bd;--omni-paint-ink-adc4d9:#91a9bd;--omni-paint-ink-526d87:#91a9bd;--omni-paint-ink-91abc4:#91a9bd;--omni-paint-ink-cce3f4:#dceaf7;--omni-paint-line-6185a1:#2c435b;--omni-paint-line-233d55:#2c435b;--omni-paint-surface-0d1e31:#102235;--omni-paint-ink-375572:#91a9bd;--omni-paint-ink-102138:#dceaf7;--omni-paint-surface-162b40:#102235;--omni-paint-ink-a8bfd4:#91a9bd;--omni-paint-line-334c65:#2c435b;--omni-paint-line-22384e:#2c435b;--omni-paint-ink-acc1d4:#91a9bd;--omni-paint-surface-132b41:#102235;--omni-paint-ink-4b6782:#91a9bd;--omni-paint-accent-6acdf7:#61d3df;--omni-paint-ink-a2d7f2:#91a9bd;--omni-paint-surface-10263c:#102235;--omni-paint-shadow-0008:#0000001f;--omni-paint-surface-030914ed:#0b1727ed;--omni-paint-ink-e1edfa:#dceaf7;--omni-paint-line-63768c:#2c435b;--omni-paint-surface-18344b:#102235;--omni-paint-ink-507b99:#91a9bd;--omni-paint-ink-6ecdf4:#91a9bd;--omni-paint-ink-6d8ba7:#91a9bd;--omni-paint-surface-1b344a:#102235;--omni-paint-ink-91b3cc:#91a9bd;--omni-paint-ink-65d8b4:#91a9bd;--omni-paint-surface-163d37:#102235;--omni-paint-ink-daebff:#dceaf7;--omni-paint-ink-85bfdd:#91a9bd;--omni-paint-ink-f3b583:#91a9bd;--omni-paint-ink-7f9ab3:#91a9bd;--omni-paint-accent-70d0f5:#61d3df;--omni-paint-line-3a94bb:#2c435b;--omni-paint-surface-16364d:#102235;--omni-paint-ink-546f88:#91a9bd;--omni-paint-ink-bcae88:#91a9bd;--omni-paint-surface-2b281f:#102235;--omni-paint-line-5b4d31:#2c435b;--omni-paint-ink-647f98:#91a9bd;--omni-paint-ink-86a6c0:#91a9bd;--omni-paint-ink-7f9bb4:#91a9bd;--omni-paint-line-28455f:#2c435b;--omni-paint-surface-0d2135:#102235;--omni-paint-ink-5db3d6:#91a9bd;--omni-paint-ink-7899b5:#91a9bd;--omni-paint-surface-633c31:#102235;--omni-paint-ink-f2c0ab:#91a9bd;--omni-paint-surface-1d4778:#102235;--omni-paint-ink-b0d7ff:#dceaf7;--omni-paint-surface-2c3a49:#102235;--omni-paint-ink-b7c9dc:#91a9bd;--omni-paint-line-29445f:#2c435b;--omni-paint-surface-0d2033:#102235;--omni-paint-surface-142d44:#102235;--omni-paint-ink-6384a1:#91a9bd;--omni-paint-line-29455e:#2c435b;--omni-paint-surface-10243a:#102235;--omni-paint-shadow-0006:#0000001a;--omni-paint-surface-112b40:#102235;--omni-paint-ink-4c7897:#91a9bd;--omni-paint-surface-0a192cba:#0b1727ba;--omni-paint-ink-8bb6d0:#91a9bd;--omni-paint-ink-7094af:#91a9bd;--omni-paint-line-233e55:#2c435b;--omni-paint-ink-7395b0:#91a9bd;--omni-paint-ink-b3cde1:#91a9bd;--omni-paint-line-36516b:#2c435b;--omni-paint-surface-10283e:#102235;--omni-paint-line-3c6381:#2c435b;--omni-paint-surface-0a1b2d:#0b1727;--omni-paint-ink-75c6ed:#91a9bd;--omni-paint-line-2c4861:#2c435b;--omni-paint-surface-1b405c:#102235;--omni-paint-line-436987:#2c435b;--omni-paint-ink-dbeaf8:#dceaf7;--omni-paint-overlay-020b15b0:#020a1580;--omni-paint-ink-96b4cc:#91a9bd;--omni-paint-line-32536d:#2c435b;--omni-paint-ink-2caddb:#91a9bd;--omni-paint-ink-84a5bf:#91a9bd;--omni-paint-line-2e526c:#2c435b;--omni-paint-surface-112d45:#102235;--omni-paint-line-2e4e68:#2c435b;--omni-paint-ink-81a2bd:#91a9bd;--omni-paint-surface-0c1e31:#0b1727;--omni-paint-line-294052:#2c435b;--omni-paint-surface-28b9bf:#193954;--omni-paint-ink-28b9bf:#91a9bd}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e={page:`_page_1gmkh_1`,primary:`_primary_1gmkh_69`,stickyHeader:`_stickyHeader_1gmkh_74`,breadcrumb:`_breadcrumb_1gmkh_83`,filterBar:`_filterBar_1gmkh_86`,toolbar:`_toolbar_1gmkh_90`,tabs:`_tabs_1gmkh_94`,categoryControl:`_categoryControl_1gmkh_139`,dateControl:`_dateControl_1gmkh_140`,count:`_count_1gmkh_148`,period:`_period_1gmkh_163`,yearButton:`_yearButton_1gmkh_168`,segment:`_segment_1gmkh_191`,message:`_message_1gmkh_215`,categoryList:`_categoryList_1gmkh_231`,categoryLegend:`_categoryLegend_1gmkh_237`,categoryHeaders:`_categoryHeaders_1gmkh_259`,categoryRows:`_categoryRows_1gmkh_260`,categoryRow:`_categoryRow_1gmkh_260`,categoryName:`_categoryName_1gmkh_334`,categoryOpen:`_categoryOpen_1gmkh_342`,iconButton:`_iconButton_1gmkh_399`,rowActions:`_rowActions_1gmkh_408`,search:`_search_1gmkh_461`,price:`_price_1gmkh_491`,configButton:`_configButton_1gmkh_515`,tableScroll:`_tableScroll_1gmkh_523`,sort:`_sort_1gmkh_570`,activeSort:`_activeSort_1gmkh_574`,productTable:`_productTable_1gmkh_578`,shopTable:`_shopTable_1gmkh_581`,shopName:`_shopName_1gmkh_599`,sales:`_sales_1gmkh_605`,identity:`_identity_1gmkh_609`,imageButton:`_imageButton_1gmkh_616`,productTitleRow:`_productTitleRow_1gmkh_630`,productId:`_productId_1gmkh_642`,imageHoverPreview:`_imageHoverPreview_1gmkh_649`,imageViewer:`_imageViewer_1gmkh_665`,imageViewerClose:`_imageViewerClose_1gmkh_692`,noImage:`_noImage_1gmkh_705`,productTitle:`_productTitle_1gmkh_630`,copyControl:`_copyControl_1gmkh_748`,copyButton:`_copyButton_1gmkh_748`,copyFeedback:`_copyFeedback_1gmkh_765`,shopId:`_shopId_1gmkh_780`,linkButton:`_linkButton_1gmkh_786`,anomaly:`_anomaly_1gmkh_793`,pagination:`_pagination_1gmkh_796`,ellipsis:`_ellipsis_1gmkh_836`,notice:`_notice_1gmkh_840`,sources:`_sources_1gmkh_850`,empty:`_empty_1gmkh_867`,emptyState:`_emptyState_1gmkh_874`,seasonBoard:`_seasonBoard_1gmkh_896`,hot:`_hot_1gmkh_902`,cold:`_cold_1gmkh_903`,neutral:`_neutral_1gmkh_904`,yearBoards:`_yearBoards_1gmkh_922`,productGrid:`_productGrid_1gmkh_966`,gridDetails:`_gridDetails_1gmkh_985`,largeImage:`_largeImage_1gmkh_1007`,picker:`_picker_1gmkh_1075`,pickerPanel:`_pickerPanel_1gmkh_1104`,pickerModes:`_pickerModes_1gmkh_1129`,pickerEmpty:`_pickerEmpty_1gmkh_1144`,cascade:`_cascade_1gmkh_1156`,selectedCategory:`_selectedCategory_1gmkh_1190`,pickerResults:`_pickerResults_1gmkh_1193`,dialog:`_dialog_1gmkh_1207`,fieldLayout:`_fieldLayout_1gmkh_1248`,fieldTools:`_fieldTools_1gmkh_1267`,dialogActions:`_dialogActions_1gmkh_1303`,chart:`_chart_1gmkh_1311`,detailScope:`_detailScope_1gmkh_1316`,detailMetrics:`_detailMetrics_1gmkh_1321`,competitorTray:`_competitorTray_1gmkh_1465`,competitorActions:`_competitorActions_1gmkh_1467`};export{e as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as e,o as t,y as n}from"./index-
|
|
1
|
+
import{g as e,o as t,y as n}from"./index-DLSVWUSu.js";var r=n(e(),1),i=t(),a=(0,r.createContext)(null);function o({value:e,children:t}){return(0,i.jsx)(a.Provider,{value:e,children:t})}function s(){let e=(0,r.useContext)(a);if(!e)throw Error(`模块需要在授权工作区中打开`);return e}export{s as n,o as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./index-
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`activity`,[[`path`,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,key:`169zse`}]]),n=e(`orbit`,[[`path`,{d:`M20.341 6.484A10 10 0 0 1 10.266 21.85`,key:`1enhxb`}],[`path`,{d:`M3.659 17.516A10 10 0 0 1 13.74 2.152`,key:`1crzgf`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}],[`circle`,{cx:`19`,cy:`5`,r:`2`,key:`mhkx31`}],[`circle`,{cx:`5`,cy:`19`,r:`2`,key:`v8kfzx`}]]);export{t as n,n as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`play`,[[`path`,{d:`M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z`,key:`10ikf1`}]]);export{t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{p as e}from"./index-DLSVWUSu.js";var t=e(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e,t}from"./clock-3-TH35nOP-.js";import{t as n}from"./play-DxbesM66.js";import{t as r}from"./plus-QakkcxdA.js";import{g as i,o as a,p as o,s,y as c}from"./index-BguiS02-.js";var l=o(`flag`,[[`path`,{d:`M4 22V4a1 1 0 0 1 .4-.8A6 6 0 0 1 8 2c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10a1 1 0 0 1-.4.8A6 6 0 0 1 16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528`,key:`1jaruq`}]]),u=o(`hand`,[[`path`,{d:`M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2`,key:`1fvzgz`}],[`path`,{d:`M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2`,key:`1kc0my`}],[`path`,{d:`M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8`,key:`10h0bg`}],[`path`,{d:`M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15`,key:`1s1gnw`}]]),d=c(i(),1),f=a();function p(e){let t=e.work;return t?.active?.length?t.active.map(e=>e.title).join(`、`):t?.queued?.length?`任务已排队,等待执行`:t?.problems?.length?`任务需要检查`:`等待下一次检查`}function m(e){return e.mode===`simulated`&&e.demoIssue?e.demoIssue:e.tier===`unassigned`?`还没有选择运营分组`:e.work?.problems?.length?e.work.problems.some(e=>e.state===`failed`)?`上次任务失败`:`运行状态需要核实`:e.work?.needsUpdate?`商品数据需要更新`:``}function h({products:i,tiers:a,ready:o,onAction:s,onAssign:c}){let d=i.filter(e=>m(e)),h={test:`核对点击和加购,挑出值得继续测的商品`,incubate:`检查新商品潜力,复查老商品是否赚钱`,scale:`核对付款人数和推广效果,安排后续投放`};function g(t,n){let r=m(t),i=p(t),a=t.work?.active?.length||t.work?.queued?.length,o=a?`等待任务完成,再核对结果`:t.work?.problems?.length?`先检查失败或过期的任务`:t.work?.needsUpdate?`先核对日期,补充需要的数据`:h[t.tier],c=n===`next`&&!a&&!r?`data`:`work`;return(0,f.jsxs)(`div`,{className:`ta-item`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:t.itemId}),(0,f.jsx)(`small`,{children:t.projectName}),(0,f.jsx)(`p`,{children:n===`now`?i:n===`needs`?r:o}),n!==`now`&&(0,f.jsx)(`small`,{children:t.work?.lastDate?`数据截至 `+t.work.lastDate:`尚无统计日期`})]}),(0,f.jsxs)(`button`,{onClick:()=>s(t,c),children:[n===`now`?`看任务`:n===`needs`?`去处理`:c===`data`?`看数据`:`去检查`,(0,f.jsx)(e,{size:12})]})]},t.key)}return(0,f.jsxs)(`section`,{className:`ta-board`,"aria-label":`各运营分组任务看板`,children:[(0,f.jsxs)(`div`,{className:`ta-heading`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`h2`,{children:`今天看这里,就知道怎么做`}),(0,f.jsx)(`p`,{children:`先看正在做的,再做下一步;橙色提醒需要你处理。`})]}),(0,f.jsxs)(`span`,{children:[o?d.length:`—`,` 个商品需要你处理`]})]}),(0,f.jsx)(`div`,{className:`ta-lanes`,children:a.map(e=>{let a=i.filter(t=>t.tier===e.id),s=a.filter(e=>m(e));return(0,f.jsxs)(`article`,{className:`ta-lane`,style:{"--tier-color":e.color},"aria-label":e.name+`任务看板`,children:[(0,f.jsxs)(`header`,{children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`small`,{children:e.caption}),(0,f.jsx)(`h3`,{children:e.name})]}),(0,f.jsxs)(`b`,{children:[o?a.length:`—`,(0,f.jsx)(`small`,{children:` 个商品`})]})]}),(0,f.jsx)(`p`,{className:`ta-goal`,children:e.goal}),(0,f.jsxs)(`section`,{className:`ta-stage now`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(n,{size:13}),`正在做什么 `,(0,f.jsxs)(`small`,{children:[a.filter(e=>e.work?.active?.length).length,` 个有运行记录`]})]}),a.length?(0,f.jsx)(`div`,{className:`ta-list`,children:a.map(e=>g(e,`now`))}):(0,f.jsx)(`p`,{className:`ta-placeholder`,children:o?`还没有商品加入,暂无执行任务。`:`正在读取任务记录…`})]}),(0,f.jsxs)(`section`,{className:`ta-stage next`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(l,{size:13}),`下一步做什么`]}),a.length?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`div`,{className:`ta-list`,children:a.map(e=>g(e,`next`))}),(0,f.jsxs)(`p`,{className:`ta-stage-note`,children:[e.cadence,`,以老师制定的企业标准判断。`]})]}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`p`,{className:`ta-placeholder`,children:`先选一个商品加入,再按下面的任务开始。`}),(0,f.jsx)(`p`,{className:`ta-planned`,children:h[e.id]}),(0,f.jsxs)(`button`,{className:`ta-add`,disabled:!i.length,onClick:()=>c(null,e.id),children:[(0,f.jsx)(r,{size:13}),`选择商品,加入`,e.name]})]})]}),(0,f.jsxs)(`section`,{className:`ta-stage needs`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(u,{size:13}),`需要你处理 `,(0,f.jsx)(`b`,{children:s.length})]}),s.length?(0,f.jsx)(`div`,{className:`ta-list`,children:s.map(e=>g(e,`needs`))}):(0,f.jsx)(`p`,{className:`ta-placeholder`,children:a.length?`目前没有数据更新或任务状态提醒。`:`先完成商品分组,才会显示对应待办。`})]}),(0,f.jsxs)(`details`,{className:`ta-rules`,children:[(0,f.jsx)(`summary`,{children:`什么时候检查?怎么判断?`}),(0,f.jsxs)(`p`,{children:[(0,f.jsx)(t,{size:12}),e.cadence]}),(0,f.jsx)(`p`,{children:e.rule}),(0,f.jsx)(`p`,{children:`频率来自方案,是否执行以实际任务记录为准。`})]}),a.length>0&&(0,f.jsx)(`button`,{className:`ta-add`,onClick:()=>c(null,e.id),children:`+ 添加或调整商品分组`})]},e.id)})}),` `,d.length>0&&(0,f.jsxs)(`details`,{className:`ta-inbox`,open:!0,children:[(0,f.jsxs)(`summary`,{children:[(0,f.jsx)(u,{size:15}),`需要你处理 `,(0,f.jsx)(`b`,{children:d.length})]}),(0,f.jsx)(`div`,{className:`ta-inbox-list`,children:d.map(t=>(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:t.itemId}),(0,f.jsx)(`small`,{children:t.projectName}),(0,f.jsx)(`p`,{children:m(t)})]}),(0,f.jsxs)(`button`,{onClick:()=>t.tier===`unassigned`?c(t):s(t,`work`),children:[t.tier===`unassigned`?`选择运营分组`:`查看并处理`,(0,f.jsx)(e,{size:13})]})]},t.key))})]}),(0,f.jsx)(`p`,{className:`ta-note`,children:`“需要你处理”来自未分组、最新统计日早于昨天、任务失败或运行状态待核实;不是自动判断商品好坏。推广预算和暂停操作需在已授权的推广系统中完成。`})]})}function g({products:e,product:t,suggestedTier:n,onSave:r,onClose:i,onDirty:a,onBusy:o}){let c=(0,d.useRef)(null),[l,u]=(0,d.useState)(t?.key||e.find(e=>e.tier===`unassigned`)?.key||e[0]?.key||``),[p,m]=(0,d.useState)(n||t?.tier||`unassigned`),[h,g]=(0,d.useState)(t?.note||``),[_,v]=(0,d.useState)(!1),[y,b]=(0,d.useState)(``),[x,S]=(0,d.useState)(``),[C,w]=(0,d.useState)(``),[T,E]=(0,d.useState)(!1);(0,d.useEffect)(()=>(a?.(T),()=>a?.(!1)),[T,a]),(0,d.useEffect)(()=>(o?.(_),()=>o?.(!1)),[_,o]);function D(){return!_&&(!T||confirm(`商品分组有未保存修改,放弃修改?`))}function O(){D()&&i()}let k=e.find(e=>e.key===l),A=k?.tier===`test`&&[`incubate`,`scale`].includes(p);return(0,d.useEffect)(()=>{c.current?.showModal()},[]),(0,f.jsxs)(`dialog`,{ref:c,className:`ta-dialog`,onChangeCapture:e=>{e.target.matches(`input,select,textarea`)&&E(!0)},onCancel:e=>{e.preventDefault(),O()},"aria-labelledby":`ta-dialog-title`,children:[(0,f.jsxs)(`div`,{className:`ta-dialog-head`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`small`,{children:`先完成这一件事`}),(0,f.jsx)(`h2`,{id:`ta-dialog-title`,children:`选择商品的运营策略`})]}),(0,f.jsx)(`button`,{"aria-label":`关闭商品分组`,disabled:_,onClick:O,children:(0,f.jsx)(s,{size:18})})]}),(0,f.jsx)(`p`,{children:`保存的是人工运营策略,看板按已有记录显示任务和待办。它不等于按全店支付销售额、访客和支付买家划定的经营梯队,也不会自动启动任务。`}),(0,f.jsxs)(`label`,{children:[`选择商品`,(0,f.jsx)(`select`,{"aria-label":`待分组商品`,disabled:_,value:l,onChange:t=>{if(!D())return;E(!1),S(``),w(``),u(t.target.value);let r=e.find(e=>e.key===t.target.value);m(n||r?.tier||`unassigned`),g(r?.note||``)},children:e.map(e=>(0,f.jsxs)(`option`,{value:e.key,children:[e.itemId,` · `,e.projectName]},e.key))})]}),(0,f.jsxs)(`label`,{children:[`这次采用哪种运营策略?`,(0,f.jsxs)(`select`,{"aria-label":`看板商品分组`,value:p,disabled:_,onChange:e=>m(e.target.value),children:[(0,f.jsx)(`option`,{value:`unassigned`,children:`暂不分组`}),(0,f.jsx)(`option`,{value:`test`,children:`测试组 · 新品测试`}),(0,f.jsx)(`option`,{value:`incubate`,children:`培养组 · 持续孵化`}),(0,f.jsx)(`option`,{value:`scale`,children:`放大组 · 重点推广`})]})]}),(0,f.jsxs)(`label`,{children:[`为什么这样分?(可选)`,(0,f.jsx)(`textarea`,{value:h,disabled:_,onChange:e=>g(e.target.value),placeholder:`写下对照了哪些商品、看了哪些数据,方便学员理解。`})]}),A&&(0,f.jsxs)(`div`,{className:`ta-qualification`,children:[(0,f.jsx)(`p`,{children:`记录运营晋级需要留下本项目采用的标准、观察时间和依据;这里只计数,不计算经营成功率。`}),(0,f.jsxs)(`label`,{children:[`老师设定的达标标准`,(0,f.jsx)(`textarea`,{"aria-label":`老师达标标准`,value:x,disabled:_,onChange:e=>S(e.target.value),placeholder:`填写这家企业采用的标准`})]}),(0,f.jsxs)(`label`,{children:[`这个商品的达标依据`,(0,f.jsx)(`textarea`,{"aria-label":`商品达标依据`,value:C,disabled:_,onChange:e=>w(e.target.value),placeholder:`填写统计日期、实际指标和核对依据`})]})]}),y&&(0,f.jsx)(`p`,{role:`alert`,children:y}),(0,f.jsx)(`button`,{className:`ta-save`,disabled:_||!k||A&&(!x.trim()||!C.trim()),onClick:async()=>{v(!0),b(``);try{await r(k,p,h,A?{confirmed:!0,standard:x.trim(),evidence:C.trim()}:void 0),i()}catch(e){b(e.message)}finally{v(!1)}},children:_?`正在保存…`:`保存分组,更新看板`}),(0,f.jsx)(`small`,{children:`保存分组不会启动采集、投放或修改广告预算,也不会改写经营梯队判定。`})]})}function _({product:e,onOpen:t,onClose:n}){let r=(0,d.useRef)(null);(0,d.useEffect)(()=>{r.current?.showModal()},[]);let i=e.work||{},a=[...i.active||[],...i.queued||[],...i.problems||[]];return(0,f.jsxs)(`dialog`,{ref:r,className:`ta-dialog`,onClose:n,"aria-labelledby":`ta-task-title`,children:[(0,f.jsxs)(`div`,{className:`ta-dialog-head`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`small`,{children:[e.projectName,` · `,e.itemId]}),(0,f.jsx)(`h2`,{id:`ta-task-title`,children:`这件事怎么处理`})]}),(0,f.jsx)(`button`,{"aria-label":`关闭商品任务`,onClick:n,children:(0,f.jsx)(s,{size:18})})]}),(0,f.jsx)(`p`,{children:m(e)||p(e)}),a.length?a.map(e=>(0,f.jsxs)(`div`,{className:`ta-task-record`,children:[(0,f.jsx)(`b`,{children:e.title}),(0,f.jsx)(`span`,{children:{running:`近期运行记录`,pending:`等待执行`,failed:`任务失败`,attention:`经营问题待处理`,uncertain:`运行状态待核实`}[e.state]}),(0,f.jsx)(`small`,{children:e.at||`未记录时间`}),(0,f.jsx)(`p`,{children:e.message||`查看监控页的实际结果后,再决定是否重新取数。`}),(0,f.jsxs)(`small`,{children:[`任务编号:`,e.id]})]},e.id)):(0,f.jsxs)(`p`,{children:[`没有归属于此商品的待执行或运行任务记录。`,i.lastDate?`最新数据统计到 `+i.lastDate+`。`:`尚无可用统计日期。`]}),(0,f.jsx)(`p`,{children:`先核对商品和日期,再按需要补数据或优化商品。`}),(0,f.jsx)(`button`,{className:`ta-save`,onClick:()=>{n(),t(e.project,{tab:`monitor`,itemId:e.itemId})},children:`进入监控,核对或补数据`}),(0,f.jsx)(`button`,{className:`ta-task-secondary`,onClick:()=>{n(),t(e.project,{tab:`optimization`,itemId:e.itemId})},children:`进入商品优化`}),(0,f.jsx)(`small`,{children:`商品编号会自动带入。打开页面不会启动取数或修改推广。`})]})}function v({product:e}){return(0,f.jsxs)(`div`,{className:`omni-product-identity`,children:[e.image&&(0,f.jsx)(`img`,{src:e.image,alt:e.title||e.projectName||`商品图片`}),(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:e.title||e.projectName||e.itemId}),(0,f.jsxs)(`small`,{children:[e.itemId,e.shopName?` · `+e.shopName:``]})]})]})}export{m as a,h as i,g as n,p as o,_ as r,v as t};
|
|
1
|
+
import{n as e,t}from"./clock-3-CDHtQwAe.js";import{t as n}from"./play-BxTFlaQX.js";import{t as r}from"./plus-D78h7lrw.js";import{g as i,o as a,p as o,s,y as c}from"./index-DLSVWUSu.js";var l=o(`flag`,[[`path`,{d:`M4 22V4a1 1 0 0 1 .4-.8A6 6 0 0 1 8 2c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10a1 1 0 0 1-.4.8A6 6 0 0 1 16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528`,key:`1jaruq`}]]),u=o(`hand`,[[`path`,{d:`M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2`,key:`1fvzgz`}],[`path`,{d:`M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2`,key:`1kc0my`}],[`path`,{d:`M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8`,key:`10h0bg`}],[`path`,{d:`M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15`,key:`1s1gnw`}]]),d=c(i(),1),f=a();function p(e){let t=e.work;return t?.active?.length?t.active.map(e=>e.title).join(`、`):t?.queued?.length?`任务已排队,等待执行`:t?.problems?.length?`任务需要检查`:`等待下一次检查`}function m(e){return e.mode===`simulated`&&e.demoIssue?e.demoIssue:e.tier===`unassigned`?`还没有选择运营分组`:e.work?.problems?.length?e.work.problems.some(e=>e.state===`failed`)?`上次任务失败`:`运行状态需要核实`:e.work?.needsUpdate?`商品数据需要更新`:``}function h({products:i,tiers:a,ready:o,onAction:s,onAssign:c}){let d=i.filter(e=>m(e)),h={test:`核对点击和加购,挑出值得继续测的商品`,incubate:`检查新商品潜力,复查老商品是否赚钱`,scale:`核对付款人数和推广效果,安排后续投放`};function g(t,n){let r=m(t),i=p(t),a=t.work?.active?.length||t.work?.queued?.length,o=a?`等待任务完成,再核对结果`:t.work?.problems?.length?`先检查失败或过期的任务`:t.work?.needsUpdate?`先核对日期,补充需要的数据`:h[t.tier],c=n===`next`&&!a&&!r?`data`:`work`;return(0,f.jsxs)(`div`,{className:`ta-item`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:t.itemId}),(0,f.jsx)(`small`,{children:t.projectName}),(0,f.jsx)(`p`,{children:n===`now`?i:n===`needs`?r:o}),n!==`now`&&(0,f.jsx)(`small`,{children:t.work?.lastDate?`数据截至 `+t.work.lastDate:`尚无统计日期`})]}),(0,f.jsxs)(`button`,{onClick:()=>s(t,c),children:[n===`now`?`看任务`:n===`needs`?`去处理`:c===`data`?`看数据`:`去检查`,(0,f.jsx)(e,{size:12})]})]},t.key)}return(0,f.jsxs)(`section`,{className:`ta-board`,"aria-label":`各运营分组任务看板`,children:[(0,f.jsxs)(`div`,{className:`ta-heading`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`h2`,{children:`今天看这里,就知道怎么做`}),(0,f.jsx)(`p`,{children:`先看正在做的,再做下一步;橙色提醒需要你处理。`})]}),(0,f.jsxs)(`span`,{children:[o?d.length:`—`,` 个商品需要你处理`]})]}),(0,f.jsx)(`div`,{className:`ta-lanes`,children:a.map(e=>{let a=i.filter(t=>t.tier===e.id),s=a.filter(e=>m(e));return(0,f.jsxs)(`article`,{className:`ta-lane`,style:{"--tier-color":e.color},"aria-label":e.name+`任务看板`,children:[(0,f.jsxs)(`header`,{children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`small`,{children:e.caption}),(0,f.jsx)(`h3`,{children:e.name})]}),(0,f.jsxs)(`b`,{children:[o?a.length:`—`,(0,f.jsx)(`small`,{children:` 个商品`})]})]}),(0,f.jsx)(`p`,{className:`ta-goal`,children:e.goal}),(0,f.jsxs)(`section`,{className:`ta-stage now`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(n,{size:13}),`正在做什么 `,(0,f.jsxs)(`small`,{children:[a.filter(e=>e.work?.active?.length).length,` 个有运行记录`]})]}),a.length?(0,f.jsx)(`div`,{className:`ta-list`,children:a.map(e=>g(e,`now`))}):(0,f.jsx)(`p`,{className:`ta-placeholder`,children:o?`还没有商品加入,暂无执行任务。`:`正在读取任务记录…`})]}),(0,f.jsxs)(`section`,{className:`ta-stage next`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(l,{size:13}),`下一步做什么`]}),a.length?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`div`,{className:`ta-list`,children:a.map(e=>g(e,`next`))}),(0,f.jsxs)(`p`,{className:`ta-stage-note`,children:[e.cadence,`,以老师制定的企业标准判断。`]})]}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`p`,{className:`ta-placeholder`,children:`先选一个商品加入,再按下面的任务开始。`}),(0,f.jsx)(`p`,{className:`ta-planned`,children:h[e.id]}),(0,f.jsxs)(`button`,{className:`ta-add`,disabled:!i.length,onClick:()=>c(null,e.id),children:[(0,f.jsx)(r,{size:13}),`选择商品,加入`,e.name]})]})]}),(0,f.jsxs)(`section`,{className:`ta-stage needs`,children:[(0,f.jsxs)(`h4`,{children:[(0,f.jsx)(u,{size:13}),`需要你处理 `,(0,f.jsx)(`b`,{children:s.length})]}),s.length?(0,f.jsx)(`div`,{className:`ta-list`,children:s.map(e=>g(e,`needs`))}):(0,f.jsx)(`p`,{className:`ta-placeholder`,children:a.length?`目前没有数据更新或任务状态提醒。`:`先完成商品分组,才会显示对应待办。`})]}),(0,f.jsxs)(`details`,{className:`ta-rules`,children:[(0,f.jsx)(`summary`,{children:`什么时候检查?怎么判断?`}),(0,f.jsxs)(`p`,{children:[(0,f.jsx)(t,{size:12}),e.cadence]}),(0,f.jsx)(`p`,{children:e.rule}),(0,f.jsx)(`p`,{children:`频率来自方案,是否执行以实际任务记录为准。`})]}),a.length>0&&(0,f.jsx)(`button`,{className:`ta-add`,onClick:()=>c(null,e.id),children:`+ 添加或调整商品分组`})]},e.id)})}),` `,d.length>0&&(0,f.jsxs)(`details`,{className:`ta-inbox`,open:!0,children:[(0,f.jsxs)(`summary`,{children:[(0,f.jsx)(u,{size:15}),`需要你处理 `,(0,f.jsx)(`b`,{children:d.length})]}),(0,f.jsx)(`div`,{className:`ta-inbox-list`,children:d.map(t=>(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:t.itemId}),(0,f.jsx)(`small`,{children:t.projectName}),(0,f.jsx)(`p`,{children:m(t)})]}),(0,f.jsxs)(`button`,{onClick:()=>t.tier===`unassigned`?c(t):s(t,`work`),children:[t.tier===`unassigned`?`选择运营分组`:`查看并处理`,(0,f.jsx)(e,{size:13})]})]},t.key))})]}),(0,f.jsx)(`p`,{className:`ta-note`,children:`“需要你处理”来自未分组、最新统计日早于昨天、任务失败或运行状态待核实;不是自动判断商品好坏。推广预算和暂停操作需在已授权的推广系统中完成。`})]})}function g({products:e,product:t,suggestedTier:n,onSave:r,onClose:i,onDirty:a,onBusy:o}){let c=(0,d.useRef)(null),[l,u]=(0,d.useState)(t?.key||e.find(e=>e.tier===`unassigned`)?.key||e[0]?.key||``),[p,m]=(0,d.useState)(n||t?.tier||`unassigned`),[h,g]=(0,d.useState)(t?.note||``),[_,v]=(0,d.useState)(!1),[y,b]=(0,d.useState)(``),[x,S]=(0,d.useState)(``),[C,w]=(0,d.useState)(``),[T,E]=(0,d.useState)(!1);(0,d.useEffect)(()=>(a?.(T),()=>a?.(!1)),[T,a]),(0,d.useEffect)(()=>(o?.(_),()=>o?.(!1)),[_,o]);function D(){return!_&&(!T||confirm(`商品分组有未保存修改,放弃修改?`))}function O(){D()&&i()}let k=e.find(e=>e.key===l),A=k?.tier===`test`&&[`incubate`,`scale`].includes(p);return(0,d.useEffect)(()=>{c.current?.showModal()},[]),(0,f.jsxs)(`dialog`,{ref:c,className:`ta-dialog`,onChangeCapture:e=>{e.target.matches(`input,select,textarea`)&&E(!0)},onCancel:e=>{e.preventDefault(),O()},"aria-labelledby":`ta-dialog-title`,children:[(0,f.jsxs)(`div`,{className:`ta-dialog-head`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`small`,{children:`先完成这一件事`}),(0,f.jsx)(`h2`,{id:`ta-dialog-title`,children:`选择商品的运营策略`})]}),(0,f.jsx)(`button`,{"aria-label":`关闭商品分组`,disabled:_,onClick:O,children:(0,f.jsx)(s,{size:18})})]}),(0,f.jsx)(`p`,{children:`保存的是人工运营策略,看板按已有记录显示任务和待办。它不等于按全店支付销售额、访客和支付买家划定的经营梯队,也不会自动启动任务。`}),(0,f.jsxs)(`label`,{children:[`选择商品`,(0,f.jsx)(`select`,{"aria-label":`待分组商品`,disabled:_,value:l,onChange:t=>{if(!D())return;E(!1),S(``),w(``),u(t.target.value);let r=e.find(e=>e.key===t.target.value);m(n||r?.tier||`unassigned`),g(r?.note||``)},children:e.map(e=>(0,f.jsxs)(`option`,{value:e.key,children:[e.itemId,` · `,e.projectName]},e.key))})]}),(0,f.jsxs)(`label`,{children:[`这次采用哪种运营策略?`,(0,f.jsxs)(`select`,{"aria-label":`看板商品分组`,value:p,disabled:_,onChange:e=>m(e.target.value),children:[(0,f.jsx)(`option`,{value:`unassigned`,children:`暂不分组`}),(0,f.jsx)(`option`,{value:`test`,children:`测试组 · 新品测试`}),(0,f.jsx)(`option`,{value:`incubate`,children:`培养组 · 持续孵化`}),(0,f.jsx)(`option`,{value:`scale`,children:`放大组 · 重点推广`})]})]}),(0,f.jsxs)(`label`,{children:[`为什么这样分?(可选)`,(0,f.jsx)(`textarea`,{value:h,disabled:_,onChange:e=>g(e.target.value),placeholder:`写下对照了哪些商品、看了哪些数据,方便学员理解。`})]}),A&&(0,f.jsxs)(`div`,{className:`ta-qualification`,children:[(0,f.jsx)(`p`,{children:`记录运营晋级需要留下本项目采用的标准、观察时间和依据;这里只计数,不计算经营成功率。`}),(0,f.jsxs)(`label`,{children:[`老师设定的达标标准`,(0,f.jsx)(`textarea`,{"aria-label":`老师达标标准`,value:x,disabled:_,onChange:e=>S(e.target.value),placeholder:`填写这家企业采用的标准`})]}),(0,f.jsxs)(`label`,{children:[`这个商品的达标依据`,(0,f.jsx)(`textarea`,{"aria-label":`商品达标依据`,value:C,disabled:_,onChange:e=>w(e.target.value),placeholder:`填写统计日期、实际指标和核对依据`})]})]}),y&&(0,f.jsx)(`p`,{role:`alert`,children:y}),(0,f.jsx)(`button`,{className:`ta-save`,disabled:_||!k||A&&(!x.trim()||!C.trim()),onClick:async()=>{v(!0),b(``);try{await r(k,p,h,A?{confirmed:!0,standard:x.trim(),evidence:C.trim()}:void 0),i()}catch(e){b(e.message)}finally{v(!1)}},children:_?`正在保存…`:`保存分组,更新看板`}),(0,f.jsx)(`small`,{children:`保存分组不会启动采集、投放或修改广告预算,也不会改写经营梯队判定。`})]})}function _({product:e,onOpen:t,onClose:n}){let r=(0,d.useRef)(null);(0,d.useEffect)(()=>{r.current?.showModal()},[]);let i=e.work||{},a=[...i.active||[],...i.queued||[],...i.problems||[]];return(0,f.jsxs)(`dialog`,{ref:r,className:`ta-dialog`,onClose:n,"aria-labelledby":`ta-task-title`,children:[(0,f.jsxs)(`div`,{className:`ta-dialog-head`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`small`,{children:[e.projectName,` · `,e.itemId]}),(0,f.jsx)(`h2`,{id:`ta-task-title`,children:`这件事怎么处理`})]}),(0,f.jsx)(`button`,{"aria-label":`关闭商品任务`,onClick:n,children:(0,f.jsx)(s,{size:18})})]}),(0,f.jsx)(`p`,{children:m(e)||p(e)}),a.length?a.map(e=>(0,f.jsxs)(`div`,{className:`ta-task-record`,children:[(0,f.jsx)(`b`,{children:e.title}),(0,f.jsx)(`span`,{children:{running:`近期运行记录`,pending:`等待执行`,failed:`任务失败`,attention:`经营问题待处理`,uncertain:`运行状态待核实`}[e.state]}),(0,f.jsx)(`small`,{children:e.at||`未记录时间`}),(0,f.jsx)(`p`,{children:e.message||`查看监控页的实际结果后,再决定是否重新取数。`}),(0,f.jsxs)(`small`,{children:[`任务编号:`,e.id]})]},e.id)):(0,f.jsxs)(`p`,{children:[`没有归属于此商品的待执行或运行任务记录。`,i.lastDate?`最新数据统计到 `+i.lastDate+`。`:`尚无可用统计日期。`]}),(0,f.jsx)(`p`,{children:`先核对商品和日期,再按需要补数据或优化商品。`}),(0,f.jsx)(`button`,{className:`ta-save`,onClick:()=>{n(),t(e.project,{tab:`monitor`,itemId:e.itemId})},children:`进入监控,核对或补数据`}),(0,f.jsx)(`button`,{className:`ta-task-secondary`,onClick:()=>{n(),t(e.project,{tab:`optimization`,itemId:e.itemId})},children:`进入商品优化`}),(0,f.jsx)(`small`,{children:`商品编号会自动带入。打开页面不会启动取数或修改推广。`})]})}function v({product:e}){return(0,f.jsxs)(`div`,{className:`omni-product-identity`,children:[e.image&&(0,f.jsx)(`img`,{src:e.image,alt:e.title||e.projectName||`商品图片`}),(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`b`,{children:e.title||e.projectName||e.itemId}),(0,f.jsxs)(`small`,{children:[e.itemId,e.shopName?` · `+e.shopName:``]})]})]})}export{m as a,h as i,g as n,p as o,_ as r,v as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{t as e}from"./arrow-up-right-DzAKT3cL.js";import{t}from"./book-open-C0B9Pao9.js";import{n,t as r}from"./link-2-CCKUDMV6.js";import{t as i}from"./chevron-right-CZlQQ5gV.js";import{t as a}from"./download-BlJN0Lg8.js";import{t as o}from"./file-text-Hd45wNTe.js";import{t as s}from"./plus-QakkcxdA.js";import{t as c}from"./search-Cisx0wBF.js";import{g as l,o as u,p as d,u as f,y as p}from"./index-BguiS02-.js";import{n as m}from"./workspace-view-state-BJMX6vWb.js";import{t as h}from"./HelpTip-CX2LFdwD.js";import{t as ee}from"./EmptyState-CE7obISq.js";var g=d(`file-braces`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1`,key:`1oajmo`}],[`path`,{d:`M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1`,key:`mpwhp6`}]]),_=d(`rotate-ccw-clock`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}],[`path`,{d:`M12 7v5l4 2`,key:`1fdv2h`}]]),v=p(l(),1),y=u(),b={simulated:`模拟数据`,"declared-real":`来源标注为真实(尚需核实)`,unverified:`真实性待核`},x=(e,t)=>e==null?`—`:typeof e!=`number`||!Number.isFinite(e)?S(e):t.type===`percent`?(e*100).toLocaleString(`zh-CN`,{maximumFractionDigits:2})+`%`:t.type===`text`?String(e):e.toLocaleString(`zh-CN`,{maximumFractionDigits:[`元`,`CNY`].includes(t.unit)?2:6}),S=e=>e==null?`—`:typeof e==`object`?JSON.stringify(e):String(e);function C({data:e,api:t,initialId:r=``,onWiki:o,onPrepare:s,onArchive:l,onSelect:u}){let[d,p]=(0,v.useState)([]),[_,C]=(0,v.useState)(0),[w,T]=(0,v.useState)(r),[E,D]=(0,v.useState)(null),[O,k]=m(`resources.data.`+e.project.id+`.query`,``),[A,j]=m(`resources.data.`+e.project.id+`.`+r+`.page`,1),[M,N]=(0,v.useState)(``),[te,P]=(0,v.useState)(!0),[F,I]=(0,v.useState)(0),[L,R]=(0,v.useState)(!1);(0,v.useEffect)(()=>{let n=!0;return P(!0),N(``),t(`/`+e.project.id+`/datasets`).then(e=>{n&&(p(e.datasets),C(e.pendingImports),T(t=>e.datasets.some(e=>e.id===t)?t:r?``:e.datasets[0]?.id||``),r&&!e.datasets.some(e=>e.id===r)&&N(`指定的数据集不可访问或已变更,请在目录中重新选择。`))}).catch(e=>n&&N(e.message)).finally(()=>n&&P(!1)),()=>{n=!1}},[e.project.id,t,F]),(0,v.useEffect)(()=>{if(!w)return;let n=!0;return D(null),N(``),t(`/`+e.project.id+`/datasets/`+encodeURIComponent(w)+`?page=`+A).then(e=>n&&D(e)).catch(e=>n&&N(e.message)),()=>{n=!1}},[w,A,e.project.id,t,F]);let z=(0,v.useMemo)(()=>d.filter(e=>`${e.title} ${e.source} ${e.period}`.toLowerCase().includes(O.toLowerCase())),[d,O]);function B(e){j(1),T(e),u?.(e)}return(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`数据中心`,(0,y.jsx)(h,{label:`查看经营数据`,children:`先按资料名称、来源或统计时间查找,再查看明细。空值表示缺失,不等于零;原始经营数据保存在数据库。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`查询数据集、统计窗口与来源。缺失值显示为「—」,真实零保留为 0。`})]}),(0,y.jsxs)(`span`,{className:`wb-chip`,children:[(0,y.jsx)(f,{size:14}),` 专用数据库 · `,d.length,` 个数据集`]})]}),M&&(0,y.jsxs)(`div`,{role:`alert`,className:`error`,children:[M,` `,(0,y.jsx)(`button`,{onClick:()=>I(e=>e+1),children:`重新读取`})]}),_>0&&(0,y.jsxs)(`div`,{className:`wb-callout`,children:[`有 `,_,` 份 JSON 附件尚未进入数据中心。原件仍在「证据与附件」中,可由维护人员核验后迁移。`]}),te?(0,y.jsx)(`p`,{role:`status`,children:`正在读取数据库目录…`}):d.length?(0,y.jsxs)(`div`,{className:`wb-data-layout`,children:[(0,y.jsxs)(`section`,{className:`card wb-catalog`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索数据集`,placeholder:`搜索资料名称、来源、统计时间`,value:O,onChange:e=>k(e.target.value)})]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`找到 `,z.length,` 个数据集`]}),(0,y.jsxs)(`div`,{className:`wb-dataset-list`,children:[z.map(e=>(0,y.jsxs)(`button`,{className:w===e.id?`active`:``,onClick:()=>B(e.id),children:[(0,y.jsxs)(`span`,{children:[(0,y.jsx)(g,{size:16}),(0,y.jsx)(`b`,{children:e.title})]}),(0,y.jsxs)(`small`,{children:[e.rowCount,` 行 · `,b[e.mode]]}),(0,y.jsx)(`small`,{children:e.period||String(e.created).slice(0,10)})]},e.id)),!z.length&&(0,y.jsx)(`p`,{className:`muted`,children:`没有匹配的数据集。`})]})]}),(0,y.jsx)(`section`,{className:`card wb-data-detail`,"aria-live":`polite`,children:E?(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`span`,{className:`wb-chip `+(E.mode===`simulated`?`warning`:``),children:b[E.mode]}),(0,y.jsx)(`h2`,{children:E.title})]}),(0,y.jsxs)(`a`,{className:`wb-link-button`,href:`/api/workbench/`+e.project.id+`/file/`+E.artifactId,children:[(0,y.jsx)(a,{size:15}),` 原始文件`]})]}),(0,y.jsxs)(`dl`,{className:`wb-metadata`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`统计窗口`}),(0,y.jsx)(`dd`,{children:E.period||`未提供`})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`归档时间`}),(0,y.jsx)(`dd`,{children:E.created})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`数据来源`}),(0,y.jsx)(`dd`,{children:E.source||`未提供`})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`数据状态`}),(0,y.jsxs)(`dd`,{children:[E.rowCount,` 行 · 原始记录保留 · `,b[E.mode]]})]})]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`原始记录的口径、备注与假设`}),(0,y.jsx)(`p`,{children:E.note==null?`原数据集未单独提供备注。请结合来源和原件核对。`:typeof E.note==`string`?E.note:JSON.stringify(E.note,null,2)})]}),(0,y.jsxs)(`label`,{className:`wb-raw-toggle`,children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:L,onChange:e=>R(e.target.checked)}),` 显示原始值`,(0,y.jsx)(`span`,{children:`金额按单位显示,百分比按列定义换算;原值保留不变。`})]}),(0,y.jsx)(`div`,{className:`wb-table-wrap`,tabIndex:0,"aria-label":`数据表,可横向滚动`,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`col`,children:`行号`}),E.columns.map(e=>(0,y.jsxs)(`th`,{scope:`col`,children:[e.label||e.key,e.unit?`(`+e.unit+`)`:``]},e.key))]})}),(0,y.jsx)(`tbody`,{children:E.rows.map(e=>(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`row`,children:e.index+1}),E.columns.map(t=>(0,y.jsx)(`td`,{title:S(e.values[t.key]),children:L?S(e.values[t.key]):x(e.values[t.key],t)},t.key))]},e.index))})]})}),(0,y.jsxs)(`div`,{className:`wb-pagination`,children:[(0,y.jsxs)(`span`,{children:[`共 `,E.rowCount,` 行 · 第 `,A,` / `,Math.max(1,Math.ceil(E.rowCount/50)),` 页`]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`button`,{"aria-label":`上一页`,disabled:A===1,onClick:()=>j(e=>e-1),children:(0,y.jsx)(n,{size:16})}),(0,y.jsx)(`button`,{"aria-label":`下一页`,disabled:A*50>=E.rowCount,onClick:()=>j(e=>e+1),children:(0,y.jsx)(i,{size:16})})]})]}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`查看记录标识与完整性校验`}),(0,y.jsxs)(`p`,{children:[`数据集 ID:`,E.id]}),(0,y.jsxs)(`p`,{children:[`来源 SHA256:`,E.sha]}),(0,y.jsxs)(`p`,{children:[`数据格式:`,E.format]})]}),(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>o(E.id),children:`用这份数据记录分析结论 →`}),l&&(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>l(E.id),children:`用这份数据进入分析任务 →`})]}):(0,y.jsx)(`p`,{role:`status`,children:M?`数据读取失败,请重试。`:`正在读取数据行…`})})]}):(0,y.jsx)(`section`,{className:`card`,children:(0,y.jsxs)(ee,{title:`还没有入库数据`,children:[`先准备本项目原始文件,注明店铺/商品、统计日期、指标含义和来源。普通表格需整理成该模块认可的资料格式后才能入库;上传附件不等于已完成数据导入。系统不会创建示例经营数据。`,s&&(0,y.jsx)(`p`,{children:(0,y.jsx)(`button`,{onClick:s,children:`查看或准备项目原件`})})]})})]})}var w={keyword:`关键词证据`,review:`评价证据`,product:`商品资料`,analysis:`分析导入`,artifact:`制作产物`};function T({data:e,api:t,onSaved:n,onDirty:r,onBusy:i}){let[o,s]=m(`resources.files.`+e.project.id+`.query`,``),[l,u]=m(`resources.files.`+e.project.id+`.kind`,`all`),[d,f]=(0,v.useState)(!1),[p,g]=(0,v.useState)(null),[_,b]=(0,v.useState)(``),[x,S]=(0,v.useState)(`keyword`),[C,T]=(0,v.useState)(!1),[E,D]=(0,v.useState)(``),O=(0,v.useRef)(null);(0,v.useEffect)(()=>{r?.(!!p||!!_.trim())},[p,_,r]),(0,v.useEffect)(()=>(i?.(C),()=>i?.(!1)),[C,i]);async function k(){if(!(!p||C)){T(!0),D(``);try{if(p.size>2e6)throw Error(`单文件上限2MB`);let r=new Uint8Array(await p.arrayBuffer()),i=``;for(let e of r)i+=String.fromCharCode(e);await t(`/`+e.project.id+`/file`,{name:p.name,source:_,kind:x,base64:btoa(i)}),g(null),b(``),O.current&&(O.current.value=``),await n(),D(`原文件已归档。数据入库与内容核验仍需在相应模块完成。`)}catch(e){D(e.message)}finally{T(!1)}}}let A=e.files.filter(e=>(l===`all`||e.kind===l)&&`${e.name} ${e.source}`.toLowerCase().includes(o.toLowerCase()));return(0,y.jsxs)(`section`,{className:`card`,children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`证据与附件`,(0,y.jsx)(h,{label:`上传与引用资料`,children:`这里保留原文件。上传时说明来源和采集日期;文件存在不代表内容真实,分析前仍需核对。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`保留原文件、来源和完整性校验信息,便于核对分析依据。`})]}),(0,y.jsx)(`button`,{onClick:()=>f(!d),children:d?`收起上传`:`上传原始资料`})]}),d&&(0,y.jsxs)(`form`,{className:`wb-upload-form`,onSubmit:e=>{e.preventDefault(),k()},children:[(0,y.jsxs)(`label`,{children:[`资料类型`,(0,y.jsx)(`select`,{disabled:C,value:x,onChange:e=>S(e.target.value),children:Object.entries(w).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[`来源与采集日期`,(0,y.jsx)(`input`,{disabled:C,required:!0,value:_,onChange:e=>b(e.target.value),placeholder:`说明来源、日期和是否为模拟资料`})]}),(0,y.jsxs)(`label`,{children:[`原始文件(≤2MB)`,(0,y.jsx)(`input`,{ref:O,disabled:C,type:`file`,onChange:e=>g(e.target.files?.[0]||null)})]}),(0,y.jsx)(`p`,{className:`muted`,children:`保存原件与来源,不自动导入数据或生成分析结论。`}),(0,y.jsx)(`button`,{disabled:C||!p||!_.trim(),children:C?`正在上传…`:`上传并归档`})]}),E&&(0,y.jsx)(`p`,{role:`status`,children:E}),(0,y.jsxs)(`div`,{className:`wb-toolbar`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索附件`,placeholder:`搜索文件名称或来源`,value:o,onChange:e=>s(e.target.value)})]}),(0,y.jsxs)(`select`,{"aria-label":`附件类型`,value:l,onChange:e=>u(e.target.value),children:[(0,y.jsx)(`option`,{value:`all`,children:`全部类型`}),Object.entries(w).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))]})]}),A.length?(0,y.jsx)(`div`,{className:`wb-table-wrap`,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{children:`文件名称`}),(0,y.jsx)(`th`,{children:`类型`}),(0,y.jsx)(`th`,{children:`来源`}),(0,y.jsx)(`th`,{children:`归档时间`}),(0,y.jsx)(`th`,{children:`文件大小`}),(0,y.jsx)(`th`,{children:`操作`})]})}),(0,y.jsx)(`tbody`,{children:A.map(t=>(0,y.jsxs)(`tr`,{children:[(0,y.jsxs)(`td`,{children:[(0,y.jsx)(`b`,{children:t.name}),(0,y.jsxs)(`details`,{children:[(0,y.jsx)(`summary`,{children:`查看文件标识与完整性信息`}),(0,y.jsxs)(`p`,{className:`wb-hash`,children:[`ID:`,t.id,(0,y.jsx)(`br`,{}),`SHA256:`,t.sha]})]})]}),(0,y.jsx)(`td`,{children:w[t.kind]||t.kind}),(0,y.jsx)(`td`,{children:t.source}),(0,y.jsx)(`td`,{children:String(t.created).slice(0,10)}),(0,y.jsxs)(`td`,{children:[(t.bytes/1024).toFixed(1),` KB`]}),(0,y.jsx)(`td`,{children:(0,y.jsx)(`a`,{"aria-label":`下载 `+t.name,href:`/api/workbench/`+e.project.id+`/file/`+t.id,children:(0,y.jsx)(a,{size:16})})})]},t.id))})]})}):(0,y.jsx)(ee,{title:`没有匹配的附件`,children:`可先准备表格、文本或图片,注明来源与日期。单文件不超过2MB;点击上方按钮直接上传。原件归档后仍需对应模块整理与核验,不会自动变成分析结果。`})]})}var E=[[`question`,`分析问题`,`这次要回答什么问题,影响哪个决策?`],[`method`,`方法与选择理由`,`使用什么方法,为什么适合这个问题?`],[`metricDefinitions`,`指标口径`,`时间窗口、样本范围、分母、单位与对比基准`],[`steps`,`数据处理与分析步骤`,`按顺序记录筛选、清洗、比较、计算和检查;原始表保留在数据中心`],[`rationale`,`关键判断依据`,`哪些观测支持结论?按所选数据集、行 ID 或附件位置标出每个判断的证据。`],[`counterEvidence`,`反证与替代解释`,`哪些证据不支持当前判断?考虑过哪些其他解释?`],[`assumptions`,`假设与待验证项`,`哪些前提尚未验证?区分事实、推断和假设`],[`limitations`,`适用边界与限制`,`样本偏差、缺失数据、不可外推的对象和周期`],[`action`,`行动与负责人`,`准备做什么、由谁负责;记录计划不代表已经执行`],[`expected`,`预期指标与验收标准`,`指标、基线、目标、观察窗口和停止条件`],[`actual`,`实际结果摘要`,`复盘时填写实测结果摘要,并选择对应结果数据;没有实测则留空`],[`learning`,`复盘判断与方法调整`,`预期和实际差异、原假设是否成立、下一次如何调整方法`],[`changes`,`本版变更说明`,`本次补充、纠正或调整了什么,为什么`]],D=()=>({...Object.fromEntries(E.map(([e])=>[e,``])),status:`draft`,reviewOn:``}),O={draft:`草稿 · 待补充`,planned:`已记录计划 · 待复盘`,reviewed:`已填写复盘`};function k({form:e,change:t,evidenceOptions:n,busy:r}){let i=e.reviewRecord,a=(e,n)=>t(`reviewRecord`,{...i,[e]:n});return(0,y.jsxs)(`fieldset`,{className:`wb-analysis-fields`,disabled:r,children:[(0,y.jsxs)(`legend`,{children:[`分析方法与复盘记录`,(0,y.jsx)(h,{label:`怎样复盘`,children:`写清问题、用到的资料、判断依据、反例和实际结果。完成复盘需选择结果证据;没有执行的计划不能当作结果。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`记录可核查的方法、依据和结果。未知内容留空,按草稿保存;不要补造历史过程或把未经验证的计划记为执行结果。`}),(0,y.jsxs)(`div`,{className:`two`,children:[(0,y.jsxs)(`label`,{children:[`记录状态`,(0,y.jsx)(`select`,{value:i.status,onChange:e=>a(`status`,e.target.value),children:Object.entries(O).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[`计划复盘日期`,(0,y.jsx)(`input`,{type:`date`,value:i.reviewOn,onChange:e=>a(`reviewOn`,e.target.value)})]})]}),E.map(([e,t,n])=>(0,y.jsxs)(`label`,{children:[t,(0,y.jsx)(`textarea`,{rows:e===`steps`?4:3,maxLength:1e4,value:i[e]||``,placeholder:n,onChange:t=>a(e,t.target.value)})]},e)),(0,y.jsxs)(`fieldset`,{className:`wb-evidence-picker`,children:[(0,y.jsx)(`legend`,{children:`实际结果证据(完成复盘时必选)`}),e.refs.length?e.refs.map(r=>(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:e.resultRefs.includes(r),onChange:n=>t(`resultRefs`,n.target.checked?[...e.resultRefs,r]:e.resultRefs.filter(e=>e!==r))}),n.find(e=>e.id===r)?.label||r]},r)):(0,y.jsx)(`p`,{className:`muted`,children:`请先在下方选择本项目证据,再标记哪些是实际复盘结果。`})]})]})}function A({current:e,entries:t,onSelect:n}){let r=e.analysisRecord,i=e.analysisOrigin&&t.find(t=>t.id===e.analysisOrigin.id&&t.kind===e.analysisOrigin.kind);if(!r)return(0,y.jsxs)(`div`,{className:`wb-callout`,children:[(0,y.jsx)(`b`,{children:`尚未建立完整分析复盘记录`}),(0,y.jsx)(`p`,{children:`此记录保留了当时填写的内容。已有内容在上方展示;空缺项表示“当时未记录”。未记录的步骤、口径、假设、反证和复盘结果无法还原;可创建关联分析,逐项补充有依据的说明。`})]});let a=t.find(t=>t.id===e.parentRevisionId),o=a?.analysisRecord?E.filter(([e])=>r[e]!==a.analysisRecord[e]).map(([,e])=>e):[];return(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`div`,{className:`wb-analysis-status`,children:[(0,y.jsx)(`span`,{className:`wb-chip`,children:O[r.status]}),(0,y.jsxs)(`span`,{children:[`计划复盘:`,r.reviewOn||`未安排`]}),r.reviewedAt&&(0,y.jsxs)(`span`,{children:[`记录复盘结果:`,r.reviewedAt.slice(0,10)]})]}),e.analysisGaps?.length>0&&(0,y.jsxs)(`div`,{className:`wb-callout`,children:[`尚未记录:`,e.analysisGaps.join(`、`),`。缺项保持为空,不能视为已验证。`]}),e.analysisOrigin&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联原记录`}),i?(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>n(i.id),children:[i.title,` →`]}):(0,y.jsx)(`p`,{children:`原记录已不可读取,保留归档时的快照。`}),(0,y.jsxs)(`p`,{className:`muted`,children:[e.originSnapshot?.created,` · `,e.originSnapshot?.version?`v`+e.originSnapshot.version:`原记录未提供版本号`]}),e.originChanged&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`原记录已变化或无法读取。此分析使用归档时快照,请在修订时重新核对。`}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`查看原记录归档快照`}),(0,y.jsx)(`p`,{children:e.originSnapshot?.summary}),(0,y.jsxs)(`p`,{children:[`原分析文字:`,e.originSnapshot?.analysis||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原方法名称:`,e.originSnapshot?.method||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原步骤:`,e.originSnapshot?.recordedSteps||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原预期:`,e.originSnapshot?.outputs||`未记录`]}),(0,y.jsxs)(`p`,{children:[`快照 SHA256:`,e.originSnapshot?.hash]})]})]}),E.filter(([e])=>r[e]).map(([e,t])=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:t}),(0,y.jsx)(`p`,{children:r[e]})]},e)),a&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`版本变更`}),(0,y.jsxs)(`p`,{children:[`相对 v`,a.version,`:`,o.length?o.join(`、`):`分析字段未变;请同时核对结论、来源与状态`,`。`]}),(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>n(a.id),children:`查看上一版本 →`})]}),!!e.sourceSnapshots?.length&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`使用的输入与来源版本`}),(0,y.jsx)(`p`,{className:`muted`,children:`保存时固定来源标识与版本信息。原始指标和完整数据仍在数据库及附件中。`}),e.sourceSnapshots.map(e=>(0,y.jsxs)(`div`,{className:`wb-reference`,children:[(0,y.jsx)(`b`,{children:e.title||`阶段版本`}),r.resultRefs?.includes(e.id)&&(0,y.jsx)(`span`,{className:`wb-chip`,children:`实际结果证据`}),(0,y.jsxs)(`p`,{children:[e.period||`未提供统计窗口`,` · `,e.version?`v`+e.version:e.created]}),(0,y.jsx)(`p`,{children:e.source||`来源描述未记录`}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`来源标识与文件完整性信息`}),(0,y.jsx)(`p`,{children:e.id}),(0,y.jsxs)(`p`,{children:[`SHA256:`,e.sha||`未提供`]})]})]},e.id))]})]})}var j={method:`任务与方法`,analysis:`分析与复盘`,action:`行动与验证`,node:`流程分析与确认`,demand:`需求分析`,note:`分析文档`,finding:`结论记录`,step:`阶段记录`,playbook:`方法论`};function M(e){let t=String(e.title||`未命名记录`);return e.kind===`node`?t.replace(/\s*·\s*[a-z0-9-]+-[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,``):t}function N(e){return e.kind===`node`&&String(e.summary||``).startsWith(`由工作台提交运行 · `)?`本节点资料已提交并留档。请查看输入、证据和待复核事项;提交记录不代表已完成人工确认或真实经营执行。`:e.summary}var te={title:``,summary:``,analysis:``,source:``,refs:[],pageId:``,expectedVersion:0,reviewRecord:D(),resultRefs:[],origin:null,originHash:``};function P({data:n,api:i,initialRef:a=``,initialEntry:l=``,onDirty:u,onData:d,onMethods:f}){let[p,g]=(0,v.useState)([]),[b,x]=(0,v.useState)([]),[S,C]=m(`resources.wiki.`+n.project.id+`.query`,``),[w,T]=m(`resources.wiki.`+n.project.id+`.kind`,`all`),[E,O]=m(`resources.wiki.`+n.project.id+`.selected`,l),[P,F]=(0,v.useState)(!0),[I,L]=(0,v.useState)(``),[R,z]=(0,v.useState)(``),[B,V]=(0,v.useState)(!1),[H,U]=(0,v.useState)(!!a),[W,G]=(0,v.useState)({...te,refs:a?[a]:[]}),[K,ne]=(0,v.useState)(!1),[re,ie]=(0,v.useState)(0),[q,J]=(0,v.useState)(``),[Y,ae]=m(`resources.wiki.`+n.project.id+`.reviewFilter`,`all`);(0,v.useEffect)(()=>{l&&O(l)},[l]),(0,v.useEffect)(()=>{let e=!0;return F(!0),L(``),Promise.all([i(`/`+n.project.id+`/knowledge`),i(`/`+n.project.id+`/datasets`)]).then(([t,n])=>{e&&(g(t.entries),x(n.datasets),O(e=>t.entries.some(t=>t.id===e)?e:(t.entries.find(e=>e.kind===`note`||e.kind===`finding`||e.kind===`demand`)||t.entries[0])?.id||``))}).catch(t=>e&&L(t.message)).finally(()=>e&&F(!1)),()=>{e=!1}},[n.project.id,i,re]);let X=(0,v.useMemo)(()=>{let e=new Map;for(let t of p){let n=e.get(t.pageId);(!n||Number(t.version)>Number(n.version))&&e.set(t.pageId,t)}return[...e.values()]},[p]),oe=X.filter(e=>(w===`all`||e.kind===w)&&(Y===`all`||(Y===`missing`?e.analysisGaps?.length>0:e.analysisRecord?.status===Y))&&`${e.title} ${e.summary} ${e.analysis}`.toLowerCase().includes(S.toLowerCase())),Z=p.find(e=>e.id===E),se=p.filter(e=>e.pageId===Z?.pageId).sort((e,t)=>Number(t.version)-Number(e.version));function ce(){return!K||confirm(`分析文档有未保存修改,放弃这些修改?`)}function le(e){ce()&&(O(e),U(!1),ne(!1),u(!1),L(``))}function ue(e){if(!ce())return;U(!0),ne(!1),u(!1),z(``);let t=e&&p.filter(t=>t.analysisOrigin?.id===e.id&&t.analysisOrigin?.kind===e.kind).sort((e,t)=>t.version-e.version)[0]||e;if(t?.analysisRecord){let e=p.find(e=>e.id===t.analysisOrigin?.id&&e.kind===t.analysisOrigin?.kind);G({title:t.title,summary:t.summary,source:t.source,analysis:``,refs:t.refs||[],pageId:t.pageId,expectedVersion:t.version,reviewRecord:{...t.analysisRecord,changes:``},resultRefs:t.analysisRecord.resultRefs||[],origin:t.analysisOrigin,originHash:e?.originHash||t.originSnapshot?.hash||``})}else G({...te,reviewRecord:{...D(),method:e?.method||``,steps:e?.recordedSteps||``},title:e?.title||``,summary:e?.summary||``,source:e?[e.source,e.period].filter(Boolean).join(` / `):``,refs:e?.refs||(a?[a]:[]),origin:e?{id:e.id,kind:e.kind}:null,originHash:e?.originHash||``})}function de(e,t){G(n=>({...n,[e]:t,...e===`refs`?{resultRefs:n.resultRefs.filter(e=>t.includes(e))}:{}})),ne(!0),u(!0)}async function fe(){V(!0),L(``);try{let e=await i(`/`+n.project.id+`/knowledge`,{...W,pageId:W.pageId||void 0});ne(!1),u(!1),U(!1),O(e.id),ie(e=>e+1),z(`已保存 v${e.version},历史版本继续保留。`)}catch(e){L(e.message)}finally{V(!1)}}let pe=[...b.map(e=>({id:e.id,label:`数据集 · `+e.title})),...n.files.filter(e=>!b.some(t=>t.id===e.id)).map(e=>({id:e.id,label:`附件 · `+e.name})),...n.revisions.map(e=>({id:e.id,label:`阶段版本 · v`+e.version+` · `+n.steps[e.step]?.title}))],Q=pe.filter(e=>W.refs.includes(e.id)||e.label.toLowerCase().includes(q.toLowerCase())).sort((e,t)=>Number(W.refs.includes(t.id))-Number(W.refs.includes(e.id))).slice(0,60);return(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`分析与复盘`,(0,y.jsx)(h,{label:`保存分析`,children:`记录问题、分析方法、依据、结论及复盘结果,并选择来源。数据明细留在数据库;修改会保留历史版本。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`记录问题、方法、证据与结果,按版本复盘项目判断。`})]}),(0,y.jsxs)(`button`,{onClick:()=>ue(),disabled:B,children:[(0,y.jsx)(s,{size:16}),` 新建分析`]})]}),I&&(0,y.jsxs)(`div`,{className:`error`,role:`alert`,children:[I,` `,(0,y.jsx)(`button`,{onClick:()=>ie(e=>e+1),children:`重新读取`})]}),R&&(0,y.jsx)(`div`,{className:`notice`,role:`status`,children:R}),P?(0,y.jsx)(`p`,{role:`status`,children:`正在读取分析记录…`}):(0,y.jsxs)(`div`,{className:`wb-wiki-layout`,children:[(0,y.jsxs)(`section`,{className:`card wb-catalog`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索分析文档`,value:S,onChange:e=>C(e.target.value),placeholder:`搜索标题、结论与分析`})]}),(0,y.jsxs)(`label`,{className:`wb-filter-label`,children:[`记录分类`,(0,y.jsxs)(`select`,{value:w,onChange:e=>T(e.target.value),children:[(0,y.jsxs)(`option`,{value:`all`,children:[`全部记录(`,X.length,`)`]}),Object.entries(j).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))]})]}),(0,y.jsxs)(`label`,{className:`wb-filter-label`,children:[`复盘状态`,(0,y.jsxs)(`select`,{"aria-label":`复盘状态筛选`,value:Y,onChange:e=>ae(e.target.value),children:[(0,y.jsx)(`option`,{value:`all`,children:`全部`}),(0,y.jsx)(`option`,{value:`missing`,children:`过程待补充`}),(0,y.jsx)(`option`,{value:`planned`,children:`待复盘`}),(0,y.jsx)(`option`,{value:`reviewed`,children:`已填写复盘`})]})]}),(0,y.jsxs)(`div`,{className:`wb-dataset-list`,children:[oe.map(e=>(0,y.jsxs)(`button`,{className:Z?.pageId===e.pageId&&!H?`active`:``,onClick:()=>le(e.id),children:[(0,y.jsxs)(`span`,{children:[(0,y.jsx)(o,{size:16}),(0,y.jsx)(`b`,{children:M(e)})]}),(0,y.jsxs)(`small`,{children:[j[e.kind],` · `,e.version?`v`+e.version:`未记录版本`]}),(0,y.jsxs)(`small`,{children:[String(e.created).slice(0,10),e.supersededBy?` · 已被取代`:``,e.stale?` · 待复核`:``]})]},e.id)),!oe.length&&(0,y.jsx)(`p`,{className:`muted`,children:`没有匹配的分析记录。`})]})]}),(0,y.jsx)(`section`,{className:`card wb-wiki-content`,children:H?(0,y.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),fe()},children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsx)(`h2`,{children:W.pageId?`修订分析`:`新建分析文档`}),(0,y.jsx)(`span`,{className:`wb-chip`,children:K?`未保存`:`编辑中`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`结论保存为新版本。原始指标表请上传至数据中心,在这里选择引用。`}),(0,y.jsxs)(`label`,{children:[`文档标题`,(0,y.jsx)(`input`,{required:!0,maxLength:200,value:W.title,onChange:e=>de(`title`,e.target.value),placeholder:`例如:本周转化下降的原因与验证计划`})]}),(0,y.jsxs)(`label`,{children:[`结论与建议`,(0,y.jsx)(`textarea`,{required:!0,rows:4,maxLength:12e3,value:W.summary,onChange:e=>de(`summary`,e.target.value),placeholder:`先写结论、适用范围与下一步行动`})]}),(0,y.jsx)(k,{form:W,change:de,evidenceOptions:pe,busy:B}),(0,y.jsxs)(`label`,{children:[`资料来源与统计时间`,(0,y.jsx)(`input`,{required:!0,maxLength:2e3,value:W.source,onChange:e=>de(`source`,e.target.value),placeholder:`资料来源、分析日期、使用的数据窗口`})]}),(0,y.jsxs)(`label`,{children:[`查找证据`,(0,y.jsx)(`input`,{"aria-label":`查找引用证据`,value:q,onChange:e=>J(e.target.value),placeholder:`搜索数据集、附件或阶段版本`})]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`已选 `,W.refs.length,` 项证据 · 共 `,pe.length,` 项可用 · 最多显示 60 项,已选项优先`]}),(0,y.jsxs)(`fieldset`,{className:`wb-evidence-picker`,children:[(0,y.jsx)(`legend`,{children:`引用本项目证据(关联历史记录时可先存草稿)`}),pe.length?Q.map(e=>(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:W.refs.includes(e.id),onChange:t=>de(`refs`,t.target.checked?[...W.refs,e.id]:W.refs.filter(t=>t!==e.id))}),(0,y.jsx)(`span`,{children:e.label})]},e.id)):(0,y.jsx)(`p`,{children:`暂无可引用证据,请先在阶段工作区保存资料。`})]}),(0,y.jsxs)(`div`,{className:`wb-actions`,children:[(0,y.jsx)(`button`,{type:`submit`,disabled:B||!W.refs.length&&!W.origin,children:B?`保存中…`:`保存新版本`}),(0,y.jsx)(`button`,{type:`button`,className:`secondary`,disabled:B,onClick:()=>{ce()&&(U(!1),ne(!1),u(!1))},children:`取消`})]})]}):Z?(0,y.jsxs)(`article`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`span`,{className:`wb-chip`,children:[(0,y.jsx)(t,{size:14}),j[Z.kind]]}),Z.kind===`demand`&&(0,y.jsx)(`span`,{className:`wb-chip`,children:`需求结果仍在需求拆分中修订`}),Z.kind===`method`?(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>f?.(Z.methodRecordId),children:`在任务与方法中查看 / 追加版本 →`}):(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>ue(se[0]),children:[Z.kind===`analysis`?`修订分析 / 记录复盘`:`补充分析记录 / 复盘`,` `,(0,y.jsx)(e,{size:14})]})]}),(0,y.jsx)(`h2`,{className:`wb-doc-title`,children:M(Z)}),(0,y.jsxs)(`p`,{className:`muted`,children:[Z.created,` · `,Z.version?`v`+Z.version:`历史记录,未提供版本号`]}),Z.stale&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`上游资料已更新,此阶段结论需要复核。`}),Z.supersededBy&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`此结论已被后续结论取代,保留供历史追溯。`}),se.length>1&&(0,y.jsxs)(`label`,{className:`wb-history`,children:[(0,y.jsx)(_,{size:16}),` 历史版本`,(0,y.jsx)(`select`,{"aria-label":`历史版本`,value:E,onChange:e=>le(e.target.value),children:se.map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[`v`,e.version,` · `,String(e.created).slice(0,16)]},e.id))})]}),[[`输入与约束`,Z.context],[`结论与建议`,N(Z)],[`已记录的方法名称`,Z.method],[`已记录的分析过程`,Z.analysisRecord?``:Z.analysis],[`已记录的分析步骤`,Z.recordedSteps],[`验证窗口`,Z.reviewWindow],[`判断与规则`,Z.reason],[`修订与注意事项`,Z.repair],[`预期产出`,Z.outputs]].filter(([,e])=>e).map(([e,t])=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:e}),(0,y.jsx)(`p`,{children:t})]},e)),Z.kind===`action`&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联结论`}),Z.linkedFinding&&p.some(e=>e.id===Z.linkedFinding)?(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>le(Z.linkedFinding),children:`查看关联结论 →`}):(0,y.jsx)(`p`,{className:`muted`,children:`当时未记录可定位的结论关联。`})]}),Z.kind!==`method`&&(0,y.jsx)(A,{current:Z,entries:p,onSelect:le}),p.some(e=>e.analysisOrigin?.id===Z.id)&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联分析与复盘`}),X.filter(e=>e.analysisOrigin?.id===Z.id).map(e=>(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>le(e.id),children:[M(e),` · v`,e.version,` →`]},e.id))]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`来源与范围`}),(0,y.jsxs)(`p`,{children:[Z.kind===`node`?`本项目节点保存记录;这是操作留档,不是外部经营数据来源。`:Z.source||`未记录`,Z.period?`
|
|
1
|
+
import{t as e}from"./arrow-up-right-IBQoN72x.js";import{t}from"./book-open-Cqdn6s-H.js";import{n,t as r}from"./link-2-VLti-YG9.js";import{t as i}from"./chevron-right-e65CaeL6.js";import{t as a}from"./download-DfM49VvV.js";import{t as o}from"./file-text-DKAT5fzJ.js";import{t as s}from"./plus-D78h7lrw.js";import{t as c}from"./search-DFdSppzm.js";import{g as l,o as u,p as d,u as f,y as p}from"./index-DLSVWUSu.js";import{n as m}from"./workspace-view-state-D0ujRczW.js";import{t as h}from"./HelpTip-BqRBO41J.js";import{t as ee}from"./EmptyState-CUHuNsaV.js";var g=d(`file-braces`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1`,key:`1oajmo`}],[`path`,{d:`M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1`,key:`mpwhp6`}]]),_=d(`rotate-ccw-clock`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}],[`path`,{d:`M12 7v5l4 2`,key:`1fdv2h`}]]),v=p(l(),1),y=u(),b={simulated:`模拟数据`,"declared-real":`来源标注为真实(尚需核实)`,unverified:`真实性待核`},x=(e,t)=>e==null?`—`:typeof e!=`number`||!Number.isFinite(e)?S(e):t.type===`percent`?(e*100).toLocaleString(`zh-CN`,{maximumFractionDigits:2})+`%`:t.type===`text`?String(e):e.toLocaleString(`zh-CN`,{maximumFractionDigits:[`元`,`CNY`].includes(t.unit)?2:6}),S=e=>e==null?`—`:typeof e==`object`?JSON.stringify(e):String(e);function C({data:e,api:t,initialId:r=``,onWiki:o,onPrepare:s,onArchive:l,onSelect:u}){let[d,p]=(0,v.useState)([]),[_,C]=(0,v.useState)(0),[w,T]=(0,v.useState)(r),[E,D]=(0,v.useState)(null),[O,k]=m(`resources.data.`+e.project.id+`.query`,``),[A,j]=m(`resources.data.`+e.project.id+`.`+r+`.page`,1),[M,N]=(0,v.useState)(``),[te,P]=(0,v.useState)(!0),[F,I]=(0,v.useState)(0),[L,R]=(0,v.useState)(!1);(0,v.useEffect)(()=>{let n=!0;return P(!0),N(``),t(`/`+e.project.id+`/datasets`).then(e=>{n&&(p(e.datasets),C(e.pendingImports),T(t=>e.datasets.some(e=>e.id===t)?t:r?``:e.datasets[0]?.id||``),r&&!e.datasets.some(e=>e.id===r)&&N(`指定的数据集不可访问或已变更,请在目录中重新选择。`))}).catch(e=>n&&N(e.message)).finally(()=>n&&P(!1)),()=>{n=!1}},[e.project.id,t,F]),(0,v.useEffect)(()=>{if(!w)return;let n=!0;return D(null),N(``),t(`/`+e.project.id+`/datasets/`+encodeURIComponent(w)+`?page=`+A).then(e=>n&&D(e)).catch(e=>n&&N(e.message)),()=>{n=!1}},[w,A,e.project.id,t,F]);let z=(0,v.useMemo)(()=>d.filter(e=>`${e.title} ${e.source} ${e.period}`.toLowerCase().includes(O.toLowerCase())),[d,O]);function B(e){j(1),T(e),u?.(e)}return(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`数据中心`,(0,y.jsx)(h,{label:`查看经营数据`,children:`先按资料名称、来源或统计时间查找,再查看明细。空值表示缺失,不等于零;原始经营数据保存在数据库。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`查询数据集、统计窗口与来源。缺失值显示为「—」,真实零保留为 0。`})]}),(0,y.jsxs)(`span`,{className:`wb-chip`,children:[(0,y.jsx)(f,{size:14}),` 专用数据库 · `,d.length,` 个数据集`]})]}),M&&(0,y.jsxs)(`div`,{role:`alert`,className:`error`,children:[M,` `,(0,y.jsx)(`button`,{onClick:()=>I(e=>e+1),children:`重新读取`})]}),_>0&&(0,y.jsxs)(`div`,{className:`wb-callout`,children:[`有 `,_,` 份 JSON 附件尚未进入数据中心。原件仍在「证据与附件」中,可由维护人员核验后迁移。`]}),te?(0,y.jsx)(`p`,{role:`status`,children:`正在读取数据库目录…`}):d.length?(0,y.jsxs)(`div`,{className:`wb-data-layout`,children:[(0,y.jsxs)(`section`,{className:`card wb-catalog`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索数据集`,placeholder:`搜索资料名称、来源、统计时间`,value:O,onChange:e=>k(e.target.value)})]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`找到 `,z.length,` 个数据集`]}),(0,y.jsxs)(`div`,{className:`wb-dataset-list`,children:[z.map(e=>(0,y.jsxs)(`button`,{className:w===e.id?`active`:``,onClick:()=>B(e.id),children:[(0,y.jsxs)(`span`,{children:[(0,y.jsx)(g,{size:16}),(0,y.jsx)(`b`,{children:e.title})]}),(0,y.jsxs)(`small`,{children:[e.rowCount,` 行 · `,b[e.mode]]}),(0,y.jsx)(`small`,{children:e.period||String(e.created).slice(0,10)})]},e.id)),!z.length&&(0,y.jsx)(`p`,{className:`muted`,children:`没有匹配的数据集。`})]})]}),(0,y.jsx)(`section`,{className:`card wb-data-detail`,"aria-live":`polite`,children:E?(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`span`,{className:`wb-chip `+(E.mode===`simulated`?`warning`:``),children:b[E.mode]}),(0,y.jsx)(`h2`,{children:E.title})]}),(0,y.jsxs)(`a`,{className:`wb-link-button`,href:`/api/workbench/`+e.project.id+`/file/`+E.artifactId,children:[(0,y.jsx)(a,{size:15}),` 原始文件`]})]}),(0,y.jsxs)(`dl`,{className:`wb-metadata`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`统计窗口`}),(0,y.jsx)(`dd`,{children:E.period||`未提供`})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`归档时间`}),(0,y.jsx)(`dd`,{children:E.created})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`数据来源`}),(0,y.jsx)(`dd`,{children:E.source||`未提供`})]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`dt`,{children:`数据状态`}),(0,y.jsxs)(`dd`,{children:[E.rowCount,` 行 · 原始记录保留 · `,b[E.mode]]})]})]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`原始记录的口径、备注与假设`}),(0,y.jsx)(`p`,{children:E.note==null?`原数据集未单独提供备注。请结合来源和原件核对。`:typeof E.note==`string`?E.note:JSON.stringify(E.note,null,2)})]}),(0,y.jsxs)(`label`,{className:`wb-raw-toggle`,children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:L,onChange:e=>R(e.target.checked)}),` 显示原始值`,(0,y.jsx)(`span`,{children:`金额按单位显示,百分比按列定义换算;原值保留不变。`})]}),(0,y.jsx)(`div`,{className:`wb-table-wrap`,tabIndex:0,"aria-label":`数据表,可横向滚动`,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`col`,children:`行号`}),E.columns.map(e=>(0,y.jsxs)(`th`,{scope:`col`,children:[e.label||e.key,e.unit?`(`+e.unit+`)`:``]},e.key))]})}),(0,y.jsx)(`tbody`,{children:E.rows.map(e=>(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`row`,children:e.index+1}),E.columns.map(t=>(0,y.jsx)(`td`,{title:S(e.values[t.key]),children:L?S(e.values[t.key]):x(e.values[t.key],t)},t.key))]},e.index))})]})}),(0,y.jsxs)(`div`,{className:`wb-pagination`,children:[(0,y.jsxs)(`span`,{children:[`共 `,E.rowCount,` 行 · 第 `,A,` / `,Math.max(1,Math.ceil(E.rowCount/50)),` 页`]}),(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`button`,{"aria-label":`上一页`,disabled:A===1,onClick:()=>j(e=>e-1),children:(0,y.jsx)(n,{size:16})}),(0,y.jsx)(`button`,{"aria-label":`下一页`,disabled:A*50>=E.rowCount,onClick:()=>j(e=>e+1),children:(0,y.jsx)(i,{size:16})})]})]}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`查看记录标识与完整性校验`}),(0,y.jsxs)(`p`,{children:[`数据集 ID:`,E.id]}),(0,y.jsxs)(`p`,{children:[`来源 SHA256:`,E.sha]}),(0,y.jsxs)(`p`,{children:[`数据格式:`,E.format]})]}),(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>o(E.id),children:`用这份数据记录分析结论 →`}),l&&(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>l(E.id),children:`用这份数据进入分析任务 →`})]}):(0,y.jsx)(`p`,{role:`status`,children:M?`数据读取失败,请重试。`:`正在读取数据行…`})})]}):(0,y.jsx)(`section`,{className:`card`,children:(0,y.jsxs)(ee,{title:`还没有入库数据`,children:[`先准备本项目原始文件,注明店铺/商品、统计日期、指标含义和来源。普通表格需整理成该模块认可的资料格式后才能入库;上传附件不等于已完成数据导入。系统不会创建示例经营数据。`,s&&(0,y.jsx)(`p`,{children:(0,y.jsx)(`button`,{onClick:s,children:`查看或准备项目原件`})})]})})]})}var w={keyword:`关键词证据`,review:`评价证据`,product:`商品资料`,analysis:`分析导入`,artifact:`制作产物`};function T({data:e,api:t,onSaved:n,onDirty:r,onBusy:i}){let[o,s]=m(`resources.files.`+e.project.id+`.query`,``),[l,u]=m(`resources.files.`+e.project.id+`.kind`,`all`),[d,f]=(0,v.useState)(!1),[p,g]=(0,v.useState)(null),[_,b]=(0,v.useState)(``),[x,S]=(0,v.useState)(`keyword`),[C,T]=(0,v.useState)(!1),[E,D]=(0,v.useState)(``),O=(0,v.useRef)(null);(0,v.useEffect)(()=>{r?.(!!p||!!_.trim())},[p,_,r]),(0,v.useEffect)(()=>(i?.(C),()=>i?.(!1)),[C,i]);async function k(){if(!(!p||C)){T(!0),D(``);try{if(p.size>2e6)throw Error(`单文件上限2MB`);let r=new Uint8Array(await p.arrayBuffer()),i=``;for(let e of r)i+=String.fromCharCode(e);await t(`/`+e.project.id+`/file`,{name:p.name,source:_,kind:x,base64:btoa(i)}),g(null),b(``),O.current&&(O.current.value=``),await n(),D(`原文件已归档。数据入库与内容核验仍需在相应模块完成。`)}catch(e){D(e.message)}finally{T(!1)}}}let A=e.files.filter(e=>(l===`all`||e.kind===l)&&`${e.name} ${e.source}`.toLowerCase().includes(o.toLowerCase()));return(0,y.jsxs)(`section`,{className:`card`,children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`证据与附件`,(0,y.jsx)(h,{label:`上传与引用资料`,children:`这里保留原文件。上传时说明来源和采集日期;文件存在不代表内容真实,分析前仍需核对。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`保留原文件、来源和完整性校验信息,便于核对分析依据。`})]}),(0,y.jsx)(`button`,{onClick:()=>f(!d),children:d?`收起上传`:`上传原始资料`})]}),d&&(0,y.jsxs)(`form`,{className:`wb-upload-form`,onSubmit:e=>{e.preventDefault(),k()},children:[(0,y.jsxs)(`label`,{children:[`资料类型`,(0,y.jsx)(`select`,{disabled:C,value:x,onChange:e=>S(e.target.value),children:Object.entries(w).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[`来源与采集日期`,(0,y.jsx)(`input`,{disabled:C,required:!0,value:_,onChange:e=>b(e.target.value),placeholder:`说明来源、日期和是否为模拟资料`})]}),(0,y.jsxs)(`label`,{children:[`原始文件(≤2MB)`,(0,y.jsx)(`input`,{ref:O,disabled:C,type:`file`,onChange:e=>g(e.target.files?.[0]||null)})]}),(0,y.jsx)(`p`,{className:`muted`,children:`保存原件与来源,不自动导入数据或生成分析结论。`}),(0,y.jsx)(`button`,{disabled:C||!p||!_.trim(),children:C?`正在上传…`:`上传并归档`})]}),E&&(0,y.jsx)(`p`,{role:`status`,children:E}),(0,y.jsxs)(`div`,{className:`wb-toolbar`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索附件`,placeholder:`搜索文件名称或来源`,value:o,onChange:e=>s(e.target.value)})]}),(0,y.jsxs)(`select`,{"aria-label":`附件类型`,value:l,onChange:e=>u(e.target.value),children:[(0,y.jsx)(`option`,{value:`all`,children:`全部类型`}),Object.entries(w).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))]})]}),A.length?(0,y.jsx)(`div`,{className:`wb-table-wrap`,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{children:`文件名称`}),(0,y.jsx)(`th`,{children:`类型`}),(0,y.jsx)(`th`,{children:`来源`}),(0,y.jsx)(`th`,{children:`归档时间`}),(0,y.jsx)(`th`,{children:`文件大小`}),(0,y.jsx)(`th`,{children:`操作`})]})}),(0,y.jsx)(`tbody`,{children:A.map(t=>(0,y.jsxs)(`tr`,{children:[(0,y.jsxs)(`td`,{children:[(0,y.jsx)(`b`,{children:t.name}),(0,y.jsxs)(`details`,{children:[(0,y.jsx)(`summary`,{children:`查看文件标识与完整性信息`}),(0,y.jsxs)(`p`,{className:`wb-hash`,children:[`ID:`,t.id,(0,y.jsx)(`br`,{}),`SHA256:`,t.sha]})]})]}),(0,y.jsx)(`td`,{children:w[t.kind]||t.kind}),(0,y.jsx)(`td`,{children:t.source}),(0,y.jsx)(`td`,{children:String(t.created).slice(0,10)}),(0,y.jsxs)(`td`,{children:[(t.bytes/1024).toFixed(1),` KB`]}),(0,y.jsx)(`td`,{children:(0,y.jsx)(`a`,{"aria-label":`下载 `+t.name,href:`/api/workbench/`+e.project.id+`/file/`+t.id,children:(0,y.jsx)(a,{size:16})})})]},t.id))})]})}):(0,y.jsx)(ee,{title:`没有匹配的附件`,children:`可先准备表格、文本或图片,注明来源与日期。单文件不超过2MB;点击上方按钮直接上传。原件归档后仍需对应模块整理与核验,不会自动变成分析结果。`})]})}var E=[[`question`,`分析问题`,`这次要回答什么问题,影响哪个决策?`],[`method`,`方法与选择理由`,`使用什么方法,为什么适合这个问题?`],[`metricDefinitions`,`指标口径`,`时间窗口、样本范围、分母、单位与对比基准`],[`steps`,`数据处理与分析步骤`,`按顺序记录筛选、清洗、比较、计算和检查;原始表保留在数据中心`],[`rationale`,`关键判断依据`,`哪些观测支持结论?按所选数据集、行 ID 或附件位置标出每个判断的证据。`],[`counterEvidence`,`反证与替代解释`,`哪些证据不支持当前判断?考虑过哪些其他解释?`],[`assumptions`,`假设与待验证项`,`哪些前提尚未验证?区分事实、推断和假设`],[`limitations`,`适用边界与限制`,`样本偏差、缺失数据、不可外推的对象和周期`],[`action`,`行动与负责人`,`准备做什么、由谁负责;记录计划不代表已经执行`],[`expected`,`预期指标与验收标准`,`指标、基线、目标、观察窗口和停止条件`],[`actual`,`实际结果摘要`,`复盘时填写实测结果摘要,并选择对应结果数据;没有实测则留空`],[`learning`,`复盘判断与方法调整`,`预期和实际差异、原假设是否成立、下一次如何调整方法`],[`changes`,`本版变更说明`,`本次补充、纠正或调整了什么,为什么`]],D=()=>({...Object.fromEntries(E.map(([e])=>[e,``])),status:`draft`,reviewOn:``}),O={draft:`草稿 · 待补充`,planned:`已记录计划 · 待复盘`,reviewed:`已填写复盘`};function k({form:e,change:t,evidenceOptions:n,busy:r}){let i=e.reviewRecord,a=(e,n)=>t(`reviewRecord`,{...i,[e]:n});return(0,y.jsxs)(`fieldset`,{className:`wb-analysis-fields`,disabled:r,children:[(0,y.jsxs)(`legend`,{children:[`分析方法与复盘记录`,(0,y.jsx)(h,{label:`怎样复盘`,children:`写清问题、用到的资料、判断依据、反例和实际结果。完成复盘需选择结果证据;没有执行的计划不能当作结果。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`记录可核查的方法、依据和结果。未知内容留空,按草稿保存;不要补造历史过程或把未经验证的计划记为执行结果。`}),(0,y.jsxs)(`div`,{className:`two`,children:[(0,y.jsxs)(`label`,{children:[`记录状态`,(0,y.jsx)(`select`,{value:i.status,onChange:e=>a(`status`,e.target.value),children:Object.entries(O).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[`计划复盘日期`,(0,y.jsx)(`input`,{type:`date`,value:i.reviewOn,onChange:e=>a(`reviewOn`,e.target.value)})]})]}),E.map(([e,t,n])=>(0,y.jsxs)(`label`,{children:[t,(0,y.jsx)(`textarea`,{rows:e===`steps`?4:3,maxLength:1e4,value:i[e]||``,placeholder:n,onChange:t=>a(e,t.target.value)})]},e)),(0,y.jsxs)(`fieldset`,{className:`wb-evidence-picker`,children:[(0,y.jsx)(`legend`,{children:`实际结果证据(完成复盘时必选)`}),e.refs.length?e.refs.map(r=>(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:e.resultRefs.includes(r),onChange:n=>t(`resultRefs`,n.target.checked?[...e.resultRefs,r]:e.resultRefs.filter(e=>e!==r))}),n.find(e=>e.id===r)?.label||r]},r)):(0,y.jsx)(`p`,{className:`muted`,children:`请先在下方选择本项目证据,再标记哪些是实际复盘结果。`})]})]})}function A({current:e,entries:t,onSelect:n}){let r=e.analysisRecord,i=e.analysisOrigin&&t.find(t=>t.id===e.analysisOrigin.id&&t.kind===e.analysisOrigin.kind);if(!r)return(0,y.jsxs)(`div`,{className:`wb-callout`,children:[(0,y.jsx)(`b`,{children:`尚未建立完整分析复盘记录`}),(0,y.jsx)(`p`,{children:`此记录保留了当时填写的内容。已有内容在上方展示;空缺项表示“当时未记录”。未记录的步骤、口径、假设、反证和复盘结果无法还原;可创建关联分析,逐项补充有依据的说明。`})]});let a=t.find(t=>t.id===e.parentRevisionId),o=a?.analysisRecord?E.filter(([e])=>r[e]!==a.analysisRecord[e]).map(([,e])=>e):[];return(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`div`,{className:`wb-analysis-status`,children:[(0,y.jsx)(`span`,{className:`wb-chip`,children:O[r.status]}),(0,y.jsxs)(`span`,{children:[`计划复盘:`,r.reviewOn||`未安排`]}),r.reviewedAt&&(0,y.jsxs)(`span`,{children:[`记录复盘结果:`,r.reviewedAt.slice(0,10)]})]}),e.analysisGaps?.length>0&&(0,y.jsxs)(`div`,{className:`wb-callout`,children:[`尚未记录:`,e.analysisGaps.join(`、`),`。缺项保持为空,不能视为已验证。`]}),e.analysisOrigin&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联原记录`}),i?(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>n(i.id),children:[i.title,` →`]}):(0,y.jsx)(`p`,{children:`原记录已不可读取,保留归档时的快照。`}),(0,y.jsxs)(`p`,{className:`muted`,children:[e.originSnapshot?.created,` · `,e.originSnapshot?.version?`v`+e.originSnapshot.version:`原记录未提供版本号`]}),e.originChanged&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`原记录已变化或无法读取。此分析使用归档时快照,请在修订时重新核对。`}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`查看原记录归档快照`}),(0,y.jsx)(`p`,{children:e.originSnapshot?.summary}),(0,y.jsxs)(`p`,{children:[`原分析文字:`,e.originSnapshot?.analysis||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原方法名称:`,e.originSnapshot?.method||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原步骤:`,e.originSnapshot?.recordedSteps||`未记录`]}),(0,y.jsxs)(`p`,{children:[`原预期:`,e.originSnapshot?.outputs||`未记录`]}),(0,y.jsxs)(`p`,{children:[`快照 SHA256:`,e.originSnapshot?.hash]})]})]}),E.filter(([e])=>r[e]).map(([e,t])=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:t}),(0,y.jsx)(`p`,{children:r[e]})]},e)),a&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`版本变更`}),(0,y.jsxs)(`p`,{children:[`相对 v`,a.version,`:`,o.length?o.join(`、`):`分析字段未变;请同时核对结论、来源与状态`,`。`]}),(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>n(a.id),children:`查看上一版本 →`})]}),!!e.sourceSnapshots?.length&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`使用的输入与来源版本`}),(0,y.jsx)(`p`,{className:`muted`,children:`保存时固定来源标识与版本信息。原始指标和完整数据仍在数据库及附件中。`}),e.sourceSnapshots.map(e=>(0,y.jsxs)(`div`,{className:`wb-reference`,children:[(0,y.jsx)(`b`,{children:e.title||`阶段版本`}),r.resultRefs?.includes(e.id)&&(0,y.jsx)(`span`,{className:`wb-chip`,children:`实际结果证据`}),(0,y.jsxs)(`p`,{children:[e.period||`未提供统计窗口`,` · `,e.version?`v`+e.version:e.created]}),(0,y.jsx)(`p`,{children:e.source||`来源描述未记录`}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`来源标识与文件完整性信息`}),(0,y.jsx)(`p`,{children:e.id}),(0,y.jsxs)(`p`,{children:[`SHA256:`,e.sha||`未提供`]})]})]},e.id))]})]})}var j={method:`任务与方法`,analysis:`分析与复盘`,action:`行动与验证`,node:`流程分析与确认`,demand:`需求分析`,note:`分析文档`,finding:`结论记录`,step:`阶段记录`,playbook:`方法论`};function M(e){let t=String(e.title||`未命名记录`);return e.kind===`node`?t.replace(/\s*·\s*[a-z0-9-]+-[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,``):t}function N(e){return e.kind===`node`&&String(e.summary||``).startsWith(`由工作台提交运行 · `)?`本节点资料已提交并留档。请查看输入、证据和待复核事项;提交记录不代表已完成人工确认或真实经营执行。`:e.summary}var te={title:``,summary:``,analysis:``,source:``,refs:[],pageId:``,expectedVersion:0,reviewRecord:D(),resultRefs:[],origin:null,originHash:``};function P({data:n,api:i,initialRef:a=``,initialEntry:l=``,onDirty:u,onData:d,onMethods:f}){let[p,g]=(0,v.useState)([]),[b,x]=(0,v.useState)([]),[S,C]=m(`resources.wiki.`+n.project.id+`.query`,``),[w,T]=m(`resources.wiki.`+n.project.id+`.kind`,`all`),[E,O]=m(`resources.wiki.`+n.project.id+`.selected`,l),[P,F]=(0,v.useState)(!0),[I,L]=(0,v.useState)(``),[R,z]=(0,v.useState)(``),[B,V]=(0,v.useState)(!1),[H,U]=(0,v.useState)(!!a),[W,G]=(0,v.useState)({...te,refs:a?[a]:[]}),[K,ne]=(0,v.useState)(!1),[re,ie]=(0,v.useState)(0),[q,J]=(0,v.useState)(``),[Y,ae]=m(`resources.wiki.`+n.project.id+`.reviewFilter`,`all`);(0,v.useEffect)(()=>{l&&O(l)},[l]),(0,v.useEffect)(()=>{let e=!0;return F(!0),L(``),Promise.all([i(`/`+n.project.id+`/knowledge`),i(`/`+n.project.id+`/datasets`)]).then(([t,n])=>{e&&(g(t.entries),x(n.datasets),O(e=>t.entries.some(t=>t.id===e)?e:(t.entries.find(e=>e.kind===`note`||e.kind===`finding`||e.kind===`demand`)||t.entries[0])?.id||``))}).catch(t=>e&&L(t.message)).finally(()=>e&&F(!1)),()=>{e=!1}},[n.project.id,i,re]);let X=(0,v.useMemo)(()=>{let e=new Map;for(let t of p){let n=e.get(t.pageId);(!n||Number(t.version)>Number(n.version))&&e.set(t.pageId,t)}return[...e.values()]},[p]),oe=X.filter(e=>(w===`all`||e.kind===w)&&(Y===`all`||(Y===`missing`?e.analysisGaps?.length>0:e.analysisRecord?.status===Y))&&`${e.title} ${e.summary} ${e.analysis}`.toLowerCase().includes(S.toLowerCase())),Z=p.find(e=>e.id===E),se=p.filter(e=>e.pageId===Z?.pageId).sort((e,t)=>Number(t.version)-Number(e.version));function ce(){return!K||confirm(`分析文档有未保存修改,放弃这些修改?`)}function le(e){ce()&&(O(e),U(!1),ne(!1),u(!1),L(``))}function ue(e){if(!ce())return;U(!0),ne(!1),u(!1),z(``);let t=e&&p.filter(t=>t.analysisOrigin?.id===e.id&&t.analysisOrigin?.kind===e.kind).sort((e,t)=>t.version-e.version)[0]||e;if(t?.analysisRecord){let e=p.find(e=>e.id===t.analysisOrigin?.id&&e.kind===t.analysisOrigin?.kind);G({title:t.title,summary:t.summary,source:t.source,analysis:``,refs:t.refs||[],pageId:t.pageId,expectedVersion:t.version,reviewRecord:{...t.analysisRecord,changes:``},resultRefs:t.analysisRecord.resultRefs||[],origin:t.analysisOrigin,originHash:e?.originHash||t.originSnapshot?.hash||``})}else G({...te,reviewRecord:{...D(),method:e?.method||``,steps:e?.recordedSteps||``},title:e?.title||``,summary:e?.summary||``,source:e?[e.source,e.period].filter(Boolean).join(` / `):``,refs:e?.refs||(a?[a]:[]),origin:e?{id:e.id,kind:e.kind}:null,originHash:e?.originHash||``})}function de(e,t){G(n=>({...n,[e]:t,...e===`refs`?{resultRefs:n.resultRefs.filter(e=>t.includes(e))}:{}})),ne(!0),u(!0)}async function fe(){V(!0),L(``);try{let e=await i(`/`+n.project.id+`/knowledge`,{...W,pageId:W.pageId||void 0});ne(!1),u(!1),U(!1),O(e.id),ie(e=>e+1),z(`已保存 v${e.version},历史版本继续保留。`)}catch(e){L(e.message)}finally{V(!1)}}let pe=[...b.map(e=>({id:e.id,label:`数据集 · `+e.title})),...n.files.filter(e=>!b.some(t=>t.id===e.id)).map(e=>({id:e.id,label:`附件 · `+e.name})),...n.revisions.map(e=>({id:e.id,label:`阶段版本 · v`+e.version+` · `+n.steps[e.step]?.title}))],Q=pe.filter(e=>W.refs.includes(e.id)||e.label.toLowerCase().includes(q.toLowerCase())).sort((e,t)=>Number(W.refs.includes(t.id))-Number(W.refs.includes(e.id))).slice(0,60);return(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`分析与复盘`,(0,y.jsx)(h,{label:`保存分析`,children:`记录问题、分析方法、依据、结论及复盘结果,并选择来源。数据明细留在数据库;修改会保留历史版本。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`记录问题、方法、证据与结果,按版本复盘项目判断。`})]}),(0,y.jsxs)(`button`,{onClick:()=>ue(),disabled:B,children:[(0,y.jsx)(s,{size:16}),` 新建分析`]})]}),I&&(0,y.jsxs)(`div`,{className:`error`,role:`alert`,children:[I,` `,(0,y.jsx)(`button`,{onClick:()=>ie(e=>e+1),children:`重新读取`})]}),R&&(0,y.jsx)(`div`,{className:`notice`,role:`status`,children:R}),P?(0,y.jsx)(`p`,{role:`status`,children:`正在读取分析记录…`}):(0,y.jsxs)(`div`,{className:`wb-wiki-layout`,children:[(0,y.jsxs)(`section`,{className:`card wb-catalog`,children:[(0,y.jsxs)(`label`,{className:`wb-search`,children:[(0,y.jsx)(c,{size:16}),(0,y.jsx)(`input`,{"aria-label":`搜索分析文档`,value:S,onChange:e=>C(e.target.value),placeholder:`搜索标题、结论与分析`})]}),(0,y.jsxs)(`label`,{className:`wb-filter-label`,children:[`记录分类`,(0,y.jsxs)(`select`,{value:w,onChange:e=>T(e.target.value),children:[(0,y.jsxs)(`option`,{value:`all`,children:[`全部记录(`,X.length,`)`]}),Object.entries(j).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))]})]}),(0,y.jsxs)(`label`,{className:`wb-filter-label`,children:[`复盘状态`,(0,y.jsxs)(`select`,{"aria-label":`复盘状态筛选`,value:Y,onChange:e=>ae(e.target.value),children:[(0,y.jsx)(`option`,{value:`all`,children:`全部`}),(0,y.jsx)(`option`,{value:`missing`,children:`过程待补充`}),(0,y.jsx)(`option`,{value:`planned`,children:`待复盘`}),(0,y.jsx)(`option`,{value:`reviewed`,children:`已填写复盘`})]})]}),(0,y.jsxs)(`div`,{className:`wb-dataset-list`,children:[oe.map(e=>(0,y.jsxs)(`button`,{className:Z?.pageId===e.pageId&&!H?`active`:``,onClick:()=>le(e.id),children:[(0,y.jsxs)(`span`,{children:[(0,y.jsx)(o,{size:16}),(0,y.jsx)(`b`,{children:M(e)})]}),(0,y.jsxs)(`small`,{children:[j[e.kind],` · `,e.version?`v`+e.version:`未记录版本`]}),(0,y.jsxs)(`small`,{children:[String(e.created).slice(0,10),e.supersededBy?` · 已被取代`:``,e.stale?` · 待复核`:``]})]},e.id)),!oe.length&&(0,y.jsx)(`p`,{className:`muted`,children:`没有匹配的分析记录。`})]})]}),(0,y.jsx)(`section`,{className:`card wb-wiki-content`,children:H?(0,y.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),fe()},children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsx)(`h2`,{children:W.pageId?`修订分析`:`新建分析文档`}),(0,y.jsx)(`span`,{className:`wb-chip`,children:K?`未保存`:`编辑中`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`结论保存为新版本。原始指标表请上传至数据中心,在这里选择引用。`}),(0,y.jsxs)(`label`,{children:[`文档标题`,(0,y.jsx)(`input`,{required:!0,maxLength:200,value:W.title,onChange:e=>de(`title`,e.target.value),placeholder:`例如:本周转化下降的原因与验证计划`})]}),(0,y.jsxs)(`label`,{children:[`结论与建议`,(0,y.jsx)(`textarea`,{required:!0,rows:4,maxLength:12e3,value:W.summary,onChange:e=>de(`summary`,e.target.value),placeholder:`先写结论、适用范围与下一步行动`})]}),(0,y.jsx)(k,{form:W,change:de,evidenceOptions:pe,busy:B}),(0,y.jsxs)(`label`,{children:[`资料来源与统计时间`,(0,y.jsx)(`input`,{required:!0,maxLength:2e3,value:W.source,onChange:e=>de(`source`,e.target.value),placeholder:`资料来源、分析日期、使用的数据窗口`})]}),(0,y.jsxs)(`label`,{children:[`查找证据`,(0,y.jsx)(`input`,{"aria-label":`查找引用证据`,value:q,onChange:e=>J(e.target.value),placeholder:`搜索数据集、附件或阶段版本`})]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`已选 `,W.refs.length,` 项证据 · 共 `,pe.length,` 项可用 · 最多显示 60 项,已选项优先`]}),(0,y.jsxs)(`fieldset`,{className:`wb-evidence-picker`,children:[(0,y.jsx)(`legend`,{children:`引用本项目证据(关联历史记录时可先存草稿)`}),pe.length?Q.map(e=>(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:W.refs.includes(e.id),onChange:t=>de(`refs`,t.target.checked?[...W.refs,e.id]:W.refs.filter(t=>t!==e.id))}),(0,y.jsx)(`span`,{children:e.label})]},e.id)):(0,y.jsx)(`p`,{children:`暂无可引用证据,请先在阶段工作区保存资料。`})]}),(0,y.jsxs)(`div`,{className:`wb-actions`,children:[(0,y.jsx)(`button`,{type:`submit`,disabled:B||!W.refs.length&&!W.origin,children:B?`保存中…`:`保存新版本`}),(0,y.jsx)(`button`,{type:`button`,className:`secondary`,disabled:B,onClick:()=>{ce()&&(U(!1),ne(!1),u(!1))},children:`取消`})]})]}):Z?(0,y.jsxs)(`article`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`span`,{className:`wb-chip`,children:[(0,y.jsx)(t,{size:14}),j[Z.kind]]}),Z.kind===`demand`&&(0,y.jsx)(`span`,{className:`wb-chip`,children:`需求结果仍在需求拆分中修订`}),Z.kind===`method`?(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>f?.(Z.methodRecordId),children:`在任务与方法中查看 / 追加版本 →`}):(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>ue(se[0]),children:[Z.kind===`analysis`?`修订分析 / 记录复盘`:`补充分析记录 / 复盘`,` `,(0,y.jsx)(e,{size:14})]})]}),(0,y.jsx)(`h2`,{className:`wb-doc-title`,children:M(Z)}),(0,y.jsxs)(`p`,{className:`muted`,children:[Z.created,` · `,Z.version?`v`+Z.version:`历史记录,未提供版本号`]}),Z.stale&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`上游资料已更新,此阶段结论需要复核。`}),Z.supersededBy&&(0,y.jsx)(`div`,{className:`wb-callout`,children:`此结论已被后续结论取代,保留供历史追溯。`}),se.length>1&&(0,y.jsxs)(`label`,{className:`wb-history`,children:[(0,y.jsx)(_,{size:16}),` 历史版本`,(0,y.jsx)(`select`,{"aria-label":`历史版本`,value:E,onChange:e=>le(e.target.value),children:se.map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[`v`,e.version,` · `,String(e.created).slice(0,16)]},e.id))})]}),[[`输入与约束`,Z.context],[`结论与建议`,N(Z)],[`已记录的方法名称`,Z.method],[`已记录的分析过程`,Z.analysisRecord?``:Z.analysis],[`已记录的分析步骤`,Z.recordedSteps],[`验证窗口`,Z.reviewWindow],[`判断与规则`,Z.reason],[`修订与注意事项`,Z.repair],[`预期产出`,Z.outputs]].filter(([,e])=>e).map(([e,t])=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:e}),(0,y.jsx)(`p`,{children:t})]},e)),Z.kind===`action`&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联结论`}),Z.linkedFinding&&p.some(e=>e.id===Z.linkedFinding)?(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>le(Z.linkedFinding),children:`查看关联结论 →`}):(0,y.jsx)(`p`,{className:`muted`,children:`当时未记录可定位的结论关联。`})]}),Z.kind!==`method`&&(0,y.jsx)(A,{current:Z,entries:p,onSelect:le}),p.some(e=>e.analysisOrigin?.id===Z.id)&&(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`关联分析与复盘`}),X.filter(e=>e.analysisOrigin?.id===Z.id).map(e=>(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>le(e.id),children:[M(e),` · v`,e.version,` →`]},e.id))]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:`来源与范围`}),(0,y.jsxs)(`p`,{children:[Z.kind===`node`?`本项目节点保存记录;这是操作留档,不是外部经营数据来源。`:Z.source||`未记录`,Z.period?`
|
|
2
2
|
统计窗口:`+Z.period:``]})]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsxs)(`h3`,{children:[(0,y.jsx)(r,{size:16}),` 证据引用`]}),Z.refs?.length?Z.refs.map(e=>{let t=b.find(t=>t.id===e),r=n.files.find(t=>t.id===e),i=p.find(t=>t.id===e);return(0,y.jsx)(`div`,{className:`wb-reference`,children:t?(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>d(e),children:[`数据集 · `,t.title,` →`]}):r?(0,y.jsxs)(`a`,{href:`/api/workbench/`+n.project.id+`/file/`+e,children:[`附件 · `,r.name]}):i?(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>le(e),children:[`阶段版本 · v`,i.version,` `,M(i)]}):(0,y.jsxs)(`span`,{children:[`引用待核:`,e]})},e)}):(0,y.jsx)(`p`,{className:`muted`,children:`此历史记录未提供可定位的引用;请结合下方来源描述复核。`}),Z.evidence?.length>0&&(0,y.jsx)(`div`,{className:`wb-table-wrap`,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{children:`指标摘要`}),(0,y.jsx)(`th`,{children:`引用值`}),(0,y.jsx)(`th`,{children:`对比基准`}),(0,y.jsx)(`th`,{children:`来源描述`})]})}),(0,y.jsx)(`tbody`,{children:Z.evidence.map((e,t)=>(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`td`,{children:e.metric}),(0,y.jsxs)(`td`,{children:[e.value??`—`,e.unit]}),(0,y.jsx)(`td`,{children:e.benchmark||`—`}),(0,y.jsx)(`td`,{children:e.source||`未提供`})]},t))})]})})]}),(0,y.jsxs)(`details`,{children:[(0,y.jsx)(`summary`,{children:`高级:原始标题、记录标识与来源`}),(0,y.jsxs)(`p`,{className:`wb-record-id`,children:[`原始标题:`,Z.title,(0,y.jsx)(`br`,{}),`原始摘要:`,Z.summary||`未记录`,(0,y.jsx)(`br`,{}),`来源:`,Z.source||`未记录`,(0,y.jsx)(`br`,{}),`记录 ID:`,Z.id]})]})]}):(0,y.jsx)(ee,{title:`还没有分析文档`,children:`从数据中心选择证据,记录分析方法、判断依据和复盘计划。`})})]})]})}var F={brief:`任务定义`,hypothesis:`候选解释`,feedback:`错误与反馈`,rule:`候选规则`,case:`验证案例`,evaluation:`验证登记`},I={brief:[[`object`,`对象`,`商品、对象或流程;未知可留空`],[`goal`,`目标`,`要完成什么;清晰任务无需重复澄清`],[`conflict`,`现象或冲突`,`实际与期望哪里不同`],[`constraints`,`约束`,`时间、预算、不能改变的条件`],[`feedback`,`反馈方式`,`用哪些观测判断是否改善`]],hypothesis:[[`explanation`,`候选解释`,`这是待验证解释,不是事实`],[`mechanism`,`可能机制`,`为何可能出现该现象`],[`counterCondition`,`反证条件`,`什么证据会推翻解释`],[`signal`,`验证信号`,`指标、口径、窗口及观察位置`],[`stopCondition`,`停止条件`,`何时停止继续采用该解释`],[`failureBranch`,`失败分支`,`证据不支持或无法取得时下一步做什么`]],feedback:[[`observed`,`错误或反馈`,`保留实际问题,勿把猜测当已定位原因`],[`impact`,`实际影响`,`未测量的影响留空`],[`correction`,`纠正依据与建议`,`哪些证据支持纠正;哪些仍不确定`]],rule:[[`rule`,`判断规则`,`明确条件与判断动作,避免泛化口号`],[`scope`,`适用范围`,`商品、渠道、阶段、时间及输入条件`],[`exceptions`,`不适用条件与反例`,`哪些情况不能套用`],[`counterCondition`,`推翻或停用条件`,`哪些观察要求退回候选或停用`],[`expectedChange`,`预期改善`,`与普通明确指令相比预期改变什么`]],case:[[`scope`,`案例范围`,`真实/模拟性质、适用条件;原始材料选择数据库或附件`],[`criteria`,`评价口径`,`标准答案的评审方式,不向干净执行者暴露答案`]],evaluation:[[`scope`,`本次验证范围`,`限定可以支持的结论`],[`model`,`隔离执行模型`,`记录外部实际使用的模型;此页不调用模型`],[`timeout`,`预留时间与依据`,`按实际任务耗时估计`],[`report`,`人工评审报告`,`记录触发、运行、泄漏、输出与合理表达差异`],[`nextAction`,`后续建议`,`报告后先由用户审核,不自动修改再测`]]},L={unknown:`尚未定位`,definition:`问题定义`,evidence:`证据或口径`,rule:`判断规则`,execution:`执行过程`,tool:`工具或平台`,permission:`权限或依赖`,expression:`表达或交付`},R={development:`开发案例`,holdout:`未参与修改的留出案例`,regression:`旧案例回归`,counterexample:`反例`},z={pass:`通过(限记录范围)`,partial:`部分通过`,not_triggered:`未触发`,timeout:`触发后超时`,runtime:`运行或平台失败`,missing_tool:`依赖缺失`,context_leak:`上下文或答案泄漏`,output_failure:`输出失败`,cannot_judge:`无法判断`},B=(e=`brief`)=>({kind:e,title:``,summary:``,fields:Object.fromEntries((I[e]||[]).map(([e])=>[e,``])),nodes:[],analysisIds:[],relatedIds:[],refs:[],cause:`unknown`,role:`development`,usedForDevelopment:!1,inputRef:``,expectedRef:``,ruleRevisionId:``,caseRevisionIds:[],trialRef:``,approvalRef:``,requestRef:``,revisionApprovalRef:``,stable:!1,level:`synthetic`,outcome:`cannot_judge`,results:[]});function V(e){return e.kind===`rule`?e.state===`verified`?e.level===`business`?`已人工验证 · 限所述业务范围`:`已人工验证 · 仅模拟案例`:`候选 · 未验证`:e.kind===`evaluation`?{draft:`准备中`,authorized:`已登记前提 · 未自动执行`,reported:`已登记报告 · 等待人工决定`,interrupted:`已中断 · 未验证`}[e.state]||`准备中`:`已记录 · 待核验`}function H({data:e,api:t,onDirty:n,initialNode:r=``,initialRecord:i=``,onWiki:a}){let[o,s]=(0,v.useState)([]),[c,l]=(0,v.useState)([]),[u,d]=(0,v.useState)(!0),[f,p]=(0,v.useState)(``),[m,ee]=(0,v.useState)(``),[g,_]=(0,v.useState)(!1),[b,x]=(0,v.useState)(`all`),[S,C]=(0,v.useState)(``),[w,T]=(0,v.useState)(r),[E,D]=(0,v.useState)(``),[O,k]=(0,v.useState)(!1),[A,j]=(0,v.useState)(B()),[M,N]=(0,v.useState)(!1),[te,P]=(0,v.useState)(``),[H,U]=(0,v.useState)(!1),[W,G]=(0,v.useState)(``),[K,ne]=(0,v.useState)(``),[re,ie]=(0,v.useState)(``),q=(0,v.useRef)(null),J=(0,v.useRef)(!0);(0,v.useEffect)(()=>(J.current=!0,Y(),()=>{J.current=!1}),[e.project.id]),(0,v.useEffect)(()=>{n(M||g)},[M,g,n]);async function Y(n){d(!0);try{let[r,a]=await Promise.all([t(`/`+e.project.id+`/methods`),t(`/`+e.project.id+`/knowledge`)]);if(!J.current)return;s(r.records),l(a.entries),D(n||r.records.find(e=>e.recordId===i)?.id||``),p(``)}catch(e){J.current&&p(e.message)}finally{J.current&&d(!1)}}let ae=(0,v.useMemo)(()=>{let e=new Map;for(let t of o)(!e.has(t.recordId)||e.get(t.recordId).version<t.version)&&e.set(t.recordId,t);return[...e.values()]},[o]),X=o.find(e=>e.id===E),oe=o.filter(e=>e.recordId===X?.recordId).sort((e,t)=>t.version-e.version),Z=oe[0],se=e.files||[],ce=ae.filter(e=>e.kind===`case`),le=ae.filter(e=>e.kind===`rule`);function ue(){return!g&&(!M||confirm(`有未保存内容,放弃这些修改?`))}function de(e){ue()&&(D(e),k(!1),N(!1),P(``),U(!1),ee(``),p(``))}function fe(e){ue()&&(j({...B(e),nodes:w?[w]:[]}),D(``),k(!0),N(!1),P(``),U(!1),p(``))}function pe(){ue()&&(D(Z.id),j(structuredClone(Z)),k(!0),N(!1),P(``),U(!1),p(``))}function Q(e,t){j(n=>({...n,[e]:t})),N(!0)}function me(e,t){Q(`fields`,{...A.fields,[e]:t})}let he=(e,t,n=!1)=>(0,y.jsxs)(`label`,{children:[e,(0,y.jsxs)(`select`,{value:A[t]||``,disabled:n,onChange:e=>Q(t,e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`未记录 / 待补充`}),se.map(e=>(0,y.jsx)(`option`,{value:e.id,children:e.name},e.id))]})]},t),ge=(e,t,n,r=!1)=>(0,y.jsxs)(`fieldset`,{className:`wb-evidence-picker`,disabled:r,children:[(0,y.jsx)(`legend`,{children:e}),n.length?n.map(e=>(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:(A[t]||[]).includes(e.id),onChange:n=>Q(t,n.target.checked?[...A[t]||[],e.id]:A[t].filter(t=>t!==e.id))}),(0,y.jsx)(`span`,{children:e.label})]},e.id)):(0,y.jsx)(`p`,{className:`muted`,children:`暂无可选记录。`})]});async function _e(n){if(g)return;let r={op:n,record:A,recordId:X?.recordId,expectedVersion:X?.version||0,reason:te,ackHuman:H,evaluationRevisionId:W,targetRevisionId:K,revisionApprovalRef:re},i=JSON.stringify(r);q.current?.key!==i&&(q.current={key:i,id:crypto.randomUUID()}),r.mutationId=q.current.id,_(!0),p(``);try{let n=await t(`/`+e.project.id+`/methods`,r);if(!J.current)return;N(!1),k(!1),U(!1),q.current=null,await Y(n.id),ee(`已保存 v${n.version}。仅登记方法与审核,未执行店铺操作或干净回归。`)}catch(e){J.current&&p(e.message+`。若连接中断,请先重新读取;同一提交可安全重试。`)}finally{J.current&&_(!1)}}let $=O&&A.kind===`evaluation`&&X?.state===`authorized`,ve=ae.filter(e=>(b===`all`||e.kind===b)&&(!w||e.nodes.includes(w))&&`${e.title} ${e.summary} ${JSON.stringify(e.fields)}`.toLowerCase().includes(S.toLowerCase())),ye=(e,t,n)=>{let r=A.results.find(t=>t.caseRevisionId===e)||{caseRevisionId:e,baselineRef:``,candidateRef:``,verdict:`unknown`,reason:``,elapsedSeconds:null,rework:null};Q(`results`,[...A.results.filter(t=>t.caseRevisionId!==e),{...r,[t]:n}])};return(0,y.jsxs)(`div`,{className:`wb-methods`,children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`h2`,{children:[`任务与方法`,(0,y.jsx)(h,{label:`记录分析方法`,children:`任务明确时不用重复填写。新增方法先保存为待验证候选,模型建议不能直接成为业务规则,也不会授权店铺操作。`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`明确问题 → 候选解释 → 现实反馈 → 规则候选 → 人工验证与复盘`})]}),(0,y.jsx)(`button`,{disabled:g,onClick:()=>fe(b===`all`?`brief`:b),children:`新增记录`})]}),(0,y.jsx)(`div`,{className:`wb-callout`,children:`清晰任务可直接进行;只按需补充未知信息。这里保存可审计依据和方法,不保存模型内部推理链。规则与店铺操作权限分离。`}),f&&(0,y.jsxs)(`div`,{className:`error`,role:`alert`,children:[f,(0,y.jsx)(`button`,{disabled:g,onClick:()=>Y(X?.id),children:`重新读取`})]}),m&&(0,y.jsx)(`div`,{className:`notice`,role:`status`,children:m}),(0,y.jsxs)(`div`,{className:`wb-method-filters`,children:[(0,y.jsxs)(`label`,{children:[`记录类型`,(0,y.jsxs)(`select`,{value:b,onChange:e=>x(e.target.value),children:[(0,y.jsx)(`option`,{value:`all`,children:`全部`}),Object.entries(F).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))]})]}),(0,y.jsxs)(`label`,{children:[`关联节点`,(0,y.jsxs)(`select`,{value:w,onChange:e=>T(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`全部节点`}),e.nodeStatus.map(e=>(0,y.jsx)(`option`,{value:e.node,children:e.name},e.node))]})]}),(0,y.jsxs)(`label`,{children:[`查找记录`,(0,y.jsx)(`input`,{value:S,onChange:e=>C(e.target.value),placeholder:`标题、说明或方法字段`})]})]}),u?(0,y.jsx)(`p`,{role:`status`,children:`正在读取版本记录…`}):(0,y.jsxs)(`div`,{className:`wb-wiki-layout`,children:[(0,y.jsx)(`aside`,{className:`card wb-catalog`,children:(0,y.jsxs)(`div`,{className:`wb-dataset-list`,children:[ve.map(e=>(0,y.jsxs)(`button`,{className:e.recordId===X?.recordId?`active`:``,disabled:g,onClick:()=>de(e.id),children:[(0,y.jsx)(`b`,{children:e.title}),(0,y.jsxs)(`small`,{children:[F[e.kind],` · v`,e.version]}),(0,y.jsx)(`small`,{children:V(e)})]},e.id)),!ve.length&&(0,y.jsx)(`p`,{children:`暂无匹配记录。历史没有记录的内容不会自动补造。`})]})}),(0,y.jsx)(`section`,{className:`card wb-wiki-content`,children:O?(0,y.jsx)(`form`,{onSubmit:e=>{e.preventDefault(),_e($?`report`:`save`)},children:(0,y.jsxs)(`fieldset`,{disabled:g,className:`wb-analysis-fields`,children:[(0,y.jsx)(`legend`,{children:X?`追加版本`:`新增记录`}),!X&&(0,y.jsxs)(`label`,{children:[`新增类型`,(0,y.jsx)(`select`,{value:A.kind,onChange:e=>{(!M||confirm(`更换类型会清空未保存表单,继续?`))&&(j({...B(e.target.value),nodes:w?[w]:[]}),N(!1))},children:Object.entries(F).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[`标题`,(0,y.jsx)(`input`,{required:!0,maxLength:200,disabled:$,value:A.title,onChange:e=>Q(`title`,e.target.value)})]}),(0,y.jsxs)(`label`,{children:[`简要说明 / 下一步`,(0,y.jsx)(`textarea`,{rows:2,maxLength:12e3,disabled:$,value:A.summary,onChange:e=>Q(`summary`,e.target.value)})]}),A.kind===`brief`&&(0,y.jsx)(`p`,{className:`muted`,children:`以下五项均可留空,不要求为清晰任务重复填写问卷。`}),I[A.kind].map(([e,t,n])=>(0,y.jsxs)(`label`,{children:[t,(0,y.jsx)(`textarea`,{rows:3,maxLength:1e4,placeholder:n,value:A.fields[e]||``,disabled:$&&![`report`,`nextAction`].includes(e),onChange:t=>me(e,t.target.value)})]},e)),A.kind===`feedback`&&(0,y.jsxs)(`label`,{children:[`可能出错的环节`,(0,y.jsx)(`select`,{value:A.cause,onChange:e=>Q(`cause`,e.target.value),children:Object.entries(L).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),A.kind===`rule`&&(0,y.jsxs)(y.Fragment,{children:[he(`报告后修改:用户明确要求修改的依据`,`revisionApprovalRef`),(0,y.jsx)(`p`,{className:`muted`,children:`新建和修订都先保存为候选。模型建议、格式通过和模拟表现不能自动成为真实业务验证。`})]}),A.kind===`case`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`案例用途`,(0,y.jsx)(`select`,{value:A.role,onChange:e=>Q(`role`,e.target.value),children:Object.entries(R).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:A.usedForDevelopment,onChange:e=>Q(`usedForDevelopment`,e.target.checked)}),`此输入曾参与规则修改或开发`]}),he(`原始输入(数据库/附件)`,`inputRef`),he(`人工认可参考依据(不进入运行上下文)`,`expectedRef`),(0,y.jsx)(`p`,{className:`muted`,children:`案例原件和答案保存在数据库及附件,不写入 Wiki 正文。留出状态是人工声明,系统会检查已登记的内容重复,不能证明人从未见过该案例。`})]}),A.kind===`evaluation`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`div`,{className:`wb-callout`,children:`干净回归门禁:用户认可的标准答案、当前迭代完成、用户主动要求,三者齐备。这里只登记前提和外部结果,不启动子代理。外部应仅启动一个隔离执行者,普通任务提示不得夹带答案、Skill 路径、评分表或设计历史;报告后先交用户审核,不自动修改再测。`}),(0,y.jsxs)(`label`,{children:[`本次验证固定使用的方法版本`,(0,y.jsxs)(`select`,{disabled:$,value:A.ruleRevisionId,onChange:e=>Q(`ruleRevisionId`,e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`请选择规则`}),($?o.filter(e=>e.id===A.ruleRevisionId):le).map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[e.title,` · v`,e.version]},e.id))]})]}),ge(`验证案例(分别保留留出、旧例与反例)`,`caseRevisionIds`,($?o.filter(e=>A.caseRevisionIds.includes(e.id)):ce).map(e=>({id:e.id,label:`${e.title} · v${e.version} · ${R[e.role]}`})),$),he(`真实/代表性主对话试用与标准答案依据`,`trialRef`,$),he(`用户已认可该标准答案的依据`,`approvalRef`,$),he(`用户本次明确要求干净回归的依据`,`requestRef`,$),(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,disabled:$,checked:A.stable,onChange:e=>Q(`stable`,e.target.checked)}),`当前迭代已完成,不在调试途中`]}),(0,y.jsxs)(`label`,{children:[`验证性质`,(0,y.jsxs)(`select`,{disabled:$,value:A.level,onChange:e=>Q(`level`,e.target.value),children:[(0,y.jsx)(`option`,{value:`synthetic`,children:`模拟案例验证,不代表业务效果`}),!e.project.simulated&&(0,y.jsx)(`option`,{value:`business`,children:`人工核验的真实业务范围`})]})]}),$&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`外部运行结果`,(0,y.jsx)(`select`,{value:A.outcome,onChange:e=>Q(`outcome`,e.target.value),children:Object.entries(z).map(([e,t])=>(0,y.jsx)(`option`,{value:e,children:t},e))})]}),A.caseRevisionIds.map(e=>{let t=o.find(t=>t.id===e),n=A.results.find(t=>t.caseRevisionId===e)||{};return(0,y.jsxs)(`fieldset`,{className:`wb-analysis-fields`,children:[(0,y.jsx)(`legend`,{children:t?.title||e}),[[`baselineRef`,`普通明确指令的输出证据`],[`candidateRef`,`加入候选规则的输出证据`]].map(([t,r])=>(0,y.jsxs)(`label`,{children:[r,(0,y.jsxs)(`select`,{value:n[t]||``,onChange:n=>ye(e,t,n.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`未记录`}),se.map(e=>(0,y.jsx)(`option`,{value:e.id,children:e.name},e.id))]})]},t)),(0,y.jsxs)(`label`,{children:[`案例判断`,(0,y.jsxs)(`select`,{value:n.verdict||`unknown`,onChange:t=>ye(e,`verdict`,t.target.value),children:[(0,y.jsx)(`option`,{value:`unknown`,children:`无法判断`}),(0,y.jsx)(`option`,{value:`pass`,children:`通过`}),(0,y.jsx)(`option`,{value:`fail`,children:`失败`})]})]}),(0,y.jsxs)(`label`,{children:[`判断依据`,(0,y.jsx)(`textarea`,{value:n.reason||``,onChange:t=>ye(e,`reason`,t.target.value)})]}),[[`elapsedSeconds`,`耗时(秒)`],[`rework`,`人工返工次数`]].map(([t,r])=>(0,y.jsxs)(`label`,{children:[r,(0,y.jsx)(`input`,{type:`number`,min:`0`,value:n[t]??``,onChange:n=>ye(e,t,n.target.value===``?null:Number(n.target.value))})]},t))]},e)})]})]}),!$&&(0,y.jsxs)(`details`,{className:`wb-method-links`,open:!!r,children:[(0,y.jsx)(`summary`,{children:`关联节点、分析、反馈和证据`}),ge(`关联节点`,`nodes`,e.nodeStatus.map(e=>({id:e.node,label:e.name}))),ge(`关联分析或节点记录版本`,`analysisIds`,c.filter(e=>!String(e.id).includes(`-audit-`)).map(e=>({id:e.id,label:`${e.title} · ${e.version?`v`+e.version:`未记录版本`}`}))),ge(`关联反馈、解释或规则版本`,`relatedIds`,ae.filter(e=>e.recordId!==X?.recordId).map(e=>({id:e.id,label:`${F[e.kind]} · ${e.title} · v${e.version}`}))),ge(`来源证据`,`refs`,se.map(e=>({id:e.id,label:e.name})))]}),X&&(0,y.jsxs)(`label`,{children:[`本版变更 / 审核理由`,(0,y.jsx)(`textarea`,{required:!0,value:te,maxLength:2e3,onChange:e=>{P(e.target.value),N(!0)}})]}),($||A.kind===`rule`)&&(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:H,onChange:e=>U(e.target.checked)}),`我已人工核对来源和适用边界;需要修订时已有用户明确要求`]}),(0,y.jsxs)(`div`,{className:`wb-actions`,children:[(0,y.jsx)(`button`,{type:`submit`,children:g?`保存中…`:$?`登记报告为新版本`:`保存为新版本`}),(0,y.jsx)(`button`,{type:`button`,className:`secondary`,onClick:()=>{ue()&&(k(!1),N(!1))},children:`取消`})]}),(0,y.jsx)(`p`,{className:`muted`,children:`提交后离开页面不会撤销已完成的保存。连接中断先回读,再重试;不会自动重跑验证。`})]})}):X?(0,y.jsxs)(`article`,{children:[(0,y.jsxs)(`div`,{className:`wb-section-heading`,children:[(0,y.jsx)(`span`,{className:`wb-chip`,children:F[X.kind]}),(0,y.jsx)(`span`,{children:V(X)})]}),(0,y.jsx)(`h2`,{className:`wb-doc-title`,children:X.title}),(0,y.jsxs)(`p`,{className:`muted`,children:[`v`,X.version,` · `,X.created]}),(0,y.jsxs)(`label`,{children:[`历史版本`,(0,y.jsx)(`select`,{value:X.id,onChange:e=>de(e.target.value),children:oe.map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[`v`,e.version,` · `,V(e)]},e.id))})]}),(0,y.jsx)(`p`,{className:`wb-prose`,children:X.summary||`当时未记录简要说明。`}),I[X.kind].map(([e,t])=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:t}),(0,y.jsx)(`p`,{children:X.fields[e]||`当时未记录`})]},e)),X.kind===`feedback`&&(0,y.jsxs)(`p`,{children:[`疑似原因:`,L[X.cause],`(并非已经证实)`]}),X.kind===`case`&&(0,y.jsxs)(`p`,{children:[R[X.role],` · `,X.usedForDevelopment?`已参与开发`:`未参与开发(人工声明)`]}),X.kind===`evaluation`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`div`,{className:`wb-callout`,children:[V(X),`。本系统未启动干净回归;不把模型建议或模拟结果当真实业务效果。`,X.ruleRevisionId&&o.some(e=>e.id===X.ruleRevisionId&&ae.some(t=>t.recordId===e.recordId&&t.id!==e.id))?`规则已产生后续版本,本报告只对应冻结版本。`:``]}),(0,y.jsxs)(`p`,{children:[`运行结果:`,z[X.outcome],` · `,X.level===`business`?`真实业务范围(人工声明)`:`仅模拟案例`]}),X.results.map(e=>(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsx)(`h3`,{children:o.find(t=>t.id===e.caseRevisionId)?.title||e.caseRevisionId}),(0,y.jsxs)(`p`,{children:[e.verdict,` · `,e.reason||`未记录判断`,` · 耗时 `,e.elapsedSeconds??`未记录`,` 秒 · 返工 `,e.rework??`未记录`,` 次`]})]},e.caseRevisionId))]}),X.review&&(0,y.jsxs)(`div`,{className:`wb-callout`,children:[`人工审核记录:`,X.review.reason,` · `,X.review.at,`。仅限:`,X.review.declaredScope,`;不自动启用业务动作。`]}),(0,y.jsxs)(`section`,{className:`wb-prose`,children:[(0,y.jsxs)(`h3`,{children:[`关联与追溯`,(0,y.jsx)(h,{label:`追溯依据`,children:`关联具体资料与分析版本。历史没记录的内容应标明缺失,不要用事后推测补成当时事实。`})]}),(0,y.jsxs)(`p`,{children:[`节点:`,X.nodes.map(t=>e.nodeStatus.find(e=>e.node===t)?.name||t).join(`、`)||`未关联`]}),X.analysisIds.map(e=>(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>a?.(e),children:[`查看分析 / 节点版本:`,c.find(t=>t.id===e)?.title||e,` →`]},e)),X.relatedIds.map(e=>(0,y.jsxs)(`button`,{className:`wb-text-button`,onClick:()=>de(e),children:[`关联记录:`,o.find(t=>t.id===e)?.title||e,` →`]},e)),X.kind!==`case`&&(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>a?.(X.id),children:`在分析 Wiki 阅读 →`})]}),(0,y.jsxs)(`details`,{className:`wb-provenance`,children:[(0,y.jsx)(`summary`,{children:`证据版本、输入与完整性校验`}),(X.sourceSnapshots||[]).map(t=>(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`a`,{href:`/api/workbench/`+e.project.id+`/file/`+t.id,children:t.name}),` · `,t.created,(0,y.jsx)(`br`,{}),`SHA256 `,t.sha]},t.id)),X.analysisSnapshots?.map(e=>(0,y.jsxs)(`p`,{children:[`关联 `,e.id,` · `,e.version?`v`+e.version:`未记录版本`,` · SHA256 `,e.sha]},e.id))]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`本版说明:`,X.changeReason||`首次记录`,X.rollbackOf?`;恢复自 `+X.rollbackOf:``]}),X.id===Z?.id&&(0,y.jsxs)(`div`,{className:`wb-method-review`,children:[(X.kind!==`evaluation`||X.state===`draft`||X.state===`authorized`)&&(0,y.jsx)(`button`,{disabled:g,onClick:pe,children:X.kind===`evaluation`&&X.state===`authorized`?`登记外部验证报告`:`编辑并保存新版本`}),(X.kind===`rule`||X.kind===`evaluation`)&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`本次审核 / 中断 / 回滚理由`,(0,y.jsx)(`textarea`,{maxLength:2e3,value:te,onChange:e=>P(e.target.value)})]}),(0,y.jsxs)(`label`,{children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:H,onChange:e=>U(e.target.checked)}),`人工核对:依据真实记录、范围和用户要求,模型自评不能替代`]})]}),X.kind===`evaluation`&&X.state===`draft`&&(0,y.jsx)(`button`,{disabled:g,onClick:()=>_e(`authorize`),children:`记录验证条件已齐备(不开始运行)`}),X.kind===`evaluation`&&[`draft`,`authorized`].includes(X.state)&&(0,y.jsx)(`button`,{className:`secondary`,disabled:g,onClick:()=>_e(`interrupt`),children:`登记中断`}),X.kind===`rule`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`本版本验证报告`,(0,y.jsxs)(`select`,{value:W,onChange:e=>G(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`请选择已报告的验证`}),ae.filter(e=>e.kind===`evaluation`&&e.ruleRevisionId===X.id&&e.state===`reported`).map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[e.title,` · `,z[e.outcome]]},e.id))]})]}),(0,y.jsx)(`button`,{disabled:g||!W,onClick:()=>_e(`verify`),children:`人工审核为已验证(限记录范围)`}),oe.length>1&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`恢复哪个历史版本`,(0,y.jsxs)(`select`,{value:K,onChange:e=>ne(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`请选择历史版本`}),oe.filter(e=>e.id!==X.id).map(e=>(0,y.jsxs)(`option`,{value:e.id,children:[`v`,e.version,` · `,e.title]},e.id))]})]}),(0,y.jsxs)(`label`,{children:[`报告后修改的用户要求依据`,(0,y.jsxs)(`select`,{value:re,onChange:e=>ie(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`未提供`}),se.map(e=>(0,y.jsx)(`option`,{value:e.id,children:e.name},e.id))]})]}),(0,y.jsx)(`button`,{className:`secondary`,disabled:g||!K,onClick:()=>_e(`rollback`),children:`将历史内容另存为待验证版本`})]})]})]})]}):(0,y.jsxs)(`div`,{className:`wb-empty`,children:[(0,y.jsx)(`h3`,{children:`按需记录,不增加重复问卷`}),(0,y.jsx)(`p`,{children:`任务已明确可直接推进现有流程;需要分析或复盘时,再创建任务定义、候选解释或错误反馈。`}),(0,y.jsx)(`button`,{onClick:()=>fe(`brief`),children:`记录任务`})]})})]})]})}var U=[[`finding`,`分析结论`,`每条结论必须挂数据依据,可被后续结论取代`],[`action-item`,`下一步动作`,`必须写清改哪里、改什么、因果链、怎么验证`],[`playbook`,`方法论库`,`可复用的分析套路,换项目也能照着跑`]],W={todo:`待办`,doing:`进行中`,done:`已完成`,dropped:`已放弃`,blocked:`受阻`},G=e=>Object.values(e||{}).some(e=>e!==``&&e!=null),K={high:`高`,medium:`中`,low:`低`};function ne(e){return e.split(`
|
|
3
3
|
`).map(e=>e.trim()).filter(Boolean).map(e=>{let[t,n,r,i,a]=e.split(`|`).map(e=>(e||``).trim());return{metric:t,value:n,unit:r,benchmark:i,source:a}})}function re({data:e,api:t,onSaved:n,onWikiEntry:r,onDirty:i,onBusy:a}){let[o,s]=(0,v.useState)(`finding`),[c,l]=(0,v.useState)(!1),[u,d]=(0,v.useState)(``),[f,p]=(0,v.useState)(!1),[m,ee]=(0,v.useState)({}),g=m[o]||{},_=e=>ee(t=>({...t,[o]:typeof e==`function`?e(t[o]||{}):e})),b=Object.values(m).some(e=>G(e));(0,v.useEffect)(()=>{i?.(b)},[b,i]),(0,v.useEffect)(()=>(a?.(c),()=>a?.(!1)),[c,a]);let x=e.findings||[],S=e.actionItems||[],C=e.playbooks||[],w={finding:x.length,"action-item":S.length,playbook:C.length};(0,v.useEffect)(()=>{p(G(m[o])),d(``)},[o]);function T(e,t){_(n=>({...n,[e]:t}))}async function E(){l(!0),d(``);try{let a={kind:o,op:`create`,data:{}};if(o===`finding`)a.data={title:g.title,conclusion:g.conclusion,scope:g.scope,window:g.window,method:g.method,confidence:g.confidence||`medium`,evidence:ne(g.evidenceText||``)};else if(o===`action-item`)a.data={title:g.title,priority:Number(g.priority)||5,target:g.target,change:g.change,causal:g.causal,expected:g.expected,verifyDays:Number(g.verifyDays)||7,requiresApproval:g.requiresApproval!==!1,evidence:ne(g.evidenceText||``)};else{let e=e=>String(g[e]||``).split(`
|
|
4
4
|
`).map(e=>e.trim()).filter(Boolean);a.data={name:g.name,when:g.when,dataNeeded:e(`dataNeededText`),steps:e(`stepsText`),rules:e(`rulesText`),pitfalls:e(`pitfallsText`),outputs:g.outputs}}let s=await t(`/`+e.project.id+`/insight`,a);_({}),p(!1),d(`已保存`),await n(),i?.(Object.entries(m).some(([e,t])=>e!==o&&G(t))),o===`finding`&&!Object.entries(m).some(([e,t])=>e!==o&&G(t))&&r?.(s.id,!0)}catch(e){d(e.message)}finally{l(!1)}}async function D(r,i){l(!0),d(``);try{await t(`/`+e.project.id+`/insight`,{kind:`action-item`,op:`update`,id:r,data:{status:i}}),await n()}catch(e){d(e.message)}finally{l(!1)}}async function O(r,i){if(confirm(`确认删除这条记录?删除后不可恢复。`)){l(!0);try{await t(`/`+e.project.id+`/insight`,{kind:r,op:`delete`,id:i}),await n()}catch(e){d(e.message)}finally{l(!1)}}}let k=e=>e.list?.length?(0,y.jsx)(`div`,{className:`wb-table-wrap wb-insight-evidence`,role:`region`,"aria-label":`结论与行动的数据依据,可横向滚动`,tabIndex:0,children:(0,y.jsxs)(`table`,{className:`wb-table`,children:[(0,y.jsx)(`thead`,{children:(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`col`,children:`指标`}),(0,y.jsx)(`th`,{scope:`col`,children:`数值`}),(0,y.jsx)(`th`,{scope:`col`,children:`对比基准`}),(0,y.jsx)(`th`,{scope:`col`,children:`来源`})]})}),(0,y.jsx)(`tbody`,{children:e.list.map((e,t)=>(0,y.jsxs)(`tr`,{children:[(0,y.jsx)(`th`,{scope:`row`,children:e.metric}),(0,y.jsxs)(`td`,{children:[e.value??`—`,e.unit]}),(0,y.jsx)(`td`,{children:e.benchmark||`—`}),(0,y.jsx)(`td`,{children:e.source||`未提供`})]},t))})]})}):null,A=(e,t,n,r=3)=>(0,y.jsxs)(`label`,{children:[t,(0,y.jsx)(`textarea`,{rows:r,value:g[e]||``,onChange:t=>T(e,t.target.value),placeholder:n})]});return(0,y.jsxs)(`section`,{className:`wb-insights`,children:[(0,y.jsxs)(`div`,{className:`section-title`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`p`,{className:`eyebrow`,children:`ANALYSIS → DECISION → ACTION`}),(0,y.jsxs)(`h2`,{children:[`结论与行动`,(0,y.jsx)(h,{label:`结论与行动`,children:`结论要写适用范围和证据;行动写负责人、预期和复盘时间。删除前确认是否还需保留该记录。`})]})]}),(0,y.jsxs)(`span`,{className:`muted`,children:[x.length,` 条结论 · `,S.length,` 个动作 · `,C.length,` 套方法论`]})]}),(0,y.jsx)(`div`,{className:`tabs`,style:{marginBottom:14},children:U.map(([e,t,n])=>(0,y.jsxs)(`button`,{disabled:c,"aria-pressed":o===e,className:o===e?`selected`:``,style:{background:o===e?`var(--omni-selected)`:`var(--omni-panel)`,color:o===e?`var(--omni-accent)`:`var(--omni-muted)`,borderBottom:o===e?`2px solid var(--omni-accent)`:`2px solid transparent`},onClick:()=>s(e),children:[t,` `,(0,y.jsxs)(`small`,{children:[w[e],G(m[e])?` · 草稿`:``]})]},e))}),(0,y.jsx)(`p`,{className:`hint`,style:{marginBottom:14},children:U.find(e=>e[0]===o)?.[2]}),u&&(0,y.jsx)(`div`,{role:`status`,className:`notice`,children:u}),(0,y.jsx)(`button`,{disabled:c,onClick:()=>p(!f),style:{marginBottom:14},children:f?`收起表单`:`+ 新增`+(o===`finding`?`结论`:o===`action-item`?`动作`:`方法论`)}),f&&(0,y.jsxs)(`section`,{className:`card`,style:{marginBottom:18},children:[G(g)&&(0,y.jsxs)(`p`,{className:`notice`,children:[`切换本页标签会保留草稿。`,(0,y.jsx)(`button`,{disabled:c,onClick:()=>{confirm(`放弃当前标签的草稿?`)&&_({})},children:`放弃此草稿`})]}),o===`finding`&&(0,y.jsx)(`p`,{className:`wb-callout`,children:`此处保存简要结论,过程标记为待补充。保存后进入 Wiki,补充分析依据与复盘计划。`}),o===`finding`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`结论标题`,(0,y.jsx)(`input`,{value:g.title||``,onChange:e=>T(`title`,e.target.value),placeholder:`例如:暖棚退款主因是价格不是履约`})]}),A(`conclusion`,`结论正文`,`把「多少、占比、和谁比」写进去,不要只写方向`,4),(0,y.jsxs)(`div`,{className:`two`,children:[(0,y.jsxs)(`label`,{children:[`结论适用时间`,(0,y.jsx)(`input`,{value:g.window||``,onChange:e=>T(`window`,e.target.value),placeholder:`2026-10-26|2026-11-01`})]}),(0,y.jsxs)(`label`,{children:[`适用范围`,(0,y.jsx)(`input`,{value:g.scope||``,onChange:e=>T(`scope`,e.target.value),placeholder:`项目 / 商品ID / 全店`})]})]}),(0,y.jsxs)(`div`,{className:`two`,children:[(0,y.jsxs)(`p`,{children:[`判断把握程度`,(0,y.jsx)(h,{label:`如何填写判断把握程度`,children:`依据资料完整性、来源可靠性和反例填写。这个数值是人工判断,不是经过统计验证的成功概率。`})]}),(0,y.jsxs)(`label`,{children:[`判断把握程度`,(0,y.jsxs)(`select`,{value:g.confidence||`medium`,onChange:e=>T(`confidence`,e.target.value),children:[(0,y.jsx)(`option`,{value:`high`,children:`高(全量实测)`}),(0,y.jsx)(`option`,{value:`medium`,children:`中(样本有限)`}),(0,y.jsx)(`option`,{value:`low`,children:`低(待复核)`})]})]}),(0,y.jsxs)(`label`,{children:[`方法论`,(0,y.jsx)(`input`,{value:g.method||``,onChange:e=>T(`method`,e.target.value),placeholder:`退款原因归因法`})]})]}),A(`evidenceText`,`数据依据(每行一条:指标|数值|单位|对比基准|来源)`,`退款额|8806|元|退款总额28320元|达摩盘`,4)]}),o===`action-item`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`行动标题`,(0,y.jsx)(`input`,{value:g.title||``,onChange:e=>T(`title`,e.target.value),placeholder:`净费比目标 4.95% → 6.0%`})]}),(0,y.jsxs)(`div`,{className:`two`,children:[(0,y.jsxs)(`label`,{children:[`优先级`,(0,y.jsx)(`input`,{type:`number`,min:1,max:9,value:g.priority??5,onChange:e=>T(`priority`,e.target.value)})]}),(0,y.jsxs)(`label`,{children:[`验证周期(天)`,(0,y.jsx)(`input`,{type:`number`,min:1,max:90,value:g.verifyDays??7,onChange:e=>T(`verifyDays`,e.target.value)})]})]}),A(`target`,`改哪里`,`计划ID / 详情页第几屏 / 商品ID`,2),A(`change`,`改什么`,`具体到数值或文案,不要写「优化一下」`,2),A(`causal`,`因果链`,`为什么这个改动能解决问题`,3),A(`expected`,`预期结果与验证标准`,`7天后看什么数、达到多少算成功`,2),A(`evidenceText`,`数据依据(每行一条:指标|数值|单位|对比基准|来源)`,`预算使用率|36|%|预算3500元实花1259元|阿里妈妈计划配置`,4),(0,y.jsxs)(`label`,{style:{display:`flex`,gap:8,alignItems:`center`},children:[(0,y.jsx)(`input`,{type:`checkbox`,checked:g.requiresApproval!==!1,onChange:e=>T(`requiresApproval`,e.target.checked),style:{width:`auto`}}),`需要人工确认后才执行`]})]}),o===`playbook`&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`label`,{children:[`方法论名称`,(0,y.jsx)(`input`,{value:g.name||``,onChange:e=>T(`name`,e.target.value),placeholder:`渠道结构对比法`})]}),A(`when`,`什么时候用`,`判断流量下滑是量的问题还是质的问题`,2),A(`dataNeededText`,`需要的数据(每行一个)`,`item.flow-source-tree-v3 前后两个7天窗口`,3),A(`stepsText`,`步骤(每行一步)`,`按 UV 和支付额排序渠道|算每渠道边际产出|找出亏损渠道`,5),A(`rulesText`,`判读规则(每行一条)`,`边际产出差10倍以上才可迁预算`,3),A(`pitfallsText`,`坑(每行一条)`,`别用总UV价值掩盖单渠道塌陷`,3),A(`outputs`,`产出物`,`渠道对比表 + 预算迁移建议`,2)]}),(0,y.jsx)(`button`,{disabled:c,onClick:E,children:`保存`})]}),o===`finding`&&(0,y.jsxs)(`section`,{children:[!x.length&&(0,y.jsx)(`p`,{className:`muted`,children:`还没有结论。取完数先落结论,再谈动作。`}),x.map(e=>(0,y.jsxs)(`article`,{className:`card wb-insight-record`,style:{marginBottom:12},children:[(0,y.jsxs)(`div`,{className:`section-title`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`p`,{className:`eyebrow`,children:[e.window||`—`,` · `,e.scope||`—`,` · 判断把握程度 `,K[e.confidence]||e.confidence]}),(0,y.jsx)(`h3`,{children:e.title})]}),(0,y.jsx)(`button`,{className:`secondary wb-record-delete`,"aria-label":`删除结论:`+e.title,disabled:c,onClick:()=>O(`finding`,e.id),children:`删除`})]}),(0,y.jsx)(`p`,{className:`wb-insight-conclusion`,style:{whiteSpace:`pre-wrap`},children:e.conclusion}),(0,y.jsx)(k,{list:e.evidence}),r&&(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>r(e.id),children:`查看分析过程 / 补充复盘 →`}),(0,y.jsxs)(`p`,{className:`muted`,children:[`方法论:`,e.method||`—`,` 记录ID:`,e.id,e.supersededBy?` 已被新结论取代`:``]})]},e.id))]}),o===`action-item`&&(0,y.jsxs)(`section`,{children:[!S.length&&(0,y.jsx)(`p`,{className:`muted`,children:`还没有动作。动作必须能从一条结论推出来。`}),S.map(e=>(0,y.jsxs)(`article`,{className:`card wb-insight-record`,style:{marginBottom:12},children:[(0,y.jsxs)(`div`,{className:`section-title`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsxs)(`p`,{className:`eyebrow`,children:[`P`,e.priority,` · `,W[e.status]||e.status,e.requiresApproval?` · 需人工确认`:``]}),(0,y.jsx)(`h3`,{children:e.title})]}),(0,y.jsx)(`button`,{className:`secondary wb-record-delete`,"aria-label":`删除动作:`+e.title,disabled:c,onClick:()=>O(`action-item`,e.id),children:`删除`})]}),(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`改哪里`}),` `,e.target]}),(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`改什么`}),` `,e.change]}),(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`因果链`}),` `,e.causal]}),(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`预期与验证`}),` `,e.expected,`(`,e.verifyDays,`天)`]}),(0,y.jsx)(k,{list:e.evidence}),r&&(0,y.jsx)(`button`,{className:`wb-text-button`,onClick:()=>r(e.id),children:`查看分析过程 / 补充复盘 →`}),!!e.steps?.length&&(0,y.jsxs)(`details`,{style:{marginTop:10},open:!0,children:[(0,y.jsxs)(`summary`,{children:[(0,y.jsx)(`b`,{children:`操作步骤`}),`(`,e.steps.length,` 步)`]}),(0,y.jsx)(`ol`,{style:{marginTop:8,lineHeight:1.75},children:e.steps.map((e,t)=>e?(0,y.jsx)(`li`,{children:e},t):(0,y.jsx)(`li`,{style:{listStyle:`none`,height:8}},t))})]}),(0,y.jsx)(`div`,{style:{display:`flex`,gap:8,flexWrap:`wrap`,marginTop:10},children:[`todo`,`doing`,`done`,`dropped`,`blocked`].map(t=>(0,y.jsx)(`button`,{className:e.status===t?``:`secondary`,disabled:c||e.status===t,onClick:()=>D(e.id,t),children:W[t]},t))})]},e.id))]}),o===`playbook`&&(0,y.jsxs)(`section`,{children:[!C.length&&(0,y.jsx)(`p`,{className:`muted`,children:`还没有方法论。每次分析完把套路存下来,下次换项目直接跑。`}),C.map(e=>(0,y.jsxs)(`article`,{className:`card wb-insight-record`,style:{marginBottom:12},children:[(0,y.jsxs)(`div`,{className:`section-title`,children:[(0,y.jsxs)(`div`,{children:[(0,y.jsx)(`p`,{className:`eyebrow`,children:`PLAYBOOK`}),(0,y.jsx)(`h3`,{children:e.name})]}),(0,y.jsx)(`button`,{className:`secondary wb-record-delete`,"aria-label":`删除方法论:`+e.name,disabled:c,onClick:()=>O(`playbook`,e.id),children:`删除`})]}),(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`何时使用`}),` `,e.when||`—`]}),!!e.dataNeeded?.length&&(0,y.jsxs)(`p`,{children:[(0,y.jsx)(`b`,{children:`需要的数据`}),` `,e.dataNeeded.map(e=>(0,y.jsx)(`code`,{style:{marginRight:6},children:e},e))]}),(0,y.jsx)(`ol`,{children:e.steps?.map((e,t)=>(0,y.jsx)(`li`,{children:e},t))}),!!e.rules?.length&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`p`,{children:(0,y.jsx)(`b`,{children:`判读规则`})}),(0,y.jsx)(`ul`,{children:e.rules.map((e,t)=>(0,y.jsx)(`li`,{children:e},t))})]}),!!e.pitfalls?.length&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`p`,{children:(0,y.jsx)(`b`,{children:`坑`})}),(0,y.jsx)(`ul`,{children:e.pitfalls.map((e,t)=>(0,y.jsx)(`li`,{children:e},t))})]}),(0,y.jsxs)(`p`,{className:`muted`,children:[`产出:`,e.outputs||`—`,` 记录ID:`,e.id]})]},e.id))]})]})}function ie(e){return[`pending`,`processing`].includes(e.state)||e.dispatch?.state===`dispatching`||!!e.analysis&&[`not_reported`,`reporting`].includes(e.notification?.state||``)}var q={page:`_page_18h23_2`,heading:`_heading_18h23_3`,notice:`_notice_18h23_6`,projectPicker:`_projectPicker_18h23_8`,error:`_error_18h23_14`},J={AUTOLOOP_DISABLED:`AutoLoop 尚未启用`,SUPERVISED_WORKER_MISSING:`尚未绑定可监管、可取消的执行器`,MODEL_DATA_SCOPE_MISSING:`尚未绑定模型与资料处理范围`,NOTIFICATION_SCOPE_MISSING:`审核通知尚未绑定或授权`,PROJECT_AUTHORIZATION_MISSING:`本项目的运行授权未配置或已到期`,EVENT_ADAPTER_MISSING:`事件来源及派发适配器尚未绑定`,TRUSTED_SESSION_ADAPTER_MISSING:`尚未接通可信人工登录`,HUMAN_PRODUCTION_SESSION_REQUIRED:`开发登录不能用于审核`,SIGN_IN_REQUIRED:`请先完成可信人工登录`,SESSION_EXPIRED:`人工登录已过期`,SESSION_VERIFICATION_FAILED:`人工登录校验失败`,PROJECT_OWNER_MISMATCH:`人工登录与项目归属不符`},Y={waiting_human:`等待审核`,feedback_pending:`已反馈,待继续分析`,paused:`已暂缓`,reviewed:`已审阅(不等于业务批准)`,pending:`等待受监管执行器`,processing:`正在分析`,failed:`分析失败,需核对后重试`},ae={completed:`已完成`,pending:`等待处理`,processing:`正在处理`,blocked:`运行条件未满足`,not_connected:`未接通`,not_sent:`尚未派发`,dispatching:`正在投递,等待确认`,sent:`已派发`,unrouted:`已送达,但没有匹配规则`,unknown:`结果未知,需核对中台,不能直接重发`,not_reported:`尚未提交回执`,reporting:`回执提交中`,accepted:`中台已接受回执(不代表通知已送达)`,rejected:`中台拒绝部分回执操作,需核对`};async function X(e,t){let n=await fetch(e,{method:t?`POST`:`GET`,headers:{"Content-Type":`application/json`},body:t?JSON.stringify(t):void 0}),r=await n.json();if(!n.ok)throw Error(r.error||`请求失败`);return r}function oe({initialProject:e=``,initialDataset:t=``,onDirty:n,onBusy:r}){let[i,a]=(0,v.useState)(e),[o,s]=(0,v.useState)(null),[c,l]=(0,v.useState)([]),[u,d]=(0,v.useState)(t),[f,p]=(0,v.useState)(``),[m,ee]=(0,v.useState)([]),[g,_]=(0,v.useState)({}),[b,x]=(0,v.useState)(!1),[S,C]=(0,v.useState)(``),[w,T]=(0,v.useState)([]),[E,D]=(0,v.useState)(!0),[O,k]=(0,v.useState)(``),[A,j]=(0,v.useState)(!!e),[M,N]=(0,v.useState)({}),[te,P]=(0,v.useState)([]),F=(0,v.useRef)(0),I=(0,v.useRef)(!1),L=(0,v.useRef)(0);function R(e){ee(e.tasks||[]),N(e.capabilities||{}),P(e.blockers||[])}let z=(0,v.useCallback)(e=>{I.current||(f.trim()||Object.values(g).some(e=>e.trim()))&&!confirm(`放弃未提交的分析目标或核对意见并切换项目?`)||(F.current++,s(null),l([]),d(``),p(``),ee([]),_({}),N({}),P([]),C(``),j(!!e),a(e))},[f,g]),B=(0,v.useCallback)(()=>{let t=++L.current;return X(`/api/workbench`).then(n=>{if(t===L.current){if(!Array.isArray(n))throw Error(`项目列表格式异常`);T(n),n.length===1&&!e&&a(n[0].id)}}).catch(e=>{t===L.current&&k(e.message)}).finally(()=>{t===L.current&&D(!1)})},[e]);(0,v.useEffect)(()=>{let e=L,t=F;return B(),()=>{e.current++,t.current++}},[B]),(0,v.useEffect)(()=>{let e=F,t=++e.current;if(!i)return;let n=`/api/workbench/`+encodeURIComponent(i);return Promise.all([X(n),X(n+`/datasets`),X(n+`/analysis-queue`)]).then(([e,n,r])=>{t===F.current&&(s(e.project||e),l(n.datasets||[]),d(e=>(n.datasets||[]).some(t=>t.id===e)?e:``),R(r))}).catch(e=>{t===F.current&&C(e.message)}).finally(()=>{t===F.current&&j(!1)}),()=>{e.current++}},[i]),(0,v.useEffect)(()=>{n?.(!!f.trim()||Object.values(g).some(e=>!!e.trim()))},[f,g,n]),(0,v.useEffect)(()=>(r?.(b),()=>r?.(!1)),[b,r]);let V=m.some(ie);(0,v.useEffect)(()=>{if(!i||!V)return;let e=F.current,t=setInterval(()=>{document.hidden||I.current||X(`/api/workbench/`+encodeURIComponent(i)+`/analysis-queue`).then(t=>{e===F.current&&R(t)}).catch(()=>{})},5e3);return()=>clearInterval(t)},[i,V]);async function H(e,t){return X(`/api/workbench/`+encodeURIComponent(i)+e,t)}async function U(){let e=F.current,t=await H(`/analysis-queue`);e===F.current&&R(t)}async function W(e){if(I.current)return;I.current=!0,x(!0),C(``);let t=F.current;try{await e()}catch(e){t===F.current&&C(e.message)}finally{I.current=!1,x(!1)}}async function G(e,t,n={}){await H(`/analysis-queue`,{op:t,taskId:e.id,expectedVersion:e.version,inputHash:e.inputHash,...n}),t===`review`&&_(t=>({...t,[e.id]:``})),await U()}let K=M.autoloop&&M.trustedReview;return(0,y.jsxs)(`main`,{className:q.page,children:[(0,y.jsxs)(`header`,{className:q.heading,children:[(0,y.jsxs)(`h1`,{children:[`已存资料分析 · 发起、结果与审核`,(0,y.jsx)(h,{label:`分析范围`,children:`选择项目已有资料和目标商品。同页完成归属检查、任务发起、结果查看及人工反馈;未满足运行条件时只做本地检查。`})]}),(0,y.jsx)(`p`,{children:`原始资料不会因重复点击而重复派发;分析草稿不自动批准业务,也不操作店铺。`})]}),!e&&(0,y.jsxs)(`section`,{className:q.projectPicker,"aria-label":`选择项目`,children:[(0,y.jsxs)(`label`,{htmlFor:`archive-project`,children:[`项目名称`,(0,y.jsxs)(`select`,{id:`archive-project`,value:i,disabled:E||b,onChange:e=>z(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:E?`正在加载项目…`:`请选择项目`}),w.map(e=>(0,y.jsx)(`option`,{value:e.id,children:e.name||`未命名项目`},e.id))]})]}),(0,y.jsx)(`p`,{children:`切换项目前会提醒保存或放弃意见。只显示当前账号可访问的项目。`}),O&&(0,y.jsxs)(`div`,{role:`alert`,children:[(0,y.jsx)(`p`,{children:O}),(0,y.jsx)(`button`,{disabled:E,onClick:()=>{D(!0),k(``),B()},children:`重试项目列表`})]}),!E&&!O&&!w.length&&(0,y.jsx)(`p`,{role:`status`,children:`当前账号暂无项目,请先创建项目或确认登录账号。`})]}),A&&(0,y.jsx)(`p`,{role:`status`,children:`正在加载项目归档与任务…`}),S&&(0,y.jsxs)(`p`,{role:`alert`,className:q.error,children:[S,`。提交结果不明确时先刷新状态,避免重复操作。`]}),o&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`section`,{"aria-label":`运行条件`,className:q.notice,children:[(0,y.jsx)(`p`,{children:K?`本项目已绑定执行条件,可以同页发起分析。`:`当前可做归属与去重检查;完整自动分析尚未启用。`}),te.length>0&&(0,y.jsx)(`ul`,{children:te.map(e=>(0,y.jsx)(`li`,{children:J[e]||e},e))}),(0,y.jsx)(`p`,{children:`接通状态由服务端核实,不能通过在页面填写“已授权”绕过。`})]}),(0,y.jsxs)(`h2`,{children:[`选择归档并发起`,(0,y.jsx)(h,{label:`资料要求`,children:`需包含评价正文 text、商品 item_id、评价 review_id、唯一行标识 row_id。缺失项保持缺失,不能猜测。`})]}),(0,y.jsxs)(`label`,{children:[`已有归档`,(0,y.jsxs)(`select`,{value:u,disabled:b,onChange:e=>d(e.target.value),children:[(0,y.jsx)(`option`,{value:``,children:`请选择`}),c.map(e=>(0,y.jsx)(`option`,{value:e.id,children:e.title},e.id))]})]}),(0,y.jsxs)(`label`,{children:[`目标商品编号`,(0,y.jsx)(`input`,{value:f,disabled:b,onChange:e=>p(e.target.value)})]}),!c.length&&(0,y.jsx)(`p`,{role:`status`,children:`此项目暂无可用归档,请先在工作台导入资料。`}),(0,y.jsx)(`button`,{disabled:b||!u||!/^\d{1,30}$/.test(f),onClick:()=>void W(async()=>{await H(`/analysis-queue`,{op:`enqueue`,datasetId:u,targetItem:f,expectedProjectVersion:o.version,expectedSourceSha:c.find(e=>e.id===u)?.sha}),p(``),await U()}),children:b?`处理中…`:K?`一键发起归档分析`:`检查资料并建立任务`}),(0,y.jsx)(`button`,{disabled:b,onClick:()=>void W(U),children:`刷新执行状态`}),V&&(0,y.jsx)(`p`,{role:`status`,children:`本页每 5 秒刷新进行中的任务。投递不明时不会自动重发。`}),!m.length&&(0,y.jsx)(`p`,{role:`status`,children:`此项目暂无执行记录。`}),m.map(e=>(0,y.jsxs)(`section`,{style:{border:`1px solid var(--omni-line,#294248)`,padding:16,marginTop:16},children:[(0,y.jsx)(`h2`,{children:Y[e.state]||e.state}),(0,y.jsxs)(`p`,{children:[`任务 `,e.id,` · 版本 `,e.version??`旧记录`,` · 第 `,e.cycle??`未知`,` 轮 · 商品 `,e.targetItem??`未记录`]}),(0,y.jsxs)(`p`,{children:[`来源 `,e.datasetId??`旧记录未提供`,` · 输入标识 `,e.inputHash]}),e.schema!==`workbench-archive-task/v2`&&(0,y.jsx)(`p`,{children:`此记录使用旧协议,保留供查看。请重新选择归档发起新任务,不会自动迁移或执行。`}),e.steps?.map(e=>(0,y.jsxs)(`p`,{children:[e.name,`:`,ae[e.state]||e.state]},e.name)),e.lastError&&(0,y.jsx)(`p`,{role:`alert`,children:e.lastError}),(0,y.jsxs)(`details`,{children:[(0,y.jsx)(`summary`,{children:`查看归属与去重结果`}),(0,y.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,overflowWrap:`anywhere`},children:JSON.stringify(e.result??{message:`尚无结果`},null,2)})]}),e.analysis?.result&&(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`h3`,{children:`内容分析草稿 · 未经人工核验`}),(0,y.jsx)(`p`,{children:e.analysis.result.summary}),(0,y.jsxs)(`details`,{open:!0,children:[(0,y.jsx)(`summary`,{children:`分析方法、逐行依据与缺失项`}),(0,y.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,overflowWrap:`anywhere`},children:JSON.stringify(e.analysis.result,null,2)})]})]}),e.dispatch?.state===`not_sent`&&(0,y.jsx)(`button`,{disabled:b||!K||e.schema!==`workbench-archive-task/v2`||e.state!==`waiting_human`,onClick:()=>void W(()=>G(e,`dispatch`)),children:`发起内容分析`}),(0,y.jsxs)(`label`,{children:[`人工核对意见`,(0,y.jsx)(`textarea`,{rows:3,value:g[e.id]||``,disabled:b,onChange:t=>_({...g,[e.id]:t.target.value})})]}),!M.trustedReview&&(0,y.jsx)(`p`,{children:`可信人工登录尚不可用,暂不能提交审核。输入的草稿仅保留在本页。`}),[[`reviewed`,`确认已审阅`],[`changes_requested`,`要求修改`],[`paused`,`暂缓`]].map(([t,n])=>(0,y.jsx)(`button`,{disabled:b||!M.trustedReview||!g[e.id]?.trim()||![`waiting_human`,`paused`,`feedback_pending`].includes(e.state)||[`reporting`,`unknown`].includes(e.notification?.state)||e.schema!==`workbench-archive-task/v2`,onClick:()=>void W(()=>G(e,`review`,{decision:t,note:g[e.id],humanConfirmed:!0})),children:n},t)),(0,y.jsx)(`p`,{children:`继续分析会绑定本次反馈并保留上一轮草稿。投递结果未知时须先核对中台。`}),(0,y.jsx)(`button`,{disabled:b||!M.trustedReview||![`feedback_pending`,`paused`,`failed`].includes(e.state)||[`unknown`,`dispatching`].includes(e.dispatch?.state)||[`unknown`,`reporting`].includes(e.notification?.state)||e.schema!==`workbench-archive-task/v2`,onClick:()=>void W(()=>G(e,`resume`)),children:K?`继续分析 / 重试`:`检查续办条件`}),(0,y.jsxs)(`details`,{children:[(0,y.jsx)(`summary`,{children:`历史草稿与人工反馈`}),(0,y.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,overflowWrap:`anywhere`},children:JSON.stringify({revisions:e.revisions||[],feedback:e.feedback||[],resumeAttempts:e.resumeAttempts||[]},null,2)})]})]},e.id))]})]})}function Z({section:e,project:t}){let{route:n,onRoute:r}=t,i=e=>r({center:!1,tab:`wiki`,wikiRef:e,wikiEntry:``}),a=(e,t=!1)=>r({center:!1,tab:`wiki`,wikiRef:``,wikiEntry:e},{confirmed:t}),o=e=>r({center:!1,tab:`data`,datasetId:e}),s=(e=``,t=``)=>r({center:!1,tab:`methods`,methodNode:t,methodRecord:e});return e===`archive`?(0,y.jsx)(oe,{initialProject:t.projectId,initialDataset:n.datasetId,onDirty:t.onDirty,onBusy:t.onBusy}):e===`data`?(0,y.jsx)(C,{...t,initialId:n.datasetId,onWiki:i,onArchive:e=>r({center:!1,tab:`archive`,datasetId:e}),onSelect:e=>r({datasetId:e},{replace:!0}),onPrepare:()=>r({center:!1,tab:`files`})},t.projectId+n.datasetId):e===`files`?(0,y.jsx)(T,{...t}):e===`wiki`?(0,y.jsx)(P,{...t,initialRef:n.wikiRef,initialEntry:n.wikiEntry,onMethods:s,onData:o},t.projectId+n.wikiRef+n.wikiEntry):e===`methods`?(0,y.jsx)(H,{...t,initialNode:n.methodNode,initialRecord:n.methodRecord,onWiki:a},t.projectId+n.methodNode+n.methodRecord):e===`insight`?(0,y.jsx)(re,{...t,onWikiEntry:a}):null}export{Z as default};
|