text stringlengths 7 3.69M |
|---|
const ZtMeta = require("../lib");
it("list database method with system",()=>{
let ztmeta=new ZtMeta({
host:'127.0.0.1',
user:'root',
password:'123456'
});
let data_actual=[''];
ztmeta.listDatabases({},(err,dbs,info)=>{
// expect(typeof data).toBe('object');
expec... |
/* 🤖 this file was generated by svg-to-ts*/
export const EOSIconsAbstract = {
name: 'abstract',
data: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M16 3H8a2 2 0 00-1.71 1l-4 7a2 2 0 000 2l4 7A2 2 0 008 21h8a2 2 0 001.74-1l4-7a2 2 0 000-2l-4-7A2 2 0 0016 3z"/></svg>`
};
|
const express = require('express');
const controller = require('./sowing.controller');
//const authJWT = require('../../middlewares/authJWT');
const router = express.Router();
router.get('/', controller.getSowings); // Coleccion (plural)
router.get('/:id', controller.getSowing)... |
console.log("connected")
////////////addEventListener////
function hiddelton(){
console.log("I got picked by taylor on her jet");
var div = document.createElement('div');
div.setAttribute('id', 'just-an-id')
document.body.appendChild(div);
document.getElementById("just-an-id").innerHTML="Hidd: mom meet my... |
// LICENSE BELOW IS FOR ACCESSIBILITY FUNCTIONS
/*
============================================
License for Application
============================================
This license is governed by United States copyright law, and with respect to matters
of tort, contract, and other causes of action it is governed by... |
// pages/order_wuliu/order_wuliu.js
const request_01 = require('../../utils/request/request_01.js');
const method = require('../../utils/tool/method.js');
const router = require('../../utils/tool/router.js');
const authorization = require('../../utils/tool/authorization.js');
const alert = require('../../utils/tool... |
// An array of all the questions
const questionsArr =[
{question: "HTML stands for?",
correctAnswer: "Hyper Text Markup Language",
incorrectAnswersArr: ["High Text Markup Language", "Hyper Tabular Markup Language", "None of these"]
},
{
question: "Which of the following tag is used to mark a beginning ... |
const initialState = {
map: {},
}
const expresses = function (state = initialState, action) {
switch (action.type) {
case 'FETCH_EXPRESS_SUCCESS':
const { id, express } = action.payload
state.map[id] = express
return { ...state }
default:
return state
}
}
export default expresses... |
import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
export class Input extends React.Component {
constructor(props) {
super(props);
this.state = {
value: props.value || "",
touched: false
};
this.handleOnChange = this.handleOnChange.bind(t... |
(function (angular) {
"use strict";
function CountryController($scope, $http) {
$http.get('../demo-data/countries.json').success(function (data) {
$scope.countries = data;
});
}
angular.module('app1', [])
.controller('CountryController', CountryController);
})(window.angular);
|
//Meteor.methods({
// getCities : function(){
// return Cities.find();
// }
//}) |
import React, { Component } from 'react';
import './index.css';
import partnershipsLabel from './partnerships_label.svg';
import stoneLabel from './stone_label.svg';
import goldLabel from './gold_label.svg';
import platinumLabel from './platinum_label.svg';
import thanks from './thanks.svg';
import BalsamiqLogo from... |
/**
* Created by admin on 09-10-2015.
*/
quizMod.controller('QuizController',function($scope,QuizService){
$scope.question = {};
})
|
import React from 'react';
import './App.scss';
function App () {
return (
<React.Fragment>
<h1>Custom Create-React-App template and setup</h1>
<h2>
Start by editing <code>src/components/App/App.jsx</code>
</h2>
</React.Fragment>
);
}
export default App;
|
// cards array holds all cards
let card = global.window.getElementsByClassName("card");
let cards = [...card];
// deck of all cards in game
const deck = global.window.getElementById("card-deck");
// declaring variable of matchedCards
let matchedCard = global.window.getElementsByClassName("match");
// close icon in m... |
const mongoose = require("mongoose");
const user = mongoose.Schema({
login: { type: String, required: true },
fullName: { type: String, required: true },
email: { type: String, required: true },
rol: { type: String, required: true, default: "Vendedor" },
estado: { type: String, required: true, default: "Pend... |
/**
* @param {number[]} houses
* @param {number[]} heaters
* @return {number}
*/
var findRadius = function(houses, heaters) {
var n = heaters.length, j = 0, res = 0;
houses.sort((a,b) => {
return a-b;
});
heaters.sort((a,b) => {
return a-b;
});
for(var i = 0 ; i < houses.length; i++) {
var c... |
import Vue from 'vue'
import App from './App.vue'
import router from './router'
// 引入muse-ui
import MuseUI from 'muse-ui';
import 'muse-ui/dist/muse-ui.css';
import 'typeface-roboto'
Vue.use(MuseUI)
Vue.config.productionTip = true
new Vue({
router,
render: h => h(App)
}).$mount('#app')
|
var NUM_HISTS = 50;
var NUM_LINES = 50;
var SW = 640;
var SH = 480;
var MAX_DIST = 400;
var TIMEOUT_MSEC = 16;
var Z_FACTOR = 200;
var WIDTH_FACTOR = 50;
var LINE_VEL = 20;
var CAM_VEL_FACTOR = 30;
var FILL_ALPHA = 10;
var FILL_ALPHA_STR = '';
var V = function(x, y, z) {
if (this == window)
return new V(x, ... |
import styled from 'styled-components';
import React from 'react';
function Logo() {
return (
<svg xmlns="http://www.w3.org/2000/svg" width="208.664" height="78.221" viewBox="0 0 208.664 78.221">
<g id="Group_1" data-name="Group 1" transform="translate(-179 -495)">
<text id="Elixir" transform="tra... |
const secondHand = document.querySelector('.secondHand');
const minuteHand = document.querySelector('.minuteHand');
const hourHand = document.querySelector('.hourHand');
const body = document.querySelector('body');
function setDate() {
const now = new Date();
const seconds = now.getSeconds();
const secondsDegre... |
// import your node modules
const express = require('express');
const cors = require('cors');
const db = require('./data/db.js');
// add your server code starting here
const server = express();
server.use(cors());
server.get('/api/posts', (request, response) => {
db
.find()
.then(posts => {
... |
import './details.css'
import {withRouter} from 'react-router';
// import '../../js/common'
// import $ from '../../js/jquery-3.2.1'
// import '../../js/details'
// import '../../js/swipeslider.min'
import React from 'react'
import http from '../../utils/httpclients'
var styleh1 = {
position: 'sticky',
top: ... |
'use strict';
var letter = "abcdefghijklmnopqrstuvwxyz";
function get_letter_com(num, result){
if(parseInt(num/26)){
var char = ""
char += letter[parseInt(num/26)-1] + letter[num % 26];
result.push(char);
}else{
result.push(letter[num]);
}
return result;
}
function get_letter_interval_2(number_a, number... |
/**
* @license Licensed under the Apache License, Version 2.0 (the "License"):
* http://www.apache.org/licenses/LICENSE-2.0
*/
/**
* @fileoverview Blocks for Arduino Tone generation
* The Arduino function syntax can be found at
* https://www.arduino.cc/en/Reference/tone
*
*/
'use strict';
goo... |
import React, { Component } from "react"
import { logout } from "../../helpers/auth"
export default class ForumNav extends Component {
render() {
return(
<nav class="navbar navbar-expand-md navbar-light bg-light">
<a class="navbar-brand"><img src="../../../../icon.png" alt="Logo... |
import Grow from './Grow'
import Fade from './Fade'
import Slide from './Slide'
export default {
Grow,
Fade,
Slide,
}
|
/**
* Expanded Math Object
*/
// var myMath = Object.create(Math);
//
// myMath.randomInt = function (max, min = 0){
// return Math.floor(Math.random() * (max - min + 1) + min);
// }
//
// console.log(myMath.randomInt(5)); // 3 for example
// console.log(myMath.randomInt(10)); // 10 for example
// console.log(myMat... |
angular.module('notebook', [])
.controller('NotebookController', function ($scope, $location, Notebook) {
$scope.allNotebooks = [];
$scope.notebook = {
title: ''
};
$scope.useNotebook = function(notebook) {
Notebook.currentNotebook = notebook;
$location.url('/display-notes');
};
$scope.save... |
import { FlowRouter } from 'meteor/ostrio:flow-router-extra';
import './home.html';
Template.home.events({
'click .js-logout'(event, instance) {
Meteor.logout();
},
'click .js-learn'(event, instance) {
FlowRouter.go('/apprendre');
},
'click .js-train'(event, instance) {
Flo... |
import React, {Component,StyleSheet,Text,TouchableHighlight,View, Dimensions, TouchableOpacity} from 'react-native';
const hairlineWidth = StyleSheet.hairlineWidth;
const window = Dimensions.get('window');
class TouchableButton extends TouchableHighlight {
touchableGetHighlightDelayMS() {
return 50;
}
}
ex... |
var jsfac = (function (self) {
var _utils = {
isNullOrWhitespace: function (string) {
return !string ? true : !/\S/.test(string);
},
isString : function(obj){
return typeof obj !== typeof "string";
},
isUndefined: function(ob){
return typ... |
/* eslint-disable */
/* global angular */
/* global document */
/* global localStorage */
/* global introJs */
angular.module('mean.system')
.controller('GameController',
[
'$scope',
'game',
'dashboard',
'$timeout',
'$http',
'$location',
'MakeAWishFactsService',
'$f... |
export default class EventEmitter {
constructor() {
this.eventListStore = {};
}
getEventInfo(eventName) {
const [event, ...rest] = eventName.split(':');
const id = rest.join(':');
return [event, id];
}
on(eventInfo, cb) {
const [event, id] = this.getEventInf... |
import React from 'react';
import { InView } from 'react-intersection-observer';
const Hobby = (props) => {
const { id, desc, img, alt, value } = props.properties;
let counter = (active, e) => {
if (active) {
const currentHobby = document.getElementById(e);
const hobbyValue = currentHobby.value... |
export let one = 1;
let two = 2;
export {two}; //сущность чего то экспортируется в скобках
export default function sayHi(){ //default - экспорт по умолчанию
console.log("hello");
} |
var vm = Backbone.ViewManager = {};
vm.Core = (function() {
var _regions = {};
return {
// register a region
// name: a unique name for this region
// selector: a DOM selector for this region
addRegion: function(name, selector) {
_regions[name] = {
e... |
import React from "react";
import { shallow, mount } from "enzyme";
import GuessCount from "./guess-count";
describe("Render Guess Count", () => {
it("renders Guess Count", () => {
shallow(<GuessCount />);
});
it('renders guess count plural', () => {
const wrapper = shallow(<GuessCount guessCount={3} /... |
// test 27
function filterArray(numbers, value) {
// Пиши код ниже этой строки
const filteredNumbers = [];
for (const num of numbers) {
const number = num;
if (number > value) {
filteredNumbers.push(number);
}
}
return filteredNumbers;
}
console.log(filterArray([1, 2, 3, 4, 5], 3));
consol... |
// 处理列表加载更多和刷新
/**
*
* @param {*Object} params // 参数
* @param {*Object} respone // 接口返回数据
* @param {*Arrary} prevData // 已经获取的数据
*/
export function handleListLoadMore(params, respone, prevData) {
let _data;
if (params.page === 1) {
_data = respone ? respone.data : [];
} else {
_data = respone ? [...p... |
import React from "react";
import styled from "styled-components";
export const Filter = ({ filter, setFilter, currentPage, setCurrentPage }) => {
return (
<>
<Wrapper>
<Button
onClick={() =>
currentPage === 1
? alert("Already at the beginning!")
: ... |
import React, { Component } from 'react';
import axios from 'axios';
class ReviewComponent extends Component{
constructor(){
super();
this.state={
Reviews:null
}
}
componentDidMount(){
const { resID }=this.props.location.state;
const URL='https://develope... |
import React, { PureComponent } from "react";
import { expect } from "chai";
import { render, cleanIt, jsdom } from "reshow-unit";
jsdom(null, { url: "http://localhost" });
import { AjaxPage, ajaxDispatch } from "organism-react-ajax";
import urlStore from "../stores/urlStore";
describe("Test Handle New Url", () => {
... |
import { REHYDRATE } from 'redux-persist/constants';
import * as types from 'kitsu/store/types';
function updateObjectInArray(array, entry) {
return array.map((currentItem) => {
if (currentItem.id !== entry.id) {
return currentItem;
}
return {
...currentItem,
...entry,
};
});
}
... |
let year = (new Date()).getFullYear();
if(year != 2019)
$("#year").html("- "+year);
|
/**
* 全局动画配置
* @author: terry <jfengsky@gmail.com>
* @date: 2013-10-21 10:47
*/
define(function(require, exports, module) {
var $ = require('jquery');
require('jquery-easing');
function Move(id, obj, fn){
$(id).animate(obj, 100, 'swing', fn);
};
module.exports = Move;
}); |
var spawn = require('child_process').spawn
var env = process.env.NODE_ENV === 'production' ? 'prod' : 'dev'
console.log('> run node in ' + env)
spawn('npm', ['run', env], { stdio: 'inherit' })
|
var express = require('express');
var router = express.Router();
var db = require('../db/queries');
const { loginRequired } = require("../auth/helpers");
/*------------------------------GET Request------------------------------------*/
router.get('/logout', loginRequired, db.logoutUser);
router.get('/sortedconceptsbyl... |
import React, { useEffect, useState } from 'react';
import formatCurrency from '../helper/currency';
import Fade from 'react-reveal/Fade';
import { connect } from "react-redux";
import { removeFromCart } from "../actions/productActions";
function Cart(CartData) {
const [proceed, setProceed] = useState(false... |
/* global navigator */
(function () { // eslint-disable-line wrap-iife,func-names
if (typeof navigator.serviceWorker !== 'undefined') {
navigator.serviceWorker.register('js/sw.js');
}
})();
|
'use strict';
var dragula = require('dragula');
/*jshint unused: false*/
function register (angular) {
return ['dragulaService', function angularDragula (dragulaService) {
return {
restrict: 'A',
scope: {
dragulaScope: '=',
dragulaModel: '='
},
link: link
};
func... |
module.exports = function (channel, queueName) {
channel.prefetch(1);
channel.assertQueue(queueName, {durable: false}).then(function (ok) {
console.log(' [*] Waiting for requests..');
channel.consume(queueName, function (message) {
var result = "HELLOOOOOOOO " + message.content.toSt... |
import sendgrid from '@sendgrid/mail'
try {
sendgrid.setApiKey(process.env.SENDGRID_API_KEY)
} catch (error) {
console.log(error)
}
const emailService = () => ({
sendMail: async (to, subject, name) => {
return sendgrid.send({
to,
from: 'vieiraneto88@gmail.com',
templateId: process.env.TMPL... |
import React, { useState } from "react";
import "antd/dist/antd.css";
import "../css/LectureMenu.css";
import { Menu } from "antd";
import { Link } from "react-router-dom";
import { firebaseApp } from "./Firebase";
const setShow = (number) => {
var isShow;
firebaseApp
.database()
.ref("Lecture/Inform/Lectu... |
const sqlite3 = require('sqlite3').verbose();
/**
* Get scan of next level one. Async mode.
* @param {string} dir - Project directory
* @param {number} minrt - minimum retention time
* @param {number} maxrt - maximum retention time
* @param {number} minmz - minimum m/z
* @param {number} maxmz - maximum m/z
* @pa... |
//
// LLamadas a la API
//
//
const URLAPI = "https://ctd-todo-api.herokuapp.com/v1";
const usuarios = {
//
// metodo crear un nuevo usuario
// @param String nombre
// @param String apellido
// @param String correo
// @param String contrasenna
// @return Promise
//
registrar: (nombre, apellid... |
let x = 10;
function text() {
console.log(x);
}
global.num=x;
global.f=text; |
import styled from 'styled-components/native';
export const Container = styled.SafeAreaView`
flex: 1;
padding: 30px;
`;
export const Content = styled.View`
border: 1px solid #ddd;
border-radius: 4px;
`;
export const Question = styled.View`
padding: 20px;
flex-direction: row;
flex-wrap: wrap;
`;
export... |
const jwt = require('jsonwebtoken');
const { constants } = require("../helpers/constants");
const apiResponse = require('../helpers/apiResponses');
const authenticateJWT = (req, res, next) => {
const authHeader = req.headers.authorization;
if (authHeader) {
const token = authHeader.split(' ')[1];
... |
'use strict';
angular.module('userAuth', [])
.constant('USER_ROLES', {
user : 'user',
admin : 'admin'
})
.factory('JWTInterceptor', [ '$window',
function ($window) {
return {
request : function (config) {
config.headers = config.headers || {};
if ($wi... |
/*!
* More Math JS <https://github.com/smujmaiku/moremath-js>
* Copyright(c) 2016-2019 Michael Szmadzinski
* MIT Licensed
*/
const objEntries = obj => Object.keys(obj).map(k => [k, obj[k]]);
/**
* Evalulates for valid numbers
* @param {*} val
* @returns {boolean}
*/
function isNumber(val) {
return typeof val... |
import React, { Component } from 'react';
import { Map, GoogleApiWrapper, Marker, InfoWindow } from 'google-maps-react';
import './Map.css';
class GoogleMap extends Component {
state = {
activeMarker: this.props.activeMarker
};
displayRestaurants = () => {
if (this.props.restaurants) {
return this.props.re... |
"use strict";
// Written by Mohammed Farghally and Cliff Shaffer
$(document).ready(function () {
var av = new JSAV("UFconcomCON", {"animationMode": "none"});
var gr = av.ds.graph({width: 500, height: 300,
layout: "manual", directed: false});
var a = gr.addNode("A", {"left": 0, "top": 10... |
const User = require('../models/User');
const bcrypt = require('bcrypt');
function add(req, res) {
let { username, email, message } = req.session;
res.render('users/register', {
title: 'Register User',
message,
username,
email,
});
}
function getLogin(req, res) {
let message = req.session.mess... |
const mongoose = require('mongoose');
// const recipeSchema = mongoose.Schema({
// title: {
// type: String,
// required: true,
// minLength: 5,
// trim: true,
// },
// description: {
// type: String,
// required: true,
// minLength: 10,
// trim: true,
// },
// image: {
// ... |
module.exports = {
extraction: (apiData) => {
let result = [];
for(var i = 0; i < apiData.length; i++) {
let temp = {};
temp.code = apiData[i].data[0].code.split('-')[1];
temp.openingPrice = apiData[i].data[0].openingPrice;
temp.highPrice = apiData[i].... |
(function () {
'use strict';
angular.module('category', ['cetegory-details'])
.config(categoryConfig);
/*@ngInject*/
function categoryConfig($stateProvider) {
$stateProvider
.state('category', {
url: "/category",
parent: 'page',
views: {
'content@page': {
templateUrl: 'main/category... |
angular.module('app.signin', ['app.services'])
.controller('signinController', ['$scope', '$location', 'HttpRequests', function($scope, $location, Signin){
$scope.user = {
talents: []
};
$scope.newTalent = {};
$scope.addTalent = function(){
if ( $scope.newTalent.talent !== "" && $scope.newTalent.lev... |
import {StyleSheet} from 'react-native';
export default StyleSheet.create({
inputsWrapper: {
marginVertical: 15,
marginBottom: 45,
},
footerWrapper: {
height: 50,
flex: 1,
justifyContent: 'center',
alignItems: 'center',
},
});
|
import React, { useState } from 'react'
import { deletePole } from '../../../store/ducks/poles/fetch-actions'
import { Table } from 'react-bootstrap'
import { useDispatch, useSelector } from 'react-redux'
import { Button, Spinner } from 'react-bootstrap'
import { Trash, PencilSquare } from 'react-bootstrap-icons'
impor... |
import React, { Component } from 'react';
import { ScrollView, View, TouchableOpacity, Text } from 'react-native';
import { Tabs, Tab, Icon } from 'react-native-elements'
export default class ScreenD extends Component {
constructor() {
super()
this.state = {
hideTabBar: false,
... |
function centerOf(string) {
let halfLength = string.length / 2
if (parseInt(halfLength) === halfLength) {
return string[halfLength - 1] + string[halfLength]
} else {
return string[Math.floor(halfLength)]
}
}
console.log(centerOf('I Love JavaScript')); // "a"
console.log(centerOf('Launch School')); ... |
import { eventBus } from '../../../service/eventBus';
import { Utils } from '../../../helpers/Utils';
export class ViewTodo {
constructor() {
this.todoContainer = document.querySelector('.todo-container-js');
this.todoBtn = document.querySelector('.todo-btn-js');
this.todoList = document.querySelector('.... |
const mongoose = require('mongoose');
const projectsSchema = new mongoose.Schema({
name: {type: String},
img: {type: String},
url: {type: String},
description: {type: String}
});
const Projects = mongoose.model('Projects', projectsSchema);
module.exports = Projects;
|
import BaseLfo from '../../core/BaseLfo';
import SourceMixin from '../../core/SourceMixin';
const AudioContext = window.AudioContext || window.webkitAudioContext;
const definitions = {
frameSize: {
type: 'integer',
default: 512,
constant: true,
},
channel: {
type: 'integer',
default: 0,
... |
import React from "react";
import withUserInfo from "./withUserInfo";
import Avatar from "../BaseComponents/Avatar";
export default withUserInfo(
({ user }) => user && user.avatarSrc && <Avatar user={user} />
);
|
const randomAnswers = [
{id: 1, a: 'I like to settle these sorts of issues with a good old fashioned game of catchphrase'},
{id: 2, a: 'Never eat mayonaise. It\'s disgusting.'},
{id: 3, a: 'Yes'},
{id: 4, a: 'No, that\'s a bad idea.'},
{id: 5, a: 'When in doubt, annoy your mentors.'},
{id: 6, a... |
define(['jquery','template','nprogress','bootstrap'],function($,template,NProgress){
//1.1发请求
$.get('/api/teacher',function(data){
console.log(data.code);
if(data.code==200){
//1.2把请求得到的数据放到页面中去
var html=template('tpl_data',{list:data.result});
//1.3把最终的html字符串添加到dom中
$('#tec_list tbody').html(html);
... |
// underscore 是一个开源库,提供了丰富的高性能的对数组,集合等的操作
// api 手册:http://learningcn.com/underscore
// 为了少加载不必要的代码,默认是不引入 underscore 的,需要用到的话
// 将define所在中的'underscore'的注释去掉即可。即改为
// define(['underscore'], function() {
// ...
// });
define([/* 'underscore' */], function() {
// data 是Graph的输入数据。
// 使用data... |
import React from 'react';
import PropTypes from 'prop-types';
const InStock = ({ inStock }) => (
<div>
{inStock <= 5 &&
<span className="size-medium color-price">
{`Only ${inStock} left in stock - order soon.`}
</span>}
{inStock > 5 &&
<span className="size-medium color-success">
In ... |
/**
* 화면 초기화 - 화면 로드시 자동 호출 됨
*/
function _Initialize() {
// 단위화면에서 사용될 일반 전역 변수 정의
// $NC.setGlobalVar({
// });
// 그리드 초기화
grdT1MasterInitialize();
grdT1DetailInitialize();
grdT1SubInitialize();
grdT2MasterInitialize();
// 탭 초기화
$NC.setInitTab("#divMasterView", {
tabIndex:... |
// lesson 3
import _ from "lodash";
const normalize = (obj) => {
obj.name = obj.name.substr(0, 1).toUpperCase() + obj.name.substr(1).toLowerCase();
obj.description = obj.description.toLowerCase();
return obj;
};
export default normalize;
// lesson 4
const is = (obj1, obj2) => {
if ((obj1.name === obj2.name... |
// This references the #pointr id tag in your HTML markup.
let pointr = document.getElementById('pointr');
document.addEventListener('mousemove',
function(e) {
var x = e.clientX;
var y = e.clientY;
pointr.style.left = x + 'px';
pointr.style.top = y + 'px';
}
); |
// 云函数入口文件
const cloud = require('wx-server-sdk')
cloud.init()
const db = cloud.database()
// 云函数入口函数
exports.main = async(event, context) => {
var result
var userInfo
if (event.validateUserResult) {
userInfo = event.validateUserResult.userInfo
if (event.validateUserResult.isAdmin) {
result = awai... |
import React from "react";
import { makeStyles } from '@material-ui/core/styles';
import CardMedia from '@material-ui/core/CardMedia';
import Typography from '@material-ui/core/Typography';
import Grid from '@material-ui/core/Grid';
import IconButton from '@material-ui/core/IconButton';
import FacebookIcon from '@mat... |
/******** Korea Main Jquery 2017 *********/
/* visual */
$(function(){
var visualArea = $("#visualarea .area");
var visualCont = visualArea.find(".txt");
var current = 0;
var active;
var returnNodes;
var last;
visualCont.css({"opacity":0}).hide().eq(0).css({"opacity":1}).show();
visualCont.ea... |
$('.link-select').select2({
ajax: {
url: $('.link-select').data('url'),
delay: 250,
type: 'POST',
dataType: 'json',
data: function (params) {
var query = {
name: params.term,
}
return query;
},
processResults... |
import React, { Component } from 'react';
import { Route, Link,Router } from 'react-router-dom';
import './App.css';
import Users from "./users";
import Moment from 'moment';
import idBox from "./IDbox";
import Groups from "./groups";
import Settings from "./settings";
import Select from 'react-select';
import DyDrop f... |
const passport = require('passport');
const GoogleStrategy = require('passport-google-oauth').OAuth2Strategy;
const Users = require('../users/users.entity');
const configAuth = require('../../config/config.js');
passport.use(new GoogleStrategy({
clientID: configAuth.GOOGLE_AUTH.clientID,
clientSecret: configAu... |
exports.up = function(knex) {
return knex.schema.createTable('projetos', table => {
table.increments('id').primary();
table
.string('nome')
.notNull()
.unique();
});
};
exports.down = function(knex) {
return knex.schema.dropTable('projetos');
};
|
/** @type {import('tailwindcss').Config} */
module.exports = {
darkMode: 'class',
content: [`./src/pages/**/*.{js,jsx,ts,tsx}`, `./src/templates/**/*.{js,jsx,ts,tsx}`, `./src/components/**/*.{js,jsx,ts,tsx}`],
theme: {
fontFamily: {
sans: ['Mona Sans', `-apple-system`, `system-ui`, `BlinkMacSystemFont`,... |
'use strict';
const Service = require('egg').Service;
const path = require('path');
const fs = require('fs');
const request = require('request');
const WebHDFS = require('webhdfs');
const xlsx = require('xlsx');
const PassThrough = require('stream').PassThrough;
const hdfs = WebHDFS.createClient({
user: 'hdfs',
ho... |
import {
displayTeacherInfo
} from './app.js';
import {
displayStudentInfo
} from './app.js';
const requestingLogingInfos = (usernameValue, passwordValue) => {
const user = {
"username": usernameValue,
"password": passwordValue
}
let chosenData = document.querySelector('select').va... |
/**
* Created by myl17 on 2017/9/12.
*/
module.exports = {
entry: './app.js',
output: {
filename: 'bundle.js'
}
} |
jQuery(function($){
$("#submit_payment_confirmation").click(function(){
if ( $("#order-number").val() == '' ) {
alert("Error : Masukan Order Number");
$("#order-number").focus();
return false;
} else if ( $("#payment-code").val() == '' ) {
alert("Error : Masukan Kode Pembayaran");
$("#payment-cod... |
WAF.onAfterInit = function onAfterInit() {// @lock
// @region namespaceDeclaration// @startlock
var btnAdd = {}; // @button
var btnCompleted = {}; // @button
var btnAll = {}; // @button
var btnActive = {}; // @button
// @endregion// @endlock
// eventHandlers// @lock
btnAdd.click = function btnAdd_click (event... |
import React from "react";
import "components/InterviewerList.scss";
import InterviewerListItem from "./InterviewerListItem";
import PropTypes from "prop-types";
export default function InterviewerList(props) {
const parsedInterviewers = props.interviewers.map((inter) => {
return (
<InterviewerListItem
... |
$('#ratingForm .ratingRadio').change(function () {
$('#ratingForm').submit();
});
|
let output = "";
for (let i = 100; i <= 200; i++) {
//Clear output first every time
output = "";
//Check for first condition
if (i % 3 === 0) {
output += "Loopy";
}
if (i % 4 === 0) {
output += "Lighthouse";
}
if (!(i % 3 === 0 || i % 4 === 0)) {
output = i;
}
console.log(output);
} |
const base_url = 'http://localhost:3000'
$(document).ready(() => {
auth()
$('#login').on('click', (e) => {
e.preventDefault();
$('#register-form').hide()
$('#login-form').show()
})
$('#register').on('click', (e) => {
e.preventDefault();
$('#login-form').hide()
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.