52 lines
1.2 KiB
Plaintext
52 lines
1.2 KiB
Plaintext
package th.co.muangthai.endrprint.model.bean.form;
|
|
|
|
import th.co.muangthai.endrprint.util.TextContent;
|
|
|
|
import java.io.Serializable;
|
|
import java.math.BigDecimal;
|
|
|
|
public class MsgErrorForm implements Serializable {
|
|
|
|
private BigDecimal errorFlag; // 0 = pass , 1 = error
|
|
private String errorDesc;
|
|
private BigDecimal htmlFlag; // 0 = close tag html ; 1 open tag html
|
|
|
|
public void setDataDefaultOk(){
|
|
setErrorFlag(TextContent.errorFlagOK);
|
|
setErrorDesc(null);
|
|
}
|
|
|
|
public void setDataErrorException(Exception e){
|
|
setErrorFlag(TextContent.errorFlagER);
|
|
setErrorDesc(TextContent.getErrorMsg(e));
|
|
}
|
|
|
|
public void setDataErrorException(String txt){
|
|
setErrorFlag(TextContent.errorFlagER);
|
|
setErrorDesc(txt);
|
|
}
|
|
|
|
public BigDecimal getErrorFlag() {
|
|
return errorFlag;
|
|
}
|
|
|
|
public void setErrorFlag(BigDecimal errorFlag) {
|
|
this.errorFlag = errorFlag;
|
|
}
|
|
|
|
public String getErrorDesc() {
|
|
return errorDesc;
|
|
}
|
|
|
|
public void setErrorDesc(String errorDesc) {
|
|
this.errorDesc = errorDesc;
|
|
}
|
|
|
|
public BigDecimal getHtmlFlag() {
|
|
return htmlFlag;
|
|
}
|
|
|
|
public void setHtmlFlag(BigDecimal htmlFlag) {
|
|
this.htmlFlag = htmlFlag;
|
|
}
|
|
} |