<?php

namespace app\common\state;

class IntegralState {

    public const SAVE = 1; //保存未提交
    public const SUBMIT = 2; //已提交未审核
    public const VERIFY_PASS = 3; //初审通过
    public const VERIFY_REJECT = 4; //初审驳回
    public const VERIFY_FAIL = 5; //初审失败
    public const REVERIFY_PASS = 6; //复审通过
    public const REVERIFY_REJECT = 7; //复审驳回
    public const REVERIFY_FAIL = 8; //复审失败
    public const ZX_PASS = 21; //征信通过|待公示
    public const ZX_FAIL = 22; //征信失信|审核不通过
    public const ANNOUNCED = 23; //已公示
    public const ANNOUNCED_REVERIFY_PASS = 24; //公示再审核通过|待公布
    public const ANNOUNCED_REVERIFY_FAIL = 25; //公示再审核不通过
    public const PUBLISH_PASS = 26; //公布通过
    public const PUBLISH_FAIL = 27; //公布不通过
    public const SUCCESS = 28; //积分兑现成功

    public static function getLogStepName($state) {
        switch ($state) {
            case 3:
            case 4:
            case 5:
                return '<span class="label label-primary">初级审核</span>';
            case 6:
            case 7:
            case 8:
                return '<span class="label label-info">复核</span>';
            case 21:
            case 22:
                return '<span class="label label-info">核查征信</span>';
            case 23:
            case 24:
            case 25:
                return '<span class="label label-info">公示</span>';
            case 26:
            case 27:
                return '<span class="label label-info">公布</span>';
            case 28:
                return '<span class="label label-inverse">发放人才码</span>';
            default:
                return "<span class='label'>用户操作</span>";
        }
    }

    public static function getLogStateName($state) {
        switch ($state) {
            case 1:
                return '<span class="label">用户保存</span>';
            case 2:
                return '<span class="label">用户提交</span>';
            case 3:
                return '<span class="label">用户提交</span>';
            case 4:
                return '<span class="label">用户提交</span>';
            case 5:
                return '<span class="label">用户提交</span>';
            case 6:
                return '<span class="label">用户提交</span>';
            case 7:
                return '<span class="label">用户提交</span>';
            case 8:
                return '<span class="label">用户提交</span>';
            default:
                return '<span class="label">添加附件</span>';
        }
    }

}
