优化及修改

This commit is contained in:
yiyan 2018-08-12 16:42:41 +08:00
parent 77d6b04e6e
commit 3c0f1472e9
23 changed files with 901 additions and 536 deletions

View File

@ -11,8 +11,11 @@ import com.ifish.service.VipService;
import com.ifish.util.IfishUtil; import com.ifish.util.IfishUtil;
import com.ifish.util.SmsUtil; import com.ifish.util.SmsUtil;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.security.core.context.SecurityContextImpl; import org.springframework.security.core.context.SecurityContextImpl;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap; import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
@ -33,17 +36,22 @@ import java.util.List;
* @Modified by: * @Modified by:
*/ */
@Controller("VipAction") @Controller("VipAction")
@Component
@RequestMapping("/vip") @RequestMapping("/vip")
public class VipAction { public class VipAction {
private final Logger log = Logger.getLogger(VipAction.class);
@Autowired @Autowired
private VipService vipService; private VipService vipService;
@RequestMapping("/sendSms.do") @RequestMapping("/sendSms.do")
@ResponseBody @ResponseBody
public boolean vipSendSms(HttpServletRequest request) throws ClientException { public Object vipSendSms(HttpServletRequest request) throws ClientException {
final String noticeType = "SMS_139227937"; final String noticeType = "SMS_139227937";
final String noticeTypeCertif = "SMS_142150098";
final String noticeTypeMember = "SMS_142145967";
String oneTel = request.getParameter("oneTel"); String oneTel = request.getParameter("oneTel");
String smsType = request.getParameter("smsType"); String smsType = request.getParameter("smsType");
//生日 //生日
@ -55,11 +63,23 @@ public class VipAction {
String smsSignTime = request.getParameter("smsSignTime"); String smsSignTime = request.getParameter("smsSignTime");
String smsContact = request.getParameter("smsContact"); String smsContact = request.getParameter("smsContact");
String smsContactTel = request.getParameter("smsContactTel"); String smsContactTel = request.getParameter("smsContactTel");
//证书到期通知
String smsCertifDate = request.getParameter("smsCertifDate");
String smsCertifTel = request.getParameter("smsCertifTel");
//会员到期通知
String smsMemberDate = request.getParameter("smsMemberDate");
String smsMoney = request.getParameter("smsMoney");
String smsAccountName = request.getParameter("smsAccountName");
String smsAccountBankName = request.getParameter("smsAccountBankName");
String smsAccountCode = request.getParameter("smsAccountCode");
String smsMemberTel = request.getParameter("smsMemberTel");
SendSmsResponse response = null;
JSONObject param = new JSONObject(); JSONObject param = new JSONObject();
//单个发送 //单个发送
if (oneTel != null && StringUtils.isNotBlank(oneTel)) { if (oneTel != null && StringUtils.isNotBlank(oneTel)) {
VipSmsResult vipSmsResult = new VipSmsResult(); VipSmsResult vipSmsResult = new VipSmsResult();
SendSmsResponse response = null;
String[] idTel = oneTel.split("_"); String[] idTel = oneTel.split("_");
String id = idTel[0]; String id = idTel[0];
VipMember vipMember = this.vipService.getVipMember(Integer.parseInt(id)); VipMember vipMember = this.vipService.getVipMember(Integer.parseInt(id));
@ -73,7 +93,23 @@ public class VipAction {
param.put("signTime",smsSignTime); param.put("signTime",smsSignTime);
param.put("contact",smsContact + " " + smsContactTel); param.put("contact",smsContact + " " + smsContactTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString()); response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
System.out.println("单条短信发送-Result" + response.getCode() + "-" + response.getMessage()); log.info("活动通知单条短信发送-Result" + response.getCode() + "-" + response.getMessage());
} else if (noticeTypeCertif.equals(smsType)) {
param.put("name",vipMember.getMemberLegal());
param.put("date",smsCertifDate);
param.put("tel",smsCertifTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
log.info("证书到期单条短信发送-Result" + response.getCode() + "-" + response.getMessage());
} else if (noticeTypeMember.equals(smsType)) {
param.put("name",vipMember.getMemberLegal());
param.put("date",smsMemberDate);
param.put("money",smsMoney);
param.put("accountName",smsAccountName);
param.put("accountBankName",smsAccountBankName);
param.put("accountCode",smsAccountCode);
param.put("tel",smsMemberTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
log.info("会员到期通知单条短信发送-Result" + response.getCode() + "-" + response.getMessage());
} }
vipSmsResult.setResultCode(response.getCode()); vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage()); vipSmsResult.setResultMessage(response.getMessage());
@ -91,7 +127,6 @@ public class VipAction {
String id = idTel[0]; String id = idTel[0];
VipMember vipMember = this.vipService.getVipMember(Integer.parseInt(id)); VipMember vipMember = this.vipService.getVipMember(Integer.parseInt(id));
VipSmsResult vipSmsResult = new VipSmsResult(); VipSmsResult vipSmsResult = new VipSmsResult();
SendSmsResponse response = null;
vipSmsResult.setResultBussId(Integer.parseInt(id)); vipSmsResult.setResultBussId(Integer.parseInt(id));
vipSmsResult.setResultTel(vipMember.getMemberTel()); vipSmsResult.setResultTel(vipMember.getMemberTel());
vipSmsResult.setResultTemplate(smsType); vipSmsResult.setResultTemplate(smsType);
@ -103,7 +138,23 @@ public class VipAction {
param.put("signTime",smsSignTime); param.put("signTime",smsSignTime);
param.put("contact",smsContact + " " + smsContactTel); param.put("contact",smsContact + " " + smsContactTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString()); response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
System.out.println("多条短信发送-Result" + response.getCode() + "-" + response.getMessage()); log.info("多条短信发送-Result" + response.getCode() + "-" + response.getMessage());
}else if (noticeTypeCertif.equals(smsType)) {
param.put("name",vipMember.getMemberLegal());
param.put("date",smsCertifDate);
param.put("tel",smsCertifTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
log.info("证书到期多条短信发送-Result" + response.getCode() + "-" + response.getMessage());
} else if (noticeTypeMember.equals(smsType)) {
param.put("name",vipMember.getMemberLegal());
param.put("date",smsMemberDate);
param.put("money",smsMoney);
param.put("accountName",smsAccountName);
param.put("accountBankName",smsAccountBankName);
param.put("accountCode",smsAccountCode);
param.put("tel",smsMemberTel);
response = SmsUtil.sendSms(vipMember.getMemberTel(), smsType, param.toJSONString());
log.info("会员到期通知多条短信发送-Result" + response.getCode() + "-" + response.getMessage());
} }
vipSmsResult.setResultCode(response.getCode()); vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage()); vipSmsResult.setResultMessage(response.getMessage());
@ -113,6 +164,9 @@ public class VipAction {
this.vipService.saveSmsResult(vipSmsResult); this.vipService.saveSmsResult(vipSmsResult);
} }
} }
if (!"OK".equals(response.getCode())) {
return response.getMessage();
}
return true; return true;
} }
@ -313,8 +367,10 @@ public class VipAction {
request.setAttribute("vipMember",vipMember); request.setAttribute("vipMember",vipMember);
List<VipCompany> vipCompanys = this.vipService.getVipCompanys(memberId); List<VipCompany> vipCompanys = this.vipService.getVipCompanys(memberId);
request.setAttribute("companys",vipCompanys); request.setAttribute("companys",vipCompanys);
VipReferrer vipReferrer = this.vipService.getVipReferrer(vipMember.getMemberReferrer().getReferrerId()); if (vipMember.getMemberReferrer() != null) {
request.setAttribute("vipReferrer",vipReferrer); VipReferrer vipReferrer = this.vipService.getVipReferrer(vipMember.getMemberReferrer().getReferrerId());
request.setAttribute("vipReferrer",vipReferrer);
}
return new ModelAndView("vip/vipMemberUpdate"); return new ModelAndView("vip/vipMemberUpdate");
} }

View File

@ -23,6 +23,9 @@ public class VipMember implements Serializable{
@Column(name = "vip_member_id") @Column(name = "vip_member_id")
private Integer memberId; private Integer memberId;
@Column(name = "vip_member_code")
private String memberCode;
@Column(name = "vip_member_name") @Column(name = "vip_member_name")
private String memberName; private String memberName;
@ -85,6 +88,18 @@ public class VipMember implements Serializable{
@Column(name = "vip_member_address") @Column(name = "vip_member_address")
private String memberAddress; private String memberAddress;
@Column(name = "vip_member_important_contact")
private String memberImportantContact;
@Column(name = "vip_member_important_tel")
private String memberImportantTel;
@Column(name = "vip_member_handling_contact")
private String memberHandlingContact;
@Column(name = "vip_member_handling_tel")
private String memberHandlingTel;
@Column(name = "vip_member_email") @Column(name = "vip_member_email")
private String memberEmail; private String memberEmail;
@ -101,7 +116,7 @@ public class VipMember implements Serializable{
private String memberItem; private String memberItem;
@Column(name = "vip_member_fee") @Column(name = "vip_member_fee")
private Double memberFee; private String memberFee;
@Column(name = "vip_member_qualification") @Column(name = "vip_member_qualification")
private String memberQualification; private String memberQualification;
@ -148,6 +163,14 @@ public class VipMember implements Serializable{
this.memberId = memberId; this.memberId = memberId;
} }
public String getMemberCode() {
return memberCode;
}
public void setMemberCode(String memberCode) {
this.memberCode = memberCode;
}
public String getMemberName() { public String getMemberName() {
return memberName; return memberName;
} }
@ -288,6 +311,38 @@ public class VipMember implements Serializable{
return memberAddress; return memberAddress;
} }
public String getMemberImportantContact() {
return memberImportantContact;
}
public void setMemberImportantContact(String memberImportantContact) {
this.memberImportantContact = memberImportantContact;
}
public String getMemberImportantTel() {
return memberImportantTel;
}
public void setMemberImportantTel(String memberImportantTel) {
this.memberImportantTel = memberImportantTel;
}
public String getMemberHandlingContact() {
return memberHandlingContact;
}
public void setMemberHandlingContact(String memberHandlingContact) {
this.memberHandlingContact = memberHandlingContact;
}
public String getMemberHandlingTel() {
return memberHandlingTel;
}
public void setMemberHandlingTel(String memberHandlingTel) {
this.memberHandlingTel = memberHandlingTel;
}
public void setMemberAddress(String memberAddress) { public void setMemberAddress(String memberAddress) {
this.memberAddress = memberAddress; this.memberAddress = memberAddress;
} }
@ -332,14 +387,6 @@ public class VipMember implements Serializable{
this.memberItem = memberItem; this.memberItem = memberItem;
} }
public Double getMemberFee() {
return memberFee;
}
public void setMemberFee(Double memberFee) {
this.memberFee = memberFee;
}
public String getMemberQualification() { public String getMemberQualification() {
return memberQualification; return memberQualification;
} }
@ -427,4 +474,12 @@ public class VipMember implements Serializable{
public void setMemberQualificationInfo(String memberQualificationInfo) { public void setMemberQualificationInfo(String memberQualificationInfo) {
this.memberQualificationInfo = memberQualificationInfo; this.memberQualificationInfo = memberQualificationInfo;
} }
public String getMemberFee() {
return memberFee;
}
public void setMemberFee(String memberFee) {
this.memberFee = memberFee;
}
} }

View File

