text
stringlengths
7
3.69M
$(document).ready(function () { $('#parkname_init_loadingModal').modal({backdrop: 'static', keyboard: false}); var init_frp_park_name = "/api/frp/init_frp_park_name"; $.ajax({ type: 'GET', url: init_frp_park_name, success: function (chunk, textStatus) { $("#park_name")...
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); exports.FONT_PT_SIZES = undefined; var _getPrototypeOf = require('babel-runtime/core-js/object/get-prototype-of'); var _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf); var _classCallCheck2 = require('babel-runtime/helpers/clas...
import React, { useState, useEffect } from 'react'; export const CurrentActivity = () => { const [day, setDay] = useState(1); const [activity, setActivity] = useState(''); // Set current day into state const currDay = () => { let today = new Date().getDay(); setDay(today); }; // useEffect to call...
export const FETCH_USER = "FETCH_USER"; export const FETCH_USER_SUCCESS = "FETCH_USER_SUCCESS"; export const FETCH_USER_FAILURE = "FETCH_USER_FAILURE";
/* * Module code goes here. Use 'module.exports' to export things: * module.exports.thing = 'a thing'; * * You can import it from another modules like this: * var mod = require('role.war.healer'); * mod.thing == 'a thing'; // true */ healer = { pickup: function(creep) { //Short circuit here to move ...
const configureStripe = require('stripe') const bodyParser = require('body-parser') const STRIPE_SECRET_KEY = process.env.NODE_ENV === 'production' ? 'sk_live_MY_SECRET_KEY' : 'sk_test_HFlmK9RxeyUAqiHwMhmJriEs004ayVg3VN' const stripe = configureStripe(STRIPE_SECRET_KEY) const postStripeCharge = res => (str...
/** * Created by Jackson on 10/20/16. */ (function () { angular.module('tpt') .controller('ProfileController', ProfileController); ProfileController.$inject = ['fetchUser', '$routeParams', '$mdDialog']; function ProfileController(fetchUser, $routeParams, $mdDialog) { var vm = this; ...
const winLossRecordSort = (playerOne, playerTwo) => playerTwo.point_count - playerOne.point_count; // calculate point count for players // sort players in each pool by point count const seedCalculator = pools => Object.values(pools) .slice(1).filter(tournamentPool => tournamentPool.length > 0) .map(tournamentPool ...
/** * TabSaver will store the currently selected tab into LocalStorage and * create a table listing all such entries, allowing the user to reopen * previously saved tabs. * * @summary TabSaver popup.js to control functionality of extension * * @author Martin Green * @copyright 2016 */ document.addEventListe...
import React, { Component } from 'react'; import dva from 'rn-dva'; import dvaLoading from 'dva-loading'; import thunk from 'redux-thunk'; import logger from 'redux-logger'; import { applyMiddleware } from 'redux'; import { Provider } from 'react-redux'; import { StoreEnhancer, PersistStore } from './utils/persist'; im...
var cover; var text; function preload() { cover = loadImage('./assets/cover.jpg'); text = loadImage('./assets/cover text.png'); } function setup() { createCanvas(windowWidth, windowHeight); image(cover, 0, 0, cover.width*1.4, cover.height*1.4); imageMode(CENTER); image(text, windowWidth/2, windowHeig...
import React from 'react' import CustomIcon from '../CustomIcon' const DocsRing = (props) => ( <CustomIcon {...props}> <circle cx="12" cy="12" r="9" stroke="currentColor" strokeWidth="6"/> </CustomIcon> ) export default DocsRing
// get trip values set welocome page in local storage var tripDestination = localStorage.getItem("tripDestination"); var tripPid = localStorage.getItem("tripPid"); var tripLat = Number(localStorage.getItem("tripLat")); var tripLng = Number(localStorage.getItem("tripLng")); var tripFromDate = localStorage.getItem('tri...
var MyApp = angular.module('MyApp',[]); MyApp.controller('ListCtrl', ['$scope','$http', '$q', function($scope, $http ,$q){ $scope.name = 'sunshine1125'; function demo(){ var deferred = $q.defer(), that = this; if (that.cache == undefined) { $http.get('https://api.github.com/users/${$scope.name}') ...
import express from "express"; const router = express.Router({ mergeParams: true }); import passport from "passport"; import { facebook, facebookFailure, logout, check } from "../handlers/routes/auth"; const facebookAuth = passport.authenticate("facebook", { scope: "email", failureRedirect: "/api/auth/facebook...
var myApp = angular.module('myApp', []); myApp.controller('MyCtrl', ['$scope','$http', function($scope) { var itemsx=[{id:1,Description:"Kathmandu"},{id:1,Description:"Bhaktapur"},{id:1,Description:"Lagenkhel"},{id:1,Description:"Janakpur"},{id:1,Description:"Koshi"},{id:1,Description:"Sagarmatha"},{id:...
// getting needed dependencies require('dotenv').config(); const express = require('express'); const bodyParser = require('body-parser'); const cors = require('cors'); const mongoose = require('mongoose'); const nocache = require('nocache'); const compression = require('compression'); const path = require('path'); cons...
module.exports = { FECAESolicitar: { ImpNeto: { type: "number", default: 0 }, ImpConc: { type: "number", default: 0 }, ImpOpEx: { type: "number", default: 0 }, ImpTrib: { type:...
export const SEARCH_FOCUS = 'SEARCH_FOCUS'; export const SEARCH_BLUR = 'SEARCH_BLUR';
var Discord = require('discord.io'); var drole = ""; /* roleid to be applied when someone joins the server */ var serverid = ""; /* your server id */ var bot = new Discord.Client({ autorun: true, /* If false, you need to connect to the server using bot.connect(); */ token: "" /* your discordapp token */ }); bot.on...
var express = require("express"); var app = express(); app.get("/", (req, res, next) => { res.json([ { title: 'CAN I SUBMIT FEEDBACK WITHIN THE APP?', desc: 'Yes! We love hearing from our app users and welcome the feedback as we work toward improving the app in the future. There ar...
let id_check = 0; let pw_pattern1 = /[0-9]/; let pw_pattern2 = /[a-zA-Z]/; let pw_pattern3 = /[~!@#$%^&*()~]/; $("#memberJoin").on("click", function(){ if($("#userID").val().length <= 0){ alert("ID는 필수입니다."); $("#userID").focus(); return; } else if($("#userName").val().length<=0){ alert("이름는 필수입니다."); $(...
import {connect} from 'react-redux'; import {EnhanceLoading} from '../../../components/Enhance'; import OrderPageContainer from './OrderPageContainer'; import EditPageContainer from './EditPageContainer'; import helper, {fetchJson, getJsonResult, initTableCols, postOption, showError} from "../../../common/common"; impo...
describe('P.views.workouts.schedule.Selected', function() { var View = P.views.workouts.schedule.Selected, Model = P.models.workouts.Session; describe('del', function() { it('emits an "unselect" event with the date', function(done) { var model = new Model({ date: '2014-01-01' }), ...
var Trie = require("../trie-ing"); var readline = require('readline'); var fs = require('fs'); var input = require("./sample/sample"); // input file is mandatory try { var output = require("./sample/sample_trie"); } catch (e){ var output = undefined; } // Decide on building a trie from the data or loading it f...
import { createSelector } from "reselect"; const selectFeed = state => state.feed; export const selectFeedPost = createSelector([selectFeed], feed => feed.posts); export const selectFeedIsLike = createSelector( [selectFeed], feed => feed.isLike );
require('dotenv').config(); var request = require('request'); var express = require('express'); var app = express(); var bodyParser = require('body-parser'); var ShortUID = require('short-uid'); var uid = new ShortUID(); var metafetch = require('metafetch'); var ejs = require('ejs'); var _ = require('lodash'); var fs...
var CallidForm; var pageSize = 25; /**********************************************************************站臺管理主頁面**************************************************************************************/ //料位管理Model Ext.define('gigade.Ilocs', { extend: 'Ext.data.Model', fields: [ { name: "boiler_type", ty...
elements = document.querySelectorAll(’.mimg’) var urls = []; for (var i = 0; i < elements.length; i++) { var url = elements[i].getAttribute(‘src’) if (url&&url.includes(‘https’)) { urls.push(url); } } window.open(‘data:text/csv;charset=utf-8,’ + escape(urls.join(’\n’)));
const express = require('express'); const bodyParser = require('body-parser'); const app = express(); const port = 8000; app.use(bodyParser.urlencoded({ extended: true })); var apiRouterV1 = express.Router(); app.use('/',apiRouterV1); var productInventoryApiV1 = express.Router(); apiRouterV1.u...
import React, {Component} from "react"; import {ENDPOINT_UPDATE_PASSWORD, makeAPIRequest} from "../../app/services/apiService"; import {simpleAlert} from "../../app/services/alertService"; import {Body, Container, Content, Footer, FooterTab, Header, Title, Text, Button, Input} from "native-base"; export default class...
class Formatter { static capitalize(string) { return string.charAt(0).toUpperCase() + string.slice(1) } static sanitize(string) { return string.replace(/[^'0-9a-z- ]/gi, '') } static titleize(string) { let result = []; let ignoreWords = ["the", "a", "an", "but", "of", "and", "for", "at", "by...
import { render, screen } from '@testing-library/react'; import '@testing-library/jest-dom'; import MovieCard from '../components/MovieCard'; import { MemoryRouter } from 'react-router-dom'; import userEvent from '@testing-library/user-event'; import { _notOnWatchListMovie, _onWatchListMovie, } from './mockData/mov...
Ext.define('eapp.model.Activity', { extend:'Ext.data.Model', config: { fields: [ 'activityid', 'userid', 'groupid', 'activityName', 'activityDateStart', 'activityContent', 'activityDateEnd', 'activityState', 'reson' ] } });
function sayThanks(name) { console.log('Thank you for your purchase '+ name + '! We appreciate your business.'); } sayThanks('Cole'); // this allows Cole to be used in the thank you statement on the recipt. //so it will diplay "Thank you for your purchase Cole! We appreciate your business."
/** * Global configuration */ import { YellowBox } from 'react-native' global.log = () => { } global.error = () => { } global.logImportant = () => { } // Disable yellow box specific case by case YellowBox.ignoreWarnings([ 'Remote debugger is in a background tab which may cause apps to perform slowly. Fix this by...
'use strict'; var gulp = require('gulp'); var uglify = require('gulp-uglify'); var rimraf = require('gulp-rimraf'); var removeUseStrict = require('gulp-remove-use-strict'); var concat = require('gulp-concat'); var notify = require('gulp-notify'); var ngHtml2Js = require('gulp-ng-html2js'); var minifyHtml = require('gu...
"use strict"; const insurances = require("../models/insurances.model"); exports.findAll = function (req, res) { insurances.findAll(function (err, insurances) { console.log("controller"); if (err) res.send(err); console.log("res", insurances); res.send(insurances); }); }; exports.create = function ...
import { logger } from '../utils/logger'; export const renderTestPage = () => { logger.info('Rendering test page'); return 'Welcome to the Mic.ro test page :)'; };
import React from 'react'; import { StyleSheet, View,Image, ImageBackground,TouchableOpacity,Alert,Platform,ScrollView } from 'react-native'; import { Container ,Header, StyleProvider,Title, Form,Left,Right,Icon,Thumbnail ,Item, Input, Label,Content,List,CheckBox,Body,ListItem,Text,Button} from 'native-base'; import As...
import React from 'react' import UserProfile from 'components/user/UserProfile' export default class Profile extends React.Component { render () { return ( <UserProfile {...this.props}/> ) } }
var fields = { identity:'身份', name:'姓名', account:'帳號', email:'E-mail', dorm:'宿舍', room:'房號', MAC:'MAC 卡號', phone:'電話', IP:'IP' }; var display_fields = [ 'name','account','dorm','room','IP' ]; app.controller( 'UserListController',['$scope', '$http', function($scope,$http){ $scop...
import React from 'react' import { Link } from 'react-router-dom' import AppBar from '@material-ui/core/AppBar'; import Toolbar from '@material-ui/core/Toolbar'; import Typography from '@material-ui/core/Typography'; import { connect } from "react-redux" import { updateUser } from '../store/utilities/user' class Heade...
import React, { Component } from 'react' class Carousel extends Component { state = { click: 1 } handleChangeUp = (e) => { if (this.state.click === 4) { this.setState({click: 1}) } else { this.setState({click:this.state.click+1}) } } ...
import { List, Spin, Form, Input, Button, Row, Col, message } from "antd"; import Avatar from "antd/lib/avatar/avatar"; import axios from "axios"; import { useEffect, useState } from "react"; const ApiCallDemo = () => { const [data, setData] = useState([]); const [loading, setLoading] = useState(false); const s...
/** * tools: casperjs/phantomjs * * This test navigates to various payment pages * and tests that they display correctly * * Run command: * casperjs test test_payment_pages.js * * @author J.Stone */ var login = 'https://voxy.com/u/login/'; var logout = 'https://voxy.com/u/logout/'; var payment_pages = [ "htt...
"use strict"; var enzyme_1 = require('enzyme'); var React = require('react'); var index_1 = require('./index'); describe('Form Error Component', function () { it('should create a form error with its children, classes and id', function () { var formError = enzyme_1.shallow(<index_1["default"] isVisible>Hello...
const fs = require('fs-plus') const load = (_file) => { return fs.readFileSync(_file, 'utf8') } const save = (_file, _content) => { fs.writeFileSync(_file, _content) } const edit = (_addrsFile, _fun) => { const content = this.load(_addrsFile) const newContent = _fun(content) this.save(_addrsFile...
import {ImmutablePropTypes, PropTypes} from 'src/App/helpers' import { immutableArchiveFilmsModel, immutablePageTextModel, immutableNichesListModel, pageRequestParamsModel, immutableTagArchiveListModel, immutableSortListModel, immutableTagArchiveListOlderOrNewerModel, immutableSponsorsL...
$(document).ready(function(){ var sum=0; psum(); //更新按钮状态 $(".cart_btn").each(function(){ btnchange($(this)); }); $(".cart_btn").click(function(){ var num=$(this).prev().children(".goods_num").val(); num++; $(this).prev().children(".goods_num").val(num); var $th=$(this); btnchange($th); var package ...
/************************************************************* * * Copyright (c) 2012-2015 MathJax Consortium * * 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...
/** * Sample React Native App * https://github.com/facebook/react-native * @flow */ import React, {Component} from 'react'; import { StyleSheet, Text, View, Image } from 'react-native'; export default class App extends Component<{}> { render() { return ( <View style={styles...
import { createStore } from 'redux'; import { persistStore, persistReducer } from 'redux-persist'; import { offlineActionTypes, checkInternetConnection } from 'react-native-offline'; import storage from 'redux-persist/lib/storage'; import reducer from '../reducers'; import middleware from '../middleware'; const persi...
var api = { // 获取指定范围随机数方法 getRandom: function (start, end) { return Math.random() * (end - start) + start }, // 定义颜色数组 getColorList: ['#2080f7', '#0f0d39', '#c728cb', '#e8a3ea', '#f2d61f', '#622725', '#f40dc4', '#0df4c7'], // 生成随机id getRandomId: function () { var id = '' for (var i = 0; i <...
function Navigation(level, extension) { Response.Write("<a class=\"navlinkA\" href=\""+GetPath(level)+"Section2/Section1/Index"+GetExtension(extension)+"\">Gynowars</a><br><br>"); Response.Write("<a class=\"navlinkA\" href=\""+GetPath(level)+"Section2/Project2"+GetExtension(extension)+"\">Assault</a><br><br>"); Resp...
const gulp = require('gulp'); const eslint = require('gulp-eslint'); const babel = require('gulp-babel'); const gulpIf = require('gulp-if'); const del = require('del'); const isFixedEslint = (file) => { return file.eslint != null && file.eslint.fixed; }; gulp.task('clean', () => { return del('dist/**'); }); gul...
'use strict'; module.exports = (sequelize, DataTypes) => { const Model = sequelize.define('Review', { id: { field: 'review_id', type: DataTypes.INTEGER, primaryKey: true }, entityId: { field: 'entity_id', type: DataTypes.INTEGE...
'use strict'; { const API = { endpoints: { laureate: 'http://api.nobelprize.org/v1/laureate.json?', prize: 'http://api.nobelprize.org/v1/prize.json?' }, queries: [{ description: 'Select a query', endpoint: '' }, ...
class GrayState { constructor() { this.observers = []; this.status = {}; } attach(func) { if (!this.observers.includes(func)) { this.observers.push(func); } } detach(func) { this.observers = this.observers.filter((observer) => observer !== func); } updateStatus(val) { this...
//导入excel export function onImportExcel(files) { console.log(this) // 获取上传的文件对象 // const { files } = file.target; // 通过FileReader对象读取文件 const fileReader = new FileReader(); let func = (event) => { try { const { result } = event.target; // 以二进制流方式读取得到整份excel表格对象 const workbook = XLSX....
import React from "react"; import {Card} from "antd"; const Basic = () => { return ( <Card title="Basic card" extra={<span className="gx-link">More</span>}> <p>The point of using Lorem Ipsum making it look like readable English. Various versions have evolved over the years, sometimes by ac...
var comb = require('comb'); var request = require('request'); var client = require('./client.js'); var logger = require(LIB_DIR + 'log_factory').create("experiments_client"); var ExperimentsClient = comb.define(client,{ instance : { constructor : function(options){ options = options || {}; options.url = "expe...
// ** Item List Component import Table from './Table' // ** Styles import '@styles/react/apps/app-general.scss' const GeneralList = () => { return ( <div className='app-general-list'> <Table /> </div> ) } export default GeneralList
import React, {useState} from "react" import { connect } from "react-redux" import styled from "styled-components" import BreadCrumbC from "../../components/BreadCrumb" import TitleC from "../../components/Title" import FilterC from "../../components/Filter" import ExamCardC from "../../components/ExamCard" import Pag...
//引入 用来发送请求的 方法 一定要把路径补全 //request表示导入函数返回的 import { request } from "../../request/index.js"; //引入⽀持es7的async语法 import regeneratorRuntime from '../../lib/runtime/runtime'; Page({ /** * 页面的初始数据 */ data: { //左侧的菜单数据 leftMenuList:[], //右侧的商品数据 rightContent:[], ...
import React from 'react' import ReactPlayer from 'react-player/youtube' function YTCard({videoId, height, width}) { return ( <div className="ytCardWrapper"> <ReactPlayer url={`https://www.youtube.com/watch?v=${videoId}`} // height="125px" // width="180px" ...
var socket = io.connect(window.location.href); var DRIVE_FORWARD = 'df'; var DRIVE_BACKWARD = 'db'; var SET_DRIVE_SPEED = 'sds'; var SET_DRIVE_SPEED_FORWARD = 'sdsf'; var SET_DRIVE_SPEED_BACKWARD = 'sdsb'; var SET_DRIVE_ANGLE = 'sda'; var DRIVE_STOP = 'ds'; var TURRET_Y_ZERO = 'tyz'; var TURRET_Y_STOP = 'tyx'; var TU...
function SmoothieChart(m) { m = m || {} m.grid = m.grid || { fillStyle: '#000000', strokeStyle: '#777777', lineWidth: 1, millisPerLine: 1e3, verticalSections: 2, } m.millisPerPixel = m.millisPerPixel || 20 m.fps = m.fps || 50 m.maxValueScale = m.maxValueScale || 1 m.minValue = m.minVal...
// This is a manifest file that'll be compiled into application.js, which will include all the files // listed below. // // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts, // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative ...
'use strict'; angular.module('WarehouseDelivery', ['ngTable', 'siTable', 'ReleaseOrder', 'Contact', 'ExportDeliveries', 'ngToast', 'Loader']) .config(['ngToastProvider', function (ngToast) { ngToast.configure({maxNumber: 1, horizontalPosition: 'center'}); }]) .controller('WarehouseDeliveryControll...
const path = require('path'); const merge = require('webpack-merge'); const { CleanWebpackPlugin } = require('clean-webpack-plugin'); const TerserPlugin = require('terser-webpack-plugin'); const CopyWebpackPlugin = require('copy-webpack-plugin'); const MiniCssExtractPlugin = require('mini-css-extract-plugin'); const Op...
import React, { Component } from 'react' import { Box, Color } from 'ink' import TextInput from 'ink-text-input' class QueryPage extends Component { state = { query : '' } render() { return ( <Box> <Box marginLeft={2}> <Color cyan> What are you looking for: </Color...
import React from 'react'; //import ReactSignupLoginComponent from 'react-signup-login-component'; import { BrowserRouter as Router, Route, Link } from "react-router-dom"; //import 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap'; //import 'https://fonts.googleapis.com/icon?family=Material+...
import ProdutoService from "../services/produto.service.js"; async function createProduto(req, res, next) { try { let produto = req.body; if (!produto.codigo || !produto.descricao || !produto.marcaId) { throw new Error('Os campos codigo, descricao e marca são obrigatórios!'); } ...
/* ============================================ ; Title: Assignment 1.5 ; Author: Albert Einstein ; Date: 25 June 2017 ; Modified By: Heather Peterson ; Description: This program demonstrates the ; use of JavaScript types, values, and ; and variables in an application. ;=========================================...
var keystone = require('keystone'); var Types = keystone.Field.Types; /** * Poll Model * ========== */ var Poll = new keystone.List('Poll', { track: true }); Poll.schema.set('usePushEach', true); Poll.add({ name: { type: String, required: true, index: true }, title: { type: String, noedit: true }, // tag...
const Album = require('../models/album'); function albumsIndex(req, res) { console.log('made it to the controller'); Album .find() .exec() .then(albums => res.status(200).json(albums)) .catch(() => res.status(500).json({ message: 'Something went wrong'})); } function albumCreate(req,res) { req.bo...
/** * Dealing with routing, static and middleware * using express js * * @ node.js cmd: * >npm init * >npm install express --save * */ //look for express @ node module var express = require('express'); //declare app as express function var app = express(); //look for system files var fs = require('fs'); //de...
import '@testing-library/jest-dom/extend-expect' import { Question, AnswerOptions, Count, Results, CorrectAnswer } from '../components' import { render, screen } from '@testing-library/react' describe('Count', () => { const props = { currentQuestion: 1, total: 9 } const differentProps = { currentQu...
import React, { Component } from 'react'; import './styles.css'; class Cell extends Component { constructor(props){ super(props); this.state ={ hasMine : props.cell.hasMine, hasFlag : props.cell.hasFlag, isOpened : props.cell.isOpened, count: props.cell.count, game: props.cel...
import { render } from '@redwoodjs/testing' import FeedPage from './FeedPage' describe('FeedPage', () => { it('renders successfully', () => { expect(() => { render(<FeedPage />) }).not.toThrow() }) })
export default async function handler(req, res) { const { email } = req.query const response = await fetch(`https://api.buttondown.email/v1/subscribers`, { method: 'POST', headers: { Authorization: `Token ${process.env.BUTTON_DOWN_API_KEY}`, 'Content-Type': 'application/json', }, body: ...
const express = require('express'); const router = express.Router(); const initHelpers = require('../dbHelpers/tweetHelpers'); module.exports = (db) => { const tweetHelpers = initHelpers(db); router.get(`/:tweetId/`, (req, res) => { const tweetId = req.params.tweetId; const userId = req.session.user_id; ...
import React from 'react'; import { config } from '../config'; import '../styles/Carrousel.scss'; import { MainSection } from './MainSection'; export const Carrousel = ({ data }) => { return ( <div id="carrousel--tv" className="carousel slide" data-ride="carousel"> <ol className="carousel-indicators"> ...
import snapshot from '@compositor/kit-snapshot' import 'jest-styled-components' import * as examples from '../examples' snapshot(examples)
import React, {useContext,useState,useEffect} from 'react'; import Parser from 'papaparse'; import {FilterContext} from './Filters.js'; import Painting from './Painting.js'; import PaintingDetails from './PaintingDetails.js'; import FilteringMessage from './FilteringMessage.js' // This data file is a combination of 2...
exports.login = require('./login'); exports.newpost = require('./newpost'); exports.welcome = require('./welcome'); exports.signup = require('./signup'); exports.permalink = require('./permalink'); exports.logout = require('./logout'); exports.users = require('./users'); exports.user = require('./user'); exports.manage...
appModule.controller("ProjectsController", function($scope){ $scope.projects = [ { id: 1, title: "Business Process Modeling and Deployment Framework", tech: "Java, AngularJS, Spring, MySQL", description: `<ul> <li>Responsible for managing the full ...
module.exports = { fetchAllUsers(success){ $.ajax({ url: "api/users", success(resp){ success(resp); } }); }, fetchSingleUser(id, success){ $.ajax({ url: `api/users/${id}`, success(resp){ success(resp); } }); } };
(function(){ 'use strict'; var baseUrl = 'http://dtapi.local/'; angular.module('app') .constant('appConstants', { logInURL: baseUrl + 'login/index', logOutURL: baseUrl + 'login/logout', isLoggedURL: baseUrl + 'login/isLogged', getSubjects: baseUr...
// @flow strict import opentelemetry from '@opentelemetry/api'; import { GraphQLInstrumentation } from '@opentelemetry/instrumentation-graphql'; import { LogLevel } from '@opentelemetry/core'; import { NodeTracerProvider } from '@opentelemetry/node'; import { ConsoleSpanExporter, BatchSpanProcessor, SimpleSpanProcess...
'use strict'; module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), clean: ['dist'], inline: { dev: { options: { cssmin: false, uglify: false }, src: 'src/index.html', dest: 'dist/index.html' }, ...
// const logger = require('./loggerService'); const qs = require('../libs/qs'); module.exports = { // 非 tabBar toPage: function (page, isTab) { if (isTab) { wx.switchTab(page); return; } wx.navigateTo(page); }, backPage: function () { wx.navigateBa...
// Code MovieReviews Here import React from 'react' import testReviews from './test-reviews.js' const MovieReviews = () => { return( <div className='review-list'> {testReviews.map(review => <div className='review' key={review.display_title}> <p>{review.display_title...
//Defines a mongoDB collection function Collection(id, d) { this.id = id; //Collection name this.database = d; //The database containing this collection this.shards; //The list of shards across which this collection is partitioned, or undefined if this collection is not sharded this.alerts = new MaxHeap...
module.exports = 'I m lib';
editFunction = function (row, store) { var editUserFrm = Ext.create('Ext.form.Panel', { id: 'editUserFrm', frame: true, plain: true, layout: 'anchor', labelWidth: 40, url: '/Vote/SaveVoteMessage', defaults: { anchor: "95%", msgTarget: "side" }, items:...
var class_disable_decal_meshes = [ [ "meshSetUpDelay", "class_disable_decal_meshes.html#a289f2162be36ac4e9614acd7d243d4ff", null ] ];
var Search = { input: document.querySelector('#search-input'), menu: document.querySelector('.searchMenu'), navbar : document.querySelector('.navbar '), start(){ this.event(); }, event(){ this.input.addEventListener('input', (evt) => { if(evt.target.value.length ...
import { combineReducers } from 'redux' import TodoListReducer from './todo_list_reducer.js' import UserReducer from './user_reducer.js' import ListsReducer from './lists_reducer.js' import ItemReducer from './item_reducer.js' //Actions describe the fact that something happened, but don't specify how the application...