- Security boot disable (change this in BIOS, for MSI computers reboot system and press delete a couple of times before the OS is loaded)
- Possible problem: Screen freezing while installing
This file contains 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
//= require jquery.maskMoney | |
//= require jquery.mask | |
var Mask = { | |
phoneMasks: ['(00) 00000-0000', '(00) 0000-00000'], | |
maskBehavior: function (val, e, field, options){ | |
return val.length > 14 ? Mask.phoneMasks[0] : Mask.phoneMasks[1]; | |
}, |
This file contains 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
class OneSignal | |
APP_ID = 'ONE_SIGNAL_APP_ID' | |
API_KEY = 'ONE_SIGNAL_APP_KEY' | |
def initialize(title, body, data, players) | |
@title, @body, @data, @players = title, body, data, players | |
end | |
def perform | |
params = { |
This file contains 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
setupOneSignal(){ | |
this.oneSignal.startInit('ab4692d4...'); | |
this.oneSignal.inFocusDisplaying(this.oneSignal.OSInFocusDisplayOption.Notification); | |
this.oneSignal.handleNotificationReceived().subscribe((jsonData) => { | |
if (jsonData.isAppInFocus){ | |
let alert = this.alertCtrl.create({ | |
title: notification.title, | |
message: notification.body, |
This file contains 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
Requisitos. | |
[1] | |
* Criar uma simples calculadora de strings. | |
* Deve ter o método int Add(string numbers). | |
* Este método pode receber 0, 1 ou 2 numeros separados por (,). | |
[2] | |
* para string vazias retornar 0. |
This file contains 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
class ActiveRecord::Base | |
def self.has_custom_fields(store_at, *custom_fields) | |
custom_fields.each.each do |name| | |
define_method name do | |
self[store_at][name] | |
end | |
define_method "#{name}=" do |new_value| | |
self[store_at][name] = new_value |
This file contains 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
# Put on config/initializers folder | |
class String | |
def to_delocalized_decimal | |
delimiter = I18n::t('number.format.delimiter') | |
separator = I18n::t('number.format.separator') | |
self.gsub(/[#{delimiter}]/, '').gsub(separator, '.') | |
end | |
def to_delocalized_money | |
unit = I18n::t('number.currency.format.unit') |
This file contains 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
# frozen_string_literal: true | |
# Use this setup block to configure all options available in SimpleForm. | |
SimpleForm.setup do |config| | |
# Default class for buttons | |
config.button_class = 'button' | |
# Define the default class of the input wrapper of the boolean input. | |
config.boolean_label_class = 'checkbox' |
This file contains 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
class SoapEnvelopeBuilder | |
SCHEMA_TYPES = { | |
'xmlns:xsd' => 'http://www.w3.org/2001/XMLSchema', | |
'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance' | |
} | |
SOAP_NAMESPACE = { | |
1 => { 'soap11' => 'http://schemas.xmlsoap.org/soap/envelope/' }, | |
2 => { 'soap12' => 'http://www.w3.org/2003/05/soap-envelope' } | |
} |
This file contains 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
gem 'nokogiri, '~> 1.10' | |
gem 'httparty' | |
gem 'wasabi' |