日期:2014-05-16 浏览次数:20491 次
$("input:radio[name='status']").each(function() {
var v = $(this).val();
if (v== '1') {
$(this).attr("checked", "checked");
}
});
//初始化日期控件
$('#selectDate').datepick({
yearRange: '2008:2099',
dateFormat: 'yy-mm-dd',
prevText:'前一月',
nextText:'后一月',
closeText:'关闭',
clearText:'清除',
monthNames:['1月','2月','3月','4月','5月','6月','7月','8月','9月','10月','11月','12月']});
http://api.showji.com/Locating/default.aspx?m=15084975782&output=json&callback=querycallback
querycallback({
"Mobile": "15084975782",
"QueryResult": "True",
"Province": "湖南",
"City": "长沙",
"AreaCode": "0731",
"PostCode": "410000",
"Corp": "中国移动",
"Card": "GSM"
});
$(".trbox").click(function(){
var obj = $(this);
var box = obj.find("input:type='checkbox'");
if (box.attr('checked')) {
box.attr('checked',false);
} else {
box.attr('checked',true);
}
});
$(".boxClass").click(function(event){
event.stopPropagation();
});
var mod = $(".mod");
mod.click(function(){
var obj = $(this);
var td = obj.parent().parent().children(".inputClass");
tdValue = $.trim(td.text());
var input = $("<input type='text' style='color:#148CDF;' value='" + tdValue + "' />"); // 文本框的HTML代码
td.html(input); // 当前td的内容变为文本框
input.click(function() {
return false;
});
// 设置文本框的样式
input.height(td.height()-10); //文本框的高度为当前td单元格的高度
input.css("margin-left","-3px");
input.width("100px"); // 宽度为当前td单元格的宽度
input.css("font-size", "12px"); // 文本框的内容文字大小为14px
input.css("text-align", "center"); // 文本居中
});