ได้ทำการเพิ่มบทบาทในระบบ DCenter เพื่อเข้าใช้งาน API Claim ในส่วนของ Production Zone เรียบร้อยครับ
Tip-m30 กันลืม
วันพุธที่ 17 เมษายน พ.ศ. 2567
วันพุธที่ 6 มีนาคม พ.ศ. 2567
เทียบเวลามาตรฐาน
ทดสอบบน Ubuntu 14.04 LTS
1. การเทียบเวลาให้ตรงกับServer Clock ของมหาวิทยาลัย
- ด้วยคำสั่ง sudo ntpdate winnie.rmutsv.ac.th
- หากต้องการให้ตั้งเทียบเวลาอัตโนมัติทุกวัน ให้สร้างแฟ้มชื่อ /etc/cron.daily/update-time มีข้อมูลว่า
/usr/sbin/ntpdate pool.ntp.org
แก้ไขให้แฟ้มนี้สามารถ execute ด้วยคำสั่ง sudo chmod +x /etc/cron.daily/update-time
แล้วสั่งให้ cron ทำงานใหม่ด้วยคำสั่ง sudo service cron restart
หากไม่ตั้งเทียบเวลาทุกวัน นาฬิกาจะเดินผิดพลาดไปวันละประมาณ 2 วินาที
ที่มา http://www.phuketadmin.org/index.php?topic=7210.0
วันพุธที่ 24 มกราคม พ.ศ. 2567
Script Backup Database
.สคริปต์สำรองข้อมูล MySQL บนระบบปฏิบัติการลีนุกซ์
1. backup_all_db.sh ==> สำรองรวมทุกดาต้าเบสเป็น 1 ไฟล์
2. backup_all_db2.sh ==> สำรองแยกดาต้าเบสออกเป็นหลายไฟล์เท่ากับจำนวนดาต้าเบสที่มีใน MySQL Server นั้นๆ
backup_all_db.zip
https://drive.google.com/file/d/1XQvnwVsSAwlmVgMivpxpaKPzl4Qq0a1-/view?usp=sharing
backup_all_db2.zip
https://drive.google.com/file/d/1YgYIJ6ALNKooFhURvlKUYOTTzKwRSddj/view?usp=sharing
วันจันทร์ที่ 15 มกราคม พ.ศ. 2567
Proxmox
https://www.youtube.com/watch?v=9d-f_Qupthk สอนเครื่องมือและการติดตั้ง Ubuntu
https://www.flash2hack.com/?p=543 // Install LAMP Stack on Proxmox
https://youtu.be/H1t6hxCoiZw?si=nIrbPSKTUVi8WF3zNew Proxmox Import Wizard for Migrating VMware ESXi VMs
MariaDB will not install with CT + systemd
วันพฤหัสบดีที่ 14 ธันวาคม พ.ศ. 2566
Moph Claim
::::API:::
D506 POST :::: $url = "https://epidemcenter.moph.go.th/epidem506/api/Send506";
EPI:: POST
https://claim-nhso.moph.go.th/api/v1/opd/service-admissions/epi
DM:: POST
https://claim-nhso.moph.go.th/api/v1/opd/service-admissions/dmht
วันศุกร์ที่ 8 ธันวาคม พ.ศ. 2566
Yii2 Spinner
html
<div id="loading-spinner" style="display: none;">
<!-- Add your spinner image or loading text here -->
Loading...
</div>
หรือ
<div id="loading-spinner" style="display: none; color: purple; font-size: 20px;">
<!-- Customize the text and style as needed -->
<strong>Loading...</strong>
</div>
<javascript>
<script>
$(document).ready(function() {
$('.popup-link').click(function(e) {
e.preventDefault();
var url = $(this).data('url');
openModalWithData(url);
});
$('#selectAll').click(function() {
// Show the spinner when the button is clicked
$('#loading-spinner').show();
});
// Assuming you have a form with the class 'your-form-class'
$(document).on('beforeSubmit', 'form[name="frmMain"]', function() {
// Show the spinner before form submission
$('#loading-spinner').show();
return true;
});
// If you're using Pjax, hide the spinner on successful Pjax response
$(document).on('pjax:success', function() {
$('#loading-spinner').hide();
});
// If you're not using Pjax, hide the spinner on any AJAX request completion
$(document).ajaxStop(function() {
$('#loading-spinner').hide();
});
});
function openModalWithData(url) {
$.ajax({
url: url,
method: 'GET',
success: function(response) {
$('#myModal .modal-body').html(response);
$('#myModal').modal('show');
},
error: function() {
alert('An error occurred while fetching data.');
}
});
}
</script>