@ -33,13 +33,13 @@ public class VipActivityImportTemplateExcel extends AbstractExcelView {
HSSFSheet sheet = workbook.createSheet("sheet"); HSSFSheet sheet = workbook.createSheet("sheet");
sheet.autoSizeColumn(0); sheet.autoSizeColumn(0);
getCell(sheet,0,0).setCellValue("单位名称(必填)"); getCell(sheet,0,0).setCellValue("单位名称");
getCell(sheet,0,1).setCellValue("联系人(必填)"); getCell(sheet,0,1).setCellValue("联系人");
getCell(sheet,0,2).setCellValue("手机(必填)"); getCell(sheet,0,2).setCellValue("手机");
getCell(sheet,0,3).setCellValue("电话(必填)"); getCell(sheet,0,3).setCellValue("电话");
getCell(sheet,0,4).setCellValue("邮箱(必填)"); getCell(sheet,0,4).setCellValue("邮箱");
getCell(sheet,0,5).setCellValue("职位(必填)"); getCell(sheet,0,5).setCellValue("职位");
getCell(sheet,0,6).setCellValue("微信(必填)"); getCell(sheet,0,6).setCellValue("微信");
HSSFCellStyle cellStyle = workbook.createCellStyle(); HSSFCellStyle cellStyle = workbook.createCellStyle();

View File

@ -55,25 +55,39 @@ public class VipCompanyExportExcel extends AbstractExcelView{
getCell(sheet,i+1,1).setCellValue(vipCompany.getCertificateCard()); getCell(sheet,i+1,1).setCellValue(vipCompany.getCertificateCard());
getCell(sheet,i+1,2).setCellValue(vipCompany.getCertificateLevel()); getCell(sheet,i+1,2).setCellValue(vipCompany.getCertificateLevel());
getCell(sheet,i+1,3).setCellValue(vipCompany.getCertificateType()); getCell(sheet,i+1,3).setCellValue(vipCompany.getCertificateType());
Date certificateApplyTime = vipCompany.getCertificateApplyTime();
calendar.setTime(certificateApplyTime);
getCell(sheet,i+1,4).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); if (vipCompany.getCertificateApplyTime() != null) {
Date certificateMaturityTime = vipCompany.getCertificateMaturityTime(); Date certificateApplyTime = vipCompany.getCertificateApplyTime();
calendar.setTime(certificateMaturityTime); calendar.setTime(certificateApplyTime);
getCell(sheet,i+1,5).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
Date openticketTime = vipCompany.getOpenticketTime();
calendar.setTime(openticketTime);
getCell(sheet,i+1,6).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); getCell(sheet,i+1,4).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
Date outcardTime = vipCompany.getOutcardTime(); }
calendar.setTime(outcardTime);
getCell(sheet,i+1,7).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
Date annualReviewTime = vipCompany.getAnnualReviewTime();
calendar.setTime(annualReviewTime);
getCell(sheet,i+1,8).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); if (vipCompany.getCertificateMaturityTime() != null) {
Date certificateMaturityTime = vipCompany.getCertificateMaturityTime();
calendar.setTime(certificateMaturityTime);
getCell(sheet,i+1,5).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
if (vipCompany.getOpenticketTime() != null) {
Date openticketTime = vipCompany.getOpenticketTime();
calendar.setTime(openticketTime);
getCell(sheet,i+1,6).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
if (vipCompany.getOutcardTime() != null) {
Date outcardTime = vipCompany.getOutcardTime();
calendar.setTime(outcardTime);
getCell(sheet,i+1,7).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
if (vipCompany.getAnnualReviewTime() != null) {
Date annualReviewTime = vipCompany.getAnnualReviewTime();
calendar.setTime(annualReviewTime);
getCell(sheet,i+1,8).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
getCell(sheet,i+1,9).setCellValue(vipCompany.getCost()); getCell(sheet,i+1,9).setCellValue(vipCompany.getCost());
getCell(sheet,i+1,10).setCellValue(vipCompany.getCertificateRemark()); getCell(sheet,i+1,10).setCellValue(vipCompany.getCertificateRemark());
} }

View File

@ -35,16 +35,16 @@ public class VipCompanyImportTemplateExcel extends AbstractExcelView {
HSSFSheet sheet = workbook.createSheet("sheet"); HSSFSheet sheet = workbook.createSheet("sheet");
sheet.autoSizeColumn(0); sheet.autoSizeColumn(0);
getCell(sheet,0,0).setCellValue("单位名称(必填)"); getCell(sheet,0,0).setCellValue("单位名称");
getCell(sheet,0,1).setCellValue("证书编号(必填)"); getCell(sheet,0,1).setCellValue("证书编号");
getCell(sheet,0,2).setCellValue("证书等级(必填)"); getCell(sheet,0,2).setCellValue("证书等级");
getCell(sheet,0,3).setCellValue("证书类型(必填)"); getCell(sheet,0,3).setCellValue("证书类型");
getCell(sheet,0,4).setCellValue("证书申请时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,4).setCellValue("证书申请时间格式YYYY-MM-DD");
getCell(sheet,0,5).setCellValue("证书到期时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,5).setCellValue("证书到期时间格式YYYY-MM-DD");
getCell(sheet,0,6).setCellValue("开票时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,6).setCellValue("开票时间格式YYYY-MM-DD");
getCell(sheet,0,7).setCellValue("出证时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,7).setCellValue("出证时间格式YYYY-MM-DD");
getCell(sheet,0,8).setCellValue("年审时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,8).setCellValue("年审时间格式YYYY-MM-DD");
getCell(sheet,0,9).setCellValue("费用(必填)"); getCell(sheet,0,9).setCellValue("费用");
getCell(sheet,0,10).setCellValue("备注"); getCell(sheet,0,10).setCellValue("备注");
//单位名称 //单位名称

View File

@ -35,73 +35,94 @@ public class VipMemberExportExcel extends AbstractExcelView{
style.setFont(fontStyle); style.setFont(fontStyle);
HSSFSheet sheet = workbook.createSheet("sheet"); HSSFSheet sheet = workbook.createSheet("sheet");
getCell(sheet,0,0).setCellValue("单位名称"); getCell(sheet,0,0).setCellValue("单位代号");
getCell(sheet,0,1).setCellValue("法人代表"); getCell(sheet,0,1).setCellValue("单位名称");
getCell(sheet,0,2).setCellValue("法人身份证号"); getCell(sheet,0,2).setCellValue("法人代表");
getCell(sheet,0,3).setCellValue("推荐人"); getCell(sheet,0,3).setCellValue("法人身份证号");
getCell(sheet,0,4).setCellValue("会员类型"); getCell(sheet,0,4).setCellValue("推荐人");
getCell(sheet,0,5).setCellValue("会员编号"); getCell(sheet,0,5).setCellValue("会员类型");
getCell(sheet,0,6).setCellValue("入会时间"); getCell(sheet,0,6).setCellValue("会员编号");
getCell(sheet,0,7).setCellValue("到期时间"); getCell(sheet,0,7).setCellValue("入会时间");
getCell(sheet,0,8).setCellValue("联系人"); getCell(sheet,0,8).setCellValue("到期时间");
getCell(sheet,0,9).setCellValue("联系人电话"); getCell(sheet,0,9).setCellValue("联系人");
getCell(sheet,0,10).setCellValue("联系情况"); getCell(sheet,0,10).setCellValue("联系人电话");
getCell(sheet,0,11).setCellValue("官网是否录入"); getCell(sheet,0,11).setCellValue("联系情况");
getCell(sheet,0,12).setCellValue("手机"); getCell(sheet,0,12).setCellValue("官网是否录入");
getCell(sheet,0,13).setCellValue("QQ"); getCell(sheet,0,13).setCellValue("手机");
getCell(sheet,0,14).setCellValue("微信"); getCell(sheet,0,14).setCellValue("QQ");
getCell(sheet,0,15).setCellValue("邮箱"); getCell(sheet,0,15).setCellValue("微信");
getCell(sheet,0,16).setCellValue("企业情况"); getCell(sheet,0,16).setCellValue("邮箱");
getCell(sheet,0,17).setCellValue("生日"); getCell(sheet,0,17).setCellValue("企业情况");
getCell(sheet,0,18).setCellValue("单位地址"); getCell(sheet,0,18).setCellValue("生日");
getCell(sheet,0,19).setCellValue("企业网"); getCell(sheet,0,19).setCellValue("单位地");
getCell(sheet,0,20).setCellValue("需求信息"); getCell(sheet,0,20).setCellValue("企业网址");
getCell(sheet,0,21).setCellValue("项目匹配"); getCell(sheet,0,21).setCellValue("需求信息");
getCell(sheet,0,22).setCellValue("会费"); getCell(sheet,0,22).setCellValue("项目匹配");
getCell(sheet,0,23).setCellValue("是否有环保资质"); getCell(sheet,0,23).setCellValue("会费");
getCell(sheet,0,24).setCellValue("等级"); getCell(sheet,0,24).setCellValue("是否有环保资质");
getCell(sheet,0,25).setCellValue("成立时间"); getCell(sheet,0,25).setCellValue("等级");
getCell(sheet,0,26).setCellValue("通知书"); getCell(sheet,0,26).setCellValue("通知书");
getCell(sheet,0,27).setCellValue("注册资金"); getCell(sheet,0,27).setCellValue("注册资金");
getCell(sheet,0,28).setCellValue("资质情况"); getCell(sheet,0,28).setCellValue("资质情况");
getCell(sheet,0,29).setCellValue("重要联系人");
getCell(sheet,0,30).setCellValue("重要手机");
getCell(sheet,0,31).setCellValue("经办联系人");
getCell(sheet,0,32).setCellValue("经办手机");
Calendar calendar = Calendar.getInstance(); Calendar calendar = Calendar.getInstance();
List<VipMember> vipMembers = (List<VipMember>) model.get("vipMembers"); List<VipMember> vipMembers = (List<VipMember>) model.get("vipMembers");
for (int i = 0; i < vipMembers.size(); i++) { for (int i = 0; i < vipMembers.size(); i++) {
VipMember vipMember = vipMembers.get(i); VipMember vipMember = vipMembers.get(i);
getCell(sheet,i+1,0).setCellValue(vipMember.getMemberName()); getCell(sheet,i+1,0).setCellValue(vipMember.getMemberCode());
getCell(sheet,i+1,1).setCellValue(vipMember.getMemberLegal()); getCell(sheet,i+1,1).setCellValue(vipMember.getMemberName());
getCell(sheet,i+1,2).setCellValue(vipMember.getMemberLegalCard()); getCell(sheet,i+1,2).setCellValue(vipMember.getMemberLegal());
getCell(sheet,i+1,3).setCellValue(vipMember.getMemberReferrer().getReferrerName()); getCell(sheet,i+1,3).setCellValue(vipMember.getMemberLegalCard());
getCell(sheet,i+1,4).setCellValue(vipMember.getMemberType().getTypeName()); if (vipMember.getMemberReferrer() != null) {
getCell(sheet,i+1,5).setCellValue(vipMember.getMemberCard()); getCell(sheet,i+1,4).setCellValue(vipMember.getMemberReferrer().getReferrerName());
Date memberAdmissionTime = vipMember.getMemberAdmissionTime(); }
calendar.setTime(memberAdmissionTime); if (vipMember.getMemberType() != null) {
getCell(sheet,i+1,5).setCellValue(vipMember.getMemberType().getTypeName());
}
getCell(sheet,i+1,6).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); getCell(sheet,i+1,6).setCellValue(vipMember.getMemberCard());
Date memberMaturityTime = vipMember.getMemberMaturityTime(); if (vipMember.getMemberAdmissionTime() != null) {
calendar.setTime(memberMaturityTime); Date memberAdmissionTime = vipMember.getMemberAdmissionTime();
getCell(sheet,i+1,7).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); calendar.setTime(memberAdmissionTime);
getCell(sheet,i+1,8).setCellValue(vipMember.getMemberContact());
getCell(sheet,i+1,9).setCellValue(vipMember.getMemberContactTel()); getCell(sheet,i+1,7).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
getCell(sheet,i+1,10).setCellValue(vipMember.getMemberContactSituation());
getCell(sheet,i+1,11).setCellValue(vipMember.getMemberWebsite()); }
getCell(sheet,i+1,12).setCellValue(vipMember.getMemberTel());
getCell(sheet,i+1,13).setCellValue(vipMember.getMemberQQ()); if (vipMember.getMemberMaturityTime() != null) {
getCell(sheet,i+1,14).setCellValue(vipMember.getMemberWechat()); Date memberMaturityTime = vipMember.getMemberMaturityTime();
getCell(sheet,i+1,15).setCellValue(vipMember.getMemberEmail()); calendar.setTime(memberMaturityTime);
getCell(sheet,i+1,16).setCellValue(vipMember.getMemberSituation()); getCell(sheet,i+1,8).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
getCell(sheet,i+1,17).setCellValue(vipMember.getMemberBirthday());
getCell(sheet,i+1,18).setCellValue(vipMember.getMemberAddress()); }
getCell(sheet,i+1,19).setCellValue(vipMember.getMemberUrl()); getCell(sheet,i+1,9).setCellValue(vipMember.getMemberContact());
getCell(sheet,i+1,20).setCellValue(vipMember.getMemberDemand()); getCell(sheet,i+1,10).setCellValue(vipMember.getMemberContactTel());
getCell(sheet,i+1,21).setCellValue(vipMember.getMemberItem()); getCell(sheet,i+1,11).setCellValue(vipMember.getMemberContactSituation());
getCell(sheet,i+1,22).setCellValue(vipMember.getMemberFee()); getCell(sheet,i+1,12).setCellValue(vipMember.getMemberWebsite());
getCell(sheet,i+1,23).setCellValue(vipMember.getMemberQualification().equals("0") ? "" : ""); getCell(sheet,i+1,13).setCellValue(vipMember.getMemberTel());
getCell(sheet,i+1,24).setCellValue(vipMember.getMemberLevel()); getCell(sheet,i+1,14).setCellValue(vipMember.getMemberQQ());
getCell(sheet,i+1,25).setCellValue(vipMember.getMemberEstablishedTime()); getCell(sheet,i+1,15).setCellValue(vipMember.getMemberWechat());
getCell(sheet,i+1,16).setCellValue(vipMember.getMemberEmail());
getCell(sheet,i+1,17).setCellValue(vipMember.getMemberSituation());
getCell(sheet,i+1,18).setCellValue(vipMember.getMemberBirthday());
getCell(sheet,i+1,19).setCellValue(vipMember.getMemberAddress());
getCell(sheet,i+1,20).setCellValue(vipMember.getMemberUrl());
getCell(sheet,i+1,21).setCellValue(vipMember.getMemberDemand());
getCell(sheet,i+1,22).setCellValue(vipMember.getMemberItem());
getCell(sheet,i+1,23).setCellValue(vipMember.getMemberFee());
getCell(sheet,i+1,24).setCellValue(vipMember.getMemberQualification() != null ? vipMember.getMemberQualification().equals("0") ? "" : "" : "");
getCell(sheet,i+1,25).setCellValue(vipMember.getMemberLevel());
// getCell(sheet,i+1,25).setCellValue(vipMember != null ? vipMember.getMemberEstablishedTime() : null);
getCell(sheet,i+1,26).setCellValue(vipMember.getMemberNoticeBook()); getCell(sheet,i+1,26).setCellValue(vipMember.getMemberNoticeBook());
getCell(sheet,i+1,27).setCellValue(vipMember.getMemberRegisteredCapital()); getCell(sheet,i+1,27).setCellValue(vipMember.getMemberRegisteredCapital());
getCell(sheet,i+1,28).setCellValue(vipMember.getMemberQualificationInfo()); getCell(sheet,i+1,28).setCellValue(vipMember.getMemberQualificationInfo());
getCell(sheet,i+1,29).setCellValue(vipMember.getMemberQualificationInfo());
getCell(sheet,i+1,30).setCellValue(vipMember.getMemberQualificationInfo());
getCell(sheet,i+1,31).setCellValue(vipMember.getMemberQualificationInfo());
getCell(sheet,i+1,32).setCellValue(vipMember.getMemberQualificationInfo());
} }
String filename = URLEncoder.encode("会员信息导出.xls", "UTF-8"); String filename = URLEncoder.encode("会员信息导出.xls", "UTF-8");

View File

@ -34,41 +34,46 @@ public class VipMemberImportTemplateExcel extends AbstractExcelView {
HSSFSheet sheet = workbook.createSheet("sheet"); HSSFSheet sheet = workbook.createSheet("sheet");
sheet.autoSizeColumn(0); sheet.autoSizeColumn(0);
getCell(sheet,0,0).setCellValue("单位名称(必填)"); getCell(sheet,0,0).setCellValue("单位代号");
getCell(sheet,0,1).setCellValue("法人代表(必填)"); getCell(sheet,0,1).setCellValue("单位名称");
getCell(sheet,0,2).setCellValue("法人身份证号(必填)"); getCell(sheet,0,2).setCellValue("法人代表");
getCell(sheet,0,3).setCellValue("推荐人(只能选择或者为空)"); getCell(sheet,0,3).setCellValue("法人身份证号");
getCell(sheet,0,4).setCellValue("会员类型(必填)"); getCell(sheet,0,4).setCellValue("推荐人(只能选择或者为空)");
getCell(sheet,0,5).setCellValue("会员编号(必填)"); getCell(sheet,0,5).setCellValue("会员类型");
getCell(sheet, 0, 6).setCellValue("入会时间必填格式YYYY-MM-DD"); getCell(sheet,0,6).setCellValue("会员编号");
getCell(sheet, 0, 7).setCellValue("到期时间必填格式YYYY-MM-DD"); getCell(sheet, 0, 7).setCellValue("入会时间格式YYYY-MM-DD");
getCell(sheet,0,8).setCellValue("联系人(必填)"); getCell(sheet, 0, 8).setCellValue("到期时间格式YYYY-MM-DD");
getCell(sheet,0,9).setCellValue("联系人电话(必填)"); getCell(sheet,0,9).setCellValue("联系人");
getCell(sheet,0,10).setCellValue("联系情况"); getCell(sheet,0,10).setCellValue("联系人电话");
getCell(sheet,0,11).setCellValue("官网"); getCell(sheet,0,11).setCellValue("联系情况");
getCell(sheet,0,12).setCellValue("手机(必填)发短信手机号"); getCell(sheet,0,12).setCellValue("官网");
getCell(sheet,0,13).setCellValue("QQ"); getCell(sheet,0,13).setCellValue("法人手机");
getCell(sheet,0,14).setCellValue("微信"); getCell(sheet,0,14).setCellValue("QQ");
getCell(sheet,0,15).setCellValue("邮箱"); getCell(sheet,0,15).setCellValue("微信");
getCell(sheet,0,16).setCellValue("企业情况"); getCell(sheet,0,16).setCellValue("邮箱");
getCell(sheet, 0, 17).setCellValue("生日必填格式MM-DD"); getCell(sheet,0,17).setCellValue("企业情况");
getCell(sheet, 0, 18).setCellValue("生日格式MM-DD");
getCell(sheet,0,18).setCellValue("单位地址(必填)"); getCell(sheet,0,19).setCellValue("单位地址");
getCell(sheet,0,19).setCellValue("企业网址"); getCell(sheet,0,20).setCellValue("重要联系人");
getCell(sheet,0,20).setCellValue("需求信息"); getCell(sheet,0,21).setCellValue("重要手机");
getCell(sheet,0,21).setCellValue("项目匹配"); getCell(sheet,0,22).setCellValue("经办联系人");
getCell(sheet,0,22).setCellValue("会费(必填)"); getCell(sheet,0,23).setCellValue("经办手机");
getCell(sheet,0,23).setCellValue("是否有环保资质(必填)"); getCell(sheet,0,24).setCellValue("企业网址");
getCell(sheet,0,25).setCellValue("需求信息");
getCell(sheet,0,26).setCellValue("项目匹配");
getCell(sheet,0,27).setCellValue("会费");
getCell(sheet,0,28).setCellValue("是否有环保资质");
getCell(sheet,0,24).setCellValue("等级"); getCell(sheet,0,29).setCellValue("等级");
getCell(sheet,0,25).setCellValue("成立时间必填格式YYYY-MM-DD"); getCell(sheet,0,30).setCellValue("成立时间格式YYYY-MM-DD");
getCell(sheet,0,26).setCellValue("通知书"); getCell(sheet,0,31).setCellValue("通知书");
getCell(sheet,0,27).setCellValue("注册资金"); getCell(sheet,0,32).setCellValue("注册资金");
getCell(sheet,0,28).setCellValue("资质情况"); getCell(sheet,0,33).setCellValue("资质情况");
//环保资质 //环保资质
String[] qualifications = {"",""}; String[] qualifications = {"",""};
CellRangeAddressList regions = new CellRangeAddressList(0, 65535, 23, 23); CellRangeAddressList regions = new CellRangeAddressList(0, 65535, 28, 28);
DVConstraint constraint = DVConstraint.createExplicitListConstraint(qualifications); DVConstraint constraint = DVConstraint.createExplicitListConstraint(qualifications);
HSSFDataValidation dataValidation = new HSSFDataValidation(regions, constraint); HSSFDataValidation dataValidation = new HSSFDataValidation(regions, constraint);
sheet.addValidationData(dataValidation); sheet.addValidationData(dataValidation);
@ -80,7 +85,7 @@ public class VipMemberImportTemplateExcel extends AbstractExcelView {
vipTypesStr[i] = vipTypes.get(i).getTypeName(); vipTypesStr[i] = vipTypes.get(i).getTypeName();
} }
CellRangeAddressList regions1 = new CellRangeAddressList(0, 65535, 4, 4); CellRangeAddressList regions1 = new CellRangeAddressList(0, 65535, 5, 5);
DVConstraint constraint1 = DVConstraint.createExplicitListConstraint(vipTypesStr); DVConstraint constraint1 = DVConstraint.createExplicitListConstraint(vipTypesStr);
HSSFDataValidation dataValidation1 = new HSSFDataValidation(regions1, constraint1); HSSFDataValidation dataValidation1 = new HSSFDataValidation(regions1, constraint1);
sheet.addValidationData(dataValidation1); sheet.addValidationData(dataValidation1);
@ -92,7 +97,7 @@ public class VipMemberImportTemplateExcel extends AbstractExcelView {
referrersStr[i] = referrers.get(i).getReferrerName(); referrersStr[i] = referrers.get(i).getReferrerName();
} }
CellRangeAddressList regions2 = new CellRangeAddressList(0, 65535, 3, 3); CellRangeAddressList regions2 = new CellRangeAddressList(0, 65535, 4, 4);
DVConstraint constraint2 = DVConstraint.createExplicitListConstraint(referrersStr); DVConstraint constraint2 = DVConstraint.createExplicitListConstraint(referrersStr);
HSSFDataValidation dataValidation2 = new HSSFDataValidation(regions2, constraint2); HSSFDataValidation dataValidation2 = new HSSFDataValidation(regions2, constraint2);
sheet.addValidationData(dataValidation2); sheet.addValidationData(dataValidation2);
@ -129,6 +134,11 @@ public class VipMemberImportTemplateExcel extends AbstractExcelView {
sheet.setDefaultColumnStyle(26,cellStyle); sheet.setDefaultColumnStyle(26,cellStyle);
sheet.setDefaultColumnStyle(27,cellStyle); sheet.setDefaultColumnStyle(27,cellStyle);
sheet.setDefaultColumnStyle(28,cellStyle); sheet.setDefaultColumnStyle(28,cellStyle);
sheet.setDefaultColumnStyle(29,cellStyle);
sheet.setDefaultColumnStyle(30,cellStyle);
sheet.setDefaultColumnStyle(31,cellStyle);
sheet.setDefaultColumnStyle(32,cellStyle);
sheet.setDefaultColumnStyle(33,cellStyle);
String filename = URLEncoder.encode("会员信息导入模板.xls", "UTF-8"); String filename = URLEncoder.encode("会员信息导入模板.xls", "UTF-8");
response.setContentType("application/vnd.ms-excel"); response.setContentType("application/vnd.ms-excel");

View File

@ -71,17 +71,27 @@ public class VipPersonalExportExcel extends AbstractExcelView{
getCell(sheet,i+1,10).setCellValue(vipPersonal.getCertificateLevel()); getCell(sheet,i+1,10).setCellValue(vipPersonal.getCertificateLevel());
getCell(sheet,i+1,11).setCellValue(vipPersonal.getCertificateType()); getCell(sheet,i+1,11).setCellValue(vipPersonal.getCertificateType());
getCell(sheet,i+1,12).setCellValue(vipPersonal.getCertificateCard()); getCell(sheet,i+1,12).setCellValue(vipPersonal.getCertificateCard());
Date certificateApplyTime = vipPersonal.getCertificateApplyTime();
calendar.setTime(certificateApplyTime);
getCell(sheet,i+1,13).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
Date certificateReceiveTime = vipPersonal.getCertificateReceiveTime(); if (vipPersonal.getCertificateApplyTime() != null) {
calendar.setTime(certificateReceiveTime); Date certificateApplyTime = vipPersonal.getCertificateApplyTime();
getCell(sheet,i+1,14).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); calendar.setTime(certificateApplyTime);
getCell(sheet,i+1,13).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
Date certificateMaturityTime = vipPersonal.getCertificateMaturityTime(); }
calendar.setTime(certificateMaturityTime);
getCell(sheet,i+1,15).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH)); if (vipPersonal.getCertificateReceiveTime() != null) {
Date certificateReceiveTime = vipPersonal.getCertificateReceiveTime();
calendar.setTime(certificateReceiveTime);
getCell(sheet,i+1,14).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
if (vipPersonal.getCertificateMaturityTime() != null) {
Date certificateMaturityTime = vipPersonal.getCertificateMaturityTime();
calendar.setTime(certificateMaturityTime);
getCell(sheet,i+1,15).setCellValue(calendar.get(Calendar.YEAR) + "-" + (calendar.get(Calendar.MONTH) + 1) + "-" + calendar.get(Calendar.DAY_OF_MONTH));
}
getCell(sheet,i+1,16).setCellValue(vipPersonal.getUploadWebsite()); getCell(sheet,i+1,16).setCellValue(vipPersonal.getUploadWebsite());
getCell(sheet,i+1,17).setCellValue(vipPersonal.getCertificateRemark()); getCell(sheet,i+1,17).setCellValue(vipPersonal.getCertificateRemark());

View File

@ -33,23 +33,23 @@ public class VipPersonalImportTemplateExcel extends AbstractExcelView {
HSSFSheet sheet = workbook.createSheet("sheet"); HSSFSheet sheet = workbook.createSheet("sheet");
sheet.autoSizeColumn(0); sheet.autoSizeColumn(0);
getCell(sheet,0,0).setCellValue("姓名(必填)"); getCell(sheet,0,0).setCellValue("姓名");
getCell(sheet,0,1).setCellValue("身份证号(必填)"); getCell(sheet,0,1).setCellValue("身份证号");
getCell(sheet,0,2).setCellValue("性别(必填)"); getCell(sheet,0,2).setCellValue("性别");
getCell(sheet,0,3).setCellValue("手机号码(必填)"); getCell(sheet,0,3).setCellValue("手机号码");
getCell(sheet,0,4).setCellValue("微信(必填)"); getCell(sheet,0,4).setCellValue("微信");
getCell(sheet,0,5).setCellValue("邮箱(必填)"); getCell(sheet,0,5).setCellValue("邮箱");
getCell(sheet,0,6).setCellValue("研究方向(必填)"); getCell(sheet,0,6).setCellValue("研究方向");
getCell(sheet,0,7).setCellValue("专业(必填)"); getCell(sheet,0,7).setCellValue("专业");
getCell(sheet,0,8).setCellValue("毕业学校(必填)"); getCell(sheet,0,8).setCellValue("毕业学校");
getCell(sheet,0,9).setCellValue("单位名称(必填)"); getCell(sheet,0,9).setCellValue("单位名称");
getCell(sheet,0,10).setCellValue("证书等级(必填)"); getCell(sheet,0,10).setCellValue("证书等级");
getCell(sheet,0,11).setCellValue("证书类型(必填)"); getCell(sheet,0,11).setCellValue("证书类型");
getCell(sheet,0,12).setCellValue("证书编号(必填)"); getCell(sheet,0,12).setCellValue("证书编号");
getCell(sheet,0,13).setCellValue("证书申请时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,13).setCellValue("证书申请时间格式YYYY-MM-DD");
getCell(sheet,0,14).setCellValue("证书领取时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,14).setCellValue("证书领取时间格式YYYY-MM-DD");
getCell(sheet,0,15).setCellValue("证书到期时间(必填)格式YYYY-MM-DD"); getCell(sheet,0,15).setCellValue("证书到期时间格式YYYY-MM-DD");
getCell(sheet,0,16).setCellValue("证书上传官网(必填)"); getCell(sheet,0,16).setCellValue("证书上传官网");
getCell(sheet,0,17).setCellValue("备注"); getCell(sheet,0,17).setCellValue("备注");
//性别 //性别

View File

@ -35,6 +35,8 @@ public interface VipService {
boolean saveOrUpdateVipReferrer(VipReferrer vipReferrer,String userName); boolean saveOrUpdateVipReferrer(VipReferrer vipReferrer,String userName);
List<VipReferrer> getVipReferrerTelByAll();
VipReferrer getVipReferrer(Integer referrerId); VipReferrer getVipReferrer(Integer referrerId);
boolean deleteVipReferrer(VipReferrer vipReferrer,String userName); boolean deleteVipReferrer(VipReferrer vipReferrer,String userName);
@ -67,6 +69,8 @@ public interface VipService {
Pagination<VipMember> getVipMemberByPage(SearchFilter searchFilter); Pagination<VipMember> getVipMemberByPage(SearchFilter searchFilter);
List<VipMember> getVipMemberTelByAll();
boolean saveOrUpdateVipMember(VipMember vipMember,VipReferrer vipReferrer,String userName,String companyIds); boolean saveOrUpdateVipMember(VipMember vipMember,VipReferrer vipReferrer,String userName,String companyIds);
VipMember getVipMember(Integer memberId); VipMember getVipMember(Integer memberId);

View File

@ -22,8 +22,10 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import java.io.InputStream; import java.io.InputStream;
import java.text.ParseException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
@ -253,6 +255,45 @@ public class VipServiceImpl implements VipService{
return true; return true;
} }
@Override
public List<VipMember> getVipMemberTelByAll() {
SimpleDateFormat sdf = new SimpleDateFormat("MM-dd");
List<VipMember> members = new ArrayList<VipMember>();
Date nowDate = new Date();
List<VipMember> list = this.vipMemberDao.findByProperty(Restrictions.eq("certificateStatus","0"));
try {
for (VipMember vipMember : list) {
String memberBirthday = vipMember.getMemberBirthday();
Date parse = sdf.parse(memberBirthday);
if (parse.getMonth() == nowDate.getMonth() && parse.getDate() == nowDate.getDate()) {
members.add(vipMember);
}
}
} catch (ParseException e) {
e.printStackTrace();
}
return members;
}
@Override
public List<VipReferrer> getVipReferrerTelByAll() {
SimpleDateFormat sdf = new SimpleDateFormat("MM-dd");
List<VipReferrer> referrers = new ArrayList<VipReferrer>();
Date nowDate = new Date();
List<VipReferrer> list = this.vipReferrerDao.findByProperty(Restrictions.eq("referrerStatus","0"));
try {
for (VipReferrer vipReferrer : list) {
String referrerBirthday = vipReferrer.getReferrerBirthday();
Date parse = sdf.parse(referrerBirthday);
if (parse.getMonth() == nowDate.getMonth() && parse.getDate() == nowDate.getDate()) {
referrers.add(vipReferrer);
}
}
} catch (ParseException e) {
e.printStackTrace();
}
return referrers;
}
@Override @Override
public Pagination<VipCompany> getVipCompanyByPage(SearchFilter searchFilter) { public Pagination<VipCompany> getVipCompanyByPage(SearchFilter searchFilter) {
@ -450,6 +491,7 @@ public class VipServiceImpl implements VipService{
VipMember vipMemberUpdate = this.vipMemberDao.get(vipMemberId); VipMember vipMemberUpdate = this.vipMemberDao.get(vipMemberId);
vipMemberUpdate.setMemberReferrer(vipReferrer); vipMemberUpdate.setMemberReferrer(vipReferrer);
vipMemberUpdate.setMemberType(vipType); vipMemberUpdate.setMemberType(vipType);
vipMemberUpdate.setMemberCode(vipMember.getMemberCode());
vipMemberUpdate.setMemberName(vipMember.getMemberName()); vipMemberUpdate.setMemberName(vipMember.getMemberName());
vipMemberUpdate.setMemberLegal(vipMember.getMemberLegal()); vipMemberUpdate.setMemberLegal(vipMember.getMemberLegal());
vipMemberUpdate.setMemberLegalCard(vipMember.getMemberLegalCard()); vipMemberUpdate.setMemberLegalCard(vipMember.getMemberLegalCard());
@ -467,6 +509,10 @@ public class VipServiceImpl implements VipService{
vipMemberUpdate.setMemberSituation(vipMember.getMemberSituation()); vipMemberUpdate.setMemberSituation(vipMember.getMemberSituation());
vipMemberUpdate.setMemberBirthday(vipMember.getMemberBirthday()); vipMemberUpdate.setMemberBirthday(vipMember.getMemberBirthday());
vipMemberUpdate.setMemberAddress(vipMember.getMemberAddress()); vipMemberUpdate.setMemberAddress(vipMember.getMemberAddress());
vipMemberUpdate.setMemberImportantContact(vipMember.getMemberImportantContact());
vipMemberUpdate.setMemberImportantTel(vipMember.getMemberImportantTel());
vipMemberUpdate.setMemberHandlingContact(vipMember.getMemberHandlingContact());
vipMemberUpdate.setMemberHandlingTel(vipMember.getMemberHandlingTel());
vipMemberUpdate.setMemberUrl(vipMember.getMemberUrl()); vipMemberUpdate.setMemberUrl(vipMember.getMemberUrl());
vipMemberUpdate.setMemberDemand(vipMember.getMemberDemand()); vipMemberUpdate.setMemberDemand(vipMember.getMemberDemand());
vipMemberUpdate.setMemberItem(vipMember.getMemberItem()); vipMemberUpdate.setMemberItem(vipMember.getMemberItem());
@ -529,80 +575,64 @@ public class VipServiceImpl implements VipService{
int rows = sheet.getLastRowNum(); int rows = sheet.getLastRowNum();
for (int i = 1; i <= rows; i++) { for (int i = 1; i <= rows; i++) {
HSSFRow row = sheet.getRow(i); HSSFRow row = sheet.getRow(i);
row.getCell(0).setCellType(Cell.CELL_TYPE_STRING); IfishUtil.setRowsType(row);
row.getCell(1).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(2).setCellType(Cell.CELL_TYPE_STRING); String memberName = row.getCell(1).getStringCellValue();
row.getCell(3).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(4).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(5).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(6).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(7).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(8).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(9).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(10).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(11).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(12).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(13).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(14).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(15).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(16).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(17).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(18).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(19).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(20).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(21).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(22).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(23).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(24).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(25).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(26).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(27).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(28).setCellType(Cell.CELL_TYPE_STRING);
String memberName = row.getCell(0).getStringCellValue();
if (StringUtils.isBlank(memberName)) { if (StringUtils.isBlank(memberName)) {
break; break;
} }
String memberLegal = row.getCell(1).getStringCellValue(); String memberCode = row.getCell(0) != null ? row.getCell(0).getStringCellValue() : null;
String memberLegalCard = row.getCell(2).getStringCellValue(); String memberLegal = row.getCell(2) != null ? row.getCell(2).getStringCellValue() : null;
String memberReferrer = row.getCell(3).getStringCellValue(); String memberLegalCard = row.getCell(3) != null ? row.getCell(3).getStringCellValue() : null;
String memberType = row.getCell(4).getStringCellValue(); String memberReferrer = row.getCell(4) != null ? row.getCell(4).getStringCellValue() : null;
String memberCard = row.getCell(5).getStringCellValue(); String memberType = row.getCell(5) != null ? row.getCell(5).getStringCellValue() : null;
String memberAdmissionTime = row.getCell(6).getStringCellValue(); String memberCard = row.getCell(6) != null ? row.getCell(6).getStringCellValue() : null;
String memberMaturityTime = row.getCell(7).getStringCellValue(); String memberAdmissionTime = row.getCell(7) != null ? row.getCell(7).getStringCellValue() : null;
String memberContact = row.getCell(8).getStringCellValue(); String memberMaturityTime = row.getCell(8) != null ? row.getCell(8).getStringCellValue() : null;
String memberContactTel = row.getCell(9).getStringCellValue(); String memberContact = row.getCell(9) != null ? row.getCell(9).getStringCellValue() : null;
String memberContactSituation = row.getCell(10).getStringCellValue(); String memberContactTel = row.getCell(10) != null ? row.getCell(10).getStringCellValue() : null;
String memberWebsite = row.getCell(11).getStringCellValue(); String memberContactSituation = row.getCell(11) != null ? row.getCell(11).getStringCellValue() : null;
String memberTel = row.getCell(12).getStringCellValue(); String memberWebsite = row.getCell(12) != null ? row.getCell(12).getStringCellValue() : null;
String memberQQ = row.getCell(13).getStringCellValue(); String memberTel = row.getCell(13) != null ? row.getCell(13).getStringCellValue() : null;
String memberWechat = row.getCell(14).getStringCellValue(); String memberQQ = row.getCell(14) != null ? row.getCell(14).getStringCellValue() : null;
String memberEmail = row.getCell(15).getStringCellValue(); String memberWechat = row.getCell(15) != null ? row.getCell(15).getStringCellValue() : null;
String memberSituation = row.getCell(16).getStringCellValue(); String memberEmail = row.getCell(16) != null ? row.getCell(16).getStringCellValue() : null;
String memberBirthday = row.getCell(17).getStringCellValue(); String memberSituation = row.getCell(17) != null ? row.getCell(17).getStringCellValue() : null;
String memberAddress = row.getCell(18).getStringCellValue(); String memberBirthday = row.getCell(18) != null ? row.getCell(18).getStringCellValue() : null;
String memberUrl = row.getCell(19).getStringCellValue(); String memberAddress = row.getCell(18) != null ? row.getCell(19).getStringCellValue() : null;
String memberDemand = row.getCell(20).getStringCellValue(); String memberImportantContact = row.getCell(20) != null ? row.getCell(20).getStringCellValue() : null;
String memberItem = row.getCell(21).getStringCellValue(); String memberImportantTel = row.getCell(21) != null ? row.getCell(21).getStringCellValue() : null;
String memberFee = row.getCell(22).getStringCellValue(); String memberHandlingContact = row.getCell(22) != null ? row.getCell(22).getStringCellValue() : null;
String memberQualification = row.getCell(23).getStringCellValue().equals("") ? "0" : "1"; String memberHandlingTel = row.getCell(23) != null ? row.getCell(23).getStringCellValue() : null;
String memberLevel = row.getCell(24).getStringCellValue(); String memberUrl = row.getCell(24) != null ? row.getCell(24).getStringCellValue() : null;
String memberEstablishedTime = row.getCell(25).getStringCellValue(); String memberDemand = row.getCell(25) != null ? row.getCell(25).getStringCellValue() : null;
String memberNoticeBook = row.getCell(26).getStringCellValue(); String memberItem = row.getCell(26) != null ? row.getCell(26).getStringCellValue() : null;
String memberRegisteredCapital = row.getCell(27).getStringCellValue(); String memberFee = row.getCell(27) != null ? row.getCell(27).getStringCellValue() : null;
String memberQualificationInfo = row.getCell(28).getStringCellValue(); String memberQualification = row.getCell(28) != null ? row.getCell(28).getStringCellValue().equals("") ? "0" : "1" : null;
String memberLevel = row.getCell(29) != null ? row.getCell(29).getStringCellValue() : null;
String memberEstablishedTime = row.getCell(30) != null ? row.getCell(30).getStringCellValue() : null;
String memberNoticeBook = row.getCell(31) != null ? row.getCell(31).getStringCellValue() : null;
String memberRegisteredCapital = row.getCell(32) != null ? row.getCell(32).getStringCellValue() : null;
String memberQualificationInfo = row.getCell(33) != null ? row.getCell(33).getStringCellValue() : null;
List<VipReferrer> referrers = this.vipReferrerDao.findByProperty(Restrictions.eq("referrerName", memberReferrer)); if (memberReferrer != null && StringUtils.isNotBlank(memberReferrer)) {
if (referrers.size() > 0) { List<VipReferrer> referrers = this.vipReferrerDao.findByProperty(Restrictions.eq("referrerName", memberReferrer));
referrer = referrers.get(0); if (referrers.size() > 0) {
referrer = referrers.get(0);
}
} }
List<VipType> types = this.vipTypeDao.findByProperty(Restrictions.eq("typeName", memberType));
if (types.size() > 0) { if (memberType != null && StringUtils.isNotBlank(memberType)) {
type = types.get(0); List<VipType> types = this.vipTypeDao.findByProperty(Restrictions.eq("typeName", memberType));
if (types.size() > 0) {
type = types.get(0);
}
} }
member = new VipMember(); member = new VipMember();
member.setMemberReferrer(referrer); member.setMemberReferrer(referrer);
member.setMemberType(type); member.setMemberType(type);
member.setMemberCode(memberCode);
member.setMemberName(memberName); member.setMemberName(memberName);
member.setMemberLegal(memberLegal); member.setMemberLegal(memberLegal);
member.setMemberLegalCard(memberLegalCard); member.setMemberLegalCard(memberLegalCard);
@ -620,13 +650,19 @@ public class VipServiceImpl implements VipService{
member.setMemberSituation(memberSituation); member.setMemberSituation(memberSituation);
member.setMemberBirthday(memberBirthday); member.setMemberBirthday(memberBirthday);
member.setMemberAddress(memberAddress); member.setMemberAddress(memberAddress);
member.setMemberImportantContact(memberImportantContact);
member.setMemberImportantTel(memberImportantTel);
member.setMemberHandlingContact(memberHandlingContact);
member.setMemberHandlingTel(memberHandlingTel);
member.setMemberUrl(memberUrl); member.setMemberUrl(memberUrl);
member.setMemberDemand(memberDemand); member.setMemberDemand(memberDemand);
member.setMemberItem(memberItem); member.setMemberItem(memberItem);
member.setMemberFee(Double.parseDouble(memberFee)); member.setMemberFee(memberFee);
member.setMemberQualification(memberQualification); member.setMemberQualification(memberQualification);
member.setMemberLevel(memberLevel); member.setMemberLevel(memberLevel);
member.setMemberEstablishedTime(yyMMdd.parse(memberEstablishedTime)); if (memberEstablishedTime != null) {
member.setMemberEstablishedTime(yyMMdd.parse(memberEstablishedTime));
}
member.setMemberNoticeBook(memberNoticeBook); member.setMemberNoticeBook(memberNoticeBook);
member.setMemberRegisteredCapital(memberRegisteredCapital); member.setMemberRegisteredCapital(memberRegisteredCapital);
member.setMemberQualificationInfo(memberQualificationInfo); member.setMemberQualificationInfo(memberQualificationInfo);
@ -661,31 +697,22 @@ public class VipServiceImpl implements VipService{
int rows = sheet.getLastRowNum(); int rows = sheet.getLastRowNum();
for (int i = 1; i <= rows; i++) { for (int i = 1; i <= rows; i++) {
HSSFRow row = sheet.getRow(i); HSSFRow row = sheet.getRow(i);
row.getCell(0).setCellType(Cell.CELL_TYPE_STRING); IfishUtil.setRowsType(row);
row.getCell(1).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(2).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(3).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(4).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(5).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(6).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(7).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(8).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(9).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(10).setCellType(Cell.CELL_TYPE_STRING);
String memberName = row.getCell(0).getStringCellValue(); String memberName = row.getCell(0).getStringCellValue();
if (StringUtils.isBlank(memberName)) { if (StringUtils.isBlank(memberName)) {
break; break;
} }
String certificateCard = row.getCell(1).getStringCellValue(); String certificateCard = row.getCell(1) != null ? row.getCell(1).getStringCellValue() : null;
String certificateLevel = row.getCell(2).getStringCellValue(); String certificateLevel = row.getCell(2) != null ? row.getCell(2).getStringCellValue() : null;
String certificateType = row.getCell(3).getStringCellValue(); String certificateType = row.getCell(3) != null ? row.getCell(3).getStringCellValue() : null;
String certificateApplyTime = row.getCell(4).getStringCellValue(); String certificateApplyTime = row.getCell(4) != null ? row.getCell(4).getStringCellValue() : null;
String certificateMaturityTime = row.getCell(5).getStringCellValue(); String certificateMaturityTime = row.getCell(5) != null ? row.getCell(5).getStringCellValue() : null;
String openticketTime = row.getCell(6).getStringCellValue(); String openticketTime = row.getCell(6) != null ? row.getCell(6).getStringCellValue() : null;
String outcardTime = row.getCell(7).getStringCellValue(); String outcardTime = row.getCell(7) != null ? row.getCell(7).getStringCellValue() : null;
String annualReviewTime = row.getCell(8).getStringCellValue(); String annualReviewTime = row.getCell(8) != null ? row.getCell(8).getStringCellValue() : null;
String cost = row.getCell(9).getStringCellValue(); String cost = row.getCell(9) != null ? row.getCell(9).getStringCellValue() : null;
String certificateRemark = row.getCell(10).getStringCellValue(); String certificateRemark = row.getCell(10) != null ? row.getCell(10).getStringCellValue() : null;
List<VipMember> vipMembers = this.vipMemberDao.findByProperty(Restrictions.eq("memberName", memberName)); List<VipMember> vipMembers = this.vipMemberDao.findByProperty(Restrictions.eq("memberName", memberName));
if (vipMembers.size() > 0) { if (vipMembers.size() > 0) {
@ -697,11 +724,22 @@ public class VipServiceImpl implements VipService{
vipCompany.setCertificateCard(certificateCard); vipCompany.setCertificateCard(certificateCard);
vipCompany.setCertificateLevel(certificateLevel); vipCompany.setCertificateLevel(certificateLevel);
vipCompany.setCertificateType(certificateType); vipCompany.setCertificateType(certificateType);
vipCompany.setCertificateApplyTime(yyMMdd.parse(certificateApplyTime)); if (certificateApplyTime != null && StringUtils.isNotBlank(certificateApplyTime)){
vipCompany.setCertificateMaturityTime(yyMMdd.parse(certificateMaturityTime)); vipCompany.setCertificateApplyTime(yyMMdd.parse(certificateApplyTime));
vipCompany.setOpenticketTime(yyMMdd.parse(openticketTime)); }
vipCompany.setOutcardTime(yyMMdd.parse(outcardTime)); if (certificateMaturityTime != null && StringUtils.isNotBlank(certificateMaturityTime)){
vipCompany.setAnnualReviewTime(yyMMdd.parse(annualReviewTime)); vipCompany.setCertificateMaturityTime(yyMMdd.parse(certificateMaturityTime));
}
if (openticketTime != null && StringUtils.isNotBlank(openticketTime)){
vipCompany.setOpenticketTime(yyMMdd.parse(openticketTime));
}
if (outcardTime != null && StringUtils.isNotBlank(outcardTime)){
vipCompany.setOutcardTime(yyMMdd.parse(outcardTime));
}
if (annualReviewTime != null && StringUtils.isNotBlank(annualReviewTime)){
vipCompany.setAnnualReviewTime(yyMMdd.parse(annualReviewTime));
}
vipCompany.setCost(Double.parseDouble(cost)); vipCompany.setCost(Double.parseDouble(cost));
vipCompany.setCertificateRemark(certificateRemark); vipCompany.setCertificateRemark(certificateRemark);
vipCompany.setCreateUser(userName); vipCompany.setCreateUser(userName);
@ -729,45 +767,29 @@ public class VipServiceImpl implements VipService{
int rows = sheet.getLastRowNum(); int rows = sheet.getLastRowNum();
for (int i = 1; i <= rows; i++) { for (int i = 1; i <= rows; i++) {
HSSFRow row = sheet.getRow(i); HSSFRow row = sheet.getRow(i);
row.getCell(0).setCellType(Cell.CELL_TYPE_STRING); IfishUtil.setRowsType(row);
row.getCell(1).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(2).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(3).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(4).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(5).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(6).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(7).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(8).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(9).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(10).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(11).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(12).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(13).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(14).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(15).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(16).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(17).setCellType(Cell.CELL_TYPE_STRING);
String personalName = row.getCell(0).getStringCellValue(); String personalName = row.getCell(0).getStringCellValue();
if (StringUtils.isBlank(personalName)) { if (StringUtils.isBlank(personalName)) {
break; break;
} }
String cardNum = row.getCell(1).getStringCellValue(); String cardNum = row.getCell(1) != null ? row.getCell(1).getStringCellValue() : null;
String personalGender = row.getCell(2).getStringCellValue(); String personalGender = row.getCell(2) != null ? row.getCell(2).getStringCellValue() : null;
String personalTel = row.getCell(3).getStringCellValue(); String personalTel = row.getCell(3) != null ? row.getCell(3).getStringCellValue() : null;
String personalWechat = row.getCell(4).getStringCellValue(); String personalWechat = row.getCell(4) != null ? row.getCell(4).getStringCellValue() : null;
String personalEmail = row.getCell(5).getStringCellValue(); String personalEmail = row.getCell(5) != null ? row.getCell(5).getStringCellValue() : null;
String personalResearchDirection = row.getCell(6).getStringCellValue(); String personalResearchDirection = row.getCell(6) != null ? row.getCell(6).getStringCellValue() : null;
String personalProfession = row.getCell(7).getStringCellValue(); String personalProfession = row.getCell(7) != null ? row.getCell(7).getStringCellValue() : null;
String personalSchool = row.getCell(8).getStringCellValue(); String personalSchool = row.getCell(8) != null ? row.getCell(8).getStringCellValue() : null;
String personalMember = row.getCell(9).getStringCellValue(); String personalMember = row.getCell(9) != null ? row.getCell(9).getStringCellValue() : null;
String certificateLevel = row.getCell(10).getStringCellValue(); String certificateLevel = row.getCell(10) != null ? row.getCell(10).getStringCellValue() : null;
String certificateType = row.getCell(11).getStringCellValue(); String certificateType = row.getCell(11) != null ? row.getCell(11).getStringCellValue() : null;
String certificateCard = row.getCell(12).getStringCellValue(); String certificateCard = row.getCell(12) != null ? row.getCell(12).getStringCellValue() : null;
String certificateApplyTime = row.getCell(13).getStringCellValue(); String certificateApplyTime = row.getCell(13) != null ? row.getCell(13).getStringCellValue() : null;
String certificateMaturityTime = row.getCell(14).getStringCellValue(); String certificateMaturityTime = row.getCell(14) != null ? row.getCell(14).getStringCellValue() : null;
String certificateReceiveTime = row.getCell(15).getStringCellValue(); String certificateReceiveTime = row.getCell(15) != null ? row.getCell(15).getStringCellValue() : null;
String uploadWebsite = row.getCell(16).getStringCellValue(); String uploadWebsite = row.getCell(16) != null ? row.getCell(16).getStringCellValue() : null;
String certificateRemark = row.getCell(17).getStringCellValue(); String certificateRemark = row.getCell(17) != null ? row.getCell(17).getStringCellValue() : null;
vipPersonal = new VipPersonal(); vipPersonal = new VipPersonal();
vipPersonal.setPersonalName(personalName); vipPersonal.setPersonalName(personalName);
@ -783,9 +805,16 @@ public class VipServiceImpl implements VipService{
vipPersonal.setCertificateLevel(certificateLevel); vipPersonal.setCertificateLevel(certificateLevel);
vipPersonal.setCertificateType(certificateType); vipPersonal.setCertificateType(certificateType);
vipPersonal.setCertificateCard(certificateCard); vipPersonal.setCertificateCard(certificateCard);
vipPersonal.setCertificateApplyTime(yyMMdd.parse(certificateApplyTime)); if (certificateApplyTime != null && StringUtils.isNotBlank(certificateApplyTime)) {
vipPersonal.setCertificateMaturityTime(yyMMdd.parse(certificateMaturityTime)); vipPersonal.setCertificateApplyTime(yyMMdd.parse(certificateApplyTime));
vipPersonal.setCertificateReceiveTime(yyMMdd.parse(certificateReceiveTime)); }
if (certificateMaturityTime != null && StringUtils.isNotBlank(certificateMaturityTime)) {
vipPersonal.setCertificateMaturityTime(yyMMdd.parse(certificateMaturityTime));
}
if (certificateReceiveTime != null && StringUtils.isNotBlank(certificateReceiveTime)) {
vipPersonal.setCertificateReceiveTime(yyMMdd.parse(certificateReceiveTime));
}
vipPersonal.setUploadWebsite(uploadWebsite); vipPersonal.setUploadWebsite(uploadWebsite);
vipPersonal.setCertificateRemark(certificateRemark); vipPersonal.setCertificateRemark(certificateRemark);
vipPersonal.setCreateUser(userName); vipPersonal.setCreateUser(userName);
@ -833,23 +862,19 @@ public class VipServiceImpl implements VipService{
for (int i = 1; i <= rows; i++) { for (int i = 1; i <= rows; i++) {
VipSmsResult vipSmsResult = new VipSmsResult(); VipSmsResult vipSmsResult = new VipSmsResult();
HSSFRow row = sheet.getRow(i); HSSFRow row = sheet.getRow(i);
row.getCell(0).setCellType(Cell.CELL_TYPE_STRING); IfishUtil.setRowsType(row);
row.getCell(1).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(2).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(3).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(4).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(5).setCellType(Cell.CELL_TYPE_STRING);
row.getCell(6).setCellType(Cell.CELL_TYPE_STRING);
String activityMemberName = row.getCell(0).getStringCellValue(); String activityMemberName = row.getCell(0).getStringCellValue();
if (StringUtils.isBlank(activityMemberName)) { if (StringUtils.isBlank(activityMemberName)) {
break; break;
} }
String activityContact = row.getCell(1).getStringCellValue();
String activityContactTel = row.getCell(2).getStringCellValue(); String activityContact = row.getCell(1) != null ? row.getCell(1).getStringCellValue() : null;
String activityPhone = row.getCell(3).getStringCellValue(); String activityContactTel = row.getCell(2) != null ? row.getCell(2).getStringCellValue() : null;
String activityEmail = row.getCell(4).getStringCellValue(); String activityPhone = row.getCell(3) != null ? row.getCell(3).getStringCellValue() : null;
String activityPosition = row.getCell(5).getStringCellValue(); String activityEmail = row.getCell(4) != null ? row.getCell(4).getStringCellValue() : null;
String activityWechat = row.getCell(6).getStringCellValue(); String activityPosition = row.getCell(5) != null ? row.getCell(5).getStringCellValue() : null;
String activityWechat = row.getCell(6) != null ? row.getCell(6).getStringCellValue() : null;
vipActivityNotice = new VipActivityNotice(); vipActivityNotice = new VipActivityNotice();
vipActivityNotice.setActivityMemberName(activityMemberName); vipActivityNotice.setActivityMemberName(activityMemberName);
@ -863,18 +888,20 @@ public class VipServiceImpl implements VipService{
vipActivityNotice.setCreateUser(userName); vipActivityNotice.setCreateUser(userName);
vipActivityNotice.setCreateTime(new Date()); vipActivityNotice.setCreateTime(new Date());
VipActivityNotice activityNotice = this.vipActivityNoticeDao.save(vipActivityNotice); VipActivityNotice activityNotice = this.vipActivityNoticeDao.save(vipActivityNotice);
if (activityNotice.getActivityId() != null && StringUtils.isNotBlank(String.valueOf(activityNotice.getActivityId()))) {
vipSmsResult.setResultBussId(activityNotice.getActivityId());
vipSmsResult.setResultTel(activityContactTel);
vipSmsResult.setResultTemplate(smsType);
response = SmsUtil.sendSms(activityContactTel, smsType, param.toJSONString());
System.out.println("短信发送-Result" + response.getCode() + "-" + response.getMessage());
vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage());
vipSmsResult.setResultRequestId(response.getRequestId());
vipSmsResult.setResultBizId(response.getBizId());
vipSmsResult.setResultCreateTime(new Date());
this.vipSmsResultDao.save(vipSmsResult);
}
vipSmsResult.setResultBussId(activityNotice.getActivityId());
vipSmsResult.setResultTel(activityContactTel);
vipSmsResult.setResultTemplate(smsType);
response = SmsUtil.sendSms(activityContactTel, smsType, param.toJSONString());
System.out.println("短信发送-Result" + response.getCode() + "-" + response.getMessage());
vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage());
vipSmsResult.setResultRequestId(response.getRequestId());
vipSmsResult.setResultBizId(response.getBizId());
vipSmsResult.setResultCreateTime(new Date());
this.vipSmsResultDao.save(vipSmsResult);

View File

@ -0,0 +1,80 @@
package com.ifish.task;
import com.alibaba.fastjson.JSONObject;
import com.aliyuncs.dysmsapi.model.v20170525.SendSmsResponse;
import com.aliyuncs.exceptions.ClientException;
import com.ifish.entity.VipCompany;
import com.ifish.entity.VipMember;
import com.ifish.entity.VipReferrer;
import com.ifish.entity.VipSmsResult;
import com.ifish.service.VipService;
import com.ifish.util.SmsUtil;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import java.util.Date;
/**
* @author: yan.y
* @Description:
* @Date: Created in 21:17 2018/7/23
* @Modified by:
*/
@Component
@EnableScheduling
@Lazy(false)
public class SmsBirthdayVipMember {
@Autowired
private VipService vipService;
@Scheduled(cron= "0 0 10 * * ?")
public void vipMemberBirthday() throws ClientException {
final String templateCode = "SMS_139227977";
final String tel = "0731-84476408";
JSONObject param = null;
for (VipMember vipMember : this.vipService.getVipMemberTelByAll()) {
param = new JSONObject();
param.put("name",vipMember.getMemberName());
param.put("tel",tel);
VipSmsResult vipSmsResult = new VipSmsResult();
SendSmsResponse response = null;
vipSmsResult.setResultBussId(vipMember.getMemberId());
vipSmsResult.setResultTel(vipMember.getMemberTel());
vipSmsResult.setResultTemplate(templateCode);
response = SmsUtil.sendSms(vipMember.getMemberTel(), templateCode, param.toJSONString());
System.out.println("会员生日提醒短信发送-Result" + response.getCode() + "-" + response.getMessage());
vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage());
vipSmsResult.setResultRequestId(response.getRequestId());
vipSmsResult.setResultBizId(response.getBizId());
vipSmsResult.setResultCreateTime(new Date());
this.vipService.saveSmsResult(vipSmsResult);
}
for (VipReferrer vipReferrer : this.vipService.getVipReferrerTelByAll()) {
param = new JSONObject();
param.put("name",vipReferrer.getReferrerName());
param.put("tel",tel);
VipSmsResult vipSmsResult = new VipSmsResult();
SendSmsResponse response = null;
vipSmsResult.setResultBussId(vipReferrer.getReferrerId());
vipSmsResult.setResultTel(vipReferrer.getReferrerTel());
vipSmsResult.setResultTemplate(templateCode);
response = SmsUtil.sendSms(vipReferrer.getReferrerTel(), templateCode, param.toJSONString());
System.out.println("推荐人生日提醒短信发送-Result" + response.getCode() + "-" + response.getMessage());
vipSmsResult.setResultCode(response.getCode());
vipSmsResult.setResultMessage(response.getMessage());
vipSmsResult.setResultRequestId(response.getRequestId());
vipSmsResult.setResultBizId(response.getBizId());
vipSmsResult.setResultCreateTime(new Date());
this.vipService.saveSmsResult(vipSmsResult);
}
}
}

View File

@ -1,5 +1,7 @@
package com.ifish.util; package com.ifish.util;
import org.apache.poi.hssf.usermodel.HSSFRow;
import org.apache.poi.ss.usermodel.Cell;
import org.codehaus.jackson.map.ObjectMapper; import org.codehaus.jackson.map.ObjectMapper;
import java.io.File; import java.io.File;
import java.io.FileInputStream; import java.io.FileInputStream;
@ -11,11 +13,7 @@ import java.security.MessageDigest;
import java.text.DateFormat; import java.text.DateFormat;
import java.text.ParseException; import java.text.ParseException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.Calendar; import java.util.*;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import java.util.Random;
import sun.misc.BASE64Decoder; import sun.misc.BASE64Decoder;
import sun.misc.BASE64Encoder; import sun.misc.BASE64Encoder;
@ -352,4 +350,18 @@ public class IfishUtil {
} }
return ""; return "";
} }
/**
* 设置列类型
* @param row
*/
public static void setRowsType(HSSFRow row){
Iterator iterator = row.iterator();
for (Cell cell : row) {
if (cell != null) {
cell.setCellType(Cell.CELL_TYPE_STRING);
}
}
}
} }

View File

@ -13,8 +13,7 @@
http://www.springframework.org/schema/task http://www.springframework.org/schema/task
http://www.springframework.org/schema/task/spring-task.xsd http://www.springframework.org/schema/task/spring-task.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop.xsd" http://www.springframework.org/schema/aop/spring-aop.xsd" default-lazy-init="true">
default-lazy-init="true">
<!-- 导入外部的properties文件--> <!-- 导入外部的properties文件-->
<context:property-placeholder location="classpath*:jdbc.properties" ignore-unresolvable="true"/> <context:property-placeholder location="classpath*:jdbc.properties" ignore-unresolvable="true"/>

View File

@ -28,5 +28,5 @@ fastDFS_url_local=http://139.196.24.156:83/
#FastDFS\u6587\u4EF6URL\u8BBF\u95EE\u8DEF\u5F84(\u6B63\u5F0F\u73AF\u5883) #FastDFS\u6587\u4EF6URL\u8BBF\u95EE\u8DEF\u5F84(\u6B63\u5F0F\u73AF\u5883)
fastDFS_url_app=http://app.ifish7.com/ fastDFS_url_app=http://app.ifish7.com/
#\u73AF\u5883(local:\u672C\u5730\u73AF\u5883,test:\u6D4B\u8BD5\u73AF\u5883,\u6B63\u5F0F\u73AF\u5883:product) #\u73AF\u5883(local:\u672C\u5730\u73AF\u5883,test:\u6D4B\u8BD5\u73AF\u5883,\u6B63\u5F0F\u73AF\u5883:product)
#env=test env=test
env=local #env=local

View File

@ -3,14 +3,18 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context" xmlns:context="http://www.springframework.org/schema/context"
xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="http://www.springframework.org/schema/beans xmlns:task="http://www.springframework.org/schema/task"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-4.0.xsd http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-4.0.xsd" http://www.springframework.org/schema/context/spring-context-4.0.xsd
http://www.springframework.org/schema/task
http://www.springframework.org/schema/task/spring-task-4.0.xsd"
default-lazy-init="true"> default-lazy-init="true">
<task:annotation-driven/>
<!-- @Controller注解的使用前提配置 --> <!-- @Controller注解的使用前提配置 -->
<mvc:annotation-driven> <mvc:annotation-driven>
<mvc:message-converters register-defaults="true"> <mvc:message-converters register-defaults="true">
@ -35,7 +39,7 @@
</mvc:message-converters> </mvc:message-converters>
</mvc:annotation-driven> </mvc:annotation-driven>
<!-- 扫描指定包 --> <!-- 扫描指定包 -->
<context:component-scan base-package="com.ifish.ueditor.action,com.ifish.action,com.ifish.exception" /> <context:component-scan base-package="com.ifish.ueditor.action,com.ifish.action,com.ifish.exception,com.ifish.task" />
<!-- 静态资源访问,资源缓存一年 --> <!-- 静态资源访问,资源缓存一年 -->
<mvc:resources mapping="/ueditor/**" location="/ueditor/" cache-period="1500" /> <mvc:resources mapping="/ueditor/**" location="/ueditor/" cache-period="1500" />

View File

@ -242,36 +242,36 @@
<div class="form-group" id="SMS_139227937_smsTitle"> <div class="form-group" id="SMS_139227937_smsTitle">
<label class="col-xs-2 control-label no-padding-right">会议名称<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">会议名称<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsTitle' name="smsTitle" class="input-medium" maxlength='20'/> <input type="text" id='smsTitle' name="smsTitle" class="input-medium"/>
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsTime_space"></div> <div class="space-4" id="SMS_139227937_smsTime_space"></div>
<div class="form-group" id="SMS_139227937_smsTime"> <div class="form-group" id="SMS_139227937_smsTime">
<label class="col-xs-2 control-label no-padding-right">会议时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">会议时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsTime' name="smsTime" class="input-medium" maxlength='20'/> <input type="text" id='smsTime' name="smsTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsAddress_space"></div> <div class="space-4" id="SMS_139227937_smsAddress_space"></div>
<div class="form-group" id="SMS_139227937_smsAddress"> <div class="form-group" id="SMS_139227937_smsAddress">
<label class="col-xs-2 control-label no-padding-right">会议地址<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">会议地址<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsAddress' name="smsAddress" class="input-medium" maxlength='20'/> <input type="text" id='smsAddress' name="smsAddress" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsSignTime_space"></div> <div class="space-4" id="SMS_139227937_smsSignTime_space"></div>
<div class="form-group" id="SMS_139227937_smsSignTime"> <div class="form-group" id="SMS_139227937_smsSignTime">
<label class="col-xs-2 control-label no-padding-right">签到时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">签到时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsSignTime' name="smsSignTime" class="input-medium" maxlength='20'/> <input type="text" id='smsSignTime' name="smsSignTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsContact_space"></div> <div class="space-4" id="SMS_139227937_smsContact_space"></div>
<div class="form-group" id="SMS_139227937_smsContact"> <div class="form-group" id="SMS_139227937_smsContact">
<label class="col-xs-2 control-label no-padding-right">联系人及电话<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">联系人及电话<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsContact' name="smsContact" class="input-medium" value="胡萧" maxlength='20'/> <input type="text" id='smsContact' name="smsContact" class="input-medium" value="胡萧" />
<input type="text" id='smsContactTel' name="smsContactTel" class="input-medium" value="18907487848" maxlength='20'/> <input type="text" id='smsContactTel' name="smsContactTel" class="input-medium" value="18907487848" />
</div> </div>
</div> </div>
</div> </div>

View File

@ -200,51 +200,6 @@
jAlert('单位不能为空!', '提示'); jAlert('单位不能为空!', '提示');
return false; return false;
} }
var certificateCard = $("#certificateCard").val();
if(certificateCard == ""){
jAlert('证书编号不能为空!', '提示');
return false;
}
var certificateType = $("#certificateType").val();
if(certificateType == ""){
jAlert('证件类型不能为空!', '提示');
return false;
}
var certificateLevel = $("#certificateLevel").val();
if(certificateLevel == ""){
jAlert('证书等级不能为空!', '提示');
return false;
}
var certificateReceiveTime = $("#certificateReceiveTime").val();
if(certificateReceiveTime == ""){
jAlert('证书领取时间不能为空!', '提示');
return false;
}
var certificateMaturityTime = $("#certificateMaturityTime").val();
if(certificateMaturityTime == ""){
jAlert('证书到期时间不能为空!', '提示');
return false;
}
var openticketTime = $("#openticketTime").val();
if(openticketTime == ""){
jAlert('开票时间不能为空!', '提示');
return false;
}
var outcardTime = $("#outcardTime").val();
if(outcardTime == ""){
jAlert('出证时间不能为空!', '提示');
return false;
}
var annualReviewTime = $("#annualReviewTime").val();
if(annualReviewTime == ""){
jAlert('年审时间不能为空!', '提示');
return false;
}
var cost = $("#cost").val();
if(cost == ""){
jAlert('费用不能为空!', '提示');
return false;
}
$("#addOrUpdateSubmitBtn").attr("disabled",true); $("#addOrUpdateSubmitBtn").attr("disabled",true);
$("#form-company").submit(); $("#form-company").submit();
@ -418,13 +373,13 @@
<label>证书到期时间</label> <label>证书到期时间</label>
</td> </td>
<td> <td>
<input type="text" id='sSearch3' name="sSearch3" class="input-medium" value="" maxlength='20'/> <input type="text" id='sSearch3' name="sSearch3" class="input-medium" value="" />
</td> </td>
<td> <td>
<label>证书申请时间</label> <label>证书申请时间</label>
</td> </td>
<td> <td>
<input type="text" id='sSearch4' name="sSearch4" class="input-medium" value="" maxlength='20'/> <input type="text" id='sSearch4' name="sSearch4" class="input-medium" value="" />
</td> </td>
</tr> </tr>
@ -480,65 +435,65 @@
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书编号<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书编号</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateCard" id="certificateCard" class="form-control" maxlength="20"/> <input type="text" name="certificateCard" id="certificateCard" class="form-control" maxlength="20"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书等级<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书等级</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateLevel" id="certificateLevel" class="form-control" maxlength="20"/> <input type="text" name="certificateLevel" id="certificateLevel" class="form-control" maxlength="20"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书类型<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书类型</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateType" id="certificateType" class="form-control" maxlength="20"/> <input type="text" name="certificateType" id="certificateType" class="form-control" maxlength="20"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书申请时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书到期时间<</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">开票时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">开票时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='openticketTime' name="openticketTime" class="input-medium" maxlength='20'/> <input type="text" id='openticketTime' name="openticketTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">出证时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">出证时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='outcardTime' name="outcardTime" class="input-medium" maxlength='20'/> <input type="text" id='outcardTime' name="outcardTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">年审时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">年审时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" maxlength='20'/> <input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">费用<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">费用</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="cost" id="cost" class="input-medium" maxlength="50" /> <input type="text" name="cost" id="cost" class="input-medium" maxlength="50" />
</div> </div>

View File

@ -47,6 +47,7 @@
{"mData": function (vipMember) { {"mData": function (vipMember) {
return '<input type="checkbox" name="checkMember" value=' + vipMember.memberId + "_" + vipMember.memberTel + ' >'; return '<input type="checkbox" name="checkMember" value=' + vipMember.memberId + "_" + vipMember.memberTel + ' >';
}, "bSortable": false}, }, "bSortable": false},
{"mData": "memberCode","bSortable": false },
{"mData": "memberName","bSortable": false }, {"mData": "memberName","bSortable": false },
{"mData": "memberLegal","bSortable": false }, {"mData": "memberLegal","bSortable": false },
{"mData": "memberLegalCard","bSortable": false }, {"mData": "memberLegalCard","bSortable": false },
@ -54,11 +55,30 @@
{"mData": "memberAdmissionTime", "bSortable": false}, {"mData": "memberAdmissionTime", "bSortable": false},
{"mData": "memberMaturityTime", "bSortable": false}, {"mData": "memberMaturityTime", "bSortable": false},
{"mData": function (vipMember) { {"mData": function (vipMember) {
return vipMember.memberType.typeName; if (vipMember.memberType != null && vipMember.memberType != 'undefined') {
return vipMember.memberType.typeName;
} else {
return "";
}
}, "bSortable": false}, }, "bSortable": false},
{"mData": function (vipMember) {
if (vipMember.memberReferrer != null && vipMember.memberReferrer != 'undefined') {
return vipMember.memberReferrer.referrerName;
} else {
return "";
}
}, "bSortable": false},
{"mData": "memberContactSituation", "bSortable": false},
{"mData": "memberTel","bSortable": false }, {"mData": "memberTel","bSortable": false },
{"mData": "memberWechat","bSortable": false }, {"mData": "memberWechat","bSortable": false },
{"mData": "memberEmail","bSortable": false }, {"mData": "memberEmail","bSortable": false },
{"mData": "memberImportantContact","bSortable": false },
{"mData": "memberImportantTel","bSortable": false },
{"mData": "memberHandlingContact","bSortable": false },
{"mData": "memberHandlingTel","bSortable": false },
{"mData": "memberAddress", "bSortable": false},
{"mData": "memberFee", "bSortable": false},
{"mData": "memberRegisteredCapital","bSortable": false }, {"mData": "memberRegisteredCapital","bSortable": false },
{"mData": "memberEstablishedTime","bSortable": false }, {"mData": "memberEstablishedTime","bSortable": false },
{"mData": "memberBirthday","bSortable": false }, {"mData": "memberBirthday","bSortable": false },
@ -70,12 +90,6 @@
{"mData": "memberSituation","bSortable": false }, {"mData": "memberSituation","bSortable": false },
{"mData": "memberContact", "bSortable": false}, {"mData": "memberContact", "bSortable": false},
{"mData": "memberContactTel", "bSortable": false}, {"mData": "memberContactTel", "bSortable": false},
{"mData": "memberContactSituation", "bSortable": false},
{"mData": function (vipMember) {
return vipMember.memberReferrer.referrerName;
}, "bSortable": false},
{"mData": "memberAddress", "bSortable": false},
{"mData": "memberFee", "bSortable": false},
{"mData": function(vipMember){ {"mData": function(vipMember){
return '<a href="javascript:void(0);" onclick="sendSms(\''+vipMember.memberId + '_' + vipMember.memberTel+'\')" class="label label-large"><span class="icon-comment"></span></a>'+ return '<a href="javascript:void(0);" onclick="sendSms(\''+vipMember.memberId + '_' + vipMember.memberTel+'\')" class="label label-large"><span class="icon-comment"></span></a>'+
'<a href="javascript:void(0);" onclick="editVipMember(\''+vipMember.memberId+'\');" class="label label-primary"><i class="icon-edit"></i></a>'+ '<a href="javascript:void(0);" onclick="editVipMember(\''+vipMember.memberId+'\');" class="label label-primary"><i class="icon-edit"></i></a>'+
@ -192,7 +206,7 @@
} }
else{ else{
//刷新当前页面 //刷新当前页面
jAlert('失败', '提示'); jAlert(data, '提示');
$("#addOrUpdateSubmitBtn").attr("disabled",false); $("#addOrUpdateSubmitBtn").attr("disabled",false);
} }
}); });
@ -269,6 +283,13 @@
dataTable.fnPageChange(--pageNum, true); dataTable.fnPageChange(--pageNum, true);
} }
function changeSmsContent() {
$("#smsType option").each(function () {
$("#" + $(this).val()).hide();
});
$("#" + $("#smsType option:selected").val()).show();
}
</script> </script>
</head> </head>
@ -321,7 +342,7 @@
<label>入会时间</label> <label>入会时间</label>
</td> </td>
<td> <td>
<input type="text" id='sSearch3' name="sSearch3" class="input-medium" value="" maxlength='20'/>-<input type="text" id='sSearch4' name="sSearch4" class="input-medium" value="" maxlength='20'/> <input type="text" id='sSearch3' name="sSearch3" class="input-medium" value="" />-<input type="text" id='sSearch4' name="sSearch4" class="input-medium" value="" />
</td> </td>
<td> <td>
<label>手机号码</label> <label>手机号码</label>
@ -367,6 +388,7 @@
<tr> <tr>
<th><input type="checkbox" name="checkAll" id="checkAll" onclick=""/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;全选</th> <th><input type="checkbox" name="checkAll" id="checkAll" onclick=""/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;全选</th>
<th>会员代号</th>
<th>单位名称</th> <th>单位名称</th>
<th>法人代表</th> <th>法人代表</th>
<th>法人身份证号</th> <th>法人身份证号</th>
@ -374,9 +396,17 @@
<th>入会时间</th> <th>入会时间</th>
<th>到期时间</th> <th>到期时间</th>
<th>会员类型</th> <th>会员类型</th>
<th>手机号码</th> <th>推荐人</th>
<th>联系情况</th>
<th>法人号码</th>
<th>微信</th> <th>微信</th>
<th>邮箱</th> <th>邮箱</th>
<th>重要联系人</th>
<th>重要手机</th>
<th>经办联系人</th>
<th>经办手机</th>
<th>单位地址</th>
<th>会费</th>
<th>注册资金</th> <th>注册资金</th>
<th>成立时间</th> <th>成立时间</th>
<th>生日</th> <th>生日</th>
@ -388,10 +418,6 @@
<th>企业情况</th> <th>企业情况</th>
<th>联系人</th> <th>联系人</th>
<th>联系电话</th> <th>联系电话</th>
<th>联系情况</th>
<th>推荐人</th>
<th>单位地址</th>
<th>会费</th>
<th>操作</th> <th>操作</th>
</tr> </tr>
</thead> </thead>
@ -427,46 +453,111 @@
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">短信类型<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">短信类型<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<select id="smsType" name="smsType" class="form-control"> <select id="smsType" name="smsType" class="form-control" onchange="changeSmsContent();">
<option value="SMS_139227937">活动通知</option> <option value="SMS_139227937">活动通知</option>
<option value="SMS_142150098">证书到期通知</option>
<option value="SMS_142145967">会员到期通知</option>
</select> </select>
</div> </div>
</div> </div>
<div id="SMS_139227937" style="display: block;">
<div class="space-4" id="SMS_139227937_smsTitle_space"></div> <div class="space-4" id="SMS_139227937_smsTitle_space"></div>
<div class="form-group" id="SMS_139227937_smsTitle"> <div class="form-group" id="SMS_139227937_smsTitle">
<label class="col-xs-2 control-label no-padding-right">会议名称<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">会议名称<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='smsTitle' name="smsTitle" class="input-medium" maxlength='20'/> <input type="text" id='smsTitle' name="smsTitle" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_139227937_smsTime_space"></div>
<div class="form-group" id="SMS_139227937_smsTime">
<label class="col-xs-2 control-label no-padding-right">会议时间<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsTime' name="smsTime" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_139227937_smsAddress_space"></div>
<div class="form-group" id="SMS_139227937_smsAddress">
<label class="col-xs-2 control-label no-padding-right">会议地址<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsAddress' name="smsAddress" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_139227937_smsSignTime_space"></div>
<div class="form-group" id="SMS_139227937_smsSignTime">
<label class="col-xs-2 control-label no-padding-right">签到时间<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsSignTime' name="smsSignTime" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_139227937_smsContact_space"></div>
<div class="form-group" id="SMS_139227937_smsContact">
<label class="col-xs-2 control-label no-padding-right">联系人及电话<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsContact' name="smsContact" class="input-medium" value="胡萧" />
<input type="text" id='smsContactTel' name="smsContactTel" class="input-medium" value="18907487848" />
</div>
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsTime_space"></div> <!-- 证书到期通知 -->
<div class="form-group" id="SMS_139227937_smsTime"> <div id="SMS_142150098" style="display: none;">
<label class="col-xs-2 control-label no-padding-right">会议时间<span style="color:red;">*</span></label> <div class="space-4" id="SMS_142150098_smsDate_space"></div>
<div class="col-xs-8"> <div class="form-group" id="SMS_142150098_smsDate">
<input type="text" id='smsTime' name="smsTime" class="input-medium" maxlength='20'/> <label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsCertifDate' name="smsCertifDate" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_142150098_smsCertifTel_space"></div>
<div class="form-group" id="SMS_142150098_smsCertifTel">
<label class="col-xs-2 control-label no-padding-right">秘书处电话<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsCertifTel' name="smsCertifTel" class="input-medium" value="84476408 84477758"/>
</div>
</div> </div>
</div> </div>
<div class="space-4" id="SMS_139227937_smsAddress_space"></div> <!-- 会员到期通知 -->
<div class="form-group" id="SMS_139227937_smsAddress"> <div id="SMS_142145967" style="display: none;">
<label class="col-xs-2 control-label no-padding-right">会议地址<span style="color:red;">*</span></label> <div class="space-4" id="SMS_142145967_smsDate_space"></div>
<div class="col-xs-8"> <div class="form-group" id="SMS_142145967_smsDate">
<input type="text" id='smsAddress' name="smsAddress" class="input-medium" maxlength='20'/> <label class="col-xs-2 control-label no-padding-right">会员到期时间<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsMemberDate' name="smsMemberDate" class="input-medium" />
</div>
</div> </div>
</div> <div class="space-4" id="SMS_142145967_smsMoney_space"></div>
<div class="space-4" id="SMS_139227937_smsSignTime_space"></div> <div class="form-group" id="SMS_142145967_smsMoney">
<div class="form-group" id="SMS_139227937_smsSignTime"> <label class="col-xs-2 control-label no-padding-right">会费<span style="color:red;">*</span></label>
<label class="col-xs-2 control-label no-padding-right">签到时间<span style="color:red;">*</span></label> <div class="col-xs-8">
<div class="col-xs-8"> <input type="text" id='smsMoney' name="smsMoney" class="input-medium" />元
<input type="text" id='smsSignTime' name="smsSignTime" class="input-medium" maxlength='20'/> </div>
</div> </div>
</div> <div class="space-4" id="SMS_142145967_smsAccountName_space"></div>
<div class="space-4" id="SMS_139227937_smsContact_space"></div> <div class="form-group" id="SMS_142145967_smsAccountName">
<div class="form-group" id="SMS_139227937_smsContact"> <label class="col-xs-2 control-label no-padding-right">户名<span style="color:red;">*</span></label>
<label class="col-xs-2 control-label no-padding-right">联系人及电话<span style="color:red;">*</span></label> <div class="col-xs-8">
<div class="col-xs-8"> <input type="text" id='smsAccountName' name="smsAccountName" class="input-medium" />
<input type="text" id='smsContact' name="smsContact" class="input-medium" value="胡萧" maxlength='20'/> </div>
<input type="text" id='smsContactTel' name="smsContactTel" class="input-medium" value="18907487848" maxlength='20'/> </div>
<div class="space-4" id="SMS_142145967_smsAccountBankName_space"></div>
<div class="form-group" id="SMS_142145967_smsAccountBankName">
<label class="col-xs-2 control-label no-padding-right">开户行<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsAccountBankName' name="smsAccountBankName" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_142145967_smsAccountCode_space"></div>
<div class="form-group" id="SMS_142145967_smsAccountCode">
<label class="col-xs-2 control-label no-padding-right">账号<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsAccountCode' name="smsAccountCode" class="input-medium" />
</div>
</div>
<div class="space-4" id="SMS_117425137_smsMemberTel_space"></div>
<div class="form-group" id="SMS_117425137_smsMemberTel">
<label class="col-xs-2 control-label no-padding-right">秘书处电话<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='smsMemberTel' name="smsMemberTel" class="input-medium" value="84476408 84477758"/>
</div>
</div> </div>
</div> </div>
</div> </div>

View File

@ -419,6 +419,15 @@
<div class="row" style="margin-left: 30px;"> <div class="row" style="margin-left: 30px;">
<div class="col-xs-12"> <div class="col-xs-12">
<form id="form-add" method="post" class="form-horizontal" role="form" action="<%=basePath%>page/vip/memberAddOrUpdate.do"> <form id="form-add" method="post" class="form-horizontal" role="form" action="<%=basePath%>page/vip/memberAddOrUpdate.do">
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">会员代号</span>
<input type="text" name="memberCode" id="memberCode" class="form-control" required="required" maxlength="100" size="50"/>
</div>
</div>
</div>
<div class="row"> <div class="row">
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
@ -465,7 +474,7 @@
</div> </div>
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
<span class="input-group-addon">手机</span> <span class="input-group-addon">法人手机</span>
<input type="text" name="memberTel" id="memberTel" class="form-control" required="required" maxlength="20"/> <input type="text" name="memberTel" id="memberTel" class="form-control" required="required" maxlength="20"/>
</div> </div>
</div> </div>
@ -576,6 +585,36 @@
</div> </div>
</div> </div>
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">重要联系人</span>
<input type="text" name="memberImportantContact" id="memberImportantContact" class="form-control" required="required" maxlength="20"/>
</div>
</div>
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">重要手机</span>
<input type="text" name="memberImportantTel" id="memberImportantTel" class="form-control" required="required" maxlength="20"/>
</div>
</div>
</div>
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">经办联系人</span>
<input type="text" name="memberHandlingContact" id="memberHandlingContact" class="form-control" required="required" maxlength="20"/>
</div>
</div>
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">经办手机</span>
<input type="text" name="memberHandlingTel" id="memberHandlingTel" class="form-control" required="required" maxlength="20"/>
</div>
</div>
</div>
<div class="row"> <div class="row">
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
@ -824,14 +863,14 @@
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" />
</div> </div>
</div> </div>
@ -839,21 +878,21 @@
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">开票时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">开票时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='openticketTime' name="openticketTime" class="input-medium" maxlength='20'/> <input type="text" id='openticketTime' name="openticketTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">出证时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">出证时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='outcardTime' name="outcardTime" class="input-medium" maxlength='20'/> <input type="text" id='outcardTime' name="outcardTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">年审时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">年审时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" maxlength='20'/> <input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" />
</div> </div>
</div> </div>

View File

@ -418,6 +418,15 @@
<div class="row" style="margin-left: 30px;"> <div class="row" style="margin-left: 30px;">
<div class="col-xs-12"> <div class="col-xs-12">
<form id="form-add" method="post" class="form-horizontal" role="form" action="<%=basePath%>page/vip/memberAddOrUpdate.do"> <form id="form-add" method="post" class="form-horizontal" role="form" action="<%=basePath%>page/vip/memberAddOrUpdate.do">
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">会员代号</span>
<input type="text" name="memberCode" id="memberCode" class="form-control" required="required" maxlength="100" />
</div>
</div>
</div>
<div class="row"> <div class="row">
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
@ -464,7 +473,7 @@
</div> </div>
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
<span class="input-group-addon">手机</span> <span class="input-group-addon">法人手机</span>
<input type="text" name="memberTel" id="memberTel" value="${vipMember.memberTel}" class="form-control" required="required" maxlength="20"/> <input type="text" name="memberTel" id="memberTel" value="${vipMember.memberTel}" class="form-control" required="required" maxlength="20"/>
</div> </div>
</div> </div>
@ -575,6 +584,36 @@
</div> </div>
</div> </div>
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">重要联系人</span>
<input type="text" name="memberImportantContact" id="memberImportantContact" value="${vipMember.memberImportantContact}" class="form-control" required="required" maxlength="20"/>
</div>
</div>
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">重要手机</span>
<input type="text" name="memberImportantTel" id="memberImportantTel" value="${vipMember.memberImportantTel}" class="form-control" required="required" maxlength="20"/>
</div>
</div>
</div>
<div class="row">
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">经办联系人</span>
<input type="text" name="memberHandlingContact" id="memberHandlingContact" value="${vipMember.memberHandlingContact}" class="form-control" required="required" maxlength="20"/>
</div>
</div>
<div class="form-group col-lg-3">
<div class="input-group">
<span class="input-group-addon">经办手机</span>
<input type="text" name="memberHandlingTel" id="memberHandlingTel" value="${vipMember.memberHandlingTel}" class="form-control" required="required" maxlength="20"/>
</div>
</div>
</div>
<div class="row"> <div class="row">
<div class="form-group col-lg-3"> <div class="form-group col-lg-3">
<div class="input-group"> <div class="input-group">
@ -650,7 +689,7 @@
<div class="input-group"> <div class="input-group">
<span class="input-group-addon">推荐人类型</span> <span class="input-group-addon">推荐人类型</span>
<select id="referrerType" name="referrerType.typeId" disabled="disabled" class="form-control"> <select id="referrerType" name="referrerType.typeId" disabled="disabled" class="form-control">
<c:forEach items="${vipTypes}" var="vipType"> <c:forEach items="${vipTypes}" var="vipType">s
<option value="${vipType.typeId}" <c:if test="${vipType.typeId == vipReferrer.referrerType.typeId}">selected="selected"</c:if> >${vipType.typeName}</option> <option value="${vipType.typeId}" <c:if test="${vipType.typeId == vipReferrer.referrerType.typeId}">selected="selected"</c:if> >${vipType.typeName}</option>
</c:forEach> </c:forEach>
</select> </select>
@ -838,14 +877,14 @@
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" />
</div> </div>
</div> </div>
@ -853,21 +892,21 @@
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">开票时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">开票时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='openticketTime' name="openticketTime" class="input-medium" maxlength='20'/> <input type="text" id='openticketTime' name="openticketTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">出证时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">出证时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='outcardTime' name="outcardTime" class="input-medium" maxlength='20'/> <input type="text" id='outcardTime' name="outcardTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">年审时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">年审时间<span style="color:red;">*</span></label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" maxlength='20'/> <input type="text" id='annualReviewTime' name="annualReviewTime" class="input-medium" />
</div> </div>
</div> </div>

View File

@ -137,41 +137,6 @@
jAlert('姓名不能为空!', '提示'); jAlert('姓名不能为空!', '提示');
return false; return false;
} }
var cardNum = $("#cardNum").val();
if(cardNum == ""){
jAlert('身份证号不能为空!', '提示');
return false;
}
var certificateType = $("#certificateType").val();
if(certificateType == ""){
jAlert('证件类型不能为空!', '提示');
return false;
}
var certificateLevel = $("#certificateLevel").val();
if(certificateLevel == ""){
jAlert('证书等级不能为空!', '提示');
return false;
}
var certificateCard = $("#certificateCard").val();
if(certificateCard == ""){
jAlert('证书编号不能为空!', '提示');
return false;
}
var certificateApplyTime = $("#certificateApplyTime").val();
if(certificateApplyTime == ""){
jAlert('证书申请时间不能为空!', '提示');
return false;
}
var certificateReceiveTime = $("#certificateReceiveTime").val();
if(certificateReceiveTime == ""){
jAlert('证书领取时间不能为空!', '提示');
return false;
}
var certificateMaturityTime = $("#certificateMaturityTime").val();
if(certificateMaturityTime == ""){
jAlert('证书到期时间不能为空!', '提示');
return false;
}
$("#addOrUpdateSubmitBtn").attr("disabled",true); $("#addOrUpdateSubmitBtn").attr("disabled",true);
$("#form-personal").submit(); $("#form-personal").submit();
@ -356,13 +321,13 @@
<label>证书到期时间</label> <label>证书到期时间</label>
</td> </td>
<td> <td>
<input type="text" id='sSearch3' name="sSearch3" class="input-medium" maxlength='20'/> <input type="text" id='sSearch3' name="sSearch3" class="input-medium" />
</td> </td>
<td> <td>
<label>证书领取时间</label> <label>证书领取时间</label>
</td> </td>
<td> <td>
<input type="text" id='sSearch4' name="sSearch4" class="input-medium" maxlength='20'/> <input type="text" id='sSearch4' name="sSearch4" class="input-medium" />
</td> </td>
</tr> </tr>
@ -415,14 +380,14 @@
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">身份证号<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">身份证号</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="cardNum" id="cardNum" class="form-control" maxlength="50"/> <input type="text" name="cardNum" id="cardNum" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">性别<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">性别</label>
<div class="col-xs-8"> <div class="col-xs-8">
<select name="personalGender" id="personalGender"> <select name="personalGender" id="personalGender">
<option value="男">男</option> <option value="男">男</option>
@ -432,93 +397,93 @@
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">手机号码<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">手机号码</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalTel" id="personalTel" class="form-control" maxlength="50"/> <input type="text" name="personalTel" id="personalTel" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">微信<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">微信</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalWechat" id="personalWechat" class="form-control" maxlength="50"/> <input type="text" name="personalWechat" id="personalWechat" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">邮箱<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">邮箱</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalEmail" id="personalEmail" class="form-control" maxlength="50"/> <input type="text" name="personalEmail" id="personalEmail" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">研究方向<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">研究方向</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalResearchDirection" id="personalResearchDirection" class="form-control" maxlength="50"/> <input type="text" name="personalResearchDirection" id="personalResearchDirection" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">专业<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">专业</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalProfession" id="personalProfession" class="form-control" maxlength="50"/> <input type="text" name="personalProfession" id="personalProfession" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">毕业学校<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">毕业学校</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalSchool" id="personalSchool" class="form-control" maxlength="50"/> <input type="text" name="personalSchool" id="personalSchool" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">单位名称<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">单位名称</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="personalMember" id="personalMember" class="form-control" maxlength="50"/> <input type="text" name="personalMember" id="personalMember" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书等级<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书等级</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateLevel" id="certificateLevel" class="form-control" maxlength="50"/> <input type="text" name="certificateLevel" id="certificateLevel" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书类型<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书类型</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateType" id="certificateType" class="form-control" maxlength="50"/> <input type="text" name="certificateType" id="certificateType" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书编号<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书编号</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" name="certificateCard" id="certificateCard" class="form-control" maxlength="50"/> <input type="text" name="certificateCard" id="certificateCard" class="form-control" maxlength="50"/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书申请时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书申请时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateApplyTime' name="certificateApplyTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书领取时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书领取时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateReceiveTime' name="certificateReceiveTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateReceiveTime' name="certificateReceiveTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">证书到期时间<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">证书到期时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" maxlength='20'/> <input type="text" id='certificateMaturityTime' name="certificateMaturityTime" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>

View File

@ -51,7 +51,6 @@
{"mData": "referrerEmail", "bSortable": false}, {"mData": "referrerEmail", "bSortable": false},
{"mData": "referrerAdmissionTime", "bSortable": false}, {"mData": "referrerAdmissionTime", "bSortable": false},
{"mData": "referrerRemark", "bSortable": false}, {"mData": "referrerRemark", "bSortable": false},
{"mData": "referrerFee", "bSortable": false},
{"mData": function(vipReferrer){ {"mData": function(vipReferrer){
return '<a onclick="editVipReferrer(\''+vipReferrer.referrerId+'\');" class="label label-primary"><i class="icon-edit"></i></a> ' return '<a onclick="editVipReferrer(\''+vipReferrer.referrerId+'\');" class="label label-primary"><i class="icon-edit"></i></a> '
+'<a href="javascript:void(0);" onclick="deleteVipReferrer('+vipReferrer.referrerId+')" class="label label-danger"><span class="icon-trash"></span></a>'; +'<a href="javascript:void(0);" onclick="deleteVipReferrer('+vipReferrer.referrerId+')" class="label label-danger"><span class="icon-trash"></span></a>';
@ -92,7 +91,6 @@
$("#referrerTel").val(""); $("#referrerTel").val("");
$("#referrerEmail").val(""); $("#referrerEmail").val("");
$("#referrerBirthday").val(""); $("#referrerBirthday").val("");
$("#referrerFee").val("");
$("#referrerAdmissionTime").val(""); $("#referrerAdmissionTime").val("");
$("#referrerRemark").val(""); $("#referrerRemark").val("");
$("#addOrUpdateSubmitBtn").attr("disabled",false); $("#addOrUpdateSubmitBtn").attr("disabled",false);
@ -117,11 +115,6 @@
jAlert('推荐人名称不能为空!', '提示'); jAlert('推荐人名称不能为空!', '提示');
return false; return false;
} }
var referrerAdmissionTime = $("#referrerAdmissionTime").val();
if(referrerAdmissionTime == ""){
jAlert('推荐人入会时间不能为空!', '提示');
return false;
}
$("#addOrUpdateSubmitBtn").attr("disabled",true); $("#addOrUpdateSubmitBtn").attr("disabled",true);
$("#form-referrer").submit(); $("#form-referrer").submit();
}); });
@ -162,7 +155,6 @@
$("#referrerTel").val(data.referrerTel); $("#referrerTel").val(data.referrerTel);
$("#referrerEmail").val(data.referrerEmail); $("#referrerEmail").val(data.referrerEmail);
$("#referrerBirthday").val(data.referrerBirthday); $("#referrerBirthday").val(data.referrerBirthday);
$("#referrerFee").val(data.referrerFee);
$("#referrerAdmissionTime").val(data.referrerAdmissionTime); $("#referrerAdmissionTime").val(data.referrerAdmissionTime);
$("#referrerRemark").val(data.referrerRemark); $("#referrerRemark").val(data.referrerRemark);
$("#referrerModal").modal("show"); $("#referrerModal").modal("show");
@ -284,7 +276,7 @@
<label>入会时间</label> <label>入会时间</label>
</td> </td>
<td colspan="2"> <td colspan="2">
<input type="text" id='sSearch3' name="sSearch3" class="input-medium" maxlength='20'/>-<input type="text" id='sSearch4' name="sSearch4" class="input-medium" maxlength='20'/> <input type="text" id='sSearch3' name="sSearch3" class="input-medium" />-<input type="text" id='sSearch4' name="sSearch4" class="input-medium" />
</td> </td>
</tr> </tr>
@ -307,7 +299,6 @@
<th>推荐人邮箱</th> <th>推荐人邮箱</th>
<th>推荐人入会时间</th> <th>推荐人入会时间</th>
<th>备注</th> <th>备注</th>
<th>推荐人费用</th>
<th>操作</th> <th>操作</th>
</tr> </tr>
</thead> </thead>
@ -337,14 +328,14 @@
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人身份证号<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">推荐人身份证号</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='referrerCard' name="referrerCard" class="input-medium" maxlength='20'/> <input type="text" id='referrerCard' name="referrerCard" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人类型<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">推荐人类型</label>
<div class="col-xs-8"> <div class="col-xs-8">
<select id="referrerType" name="referrerType.typeId" class="form-control"> <select id="referrerType" name="referrerType.typeId" class="form-control">
<option value="">请选择</option> <option value="">请选择</option>
@ -356,37 +347,30 @@
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人手机号码<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">推荐人手机号码</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='referrerTel' name="referrerTel" class="input-medium" maxlength='20'/> <input type="text" id='referrerTel' name="referrerTel" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人邮箱<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">推荐人邮箱</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='referrerEmail' name="referrerEmail" class="input-medium" maxlength='20'/> <input type="text" id='referrerEmail' name="referrerEmail" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人生日<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">推荐人生日</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='referrerBirthday' name="referrerBirthday" class="input-medium" maxlength='20'/> <input type="text" id='referrerBirthday' name="referrerBirthday" class="input-medium" />
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 control-label no-padding-right">推荐人费用<span style="color:red;">*</span></label> <label class="col-xs-2 control-label no-padding-right">入会时间</label>
<div class="col-xs-8"> <div class="col-xs-8">
<input type="text" id='referrerFee' name="referrerFee" class="input-medium" maxlength='20'/> <input type="text" id='referrerAdmissionTime' name="referrerAdmissionTime" class="input-medium" />
</div>
</div>
<div class="space-4"></div>
<div class="form-group">
<label class="col-xs-2 control-label no-padding-right">入会时间<span style="color:red;">*</span></label>
<div class="col-xs-8">
<input type="text" id='referrerAdmissionTime' name="referrerAdmissionTime" class="input-medium" maxlength='20'/>
</div> </div>
</div> </div>
<div class="space-4"></div> <div class="space-4"></div>