增加品牌管理,品牌动态选择

This commit is contained in:
19173159168
2025-08-12 21:53:13 +08:00
parent 6fadd0aed9
commit 91aa3aaa79
5 changed files with 30 additions and 37 deletions

View File

@ -284,30 +284,30 @@ public class CommonController
try
{
/** oss --------------- */
// // 检查文件是否为空
// if (file.isEmpty()) {
// return AjaxResult.error("上传文件不能为空");
// }
//
// // 检查文件类型(可选)
// String contentType = file.getContentType();
// if (contentType == null || !contentType.startsWith("image/")) {
// return AjaxResult.error("只允许上传图片文件");
// }
//
// // 上传到 OSS
// String url = ossService.uploadImage(file);
// // 返回文件访问 URL
// String[] str = url.split("/");
// String fileName = str[str.length - 1];
// 检查文件是否为空
if (file.isEmpty()) {
return AjaxResult.error("上传文件不能为空");
}
// 检查文件类型(可选)
String contentType = file.getContentType();
if (contentType == null || !contentType.startsWith("image/")) {
return AjaxResult.error("只允许上传图片文件");
}
// 上传到 OSS
String url = ossService.uploadImage(file);
// 返回文件访问 URL
String[] str = url.split("/");
String fileName = str[str.length - 1];
/** 原文件上传 --------------- */
// 上传文件路径
String filePath = RuoYiConfig.getUploadPath();
// 上传并返回新文件名称
String fileName = FileUploadUtils.upload(filePath, fileType, file);
String url = serverConfig.getUrl() + fileName;
// // 上传文件路径
// String filePath = RuoYiConfig.getUploadPath();
// // 上传并返回新文件名称
// String fileName = FileUploadUtils.upload(filePath, fileType, file);
//
// String url = serverConfig.getUrl() + fileName;
/** -------------------------- */
String uuid = UUID.randomUUID().toString();
CommonAttachment insert = new CommonAttachment();

View File

@ -58,6 +58,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="extend2 != null and extend2 != ''"> and extend2 = #{extend2}</if>
<if test="extend3 != null and extend3 != ''"> and extend3 = #{extend3}</if>
</where>
order by update_time desc
</select>
<select id="selectZcCarBrandById" parameterType="Long" resultMap="ZcCarBrandZcCarModelResult">

View File

@ -53,6 +53,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="brandName != null and brandName != ''"> and brand_name like concat('%', #{brandName}, '%')</if>
<if test="status != null and status != ''"> and status = #{status}</if>
</where>
order by update_time desc
</select>
<select id="selectZcCarModelById" parameterType="Long" resultMap="ZcCarModelResult">

View File

@ -234,19 +234,11 @@
align: 'center',
title: '实际支付时间'
},
{
field: 'remark',
align: 'center',
title: '备注'
},
{
field: 'createTime',
align: 'center',
title: '创建时间'
},
{
field: 'updateTime',
align: 'center',