运营商管理

This commit is contained in:
majian314
2025-07-01 19:14:02 +08:00
parent 854477eafe
commit 87e606c685
10 changed files with 248 additions and 554 deletions

View File

@ -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));
}
}

View File

@ -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())

View File

@ -58,4 +58,6 @@ public interface ICompanyService
* @return 结果
*/
public int deleteCompanyById(Long id);
public int changeStatus(Company company);
}

View File

@ -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);
}
}