-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
159 lines (154 loc) · 8.42 KB
/
index.html
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
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
<!DOCTYPE html>
<html lang="ir" dir="rtl">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="css/bootstrap.rtl.min.css">
<link rel="stylesheet" href="css/bootstrap-utilities.rtl.min.css">
<link rel="stylesheet" href="css/bootstrap-reboot.rtl.min.css">
<link rel="stylesheet" href="css/bootstrap-grid.rtl.min.css">
<link rel="stylesheet" href="css/dataTables.bootstrap5.min.css">
<link rel="stylesheet" href="css/fontiran.css">
<link rel="stylesheet" href="css/style.css">
<title>مدیریت دخل و خرج</title>
</head>
<body>
<img class="header position-absolute top-0" src="img/header.jpg" alt="header">
<div class="container mt-content">
<div class="d-flex justify-content-between">
<div class="col-md-6">
<div class="card h-100 px-4 pt-3">
<div class="card-body">
<form id="form">
<div class="mb-3">
<div class="d-flex justify-content-between">
<div class="col-md-6 pe-2">
<div class="form-check fs-5 radio-button-sizing">
<input class="form-check-input" type="radio" name="radio" id="radio-button-income" onclick="document.getElementById('char').classList.add('text-success'); document.getElementById('char').classList.remove('text-danger');">
<label class="form-check-label" for="radio-button-income">
درآمد
</label>
</div>
</div>
<div class="col-md-6 ps-2">
<div class="form-check fs-5 radio-button-sizing">
<input class="form-check-input" type="radio" name="radio" id="radio-button-cost" onclick="document.getElementById('char').classList.add('text-danger'); document.getElementById('char').classList.remove('text-success');" checked>
<label class="form-check-label" for="radio-button-cost">
هزینه
</label>
</div>
</div>
</div>
</div>
<div class="mb-3">
<label for="price" class="form-label fw-bold">مبلغ :</label>
<input type="number" class="form-control" id="price" name="price" onchange="document.getElementById('char').innerHTML = Num2persian(this.value)" required>
<div class="text-muted">
<span id="char" class="text-danger fw-bold">صفر</span> تومان
</div>
</div>
<div class="mb-3">
<label for="exampleFormControlInput1" class="form-label fw-bold">تاریخ :</label>
<div class="d-flex justify-content-between">
<input type="number" name="day" class="form-control" placeholder="روز" required>
<input type="number" name="month" class="form-control mx-3" placeholder="ماه" required>
<input type="number" name="year" class="form-control" placeholder="سال" required>
</div>
</div>
<div class="mb-3">
<label for="exampleFormControlTextarea1" class="form-label fw-bold">توضیحات :</label>
<textarea name="desc" class="form-control" id="exampleFormControlTextarea1" rows="2"></textarea>
</div>
<div class="d-grid mb-3">
<input id="btn" type="submit" class="btn btn-lg btn-success" value="ثبت دخل و خرج">
</div>
</form>
</div>
</div>
</div>
<div class="col-md-6 padding-right">
<div class="card size-total-price">
<div class="card-body d-flex fs-4">
<div class="col-md-6 d-flex justify-content-center align-items-center">
<div class="text-center">
<div class="">درآمد</div>
<div id="total-income" class="text-success">۰</div>
</div>
</div>
<div class="col-md-6 d-flex justify-content-center align-items-center border-dashed-right">
<div class="text-center">
<div class="">مخارج</div>
<div id="total-cost" class="text-danger">۰</div>
</div>
</div>
</div>
</div>
<div class="card mt-3">
<div class="card-body">
<canvas id="myChart" class="my-2"></canvas>
</div>
</div>
</div>
</div>
<div class="card mt-3 mb-5">
<div class="card-body">
<table id="dataTable" class="table table-striped" style="width:100%">
<thead>
<tr>
<th>ردیف</th>
<th>مبلغ</th>
<th>تاریخ</th>
<th>نوع هزینه</th>
<th>توضیحات</th>
</tr>
</thead>
<tbody id="table-body">
</tbody>
</table>
</div>
</div>
</div>
<div class="modal fade" id="deleteModal" tabindex="-1" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">حذف</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<span>آیا مطمئن هستید؟</span>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">بستن</button>
<button id="btn_delete" type="button" class="btn btn-danger">حذف</button>
</div>
</div>
</div>
</div>
<div class="modal fade" id="descModal" tabindex="-1" aria-labelledby="descModalLabel" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="descModalLabel">توضیحات</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<span id="desc_text"></span>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">بستن</button>
</div>
</div>
</div>
</div>
<script src="js/jquery-3.5.1.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/bootstrap.esm.min.js"></script>
<script src="js/bootstrap.bundle.min.js"></script>
<script src="js/jquery.dataTables.min.js"></script>
<script src="js/dataTables.bootstrap5.min.js"></script>
<script src="js/chart.min.js"></script>
<script src="js/num2persian.js" type="text/javascript"></script>
<script src="js/main.js"></script>
<script src="js/script.js"></script>
</body>
</html>