Administrator
2022-06-13 f70d9a7b19b8451532de026bf1e6b2a5770c16bd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package org.springblade.common.utils;
 
import java.util.Calendar;
import java.util.Date;
 
/**
 * 保安证编号生成
 * @author zhongrj
 * @since 2021-08-11
 */
public class SecurityPaperUtil {
 
    private final static String pre = "赣洪";
 
    public static String getSecurityPaper(){
        //获取当前时间
        Date date = new Date();
        Calendar instance = Calendar.getInstance();
        instance.setTime(date);
        //获取年份
        int year = instance.get(Calendar.YEAR);
        return pre+year;
    }
}