未命名课程暂不允许进行课程管理

This commit is contained in:
yuanke 2016-07-08 16:40:24 +08:00
parent d38ce793bd
commit 3a2e2c1174
2 changed files with 3 additions and 1 deletions

View File

@ -8,6 +8,8 @@ class SyllabusesService
def judge_can_setting(sy,user)
sy[:can_setting] = sy[:user_id] == user.id ? true : false
sy[:can_setting] = false if sy[:id].nil?
sy.courses.each do |c|
c[:can_setting] = false

View File

@ -36,7 +36,7 @@ app.controller('ClassListController', ['$scope', 'config', 'auth', '$http', '$lo
function (response) {
console.log(response.data);
if (response.data.auth == 0) {
vm.alertService.showMessage('提示', '对不起您不是老师不能新建课程');
vm.alertService.showMessage('提示', '非教师身份不能创建课程哦~');
}
else{
$location.path("/new_class");