my_income.html
4.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="../assets/css/swiper-3.4.2.min.css">
<link rel="stylesheet" href="//at.alicdn.com/t/font_724456_0m7h09j73i3.css">
<script type="text/javascript" src="../assets/js/fontsize.js"></script>
<link rel="stylesheet" href="../assets/css/weui.min.css">
<link rel="stylesheet" href="../assets/css/style.css">
<title>收入记录</title>
<style>
body {
background-color: #f7f7f7;
}
</style>
</head>
<body>
<div class="mypay_top" style="background-image: url('../assets/imgs/bg.png')">
<div class="mypay_title">收入总计</div>
<div class="all_income">全部记录</div>
<div class="mymoney">
<span class="money_span">0.00</span><span>元</span>
</div>
</div>
<div class="income_next">
<div class="income_left">
<div style="position: relative">
<div class="income_icon">
<img src="../assets/imgs/income_icon.png" alt="">
</div>
<input type="text" placeholder="开始时间" id="txt_dateStart">
</div>
<div style="position: relative">
<input type="text" placeholder="结束时间" id="txt_dateEnd">
<div class="income_icon">
<img src="../assets/imgs/income_icon.png" alt="">
</div>
</div>
</div>
<div class="choose">检索</div>
</div>
<div class="income_item">
<div class="income_itemleft">
<div>收入</div>
<div class="income_time">2018-3-27</div>
</div>
<div class="income_itemright">
+ 15
</div>
</div>
<div class="income_item">
<div class="income_itemleft">
<div>收入</div>
<div class="income_time">2018-3-27</div>
</div>
<div class="income_itemright">
+ 15
</div>
</div>
<div class="income_item">
<div class="income_itemleft">
<div>收入</div>
<div class="income_time">2018-3-27</div>
</div>
<div class="income_itemright">
+ 15
</div>
</div>
<script type="text/javascript" src="../assets/js/jquery-2.1.0.js"></script>
<script type="text/javascript" src="../assets/js/weui.min.js"></script>
<script type="text/javascript" src="../assets/js/Augly_Verification.js"></script>
<script type="text/javascript" src="../assets/js/common.js"></script>
<script>
$('#txt_dateStart').on('focus', function () {
var dt = new Date();
var df= [dt.getFullYear(), (dt.getMonth() + 1), dt.getDate()];
var id=dt.getFullYear()+""+dt.getMonth() +""+dt.getDate()+""+dt.getHours()+""+ dt.getMinutes()+""+dt.getSeconds();
var value=$.trim($("#txt_dateStart").val());
if(value!="")
{
var arrays = value.split("-");
df= [parseInt(arrays[0]), parseInt(arrays[1]), parseInt(arrays[2])];
}
weui.datePicker({
id: "start"+id,
start: 2000,
end: dt.getFullYear()+20,
defaultValue:df,
onConfirm: function (result) {
$("#txt_dateStart").val(result[0].label.replace("年","-") + result[1].label.replace("月","-") + result[2].label.replace("日",""));
$("#txt_dateEnd").val("");
}
});
});
//结束日期
$('#txt_dateEnd').on('focus', function () {
var dt = new Date();
var df = [dt.getFullYear(), (dt.getMonth() + 1), dt.getDate()];
var id = dt.getFullYear() + "" + dt.getMonth() + "" + dt.getDate() + "" + dt.getHours() + "" + dt.getMinutes() + "" + dt.getSeconds();
var value = $.trim($("#txt_dateEnd").val());
if (value != "") {
var arrays = value.split("-");
df = [parseInt(arrays[0]), parseInt(arrays[1]), parseInt(arrays[2])];
}
var dfStart = "2000";
var startVal = $.trim($("#txt_dateStart").val());
if (startVal != "") {
dfStart = startVal;
}
var dts = dfStart.split('-');
var std;
if(dts.length==1)
{
std=new Date(dts[0],1,1);
}else{
std=new Date(dts[0],dts[1],dts[2]);
}
weui.datePicker({
id: "end" + id,
start: std,
end: dt.getFullYear() + 2,
defaultValue: df,
onConfirm: function (result) {
$("#txt_dateEnd").val(result[0].label.replace("年", "-") + result[1].label.replace("月", "-") + result[2].label.replace("日", ""));
}
});
});
</script>
</body>
</html>