Coder Social home page Coder Social logo

cmfun's Introduction

CMFun

基于jQuery封装的一些常用的Function

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

功能:下拉分页功能

函数名: CMFun.draw(fn, list, count, container)

参数:
fn: 执行执行绘制下拉的函数
list: 绘制数据json数组 [{}, {}]
count: 绘制数据json数组长度
container: 分页Page所在Div的jQuery对象

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

功能:鼠标悬浮浮层功能

函数名: CMFun.Hover.init(tid, eid, cfg)

参数:
tid:目标base对象的id
eid:悬浮浮层对象的id
cfg:json的配置参数,可选,{topFix: (Int), leftFix: (Int)}

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

功能:模态弹出层弹出功能

函数名:$(xxx).mask() $(xxx).unmask()

参数:
extend扩展了jQ的$.fn的方法
$().mask(): 弹出层弹出
$().unmask(): 弹出层收起

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

功能:时间格式的Format

函数名: Date .Format('yyyy-MM-dd hh:mm:ss q S')

参数:
yyyy:年份
MM:月份
dd:天数
hh:小时
mm:分钟
ss:秒钟
q:季度
S:millisecond

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

功能:Submit Form 提交表单

函数名:CMFun.FormSubmit({})

参数:
url: Action的地址
method: POST/GET
target: _blank/_self
data: data数据格式为json格式

也可以将整个form 的html字符串传入,或者不包含form的html字符串也可以当data传入

☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆☆

cmfun's People

Contributors

dstar2013 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.