Browse Source

生成二维码

xubh 5 years ago
parent
commit
7325ab6d94

+ 26 - 0
src/main/java/com/minpay/common/service/IQrcodeService.java

@@ -0,0 +1,26 @@
+package com.minpay.common.service;
+
+
+import com.startup.minpay.frame.exception.MINBusinessException;
+import com.startup.minpay.frame.service.base.IMINLocalService;
+
+import java.util.Map;
+
+/**
+ *  地址重定向表
+ * @author xubh
+ *
+ */
+public interface IQrcodeService extends IMINLocalService {
+
+	/**
+	 * 创建二维码
+	 * @param time 有效时间 (分钟) 8888=无限期
+	 * @param url	url
+	 * @param sum	剩余次数
+	 * @return
+	 */
+	public String createQrCode(String time, String url , String sum) throws MINBusinessException;
+
+	
+}

+ 43 - 0
src/main/java/com/minpay/common/service/impl/QrcodeServiceImpl.java

@@ -0,0 +1,43 @@
+package com.minpay.common.service.impl;
+
+import com.min.util.DateUtil;
+import com.minpay.common.service.IPropertiesService;
+import com.minpay.common.service.IQrcodeService;
+import com.minpay.db.table.mapper.VmQrcodeInfMapper;
+import com.minpay.db.table.model.VmQrcodeInf;
+import com.startup.minpay.frame.exception.MINBusinessException;
+import com.startup.minpay.frame.service.base.IMINDataBaseService;
+import com.startup.minpay.frame.service.base.Service;
+import com.startup.minpay.frame.target.MINComponent;
+
+import java.util.UUID;
+
+/**
+ *重定向地址表
+ * @author xubh
+ */
+@MINComponent
+public class QrcodeServiceImpl implements IQrcodeService {
+
+
+
+
+    @Override
+    public String createQrCode(String time, String url, String sum) throws MINBusinessException{
+        VmQrcodeInf vmQrcodeInf = new VmQrcodeInf();
+        String uuid = UUID.randomUUID().toString().replaceAll("-","").substring(0,10);
+        vmQrcodeInf.setId(uuid);
+        vmQrcodeInf.setCreateTime(DateUtil.getCurrentDateTimeString());
+        vmQrcodeInf.setTime(time);
+        vmQrcodeInf.setUrl(url);
+        vmQrcodeInf.setSum(sum);
+        int ress = Service.lookup(IMINDataBaseService.class).getMybatisMapper(VmQrcodeInfMapper.class).insertSelective(vmQrcodeInf);
+        if(ress < 0){
+            throw new MINBusinessException("生成二维码失败,请刷新页面!");
+        }
+        String redirectUrl = Service.lookup(IPropertiesService.class)
+                .getSystemProperties().get("REDIRECT_URl").getKey();
+        redirectUrl = redirectUrl.concat("code=").concat(uuid);
+        return redirectUrl;
+    }
+}

+ 19 - 2
src/main/java/com/minpay/common/util/DateUtil.java

@@ -735,6 +735,23 @@ public class DateUtil {
 			cal.add(Calendar.DATE, 30);
 			return format.format(cal.getTime());
 		}
-		
-		
+
+	/**
+	 * 指定时间添加分钟
+	 * @param time 时间
+	 * @param day	天
+	 * @return
+	 * @throws ParseException
+	 */
+	public static String dateAddminute(String time,String minute) throws ParseException{
+		SimpleDateFormat format = new SimpleDateFormat("yyyyMMddHHmmss");
+		Date d = format.parse(time);
+		format.format(d);
+		Calendar cal=Calendar.getInstance();
+		cal.setTime(d);
+		cal.add(Calendar.MINUTE, Integer.valueOf(minute));
+		return format.format(cal.getTime());
+	}
+
+
 }

+ 97 - 0
src/main/java/com/minpay/db/table/mapper/VmQrcodeInfMapper.java

