会员优化
This commit is contained in:
parent
cbdac15354
commit
9ffb34d10b
|
|
@ -1,5 +1,6 @@
|
||||||
package com.ruoyi.train.course.controller;
|
package com.ruoyi.train.course.controller;
|
||||||
|
|
||||||
|
import cn.hutool.json.JSONObject;
|
||||||
import com.ruoyi.common.base.AjaxResult;
|
import com.ruoyi.common.base.AjaxResult;
|
||||||
import com.ruoyi.framework.web.base.BaseController;
|
import com.ruoyi.framework.web.base.BaseController;
|
||||||
import com.ruoyi.train.course.domain.TrainCourse;
|
import com.ruoyi.train.course.domain.TrainCourse;
|
||||||
|
|
@ -8,7 +9,6 @@ import com.ruoyi.train.course.domain.TrainCourseSection;
|
||||||
import com.ruoyi.train.course.service.ITrainCourseCategoryService;
|
import com.ruoyi.train.course.service.ITrainCourseCategoryService;
|
||||||
import com.ruoyi.train.course.service.ITrainCourseSectionService;
|
import com.ruoyi.train.course.service.ITrainCourseSectionService;
|
||||||
import com.ruoyi.train.course.service.ITrainCourseService;
|
import com.ruoyi.train.course.service.ITrainCourseService;
|
||||||
import net.sf.json.JSONObject;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
|
@ -49,12 +49,8 @@ public class ApiTrainCourseController extends BaseController {
|
||||||
@GetMapping("/trainCourse/{id}")
|
@GetMapping("/trainCourse/{id}")
|
||||||
public AjaxResult get(@PathVariable("id") Integer id) {
|
public AjaxResult get(@PathVariable("id") Integer id) {
|
||||||
TrainCourse trainCourse = trainCourseService.selectById( id );
|
TrainCourse trainCourse = trainCourseService.selectById( id );
|
||||||
// TrainCourseCategory courseCategory = trainCourseCategoryService.selectById( trainCourse.getTrainCourseCategoryId() );
|
|
||||||
JSONObject jsonObject = JSONObject.fromObject( trainCourse );
|
|
||||||
// JSONObject courseCategoryJSON = JSONObject.fromObject( courseCategory );
|
|
||||||
// jsonObject.put( "courseCategory", courseCategory );
|
|
||||||
AjaxResult success = success( "查询成功" );
|
AjaxResult success = success( "查询成功" );
|
||||||
success.put( "data", jsonObject );
|
success.put( "data", trainCourse );
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -16,8 +16,6 @@ import com.ruoyi.framework.web.util.ServletUtils;
|
||||||
import com.ruoyi.framework.web.util.ShiroUtils;
|
import com.ruoyi.framework.web.util.ShiroUtils;
|
||||||
import com.ruoyi.system.domain.SysUser;
|
import com.ruoyi.system.domain.SysUser;
|
||||||
import com.ruoyi.system.service.ISysUserService;
|
import com.ruoyi.system.service.ISysUserService;
|
||||||
import com.ruoyi.vip.domain.VipUser;
|
|
||||||
import com.ruoyi.vip.service.IVipUserService;
|
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.shiro.SecurityUtils;
|
import org.apache.shiro.SecurityUtils;
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@
|
||||||
minlength: 2,
|
minlength: 2,
|
||||||
maxlength: 20,
|
maxlength: 20,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkLoginNameUnique",
|
url: ctx + "vip/user/checkLoginNameUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -103,7 +103,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
email:true,
|
email:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkEmailUnique",
|
url: ctx + "vip/user/checkEmailUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -120,7 +120,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
isPhone:true,
|
isPhone:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkPhoneUnique",
|
url: ctx + "vip/user/checkPhoneUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -168,7 +168,7 @@
|
||||||
$.ajax({
|
$.ajax({
|
||||||
cache : true,
|
cache : true,
|
||||||
type : "POST",
|
type : "POST",
|
||||||
url : ctx + "system/user/add",
|
url : ctx + "vip/user/add",
|
||||||
data : {
|
data : {
|
||||||
"userId": userId,
|
"userId": userId,
|
||||||
"deptId": deptId,
|
"deptId": deptId,
|
||||||
|
|
|
||||||
|
|
@ -74,7 +74,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
email:true,
|
email:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkEmailUnique",
|
url: ctx + "vip/user/checkEmailUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -94,7 +94,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
isPhone:true,
|
isPhone:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkPhoneUnique",
|
url: ctx + "vip/user/checkPhoneUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -143,7 +143,7 @@
|
||||||
$.ajax({
|
$.ajax({
|
||||||
cache : true,
|
cache : true,
|
||||||
type : "POST",
|
type : "POST",
|
||||||
url : ctx + "system/user/edit",
|
url : ctx + "vip/user/edit",
|
||||||
data : {
|
data : {
|
||||||
"userId": userId,
|
"userId": userId,
|
||||||
"deptId": deptId,
|
"deptId": deptId,
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@
|
||||||
|
|
||||||
function submitHandler() {
|
function submitHandler() {
|
||||||
if ($.validate.form()) {
|
if ($.validate.form()) {
|
||||||
$.operate.save(ctx + "system/user/resetPwd", $('#form-user-resetPwd').serialize());
|
$.operate.save(ctx + "vip/user/resetPwd", $('#form-user-resetPwd').serialize());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,7 @@
|
||||||
var removeFlag = [[${@permission.hasPermi('system:user:remove')}]];
|
var removeFlag = [[${@permission.hasPermi('system:user:remove')}]];
|
||||||
var resetPwdFlag = [[${@permission.hasPermi('system:user:resetPwd')}]];
|
var resetPwdFlag = [[${@permission.hasPermi('system:user:resetPwd')}]];
|
||||||
var datas = [[${@dict.getType('sys_normal_disable')}]];
|
var datas = [[${@dict.getType('sys_normal_disable')}]];
|
||||||
var prefix = ctx + "system/user";
|
var prefix = ctx + "vip/user";
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
$('body').layout({ west__size: 185 });
|
$('body').layout({ west__size: 185 });
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue