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
@Repository | |
interface StockRepository extends JpaRepository<Stock, Long> { | |
@Query(value = 'SELECT DISTINCT s FROM Stock s LEFT JOIN FETCH s.warehouse LEFT JOIN FETCH s.commitments WHERE s.sku IN (?1) AND s.organizationId = ?2') | |
List<Stock> findAllBySkuInAndOrganizationId(Set<String> skus, Long organizationId) | |
//... | |
} |
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
@Repository | |
class StockJdbcRepository { | |
final NamedParameterJdbcTemplate inventoryJdbcTemplate | |
@Autowired | |
StockJdbcRepository(NamedParameterJdbcTemplate inventoryJdbcTemplate) { | |
this.inventoryJdbcTemplate = inventoryJdbcTemplate | |
} | |
List<Stock> findAllBySkuInAndOrganizationId(Set<String> skus, Long organizationId) { |
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
Verifying that +wbruno is my blockchain ID. https://onename.com/wbruno |
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
<ul id="menu"> | |
<li>1</li> | |
<li>2</li> | |
<li>3</li> | |
<li>4</li> | |
</ul> | |
<script type="text/javascript"> | |
Element.prototype.is = function(elementSelector) { | |
switch(elementSelector[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
/** | |
* 2.Faça uma função que receba um número N e retorne a soma dos algarismos de N!. | |
* Ex: se N = 4, N! = 24. Logo, a soma de seus algarismos e 2 + 4 = 6. | |
*/ | |
#include <stdio.h> | |
#include <string.h> | |
int fatorial(int n) { | |
int fat = 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
/** | |
* Consulta ao WebService CEP da Republica Virtual (http://www.republicavirtual.com.br/cep/), por json | |
* exemplo em NodeJS por William Bruno <[email protected]> | |
*/ | |
(function(){ | |
'use strict'; | |
var http = require('http'), | |
cep = '05570060', |