@@ -0,0 +1,97 @@
+package com.minpay.db.table.mapper;
+
+import com.minpay.db.table.model.VmQrcodeInf;
+import com.minpay.db.table.model.VmQrcodeInfExample;
+import com.startup.minpay.frame.jdbc.IMINMybatisEntityMapper;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface VmQrcodeInfMapper extends IMINMybatisEntityMapper<VmQrcodeInf, String, VmQrcodeInfExample> {
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int countByExample(VmQrcodeInfExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int deleteByExample(VmQrcodeInfExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int deleteByPrimaryKey(String id);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int insert(VmQrcodeInf record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int insertSelective(VmQrcodeInf record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    List<VmQrcodeInf> selectByExample(VmQrcodeInfExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    VmQrcodeInf selectByPrimaryKey(String id);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int updateByExampleSelective(@Param("record") VmQrcodeInf record, @Param("example") VmQrcodeInfExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int updateByExample(@Param("record") VmQrcodeInf record, @Param("example") VmQrcodeInfExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int updateByPrimaryKeySelective(VmQrcodeInf record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    int updateByPrimaryKey(VmQrcodeInf record);
+}

+ 229 - 0
src/main/java/com/minpay/db/table/model/VmQrcodeInf.java

@@ -0,0 +1,229 @@
+package com.minpay.db.table.model;
+
+import com.startup.minpay.frame.data.AbstractMINBean;
+
+public class VmQrcodeInf extends AbstractMINBean {
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_id
+     *
+     * @mbggenerated
+     */
+    private String id;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_state
+     *
+     * @mbggenerated
+     */
+    private String state;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_time
+     *
+     * @mbggenerated
+     */
+    private String time;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_url
+     *
+     * @mbggenerated
+     */
+    private String url;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_create_user
+     *
+     * @mbggenerated
+     */
+    private String createUser;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_create_time
+     *
+     * @mbggenerated
+     */
+    private String createTime;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column vm_qrcode_inf.vqi_sum
+     *
+     * @mbggenerated
+     */
+    private String sum;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_id
+     *
+     * @return the value of vm_qrcode_inf.vqi_id
+     *
+     * @mbggenerated
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_id
+     *
+     * @param id the value for vm_qrcode_inf.vqi_id
+     *
+     * @mbggenerated
+     */
+    public void setId(String id) {
+        this.id = id == null ? null : id.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_state
+     *
+     * @return the value of vm_qrcode_inf.vqi_state
+     *
+     * @mbggenerated
+     */
+    public String getState() {
+        return state;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_state
+     *
+     * @param state the value for vm_qrcode_inf.vqi_state
+     *
+     * @mbggenerated
+     */
+    public void setState(String state) {
+        this.state = state == null ? null : state.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_time
+     *
+     * @return the value of vm_qrcode_inf.vqi_time
+     *
+     * @mbggenerated
+     */
+    public String getTime() {
+        return time;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_time
+     *
+     * @param time the value for vm_qrcode_inf.vqi_time
+     *
+     * @mbggenerated
+     */
+    public void setTime(String time) {
+        this.time = time == null ? null : time.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_url
+     *
+     * @return the value of vm_qrcode_inf.vqi_url
+     *
+     * @mbggenerated
+     */
+    public String getUrl() {
+        return url;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_url
+     *
+     * @param url the value for vm_qrcode_inf.vqi_url
+     *
+     * @mbggenerated
+     */
+    public void setUrl(String url) {
+        this.url = url == null ? null : url.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_create_user
+     *
+     * @return the value of vm_qrcode_inf.vqi_create_user
+     *
+     * @mbggenerated
+     */
+    public String getCreateUser() {
+        return createUser;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_create_user
+     *
+     * @param createUser the value for vm_qrcode_inf.vqi_create_user
+     *
+     * @mbggenerated
+     */
+    public void setCreateUser(String createUser) {
+        this.createUser = createUser == null ? null : createUser.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_create_time
+     *
+     * @return the value of vm_qrcode_inf.vqi_create_time
+     *
+     * @mbggenerated
+     */
+    public String getCreateTime() {
+        return createTime;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_create_time
+     *
+     * @param createTime the value for vm_qrcode_inf.vqi_create_time
+     *
+     * @mbggenerated
+     */
+    public void setCreateTime(String createTime) {
+        this.createTime = createTime == null ? null : createTime.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column vm_qrcode_inf.vqi_sum
+     *
+     * @return the value of vm_qrcode_inf.vqi_sum
+     *
+     * @mbggenerated
+     */
+    public String getSum() {
+        return sum;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column vm_qrcode_inf.vqi_sum
+     *
+     * @param sum the value for vm_qrcode_inf.vqi_sum
+     *
+     * @mbggenerated
+     */
+    public void setSum(String sum) {
+        this.sum = sum == null ? null : sum.trim();
+    }
+}

+ 827 - 0
src/main/java/com/minpay/db/table/model/VmQrcodeInfExample.java

@@ -0,0 +1,827 @@
+package com.minpay.db.table.model;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class VmQrcodeInfExample {
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    protected String orderByClause;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    protected boolean distinct;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    protected List<Criteria> oredCriteria;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public VmQrcodeInfExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("vqi_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("vqi_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(String value) {
+            if(value == null ){
+                andIdIsNull();
+            } else {
+                addCriterion("vqi_id =", value, "id");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(String value) {
+            if(value == null ){
+                andIdIsNotNull();
+            } else {
+                addCriterion("vqi_id <>", value, "id");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(String value) {
+            addCriterion("vqi_id >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_id >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(String value) {
+            addCriterion("vqi_id <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(String value) {
+            addCriterion("vqi_id <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLike(String value) {
+            addCriterion("vqi_id like", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotLike(String value) {
+            addCriterion("vqi_id not like", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<String> values) {
+            addCriterion("vqi_id in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<String> values) {
+            addCriterion("vqi_id not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(String value1, String value2) {
+            addCriterion("vqi_id between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(String value1, String value2) {
+            addCriterion("vqi_id not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIsNull() {
+            addCriterion("vqi_state is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIsNotNull() {
+            addCriterion("vqi_state is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateEqualTo(String value) {
+            if(value == null ){
+                andStateIsNull();
+            } else {
+                addCriterion("vqi_state =", value, "state");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotEqualTo(String value) {
+            if(value == null ){
+                andStateIsNotNull();
+            } else {
+                addCriterion("vqi_state <>", value, "state");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andStateGreaterThan(String value) {
+            addCriterion("vqi_state >", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_state >=", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateLessThan(String value) {
+            addCriterion("vqi_state <", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateLessThanOrEqualTo(String value) {
+            addCriterion("vqi_state <=", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateLike(String value) {
+            addCriterion("vqi_state like", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotLike(String value) {
+            addCriterion("vqi_state not like", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIn(List<String> values) {
+            addCriterion("vqi_state in", values, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotIn(List<String> values) {
+            addCriterion("vqi_state not in", values, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateBetween(String value1, String value2) {
+            addCriterion("vqi_state between", value1, value2, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotBetween(String value1, String value2) {
+            addCriterion("vqi_state not between", value1, value2, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeIsNull() {
+            addCriterion("vqi_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeIsNotNull() {
+            addCriterion("vqi_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeEqualTo(String value) {
+            if(value == null ){
+                andTimeIsNull();
+            } else {
+                addCriterion("vqi_time =", value, "time");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeNotEqualTo(String value) {
+            if(value == null ){
+                andTimeIsNotNull();
+            } else {
+                addCriterion("vqi_time <>", value, "time");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeGreaterThan(String value) {
+            addCriterion("vqi_time >", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_time >=", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeLessThan(String value) {
+            addCriterion("vqi_time <", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeLessThanOrEqualTo(String value) {
+            addCriterion("vqi_time <=", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeLike(String value) {
+            addCriterion("vqi_time like", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeNotLike(String value) {
+            addCriterion("vqi_time not like", value, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeIn(List<String> values) {
+            addCriterion("vqi_time in", values, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeNotIn(List<String> values) {
+            addCriterion("vqi_time not in", values, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeBetween(String value1, String value2) {
+            addCriterion("vqi_time between", value1, value2, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andTimeNotBetween(String value1, String value2) {
+            addCriterion("vqi_time not between", value1, value2, "time");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlIsNull() {
+            addCriterion("vqi_url is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlIsNotNull() {
+            addCriterion("vqi_url is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlEqualTo(String value) {
+            if(value == null ){
+                andUrlIsNull();
+            } else {
+                addCriterion("vqi_url =", value, "url");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlNotEqualTo(String value) {
+            if(value == null ){
+                andUrlIsNotNull();
+            } else {
+                addCriterion("vqi_url <>", value, "url");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlGreaterThan(String value) {
+            addCriterion("vqi_url >", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_url >=", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlLessThan(String value) {
+            addCriterion("vqi_url <", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlLessThanOrEqualTo(String value) {
+            addCriterion("vqi_url <=", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlLike(String value) {
+            addCriterion("vqi_url like", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlNotLike(String value) {
+            addCriterion("vqi_url not like", value, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlIn(List<String> values) {
+            addCriterion("vqi_url in", values, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlNotIn(List<String> values) {
+            addCriterion("vqi_url not in", values, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlBetween(String value1, String value2) {
+            addCriterion("vqi_url between", value1, value2, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andUrlNotBetween(String value1, String value2) {
+            addCriterion("vqi_url not between", value1, value2, "url");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserIsNull() {
+            addCriterion("vqi_create_user is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserIsNotNull() {
+            addCriterion("vqi_create_user is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserEqualTo(String value) {
+            if(value == null ){
+                andCreateUserIsNull();
+            } else {
+                addCriterion("vqi_create_user =", value, "createUser");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserNotEqualTo(String value) {
+            if(value == null ){
+                andCreateUserIsNotNull();
+            } else {
+                addCriterion("vqi_create_user <>", value, "createUser");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserGreaterThan(String value) {
+            addCriterion("vqi_create_user >", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_create_user >=", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserLessThan(String value) {
+            addCriterion("vqi_create_user <", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserLessThanOrEqualTo(String value) {
+            addCriterion("vqi_create_user <=", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserLike(String value) {
+            addCriterion("vqi_create_user like", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserNotLike(String value) {
+            addCriterion("vqi_create_user not like", value, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserIn(List<String> values) {
+            addCriterion("vqi_create_user in", values, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserNotIn(List<String> values) {
+            addCriterion("vqi_create_user not in", values, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserBetween(String value1, String value2) {
+            addCriterion("vqi_create_user between", value1, value2, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateUserNotBetween(String value1, String value2) {
+            addCriterion("vqi_create_user not between", value1, value2, "createUser");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeIsNull() {
+            addCriterion("vqi_create_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeIsNotNull() {
+            addCriterion("vqi_create_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeEqualTo(String value) {
+            if(value == null ){
+                andCreateTimeIsNull();
+            } else {
+                addCriterion("vqi_create_time =", value, "createTime");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeNotEqualTo(String value) {
+            if(value == null ){
+                andCreateTimeIsNotNull();
+            } else {
+                addCriterion("vqi_create_time <>", value, "createTime");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeGreaterThan(String value) {
+            addCriterion("vqi_create_time >", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_create_time >=", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeLessThan(String value) {
+            addCriterion("vqi_create_time <", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeLessThanOrEqualTo(String value) {
+            addCriterion("vqi_create_time <=", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeLike(String value) {
+            addCriterion("vqi_create_time like", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeNotLike(String value) {
+            addCriterion("vqi_create_time not like", value, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeIn(List<String> values) {
+            addCriterion("vqi_create_time in", values, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeNotIn(List<String> values) {
+            addCriterion("vqi_create_time not in", values, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeBetween(String value1, String value2) {
+            addCriterion("vqi_create_time between", value1, value2, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateTimeNotBetween(String value1, String value2) {
+            addCriterion("vqi_create_time not between", value1, value2, "createTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumIsNull() {
+            addCriterion("vqi_sum is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumIsNotNull() {
+            addCriterion("vqi_sum is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumEqualTo(String value) {
+            if(value == null ){
+                andSumIsNull();
+            } else {
+                addCriterion("vqi_sum =", value, "sum");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andSumNotEqualTo(String value) {
+            if(value == null ){
+                andSumIsNotNull();
+            } else {
+                addCriterion("vqi_sum <>", value, "sum");
+            }
+            return (Criteria) this;
+        }
+
+        public Criteria andSumGreaterThan(String value) {
+            addCriterion("vqi_sum >", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumGreaterThanOrEqualTo(String value) {
+            addCriterion("vqi_sum >=", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumLessThan(String value) {
+            addCriterion("vqi_sum <", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumLessThanOrEqualTo(String value) {
+            addCriterion("vqi_sum <=", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumLike(String value) {
+            addCriterion("vqi_sum like", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumNotLike(String value) {
+            addCriterion("vqi_sum not like", value, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumIn(List<String> values) {
+            addCriterion("vqi_sum in", values, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumNotIn(List<String> values) {
+            addCriterion("vqi_sum not in", values, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumBetween(String value1, String value2) {
+            addCriterion("vqi_sum between", value1, value2, "sum");
+            return (Criteria) this;
+        }
+
+        public Criteria andSumNotBetween(String value1, String value2) {
+            addCriterion("vqi_sum not between", value1, value2, "sum");
+            return (Criteria) this;
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated do_not_delete_during_merge
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table vm_qrcode_inf
+     *
+     * @mbggenerated
+     */
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.betweenValue = true;
+        }
+    }
+}

+ 102 - 0
src/main/java/com/minpay/shouhuo/ApiAction.java

@@ -0,0 +1,102 @@
+package com.minpay.shouhuo;
+
+import com.google.zxing.WriterException;
+import com.minpay.common.bean.User;
+import com.minpay.common.constant.Constant;
+import com.minpay.common.format.IFormatService;
+import com.minpay.common.service.ILogService;
+import com.minpay.common.service.IPropertiesService;
+import com.minpay.common.service.IPublicService;
+import com.minpay.common.service.IQrcodeService;
+import com.minpay.common.service.impl.QrcodeServiceImpl;
+import com.minpay.common.util.*;
+import com.minpay.db.table.mapper.VmPersonInfMapper;
+import com.minpay.db.table.mapper.VmQrcodeInfMapper;
+import com.minpay.db.table.mapper.VmRechargeRuleMapper;
+import com.minpay.db.table.model.VmPersonInf;
+import com.minpay.db.table.model.VmPersonInfExample;
+import com.minpay.db.table.model.VmQrcodeInf;
+import com.minpay.db.table.own.mapper.PersonManageMapper;
+import com.minpay.db.table.own.mapper.SequenceMapper;
+import com.minpay.huicai.util.EquCodeCreateUtil;
+import com.startup.minpay.frame.business.IMINAction;
+import com.startup.minpay.frame.business.MINHttpServletRequestContext;
+import com.startup.minpay.frame.business.res.MINActionResult;
+import com.startup.minpay.frame.constant.IMINBusinessConstant;
+import com.startup.minpay.frame.constant.IMINTransactionEnum;
+import com.startup.minpay.frame.data.format.MINCopyFormat;
+import com.startup.minpay.frame.exception.MINBusinessException;
+import com.startup.minpay.frame.jdbc.MINRowBounds;
+import com.startup.minpay.frame.service.base.IMINDataBaseService;
+import com.startup.minpay.frame.service.base.Service;
+import com.startup.minpay.frame.session.MINSession;
+import com.startup.minpay.frame.target.MINAction;
+import com.startup.minpay.frame.target.MINComponent;
+import com.startup.minpay.frame.target.MINParam;
+import io.netty.util.internal.StringUtil;
+import net.sf.json.JSONObject;
+
+import javax.servlet.http.HttpServletResponse;
+import java.io.*;
+import java.text.ParseException;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 用户管理
+ * @author xbh
+ *
+ */
+@MINComponent
+public class ApiAction implements IMINAction {
+
+	/** 重定向(二维码)**/
+	public static final String REDIRECT = "redirect";
+
+	/**
+	 * 查询url
+	 */
+	@MINAction(value = REDIRECT, transaction = IMINTransactionEnum.CMT,session = false)
+	public static MINActionResult redirect(
+			@MINParam(key = "code") String code,
+			HttpServletResponse resp
+			) throws IOException, MINBusinessException {
+
+		MINActionResult res = new MINActionResult();
+		if(!StringUtil.isNullOrEmpty(code)){
+			VmQrcodeInf vmQrcodeInf =  Service.lookup(IMINDataBaseService.class).selectByPrimaryKey(VmQrcodeInfMapper.class, code);
+			String createTime = vmQrcodeInf.getCreateTime();  //创建时间
+			String sum = vmQrcodeInf.getSum();	//次数
+			String time = vmQrcodeInf.getTime(); //有效时间分钟
+			String state = vmQrcodeInf.getState(); //状态
+			String url = vmQrcodeInf.getUrl();
+			if(!state.equals("00")){
+				throw new MINBusinessException("二维码失效,请重新获取!");
+			}
+			if(!"-1".equals(sum) && "0".equals(sum)){
+				throw new MINBusinessException("二维码使用次数上限,请重新获取!");
+			}
+			if(!"-1".equals(time) ){
+				try {
+					String timeb = DateUtil.dateAddminute(createTime,time);
+					String nowTime = DateUtil.getCurrentDateTimeString();
+					long timebc = Long.parseLong(timeb);
+					long nowTimec = Long.parseLong(nowTime);
+					if(timebc < nowTimec){
+						throw new MINBusinessException("二维码异常,请重新获取");
+					}
+				} catch (ParseException e) {
+					throw new MINBusinessException("二维码异常,请重新获取");
+				}
+			}
+
+			resp.sendRedirect(url);
+		}else{
+			throw new MINBusinessException("数据异常");
+		}
+
+		return res;
+	}
+
+}

+ 13 - 3
src/main/java/com/minpay/shouhuo/PersManageAction.java

@@ -9,6 +9,8 @@ import com.minpay.common.format.IFormatService;
 import com.minpay.common.service.ILogService;
 import com.minpay.common.service.IPropertiesService;
 import com.minpay.common.service.IPublicService;
+import com.minpay.common.service.IQrcodeService;
+import com.minpay.common.service.impl.QrcodeServiceImpl;
 import com.minpay.common.util.*;
 import com.minpay.db.table.mapper.VmPersonInfMapper;
 import com.minpay.db.table.model.VmPersonInf;
@@ -34,6 +36,7 @@ import net.sf.json.JSONObject;
 
 import javax.servlet.http.HttpServletResponse;
 import java.io.*;
+import java.net.URLDecoder;
 import java.net.URLEncoder;
 import java.util.HashMap;
 import java.util.List;
@@ -319,7 +322,12 @@ public class PersManageAction implements IMINAction {
 		// 加密客户号
 		OutputStream outputStream = new FileOutputStream(file);
 		String openUrl = "https://open.weixin.qq.com/connect/oauth2/authorize?";
-		String redirect_uri = "http://xubing2.minpay.cc/adm/admin/wxuserManage/addUserTransfer.html?role=".concat(role).concat("&branchId=").concat(userId);
+
+		//String redirect_uri = "http://xubing2.minpay.cc/adm/admin/wxuserManage/addUserTransfer.html?role=".concat(role).concat("&branchId=").concat(userId);
+		String redirect_uri = Service.lookup(IPropertiesService.class)
+				.getSystemProperties().get(channel+"_ADM_URl").getKey();
+		redirect_uri = redirect_uri.concat("/admin/wxuserManage/addUserTransfer.html?role=").concat(role).concat("&branchId=").concat(userId);
+		redirect_uri = URLEncoder.encode(redirect_uri, "GBK");
 		//在微信的appId
 		String appId = Service.lookup(IPublicService.class).getSysParValue(channel + "_APP_ID");
 		//配置参数
@@ -334,11 +342,13 @@ public class PersManageAction implements IMINAction {
 		String admUrl = Service.lookup(IPropertiesService.class)
 				.getSystemProperties().get(channel+"_ADM_URl").getKey();
 		admUrl = admUrl.concat("/admin/h5AddUser.html?role=").concat(role).concat("&branchId=").concat(userId);;
+		IQrcodeService iQrcodeService = new QrcodeServiceImpl();
+		String urls = iQrcodeService.createQrCode("-1",paramStr.toString(),"-1");
 		//String urlString = URLEncoder.encode(, "GBK");
-
+		http://shjservices.personalpay.cn/adm
 		// 生成二维码图片到本地
 		try {
-			EquCodeCreateUtil.createQrCode(outputStream,admUrl,900,"JPEG");
+			EquCodeCreateUtil.createQrCode(outputStream,urls,900,"JPEG");
 		} catch (com.google.zxing.WriterException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();

+ 303 - 0
src/main/resources/com/minpay/db/table/mapper/VmQrcodeInfMapper.xml

@@ -0,0 +1,303 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.minpay.db.table.mapper.VmQrcodeInfMapper">
+  <resultMap id="BaseResultMap" type="com.minpay.db.table.model.VmQrcodeInf">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <id column="vqi_id" jdbcType="VARCHAR" property="id" />
+    <result column="vqi_state" jdbcType="VARCHAR" property="state" />
+    <result column="vqi_time" jdbcType="VARCHAR" property="time" />
+    <result column="vqi_url" jdbcType="VARCHAR" property="url" />
+    <result column="vqi_create_user" jdbcType="VARCHAR" property="createUser" />
+    <result column="vqi_create_time" jdbcType="VARCHAR" property="createTime" />
+    <result column="vqi_sum" jdbcType="VARCHAR" property="sum" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    vqi_id, vqi_state, vqi_time, vqi_url, vqi_create_user, vqi_create_time, vqi_sum
+  </sql>
+  <select id="selectByExample" parameterType="com.minpay.db.table.model.VmQrcodeInfExample" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from vm_qrcode_inf
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    select 
+    <include refid="Base_Column_List" />
+    from vm_qrcode_inf
+    where vqi_id = #{id,jdbcType=VARCHAR}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    delete from vm_qrcode_inf
+    where vqi_id = #{id,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.minpay.db.table.model.VmQrcodeInfExample">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    delete from vm_qrcode_inf
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.minpay.db.table.model.VmQrcodeInf">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    insert into vm_qrcode_inf (vqi_id, vqi_state, vqi_time, 
+      vqi_url, vqi_create_user, vqi_create_time, 
+      vqi_sum)
+    values (#{id,jdbcType=VARCHAR}, #{state,jdbcType=VARCHAR}, #{time,jdbcType=VARCHAR}, 
+      #{url,jdbcType=VARCHAR}, #{createUser,jdbcType=VARCHAR}, #{createTime,jdbcType=VARCHAR}, 
+      #{sum,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.minpay.db.table.model.VmQrcodeInf">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    insert into vm_qrcode_inf
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        vqi_id,
+      </if>
+      <if test="state != null">
+        vqi_state,
+      </if>
+      <if test="time != null">
+        vqi_time,
+      </if>
+      <if test="url != null">
+        vqi_url,
+      </if>
+      <if test="createUser != null">
+        vqi_create_user,
+      </if>
+      <if test="createTime != null">
+        vqi_create_time,
+      </if>
+      <if test="sum != null">
+        vqi_sum,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=VARCHAR},
+      </if>
+      <if test="state != null">
+        #{state,jdbcType=VARCHAR},
+      </if>
+      <if test="time != null">
+        #{time,jdbcType=VARCHAR},
+      </if>
+      <if test="url != null">
+        #{url,jdbcType=VARCHAR},
+      </if>
+      <if test="createUser != null">
+        #{createUser,jdbcType=VARCHAR},
+      </if>
+      <if test="createTime != null">
+        #{createTime,jdbcType=VARCHAR},
+      </if>
+      <if test="sum != null">
+        #{sum,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.minpay.db.table.model.VmQrcodeInfExample" resultType="java.lang.Integer">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    select count(*) from vm_qrcode_inf
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update vm_qrcode_inf
+    <set>
+      <if test="record.id != null">
+        vqi_id = #{record.id,jdbcType=VARCHAR},
+      </if>
+      <if test="record.state != null">
+        vqi_state = #{record.state,jdbcType=VARCHAR},
+      </if>
+      <if test="record.time != null">
+        vqi_time = #{record.time,jdbcType=VARCHAR},
+      </if>
+      <if test="record.url != null">
+        vqi_url = #{record.url,jdbcType=VARCHAR},
+      </if>
+      <if test="record.createUser != null">
+        vqi_create_user = #{record.createUser,jdbcType=VARCHAR},
+      </if>
+      <if test="record.createTime != null">
+        vqi_create_time = #{record.createTime,jdbcType=VARCHAR},
+      </if>
+      <if test="record.sum != null">
+        vqi_sum = #{record.sum,jdbcType=VARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update vm_qrcode_inf
+    set vqi_id = #{record.id,jdbcType=VARCHAR},
+      vqi_state = #{record.state,jdbcType=VARCHAR},
+      vqi_time = #{record.time,jdbcType=VARCHAR},
+      vqi_url = #{record.url,jdbcType=VARCHAR},
+      vqi_create_user = #{record.createUser,jdbcType=VARCHAR},
+      vqi_create_time = #{record.createTime,jdbcType=VARCHAR},
+      vqi_sum = #{record.sum,jdbcType=VARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.minpay.db.table.model.VmQrcodeInf">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update vm_qrcode_inf
+    <set>
+      <if test="state != null">
+        vqi_state = #{state,jdbcType=VARCHAR},
+      </if>
+      <if test="time != null">
+        vqi_time = #{time,jdbcType=VARCHAR},
+      </if>
+      <if test="url != null">
+        vqi_url = #{url,jdbcType=VARCHAR},
+      </if>
+      <if test="createUser != null">
+        vqi_create_user = #{createUser,jdbcType=VARCHAR},
+      </if>
+      <if test="createTime != null">
+        vqi_create_time = #{createTime,jdbcType=VARCHAR},
+      </if>
+      <if test="sum != null">
+        vqi_sum = #{sum,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where vqi_id = #{id,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.minpay.db.table.model.VmQrcodeInf">
+    <!--
+      WARNING - @mbggenerated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update vm_qrcode_inf
+    set vqi_state = #{state,jdbcType=VARCHAR},
+      vqi_time = #{time,jdbcType=VARCHAR},
+      vqi_url = #{url,jdbcType=VARCHAR},
+      vqi_create_user = #{createUser,jdbcType=VARCHAR},
+      vqi_create_time = #{createTime,jdbcType=VARCHAR},
+      vqi_sum = #{sum,jdbcType=VARCHAR}
+    where vqi_id = #{id,jdbcType=VARCHAR}
+  </update>
+</mapper>

+ 0 - 1
src/main/webapp/admin/wxuserManage/addUserwx.html

@@ -45,7 +45,6 @@
             });
 
            form.on('radio(role)', function (data) {
-                alert(JSON.stringify(data));
                 $.request({
                     action : '../../PersManageAction/createQrCode',
                     data : {