XzdwxxService.java 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. package com.cxfws.gkjcxx.service.impl;
  2. import java.util.List;
  3. import javax.annotation.PostConstruct;
  4. import javax.jws.WebMethod;
  5. import javax.jws.WebResult;
  6. import javax.jws.WebService;
  7. import net.sf.json.JSONArray;
  8. import org.springframework.beans.factory.annotation.Autowired;
  9. import org.springframework.stereotype.Service;
  10. import com.cxfws.gkjcxx.service.IXzdwxxService;
  11. import com.xt.jygl.common.BaseWebCtl;
  12. import com.xt.jygl.gkjcxx.xzdwxxgl.xzglbmxx.dao.XzglbmxxDao;
  13. import com.xt.jygl.gkjcxx.xzdwxxgl.xzglbmxx.entity.XzglbmxxEntity;
  14. /**
  15. * 行政单位信息查询(根据所在地)
  16. * @author b_zhaohang
  17. *
  18. */
  19. @Service("xzbmWebService")
  20. @WebService(targetNamespace = "http://service.web.jsjty.com/", portName = "xzbmWebServicePort", serviceName = "xzbmWebService")
  21. public class XzdwxxService extends BaseWebCtl implements IXzdwxxService{
  22. @Autowired
  23. private XzglbmxxDao dao;
  24. @PostConstruct
  25. private void init(){
  26. //System.out.println("------DiexcService--init-");
  27. }
  28. @Override
  29. @WebMethod(operationName = "findXzbm", action = "http://service.web.jsjty.com/findXZbm")
  30. @WebResult(name = "result", targetNamespace = "http://service.web.jsjty.com/")
  31. public String findXzbm(String pid,String szd) {
  32. if (!this.checkUser()){
  33. return BaseWebCtl.NOLOGIN;
  34. }
  35. List<XzglbmxxEntity> list = dao.queryXzglbm(pid,szd);
  36. JSONArray jsons=JSONArray.fromObject(list);
  37. return jsons.toString();
  38. }
  39. }