/
home
/
efamember
/
domains
/
efa-member.com
/
public_html
/
backoffice
/
ajax
/
company_info
/
up file
home
<?php include("../../../config/main_function.php"); $secure = "cAh3DrJACzw4RbU"; $connection = connectDB($secure); if ($connection) { $search = mysqli_real_escape_string($connection, $_POST['search']); $company_status = mysqli_real_escape_string($connection, $_POST['company_status']); if ($company_status == '1') { $con_status = "AND company_status LIKE '%ยังดำเนิน%'"; } elseif ($company_status == '0') { $con_status = "AND company_status LIKE '%เลิกกิจการ%' OR company_status LIKE '%ยกเลิก%' OR company_status LIKE '%ปิด%'"; } else { $con_status = ""; } if ($search != '') { $con_search = "AND (company_name LIKE '%$search%' OR license_no LIKE '%$search%')"; } else { $con_search = ""; } $sql_member = "SELECT * FROM tbl_company_info WHERE active_status IS NOT NULL $con_search $con_status;"; $rs_member = mysqli_query($connection, $sql_member) or die($connection->error); } else { $arr['result'] = 9; $arr['message'] = "Connection Error"; } ?> <div class="table-responsive"> <table class="table table-striped table-bordered align-middle data_table"> <thead> <tr> <td style="width: 10%;">หมายเลขนิติบุคคล</td> <td style="width: 30%;">ข้อมูลบริษัท</td> <td style="width: 20%;">ติดต่อ</td> <td style="width: 10%;">ดูข้อมูล</td> </tr> </thead> <tbody> <?php while ($row = mysqli_fetch_assoc($rs_member)) { ?> <tr> <td> <?php echo $row['license_no']; ?> </td> <td> <strong class="thumb-info-inner"><?php echo $row['company_name']; ?></strong><br> <span><strong>กรรมการ : </strong><?php echo $row['authorized_person']; ?></span><br> <span><strong>หมายเลขใบอนุญาต : </strong><?php echo $row['legalentity_number']; ?></span><br> <span><strong>ทุนจดทะเบียน : </strong><?php echo $row['registered_capital']; ?></span><br> </td> <td> <span><strong>ที่อยู่ : </strong><?php echo $row['address']; ?></span><br> <?php if ($row['phone'] != ''): ?> <strong class="text-dark">โทร :</strong> <a href="tel:<?php echo $row['phone']; ?>"><?php echo $row['phone']; ?></a><br> <?php endif; ?> <?php if ($row['email'] != ''): ?> <strong class="text-dark">Email : </strong> <a href="mailto:<?php echo $row['email']; ?>"><?php echo $row['email']; ?></a><br> <?php endif; ?> <?php if ($row['company_line'] != ''): ?> <strong class="text-dark">Line : </strong> <a href="<?php echo $row['phone_line']; ?>" target="_blank">LINE</a><br> <?php endif; ?> </td> <td> <button class="btn btn-xs btn-<?php echo ($row['active_status'] == '1') ? "primary" : "danger"; ?> mb-2 btn-block" onclick="ChangStatus('<?php echo $row['company_id']; ?>')"><?php echo ($row['active_status'] == '1') ? "แสดง" : "ไม่แสดง"; ?></button> <a href="company_info_update?comp=<?php echo $row['company_id']; ?>" class="btn btn-success btn-xs btn-block mb-2 text-white">รายละเอียด</a> <button class="btn btn-xs btn-info w-100" id="DownloadAll" onclick="DownloadAll('<?php echo $row['company_id']; ?>')">ดาวน์โหลดข้อมูล</button> </td> </tr> <?php } ?> </tbody> </table> </div>