Skip to content

Instantly share code, notes, and snippets.

View nihat-js's full-sized avatar
📑
Reading Documentation ...

Nihat nihat-js

📑
Reading Documentation ...
View GitHub Profile
<div class="w-full flex justify-between mt-8 gap-5">
<button class="group/button relative overflow-hidden rounded-md bg-secondary px-4 py-1 text-xs font-medium text-red-500 transition-all duration-150 hover:border-red-500 active:scale-95 w-full"><a href="https://youtu.be/U9XuioCIbFE" target="_blank"><span class="absolute bottom-0 left-0 z-0 h-0 w-full bg-gradient-to-t from-red-600 to-red-500 transition-all duration-500 group-hover/button:h-full"></span><span class="relative z-10 transition-all duration-500 group-hover/button:text-white w-full flex justify-center"><div class="flex flex-col items-center"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-youtube"><path d="M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17"></path><path d="m1
<?php
namespace App\Services\Payment;
use App\Transaction;
use Request;
class Epoint
{
@nihat-js
nihat-js / Program.cs
Created August 16, 2024 08:42
Entity Framework Core with SQL Server Crud Sample
using Microsoft.EntityFrameworkCore;
using System.Numerics;
Console.WriteLine("Hello, World!");
var context = new ApplicationContext();
while (true) {
Console.WriteLine("" +
@nihat-js
nihat-js / P
Created August 16, 2024 08:06
Entity framework very very simple tutotrial with SQL Server Connection String
// See https://aka.ms/new-console-template for more information
using Microsoft.EntityFrameworkCore;
Console.WriteLine("Hello, World!");
var context = new ApplicationContext();
var users = context.Users.ToList();
foreach (var user in users) {
Console.WriteLine(user.Name + " " + user.Surname + " => " + user.Email);
}
SELECT
[STOCKREF] as product_remote_id,
SUM([ONHAND]) as quantity,
INVENNO as remote_warehouse_id
FROM LV_006_02_STINVTOT
WHERE STOCKREF in ( 6518,147,148,150,151,156,744,745,746,747,748,751,760,761,762,764,766,776,777,778,779,780,786,787,788,789,790,791,792,793,795,798,800,801,802,803,805,806,807,808,810,811,812,814,816,817,818,819,820,821,822,823,824,825,826,827,828,829,830,834,836,837,838,839,843,845,846,847,848,849,850,851,852,853,854,855,857,859,860,862,866,867,868,869,1333,1337,1340,1341,1343,1344,1345,1346,1347,1348,1349,1350,1351,1352,1353,1354,1373,1358,1359,1360,1361,1362,1363,1364,1365,1366,1367,1368,1369,1370,1371,1372,1374,1375,1376,1377,1378,6534,1380,1381,1382,1383,1384,1385,1386,1388,1390,1394,1396,1397,1398,1399,1400,1401,1403,1404,1405,1406,1407,1408,1409,1410,1411,1412,1414,1415,1416,1417,1418,1419,1420,1421,870,871,872,880,882,884,885,889,890,891,894,895,896,897,898,901
alert(JSON.stringify(localStorage))
console.log("should work")
$("#admin_basket_check_all").on("change",function(){
if ($(this).is(":checked")){
$("tbody [type='checkbox']").prop("checked",true)
}else{
$("tbody [type='checkbox']").prop("checked",false)
}
})
$(document).on("change","tbody [type='checkbox']",function(){
let isAllChecked = $("tbody input:checked").length === $("table tbody input:not(:checked)").length
@nihat-js
nihat-js / ikincfil.e
Created February 7, 2024 17:00
elave melumat
‎‎​
@nihat-js
nihat-js / User.model.js
Created December 13, 2023 22:34
mongoose-user-schema
const mongoose = require("mongoose")
const userSchema = new mongoose.Schema({
username: { type: String, required: true, unique: true, maxLength: 32, },
email: { type: String, required: true, unique: true, maxLength: 255, },
phone: { type: Number, default: null, },
password: { type: String, required: true, },
is_email_verified: { type: Boolean, default: false },
is_phone_verified: { type: Boolean, default: false },
is_private: { type: Boolean, default: false, },
register_info: { type: Object, required: true },
public class ZombieThreadTester {
public static void main(String[] args) {
Thread[] threads = new Thread[100];
for (int i = 0; i < 100; i++) {
threads[i] = new Thread(new MyRunnable(i));
}
for (int i = 0; i < 100; i++) {
threads[i].start();