Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
ujia
/
uj-admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 4b4d68bb
authored
Nov 16, 2026
by
liimin
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
调整下载中心
1 parent
2b32d867
Hide whitespace changes
Inline
Side-by-side
Showing
57 changed files
with
2975 additions
and
295 deletions
apps/web/shell/src/layouts/BasicLayout.tsx
apps/web/shell/src/subapp-lifecycle.ts
apps/web/shell/src/theme/design.css
apps/web/subapps/finance/src/App.tsx
apps/web/subapps/points/DELIVERY.md
apps/web/subapps/points/out/.temp/wire-check.mjs
apps/web/subapps/points/src/App.tsx
apps/web/subapps/points/src/api/modules/points.ts
apps/web/subapps/points/src/features/shared/PageShell.tsx
apps/web/subapps/points/src/features/shared/navigate.ts
apps/web/subapps/points/src/index.css
apps/web/subapps/points/src/pages/OrderList/index.tsx
apps/web/subapps/points/src/pages/ScoreUsers/index.tsx
apps/web/subapps/points/src/pages/UserScoreDetail/index.tsx
apps/web/subapps/points/src/pages/UserScoreDetail/tools/RevokeDialog.tsx
apps/web/subapps/points/src/pages/WithdrawArrival/index.tsx
apps/web/subapps/points/src/pages/WithdrawBatch/index.tsx
apps/web/subapps/points/src/pages/WithdrawManage/WithdrawApprove.tsx
apps/web/subapps/points/src/pages/WithdrawManage/index.tsx
apps/web/subapps/points/src/routes.ts
apps/web/subapps/usedcar/package.json
apps/web/subapps/usedcar/src/App.tsx
apps/web/subapps/usedcar/src/api/modules/assessment.ts
apps/web/subapps/usedcar/src/api/modules/contract.ts
apps/web/subapps/usedcar/src/lib/ossUpload.ts
apps/web/subapps/usedcar/src/pages/Assessment/AssessmentDetail.tsx
apps/web/subapps/usedcar/src/pages/Assessment/EvaluatePage.tsx
apps/web/subapps/usedcar/src/pages/Assessment/assessment.css
apps/web/subapps/usedcar/src/pages/Assessment/index.tsx
apps/web/subapps/usedcar/src/pages/Dashboard/components/TrendChart.tsx
apps/web/subapps/usedcar/src/pages/Leads/LeadDetail.tsx
apps/web/subapps/usedcar/src/pages/Leads/navigate.ts
apps/web/subapps/usedcar/src/pages/Operation/ContractDetail.tsx
apps/web/subapps/usedcar/src/pages/Operation/ContractEdit.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/ContractTab.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/ImportContractModal.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineDetailModal.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineFormModal.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineTab.tsx
apps/web/subapps/usedcar/src/pages/Operation/components/tableConfig.tsx
apps/web/subapps/usedcar/src/pages/Operation/contractDetail.css
apps/web/subapps/usedcar/src/pages/Operation/contractDetailConfig.ts
docs/PORT_CONVERSION.md
packages/biz/src/components/PageShell/index.tsx
packages/contracts/src/download-center.ts
packages/download-center/src/DownloadCenterButton.tsx
packages/download-center/src/DownloadCenterProvider.tsx
packages/download-center/src/engine.ts
packages/download-center/src/handlers/asyncExport.ts
packages/platform-sdk/src/downloadCenter.ts
packages/typescript-config/glsk-oss-jssdk.d.ts
packages/typescript-config/react-app.json
packages/ui/src/components/Image/index.tsx
packages/ui/src/index.ts
packages/ui/src/styles/ui.css
pnpm-lock.yaml
pnpm-workspace.yaml
apps/web/shell/src/layouts/BasicLayout.tsx
View file @
4b4d68b
import { bus } from 'wujie';
import { PAGE_LEAVE_EVENT } from '@uj/contracts';
import { Layout, Avatar, Dropdown, Breadcrumb } from 'antd';
import { Layout, Avatar, Dropdown, Breadcrumb
, Tooltip
} from 'antd';
import { LogoutOutlined, UserOutlined } from '@ant-design/icons';
import { Suspense, useEffect, useMemo, useState } from 'react';
import { Outlet, useLocation, useNavigate } from 'react-router-dom';
...
...
@@ -67,6 +67,28 @@ fallbackGroups.forEach((g) =>
const GROUP_KEY_PREFIX = 'group:';
const groupKey = (group: string) => `${GROUP_KEY_PREFIX}${group}`;
/**
* 返回字形(自绘,不用 LeftOutlined):一大一小两条折线,一实一虚。
* 实的、大的 = 要回去的上一层;虚的、小的 = 正要离开的当前页。大小与深浅同时拉开,
* 是为了让它在 28px 的键面里仍读得出「往回一级」而不是「往左」——
* 等宽双折线(«)在这个字号会淡成一根线,单箭头又只说得出方向。
* 几何(20 格画布,折角 90°、两线都是 45° 斜率):
* 主线 顶点 (4.2,10),两臂各跨 5.6 → 墨迹高 11.2、宽 5.6
* 副线 顶点 (12.4,10),两臂各跨 3.4 → 墨迹高 6.8
* 两线之间空 2.6;总墨迹 x 4.2→15.8,中心正好压在 10 上(不偏右)
* hover 整对左移 2 格后仍在画布内,不会被裁
* 渲染 18×18(28px 键面里的光学尺寸):线宽主 1.9 / 副 1.6 → 约 1.71 / 1.44 物理像素,
* 主线压得住键面,副线靠浅不靠细到看不见。
*/
function BackGlyph() {
return (
<svg className="uj-back-glyph" viewBox="0 0 20 20" width="18" height="18" aria-hidden="true">
<path className="uj-back-trail" d="M15.8 6.6 12.4 10l3.4 3.4" />
<path className="uj-back-head" d="M9.8 4.4 4.2 10l5.6 5.6" />
</svg>
);
}
export default function BasicLayout() {
const navigate = useNavigate();
const location = useLocation();
...
...
@@ -161,6 +183,11 @@ export default function BasicLayout() {
const activeGroupName = currentGroup?.group ?? null;
const roleLabel = roleCodes.length ? roleCodes.join(' / ') : roleLabels[role];
// 返回:判据只有地址层级这一条 —— 比命中的菜单路径更深,就是二级页,回的那一级就是菜单路径。
// 代价写在 points 的 DELIVERY.md §2:详情地址必须挂在它自己的菜单页下面,
// 平铺在域根上的详情(/points/batch/1)这里认不出来,既没有返回也没有面包屑。
const backTo = selectedKey && location.pathname !== selectedKey ? selectedKey : '';
// 面包屑:分组 > 当前页;分组名与页题同名(如「工作台」)时只留一级,避免重复。
// 非菜单页(/profile)无分组,只显示 EXTRA_TITLES 登记的页题。
const crumbTitles = [
...
...
@@ -179,6 +206,22 @@ export default function BasicLayout() {
),
}));
// 返回键贴在面包屑左侧(判据见上面 backTo)。它不常驻占位:没有去处时槽位宽度收到 0,
// 有去处时用一段 180ms 的展开把面包屑推出去 —— 既不是一级页留一块空洞,
// 也不是详情页「啪」地跳位,位移本身被动画说清楚。
const backButton = (
<button
type="button"
className="uj-header-back"
aria-label={backTo ? `返回 ${current?.label ?? ''}` : undefined}
tabIndex={backTo ? 0 : -1}
onClick={() => navigate(backTo)}
>
<BackGlyph />
<span>返回</span>
</button>
);
// wujie:登出必须同时销毁所有子应用实例。只清本地令牌的话,重新登录时
// startApp(同名 + alive) 会复用带着上一个账号数据的 iframe(QueryClient 缓存、
// 权限点、会话派生状态全是旧的)。顺序与广播逻辑收口在 subapp-lifecycle.ts。
...
...
@@ -227,8 +270,15 @@ export default function BasicLayout() {
<Layout style={{ minWidth: 0 }}>
<Header className="uj-header">
{/* 左:面包屑(分组 > 当前页);折叠控制在侧栏底部 */}
<div className="uj-header-left">
{/* 左:返回(贴在面包屑左侧,收起时收到 0 宽)+ 面包屑(分组 > 当前页);折叠控制在侧栏底部 */}
<div className={`uj-header-left${backTo ? ' has-back' : ''}`}>
<span className="uj-header-back-slot">
{backTo ? (
<Tooltip title={`返回「${current?.label ?? ''}」`}>{backButton}</Tooltip>
) : (
backButton
)}
</span>
{crumbItems.length > 0 && <Breadcrumb className="uj-header-crumb" items={crumbItems} />}
</div>
...
...
apps/web/shell/src/subapp-lifecycle.ts
View file @
4b4d68b
...
...
@@ -3,6 +3,7 @@ import { busEvents } from '@uj/contracts';
import
{
collectRouteDefs
}
from
'./dynamic-subapps'
;
import
{
forgetReady
,
isReady
}
from
'./subapp-handshake'
;
import
{
destroyAppLocked
}
from
'./wujie-lifecycle'
;
import
{
stopDownloadCenter
}
from
'@uj/download-center'
;
import
{
useAppStore
}
from
'@/store/useAppStore'
;
import
{
auth
,
menu
as
menuApi
}
from
'@/api'
;
...
...
@@ -19,6 +20,10 @@ import { auth, menu as menuApi } from '@/api';
* 子应用绝不自己 clearToken():令牌与会话的真源在主壳,两边各自清会留下半吊子状态。
*/
export
async
function
logoutEverything
(
navigate
:
(
path
:
string
)
=>
void
):
Promise
<
void
>
{
// 必须在销毁子应用之前中止在途下载:ROP 通道的 postRop 闭包在子应用 iframe 里,
// 销毁后失效,正在轮询的任务会失败并被误报「导出失败」。先落 canceled 再销毁。
stopDownloadCenter
({
markCanceled
:
true
});
try
{
await
auth
.
logout
();
}
catch
{
...
...
apps/web/shell/src/theme/design.css
View file @
4b4d68b
...
...
@@ -990,10 +990,119 @@
.uj-header-left
{
display
:
flex
;
align-items
:
center
;
gap
:
8px
;
gap
:
0
;
/* 间距由返回槽自己带,收起时才是真的 0 */
white-space
:
nowrap
;
}
/* 折叠按钮已移入侧栏底部(.uj-fold-btn),Header 里不再有 .uj-header-fold。 */
/* 返回:贴在面包屑左侧 = 导航的位置;判据只有地址层级一条(见 BasicLayout 的 backTo)。
不常驻占位:没有去处时槽位宽 0,有去处时展开到 36(28 键 + 8 呼吸)。
位移交给宽度过渡 —— 面包屑是被「推」出去的,不是啪一下跳走的;
一级页也不会留下一块空洞。 */
.uj-header-back-slot
{
display
:
flex
;
flex
:
0
0
auto
;
width
:
0
;
overflow
:
hidden
;
visibility
:
hidden
;
/* 收起:宽度走完再隐藏,别让按钮在半宽处凭空消失 */
transition
:
width
0.18s
ease-out
,
visibility
0s
linear
0.18s
;
}
.uj-header-left.has-back
.uj-header-back-slot
{
/* 64 键面 + 8 呼吸 = 72。键面宽是算出来的,不是量的:
左右内边距 8+8 + 图标 18 + 图标与文字之间 4 + 「返回」两个全角字 13×2 = 64。 */
width
:
72px
;
visibility
:
visible
;
/* 展开:立刻可见,否则动画前半段是空的 */
transition
:
width
0.18s
ease-out
,
visibility
0s
;
}
.uj-header-back
{
flex
:
none
;
height
:
28px
;
margin-right
:
8px
;
padding
:
0
8px
;
display
:
flex
;
align-items
:
center
;
gap
:
4px
;
border
:
none
;
border-radius
:
var
(
--uj-radius-md
,
6px
);
background
:
transparent
;
color
:
var
(
--uj-text-2
,
#4a5568
);
font-size
:
var
(
--uj-font-sm
,
13px
);
white-space
:
nowrap
;
cursor
:
pointer
;
opacity
:
0
;
transform
:
translateX
(
6px
);
transition
:
opacity
0.14s
ease-out
,
transform
0.18s
ease-out
,
background-color
0.16s
ease-out
,
color
0.16s
ease-out
;
}
.uj-header-left.has-back
.uj-header-back
{
opacity
:
1
;
transform
:
none
;
}
.uj-header-back
:hover
{
background
:
var
(
--uj-surface-3
,
#f2f5fa
);
color
:
var
(
--uj-primary
,
#2b5ce6
);
}
.uj-header-back
:active
{
background
:
var
(
--uj-primary-soft
,
#eef3ff
);
color
:
var
(
--uj-primary-active
,
#1f49c4
);
}
.uj-header-back
:focus-visible
{
outline
:
2px
solid
var
(
--uj-primary
,
#2b5ce6
);
outline-offset
:
-1px
;
}
/* 字形(自绘一大一小双折线,路径几何见 BasicLayout 的 BackGlyph):
大且实 = 要回去的上一层,小且浅 = 正要离开的当前页 —— 深浅之外再拉开大小,
18px 下才不会糊成一根线。hover 时整对左移一档、浅的那条转实,
「让位给上一层」这个动作就是控件的含义。 */
.uj-back-glyph
.uj-back-head
,
.uj-back-glyph
.uj-back-trail
{
fill
:
none
;
stroke
:
currentColor
;
stroke-linecap
:
round
;
stroke-linejoin
:
round
;
transition
:
transform
0.18s
ease-out
,
opacity
0.18s
ease-out
;
}
.uj-back-glyph
.uj-back-head
{
stroke-width
:
1.9
;
}
.uj-back-glyph
.uj-back-trail
{
stroke-width
:
1.6
;
opacity
:
0.45
;
}
.uj-header-back
:hover
.uj-back-head
,
.uj-header-back
:hover
.uj-back-trail
{
transform
:
translateX
(
-2px
);
}
.uj-header-back
:hover
.uj-back-trail
{
opacity
:
0.85
;
}
@media
(
prefers-reduced-motion
:
reduce
)
{
.uj-back-glyph
.uj-back-head
,
.uj-back-glyph
.uj-back-trail
,
.uj-header-back-slot
,
.uj-header-left.has-back
.uj-header-back-slot
,
.uj-header-back
{
transition
:
none
;
}
.uj-header-back
{
opacity
:
1
;
transform
:
none
;
}
.uj-header-back
:hover
.uj-back-head
,
.uj-header-back
:hover
.uj-back-trail
{
transform
:
none
;
}
}
/* 面包屑:antd Breadcrumb 承载结构,这里只定字号(末级=页题,其余=分组) */
.uj-header-crumb
{
white-space
:
nowrap
;
...
...
@@ -1072,6 +1181,32 @@
background
:
#f2f4f9
!important
;
color
:
#2b5ce6
!important
;
}
/* 有进行中的下载任务时,图标本身静止,外圈一道细弧匀速旋转(标准「进行中」语义) */
.uj-header-icon-btn.uj-download-active
{
position
:
relative
;
}
.uj-header-icon-btn.uj-download-active
.anticon-download
{
color
:
#2b5ce6
;
}
.uj-header-icon-btn.uj-download-active
::before
{
content
:
''
;
position
:
absolute
;
inset
:
3px
;
border
:
2px
solid
transparent
;
border-top-color
:
#2b5ce6
;
border-radius
:
50%
;
animation
:
uj-download-spin
0.9s
linear
infinite
;
pointer-events
:
none
;
}
@keyframes
uj-download-spin
{
to
{
transform
:
rotate
(
360deg
);
}
}
/* 尊重系统「减少动态效果」偏好:不旋转,但保留蓝色状态色 */
@media
(
prefers-reduced-motion
:
reduce
)
{
.uj-header-icon-btn.uj-download-active
::before
{
animation
:
none
;
}
}
.uj-header-divider
{
width
:
1px
;
height
:
22px
;
...
...
apps/web/subapps/finance/src/App.tsx
View file @
4b4d68b
import { useEffect, useMemo, useState } from 'react';
import { busEvents } from '@uj/contracts';
import { SubAppProvider, readInitialPage, shortName, subappBus } from '@uj/platform-sdk';
import { busEvents, downloadChannelRop } from '@uj/contracts';
import {
SubAppProvider,
downloadCenter,
readInitialPage,
shortName,
subappBus,
} from '@uj/platform-sdk';
import { UEmpty } from '@uj/ui';
import { financeClient } from './api/core/client';
import Payment from './pages/Payment';
import type { PageParams, RouteDef } from './routes';
import { matchRoute } from './routes';
...
...
@@ -35,6 +42,12 @@ function FinanceApp() {
bus.$on(events.navigate, onNavigate);
bus.$on(events.logout, onLogout);
// 付款导出走 ROP 主网关;本子应用持有 ROP 凭据,注册为 rop 通道供下载引擎提交/轮询。
downloadCenter.registerChannel(downloadChannelRop(shortName()), (req) =>
financeClient.postRop(req.url, (req.data ?? {}) as Record<string, unknown>),
);
bus.$emit(events.ready);
return () => {
...
...
apps/web/subapps/points/DELIVERY.md
View file @
4b4d68b
...
...
@@ -29,18 +29,20 @@
主壳菜单只需要配三个入口,其余五条是页面内部跳转(
`goTo()`
),菜单不用配也不该配。
| 菜单 | 地址栏 | 页面 |
| ---------------------------------------- | --------------------------------------------------- | ---------------------------------------------- |
| 积分核销订单 |
`/points/list`
|
`pages/OrderList`
|
| ↳ 查看(抽屉) | 列表内抽屉,不跳路由 |
`pages/OrderList/components/OrderDetailDrawer`
|
| 用户积分明细 |
`/points/users`
|
`pages/ScoreUsers`
|
| ↳ 积分详情(阳光激励,按员工号) |
`/points/user/<channelSource>/<staffId>`
|
`pages/UserScoreDetail`
|
| ↳ 积分详情(续保/管理层,按门店+手机号) |
`/points/user/<channelSource>/<merchantId>/<phone>`
|
`pages/UserScoreDetail`
|
| 积分提现管理 |
`/points/withdraw`
|
`pages/WithdrawManage`
(两个 tab) |
| ↳ 编辑批次 |
`/points/batch/<id>`
|
`pages/WithdrawBatch`
|
| ↳ 到账明细 |
`/points/arrival/<id>`
|
`pages/WithdrawArrival`
|
同一个
`user`
前缀下两种参数长度共存,靠段数区分(
[
src/routes.ts:22-49
](
file:///D:/work/uj-admin/apps/web/subapps/points/src/routes.ts#L22-L49
)
)。
| 菜单 | 地址栏 | 页面 |
| ---------------------------------------- | ---------------------------------------------------- | ---------------------------------------------- |
| 积分核销订单 |
`/points/list`
|
`pages/OrderList`
|
| ↳ 查看(抽屉) | 列表内抽屉,不跳路由 |
`pages/OrderList/components/OrderDetailDrawer`
|
| 用户积分明细 |
`/points/users`
|
`pages/ScoreUsers`
|
| ↳ 积分详情(阳光激励,按员工号) |
`/points/users/<channelSource>/<staffId>`
|
`pages/UserScoreDetail`
|
| ↳ 积分详情(续保/管理层,按门店+手机号) |
`/points/users/<channelSource>/<merchantId>/<phone>`
|
`pages/UserScoreDetail`
|
| 积分提现管理 |
`/points/withdraw`
|
`pages/WithdrawManage`
(两个 tab) |
| ↳ 编辑批次 |
`/points/withdraw/batch/<id>`
|
`pages/WithdrawBatch`
|
| ↳ 到账明细 |
`/points/withdraw/arrival/<id>`
|
`pages/WithdrawArrival`
|
同一个
`users`
前缀下两种参数长度共存,靠段数区分(
[
src/routes.ts:22-49
](
file:///D:/work/uj-admin/apps/web/subapps/points/src/routes.ts#L22-L49
)
)。
详情地址必须挂在它自己的菜单页下面(
`users/…`
、
`withdraw/batch/…`
),不能平铺在域根上:主壳顶栏的「返回」只按地址层级判定二级页(更深一级 → 回的那一级就是菜单路径),平铺写法既拿不到返回,也拿不到面包屑与菜单高亮。
---
...
...
@@ -117,7 +119,7 @@
points 装配层(
`adapter/rpc.ts`
)因此
**不**
声明 content-type —— 编码是网关事实,只在
`prepareRpcCall`
说一次;在这一层再写一次就成了两个真源,而两个真源迟早会不一致(不一致的后果就是上面那个 22)。
5.
**`usedCarFlag=1` 是这个系统的数据身份,不是筛选条件。**
后端把它加在 13 个接口的请求体上(
`StaffScoreRopRequest`
/
`IntegralOrderPageRequest`
/
`IntegralTransferOutPageRequest`
三组,同组的导出、金额合计、一键操作校验各自复用),传
`1`
= 只返回二手车展业门店数据、不传 = 原逻辑查全部。本系统只服务二手车,所以口径定成
**一律传 1**
:字段名与取值只在
[
api/core/usedCarScope.ts
](
file:///D:/work/uj-admin/apps/web/subapps/points/src/api/core/usedCarScope.ts
)
定义一次,由唯一的请求出口
[
api/core/rpc-client.ts
](
file:///D:/work/uj-admin/apps/web/subapps/points/src/api/core/rpc-client.ts
)
在
`rpc()`
里注入并覆盖。带来的三个后果都是刻意的:
-
页面上没有「门店范围」下拉了 —— 一个改了也不改变结果的控件比没有控件更坏;三屏的字段表与表单初值里都不再出现这个字段。
-
详情地址少一段:
`/points/
user/<channelSource>/<staffId>`
与
`/points/
user/<channelSource>/<merchantId>/<phone>`
。范围不再随地址流动,因为它不随任何人变。
-
详情地址少一段:
`/points/
users/<channelSource>/<staffId>`
与
`/points/u
sers/<channelSource>/<merchantId>/<phone>`
。范围不再随地址流动,因为它不随任何人变。
-
覆盖范围按出口算,不按清单算:
`wire-check.mjs`
⑩ 逐个复算
**53 个已登记方法**
(需求点名的 13 个只是其中的子集),新接一个接口不需要登记条件就一定带 —— 漏不掉,也不需要谁记得。
将来若真要同域共存第二套部署(非二手车),改的是这个常量与注入点,而不是往页面里加回控件。
6.
**数组与嵌套对象在请求出口摊平,签名原文与请求体是同一份字节。**
`ids: [214, 213, 212]`
→
`ids[0]=214&ids[1]=213&ids[2]=212`
,嵌套对象 →
`a.b`
,
`null`
→ 空串,
`undefined`
和空数组连键都不出现。规则逐字对齐老系统
`glsx-common/src/util.js#createSign`
里的
`qs.stringify({ arrayFormat: 'indices', allowDots: true, encodeValuesOnly: true })`
,实现只有一处:
`packages/api-core/src/gateway/dispatcher.ts`
的
`flattenFormParams`
,在
`prepareRpcCall`
合并完
`fixedParams`
/ 业务参数 / 会话号之后、加签之前跑一次。web 与小程序共用这条组装,所以 points、mp/points、mp/sales 的数组入参一起被修正。
...
...
@@ -214,7 +216,7 @@ points 摮瓷 bypass 閫
7.
**审批状态字典合一份**
:老系统筛选用
`statusList`
、列渲染用
`tableStatus`
,两份文案一致 → 合并成一份
`APPROVAL_STATUS`
;到账明细页复用 9 项的
`TRANSFER_STATUS`
,0-6 项文案与老系统那 7 项逐字相同。
8.
**提现导入的表头校验交给后端**
:老页面在前端解析 xlsx 比对 10 个固定列名(从 A9 起)。本子应用依赖里没有 xlsx,加它要改工作区外的
`pnpm-workspace.yaml`
,属于 6.1 之外的越界;文件不合规时导入接口回
`errorUrl`
,弹窗按失败态给可下载模版。要恢复前端预校验 = 允许装
`xlsx`
依赖。
9.
**「受理失败」的颜色不按老系统照抄**
:老系统把这一项涂成绿色,是那一行复制粘贴抄错了;现在按语义给红(
`dictionaries.ts:78`
已注明)。
10.
**详情地
址就是老系统那两段,不多一段**
:
`user/<channelSource>/<staffId>`
与
`user/<channelSource>/<merchantId>/<phone>`
。中途曾经末尾补过一段
`all`
/
`1`
(
`usedCarFlag`
),用来让流水与顶部四张卡跟着列表页的范围走;范围改成系统级恒定值之后,这一段没有任何信息量,已经删
干净。留下的兼容性问题只有一种:改造期间发出去的旧链接(带末段)。它们的下场是「接不住」而不是「查错人」—— 四段形制会被读成「门店+手机号」那一类、因缺标识落到「缺少用户标识」提示,五段形制匹配不到任何路由(离线核对 ⑥⑦⑧ 三组断言钉住)。
10.
**详情地
址末尾不多一段、首段是它自己的菜单页**
:
`users/<channelSource>/<staffId>`
与
`users/<channelSource>/<merchantId>/<phone>`
。中途曾经末尾补过一段
`all`
/
`1`
(
`usedCarFlag`
),用来让流水与顶部四张卡跟着列表页的范围走;范围改成系统级恒定值之后,这一段没有任何信息量,已经删干净。首段
`users`
/
`withdraw`
是后来加上去的,加它不是为了参数,而是顶栏「返回」只按地址层级判定二级页(见 §
2)。留下的兼容性问题只有一种:改造期间发出去的旧链接。它们的下场是「接不住」而不是「查错人」—— 带范围末段的四段形制会被读成「门店+手机号」那一类、因缺标识落到「缺少用户标识」提示,五段形制匹配不到任何路由;改名前那批不带
`users`
首段的地址(
`user/1/9`
)整条不命中,落到「没有匹配「…」的页面,请从菜单进入」(离线核对 ⑥⑦⑧ 三组断言钉住)。
11.
**批量被拦时点名到哪几条**
:老系统只说「请选择待审核的提现记录」(付款是「请选择已审核或受理失败的提现记录」,驳回是「请选择能够驳回的提现记录」,三句三个说法),后端只回一个
`canApprove:false`
,所以勾选的行里到底是哪几条不合格,人得自己对状态列。现在四个入口共用一张状态表,被拦时给
`214(驳回) 不是待审核状态`
(超过 8 条列前 8 条并给总数),文案里的状态名与判定集合同源,见 §4 第 7 条与闸门 ⑱。判定权仍在后端 —— 页面只是把它的结论翻译到人能看的粒度,没有前端拦下后端允许的操作。
---
...
...
apps/web/subapps/points/out/.temp/wire-check.mjs
View file @
4b4d68b
...
...
@@ -168,17 +168,18 @@ try {
await check('⑦ 列表拼出的详情地址,详情页接得住,地址里只剩「哪一个人」', () => {
const usersSrc = readFileSync('src/pages/ScoreUsers/index.tsx', 'utf8');
assert.match(usersSrc, /`user\/1\/\$\{encodeURIComponent\(row\.staffId\)\}`/);
// 详情地址挂在菜单页 users 下面:顶栏的「返回」只按地址层级判定二级页。
assert.match(usersSrc, /`users\/1\/\$\{encodeURIComponent\(row\.staffId\)\}`/);
assert.match(
usersSrc,
/`user\/\$\{channelSource\}\/\$\{encodeURIComponent\(\s*row\.merchantId,?\s*\)\}\/\$\{encodeURIComponent\(\s*row\.staffPhone,?\s*\)\}`,?/,
/`user
s
\/\$\{channelSource\}\/\$\{encodeURIComponent\(\s*row\.merchantId,?\s*\)\}\/\$\{encodeURIComponent\(\s*row\.staffPhone,?\s*\)\}`,?/,
);
const sunshine = matchRoute(ROUTES, 'user/1/9');
const sunshine = matchRoute(ROUTES, 'user
s
/1/9');
assert.equal(sunshine?.params.staffId, '9');
assert.equal(sunshine?.params.usedCarFlag, undefined, '地址里不该再有范围段');
const renewal = matchRoute(ROUTES, 'user/2/7001/13800000000');
const renewal = matchRoute(ROUTES, 'user
s
/2/7001/13800000000');
assert.deepEqual(renewal?.params, {
channelSource: '2',
merchantId: '7001',
...
...
@@ -187,13 +188,17 @@ try {
});
await check('⑧ 改造前的旧地址(带范围末段)只会「接不住」,不会静默查错人', () => {
// 旧四段 user/1/<staffId>/<scope> 如今会落到「门店+手机号」那条路由上:
// 旧四段 user
s
/1/<staffId>/<scope> 如今会落到「门店+手机号」那条路由上:
// 阳光激励渠道要求 staffId 定位,缺了就查不出人,页面走「标识不全」而不是拿 9/1 当门店手机号去查别人。
const stale = matchRoute(ROUTES, 'user/1/9/1');
const stale = matchRoute(ROUTES, 'user
s
/1/9/1');
assert.equal(stale?.params.channelSource, '1');
assert.equal(stale?.params.staffId, undefined);
// 旧五段(续保/管理层 + 范围)没有对应路由:整条地址不命中,提示页而非查到错的人。
assert.equal(matchRoute(ROUTES, 'user/2/7001/13800000000/1'), undefined);
assert.equal(matchRoute(ROUTES, 'users/2/7001/13800000000/1'), undefined);
// 二级页规范化之前那批不带 users 前缀的地址(user/1/9)同样整条不命中:
// 落到「没有匹配「…」的页面,请从菜单进入」,不会出现拿旧地址查错人。
assert.equal(matchRoute(ROUTES, 'user/1/9'), undefined);
assert.equal(matchRoute(ROUTES, 'user/2/7001/13800000000'), undefined);
});
const apiSrc = ['src/api/modules/points.ts', 'src/api/modules/withdraw.ts']
...
...
apps/web/subapps/points/src/App.tsx
View file @
4b4d68b
...
...
@@ -14,15 +14,18 @@ import { UEmpty } from '@uj/ui';
/**
* 页面表:主壳给的 subPath(形如 order/123)在这里换成组件与路径参数。
* 新增页面 = 加一行 + 建一个页面目录;地址栏规则只在 routes.ts 里描述一次。
*
* 详情行的地址必须挂在它自己的菜单页下面(`users/…`、`withdraw/batch/…`),
* 顶栏才认得出「这是二级页」并给出返回 —— 判据只有地址层级这一条,见主壳 BasicLayout。
*/
const ROUTES: RouteDef[] = [
{ path: 'list', Page: OrderList },
{ path: 'users', Page: ScoreUsers },
{ path: 'user/:channelSource/:staffId', Page: UserScoreDetail },
{ path: 'user/:channelSource/:merchantId/:phone', Page: UserScoreDetail },
{ path: 'user
s
/:channelSource/:staffId', Page: UserScoreDetail },
{ path: 'user
s
/:channelSource/:merchantId/:phone', Page: UserScoreDetail },
{ path: 'withdraw', Page: WithdrawManage },
{ path: 'batch/:id', Page: WithdrawBatch },
{ path: 'arrival/:id', Page: WithdrawArrival },
{ path: '
withdraw/
batch/:id', Page: WithdrawBatch },
{ path: '
withdraw/
arrival/:id', Page: WithdrawArrival },
];
function renderPage(subPath: string) {
...
...
apps/web/subapps/points/src/api/modules/points.ts
View file @
4b4d68b
...
...
@@ -112,6 +112,23 @@ class PointsApi extends RpcApiClient {
params
,
);
}
/**
* 撤销抵扣前先取流水详情拿 orderCode(源 point.js getScoreDetail / dj.api.smartcarlife.staff.score.detail)。
* 走 dj-smartcarlife 网关,与撤销方法同源。
*/
scoreDetail
(
id
:
string
)
{
return
this
.
rpc
<
{
id
?:
string
;
orderCode
?:
string
;
[
key
:
string
]:
unknown
}
>
(
'dj-smartcarlife'
,
'dj.api.smartcarlife.staff.score.detail'
,
{
id
},
);
}
/** 撤销抵扣(源 point.js cancelDeduct / dj.api.smartcarlife.staff.score.cancel.deduct)。 */
cancelDeduct
(
params
:
{
scoreId
:
string
;
remark
?:
string
;
orderCode
?:
string
})
{
return
this
.
rpc
<
unknown
>
(
'dj-smartcarlife'
,
'dj.api.smartcarlife.staff.score.cancel.deduct'
,
params
);
}
}
export
const
pointsApi
=
new
PointsApi
();
apps/web/subapps/points/src/features/shared/PageShell.tsx
deleted
100644 → 0
View file @
2b32d86
import type { ReactNode } from 'react';
import { PageShell as SharedPageShell } from '@/components';
import { goTo } from './navigate';
interface PageShellProps {
title: string;
/** 一句说明这个页面能做什么;写业务动作,不写字段名。 */
description?: ReactNode;
/** 子页面用:返回目标路径(相对本子应用),老系统的每个详情页都有退回入口。 */
back?: string;
actions?: ReactNode;
/** 列表页:整屏定高、表体内滚、分页贴底。 */
fill?: boolean;
children: ReactNode;
}
/**
* points 的页面外壳:共享层的薄封装,只多了「返回目标是一个相对路径」这一件本子应用的事。
* 布局、标题层级、间距全部由 @uj/biz 的 PageShell 承担 —— 三个子应用共用一份,
* 这样 system / store 接过来的时候不会长出第二套字号。
*/
export function PageShell({ back, children, ...rest }: PageShellProps) {
return (
<SharedPageShell {...rest} onBack={back ? () => goTo(back) : undefined}>
{children}
</SharedPageShell>
);
}
apps/web/subapps/points/src/features/shared/navigate.ts
View file @
4b4d68b
export
{
goTo
}
from
'@uj/platform-sdk'
;
import
{
goTo
}
from
'@uj/platform-sdk'
;
/**
* 子应用内部跳转的真源已收编到 platform-sdk 的 `goTo`
* (页面切换真源在主壳地址栏:相对路径拼成 `/<应用名>/<路径>` 交给主壳)。
*
本文件只保留积分域的固定落点
。
*
「返回上一级」不在这里:那是顶栏的职责,见主壳 BasicLayout 的二级页判定
。
*/
/** 回到某个菜单首屏。 */
export
const
goList
=
(
menu
:
'list'
|
'users'
|
'withdraw'
)
=>
goTo
(
menu
);
export
{
goTo
}
from
'@uj/platform-sdk'
;
apps/web/subapps/points/src/index.css
View file @
4b4d68b
...
...
@@ -2,23 +2,8 @@
tokens.css 由 main.tsx 引入;根节点带 .uj-scope 让令牌在 shadowRoot 内有本地落点,
不依赖「自定义属性恰好能穿透 shadow DOM」这个侥幸。 */
/* 根因修复:iframe 的 html/body 必须定高,否则下方 .uj-points-app 的 height:100%
会回退成「内容高度」,导致 body 实际溢出。
溢出后 antd 抽屉打开时,rc-util 的滚动锁(useScrollLocker)检测到 body 溢出,
会给 `html body` 注入 `width: calc(100% - 滚动条宽px)` 来补偿被隐藏的滚动条 ——
可本应用滚动收在 .uj-points-app(overflow:auto)里、body 本身并不滚动,
这条补偿只会把整页宽度收窄,造成「打开抽屉整页左移、关闭复原」的抖动。
定高后 body 不再溢出,滚动锁不再注入该宽度补偿,抖动从源头消失。 */
html
,
body
{
height
:
100%
;
}
/* 兜底:万一某些长页面仍让 body 溢出(极端内容/未走 .uj-points-app 的入口),
直接强制 body 满宽,彻底消除左移,且不影响 .uj-points-app 内部自身的滚动。 */
html
body
{
width
:
100%
!important
;
}
/* 「打开抽屉整页左移」的根因与修法已收进 @uj/ui 的 styles/ui.css(弹层滚动锁一节):
body 定高链 + 压掉 ScrollLocker 注入的 width 补偿,两处都在共享层,这里不再重复一份。 */
.uj-points-app
{
/* height(而非 min-height):列表页要靠这条定高链路把剩余空间量出来。
...
...
apps/web/subapps/points/src/pages/OrderList/index.tsx
View file @
4b4d68b
...
...
@@ -3,6 +3,7 @@ import { useMutation } from '@tanstack/react-query';
import { UAlert, UButton, UCard, UResult, UUpload, useUMessage } from '@uj/ui';
import {
DataTable,
PageShell,
SearchForm,
type ActionSchema,
type FieldSchema,
...
...
@@ -15,7 +16,6 @@ import { SETTLE_STATUS, withAll } from '@/features/shared/dictionaries';
import { compactParams, errorMessage, expandDateRanges } from '@/features/shared/format';
import { isExcel, readLegacyFile, sizeError } from '@/features/shared/files';
import { firstPage, useExport, useList, usePageClamp, useRefresh } from '@/features/shared/queries';
import { PageShell } from '@/features/shared/PageShell';
import { useConfirmAction } from '@/features/shared/useConfirmAction';
import { buildOrderColumns } from './tools/columns';
import { OrderDetailDrawer } from './components/OrderDetailDrawer';
...
...
apps/web/subapps/points/src/pages/ScoreUsers/index.tsx
View file @
4b4d68b
...
...
@@ -2,6 +2,7 @@ import { useMemo, useState } from 'react';
import { UAlert, UButton, UCard, UResult, UTabs, tabLabel } from '@uj/ui';
import {
DataTable,
PageShell,
SearchForm,
type ActionSchema,
type FieldSchema,
...
...
@@ -14,7 +15,6 @@ import { SCORE_TABS, withAll } from '@/features/shared/dictionaries';
import { compactParams, expandDateRanges } from '@/features/shared/format';
import { firstPage, useExport, useLists, usePageClamp } from '@/features/shared/queries';
import { useShopMerchants } from '@/features/shared/options';
import { PageShell } from '@/features/shared/PageShell';
import { goTo } from '@/features/shared/navigate';
import { buildStaffScoreColumns } from './tools/columns';
...
...
@@ -40,10 +40,10 @@ const DATE_RANGES = [
*/
function detailPath(row: StaffScoreRow, channelSource: string): string | undefined {
if (channelSource === '1') {
return row.staffId ? `user/1/${encodeURIComponent(row.staffId)}` : undefined;
return row.staffId ? `user
s
/1/${encodeURIComponent(row.staffId)}` : undefined;
}
if (!row.merchantId || !row.staffPhone) return undefined;
return `user/${channelSource}/${encodeURIComponent(row.merchantId)}/${encodeURIComponent(
return `user
s
/${channelSource}/${encodeURIComponent(row.merchantId)}/${encodeURIComponent(
row.staffPhone,
)}`;
}
...
...
apps/web/subapps/points/src/pages/UserScoreDetail/index.tsx
View file @
4b4d68b
...
...
@@ -3,6 +3,7 @@ import { useQuery } from '@tanstack/react-query';
import { UAlert, UButton, UCard, UResult } from '@uj/ui';
import {
DataTable,
PageShell,
SearchForm,
type ActionSchema,
type FieldSchema,
...
...
@@ -14,7 +15,6 @@ import { usePointsAccess } from '@/features/shared/access';
import { canRevokeScore, scoreInfoNameOptions } from '@/features/shared/dictionaries';
import { compactParams, expandDateRanges, numberOr, textOr } from '@/features/shared/format';
import { firstPage, useExport, useList, usePageClamp } from '@/features/shared/queries';
import { PageShell } from '@/features/shared/PageShell';
import type { PageParams } from '@/routes';
import { buildScoreDetailColumns } from './tools/columns';
import { RevokeDialog } from './tools/RevokeDialog';
...
...
@@ -131,7 +131,6 @@ export default function UserScoreDetail({ params }: { params: PageParams }) {
fill
title="积分详情"
description="这一位用户的积分流水;可按积分类型与变化时间筛选,也可导出全部记录。"
back="users"
>
<div className="uj-points-statistics">
{cards.map((card) => (
...
...
@@ -190,7 +189,12 @@ export default function UserScoreDetail({ params }: { params: PageParams }) {
}}
/>
</UCard>
<RevokeDialog open={!!revokeRow} record={revokeRow} onClose={() => setRevokeRow(undefined)} />
<RevokeDialog
open={!!revokeRow}
record={revokeRow}
onClose={() => setRevokeRow(undefined)}
onSuccess={() => void list.query.refetch()}
/>
</PageShell>
);
}
apps/web/subapps/points/src/pages/UserScoreDetail/tools/RevokeDialog.tsx
View file @
4b4d68b
import { useState } from 'react';
import { useMutation } from '@tanstack/react-query';
import { UForm, UInput, UText, useUMessage } from '@uj/ui';
import { ConfirmModal } from '@/components';
import type { ScoreDetailRow } from '@/api';
import { pointsApi, type ScoreDetailRow } from '@/api';
import { errorDetail } from '@/utils/error';
interface RevokeDialogProps {
open: boolean;
record?: ScoreDetailRow;
onClose: () => void;
/** 撤销成功后刷新流水列表。 */
onSuccess: () => void;
}
/**
* 撤销抵扣弹窗:字段、字数上限与「非必填」都照
老系统
revocationDialog.vue。
* 撤销抵扣弹窗:字段、字数上限与「非必填」都照
源
revocationDialog.vue。
*
*
老系统的提交逻辑整段是注释状态,它要调的 cancelDeduct / getScoreDetail 两个接口
*
在本仓库的 api 层根本不存在,也就是说这个入口从来没有真正撤销过任何东西。
*
平移要求「有弹窗就要有弹窗」,因此界面与入口都保留,但确定时如实告知没有提交,
*
不做假成功提示,也不伪造一个后端没有的接口。等后端补齐再在这里接上
。
*
提交流程与源一致(revocationDialog.vue:77-91):
*
1) scoreDetail(id) 取 orderCode;
*
2) cancelDeduct({ scoreId: id, orderCode, remark });
*
两个 RPC method 走 dj-smartcarlife 网关,见 api/modules/points.ts
。
*/
export function RevokeDialog({ open, record, onClose }: RevokeDialogProps) {
export function RevokeDialog({ open, record, onClose
, onSuccess
}: RevokeDialogProps) {
const message = useUMessage();
const [remark, setRemark] = useState('');
const revoke = useMutation({
mutationFn: async (scoreId: string) => {
const detail = await pointsApi.scoreDetail(scoreId);
return pointsApi.cancelDeduct({ scoreId, orderCode: detail.orderCode, remark });
},
onSuccess: () => {
message.success('操作成功');
setRemark('');
onClose();
onSuccess();
},
onError: (error) => message.error(errorDetail(error)),
});
const resetAndClose = () => {
setRemark('');
onClose();
};
return (
<ConfirmModal
open={open}
...
...
@@ -42,14 +65,11 @@ export function RevokeDialog({ open, record, onClose }: RevokeDialogProps) {
</UText>
</UForm>
}
onCancel={() => {
setRemark('');
onClose();
}}
confirmLoading={revoke.isPending}
onCancel={resetAndClose}
onConfirm={() => {
setRemark('');
void message.warning('撤销未提交:老系统的撤销接口未开放,请先联系后端确认');
onClose();
if (record?.id) revoke.mutate(record.id);
else message.warning('该流水缺少记录 id,无法撤销');
}}
/>
);
...
...
apps/web/subapps/points/src/pages/WithdrawArrival/index.tsx
View file @
4b4d68b
import { useMemo, useState } from 'react';
import { useMutation } from '@tanstack/react-query';
import { UAlert, UButton, UCard, UResult } from '@uj/ui';
import { DataTable, SearchForm, type RowActionSchema } from '@/components';
import { DataTable,
PageShell,
SearchForm, type RowActionSchema } from '@/components';
import { withdrawApi, type WithdrawRow } from '@/api';
import { PP } from '@/permissions/codes';
import { usePointsAccess } from '@/features/shared/access';
...
...
@@ -13,7 +13,6 @@ import {
usePageClamp,
useRefresh,
} from '@/features/shared/queries';
import { PageShell } from '@/features/shared/PageShell';
import {
APPROVAL_TRANSFER_FIELDS,
buildApprovalTransferColumns,
...
...
@@ -87,7 +86,6 @@ export default function WithdrawArrival({ params }: { params: PageParams }) {
fill
title="到账明细"
description="这一个批次逐笔提现的到账情况;受理失败的记录可以重新发起打款。"
back="withdraw"
>
<UCard className="uj-filter-card" size="small">
<SearchForm
...
...
apps/web/subapps/points/src/pages/WithdrawBatch/index.tsx
View file @
4b4d68b
import { useEffect, useMemo, useRef, useState } from 'react';
import { UAlert, UButton, UCard, UResult, useUMessage } from '@uj/ui';
import { DataTable, SearchForm, type RowActionSchema } from '@/components';
import { DataTable,
PageShell,
SearchForm, type RowActionSchema } from '@/components';
import { withdrawApi, type WithdrawRow } from '@/api';
import { PP } from '@/permissions/codes';
import { usePointsAccess } from '@/features/shared/access';
...
...
@@ -8,7 +8,6 @@ import { compactParams } from '@/features/shared/format';
import { firstPage, useList, usePageClamp, useRefresh } from '@/features/shared/queries';
import { useConfirmAction } from '@/features/shared/useConfirmAction';
import { goTo } from '@/features/shared/navigate';
import { PageShell } from '@/features/shared/PageShell';
import {
APPROVAL_TRANSFER_FIELDS,
buildApprovalTransferColumns,
...
...
@@ -97,7 +96,6 @@ export default function WithdrawBatch({ params }: { params: PageParams }) {
fill
title="编辑批次"
description="这一个提现批次里的提现记录;解散整批或移出单条,被移出的记录会回到待审核。"
back="withdraw"
actions={
can(PP.APPROVAL_DISBAND) ? (
<UButton
...
...
apps/web/subapps/points/src/pages/WithdrawManage/WithdrawApprove.tsx
View file @
4b4d68b
...
...
@@ -68,7 +68,7 @@ export default function WithdrawApprove() {
{
label: '编辑',
visible: (row) => EDITABLE.has(String(row.status ?? '')),
onClick: (row) => goTo(`batch/${row.id}`),
onClick: (row) => goTo(`
withdraw/
batch/${row.id}`),
},
{
label: '付款审批',
...
...
@@ -78,7 +78,7 @@ export default function WithdrawApprove() {
{
label: '到账明细',
visible: (row) => ARRIVED.has(String(row.status ?? '')),
onClick: (row) => goTo(`arrival/${row.id}`),
onClick: (row) => goTo(`
withdraw/
arrival/${row.id}`),
},
{
label: '导出',
...
...
apps/web/subapps/points/src/pages/WithdrawManage/index.tsx
View file @
4b4d68b
import { useState } from 'react';
import { UTabs } from '@uj/ui';
import { PageShell } from '@/
features/shared/PageShell
';
import { PageShell } from '@/
components
';
import WithdrawList from './WithdrawList';
import WithdrawApprove from './WithdrawApprove';
...
...
apps/web/subapps/points/src/routes.ts
View file @
4b4d68b
...
...
@@ -15,8 +15,8 @@ export interface MatchedRoute {
}
/**
* 按段匹配:段数不等的路径互不干扰(`user/:channelSource/:staffId` 三段、
* `user/:channelSource/:merchantId/:phone` 四段),因此同一前缀下的长短路径可以共存。
* 按段匹配:段数不等的路径互不干扰(`user
s
/:channelSource/:staffId` 三段、
* `user
s
/:channelSource/:merchantId/:phone` 四段),因此同一前缀下的长短路径可以共存。
* 参数值做 decodeURIComponent,手机号与门店编号里不会有需要转义的字符,但保持成对。
*/
export
function
matchRoute
(
routes
:
RouteDef
[],
subPath
:
string
):
MatchedRoute
|
undefined
{
...
...
apps/web/subapps/usedcar/package.json
View file @
4b4d68b
...
...
@@ -21,6 +21,7 @@
"@tanstack/react-query"
:
"catalog:"
,
"antd"
:
"catalog:"
,
"dayjs"
:
"catalog:"
,
"glsk-oss-jssdk"
:
"catalog:"
,
"react"
:
"catalog:"
,
"react-dom"
:
"catalog:"
,
"react-router-dom"
:
"catalog:"
...
...
apps/web/subapps/usedcar/src/App.tsx
View file @
4b4d68b
import { useEffect, useMemo, useState } from 'react';
import { busEvents } from '@uj/contracts';
import { SubAppProvider, readInitialPage, shortName, subappBus } from '@uj/platform-sdk';
import { busEvents, downloadChannelRop } from '@uj/contracts';
import {
SubAppProvider,
downloadCenter,
readInitialPage,
shortName,
subappBus,
} from '@uj/platform-sdk';
import { UEmpty } from '@uj/ui';
import { usedcarClient } from './api/core/client';
import Dashboard from './pages/Dashboard';
import Leads from './pages/Leads';
import LeadDetail from './pages/Leads/LeadDetail';
import Assessment from './pages/Assessment';
import AssessmentDetail from './pages/Assessment/AssessmentDetail';
import EvaluatePage from './pages/Assessment/EvaluatePage';
import Operation from './pages/Operation';
import ContractDetail from './pages/Operation/ContractDetail';
import ContractEdit from './pages/Operation/ContractEdit';
import Vehicles from './pages/Vehicles';
import Delivery from './pages/Delivery';
import Ledger from './pages/Ledger';
...
...
@@ -30,7 +40,10 @@ const ROUTES: RouteDef[] = [
{ path: 'leads/:id', Page: LeadDetail },
{ path: 'assessment', Page: Assessment },
{ path: 'assessment/:evalOrderNo', Page: AssessmentDetail },
{ path: 'assessment/evaluate/:scene/:evalOrderNo', Page: EvaluatePage },
{ path: 'operation', Page: Operation },
{ path: 'operation/contract/:id', Page: ContractDetail },
{ path: 'operation/contract-edit/:id/:contractNo', Page: ContractEdit },
{ path: 'vehicles', Page: Vehicles },
{ path: 'delivery', Page: Delivery },
{ path: 'ledger', Page: Ledger },
...
...
@@ -62,6 +75,14 @@ function UsedcarApp() {
bus.$on(events.navigate, onNavigate);
bus.$on(events.logout, onLogout);
// 异步导出的编排接口(dj.api.common.*)走 ROP 主网关。ROP 凭据/客户端在本子应用,
// 下载引擎在主壳——把 postRop 适配成 RemoteRequestFn 注册为 rop 通道。
// url 即 ROP method 名,data 即业务参数,与 postRop(method, data) 一一对应。
downloadCenter.registerChannel(downloadChannelRop(shortName()), (req) =>
usedcarClient.postRop(req.url, (req.data ?? {}) as Record<string, unknown>),
);
bus.$emit(events.ready);
return () => {
...
...
apps/web/subapps/usedcar/src/api/modules/assessment.ts
View file @
4b4d68b
import
{
ApiClient
}
from
'../core/client'
;
export
interface
AssessmentRow
{
id
:
string
|
number
;
evalOrderNo
?:
string
;
coverImage
?:
string
;
licensePlate
?:
string
;
vin
?:
string
;
carBrand
?:
string
;
carSeriesName
?:
string
;
carTypeName
?:
string
;
registrationDate
?:
string
;
registrationProvinceName
?:
string
;
registrationCityName
?:
string
;
sellerMerchantName
?:
string
;
sellerName
?:
string
;
conversionName
?:
string
;
buyNewCar
?:
number
;
hasAccident
?:
number
;
status
?:
number
|
string
;
previousOwnerName
?:
string
;
previousOwnerPhone
?:
string
;
evalOrderTime
?:
string
;
evalOperatorName
?:
string
;
source
?:
string
;
contractOrg
?:
string
;
showEvalBtn
?:
boolean
;
showCheckPriceBtn
?:
boolean
;
}
export
interface
AssessmentRow
{
id
:
string
|
number
;
evalOrderNo
?:
string
;
coverImage
?:
string
;
licensePlate
?:
string
;
vin
?:
string
;
carBrand
?:
string
;
carSeriesName
?:
string
;
carTypeName
?:
string
;
registrationDate
?:
string
;
registrationProvinceName
?:
string
;
registrationCityName
?:
string
;
sellerMerchantName
?:
string
;
sellerName
?:
string
;
conversionName
?:
string
;
buyNewCar
?:
number
;
hasAccident
?:
number
;
status
?:
number
|
string
;
previousOwnerName
?:
string
;
previousOwnerPhone
?:
string
;
evalOrderTime
?:
string
;
evalOperatorName
?:
string
;
source
?:
string
;
contractOrg
?:
string
;
showEvalBtn
?:
boolean
;
showCheckPriceBtn
?:
boolean
;
usageType
?:
string
|
number
;
ownerType
?:
string
|
number
;
vehicleCategory
?:
string
|
number
;
}
export
interface
AssessmentPage
{
records
:
AssessmentRow
[];
total
:
number
;
}
export
interface
AssessmentDetail
extends
AssessmentRow
{
[
key
:
string
]:
unknown
;
priceHistoryListDTO
?:
Array
<
Record
<
string
,
unknown
>>
;
}
class
AssessmentApi
extends
ApiClient
{
page
(
params
:
Record
<
string
,
unknown
>
)
{
return
this
.
post
<
AssessmentPage
>
(
'/evalOrderManage/getEvalOrderList'
,
params
);
}
detail
(
evalOrderNo
:
string
)
{
return
this
.
post
<
AssessmentDetail
>
(
'/evalOrderManage/getEvalOrderDetail'
,
{
evalOrderNo
});
}
history
(
evalOrderNo
:
string
)
{
return
this
.
post
<
Array
<
Record
<
string
,
unknown
>>>
(
'/evalOrderManage/getEvalOrderPriceHistory'
,
{
evalOrderNo
});
}
exportOrders
(
params
:
Record
<
string
,
unknown
>
)
{
return
this
.
post
<
unknown
>
(
'/evalOrderManage/exportEvalOrderAsync'
,
params
);
}
exportImages
(
evalOrderNo
:
string
)
{
return
this
.
post
<
unknown
>
(
'/evalOrderManage/exportEvalOrderImageZipAsync'
,
{
evalOrderNo
});
}
}
...
...
apps/web/subapps/usedcar/src/api/modules/contract.ts
View file @
4b4d68b
...
...
@@ -7,13 +7,96 @@
import
{
usedcarClient
}
from
'../core/client'
;
import
type
{
UsedcarParams
}
from
'../core/types'
;
/**
* 合同详情返回结构 —— 逐字段对照源系统
* src/views/usedCarManagement/operateManagement/components/contract/detail.vue 的 configData。
* 源系统没有 DTO,字段一律可选;索引签名兜住未列举的返回字段,避免把后端新增字段当成类型错误。
*/
/** 合同签署方:`electronicContractField` 为 JSON 字符串,解析后按 partA* / partB* 取甲乙方。 */
export
interface
ContractSigner
{
partAName
?:
string
;
partBName
?:
string
;
partAContactName
?:
string
;
partBContactName
?:
string
;
partAContactMobile
?:
string
;
partBContactMobile
?:
string
;
partAIdentityCode
?:
string
;
partBIdentityCode
?:
string
;
electronicContractType
?:
string
|
number
;
signerType
?:
string
|
number
;
[
key
:
string
]:
unknown
;
}
/** 付款审批记录(源 configData「合同状态」块下的 oaAudits 表格)。 */
export
interface
ContractOaAudit
{
paymentType
?:
string
|
number
;
oaFlowPaymentStatus
?:
string
|
number
;
paymentAmount
?:
string
|
number
;
oaFlowCode
?:
string
;
oaFlowStatus
?:
string
|
number
;
splitPay
?:
string
|
number
;
detail
?:
string
;
[
key
:
string
]:
unknown
;
}
/** 合同内容项:value 为图片/视频 URL 串,otherType 由前端按扩展名判定。 */
export
interface
ContractFieldItem
{
label
?:
string
;
value
?:
string
;
otherType
?:
string
;
[
key
:
string
]:
unknown
;
}
/** 操作记录(源 configData「操作记录」块下的 logs)。 */
export
interface
ContractLog
{
opType
?:
string
|
number
;
createdBy
?:
string
;
createdDate
?:
string
;
[
key
:
string
]:
unknown
;
}
/** 合同车型信息。 */
export
interface
ContractCarBase
{
carBrand
?:
string
;
carSeriesName
?:
string
;
carTypeName
?:
string
;
[
key
:
string
]:
unknown
;
}
/** GET /evalElectronicContract/detail 的 data。 */
export
interface
ContractDetail
{
id
:
string
|
number
;
/** 合同流转状态:1 签署中 / 2 签署完成。 */
electronicContractStatus
?:
string
|
number
;
evalOrderNo
?:
string
;
/** 合同来源:1 系统生成 / 2 人工导入。 */
source
?:
string
|
number
;
/** 付款方式:1 银行转账 / 2 冲账。 */
paymentMethod
?:
string
|
number
;
oaAudits
?:
ContractOaAudit
[];
/** 合同类型:1 二手车转让协议 / 2 车辆代保管协议 / 3 二手车补充协议 / 4 车辆交接确认单。 */
electronicContractType
?:
string
|
number
;
carBase
?:
ContractCarBase
;
/** 兼容源系统在顶层补的 carTypeName 字段。 */
carTypeName
?:
string
;
docTemplateName
?:
string
;
contractPrice
?:
string
|
number
;
description
?:
string
;
fieldItems
?:
ContractFieldItem
[];
/** 源返回为 JSON 字符串,详情页 JSON.parse 后使用;兼容个别环境直接下发对象。 */
electronicContractField
?:
string
|
ContractSigner
;
logs
?:
ContractLog
[];
[
key
:
string
]:
unknown
;
}
// 合同管理列表
export
function
getContractList
<
T
=
unknown
>
(
data
:
UsedcarParams
=
{})
{
return
usedcarClient
.
post
<
T
>
(
'/evalElectronicContract/page'
,
data
);
}
// 合同管理详情
export
function
getContractDetail
<
T
=
unknown
>
(
data
:
UsedcarParams
=
{})
{
// 合同管理详情
(源详情页只传 { id })
export
function
getContractDetail
<
T
=
ContractDetail
>
(
data
:
UsedcarParams
=
{})
{
return
usedcarClient
.
post
<
T
>
(
'/evalElectronicContract/detail'
,
data
);
}
...
...
apps/web/subapps/usedcar/src/lib/ossUpload.ts
0 → 100644
View file @
4b4d68b
import
type
GlOssApi
from
'glsk-oss-jssdk'
;
import
type
{
OssUploadResult
}
from
'glsk-oss-jssdk'
;
/**
* 源系统同款 OSS 直传封装(dj-car-life-system 的 GlOssApi.multipartUpload)。
*
* - 桶名与源 system/合同模块一致:jinrong-huidan-test
* - 目录沿用源传法:取文件后缀(xlsx / pdf / png ...)
* - SDK 自包含配置中心 + STS 凭证获取,无需在子应用侧配置密钥
* - 动态 import:ali-oss 体积大,只在真正上传时才加载,不进首屏包
*/
export
const
OSS_BUCKET
=
'jinrong-huidan-test'
;
let
apiPromise
:
Promise
<
GlOssApi
>
|
null
=
null
;
function
getApi
():
Promise
<
GlOssApi
>
{
if
(
!
apiPromise
)
{
apiPromise
=
import
(
'glsk-oss-jssdk'
).
then
(({
default
:
GlOssApi
})
=>
new
GlOssApi
());
}
return
apiPromise
;
}
/** 取文件后缀作为 OSS 目录,与源 `fileName.substr(lastIndexOf('.') + 1)` 等价。 */
function
dirOf
(
file
:
File
):
string
{
const
index
=
file
.
name
.
lastIndexOf
(
'.'
);
return
index
>=
0
?
file
.
name
.
slice
(
index
+
1
).
toLowerCase
()
:
'file'
;
}
/**
* 上传单个文件,resolve 的 aliyunAddress 即业务接口需要的 fileUrl。
* SDK 自身有重试;这里只负责把回调式 API 转成 Promise。
*/
export
async
function
uploadToOss
(
file
:
File
):
Promise
<
OssUploadResult
>
{
const
api
=
await
getApi
();
return
new
Promise
<
OssUploadResult
>
((
resolve
,
reject
)
=>
{
api
.
multipartUpload
(
file
,
(
result
)
=>
resolve
(
result
),
(
error
)
=>
reject
(
error
instanceof
Error
?
error
:
new
Error
(
String
(
error
))),
OSS_BUCKET
,
dirOf
(
file
),
);
});
}
/** 上传成功后的地址(业务接口的 fileUrl 字段)。 */
export
async
function
uploadFileUrl
(
file
:
File
):
Promise
<
string
>
{
const
result
=
await
uploadToOss
(
file
);
return
result
.
aliyunAddress
;
}
export
type
{
OssUploadResult
};
apps/web/subapps/usedcar/src/pages/Assessment/AssessmentDetail.tsx
View file @
4b4d68b
import { useQuery } from '@tanstack/react-query';
import { UAlert, UButton, UCard, UEmpty, U
Form, UFormItem, U
Result } from '@uj/ui';
import { UAlert, UButton, UCard, UEmpty, UResult } from '@uj/ui';
import { downloadCenter } from '@uj/platform-sdk';
import {
CombiForm, PageShell, type FieldSchema } from '@/components';
import { CombiForm, PageShell, type FieldSchema } from '@/components';
import { useAccess } from '@/access';
import { assessmentApi, type AssessmentDetail as Detail } from '@/api';
import { UC } from '@/permissions/codes';
import type { PageParams } from '@/routes';
import {
goTo } from '../Leads/navigate
';
import {
errorDetail } from '@/utils/error
';
import { DYNAMIC_EVENT_CONFIG, PRICE_DETAIL_FIELDS, readOnlyValues, VEHICLE_ASSET_GROUPS, VEHICLE_DETAIL_FIELDS } from './detailConfig';
import './assessment.css';
...
...
@@ -49,11 +49,7 @@ export default function AssessmentDetail({ params }: { params: PageParams }) {
? data.priceHistoryListDTO.filter((item) => Number(item.opType) === 40)
: [];
return (
<PageShell
title="评估单详情"
description="查看车辆资料、总部估价、核价意见和评估动态。"
onBack={() => goTo('assessment')}
>
<PageShell title="评估单详情" description="查看车辆资料、总部估价、核价意见和评估动态。">
{detail.isError ? <UAlert type="error" showIcon title="评估单详情加载失败" description={errorDetail(detail.error)} /> : null}
<div className="uc-assess-detail">
<UCard>
...
...
@@ -77,7 +73,7 @@ export default function AssessmentDetail({ params }: { params: PageParams }) {
downloadCenter.url({
source: 'usedcar',
sourceLabel: '二手车管理 / 评估管理 / 车辆资料',
label: `${String(label)} · 文件 ${index + 1}`,
label: `${String(
group.
label)} · 文件 ${index + 1}`,
url: String(url),
silent: true,
dedupeKey: `usedcar-assess-file-${String(url)}`,
...
...
apps/web/subapps/usedcar/src/pages/Assessment/EvaluatePage.tsx
0 → 100644
View file @
4b4d68b
import { useMemo, useState } from 'react';
import { useMutation, useQuery } from '@tanstack/react-query';
import {
UAlert,
UButton,
UCard,
UDescriptions,
UForm,
UModal,
UResult,
UText,
useUMessage,
} from '@uj/ui';
import { CombiForm, PageShell, type FieldSchema } from '@/components';
import { useAccess } from '@/access';
import { assessmentApi, evalOrderApi, type AssessmentDetail } from '@/api';
import { UC } from '@/permissions/codes';
import type { PageParams } from '@/routes';
import { errorDetail } from '@/utils/error';
import { goTo } from '../Leads/navigate';
import { readOnlyValues, VEHICLE_DETAIL_FIELDS } from './detailConfig';
import './assessment.css';
/**
* 车辆评估 / 核价操作页。
* 对照源 evaluationManagement/evaluate.vue + components/assess.vue/check.vue/rejectDialog.vue:
* scene=assess → 评估价 evalPrice + 评估意见 evalOpinion,保存 opType=10,驳回 30
* scene=checkPrice → 核价 checkPrice + 核价意见 checkOpinion,保存 opType=40,驳回 50
* 两条路径都复用 evaluateCar/checkPriceCar,靠 opType 区分保存与驳回。
*/
type Scene = 'assess' | 'checkPrice';
type SaveValues = { evalPrice?: string; evalOpinion?: string; checkPrice?: string; checkOpinion?: string };
type RejectValues = { rejectReason: string; rejectSuggestion: string };
const display = (value: unknown) =>
value === undefined || value === null || value === '' ? '-' : String(value);
const integerRule = (label: string) => [
{ required: true, message: `请输入${label}` },
{
pattern: /^\d+$/,
message: '只能输入整数',
},
{
validator: (_: unknown, value: string) => {
if (!value) return;
const n = Number(value);
if (n <= 0) return Promise.reject(new Error(`${label}必须大于0`));
if (n > 9999999) return Promise.reject(new Error(`${label}必须小于9999999`));
},
},
];
export default function EvaluatePage({ params }: { params: PageParams }) {
const { canPoint } = useAccess();
const msg = useUMessage();
const [form] = UForm.useForm<SaveValues>();
const [rejectForm] = UForm.useForm<RejectValues>();
const [rejectOpen, setRejectOpen] = useState(false);
const scene = (params.scene === 'checkPrice' ? 'checkPrice' : 'assess') as Scene;
const evalOrderNo = params.evalOrderNo ?? '';
const isCheck = scene === 'checkPrice';
const allowed = canPoint(isCheck ? UC.ASSESS_PRICE_AUDIT : UC.ASSESS_EVALUATE);
const detail = useQuery({
queryKey: ['usedcar', 'assessment', evalOrderNo],
queryFn: () => assessmentApi.detail(evalOrderNo),
enabled: allowed && Boolean(evalOrderNo),
});
const history = useQuery({
queryKey: ['usedcar', 'assessment', evalOrderNo, 'history'],
queryFn: () => assessmentApi.history(evalOrderNo),
enabled: allowed && Boolean(evalOrderNo),
});
const submit = useMutation({
mutationFn: (payload: Record<string, unknown>) =>
isCheck ? evalOrderApi.checkPriceCar(payload) : evalOrderApi.evaluateCar(payload),
onSuccess: (res) => {
// 源 submitData:后端把结果放在 res.data.code(client 已 unwrap 一层,故兼容两种形状)。
const wrapped = (res as { data?: { code?: number; msg?: string }; code?: number; msg?: string }) ?? {};
const code = wrapped.data?.code ?? wrapped.code;
const message = wrapped.data?.msg ?? wrapped.msg;
if (code !== undefined && code !== 0) {
msg.error(message ?? '操作失败');
return;
}
msg.success('操作成功');
void history.refetch();
void detail.refetch();
goTo(`assessment/${encodeURIComponent(evalOrderNo)}`);
},
onError: (error) => msg.error(errorDetail(error)),
});
const fields: FieldSchema<SaveValues>[] = useMemo(
() =>
isCheck
? [
{
name: 'checkPrice',
label: '核价',
type: 'input',
inputProps: { maxLength: 7 },
rules: integerRule('核价'),
},
{
name: 'checkOpinion',
label: '核价意见',
type: 'textarea',
textareaProps: { rows: 4, maxLength: 200 },
rules: [{ required: true, message: '请输入核价意见' }],
},
]
: [
{
name: 'evalPrice',
label: '评估价',
type: 'input',
inputProps: { maxLength: 7 },
rules: integerRule('评估价'),
},
{
name: 'evalOpinion',
label: '评估意见',
type: 'textarea',
textareaProps: { rows: 4, maxLength: 200 },
rules: [{ required: true, message: '请输入评估意见' }],
},
],
[isCheck],
);
const rejectFields: FieldSchema<RejectValues>[] = [
{ name: 'rejectReason', label: '驳回原因', type: 'input', rules: [{ required: true, message: '请输入驳回原因' }] },
{ name: 'rejectSuggestion', label: '驳回意见', type: 'input', rules: [{ required: true, message: '请输入驳回意见' }] },
];
if (!allowed)
return (
<UResult
status="403"
title={isCheck ? '无评估核价权限' : '无车辆评估权限'}
subTitle="请联系管理员开通对应权限。"
/>
);
if (!evalOrderNo)
return <UResult status="404" title="未找到评估单" subTitle="操作地址缺少评估单编号。" />;
const data: Partial<AssessmentDetail> = detail.data ?? {};
const onSave = (values: SaveValues) => {
const payload = {
vin: data.vin,
evalOrderNo,
opType: isCheck ? 40 : 10,
...values,
};
submit.mutate(payload);
};
const onReject = (values: RejectValues) => {
setRejectOpen(false);
submit.mutate({
vin: data.vin,
evalOrderNo,
opType: isCheck ? 50 : 30,
...values,
});
};
return (
<PageShell
title={isCheck ? '评估核价' : '车辆评估'}
description={isCheck ? '录入核价与核价意见,或驳回该评估单。' : '录入评估价与评估意见,或驳回该评估单。'}
actions={<UButton onClick={() => goTo('assessment')}>返回列表</UButton>}
>
{detail.isError ? (
<UAlert type="error" showIcon title="评估单加载失败" description={errorDetail(detail.error)} />
) : null}
<div className="uc-assess-detail">
<UCard>
<h3>车辆信息</h3>
<UDescriptions
column={2}
size="small"
items={readOnlyValues(VEHICLE_DETAIL_FIELDS, data as AssessmentDetail).map(
([label, value]) => ({ key: label, label, children: display(value) }),
)}
/>
</UCard>
<UCard>
<h3>{isCheck ? '核价与意见' : '总部定价师估价与意见'}</h3>
<CombiForm mode="form" form={form} fields={fields} layout="vertical" onSubmit={onSave} />
</UCard>
<UCard>
<h3>评估动态</h3>
{history.data?.length ? (
<div className="uc-assess-dynamics">
{history.data.map((item, index) => (
<div key={index} className="uc-assess-dynamic">
<UText type="secondary">
{display(item.opType)} · {display(item.createdDate)} · {display(item.createdBy)}
</UText>
<div>
{Object.entries(item)
.filter(([key, value]) =>
['evalPrice', 'evalOpinion', 'checkPrice', 'checkOpinion', 'rejectReason', 'rejectSuggestion'].includes(key) &&
value !== undefined &&
value !== '',
)
.map(([key, value]) => (
<span key={key} style={{ marginRight: 16 }}>
{key}:{String(value)}
</span>
))}
</div>
</div>
))}
</div>
) : (
<UText type="secondary">暂无评估动态</UText>
)}
</UCard>
</div>
<div style={{ display: 'flex', gap: 8, justifyContent: 'flex-end', padding: '12px 0' }}>
<UButton type="primary" loading={submit.isPending} onClick={() => form.submit()}>
保存
</UButton>
<UButton onClick={() => setRejectOpen(true)}>驳回</UButton>
<UButton onClick={() => goTo('assessment')}>关闭</UButton>
</div>
<UModal
open={rejectOpen}
title="驳回"
confirmLoading={submit.isPending}
onCancel={() => setRejectOpen(false)}
onOk={() => rejectForm.submit()}
>
<CombiForm
mode="form"
form={rejectForm}
fields={rejectFields}
layout="vertical"
onSubmit={onReject}
/>
</UModal>
</PageShell>
);
}
apps/web/subapps/usedcar/src/pages/Assessment/assessment.css
View file @
4b4d68b
...
...
@@ -2,7 +2,8 @@
display
:
block
;
width
:
96px
;
height
:
54px
;
object-fit
:
contain
;
object-fit
:
cover
;
object-position
:
center
;
border-radius
:
4px
;
background
:
#f5f5f5
;
}
...
...
apps/web/subapps/usedcar/src/pages/Assessment/index.tsx
View file @
4b4d68b
import { useMemo, useState } from 'react';
import { useQuery } from '@tanstack/react-query';
import type { Dayjs } from 'dayjs';
import { UAlert, UButton, UCard, U
Result, UTag, useUMessage
} from '@uj/ui';
import { UAlert, UButton, UCard, U
Image, UResult, UTag
} from '@uj/ui';
import {
DataTable,
PageShell,
...
...
@@ -45,6 +45,22 @@ const yesNo = [
{ value: '1', label: '是' },
{ value: '0', label: '否' },
];
// 源 constants.js:usageTypeOpt / ownerTypeOpt / vehicleCategoryOpt(value 存 confId)。
const USAGE_TYPES = [
{ value: '1', label: '非营运' },
{ value: '2', label: '营运' },
{ value: '3', label: '营转非' },
];
const OWNER_TYPES = [
{ value: '1', label: '个人' },
{ value: '2', label: '单位' },
];
const VEHICLE_CATEGORIES = [
{ value: '1', label: '置换车' },
{ value: '2', label: '报废车' },
];
const labelOf = (options: Array<{ value: string; label: string }>, value: unknown): string =>
options.find((o) => o.value === String(value))?.label || text(value);
const statusMap: Record<string, string> = {
'1': '待评估',
'2': '评估中',
...
...
@@ -76,7 +92,6 @@ function filtersToParams(filters: Filters): Record<string, unknown> {
/** menu_code 1002603 · 评估管理 · usedcar:assess:view */
export default function Assessment() {
const { canPoint } = useAccess();
const message = useUMessage();
const allowed = canPoint(UC.ASSESS_VIEW);
const [filters, setFilters] = useState<Filters>({});
const [page, setPage] = useState({ current: 1, size: 10 });
...
...
@@ -107,6 +122,9 @@ export default function Assessment() {
{ name: 'evalOperatorName', label: '总部定价师', type: 'input' },
{ name: 'source', label: '评估单来源', type: 'input' },
{ name: 'contractOrg', label: '内部主体', type: 'input' },
{ name: 'usageType', label: '使用性质', type: 'select', options: USAGE_TYPES },
{ name: 'ownerType', label: '所有人性质', type: 'select', options: OWNER_TYPES },
{ name: 'vehicleCategory', label: '车辆类别', type: 'select', options: VEHICLE_CATEGORIES },
];
if (!allowed)
return (
...
...
@@ -118,7 +136,18 @@ export default function Assessment() {
dataIndex: 'coverImage',
width: 120,
render: (url: unknown) =>
typeof url === 'string' ? <img className="uc-assess-cover" src={url} alt="车辆" /> : '-',
typeof url === 'string' && url ? (
<UImage
className="uc-assess-cover"
src={url}
alt="车辆"
width={96}
height={54}
style={{ objectFit: 'cover', objectPosition: 'center' }}
/>
) : (
'-'
),
},
{ title: '车牌号', dataIndex: 'licensePlate', width: 110, render: text },
{ title: '车架号', dataIndex: 'vin', width: 180, render: text },
...
...
@@ -130,6 +159,24 @@ export default function Assessment() {
[row.carBrand, row.carSeriesName, row.carTypeName].filter(Boolean).join(' ') || '-',
},
{ title: '上牌时间', dataIndex: 'registrationDate', width: 120, render: text },
{
title: '使用性质',
dataIndex: 'usageType',
width: 90,
render: (v: unknown) => labelOf(USAGE_TYPES, v),
},
{
title: '所有人性质',
dataIndex: 'ownerType',
width: 90,
render: (v: unknown) => labelOf(OWNER_TYPES, v),
},
{
title: '车辆类别',
dataIndex: 'vehicleCategory',
width: 90,
render: (v: unknown) => labelOf(VEHICLE_CATEGORIES, v),
},
{ title: '评估单编号', dataIndex: 'evalOrderNo', width: 180, render: text },
{
title: '上牌城市',
...
...
@@ -176,14 +223,16 @@ export default function Assessment() {
{
label: '车辆评估',
permission: UC.ASSESS_EVALUATE,
visible: (row) => Boolean(row.showEvalBtn),
onClick: () => message.info('车辆评估功能将通过评估单详情页接入。'),
visible: (row) => Boolean(row.showEvalBtn && row.evalOrderNo),
onClick: (row) =>
goTo(`assessment/evaluate/assess/${encodeURIComponent(String(row.evalOrderNo))}`),
},
{
label: '评估核价',
permission: UC.ASSESS_PRICE_AUDIT,
visible: (row) => Boolean(row.showCheckPriceBtn),
onClick: () => message.info('评估核价功能将通过评估单详情页接入。'),
visible: (row) => Boolean(row.showCheckPriceBtn && row.evalOrderNo),
onClick: (row) =>
goTo(`assessment/evaluate/checkPrice/${encodeURIComponent(String(row.evalOrderNo))}`),
},
{
label: '图片下载',
...
...
@@ -195,7 +244,12 @@ export default function Assessment() {
sourceLabel: '二手车管理 / 评估管理 / 评估图片下载',
label: '评估图片下载',
method: '/evalOrderManage/exportEvalOrderImageZipAsync',
params: { evalOrderNo: String(row.evalOrderNo) },
params: {
evalOrderNo: String(row.evalOrderNo),
// 源 handleDownLoad:通用异步导出服务靠这两个字段选执行网关,漏带会报「请求资源不存在」。
server_provider_type: 'gsc',
server_provider_name: 'gsc-vcp-web-facade',
},
dedupeKey: `assess-images-${String(row.evalOrderNo)}`,
}),
},
...
...
@@ -211,7 +265,14 @@ export default function Assessment() {
sourceLabel: '二手车管理 / 评估管理 / 评估订单导出',
label: '评估订单导出',
method: '/evalOrderManage/exportEvalOrderAsync',
params: { ...params, idsStr: selectedKeys.join(','), currentPage: 1 },
params: {
...params,
idsStr: selectedKeys.join(','),
currentPage: 1,
// 源 handleExport 同样带 gsc provider 参数。
server_provider_type: 'gsc',
server_provider_name: 'gsc-vcp-web-facade',
},
dedupeKey: 'assess-orders-export',
}),
},
...
...
apps/web/subapps/usedcar/src/pages/Dashboard/components/TrendChart.tsx
View file @
4b4d68b
...
...
@@ -54,7 +54,7 @@ function formatNumber(value: number): string {
export function TrendChart({ data, label, unit = '辆', loading = false }: TrendChartProps) {
const containerRef = useRef<HTMLDivElement>(null);
const [width, setWidth] = useState(CHART.width);
const [width, setWidth] = useState
<number>
(CHART.width);
const [activeIndex, setActiveIndex] = useState<number | null>(null);
useEffect(() => {
...
...
apps/web/subapps/usedcar/src/pages/Leads/LeadDetail.tsx
View file @
4b4d68b
...
...
@@ -5,7 +5,6 @@ import { useAccess } from '@/access';
import { leadsApi, type FollowRecord, type LeadDetail, type OperationLog } from '@/api';
import { UC } from '@/permissions/codes';
import type { PageParams } from '@/routes';
import { goLeads } from './navigate';
import { errorDetail } from '@/utils/error';
import './leads.css';
...
...
@@ -44,7 +43,7 @@ export default function LeadDetail({ params }: { params: PageParams }) {
const data: LeadDetail = detail.data ?? { id };
const status = String(data.cluesStatus ?? '');
const followStatus = Number(data.followTimeStatus);
return <PageShell title="线索详情" description="查看线索基础信息、跟进记录和操作日志。"
onBack={goLeads}
>
return <PageShell title="线索详情" description="查看线索基础信息、跟进记录和操作日志。">
{detail.isError ? <UAlert type="error" showIcon title="线索详情加载失败" description={errorDetail(detail.error)} action={<UButton type="link" onClick={() => void detail.refetch()}>重试</UButton>} /> : null}
<div className="uc-lead-detail">
<div className="uc-lead-detail__top">
...
...
apps/web/subapps/usedcar/src/pages/Leads/navigate.ts
View file @
4b4d68b
export
{
goTo
}
from
'@uj/platform-sdk'
;
import
{
goTo
}
from
'@uj/platform-sdk'
;
/** 二手车域的固定落点:跳转机制真源在 platform-sdk 的 `goTo`。 */
export
function
goLeads
():
void
{
goTo
(
'leads'
);
}
apps/web/subapps/usedcar/src/pages/Operation/ContractDetail.tsx
0 → 100644
View file @
4b4d68b
import { useState } from 'react';
import { useMutation, useQuery } from '@tanstack/react-query';
import {
UAlert,
UButton,
UCard,
UDescriptions,
UEmpty,
UInput,
UResult,
UTable,
UTag,
useUMessage,
} from '@uj/ui';
import { PageShell } from '@/components';
import { downloadCenter } from '@uj/platform-sdk';
import { useAccess } from '@/access';
import { contractApi, type ContractDetail as Detail, type ContractOaAudit } from '@/api';
import { UC } from '@/permissions/codes';
import type { PageParams } from '@/routes';
import { errorDetail } from '@/utils/error';
import { goTo } from '../Leads/navigate';
import {
DICT,
contractModel,
dictTone,
dictValue,
display,
fileType,
logTypeName,
ossThumb,
parseSigners,
signerTypeName,
SIGNER_FIELDS,
splitUrls,
} from './contractDetailConfig';
import './contractDetail.css';
/**
* 合同详情的独立页面:/usedcar/operation/contract/:id。
* 数据源与信息块逐一对齐源系统 .../contract/detail.vue:
* 合同状态(含付款表)/ 合同信息 / 合同内容 / 签署人信息 / 操作记录。
* 唯一可编辑字段是合同描述,保存走 /evalElectronicContract/editDescription。
*/
export default function ContractDetail({ params }: { params: PageParams }) {
const { canPoint } = useAccess();
const msg = useUMessage();
const allowed = canPoint(UC.CONTRACT_DETAIL);
const id = String(params.id ?? '');
const [description, setDescription] = useState<string | null>(null);
const detail = useQuery({
queryKey: ['usedcar', 'contract', id],
queryFn: () => contractApi.getContractDetail({ id }),
enabled: allowed && Boolean(id),
});
const save = useMutation({
mutationFn: (next: string) =>
contractApi.getContractEdit({ id, description: next }),
onSuccess: () => {
msg.success('操作成功');
goTo('operation');
},
onError: (error) => msg.error(errorDetail(error)),
});
if (!allowed)
return (
<UResult
status="403"
title="无查看合同详情的权限"
subTitle="请联系管理员开通“合同详情”权限。"
/>
);
if (!id)
return (
<UResult status="404" title="未找到合同" subTitle="详情地址缺少合同记录 id。" />
);
const data: Detail = detail.data ?? { id };
const signers = parseSigners(data.electronicContractField);
const currentDescription = description ?? display(data.description);
const oaAudits = Array.isArray(data.oaAudits) ? data.oaAudits : [];
const fieldItems = Array.isArray(data.fieldItems) ? data.fieldItems : [];
const logs = Array.isArray(data.logs) ? data.logs : [];
const payColumns = [
{
title: '支付方式',
render: (row: ContractOaAudit) => dictValue(DICT.payType, row.paymentType),
},
{
title: '支付状态',
render: (row: ContractOaAudit) => (
<UTag color={dictTone(DICT.payStatus, row.oaFlowPaymentStatus)}>
{dictValue(DICT.payStatus, row.oaFlowPaymentStatus)}
</UTag>
),
},
{
title: '支付金额',
render: (row: ContractOaAudit) =>
row.paymentAmount === undefined || row.paymentAmount === ''
? '-'
: `¥${String(row.paymentAmount)}`,
},
{ title: '企微审批单号', dataIndex: 'oaFlowCode', render: display },
{
title: '企微审批状态',
render: (row: ContractOaAudit) => (
<UTag color={dictTone(DICT.oaFlowStatus, row.oaFlowStatus)}>
{dictValue(DICT.oaFlowStatus, row.oaFlowStatus)}
</UTag>
),
},
{
title: '是否拆分',
render: (row: ContractOaAudit) => (Number(row.splitPay) === 1 ? '是' : '否'),
},
{ title: '拆分详情', dataIndex: 'detail', render: display },
];
return (
<PageShell
title="合同详情"
description="查看合同状态、合同信息、合同内容、签署人信息与操作记录。"
actions={
<UButton type="default" size="small" onClick={() => goTo('operation')}>
返回列表
</UButton>
}
>
{detail.isError ? (
<UAlert
type="error"
showIcon
title="合同详情加载失败"
description={errorDetail(detail.error)}
action={
<UButton type="link" onClick={() => void detail.refetch()}>
重试
</UButton>
}
/>
) : null}
<div className="uc-contract-detail">
<UCard>
<h3 className="uc-contract-detail__title">
合同状态
<UTag color={dictTone(DICT.status, data.electronicContractStatus)}>
{dictValue(DICT.status, data.electronicContractStatus)}
</UTag>
</h3>
<UDescriptions column={2} size="small">
<UDescriptions.Item label="合同流转状态">
{dictValue(DICT.status, data.electronicContractStatus)}
</UDescriptions.Item>
<UDescriptions.Item label="评估单编号">{display(data.evalOrderNo)}</UDescriptions.Item>
<UDescriptions.Item label="合同来源">{dictValue(DICT.source, data.source)}</UDescriptions.Item>
<UDescriptions.Item label="付款方式">
{dictValue(DICT.paymentMethod, data.paymentMethod)}
</UDescriptions.Item>
</UDescriptions>
<h4 className="uc-contract-detail__subtitle">付款信息</h4>
{oaAudits.length ? (
<UTable<ContractOaAudit>
rowKey={(_, index) => String(index)}
size="small"
pagination={false}
dataSource={oaAudits}
columns={payColumns}
scroll={{ x: 900 }}
/>
) : (
<UEmpty description="暂无付款信息" />
)}
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">合同信息</h3>
<UDescriptions column={2} size="small">
<UDescriptions.Item label="合同类型">
{dictValue(DICT.contractType, data.electronicContractType)}
</UDescriptions.Item>
<UDescriptions.Item label="合同车型">{contractModel(data)}</UDescriptions.Item>
<UDescriptions.Item label="合同模板">{display(data.docTemplateName)}</UDescriptions.Item>
<UDescriptions.Item label="合同金额">
{data.contractPrice === undefined || data.contractPrice === ''
? '-'
: `¥${String(data.contractPrice)}`}
</UDescriptions.Item>
<UDescriptions.Item label="合同描述" span={2}>
<UInput.TextArea
className="uc-contract-detail__desc"
value={currentDescription === '-' ? '' : currentDescription}
onChange={(event) => setDescription(event.target.value)}
maxLength={200}
showCount
rows={3}
placeholder="请输入合同描述"
/>
</UDescriptions.Item>
</UDescriptions>
<div className="uc-contract-detail__actions">
<UButton
type="primary"
size="small"
loading={save.isPending}
disabled={!currentDescription || currentDescription === '-'}
onClick={() => void save.mutate(currentDescription === '-' ? '' : currentDescription)}
>
保存
</UButton>
</div>
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">合同内容</h3>
{fieldItems.length ? (
<div className="uc-contract-detail__fields">
{fieldItems.map((item, index) => {
const urls = splitUrls(item.value);
const type = urls.length ? fileType(urls[0]) : 'unknown';
return (
<div className="uc-contract-detail__field" key={`${String(item.label)}-${index}`}>
<span className="uc-contract-detail__field-label">{display(item.label)}:</span>
<span className="uc-contract-detail__field-value">
{urls.length ? (
urls.map((url, urlIndex) =>
type === 'image' ? (
<img
className="uc-contract-detail__thumb"
key={`${url}-${urlIndex}`}
src={ossThumb(url)}
alt={String(item.label ?? '合同资料')}
onClick={() =>
downloadCenter.url({
source: 'usedcar',
sourceLabel: '二手车管理 / 运营管理 / 合同内容',
label: `${String(item.label ?? '合同资料')} · 图片 ${urlIndex + 1}`,
url,
silent: true,
dedupeKey: `usedcar-contract-field-${url}`,
})
}
/>
) : type === 'video' ? (
<UButton
type="link"
size="small"
key={`${url}-${urlIndex}`}
onClick={() =>
downloadCenter.url({
source: 'usedcar',
sourceLabel: '二手车管理 / 运营管理 / 合同内容',
label: `${String(item.label ?? '合同资料')} · 视频 ${urlIndex + 1}`,
url,
silent: true,
dedupeKey: `usedcar-contract-field-${url}`,
})
}
>
视频 {urlIndex + 1}
</UButton>
) : (
<span key={`${url}-${urlIndex}`}>{url}</span>
),
)
) : (
display(item.value)
)}
</span>
</div>
);
})}
</div>
) : (
<UEmpty description="暂无合同内容" />
)}
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">签署人信息</h3>
{([1, 2] as const).map((side) => (
<div className="uc-contract-detail__signer" key={side}>
<h4 className="uc-contract-detail__subtitle">
{side === 1 ? '甲方' : '乙方'}
</h4>
<UDescriptions column={2} size="small">
{SIGNER_FIELDS.map((field) => {
let value: string;
if (field.kind === 'side') value = side === 1 ? '甲方' : '乙方';
else if (field.kind === 'type') value = signerTypeName(data, side);
else if (field.kind === 'idType') value = '身份证/营业执照';
else {
const key = side === 1 ? field.keyA : field.keyB;
value = display(key ? signers[key] : undefined);
}
return (
<UDescriptions.Item label={field.title} key={field.title}>
{value}
</UDescriptions.Item>
);
})}
</UDescriptions>
</div>
))}
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">操作记录</h3>
{logs.length ? (
<div className="uc-contract-detail__logs">
{logs.map((item, index) => (
<div className="uc-contract-detail__log" key={`${String(item.createdDate)}-${index}`}>
<b>{logTypeName(item.opType)}</b>
<span>操作人:{display(item.createdBy)}</span>
<span>操作时间:{display(item.createdDate)}</span>
</div>
))}
</div>
) : (
<UEmpty description="暂无操作记录" />
)}
</UCard>
</div>
</PageShell>
);
}
apps/web/subapps/usedcar/src/pages/Operation/ContractEdit.tsx
0 → 100644
View file @
4b4d68b
import { useState } from 'react';
import { useMutation, useQuery } from '@tanstack/react-query';
import {
UAlert,
UButton,
UCard,
UDescriptions,
URadio,
USteps,
UText,
UUpload,
UResult,
useUMessage,
} from '@uj/ui';
import { PageShell } from '@/components';
import { useAccess } from '@/access';
import { contractApi, type ContractDetail as Detail } from '@/api';
import { uploadToOss } from '@/lib/ossUpload';
import { UC } from '@/permissions/codes';
import type { PageParams } from '@/routes';
import { errorDetail } from '@/utils/error';
import { goTo } from '../Leads/navigate';
/**
* 合同编辑独立页(源 contract/edit.vue):
* - 三步附件经 glsk-oss-jssdk 直传 OSS,回填 fileUrl 后按源 payload 规则提交
* - 发起定金 / 尾款审批前先 checkContract 校验(data == 2)
*/
const display = (v: unknown) =>
v === undefined || v === null || v === '' ? '-' : String(v);
type StepKey = 'transfer' | 'delivery' | 'custody';
type OssFile = { name: string; fileUrl: string };
const STEP_KEYS: StepKey[] = ['transfer', 'delivery', 'custody'];
const STEP_TITLES: Record<StepKey, string> = {
transfer: '转让协议',
delivery: '交车确认单',
custody: '代保管协议',
};
/** 源 edit.vue:520-645 的字段与数量上限(1113-1134)。 */
type FieldDef = {
key: string;
label: string;
max: number;
required?: boolean;
/** 付款方式为「冲账」时才显示、必填(源 updateFileRules)。 */
voucher?: boolean;
};
const STEP_FIELDS: Record<StepKey, FieldDef[]> = {
transfer: [
{ key: 'attachmentList', label: '二手车转让协议', max: 3, required: true },
{ key: 'registrationList', label: '登记证', max: 3, required: true },
{ key: 'vehicleList', label: '行驶证', max: 3, required: true },
{ key: 'idCardBackList', label: '身份证(人像面)', max: 1, required: true },
{ key: 'idCardFrontList', label: '身份证(国徽面)', max: 1, required: true },
{ key: 'paymentVoucherList', label: '付款凭证', max: 3, voucher: true },
{ key: 'reportList', label: '车辆检测报告', max: 3 },
{ key: 'currentOtherImagesList', label: '其他', max: 10 },
],
delivery: [
{ key: 'attachmentList', label: '车辆交接确认单', max: 3, required: true },
{ key: 'currentOtherImagesList', label: '其他', max: 10 },
],
custody: [
{ key: 'attachmentList', label: '车辆代保管协议', max: 3, required: true },
{ key: 'paymentVoucherList', label: '付款凭证', max: 3 },
{ key: 'currentOtherImagesList', label: '其他', max: 10 },
],
};
const emptyFiles = (): Record<StepKey, Record<string, OssFile[]>> => ({
transfer: {},
delivery: {},
custody: {},
});
/** 源 extractFileUrls:每个字段的 fileUrl 以逗号拼接。 */
const extractUrls = (list?: OssFile[]) => (list ?? []).map((f) => f.fileUrl).join(',');
const fileExt = (name: string) => {
const i = name.lastIndexOf('.');
return i >= 0 ? name.slice(i + 1).toLowerCase() : '';
};
export default function ContractEdit({ params }: { params: PageParams }) {
const { canPoint } = useAccess();
const msg = useUMessage();
const allowed = canPoint(UC.CONTRACT_DETAIL);
const id = params.id ?? '';
const contractNo = params.contractNo ?? '';
const [activeStep, setActiveStep] = useState(0);
const [files, setFiles] = useState<Record<StepKey, Record<string, OssFile[]>>>(emptyFiles);
const [paymentMethod, setPaymentMethod] = useState<Record<'transfer' | 'custody', number>>({
transfer: 1,
custody: 1,
});
const detail = useQuery({
queryKey: ['usedcar', 'contract', id],
queryFn: () => contractApi.getContractDetail<Detail>({ id }),
enabled: allowed && Boolean(id),
});
const paymentType = Number((detail.data as unknown as Record<string, unknown>)?.paymentType ?? 1);
const ossUpload = useMutation({
mutationFn: async ({
file,
step,
field,
}: {
file: File;
step: StepKey;
field: FieldDef;
}) => {
const size = file.size / 1024 / 1024;
if (size >= 10) throw new Error('上传文件不可超过 10M');
const result = await uploadToOss(file);
return { step, field, file: { name: result.attachment, fileUrl: result.aliyunAddress } };
},
onSuccess: ({ step, field, file }) => {
setFiles((prev) => ({
...prev,
[step]: {
...prev[step],
[field.key]: [...(prev[step][field.key] ?? []), file],
},
}));
},
onError: (error) => msg.error(errorDetail(error)),
});
const submit = useMutation({
mutationFn: (step: StepKey) => {
const group = files[step];
const base = { contractNo, currentOtherImages: extractUrls(group.currentOtherImagesList) };
if (step === 'transfer') {
const evalImageInfoDTOs = [
...(group.vehicleList ?? []).map((f) => ({
fileType: 2, fileSubtype: 21, fileName: f.name, fileUrl: f.fileUrl, fileFormat: fileExt(f.name),
})),
...(group.registrationList ?? []).map((f) => ({
fileType: 2, fileSubtype: 22, fileName: f.name, fileUrl: f.fileUrl, fileFormat: fileExt(f.name),
})),
...(group.reportList ?? []).map((f) => ({
fileType: 5, fileSubtype: 51, fileName: f.name, fileUrl: f.fileUrl, fileFormat: fileExt(f.name),
})),
];
return contractApi.uploadTransferAgreement({
...base,
attachmentUrl: extractUrls(group.attachmentList),
idCardFrontUrl: extractUrls(group.idCardFrontList),
idCardBackUrl: extractUrls(group.idCardBackList),
paymentVoucher: extractUrls(group.paymentVoucherList),
paymentMethod: paymentMethod.transfer,
evalImageInfoDTOs,
});
}
if (step === 'delivery') {
return contractApi.uploadDeliveryConfirm({
...base,
attachmentUrl: extractUrls(group.attachmentList),
});
}
return contractApi.uploadCustodyAgreement({
...base,
attachmentUrl: extractUrls(group.attachmentList),
paymentMethod: paymentMethod.custody,
paymentVoucher: extractUrls(group.paymentVoucherList),
});
},
onSuccess: (_res, step) => {
msg.success(`${STEP_TITLES[step]}已提交`);
void detail.refetch();
},
onError: (error) => msg.error(errorDetail(error)),
});
// 源 edit.vue approve():checkContract 成功且 data == 2 才提交。
const approve = useMutation({
mutationFn: async (type: 'deposit' | 'final') => {
const check = await contractApi.checkContract<{ code?: number; data?: number | string; msg?: string }>({
contractNo,
});
if (check?.code !== 0 || Number(check.data) !== 2) {
throw new Error(check?.msg ?? '当前合同状态不支持发起审批');
}
const payload = { contractNo, evalOrderNo: detail.data?.evalOrderNo };
return type === 'deposit'
? contractApi.webPayDepositApplication(payload)
: contractApi.webPayFinalApplication(payload);
},
onSuccess: () => {
msg.success('操作成功');
void detail.refetch();
},
onError: (error) => msg.error(errorDetail(error)),
});
if (!allowed)
return <UResult status="403" title="无编辑合同的权限" subTitle="请联系管理员开通“合同详情”权限。" />;
if (!id || !contractNo)
return <UResult status="404" title="未找到合同" subTitle="编辑地址缺少合同 id 或编号。" />;
const data: Partial<Detail> = detail.data ?? {};
const stepKey = STEP_KEYS[activeStep];
const visibleFields = STEP_FIELDS[stepKey].filter((field) => {
if (!field.voucher) return true;
// 源:步骤0 仅 paymentType=1 且 paymentMethod=2(冲账)显示;步骤2 始终显示。
return stepKey === 'custody' || (paymentType === 1 && paymentMethod.transfer === 2);
});
const handleSubmit = () => {
// 源 updateFileRules:步骤0 付款方式为「冲账」时付款凭证必填。
const needVoucher = stepKey === 'transfer' && paymentType === 1 && paymentMethod.transfer === 2;
const missing = STEP_FIELDS[stepKey].find((field) => {
if (!visibleFields.includes(field)) return false;
if (field.voucher) return needVoucher && !(files[stepKey][field.key] ?? []).length;
return field.required && !(files[stepKey][field.key] ?? []).length;
});
if (missing) {
msg.warning(`请上传${missing.label}`);
return;
}
submit.mutate(stepKey);
};
return (
<PageShell
title="合同编辑"
description="维护合同附件并发起付款审批。"
actions={<UButton onClick={() => goTo('operation')}>返回列表</UButton>}
>
{detail.isError ? (
<UAlert type="error" showIcon title="合同信息加载失败" description={errorDetail(detail.error)} />
) : null}
<div className="uc-contract-detail">
<UCard>
<h3 className="uc-contract-detail__title">合同信息</h3>
<UDescriptions
column={2}
size="small"
items={[
{ key: 'no', label: '合同编号', children: display(contractNo) },
{ key: 'eval', label: '评估单编号', children: display(data.evalOrderNo) },
{ key: 'status', label: '流转状态', children: display(data.electronicContractStatus) },
{ key: 'price', label: '合同金额', children: display(data.contractPrice) },
]}
/>
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">上传合同附件</h3>
<USteps
current={activeStep}
onChange={setActiveStep}
items={STEP_KEYS.map((key) => ({ title: STEP_TITLES[key] }))}
style={{ margin: '8px 0 20px' }}
/>
{stepKey !== 'delivery' && paymentType === 1 ? (
<div style={{ marginBottom: 16 }}>
<UText style={{ marginRight: 12 }}>付款方式</UText>
<URadio.Group
value={paymentMethod[stepKey as 'transfer' | 'custody']}
onChange={(e) => {
const value = Number(e.target.value);
setPaymentMethod((prev) =>
stepKey === 'transfer' || stepKey === 'custody'
? { ...prev, [stepKey]: value }
: prev,
);
// 源 watch:切回银行转账时清空付款凭证。
if (value === 1) {
setFiles((prev) => ({ ...prev, [stepKey]: { ...prev[stepKey], paymentVoucherList: [] } }));
}
}}
options={[
{ label: '银行转账', value: 1 },
{ label: '冲账', value: 2 },
]}
/>
</div>
) : null}
{visibleFields.map((field) => {
const current = files[stepKey][field.key] ?? [];
return (
<div key={field.key} style={{ marginBottom: 16 }}>
<div style={{ marginBottom: 6 }}>
<UText>
{field.label}
{field.required ? ' *' : ''}
</UText>
</div>
<div style={{ display: 'flex', gap: 8, flexWrap: 'wrap', alignItems: 'center' }}>
<UUpload
accept=".pdf,image/jpeg,image/png,image/bmp,image/webp"
showUploadList={false}
multiple={field.max > 1}
disabled={current.length >= field.max || ossUpload.isPending}
beforeUpload={(file) => {
ossUpload.mutate({ file, step: stepKey, field });
return false;
}}
>
<UButton loading={ossUpload.isPending} disabled={current.length >= field.max}>
添加附件
</UButton>
</UUpload>
<UText type="secondary">
{current.length}/{field.max}
</UText>
</div>
{current.length ? (
<div style={{ marginTop: 6 }}>
{current.map((item, index) => (
<div key={`${item.fileUrl}-${index}`} style={{ display: 'flex', gap: 8, alignItems: 'center' }}>
<a href={item.fileUrl} target="_blank" rel="noreferrer">
{item.name}
</a>
<UButton
type="link"
size="small"
onClick={() =>
setFiles((prev) => ({
...prev,
[stepKey]: {
...prev[stepKey],
[field.key]: (prev[stepKey][field.key] ?? []).filter((_, i) => i !== index),
},
}))
}
>
移除
</UButton>
</div>
))}
</div>
) : null}
</div>
);
})}
<UButton type="primary" loading={submit.isPending} onClick={handleSubmit}>
提交{STEP_TITLES[stepKey]}
</UButton>
</UCard>
<UCard>
<h3 className="uc-contract-detail__title">发起审批</h3>
<UText type="secondary" style={{ display: 'block', marginBottom: 12 }}>
发起前系统会校验合同当前状态;不满足条件时会提示原因。
</UText>
<div style={{ display: 'flex', gap: 8 }}>
<UButton type="primary" loading={approve.isPending} onClick={() => approve.mutate('deposit')}>
发起定金审批
</UButton>
<UButton loading={approve.isPending} onClick={() => approve.mutate('final')}>
发起尾款/全款审批
</UButton>
</div>
</UCard>
</div>
</PageShell>
);
}
apps/web/subapps/usedcar/src/pages/Operation/components/ContractTab.tsx
View file @
4b4d68b
import { useState } from 'react';
import { use
Query
} from '@tanstack/react-query';
import { UAlert, UCard,
UModal,
useUMessage } from '@uj/ui';
import { use
Mutation, useQuery, useQueryClient
} from '@tanstack/react-query';
import { UAlert, UCard, useUMessage } from '@uj/ui';
import { DataTable, SearchForm, type FieldSchema, type RowActionSchema } from '@/components';
import { useAccess } from '@/access';
import { operationApi, type Contract } from '@/api';
import {
contractApi,
operationApi, type Contract } from '@/api';
import { UC } from '@/permissions/codes';
import { downloadCenter } from '@uj/platform-sdk';
import { errorDetail } from '@/utils/error';
import { CONTRACT_COLUMNS } from './tableConfig';
import { goTo } from '../../Leads/navigate';
import ImportContractModal from './ImportContractModal';
export default function ContractTab() {
const { canPoint } = useAccess(),
msg = useUMessage();
msg = useUMessage(),
qc = useQueryClient();
const [p, setP] = useState({ current: 1, size: 10 });
const [f, setF] = useState<Record<string, unknown>>({});
const [importOpen, setImportOpen] = useState(false);
...
...
@@ -17,37 +21,73 @@ export default function ContractTab() {
queryKey: ['op', 'contracts', p, f],
queryFn: () => operationApi.contracts({ currentPage: p.current, pageSize: p.size, t: f }),
});
// 合同编辑前置校验(源 index.vue jumpDetail):checkContract 通过且 data!==0 才跳编辑页。
const checkEdit = useMutation({
mutationFn: (row: Contract) =>
contractApi.checkContract<{ code?: number; data?: number | string; msg?: string }>({
contractNo: row.contractNo,
}),
onSuccess: (res, row) => {
if (res?.code === 0 && Number(res.data) !== 0) {
// 同时带 id(查详情)与 contractNo(编辑/审批接口用)。
goTo(
`operation/contract-edit/${encodeURIComponent(String(row.id))}/${encodeURIComponent(String(row.contractNo))}`,
);
} else {
msg.error(res?.msg ?? '暂时无法编辑');
}
},
onError: (error) => msg.error(errorDetail(error)),
});
// 查询项对齐源 contract/index.vue searchForm(21 项里的高频字段;金额区间按源拆起止)。
const fields: FieldSchema<Record<string, unknown>>[] = [
{ name: 'licensePlate', label: '车牌号', type: 'input', essential: true },
{ name: 'vin', label: '车架号', type: 'input', essential: true },
{ name: 'contractNo', label: '合同编号', type: 'input', essential: true },
{ name: 'evalOrderNo', label: '评估单编号', type: 'input' },
{ name: 'signTime', label: '签约时间', type: 'dateRange' },
{ name: 'electronicContractType', label: '合同类型', type: 'input' },
{ name: 'docTemplateType', label: '合同模版', type: 'input' },
{ name: 'electronicContractStatus', label: '流转状态', type: 'input' },
{ name: 'createdBy', label: '驻店人员', type: 'input' },
{ name: 'oaFlowPaymentStatus', label: '支付状态', type: 'input' },
{ name: 'paymentType', label: '支付方式', type: 'input' },
{ name: 'lastOaFlowCode', label: '企微审批单号', type: 'input' },
{ name: 'oaFlowStatus', label: '企微审批状态', type: 'input' },
{ name: 'previousOwnerName', label: '车主姓名', type: 'input' },
{ name: 'previousOwnerPhone', label: '车主电话', type: 'input' },
{ name: 'source', label: '合同来源', type: 'input' },
{ name: 'signerType', label: '签署人类型', type: 'input' },
{ name: 'contractOrg', label: '内部主体', type: 'input' },
];
const actions: RowActionSchema<Contract>[] = [
{
label: '详情',
permission: UC.CONTRACT_DETAIL,
onClick: () => msg.info('合同详情将以独立页面接入。'),
visible: (row) => Boolean(row.id),
onClick: (row) => goTo(`operation/contract/${encodeURIComponent(String(row.id))}`),
},
{
label: '合同下载',
permission: UC.CONTRACT_DOWNLOAD,
visible: (r) => Number(r.electronicContractStatus) === 2,
onClick: async (r) => {
try {
const x = await operationApi.contractFile(r.id);
if (x.url) window.open(x.url, '_blank');
else msg.warning('未获取到合同文件地址');
} catch (e) {
msg.error(e instanceof Error ? e.message : '合同文件获取失败');
}
},
onClick: (r) =>
// 源 contract/index.vue:887-912 走下载中心的压缩包异步导出,而非 getContractFileUrl。
downloadCenter.asyncExport({
source: 'usedcar',
sourceLabel: '运营管理 / 合同管理 / 合同下载',
label: '合同文件下载',
method: '/evalElectronicContract/exportContractImageZipAsync',
params: { id: r.id, contractNo: r.contractNo },
dedupeKey: `usedcar-contract-download-${r.id}`,
}),
},
{
label: '合同编辑',
permission: UC.CONTRACT_DETAIL,
visible: (r) => Boolean(r.contractProcessNode),
onClick: (
) => msg.info('合同编辑将以独立页面接入。'
),
visible: (r) => Boolean(r.contractProcessNode
&& r.contractNo
),
onClick: (
r) => checkEdit.mutate(r
),
},
];
return (
...
...
@@ -56,7 +96,18 @@ export default function ContractTab() {
<SearchForm
fields={fields}
onSearch={(v) => {
setF(v);
// 签约时间是范围控件,按源拆成起止两个参数再传给列表/导出。
const { signTime, ...rest } = v;
const range = signTime as unknown as Array<{ format: (f: string) => string }> | undefined;
setF({
...rest,
...(range?.length === 2
? {
signTimeStart: range[0].format('YYYY-MM-DD'),
signTimeEnd: range[1].format('YYYY-MM-DD'),
}
: {}),
});
setP((x) => ({ ...x, current: 1 }));
}}
onReset={() => setF({})}
...
...
@@ -107,17 +158,11 @@ export default function ContractTab() {
}}
/>
</UCard>
<
U
Modal
<
ImportContract
Modal
open={importOpen}
title="合同导入"
onCancel={() => setImportOpen(false)}
onOk={() => {
setImportOpen(false);
msg.info('请选择文件后将调用合同导入接口。');
}}
>
<p>请上传合同信息表。上传完成后将调用合同导入接口。</p>
</UModal>
onClose={() => setImportOpen(false)}
onSuccess={() => qc.invalidateQueries({ queryKey: ['op', 'contracts'] })}
/>
</>
);
}
apps/web/subapps/usedcar/src/pages/Operation/components/ImportContractModal.tsx
0 → 100644
View file @
4b4d68b
import { useState } from 'react';
import { useMutation } from '@tanstack/react-query';
import { UAlert, UButton, UModal, UText, UUpload, useUMessage } from '@uj/ui';
import { downloadCenter } from '@uj/platform-sdk';
import { contractApi } from '@/api';
import { uploadFileUrl } from '@/lib/ossUpload';
import { errorDetail } from '@/utils/error';
/**
* 源合同导入弹窗(contract/index.vue:202-282 + 946-1043):
* 选文件 → glsk-oss-jssdk 直传 OSS → 成功回调拿 aliyunAddress → 立刻调
* importContract({ fileUrl }) → 展示成功/失败记录。弹窗不自动关闭。
*/
const TEMPLATE_URL =
'https://jinrong-huidan-test.oss-cn-shenzhen.aliyuncs.com/template/15b20472-9d99-470d-aaff-67bcd243e0dc%E3%80%90%E6%A8%A1%E6%9D%BF%E3%80%91%E5%90%88%E5%90%8C%E5%AF%BC%E5%85%A5-V1.0.1.xlsx';
interface ImportResult {
succ?: number;
fail?: number;
failDownloadUrl?: string;
[key: string]: unknown;
}
interface ImportResponse {
code?: number;
msg?: string;
data?: ImportResult;
}
export default function ImportContractModal({
open,
onClose,
onSuccess,
}: {
open: boolean;
onClose: () => void;
onSuccess: () => void;
}) {
const msg = useUMessage();
const [fileName, setFileName] = useState('');
const [result, setResult] = useState<ImportResult | null>(null);
const importMutation = useMutation({
mutationFn: async (file: File) => {
const fileUrl = await uploadFileUrl(file);
return contractApi.importContract<ImportResponse>({ fileUrl });
},
onSuccess: (res) => {
if (res?.code !== undefined && res.code !== 0) {
msg.error(res.msg ?? '导入失败');
return;
}
setResult(res?.data ?? {});
msg.success('导入完成');
onSuccess();
},
onError: (error) => {
msg.error(errorDetail(error));
setResult(null);
},
});
const handleFile = (file: File) => {
const size = file.size / 1024 / 1024;
if (size >= 10) {
msg.error('上传文件不可超过 10M');
return false;
}
setFileName(file.name);
setResult(null);
importMutation.mutate(file);
// 与源一致:不让 antd 自己再上传一次,上传完全交给 OSS SDK。
return false;
};
return (
<UModal
open={open}
title="合同导入"
okText="关闭"
confirmLoading={false}
onCancel={onClose}
onOk={onClose}
width={560}
>
<UAlert
type="info"
showIcon
title="选择合同信息表后自动导入"
description="文件经 OSS 直传后自动提交导入,导入结果会显示在下方。可从右侧下载标准模板。"
style={{ marginBottom: 16 }}
/>
<div style={{ display: 'flex', gap: 8, alignItems: 'center' }}>
<UUpload
accept=".xls,.xlsx"
showUploadList={false}
maxCount={1}
disabled={importMutation.isPending}
beforeUpload={handleFile}
>
<UButton loading={importMutation.isPending}>添加附件</UButton>
</UUpload>
<UText>{fileName || '请选择需要导入的合同信息表格'}</UText>
</div>
<div style={{ marginTop: 12, textAlign: 'right' }}>
<UButton
type="link"
onClick={() =>
downloadCenter.url({
source: 'usedcar',
sourceLabel: '运营管理 / 合同管理 / 导入模板',
label: '合同导入模板',
url: TEMPLATE_URL,
fileName: '合同导入模板.xlsx',
silent: true,
dedupeKey: 'usedcar-contract-template',
})
}
>
下载模板
</UButton>
</div>
{result ? (
<UAlert
type={Number(result.fail) > 0 ? 'warning' : 'success'}
showIcon
title="操作结果"
description={
<div>
<div>
成功记录 <span style={{ color: '#2cca74' }}>{result.succ ?? 0}</span>
{' '}失败记录 <span style={{ color: '#eb4e4e' }}>{result.fail ?? 0}</span>
</div>
{result.failDownloadUrl ? (
<UButton
type="link"
onClick={() => window.open(result.failDownloadUrl, '_blank')}
style={{ paddingLeft: 0 }}
>
导出失败记录
</UButton>
) : null}
</div>
}
style={{ marginTop: 16 }}
/>
) : null}
</UModal>
);
}
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineDetailModal.tsx
View file @
4b4d68b
import {
UModal } from '@uj/ui
';
import {
CombiForm, type FieldSchema } from '@/components
';
import
type {
Sunshine } from '@/api';
import {
useQuery } from '@tanstack/react-query
';
import {
UModal, UTable, UAlert, UEmpty, UDescriptions } from '@uj/ui
';
import
{ operationApi, type
Sunshine } from '@/api';
const FIELDS: FieldSchema<Sunshine>[] = [
{ name: 'sellerMerchantName', label: '4S门店', type: 'input' },
{ name: 'carType', label: '车辆类型', type: 'input' },
{
name: 'sunlightInspiresPrice',
label: '激励价格',
type: 'input',
render: (value) => (value === undefined ? '-' : `¥${String(value)}`),
},
{ name: 'createdDate', label: '录入时间', type: 'input' },
/** 空值统一占位(与 usedcar 其它页面 text() 一致)。 */
const text = (value: unknown): string =>
value === undefined || value === null || value === '' ? '-' : String(value);
/** 源 constants.js vehicleCategoryOpt:carType 存 confId,展示 confValue。 */
const CAR_TYPE_LABEL: Record<string, string> = { '1': '置换车', '2': '报废车' };
type LogRow = { operator?: string; operateTime?: string; operateContent?: string; [key: string]: unknown };
const LOG_COLUMNS = [
{ title: '操作人', dataIndex: 'operator', render: text },
{ title: '操作时间', dataIndex: 'operateTime', render: text },
{ title: '操作内容', dataIndex: 'operateContent', render: text },
];
/** 阳光激励详情弹窗统一使用 CombiForm 的详情模式。 */
/**
* 阳光激励详情弹窗:与源 sunshine/components/detail.vue 一致,
* 打开时并行拉详情(details)与操作日志(log/page),不再拿列表行数据充当详情。
*/
export default function SunshineDetailModal({
record,
onClose,
...
...
@@ -22,9 +28,56 @@ export default function SunshineDetailModal({
record: Sunshine | null;
onClose: () => void;
}) {
const id = record?.id ?? '';
const detail = useQuery({
queryKey: ['op', 'sun', 'detail', id],
queryFn: () => operationApi.sunshineDetail(id),
enabled: Boolean(id),
});
const logs = useQuery({
queryKey: ['op', 'sun', 'log', id],
queryFn: () => operationApi.sunshineLog(id),
enabled: Boolean(id),
});
const data: Partial<Sunshine> = detail.data ?? record ?? {};
const logRows: LogRow[] = Array.isArray(logs.data) ? (logs.data as LogRow[]) : [];
return (
<UModal open={Boolean(record)} title="阳光激励详情" footer={null} onCancel={onClose}>
{record ? <CombiForm mode="detail" fields={FIELDS} initialValues={record} /> : null}
{detail.isError ? <UAlert type="error" showIcon title="详情加载失败" /> : null}
<UDescriptions
column={1}
items={[
{ key: 'store', label: '4S门店', children: text(data.sellerMerchantName) },
{
key: 'carType',
label: '车辆类型',
children: CAR_TYPE_LABEL[String(data.carType)] ?? text(data.carType),
},
{
key: 'price',
label: '激励价格',
children:
data.sunlightInspiresPrice === undefined
? '-'
: `${String(data.sunlightInspiresPrice)}元`,
},
{ key: 'createdDate', label: '录入时间', children: text(data.createdDate) },
]}
/>
<h4 style={{ margin: '16px 0 8px', fontSize: 14, fontWeight: 600 }}>操作日志</h4>
{logRows.length ? (
<UTable<LogRow>
rowKey={(_, index) => String(index)}
size="small"
pagination={false}
dataSource={logRows}
columns={LOG_COLUMNS}
/>
) : (
<UEmpty description="暂无操作日志" />
)}
</UModal>
);
}
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineFormModal.tsx
View file @
4b4d68b
import { useEffect, useState } from 'react';
import { useQuery } from '@tanstack/react-query';
import { UForm, UModal, useUMessage } from '@uj/ui';
import { CombiForm, type FieldSchema } from '@/components';
import { operationApi, type Sunshine } from '@/api';
import { useAppStore } from '@/store/useAppStore';
import { dashboardApi, operationApi, type StoreItem, type Sunshine } from '@/api';
import { errorDetail } from '@/utils/error';
interface Props {
record: Sunshine | null;
...
...
@@ -10,72 +13,102 @@ interface Props {
}
type SunshineFormValues = {
sellerMerchant
Name
: string;
sellerMerchant
Id
: string;
carType: string;
sunlightInspiresPrice: string;
};
/** 新增 / 修改激励字段及校验的唯一配置位置。 */
const FIELDS: FieldSchema<SunshineFormValues>[] = [
{
name: 'sellerMerchantName',
label: '4S门店',
type: 'input',
inputProps: { maxLength: 50 },
rules: [{ required: true, message: '请输入4S门店' }],
},
{
name: 'carType',
label: '车辆类型',
type: 'input',
inputProps: { maxLength: 50 },
rules: [{ required: true, message: '请输入车辆类型' }],
},
{
name: 'sunlightInspiresPrice',
label: '激励价格(元)',
type: 'input',
inputProps: { inputMode: 'decimal', maxLength: 10 },
rules: [
{ required: true, message: '请输入激励价格' },
{ pattern: /^\d+(\.\d{1,2})?$/, message: '请输入最多两位小数的正数' },
],
},
/**
* 源车辆类型字典 constants.js vehicleCategoryOpt:value 存 confId,展示 confValue。
* 与源 add.vue 的 carType 下拉一致:提交 id、列表按字典翻译。
*/
const CAR_TYPES = [
{ value: '1', label: '置换车' },
{ value: '2', label: '报废车' },
];
/** 新增 / 修改激励字段及校验的唯一配置位置。 */
function buildFields(stores: StoreItem[], editing: boolean): FieldSchema<SunshineFormValues>[] {
return [
{
name: 'sellerMerchantId',
label: '4S门店',
type: 'select',
options: stores.map((s) => ({ value: s.merchantId, label: s.merchantName })),
// 源 add.vue:编辑时门店不可改(isDisabled: paramsObj.id)。
selectProps: { showSearch: true, optionFilterProp: 'label', disabled: editing },
rules: [{ required: true, message: '请选择4S门店' }],
},
{
name: 'carType',
label: '车辆类型',
type: 'select',
options: CAR_TYPES,
rules: [{ required: true, message: '请选择车辆类型' }],
},
{
name: 'sunlightInspiresPrice',
label: '激励价格(元)',
type: 'input',
inputProps: { inputMode: 'decimal', maxLength: 10 },
rules: [
{ required: true, message: '请输入激励价格' },
{ pattern: /^\d+(\.\d{1,2})?$/, message: '请输入最多两位小数的正数' },
],
},
];
}
/** 新增与修改共用的独立表单弹窗。 */
export default function SunshineFormModal({ record, onClose, onSaved }: Props) {
const [form] = UForm.useForm<SunshineFormValues>();
const message = useUMessage();
const { currentUser } = useAppStore();
const [saving, setSaving] = useState(false);
const editing = Boolean(record?.id);
// 4S 门店下拉:源 add.vue 用 getServiceStore 的 storeIdList(merchantId/merchantName)。
const stores = useQuery({
queryKey: ['usedcar', 'service-store', 7],
queryFn: () => dashboardApi.getServiceStore({ scene: 7 }),
});
useEffect(() => {
if (!record) return;
form.setFieldsValue({
sellerMerchant
Name: record.sellerMerchantName
,
carType: record.carType,
sellerMerchant
Id: record.sellerMerchantId ?? ''
,
carType: record.carType
?? ''
,
sunlightInspiresPrice:
record.sunlightInspiresPrice === undefined ? '' : String(record.sunlightInspiresPrice),
});
}, [form, record]);
const save = async (values: SunshineFormValues) => {
const store = (stores.data ?? []).find((s) => s.merchantId === values.sellerMerchantId);
const payload: Record<string, unknown> = {
sellerMerchantId: values.sellerMerchantId,
sellerMerchantName: store?.merchantName ?? record?.sellerMerchantName ?? '',
carType: values.carType,
sunlightInspiresPrice: Number(values.sunlightInspiresPrice),
};
// 源 add.vue:229/231:新增带 createdBy、编辑带 updatedBy(取当前登录用户名)。
if (editing) payload.updatedBy = currentUser.name;
else payload.createdBy = currentUser.name;
setSaving(true);
try {
const price = Number(values.sunlightInspiresPrice);
const payload = {
sellerMerchantName: String(values.sellerMerchantName),
carType: String(values.carType),
sunlightInspiresPrice: price,
};
if (editing) await operationApi.updateSunshine({ ...payload, id: record!.id });
else await operationApi.createSunshine(payload);
message.success('操作成功');
onSaved();
onClose();
} catch (error) {
message.error(errorDetail(error));
} finally {
setSaving(false);
}
};
return (
<UModal
open={Boolean(record)}
...
...
@@ -87,7 +120,7 @@ export default function SunshineFormModal({ record, onClose, onSaved }: Props) {
<CombiForm
mode="form"
form={form}
fields={
FIELDS
}
fields={
buildFields(stores.data ?? [], editing)
}
layout="vertical"
onSubmit={(values) => void save(values)}
/>
...
...
apps/web/subapps/usedcar/src/pages/Operation/components/SunshineTab.tsx
View file @
4b4d68b
import { useState } from 'react';
import { useQuery, useQueryClient } from '@tanstack/react-query';
import { UCard, useUMessage } from '@uj/ui';
import { DataTable, SearchForm, type FieldSchema, type RowActionSchema } from '@/components';
import {
DataTable,
SearchForm,
ConfirmModal,
type FieldSchema,
type RowActionSchema,
} from '@/components';
import { useAccess } from '@/access';
import {
operationApi
, type Sunshine } from '@/api';
import {
dashboardApi, operationApi, type StoreItem
, type Sunshine } from '@/api';
import { UC } from '@/permissions/codes';
import { SUNSHINE_COLUMNS } from './tableConfig';
import SunshineFormModal from './SunshineFormModal';
import SunshineDetailModal from './SunshineDetailModal';
import { downloadCenter } from '@uj/platform-sdk';
import { errorDetail } from '@/utils/error';
/** 源 constants.js vehicleCategoryOpt:与表单下拉共用 confId → confValue。 */
const CAR_TYPES = [
{ value: '1', label: '置换车' },
{ value: '2', label: '报废车' },
];
type SunshineFilters = Record<string, unknown>;
export default function SunshineTab() {
const { canPoint } = useAccess(),
msg = useUMessage(),
qc = useQueryClient();
const [p, setP] = useState({ current: 1, size: 10 });
const [f, setF] = useState<
Record<string, unknown>
>({});
const [f, setF] = useState<
SunshineFilters
>({});
const [edit, setEdit] = useState<Sunshine | null>(null);
const [detail, setDetail] = useState<Sunshine | null>(null);
const [pendingDelete, setPendingDelete] = useState<Sunshine | null>(null);
// 4S 门店下拉(列表筛选 + 新增共用同一份门店数据)。
const stores = useQuery({
queryKey: ['usedcar', 'service-store', 7],
queryFn: () => dashboardApi.getServiceStore({ scene: 7 }),
});
const toParams = (filters: SunshineFilters) => ({
...filters,
currentPage: p.current,
pageSize: p.size,
});
const q = useQuery({
queryKey: ['op', 'sun', p, f],
queryFn: () => operationApi.sunshine(
{ currentPage: p.current, pageSize: p.size, t: f }
),
queryFn: () => operationApi.sunshine(
toParams(f)
),
});
const reload = () => qc.invalidateQueries({ queryKey: ['op', 'sun'] });
const actions: RowActionSchema<Sunshine>[] = [
{ label: '详情', permission: UC.INCENTIVE_DETAIL, onClick: setDetail },
{ label: '修改', permission: UC.INCENTIVE_UPDATE, onClick: setEdit },
{
label: '删除',
permission: UC.INCENTIVE_DELETE,
onClick: async (r) => {
await operationApi.deleteSunshine(r.id);
reload();
msg.success('已删除');
},
onClick: (r) => setPendingDelete(r),
},
];
const fields: FieldSchema<Record<string, unknown>>[] = [
{ name: 'sellerMerchantName', label: '4S门店', type: 'input', essential: true },
{ name: 'carType', label: '车辆类型', type: 'input', essential: true },
const fields: FieldSchema<SunshineFilters>[] = [
{
name: 'sellerMerchantIds',
label: '4S门店',
type: 'selectMultiple',
options: (stores.data ?? []).map((s: StoreItem) => ({
value: s.merchantId,
label: s.merchantName,
})),
},
{ name: 'carType', label: '车辆类型', type: 'select', options: CAR_TYPES },
{
name: 'sunlightInspiresPriceBegin',
label: '激励价格起',
type: 'input',
inputProps: { inputMode: 'decimal' },
},
{
name: 'sunlightInspiresPriceEnd',
label: '激励价格止',
type: 'input',
inputProps: { inputMode: 'decimal' },
},
{ name: 'createdDate', label: '录入时间', type: 'dateRange' },
];
const doDelete = async () => {
if (!pendingDelete) return;
try {
await operationApi.deleteSunshine(pendingDelete.id);
msg.success('已删除');
setPendingDelete(null);
reload();
} catch (error) {
msg.error(errorDetail(error));
}
};
return (
<>
<UCard className="uj-filter-card" size="small">
...
...
@@ -68,7 +130,19 @@ export default function SunshineTab() {
label: '导出',
tone: 'export' as const,
onClick: () =>
operationApi.exportSunshine(f).then(() => msg.success('导出任务已提交')),
downloadCenter.asyncExport({
source: 'usedcar',
sourceLabel: '运营管理 / 阳光激励',
label: '阳光激励导出',
method: '/sunlightInspiresConfig/export',
params: {
...f,
currentPage: 1,
server_provider_type: 'gsc',
server_provider_name: 'gsc-vcp-web-facade',
},
dedupeKey: 'operation-sunshine-export',
}),
},
]
: []),
...
...
@@ -83,6 +157,12 @@ export default function SunshineTab() {
</UCard>
<SunshineFormModal record={edit} onClose={() => setEdit(null)} onSaved={reload} />
<SunshineDetailModal record={detail} onClose={() => setDetail(null)} />
<ConfirmModal
open={Boolean(pendingDelete)}
content="请确认是否要执行当前操作?删除后不可恢复。"
onCancel={() => setPendingDelete(null)}
onConfirm={() => void doDelete()}
/>
</>
);
}
apps/web/subapps/usedcar/src/pages/Operation/components/tableConfig.tsx
View file @
4b4d68b
...
...
@@ -2,21 +2,48 @@ import type { DataTableColumnsType } from '@/components';
import type { Contract, Sunshine } from '@/api';
/** 运营管理表格列的唯一配置位置;页面只负责数据和操作。 */
const cell = (v: unknown) => (v === undefined || v === null || v === '' ? '-' : String(v));
/** 对齐源 contract/index.vue 的高频列;字典类暂以接口返回值直出(后端口径待真机核对)。 */
export const CONTRACT_COLUMNS: DataTableColumnsType<Contract> = [
{ title: '车牌号', dataIndex: 'licensePlate' },
{ title: '车架号', dataIndex: 'vin' },
{ title: '车牌号', dataIndex: 'licensePlate'
, render: cell
},
{ title: '车架号', dataIndex: 'vin'
, render: cell
},
{
title: '车型',
render: (_, row) =>
[row.carBrand, row.carSeriesName, row.carTypeName].filter(Boolean).join(' ') || '-',
},
{ title: '评估单编号', dataIndex: 'evalOrderNo' },
{ title: '合同状态', dataIndex: 'electronicContractStatus' },
{ title: '合同编号', dataIndex: 'contractNo', render: cell },
{ title: '评估单编号', dataIndex: 'evalOrderNo', render: cell },
{
title: '合同类型',
dataIndex: 'electronicContractType',
render: cell,
},
{ title: '合同模版', dataIndex: 'docTemplateName', render: cell },
{ title: '签约时间', dataIndex: 'signTime', render: cell },
{ title: '驻店人员', dataIndex: 'createdBy', render: cell },
{ title: '车主姓名', dataIndex: 'previousOwnerName', render: cell },
{ title: '车主电话', dataIndex: 'previousOwnerPhone', render: cell },
{ title: '支付状态', dataIndex: 'oaFlowPaymentStatus', render: cell },
{ title: '企微审批单号', dataIndex: 'lastOaFlowCode', render: cell },
{ title: '合同金额', dataIndex: 'contractPrice', render: cell },
{ title: '合同状态', dataIndex: 'electronicContractStatus', render: cell },
];
/** 源 constants.js vehicleCategoryOpt:carType 存 confId,列表按字典翻译。 */
const CAR_TYPE_LABEL: Record<string, string> = { '1': '置换车', '2': '报废车' };
export const SUNSHINE_COLUMNS: DataTableColumnsType<Sunshine> = [
{ title: '4S门店', dataIndex: 'sellerMerchantName' },
{ title: '车辆类型', dataIndex: 'carType' },
{
title: '车辆类型',
dataIndex: 'carType',
render: (value) => {
const v = String(value ?? '');
return CAR_TYPE_LABEL[v] || v || '-';
},
},
{
title: '激励价格',
dataIndex: 'sunlightInspiresPrice',
...
...
apps/web/subapps/usedcar/src/pages/Operation/contractDetail.css
0 → 100644
View file @
4b4d68b
.uc-contract-detail
{
display
:
grid
;
gap
:
16px
;
}
.uc-contract-detail__title
{
display
:
flex
;
align-items
:
center
;
gap
:
10px
;
margin
:
0
0
16px
;
font-size
:
15px
;
}
.uc-contract-detail__subtitle
{
margin
:
16px
0
8px
;
font-size
:
13px
;
color
:
var
(
--uj-text-2
);
}
.uc-contract-detail__desc
{
max-width
:
100%
;
}
.uc-contract-detail__actions
{
display
:
flex
;
justify-content
:
flex-end
;
margin-top
:
12px
;
}
.uc-contract-detail__fields
{
display
:
grid
;
gap
:
12px
;
}
.uc-contract-detail__field
{
display
:
grid
;
grid-template-columns
:
140px
minmax
(
0
,
1
fr
);
gap
:
8px
;
align-items
:
start
;
}
.uc-contract-detail__field-label
{
color
:
var
(
--uj-text-2
);
}
.uc-contract-detail__field-value
{
display
:
flex
;
flex-wrap
:
wrap
;
gap
:
8px
;
align-items
:
center
;
}
.uc-contract-detail__thumb
{
width
:
72px
;
height
:
72px
;
object-fit
:
cover
;
border-radius
:
6px
;
cursor
:
zoom-in
;
border
:
1px
solid
var
(
--uj-border
,
#e5e7eb
);
}
.uc-contract-detail__signer
+
.uc-contract-detail__signer
{
margin-top
:
8px
;
}
.uc-contract-detail__logs
{
display
:
grid
;
gap
:
10px
;
}
.uc-contract-detail__log
{
display
:
flex
;
gap
:
20px
;
align-items
:
center
;
border-left
:
2px
solid
#1677ff
;
padding-left
:
14px
;
color
:
var
(
--uj-text-2
);
}
.uc-contract-detail__log
b
{
color
:
var
(
--uj-text-1
);
font-weight
:
500
;
}
@media
(
max-width
:
900px
)
{
.uc-contract-detail__field
{
grid-template-columns
:
1
fr
;
}
.uc-contract-detail__log
{
flex-direction
:
column
;
gap
:
4px
;
}
}
apps/web/subapps/usedcar/src/pages/Operation/contractDetailConfig.ts
0 → 100644
View file @
4b4d68b
import
type
{
ContractDetail
,
ContractSigner
}
from
'@/api'
;
/**
* 合同详情展示配置 —— 字典与取数规则逐字对照源系统
* src/common/constants.js 与 .../contract/detail.vue 的 configData。
* 页面只按这里的配置渲染,新增/调整字典不改页面结构。
*/
/** 字典项:confId 用字符串比较(源返回数字/字符串混用),value 为展示文案,tone 映射 UTag 配色。 */
export
interface
DictItem
{
confId
:
string
;
value
:
string
;
tone
?:
'blue'
|
'green'
|
'orange'
|
'red'
|
'default'
;
}
export
const
DICT
=
{
/** 合同流转状态 electronicContractStatusOpt */
status
:
[
{
confId
:
'1'
,
value
:
'合同签署中'
,
tone
:
'orange'
},
{
confId
:
'2'
,
value
:
'合同签署完成'
,
tone
:
'green'
},
]
as
DictItem
[],
/** 合同来源 electronicContractOpt */
source
:
[
{
confId
:
'1'
,
value
:
'系统生成'
},
{
confId
:
'2'
,
value
:
'人工导入'
},
]
as
DictItem
[],
/** 付款方式 paymentMethodOpt */
paymentMethod
:
[
{
confId
:
'1'
,
value
:
'银行转账'
},
{
confId
:
'2'
,
value
:
'冲账'
},
]
as
DictItem
[],
/** 合同类型 electronicContractTypeOpt */
contractType
:
[
{
confId
:
'1'
,
value
:
'二手车转让协议'
},
{
confId
:
'3'
,
value
:
'二手车补充协议'
},
{
confId
:
'2'
,
value
:
'车辆代保管协议'
},
{
confId
:
'4'
,
value
:
'车辆交接确认单'
},
]
as
DictItem
[],
/** 支付方式 payStatusOpt */
payType
:
[
{
confId
:
'1'
,
value
:
'定金'
},
{
confId
:
'2'
,
value
:
'尾款'
},
{
confId
:
'3'
,
value
:
'全款'
},
]
as
DictItem
[],
/** 支付状态 oaFlowPaymentStatusOpt */
payStatus
:
[
{
confId
:
'1'
,
value
:
'支付中'
,
tone
:
'orange'
},
{
confId
:
'2'
,
value
:
'支付成功'
,
tone
:
'green'
},
{
confId
:
'3'
,
value
:
'支付失败'
,
tone
:
'red'
},
{
confId
:
'4'
,
value
:
'支付取消'
,
tone
:
'default'
},
]
as
DictItem
[],
/** 企微审批状态 oaFlowStatusOpt */
oaFlowStatus
:
[
{
confId
:
'1'
,
value
:
'审批中'
,
tone
:
'orange'
},
{
confId
:
'2'
,
value
:
'已通过'
,
tone
:
'green'
},
{
confId
:
'3'
,
value
:
'已驳回'
,
tone
:
'red'
},
{
confId
:
'4'
,
value
:
'已撤销'
,
tone
:
'default'
},
]
as
DictItem
[],
};
export
const
display
=
(
value
:
unknown
):
string
=>
value
===
undefined
||
value
===
null
||
value
===
''
?
'-'
:
String
(
value
);
/** 按字典取展示文案,未命中时回落原值(源 getStatusItem 取 confValue 的等价实现)。 */
export
function
dictValue
(
dict
:
DictItem
[],
value
:
unknown
):
string
{
if
(
value
===
undefined
||
value
===
null
||
value
===
''
)
return
'-'
;
const
hit
=
dict
.
find
((
item
)
=>
item
.
confId
===
String
(
value
));
return
hit
?
hit
.
value
:
String
(
value
);
}
/** 按字典取标签配色,未命中给默认灰。 */
export
function
dictTone
(
dict
:
DictItem
[],
value
:
unknown
):
'blue'
|
'green'
|
'orange'
|
'red'
|
'default'
{
return
dict
.
find
((
item
)
=>
item
.
confId
===
String
(
value
))?.
tone
??
'default'
;
}
/** 合同车型:carBase 品牌 + 车系 + 车型,逐字沿用源 formatter。 */
export
function
contractModel
(
data
:
ContractDetail
):
string
{
const
base
=
data
.
carBase
??
{};
return
[
base
.
carBrand
,
base
.
carSeriesName
,
base
.
carTypeName
].
filter
(
Boolean
).
join
(
' '
)
||
'-'
;
}
/** 解析电子合同签署人字段:源返回 JSON 字符串,个别环境直接下发对象。 */
export
function
parseSigners
(
raw
:
ContractDetail
[
'electronicContractField'
]):
ContractSigner
{
if
(
!
raw
)
return
{};
if
(
typeof
raw
===
'string'
)
{
try
{
const
parsed
:
unknown
=
JSON
.
parse
(
raw
);
return
parsed
&&
typeof
parsed
===
'object'
?
(
parsed
as
ContractSigner
)
:
{};
}
catch
{
return
{};
}
}
return
raw
;
}
/** 签署人类型:逐字沿用源 detail.vue subData「签署人类型」formatter。 */
export
function
signerTypeName
(
data
:
ContractDetail
,
signIndex
:
1
|
2
):
string
{
const
signers
=
parseSigners
(
data
.
electronicContractField
);
const
contractType
=
Number
(
data
.
electronicContractType
??
signers
.
electronicContractType
);
const
signerType
=
signers
.
signerType
;
if
(
signIndex
===
1
)
{
const
isEnterprise
=
contractType
===
2
||
(
signerType
!==
0
&&
signerType
!==
1
);
return
isEnterprise
?
'企业'
:
'个人'
;
}
return
contractType
===
2
?
'个人'
:
'企业'
;
}
/** 签署人信息行配置:keyA 甲方 / keyB 乙方,来自解析后的 electronicContractField。 */
export
const
SIGNER_FIELDS
:
Array
<
{
title
:
string
;
keyA
?:
keyof
ContractSigner
;
keyB
?:
keyof
ContractSigner
;
kind
?:
'side'
|
'type'
|
'idType'
;
}
>
=
[
{
title
:
'所属方'
,
kind
:
'side'
},
{
title
:
'签署人类型'
,
kind
:
'type'
},
{
title
:
'签署人公司'
,
keyA
:
'partAName'
,
keyB
:
'partBName'
},
{
title
:
'签署人姓名'
,
keyA
:
'partAContactName'
,
keyB
:
'partBContactName'
},
{
title
:
'签署人手机号码'
,
keyA
:
'partAContactMobile'
,
keyB
:
'partBContactMobile'
},
{
title
:
'签署人证件类型'
,
kind
:
'idType'
},
{
title
:
'签署人证件号'
,
keyA
:
'partAIdentityCode'
,
keyB
:
'partBIdentityCode'
},
];
/** 操作记录 opType 文案:源模板 v-if 链。 */
export
function
logTypeName
(
opType
:
unknown
):
string
{
const
n
=
Number
(
opType
);
return
n
===
1
?
'新增合同描述'
:
n
===
2
?
'修改合同描述'
:
n
===
3
?
'批量导入合同'
:
'合同编辑'
;
}
/**
* 按「逗号 + http」分割 URL 串,避免 OSS query 中的逗号(如 quality,q_100)误分割。
* 逐字沿用源 detail.vue splitUrls。
*/
export
function
splitUrls
(
raw
:
unknown
):
string
[]
{
if
(
!
raw
||
typeof
raw
!==
'string'
)
return
[];
return
raw
.
split
(
/,
\s
*
(?=
https
?
:
\/\/)
/
)
.
map
((
s
)
=>
s
.
trim
())
.
filter
(
Boolean
);
}
/** 按扩展名判定图片/视频(去 query、兼容 OSS 处理参数),逐字沿用源 getFileType。 */
export
function
fileType
(
url
:
string
):
'image'
|
'video'
|
'unknown'
{
const
imageExt
=
[
'jpg'
,
'jpeg'
,
'png'
,
'gif'
,
'bmp'
,
'webp'
,
'svg'
];
const
videoExt
=
[
'mp4'
,
'avi'
,
'mov'
,
'wmv'
,
'flv'
,
'webm'
,
'mkv'
];
const
pathname
=
url
.
split
(
'?'
)[
0
];
const
ext
=
pathname
.
split
(
'.'
).
pop
()?.
toLowerCase
()
??
''
;
if
(
imageExt
.
includes
(
ext
))
return
'image'
;
if
(
videoExt
.
includes
(
ext
))
return
'video'
;
if
(
/x-oss-process=image
\/
format,
\w
+/
.
test
(
url
))
return
'image'
;
return
'unknown'
;
}
/** 图片缩略图 URL:源 getOssImageUrl,追加 `x-oss-process=image/format,jpg/quality,q_100`。 */
export
function
ossThumb
(
url
:
string
):
string
{
if
(
!
url
||
url
.
includes
(
'x-oss-process='
))
return
url
;
return
`
${
url
}${
url
.
includes
(
'?'
)
?
'&'
:
'?'
}
x-oss-process=image/format,jpg/quality,q_100`
;
}
docs/PORT_CONVERSION.md
View file @
4b4d68b
...
...
@@ -200,7 +200,8 @@ UResult UEmpty USteps UTimeline UDropdown UDatePicker URadio USwit
##
9
.
页面骨架与路由
-
**
页面外壳
**
用
`PageShell`
(标题
/
说明
/
返回
/
右上角动作
/
内容)。列表页
`fill`
开整屏定高。
-
**
页面外壳
**
用
`PageShell`
(标题
/
说明
/
右上角动作
/
内容)。列表页
`fill`
开整屏定高。
-
**
返回不在页面上
**
:主壳顶栏在面包屑左侧给一个返回键(图标
+
「返回」),判据是地址层级
——
比命中的菜单路径更深一级才算二级页,回的目标就是那条菜单路径。它
**
不常驻占位
**
:一级页槽位宽
0
,二级页
180
ms
展开到
72
px
(键面
64
=
8
+
18
+
4
+
13
×
2
+
8
,再加
8
呼吸),面包屑是被推出去的不是啪一下跳走;
hover
的
tooltip
点名去处「返回『线索管理』」。所以详情页的地址必须挂在它自己的菜单页下面(
`/points/withdraw/batch/1`
,不是
`/points/batch/1`
);平铺在域根的详情既没有返回,也没有面包屑与菜单高亮。
-
**
路由查表
**
(
`apps/web/subapps/points/src/App.tsx`
+
`routes.ts`
):子应用维护一个
`ROUTES: RouteDef[]`
,用
`matchRoute`
按段匹配
`subPath`
。
**
不要
switch
、不要手写路由分发
**
(子应用内部
`BrowserRouter`
只提供
router
context
,不做分发)。
-
**
主壳
URL
是唯一真源
**
:
`/points/withdraw`
这种「子应用前缀
+
页名」由主壳经
bus
的
`<name>:navigate`
下发
`subPath`
,子应用查表渲染。未知页名显示明确错误页,不静默渲染一个看起来正常的页。
-
**
握手
**
:
`bus.$emit(events.ready)`
通知主壳已就绪;订阅
`navigate`
/
`logout`
。主壳
`SubAppProvider`
已封装,照
`points/src/App.tsx`
抄。
...
...
packages/biz/src/components/PageShell/index.tsx
View file @
4b4d68b
import type { ReactNode } from 'react';
import { UButton } from '@uj/ui';
export interface PageShellProps {
title: ReactNode;
/** 一句说明这个页面能做什么;写业务动作,不写字段名。 */
description?: ReactNode;
/** 子页面用:返回上一级。路由跳转方式由调用方提供,共享层不认识具体子应用的路由表。 */
onBack?: () => void;
/** 返回按钮文案,默认「返回」。 */
backLabel?: string;
/** 右上角动作区。 */
actions?: ReactNode;
/**
...
...
@@ -20,23 +15,18 @@ export interface PageShellProps {
}
/**
* 三个子应用共用的页面外壳:标题 + 说明 +
返回 +
右上角动作 + 内容。
* 三个子应用共用的页面外壳:标题 + 说明 + 右上角动作 + 内容。
*
* 统一这一层的原因:system 用内联 `padding: 10` 自己拼一遍、points 有 PageShell、
* store 又是第三套 .store-page/.store-page-header —— 同一件事三个写法,
* 标题字号、说明行高、动作间距全靠各自记,页面一多就参差。
*
* 只到页面骨架为止:控件、筛选、表格仍然是各页自己配(见「页面抽象阶梯」)。
*
* 这里没有「返回」:返回是导航,归顶栏面包屑左侧(BasicLayout 按地址层级判定),
* 页面自己不再摆一个返回按钮 —— 否则同一个意图在两处各配一份,还会各说各的目标页。
*/
export function PageShell({
title,
description,
onBack,
backLabel = '返回',
actions,
fill = false,
children,
}: PageShellProps) {
export function PageShell({ title, description, actions, fill = false, children }: PageShellProps) {
return (
<div className={fill ? 'uj-page uj-page--fill' : 'uj-page'}>
<div className="uj-page__header">
...
...
@@ -44,12 +34,7 @@ export function PageShell({
<h2 className="uj-page__title">{title}</h2>
{description ? <p className="uj-page__desc">{description}</p> : null}
</div>
{onBack || actions ? (
<div className="uj-page__tools">
{onBack ? <UButton onClick={onBack}>{backLabel}</UButton> : null}
{actions}
</div>
) : null}
{actions ? <div className="uj-page__tools">{actions}</div> : null}
</div>
{fill ? <div className="uj-page__body">{children}</div> : children}
</div>
...
...
packages/contracts/src/download-center.ts
View file @
4b4d68b
...
...
@@ -144,3 +144,18 @@ export interface RegisterExportTaskInput extends CommonDownloadInput {
export
const
DOWNLOAD_CENTER_REGISTER_EVENT
=
'uj:download-center:register'
;
/** 子应用 -> 主壳:取消一个任务(payload 为 taskId)。 */
export
const
DOWNLOAD_CENTER_CANCEL_EVENT
=
'uj:download-center:cancel'
;
/**
* 子应用 -> 主壳:注册一个请求通道(供下载任务的 handler 按 channel 名选用)。
*
* payload: `{ name: string; request: RemoteRequestFn }`。函数经 wujie bus 引用传递
* (同源 iframe,不序列化),解决「ROP/GSC 凭据与客户端在子应用、下载引擎在主壳」
* 的跨 realm 问题。典型用途:源系统的异步导出编排接口走 ROP 主网关,
* 由持有 ROP 凭据的子应用注册 `rop` 通道,任务带 `channel: 'rop'` 即可。
*/
export
const
DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT
=
'uj:download-center:register-channel'
;
/**
* ROP 主网关(SHA1 表单签名)的通道名,与源系统 dj.api.common.* 编排接口对齐。
* 按 source 命名(rop:<source>)避免多个持有各自 ROP 凭据的子应用互相覆盖通道。
*/
export
const
downloadChannelRop
=
(
source
:
string
):
string
=>
`rop:
${
source
}
`
;
packages/download-center/src/DownloadCenterButton.tsx
View file @
4b4d68b
...
...
@@ -5,7 +5,7 @@ import { useDownloadCenterStore } from './store';
import { cancelTask, removeTask, redownload } from './engine';
import type { DownloadTaskStatus, DownloadTask } from './types';
type TaskFilter = 'all' | 'success' | 'failed';
type TaskFilter = 'all' | '
active' | '
success' | 'failed';
/** 头部统计卡:展示数量,点击切换对应筛选。 */
function StatFilter({
...
...
@@ -132,6 +132,7 @@ export function DownloadCenterButton() {
const hasFinished = tasks.some((t) => FINISHED.has(t.status));
const filteredTasks = useMemo(() => {
if (filter === 'active') return tasks.filter((t) => IN_FLIGHT.has(t.status));
if (filter === 'success') return tasks.filter((t) => t.status === 'done');
if (filter === 'failed') return tasks.filter((t) => t.status === 'failed');
return tasks;
...
...
@@ -163,6 +164,13 @@ export function DownloadCenterButton() {
<div style={{ display: 'flex', gap: 8, marginTop: 8 }}>
<StatFilter label="总数量" count={tasks.length} active={filter === 'all'} onClick={() => setFilter('all')} />
<StatFilter
label="进行中"
count={activeCount}
active={filter === 'active'}
countColor="#1677ff"
onClick={() => setFilter('active')}
/>
<StatFilter
label="成功数量"
count={successCount}
active={filter === 'success'}
...
...
@@ -301,7 +309,7 @@ export function DownloadCenterButton() {
type="text"
aria-label="下载中心"
icon={<DownloadOutlined />}
className=
"uj-header-icon-btn"
className=
{`uj-header-icon-btn${activeCount > 0 ? ' uj-download-active' : ''}`}
/>
</Badge>
</Popover>
...
...
packages/download-center/src/DownloadCenterProvider.tsx
View file @
4b4d68b
...
...
@@ -5,9 +5,11 @@ import type { RegisterDownloadInput, RemoteRequestFn } from '@uj/contracts';
import {
DOWNLOAD_CENTER_REGISTER_EVENT,
DOWNLOAD_CENTER_CANCEL_EVENT,
DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT,
} from '@uj/contracts';
import {
configureDownloadCenter,
registerChannel,
startDownloadCenter,
stopDownloadCenter,
cancelTask,
...
...
@@ -28,6 +30,12 @@ import type { DownloadTask } from './types';
* ⚠️ 这里刻意不做「自动下载」:落地动作统一由各 DownloadHandler 内部按
* input.autoDownload 执行。Provider 再触发一次会导致同一个文件下载两遍。
*/
/** 提交通知的 key:按任务 id 稳定,便于终态到来时精确关掉这条「进行中」提示。 */
function submitNoticeKey(taskId: string): string {
return `uj:download-center:submit:${taskId}`;
}
export function DownloadCenterProvider({
request,
children,
...
...
@@ -48,8 +56,15 @@ export function DownloadCenterProvider({
const id = args[0];
if (typeof id === 'string') cancelTask(id);
};
const onRegisterChannel = (...args: unknown[]) => {
const payload = args[0] as { name?: unknown; request?: unknown } | undefined;
if (payload && typeof payload.name === 'string' && typeof payload.request === 'function') {
registerChannel(payload.name, payload.request as RemoteRequestFn);
}
};
bus.$on(DOWNLOAD_CENTER_REGISTER_EVENT, onRegister);
bus.$on(DOWNLOAD_CENTER_CANCEL_EVENT, onCancel);
bus.$on(DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT, onRegisterChannel);
// 通知去重:按「任务的第几次尝试」去重,而不是按任务 id 永久去重。
//
...
...
@@ -66,12 +81,36 @@ export function DownloadCenterProvider({
if (t.status === 'done' || t.status === 'failed') notifiedAt.set(t.id, t.updatedAt);
});
// 提交提示去重:新建的异步导出任务入队时提示一次「已提交,后台生成中」,
// 让用户点完立刻确认任务已被接受、无需守在页面等结果。
// 挂载时已存在的任务(含刷新恢复的 waiting)一律视为历史,不补弹。
const submittedNotified = new Set<string>(
useDownloadCenterStore.getState().tasks.map((t) => t.id),
);
const unsubscribe = useDownloadCenterStore.subscribe((state) => {
state.tasks.forEach((t: DownloadTask) => {
// 异步导出是长任务:提交那一刻必须给即时反馈,否则点了没反应,用户
// 不知道后台已开始生成(源系统靠铃铛红点 + 2s 自动弹任务面板提示)。
if (t.kind === 'async-export' && !submittedNotified.has(t.id) && !t.input.silent) {
submittedNotified.add(t.id);
notification.info({
key: submitNoticeKey(t.id),
title: '导出任务已提交',
description: `${t.label}正在后台生成,完成后将自动下载。可在顶部下载中心查看进度。`,
placement: 'top',
});
}
if (t.status !== 'done' && t.status !== 'failed') return;
if (notifiedAt.get(t.id) === t.updatedAt) return; // 这一次终态已提示过
notifiedAt.set(t.id, t.updatedAt);
// 先关掉这条任务的「已提交」提示,再弹终态通知。
// 否则秒级失败时,两条 top 通知会叠在一起(提交 + 失败),
// 逻辑上失败应发生在提交之后,进行中的提示此时已过时。
notification.destroy(submitNoticeKey(t.id));
if (t.status === 'done') {
// silent 只压「完成」类提示;失败永远要提示,不能被 silent 吞掉。
if (t.input.silent) return;
...
...
@@ -101,6 +140,7 @@ export function DownloadCenterProvider({
return () => {
bus.$off(DOWNLOAD_CENTER_REGISTER_EVENT, onRegister);
bus.$off(DOWNLOAD_CENTER_CANCEL_EVENT, onCancel);
bus.$off(DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT, onRegisterChannel);
unsubscribe();
stopDownloadCenter();
};
...
...
packages/download-center/src/engine.ts
View file @
4b4d68b
...
...
@@ -33,9 +33,22 @@ export function configureDownloadCenter(opts: {
opts
.
handlers
?.
forEach
((
h
)
=>
registerHandler
(
h
.
kind
,
h
));
}
/** 运行时追加通道(例如老业务网关在拿到配置后再注册)。 */
/**
* 任务所需通道是否已就绪。
* host 在 configureDownloadCenter 时恒定注册;具名通道(rop:<source>)由子应用
* 挂载后经 bus 注册。刷新恢复的任务可能在子应用挂载前就进入 waiting,此时必须
* 等通道就绪再跑,否则 requestFor 会静默 fallback 到 host(web 网关)→ 10004。
*/
function
channelReady
(
task
:
DownloadTask
):
boolean
{
const
name
=
task
.
input
.
channel
;
return
!
name
||
name
===
'host'
||
channels
.
has
(
name
);
}
/** 运行时追加通道(例如 ROP 网关在子应用挂载拿到凭据后注册)。 */
export
function
registerChannel
(
name
:
string
,
fn
:
RemoteRequestFn
):
void
{
channels
.
set
(
name
,
fn
);
// 通道就绪后立即拉起等待它的任务:刷新恢复的异步导出就靠这一步续轮询。
schedule
();
}
function
requestFor
(
task
:
DownloadTask
):
RemoteRequestFn
{
...
...
@@ -46,6 +59,27 @@ function statusOf(id: string): DownloadTask['status'] | undefined {
return
useDownloadCenterStore
.
getState
().
tasks
.
find
((
t
)
=>
t
.
id
===
id
)?.
status
;
}
/**
* 跨 realm 安全地提取错误文案。
*
* 请求通道可能来自子应用 realm(如 ROP 通道由 usedcar 的 postRop 提供),
* 它抛出的 RequestError / Error 在主壳 `instanceof Error === false`——项目
* api-core/errors.ts 已明确禁止用 instanceof 判定这类错误。这里改读实例自有
* 字段:message 是人话文案,code 是后端业务码(如 ROP 的 -1),拼出来让提示
* 直接显示后端原因,而不是一律降级成「下载失败」。
*/
function
describeTaskError
(
error
:
unknown
):
string
{
if
(
!
error
||
typeof
error
!==
'object'
)
return
'下载失败'
;
const
e
=
error
as
{
message
?:
unknown
;
code
?:
unknown
;
isRequestError
?:
unknown
};
const
message
=
typeof
e
.
message
===
'string'
&&
e
.
message
?
e
.
message
:
error
instanceof
Error
?
error
.
message
:
''
;
if
(
!
message
)
return
'下载失败'
;
// 业务码有诊断价值(如 -1=后端生成失败),但别把 code=200 之类成功码带进来。
const
code
=
e
.
code
;
const
hasCode
=
(
typeof
code
===
'string'
||
typeof
code
===
'number'
)
&&
String
(
code
)
!==
''
;
return
hasCode
&&
!
message
.
includes
(
String
(
code
))
?
`
${
message
}
(code:
${
String
(
code
)}
)`
:
message
;
}
async
function
runOne
(
task
:
DownloadTask
):
Promise
<
void
>
{
const
handler
=
handlerOf
(
task
);
if
(
!
handler
)
{
...
...
@@ -96,7 +130,7 @@ async function runOne(task: DownloadTask): Promise<void> {
useDownloadCenterStore
.
getState
().
patch
(
task
.
id
,
{
status
:
'failed'
,
stage
:
'失败'
,
error
:
e
instanceof
Error
?
e
.
message
:
'下载失败'
,
error
:
describeTaskError
(
e
)
,
});
}
}
finally
{
...
...
@@ -115,7 +149,7 @@ function schedule(): void {
if
(
slots
<=
0
)
return
;
const
waiting
=
useDownloadCenterStore
.
getState
()
.
tasks
.
filter
((
t
)
=>
t
.
status
===
'waiting'
)
.
tasks
.
filter
((
t
)
=>
t
.
status
===
'waiting'
&&
channelReady
(
t
)
)
.
slice
(
0
,
slots
);
waiting
.
forEach
((
t
)
=>
void
runOne
(
t
));
}
...
...
@@ -130,10 +164,26 @@ export function startDownloadCenter(): void {
schedule
();
}
/** 登出 / 卸载:中止所有在途长任务,避免 iframe 销毁后轮询还在跑。 */
export
function
stopDownloadCenter
():
void
{
/**
* 登出 / 卸载:中止所有在途长任务,避免 iframe 销毁后轮询还在跑。
*
* markCanceled=true(登出):除了 abort,还把所有 waiting/running 任务显式落为
* canceled。原因:ROP 通道的 postRop 闭包在子应用销毁后失效,abort 与请求失败
* 竞态时任务可能被 engine 的 catch 记为 failed、误弹「导出失败」;显式落 canceled
* 既压掉误报,也避免已返回响应的任务卡在 running。
* 默认 false(组件卸载 / StrictMode 双跑):只 abort,不改任务状态——刷新恢复的
* waiting 任务要保留原状态,下次挂载才能续轮询。
*/
export
function
stopDownloadCenter
(
opts
?:
{
markCanceled
?:
boolean
}):
void
{
controllers
.
forEach
((
c
)
=>
c
.
abort
());
controllers
.
clear
();
if
(
!
opts
?.
markCanceled
)
return
;
const
store
=
useDownloadCenterStore
.
getState
();
store
.
tasks
.
forEach
((
t
)
=>
{
if
(
t
.
status
===
'waiting'
||
t
.
status
===
'running'
)
{
store
.
patch
(
t
.
id
,
{
status
:
'canceled'
,
stage
:
'已取消(退出登录)'
});
}
});
}
/** 取消单个任务:先 abort 让 sleep / 请求立刻停下,再落状态。 */
...
...
packages/download-center/src/handlers/asyncExport.ts
View file @
4b4d68b
...
...
@@ -40,6 +40,28 @@ function debugLog(scope: string, ...args: unknown[]): void {
if
(
on
)
console
.
log
(
`[download-center][
${
scope
}
]`
,
...
args
);
}
/**
* 把请求失败对象摊平成可读字段。跨 wujie realm 的 RequestError 不是本 realm 的
* Error 实例,也不能靠 instanceof 判断,故一律按「自有字段 + 消息」抓取。
* 只用于诊断日志,不参与任何执行分支。
*/
function
describeRequestError
(
error
:
unknown
):
Record
<
string
,
unknown
>
{
const
out
:
Record
<
string
,
unknown
>
=
{
name
:
(
error
as
{
name
?:
unknown
})?.
name
,
message
:
error
instanceof
Error
?
error
.
message
:
String
(
error
),
};
if
(
error
&&
typeof
error
===
'object'
)
{
const
e
=
error
as
Record
<
string
,
unknown
>
;
for
(
const
key
of
[
'code'
,
'data'
,
'response'
,
'status'
,
'isRequestError'
]
as
const
)
{
if
(
e
[
key
]
!==
undefined
)
out
[
key
]
=
e
[
key
];
}
const
cfg
=
e
.
config
as
{
url
?:
unknown
;
baseURL
?:
unknown
;
method
?:
unknown
}
|
undefined
;
if
(
cfg
)
out
.
config
=
{
url
:
cfg
.
url
,
baseURL
:
cfg
.
baseURL
,
method
:
cfg
.
method
};
if
(
e
.
cause
)
out
.
cause
=
describeRequestError
(
e
.
cause
);
}
return
out
;
}
function
normalizeUuid
(
result
:
unknown
):
string
|
undefined
{
if
(
typeof
result
===
'string'
&&
result
)
return
result
;
if
(
!
result
||
typeof
result
!==
'object'
)
return
undefined
;
...
...
@@ -72,19 +94,28 @@ async function submit(
payload
:
AsyncExportPayload
,
signal
:
AbortSignal
,
):
Promise
<
string
>
{
const
exportParam
=
JSON
.
stringify
({
method
:
payload
.
method
,
...(
payload
.
params
??
{})
});
const
exportParamObj
=
{
method
:
payload
.
method
,
...(
payload
.
params
??
{})
};
const
exportParam
=
JSON
.
stringify
(
exportParamObj
);
const
url
=
payload
.
submitMethod
??
DEFAULT_SUBMIT_METHOD
;
debugLog
(
'submit:req'
,
{
url
,
exportParam
,
exportParamParsed
:
JSON
.
parse
(
exportParam
),
});
const
res
=
await
request
({
method
:
'POST'
,
url
,
data
:
{
exportParam
},
signal
,
});
debugLog
(
'submit:req'
,
{
url
,
exportParam
,
exportParamParsed
:
exportParamObj
});
let
res
:
unknown
;
try
{
res
=
await
request
({
method
:
'POST'
,
url
,
data
:
{
exportParam
},
signal
,
});
}
catch
(
e
)
{
// 错误日志无条件输出(不依赖 debug 开关)——失败本就该在控制台留痕。
// 只加日志,不改变失败语义:原样重抛交给引擎落 failed。
console
.
error
(
'[download-center][submit:err]'
,
{
url
,
exportParamParsed
:
exportParamObj
,
error
:
describeRequestError
(
e
),
});
throw
e
;
}
const
uuid
=
normalizeUuid
(
res
);
debugLog
(
'submit:res'
,
{
url
,
res
,
uuid
});
if
(
!
uuid
)
throw
new
Error
(
'后端未返回任务 uuid'
);
...
...
@@ -98,12 +129,18 @@ async function query(
signal
:
AbortSignal
,
):
Promise
<
ExportQueryItem
[]
>
{
const
url
=
payload
.
queryMethod
??
DEFAULT_QUERY_METHOD
;
const
res
=
await
request
({
method
:
'POST'
,
url
,
data
:
{
fileUuidList
:
[
uuid
]
},
signal
,
});
let
res
:
unknown
;
try
{
res
=
await
request
({
method
:
'POST'
,
url
,
data
:
{
fileUuidList
:
[
uuid
]
},
signal
,
});
}
catch
(
e
)
{
console
.
error
(
'[download-center][poll:err]'
,
{
url
,
uuid
,
error
:
describeRequestError
(
e
)
});
throw
e
;
}
debugLog
(
'poll:res'
,
{
url
,
uuid
,
res
});
if
(
Array
.
isArray
(
res
))
return
res
as
ExportQueryItem
[];
const
data
=
(
res
as
{
data
?:
ExportQueryItem
[]
}
|
undefined
)?.
data
;
...
...
packages/platform-sdk/src/downloadCenter.ts
View file @
4b4d68b
...
...
@@ -2,6 +2,8 @@ import { subappBus } from './subapp';
import
{
DOWNLOAD_CENTER_REGISTER_EVENT
,
DOWNLOAD_CENTER_CANCEL_EVENT
,
DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT
,
downloadChannelRop
,
type
AsyncExportPayload
,
type
Base64Payload
,
type
BlobPayload
,
...
...
@@ -9,6 +11,7 @@ import {
type
DownloadKind
,
type
RegisterDownloadInput
,
type
RegisterExportTaskInput
,
type
RemoteRequestFn
,
type
StreamPayload
,
type
UrlPayload
,
}
from
'@uj/contracts'
;
...
...
@@ -54,10 +57,22 @@ function emit(kind: DownloadKind, input: object): void {
* 子应用侧全系统下载入口。
*
* 业务页只「登记任务」,真正的请求 / 轮询 / 通知 / 面板 / 历史全在主壳下载中心。
*
请求因此统一
走主壳 props.request(加签 / 验签 / 401 统一登出),不绕过任何拦截器。
*
常规请求
走主壳 props.request(加签 / 验签 / 401 统一登出),不绕过任何拦截器。
*
* 后端零改动:asyncExport 的 method 即业务导出 method 串,会被包进 exportParam.method。
* 异步导出的编排接口(dj.api.common.*)例外——它是 ROP method,必须走 ROP 网关:
* asyncExport 默认带 channel:`rop:<source>`,对应子应用挂载时经 registerChannel 注册的
* ROP 请求能力;其它下载方式(stream/url/blob/base64)仍走主壳 host 通道。
*/
/**
* 异步导出默认走 ROP 通道:源系统所有 dj.api.common.* 编排接口都用 ROP 主网关。
* 子应用挂载时已注册 `rop:<source>` 通道(持有各自 ROP 凭据)。调用方可用 channel 显式覆盖。
*/
function
withRopChannel
(
input
:
AsyncExportInput
):
AsyncExportInput
{
if
(
input
.
channel
)
return
input
;
return
{
...
input
,
channel
:
downloadChannelRop
(
input
.
source
)
};
}
export
const
downloadCenter
=
{
/** 统一登记(显式 kind);兼容旧写法:不带 kind 但带 method 时默认 async-export。 */
register
(
input
:
RegisterDownloadInput
|
RegisterExportTaskInput
):
void
{
...
...
@@ -66,13 +81,13 @@ export const downloadCenter = {
const
extra
=
payload
&&
typeof
payload
===
'object'
?
payload
:
{};
emit
(
kind
,
{
...
common
,
...
extra
});
}
else
{
emit
(
'async-export'
,
input
);
emit
(
'async-export'
,
withRopChannel
(
input
)
);
}
},
/** 异步导出任务:提交 uuid -> 轮询 -> 通知 -> 自动下载。 */
asyncExport
(
input
:
AsyncExportInput
):
void
{
emit
(
'async-export'
,
input
);
emit
(
'async-export'
,
withRopChannel
(
input
)
);
},
/** 同源、需主壳签名的文件流下载(绝不能用 <a href> 直开)。 */
...
...
@@ -98,4 +113,16 @@ export const downloadCenter = {
cancel
(
taskId
:
string
):
void
{
subappBus
()?.
$emit
(
DOWNLOAD_CENTER_CANCEL_EVENT
,
taskId
);
},
/**
* 注册请求通道:把子应用持有的网关请求能力交给主壳下载引擎。
*
* 用途:异步导出的编排接口(dj.api.common.async.exportExcel)走 ROP 主网关,
* 凭据与客户端在子应用、引擎在主壳。子应用挂载时注册 `rop` 通道,
* asyncExport 任务带 channel:'rop' 即用这里的 requestFn 提交/轮询。
* 函数经 wujie bus 引用传递(同源 iframe),不序列化。
*/
registerChannel
(
name
:
string
,
request
:
RemoteRequestFn
):
void
{
subappBus
()?.
$emit
(
DOWNLOAD_CENTER_REGISTER_CHANNEL_EVENT
,
{
name
,
request
});
},
};
packages/typescript-config/glsk-oss-jssdk.d.ts
0 → 100644
View file @
4b4d68b
/**
* glsk-oss-jssdk(源系统 dj-car-life-system 同款)的类型声明。
* 包本身只有 JS,无 d.ts;此处按 src/index.js 与 README 的真实签名声明。
*/
declare
module
'glsk-oss-jssdk'
{
export
interface
OssUploadResult
{
/** 上传到 OSS 后的文件名(带时间戳) */
attachment
:
string
;
/** 可用于业务接口回填的 OSS 地址(fileUrl) */
aliyunAddress
:
string
;
/** 人类可读的文件大小,如 1.20M */
size
:
string
;
}
export
default
class
GlOssApi
{
constructor
(
params
?:
{
addTimestamp
?:
boolean
;
defaultImageProcess
?:
string
|
null
});
/**
* 分片上传。SDK 内部自行从配置中心获取 bucket/endpoint 与 STS 凭证。
* @param dir 上传目录,源系统合同相关上传传的是文件后缀(如 xlsx / pdf)
*/
multipartUpload
(
file
:
File
,
successCallback
?:
(
result
:
OssUploadResult
)
=>
void
,
errCallBack
?:
(
error
:
unknown
)
=>
void
,
bucketName
?:
string
,
dir
?:
string
,
custAttrObj
?:
Record
<
string
,
unknown
>
,
compressObj
?:
Record
<
string
,
unknown
>
,
partSize
?:
number
,
maxRetries
?:
number
,
imageProcess
?:
string
|
null
,
):
Promise
<
void
>
;
}
}
packages/typescript-config/react-app.json
View file @
4b4d68b
{
"$schema"
:
"https://json.schemastore.org/tsconfig"
,
"files"
:
[
"./glsk-oss-jssdk.d.ts"
],
"compilerOptions"
:
{
"target"
:
"ES2022"
,
"lib"
:
[
"ES2022"
,
"DOM"
,
"DOM.Iterable"
],
...
...
packages/ui/src/components/Image/index.tsx
0 → 100644
View file @
4b4d68b
import { Image, type ImageProps } from 'antd';
export type UImageProps = ImageProps;
/**
* 项目图片组件:antd Image 的 U* 出口。
*
* 默认开启点击预览大图(antd 原生 preview 带缩放/旋转/翻页),
* 对齐源系统列表缩略图点击弹 image-viewer 的行为。
*
* 子应用禁止直引 antd(eslint no-restricted-imports 门禁),统一从 @uj/ui 消费。
* 缩略图尺寸/裁剪由调用方传 width/height + classNames.image + styles.image 控制;
* antd 自带 `.ant-image-img { width:100%; height:auto }` 与业务 class 同特异性,
* 故 object-fit 走 styles.image(inline)确保覆盖,不依赖 CSS 注入顺序。
*/
export function UImage({ preview = true, ...rest }: UImageProps) {
return <Image preview={preview} {...rest} />;
}
packages/ui/src/index.ts
View file @
4b4d68b
...
...
@@ -44,6 +44,8 @@ export { UCard } from './components/Card';
export
type
{
UCardProps
}
from
'./components/Card'
;
export
{
UTag
}
from
'./components/Tag'
;
export
type
{
UTagProps
}
from
'./components/Tag'
;
export
{
UImage
}
from
'./components/Image'
;
export
type
{
UImageProps
}
from
'./components/Image'
;
export
{
UAlert
}
from
'./components/Alert'
;
export
type
{
UAlertProps
}
from
'./components/Alert'
;
export
{
UModal
}
from
'./components/Modal'
;
...
...
packages/ui/src/styles/ui.css
View file @
4b4d68b
...
...
@@ -24,6 +24,16 @@ body {
margin
:
0
;
}
/* 弹层滚动锁的宽度补偿在这里永远是错的:Drawer/Modal 带 mask 时,rc-component/util 的
ScrollLocker 会给 body 注入 inline `width: calc(100% - 滚动条宽px)` + `overflow:hidden`,
用来补它「顺手」藏掉的那条 body 纵向滚动条。但本项目的滚动全部收在页面自己那层
(.uj-*-app / .uj-page--fill 的 overflow),body 本身从不滚 —— 这条补偿只会把整页宽度
凭空收窄一档,表现就是「抽屉一开整页左移、一关又弹回」。
inline 样式没有 !important,作者样式表的 !important 一定压得住,且只影响这一个属性。 */
html
body
{
width
:
100%
!important
;
}
/* antd <App> 边界(SubAppProvider / 主壳入口各挂一层):它默认是块级容器、没有高度,
却正好夹在 #root 与子应用根之间 —— 不补这一条,百分比高度到它这里同样断掉。 */
.ant-app
{
...
...
pnpm-lock.yaml
View file @
4b4d68b
...
...
@@ -54,6 +54,9 @@ catalogs:
globals
:
specifier
:
^15.14.0
version
:
15.15.0
glsk-oss-jssdk
:
specifier
:
1.0.9
version
:
1.0.9
jsrsasign
:
specifier
:
^11.1.5
version
:
11.1.5
...
...
@@ -680,6 +683,9 @@ importers:
dayjs
:
specifier
:
'
catalog:'
version
:
1.11.23
glsk-oss-jssdk
:
specifier
:
'
catalog:'
version
:
1.0.9
react
:
specifier
:
'
catalog:'
version
:
19.3.1
...
...
@@ -2275,13 +2281,25 @@ packages:
engines
:
{
node
:
'
>=0.4.0'
}
hasBin
:
true
address@1.2.2
:
resolution
:
{
integrity
:
sha512-4B/qKCfeE/ODUaAUpSwfzazo5x29WD4r3vXiWsB7I2mSDAihwEqKO+g8GELZUQSSAo5e1XTYh3ZVfLyxBc12nA==
}
engines
:
{
node
:
'
>=
10.0.0'
}
agent-base@6.0.2
:
resolution
:
{
integrity
:
sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==
}
engines
:
{
node
:
'
>=
6.0.0'
}
agentkeepalive@3.5.3
:
resolution
:
{
integrity
:
sha512-yqXL+k5rr8+ZRpOAntkaaRgWgE5o8ESAj5DyRmVTCSoZxXmqemb9Dd7T4i5UzwuERdLAJUy6XzR9zFVuf0kzkw==
}
engines
:
{
node
:
'
>=
4.0.0'
}
ajv@6.15.0
:
resolution
:
{
integrity
:
sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==
}
ali-oss@6.23.0
:
resolution
:
{
integrity
:
sha512-FipRmyd16Pr/tEey/YaaQ/24Pc3HEpLM9S1DRakEuXlSLXNIJnu1oJtHM53eVYpvW3dXapSjrip3xylZUTIZVQ==
}
engines
:
{
node
:
'
>=8'
}
ansi-styles@4.3.0
:
resolution
:
{
integrity
:
sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==
}
engines
:
{
node
:
'
>=8'
}
...
...
@@ -2328,6 +2346,9 @@ packages:
bmp-js@0.1.0
:
resolution
:
{
integrity
:
sha512-vHdS19CnY3hwiNdkaqk93DvjVLfbEcI8mys4UjuWrlX1haDmroo8o4xCzh4wD6DGV6HxRCyauwhHRqMTfERtjw==
}
bowser@1.9.4
:
resolution
:
{
integrity
:
sha512-9IdMmj2KjigRq6oWhmwv1W36pDuA4STQZ8q6YO9um+x07xgYNCD3Oou+WP/3L1HNz7iqythGet3/p4wvc8AAwQ==
}
brace-expansion@1.1.21
:
resolution
:
{
integrity
:
sha512-9zeA+KLZNNzglF2TPKRQEDyx6Yby7daAkuy8MiPzpXPsYDWi/DRM8jmwUDxokQjYqBpv5DgPiwD4h4ZZSy1Ujw==
}
...
...
@@ -2350,6 +2371,9 @@ packages:
buffer@6.0.3
:
resolution
:
{
integrity
:
sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==
}
builtin-status-codes@3.0.0
:
resolution
:
{
integrity
:
sha512-HpGFw18DgFWlncDfjTa2rcQ4W88O1mC8e8yZ2AvQY5KDaktSTwo+KRf6nHK6FRI5FyRyb/5T6+TSxfP7QyGsmQ==
}
bundle-require@5.1.0
:
resolution
:
{
integrity
:
sha512-3WrrOuZiyaaZPWiEt4G3+IffISVC9HYlWueJEBWED4ZH4aIAC2PnkdnuRrR94M+w6yGWn4AglWtJtBI8YqvgoA==
}
engines
:
{
node
:
^12.20.0 || ^14.13.1 || >=16.0.0
}
...
...
@@ -2364,6 +2388,10 @@ packages:
resolution
:
{
integrity
:
sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==
}
engines
:
{
node
:
'
>=
0.4'
}
call-bound@1.0.4
:
resolution
:
{
integrity
:
sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==
}
engines
:
{
node
:
'
>=
0.4'
}
callsites@3.1.0
:
resolution
:
{
integrity
:
sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==
}
engines
:
{
node
:
'
>=6'
}
...
...
@@ -2414,6 +2442,10 @@ packages:
resolution
:
{
integrity
:
sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==
}
engines
:
{
node
:
^14.18.0 || >=16.10.0
}
content-type@1.0.5
:
resolution
:
{
integrity
:
sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==
}
engines
:
{
node
:
'
>=
0.6'
}
convert-source-map@2.0.0
:
resolution
:
{
integrity
:
sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==
}
...
...
@@ -2421,6 +2453,12 @@ packages:
resolution
:
{
integrity
:
sha512-ei8Aos7ja0weRpFzJnEA9UHJ/7XQmqglbRwnf2ATjcB9Wq874VKH9kfjjirM6UhU2/E5fFYadylyhFldcqSidQ==
}
engines
:
{
node
:
'
>=18'
}
copy-to@2.0.1
:
resolution
:
{
integrity
:
sha512-3DdaFaU/Zf1AnpLiFDeNCD4TOWe3Zl2RZaTzUvWiIk5ERzcCodOE20Vqq4fzCbNoHURFHT4/us/Lfq+S2zyY4w==
}
core-util-is@1.0.3
:
resolution
:
{
integrity
:
sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==
}
cross-spawn@7.0.6
:
resolution
:
{
integrity
:
sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==
}
engines
:
{
node
:
'
>=
8'
}
...
...
@@ -2428,6 +2466,9 @@ packages:
csstype@3.2.3
:
resolution
:
{
integrity
:
sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==
}
dateformat@2.2.0
:
resolution
:
{
integrity
:
sha512-GODcnWq3YGoTnygPfi02ygEiRxqUxpJwuRHjdhJYuxpcZmDq4rjBiXYmbCCzStxo176ixfLT6i4NPwQooRySnw==
}
dayjs@1.11.23
:
resolution
:
{
integrity
:
sha512-QDTCU0M0MxR3hQfnlDJfwekQiaanm1ubOD231u73WBckQ/fsamwRLiE2GBz6D3a/xF1NgfiDLJjXBa1hYOYTtQ==
}
...
...
@@ -2443,10 +2484,22 @@ packages:
deep-is@0.1.4
:
resolution
:
{
integrity
:
sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==
}
default-user-agent@1.0.0
:
resolution
:
{
integrity
:
sha512-bDF7bg6OSNcSwFWPu4zYKpVkJZQYVrAANMYB8bc9Szem1D0yKdm4sa/rOCs2aC9+2GMqQ7KnwtZRvDhmLF0dXw==
}
engines
:
{
node
:
'
>=
0.10.0'
}
delayed-stream@1.0.0
:
resolution
:
{
integrity
:
sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==
}
engines
:
{
node
:
'
>=0.4.0'
}
destroy@1.2.0
:
resolution
:
{
integrity
:
sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==
}
engines
:
{
node
:
'
>=
0.8'
,
npm
:
1.2.8000 || >= 1.4.16
}
digest-header@1.1.0
:
resolution
:
{
integrity
:
sha512-glXVh42vz40yZb9Cq2oMOt70FIoWiv+vxNvdKdU8CwjLad25qHM3trLxhl9bVjdr6WaslIXhWpn0NO8T/67Qjg==
}
engines
:
{
node
:
'
>=
8.0.0'
}
dom-walk@0.1.2
:
resolution
:
{
integrity
:
sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w==
}
...
...
@@ -2454,9 +2507,19 @@ packages:
resolution
:
{
integrity
:
sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==
}
engines
:
{
node
:
'
>=
0.4'
}
ee-first@1.1.1
:
resolution
:
{
integrity
:
sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==
}
electron-to-chromium@1.5.477
:
resolution
:
{
integrity
:
sha512-PN++F4zWZoVDGWinxMnSCpVqKhqFOJfLXxdU8bYJKudAEsHL/XKVITOKWVbfMt1r276Mi9RDLU9VHx9uKJ4RMQ==
}
end-of-stream@1.4.5
:
resolution
:
{
integrity
:
sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==
}
end-or-error@1.0.1
:
resolution
:
{
integrity
:
sha512-OclLMSug+k2A0JKuf494im25ANRBVW8qsjmwbgX7lQ8P82H21PQ1PWkoYwb9y5yMBS69BPlwtzdIFClo3+7kOQ==
}
engines
:
{
node
:
'
>=
0.11.14'
}
es-define-property@1.0.1
:
resolution
:
{
integrity
:
sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==
}
engines
:
{
node
:
'
>=
0.4'
}
...
...
@@ -2487,6 +2550,9 @@ packages:
resolution
:
{
integrity
:
sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==
}
engines
:
{
node
:
'
>=6'
}
escape-html@1.0.3
:
resolution
:
{
integrity
:
sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==
}
escape-string-regexp@4.0.0
:
resolution
:
{
integrity
:
sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==
}
engines
:
{
node
:
'
>=10'
}
...
...
@@ -2565,6 +2631,10 @@ packages:
exif-parser@0.1.12
:
resolution
:
{
integrity
:
sha512-c2bQfLNbMzLPmzQuOr8fy0csy84WmwnER81W88DzTp9CYNPJ6yzOj2EZAh9pywYpqHnshVLHQJ8WzldAyfY+Iw==
}
extend-shallow@2.0.1
:
resolution
:
{
integrity
:
sha512-zCnTtlxNoAiDc3gqY2aYAWFx7XWWiasuF2K8Me5WbN8otHKTUKBwjPtNpRs/rbUZm7KxWAaNj7P1a/p52GbVug==
}
engines
:
{
node
:
'
>=0.10.0'
}
fast-deep-equal@3.1.3
:
resolution
:
{
integrity
:
sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==
}
...
...
@@ -2618,6 +2688,9 @@ packages:
resolution
:
{
integrity
:
sha512-vKatAh4SlVfgbv+YtmhiRjhEMJsYpsG1Y2rMQtR+SVSbytsSD1YGzDIcrAJmdFec88u/+VoGmxnl+80gL1tRCQ==
}
engines
:
{
node
:
'
>=
6'
}
formstream@1.5.3
:
resolution
:
{
integrity
:
sha512-dho1DOEYWII8HXtnUg3EKm9vcMxaOgF469psDkq9SIcb0KHtl16fQX5toylxnomL1K5pCJDaVrx/LIXtapEluQ==
}
fsevents@2.3.3
:
resolution
:
{
integrity
:
sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==
}
engines
:
{
node
:
^8.16.0 || ^10.6.0 || >=11.0.0
}
...
...
@@ -2638,6 +2711,9 @@ packages:
resolution
:
{
integrity
:
sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==
}
engines
:
{
node
:
'
>=
0.4'
}
get-ready@1.0.0
:
resolution
:
{
integrity
:
sha512-mFXCZPJIlcYcth+N8267+mghfYN9h3EhsDa6JSnbA3Wrhh/XFpuowviFcsDeYZtKspQyWyJqfs4O6P8CHeTwzw==
}
gifwrap@0.10.1
:
resolution
:
{
integrity
:
sha512-2760b1vpJHNmLzZ/ubTtNnEx5WApN/PYWJvXvgS+tL1egTTthayFYIQQNi136FLEDcN/IyEY2EcGpIITD6eYUw==
}
...
...
@@ -2659,6 +2735,9 @@ packages:
glsk-map-jssdk@0.1.1
:
resolution
:
{
integrity
:
sha512-kwCyU8A1t7Q7V2hlzC03nc9VNNW9HPXQ5YhHsGGnrEtPxykGDG7AEyT5O7LY1zZk/8adkkk6FHgCM53r6p/4yw==
}
glsk-oss-jssdk@1.0.9
:
resolution
:
{
integrity
:
sha512-vzgFohJpWT8FgxLGZkeKWCRCwXCPVFJMe2dg+vpjnDQ5GtMR3PoGo0FGCIVwPgHXtT3kqiOQ6iHhBJTDypjTWQ==
}
glsx-applet-component@1.1.29
:
resolution
:
{
integrity
:
sha512-HPzVayIRZvA3nvG2Lj9V9+S+BFiCer4XxjQwuZksta5Bs9JbbKaY4ztcIEe1Se3vw3rbPL0Dv2OsWvVz2b5jfw==
}
...
...
@@ -2689,6 +2768,13 @@ packages:
resolution
:
{
integrity
:
sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==
}
engines
:
{
node
:
'
>=
6'
}
humanize-ms@1.2.1
:
resolution
:
{
integrity
:
sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ==
}
iconv-lite@0.6.3
:
resolution
:
{
integrity
:
sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==
}
engines
:
{
node
:
'
>=0.10.0'
}
ieee754@1.2.1
:
resolution
:
{
integrity
:
sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==
}
...
...
@@ -2711,6 +2797,16 @@ packages:
resolution
:
{
integrity
:
sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==
}
engines
:
{
node
:
'
>=0.8.19'
}
inherits@2.0.4
:
resolution
:
{
integrity
:
sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==
}
is-class-hotfix@0.0.6
:
resolution
:
{
integrity
:
sha512-0n+pzCC6ICtVr/WXnN2f03TK/3BfXY7me4cjCAqT8TYXEl0+JBRoqBo94JJHXcyDSLUeWbNX8Fvy5g5RJdAstQ==
}
is-extendable@0.1.1
:
resolution
:
{
integrity
:
sha512-5BMULNob1vgFX6EjQw5izWDxrecWK9AM72rugNr0TFldMOi0fj6Jk+zeKIt0xGj4cEfQIJth4w3OKWOJ4f+AFw==
}
engines
:
{
node
:
'
>=0.10.0'
}
is-extglob@2.1.1
:
resolution
:
{
integrity
:
sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==
}
engines
:
{
node
:
'
>=0.10.0'
}
...
...
@@ -2725,12 +2821,21 @@ packages:
is-mobile@5.0.0
:
resolution
:
{
integrity
:
sha512-Tz/yndySvLAEXh+Uk8liFCxOwVH6YutuR74utvOcu7I9Di+DwM0mtdPVZNaVvvBUM2OXxne/NhOs1zAO7riusQ==
}
is-type-of@1.4.0
:
resolution
:
{
integrity
:
sha512-EddYllaovi5ysMLMEN7yzHEKh8A850cZ7pykrY1aNRQGn/CDjRDE9qEWbIdt7xGEVJmjBXzU/fNnC4ABTm8tEQ==
}
isarray@1.0.0
:
resolution
:
{
integrity
:
sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==
}
isexe@2.0.0
:
resolution
:
{
integrity
:
sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==
}
isomorphic-fetch@3.0.0
:
resolution
:
{
integrity
:
sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA==
}
isstream@0.1.2
:
resolution
:
{
integrity
:
sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==
}
jimp@0.22.12
:
resolution
:
{
integrity
:
sha512-R5jZaYDnfkxKJy1dwLpj/7cvyjxiclxU3F4TrI/J4j2rS0niq6YDUMoPn5hs8GDpO+OZGo7Ky057CRtWesyhfg==
}
...
...
@@ -2741,6 +2846,9 @@ packages:
jpeg-js@0.4.4
:
resolution
:
{
integrity
:
sha512-WZzeDOEtTOBK4Mdsar0IqEU5sMr3vSV2RqkAIzUEV2BHnUfKGyswWFPFwK5EeDo93K3FohSHbLAjj0s1Wzd+dg==
}
js-base64@2.6.4
:
resolution
:
{
integrity
:
sha512-pZe//GGmwJndub7ZghVHz7vjb2LgC1m8B07Au3eYqeqv9emhESByMXxaEgkUkEqJe87oBbSniGYoQNIBklc7IQ==
}
js-tokens@4.0.0
:
resolution
:
{
integrity
:
sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==
}
...
...
@@ -2774,6 +2882,9 @@ packages:
resolution
:
{
integrity
:
sha512-i6mAjey0/4UQmlOaNS2vROl8EkWV8Ei436reJAby2OPQ3lF6uXSs1VYpnM8hndmmCMFIzNc04Uw2GF+0JVLFbg==
}
deprecated
:
This package is no longer maintained.
jstoxml@2.2.9
:
resolution
:
{
integrity
:
sha512-OYWlK0j+roh+eyaMROlNbS5cd5R25Y+IUpdl7cNdB8HNrkgwQzIS7L9MegxOiWNBj9dQhA/yAxiMwCC5mwNoBw==
}
keyv@4.5.4
:
resolution
:
{
integrity
:
sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==
}
...
...
@@ -2805,6 +2916,9 @@ packages:
lodash.merge@4.6.2
:
resolution
:
{
integrity
:
sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==
}
lodash@4.18.1
:
resolution
:
{
integrity
:
sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq+0Q==
}
lossless-json@4.3.3
:
resolution
:
{
integrity
:
sha512-FGFrGArHsv7BRiYOf37ZRieT9HlKw+Kpu9HvtpYjcoOEo8lqNkjny8A2YAfWNWWQC+9pcLIrLZ+IviKJhaHwGQ==
}
...
...
@@ -2818,6 +2932,9 @@ packages:
resolution
:
{
integrity
:
sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==
}
engines
:
{
node
:
'
>=
0.4'
}
merge-descriptors@1.0.3
:
resolution
:
{
integrity
:
sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==
}
mime-db@1.52.0
:
resolution
:
{
integrity
:
sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==
}
engines
:
{
node
:
'
>=
0.6'
}
...
...
@@ -2831,6 +2948,11 @@ packages:
engines
:
{
node
:
'
>=4'
}
hasBin
:
true
mime@2.6.0
:
resolution
:
{
integrity
:
sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==
}
engines
:
{
node
:
'
>=4.0.0'
}
hasBin
:
true
min-document@2.19.2
:
resolution
:
{
integrity
:
sha512-8S5I8db/uZN8r9HSLFVWPdJCvYOejMcEC82VIzNUc6Zkklf/d1gg2psfE79/vyhWOj4+J8MtwmoOz3TmvaGu5A==
}
...
...
@@ -2841,9 +2963,16 @@ packages:
minimatch@3.1.5
:
resolution
:
{
integrity
:
sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==
}
minimist@1.2.8
:
resolution
:
{
integrity
:
sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==
}
miniprogram-automator@0.12.1
:
resolution
:
{
integrity
:
sha512-HIzpx9FuDJZjRCi8dx39E2IWNiSD6mAPEnZ3yC8ahl31o+2uphPINWhWSGN03CReb9ZvcNBuBGNjnwRBhVm4NQ==
}
mkdirp@0.5.6
:
resolution
:
{
integrity
:
sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==
}
hasBin
:
true
mlly@1.8.2
:
resolution
:
{
integrity
:
sha512-d+ObxMQFmbt10sretNDytwt85VrbkhhUA/JBGm1MPaWJ65Cl4wOgLaB1NYvJSZ0Ef03MMEU/0xpPMXUIQ29UfA==
}
...
...
@@ -2870,6 +2999,10 @@ packages:
encoding
:
optional
:
true
node-hex@1.0.1
:
resolution
:
{
integrity
:
sha512-iwpZdvW6Umz12ICmu9IYPRxg0tOLGmU3Tq2tKetejCj3oZd7b2nUXwP3a7QA5M9glWy8wlPS1G3RwM/CdsUbdQ==
}
engines
:
{
node
:
'
>=8.0.0'
}
node-releases@2.0.63
:
resolution
:
{
integrity
:
sha512-6li2QanLsAXpIH2R6j77MzRyvOyrvdTqlKtO4CgBdHGNvN99ZZfyxszHc5o5+IZBWD5u6Hzwg83JoGXmqZNG9Q==
}
engines
:
{
node
:
'
>=18'
}
...
...
@@ -2881,13 +3014,30 @@ packages:
resolution
:
{
integrity
:
sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==
}
engines
:
{
node
:
'
>=0.10.0'
}
object-inspect@1.13.4
:
resolution
:
{
integrity
:
sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==
}
engines
:
{
node
:
'
>=
0.4'
}
omggif@1.0.10
:
resolution
:
{
integrity
:
sha512-LMJTtvgc/nugXj0Vcrrs68Mn2D1r0zf630VNtqtpI1FEO7e+O9FP4gqs9AcnBaSEeoHIPm28u6qgPR0oyEpGSw==
}
once@1.4.0
:
resolution
:
{
integrity
:
sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==
}
optionator@0.9.4
:
resolution
:
{
integrity
:
sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==
}
engines
:
{
node
:
'
>=
0.8.0'
}
os-name@1.0.3
:
resolution
:
{
integrity
:
sha512-f5estLO2KN8vgtTRaILIgEGBoBrMnZ3JQ7W9TMZCnOIGwHe8TRGSpcagnWDo+Dfhd/z08k9Xe75hvciJJ8Qaew==
}
engines
:
{
node
:
'
>=0.10.0'
}
hasBin
:
true
osx-release@1.1.0
:
resolution
:
{
integrity
:
sha512-ixCMMwnVxyHFQLQnINhmIpWqXIfS2YOXchwQrk+OFzmo6nDjQ0E4KXAyyUh0T0MZgV4bUhkRrAbVqlE4yLVq4A==
}
engines
:
{
node
:
'
>=0.10.0'
}
hasBin
:
true
p-limit@3.1.0
:
resolution
:
{
integrity
:
sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==
}
engines
:
{
node
:
'
>=10'
}
...
...
@@ -2926,6 +3076,9 @@ packages:
pathe@2.0.3
:
resolution
:
{
integrity
:
sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==
}
pause-stream@0.0.11
:
resolution
:
{
integrity
:
sha512-e3FBlXLmN/D1S+zHzanP4E/4Z60oFAa3O051qt1pxa7DEJWKAyil6upYVXCWadEnuoqa4Pkc9oUx9zsxYeRv8A==
}
peek-readable@4.1.0
:
resolution
:
{
integrity
:
sha512-ZI3LnwUv5nOGbQzD9c2iDG6toheuXSZP5esSHBjopsXH4dg19soufvpUGA3uohi5anFtGb2lhAVdHzH6R/Evvg==
}
engines
:
{
node
:
'
>=8'
}
...
...
@@ -2953,6 +3106,9 @@ packages:
pkg-types@1.3.1
:
resolution
:
{
integrity
:
sha512-/Jm5M4RvtBFVkKWRu2BLUTNP8/M2a+UwuAX+ae4770q1qVGtfjG+WTCupoZixokjmHiry8uI+dlY8KXYV5HVVQ==
}
platform@1.3.6
:
resolution
:
{
integrity
:
sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==
}
pngjs@3.4.0
:
resolution
:
{
integrity
:
sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w==
}
engines
:
{
node
:
'
>=4.0.0'
}
...
...
@@ -2992,6 +3148,9 @@ packages:
engines
:
{
node
:
'
>=14'
}
hasBin
:
true
process-nextick-args@2.0.1
:
resolution
:
{
integrity
:
sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==
}
process@0.11.10
:
resolution
:
{
integrity
:
sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==
}
engines
:
{
node
:
'
>=
0.6.0'
}
...
...
@@ -3000,6 +3159,9 @@ packages:
resolution
:
{
integrity
:
sha512-cJ+oHTW1VAEa8cJslgmUZrc+sjRKgAKl3Zyse6+PV38hZe/V6Z14TbCuXcan9F9ghlz4QrFr2c92TNF82UkYHA==
}
engines
:
{
node
:
'
>=10'
}
pump@3.0.4
:
resolution
:
{
integrity
:
sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA==
}
punycode@2.3.1
:
resolution
:
{
integrity
:
sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==
}
engines
:
{
node
:
'
>=6'
}
...
...
@@ -3011,6 +3173,10 @@ packages:
resolution
:
{
integrity
:
sha512-EXtzRZmC+YGmGlDFbXKxQiMZNwCLEO6BANKXG4iCtSIM0yqc/pappSx3RIKr4r0uh5JsBckOXeKrB3Iz7mdQpQ==
}
hasBin
:
true
qs@6.17.1
:
resolution
:
{
integrity
:
sha512-jd3COkaKVgGUW+ZHyEHCG9bH7RoaaiWuMgzsIBjUMVjLAaWGWpoUAVwljVvBHxRu/2qEHnadLGZrkutYUBPQJA==
}
engines
:
{
node
:
'
>=0.6'
}
react-dom@19.3.1
:
resolution
:
{
integrity
:
sha512-Y0bARz53lhEC1NMCASs0/j+faB/zqt3R8hpvg1e8+61ZVJ4UL0UdC4cBbXfZMcIuhrfgeILTLe+ZeBCavQPtKQ==
}
peerDependencies
:
...
...
@@ -3044,6 +3210,9 @@ packages:
resolution
:
{
integrity
:
sha512-QNhWdt7nrgVWWQG58QuGsAR3jv3Hbe4mb4vz7w2csnHavciZJgda1CPNaldF6eVxv90ud3jUXpKlHL69gO38yw==
}
engines
:
{
node
:
'
>=0.10.0'
}
readable-stream@2.3.8
:
resolution
:
{
integrity
:
sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==
}
readable-stream@4.8.0
:
resolution
:
{
integrity
:
sha512-2jhTTU3Eilp/2DMT71gbcoqC35eQHasMJH0RHkYxwlxIv3+FR6Y5xAFZIwEGLxKkjZYEFlsiMNIdwUqjK2lLHQ==
}
engines
:
{
node
:
^12.22.0 || ^14.17.0 || >=16.0.0
}
...
...
@@ -3075,9 +3244,15 @@ packages:
engines
:
{
node
:
'
>=18.0.0'
,
npm
:
'
>=8.0.0'
}
hasBin
:
true
safe-buffer@5.1.2
:
resolution
:
{
integrity
:
sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==
}
safe-buffer@5.2.1
:
resolution
:
{
integrity
:
sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==
}
safer-buffer@2.1.2
:
resolution
:
{
integrity
:
sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==
}
sax@1.6.1
:
resolution
:
{
integrity
:
sha512-42tBVwLWnaQvW5zc4HbZrTuWccECCZfBi92FDuwtqxasH+JbPB3/FOKb1m222K42R4WxuxzzMsTswfzgtSu64Q==
}
engines
:
{
node
:
'
>=11.0.0'
}
...
...
@@ -3088,6 +3263,13 @@ packages:
scroll-into-view-if-needed@3.1.0
:
resolution
:
{
integrity
:
sha512-49oNpRjWRvnU8NyGVmUaYG4jtTkNonFZI86MmGRDqBphEK2EXT9gdEUoQPZhuBM8yWHxCWbobltqYO5M4XrUvQ==
}
sdk-base@2.0.1
:
resolution
:
{
integrity
:
sha512-eeG26wRwhtwYuKGCDM3LixCaxY27Pa/5lK4rLKhQa7HBjJ3U3Y+f81MMZQRsDw/8SC2Dao/83yJTXJ8aULuN8Q==
}
semver@5.7.3
:
resolution
:
{
integrity
:
sha512-kM18BPOqTi0+TB68703/GJRpAML5Me+IDQsR1J26YB3EFKKNEyHIVZuWDX7+WKQB3tHwDwgk24BfhdpWUbytvQ==
}
hasBin
:
true
semver@6.3.2
:
resolution
:
{
integrity
:
sha512-GYrCADwpu6yV5OAvchkQ27Z5wwMxWAEMg5NNWjyHh/5DboFFqbdbvYNIvZouQpxXyeMPoTOh0vdPYKlf0ZswdQ==
}
hasBin
:
true
...
...
@@ -3108,6 +3290,22 @@ packages:
resolution
:
{
integrity
:
sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==
}
engines
:
{
node
:
'
>=8'
}
side-channel-list@1.0.1
:
resolution
:
{
integrity
:
sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==
}
engines
:
{
node
:
'
>=
0.4'
}
side-channel-map@1.0.1
:
resolution
:
{
integrity
:
sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==
}
engines
:
{
node
:
'
>=
0.4'
}
side-channel-weakmap@1.0.2
:
resolution
:
{
integrity
:
sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==
}
engines
:
{
node
:
'
>=
0.4'
}
side-channel@1.1.1
:
resolution
:
{
integrity
:
sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==
}
engines
:
{
node
:
'
>=
0.4'
}
source-map-js@1.2.2
:
resolution
:
{
integrity
:
sha512-KGj/8Y43x35aZVDtt+J4mK1hoLGHULMYfSkODJNQjNDC3oW1PqPoxMwo0pLUsWM/UEGzON/NxeHywEfNXNP3Vw==
}
engines
:
{
node
:
'
>=0.10.0'
}
...
...
@@ -3116,9 +3314,23 @@ packages:
resolution
:
{
integrity
:
sha512-i5uvt8C3ikiWeNZSVZNWcfZPItFQOsYTUAOkcUPGd8DqDy1uOUikjt5dG+uRlwyvR108Fb9DOd4GvXfT0N2/uQ==
}
engines
:
{
node
:
'
>=
12'
}
statuses@1.5.0
:
resolution
:
{
integrity
:
sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==
}
engines
:
{
node
:
'
>=
0.6'
}
stream-http@2.8.2
:
resolution
:
{
integrity
:
sha512-QllfrBhqF1DPcz46WxKTs6Mz1Bpc+8Qm6vbqOpVav5odAXwbyzwnEczoWqtxrsmlO+cJqtPrp/8gWKWjaKLLlA==
}
stream-wormhole@1.1.0
:
resolution
:
{
integrity
:
sha512-gHFfL3px0Kctd6Po0M8TzEvt3De/xu6cnRrjlfYNhwbhLPLwigI2t1nc6jrzNuaYg5C4YF78PPFuQPzRiqn9ew==
}
engines
:
{
node
:
'
>=4.0.0'
}
string-convert@0.2.1
:
resolution
:
{
integrity
:
sha512-u/1tdPl4yQnPBjnVrmdLo9gtuLvELKsAoRapekWggdiQNvvvum+jYF329d84NAa660KQw7pB2n36KrIKVoXa3A==
}
string_decoder@1.1.1
:
resolution
:
{
integrity
:
sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==
}
string_decoder@1.3.0
:
resolution
:
{
integrity
:
sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==
}
...
...
@@ -3153,6 +3365,9 @@ packages:
resolution
:
{
integrity
:
sha512-B71/4oyj61iNH0KeCamLuE2rmKuTO5byTOSVwECM5FA7TiAiAW+UqTKZ9ERueC4qvgSttUhdmq1mXC3kJqGX7A==
}
engines
:
{
node
:
'
>=12.22'
}
through@2.3.8
:
resolution
:
{
integrity
:
sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==
}
timm@1.7.1
:
resolution
:
{
integrity
:
sha512-IjZc9KIotudix8bMaBW6QvMuq64BrJWFs1+4V0lXwWGQZwH+LnX87doAYhem4caOEusRP9/g6jVDQmZ8XOk1nw==
}
...
...
@@ -3166,6 +3381,9 @@ packages:
resolution
:
{
integrity
:
sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==
}
engines
:
{
node
:
'
>=12.0.0'
}
to-arraybuffer@1.0.1
:
resolution
:
{
integrity
:
sha512-okFlQcoGTi4LQBG/PgSYblw9VOyptsz2KJZqc6qtgGdes8VktzUQkj4BI2blit072iS8VODNcMA+tvnS9dnuMA==
}
token-types@4.2.1
:
resolution
:
{
integrity
:
sha512-6udB24Q737UD/SDsKAHI9FCRP7Bqc9D/MQUV02ORQg5iskjtLJlZJNdN4kKtcdtwCeWIwIHDGaUsTsCCAa8sFQ==
}
engines
:
{
node
:
'
>=10'
}
...
...
@@ -3231,6 +3449,10 @@ packages:
undici-types@6.21.0
:
resolution
:
{
integrity
:
sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==
}
unescape@1.0.1
:
resolution
:
{
integrity
:
sha512-O0+af1Gs50lyH1nUu3ZyYS1cRh01Q/kUKatTOkSs7jukXE6/NebucDVxyiDsA9AQ4JC1V1jUH9EO8JX2nMDgGQ==
}
engines
:
{
node
:
'
>=0.10.0'
}
update-browserslist-db@1.3.4
:
resolution
:
{
integrity
:
sha512-t8wonIOdQyOjtPd2VktlBu6QjTVTks6v8bSi7kd0r2Vll8TK1JYDZtRRdbmCHOAMphkZgrzK+L+vXK4pyZ8t4A==
}
hasBin
:
true
...
...
@@ -3240,9 +3462,25 @@ packages:
uri-js@4.4.1
:
resolution
:
{
integrity
:
sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==
}
urllib@2.44.1
:
resolution
:
{
integrity
:
sha512-vreOVvFizoiIz5NK9IYMgUknkriHHBVccn2VFfJhgKz6O2qwm0SgjFk4OpXFRDXpdrTx8EzM1DB0/pejrqXwPA==
}
engines
:
{
node
:
'
>=
0.10.0'
}
peerDependencies
:
proxy-agent
:
^5.0.0
peerDependenciesMeta
:
proxy-agent
:
optional
:
true
utif2@4.1.0
:
resolution
:
{
integrity
:
sha512-+oknB9FHrJ7oW7A2WZYajOcv4FcDR4CfoGB0dPNfxbi4GO05RRnFmt5oa23+9w32EanrYcSJWspUiJkLMs+37w==
}
util-deprecate@1.0.2
:
resolution
:
{
integrity
:
sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==
}
utility@1.18.0
:
resolution
:
{
integrity
:
sha512-PYxZDA+6QtvRvm//++aGdmKG/cI07jNwbROz0Ql+VzFV1+Z0Dy55NI4zZ7RHc9KKpBePNFwoErqIuqQv/cjiTA==
}
engines
:
{
node
:
'
>=
0.12.0'
}
vite@6.4.5
:
resolution
:
{
integrity
:
sha512-4enwjFfi4IwtEh0w+jPzpLVOFQiPHmmzPxcHXQOyEur47o6u0jE573DmGpjA+7irXoMLYRZD5ZaFUEneS3abPg==
}
engines
:
{
node
:
^18.0.0 || ^20.0.0 || >=22.0.0
}
...
...
@@ -3297,10 +3535,17 @@ packages:
engines
:
{
node
:
'
>=
8'
}
hasBin
:
true
win-release@1.1.1
:
resolution
:
{
integrity
:
sha512-iCRnKVvGxOQdsKhcQId2PXV1vV3J/sDPXKA4Oe9+Eti2nb2ESEsYHRYls/UjoUW3bIc5ZDO8dTH50A/5iVN+bw==
}
engines
:
{
node
:
'
>=0.10.0'
}
word-wrap@1.2.5
:
resolution
:
{
integrity
:
sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==
}
engines
:
{
node
:
'
>=0.10.0'
}
wrappy@1.0.2
:
resolution
:
{
integrity
:
sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==
}
ws@6.2.6
:
resolution
:
{
integrity
:
sha512-XTrf1gv7kXoVf1hbC3PAyAiPgR8Wz1blcrYIjEsUmr08BLksT41R8KbjmS9408C2ERx7v1JDLD/BkpLEttjfKA==
}
peerDependencies
:
...
...
@@ -3325,6 +3570,10 @@ packages:
resolution
:
{
integrity
:
sha512-drPFnkQJik/O+uPKpqSgr22mpuFHqKdbS835iAQrUC73L2F5WkboIRd63ai/2Yg6I1jzifPFKH2NTK+cfglkIA==
}
engines
:
{
node
:
'
>=4.0.0'
}
xml2js@0.6.2
:
resolution
:
{
integrity
:
sha512-T4rieHaC1EXcES0Kxxj4JWgaUQHDk+qwHcYOCFHfiwKz7tOVPLq7Hjq9dM1WCMhylqMEfP7hMcOIChvotiZegA==
}
engines
:
{
node
:
'
>=4.0.0'
}
xmlbuilder@11.0.1
:
resolution
:
{
integrity
:
sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==
}
engines
:
{
node
:
'
>=4.0'
}
...
...
@@ -4594,12 +4843,18 @@ snapshots:
acorn@8.19.0
:
{}
address@1.2.2
:
{}
agent-base@6.0.2
:
dependencies
:
debug
:
4.4.3
transitivePeerDependencies
:
-
supports-color
agentkeepalive@3.5.3
:
dependencies
:
humanize-ms
:
1.2.1
ajv@6.15.0
:
dependencies
:
fast-deep-equal
:
3.1.3
...
...
@@ -4607,6 +4862,37 @@ snapshots:
json-schema-traverse
:
0.4.1
uri-js
:
4.4.1
ali-oss@6.23.0
:
dependencies
:
address
:
1.2.2
agentkeepalive
:
3.5.3
bowser
:
1.9.4
copy-to
:
2.0.1
dateformat
:
2.2.0
debug
:
4.4.3
destroy
:
1.2.0
end-or-error
:
1.0.1
get-ready
:
1.0.0
humanize-ms
:
1.2.1
is-type-of
:
1.4.0
js-base64
:
2.6.4
jstoxml
:
2.2.9
lodash
:
4.18.1
merge-descriptors
:
1.0.3
mime
:
2.6.0
platform
:
1.3.6
pump
:
3.0.4
qs
:
6.17.1
sdk-base
:
2.0.1
stream-http
:
2.8.2
stream-wormhole
:
1.1.0
urllib
:
2.44.1
utility
:
1.18.0
xml2js
:
0.6.2
transitivePeerDependencies
:
-
proxy-agent
-
supports-color
ansi-styles@4.3.0
:
dependencies
:
color-convert
:
2.0.1
...
...
@@ -4698,6 +4984,8 @@ snapshots:
bmp-js@0.1.0
:
{}
bowser@1.9.4
:
{}
brace-expansion@1.1.21
:
dependencies
:
balanced-match
:
1.0.2
...
...
@@ -4727,6 +5015,8 @@ snapshots:
base64-js
:
1.5.1
ieee754
:
1.2.1
builtin-status-codes@3.0.0
:
{}
bundle-require@5.1.0(esbuild@0.27.7)
:
dependencies
:
esbuild
:
0.27.7
...
...
@@ -4739,6 +5029,11 @@ snapshots:
es-errors
:
1.3.0
function-bind
:
1.1.2
call-bound@1.0.4
:
dependencies
:
call-bind-apply-helpers
:
1.0.2
get-intrinsic
:
1.3.0
callsites@3.1.0
:
{}
caniuse-lite@1.0.30001820
:
{}
...
...
@@ -4780,10 +5075,16 @@ snapshots:
consola@3.4.2
:
{}
content-type@1.0.5
:
{}
convert-source-map@2.0.0
:
{}
cookie@1.1.1
:
{}
copy-to@2.0.1
:
{}
core-util-is@1.0.3
:
{}
cross-spawn@7.0.6
:
dependencies
:
path-key
:
3.1.1
...
...
@@ -4792,6 +5093,8 @@ snapshots:
csstype@3.2.3
:
{}
dateformat@2.2.0
:
{}
dayjs@1.11.23
:
{}
debug@4.4.3
:
...
...
@@ -4800,8 +5103,16 @@ snapshots:
deep-is@0.1.4
:
{}
default-user-agent@1.0.0
:
dependencies
:
os-name
:
1.0.3
delayed-stream@1.0.0
:
{}
destroy@1.2.0
:
{}
digest-header@1.1.0
:
{}
dom-walk@0.1.2
:
{}
dunder-proto@1.0.1
:
...
...
@@ -4810,8 +5121,16 @@ snapshots:
es-errors
:
1.3.0
gopd
:
1.2.0
ee-first@1.1.1
:
{}
electron-to-chromium@1.5.477
:
{}
end-of-stream@1.4.5
:
dependencies
:
once
:
1.4.0
end-or-error@1.0.1
:
{}
es-define-property@1.0.1
:
{}
es-errors@1.3.0
:
{}
...
...
@@ -4887,6 +5206,8 @@ snapshots:
escalade@3.2.0
:
{}
escape-html@1.0.3
:
{}
escape-string-regexp@4.0.0
:
{}
eslint-config-prettier@10.1.8(eslint@9.39.4)
:
...
...
@@ -4975,6 +5296,10 @@ snapshots:
exif-parser@0.1.12
:
{}
extend-shallow@2.0.1
:
dependencies
:
is-extendable
:
0.1.1
fast-deep-equal@3.1.3
:
{}
fast-json-stable-stringify@2.1.0
:
{}
...
...
@@ -5025,6 +5350,13 @@ snapshots:
hasown
:
2.0.4
mime-types
:
2.1.35
formstream@1.5.3
:
dependencies
:
destroy
:
1.2.0
mime
:
2.6.0
node-hex
:
1.0.1
pause-stream
:
0.0.11
fsevents@2.3.3
:
optional
:
true
...
...
@@ -5050,6 +5382,8 @@ snapshots:
dunder-proto
:
1.0.1
es-object-atoms
:
1.1.2
get-ready@1.0.0
:
{}
gifwrap@0.10.1
:
dependencies
:
image-q
:
4.0.0
...
...
@@ -5070,6 +5404,15 @@ snapshots:
glsk-map-jssdk@0.1.1
:
{}
glsk-oss-jssdk@1.0.9
:
dependencies
:
ali-oss
:
6.23.0
axios
:
1.21.0
transitivePeerDependencies
:
-
debug
-
proxy-agent
-
supports-color
glsx-applet-component@1.1.29
:
{}
glsx-map-sdk@0.2.0
:
{}
...
...
@@ -5095,6 +5438,14 @@ snapshots:
transitivePeerDependencies
:
-
supports-color
humanize-ms@1.2.1
:
dependencies
:
ms
:
2.1.3
iconv-lite@0.6.3
:
dependencies
:
safer-buffer
:
2.1.2
ieee754@1.2.1
:
{}
ignore@5.3.2
:
{}
...
...
@@ -5112,6 +5463,12 @@ snapshots:
imurmurhash@0.1.4
:
{}
inherits@2.0.4
:
{}
is-class-hotfix@0.0.6
:
{}
is-extendable@0.1.1
:
{}
is-extglob@2.1.1
:
{}
is-function@1.0.2
:
{}
...
...
@@ -5122,6 +5479,14 @@ snapshots:
is-mobile@5.0.0
:
{}
is-type-of@1.4.0
:
dependencies
:
core-util-is
:
1.0.3
is-class-hotfix
:
0.0.6
isstream
:
0.1.2
isarray@1.0.0
:
{}
isexe@2.0.0
:
{}
isomorphic-fetch@3.0.0
:
...
...
@@ -5131,6 +5496,8 @@ snapshots:
transitivePeerDependencies
:
-
encoding
isstream@0.1.2
:
{}
jimp@0.22.12(debug@4.4.3)
:
dependencies
:
'
@jimp/custom'
:
0.22.12
...
...
@@ -5145,6 +5512,8 @@ snapshots:
jpeg-js@0.4.4
:
{}
js-base64@2.6.4
:
{}
js-tokens@4.0.0
:
{}
js-yaml@4.3.2
:
...
...
@@ -5167,6 +5536,8 @@ snapshots:
jsrsasign@11.1.5
:
{}
jstoxml@2.2.9
:
{}
keyv@4.5.4
:
dependencies
:
json-buffer
:
3.0.1
...
...
@@ -5203,6 +5574,8 @@ snapshots:
lodash.merge@4.6.2
:
{}
lodash@4.18.1
:
{}
lossless-json@4.3.3
:
{}
lru-cache@5.1.1
:
...
...
@@ -5215,6 +5588,8 @@ snapshots:
math-intrinsics@1.1.0
:
{}
merge-descriptors@1.0.3
:
{}
mime-db@1.52.0
:
{}
mime-types@2.1.35
:
...
...
@@ -5223,6 +5598,8 @@ snapshots:
mime@1.6.0
:
{}
mime@2.6.0
:
{}
min-document@2.19.2
:
dependencies
:
dom-walk
:
0.1.2
...
...
@@ -5235,6 +5612,8 @@ snapshots:
dependencies
:
brace-expansion
:
1.1.21
minimist@1.2.8
:
{}
miniprogram-automator@0.12.1
:
dependencies
:
debug
:
4.4.3
...
...
@@ -5249,6 +5628,10 @@ snapshots:
-
supports-color
-
utf-8-validate
mkdirp@0.5.6
:
dependencies
:
minimist
:
1.2.8
mlly@1.8.2
:
dependencies
:
acorn
:
8.19.0
...
...
@@ -5272,14 +5655,22 @@ snapshots:
dependencies
:
whatwg-url
:
5.0.0
node-hex@1.0.1
:
{}
node-releases@2.0.63
:
{}
number-precision@1.6.0
:
{}
object-assign@4.1.1
:
{}
object-inspect@1.13.4
:
{}
omggif@1.0.10
:
{}
once@1.4.0
:
dependencies
:
wrappy
:
1.0.2
optionator@0.9.4
:
dependencies
:
deep-is
:
0.1.4
...
...
@@ -5289,6 +5680,15 @@ snapshots:
type-check
:
0.4.0
word-wrap
:
1.2.5
os-name@1.0.3
:
dependencies
:
osx-release
:
1.1.0
win-release
:
1.1.1
osx-release@1.1.0
:
dependencies
:
minimist
:
1.2.8
p-limit@3.1.0
:
dependencies
:
yocto-queue
:
0.1.0
...
...
@@ -5320,6 +5720,10 @@ snapshots:
pathe@2.0.3
:
{}
pause-stream@0.0.11
:
dependencies
:
through
:
2.3.8
peek-readable@4.1.0
:
{}
phin@3.7.1(debug@4.4.3)
:
...
...
@@ -5344,6 +5748,8 @@ snapshots:
mlly
:
1.8.2
pathe
:
2.0.3
platform@1.3.6
:
{}
pngjs@3.4.0
:
{}
pngjs@6.0.0
:
{}
...
...
@@ -5364,16 +5770,28 @@ snapshots:
prettier@3.9.10
:
{}
process-nextick-args@2.0.1
:
{}
process@0.11.10
:
{}
proxy-from-env@2.1.0
:
{}
pump@3.0.4
:
dependencies
:
end-of-stream
:
1.4.5
once
:
1.4.0
punycode@2.3.1
:
{}
qrcode-reader@1.0.4
:
{}
qrcode-terminal@0.12.0
:
{}
qs@6.17.1
:
dependencies
:
es-define-property
:
1.0.1
side-channel
:
1.1.1
react-dom@19.3.1(react@19.3.1)
:
dependencies
:
react
:
19.3.1
...
...
@@ -5399,6 +5817,16 @@ snapshots:
react@19.3.1
:
{}
readable-stream@2.3.8
:
dependencies
:
core-util-is
:
1.0.3
inherits
:
2.0.4
isarray
:
1.0.0
process-nextick-args
:
2.0.1
safe-buffer
:
5.1.2
string_decoder
:
1.1.1
util-deprecate
:
1.0.2
readable-stream@4.8.0
:
dependencies
:
abort-controller
:
3.0.0
...
...
@@ -5453,8 +5881,12 @@ snapshots:
'
@rollup/rollup-win32-x64-msvc'
:
4.67.5
fsevents
:
2.3.3
safe-buffer@5.1.2
:
{}
safe-buffer@5.2.1
:
{}
safer-buffer@2.1.2
:
{}
sax@1.6.1
:
{}
scheduler@0.28.0
:
{}
...
...
@@ -5463,6 +5895,12 @@ snapshots:
dependencies
:
compute-scroll-into-view
:
3.1.1
sdk-base@2.0.1
:
dependencies
:
get-ready
:
1.0.0
semver@5.7.3
:
{}
semver@6.3.2
:
{}
semver@7.8.6
:
{}
...
...
@@ -5475,12 +5913,56 @@ snapshots:
shebang-regex@3.0.0
:
{}
side-channel-list@1.0.1
:
dependencies
:
es-errors
:
1.3.0
object-inspect
:
1.13.4
side-channel-map@1.0.1
:
dependencies
:
call-bound
:
1.0.4
es-errors
:
1.3.0
get-intrinsic
:
1.3.0
object-inspect
:
1.13.4
side-channel-weakmap@1.0.2
:
dependencies
:
call-bound
:
1.0.4
es-errors
:
1.3.0
get-intrinsic
:
1.3.0
object-inspect
:
1.13.4
side-channel-map
:
1.0.1
side-channel@1.1.1
:
dependencies
:
es-errors
:
1.3.0
object-inspect
:
1.13.4
side-channel-list
:
1.0.1
side-channel-map
:
1.0.1
side-channel-weakmap
:
1.0.2
source-map-js@1.2.2
:
{}
source-map@0.7.6
:
{}
statuses@1.5.0
:
{}
stream-http@2.8.2
:
dependencies
:
builtin-status-codes
:
3.0.0
inherits
:
2.0.4
readable-stream
:
2.3.8
to-arraybuffer
:
1.0.1
xtend
:
4.0.2
stream-wormhole@1.1.0
:
{}
string-convert@0.2.1
:
{}
string_decoder@1.1.1
:
dependencies
:
safe-buffer
:
5.1.2
string_decoder@1.3.0
:
dependencies
:
safe-buffer
:
5.2.1
...
...
@@ -5518,6 +6000,8 @@ snapshots:
throttle-debounce@5.0.2
:
{}
through@2.3.8
:
{}
timm@1.7.1
:
{}
tinycolor2@1.6.0
:
{}
...
...
@@ -5529,6 +6013,8 @@ snapshots:
fdir
:
6.5.0(picomatch@4.0.7)
picomatch
:
4.0.7
to-arraybuffer@1.0.1
:
{}
token-types@4.2.1
:
dependencies
:
'
@tokenizer/token'
:
0.3.0
...
...
@@ -5602,6 +6088,10 @@ snapshots:
undici-types@6.21.0
:
{}
unescape@1.0.1
:
dependencies
:
extend-shallow
:
2.0.1
update-browserslist-db@1.3.4(browserslist@4.29.5)
:
dependencies
:
browserslist
:
4.29.5
...
...
@@ -5612,10 +6102,35 @@ snapshots:
dependencies
:
punycode
:
2.3.1
urllib@2.44.1
:
dependencies
:
any-promise
:
1.3.0
content-type
:
1.0.5
default-user-agent
:
1.0.0
digest-header
:
1.1.0
ee-first
:
1.1.1
formstream
:
1.5.3
humanize-ms
:
1.2.1
iconv-lite
:
0.6.3
pump
:
3.0.4
qs
:
6.17.1
statuses
:
1.5.0
utility
:
1.18.0
utif2@4.1.0
:
dependencies
:
pako
:
1.0.11
util-deprecate@1.0.2
:
{}
utility@1.18.0
:
dependencies
:
copy-to
:
2.0.1
escape-html
:
1.0.3
mkdirp
:
0.5.6
mz
:
2.7.0
unescape
:
1.0.1
vite@6.4.5(@types/node@22.20.5)
:
dependencies
:
esbuild
:
0.25.12
...
...
@@ -5641,8 +6156,14 @@ snapshots:
dependencies
:
isexe
:
2.0.0
win-release@1.1.1
:
dependencies
:
semver
:
5.7.3
word-wrap@1.2.5
:
{}
wrappy@1.0.2
:
{}
ws@6.2.6
:
dependencies
:
async-limiter
:
1.0.1
...
...
@@ -5665,6 +6186,11 @@ snapshots:
sax
:
1.6.1
xmlbuilder
:
11.0.1
xml2js@0.6.2
:
dependencies
:
sax
:
1.6.1
xmlbuilder
:
11.0.1
xmlbuilder@11.0.1
:
{}
xtend@4.0.2
:
{}
...
...
pnpm-workspace.yaml
View file @
4b4d68b
...
...
@@ -53,6 +53,9 @@ catalogs:
zustand
:
^5.0.3
'
@tanstack/react-query'
:
^5.62.0
axios
:
^1.7.9
# OSS 分片上传 SDK(源系统 dj-car-life-system 同款,走配置中心取 STS 凭证)
# 仅 usedcar 子应用使用,但与源系统上传行为强耦合,版本必须锁死。
glsk-oss-jssdk
:
1.0.9
# 请求加签(RSA-SHA256)与无损 JSON 解析,platform-core 独占
jsrsasign
:
^11.1.5
lossless-json
:
^4.3.1
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment