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
package com.scrumplus.bo.entity | |
import com.scrumplus.core.framework.crud.{CRUD, BaseCRUD} | |
import com.scrumplus.core.framework.exception.{ErrorCode, ValidationException} | |
import com.scrumplus.core.util.PasswordUtil | |
import com.scrumplus.entity.User | |
/** | |
* @project simple-heroku-webapp | |
* @author sergiovilar |
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
package com.scrumplus.entity | |
import java.util.Date | |
import javax.persistence._ | |
import com.scrumplus.core.framework.crud.{AppEntity, BaseCRUD} | |
import scala.beans.BeanProperty | |
/** | |
* @project simple-heroku-webapp | |
* @author sergiovilar |
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
var validations = Map( | |
"email" -> Map( | |
"function" -> ((bo: CRUD, email: String) => bo.findBy("email", email).size() > 0), | |
"message" -> "Este email já está em uso" | |
), | |
"username" -> Map( | |
"function" -> ((bo: CRUD, username: String) => bo.findBy("username", username).size() > 0), | |
"message" -> "Este nome de usuário já está em uso" | |
) | |
) |
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
#!/bin/bash | |
# A simple script to download all subtitles of files in directory using opensubtitles-client (https://www.npmjs.com/package/opensubtitles-client) | |
for f in * ; do subtitler "$f" --lang pob ; done |
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
package com.scrumplus.core.framework.crud | |
import java.beans.Introspector | |
import java.lang.reflect.Field | |
import com.scrumplus.core.framework.annotation.{Private, WriteOnly, ReadOnly} | |
import scala.language.dynamics | |
import scala.collection.mutable.ListBuffer | |
/** | |
* @project simple-heroku-webapp |
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
class Teste{ | |
String nome, sobrenome; | |
Teste(this.nome, this.sobrenome); | |
String ola(){ | |
return 'Olá, '+this.nome + ' '+ this.sobrenome; | |
} |
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
define([ | |
'jquery', | |
'underscore', | |
'backbone' | |
], function($, _, Backbone){ | |
var Customer = Backbone.Model.extend({ | |
}); | |
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
<?php | |
class ConfigurationController extends BaseController{ | |
protected $layout = 'layouts.dashboard'; | |
function index(){ | |
$articlesNumber = array(10, 20, 40, 60, 80, 100); |
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
def new | |
@cidade = Cidade.new | |
respond_to do |format| | |
flash[:alert] = 'Cidade cadastrada com sucesso' | |
format.html # new.html.erb | |
format.json { render json: @cidade } | |
end | |
end |
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
{ | |
"filter": [ | |
{ | |
"name": "codAgente", | |
"type": "number", | |
"label": "Agente" | |
}, | |
{ |