xiaoyong931011
2021-04-12 a13a93a493e7e94e28b2225c26e7e13b52d3288c
zq-erp/src/main/java/com/matrix/system/hive/action/SupplierInfoController.java
@@ -8,9 +8,12 @@
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;
@@ -31,6 +34,8 @@
   @Resource
   private CodeService codeService;
   @Autowired
   private SysShopInfoDao shopInfoDao;
   
@@ -93,8 +98,9 @@
   @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);
   }