parent
3b2718e6fe
commit
7b563647f4
@ -0,0 +1,26 @@
|
||||
package au.com.royalpay.payment.manage.mappers.system;
|
||||
|
||||
import cn.yixblog.support.mybatis.autosql.annotations.AdvanceSelect;
|
||||
import cn.yixblog.support.mybatis.autosql.annotations.AutoMapper;
|
||||
import cn.yixblog.support.mybatis.autosql.annotations.AutoSql;
|
||||
import cn.yixblog.support.mybatis.autosql.annotations.SqlType;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import javax.validation.constraints.Max;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by yixian on 2017-03-14.
|
||||
*/
|
||||
@AutoMapper(tablename = "sys_wx_merchant_apply",pkName = "merchant_app_id")
|
||||
public interface SysWxMerchantApplyMapper {
|
||||
@AutoSql(type = SqlType.SELECT)
|
||||
List<JSONObject> listWxMerchantApplices(@Param("client_id") int client_id);
|
||||
|
||||
@AutoSql(type = SqlType.INSERT)
|
||||
void insertWxMerchantApply(JSONObject params);
|
||||
|
||||
@AutoSql(type = SqlType.UPDATE)
|
||||
void updateWxMerchantApply(JSONObject params);
|
||||
}
|
@ -0,0 +1,162 @@
|
||||
package au.com.royalpay.payment.manage.merchants.beans;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.alibaba.fastjson.annotation.JSONField;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.constraints.NotBlank;
|
||||
|
||||
/**
|
||||
* Created by yuan on 2018/1/19.
|
||||
*/
|
||||
public class SubMerchantIdApply {
|
||||
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@Length(max = 50)
|
||||
@JSONField(name = "company_name")
|
||||
private String merchant_name;
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@Length(max = 20)
|
||||
@JSONField(name = "short_name")
|
||||
private String merchant_shortname;
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@Length(max = 20)
|
||||
@JSONField(name = "company_phone")
|
||||
private String office_phone;
|
||||
@JSONField(name = "contact_person")
|
||||
private String contact_name;
|
||||
private String contact_phone;
|
||||
private String contact_email;
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@JSONField(name = "industry")
|
||||
private String business_category;
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@Length(max = 20)
|
||||
@JSONField(name = "remark")
|
||||
private String merchant_remark;
|
||||
@JSONField(name = "company_website")
|
||||
private String website;
|
||||
@NotBlank(message = "error.payment.valid.param_missing")
|
||||
@Length(min = 10, max = 256)
|
||||
@JSONField(name = "description")
|
||||
private String merchant_introduction;
|
||||
|
||||
public JSONObject insertObject() {
|
||||
JSONObject params = new JSONObject();
|
||||
if(StringUtils.isNotEmpty(merchant_name)){
|
||||
params.put("merchant_name",merchant_name);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(merchant_shortname)){
|
||||
params.put("merchant_shortname",merchant_shortname);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(office_phone)){
|
||||
params.put("office_phone",office_phone);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(contact_name)){
|
||||
params.put("contact_name",contact_name);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(contact_phone)){
|
||||
params.put("contact_phone",contact_phone);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(contact_email)){
|
||||
params.put("contact_email",contact_email);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(business_category)){
|
||||
params.put("business_category",business_category);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(merchant_remark)){
|
||||
params.put("merchant_remark",merchant_remark);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(website)){
|
||||
params.put("website",website);
|
||||
}
|
||||
if(StringUtils.isNotEmpty(merchant_introduction)){
|
||||
params.put("merchant_introduction",merchant_introduction);
|
||||
}
|
||||
return params;
|
||||
}
|
||||
|
||||
public SubMerchantIdApply() {
|
||||
}
|
||||
|
||||
public String getMerchant_name() {
|
||||
return this.merchant_name;
|
||||
}
|
||||
|
||||
public void setMerchant_name(String merchant_name) {
|
||||
this.merchant_name = merchant_name;
|
||||
}
|
||||
|
||||
public String getMerchant_shortname() {
|
||||
return this.merchant_shortname;
|
||||
}
|
||||
|
||||
public void setMerchant_shortname(String merchant_shortname) {
|
||||
this.merchant_shortname = merchant_shortname;
|
||||
}
|
||||
|
||||
public String getOffice_phone() {
|
||||
return this.office_phone;
|
||||
}
|
||||
|
||||
public void setOffice_phone(String office_phone) {
|
||||
this.office_phone = office_phone;
|
||||
}
|
||||
|
||||
public String getContact_name() {
|
||||
return this.contact_name;
|
||||
}
|
||||
|
||||
public void setContact_name(String contact_name) {
|
||||
this.contact_name = contact_name;
|
||||
}
|
||||
|
||||
public String getContact_phone() {
|
||||
return this.contact_phone;
|
||||
}
|
||||
|
||||
public void setContact_phone(String contact_phone) {
|
||||
this.contact_phone = contact_phone;
|
||||
}
|
||||
|
||||
public String getContact_email() {
|
||||
return this.contact_email;
|
||||
}
|
||||
|
||||
public void setContact_email(String contact_email) {
|
||||
this.contact_email = contact_email;
|
||||
}
|
||||
|
||||
public String getBusiness_category() {
|
||||
return this.business_category;
|
||||
}
|
||||
|
||||
public void setBusiness_category(String business_category) {
|
||||
this.business_category = business_category;
|
||||
}
|
||||
|
||||
public String getMerchant_remark() {
|
||||
return this.merchant_remark;
|
||||
}
|
||||
|
||||
public void setMerchant_remark(String merchant_remark) {
|
||||
this.merchant_remark = merchant_remark;
|
||||
}
|
||||
|
||||
public String getMerchant_introduction() {
|
||||
return this.merchant_introduction;
|
||||
}
|
||||
|
||||
public void setMerchant_introduction(String merchant_introduction) {
|
||||
this.merchant_introduction = merchant_introduction;
|
||||
}
|
||||
|
||||
public String getWebsite() {
|
||||
return this.website;
|
||||
}
|
||||
|
||||
public void setWebsite(String website) {
|
||||
this.website = website;
|
||||
}
|
||||
}
|
Loading…
Reference in new issue