Browse Source

增加会议评审类型枚举类

master
WendyYang 1 year ago
parent
commit
28b3e68fa8
1 changed files with 45 additions and 0 deletions
  1. +45
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/enumeration/MeetingReviewTypeEnum.java

+ 45
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/enumeration/MeetingReviewTypeEnum.java View File

@@ -0,0 +1,45 @@
package com.ningdatech.pmapi.meeting.entity.enumeration;

import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;

/**
* <p>
* MeetingReviewTypeEnum
* </p>
*
* @author WendyYang
* @since 16:32 2023/3/15
*/
@Getter
@AllArgsConstructor
public enum MeetingReviewTypeEnum {

/**
* 会议评审类型
*/
PRELIMINARY_SCHEME_REVIEW("初步方案评审", "1"),

CONSTRUCTION_SCHEME_REVIEW("建设方案评审", "2"),

ACCEPTANCE_SCHEME_REVIEW("验收方案评审", "3"),

DEPT_JOIN_REVIEW("部门联审", "4");

private final String value;
private final String code;

public boolean eq(String code) {
return this.getCode().equals(code);
}

public static MeetingReviewTypeEnum getByCode(String code) {
return Arrays.stream(values())
.filter(w -> w.getCode().equals(code))
.findFirst()
.orElseThrow(() -> new IllegalArgumentException("无效的会议评审类型编码"));
}

}

Loading…
Cancel
Save