Posts by Marcelo Ferreira • 544 points
47 posts
-
1
votes1
answer106
viewsQ: properties, and 'i18n' does not exist in type
Project "Vue": " 2.6.10", "Vue-i18n": " 8.15.3" I am configuring the internationalization of the project import Vue from 'vue' import App from './App.vue' import router from './router' import store…
-
0
votes1
answer507
viewsA: Criteria to filter a string array list
Your problem is in that code: filtro.getIndicacoes() This returns a array of string[] {"c1","C2"} While you should return a list of objects Indicacao Objects need to be of compatible types To adjust…
-
1
votes0
answers39
viewsQ: Quartz Spring Test Junit
How to recur a Job that is operating in Cluster in Spring? Spring 4.3 Quartz 2.2.3 Example of Job’s declaration @PersistJobDataAfterExecution @DisallowConcurrentExecution public class…
-
3
votes0
answers182
viewsQ: Quartz cronSchedule for running with an interval greater than one hour
I’m looking to do a cronSchedule of Quartz like this cronSchedule("0 0/5 * 1/1 * ? *") but it’s around every 5 minutes example 7:05, 7:10, 7:15, ... and so on What I need is this 7:05, 8:10, 9:15,…
-
0
votes3
answers1691
viewsA: Button does not execute the Managedbean method
First do not use "setPropertyActionListener" use the method itself Change the edit signature to public String editar(Usuario usuarioEditar){ Another where this "value=#{user}" comes from place in…
-
1
votes0
answers157
viewsQ: Testng Facescontext.getCurrentInstance() Return null
I’m running a test on Facescontext.getCurrentInstance() is returning null. Ambience: Spring 4.3 JSF 2.2 Scope view Escope view is customized for Spring This is scope class, it works public class…
-
0
votes2
answers549
viewsA: Removing replaceAll("[().- "]")
Try it this way "when I apply to remove one at a time the right", take and assemble it, as follows: [ "value-1"|"value-2"|"value-3"] test and see if it is right. Detail this can be much slower than…
-
-1
votes4
answers5888
viewsA: Select with multiple Left Joins Sql Server
First your tables are wrong If name is common to all, so it should be on the parent table Common fields are in the parent table In the parent table you should define a type, which represents, what…
-
1
votes0
answers260
viewsQ: Integration test send e-mail
Today I have a system, which sends several emails. Many settings and upload rules. I need to add about 50 new rules, new emails Time formats with attached file, images and other "cositas" more. Like…
-
1
votes1
answer74
viewsA: How to change getRealPath() save location? Photocam primefaces
First you need to read the file Second you need to know where you want to save the new file Third party you need to copy or crop the file to the new location I like to use apache lib, Fileutils is…
-
1
votes2
answers635
viewsA: Thymeleaf Spring JSF
The whole problem was generated as follows: Themeleaf injects into your source somewhere, it only reads the Messagesource interface; That must have the bean messageSource How JSF needs…
-
1
votes2
answers635
viewsQ: Thymeleaf Spring JSF
I’m trying to do the internationalization of templat using Thymeleaf 3.0 Spring 4.2.3 JSF 2.2 Which is sent along with an email. #{i18N.descriptionPortal} When you print in the email html it looks…
-
0
votes3
answers174
viewsA: Java Strings Comparison Error
If what you said is correct. but when I try to compare it with any string EQUAL java does not recognize that they are equal and simply ignore So the tool you’re using is not compiling, or is trying…
-
0
votes2
answers333
viewsA: Delete data with the @Manytoone interface
If the mapping this current, That’s the way it is. objetoPai.getPedido().remove(pedido-a-ser-removido); sessao.update(objetoPai); To remove it from the list you need to have the hashcode and Equals…
-
2
votes2
answers205
viewsA: Why does my ajax only work when you want?
This one works when it wants to, if it does wrong how it will work. This happens for three reasons. First of all, they don’t really know the concept of ajax. (Concept: Ajax is an asynchronous call…
-
6
votes0
answers180
viewsQ: Spring Websocket multi user chat with sound
I’m trying to develop a real-time chat, with the following scenario. Online clerk Every user he meets is a conversation One to one An attendant sees all users on a list that he is attending. When he…
-
0
votes0
answers397
viewsQ: Chat in Spring JSF and Primefaces
I need to develop a chat for our website. Developed in: JSF 2.2 Srping 4.2 Hibernate 5 Primefaces 5.3 Css bootstrap I already downloaded a project from github, it works cool but is very poor, wanted…
-
5
votes1
answer289
viewsQ: Tag Google Adwords Conversion Actions
Creating a campaign on google Adwords** has the part that needs to validate clicks if they have been effective. In "Conversion Actions" tools creates that script, which says the following that you…
-
0
votes1
answer85
viewsA: Unable to view event details created in the first faces Schedule
This is related to Ajax events That is, when you define (or not, but should limit the scope of the page update) the process="@this" property processes only the Current tag, if you use the…
-
0
votes3
answers523
viewsA: Error in Hibernate
This problem is simply a fact: Factory, failed to map the @Entity objects In other words, Factory does not recognize these classes cfg.addAnnotatedClass(Client.class); This is not working. Hint look…
-
-1
votes2
answers1494
viewsA: Access and permission control
Better than pure filter does not exist. Springsecurity also filter, but specific and plastered. Example: /** * Filter para tratar login no sistema */ @WebFilter( filterName = "all", urlPatterns = {…
-
2
votes1
answer43
viewsA: JSF + Richfaces - Print HTML in Datatable
Use the property: * escape="false" More details here
-
0
votes1
answer42
viewsA: Null in Baseurl - Selenium IDE - Junit
Downloaded the driver, configured? Ai can use, Example with the Chrome public WebDriver getChromeDriver() { LOG.info("getChromeDriver"); System.setProperty("webdriver.chrome.driver",…
selenium-webdriveranswered Marcelo Ferreira 544 -
2
votes2
answers95
viewsA: Validate text before going to the screen
Your problem seems to be on a strange course, if I understand what you need, this answer solves. That does not need algorithms because jsf already has a property to treat that. Something else will…
-
1
votes2
answers153
viewsA: Many to One Hibernate Java
Don’t use that @Fetch(Fetchmode.SUBSELECT) because you need to use it that way? remove this and resolve. @OneToMany(targetEntity = Aditivo.class, mappedBy="contrato", fetch=FetchType.EAGER)…
-
1
votes4
answers724
viewsA: Java: When to use Interrupt vs flags?
My experience Your project is simple. Few threads Few routines So we can consider such a scenario as any well-implemented solution serves. Context, I participated in a project where parallel…
-
1
votes2
answers223
viewsA: Comparator - Priorityqueue
To sort with one or more fields works like this, assuming 3 fields in your case is two. Lesson 1: as the number of fields increases the number increases and when it returns zero it does not change…
javaanswered Marcelo Ferreira 544 -
1
votes2
answers104
viewsA: bootstrapValidator.js with jsf does not work
You can’t use it that way $ = jQuery; Replace all $ for Jquery, this generates conflicts with the lib primefaces, I know Jquery and Other JS say they can do what they did. But it doesn’t work! Use…
-
0
votes1
answer196
viewsA: Relation N x N in Java objects
I’ll share a solution with you. You will only need to get a few details such as field names to do the get and set and hashcode and equals methods of the 4 classes Item class @Entity @Table(name =…
-
0
votes2
answers419
viewsA: What are private and public Keys?
Public and private keys are related to their functionality, where and when to send data, consider whether the client server scenario. Example by sending a form (client), take my public key encode…
-
0
votes0
answers177
viewsQ: Liquibase. sql file not found
When I run liquibase it does not find . slq files configured by tag. Sqlfile. how to solve this? Data from the problem: Design use of liquibase 3.4.2. Configured the Maven plugin Execute script in…
-
0
votes1
answer175
viewsQ: p:primefaces editor tabindex does not work
In a view . xhtml I use the p:editor of the first faces <p:editor id="idDescription" tabidex="2" > ... When the tab key is pressed, after being in field 1, tabindex="1", it does not go to the…
-
0
votes2
answers61
viewsA: Could you help me because you won’t remove it from the list?
Do not remove from the list simply because you have not implemented the object’s hashcode and Equals methods, or are done wrong. This way the list does not find the object to be removed. Implement…
javaanswered Marcelo Ferreira 544 -
0
votes1
answer180
viewsA: Selenium perform task to the end
I made several configurations with Annotations, they even work a few times but they present a very big instability. So I was able to understand that only with Annotations does not work, Selenium…
-
1
votes1
answer180
viewsQ: Selenium perform task to the end
In tests with Selenium, running by Eclipse, when I run several at the same time. Errors happen: First, does not finish running the task opens another browser. Starts running the second test without…
-
2
votes2
answers352
viewsA: Code help (appears to be hexadecimal)
That is hexadicimal yes Translation is this QDR YD WDR JH QWLOPHQWH QHV VD ERD QRLWX HVFXUDUDLYD F RQWUD D PRUWH GD OXC TX IX OJXUD Now all that’s missing is the mathematical function that untangles…
-
0
votes1
answer186
viewsQ: Httpsessionlistener a single session per user
How can I make only one http session is open per user on the system. Main technologies in the project: Spring 4 JSF 2.2 Hibernate 5 Example: The user Juca, works on your computer using 3 browser.…
-
1
votes1
answer824
viewsA: Create Dto by Constructor with a List parameter of a Hibernate entity
You must create a constructor as follows for the object OperacaoDTO(operacao.stagings, operacao.valor) The types must be equal to the Object, for example: if value is Double and stagings for String…
-
0
votes3
answers1045
viewsA: Separate values from List
Do not use vector, use maps (Map) or implement hashCode and and equals of the object and work as follows. List<Integer> lista = new ArrayList<Integer>(); lista.add(new Integer(30));…
-
1
votes1
answer194
viewsA: List coming with null value
Your mistake is in your service. Productoservice public List<Produto> buscarPrincipaisProdutos(){ //ligar serviço ao repositório return null; //ajuste isso } For if his Product has the objects…
-
2
votes1
answer935
viewsA: JPA/Primefaces - Add/Remove records from a daughter table
Your problem is related to Actions, for example: for Factory Hibernate (sessionfactory) @Cascade(value = { CascadeType.PERSIST, CascadeType.MERGE, CascadeType.DELETE, CascadeType.SAVE_UPDATE}) If…
-
0
votes0
answers147
viewsQ: Selenium with Maven plugin does not work the tests
Implementation to run a Junit and testNG test suite, When executed by the eclipse plugin, it works. By Maven no, the behavior of testNG tests, are changed, It seems that the http sessions do not end…
-
2
votes4
answers2850
viewsQ: Selenium cannot find by id
I’m running a test with testNG along with Selenium org.openqa.selenium.By Test, do this search: driver.findElement(By.id("idRoleCheck:0")).click(); Gives the following error:…
-
0
votes2
answers224
viewsA: Why does Hibernate not list results if the select query calls table null field?
Hibernate does not work with primitive types (hibernate, do not work) Java and primitive types need converters because a primitive type will never be null always has a default value Try to do…
-
0
votes1
answer43
viewsA: variable does not take selectedOneMenu value
This is wrong <f:selectItems value="#{dir_controle.selectedDs()}" /> it must be something like this <f:selectItems itemLabel="#{status.name}" var="status"…
jsfanswered Marcelo Ferreira 544 -
0
votes3
answers1429
viewsA: Edit an already created XLS file
That’ll fix what you need XSSFWorkbook workbook = null; File file = new File("C:\\Teste.xls"); FileOutputStream out = null; XSSFSheet excelSheet = null; CellStyle style = null; XSSFFont font = null;…
-
1
votes0
answers341
viewsQ: Barcode Ireport, Barcode 2int5
I built a new custom layout that we received by webservice I used Ireport 6.3.0 When I print the barcode gets distorted The variable that the barcode receives the value is of type String The value…