Commit 83ea7190 by 伍思炜

毕业生宽带下单二维码

parent 0a2fb603
......@@ -82,12 +82,25 @@ public class StartSelectController {
UserSchool userSchool = userSchoolMapper.selectById(id);
if(userSchool != null){
School school = schoolMapper.selectById(userSchool.getSchoolId());
System.out.println(school);
return ResponseData.success(school);
}
return ResponseData.error("没有查询相关的合伙人id的信息!!!");
}
/**
* 查询学校信息中的老用户升级套餐二维码
*/
@RequestMapping(value = "findSchoolPackageQrcode", method = RequestMethod.POST)
public ResponseData<String> selectSchoolPackageQrcode(@RequestParam("id") String id) {
UserSchool userSchool = userSchoolMapper.selectById(id);
if(userSchool != null){
School school = schoolMapper.selectById(userSchool.getSchoolId());
return ResponseData.success(school.getPackageQrcode());
}
return ResponseData.error("没有查询相关的合伙人id的信息!!!");
}
@ResponseBody
@RequestMapping(value = "sendBysCodes", method = RequestMethod.POST)
public ResponseData<Map<String, Object>> checkStudent(String phone) {
......
......@@ -143,6 +143,7 @@ public class SchoolManagementController extends BaseController {
/**
* 修改学校信息
*
* @param school
* @param chosePages
* @return
......@@ -293,6 +294,7 @@ public class SchoolManagementController extends BaseController {
}
}
}
@Permission(menuname = "上传二维码", value = "qrcodeUpload2", method = RequestMethod.POST)
public ResponseData<String> xiaotuUpload2(@RequestParam(value = "file") MultipartFile file, @RequestParam(value = "id", required = false) String id) {
String backgroundpath = FilePath.BACKGROUNDIMG.getValue() + "/" + DEFAULTPATH;
......@@ -307,7 +309,7 @@ public class SchoolManagementController extends BaseController {
return ResponseData.error("图片过大,无法上传");
}
School school1 = schoolMapper.selectById(id);
File savePath = new File(backgroundpath, school1.getId() + FILENAME);
File savePath = new File(backgroundpath, school1.getId()+ "-2" + FILENAME);
OutputStream os = null;
try {
os = new FileOutputStream(savePath);
......@@ -318,7 +320,7 @@ public class SchoolManagementController extends BaseController {
wrapper.eq("id", id);
School school = schoolMapper.selectById(id);
Map<String, Object> map = new HashMap<>();
map.put("package_qrcode", backgroundpath + school.getId() + FILENAME);
map.put("package_qrcode", backgroundpath + school.getId()+ "-2" + FILENAME);
Integer integer = schoolMapper.updateForSet(MyBatisPlusUpdateUtils.toUpdateSet(map), wrapper);
if (integer != 1) {
return ResponseData.error("上传失败!");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment