| | |
| | | import com.matrix.core.tools.WebUtil; |
| | | import com.matrix.system.common.bean.SysUsers; |
| | | import com.matrix.system.hive.action.util.QueryUtil; |
| | | import com.matrix.system.hive.bean.SysShopInfo; |
| | | import com.matrix.system.hive.bean.SysSupplierInfo; |
| | | import com.matrix.system.hive.dao.SysShopInfoDao; |
| | | import com.matrix.system.hive.service.CodeService; |
| | | import com.matrix.system.hive.service.SysSupplierInfoService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | |
| | | @Resource |
| | | private CodeService codeService; |
| | | |
| | | @Autowired |
| | | private SysShopInfoDao shopInfoDao; |
| | | |
| | | |
| | | |
| | |
| | | @RequestMapping(value = "/all") |
| | | public @ResponseBody AjaxResult all(SysSupplierInfo sysSupplierInfo) { |
| | | SysUsers sysUsers = WebUtil.getSessionAttribute(MatrixConstance.LOGIN_KEY); |
| | | sysSupplierInfo.setShopId(sysUsers.getShopId()); |
| | | sysSupplierInfo.setCompanyId(sysUsers.getCompanyId()); |
| | | SysShopInfo shopInfo = shopInfoDao.selectZbShop(sysUsers.getCompanyId()); |
| | | sysSupplierInfo.setShopId(shopInfo.getId()); |
| | | sysSupplierInfo.setCompanyId(shopInfo.getCompanyId()); |
| | | |
| | | return new AjaxResult(AjaxResult.STATUS_SUCCESS, currentService.findByModel(sysSupplierInfo), 0); |
| | | } |