Package com.jpoweredcart.common.entity.catalog

Examples of com.jpoweredcart.common.entity.catalog.InformationToLayout


  public static class Layout implements RowMapper<InformationToLayout>{

    @Override
    public InformationToLayout mapRow(ResultSet rs, int rowNum)
        throws SQLException {
      InformationToLayout infoLayout = new InformationToLayout();
      infoLayout.setInformationId(rs.getInt("information_id"));
      infoLayout.setStoreId(rs.getInt("store_id"));
      infoLayout.setLayoutId(rs.getInt("layout_id"));
      return infoLayout;
    }
View Full Code Here


    List<InformationDesc> descList = languageAdminModel
        .createDescriptionList(InformationDesc.class);
    infoForm.setDescs(descList);
    List<InformationToLayout> itlList = new ArrayList<InformationToLayout>();
    for(Store store: storeAdminModel.getAll()){
      InformationToLayout itl = new InformationToLayout();
      itl.setStoreId(store.getId());
      itl.setStoreName(store.getName());
      itlList.add(itl);
    }
    infoForm.setLayouts(itlList);
   
    return infoForm;
View Full Code Here

  @Override
  public List<InformationToLayout> getInfoLayouts(Integer infoId) {
    List<InformationToLayout> itlList = new ArrayList<InformationToLayout>();
    for(Store store: storeAdminModel.getAll()){
      InformationToLayout itl = new InformationToLayout();
      itl.setStoreId(store.getId());
      itl.setStoreName(store.getName());
      String sql = "SELECT layout_id FROM "+quoteTable("information_to_layout")
          +" WHERE information_id=? AND store_id=?";
      Integer layoutId = getJdbcOperations().query(sql,
          new Object[]{infoId, store.getId()},
          new ScalarResultSetExtractor<Integer>());
      itl.setLayoutId(layoutId);
      itlList.add(itl);
    }
    return itlList;
  }
View Full Code Here

TOP

Related Classes of com.jpoweredcart.common.entity.catalog.InformationToLayout

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.