diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/AddressController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/AddressController.java new file mode 100755 index 000000000..6d5e324fa --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/AddressController.java @@ -0,0 +1,142 @@ +package com.ruoyi.web.controller.system; + +import java.util.List; + +import org.apache.commons.lang3.StringUtils; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.system.domain.Address; +import com.ruoyi.system.service.IAddressService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 地区信息Controller + * + * @author ruoyi + * @date 2020-05-23 + */ +@Controller +@RequestMapping("/system/address") +public class AddressController extends BaseController +{ + private final static String PREFIX = "system/address"; + private final static String ROOT = "0"; + + @Autowired + private IAddressService addressService; + + @RequiresPermissions("system:address:view") + @GetMapping() + public String address() + { + return PREFIX + "/address"; + } + + @RequiresPermissions("system:address:list") + @GetMapping("/childrenList") + @ResponseBody + public List
selectAddressByParentCode(String code) { + return addressService.selectAddressByParentCode(code); + } + + /** + * 查询地区信息列表 + */ + @RequiresPermissions("system:address:list") + @GetMapping("/list") + @ResponseBody + public TableDataInfo list(Address address) + { + startPage(); + if (StringUtils.isBlank(address.getAreaCode()) + || StringUtils.isBlank(address.getAreaName()) + || StringUtils.isBlank(address.getParentCode()) + || address.getId() == null) { + address.setParentCode(ROOT); + } + List
list = addressService.selectAddressList(address); + return getDataTable(list); + } + + /** + * 导出地区信息列表 + */ + @RequiresPermissions("system:address:export") + @Log(title = "地区信息", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(Address address) + { + List
list = addressService.selectAddressList(address); + ExcelUtil
util = new ExcelUtil
(Address.class); + return util.exportExcel(list, "address"); + } + + /** + * 新增地区信息 + */ + @GetMapping("/add") + public String add() + { + return PREFIX + "/add"; + } + + /** + * 新增保存地区信息 + */ + @RequiresPermissions("system:address:add") + @Log(title = "地区信息", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(Address address) + { + return toAjax(addressService.insertAddress(address)); + } + + /** + * 修改地区信息 + */ + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Long id, ModelMap mmap) + { + Address address = addressService.selectAddressById(id); + mmap.put("address", address); + return PREFIX + "/edit"; + } + + /** + * 修改保存地区信息 + */ + @RequiresPermissions("system:address:edit") + @Log(title = "地区信息", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(Address address) + { + return toAjax(addressService.updateAddress(address)); + } + + /** + * 删除地区信息 + */ + @RequiresPermissions("system:address:remove") + @Log(title = "地区信息", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(addressService.deleteAddressByIds(ids)); + } +} diff --git a/ruoyi-admin/src/main/resources/templates/system/address/add.html b/ruoyi-admin/src/main/resources/templates/system/address/add.html new file mode 100755 index 000000000..fa514a27a --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/address/add.html @@ -0,0 +1,43 @@ + + + + + + +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/address/address.html b/ruoyi-admin/src/main/resources/templates/system/address/address.html new file mode 100755 index 000000000..a56e88b91 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/address/address.html @@ -0,0 +1,102 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/address/edit.html b/ruoyi-admin/src/main/resources/templates/system/address/edit.html new file mode 100755 index 000000000..09f33e570 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/address/edit.html @@ -0,0 +1,44 @@ + + + + + + +
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/firm/add.html b/ruoyi-admin/src/main/resources/templates/system/firm/add.html index f4ea00240..07721fd84 100755 --- a/ruoyi-admin/src/main/resources/templates/system/firm/add.html +++ b/ruoyi-admin/src/main/resources/templates/system/firm/add.html @@ -13,7 +13,7 @@ -
+
@@ -47,9 +47,10 @@
- 代码生成请选择字典属性
@@ -59,13 +60,13 @@
- +
- +
@@ -76,103 +77,73 @@
-
- + +
+
- +
-
- +
+
-
- - -
- 代码生成请选择字典属性 -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- + + - 代码生成请选择字典属性
-
- +
+
- + +
+
- +
- + +
+
- +
- + +
+
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- + +
+
-
- -
- -
-
+
@@ -185,33 +156,10 @@
-
- -
- -
-
-
- -
- -
-
-
- -
-
- - -
-
-
-
- -
- -
-
+ + + +
@@ -233,6 +181,44 @@ minView: "month", autoclose: true }); + + function changeAreaCode(selectId) { + var code = '0'; + var nextSelectId = ""; + if ("provinceSelect" == selectId) { + $("#citySelect").empty(); + $("#countrySelect").empty(); + $("#townSelect").empty(); + code = $("#provinceSelect").find("option:selected").attr("value"); + nextSelectId = "citySelect"; + $("#provinceName").val($("#provinceSelect").find("option:selected").text()); + } else if ("citySelect" == selectId) { + code = $("#citySelect").find("option:selected").attr("value"); + nextSelectId = "countrySelect"; + $("#cityName").val($("#citySelect").find("option:selected").text()); + } else if ("countrySelect" == selectId) { + code = $("#countrySelect").find("option:selected").attr("value"); + nextSelectId = "townSelect"; + $("#countryName").val($("#countrySelect").find("option:selected").text()); + } else if ("townSelect" == selectId) { + $("#townName").val($("#townSelect").find("option:selected").text()); + } + + $.ajax({ + url: '/system/address/childrenList', + dataType : "json", + async:true, + data:{code:code}, + success:function (result) { + var str=''; + for (var i = 0; i < result.length; i++) { + str+=''; + } + $("#" + nextSelectId + "").html(str); + } + + }); + } \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/firm/edit.html b/ruoyi-admin/src/main/resources/templates/system/firm/edit.html index f3e2e8cdc..0eee839b2 100755 --- a/ruoyi-admin/src/main/resources/templates/system/firm/edit.html +++ b/ruoyi-admin/src/main/resources/templates/system/firm/edit.html @@ -48,9 +48,10 @@
- 代码生成请选择字典属性
@@ -60,39 +61,18 @@
- +
- +
-
- -
- -
-
-
- -
- -
-
-
- -
-
- - -
- 代码生成请选择字典属性 -
-
+
@@ -108,72 +88,64 @@
- + + - 代码生成请选择字典属性
-
- + + +
+
- + +
-
- + +
+
- + +
-
- + +
+
- + +
-
- + +
+
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- + +
+ + +
-
- -
- -
-
+
@@ -186,32 +158,14 @@
-
- -
- -
-
-
- -
-
- - -
-
-
-
- -
- -
-
+ + +
- \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/firm/firm.html b/ruoyi-admin/src/main/resources/templates/system/firm/firm.html index 5e175d2d9..8bcb0a71f 100755 --- a/ruoyi-admin/src/main/resources/templates/system/firm/firm.html +++ b/ruoyi-admin/src/main/resources/templates/system/firm/firm.html @@ -18,133 +18,52 @@ -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • - - -
  • -
  • - - -
  • -
  • - - - + +
  • - - + +
  • - - + +
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - - - - -
  • -
  • - - + +
  • + + +
  •  搜索  重置 @@ -201,47 +120,53 @@ }, { field: 'loginName', - title: '登录账号' + title: '登录账号', + visible: false + }, { field: 'userName', - title: '用户昵称' + title: '商家名称' }, + { + field: 'businessType', + title: '商家类型' + } + , { field: 'email', title: '用户邮箱' }, { field: 'telephoneNo', - title: '固定电话' + title: '固定电话', + visible: false }, { field: 'phoneNo', - title: '手机号码' + title: '手机号码', + visible: false }, { field: 'sex', - title: '用户性别' + title: '用户性别', + visible: false }, { field: 'avatar', - title: '头像路径' + title: '头像路径', + visible: false + }, { field: 'idCard', - title: '身份证证件地址' + title: '身份证', + visible: false }, { field: 'credentials', - title: '房产、合同等证件地址,json串' - }, - { - field: 'password', - title: '密码' - }, - { - field: 'salt', - title: '盐加密' + title: '证件地址', + visible: false }, { field: 'status', @@ -249,75 +174,46 @@ }, { field: 'guaranteeMoney', - title: '质保金金额' + title: '质保金' }, { field: 'refundGuaranteeMoney', - title: '已退质保金金额' - }, - { - field: 'bussinessType', - title: '商家类型,0个人 1商家' - }, - { - field: 'provinceCode', - title: '省id' + title: '已退质保金' }, { field: 'provinceName', - title: '省名称' + title: '省' }, { - field: 'cityCode', - title: '市ID' + field: 'cityName', + title: '市' }, { - field: 'ciityName', - title: '市名称' - }, - { - field: 'countyCode', - title: '县ID' - }, - { - field: 'countyName', - title: '县名称' - }, - { - field: 'townCode', - title: '乡/镇ID' + field: 'countryName', + title: '县' }, { field: 'townName', - title: '乡/镇名称' + title: '乡/镇' }, { field: 'adress', - title: '详细地址信息' + title: '详细地址' }, { field: 'coordinatePoint', - title: '坐标地址' + title: '坐标地址', + visible: false }, { field: 'bankName', - title: '开户行名称' + title: '开户行名称', + visible: false }, { field: 'bankCardNo', - title: '开户行卡号' - }, - { - field: 'loginIp', - title: '最后登陆ip' - }, - { - field: 'loginDate', - title: '最后登陆时间' - }, - { - field: 'version', - title: '版本号' + title: '开户行卡号', + visible: false }, { field: 'remark', diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/domain/Address.java b/ruoyi-system/src/main/java/com/ruoyi/system/domain/Address.java new file mode 100755 index 000000000..2a03bba5a --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/domain/Address.java @@ -0,0 +1,79 @@ +package com.ruoyi.system.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 地区信息对象 address + * + * @author + * @date 2020-05-23 + */ +public class Address extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** $column.columnComment */ + private Long id; + + /** 地区编码 */ + @Excel(name = "地区编码") + private String areaCode; + + /** 地区名称 */ + @Excel(name = "地区名称") + private String areaName; + + /** 父节点CODE */ + @Excel(name = "父节点CODE") + private String parentCode; + + public void setId(Long id) + { + this.id = id; + } + + public Long getId() + { + return id; + } + public void setAreaCode(String areaCode) + { + this.areaCode = areaCode; + } + + public String getAreaCode() + { + return areaCode; + } + public void setAreaName(String areaName) + { + this.areaName = areaName; + } + + public String getAreaName() + { + return areaName; + } + public void setParentCode(String parentCode) + { + this.parentCode = parentCode; + } + + public String getParentCode() + { + return parentCode; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("areaCode", getAreaCode()) + .append("areaName", getAreaName()) + .append("parentCode", getParentCode()) + .toString(); + } +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/domain/BusinessFirm.java b/ruoyi-system/src/main/java/com/ruoyi/system/domain/BusinessFirm.java index 209bc9deb..a62d067c3 100755 --- a/ruoyi-system/src/main/java/com/ruoyi/system/domain/BusinessFirm.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/domain/BusinessFirm.java @@ -81,7 +81,7 @@ public class BusinessFirm extends BaseEntity /** 商家类型,0个人 1商家 */ @Excel(name = "商家类型,0个人 1商家") - private String bussinessType; + private String businessType; /** 省id */ @Excel(name = "省id") @@ -97,15 +97,15 @@ public class BusinessFirm extends BaseEntity /** 市名称 */ @Excel(name = "市名称") - private String ciityName; + private String cityName; /** 县ID */ @Excel(name = "县ID") - private String countyCode; + private String countryCode; /** 县名称 */ @Excel(name = "县名称") - private String countyName; + private String countryName; /** 乡/镇ID */ @Excel(name = "乡/镇ID") @@ -290,14 +290,14 @@ public class BusinessFirm extends BaseEntity { return refundGuaranteeMoney; } - public void setBussinessType(String bussinessType) + public void setBussinessType(String businessType) { - this.bussinessType = bussinessType; + this.businessType = businessType; } - public String getBussinessType() + public String getBusinessType() { - return bussinessType; + return businessType; } public void setProvinceCode(String provinceCode) { @@ -326,32 +326,32 @@ public class BusinessFirm extends BaseEntity { return cityCode; } - public void setCiityName(String ciityName) + public void setCityName(String cityName) { - this.ciityName = ciityName; + this.cityName = cityName; } - public String getCiityName() + public String getCityName() { - return ciityName; + return cityName; } - public void setCountyCode(String countyCode) + public void setCountryCode(String countryCode) { - this.countyCode = countyCode; + this.countryCode = countryCode; } - public String getCountyCode() + public String getCountryCode() { - return countyCode; + return countryCode; } - public void setCountyName(String countyName) + public void setCountryName(String countryName) { - this.countyName = countyName; + this.countryName = countryName; } - public String getCountyName() + public String getCountryName() { - return countyName; + return countryName; } public void setTownCode(String townCode) { @@ -463,13 +463,13 @@ public class BusinessFirm extends BaseEntity .append("status", getStatus()) .append("guaranteeMoney", getGuaranteeMoney()) .append("refundGuaranteeMoney", getRefundGuaranteeMoney()) - .append("bussinessType", getBussinessType()) + .append("businessType", getBusinessType()) .append("provinceCode", getProvinceCode()) .append("provinceName", getProvinceName()) .append("cityCode", getCityCode()) - .append("ciityName", getCiityName()) - .append("countyCode", getCountyCode()) - .append("countyName", getCountyName()) + .append("cityName", getCityName()) + .append("countryCode", getCountryCode()) + .append("countryName", getCountryName()) .append("townCode", getTownCode()) .append("townName", getTownName()) .append("adress", getAdress()) diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/mapper/AddressMapper.java b/ruoyi-system/src/main/java/com/ruoyi/system/mapper/AddressMapper.java new file mode 100755 index 000000000..746667eb0 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/mapper/AddressMapper.java @@ -0,0 +1,68 @@ +package com.ruoyi.system.mapper; + +import java.util.List; +import com.ruoyi.system.domain.Address; + +/** + * 地区信息Mapper接口 + * + * @author ruoyi + * @date 2020-05-23 + */ +public interface AddressMapper +{ + /** + * 查询地区信息 + * + * @param id 地区信息ID + * @return 地区信息 + */ + Address selectAddressById(Long id); + + /** + * 查询地区信息列表 + * + * @param address 地区信息 + * @return 地区信息集合 + */ + List
    selectAddressList(Address address); + + /** + * 新增地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + int insertAddress(Address address); + + /** + * 修改地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + int updateAddress(Address address); + + /** + * 删除地区信息 + * + * @param id 地区信息ID + * @return 结果 + */ + int deleteAddressById(Long id); + + /** + * 批量删除地区信息 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + int deleteAddressByIds(String[] ids); + + /** + * 查询地区信息列表 + * @param parentCode + * @return + */ + List
    selectAddressByParentCode(String parentCode); +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/IAddressService.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/IAddressService.java new file mode 100755 index 000000000..a90bb7106 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/IAddressService.java @@ -0,0 +1,68 @@ +package com.ruoyi.system.service; + +import java.util.List; +import com.ruoyi.system.domain.Address; + +/** + * 地区信息Service接口 + * + * @author ruoyi + * @date 2020-05-23 + */ +public interface IAddressService +{ + /** + * 查询地区信息 + * + * @param id 地区信息ID + * @return 地区信息 + */ + public Address selectAddressById(Long id); + + /** + * 查询地区信息 + * @param parentCode + * @return 地区信息 + */ + List
    selectAddressByParentCode(String parentCode); + + /** + * 查询地区信息列表 + * + * @param address 地区信息 + * @return 地区信息集合 + */ + public List
    selectAddressList(Address address); + + /** + * 新增地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + public int insertAddress(Address address); + + /** + * 修改地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + public int updateAddress(Address address); + + /** + * 批量删除地区信息 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + public int deleteAddressByIds(String ids); + + /** + * 删除地区信息信息 + * + * @param id 地区信息ID + * @return 结果 + */ + public int deleteAddressById(Long id); +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/AddressServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/AddressServiceImpl.java new file mode 100755 index 000000000..c40f26cdb --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/AddressServiceImpl.java @@ -0,0 +1,111 @@ +package com.ruoyi.system.service.impl; + +import java.util.List; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.stereotype.Service; +import com.ruoyi.system.mapper.AddressMapper; +import com.ruoyi.system.domain.Address; +import com.ruoyi.system.service.IAddressService; +import com.ruoyi.common.core.text.Convert; + +/** + * 地区信息Service业务层处理 + * + * @author ruoyi + * @date 2020-05-23 + */ +@Service("iAddressService") +public class AddressServiceImpl implements IAddressService +{ + @Autowired + private AddressMapper addressMapper; + + /** + * 查询地区信息 + * + * @param id 地区信息ID + * @return 地区信息 + */ + @Override + public Address selectAddressById(Long id) + { + return addressMapper.selectAddressById(id); + } + + + /** + * 查询地区信息 + * + * @param parentCode + * @return 地区信息 + */ + @Override + public List
    selectAddressByParentCode(String parentCode) + { + return addressMapper.selectAddressByParentCode(parentCode); + } + + /** + * 查询地区信息列表 + * + * @param address 地区信息 + * @return 地区信息 + */ + @Override + public List
    selectAddressList(Address address) + { + return addressMapper.selectAddressList(address); + } + + /** + * 新增地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + @Override + @Transactional(rollbackFor = Exception.class) + public int insertAddress(Address address) + { + return addressMapper.insertAddress(address); + } + + /** + * 修改地区信息 + * + * @param address 地区信息 + * @return 结果 + */ + @Override + @Transactional(rollbackFor = Exception.class) + public int updateAddress(Address address) + { + return addressMapper.updateAddress(address); + } + + /** + * 删除地区信息对象 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + @Override + @Transactional(rollbackFor = Exception.class) + public int deleteAddressByIds(String ids) + { + return addressMapper.deleteAddressByIds(Convert.toStrArray(ids)); + } + + /** + * 删除地区信息信息 + * + * @param id 地区信息ID + * @return 结果 + */ + @Override + public int deleteAddressById(Long id) + { + return addressMapper.deleteAddressById(id); + } +} diff --git a/ruoyi-system/src/main/resources/mapper/system/AddressMapper.xml b/ruoyi-system/src/main/resources/mapper/system/AddressMapper.xml new file mode 100755 index 000000000..1152edb11 --- /dev/null +++ b/ruoyi-system/src/main/resources/mapper/system/AddressMapper.xml @@ -0,0 +1,71 @@ + + + + + + + + + + + + + select id, area_code, area_name, parent_code from address + + + + + + + + insert into address + + area_code, + area_name, + parent_code, + + + #{areaCode}, + #{areaName}, + #{parentCode}, + + + + + update address + + area_code = #{areaCode}, + area_name = #{areaName}, + parent_code = #{parentCode}, + + where id = #{id} + + + + delete from address where id = #{id} + + + + delete from address where id in + + #{id} + + + + + \ No newline at end of file diff --git a/ruoyi-system/src/main/resources/mapper/system/BusinessFirmMapper.xml b/ruoyi-system/src/main/resources/mapper/system/BusinessFirmMapper.xml index f2c93cdf6..61b0f974d 100755 --- a/ruoyi-system/src/main/resources/mapper/system/BusinessFirmMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/BusinessFirmMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -21,13 +21,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + - - - + + + @@ -46,10 +46,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select id, business_code, login_name, user_name, email, telephone_no, phone_no, sex, avatar, id_card, credentials, password, salt, status, guarantee_money, refund_guarantee_money, bussiness_type, province_code, province_name, city_code, ciity_name, county_code, county_name, town_code, town_name, adress, coordinate_point, bank_name, bank_card_no, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, version, remark from business_firm + select id, business_code, login_name, user_name, email, telephone_no, phone_no, sex, avatar, id_card, credentials, password, salt, status, guarantee_money, refund_guarantee_money, business_type, province_code, province_name, city_code, city_name, country_code, country_name, town_code, town_name, adress, coordinate_point, bank_name, bank_card_no, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, version, remark from business_firm - and business_code = #{businessCode} @@ -67,13 +67,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and status = #{status} and guarantee_money = #{guaranteeMoney} and refund_guarantee_money = #{refundGuaranteeMoney} - and bussiness_type = #{bussinessType} + and business_type = #{businessType} and province_code = #{provinceCode} and province_name like concat('%', #{provinceName}, '%') and city_code = #{cityCode} - and ciity_name like concat('%', #{ciityName}, '%') - and county_code = #{countyCode} - and county_name like concat('%', #{countyName}, '%') + and city_name like concat('%', #{cityName}, '%') + and country_code = #{countryCode} + and country_name like concat('%', #{countryName}, '%') and town_code = #{townCode} and town_name like concat('%', #{townName}, '%') and adress = #{adress} @@ -91,7 +91,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where id = #{id} - + insert into business_firm business_code, @@ -109,13 +109,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" status, guarantee_money, refund_guarantee_money, - bussiness_type, + business_type, province_code, province_name, city_code, - ciity_name, - county_code, - county_name, + city_name, + country_code, + country_name, town_code, town_name, adress, @@ -148,13 +148,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" #{status}, #{guaranteeMoney}, #{refundGuaranteeMoney}, - #{bussinessType}, + #{businessType}, #{provinceCode}, #{provinceName}, #{cityCode}, - #{ciityName}, - #{countyCode}, - #{countyName}, + #{cityName}, + #{countryCode}, + #{countryName}, #{townCode}, #{townName}, #{adress}, @@ -173,7 +173,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update business_firm business_code = #{businessCode}, @@ -191,13 +191,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" status = #{status}, guarantee_money = #{guaranteeMoney}, refund_guarantee_money = #{refundGuaranteeMoney}, - bussiness_type = #{bussinessType}, + business_type = #{businessType}, province_code = #{provinceCode}, province_name = #{provinceName}, city_code = #{cityCode}, - ciity_name = #{ciityName}, - county_code = #{countyCode}, - county_name = #{countyName}, + city_name = #{cityName}, + country_code = #{countryCode}, + country_name = #{countryName}, town_code = #{townCode}, town_name = #{townName}, adress = #{adress}, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysConfigMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysConfigMapper.xml index 4756c1f18..46f6a73b9 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysConfigMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysConfigMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -33,12 +33,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - - @@ -64,7 +64,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where config_key = #{configKey} - + insert into sys_config ( config_name, config_key, @@ -84,7 +84,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ) - + update sys_config config_name = #{configName}, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml index bb018a730..63324582c 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -35,7 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" order by d.parent_id, d.order_num - where d.del_flag = '0' @@ -56,7 +56,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" select count(1) from sys_user where dept_id = #{deptId} and del_flag = '0' - select count(1) from sys_dept where del_flag = '0' and dept_id = #{deptId} @@ -83,7 +83,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" select count(*) from sys_dept where status = 0 and del_flag = '0' and find_in_set(#{deptId}, ancestors) - + insert into sys_dept( dept_id, parent_id, @@ -111,7 +111,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ) - + update sys_dept parent_id = #{parentId}, @@ -145,7 +145,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" update sys_dept set del_flag = '2' where dept_id = #{deptId} - + update sys_dept status = #{status}, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysDictDataMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysDictDataMapper.xml index aebd9b4f6..19cb2fc2a 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysDictDataMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysDictDataMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -25,7 +25,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from sys_dict_data - @@ -40,7 +40,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - where status = '0' and dict_type = #{dictType} order by dict_sort asc @@ -70,7 +70,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update sys_dict_data dict_sort = #{dictSort}, @@ -92,7 +92,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" update sys_dict_data set dict_type = #{newDictType} where dict_type = #{oldDictType} - + insert into sys_dict_data( dict_sort, dict_label, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysDictTypeMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysDictTypeMapper.xml index 1ddabe6ef..f03958c7a 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysDictTypeMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysDictTypeMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -20,7 +20,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from sys_dict_type - @@ -71,7 +71,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update sys_dict_type dict_name = #{dictName}, @@ -84,7 +84,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where dict_id = #{dictId} - + insert into sys_dict_type( dict_name, dict_type, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml index a2ac5b4e5..9e680408f 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -16,12 +16,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + insert into sys_logininfor (login_name, status, ipaddr, login_location, browser, os, msg, login_time) values (#{loginName}, #{status}, #{ipaddr}, #{loginLocation}, #{browser}, #{os}, #{msg}, sysdate()) - select info_id,login_name,ipaddr,login_location,browser,os,status,msg,login_time from sys_logininfor diff --git a/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml index 9a06fde16..610d88cbd 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml @@ -4,7 +4,7 @@ "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -77,7 +77,7 @@ order by m.parent_id, m.order_num - @@ -90,7 +90,7 @@ order by parent_id, order_num - select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.visible, ifnull(m.perms,'') as perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time from sys_menu m left join sys_role_menu rm on m.menu_id = rm.menu_id @@ -121,12 +121,12 @@ select count(1) from sys_menu where parent_id=#{menuId} - where menu_name=#{menuName} and parent_id = #{parentId} - + update sys_menu menu_name = #{menuName}, @@ -145,7 +145,7 @@ where menu_id = #{menuId} - + insert into sys_menu( menu_id, parent_id, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml index dfca13c04..8528b9a64 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -27,7 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where notice_id = #{noticeId} - @@ -42,7 +42,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + insert into sys_notice ( notice_title, notice_type, @@ -62,7 +62,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ) - + update sys_notice notice_title = #{noticeTitle}, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml index 9658e873a..37245654a 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -28,12 +28,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from sys_oper_log - + insert into sys_oper_log(title, business_type, method, request_method, operator_type, oper_name, dept_name, oper_url, oper_ip, oper_location, oper_param, json_result, status, error_msg, oper_time) values (#{title}, #{businessType}, #{method}, #{requestMethod}, #{operatorType}, #{operName}, #{deptName}, #{operUrl}, #{operIp}, #{operLocation}, #{operParam}, #{jsonResult}, #{status}, #{errorMsg}, sysdate()) - diff --git a/ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml index 8b0c0292c..32f0b1921 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -22,7 +22,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from sys_post - @@ -71,7 +71,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update sys_post post_code = #{postCode}, @@ -85,7 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where post_id = #{postId} - + insert into sys_post( post_id, post_code, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysRoleDeptMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysRoleDeptMapper.xml index 700671e15..c2815f24e 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysRoleDeptMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysRoleDeptMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + diff --git a/ruoyi-system/src/main/resources/mapper/system/SysRoleMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysRoleMapper.xml index 8d810c395..fdc7f47fa 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysRoleMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysRoleMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -33,7 +33,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from sys_role r - where r.del_flag = '0' @@ -89,7 +89,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update sys_role role_name = #{roleName}, @@ -104,7 +104,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where role_id = #{roleId} - + insert into sys_role( role_id, role_name, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysRoleMenuMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysRoleMenuMapper.xml index f509d207e..7c33d23c5 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysRoleMenuMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysRoleMenuMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + diff --git a/ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml index b02bd3fdb..4b3e6af57 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -29,7 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + @@ -38,7 +38,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + @@ -57,7 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" left join sys_role r on r.role_id = ur.role_id - select u.user_id, u.dept_id, u.login_name, u.user_name, u.user_type, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.salt, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, d.dept_name, d.leader from sys_user u left join sys_dept d on u.dept_id = d.dept_id where u.del_flag = '0' @@ -83,7 +83,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ${params.dataScope} - select distinct u.user_id, u.dept_id, u.login_name, u.user_name, u.user_type, u.email, u.avatar, u.phonenumber, u.status, u.create_time from sys_user u left join sys_dept d on u.dept_id = d.dept_id @@ -100,7 +100,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ${params.dataScope} - select distinct u.user_id, u.dept_id, u.login_name, u.user_name, u.user_type, u.email, u.avatar, u.phonenumber, u.status, u.create_time from sys_user u left join sys_dept d on u.dept_id = d.dept_id @@ -161,7 +161,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update sys_user dept_id = #{deptId}, @@ -184,7 +184,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where user_id = #{userId} - + insert into sys_user( user_id, dept_id, diff --git a/ruoyi-system/src/main/resources/mapper/system/SysUserOnlineMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysUserOnlineMapper.xml index 56adfd320..996496daf 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysUserOnlineMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysUserOnlineMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -28,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where sessionid = #{sessionid} - + replace into sys_user_online(sessionId, login_name, dept_name, ipaddr, login_location, browser, os, status, start_timestamp, last_access_time, expire_time) values (#{sessionId}, #{loginName}, #{deptName}, #{ipaddr}, #{loginLocation}, #{browser}, #{os}, #{status}, #{startTimestamp}, #{lastAccessTime}, #{expireTime}) @@ -37,7 +37,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" delete from sys_user_online where sessionId = #{sessionId} - diff --git a/ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml index 21c40981b..0ff0cb91f 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + diff --git a/ruoyi-system/src/main/resources/mapper/system/SysUserRoleMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysUserRoleMapper.xml index b091ba757..eb4217243 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysUserRoleMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysUserRoleMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -35,7 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + delete from sys_user_role where user_id=#{userId} and role_id=#{roleId}