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
Order.where(:created_at=>dt1.beginning_of_day..dt2.end_of_day).each{|p1| | |
dt << p1.created_at.strftime("%d/%m/%Y") | |
Orderitem.where(orders_id: p1.id).each {|p2| | |
quantity << {data: p1.created_at.strftime("%d/%m/%Y"), product: Product.find_by_id(p2.products_id).product_name,quantity: p2.quantity} | |
} | |
} |
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
from bottle import auth_basic,run, request, response,HTTPResponse,Bottle | |
import json,md5,time | |
from dbase import database as db | |
app = Bottle() | |
@app.hook('before_request') | |
def enable_cors(): | |
response.headers['Access-Control-Allow-Origin'] = '*' | |
response.headers['Access-Control-Allow-Methods'] = 'PUT, GET, POST, DELETE, OPTIONS' |
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
$http({ | |
url:"http://127.0.0.1:3000/login", | |
contentType:"application/json", | |
method:"POST", | |
data: JSON.stringify(login) , | |
}).success(function(e){ | |
console.log(e); | |
}); |
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
source 'https://rubygems.org' | |
git_source(:github) do |repo_name| | |
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") | |
"https://github.com/#{repo_name}.git" | |
end | |
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' | |
gem 'rails', '~> 5.0.2' |
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
<<APP>> change this variables |
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
import { Component } from '@angular/core'; | |
import { NavController } from 'ionic-angular'; | |
import { LoginPage} from '../login-page/login-page'; | |
@Component({ | |
selector: 'page-home', | |
templateUrl: 'home.html' | |
}) | |
export class HomePage { | |
constructor(public navCtrl: NavController) { |
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
import { Component } from '@angular/core'; | |
import { NavController } from 'ionic-angular'; | |
import { LoginPage} from '../login-page/login-page'; | |
@Component({ | |
selector: 'page-home', | |
templateUrl: 'home.html' | |
}) | |
export class HomePage { | |
constructor(public navCtrl: NavController) { |
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
import { Component } from '@angular/core'; | |
import { IonicPage, NavController, NavParams } from 'ionic-angular'; | |
import { ToastController } from 'ionic-angular'; | |
import { HomePage } from '../home/home'; | |
/** | |
* Generated class for the LoginPage page. | |
* | |
* See http://ionicframework.com/docs/components/#navigation for more info | |
* on Ionic pages and navigation. | |
*/ |
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
{ | |
"place": [ | |
{ | |
"id": 1, | |
"nome_espaco": "Salao de festas", | |
"descricao": "Salao usado para festas", | |
"max_pessoa": 20, | |
"intervalo_min_reserva": 5, | |
"valor": 400.35, | |
"regras_gerais": "Não pode remover as lampadas do espaco", |
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
public class Main { | |
public static void main(String[] args){ | |
CoroaCircular cc = new CoroaCircular(10,8); | |
System.out.println(cc.calAreaCC()); | |
} | |
} | |
public class AreaCirculo{ | |
public double calcArea(double raio){ | |
return Math.pow(raio,2)*(Math.PI); |
OlderNewer