AL-4824
parent
7e45bb957a
commit
62c528747e
|
@ -16,4 +16,8 @@ public interface FormaPagoDAO extends GenericDAO<FormaPago, Short> {
|
||||||
public List<FormaPago> buscarPorDescricao(String descpago);
|
public List<FormaPago> buscarPorDescricao(String descpago);
|
||||||
|
|
||||||
public List<FormaPago> buscarTodosExceto(Integer... idFormaPago);
|
public List<FormaPago> buscarTodosExceto(Integer... idFormaPago);
|
||||||
|
|
||||||
|
public List<FormaPago> buscarNotIn(Short... idsFormaPago);
|
||||||
|
|
||||||
|
public List<FormaPago> buscarIn(Short... idsFormaPago);
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,4 +55,24 @@ public class FormaPagoHibernateDAO extends GenericHibernateDAO<FormaPago, Short>
|
||||||
return c.list();
|
return c.list();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<FormaPago> buscarNotIn(Short... idsFormaPago) {
|
||||||
|
Criteria c = this.makeCriteria();
|
||||||
|
for (Short id : idsFormaPago) {
|
||||||
|
c.add(Restrictions.ne("formapagoId", id));
|
||||||
|
}
|
||||||
|
c.add(Restrictions.eq(ACTIVO, Boolean.TRUE));
|
||||||
|
c.addOrder(Order.asc("descpago"));
|
||||||
|
return c.list();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<FormaPago> buscarIn(Short... idFormaPago) {
|
||||||
|
Criteria c = this.makeCriteria();
|
||||||
|
c.add(Restrictions.in("formapagoId", idFormaPago));
|
||||||
|
c.add(Restrictions.eq(ACTIVO, Boolean.TRUE));
|
||||||
|
c.addOrder(Order.asc("descpago"));
|
||||||
|
return c.list();
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,4 +22,8 @@ public interface FormaPagoService extends GenericService<FormaPago, Short> {
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public List<FormaPago> buscarFormasPagoExceptoEspeciales();
|
public List<FormaPago> buscarFormasPagoExceptoEspeciales();
|
||||||
|
|
||||||
|
public List<FormaPago> buscarNotIn(Short... idFormaPago);
|
||||||
|
|
||||||
|
public List<FormaPago> buscarIn(Short... idFormaPago);
|
||||||
}
|
}
|
||||||
|
|
|
@ -103,4 +103,12 @@ public class FormaPagoServiceImpl implements FormaPagoService {
|
||||||
public List<FormaPago> buscarFormasPagoExceptoEspeciales() {
|
public List<FormaPago> buscarFormasPagoExceptoEspeciales() {
|
||||||
return formaPagoDAO.buscarTodosExceto(formasPagoEspeciales);
|
return formaPagoDAO.buscarTodosExceto(formasPagoEspeciales);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<FormaPago> buscarNotIn(Short... idFormaPago) {
|
||||||
|
return formaPagoDAO.buscarNotIn(idFormaPago);
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<FormaPago> buscarIn(Short... idFormaPago) {
|
||||||
|
return formaPagoDAO.buscarIn(idFormaPago);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue