Преглед изворни кода

基础信息数据查询功能修复

liao-sea пре 1 година
родитељ
комит
5467281b55

+ 13 - 13
src/main/java/com/hz/employmentsite/controller/baseSettings/InstitutionController.java

@@ -45,7 +45,7 @@ public class InstitutionController {
     public BaseResponse<InstitutionModel> get(@RequestParam(required = false) String szkey) {
         InstitutionModel dataModel = new  InstitutionModel();
         if (szkey==null || szkey==""){
-            dataModel.szkey = UUID.randomUUID().toString();
+            dataModel.InstitutionID = UUID.randomUUID().toString();
         }else{
             dataModel = institutionService.get(szkey);
         }
@@ -75,18 +75,18 @@ public class InstitutionController {
                 List<Object> row = new ArrayList();
                 ++i;
                 row.add(i);
-                row.add(item.szcompanycode);
-                row.add(item.szcompanyname);
-                row.add(item.szcomusermobile);
-                row.add(item.szcomusername);
-                row.add(item.szfrmobile);
-                row.add(item.szfrname);
-                row.add(item.szsavetime);
-                row.add(item.szupdatetime);
-                row.add(item.szcomaddress);
-                row.add(item.szdetail);
-                row.add(item.szsaveuser);
-                row.add(item.szupdateuser);
+                row.add(item.CompanyCode);
+                row.add(item.CompanyCode);
+                row.add(item.FzrName);
+                row.add(item.FzrMobile);
+                row.add(item.FrName);
+                row.add(item.FrMobile);
+                row.add(item.CompanyAddress);
+                row.add(item.CompanyDesc);
+                row.add(item.CreateUserID);
+                row.add(item.CreateTime);
+                row.add(item.ModifyUserID);
+                row.add(item.ModifyTime);
                 rowDatas.add(row);
             }
             data.setRows(rowDatas);

+ 2 - 2
src/main/java/com/hz/employmentsite/controller/baseSettings/SiteInfoController.java

@@ -28,9 +28,9 @@ public class SiteInfoController {
     public BaseResponse<PageInfo<SiteInfoModel>> getList(@RequestParam("pageIndex") int pageIndex, @RequestParam("pageSize") int pageSize,
                                                          @RequestParam(required = false) String primaryKey, @RequestParam(required = false) String siteCode,
                                                          @RequestParam(required = false) String siteName, @RequestParam(required = false) String institutionName,
-                                                         @RequestParam(required = false) String regionName, @RequestParam(required = false) String streetName) {
+                                                         @RequestParam(required = false) String regionCode, @RequestParam(required = false) String streetCode) {
 
-        PageInfo<SiteInfoModel> result = siteService.getList(pageIndex,pageSize,primaryKey,siteCode,siteName,institutionName,regionName,streetName);
+        PageInfo<SiteInfoModel> result = siteService.getList(pageIndex,pageSize,primaryKey,siteCode,siteName,institutionName,regionCode,streetCode);
 
         return RespGenerstor.success(result);
     }

+ 0 - 15
src/main/java/com/hz/employmentsite/mapper/InstitutionMapper.java

@@ -1,15 +0,0 @@
-package com.hz.employmentsite.mapper;
-
-import com.hz.employmentsite.model.InstitutionRecord;
-import com.hz.employmentsite.model.InstitutionRecordExample;
-
-public interface InstitutionMapper {
-
-    InstitutionRecord selectByPrimaryKey(String problemLedgerRecordID);
-
-    int insert(InstitutionRecord row);
-
-    int updateByPrimaryKey(InstitutionRecord row);
-
-    int deleteByExample(InstitutionRecordExample example);
-}

+ 1 - 1
src/main/java/com/hz/employmentsite/mapper/cquery/SiteInfoCQuery.java

@@ -8,6 +8,6 @@ import java.util.List;
 public interface SiteInfoCQuery {
     List<SiteInfoModel> getList(@Param("primaryKey") String primaryKey, @Param("siteCode") String siteCode,
                                 @Param("siteName") String siteName, @Param("institutionName") String institutionName,
-                                @Param("regionName") String regionName, @Param("streetName") String streetName);
+                                @Param("regionCode") String regionCode, @Param("streetCode") String streetCode);
 
 }

+ 0 - 84
src/main/java/com/hz/employmentsite/model/InstitutionRecord.java

@@ -1,84 +0,0 @@
-package com.hz.employmentsite.model;
-
-public class InstitutionRecord {
-    public String szkey;
-    public String szcompanycode;
-    public String szcompanyname;
-    public String szcomaddress;
-    public String szdetail;
-
-    public String szcomusername;
-    public String szcomusermobile;
-
-    public String szfrname;
-    public String szfmobile;
-
-    public String szsaveuser;
-    public String szsavetime;
-    public String szupdateuser;
-    public String szupdatetime;
-
-    public String getszkey() {
-        return szkey;
-    }
-    public void setszkey(String szkey) {this.szkey = szkey == null ? null : szkey.trim();}
-
-
-    public String getszcompanycode() {
-        return szcompanycode;
-    }
-    public void setszcompanycode(String szcompanycode) {this.szcompanycode = szcompanycode == null ? null : szcompanycode.trim();}
-    public String getszcompanyname() {
-        return szcompanyname;
-    }
-    public void setszcompanyname(String szcompanyname) {this.szcompanyname = szcompanyname == null ? null : szcompanyname.trim();}
-    public String getszcomaddress() {
-        return szcomaddress;
-    }
-    public void setszcomaddress(String szcomaddress) {this.szcomaddress = szcomaddress == null ? null : szcomaddress.trim();}
-
-
-    public String getszcomusername() {
-        return szcomusername;
-    }
-    public void setszcomusername(String szcomusername) {this.szcomusername = szcomusername == null ? null : szcomusername.trim();}
-    public String getszcomusermobile() {
-        return szcomusermobile;
-    }
-    public void setszcomusermobile(String szcomusermobile) {this.szcomusermobile = szcomusermobile == null ? null : szcomusermobile.trim();}
-    public String getszdetail() {
-        return szdetail;
-    }
-    public void setszdetail(String szdetail) {this.szdetail = szdetail == null ? null : szdetail.trim();}
-
-    public String getszfrname() {
-        return szfrname;
-    }
-    public void setszfrname(String szfrname) {this.szfrname = szfrname == null ? null : szfrname.trim();}
-    public String getszfmobile() {
-        return szfmobile;
-    }
-    public void setszfmobile(String szfmobile) {this.szfmobile = szfmobile == null ? null : szfmobile.trim();}
-
-
-
-    public String getszsaveuser() {
-        return szsaveuser;
-    }
-    public void setszsaveuser(String szsaveuser) {this.szsaveuser = szsaveuser == null ? null : szsaveuser.trim();}
-    public String getszsavetime() {
-        return szsavetime;
-    }
-    public void setszsavetime(String szsavetime) {this.szsavetime = szsavetime == null ? null : szsavetime.trim();}
-
-
-    public String getszupdateuser() {
-        return szupdateuser;
-    }
-    public void setszupdateuser(String szupdateuser) {this.szupdateuser = szupdateuser == null ? null : szupdateuser.trim();}
-    public String getszupdatetime() {
-        return szupdatetime;
-    }
-    public void setszupdatetime(String szupdatetime) {this.szupdatetime = szupdatetime == null ? null : szupdatetime.trim();}
-
-}

Разлика између датотеке није приказан због своје велике величине
+ 0 - 1084
src/main/java/com/hz/employmentsite/model/InstitutionRecordExample.java


+ 35 - 35
src/main/java/com/hz/employmentsite/services/impl/baseSettings/InstitutionImpl.java

@@ -2,10 +2,10 @@ package com.hz.employmentsite.services.impl.baseSettings;
 
 import com.github.pagehelper.PageHelper;
 import com.github.pagehelper.PageInfo;
-import com.hz.employmentsite.mapper.InstitutionMapper;
+import com.hz.employmentsite.mapper.PcInstitutionMapper;
 import com.hz.employmentsite.mapper.cquery.InstitutionCQuery;
-import com.hz.employmentsite.model.InstitutionRecord;
-import com.hz.employmentsite.model.InstitutionRecordExample;
+import com.hz.employmentsite.model.PcInstitution;
+import com.hz.employmentsite.model.PcInstitutionExample;
 import com.hz.employmentsite.services.service.baseSettings.InstitutionService;
 import com.hz.employmentsite.util.StringUtils;
 import com.hz.employmentsite.vo.baseSettings.InstitutionModel;
@@ -26,7 +26,8 @@ public class InstitutionImpl implements InstitutionService {
     private StringUtils stringUtils;
 
     @Autowired
-    private InstitutionMapper institutionMapper;
+    private PcInstitutionMapper pcInstitutionMapper;
+
 
     @Override
     public PageInfo<InstitutionModel> getList(int pageIndex, int pageSize, String primaryKey,String companyName,String companyAddress,String dutyUserName) {
@@ -47,47 +48,46 @@ public class InstitutionImpl implements InstitutionService {
     @Override
     public Integer save(InstitutionModel data, String userId) {
         int result = 0;
-        InstitutionModel record = get(data.szkey);
-        InstitutionRecord dbData = record ==null ? null : institutionMapper.selectByPrimaryKey(record.szkey);
+        InstitutionModel record = get(data.InstitutionID);
+        PcInstitution dbData = record ==null ? null : pcInstitutionMapper.selectByPrimaryKey(record.InstitutionID);
         Boolean isExist = dbData != null;
         if (!isExist) {
             //添加
-            dbData = new InstitutionRecord();
-            dbData.setszkey(data.getSzkey());
-            dbData.setszcompanycode(data.getSzcompanycode());
-            dbData.setszcompanyname(data.getSzcompanyname());
-            dbData.setszcomaddress(data.getSzcomaddress());
-            dbData.setszcomusername(data.getSzcomusername());
-            dbData.setszcomusermobile(data.getSzcomusermobile());
-            dbData.setszfrname(data.getSzfrname());
-            dbData.setszfmobile(data.getSzfrmobile());
-            dbData.setszdetail(data.getSzdetail());
-            dbData.setszsaveuser(userId);
-            dbData.setszsavetime(new Date().toString());
-            result = institutionMapper.insert(dbData);
+            dbData = new PcInstitution();
+            dbData.setInstitutionID(data.getInstitutionID());
+            dbData.setCompanyCode(data.getCompanyCode());
+            dbData.setCompanyName(data.getCompanyName());
+            dbData.setCompanyAddress(data.getCompanyAddress());
+            dbData.setFzrName(data.getFzrName());
+            dbData.setFzrMobile(data.getFzrName());
+            dbData.setFrName(data.getFrName());
+            dbData.setFrMobile(data.getFzrMobile());
+            dbData.setCompanyDesc(data.getCompanyDesc());
+            dbData.setCreateUserID(userId);
+            dbData.setCreateTime(new Date());
+            result = pcInstitutionMapper.insert(dbData);
         } else {
             //修改
-            dbData.setszcompanycode(data.szcompanycode);
-            dbData.setszcomaddress(data.szcomaddress);
-            dbData.setszfmobile(data.szfrmobile);
-            dbData.setszdetail(data.szdetail);
-            dbData.setszfrname(data.szfrname);
-            dbData.setszcomusermobile(data.szcomusermobile);
-            dbData.setszcompanyname(data.szcompanyname);
-            dbData.setszcomusername(data.szcomusername);
-            dbData.setszupdateuser(userId);
-            dbData.setszupdatetime(new Date().toString());
-            result = institutionMapper.updateByPrimaryKey(dbData);
+            dbData.setCompanyCode(data.CompanyCode);
+            dbData.setCompanyName(data.CompanyName);
+            dbData.setCompanyAddress(data.CompanyAddress);
+            dbData.setFzrName(data.FzrName);
+            dbData.setFzrMobile(data.FzrMobile);
+            dbData.setFrName(data.FzrName);
+            dbData.setFrMobile(data.FzrMobile);
+            dbData.setCompanyDesc(data.CompanyDesc);
+            dbData.setModifyUserID(userId);
+            dbData.setModifyTime(new Date());
+            result = pcInstitutionMapper.updateByPrimaryKey(dbData);
         }
         return result;
     }
 
     @Override
     public Integer delete(List<String> idList){
-        InstitutionRecordExample contactExample = new InstitutionRecordExample();
-        contactExample.or().andszkeyIn(idList);
-        institutionMapper.deleteByExample(contactExample);
-
-        return institutionMapper.deleteByExample(contactExample);
+        PcInstitutionExample contactExample = new PcInstitutionExample();
+        contactExample.or().andInstitutionIDIn(idList);
+        pcInstitutionMapper.deleteByExample(contactExample);
+        return pcInstitutionMapper.deleteByExample(contactExample);
     }
 }

+ 3 - 3
src/main/java/com/hz/employmentsite/services/impl/baseSettings/SiteInfoImpl.java

@@ -15,15 +15,15 @@ import java.util.List;
 public class SiteInfoImpl implements SiteInfoService {
 
     @Autowired
-    private SiteInfoCQuery siteCQuery;
+    private SiteInfoCQuery siteInfoCQuery;
 
     @Autowired
     private StringUtils stringUtils;
 
     @Override
-    public PageInfo<SiteInfoModel> getList(int pageIndex, int pageSize, String primaryKey, String siteCode, String siteName, String institutionName, String regionName, String streetName) {
+    public PageInfo<SiteInfoModel> getList(int pageIndex, int pageSize, String primaryKey, String siteCode, String siteName, String institutionName, String regionCode, String streetCode) {
         PageHelper.startPage(pageIndex, pageSize);
-        List<SiteInfoModel> dataList = siteCQuery.getList(primaryKey,siteCode,siteName,institutionName,regionName,streetName);
+        List<SiteInfoModel> dataList = siteInfoCQuery.getList(primaryKey,siteCode,siteName,institutionName,regionCode,streetCode);
         PageInfo<SiteInfoModel> result = new PageInfo(dataList);
         return result;
     }

+ 1 - 1
src/main/java/com/hz/employmentsite/services/service/baseSettings/SiteInfoService.java

@@ -6,6 +6,6 @@ import com.hz.employmentsite.vo.baseSettings.SiteInfoModel;
 
 public interface SiteInfoService {
 
-    PageInfo<SiteInfoModel> getList(int pageIndex, int pageSize, String primaryKey, String siteCode, String siteName, String institutionName, String regionName, String streetName);
+    PageInfo<SiteInfoModel> getList(int pageIndex, int pageSize, String primaryKey, String siteCode, String siteName, String institutionName, String regionCode, String streetCode);
 
 }

+ 15 - 13
src/main/java/com/hz/employmentsite/vo/baseSettings/InstitutionModel.java

@@ -1,26 +1,28 @@
 package com.hz.employmentsite.vo.baseSettings;
 import lombok.Data;
 
+import java.sql.Time;
+
 @Data
 public class InstitutionModel {
 
-    public String szkey;
-    public String szcompanycode;
-    public String szcompanyname;
-    public String szcomaddress;
-    public String szdetail;
+    public String InstitutionID;
+    public String CompanyCode;
+    public String CompanyName;
+    public String CompanyAddress;
+    public String CompanyDesc;
 
-    public String szcomusername;
-    public String szcomusermobile;
+    public String FzrName;
+    public String FzrMobile;
 
-    public String szfrname;
-    public String szfrmobile;
+    public String FrName;
+    public String FrMobile;
 
     public Integer SiteCount;
 
-    public String szsaveuser;
-    public String szsavetime;
-    public String szupdateuser;
-    public String szupdatetime;
+    public String CreateUserID;
+    public Time CreateTime;
+    public String ModifyUserID;
+    public Time ModifyTime;
 
 }

+ 16 - 14
src/main/java/com/hz/employmentsite/vo/baseSettings/SiteInfoModel.java

@@ -1,27 +1,29 @@
 package com.hz.employmentsite.vo.baseSettings;
 import lombok.Data;
 
+import java.sql.Time;
+
 @Data
 public class SiteInfoModel {
 
-    public String szkey;
-    public String szcode;
-    public String szregion;
-    public String szstreet;
-    public String szaddress;
+    public String SiteID;
+    public String SiteCode;
+    public String RegionCode;
+    public String StreetCode;
+    public String DetailAddress;
 
-    public String szx;
-    public String szy;
+    public String SiteX;
+    public String SiteY;
 
-    public String szname;
-    public String szusername;
-    public String szusermobile;
+    public String SiteName;
+    public String FzrName;
+    public String FzrMobile;
 
     public String CompanyName;
 
-    public String szsaveuser;
-    public String szsavetime;
-    public String szupdateuser;
-    public String szupdatetime;
+    public String CreateUserID;
+    public Time CreateTime;
+    public String ModifyUserID;
+    public Time ModifyTime;
 
 }

+ 0 - 337
src/main/resources/mapping/InstitutionRecordMapper.xml

@@ -1,337 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.hz.employmentsite.mapper.InstitutionMapper">
-  <resultMap id="BaseResultMap" type="com.hz.employmentsite.model.InstitutionRecord">
-    <id column="szkey" jdbcType="VARCHAR" property="szkey" />
-    <result column="szcompanycode" jdbcType="VARCHAR" property="szcompanycode" />
-    <result column="szcompanyname" jdbcType="VARCHAR" property="szcompanyname" />
-    <result column="szcomaddress" jdbcType="VARCHAR" property="szcomaddress" />
-    <result column="szdetail" jdbcType="VARCHAR" property="szdetail" />
-    <result column="szcomusername" jdbcType="VARCHAR" property="szcomusername" />
-    <result column="szcomusermobile" jdbcType="VARCHAR" property="szcomusermobile" />
-    <result column="szfrname" jdbcType="VARCHAR" property="szfrname" />
-    <result column="szfmobile" jdbcType="VARCHAR" property="szfmobile" />
-    <result column="szsaveuser" jdbcType="VARCHAR" property="szsaveuser" />
-    <result column="szsavetime" jdbcType="VARCHAR" property="szsavetime" />
-    <result column="szupdateuser" jdbcType="VARCHAR" property="szupdateuser" />
-    <result column="szupdatetime" jdbcType="VARCHAR" property="szupdatetime" />
-  </resultMap>
-  <sql id="Example_Where_Clause">
-    <where>
-      <foreach collection="oredCriteria" item="criteria" separator="or">
-        <if test="criteria.valid">
-          <trim prefix="(" prefixOverrides="and" suffix=")">
-            <foreach collection="criteria.criteria" item="criterion">
-              <choose>
-                <when test="criterion.noValue">
-                  and ${criterion.condition}
-                </when>
-                <when test="criterion.singleValue">
-                  and ${criterion.condition} #{criterion.value}
-                </when>
-                <when test="criterion.betweenValue">
-                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
-                </when>
-                <when test="criterion.listValue">
-                  and ${criterion.condition}
-                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
-                    #{listItem}
-                  </foreach>
-                </when>
-              </choose>
-            </foreach>
-          </trim>
-        </if>
-      </foreach>
-    </where>
-  </sql>
-  <sql id="Update_By_Example_Where_Clause">
-    <where>
-      <foreach collection="example.oredCriteria" item="criteria" separator="or">
-        <if test="criteria.valid">
-          <trim prefix="(" prefixOverrides="and" suffix=")">
-            <foreach collection="criteria.criteria" item="criterion">
-              <choose>
-                <when test="criterion.noValue">
-                  and ${criterion.condition}
-                </when>
-                <when test="criterion.singleValue">
-                  and ${criterion.condition} #{criterion.value}
-                </when>
-                <when test="criterion.betweenValue">
-                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
-                </when>
-                <when test="criterion.listValue">
-                  and ${criterion.condition}
-                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
-                    #{listItem}
-                  </foreach>
-                </when>
-              </choose>
-            </foreach>
-          </trim>
-        </if>
-      </foreach>
-    </where>
-  </sql>
-  <sql id="Base_Column_List">
-    szkey,szcompanycode,szcompanyname,szcomaddress,szdetail,szcomusername,szcomusermobile,
-    szfrname,szfmobile,szsaveuser,szsavetime,szupdateuser,szupdatetime
-  </sql>
-  <select id="selectByExample" parameterType="com.hz.employmentsite.model.InstitutionRecord" resultMap="BaseResultMap">
-    select
-    <if test="distinct">
-      distinct
-    </if>
-    <include refid="Base_Column_List" />
-    from pc_institution
-    <if test="_parameter != null">
-      <include refid="Example_Where_Clause" />
-    </if>
-    <if test="orderByClause != null">
-      order by ${orderByClause}
-    </if>
-  </select>
-  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
-    select 
-    <include refid="Base_Column_List" />
-    from pc_institution
-    where szkey = #{szkey,jdbcType=VARCHAR}
-  </select>
-  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
-    delete from pc_institution
-    where szkey = #{szkey,jdbcType=VARCHAR}
-  </delete>
-  <delete id="deleteByExample" parameterType="com.hz.employmentsite.model.InstitutionRecord">
-    delete from pc_institution
-    <if test="_parameter != null">
-      <include refid="Example_Where_Clause" />
-    </if>
-  </delete>
-  <insert id="insert" parameterType="com.hz.employmentsite.model.InstitutionRecord">
-    insert into pc_institution (szkey,szcompanycode,szcompanyname,szcomaddress,szdetail,szcomusername,szcomusermobile,
-    szfrname,szfmobile,szsaveuser,szsavetime,szupdateuser,szupdatetime)
-    values ( #{szkey,jdbcType=VARCHAR}, #{szcompanycode,jdbcType=VARCHAR},#{szcompanyname,jdbcType=VARCHAR},
-      #{szcomaddress,jdbcType=VARCHAR},#{szdetial,jdbcType=VARCHAR},#{szcomusername,jdbcType=VARCHAR},#{szcomusermobile,jdbcType=VARCHAR},
-      #{szfrname,jdbcType=VARCHAR}, #{szfmobile,jdbcType=VARCHAR},#{szsaveuser,jdbcType=VARCHAR},
-      #{szsavetime,jdbcType=VARCHAR},#{szupdateuser,jdbcType=VARCHAR},#{szupdatetime,jdbcType=VARCHAR})
-  </insert>
-  <insert id="insertSelective" parameterType="com.hz.employmentsite.model.InstitutionRecord">
-    insert into pc_institution
-    <trim prefix="(" suffix=")" suffixOverrides=",">
-      <if test="szkey != null">
-        szkey,
-      </if>
-      <if test="szcompanycode != null">
-        szcompanycode,
-      </if>
-      <if test="szcompanyname != null">
-        szcompanyname,
-      </if>
-      <if test="szcomaddress != null">
-        szcomaddress,
-      </if>
-      <if test="szdetail != null">
-        szdetail,
-      </if>
-      <if test="szcomusername != null">
-        szcomusername,
-      </if>
-      <if test="szcomusermobile != null">
-        szcomusermobile,
-      </if>
-      <if test="szfrname != null">
-        szfrname,
-      </if>
-      <if test="szfmobile != null">
-        szfmobile,
-      </if>
-      <if test="szsaveuser != null">
-        szsaveuser,
-      </if>
-      <if test="szsavetime != null">
-        szsavetime,
-      </if>
-      <if test="szupdateuser != null">
-        szupdateuser,
-      </if>
-      <if test="szupdatetime != null">
-        szupdatetime,
-      </if>
-    </trim>
-    <trim prefix="values (" suffix=")" suffixOverrides=",">
-      <if test="szkey != null">
-        #{szkey,jdbcType=VARCHAR},
-      </if>
-      <if test="szcompanycode != null">
-        #{szcompanycode,jdbcType=VARCHAR},
-      </if>
-      <if test="szcompanyname != null">
-        #{szcompanyname,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomaddress != null">
-        #{szcomaddress,jdbcType=VARCHAR},
-      </if>
-      <if test="szdetail != null">
-        #{szdetail,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomusername != null">
-        #{szcomusername,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomusermobile != null">
-        #{szcomusermobile,jdbcType=VARCHAR},
-      </if>
-      <if test="szfrname != null">
-        #{szfrname,jdbcType=VARCHAR},
-      </if>
-      <if test="szfmobile != null">
-        #{szfmobile,jdbcType=VARCHAR},
-      </if>
-      <if test="szsaveuser != null">
-        #{szsaveuser,jdbcType=VARCHAR},
-      </if>
-      <if test="szsavetime != null">
-        #{szsavetime,jdbcType=VARCHAR},
-      </if>
-      <if test="szupdateuser != null">
-        #{szupdateuser,jdbcType=VARCHAR},
-      </if>
-      <if test="szupdatetime != null">
-        #{szupdatetime,jdbcType=VARCHAR},
-      </if>
-    </trim>
-  </insert>
-  <select id="countByExample" parameterType="com.hz.employmentsite.model.InstitutionRecord" resultType="java.lang.Long">
-    select count(*) from pc_institution
-    <if test="_parameter != null">
-      <include refid="Example_Where_Clause" />
-    </if>
-  </select>
-  <update id="updateByExampleSelective" parameterType="map">
-    update pc_institution
-    <set>
-      <if test="row.szkey != null">
-        szkey = #{row.szkey,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szcompanyname != null">
-        szcompanyname = #{row.szcompanyname,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szcompanycode != null">
-        szcompanycode = #{row.szcompanycode,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szcomaddress != null">
-        szcomaddress = #{row.szcomaddress,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szcomusername != null">
-        szcomusername = #{row.szcomusername,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szcomusermobile != null">
-        szcomusermobile = #{row.szcomusermobile,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szfrname != null">
-        szfrname = #{row.szfrname,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szfrmobile != null">
-        szfrmobile = #{row.szfrmobile,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szdetail != null">
-        szdetail = #{row.szdetail,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szsaveuser != null">
-        szsaveuser = #{row.szsaveuser,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szsavetime != null">
-        szsavetime = #{row.szsavetime,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szupdateuser != null">
-        szupdateuser = #{row.szupdateuser,jdbcType=VARCHAR},
-      </if>
-      <if test="row.szupdatetime != null">
-        szupdatetime = #{row.szupdatetime,jdbcType=VARCHAR},
-      </if>
-    </set>
-    <if test="example != null">
-      <include refid="Update_By_Example_Where_Clause" />
-    </if>
-  </update>
-  <update id="updateByExample" parameterType="map">
-    update pc_institution
-    set szkey = #{row.szkey,jdbcType=VARCHAR},
-        szcompanyname = #{row.szcompanyname,jdbcType=VARCHAR},
-        szcompanycode = #{row.szcompanycode,jdbcType=VARCHAR},
-        szcomaddress = #{row.szcomaddress,jdbcType=VARCHAR},
-        szcomusername = #{row.szcomusername,jdbcType=VARCHAR},
-        szcomusermobile = #{row.szcomusermobile,jdbcType=VARCHAR},
-        szfrname = #{row.szfrname,jdbcType=VARCHAR},
-        szfrmobile = #{row.szfrmobile,jdbcType=VARCHAR},
-        szdetail = #{row.szdetail,jdbcType=VARCHAR},
-        szsaveuser = #{row.szsaveuser,jdbcType=VARCHAR},
-        szsavetime = #{row.szsavetime,jdbcType=VARCHAR},
-        szupdateuser = #{row.szupdateuser,jdbcType=VARCHAR},
-        szupdatetime = #{row.szupdatetime,jdbcType=VARCHAR}
-    <if test="example != null">
-      <include refid="Update_By_Example_Where_Clause" />
-    </if>
-  </update>
-  <update id="updateByPrimaryKeySelective" parameterType="com.hz.employmentsite.model.InstitutionRecord">
-    update pc_institution
-    <set>
-      <if test="szkey != null">
-        szkey = #{szkey,jdbcType=VARCHAR},
-      </if>
-      <if test="szcompanyname != null">
-        szcompanyname = #{szcompanyname,jdbcType=VARCHAR},
-      </if>
-      <if test="szcompanycode != null">
-        szcompanycode = #{szcompanycode,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomaddress != null">
-        szcomaddress = #{szcomaddress,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomusername != null">
-        szcomusername = #{szcomusername,jdbcType=VARCHAR},
-      </if>
-      <if test="szcomusermobile != null">
-        szcomusermobile = #{szcomusermobile,jdbcType=VARCHAR},
-      </if>
-      <if test="szfrname != null">
-        szfrname = #{szfrname,jdbcType=VARCHAR},
-      </if>
-      <if test="szfrmobile != null">
-        szfrmobile = #{szfrmobile,jdbcType=VARCHAR},
-      </if>
-      <if test="szdetail != null">
-        szdetail = #{szdetail,jdbcType=VARCHAR},
-      </if>
-      <if test="szsaveuser != null">
-        szsaveuser = #{szsaveuser,jdbcType=VARCHAR},
-      </if>
-      <if test="szsavetime != null">
-        szsavetime = #{szsavetime,jdbcType=VARCHAR},
-      </if>
-      <if test="szupdateuser != null">
-        szupdateuser = #{szupdateuser,jdbcType=VARCHAR},
-      </if>
-      <if test="szupdatetime != null">
-        szupdatetime = #{szupdatetime,jdbcType=VARCHAR},
-      </if>
-    </set>
-    where szkey = #{szkey,jdbcType=VARCHAR}
-  </update>
-  <update id="updateByPrimaryKey" parameterType="com.hz.employmentsite.model.InstitutionRecord">
-    update pc_institution
-    set szcompanyname = #{szcompanyname,jdbcType=VARCHAR},
-        szcompanycode = #{szcompanycode,jdbcType=VARCHAR},
-        szcomaddress = #{szcomaddress,jdbcType=VARCHAR},
-        szcomusername = #{szcomusername,jdbcType=VARCHAR},
-        szcomusermobile = #{szcomusermobile,jdbcType=VARCHAR},
-        szfrname = #{szfrname,jdbcType=VARCHAR},
-        szfrmobile = #{szfrmobile,jdbcType=VARCHAR},
-        szdetail = #{szdetail,jdbcType=VARCHAR},
-        szsaveuser = #{szsaveuser,jdbcType=VARCHAR},
-        szsavetime = #{szsavetime,jdbcType=VARCHAR},
-        szupdateuser = #{szupdateuser,jdbcType=VARCHAR},
-        szupdatetime = #{szupdatetime,jdbcType=VARCHAR}
-    where szkey = #{szkey,jdbcType=VARCHAR}
-  </update>
-</mapper>

+ 7 - 5
src/main/resources/mapping/cquery/InstitutionCQuery.xml

@@ -2,19 +2,21 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.hz.employmentsite.mapper.cquery.InstitutionCQuery">
     <select id="getList" resultType="com.hz.employmentsite.vo.baseSettings.InstitutionModel">
-        select  A.*,Count(B.szkey)as SiteCount from pc_institution A,pc_site_institution B where A.szkey = B.szinstitutionkey  and 1=1
+        select  B.*,Count(A.SiteInstitutionID)as SiteCount from pc_site_institution  A inner join  pc_institution B on
+        A.InstitutionID = B.InstitutionID  where 1=1
         <if test="primaryKey!='' and primaryKey!=null">
-            and szkey in (${primaryKey})
+            and InstitutionID in (${primaryKey})
         </if>
         <if test="companyName!='' and companyName!=null">
-            and szcompanyname like Concat('%',#{companyName},'%')
+            and Companyname like Concat('%',#{companyName},'%')
         </if>
         <if test="companyAddress!='' and companyAddress!=null">
-            and szcomaddress like Concat('%',#{companyAddress},'%')
+            and CompanyAddress like Concat('%',#{companyAddress},'%')
         </if>
         <if test="dutyUserName!='' and dutyUserName!=null">
-            and szcomusername like Concat('%',#{dutyUserName},'%')
+            and FzrName like Concat('%',#{dutyUserName},'%')
         </if>
+        group by B.InstitutionID
     </select>
 
 </mapper>

+ 10 - 10
src/main/resources/mapping/cquery/SiteInfoCQuery.xml

@@ -2,25 +2,25 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.hz.employmentsite.mapper.cquery.SiteInfoCQuery">
     <select id="getList" resultType="com.hz.employmentsite.vo.baseSettings.SiteInfoModel">
-        select  A.*,C.szcompanyname as CompanyName from pc_site A,pc_site_institution B,pc_institution C
-        where A.szkey = B.szsitekey and B.szinstitutionkey = C.szkey and 1=1
+        select  A.*,C.CompanyName as CompanyName from pc_site A,pc_site_institution B,pc_institution C
+        where A.SiteID = B.SiteID and B.InstitutionID = C.InstitutionID and 1=1
         <if test="primaryKey!='' and primaryKey!=null">
-            and szkey in (${primaryKey})
+            and A.SiteID in (${primaryKey})
         </if>
         <if test="siteCode!='' and siteCode!=null">
-            and szcode like Concat('%',#{siteCode},'%')
+            and SiteCode like Concat('%',#{siteCode},'%')
         </if>
         <if test="siteName!='' and siteName!=null">
-            and szname like Concat('%',#{siteName},'%')
+            and SiteName like Concat('%',#{siteName},'%')
         </if>
         <if test="institutionName!='' and institutionName!=null">
-            and C.szcompanyname like Concat('%',#{institutionName},'%')
+            and C.CompanyName like Concat('%',#{institutionName},'%')
         </if>
-        <if test="regionName!='' and regionName!=null">
-            and szregion like Concat('%',#{regionName},'%')
+        <if test="regionCode!='' and regionCode!=null">
+            and RegionCode like Concat('%',#{regionCode},'%')
         </if>
-        <if test="streetName!='' and streetName!=null">
-            and szstreet like Concat('%',#{streetName},'%')
+        <if test="streetCode!='' and streetCode!=null">
+            and StreetCode like Concat('%',#{streetCode},'%')
         </if>
     </select>
 

+ 1 - 1
src/main/resources/mapping/cquery/UserInfoCQuery.xml

@@ -8,7 +8,7 @@
             and UserID in (${primaryKey})
         </if>
         <if test="userName!='' and userName!=null">
-            and Name like Concat('%',#{userName},'%')
+            and A.Name like Concat('%',#{userName},'%')
         </if>
 
     </select>

+ 7 - 7
vue/src/views/baseSettings/institution/index.vue

@@ -128,13 +128,13 @@ export default defineComponent({
     });
     const columns: TableColumnsType = [
       {title: '序号', align: "center",key: 'szkey',customRender: item => `${searchParams.pageSize * (searchParams.pageIndex - 1) + item.index + 1}`},
-      {title: '企业名称', dataIndex: 'szcompanyname', key: 'szcompanyname', align: "center"},
-      {title: '企业地址', dataIndex: 'szcomaddress', key: 'szcomaddress',width:120, align: "center"},
-      {title: '负责人姓名', dataIndex: 'szcomusername', key: 'szcomusername', align: "center"},
-      {title: '负责人电话', dataIndex: 'szcomusermobile', key: 'szcomusermobile', align: "center"},
-      {title: '法人姓名', dataIndex: 'szfrname', key: 'szfrname', align: "center"},
-      {title: '法人电话', dataIndex: 'szfrmobile', key: 'szfmobile', align: "center"},
-      {title: '企业机构代码', dataIndex: 'szcompanycode', key: 'szcompanycode', align: "center"},
+      {title: '企业名称', dataIndex: 'CompanyName', key: 'CompanyName', align: "center"},
+      {title: '企业地址', dataIndex: 'CompanyAddress', key: 'CompanyAddress',width:120, align: "center"},
+      {title: '负责人姓名', dataIndex: 'FzrName', key: 'FzrName', align: "center"},
+      {title: '负责人电话', dataIndex: 'FzrMobile', key: 'FzrMobile', align: "center"},
+      {title: '法人姓名', dataIndex: 'FrName', key: 'FrName', align: "center"},
+      {title: '法人电话', dataIndex: 'FrMobile', key: 'FrMobile', align: "center"},
+      {title: '企业机构代码', dataIndex: 'CompanyCode', key: 'CompanyCode', align: "center"},
       {
         title: '管理驿站数量', dataIndex: 'SiteCount', key: 'SiteCount', align: "center",
         /*customRender:  ({record}) => record.resolveDate == null?"":dayjs(record.resolveDate).format('YYYY-MM-DD')*/

+ 13 - 13
vue/src/views/baseSettings/site/index.vue

@@ -23,13 +23,13 @@
       </a-row>
       <a-row :gutter="24">
         <a-col :span="6">
-          <a-form-item label="所属县区" :label-col="{span:6}" name="RegionName">
-            <a-input v-model:value="searchParams.regionName" placeholder=""/>
+          <a-form-item label="所属县区" :label-col="{span:6}" name="RegionCode">
+            <a-input v-model:value="searchParams.regionCode" placeholder=""/>
           </a-form-item>
         </a-col>
         <a-col :span="7">
-          <a-form-item label="所属街道" :label-col="{span:7}" name="StreetName">
-            <a-input v-model:value="searchParams.streetName" placeholder=""/>
+          <a-form-item label="所属街道" :label-col="{span:7}" name="StreetCode">
+            <a-input v-model:value="searchParams.streetCode" placeholder=""/>
           </a-form-item>
         </a-col>
         <a-col :span="6">
@@ -86,8 +86,8 @@ export default defineComponent({
       siteCode: '',
       siteName: '',
       institutionName:'',
-      regionName:'',
-      streetName:'',
+      regionCode:'',
+      streetCode:'',
     });
     const formState = reactive({
       total: 0,
@@ -96,13 +96,13 @@ export default defineComponent({
     });
     const columns: TableColumnsType = [
       {title: '序号', align: "center",key: 'szkey',customRender: item => `${searchParams.pageSize * (searchParams.pageIndex - 1) + item.index + 1}`},
-      {title: '驿站编号', dataIndex: 'szcode', key: 'szcode', align: "center"},
-      {title: '站点名称', dataIndex: 'szname', key: 'szname',width:120, align: "center"},
-      {title: '站点负责人', dataIndex: 'szusername', key: 'szusername', align: "center"},
-      {title: '联系电话', dataIndex: 'szusermobile', key: 'szusermobile', align: "center"},
-      {title: '所属县区', dataIndex: 'szregion', key: 'szregion', align: "center"},
-      {title: '所属街道', dataIndex: 'szstreet', key: 'szstreet', align: "center"},
-      {title: '详细地址', dataIndex: 'szaddress', key: 'szaddress', align: "center"},
+      {title: '驿站编号', dataIndex: 'SiteCode', key: 'SiteCode', align: "center"},
+      {title: '站点名称', dataIndex: 'SiteName', key: 'SiteName',width:120, align: "center"},
+      {title: '站点负责人', dataIndex: 'FzrName', key: 'FzrName', align: "center"},
+      {title: '联系电话', dataIndex: 'FzrMobile', key: 'FzrMobile', align: "center"},
+      {title: '所属县区', dataIndex: 'RegionCode', key: 'RegionCode', align: "center"},
+      {title: '所属街道', dataIndex: 'StreetCode', key: 'StreetCode', align: "center"},
+      {title: '详细地址', dataIndex: 'DetailAddress', key: 'DetailAddress', align: "center"},
       {title: '所属机构', dataIndex: 'CompanyName', key: 'CompanyName', align: "center"},
       {title: '驿站人员数量', key: 'UserNumber', fixed: 'right',width:170, align: "center"},
       {title: '操作', key: 'operation', fixed: 'right',width:170, align: "center"},