Guest User

ghfghgh

a guest
Apr 4th, 2018
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 41.20 KB | None | 0 0
  1. <?php
  2. ini_set('display_errors', 1);
  3. ini_set('display_startup_errors', 1);
  4. error_reporting(E_ALL);
  5. //mysqli_report(MYSQLI_REPORT_ALL & ~MYSQLI_REPORT_INDEX);
  6. require_once("dbcontroller.php");
  7. $db_handle = new DBController();
  8.  
  9. if (isset($_GET['pageno'])) {
  10. $pageno = $_GET['pageno'];
  11. } else {
  12. $pageno = 1;
  13. }
  14.  
  15. $mysqli = new mysqli('localhost', 'root', '', '');
  16. $connect = mysqli_connect('localhost', 'root', '', '');
  17. ?>
  18.  
  19.  
  20. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  21. <html xmlns="http://www.w3.org/1999/xhtml">
  22. <head>
  23. <title>Main Order Details</title>
  24. <link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon"/>
  25. <link rel="icon" href="images/favicon.ico" type="image/x-icon"/>
  26. <link href="SpryAssets/style.css" rel="stylesheet" type="text/css" />
  27. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  28. <link href="SpryAssets/Tab.css" rel="stylesheet" type="text/css" />
  29. <script src="SpryAssets/jquery-2.1.1.min.js" type="text/javascript"></script>
  30. <script src="SpryAssets/jquery-ui.min.js"></script>
  31. <link href="SpryAssets/jquery.dataTables.min.css" rel="stylesheet" type="text/css" />
  32. <link rel="shortcut icon" href="images/2DO_1.png" type="image/x-icon">
  33.  
  34. <link href="SpryAssets/jquery-ui.css" rel="stylesheet" type="text/css" />
  35.  
  36. </head>
  37. <body>
  38. <div id="wrapper">
  39. <?php include "Header.php";?>
  40. <?php
  41.  
  42. $sqluser = "SELECT * from admin_master where UserName!='".$loginuser."' AND TYPE !=0" ;
  43. $userresult = $db_handle->runSelectQuery($sqluser);
  44. //print_r($userresult);die;
  45. $numrowsuser =count($userresult);
  46. ?>
  47. <div id="ordercontent">
  48. <div class="tab" >
  49. <button><a href = "dashboard.php">Orders</a></button>
  50. <button><a href = "delivered.php">Delivered</a></button>
  51. <button><a href = "cancelled.php">Cancel</a></button>
  52. <button><a href = "ecallpage.php">ECall</a></button>
  53. <button><a href = "edcallpage.php">EDCall</a></button>
  54. <button class="tablinks active" onclick="openTab(event, 'LeadManager')" id="<?php if($logintype=='0'){echo"defaultOpen";}?>"><a href = "sentpage.php">Sent</a></button>
  55. <button><a href = "holdpage.php">Hold</a></button>
  56. <button><a href = "search.php">Search</a></button>
  57.  
  58.  
  59.  
  60. </div>
  61. <!-- Tab content -->
  62. <div id="AllTeam" >
  63. <?php if($logintype=="2" && ($userdepart=="1" || $userdepart=="2" || $userdepart=="3" || $userdepart=="4")){?>
  64. <input type="text" name="tag" id="focus" placeholder="Use handheld RFID scanner"/>
  65. <?php }?>
  66. </div>
  67. <div id="LeadManager" class="tabcontent">
  68. <h3><?php echo $usertype;?></h3>
  69. <input type="hidden" name="orderids" id="orderids" value=""/>
  70. <?php if($logintype!="2"){?>
  71.  
  72.  
  73.  
  74.  
  75.  
  76.  
  77.  
  78. <!-- Import Order -->
  79.  
  80.  
  81. <div class="importorder">
  82. <form name="importorderform" id="importorderform" method="post" enctype="multipart/form-data" action="importOrder.php" >
  83.  
  84.  
  85. </form>
  86.  
  87.  
  88. </div>
  89. <div style="clear:both;"></div>
  90.  
  91. <?PHP }?>
  92. <div style="clear:both;"></div>
  93.  
  94. <!-- order per page -->
  95.  
  96.  
  97.  
  98. <!-- order per page end-->
  99. <div style="clear:both;"></div>
  100.  
  101.  
  102.  
  103.  
  104.  
  105. <?php
  106.  
  107. $userToSearch='';
  108. $searchValue='';
  109. $ordercheckall='';
  110. $rowNumber="";
  111.  
  112. // if(isset($_GET['searchOrder']) && $_GET['searchOrder']!='')
  113. if(isset($_GET['searchOrder']) && $_GET['searchOrder']!='')
  114. {
  115. $searchValue=$_GET['searchOrder'];
  116. //if($_POST['searchOrder']=='all'){$loginuser='';}
  117. if($logintype==2)
  118. {
  119. if($_GET['searchOrder']=='all'){
  120. $userToSearch = "WHERE (conformed_by LIKE '%".$loginuser."%' OR conformed_by IS NULL) AND status NOT IN ('Conformed','Hold','Canceled')";
  121. }
  122. else if($_GET['searchOrder']=='assigned'){
  123.  
  124. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND status NOT IN ('Conformed','Hold','Canceled')";
  125. }
  126. else if($_GET['searchOrder']=="unassigned"){
  127. $userToSearch = "WHERE conformed_by IS NULL AND status NOT IN ('Conformed','Hold','Canceled')";
  128. }
  129. else if($_GET['searchOrder']=='hold'){
  130. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND status='Hold'";
  131. }
  132. else if($_GET['searchOrder']=='cancel'){
  133. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND status='Canceled'";
  134. }
  135. else if($_GET['searchOrder']=="PPD"){
  136. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND payment_type NOT IN ('Cash on delivery')";
  137. }
  138. else if($_GET['searchOrder']=="COD"){
  139. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND payment_type IN ('Cash on delivery')";
  140. }
  141. else if($_GET['searchOrder']=="Wholesale"){
  142. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND customer_group=2";
  143. }
  144. else if($_GET['searchOrder']=="Local"){
  145. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND customer_group!=2 AND store_id=1";
  146. }
  147. else if($_GET['searchOrder']=="Foreign"){
  148. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND store_id=2";
  149. }
  150. else if($_GET['searchOrder']=="High"){
  151. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND priority LIKE '%High%'";
  152. }
  153. else if($_GET['searchOrder']=="Medium"){
  154. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND priority LIKE '%Medium%'";
  155. }
  156. else if($_GET['searchOrder']=="Low"){
  157. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND priority LIKE '%Low%'";
  158. }
  159. else
  160. {
  161. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND status NOT IN ('Conformed','Hold','Canceled')";
  162. }
  163. }
  164. else
  165. {
  166. if($_GET['searchOrder']=='all'){
  167. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND status NOT IN ('Conformed','Hold','Canceled')";
  168. }
  169. else if($_GET['searchOrder']=='assigned'){
  170.  
  171. $userToSearch = "WHERE (conformed_by IS NOT NULL OR conformed_by!='') AND status NOT IN ('Conformed','Hold','Canceled')";
  172. }
  173. else if($_GET['searchOrder']=="unassigned"){
  174. $userToSearch = "WHERE conformed_by IS NULL AND status NOT IN ('Conformed','Hold','Canceled')";
  175. }
  176. else if($_GET['searchOrder']=='hold'){
  177.  
  178. $userToSearch = "WHERE (conformed_by IS NOT NULL OR conformed_by!='') AND status='Hold'";
  179. }
  180. else if($_GET['searchOrder']=='cancel'){
  181.  
  182. $userToSearch = "WHERE (conformed_by IS NOT NULL OR conformed_by!='') AND status='Canceled'";
  183. }
  184. else if($_GET['searchOrder']=="PPD"){
  185. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND payment_type NOT IN ('Cash on delivery')";
  186. }
  187. else if($_GET['searchOrder']=="COD"){
  188. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND payment_type IN ('Cash on delivery')";
  189. }
  190. else if($_GET['searchOrder']=="Wholesale"){
  191. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND customer_group=2";
  192. }
  193. else if($_GET['searchOrder']=="Local"){
  194. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND customer_group!=2 AND store_id=1";
  195. }
  196. else if($_GET['searchOrder']=="Foreign"){
  197. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND store_id=2";
  198. }
  199. else if($_GET['searchOrder']=="High"){
  200. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND priority LIKE '%High%'";
  201. }
  202. else if($_GET['searchOrder']=="Medium"){
  203. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND priority LIKE '%Medium%'";
  204. }
  205. else if($_GET['searchOrder']=="Low"){
  206. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND priority LIKE '%Low%'";
  207. }
  208. else
  209. {
  210. $userToSearch = "WHERE conformed_by LIKE '%".$_GET['searchOrder']."%' AND status NOT IN ('Conformed','Hold','Canceled')";
  211. }
  212. }
  213. }
  214. else if(isset($_POST['orderbyid']) && $_POST['orderbyid']!='')
  215. {
  216. $userToSearch = "WHERE order_id in (".$_POST['orderbyid'].")";
  217. }
  218. else
  219. {
  220. if($logintype==2 && $userdepart==0)
  221. {
  222. $userToSearch = "WHERE conformed_by LIKE '%".$loginuser."%' AND (status!='Conformed' AND status!='Hold' AND status!='Canceled')";
  223. }
  224. else
  225. {
  226. $userToSearch = "WHERE (conformed_by LIKE '%%' OR conformed_by IS NULL) AND status NOT IN ('Conformed','Hold','Canceled')";
  227. }
  228. }
  229.  
  230. // Display table rows
  231.  
  232. $sqlresultdoorder = "SELECT * from do_order";
  233. $resultdoorder = $db_handle->runSelectQuery($sqlresultdoorder);
  234. $numrows =count($resultdoorder);
  235. //$counter = --$numrows;
  236. $rows_per_page = 100000;
  237. $lastpage= ceil($numrows/$rows_per_page);
  238. $pageno = (int)$pageno;
  239. if ($pageno > $lastpage) {
  240. $pageno = $lastpage;
  241. } // if
  242. if ($pageno < 1) {
  243. $pageno = 1;
  244. }
  245. $limit = 'LIMIT ' .($pageno - 1) * $rows_per_page .',' .$rows_per_page;
  246. $sqlresult = "SELECT * from do_order ORDER BY id DESC ".$limit;
  247. $orderrecords = $db_handle->runSelectQuery($sqlresult);
  248.  
  249. // Display table rows end
  250.  
  251. // date search
  252.  
  253. $query = "SELECT * FROM do_order ORDER BY order_id desc";
  254. $result = mysqli_query($connect, $query);
  255.  
  256. //date search end
  257.  
  258.  
  259.  
  260. ?>
  261.  
  262.  
  263. <div class="col-md-3">
  264. <input type="text" name="from_date" id="from_date" class="form-control" placeholder="From Date" />
  265. </div>
  266. <div class="col-md-3">
  267. <input type="text" name="to_date" id="to_date" class="form-control" placeholder="To Date" />
  268. </div>
  269. <div class="col-md-5">
  270. <input type="button" name="filter" id="filter" value="Filter" class="btn btn-info" />
  271. </div>
  272. <div style="clear:both"></div>
  273. <br />
  274.  
  275.  
  276.  
  277.  
  278. <!--
  279. <div class="serchorderbyid">
  280. <form name="serchorderbyidform" id="serchorderbyidform" method="post" enctype="multipart/form-data" action="" >
  281. Order ID (101,102,103): <input type="text" name="orderbyid" id="orderbyid" value=""/>
  282. <input type="button" class="ajax-assign-button" id="OrderById" value="OrderById" onclick="searchorderbyid()"/>
  283. <a href="dashboard2.php"><input type="button" class="ajax-assign-button" id="resetFilter" value="Reset"/></a>
  284. </form>
  285. </div>
  286. -->
  287.  
  288.  
  289. <?php
  290.  
  291. $tabindex=1;
  292.  
  293. ?>
  294.  
  295.  
  296. <?php
  297.  
  298.  
  299.  
  300.  
  301. ?>
  302.  
  303.  
  304.  
  305. <!-- export -->
  306.  
  307. <div class="serchorderbyid">
  308. <form name="serchorderbyidform" id="serchorderbyidform" method="post" enctype="multipart/form-data" action="" >
  309.  
  310. <input type="button" class="ajax-assign-button" id="csvfile" value="Export" onclick="exportorders();" />
  311.  
  312. <button type= "button" id="show_status" class="ajax-assign-button">Show Status</button>
  313.  
  314. <button type= "button" id="cancel" class="ajax-assign-button">Cancel</button>
  315.  
  316.  
  317. <button type= "button" id="orderstab" class="ajax-assign-button">Orderstab</button>
  318.  
  319. </form>
  320. </div>
  321.  
  322. <!-- export -->
  323.  
  324. <br/>
  325. <div id="order_table">
  326. <table class="tbl-qa" border="1" id="content-table">
  327. <thead>
  328. <tr>
  329.  
  330. <th></th>
  331.  
  332. <th class="table-header">AWB</th>
  333. <th class="table-header">ORDERID</th>
  334. <th class="table-header">Sent</th>
  335. <th class="table-header">Last Update Date</th>
  336. <th class="table-header">Attempted</th>
  337.  
  338.  
  339. <th class="table-header"><div style="width: 50px" >
  340.  
  341. <select id="my_select" onchange="send_option();">
  342. <option value="all">Status</option>
  343.  
  344. <?php
  345.  
  346. $query = "SELECT DISTINCT in_transit FROM do_order";
  347. $result = mysqli_query ($mysqli, $query);
  348. while ( $row = mysqli_fetch_array($result) )
  349. echo "<option value='" . $row['in_transit'] . "'>" . $row['in_transit'] . "</option>";
  350. ?>
  351. </select>
  352. </div></th>
  353.  
  354.  
  355. <th class="table-header">
  356.  
  357. <select id="my_select1" onchange="send_option();">
  358. <option value="all">Tracking Status</option>
  359.  
  360.  
  361. <?php
  362.  
  363. $query = "SELECT DISTINCT tracking FROM do_order";
  364. $result = mysqli_query ($mysqli, $query);
  365. while ( $row = mysqli_fetch_array($result) )
  366. echo "<option value='" . $row['tracking'] . "'>" . $row['tracking'] . "</option>";
  367. ?>
  368. </select>
  369.  
  370. </th>
  371.  
  372.  
  373.  
  374.  
  375.  
  376.  
  377.  
  378.  
  379.  
  380. <th class="table-header">
  381.  
  382. <select id="my_select3" onchange="send_option();">
  383. <option value="all">Reason code</option>
  384.  
  385.  
  386. <?php
  387.  
  388. $query = "SELECT DISTINCT reason1 FROM do_order";
  389. $result = mysqli_query ($mysqli, $query);
  390. while ( $row = mysqli_fetch_array($result) )
  391. echo "<option value='" . $row['reason1'] . "'>" . $row['reason1'] . "</option>";
  392. ?>
  393. </select>
  394.  
  395.  
  396.  
  397. </th>
  398.  
  399. <th class="table-header">
  400.  
  401. <select id="my_select2" onchange="send_option();">
  402. <option value="all">NOA</option>
  403.  
  404.  
  405. <?php
  406.  
  407. $query = "SELECT DISTINCT no_of_attempts FROM do_order";
  408. $result = mysqli_query ($mysqli, $query);
  409. while ( $row = mysqli_fetch_array($result) )
  410. echo "<option value='" . $row['no_of_attempts'] . "'>" . $row['no_of_attempts'] . "</option>";
  411. ?>
  412. </select>
  413.  
  414. </th>
  415.  
  416. <th class="table-header">My Name</th>
  417. <th class="table-header">Final comments</th>
  418.  
  419. <th class="table-header">Consignee</th>
  420. <th class="table-header">Uploaded</th>
  421. <th class="table-header">Updated</th>
  422.  
  423. <th class="table-header">tab</th>
  424. <th class="table-header">Telecomments</th>
  425.  
  426.  
  427.  
  428. </tr>
  429. </thead>
  430. <tbody id="table-body">
  431.  
  432.  
  433. <?php
  434.  
  435. $theBigQuery = "SELECT * FROM do_order WHERE 1";
  436.  
  437.  
  438. if (isset($_POST['my_option']) && $_POST['my_option'] != ""){
  439. if($_POST['my_option'] == "all"){
  440.  
  441. } else {
  442. $theBigQuery .= " AND in_transit like '" . $_POST["my_option"] . "'";
  443. }
  444. echo "<script type='text/javascript'>function changeOption(){document.getElementById('my_select').value='".$_POST['my_option']."';} changeOption();</script>";
  445.  
  446. }
  447.  
  448.  
  449.  
  450. if (isset($_POST['my_option1']) && $_POST['my_option1'] != ""){
  451. if($_POST['my_option1'] == "all"){
  452.  
  453. } else {
  454. $theBigQuery .= " AND tracking like '" . $_POST["my_option1"] . "'";
  455. }
  456. echo "<script type='text/javascript'>function changeOption1(){document.getElementById('my_select1').value='".$_POST['my_option1']."';} changeOption1();</script>";
  457.  
  458. }
  459.  
  460.  
  461.  
  462.  
  463. if (isset($_POST['my_option2']) && $_POST['my_option2'] != ""){
  464. if($_POST['my_option2'] == "all"){
  465.  
  466. } else {
  467. $theBigQuery .= " AND no_of_attempts like '" . $_POST["my_option2"] . "'";
  468. }
  469. echo "<script type='text/javascript'>function changeOption2(){document.getElementById('my_select2').value='".$_POST['my_option2']."';} changeOption2();</script>";
  470.  
  471. }
  472.  
  473.  
  474. if (isset($_POST['my_option3']) && $_POST['my_option3'] != ""){
  475. if($_POST['my_option3'] == "all"){
  476.  
  477. } else {
  478. $theBigQuery .= " AND reason1 like '" . $_POST["my_option3"] . "'";
  479. }
  480. echo "<script type='text/javascript'>function changeOption3(){document.getElementById('my_select3').value='".$_POST['my_option3']."';} changeOption3();</script>";
  481.  
  482. }
  483.  
  484. $theBigQuery .= " ORDER BY id DESC";
  485. $orderrecords = $db_handle->runSelectQuery($theBigQuery);
  486.  
  487. if(!empty($orderrecords))
  488. {
  489. foreach($orderrecords as $k=>$v)
  490. {
  491.  
  492. $hide='';
  493. if ($v['in_transit'] == "Delivered / Closed")
  494. {
  495. $hide .= 'style="display: none;"';
  496. }
  497.  
  498. if ($v['reattempt']!== "sent" || $v['reattempt']="")
  499. {
  500. $hide .= 'style="display: none;"';
  501. }
  502.  
  503.  
  504. ?>
  505.  
  506.  
  507.  
  508.  
  509.  
  510.  
  511. <tr <?php echo $hide;?> class="table-row" id="table-row-<?php echo $orderrecords[$k]["id"]; ?>" tabindex="<?php echo $tabindex;?>">
  512.  
  513. <td> <input type="checkbox" id="assigneeid-<?php echo $orderrecords[$k]["tracking_id"]; ?>" onclick="assignorderids('<?php echo $orderrecords[$k]["tracking_id"]; ?>')" name="checkassigneeid" class="assigneeid-order" value="<?php echo $orderrecords[$k]["tracking_id"]; ?>"> </td>
  514.  
  515. <td><?php echo $orderrecords[$k]["tracking_id"]; ?></td>
  516. <td><?php echo $orderrecords[$k]["order_id"]; ?></td>
  517.  
  518. <td><?php echo $orderrecords[$k]["sent_date"]; ?></td>
  519.  
  520. <td id="<?php echo $orderrecords[$k]["tracking_id"];?>lud">
  521. <?php echo $orderrecords[$k]["lud"]; ?>
  522. </td>
  523.  
  524. <td>
  525.  
  526. <?php
  527.  
  528. $orderrecords[$k]["sent_date"]= strtotime($orderrecords[$k]["sent_date"]);
  529. $orderrecords[$k]["lud"]= strtotime($orderrecords[$k]["lud"]);
  530.  
  531. if ($orderrecords[$k]["lud"] < $orderrecords[$k]["sent_date"])
  532. {
  533. $sqlecom = 'UPDATE table SET attempted = "attempted"
  534. WHERE id = ' . $orderrecords[$k]['id'];
  535.  
  536. $db_handleecom = new DBController();
  537. $resultecom = $db_handleecom->executeUpdate($sqlecom);
  538. //echo "attempted";
  539. }
  540.  
  541. echo $orderrecords[$k]["attempted"];
  542.  
  543. ?>
  544.  
  545.  
  546. </td>
  547.  
  548. <td id="<?php echo $orderrecords[$k]["tracking_id"];?>">
  549. <?php echo $orderrecords[$k]["in_transit"]; ?>
  550. </td>
  551.  
  552. <td id="<?php echo $orderrecords[$k]["tracking_id"];?>tracking">
  553. <?php echo $orderrecords[$k]["tracking"]; ?>
  554. </td>
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561. <td id="<?php echo $orderrecords[$k]["tracking_id"];?>reason1">
  562. <?php echo $orderrecords[$k]["reason1"]; ?>
  563. </td>
  564.  
  565. <td class="id"><?php echo $orderrecords[$k]["no_of_attempts"]; ?></td>
  566.  
  567. <td <?php if($userdepart==0 ){?>contenteditable="true" onBlur="saveToDatabase(this,'name','<?php echo $orderrecords[$k]["id"]; ?>')"<?php }?>><?php echo substr($orderrecords[$k]["name"],0,75); ?></td>
  568. <td <?php if($userdepart==0 ){?>contenteditable="true" onBlur="saveToDatabase(this,'comments','<?php echo $orderrecords[$k]["id"]; ?>')"<?php }?>><?php echo substr($orderrecords[$k]["comments"],0,99999); ?></td>
  569.  
  570.  
  571.  
  572.  
  573.  
  574. <td><?php echo $orderrecords[$k]["consignee"]; ?></td>
  575. <td><?php echo $orderrecords[$k]["uploaded_date"]; ?></td>
  576. <td><?php echo $orderrecords[$k]["updated_date"]; ?></td>
  577.  
  578. <td><?php echo $orderrecords[$k]["reattempt"]; ?></td>
  579.  
  580. <td><?php echo $orderrecords[$k]["telecomments"]; ?></td>
  581.  
  582. </tr>
  583. <?php
  584. $tabindex++;
  585.  
  586. }
  587. }?>
  588. </tbody>
  589. </table>
  590. </div>
  591.  
  592. <form method="post" action"dashboard.php" style="display:none" id="my_form">
  593. <input type="text" id="my_option" name="my_option"/>
  594. <input type="text" id="my_option1" name="my_option1"/>
  595. <input type="text" id="my_option2" name="my_option2"/>
  596. <input type="text" id="my_option3" name="my_option3"/>
  597. </form>
  598.  
  599. <input type="hidden" name="ordercheckallIDs" id="ordercheckallIDs" value="<?php echo $ordercheckall;?>"/>
  600.  
  601. <div class="pagination">
  602. <?php
  603. $sordersearch='';
  604.  
  605. if($searchValue!='')
  606. {
  607. $sordersearch="&searchOrder=".$searchValue;
  608. }
  609.  
  610. ?>
  611. <?php if ($pageno == 1) {
  612. echo " <span class='firstspan'>FIRST</span>";
  613. } else {
  614. echo " <span class='firstpage'><a href='{$_SERVER['PHP_SELF']}?pageno=1&limitperpage=$rows_per_page$sordersearch'>FIRST</a></span> ";
  615. $prevpage = $pageno-1;
  616. echo " <span class='prvpage'><a href='{$_SERVER['PHP_SELF']}?pageno=$prevpage&limitperpage=$rows_per_page$sordersearch'>PREV</a></span> ";
  617. }
  618.  
  619. if ($pageno == $lastpage) {
  620. echo " <span class='nextlastpage'>LAST</span> ";
  621. } else {
  622. $nextpage = $pageno+1;
  623. echo " <span class='nextpage'><a href='{$_SERVER['PHP_SELF']}?pageno=$nextpage&limitperpage=$rows_per_page$sordersearch'>NEXT</a></span> ";
  624. echo " <span class='lastpage'><a href='{$_SERVER['PHP_SELF']}?pageno=$lastpage&limitperpage=$rows_per_page$sordersearch'>LAST</a></span> ";
  625. }
  626. echo " ( Page $pageno of $lastpage ) ";
  627. ?>
  628. </div>
  629. </div>
  630. </div>
  631.  
  632. <div style="clear:both;"></div>
  633. <?php include "Footer.php"; ?>
  634. </div>
  635. <script type="text/javascript">
  636.  
  637. // Date search
  638.  
  639. $(document).ready(function(){
  640. $.datepicker.setDefaults({
  641. dateFormat: 'yy-mm-dd'
  642. });
  643. $(function(){
  644. $("#from_date").datepicker();
  645. $("#to_date").datepicker();
  646. });
  647. $('#filter').click(function(){
  648. var from_date = $('#from_date').val();
  649. var to_date = $('#to_date').val();
  650. if(from_date != '' && to_date != '')
  651. {
  652. $.ajax({
  653. url:"filter.php",
  654. method:"POST",
  655. data:{from_date:from_date, to_date:to_date},
  656. success:function(data)
  657. {
  658. $('#order_table').html(data);
  659. }
  660. });
  661. }
  662. else
  663. {
  664. alert("Please Select Date");
  665. }
  666. });
  667. });
  668.  
  669. // date search end
  670.  
  671.  
  672.  
  673. //document.getElementById("defaultOpen").click();
  674. function openTab(evt,tabname)
  675. {
  676. // Declare all variables
  677. var i, tabcontent, tablinks;
  678.  
  679. // Get all elements with class="tabcontent" and hide them
  680. tabcontent = document.getElementsByClassName("tabcontent");
  681. for (i = 0; i < tabcontent.length; i++) {
  682. tabcontent[i].style.display = "none";
  683. }
  684. // Get all elements with class="tablinks" and remove the class "active"
  685. tablinks = document.getElementsByClassName("tablinks");
  686. for (i = 0; i < tablinks.length; i++) {
  687. tablinks[i].className = tablinks[i].className.replace(" active", "");
  688. }
  689. // Show the current tab, and add an "active" class to the button that opened the tab
  690. document.getElementById(tabname).style.display = "block";
  691. evt.currentTarget.className += " active";
  692. }
  693.  
  694. function assignallorderids()
  695. {
  696. var checkstatus=$("#checkall").is(":checked");
  697.  
  698. if(checkstatus==true)
  699. {
  700. var id=document.getElementById("ordercheckallIDs").value;
  701. document.getElementById("orderids").value=id;
  702. $("input:checkbox[name='checkassigneeid']").prop('checked',true);
  703.  
  704. }
  705. else
  706. {
  707. $("input:checkbox[name='checkassigneeid']").prop('checked',false);
  708. document.getElementById("orderids").value='';
  709. }
  710. }
  711.  
  712. function assignorderids(oid)
  713. {
  714. var checkstatus=$("#assigneeid-"+oid).is(":checked");
  715. var morderId =document.getElementById("orderids").value;
  716. if(checkstatus==false)
  717. {
  718. var arrayorder = JSON.parse("[" + morderId + "]");
  719. document.getElementById("orderids").value='';
  720. for (var i = 0; i < arrayorder.length; i++) {
  721. var orderstatusValue=arrayorder[i];
  722. if(orderstatusValue!=oid){
  723. if (document.getElementById("orderids").value=='')
  724. {
  725. document.getElementById("orderids").value=orderstatusValue;
  726. }
  727. else
  728. {
  729. var newvalue=document.getElementById("orderids").value;
  730. document.getElementById("orderids").value=newvalue+","+orderstatusValue;
  731. }
  732. }
  733. }
  734. }
  735. else
  736. {
  737. if(morderId=='')
  738. {
  739. document.getElementById("orderids").value=oid;
  740. }
  741. else
  742. {
  743. document.getElementById("orderids").value=morderId+","+oid;
  744. }
  745. }
  746. }
  747. function graphicsorderids(goid)
  748. {
  749. var checkstatus=$("#gorderid-"+goid).is(":checked");
  750. var gmorderId =document.getElementById("gorderids").value;
  751. if(checkstatus==false)
  752. {
  753. var garrayorder = JSON.parse("[" + gmorderId + "]");
  754. document.getElementById("gorderids").value='';
  755. for (var i = 0; i < garrayorder.length; i++) {
  756. var gorderstatusValue=garrayorder[i];
  757. if(gorderstatusValue!=goid){
  758. if (document.getElementById("gorderids").value=='')
  759. {
  760. document.getElementById("gorderids").value=gorderstatusValue;
  761. }
  762. else
  763. {
  764. var gnewvalue=document.getElementById("gorderids").value;
  765. document.getElementById("gorderids").value=gnewvalue+","+gorderstatusValue;
  766. }
  767. }
  768. }
  769. }
  770. else
  771. {
  772. if(gmorderId=='')
  773. {
  774. document.getElementById("gorderids").value=goid;
  775. }
  776. else
  777. {
  778. document.getElementById("gorderids").value=gmorderId+","+goid;
  779. }
  780. }
  781. }
  782. function packingsids(pacoid)
  783. {
  784. var checkstatus=$("#pacorderid-"+pacoid).is(":checked");
  785. var pacmorderId =document.getElementById("pacorderids").value;
  786. if(checkstatus==false)
  787. {
  788. var pacarrayorder = JSON.parse("[" + pacmorderId + "]");
  789. document.getElementById("pacorderids").value='';
  790. for (var i = 0; i < pacarrayorder.length; i++) {
  791. var pacorderstatusValue=pacarrayorder[i];
  792. if(pacorderstatusValue!=pacoid){
  793. if (document.getElementById("pacorderids").value=='')
  794. {
  795. document.getElementById("pacorderids").value=pacorderstatusValue;
  796. }
  797. else
  798. {
  799. var pacnewvalue=document.getElementById("pacorderids").value;
  800. document.getElementById("pacorderids").value=pacnewvalue+","+pacorderstatusValue;
  801. }
  802. }
  803. }
  804. }
  805. else
  806. {
  807. if(pacmorderId=='')
  808. {
  809. document.getElementById("pacorderids").value=pacoid;
  810. }
  811. else
  812. {
  813. document.getElementById("pacorderids").value=pacmorderId+","+pacoid;
  814. }
  815. }
  816. }
  817. function dispatchsids(dpoid)
  818. {
  819. var checkstatus=$("#dporderid-"+dpoid).is(":checked");
  820. var dpmorderId =document.getElementById("dporderids").value;
  821. if(checkstatus==false)
  822. {
  823. var dparrayorder = JSON.parse("[" + dpmorderId + "]");
  824. document.getElementById("dporderids").value='';
  825. for (var i = 0; i < dparrayorder.length; i++) {
  826. var dporderstatusValue=dparrayorder[i];
  827. if(dporderstatusValue!=dpoid){
  828. if (document.getElementById("dporderids").value=='')
  829. {
  830. document.getElementById("dporderids").value=dporderstatusValue;
  831. }
  832. else
  833. {
  834. var dpnewvalue=document.getElementById("dporderids").value;
  835. document.getElementById("dporderids").value=dpnewvalue+","+dporderstatusValue;
  836. }
  837. }
  838. }
  839. }
  840. else
  841. {
  842. if(dpmorderId=='')
  843. {
  844. document.getElementById("dporderids").value=dpoid;
  845. }
  846. else
  847. {
  848. document.getElementById("dporderids").value=dpmorderId+","+dpoid;
  849. }
  850. }
  851. }
  852.  
  853. function printsids(poid)
  854. {
  855. var checkstatus=$("#porderid-"+poid).is(":checked");
  856. var pmorderId =document.getElementById("porderids").value;
  857. if(checkstatus==false)
  858. {
  859. var parrayorder = JSON.parse("[" + pmorderId + "]");
  860. document.getElementById("porderids").value='';
  861. for (var i = 0; i < parrayorder.length; i++) {
  862. var porderstatusValue=parrayorder[i];
  863. if(porderstatusValue!=poid){
  864. if (document.getElementById("porderids").value=='')
  865. {
  866. document.getElementById("porderids").value=porderstatusValue;
  867. }
  868. else
  869. {
  870. var pnewvalue=document.getElementById("porderids").value;
  871. document.getElementById("porderids").value=pnewvalue+","+porderstatusValue;
  872. }
  873. }
  874. }
  875. }
  876. else
  877. {
  878. if(pmorderId=='')
  879. {
  880. document.getElementById("porderids").value=poid;
  881. }
  882. else
  883. {
  884. document.getElementById("porderids").value=pmorderId+","+poid;
  885. }
  886. }
  887. }
  888. function assignorder()
  889. {
  890.  
  891. var assignee=$("#assignee option:selected" ).val();
  892. var orderids=document.getElementById("orderids").value;
  893. document.getElementById("assignedid").value=orderids;
  894. var orderId=document.getElementById("assignedid").value;
  895. if(assignee == '0'){alert("Please Select Name To Assign.");}
  896. else{if(orderId ==''){alert("Please Checked Order To Assign.");}}
  897. if(assignee != '0' && orderId!=''){
  898. $("#assigneeform").submit();
  899. }
  900. }
  901. function conformorder(id,neworderids,formname)
  902. {
  903. var orderids=document.getElementById(id).value;
  904.  
  905. if(orderids!='')
  906. {
  907. document.getElementById(neworderids).value=orderids;
  908. }
  909. if(orderids=='')
  910. {
  911. alert("Please Checked Order To Conformed.");
  912. }
  913. else
  914. {
  915. $("#"+formname).submit();
  916. }
  917. }
  918. function insertToDatabase(editableObj,column) {
  919. $.ajax({
  920. url: "insertOrder.php",
  921. type: "POST",
  922. data:'column='+column+'&editval='+$(editableObj).text(),
  923. success: function(data){
  924. $(editableObj).css("background","#FDFDFD");
  925. location.reload();
  926. }
  927. });
  928. }
  929. function saveToDatabase(editableObj,column,id) {
  930.  
  931. if(column=="image_ready" || column=="ready_to_print" || column=="ready_to_packaging" || column=="ready_to_dispatch"){cvalue=editableObj;}else{var cvalue=$(editableObj).text();}
  932.  
  933. $.ajax({
  934. url: "editOrder.php",
  935. type: "POST",
  936. data:'column='+column+'&editval='+cvalue+'&id='+id,
  937. success: function(data){
  938. $(editableObj).css("background","#dddddd");
  939. if(column=="image_ready" || column=="ready_to_print" || column=="ready_to_packaging" || column=="ready_to_dispatch"){location.reload();}
  940. }
  941. });
  942. }
  943.  
  944. function handler(e,column,id){
  945.  
  946. editableObj=e.target.value;
  947. $.ajax({
  948. url: "editOrder.php",
  949. type: "POST",
  950. data:'column='+column+'&editval='+editableObj+'&id='+id,
  951. success: function(data){
  952. $(editableObj).css("background","#dddddd");
  953. location.reload();
  954. }
  955. });
  956.  
  957. }
  958. //add new row
  959. function createNew() {
  960. $("#add-more").hide();
  961. var data = '<tr class="table-row" id="new_row_ajax">' +
  962. '<td contenteditable="false" id="txt_id"></td>' +
  963. '<td contenteditable="true" id="txt_order_id" onBlur="insertToDatabase(this,\'order_id\')" ></td>'+
  964. '<td contenteditable="true" id="txt_order_date"></td>'+
  965. '<td contenteditable="true" id="txt_payment_type" ></td>'+
  966. '<td contenteditable="true" id="txt_conformed_by" ></td>'+
  967. '<td contenteditable="true" id="txt_status" ></td>' +
  968. '<td contenteditable="true" id="txt_customer_name"></td>' +
  969. '<td contenteditable="true" id="txt_phone_number"></td>' +
  970. '<td contenteditable="true" id="txt_address"></td>' +
  971. '<td contenteditable="false" id="txt_image_ready"></td>' +
  972. '<td contenteditable="false" id="txt_ready_to_print"></td>' +
  973. '<td contenteditable="false" id="txt_ready_to_packaging"></td>' +
  974. '<td contenteditable="false" id="txt_ready_to_dispatch"></td>' +
  975.  
  976. '</tr>';
  977. $("#table-body").prepend(data);
  978. }
  979. $(document).ready(function () {
  980. $("#fromdate").datepicker();
  981. $('#todate').datepicker();
  982. $("#importorder").click(function() {
  983. var todate = $("#todate").val();
  984. var fromdate = $("#fromdate").val();
  985. var selectedfromtime = $("#formtime option:selected").val();
  986. var selectedtotime = $("#totime option:selected").val();
  987. if (fromdate === "") {
  988. alert("Please select departing and returning dates.");
  989. } else {
  990. $("#toorderdate").val(todate);
  991. $("#fromorderdate").val(fromdate);
  992. $("#directorderform").submit();
  993. }
  994. });
  995. $("#focus").select();
  996. //setTimeout(selectBarcode(),1000);
  997. $('input[name="tag"]').change(function()
  998. {
  999. txt = $("#focus").val();//alert('You have changed the input'+txt);
  1000. $.ajax({
  1001. url: "scanupdates.php",
  1002. type: "POST",
  1003. data:'order_id='+txt+'&wtype='+<?php echo $userdepart?>+'&uname='+'<?php echo $loginuser?>',
  1004. success: function(data){
  1005. alert(data);
  1006. if(data=="")
  1007. {
  1008. alert(data);
  1009. }
  1010. location.reload();
  1011. // $(editableObj).css("background","#FDFDFD");
  1012. }
  1013. });
  1014. //
  1015. });
  1016. });
  1017.  
  1018. // Orders per page
  1019. /*
  1020. function loadPage()
  1021. {
  1022. var limitval=$("#pagination option:selected" ).val();
  1023. var searchordevalue="<?php echo $searchValue?>";
  1024. if(searchordevalue!='')
  1025. {
  1026. window.location = "../Admin/dashboard2.php?limitperpage="+limitval+"&searchOrder="+searchordevalue;
  1027. }
  1028. else
  1029. {
  1030. window.location = "../Admin/dashboard2.php?limitperpage="+limitval;
  1031. }
  1032. */
  1033. // Orders per page end
  1034.  
  1035. //show status
  1036.  
  1037.  
  1038. $('#show_status').click(function(){
  1039. var selected = [];
  1040. $('.assigneeid-order:checked').each(function() {
  1041. selected.push($(this).val());
  1042. $('.assigneeid-order').prop('checked', false);
  1043. });
  1044.  
  1045.  
  1046.  
  1047.  
  1048. var jsonString = JSON.stringify(selected);
  1049.  
  1050. $.ajax({
  1051. type: "POST",
  1052. url: "api.php",
  1053. data: {data : jsonString},
  1054. success: function(response){
  1055.  
  1056. response = $.parseJSON(response);
  1057.  
  1058. $.each(response, function(index, val) {
  1059.  
  1060. //console.log(index, val);
  1061. //console.log("#"+index+"lud", val.lud);
  1062.  
  1063. $("#"+index+"").html(val);
  1064. $("#"+index+"").html(val.status);
  1065. $("#"+index+"lud").html(val.lud);
  1066. $("#"+index+"tracking").html(val.tracking);
  1067. $("#"+index+"reason1").html(val.reason1);
  1068.  
  1069. });
  1070. }
  1071. });
  1072.  
  1073. });
  1074.  
  1075. //show status end
  1076.  
  1077. // Reattempt
  1078.  
  1079. $('#reattempt').click(function(){
  1080. var selected = [];
  1081. $('.assigneeid-order:checked').each(function() {
  1082. selected.push($(this).val());
  1083. $('.assigneeid-order').prop('checked', false);
  1084. });
  1085.  
  1086.  
  1087. var jsonString = JSON.stringify(selected);
  1088.  
  1089. $.ajax({
  1090. type: "POST",
  1091. url: "reattempt.php",
  1092. data: {data : jsonString},
  1093. success: function(response){
  1094.  
  1095. response = $.parseJSON(response);
  1096.  
  1097. $.each(response, function(index, val) {
  1098.  
  1099.  
  1100. $("#"+index+"reattempt").html(val.reattempt);
  1101.  
  1102. });
  1103. }
  1104. });
  1105.  
  1106. });
  1107.  
  1108.  
  1109. //Reattempt end
  1110.  
  1111. // Cancel
  1112.  
  1113. $('#cancel').click(function(){
  1114. var selected = [];
  1115. $('.assigneeid-order:checked').each(function() {
  1116. selected.push($(this).val());
  1117. $('.assigneeid-order').prop('checked', false);
  1118. });
  1119.  
  1120.  
  1121. var jsonString = JSON.stringify(selected);
  1122.  
  1123. $.ajax({
  1124. type: "POST",
  1125. url: "cancel.php",
  1126. data: {data : jsonString},
  1127. success: function(response){
  1128.  
  1129. response = $.parseJSON(response);
  1130.  
  1131. $.each(response, function(index, val) {
  1132.  
  1133.  
  1134. $("#"+index+"cancel").html(val.cancel);
  1135.  
  1136. });
  1137. }
  1138. });
  1139.  
  1140. });
  1141. //cancel end
  1142.  
  1143. // ecall
  1144.  
  1145. $('#ecall').click(function(){
  1146. var selected = [];
  1147. $('.assigneeid-order:checked').each(function() {
  1148. selected.push($(this).val());
  1149. $('.assigneeid-order').prop('checked', false);
  1150. });
  1151.  
  1152.  
  1153. var jsonString = JSON.stringify(selected);
  1154.  
  1155. $.ajax({
  1156. type: "POST",
  1157. url: "ecall.php",
  1158. data: {data : jsonString},
  1159. success: function(response){
  1160.  
  1161. response = $.parseJSON(response);
  1162.  
  1163. $.each(response, function(index, val) {
  1164.  
  1165.  
  1166. $("#"+index+"ecall").html(val.ecall);
  1167.  
  1168. });
  1169. }
  1170. });
  1171.  
  1172. });
  1173. //ecall end
  1174.  
  1175.  
  1176. // edcall
  1177.  
  1178. $('#edcall').click(function(){
  1179. var selected = [];
  1180. $('.assigneeid-order:checked').each(function() {
  1181. selected.push($(this).val());
  1182. $('.assigneeid-order').prop('checked', false);
  1183. });
  1184.  
  1185.  
  1186. var jsonString = JSON.stringify(selected);
  1187.  
  1188. $.ajax({
  1189. type: "POST",
  1190. url: "edcall.php",
  1191. data: {data : jsonString},
  1192. success: function(response){
  1193.  
  1194. response = $.parseJSON(response);
  1195.  
  1196. $.each(response, function(index, val) {
  1197.  
  1198.  
  1199. $("#"+index+"edcall").html(val.edcall);
  1200.  
  1201. });
  1202. }
  1203. });
  1204.  
  1205. });
  1206. //edcall end
  1207.  
  1208. // sent
  1209.  
  1210. $('#sent').click(function(){
  1211. var selected = [];
  1212. $('.assigneeid-order:checked').each(function() {
  1213. selected.push($(this).val());
  1214. $('.assigneeid-order').prop('checked', false);
  1215. });
  1216.  
  1217.  
  1218. var jsonString = JSON.stringify(selected);
  1219.  
  1220. $.ajax({
  1221. type: "POST",
  1222. url: "sent.php",
  1223. data: {data : jsonString},
  1224. success: function(response){
  1225.  
  1226. response = $.parseJSON(response);
  1227.  
  1228. $.each(response, function(index, val) {
  1229.  
  1230.  
  1231. $("#"+index+"sent").html(val.sent);
  1232.  
  1233. });
  1234. }
  1235. });
  1236.  
  1237. });
  1238. //sent end
  1239.  
  1240. // orders
  1241.  
  1242. $('#orderstab').click(function(){
  1243. var selected = [];
  1244. $('.assigneeid-order:checked').each(function() {
  1245. selected.push($(this).val());
  1246. $('.assigneeid-order').prop('checked', false);
  1247. });
  1248.  
  1249.  
  1250. var jsonString = JSON.stringify(selected);
  1251.  
  1252. $.ajax({
  1253. type: "POST",
  1254. url: "orderstab.php",
  1255. data: {data : jsonString},
  1256. success: function(response){
  1257.  
  1258. response = $.parseJSON(response);
  1259.  
  1260. $.each(response, function(index, val) {
  1261.  
  1262.  
  1263. $("#"+index+"orderstab").html(val.orderstab);
  1264.  
  1265. });
  1266. }
  1267. });
  1268.  
  1269. });
  1270. //orders end
  1271.  
  1272.  
  1273.  
  1274. // open orders tab by default
  1275.  
  1276. document.getElementsByClassName('tablinks active')[0].click()
  1277.  
  1278. // open orders tab by default end
  1279.  
  1280. //Search by order id
  1281.  
  1282. function searchorderbyid()
  1283. {
  1284. var orderId=document.getElementById("orderbyid").value;
  1285. if(orderId ==''){alert("Please Enter order id to search.");}
  1286. else{$("#serchorderbyidform").submit();}
  1287. }
  1288.  
  1289. //Search by order id end
  1290.  
  1291.  
  1292.  
  1293. //export
  1294.  
  1295. function exportorders()
  1296. {
  1297. var sqlorderresult="<?php echo $userToSearch;?>";
  1298. var d = new Date();
  1299. var yyyy = d.getFullYear().toString();
  1300. var mm = (d.getMonth()+1).toString(); // getMonth() is zero-based
  1301. var dd = d.getDate().toString();
  1302. var hh = d.getHours().toString();
  1303. var min = d.getMinutes().toString();
  1304. var sec = d.getSeconds().toString();
  1305. fulldate=yyyy+"-"+mm+"-"+dd+"-"+hh+"-"+min+"-"+sec;
  1306. var orderId=document.getElementById("orderids").value;
  1307. $.ajax({
  1308. url: "exportOrderCsv.php",
  1309. type: "POST",
  1310. data:'exportorders='+sqlorderresult+'&department=customercare&orderId='+orderId,
  1311. success: function(data){
  1312. var pom = document.createElement('a');
  1313. var csvContent=data; //here we load our csv data
  1314. var blob = new Blob([csvContent],{type: 'text/csv;charset=utf-8;'});
  1315. var url = URL.createObjectURL(blob);
  1316. pom.href = url;
  1317. pom.setAttribute('download', fulldate+'.csv');
  1318. pom.click();
  1319. }
  1320. });
  1321. }
  1322.  
  1323. //export end
  1324.  
  1325. // SENDS SELECTED OPTION TO RETRIEVE DATA TO FILL TABLE.
  1326. function send_option () {
  1327. var sel = document.getElementById( "my_select" );
  1328. var txt = document.getElementById( "my_option" );
  1329. txt.value = sel.options[ sel.selectedIndex ].value;
  1330.  
  1331. var sel1 = document.getElementById( "my_select1" );
  1332. var txt1 = document.getElementById( "my_option1" );
  1333. txt1.value = sel1.options[ sel1.selectedIndex ].value;
  1334.  
  1335. var sel2 = document.getElementById( "my_select2" );
  1336. var txt2 = document.getElementById( "my_option2" );
  1337. txt2.value = sel2.options[ sel2.selectedIndex ].value;
  1338.  
  1339. var sel3 = document.getElementById( "my_select3" );
  1340. var txt3 = document.getElementById( "my_option3" );
  1341. txt3.value = sel3.options[ sel3.selectedIndex ].value;
  1342.  
  1343.  
  1344. var frm = document.getElementById( "my_form" );
  1345. frm.submit();
  1346. }
  1347.  
  1348. </script>
  1349.  
  1350.  
  1351. </body>
  1352. </html>
  1353. </html>
  1354.  
  1355. <style>
  1356.  
  1357. .button1 { font-size : 20px; }
  1358.  
  1359. #my_select
  1360. {
  1361. width:70px;
  1362. }
  1363.  
  1364. #my_select option{
  1365. width:70px;
  1366. }
  1367.  
  1368.  
  1369. #my_select1
  1370. {
  1371. width:70px;
  1372. }
  1373.  
  1374. #my_select1 option{
  1375. width:70px;
  1376. }
  1377.  
  1378.  
  1379. #my_select3
  1380. {
  1381. width:70px;
  1382. }
  1383.  
  1384. #my_select3 option{
  1385. width:70px;
  1386. }
  1387.  
  1388. table {
  1389. counter-reset: rowNumber;
  1390. }
  1391.  
  1392. table tr {
  1393. counter-increment: rowNumber;
  1394. }
  1395.  
  1396. table tr td:first-child::before {
  1397. content: counter(rowNumber);
  1398. min-width: 1em;
  1399. margin-right: 0.5em;
  1400. }
  1401.  
  1402.  
  1403. </style>
Add Comment
Please, Sign In to add comment