AjaxResultSrmBack.java 1.01 KB
package com.huaheng.framework.web.domain;

import java.io.Serializable;
import java.util.List;

import com.alibaba.fastjson.annotation.JSONField;

import lombok.Data;

/**
 *
 * @author huaheng
 */
@Data
public class AjaxResultSrmBack<T> implements Serializable
{
    private static final long serialVersionUID = 1L;

    @JSONField(name = "IsOK")
    public Boolean IsOK;
    @JSONField(name = "Message")
    private String Message;
    @JSONField(name = "RD01List")
    private List<RD01List> rd01Lists;


    /**
     * erp返回体解析
     * @return
     */
    public  AjaxResult responseAnalyz(){
        if(IsOK){
            return AjaxResult.success(Message);
        }else{
//            if(rd01Lists!=null&&rd01Lists.size()>0){
//                String mes=rd01Lists.get(0).getMessage();
//                if(mes.contains("请购单号已存在")){
//                    return AjaxResult.success("请购单号已存在");
//                }
//            }
            return AjaxResult.error(Message);
        }
    }


}