微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

js插件dropload上拉下滑加载数据实例解析

本文实例为大家分享了dropload插件上拉下滑加载数据的具体代码,供大家参考,具体内容如下

效果图:

1.导入js

dropload.min.js zepto.min.js

2.后台查询

rush:js;"> /** * 我找的劵 * * @return */ @Action("IFindTicket") public String IFindTicket() { try { FuTransaction transaction = fuTransactionService.findByUserId(userId); Map map = new HashMap(); map.put("transactionId",transaction == null ? 0L : transaction.getId()); List accounts = fuStockAccountService.findAccountByMap(0,5,map); this.getActionContext().put("accounts",accounts); } catch (Exception e) { e.printstacktrace(); logger.equals(e); } return SUCCESS; }

/**

  • 我找的劵数据
  • @return
    */
    @Action("findTicketData")
    public String findTicketData() {
    try {
    FuTransaction transaction = fuTransactionService.findByUserId(userId);
    Map<String,Integer.MAX_VALUE,map);
    JSONObject json = new JSONObject();
    JSONArray array = new JSONArray();
    if (accounts.size() > 0) {
    for (FuStockAccount account : accounts) {
    JSONObject obj = new JSONObject();
    obj.put("id",account.getId());
    obj.put("openEquity",account.getopenEquity());
    obj.put("capitalAccount",account.getCapitalAccount());
    obj.put("transactionStatus",account.getTransactionStatus());
    obj.put("status",account.getTransactionStatus() == 0 ? "正在操作" : "已退劵");
    obj.put("available",new DecimalFormat("#,###,##0.00").format(account.getAvailable() == null ? 0 : account.getAvailable()));
    obj.put("ableMoney",##0.00").format(account.getAbleMoney() == null ? 0 : account.getAbleMoney()));
    obj.put("createTime",new SimpleDateFormat("yyyy.MM.dd").format(account.getCreateTime()));
    array.add(obj);
    }
    }
    json.put("array",array);
    write(json.toString());
    } catch (Exception e) {
    e.printstacktrace();
    logger.error(e);
    }
    return null;
    }

3.页面插件的使用

rush:xhtml;"> <Meta http-equiv="X-UA-Compatible" content="IE=Edge"> <Meta name="viewport" content="width=device-width,height=device-height,inital-scale=1.0,maximum-scale=1.0,user-scalable=no;"> <Meta name="apple-mobile-web-app-capable" content="yes"> <Meta name="apple-mobile-web-app-status-bar-style" content="black"> <Meta name="format-detection" content="telephone=no"> <%@ include file="../common/meta.jsp" %> <%@ include file="/WEB-INF/include/tagtld.jsp"%> ${title}-我找的券 <%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%> <%@ include file="../common/css.jsp"%>
irstTd">
可用资金:

以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持编程之家。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