This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log('test') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<meta name="csrf-token" content="{{ csrf_token() }}"> | |
<title>Laravel + Vue</title> | |
</head> | |
<body> | |
<div id="app"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const generatePayload = require('promptpay-qr') | |
const qrcode = require('qrcode') | |
const fs = require('fs') | |
const mobileNumber = '000-000-0000' | |
const IDCardNumber = '0-0000-00000-00-0' | |
const amount = 0 | |
const payload = generatePayload(mobileNumber, { amount }) //First parameter : mobileNumber || IDCardNumber | |
console.log(payload) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3" | |
services: | |
sonarqube: | |
image: sonarqube | |
command: -Dsonar.ce.javaOpts=-Xmx2048m -Dsonar.web.javaOpts=-Xmx2048m | |
ports: | |
- "9000:9000" | |
- "9092:9092" | |
networks: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const moment = require('moment') | |
const endDateOfMonth = moment().endOf('month').format('DD') | |
const currentDate = moment().format('DD') | |
let message = '' | |
console.log({currentDate, endDateOfMonth}) | |
if(currentDate == endDateOfMonth) { | |
message = `วันนี้เป็นวันสิ้นเดือนจ้า เย่เย้ ~~ 😁😁` | |
} else { | |
message = `อีก ${endDateOfMonth - currentDate} วัน จะสิ้นเดือน สู้สู้จ้า 🎉🎉` | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const request = require('request') | |
request({ | |
method: 'POST', | |
uri: 'https://notify-api.line.me/api/notify', | |
headers: { | |
'Content-Type': 'application/x-www-form-urlencoded' | |
}, | |
auth: { | |
'bearer': <access_token> //คัดลอก line notify access token มาวางไว้ที่นี้ | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const functions = require('firebase-functions') | |
const moment = require('moment') | |
const request = require('request') | |
exports.CountEndOfMonth = functions.pubsub.schedule("0 7 * * *").timeZone('Asia/Bangkok').onRun((context) => { | |
const endDateOfMonth = moment().endOf('month').format('DD') | |
const currentDate = moment().format('DD') | |
let message = '' | |
if (currentDate === endDateOfMonth) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exports.CountEndOfMonth = functions.pubsub.schedule("* * * * *").timeZone('Asia/Bangkok').onRun((context) => { | |
const endDateOfMonth = moment().endOf('month').format('DD') | |
const currentDate = moment().format('DD') | |
let message = '' | |
if (currentDate === endDateOfMonth) { | |
message = `วันนี้เป็นวันสิ้นเดือนจ้า เย่เย้ ~~ 😁😁` | |
} else { | |
message = `อีก ${endDateOfMonth - currentDate} วัน จะสิ้นเดือน สู้สู้จ้า 🎉🎉` | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const nodemailer = require("nodemailer"); | |
async function main() { | |
let transporter = nodemailer.createTransport({ | |
host: "smtp.mailtrap.io", | |
port: 2525, | |
auth: { | |
user: "", // SMTP username from mailtrap | |
pass: "", // SMTP password from mailtrap | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div id="app"></div> | |
</template> | |
<script> | |
import pdfMake from 'pdfmake' | |
export default { | |
name: 'App', |
OlderNewer