You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

637 lines
32 KiB

3 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <!DOCTYPE html>
  2. <html lang="en" dir="">
  3. <html xmlns:th="http://www.thymeleaf.org">
  4. <head th:replace="~{fragments/modules/base/head :: head}"></head>
  5. <body>
  6. <!--[if lt IE 8]>
  7. <p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
  8. <![endif]-->
  9. <div class="wrapper">
  10. <!-- header top menu Start -->
  11. <header th:replace="~{fragments/modules/base/header :: header}"></header>
  12. <!-- header top menu end -->
  13. <div class="page-wrap">
  14. <!--=============== Left Menu side Start ===================-->
  15. <div th:replace="~{fragments/modules/base/menu :: menu}"></div>
  16. <!--=============== Left side End ================-->
  17. <div class="main-content">
  18. <div class="container-fluid">
  19. <div class="page-header">
  20. <div class="row align-items-end">
  21. <div class="col-lg-4">
  22. <div class="page-header-title">
  23. <i class='fa fa-check-circle' style='font-size:24px; color: #1aafd4'></i>
  24. <div class="d-inline">
  25. <h5>Accepted Info</h5>
  26. <span>Pet Registration</span>
  27. </div>
  28. </div>
  29. </div>
  30. <div class="col-lg-5">
  31. <div class="content">
  32. <div class="block block-rounded">
  33. <div class="block-header block-header-default" style="display: block;">
  34. <form class="row" action="javascript:getbydate()">
  35. <div class="row">
  36. <div class="col-4">
  37. <input type="date" th:value="${fromDate}" class="form-control" name="FromDate" id="fromdate" data-date-format="yyyy-mm-dd" />
  38. </div>
  39. <div class="col-4">
  40. <input type="date" th:value="${toDate}" class="form-control" name="ToDate" id="todate" data-date-format="yyyy-mm-dd" />
  41. </div>
  42. <div class="col-2 p-0 text-center">
  43. <button type="submit" class="btn btn-sm btn-primary" name="submit" id="submit" onclick="getbydate()" >Submit</button>
  44. <br>
  45. </div>
  46. <div class="col-2 p-0 text-center">
  47. <button class="btn btn-danger" onclick="resetDate()" name="reset" type="reset">Reset</button>
  48. </div>
  49. </div>
  50. </div>
  51. </form>
  52. </div>
  53. </div>
  54. </div>
  55. <div class="col-lg-3">
  56. <nav class="breadcrumb-container" aria-label="breadcrumb">
  57. <ol class="breadcrumb">
  58. <li class="breadcrumb-item">
  59. <a href="/index"><i class="ik ik-home"></i></a>
  60. </li>
  61. <li class="breadcrumb-item">Pet Registration</li>
  62. <li class="breadcrumb-item">Accepted</li>
  63. </ol>
  64. </nav>
  65. </div>
  66. </div>
  67. </div>
  68. <hr>
  69. <div class="row">
  70. <div class="col-md-12">
  71. <div class="card">
  72. <div class="card-block">
  73. <div>
  74. <table id="assetDatatable" class="table table-striped table-bordered table-hover dataTable" role="grid" width="99.5%">
  75. <thead class="thead-dark">
  76. <tr role="row">
  77. <th>S.No</th>
  78. <th>Name</th>
  79. <th>Type</th>
  80. <th>Breed</th>
  81. <th>sex</th>
  82. <th>pet photo</th>
  83. <th>Rabies certi</th>
  84. <th>Application photo</th>
  85. <th>Address Proof</th>
  86. <th class="text-center" width="10%">Status</th>
  87. <th class="text-center text-center no-sort" width="10%">Action</th>
  88. </tr>
  89. </theadclass="thead-dark">
  90. <tbody>
  91. <tr th:each="list, i : ${petlist}" class="${petlist}" >
  92. <td th:text="${i.count}">0</td>
  93. <td class="text-center" th:text="${list.petname}"></td>
  94. <td th:text="${list.species}" ></td>
  95. <td th:text="${list.breed}"></td>
  96. <td th:text="${list.gender}"></td>
  97. <!-- <td th:text="${list.gender}"></td>-->
  98. <td class="text-center">
  99. <button type="button" th:onclick="petimg([[${list.mobilenum}]],[[${list.uniqueid}]])" class="btn btn-primary">
  100. view
  101. </button>
  102. </td>
  103. <td class="text-center">
  104. <button type="button" th:onclick="certificateimg([[${list.mobilenum}]],[[${list.uniqueid}]])" class="btn btn-primary">
  105. view
  106. </button>
  107. </td>
  108. <td class="text-center">
  109. <button type="button" th:onclick="applicantimg([[${list.mobilenum}]],[[${list.uniqueid}]])" class="btn btn-primary">
  110. view
  111. </button>
  112. </td>
  113. <td class="text-center">
  114. <button type="button" th:onclick="proofimg([[${list.mobilenum}]],[[${list.uniqueid}]])" class="btn btn-primary">
  115. view
  116. </button>
  117. </td>
  118. <td >
  119. <p >
  120. <!-- <span class="badge bg-success" th:onclick="accept([[${list.uniqueid}]])">Accept</span> -->
  121. <span class="badge bg-warning" style="cursor: pointer;" th:onclick="reject([[${list.uniqueid}]])">Accepted</span>
  122. </p>
  123. </td>
  124. <td class="text-center">
  125. <!-- <a th:href="@{#}" th:onclick="return callview( [[${list.status}]] );" data-bs-toggle="tooltip" data-bs-animation="true" data-bs-placement="top" title="View Pet info"><i class="far fa-bookmark" style="font-size: 18px;"></i></a> -->
  126. <a th:onclick="viewOwner( [[${list.mobilenum}]] );" data-bs-toggle="tooltip" data-bs-animation="true" data-bs-placement="top" title="View PetOwner info"><i class="fa-regular fa-user" style="font-size: 18px;"></i></a>
  127. </td>
  128. </tr>
  129. </tbody>
  130. <tfoot class="thead-dark">
  131. <tr>
  132. <th>S.No</th>
  133. <th>Name</th>
  134. <th>Type</th>
  135. <th>Breed</th>
  136. <th>sex</th>
  137. <th>pet photo</th>
  138. <th>Rabies certi</th>
  139. <th>Application photo</th>
  140. <th>Address Proof</th>
  141. <th class="text-center" width="10%">Status</th>
  142. <th class="text-center text-center no-sort" width="10%">Action</th>
  143. </tr>
  144. </tfoot>
  145. </table>
  146. </div>
  147. </div>
  148. </div>
  149. </div>
  150. </div>
  151. </div>
  152. </div>
  153. </div>
  154. <footer th:replace="~{fragments/modules/base/footer :: footer}"></footer>
  155. </div>
  156. <!-- Modal image -->
  157. <div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterLabel" aria-hidden="true">
  158. <div class="modal-dialog modal-dialog-centered modal-lg" role="document">
  159. <div class="modal-content">
  160. <div class="modal-header">
  161. <h5 class="modal-title" id="exampleModalCenterLabel">Photo</h5>
  162. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  163. </div>
  164. <div class="modal-body">
  165. <img alt="" id="myImg" src="" style="width:100%">
  166. </div>
  167. <div class="modal-footer">
  168. <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
  169. </div>
  170. </div>
  171. </div>
  172. </div>
  173. <!-- end of modal image -->
  174. <!-- Pet Info Form -->
  175. <div class="modal fade" id="rejectForm" tabindex="-1" role="dialog" aria-labelledby="rejectFormCenterLabel" aria-hidden="true">
  176. <div class="modal-dialog modal-dialog-centered modal-lg" role="document">
  177. <div class="modal-content">
  178. <div class="modal-header">
  179. <h5 class="modal-title" id="rejectFormCenterLabel">Pet Information</h5>
  180. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  181. </div>
  182. <div class="modal-body">
  183. <div class="row">
  184. <input type="hidden" class="form-control text-center" name="uniqid" id="uniqid" disabled />
  185. <div class="col-xl-6 col-md-12"> <strong>Pet Name</strong>
  186. <p class="text-muted form-control showInputValue" id="petna"></p>
  187. </div>
  188. <div class="col-xl-6 col-md-12"> <strong>Pet Type</strong>
  189. <p class="text-muted form-control showInputValue" id="speci" ></p>
  190. </div>
  191. <div class="col-xl-6 col-md-12"> <strong>Breed</strong>
  192. <p class="text-muted form-control showInputValue" id="bre" ></p>
  193. </div>
  194. <div class="col-xl-6 col-md-12"> <strong>Sex</strong>
  195. <p class="text-muted form-control showInputValue" id="gend" ></p>
  196. </div>
  197. <div class="col-xl-6 col-md-12"> <strong>Age</strong>
  198. <p class="text-muted form-control showInputValue" id="age"></p>
  199. </div>
  200. <div class="col-xl-6 col-md-12"> <strong>ARV Date</strong>
  201. <p class="text-muted form-control showInputValue" id="arvd"></p>
  202. </div>
  203. <div class="col-xl-6 col-md-12"> <strong>Last Date Of De-Worming</strong>
  204. <p class="text-muted form-control showInputValue" id="dewormdate"></p>
  205. </div>
  206. <div class="col-xl-6 col-md-12"> <strong>Other Vaccination Given</strong>
  207. <p class="text-muted form-control showInputValue" id="othervac"></p>
  208. </div>
  209. <div class="col-xl-6 col-md-12"> <strong>Previous License No</strong>
  210. <p class="text-muted form-control showInputValue" id="previoslicenseNo"></p>
  211. </div>
  212. <div class="col-xl-6 col-md-12"> <strong>Name of Veterinary doctor</strong>
  213. <p class="text-muted form-control showInputValue" id="VeterinaryConsultant"></p>
  214. </div>
  215. <div class="col-xl-6 col-md-12"> <strong>Veterinary Council Number</strong>
  216. <p class="text-muted form-control showInputValue" id="TNVCNo"></p>
  217. </div>
  218. <div class="col-xl-6 col-md-12"> <strong>Register Date</strong>
  219. <p class="text-muted form-control showInputValue" id="registerdate"></p>
  220. </div>
  221. </div>
  222. </div>
  223. </div>
  224. </div>
  225. </div>
  226. <!-- owner Info -->
  227. <div class="modal fade" id="ownerForm" tabindex="-1" role="dialog" aria-labelledby="ownerFormCenterLabel" aria-hidden="true">
  228. <div class="modal-dialog modal-dialog-centered modal-lg" role="document">
  229. <div class="modal-content">
  230. <div class="modal-header">
  231. <h5 class="modal-title" id="ownerFormCenterLabel">Pet Owner information</h5>
  232. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  233. </div>
  234. <div class="modal-body">
  235. <div class="row">
  236. <input type="hidden" class="form-control text-center" name="uniqid" id="uniqid" disabled />
  237. <div class="col-xl-6 col-md-12"> <strong>Tittle</strong>
  238. <p class="text-muted form-control showInputValue" id="title"></p>
  239. </div>
  240. <div class="col-xl-6 col-md-12"> <strong>Pet Owner Name</strong>
  241. <p class="text-muted form-control showInputValue" id="fname" ></p>
  242. </div>
  243. <div class="col-xl-6 col-md-12"> <strong>Door No</strong>
  244. <p class="text-muted form-control showInputValue" id="doornumber" ></p>
  245. </div>
  246. <div class="col-xl-6 col-md-12"> <strong>Street</strong>
  247. <p class="text-muted form-control showInputValue" id="street" ></p>
  248. </div>
  249. <div class="col-xl-6 col-md-12"> <strong>Area</strong>
  250. <p class="text-muted form-control showInputValue" id="area"></p>
  251. </div>
  252. <div class="col-xl-6 col-md-12"> <strong>City</strong>
  253. <p class="text-muted form-control showInputValue" id="city"></p>
  254. </div>
  255. <div class="col-xl-6 col-md-12"> <strong>Pincode</strong>
  256. <p class="text-muted form-control showInputValue" id="pincode"></p>
  257. </div>
  258. <div class="col-xl-6 col-md-12"> <strong>Zone</strong>
  259. <p class="text-muted form-control showInputValue" id="zone"></p>
  260. </div>
  261. <div class="col-xl-6 col-md-12"> <strong>Ward</strong>
  262. <p class="text-muted form-control showInputValue" id="ward"></p>
  263. </div>
  264. <div class="col-xl-6 col-md-12"> <strong>Contact No</strong>
  265. <p class="text-muted form-control showInputValue" id="phone"></p>
  266. </div>
  267. <div class="col-xl-6 col-md-12"> <strong>Email Id</strong>
  268. <p class="text-muted form-control showInputValue" id="email"></p>
  269. </div>
  270. </div>
  271. </div>
  272. </div>
  273. </div>
  274. </div>
  275. <!-- End owner Info -->
  276. <!-- Script -->
  277. <!-- <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script> -->
  278. <!-- <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"> -->
  279. <div th:replace="~{fragments/modules/base/app_module_menu_box :: div}"></div>
  280. <script th:replace="~{fragments/modules/base/script :: script}"></script>
  281. <script type="text/javascript">
  282. $(document).ready(function() {
  283. // DataTables buttons configuration
  284. var buttons = [
  285. {
  286. extend: 'pageLength',
  287. className: 'btn btn-warning'
  288. },
  289. {
  290. title: 'Data export',
  291. extend: 'copyHtml5',
  292. text: 'Copy',
  293. className: 'btn btn-secondary',
  294. id: 'copyBtn'
  295. },
  296. {
  297. extend: 'excelHtml5',
  298. text: 'Excel',
  299. className: 'btn btn-secondary',
  300. id: 'excelBtn'
  301. },
  302. {
  303. extend: 'csvHtml5',
  304. text: 'CSV',
  305. className: 'btn btn-secondary',
  306. id: 'csvBtn'
  307. },
  308. {
  309. extend: 'pdfHtml5',
  310. text: 'PDF',
  311. className: 'btn btn-secondary',
  312. id: 'pdfBtn'
  313. },
  314. ];
  315. $('#assetDatatable').DataTable( {
  316. dom: 'Bftip',
  317. columnDefs: [
  318. { targets: 'no-sort', orderable: false }
  319. ],
  320. lengthMenu: [
  321. [ 50, 100, 200, 500, -1 ],
  322. [ '50 rows', '100 rows', '200 rows','500 rows', 'Show all' ]
  323. ],
  324. scrollY: '50vh',
  325. fixedColumns: {
  326. left: 1,
  327. right: 1
  328. },
  329. buttons: [buttons],
  330. responsive: true,
  331. searching: true,
  332. select: false,
  333. processing: false,
  334. } );
  335. $('#searchInput').on('keyup', function() {
  336. dataTable.search(this.value).draw();
  337. });
  338. } );
  339. function petimg(mobno,uniqueid){
  340. $.ajax({
  341. type: "GET",
  342. url: '/api/pet/getpetimg',
  343. data: {
  344. 'mobno':mobno,
  345. 'uniqueid':uniqueid
  346. },
  347. success: function(x) {
  348. document.getElementById("myImg").src ="data:image/jpeg;base64,"+x;
  349. }
  350. });
  351. $('#exampleModal').modal({
  352. backdrop: 'static',
  353. keyboard: false
  354. });
  355. $('#exampleModal').modal('show');
  356. return false;
  357. }
  358. function applicantimg(mobno,uniqueid){
  359. $.ajax({
  360. type: "GET",
  361. url: '/api/pet/getapplicantimg',
  362. data: {
  363. 'mobno':mobno,
  364. 'uniqueid':uniqueid
  365. },
  366. success: function(x) {
  367. document.getElementById("myImg").src ="data:image/jpeg;base64,"+x;
  368. }
  369. });
  370. $('#exampleModal').modal({
  371. backdrop: 'static',
  372. keyboard: false
  373. });
  374. $('#exampleModal').modal('show');
  375. //document.getElementById("myImg").src ="data:image/jpeg;base64,"+x.applicantphoto;
  376. }
  377. function certificateimg(mobno,uniqueid){
  378. $.ajax({
  379. type: "GET",
  380. url: '/api/pet/getvacimg',
  381. data: {
  382. 'mobno':mobno,
  383. 'uniqueid':uniqueid
  384. },
  385. success: function(x) {
  386. document.getElementById("myImg").src ="data:image/jpeg;base64,"+x;
  387. }
  388. });
  389. $('#exampleModal').modal({
  390. backdrop: 'static',
  391. keyboard: false
  392. });
  393. $('#exampleModal').modal('show');
  394. //document.getElementById("myImg").src ="data:image/jpeg;base64,"+x.rabiesvacCerti;
  395. }
  396. function proofimg(mobno,uniqueid){
  397. $.ajax({
  398. type: "GET",
  399. url: '/api/pet/getaddproofimg',
  400. data: {
  401. 'mobno':mobno,
  402. 'uniqueid':uniqueid
  403. },
  404. success: function(x) {
  405. document.getElementById("myImg").src ="data:image/jpeg;base64,"+x;
  406. }
  407. });
  408. $('#exampleModal').modal({
  409. backdrop: 'static',
  410. keyboard: false
  411. });
  412. $('#exampleModal').modal('show');
  413. //document.getElementById("myImg").src ="data:image/jpeg;base64,"+x.addressproof;
  414. }
  415. function accept(){
  416. let id = document.getElementById("uniqid").value;
  417. Swal.fire({
  418. title: 'Do you want to Accept this Pet ?',
  419. showDenyButton: true,
  420. showCancelButton: true,
  421. confirmButtonText: 'YES',
  422. denyButtonText: `NO`,
  423. }).then((result) => {
  424. /* Read more about isConfirmed, isDenied below */
  425. if (result.isConfirmed) {
  426. $.ajax({
  427. type: "GET",
  428. url: '/pet/accept',
  429. data: {'id':id},
  430. success: function(bodyMessage) {
  431. if(bodyMessage=="success"){
  432. Swal.fire(
  433. 'Done',
  434. 'Successfully Accepted to the ID:'+id,
  435. 'success'
  436. ).then(() => {
  437. location.reload();
  438. });
  439. }
  440. }
  441. });
  442. } else if (result.isDenied) {
  443. Swal.fire('Changes are not saved', '', 'info')
  444. }
  445. })
  446. }
  447. function reject(uniqueid){
  448. $.ajax({
  449. type: "GET",
  450. url: '/api/pet/getpetInfo',
  451. data: {
  452. 'petid':uniqueid
  453. },
  454. success: function(x) {
  455. showPetInfo(x)
  456. }
  457. });
  458. }
  459. function showPetInfo(list){
  460. console.log(list);
  461. $('#rejectForm').modal({
  462. backdrop: 'static',
  463. keyboard: false
  464. });
  465. $('#rejectForm').modal('show');
  466. document.getElementById("uniqid").innerHTML =list.uniqueid;
  467. document.getElementById("petna").innerHTML =list.petname;
  468. document.getElementById("speci").innerHTML =list.species;
  469. document.getElementById("bre").innerHTML =list.breed;
  470. document.getElementById("gend").innerHTML =list.gender;
  471. document.getElementById("age").innerHTML =list.age;
  472. document.getElementById("arvd").innerHTML =list.arvdate;
  473. document.getElementById("dewormdate").innerHTML =list.dewormdate;
  474. document.getElementById("othervac").innerHTML =list.othervac;
  475. document.getElementById("previoslicenseNo").innerHTML =list.previoslicenseNo;
  476. document.getElementById("VeterinaryConsultant").innerHTML =list.veterinaryConsultant;
  477. document.getElementById("TNVCNo").innerHTML =list.tnvcno;
  478. document.getElementById("registerdate").innerHTML =list.registerdate;
  479. }
  480. function rejectsubmit(){
  481. var reason = $("#reason").val();
  482. var id = $("#uniqid").val();
  483. Swal.fire({
  484. title: 'Do you want to Reject this Pet ?',
  485. showDenyButton: true,
  486. showCancelButton: true,
  487. confirmButtonText: 'YES',
  488. denyButtonText: `NO`,
  489. }).then((result) => {
  490. /* Read more about isConfirmed, isDenied below */
  491. if (result.isConfirmed) {
  492. $.ajax({
  493. type: "GET",
  494. url: '/pet/reject',
  495. data: {'id':id,'reason':reason},
  496. success: function(bodyMessage) {
  497. if(bodyMessage=="success"){
  498. console.log("done");
  499. Swal.fire(
  500. 'Done',
  501. 'Successfully Rejected to the ID:'+id,
  502. 'success'
  503. ).then(() => {
  504. location.reload();
  505. });
  506. }
  507. }
  508. });
  509. } else if (result.isDenied) {
  510. Swal.fire('Changes are not saved', '', 'info')
  511. }
  512. })
  513. return false;
  514. }
  515. function viewOwner(mobilenum){
  516. $.ajax({
  517. type: "GET",
  518. url: '/api/pet/getpetOwner',
  519. data: {
  520. 'mobilenum':mobilenum,
  521. },
  522. success: function(bodyMessage) {
  523. ownercall(bodyMessage);
  524. }
  525. });
  526. }
  527. function ownercall(list){
  528. $('#ownerForm').modal({
  529. backdrop: 'static',
  530. keyboard: false
  531. });
  532. $('#ownerForm').modal('show');
  533. document.getElementById("title").innerHTML =list.title;
  534. document.getElementById("fname").innerHTML =list.fname;
  535. document.getElementById("doornumber").innerHTML =list.doornumber;
  536. document.getElementById("street").innerHTML =list.street;
  537. document.getElementById("area").innerHTML =list.area;
  538. document.getElementById("city").innerHTML =list.city;
  539. document.getElementById("pincode").innerHTML =list.pincode;
  540. document.getElementById("zone").innerHTML =list.zone;
  541. document.getElementById("ward").innerHTML =list.ward;
  542. document.getElementById("phone").innerHTML =list.phone;
  543. document.getElementById("email").innerHTML =list.email;
  544. document.getElementById("pancard").innerHTML =list.pancard;
  545. document.getElementById("aadhar").innerHTML =list.aadhar;
  546. document.getElementById("voterid").innerHTML =list.voterid;
  547. }
  548. // Function to call modal for New pet registration
  549. callAdd = function(){
  550. $('#addForm').modal({
  551. backdrop: 'static',
  552. keyboard: false
  553. })
  554. $('#addForm').modal('show');
  555. }
  556. // $(document).ready(function () {
  557. // var today = new Date();
  558. // $('.datepicker').datepicker({
  559. // dateFormat: 'yy-mm-dd',
  560. // maxDate: '1'
  561. // })
  562. // $('.datepicker').keyup(function () {
  563. // if (this.value.match(/[^0-9]/g)) {
  564. // this.value = this.value.replace(/[^0-9^-]/g, '');
  565. // }
  566. // });
  567. // });
  568. function getbydate(){
  569. var x= document.getElementById("fromdate").value;
  570. var y= document.getElementById("todate").value;
  571. var url= '/pet/acceptedPets?fromDate='+x+'&toDate='+y;
  572. window.location.href=url;
  573. }
  574. function resetDate(){
  575. var url= '/pet/acceptedPets';
  576. window.location.href=url;
  577. }
  578. </script>
  579. </body>
  580. </html>