feat: 添加最小会议时长配置和优化设备列表样式
- 在 `AndroidMeetingController` 和 `AndroidMeetingConfigVo` 中添加最小会议时长配置 - 优化 `ListTable` 组件的滚动样式和逻辑 - 更新 `devices/index.less` 和 `devices/index.tsx`,改进设备列表单元格样式和内容展示dev_na
parent
443e067b30
commit
8d4a31e043
|
|
@ -22,6 +22,10 @@ public final class SysParamKeys {
|
|||
public static final String MEETING_MAX_PAUSE_DURATION = "meeting.max_pause_duration";
|
||||
/** 单场会议最大时长,单位分钟。 */
|
||||
public static final String MEETING_MAX_MEETING_DURATION = "meeting.max_meeting_duration";
|
||||
/**
|
||||
* 单场会议最小时长,单位秒。
|
||||
*/
|
||||
public static final String MEETING_MIN_MEETING_DURATION = "meeting.min_meeting_duration";
|
||||
/** 会议音频传输丢包率配置值。 */
|
||||
public static final String MEETING_PACKET_LOSS_RATE = "meeting.packet_loss_rate";
|
||||
/** 安卓端是否启用音频分片上传。 */
|
||||
|
|
|
|||
|
|
@ -453,6 +453,7 @@ public class AndroidMeetingController {
|
|||
resultVo.setModelsList(enabledModels);
|
||||
resultVo.setSummaryDegreeOfDetail(dictItemService.getItemsByTypeCode("summary_degree_detail"));
|
||||
resultVo.setMaxMeetingDuration(Integer.valueOf(paramService.getParamValue(SysParamKeys.MEETING_MAX_MEETING_DURATION,"30")));
|
||||
resultVo.setMinMeetingDuration(Integer.valueOf(paramService.getParamValue(SysParamKeys.MEETING_MIN_MEETING_DURATION, "10")));
|
||||
resultVo.setMaxPauseDuration(Integer.valueOf(paramService.getParamValue(SysParamKeys.MEETING_MAX_PAUSE_DURATION,String.valueOf(60*4))));
|
||||
BigDecimal bigDecimal = new BigDecimal(paramService.getParamValue(SysParamKeys.MEETING_MAX_PAUSE_DURATION, "99"));
|
||||
bigDecimal = bigDecimal.setScale(2, RoundingMode.HALF_UP);
|
||||
|
|
|
|||
|
|
@ -35,6 +35,8 @@ public class AndroidMeetingConfigVo {
|
|||
private Integer maxPauseDuration;
|
||||
@io.swagger.v3.oas.annotations.media.Schema(description = "最大会议时长,单位分钟")
|
||||
private Integer maxMeetingDuration;
|
||||
@io.swagger.v3.oas.annotations.media.Schema(description = "最小会议时长,单位秒")
|
||||
private Integer minMeetingDuration;
|
||||
@io.swagger.v3.oas.annotations.media.Schema(description = "允许的最大丢包率")
|
||||
private BigDecimal packetLossRate;
|
||||
@io.swagger.v3.oas.annotations.media.Schema(description = "是否启用音频分片上传")
|
||||
|
|
|
|||
|
|
@ -47,3 +47,31 @@
|
|||
color: var(--link-color);
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-spin-nested-loading,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-spin-container,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table-container {
|
||||
height: 100%;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-spin-container,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table,
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table-container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table-content {
|
||||
flex: none;
|
||||
min-height: auto;
|
||||
}
|
||||
|
||||
.list-table-container .list-table-table--y-scroll.ant-table-wrapper .ant-table-body {
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
max-height: var(--list-table-scroll-y) !important;
|
||||
overflow-y: auto !important;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ function ListTable<T extends Record<string, any>>({
|
|||
className = "",
|
||||
onChange,
|
||||
}: ListTableProps<T>) {
|
||||
const hasVerticalScroll = scroll?.y !== undefined;
|
||||
const rowSelection: TableProps<T>["rowSelection"] = onSelectionChange
|
||||
? {
|
||||
selectedRowKeys,
|
||||
|
|
@ -101,9 +102,16 @@ function ListTable<T extends Record<string, any>>({
|
|||
),
|
||||
};
|
||||
|
||||
const wrapperStyle = hasVerticalScroll
|
||||
? ({
|
||||
["--list-table-scroll-y" as string]: typeof scroll.y === "number" ? `${scroll.y}px` : scroll.y,
|
||||
} as React.CSSProperties)
|
||||
: undefined;
|
||||
|
||||
return (
|
||||
<div className={`list-table-container ${className}`}>
|
||||
<div className={`list-table-container ${className}`} style={wrapperStyle}>
|
||||
<Table
|
||||
className={hasVerticalScroll ? "list-table-table--y-scroll" : undefined}
|
||||
size="middle"
|
||||
rowSelection={rowSelection}
|
||||
columns={columns}
|
||||
|
|
|
|||
|
|
@ -141,12 +141,25 @@
|
|||
font-size: 20px;
|
||||
}
|
||||
|
||||
.device-cell {
|
||||
width: 100%;
|
||||
min-width: 0;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.device-cell__content {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.device-name {
|
||||
display: block;
|
||||
font-weight: 600;
|
||||
color: #262626;
|
||||
}
|
||||
|
||||
.device-code {
|
||||
display: block;
|
||||
font-size: 12px;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
|
|
@ -162,6 +175,11 @@
|
|||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.app-page__table-wrap .ant-table-wrapper .ant-table-cell-fix-right-first,
|
||||
.app-page__table-wrap .ant-table-wrapper .ant-table-cell-fix-right-last {
|
||||
right: 0 !important;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.devices-page {
|
||||
padding: 16px;
|
||||
|
|
|
|||
|
|
@ -141,14 +141,19 @@ export default function Devices() {
|
|||
title: t("devicesExt.device"),
|
||||
key: "device",
|
||||
width: 280,
|
||||
ellipsis: {showTitle: true},
|
||||
render: (_value: unknown, record: DeviceInfo) => (
|
||||
<Space>
|
||||
<Space className="device-cell">
|
||||
<div className="device-icon-placeholder">
|
||||
<DesktopOutlined aria-hidden="true" />
|
||||
</div>
|
||||
<div>
|
||||
<div className="device-name font-medium">{record.deviceName || t("devicesExt.unnamedDevice")}</div>
|
||||
<div className="device-code text-xs text-gray-400 tabular-nums">{record.deviceCode}</div>
|
||||
<div className="device-cell__content">
|
||||
<Text className="device-name" ellipsis={{tooltip: record.deviceName || t("devicesExt.unnamedDevice")}}>
|
||||
{record.deviceName || t("devicesExt.unnamedDevice")}
|
||||
</Text>
|
||||
<Text className="device-code tabular-nums" ellipsis={{tooltip: record.deviceCode}}>
|
||||
{record.deviceCode}
|
||||
</Text>
|
||||
</div>
|
||||
</Space>
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in New Issue