# 工单评分管理功能类图

## 1. 整体架构

```mermaid
graph TD
    A[GxtOrderScoreController] --> B[IGxtOrderScoreService]
    B --> C[GxtOrderScoreServiceImpl]
    C --> D[GxtOrderScoreMapper]
    C --> E[IGxtRepairOrderService]
    C --> F[IGxtWorkOrderService]
    C --> G[其他相关服务]
    
    E --> H[GxtRepairOrderMapper]
    F --> I[GxtWorkOrderMapper]
    
    C --> J[IGxtRepairOrderFlowService]
    C --> K[IGxtWorkOrderFlowService]
    C --> L[IGxtUserScoreService]
    C --> M[IGxtMonthScoreService]
```

## 2. 控制层类图

```mermaid
classDiagram
    class GxtOrderScoreController {
        +IGxtRepairOrderService gxtRepairOrderService
        +IGxtWorkOrderService gxtWorkOrderService
        +IGxtOrderScoreService gxtOrderScoreService
        
        +list(GxtRepairOrder repairOrder, GxtWorkOrder workOrder) TableDataInfo
        +mobileList(GxtRepairOrder repairOrder, GxtWorkOrder workOrder, String keyword, String scoringStatus) TableDataInfo
        +getStatistics(GxtRepairOrder repairOrder, GxtWorkOrder workOrder, String month) AjaxResult
        +getInfo(Integer orderType, Long orderId) AjaxResult
        +selfEvaluation(OrderScoreInfo orderScoreInfo) AjaxResult
        +review(OrderScoreInfo orderScoreInfo) AjaxResult
        +finalEvaluation(OrderScoreInfo orderScoreInfo) AjaxResult
        +confirm(OrderScoreInfo orderScoreInfo) AjaxResult
        +appeal(OrderScoreInfo orderScoreInfo) AjaxResult
    }
    
    class BaseController {
        <<abstract>>
    }
    
    GxtOrderScoreController --|> BaseController
```

## 3. 服务层类图

```mermaid
classDiagram
    class IGxtOrderScoreService {
        <<interface>>
        +selectUnionOrderList(GxtRepairOrder, GxtWorkOrder, String) List~OrderScoreInfo~
        +getOrderScoreStatistics(GxtRepairOrder, GxtWorkOrder, String) Map~String,Object~
        +selfEvaluation(OrderScoreInfo) int
        +review(OrderScoreInfo) int
        +finalEvaluation(OrderScoreInfo) int
        +confirm(OrderScoreInfo) int
        +appeal(OrderScoreInfo) int
    }
    
    class GxtOrderScoreServiceImpl {
        -GxtOrderScoreMapper gxtOrderScoreMapper
        -IGxtRepairOrderService gxtRepairOrderService
        -IGxtWorkOrderService gxtWorkOrderService
        -SysUserMapper userMapper
        -ISysConfigService configService
        -IGxtRepairOrderFlowService repairOrderFlowService
        -IGxtWorkOrderFlowService gxtWorkOrderFlowService
        -IGxtUserScoreService gxtUserScoreService
        -IGxtMonthScoreService gxtMonthScoreService
        -SysDeptMapper sysDeptMapper
        -RedisCache redisCache
        
        +selectUnionOrderList(GxtRepairOrder, GxtWorkOrder, String) List~OrderScoreInfo~
        +getOrderScoreStatistics(GxtRepairOrder, GxtWorkOrder, String) Map~String,Object~
        +selfEvaluation(OrderScoreInfo) int
        +review(OrderScoreInfo) int
        +finalEvaluation(OrderScoreInfo) int
        +confirm(OrderScoreInfo) int
        +appeal(OrderScoreInfo) int
    }
    
    IGxtOrderScoreService <|.. GxtOrderScoreServiceImpl
```

## 4. 数据访问层类图

```mermaid
classDiagram
    class GxtOrderScoreMapper {
        +selectUnionOrderList(GxtRepairOrder, GxtWorkOrder, String) List~OrderScoreInfo~
        +selectOrderScoreStatistics(GxtRepairOrder, GxtWorkOrder, String) Map~String,Object~
        +selectMobileUnionOrderList(GxtRepairOrder, GxtWorkOrder, String) List~OrderScoreInfo~
    }
```

## 5. 实体类关系图

```mermaid
classDiagram
    class OrderScoreInfo {
        -Integer orderType
        -Long id
        -String workOrderProjectNo
        -String workOrderStatus
        -String scoringStatus
        -String workSummary
        -String maintenanceType
        -String inspectionType
        -BigDecimal itemCompletionFactor
        -BigDecimal itemCompletionFactorSum
        -Integer reviewScoreNum
        -BigDecimal finalCoefficient
        -Integer confirmStatus
        -String feedbackReason
        -String appealReason
        -List~OrderScorePerson~ scorePersonList
        -BigDecimal myScore
    }
    
    class OrderScorePerson {
        -Long id
        -Long userId
        -String nickName
        -String userName
        -Double selfScore
        -Double reviewScore
        -Double finalScore
        -Integer isLeader
        -String feedbackReason
        -Integer confirmStatus
    }
    
    class GxtRepairOrder {
        -Long id
        -String workOrderProjectNo
        -String workOrderStatus
        -String scoringStatus
        -String content
        -String maintenanceType
        -Integer reviewScoreNum
        -BigDecimal finalCoefficient
        -BigDecimal score
    }
    
    class GxtWorkOrder {
        -Long id
        -String workOrderProjectNo
        -String workOrderStatus
        -String scoringStatus
        -String realContent
        -String inspectionType
        -BigDecimal itemCompletionFactor
        -BigDecimal itemCompletionFactorSum
        -BigDecimal score
    }
    
    class GxtRepairOrderPerson {
        -Long id
        -Long userId
        -String nickName
        -Double selfScore
        -Double reviewScore
        -Double finalScore
        -Integer isLeader
        -String feedbackReason
        -Integer confirmStatus
        -BigDecimal score
    }
    
    class GxtWorkOrderPerson {
        -Long id
        -Long userId
        -String nickName
        -Double selfScore
        -Double reviewScore
        -Double finalScore
        -Integer isLeader
        -String feedbackReason
        -Integer confirmStatus
        -BigDecimal score
    }
    
    OrderScoreInfo "1" --> "0..*" OrderScorePerson : contains
    GxtRepairOrder "1" --> "0..*" GxtRepairOrderPerson : contains
    GxtWorkOrder "1" --> "0..*" GxtWorkOrderPerson : contains
```

## 6. 流程记录类图

```mermaid
classDiagram
    class GxtRepairOrderFlow {
        -Long id
        -Long orderId
        -String orderCode
        -String actionType
        -String fromStatus
        -String toStatus
        -String fromScoreStatus
        -String toScoreStatus
        -Long operatorId
        -String operatorName
        -Date actionTime
        -String actionRemark
    }
    
    class GxtWorkOrderFlow {
        -Long id
        -Long orderId
        -String orderCode
        -String actionType
        -String fromStatus
        -String toStatus
        -String fromScoreStatus
        -String toScoreStatus
        -Long operatorId
        -String operatorName
        -Date actionTime
        -String actionRemark
    }
```
