Merge branch 'master' of git@github.com:easysoft/zentaopms

This commit is contained in:
azhi
2013-07-30 16:22:09 +08:00
3 changed files with 14 additions and 2 deletions
+6 -2
View File
@@ -89,8 +89,12 @@ class dept extends control
{
if($confirm == 'no')
{
echo js::confirm($this->lang->dept->confirmDelete, $this->createLink('dept', 'delete', "deptID=$deptID&confirm=yes"));
exit;
$sons = $this->dept->getSons($deptID);
$users = $this->dept->getUsers($deptID);
if($sons) die(js::alert($this->lang->dept->error->hasSons));
if($users) die(js::alert($this->lang->dept->error->hasUsers));
die(js::confirm($this->lang->dept->confirmDelete, $this->createLink('dept', 'delete', "deptID=$deptID&confirm=yes")));
}
else
{
+4
View File
@@ -21,3 +21,7 @@ $lang->dept->users = "Users";
$lang->dept->saveButton = " Save (S) ";
$lang->dept->confirmDelete = "Are you sure to delete this department?";
$lang->dept->error = new stdclass();
$lang->dept->error->hasSons = "Can't delete this dept, because that has child.";
$lang->dept->error->hasUsers = "Can't delete this dept, because that has users.";
+4
View File
@@ -21,3 +21,7 @@ $lang->dept->users = "成员列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您确定删除该部门吗?";
$lang->dept->error = new stdclass();
$lang->dept->error->hasSons = '该部门有子部门,不能删除!';
$lang->dept->error->hasUsers = '该部门有职员,不能删除!';