diff --git a/ruoyi-admin/src/main/java/com/ruoyi/operation/controller/CompanyController.java b/ruoyi-admin/src/main/java/com/ruoyi/operation/controller/CompanyController.java index a1be28a..8ed507c 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/operation/controller/CompanyController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/operation/controller/CompanyController.java @@ -1,6 +1,8 @@ package com.ruoyi.operation.controller; import java.util.List; + +import com.ruoyi.common.core.domain.entity.SysUser; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -86,6 +88,7 @@ public class CompanyController extends BaseController @ResponseBody public AjaxResult addSave(Company company) { + company.setCreateBy(getLoginName()); return toAjax(companyService.insertCompany(company)); } @@ -110,6 +113,7 @@ public class CompanyController extends BaseController @ResponseBody public AjaxResult editSave(Company company) { + company.setUpdateBy(getLoginName()); return toAjax(companyService.updateCompany(company)); } @@ -124,4 +128,14 @@ public class CompanyController extends BaseController { return toAjax(companyService.deleteCompanyByIds(ids)); } + + + @Log(title = "运营商管理", businessType = BusinessType.UPDATE) + @RequiresPermissions("operation:company:edit") + @PostMapping("/changeStatus") + @ResponseBody + public AjaxResult changeStatus(Company company) + { + return toAjax(companyService.changeStatus(company)); + } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/operation/domain/Company.java b/ruoyi-admin/src/main/java/com/ruoyi/operation/domain/Company.java index db1dc1b..b2a579f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/operation/domain/Company.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/operation/domain/Company.java @@ -96,9 +96,11 @@ public class Company extends BaseEntity private Long channelId; /** 运营商管理城市 */ - @Excel(name = "运营商管理城市") private String citys; - + /** 运营商管理城市 */ + @Excel(name = "运营商管理城市") + private String cityName; + /** 支付宝支付模式 */ @Excel(name = "支付宝支付模式") private Long aliPayModel; @@ -366,6 +368,15 @@ public class Company extends BaseEntity { return citys; } + + public String getCityName() { + return cityName; + } + + public void setCityName(String cityName) { + this.cityName = cityName; + } + public void setAliPayModel(Long aliPayModel) { this.aliPayModel = aliPayModel; @@ -580,6 +591,7 @@ public class Company extends BaseEntity .append("allowChange", getAllowChange()) .append("channelId", getChannelId()) .append("citys", getCitys()) + .append("cityName", getCityName()) .append("aliPayModel", getAliPayModel()) .append("aliReceivingAccount", getAliReceivingAccount()) .append("aliKey", getAliKey()) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/operation/service/ICompanyService.java b/ruoyi-admin/src/main/java/com/ruoyi/operation/service/ICompanyService.java index eba37fe..06def9c 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/operation/service/ICompanyService.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/operation/service/ICompanyService.java @@ -58,4 +58,6 @@ public interface ICompanyService * @return 结果 */ public int deleteCompanyById(Long id); + + public int changeStatus(Company company); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/operation/service/impl/CompanyServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/operation/service/impl/CompanyServiceImpl.java index 4911825..309ffe0 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/operation/service/impl/CompanyServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/operation/service/impl/CompanyServiceImpl.java @@ -55,6 +55,7 @@ public class CompanyServiceImpl implements ICompanyService public int insertCompany(Company company) { company.setCreateTime(DateUtils.getNowDate()); + company.setUpdateTime(DateUtils.getNowDate()); return companyMapper.insertCompany(company); } @@ -94,4 +95,11 @@ public class CompanyServiceImpl implements ICompanyService { return companyMapper.deleteCompanyById(id); } + + @Override + public int changeStatus(Company company) + { + company.setUpdateTime(DateUtils.getNowDate()); + return companyMapper.updateCompany(company); + } } diff --git a/ruoyi-admin/src/main/resources/mapper/operation/CompanyMapper.xml b/ruoyi-admin/src/main/resources/mapper/operation/CompanyMapper.xml index 69c6977..738dec0 100644 --- a/ruoyi-admin/src/main/resources/mapper/operation/CompanyMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/operation/CompanyMapper.xml @@ -26,6 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + @@ -54,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select id, company_name, contact_name, phone, address, balance, deposit, type, is_delete, allow_split_bill, max_percentage, is_add_rules, sharing_ratio, wechat_pay_model, wechat_receiving_account, wechat_key, charge_mode, charge_param, allow_change, channel_id, citys, ali_pay_model, ali_receiving_account, ali_key, service_order_type, split_order_type, wechat_balance, alipay_balance, invite_reward_mode, invite_reward_param, reward_type, reward_param, is_reservation, reservation_duration, reservation_number, status, del_flag, create_by, create_time, update_by, update_time, extend1, extend2, extend3, extend4, extend5 from company + select id, company_name, contact_name, phone, address, balance, deposit, type, is_delete, allow_split_bill, max_percentage, is_add_rules, sharing_ratio, wechat_pay_model, wechat_receiving_account, wechat_key, charge_mode, charge_param, allow_change, channel_id, citys, city_name, ali_pay_model, ali_receiving_account, ali_key, service_order_type, split_order_type, wechat_balance, alipay_balance, invite_reward_mode, invite_reward_param, reward_type, reward_param, is_reservation, reservation_duration, reservation_number, status, del_flag, create_by, create_time, update_by, update_time, extend1, extend2, extend3, extend4, extend5 from company +
- +
- +
- +
- +
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
+
- +
-
+ +
-
- +
+
- +
+ + + +
+
+ +
+ +
+
+ +
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- +
+ +
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- +
+ +
+ + + - \ No newline at end of file + diff --git a/ruoyi-admin/src/main/resources/templates/operation/company/company.html b/ruoyi-admin/src/main/resources/templates/operation/company/company.html index 9a2572f..4971235 100644 --- a/ruoyi-admin/src/main/resources/templates/operation/company/company.html +++ b/ruoyi-admin/src/main/resources/templates/operation/company/company.html @@ -11,7 +11,7 @@
  • - +
  • @@ -23,112 +23,11 @@
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - + +
  •  搜索 @@ -149,9 +48,9 @@ 删除 - - 导出 - + + +
@@ -162,6 +61,8 @@ - \ No newline at end of file + diff --git a/ruoyi-admin/src/main/resources/templates/operation/company/edit.html b/ruoyi-admin/src/main/resources/templates/operation/company/edit.html index 2cec109..de5de9f 100644 --- a/ruoyi-admin/src/main/resources/templates/operation/company/edit.html +++ b/ruoyi-admin/src/main/resources/templates/operation/company/edit.html @@ -2,69 +2,39 @@ + + +
- +
- +
- +
- +
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- +
+
- +
@@ -73,126 +43,63 @@
-
- +
+
- +
+ + + +
+
+
+
+ +
+
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- +
- +
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- +
+
+ + + - \ No newline at end of file + diff --git a/ruoyi-admin/src/main/resources/templates/system/user/user.html b/ruoyi-admin/src/main/resources/templates/system/user/user.html index 1b0e3e1..3b09cc2 100644 --- a/ruoyi-admin/src/main/resources/templates/system/user/user.html +++ b/ruoyi-admin/src/main/resources/templates/system/user/user.html @@ -200,23 +200,11 @@ // }, { field: 'cityName', - title: '市' + title: '省' }, { field: 'districtName', - title: '县' - }, - { - field: 'townName', - title: '乡/镇' - }, - { - field: 'villageName', - title: '村' - }, - { - field: 'groupName', - title: '办案室' + title: '市' }, // { // field: 'createTime',