text
stringlengths
3
1.05M
""" legoBTLE.networking.server ========================== This package holds the classes to set up a server where devices can register and route message from and to the bluetooth sender/receiver. """ import asyncio import os from asyncio import AbstractEventLoop, StreamReader, StreamWriter, IncompleteReadError from ...
"""Tests for 'site'. Tests assume the initial paths in sys.path once the interpreter has begun executing have not been removed. """ import unittest import test.support from test.support import run_unittest, TESTFN, EnvironmentVarGuard from test.support import captured_stderr import builtins import os import sys impor...
from game.pkchess.objbase import BattleObjectModel __all__ = ["CharacterModel"] class CharacterModel(BattleObjectModel): pass
import sys, math, pdb from datetime import timedelta import pandas as pd import logging import numpy as np def combine_municipalities_data(municipality_id_df, municipality_data): municipality_ids = municipality_id_df['municipalityId'].unique() summary = None for municipality_id in municipality_ids: ...
/** * @license Apache-2.0 * * Copyright (c) 2018 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by a...
//C:\Users\Your Name>npm install mysql var mysql = require('mysql'); //Download MySQL and create user : http://dev.mysql.com/downloads/mysql/ var con = mysql.createConnection({ host: "localhost", user: "nodejs_user", password: "uqUYfgkUPL4TavWW" }); con.connect(function(err) { if (err) throw err; ...
from matplotlib import pyplot as plt from matplotlib import image as Image import numpy as np import math import sys import os class LineBuilder(): def __init__(self, scale, img_size ,line,line2,line3,line_paral_1,line_paral_2,text_1,line_ex1,line_ex2, line_relative, text_relative,result_name): self.line ...
# This script calls [PaCMAP](https://arxiv.org/abs/1910.00204) functions to operate on the TopOGraph class # TriMAP was originally implemented by Yingfan Wang at https://github.com/YingfanWang/PaCMAP. # This is rather a modular adaptation, and does not change much of the optimization algorithm. # The main change is the...
#!/usr/bin/env node // 初始化创建步骤选项列表 const { inquirerList, inquirerPrecssList, options, dependencies } = require('./store'); const inquirer = require('inquirer'); const store = require('./store'); module.exports = async function () { const answersStep = []; const submenu = ['precss']; await inquirerPro() await i...
#!/usr/bin/env python import asyncio import logging from typing import Any, Dict, List, Optional import ujson import hummingbot.connector.exchange.alpaca.alpaca_constants as CONSTANTS from hummingbot.connector.exchange.alpaca.alpaca_order_book import AlpacaOrderBook from hummingbot.connector.exchange.alpaca.alpaca_ut...
const apiproxy_revision = context.getVariable('apiproxy.revision'); const healthcheck_status_code = context.getVariable('healthcheckResponse.status.code'); const healthcheck_request_url = context.getVariable('healthcheckRequest.url'); const healthcheck_failed = context.getVariable("servicecallout.ServiceCallout.CallHe...
import React , { Component } from 'react'; import logo from '../../assets/curandoMe-white-logo-min.png'; import './Header.css' class Header extends Component{ render(){ return( <div className = "header"> <div className = "image"> <img src = { logo } className="img-fluid"...
casper.test.begin('Nested Viewmodels', 7, function (test) { casper .start('./fixtures/nested-vms.html') .then(function () { test.assertSelectorHasText('.ancestor', 'Andy Johnson') test.assertSelectorHasText('.jack', 'Jack, son of Andy') test.assertSelectorHasText('.mike', 'Mike...
'use strict'; angular.module('cpZenPlatform').factory('userUtils', ['$location', '$window', '$translate', '$state', '$rootScope', 'cdDojoService', 'cdUsersService', 'auth', 'usSpinnerService', 'alertService', 'permissionService', 'Analytics', function($location, $window, $translate, $state, $rootScope, cdDojoServi...
import{r as t,f as e,h as i,H as s,e as a}from"./p-212d0ebd.js";class n{constructor(i){t(this,i),this.transitioning=!1,this.tabs=[],this.useRouter=!1,this.onTabClicked=t=>{const{href:e,tab:i}=t.detail,s=this.tabs.find(t=>t.tab===i);if(this.useRouter&&void 0!==e){const t=document.querySelector("ion-router");t&&t.push(e)...
import { Typography } from "@material-ui/core"; import { LinkOut } from "../link/LinkOut" export default (props) => ( <Typography component={LinkOut} variant="h6" {...props}> {props.children} </Typography> );
//============================================================================= // ShowIncredibleActions.js // ---------------------------------------------------------------------------- // Copyright (c) 2017 Tsumio // This software is released under the MIT License. // http://opensource.org/licenses/mit-license.php /...
import React from 'react' import { useFormik } from 'formik'; import validationSchema from './validations'; function SignUp() { const {handleChange, handleSubmit, handleBlur, values, errors, touched} = useFormik({ initialValues: { email: '', password:'', passwordConfirm:'', }, onSubmit...
import torch import torch.nn as nn from torch.autograd import Variable import numpy as np class RandomShift(nn.Module): def __init__(self, shift_min, shift_max): super(RandomShift, self).__init__() self.shift_min = shift_min self.shift_max = shift_max def forward(self, x): #FI...
/** * Copyright (c) 2022 大漠穷秋. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ import { keyboardEvents, mouseEvents } from '../consts/DOM_EVENT_MAPPING_CONSTS'; import root from '../cross-platform/root'; /** * @class DOMEventInte...
// THIS FILE IS AUTO GENERATED import { GenIcon } from '../lib'; export function IoWalk (props) { return GenIcon({"tag":"svg","attr":{"viewBox":"0 0 512 512"},"child":[{"tag":"path","attr":{"strokeLinecap":"round","strokeLinejoin":"round","strokeWidth":"32","d":"M312.55 479.9l-56.42-114-44.62-57a72.37 72.37 0 01-10.0...
import process from 'process' import { once } from 'events' import assert from 'webassert' import chokidar from 'chokidar' import { basename, relative } from 'path' import makeArray from 'make-array' import ignore from 'ignore' import cpx from 'cpx2' import { getCopyGlob } from './lib/build-static/index.js' import { b...
import React from 'react'; import './Footer.less'; import ScrollUpButton from 'react-scroll-up-button'; import {Element} from 'nav-frontend-typografi'; import {Link} from 'react-router-dom'; class Footer extends React.Component { render() { return ( <div className="footer"> <div className="foo...
const {SEDataSource} = require('./base'); class QuestionsAPI extends SEDataSource { constructor(key) { super(key, 'questions'); } } module.exports = QuestionsAPI;
const mongoose = require('mongoose') require('dotenv').config() mongoose.connect(`mongodb+srv://${process.env.USERNAME}:${process.env.PASSWORD}@cluster0-njnty.mongodb.net/resume`, { useUnifiedTopology: true, useNewUrlParser: true }) const connection = mongoose.connection connection.on('conne...
import sqlite3 #create database conn = sqlite3.connect('customer.db') #create cursor cur = conn.cursor() #create a table cur.execute(""" CREATE TABLE customers ( first_name text, last_name text, email text )""") #commit changes to database ...
'use strict'; polarity.export = PolarityComponent.extend({ computedTest: Ember.computed('block.data.details', function(){ let test = Ember.Object.create({ type: 'NA' }); return 'test data 2'; }) });
# coding: utf-8 # # Copyright 2022 :Barry-Thomas-Paul: Moss # # Licensed under the Apache License, Version 2.0 (the "License") # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http: // www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Misc utils/functions for hammer_vlsi. # # See LICENSE for licence details. import copy import inspect import math import sys import os import errno from functools import reduce from typing import List, Any, Set, Dict, Tuple, TypeVar, Callable, Iterable, Optional, Un...
import React, { useState } from "react"; import { Link, NavLink } from "react-router-dom"; const Navbar = () => { const [burgerOpen, setBurgerOpen] = useState(false); const activeClass = burgerOpen ? "is-active" : ""; return ( <nav className="navbar is-transparent" role="navigation" aria-la...
import * as React from "react"; export class DateTime extends React.PureComponent { render() { let { timestamp, locale } = this.props; let value = new Date(timestamp * 1000).toLocaleDateString(locale, { timeZone: "UTC", timeZoneName: "short", year: "numeric", mont...
// DO NOT EDIT! This test has been generated by tools/gentest.py. // OffscreenCanvas test in a worker:2d.composite.uncovered.pattern.source-out // Description:Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged. // Note: importScripts("/resources/testharne...
macDetailCallback("38aa3c000000/24",[{"d":"2012-07-10","t":"add","a":"314, Maetan3-Dong, Yeongtong-Gu\nSuwon Gyunggi-Do 443-743\n\n","c":"KOREA, REPUBLIC OF","o":"SAMSUNG ELECTRO-MECHANICS"},{"d":"2015-08-27","t":"change","a":"314, Maetan3-Dong, Yeongtong-Gu\nSuwon Gyunggi-Do 443-743\n\n","c":"US","o":"SAMSUNG ELECTR...
/* * @Author: 大司马 * @Date: 2021-01-04 15:58:08 * @LastEditors: 大司马 * @LastEditTime: 2021-01-18 16:27:21 * @FilePath: \open-platform-ui\platform-console\src\api\applyMgr.js */ import platform from '@/config/platform' import axios from '@/libs/api.request' // 获取申请分页 查询 初始化 export const getInit = data => { retur...
""" Tests if a script is compliant with numsed python syntax. The following is tested: - the script respects python syntax - the only scalar type is integer - strings are allowed only as print arguments - characters in strings are limited to ASCII-32 (space) to ASCII-125 ("}") less the characters "@", "|" and ";" whi...
"""This file contains the logic to run the __main__.py body of the program. Name: classes.py Authors: - Jurre Brandsen - Lennart Klein - Thomas de Lange LICENSE: MIT """ import collections from collections import Counter import copy import csv import heapq import random import sys from ast import literal_eval impo...
/** * System configuration for Angular samples * Adjust as necessary for your application needs. */ (function (global) { System.config({ paths: { // paths serve as alias 'npm:': 'node_modules/' }, // map tells the System loader where to look for things map: { // our app is within ...
//console.log("loaded"); //alert("loaded"); angular.module('stage',[]);
const debug = require('debug')('app:swagger') 'use strict'; // Register swagger var pack = require('../../package'), swaggerOptions = { apiVersion: pack.version, pathPrefixSize: 2, info: { 'title': `${process.env.APP_NAME} API Documentation`, 'description': `${process.env.APP_NAME} API docume...
export function getColorAccessibilityProps(checked, color) { return { 'aria-pressed': checked, 'aria-label': 'Color Picker ' + color }; } //# sourceMappingURL=getColorAccessibilityProps.js.map
const INITIAL_STATE = [ { id: 0, description: 'Arrumar quarto', type: 'Pessoal', date: new Date('2021/03/29').getTime(), done: false, }, { id: 1, description: 'Terminar aplicativo', type: 'Programação', date: new Date('2021/04/16').getTime(), done: false, }, { id: 2, description: 'Fazer com...
import React from 'react' import { node } from 'prop-types' import { Box } from '@welcome-ui/box' import { HEIGHT, WIDTH } from './utils' export function Panel({ children }) { return ( <Box display="grid" minHeight={HEIGHT} minWidth={WIDTH}> {children} </Box> ) } Panel.propTypes = { children: nod...
country = 'Canadag' # by converting the string entered to lowercase and comparing it to a string # that is all lowercase letters I make the comparison case-insensitive # If someone types in CANADA or Canada it will still be a match if country.lower() == 'canada': print('Hello eh') else: print('Hello')
'use strict'; var context = SP.ClientContext.get_current(); var user = context.get_web().get_currentUser(); // extends jquer for easier fetching url parameter $.extend({ getUrlVars: function () { var vars = [], hash; var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).s...
from opentrons import types metadata = { 'protocolName': 'Testosaur', 'author': 'Opentrons <engineering@opentrons.com>', 'description': 'A variant on "Dinosaur" for testing', 'source': 'Opentrons Repository', 'apiLevel': '2.3' } def run(ctx): ctx.home() tr = ctx.load_labware('opentrons_96...
import { configure, setAddon, addDecorator } from '@storybook/react' //addDecorator(withInfo()) //import 'storybook-addon-specifications/register'; //import chaptersAddon from 'react-storybook-addon-chapters'; //import 'storybook-addon-jsx/register'; //setAddon(chaptersAddon) import { setDefaults } from '@storybook/ad...
let mix = require('laravel-mix'); /* |-------------------------------------------------------------------------- | Mix Asset Management |-------------------------------------------------------------------------- | | Mix provides a clean, fluent API for defining some Webpack build steps | for your Laravel applica...
from func.firebase_init import db from func.stuff import add_spaces from func.trading import get_current_price, get_multiple_prices, get_trading_buy_db from disnake.ext.commands import Param from disnake.ext import commands import disnake from typing import Literal class AvailableTokens(disnake.ui.View): def __...
""" WSGI config for szekelydata project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/2.0/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefa...
import numpy as np import matplotlib.pyplot as plt from matplotlib import rcParams, cycler import matplotlib.cm as cm from mpl_toolkits.axes_grid1 import make_axes_locatable import datetime import glob2 import xarray as xr import pandas as pd import itertools import re import clean.clean_03 as southtrac from matplotli...
import torch import torchio as tio from ...utils import TorchioTestCase class TestContour(TorchioTestCase): """Tests for `Contour`.""" def test_one_hot(self): image = self.sample_subject.label tio.Contour()(image) def test_multichannel(self): label_map = tio.LabelMap(tensor=torch....
from sklearn2sql_heroku.tests.classification import generic as class_gen class_gen.test_model("DecisionTreeClassifier" , "BreastCancer" , "mssql")
from .__init__ import * def primeFactorsFunc(minVal=1, maxVal=200): a = random.randint(minVal, maxVal) n = a i = 2 factors = [] while i * i <= n: if n % i: i += 1 else: n //= i factors.append(i) if n > 1: factors.append(n) prob...
#!/usr/bin/env python3 """ This is a script to convert GenBank flat files to GFF3 format with a specific focus on initially maintaining as much structural annotation as possible, then expanding into functional annotation support. This is not guaranteed to convert all features, but warnings will be printed wherever po...
const Mock = require('mockjs') // 获取 mock.Random 对象 const Random = Mock.Random // mock一组数据 const produceNewsData = function () { let articles = [] for (let i = 0; i < 100; i++) { let newArticleObject = { title: Random.csentence(5, 30), // Random.csentence( min, max ) th...
import * as React from "react"; import * as Constants from "~/common/constants"; import * as Actions from "~/common/actions"; import * as Events from "~/common/custom-events"; import { css } from "@emotion/react"; import { ButtonPrimary } from "~/components/system/components/Buttons"; const STYLES_MODAL = css` text...
(function(global) { 'use strict'; var fabric = global.fabric || (global.fabric = { }), extend = fabric.util.object.extend, min = fabric.util.array.min, max = fabric.util.array.max, toFixed = fabric.util.toFixed, NUM_FRACTION_DIGITS = fabric.Object.NUM_FRACTION_DIGITS; if (fabric.P...
/** * # Auth settings * Copyright(c) 2016 Stefano Balietti * MIT Licensed * * http://www.nodegame.org * --- */ module.exports = { /** * ## enabled * * If TRUE, authorization files will be imported and checked */ enabled: false, // [true, false] Default: TRUE. /** * ## mode...
/*! DataTables Bootstrap 3 integration ©2011-2015 SpryMedia Ltd - datatables.net/license */ (function(b){"function"===typeof define&&define.amd?define(["static/vendor/datatables/js/jquery","datatables.net"],function(a){return b(a,window,document)}):"object"===typeof exports?module.exports=function(a, d){a||(a=window)...
import Vue from 'vue' import router from '@/router' import store from '@/store' /** * 获取uuid */ export function getUUID () { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, c => { return (c === 'x' ? (Math.random() * 16 | 0) : ('r&0x3' | '0x8')).toString(16) }) } /** * 是否有权限 * @param {*} ke...
const router = require("express").Router(); const recipeRoutes = require("./recipes"); const userRoutes = require("./user") router.use("/recipes", recipeRoutes); router.use("/users", userRoutes); module.exports = router;
export default class ToggleMenu { constructor(element) { let that = this this.element = element this.menu = document.getElementsByClassName('js-menu-toggle')[0] this.navItems = document.getElementsByClassName('js-nav-items')[0] this.burgerWrapper = element.getElementsByClassName('burger__wrapper')...
""" Custom column/table names If your database column name is different than your model attribute, use the ``db_column`` parameter. Note that you'll use the field's name, not its column name, in API usage. If your database table name is different than your model name, use the ``db_table`` Meta attribute. This has no ...
const path = require("path"); module.exports = env => { return { mode: env, entry: { main: path.resolve(__dirname, "../src/background/main.ts") }, output: { filename: "main.js", path: path.resolve(__dirname, "../dist"), devtoolModuleFilenameTemplate: "[absolute-resource-path]"...
module.exports = function() { $('a[data-swal]').on('click', function(e) { e.preventDefault() var url = $(this).attr('href') var _token = $(this).data('swal-token') var body = '<strong class="text-red">' + $(this).data('swal-record') + '</strong>' swal({ cancelB...
from openff.bespokefit.optimizers.forcebalance.factories import ForceBalanceInputFactory from openff.bespokefit.optimizers.forcebalance.forcebalance import ForceBalanceOptimizer __all__ = ["ForceBalanceInputFactory", "ForceBalanceOptimizer"]
// flow-typed signature: 017910737b8e43acdefc38a395d6e944 // flow-typed version: <<STUB>>/babel-plugin-istanbul_v^4.0.0/flow_v0.76.0 /** * This is an autogenerated libdef stub for: * * 'babel-plugin-istanbul' * * Fill this stub out by replacing all the `any` types. * * Once filled out, we encourage you to sha...
module.exports = { // purge: ['./src/**/*.{js,jsx,ts,tsx}', './public/index.html'], darkMode: false, // or 'media' or 'class' theme: { extend: { colors: { githubTheme: { blue100: "#52A8F2", blue200:"#2561D9", blue300:"#26358C", black: "#1D2126", ...
/* @echo header */ var // dictionary _locale = { fr: 'fr_FR', en: 'en_US' }, // default params _params = { app_id: '', status: true, cookie: true, xfbml: true, statusConnected: null, statusNotConnected: null, permissions: ...
/* eslint-disable no-new, no-plusplus, object-curly-spacing, prefer-const, semi */ /* global IssuableContext */ /* global LabelsSelect */ //= require lib/utils/type_utility //= require jquery //= require bootstrap //= require gl_dropdown //= require select2 //= require jquery.nicescroll //= require api //= require cre...
(function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('lodash'), require('@angular/core'), require('@angular/common')) : typeof define === 'function' && define.amd ? define('ng9-odometer', ['exports', 'lodash', '@angular/core', '@angular/common'], ...
export function initialize(application) { application.inject('route', 'segment', 'service:segment'); } export default { name: 'segment', initialize };
!function(t,e){"object"==typeof module&&"object"==typeof module.exports?module.exports=t.document?e(t,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return e(t)}:e(t)}("undefined"!=typeof window?window:this,function(t,e){function i(t){var e=t.length,i=J.type(t);return"functio...
# Copyright 2011 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
import React, { Component, } from 'react'; import { EuiHeaderSectionItemButton, EuiPopover, EuiButton, EuiAvatar, EuiSelectable, EuiPopoverTitle, EuiPopoverFooter, } from '../../../../src/components'; import { Fragment } from 'react-is'; export default class extends Component { constructor(props) { ...
import selectedCamera from '../../src/reducers/select-camera-reducer'; describe('selectedCamera reducer', () => { it('should return the initial state', () => { expect(selectedCamera(undefined, {})).to.eql('ALL') }); it('should return correct state when ', () => { expect(selectedCamera('AL...
from . poly_spline import PolySpline from . bezier_spline import BezierSpline def connectSplines(splines): if len(splines) == 0: return BezierSpline() if len(splines) == 1: return splines[0].copy() if allPolySplines(splines): return joinPolySplines(splines) else: return joinInBezierSpl...
const path = require('path') const server = require(path.resolve('./server.js')) const request = require('supertest').agent(server.listen()) const { test } = require('ava') const moment = require('moment') const admin = { id: 1, email: 'admin@localhost.com', firstName: 'Alpha', lastName: 'Beta', password:...
module.exports = function (app) { app.get('/', function (req, res) { res.send('hello world!'); }); app.get('/admin', function (req, res) { res.send('admin page!'); }); }
import React from 'react'; function Login() { return ( <> <div id="sidebar-wrapper"> <div className="border-end bg-white"> <div className="sidebar-heading border-bottom bg-light"> <h1>Login </h1> </div> <div className="list-group list-gro...
/* * DateJS Culture String File * Country Code: fi-FI * Name: Finnish (Finland) * Format: "key" : "value" * Key is the en-US term, Value is the Key in the current language. */ Date.CultureStrings = Date.CultureStrings || {}; Date.CultureStrings["fi-FI"] = { "name": "fi-FI", "englishName": "Finnish (Finla...
import os import unittest from recipe_scrapers.delish import Delish class TestDelishScraper(unittest.TestCase): def setUp(self): #tests are run from tests.py with open(os.path.join( os.getcwd(), 'recipe_scrapers', 'tests', 'test_data', ...
import React from 'react'; import { Section, Container } from '@components/global'; import FaqItem from '@common/FaqItem'; import ExternalLink from '@common/ExternalLink'; const FAQS = [ { title: 'what is COVID-19 and what are the symptoms to look out for?', content: () => ( <> Coronavirus di...
import gulp from 'gulp'; import runSequence from 'run-sequence'; import httpProxy from 'http-proxy-middleware'; import browserSync from 'browser-sync'; import {dirs, files, proxy} from '../gulpfile-config'; import {prepareAssetsSass} from './prepare'; import {test, jslint, testUnit} from './test'; const browserSyncSe...
// Copyright 2021 The casbin Authors. All Rights Reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by a...
const express = require('express'); const router = express.Router(); router.get('/', async (req, res) => { }); router.post('/', async (req, res) => { }); module.exports = router;
import datetime import functools from collections import namedtuple from base64 import urlsafe_b64encode, urlsafe_b64decode from validr import T, validator, SchemaError, Invalid, Compiler, builtin_validators from django.core.validators import URLValidator from django.core.exceptions import ValidationError from django....
(function (app) { 'use strict'; app.registerModule('logicjumps', ['core', 'ui.router', 'core.routes']); }(ApplicationConfiguration));
import styled from 'styled-components'; import { containerMixin, flexCenterMixin } from '../../../global-styles/mixins'; export const Container = styled.div` ${containerMixin}; ${flexCenterMixin}; flex-direction: column; `; export const Form = styled.form` ${flexCenterMixin}; flex-direction: column; `;
import GameLogic from '../utils/GameLogic'; import ScoreLogic from '../utils/ScoreLogic'; import { GameStatus } from '../utils/enums'; import routes from '../utils/routes'; import { getTokenAndBestScore, sendBestScore } from '../utils/apiCalls'; import { setBestScore, setCurrentScore, setPlayerSelection, setAcc...
# Copyright 2019 Intel Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
function deleteItem(itemId) { $.get("/admin/equipment/delete", { id: itemId }); $("#row-" + itemId).remove(); $("#hr-" + itemId).remove(); }
/** * Extend the basic ItemSheet with some very simple modifications * @extends {ItemSheet} */ export class CairnItemSheet extends ItemSheet { /** @override */ static get defaultOptions () { return mergeObject(super.defaultOptions, { classes: ["cairn", "sheet", "item"], width...
var util = require("util"); var i = 4; // while i < 10 do util.print(i); i++; // end util.print(i);
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _createSvgIcon = _interopRequireDefault(require("./utils/createSvgIcon")); var _jsxRuntime = require("react/jsx-runtime")...
/* Tabulator v4.7.2 (c) Oliver Folkerd */ var Print=function(t){this.table=t,this.element=!1,this.manualBlock=!1};Print.prototype.initialize=function(){window.addEventListener("beforeprint",this.replaceTable.bind(this)),window.addEventListener("afterprint",this.cleanup.bind(this))},Print.prototype.replaceTable=function...
'use strict' const jwt = require('jwt-simple') const moment = require('moment') const config = require('../config') function createToken (user) { const payload = { sub: user._id, iat: moment().unix(), exp: moment().add(14, 'days').unix() } return jwt.encode(payload, config.SECRET_TOKEN) } function...
!function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return ...
// Copyright (c) 2020 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge...
import unittest from http_monitor.recurrent_period import RecurrentPeriod from tests.utils import captured_output class SlidingPeriodTestDict(unittest.TestCase): def test_one_elt_hit_dict_content(self): rp = RecurrentPeriod(time_window=10) rp.add(100, "/report") self.assertDictEqual(dict...