|
|
@@ -2,12 +2,13 @@ import React from 'react';
|
|
|
import { Layout, Button, Typography, Divider, Flex } from 'antd';
|
|
|
import { ArrowLeftOutlined } from '@ant-design/icons';
|
|
|
import { useIntl } from 'react-intl';
|
|
|
-import { useDispatch } from 'react-redux';
|
|
|
+import { useDispatch, useSelector } from 'react-redux';
|
|
|
import { switchToOperationPanel } from '../../../states/panelSwitchSliceForView';
|
|
|
import {
|
|
|
setMeasurementAction,
|
|
|
type MeasurementAction,
|
|
|
} from '../../../states/view/measurementPanelSlice';
|
|
|
+import type { RootState } from '../../../states/store';
|
|
|
import Icon from '@/components/Icon';
|
|
|
import '@/themes/truncateText.css';
|
|
|
|
|
|
@@ -65,6 +66,7 @@ const FunctionButton = ({
|
|
|
const MeasurementPanel = () => {
|
|
|
const intl = useIntl();
|
|
|
const dispatch = useDispatch();
|
|
|
+ const productName = useSelector((state: RootState) => state.product.productName);
|
|
|
|
|
|
const handleReturn = () => {
|
|
|
dispatch(switchToOperationPanel());
|
|
|
@@ -152,136 +154,138 @@ const MeasurementPanel = () => {
|
|
|
<Divider />
|
|
|
|
|
|
{/* 宠物专用测量组 */}
|
|
|
- <div style={{ marginBottom: '24px' }}>
|
|
|
- <Text
|
|
|
- strong
|
|
|
- style={{ fontSize: '14px', marginBottom: '12px', display: 'block' }}
|
|
|
- >
|
|
|
- {intl.formatMessage({ id: 'measurementPanel.petSpecificMeasurements' })}
|
|
|
- </Text>
|
|
|
- <Flex wrap gap="small" align="center" justify="start" className="p-1">
|
|
|
- <FunctionButton
|
|
|
- title="髋臼水平角"
|
|
|
- action="髋臼水平角"
|
|
|
- iconName="btn_DAR"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="胫骨平台夹角"
|
|
|
- action="胫骨平台夹角"
|
|
|
- iconName="btn_TPA"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="髋关节牵引指数"
|
|
|
- action="髋关节牵引指数"
|
|
|
- iconName="btn_HDI"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="髋关节水平角"
|
|
|
- action="髋关节水平角"
|
|
|
- iconName="btn_NHA"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="心锥比"
|
|
|
- action="心锥比"
|
|
|
- iconName="btn_VHS"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="胫骨平台骨切开术"
|
|
|
- action="胫骨平台骨切开术"
|
|
|
- iconName="btn_TPLO"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="胫骨结节前移术"
|
|
|
- action="胫骨结节前移术"
|
|
|
- iconName="btn_TTA"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="胫骨结节前移术5点测量法"
|
|
|
- action="胫骨结节前移术5点测量法"
|
|
|
- iconName="btn_TTA2"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="水平截骨术"
|
|
|
- action="水平截骨术"
|
|
|
- iconName="btn_CBLO"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="股骨头覆盖率"
|
|
|
- action="股骨头覆盖率"
|
|
|
- iconName="btn_DLS"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="髋臼背覆盖"
|
|
|
- action="髋臼背覆盖"
|
|
|
- iconName="btn_DAC"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="拆线长度测量"
|
|
|
- action="拆线长度测量"
|
|
|
- iconName="btn_FoldLine"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="多边形长度测量"
|
|
|
- action="多边形长度测量"
|
|
|
- iconName="btn_Polygon"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="找圆心"
|
|
|
- action="找圆心"
|
|
|
- iconName="btn_CenterCircle"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="找中线"
|
|
|
- action="找中线"
|
|
|
- iconName="btn_CenterLine"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="找中点"
|
|
|
- action="找中点"
|
|
|
- iconName="btn_Midpoint"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="直线垂直倾斜度"
|
|
|
- action="直线垂直倾斜度"
|
|
|
- iconName="btn_VerticalInclination"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="直线水平倾斜度"
|
|
|
- action="直线水平倾斜度"
|
|
|
- iconName="btn_HorizontalInclination"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="矩形区域灰度"
|
|
|
- action="矩形区域灰度"
|
|
|
- iconName="btn_RectangularGrayscale"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- <FunctionButton
|
|
|
- title="直线灰度"
|
|
|
- action="直线灰度"
|
|
|
- iconName="btn_LineGrayscale"
|
|
|
- productId="animal"
|
|
|
- />
|
|
|
- </Flex>
|
|
|
- </div>
|
|
|
+ {productName === 'VETDROS' && (
|
|
|
+ <div style={{ marginBottom: '24px' }}>
|
|
|
+ <Text
|
|
|
+ strong
|
|
|
+ style={{ fontSize: '14px', marginBottom: '12px', display: 'block' }}
|
|
|
+ >
|
|
|
+ {intl.formatMessage({ id: 'measurementPanel.petSpecificMeasurements' })}
|
|
|
+ </Text>
|
|
|
+ <Flex wrap gap="small" align="center" justify="start" className="p-1">
|
|
|
+ <FunctionButton
|
|
|
+ title="髋臼水平角"
|
|
|
+ action="髋臼水平角"
|
|
|
+ iconName="btn_DAR"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="胫骨平台夹角"
|
|
|
+ action="胫骨平台夹角"
|
|
|
+ iconName="btn_TPA"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="髋关节牵引指数"
|
|
|
+ action="髋关节牵引指数"
|
|
|
+ iconName="btn_HDI"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="髋关节水平角"
|
|
|
+ action="髋关节水平角"
|
|
|
+ iconName="btn_NHA"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="心锥比"
|
|
|
+ action="心锥比"
|
|
|
+ iconName="btn_VHS"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="胫骨平台骨切开术"
|
|
|
+ action="胫骨平台骨切开术"
|
|
|
+ iconName="btn_TPLO"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="胫骨结节前移术"
|
|
|
+ action="胫骨结节前移术"
|
|
|
+ iconName="btn_TTA"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="胫骨结节前移术5点测量法"
|
|
|
+ action="胫骨结节前移术5点测量法"
|
|
|
+ iconName="btn_TTA2"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="水平截骨术"
|
|
|
+ action="水平截骨术"
|
|
|
+ iconName="btn_CBLO"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="股骨头覆盖率"
|
|
|
+ action="股骨头覆盖率"
|
|
|
+ iconName="btn_DLS"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="髋臼背覆盖"
|
|
|
+ action="髋臼背覆盖"
|
|
|
+ iconName="btn_DAC"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="拆线长度测量"
|
|
|
+ action="拆线长度测量"
|
|
|
+ iconName="btn_FoldLine"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="多边形长度测量"
|
|
|
+ action="多边形长度测量"
|
|
|
+ iconName="btn_Polygon"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="找圆心"
|
|
|
+ action="找圆心"
|
|
|
+ iconName="btn_CenterCircle"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="找中线"
|
|
|
+ action="找中线"
|
|
|
+ iconName="btn_CenterLine"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="找中点"
|
|
|
+ action="找中点"
|
|
|
+ iconName="btn_Midpoint"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="直线垂直倾斜度"
|
|
|
+ action="直线垂直倾斜度"
|
|
|
+ iconName="btn_VerticalInclination"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="直线水平倾斜度"
|
|
|
+ action="直线水平倾斜度"
|
|
|
+ iconName="btn_HorizontalInclination"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="矩形区域灰度"
|
|
|
+ action="矩形区域灰度"
|
|
|
+ iconName="btn_RectangularGrayscale"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ <FunctionButton
|
|
|
+ title="直线灰度"
|
|
|
+ action="直线灰度"
|
|
|
+ iconName="btn_LineGrayscale"
|
|
|
+ productId="animal"
|
|
|
+ />
|
|
|
+ </Flex>
|
|
|
+ </div>
|
|
|
+ )}
|
|
|
</Content>
|
|
|
</Layout>
|
|
|
);
|