From ac6ddfbc202a4012c44741b870863c3a6f038e0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=83=A1?= <3203164629@qq.com> Date: Wed, 10 Jan 2024 18:57:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E8=87=B3v1.87=EF=BC=8C?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=86=85=E5=AE=B9=E5=9C=A8=E7=AC=94=E8=AE=B0?= =?UTF-8?q?=E4=B8=AD=E6=9F=A5=E7=9C=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- admin/appmanagement/template/main.htm | 3 + admin/appmarket/index.php | 10 +- admin/orguser/ajax.php | 519 +++++++++++++++++ admin/orguser/edituser.php | 440 ++++++++++++++ admin/orguser/export.php | 183 ++++++ admin/orguser/export_tmpl.php | 96 ++++ admin/orguser/images/add_guide.png | Bin 0 -> 17935 bytes admin/orguser/images/ctrl.png | Bin 0 -> 537 bytes admin/orguser/images/icons.png | Bin 0 -> 3904 bytes admin/orguser/images/icons_24.png | Bin 0 -> 7124 bytes admin/orguser/images/orguser.css | 276 +++++++++ admin/orguser/images/user_bg.png | Bin 0 -> 8276 bytes admin/orguser/import.php | 462 +++++++++++++++ admin/orguser/index.php | 30 + admin/orguser/language/en-US/lang.php | 164 ++++++ admin/orguser/language/zh-cn/lang.php | 164 ++++++ admin/orguser/scripts/orguser.js | 539 ++++++++++++++++++ admin/orguser/template.xlsx | Bin 0 -> 9918 bytes admin/orguser/template/adduser.htm | 285 +++++++++ admin/orguser/template/detail_org.htm | 281 +++++++++ admin/orguser/template/edituser.htm | 301 ++++++++++ admin/orguser/template/export.htm | 71 +++ admin/orguser/template/guide.htm | 20 + admin/orguser/template/header_left.htm | 13 + admin/orguser/template/header_search.htm | 25 + admin/orguser/template/import_guide.htm | 71 +++ admin/orguser/template/import_list.htm | 209 +++++++ admin/orguser/template/main.htm | 87 +++ admin/orguser/template/profile.htm | 55 ++ admin/orguser/template/tree.htm | 420 ++++++++++++++ admin/orguser/view.php | 60 ++ admin/setting/template/main.htm | 6 + admin/setting/template/perm_group.htm | 5 +- admin/system/xtxx.php | 2 +- core/api/OneDrive/Client.php | 2 +- core/class/class_FileDownload.php | 21 +- core/class/class_core.php | 10 +- core/class/class_template.php | 16 +- core/class/dzz/Hook.php | 2 + core/class/dzz/apprun.php | 2 +- core/class/dzz/config.php | 2 +- core/class/dzz/dzz_app.php | 44 +- core/class/dzz/dzz_io.php | 13 +- core/class/dzz/modrun.php | 1 + core/class/dzz/route.php | 7 +- core/class/helper/helper_browser.php | 30 +- core/class/io/io_dzz.php | 13 +- core/class/table/table_resources_statis.php | 2 +- core/core_version.php | 6 +- core/function/function_core.php | 54 +- core/language/en-US/lang.php | 1 + core/language/zh-cn/lang.php | 1 + core/template/default/common/adminlogin.htm | 3 - core/template/default/common/footer.htm | 2 +- .../template/default/common/footer_simple.htm | 2 +- .../template/default/common/footer_system.htm | 122 ++++ core/template/default/common/wx_appinfo.htm | 1 - dzz/comment/ajax.php | 96 +--- dzz/comment/images/comment.css | 5 +- dzz/comment/images/ico_upload.gif | Bin 0 -> 115 bytes dzz/comment/images/img.png | Bin 0 -> 155 bytes dzz/comment/images/max.ico | Bin 0 -> 2462 bytes dzz/comment/images/min.ico | Bin 0 -> 2462 bytes dzz/comment/images/qunatip.gif | Bin 0 -> 1638 bytes dzz/comment/images/zoom.ico | Bin 0 -> 2462 bytes dzz/comment/index.php | 122 ++-- dzz/comment/template/list.htm | 8 +- dzz/filemanage/index.php | 6 +- dzz/filemanage/template/list.htm | 18 +- dzz/images/folder/folder.css | 27 +- dzz/index/index.php | 1 - dzz/language/en-US/lang.php | 1 - dzz/language/zh-cn/lang.php | 1 - dzz/orguser/edituser.php | 2 +- dzz/orguser/import.php | 4 +- dzz/share/ajax.php | 4 +- dzz/share/language/en-US/lang.php | 1 - dzz/share/language/zh-cn/lang.php | 1 - dzz/share/template/share.htm | 4 +- dzz/shares/template/list.htm | 17 +- dzz/shares/template/list_item.htm | 6 +- dzz/system/fileselection/listtree.php | 4 +- dzz/system/scripts/uplodfile.js | 4 +- dzz/system/selectfile.php | 4 +- dzz/system/template/filelist.htm | 9 +- dzz/system/template/fileselection/ajax.htm | 11 + dzz/system/template/fileselection/index.htm | 2 +- .../template/fileselection/listcontent.htm | 6 + dzz/system/template/notification_list.htm | 4 - dzz/system/template/orgtree.htm | 2 +- .../bootstrap/dist/css/bootstrap.min.css | 2 +- .../bootstrap/dist/js/bootstrap.min.js | 4 +- install/include/install_function.php | 2 +- install/include/install_var.php | 2 +- static/bootstrap/css/bootstrap.min.css | 154 +++++ static/css/app_manage.css | 4 +- static/css/style.min.css | 6 +- .../jquery_file_upload/jquery.fileupload.js | 1 - static/js/common.js | 33 +- static/js/perfect-scrollbar.min.js | 23 +- .../bootstrap-lyear-select.js | 2 +- user/classes/route.php | 2 +- user/function/function_user.php | 5 +- user/language/zh-cn/lang.php | 4 +- user/login/images/login.jpg | Bin 0 -> 103007 bytes user/login/images/login_single.css | 120 ++++ user/login/images/login_single1.css | 160 ++++++ user/login/images/login_single2.css | 163 ++++++ user/login/images/login_single3.css | 147 +++++ user/login/images/login_single4.css | 217 +++++++ user/login/logging/login.php | 35 ++ user/login/template/login_single3.htm | 2 +- user/login/template/login_single4.htm | 117 ++++ user/profile/index.php | 3 +- user/profile/password.php | 2 +- user/profile/template/profile.htm | 8 +- user/register/register.php | 4 +- user/space/about.php | 5 +- user/space/index.php | 11 +- user/space/lang.php | 24 + user/space/template/navmenu.htm | 15 +- user/space/template/space.htm | 9 +- user/space/yuyan.php | 39 -- 123 files changed, 6426 insertions(+), 423 deletions(-) create mode 100644 admin/orguser/ajax.php create mode 100644 admin/orguser/edituser.php create mode 100644 admin/orguser/export.php create mode 100644 admin/orguser/export_tmpl.php create mode 100644 admin/orguser/images/add_guide.png create mode 100644 admin/orguser/images/ctrl.png create mode 100644 admin/orguser/images/icons.png create mode 100644 admin/orguser/images/icons_24.png create mode 100644 admin/orguser/images/orguser.css create mode 100644 admin/orguser/images/user_bg.png create mode 100644 admin/orguser/import.php create mode 100644 admin/orguser/index.php create mode 100644 admin/orguser/language/en-US/lang.php create mode 100644 admin/orguser/language/zh-cn/lang.php create mode 100644 admin/orguser/scripts/orguser.js create mode 100644 admin/orguser/template.xlsx create mode 100644 admin/orguser/template/adduser.htm create mode 100644 admin/orguser/template/detail_org.htm create mode 100644 admin/orguser/template/edituser.htm create mode 100644 admin/orguser/template/export.htm create mode 100644 admin/orguser/template/guide.htm create mode 100644 admin/orguser/template/header_left.htm create mode 100644 admin/orguser/template/header_search.htm create mode 100644 admin/orguser/template/import_guide.htm create mode 100644 admin/orguser/template/import_list.htm create mode 100644 admin/orguser/template/main.htm create mode 100644 admin/orguser/template/profile.htm create mode 100644 admin/orguser/template/tree.htm create mode 100644 admin/orguser/view.php create mode 100644 core/template/default/common/footer_system.htm create mode 100644 dzz/comment/images/ico_upload.gif create mode 100644 dzz/comment/images/img.png create mode 100644 dzz/comment/images/max.ico create mode 100644 dzz/comment/images/min.ico create mode 100644 dzz/comment/images/qunatip.gif create mode 100644 dzz/comment/images/zoom.ico create mode 100644 user/login/images/login.jpg create mode 100644 user/login/images/login_single.css create mode 100644 user/login/images/login_single1.css create mode 100644 user/login/images/login_single2.css create mode 100644 user/login/images/login_single3.css create mode 100644 user/login/images/login_single4.css create mode 100644 user/login/template/login_single4.htm create mode 100644 user/space/lang.php delete mode 100644 user/space/yuyan.php diff --git a/admin/appmanagement/template/main.htm b/admin/appmanagement/template/main.htm index 6110b3b..d7bce3c 100644 --- a/admin/appmanagement/template/main.htm +++ b/admin/appmanagement/template/main.htm @@ -6,6 +6,9 @@ border: none; background: none; } +.row{ + padding: 1rem; +} diff --git a/admin/appmarket/index.php b/admin/appmarket/index.php index c9e016c..2fb818c 100644 --- a/admin/appmarket/index.php +++ b/admin/appmarket/index.php @@ -41,8 +41,11 @@ $order = ' ORDER BY disp'; $start = ($page - 1) * $perpage; $apps = array(); $string = " 1 "; +$param=array('app_market'); if ($keyword) { - $string .= " and appname like '%$keyword%' or vendor like '%$keyword%'"; + $string .= " and appname like %s or vendor like %s"; + $param[]='%'.$keyword.'%'; + $param[]='%'.$keyword.'%'; } if ($tagid) { $appids = C::t('app_relative') -> fetch_appids_by_tagid($tagid); @@ -52,11 +55,10 @@ if ($group) { $sql = " and `group` = '{$group}'"; $string .= " and `group` = '{$group}'"; } -if ($count = DB::result_first("SELECT COUNT(*) FROM " . DB::table('app_market') . " WHERE ".$string)) { - $apps = DB::fetch_all("SELECT * FROM " . DB::table('app_market') . " WHERE ".$string." $order limit $start,$perpage"); +if ($count = DB::result_first("SELECT COUNT(*) FROM %t WHERE ".$string,$param)) { + $apps = DB::fetch_all("SELECT * FROM %t WHERE ".$string." $order limit $start,$perpage",$param); $multi = multi($count, $perpage, $page, $theurl, 'pull-right'); } - $list = array(); $grouptitle = array('0' => lang('all'), '-1' => lang('visitors_visible'), '1' => lang('members_available'), '2' => lang('section_administrators_available'), '3' => lang('system_administrators_available')); foreach ($apps as $value) { diff --git a/admin/orguser/ajax.php b/admin/orguser/ajax.php new file mode 100644 index 0000000..9a39bba --- /dev/null +++ b/admin/orguser/ajax.php @@ -0,0 +1,519 @@ +'.strtoupper(new_strsubstr($v['text'],1,'')).''.$v['text']; + + }else{ + $v['icon'] = false; + $v['text']= avatar_block($uid,array(),'iconFirstWord').$v['text']; + } + $data[] = $v; + } +} +$do = trim($_GET['do']); +$orgid = intval($_GET['orgid']); +if ($do == 'upload') {//上传图片文件 + include libfile('class/uploadhandler'); + $options = array('accept_file_types' => '/\.(gif|jpe?g|png)$/i', + 'upload_dir' => $_G['setting']['attachdir'] . 'cache/', + 'upload_url' => $_G['setting']['attachurl'] . 'cache/', + 'thumbnail' => array('max-width' => 40, 'max-height' => 40)); + $upload_handler = new uploadhandler($options); + exit(); +} /*elseif ($do == 'getdefaultpic') {//获取群组默认图片,上传图片保存 + $imgs = C::t('resources_grouppic')->fetch_user_pic(); + if (isset($_GET['aid'])) { + $aid = intval($_GET['aid']); + if ($_G['adminid'] == 1) $dafault = 1; + else $default = 0; + if (C::t('resources_grouppic')->insert_data($aid, $default)) { + showTips(array('success' => true), 'json'); + } else { + showTips(array('error' => true), 'json'); + } + } +}*/elseif($do == 'getchildren') { + + $id = intval($_GET['id']); + $list = array(); + $limit = 0; + $html = ''; + + //判断用户有没有操作权限 + $ismoderator = C::t('organization_admin') -> ismoderator_by_uid_orgid($id, $_G['uid']); + if ($ismoderator) { + $disable = ''; + $type = 'user'; + } else { + $disable = '"disabled":true,'; + $type = "disabled"; + } + if ($id) { + $icon = 'dzz/system/images/department.png'; + } else { + $icon = 'dzz/system/images/organization.png'; + } + $data = array(); + if ($_GET['id'] == '#') { + if($_G['adminid']!=1) $topids=C::t('organization_admin')->fetch_toporgids_by_uid($_G['uid']); + foreach (C::t('organization')->fetch_all_by_forgid($id,0,0) as $value) { + if($value['type']==1) continue;//过滤群 + if($_G['adminid']!=1 && !in_array($value['orgid'],$topids)) continue; + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($value['orgid'], $_G['uid'])) { + $orgdisable = false; + $orgtype = 'organization'; + } else { + $orgdisable = true; + $orgtype = 'disabled'; + } + $arr=array('id' => $value['orgid'], 'text' => $value['orgname'], 'icon' => $icon, 'state' => array('disabled' => $orgdisable), "type" => $orgtype, 'children' => true); + if(intval($value['aid'])==0){ + $arr['text'] = avatar_group($value['orgid'],array($value['orgid']=>array('aid'=>$value['aid'],'orgname'=>$value['orgname']))).$value['orgname']; + $arr['icon'] = false; + }else{ + $arr['text'] = $value['orgname']; + $arr['icon']='index.php?mod=io&op=thumbnail&width=24&height=24&path=' . dzzencode('attach::' . $value['aid']); + } + $data[]=$arr; + + } + + $data[] = array('id' => 'other', 'text' => lang('no_institution_users'), 'state' => array('disabled' => $disable), "type" => 'group', 'children' => true); + } else { + //获取用户列表 + + if (!$id) { + + if ($ismoderator) { + $uids = array(); + $datas = array(); + foreach (C::t('organization_user')->fetch_user_not_in_orgid($limit) as $value) { + if(!$value['uid']) continue; + $uids[] = $value['uid']; + $datas[] = array('id' => 'uid_' . $value['uid'], 'text' => $value['username'] . '' . $value['email'] . '', 'icon' => 'dzz/system/images/user.png', 'state' => array('disabled' => $disable), "type" => $type, 'li_attr' => array('uid' => $value['uid'])); + } + getuserIcon($uids,$datas,$data); + } + + } else { + foreach (C::t('organization')->fetch_all_by_forgid($id) as $value) { + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($value['orgid'], $_G['uid'])) { + $orgdisable = ''; + $orgtype = 'organization'; + } else { + $orgdisable = '"disabled":true,'; + $orgtype = 'disabled'; + } + $arr=array('id' => $value['orgid'], 'text' => $value['orgname'], 'icon' => $icon, 'state' => array('disabled' => $orgdisable), "type" => $orgtype, 'children' => true); + if(intval($value['aid'])==0){ + $arr['text'] = avatar_group($value['orgid'],array($value['orgid']=>array('aid'=>$value['aid'],'orgname'=>$value['orgname']))).$value['orgname']; + $arr['icon'] = false; + }else{ + $arr['text'] = $value['orgname']; + $arr['icon']='index.php?mod=io&op=thumbnail&width=24&height=24&path=' . dzzencode('attach::' . $value['aid']); + } + $data[]=$arr; + } + if ($ismoderator) { + $uids = array(); + $datas = array(); + foreach (C::t('organization_user')->fetch_user_by_orgid($id,$limit) as $value) { + if(!$value['uid']) continue; + $uids[] = $value['uid']; + $datas[] = array('id' => 'orgid_' . $value['orgid'] . '_uid_' . $value['uid'], 'text' => $value['username'] . '' . $value['email'] . '', 'icon' => 'dzz/system/images/user.png', 'state' => array('disabled' => $disable), "type" => $type, 'li_attr' => array('uid' => $value['uid'])); + } + getuserIcon($uids,$datas,$data); + } + } + + } + + exit(json_encode($data)); +} elseif ($do == 'search') {//jstree搜索接口 + $str = trim($_GET['str']); + $str = '%' . $str . '%'; + $sql = "username LIKE %s"; + //搜索用户 + $data = array('other'); + $uids = array(); + foreach (DB::fetch_all("select * from %t where $sql ",array('user',$str)) as $value) { + $uids[] = $value['uid']; + $data['uid_' . $value['uid']] = 'uid_' . $value['uid']; + } + $orgids = array(); + foreach ($orgusers=C::t('organization_user')->fetch_all_by_uid($uids) as $value) { + $data['uid_' . $value['uid']] = 'orgid_' . $value['orgid'] . '_uid_' . $value['uid']; + $orgids[] = $value['orgid']; + } + + foreach ($orgids as $orgid) { + $uporgids = C::t('organization')->fetch_parent_by_orgid($orgid); + foreach ($uporgids as $value) { + $data[$value] = $value; + } + } + $temp = array(); + foreach ($data as $value) { + $temp[] = $value; + } + exit(json_encode($temp)); + +} elseif ($do == 'getjobs') { + $orgid = intval($_GET['orgid']); + $jobs = C::t('organization_job') -> fetch_all_by_orgid($orgid); + $html = '
  • '.lang('none').'
  • '; + foreach ($jobs as $job) { + $html .= '
  • ' . $job['name'] . '
  • '; + } + exit($html); +} elseif ($do == 'create') { + $forgid = intval($_GET['forgid']); + $borgid = intval($_GET['orgid']); + //放在此部门后面 + if (!$ismoderator = C::t('organization_admin') -> ismoderator_by_uid_orgid($forgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + /*默认新建机构和部门开始群组manageon群组管理员开启 syatemon系统管理员开启 available 系统管理员开启共享目录,保留diron(群组管理员开启目录)控制是否开启目录显示在前台*/ + $setarr = array('forgid' => intval($_GET['forgid']), 'orgname' => lang('new_department'), 'fid' => 0, 'disp' => intval($_GET['disp']), 'indesk' => 0, 'dateline' => TIMESTAMP, 'available' => 1,'syatemon'=>1,'manageon'=>1,'maxspacesize'=> getglobal('orgmemorySpace', 'setting')); + if ($setarr = C::t('organization') -> insert_by_forgid($setarr, $borgid)) { + include_once libfile('function/cache'); + updatecache('organization'); + } else { + $setarr['error'] = 'create organization failure'; + } + + exit(json_encode($setarr)); +} elseif ($do == 'rename') { + $orgid = intval($_GET['orgid']); + if (!$ismoderator = C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization') -> update_by_orgid($orgid, array('orgname' => getstr($_GET['text'])))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('msg' => lang('rechristen_error')))); + } +} elseif ($do == 'delete') { + + if ($_GET['type'] == 'user') {//删除用户 + $forgid = intval($_GET['forgid']); + $uids = $_GET['uids']; + $realdelete = intval($_GET['realdelete']); + if ($realdelete) { + if ($_G['adminid'] != 1) + exit(json_encode(array('error' => lang('privilege')))); + //判断用户是否在部门中,在部门中的用户不彻底删除 + if (C::t('organization_user') -> fetch_orgids_by_uid($uids)) { + exit(json_encode(array('error' => lang('orguser_ajax_delete')))); + } + foreach ($uids as $uid) { + //删除用户 + C::t('user') -> delete_by_uid($uid); + } + exit(json_encode(array('msg' => 'success'))); + } else { + //检测权限 + if (!$ismoderator = C::t('organization_admin') ->chk_memberperm($forgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization_user') -> delete_by_uid_orgid($uids, $forgid)) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('msg' => lang('delete_error')))); + } + } + + } else { + $orgid = ($_GET['orgid']); + $forgid = intval($_GET['forgid']); + if (!$ismoderator = C::t('organization_admin') -> ismoderator_by_uid_orgid($forgid, $_G['uid'])) { + exit(json_encode(array('error' => loang('privilege')))); + } + if ($return = C::t('organization') -> delete_by_orgid($orgid)) {//删除部门,部门的用户移动到上级部门去; + if ($return['error']) { + exit(json_encode($return)); + } + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('msg' => lang('delete_error')))); + } + } +} elseif ($do == 'move') { + + if ($_GET['type'] == 'user') {//移动用户 + $orgid = intval($_GET['orgid']); + $forgid = intval($_GET['forgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($forgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + $copy = intval($_GET['copy']); + + $uid = intval($_GET['uid']); + if (C::t('organization_user') -> move_to_by_uid_orgid($uid, $forgid, $orgid, $copy)) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('movement_error')))); + } + } else { + $orgid = intval($_GET['orgid']); + $disp = intval($_GET['position']); + $forgid = intval($_GET['forgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($forgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization') -> setDispByOrgid($orgid, $disp, $forgid)) {//移动部门; + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('msg' => lang('delete_error')))); + } + } +} elseif ($do == 'jobedit') { + $jobid = intval($_GET['jobid']); + $orgid = intval($_GET['orgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + $name = str_replace('...', '', getstr($_GET['name'], 30)); + if (C::t('organization_job') -> update($jobid, array('name' => $name))) { + exit(json_encode(array('jobid' => $jobid, 'name' => $name))); + } else { + exit(json_encode(array('error' => lang('edit_error')))); + } +} elseif ($do == 'jobdel') { + $jobid = intval($_GET['jobid']); + $orgid = intval($_GET['orgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization_job') -> delete($jobid)) { + exit(json_encode(array('jobid' => $jobid))); + } else { + exit(json_encode(array('error' => lang('delete_unsuccess')))); + } +} elseif ($do == 'jobadd') { + $orgid = intval($_GET['orgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + $setarr = array('orgid' => $orgid, 'name' => str_replace('...', '', getstr($_GET['name'], 30)), 'dateline' => TIMESTAMP, 'opuid' => $_G['uid']); + if ($setarr['jobid'] = C::t('organization_job') -> insert($setarr)) { + exit(json_encode($setarr)); + } else { + exit(json_encode(array('error' => lang('add_unsuccess')))); + } +} elseif ($do == 'moderator_add') { + $orgid = intval($_GET['orgid']); + $org = C::t('organization') -> fetch($orgid); + $perm = C::t('organization_admin') ->chk_memberperm($orgid, $_G['uid']); + if ($perm < 2) { + exit(json_encode(array('error' => lang('privilege')))); + } + $setarr = array('orgid' => $orgid, 'uid' => intval($_GET['uid']), 'dateline' => TIMESTAMP, 'opuid' => $_G['uid']); + if ($setarr['id'] = C::t('organization_admin') -> insert(intval($_GET['uid']), $orgid)) { + $user = getuserbyuid($setarr['uid']); + $setarr['username'] = $user['username']; + $setarr['avatar']=avatar_block($setarr['uid']); + exit(json_encode($setarr)); + } else { + exit(json_encode(array('error' => lang('add_administrator_unsuccess')))); + } +} elseif ($do == 'moderator_del') { + $orgid = intval($_GET['orgid']); + $org = C::t('organization_admin') -> fetch($orgid); + //获取当前操作用户权限,系统管理员,上级部门管理员和群组创建人均返回2 + $perm = C::t('organization_admin') ->chk_memberperm($orgid,$_G['uid']); + if ($perm < 2) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization_admin') -> delete_by_id(intval($_GET['id']))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('add_administrator_unsuccess')))); + } +} elseif ($do == 'folder_available') { + $orgid = intval($_GET['orgid']); + + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization') -> setFolderAvailableByOrgid($orgid, intval($_GET['available']))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('unable_set')))); + } +} elseif ($do == 'folder_indesk') { + $orgid = intval($_GET['orgid']); + + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization') -> setIndeskByOrgid($orgid, intval($_GET['indesk']))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('no_open_Shared_directory')))); + } +} elseif ($do == 'set_org_orgname') { + $orgid = intval($_GET['orgid']); + $orgname=getstr($_GET['orgname'],255); + + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization')->update_by_orgid($orgid, array('orgname'=>$orgname))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('rechristen_error')))); + } +}elseif($do == 'set_org_logo'){ + $orgid = intval($_GET['orgid']); + $img=intval(($_GET['aid'])); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization')->update_by_orgid($orgid, array('aid'=>$img))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('rechristen_error')))); + } + +}elseif ($do == 'set_org_desc') { + $orgid = intval($_GET['orgid']); + $desc=getstr($_GET['desc']); + + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization')->update_by_orgid($orgid, array('desc'=>$desc))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('rechristen_error')))); + } +}elseif($do == 'group_on'){ + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if (C::t('organization') -> setgroupByOrgid($orgid, intval($_GET['available']))) { + exit(json_encode(array('msg' => 'success'))); + } else { + exit(json_encode(array('error' => lang('unable_set')))); + } +}elseif($do == 'orginfo'){ + $array = isset($_GET['arr']) ? $_GET['arr']:''; + if(!empty($array)){ + $orgid = intval($array['orgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(json_encode(array('error' => lang('privilege')))); + } + if(!$org = C::t('organization') -> fetch($orgid)){ + exit(json_encode(array('error' => lang('organization_not_exists')))); + } + $setarr = array( + 'desc'=>getstr($array['desc']), + 'groupback'=>isset($array['groupback']) ? intval($array['groupback']):0, + 'aid'=>isset($array['aid']) ? intval($array['aid']):0, + //'orgname'=>getstr($array['orgname']); + ); + if(C::t('organization')->update($orgid,$setarr)){ + $addaids = array(); + $delaids = array(); + if(!empty($array['aid']) && $array['aid'] != $org['aid']){ + $addaids[] = $array['aid']; + $delaids[] = $org['aid']; + } + if(!empty($array['groupback']) && $array['groupback'] != $org['groupback']){ + $addaids[] = $array['groupback']; + $delaids[] = $org['groupback']; + } + if(!empty($addaids)){ + C::t('attachment')->addcopy_by_aid($addaids); + } + if(!empty($delaids)){ + C::t('attachment')->addcopy_by_aid($delaids,-1); + } + exit(json_encode(array('success' =>true))); + }else{ + exit(json_encode(array('error' => lang('edit_error')))); + } + } +}elseif($do=='folder_maxspacesize'){ + $orgid=intval($_GET['orgid']); + $setspacesize = intval($_GET['maxspacesize']); + if(!$org=C::t('organization')->fetch($orgid)){ + exit(json_encode(array('error'=>'该机构或群组不存在或被删除'))); + } + //暂时只允许系统管理员进行空间相关设置 + if($_G['adminid'] != 1){ + exit(json_encode(array('error'=>'没有权限'))); + } + if($setspacesize != 0){ + + //获取允许设置的空间值 + $allowallotspace = C::t('organization')->get_allowallotspacesize_by_orgid($orgid); + + if($allowallotspace < 0) { + exit(json_encode(array('error' => '可分配空间不足'))); + } + + //获取当前已占用空间大小 + $currentallotspace = C::t('organization')->get_orgallotspace_by_orgid($orgid,0,false); + //设置值小于当前下级分配总空间值即:当前设置值 < 下级分配总空间 + if($setspacesize > 0 && $setspacesize*1024*1024 < $currentallotspace){ + + exit(json_encode(array('error'=>'设置空间值不足,小于已分配空间值!','val'=>$org['maxspacesize']))); + + } + //上级包含空间限制时,无限制不处理,直接更改设置值 + if($allowallotspace > 0 && ($setspacesize*1024*1024 > $allowallotspace)){ + + exit(json_encode(array('error'=>'总空间不足!','val'=>$org['maxspacesize']))); + + } + } + + //设置新的空间值 + if(C::t('organization')->update($orgid,array('maxspacesize'=>$setspacesize))){ + + exit(json_encode(array('msg'=>'success'))); + + }else{ + exit(json_encode(array('error'=>'设置不成功或未更改','val'=>$org['maxspacesize']))); + } + +}elseif ($do == 'guide') { + include template('guide'); +} +exit(); +?> diff --git a/admin/orguser/edituser.php b/admin/orguser/edituser.php new file mode 100644 index 0000000..e72c6b7 --- /dev/null +++ b/admin/orguser/edituser.php @@ -0,0 +1,440 @@ + $orgid) { + if (!$orgid) + continue; + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'], 1)) { + $orgids[$orgid] = intval($_GET['jobids'][$key]); + } + } + if (!$orgids && $_G['adminid'] != 1) + showmessage('no_parallelism_jurisdiction'); + //用户名验证 + $username = trim($_GET['username']); + if ($username) { + $usernamelen = dstrlen($_GET['username']); + if ($usernamelen < 3) { + showmessage('profile_username_tooshort'); + } elseif ($usernamelen > 30) { + showmessage('profile_username_toolong'); + } + if ($_G['setting']['censoruser'] && @preg_match($censorexp, $username)) { + showmessage('profile_username_protect'); + } + //如果输入用户名,检查用户名不能重复 + + if (C::t('user') -> fetch_by_username($username)) { + showmessage('user_registered_retry'); + } + + } + $user_extra = array(); + //如果输入手机号码,检查手机号码不能重复 + $phone = trim($_GET['phone']); + if ($phone) { + if (!preg_match("/^\d+$/", $phone)) { + showmessage('user_phone_illegal'); + } + if (C::t('user') -> fetch_by_phone($phone)) { + showmessage('user_phone_registered'); + } + $user_extra['phone'] = $phone; + } + //如果输入微信号,检查微信号不能重复 + $weixinid = trim($_GET['weixinid']); + if ($weixinid) { + if (!preg_match("/^[a-zA-Z\d_]{5,}$/i", $weixinid)) { + showmessage(lang('weixin_illegal')); + } + if (C::t('user') -> fetch_by_weixinid($weixinid)) { + showmessage('weixin_registered'); + } + $user_extra['weixinid'] = $weixinid; + } + + + //邮箱验证部分 + $email = strtolower(trim($_GET['email'])); + checkemail($_GET['email']); + + //密码验证部分 + if ($_G['setting']['pwlength']) { + if (strlen($_GET['password']) < $_G['setting']['pwlength']) { + showmessage('profile_password_tooshort', '', array('pwlength' => $_G['setting']['pwlength'])); + } + } + + if (!$_GET['password'] || $_GET['password'] != addslashes($_GET['password'])) { + showmessage('profile_passwd_illegal'); + } + $password = $_GET['password']; + + $result = uc_user_register(addslashes($username), $password, $email, $nickname, $questionid, $answer, $_G['clientip'], 0); + if (is_array($result)) { + $uid = $result['uid']; + $password = $result['password']; + } else { + $uid = $result; + } + if ($uid <= 0) { + if ($uid == -1) { + showmessage('profile_username_illegal'); + } elseif ($uid == -2) { + showmessage('profile_username_protect'); + } elseif ($uid == -3) { + showmessage('profile_username_duplicate'); + } elseif ($uid == -4) { + showmessage('profile_email_illegal'); + } elseif ($uid == -5) { + showmessage('profile_email_domain_illegal'); + } elseif ($uid == -6) { + showmessage('profile_email_duplicate'); + } elseif ($uid == -7) { + showmessage('profile_username_illegal'); + } else { + showmessage('undefined_action'); + } + } + //插入用户状态表 + $status = array('uid' => $uid, 'regip' => '', 'lastip' => '', 'lastvisit' => '', 'lastactivity' => '', 'lastsendmail' => 0); + C::t('user_status') -> insert($status, false, true); + //处理管理员 + C::t('user') -> setAdministror($uid, intval($_GET['groupid'])); + //加入额外信息 + if ($user_extra) + C::t('user') -> update($uid, $user_extra); + + //处理额外空间 + $addsize = intval($_GET['addsize']); + if (C::t('user_field') -> fetch($uid)) { + C::t('user_field') -> update($uid, array('addsize' => $addsize, 'perm' => 0)); + } else { + C::t('user_field') -> insert(array('uid' => $uid, 'addsize' => $addsize, 'perm' => 0, 'iconview' => $_G['setting']['desktop_default']['iconview'] ? $_G['setting']['desktop_default']['iconview'] : 2, 'taskbar' => $_G['setting']['desktop_default']['taskbar'] ? $_G['setting']['desktop_default']['taskbar'] : 'bottom', 'iconposition' => intval($_G['setting']['desktop_default']['iconposition']), 'direction' => intval($_G['setting']['desktop_default']['direction']), )); + } + + if ($orgids) + C::t('organization_user') -> replace_orgid_by_uid($uid, $orgids); + //处理上司职位; + C::t('organization_upjob') -> insert_by_uid($uid, intval($_GET['upjobid'])); + Hook::listen('syntoline_user',$uid);//注册绑定到钉钉部门表 + if ($_GET['sendmail']) { + $sitename=$_G['setting']['sitename']; + $email_password_message = <<尊敬的用户$member[username],您好!

    +

    您收到这封邮件,是由于 $sitename 的管理员添加成员时使用了这个邮箱地址。如果您不知道 $sitename 请忽略这封邮件。您不需要退订或进行其他进一步的操作。

    +

    登录帐号和密码

    +

    登录帐号:$_GET[email]

    +

    登录密码:$_GET[password]

    +

    感谢您的访问,祝您使用愉快!

    +EOT; + + if (!sendmail("$_GET[email] <$_GET[email]>", '用户帐号和密码', $email_password_message)) { + runlog('sendmail', "$_GET[email] 发送失败"); + } + } + + showmessage('add_user_success', MOD_URL.'#user_' . $uid, array('uid' => $uid, 'orgids' => $orgids)); + + } else { + $orgid = intval($_GET['orgid']); + if (!C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(lang('orguser_edituser_add_user')); + } + if ($org = C::t('organization') -> fetch($orgid)) { + $org['jobs'] = C::t('organization_job') -> fetch_all_by_orgid($org['orgid']); + $orgpath = getPathByOrgid($org['orgid']); + $org['depart'] = implode('-', ($orgpath)); + } + + include template('adduser'); + } + +} elseif ($do == 'edit') { + if (submitcheck('accountedit')) { + + //判断是否对此用户有管理权限 + $uperm = false; + if ($_G['adminid'] != 1) { + if ($orgids_uid = C::t('orginization_user') -> fetch_orgids_by_uid($uid)) { + foreach ($orgids_uid as $orgid) { + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + $uperm = true; + break; + } + } + if (!$uperm) + showmessage('privilege'); + } else { + showmessage('privilege'); + } + } + + $orgids = array(); + foreach ($_GET['orgids'] as $key => $orgid) { + if ($orgid) + $orgids[$orgid] = intval($_GET['jobids'][$key]); + } + + $user = C::t('user') -> fetch_by_uid($uid); + if ($user['groupid'] < $_G['groupid'] || (C::t('user') -> checkfounder($user) && !C::t('user') -> checkfounder($_G['member']))) { + //处理用户部门和职位 + C::t('organization_user') -> replace_orgid_by_uid($uid, $orgids); + + //处理上司职位; + C::t('organization_upjob') -> insert_by_uid($uid, intval($_GET['upjobid'])); + + showmessage('edit_user_success', MOD_URL.'#user_' . $uid, array()); + } + + + //用户名验证 + $username = trim($_GET['username']); + + $usernamelen = dstrlen($_GET['username']); + if ($usernamelen < 3) { + showmessage('profile_username_tooshort'); + } elseif ($usernamelen > 30) { + showmessage('profile_username_toolong'); + } elseif (!check_username(addslashes(trim(stripslashes($username))))) { + showmessage('profile_username_illegal'); + } + + //如果输入用户名,检查用户名不能重复 + if ($username != $user['username']) { + if (C::t('user') -> fetch_by_username($username)) { + showmessage('user_registered_retry'); + } + if ($_G['setting']['censoruser'] && @preg_match($censorexp, $username)) { + showmessage('profile_username_protect'); + } + } + + + //如果输入手机号码,检查手机号码不能重复 + $phone = trim($_GET['phone']); + if ($phone) { + if (!preg_match("/^\d+$/", $phone)) { + showmessage('user_phone_illegal'); + } + if ($phone != $user['phone'] && C::t('user') -> fetch_by_phone($phone)) { + showmessage('user_phone_registered'); + } + } + //如果输入微信号,检查微信号不能重复 + $weixinid = trim($_GET['weixinid']); + if ($weixinid) { + if (!preg_match("/^[a-zA-Z\d_]{5,}$/i", $weixinid)) { + showmessage(lang('weixin_illegal')); + } + if ($weixinid != $user['weixinid'] && C::t('user') -> fetch_by_weixinid($weixinid)) { + showmessage('weixin_registered'); + } + } + + //邮箱验证部分 + $email = strtolower(trim($_GET['email'])); + if (!isemail($email)) { + showmessage('profile_email_illegal', '', array(), array('handle' => false)); + } elseif (!check_emailaccess($email)) { + showmessage('profile_email_domain_illegal', '', array(), array('handle' => false)); + } + if ($email != strtolower($user['email'])) { + //邮箱不能重复 + if (C::t('user') -> fetch_by_email($email)) { + showmessage('email_registered_retry'); + } + } + + //密码验证部分 + if ($_GET['password']) { + if ($_G['setting']['pwlength']) { + if (strlen($_GET['password']) < $_G['setting']['pwlength']) { + showmessage('profile_password_tooshort', '', array('pwlength' => $_G['setting']['pwlength'])); + } + } + + if ($_GET['password'] !== $_GET['password2']) { + showmessage('profile_passwd_notmatch'); + } + } + $password = $_GET['password']; + if ($password) { + $salt = substr(uniqid(rand()), -6); + $setarr = array('salt' => $salt, 'password' => md5(md5($password) . $salt), 'username' => $username, 'phone' => $phone, 'weixinid' => $weixinid, 'secques' => '', 'email' => $email, 'status' => intval($_GET['status'])); + + } else { + $setarr = array('username' => $username, 'email' => $email, 'phone' => $phone, 'weixinid' => $weixinid, 'status' => intval($_GET['status'])); + } + C::t('user') -> update($uid, $setarr); + + //处理管理员 + C::t('user') -> setAdministror($uid, intval($_GET['groupid'])); + //处理额外空间和用户空间 + //$addsize = intval($_GET['addsize']); + $userspace = intval($_GET['userspace']); + if (C::t('user_field') -> fetch($uid)) { + C::t('user_field') -> update($uid, array('userspace'=>$userspace,'perm' => 0)); + } else { + C::t('user_field') -> insert(array('uid' => $uid,'userspace'=>$userspace, 'perm' => 0, 'iconview' => $_G['setting']['desktop_default']['iconview'] ? $_G['setting']['desktop_default']['iconview'] : 2, 'taskbar' => $_G['setting']['desktop_default']['taskbar'] ? $_G['setting']['desktop_default']['taskbar'] : 'bottom', 'iconposition' => intval($_G['setting']['desktop_default']['iconposition']), 'direction' => intval($_G['setting']['desktop_default']['direction']), )); + } + //处理用户部门和职位 + + if ($orgids) + C::t('organization_user') -> replace_orgid_by_uid($uid, $orgids); + //处理上司职位; + + C::t('organization_upjob') -> insert_by_uid($uid, intval($_GET['upjobid'])); + Hook::listen('syntoline_user',$uid);//注册绑定到钉钉部门表 + showmessage('edit_user_success', MOD_URL.'#user_' . $uid, array()); + } else { + require_once libfile('function/organization'); + + $user = C::t('user') -> fetch_by_uid($uid); + $userfield = C::t('user_field') -> fetch($uid); + + //$user['status']=$user['status']>0?0:1; + $departs = array(); + $data_depart = array(); + //$departs=getDepartmentByUid($uid); + $orgids = C::t('organization_user') -> fetch_orgids_by_uid($uid); + //判断是否对此用户有管理权限 + $uperm = false; + if ($_G['adminid'] != 1) { + foreach ($orgids as $orgid) { + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + $uperm = true; + break; + } + } + if (!$uperm) + exit(lang('orguser_edituser_add_user1')); + } + //获取系统可分配空间大小 + $allowallotspace = C::t('organization')->get_system_allowallot_space(); + //如果该用户之前有分配空间,当前用户可分配空间=系统可分配空间+该用户之前分配空间(若无,则加上当前用户已使用空间) + if($userfield['userspace'] > 0){ + $currentuserAllotspace = $allowallotspace + $userfield['userspace']*1024*1024; + }else{ + $currentuserAllotspace = $allowallotspace + $userfield['usesize']; + } + $departs = C::t('organization') -> fetch_all($orgids); + foreach ($departs as $key => $value) { + $orgpath = getPathByOrgid($value['orgid']); + $value['depart'] = implode('-', ($orgpath)); + $value['ismoderator'] = C::t('organization_admin') -> ismoderator_by_uid_orgid($value['orgid'], $_G['uid']); + $value['jobs'] = C::t('organization_job') -> fetch_all_by_orgid($value['orgid']); + $value['user'] = C::t('organization_user') -> fetch_by_uid_orgid($uid, $value['orgid']); + $value['jobid'] = $value['user']['jobid']; + $value['jobname'] = $value['jobs'][$value['jobid']] ? $value['jobs'][$value['jobid']]['name'] : lang('none'); + $data_depart[$key] = $value; + } + //$orgtree_admin=getDepartmentOption_admin(0); + if ($upjob = C::t('organization_upjob') -> fetch_by_uid($uid)) { + $upjob['jobs'] = C::t('organization_job') -> fetch_all_by_orgid($upjob['orgid']); + } else { + $upjob = array('jobid' => 0, 'depart' => lang('please_select_a_organization_or_department'), 'name' => lang('none')); + } + //$orgtree_all=getDepartmentOption_admin(0,'',true); + $perm = 1; + if ($user['groupid'] < $_G['groupid'] || (C::t('user') -> checkfounder($user) && !C::t('user') -> checkfounder($_G['member']))) { + $perm = 0; + } + + include template('edituser'); + } + +} elseif ($do == 'profile') { + //判断是否对此用户有管理权限 + $uperm = false; + if ($_G['adminid'] != 1) { + if ($orgids = C::t('organization_user') -> fetch_orgids_by_uid($uid)) { + foreach ($orgids as $orgid) { + if (C::t('organization_admin') -> ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + $uperm = true; + break; + } + } + } + if (!$uperm) + exit(lang('orguser_edituser_add_user1')); + } + include_once libfile('function/profile', '', 'user'); + $space = getuserbyuid($uid); + space_merge($space, 'profile'); + loadcache('profilesetting'); + if (empty($_G['cache']['profilesetting'])) { + loadcache('profilesetting'); + } + if (submitcheck('profilesubmit')) { + $setarr = array(); + foreach ($_GET as $key => $value) { + $field = $_G['cache']['profilesetting'][$key]; + if (empty($field)) { + continue; + } elseif (profile_check($key, $value, $space)) { + $setarr[$key] = dhtmlspecialchars(trim($value)); + } + } + if (isset($_POST['birthmonth']) && ($space['birthmonth'] != $_POST['birthmonth'] || $space['birthday'] != $_POST['birthday'])) { + $setarr['constellation'] = get_constellation($_POST['birthmonth'], $_POST['birthday']); + } + if (isset($_POST['birthyear']) && $space['birthyear'] != $_POST['birthyear']) { + $setarr['zodiac'] = get_zodiac($_POST['birthyear']); + } + + if ($setarr) { + $setarr['uid'] = $uid; + C::t('user_profile') -> insert($setarr); + } + showmessage('subscriber_data_alter_success', MOD_URL.'#user_' . $uid . '_profile', array()); + } else { + $allowitems = array(); + foreach ($_G['cache']['profilesetting'] as $key => $value) { + if ($value['available'] > 0) + $allowitems[] = $key; + } + $htmls = $settings = array(); + foreach ($allowitems as $fieldid) { + if (!in_array($fieldid, array('department', 'timeoffset'))) { + $html = profile_setting($fieldid, $space, false, true); + if ($html) { + $settings[$fieldid] = $_G['cache']['profilesetting'][$fieldid]; + $htmls[$fieldid] = $html; + } + } + } + $active = array('profile' => 'class="active"'); + + include template('profile'); + } + +} +exit(); +?> diff --git a/admin/orguser/export.php b/admin/orguser/export.php new file mode 100644 index 0000000..c11eee5 --- /dev/null +++ b/admin/orguser/export.php @@ -0,0 +1,183 @@ +lang('compellation'),'email'=>lang('email'),'birth'=>lang('date_birth'),'gender'=>lang('gender'),'mobile'=>lang('cellphone'),'weixinid'=>lang('weixin'),'orgname'=>lang('category_department'),'job'=>lang('department_position')); + $h1=getProfileForImport(); + $h0=array_merge($h0,$h1); +$orgid=intval($_GET['orgid']); +if(!submitcheck('exportsubmit')){ + $orgpath=C::t('organization')->getPathByOrgid($orgid); + if(empty($orgpath)) $orgpath=lang('please_select_range_export'); + + //默认选中 + $open=array(); + $patharr=getPathByOrgid($orgid); + $arr=array_keys($patharr); + array_pop($arr); + $count=count($arr); + if($open[$arr[$count-1]]){ + if(count($open[$arr[$count-1]])>$count) $open[$arr[count($arr)-1]]=$arr; + }else{ + $open[$arr[$count-1]]=$arr; + } + $openarr=json_encode(array('orgid'=>$open)); + + include template('export'); + exit(); +}else{ + if(!is_array($_GET['item'])) showmessage('please_select_project_export',dreferer()); + foreach($h0 as $key=>$value){ + if(!in_array($key,$_GET['item'])) unset($h0[$key]); + } + $title=''; + if($org=C::t('organization')->fetch($orgid)){ + $orgids=getOrgidTree($org['orgid']); + if($org['forgid']>0){ + $toporgid=C::t('organization')->getTopOrgid($orgid); + $toporg=C::t('organization')->fetch($toporgid); + $title=$_G['setting']['sitename'].'-'.$toporg['orgname'].'-'.$org['orgname']; + }else{ + $title=$_G['setting']['sitename'].'-'.$org['orgname']; + } + }else{ + $title=$_G['setting']['sitename']; + } + + + $objPHPExcel = new PHPExcel(); + $objPHPExcel->getProperties()->setCreator($_G['username']) + ->setTitle($title.' - '.lang('user_information_table').' - DzzOffice') + ->setSubject($title.' - '.lang('user_information_table')) + ->setDescription($title.' - '.lang('user_information_table').' Export By DzzOffice '.date('Y-m-d H:i:s')) + ->setKeywords($title.' - '.lang('user_information_table')) + ->setCategory(lang('user_information_table')); + $list=array(); + // Create a first sheet + $objPHPExcel->setActiveSheetIndex(0); + $j=0; + foreach($h0 as $key =>$value){ + $index=getColIndex($j).'1'; + $objPHPExcel->getActiveSheet()->setCellValue($index,$value); + $list[1][$index]=$value; + $j++; + } + $i=2; + $wheresql=1; + if($orgid){ + $uids=C::t('organization_user')->fetch_uids_by_orgid($orgids); + $wheresql=" where uid IN (".dimplode($uids).")"; + }else{ + $wheresql=" where 1 "; + } + + foreach(DB::fetch_all("select * from %t $wheresql",array('user')) as $user){ + + $profile=C::t('user_profile')->fetch_all($user['uid']); + if($profile) $value=array_merge($user,$profile[$user['uid']]); + else $value=$user; + if($value['birthyear'] && $value['birthmonth'] && $value['birthday']) $value['birth']=$value['birthyear'] .'-'. $value['birthmonth'] .'-'. $value['birthday']; + if($value['gender']){ + if($value['gender']==2) $value['gender']=lang('woman'); + elseif($value['gender']==1) $value['gender']=lang('man'); + else $value['gender']=''; + } + //获取用户的部门和职位 + if($orgids=C::t('organization_user')->fetch_orgids_by_uid($value['uid'])){ + $k=0; + foreach($orgids as $key=> $gid){ + $orgpath=C::t('organization')->getPathByOrgid($gid); + $value['orgname']=str_replace('-','/',$orgpath); + if(empty($value['orgname'])) continue; + if($job=DB::fetch_first("select j.name from %t u LEFT JOIN %t j ON u.jobid=j.jobid where u.orgid=%d and u.uid=%d",array('organization_user','organization_job',$gid,$user['uid']))) $value['job']=$job['name']; + $j=0; + foreach($h0 as $key1 =>$fieldid){ + $index=getColIndex($j).intval($i+$k); + $objPHPExcel->getActiveSheet()->setCellValue($index,$value[$key1]); + $j++; + $list[$i+$k][$index]=$value[$key1]; + } + $k++; + } + $i+=$k-1; + }else{ + $j=0; + foreach($h0 as $key1 =>$fieldid){ + $index=getColIndex($j).($i); + $objPHPExcel->getActiveSheet()->setCellValue($index,$value[$key1]); + $j++; + $list[$i][$index]=$value[$key1]; + } + } + $i++; + } + $objPHPExcel->setActiveSheetIndex(0); + $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007'); + $filename=$_G['setting']['attachdir'].'./cache/'.random(5).'.xlsx'; + $objWriter->save($filename); + + + $name=$title.' - '.lang('user_information_table').'.xlsx'; + $name = '"'.(strtolower(CHARSET) == 'utf-8' && (strexists($_SERVER['HTTP_USER_AGENT'], 'MSIE') || strexists($_SERVER['HTTP_USER_AGENT'], 'rv:11')) ? urlencode($name) : $name).'"'; + + $filesize=filesize($filename); + $chunk = 10 * 1024 * 1024; + if(!$fp = @fopen($filename, 'rb')) { + exit(lang('export_failure')); + } + dheader('Date: '.gmdate('D, d M Y H:i:s', TIMESTAMP).' GMT'); + dheader('Last-Modified: '.gmdate('D, d M Y H:i:s', TIMESTAMP).' GMT'); + dheader('Content-Encoding: none'); + dheader('Content-Disposition: attachment; filename='.$name); + dheader('Content-Type: application/octet-stream'); + dheader('Content-Length: '.$filesize); + @ob_end_clean();if(getglobal('gzipcompress')) @ob_start('ob_gzhandler'); + while (!feof($fp)) { + echo fread($fp, $chunk); + @ob_flush(); // flush output + @flush(); + } + @unlink($filename); + exit(); +} +function getColIndex($index){ + $string="ABCDEFGHIJKLMNOPQRSTUVWXYZ"; + $ret=''; + if($index>255) return ''; + for($i=0;$i $value){ + if(in_array($key,array('department','realname','gender','birthyear','birthmonth','birthday','constellation','zodiac'))) continue; + elseif($value['formtype']=='file') continue; + elseif($value['formtype']=='select' || $value['formtype']=='radio'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'|',$value['choices']).')':'')*/; + }elseif( $value['formtype']=='checkbox'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'-',$value['choices']).')':'')*/; + }else{ + $ret[$key]=$value['title']; + } + } + return $ret; +} +?> diff --git a/admin/orguser/export_tmpl.php b/admin/orguser/export_tmpl.php new file mode 100644 index 0000000..e6f46d1 --- /dev/null +++ b/admin/orguser/export_tmpl.php @@ -0,0 +1,96 @@ +lang('compellation'),'email'=>lang('email'),'password'=>lang('user_login_password'),'birth'=>lang('date_birth'),'gender'=>lang('gender'),'mobile'=>lang('cellphone'),'weixinid'=>lang('weixin'),'orgname'=>lang('category_department'),'job'=>lang('department_position')); + $h1=getProfileForImport(); + $h0=array_merge($h0,$h1); + $title=lang('bulk_import_user_template'); + $objPHPExcel = new PHPExcel(); + $objPHPExcel->getProperties()->setCreator($_G['username']) + ->setTitle($title.' - DzzOffice') + ->setSubject($title) + ->setDescription($title.' Export By DzzOffice '.date('Y-m-d H:i:s')) + ->setKeywords($title) + ->setCategory($title); + $list=array(); + // Create a first sheet + $objPHPExcel->setActiveSheetIndex(0); + $j=0; + foreach($h0 as $key =>$value){ + $index=getColIndex($j).'1'; + $objPHPExcel->getActiveSheet()->setCellValue($index,$value); + if($key=='username' || $key=='email'){ + $objPHPExcel->getActiveSheet()->getStyle($index)->getFont()->getColor()->setARGB(PHPExcel_Style_Color::COLOR_RED); + } + $list[1][$index]=$value; + $j++; + } + + $objPHPExcel->setActiveSheetIndex(0); + $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007'); + $filename=$_G['setting']['attachdir'].'./cache/'.random(5).'.xlsx'; + $objWriter->save($filename); + + + $name=$title.'.xlsx'; + $name = '"'.(strtolower(CHARSET) == 'utf-8' && (strexists($_SERVER['HTTP_USER_AGENT'], 'MSIE') || strexists($_SERVER['HTTP_USER_AGENT'], 'rv:11')) ? urlencode($name) : $name).'"'; + + $filesize=filesize($filename); + $chunk = 10 * 1024 * 1024; + if(!$fp = @fopen($filename, 'rb')) { + exit(lang('export_failure')); + } + dheader('Date: '.gmdate('D, d M Y H:i:s', TIMESTAMP).' GMT'); + dheader('Last-Modified: '.gmdate('D, d M Y H:i:s', TIMESTAMP).' GMT'); + dheader('Content-Encoding: none'); + dheader('Content-Disposition: attachment; filename='.$name); + dheader('Content-Type: application/octet-stream'); + dheader('Content-Length: '.$filesize); + @ob_end_clean();if(getglobal('gzipcompress')) @ob_start('ob_gzhandler'); + while (!feof($fp)) { + echo fread($fp, $chunk); + @ob_flush(); // flush output + @flush(); + } + @unlink($filename); + exit(); + +function getColIndex($index){ + $string="ABCDEFGHIJKLMNOPQRSTUVWXYZ"; + $ret=''; + if($index>255) return ''; + for($i=0;$i $value){ + if(in_array($key,array('department','realname','gender','birthyear','birthmonth','birthday','constellation','zodiac'))) continue; + elseif($value['formtype']=='file') continue; + elseif($value['formtype']=='select' || $value['formtype']=='radio'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'|',$value['choices']).')':'')*/; + }elseif( $value['formtype']=='checkbox'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'-',$value['choices']).')':'')*/; + }else{ + $ret[$key]=$value['title']; + } + } + return $ret; +} +?> diff --git a/admin/orguser/images/add_guide.png b/admin/orguser/images/add_guide.png new file mode 100644 index 0000000000000000000000000000000000000000..359b8b332ad695d3412fec946fedd2c02495d825 GIT binary patch literal 17935 zcmXtg1yod9`}d&-0U4C;?vn0qknWTY>FyF?=mwFzga}AThk%NRbf+REE!`mS-@M=Y zSc}WO+?g}y>~r?>{OTcAQ(Y0~5$Picf^d|Tb3r?Puv}3rX9!S=mx6IC|Rpxp}_y zqL$SW*!onT0A5G<@H$yfTT5?8H&<$1M;BX&TY&2sFV{0ZwVMA-A&44MmXp@?&)YK# z@W+?G4y`KR9LbkbLjIG4X^$_B*GnB=gN(diTtj3jr>{G+TxmT+utuV&wc5VJDze;m z{Zr3feC8G1avTvWDy?8t3f$A4C#R!h_d?MxeIz9cl_woKkqMW@=1~=<7y;Gj52w0&sTKHiT^0D zvxZJFi7)v6_9F3ODJ)D?2TZ8 z(NWmg?pXsAg;C|9?Bn3mW?DEkJ>9u>w}b&D_UC-VdK^2sZ$kdWJ-IXOA&kkq%h$-7IFC?!JwJT3b4qmxm| z46@VeVZo~$Npj%W}LG$g`=|yFiSB?jjEq}u4qucI?;dAPISy= zk;c`JCwI^KjjILps`Z&r#?DU_BnoR6_I&T{!Fh1y`~40O4ZKMRc@6JJPM$2V8R!~T zqzcIp^V!jDFt6=4FVmLy^P?=Al4Wu6>R9}l`}S?uQg>L`{7O&EF2&=Rj^^eWkHckY zduwaD@^J?xAD^a!&k-mRkdmsZ4if`IMW;DeVq&7Lj*bovSSp2*@%Ll`&T~blr>D=r z7txk?`*>6ew~SKDx3z$-`E}3E7S~0Q!4F0akFO+kituQSmOU2I)V4`Sa(ERllEeP3 zfjcuNlV#h{WGYeURzA7?D|G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6+N$=wRi@GwM><2%6stAwqPqms80z9SF(R$*|J&ANZpz|2GCtS3j3^ HP6M~)m}=yCi1|9@fGKSrP%G)jW}f`MFO0K>jjdJ;fA zoCO|{#S9GGLLkg|>2BR0prA~NYeY$Kep*R+Vo@rCV@iHfs)Ac)QEGX9QFgI{bFkTq zJ)3%f>h5^DIEH9UZ0+wBYElqz%~x%Tx@CQur~2Xl|A{&a9*LBt-MG0o-JLOapFR7H z^-)h)55F;AbE2>#?X$o|!Q~l(&p!E258mZ;a*=`Px!_;F!jG>xEN-^4&@d|VkF2?+ zZ*aLpa&7S9M{~4AvyaW1^y69PUWfe!M_GiX3OH%zEeyGtl-Bt=Vz>X-UH`7FyJ+Ia zy-L})bHlA44|#s|MLS(672ciRGq1yspTqmn79X_=hh?_=3>fQw-Mas>WOCa>eUqCK z=|1{#JJJ)kOcS=68u5PG!gSqo=`GPe`4qOlWoL}kF%7G6nGf_QgQu&X%Q~loCIA*F BA(Q|B literal 0 HcmV?d00001 diff --git a/admin/orguser/images/icons.png b/admin/orguser/images/icons.png new file mode 100644 index 0000000000000000000000000000000000000000..6238dc9821a498a361e0d405f00969e69de9739a GIT binary patch literal 3904 zcmV-G55Mq000W>0fLJSS^xk59CSrkbW?9;ba!ELWdK2BZ(?O2Mrm?o zcW-iQb09-gHt4*vi~s-t7IZ~ebVG7wVRUJ4ZXi@?ZDjy3GcPeSFEKP8mX7-X01lW* zL_t(|ob8)=bX?Va$3OSIH=AZ8jrPT8F}9IMKG+UxYeFjnHm6_{QwMBF3K$5K&_mjW zlb*I|aA=ytNyrI=C3XpzEhf0c!L@0^ZV0;#*ce%kg;y=sXq$bX_iq0f$<{K91kTAJ zyx-9~GoyL;_qo5{eed3%-uFsKDfwfX@<;XlX93W1eIbP4f~SuDM}4LJPD7VrAwUS> z>K%;T^~%*v|C+5$w(%6X2Kmd6AHCmV5!cLZbQSAH<{VWK9O#J*$KpnL+>p=gT+@6- zAwbRuE}Bz(>p8QFdGA=9b88*E?~QX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YqJKC~dgVQ~_Y1Xi!l0-~|&7mcQ^WpIm8; literal 0 HcmV?d00001 diff --git a/admin/orguser/images/orguser.css b/admin/orguser/images/orguser.css new file mode 100644 index 0000000..5ba8eb0 --- /dev/null +++ b/admin/orguser/images/orguser.css @@ -0,0 +1,276 @@ +.news { + width: 100%; + margin-bottom: 20px; + box-shadow: 0 2px 12px 0 rgb(0 0 0 / 10%); + border: 1px solid #ebeef5; + border-radius: var(--radius); + padding: 20px; + display: flex; +} +.form-horizontal-left .form-control{ + width: 100% +} +.bs-main-container{ + padding:0; +} +.jstree-root{ + padding:5px 0 0 10px; + line-height:24px; +} +.classtree-topbar{ + position:relative; + bottom:0px; + left:0px; + border-bottom:1px solid #D2D2D2; + border-top:1px solid #FFF; + padding:7px 10px 3px 10px; +} +.classtree-search{ + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 39px; + display: none; +} +.classtree-topbar a{ + display:inline-block; + width:24px; + height:24px; + background-image:url(icons_24.png); + _filter: Alpha(opacity=70); + opacity: 0.7; +} +.classtree-topbar .newdir{ + background-position:0 0; +} +.classtree-topbar .newdir_1{ + background-position:0 -24px; +} +.classtree-topbar .newdoc{ + background-position:0 -48px; +} +.classtree-topbar .import{ + background-position:0 -72px; +} +.classtree-topbar .search{ + background-position:0 -96px; +} +.classtree-topbar .guide{ + background-position:0 -120px; +} +.classtree-topbar a:hover{ + _filter: Alpha(opacity=100); + opacity: 1; +} +.classtree-topbar a:active{ + +} +/*重定义图标*/ + +.jstree-default .jstree-icon:empty { + font-size: 22px; +} +.jstree-default-large .jstree-icon:empty{ + width: 24px; + height: 24px; + border-radius: 50%; +} +.jstree-default .jstree-icon { + width: 24px; + height: 24px; + border-radius: 50%; +} +.jstree-default .jstree-icon.jstree-themeicon-custom{ + margin-top:5px; +} +.jstree-default .jstree-icon.jstree-themeicon-custom.dzz{ + margin-top:-2px; +} +.moderators-container .user-item{ + padding:10px;width:120px;position:relative;height:180px; +} +.moderators-container .user-item .delete{ + display:none; + position:absolute;top:5px;right:5px;width:24px;height:24px; + cursor:pointer; + z-index:100; + +} +.moderators-container .user-item.hover .delete{ + display:block; +} +.moderators-container .user-item-avatar{ + + width:100px;height:100px; + +} + +.moderators-container .user-item .avatar-cover{ + width:100px;height:100px; + position:absolute; + left:10px; + top:10px; + background:url(user_bg.png) no-repeat; + z-index:10; + +} +.ie8 .moderators-container .user-item .avatar-cover{ + display:none; +} +.moderators-container .user-item-avatar .avatar-face{ + width:90px;height:90px;margin:5px + +} +.moderators-container .user-item-avatar img{ + width:100%; + height:100%; + border-radius:50%; +} +.moderators-container .moderators-acceptor{ + padding:10px;width:227px;height:170px;position:relative; + margin-top:10px; + background:url(add_guide.png) no-repeat; +} +.moderators-container .moderators-acceptor .avatar-cover{ + left:25px; + top:0px; + display:none; + width:100px;height:100px; + position:absolute; + background:url(user_bg.png) no-repeat; + z-index:10; +} +.moderators-container .moderators-acceptor .user-item-avatar{ + margin:-10px 0 0 15px; + display:none; + + + +} +.moderators-container .moderators-acceptor.hover .user-item-avatar,.moderators-container .moderators-acceptor.hover .avatar-cover { + display:block; +} +.main-body{ + border-top:1px solid #FFF; +} +.group-head li{ + float: left; + list-style: none; +} +.head-portrait { + margin-right: 10px; + border: 1px solid transparent; + border-radius: 3px; + position: relative; + margin-bottom: 0; +} +.head-portrait img, .head-file img, .head-file input { + width: 100%; + height: 100%; + border-radius: 50%; +} +.head-file { + position: relative; +} +.head-file input { + position: absolute; + top: 0; + left: 0; + opacity: 0; +} +textarea{ + resize: none; +} +.setting-img { + height: 150px; +} +.setting-img img { + width: 100%; + height: 100%; +} +.upload-click { + position: absolute; + top: 0; + bottom: 0; + width: 100%; + color: #fff; + line-height: 150px; + text-align: center; + font-size: 18px; + letter-spacing: 2px; +} +#exampleInputFile { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + width: 100%; + opacity: 0; +} +.head-checkbox{ + display: none; + position: absolute; + left:1px; + top:0; + width:100%; + height:100%; +} +.head-portrait:hover { + border: 1px solid #2196f3; +} +.group-head .head-checkbox .checkbox-custom { + height:100%; + margin: 0px; +} +.group-head .head-checkbox .checkbox-custom label{ + vertical-align: text-top; +} +.headFirstWord{ + display: inline-block; + width: 50px; + height: 50px; + text-align: center; + line-height: 50px; + font-size: 18px; +} +.head-portrait:hover .head-checkbox { + display: block; +} +.group-head{ + overflow: hidden; + padding: 0; +} +.head-portrait .hover{ + display: block; +} +.has-warning .form-control { +border-color: #ff3203; +box-shadow: inset 0 0px 0px rgba(0,0,0,.075); +} +kbd{ + background-color: transparent;color: #ff3203;font-size: 100%;-webkit-box-shadow:inset 0 0 0 rgba(0,0,0,.25);box-shadow:inset 0 0 0 rgba(0,0,0,.25); +} +.head-portrait .iconFirstWord{ + width: 40px; + height: 40px; + border-radius: 50%; + display: inline-block; + line-height: 40px; + text-align: center; + margin-right: 2px; + color: #FFFFFF; + font-size:24px; +} +.iconFirstWord { + width: 24px; + height: 24px; + border-radius: 50%; + display: inline-block; + line-height: 24px; + text-align: center; + margin-right: 2px; + color: #FFFFFF; + font-size:14px; +} \ No newline at end of file diff --git a/admin/orguser/images/user_bg.png b/admin/orguser/images/user_bg.png new file mode 100644 index 0000000000000000000000000000000000000000..552983662c1cb507fbf76ff1d76f4ab528569e26 GIT binary patch literal 8276 zcmWkz1ymGm6dg(yL0Dy_YY_>hOFEVogdZtskdl@TDPale5~M?5`D{5a|*S zY4|_)oZUJ5&CH(J_r7=Ez4yKQPgUX0ZK~T41l>_mlzk44=KtQXTj2Bc&-a?(fa`)% z(u9GR56nCad?$FVsOtg_H~-#P_}?Yu!6J>T+zVF?M@v@^Q)dfE+T8J_1%te`vxSGF zv#kq*jE3OG*Q!Wx9ofI@WSlKbU9BA*7&NWzEg)_|E*?HE9)6Yb90LfVFIAG2*7Qu@ zHT3dCXw^#A)h>+CZZPpH^|Zt?@H~nTgPV^Re1jyM&~fSy`k~w<)*(ZaKbs7E(v-Pz zZ{uQE_&&mT1EPtQd#F3{H1DAl6&c=aFl7vHeyM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eR$!5J!SzqVVuEo}&&q*_1H2JEV)+*yvIn&7~{NgsZi!JtYo zlDP}KdH+Kk60zSA_4V}xG~L0Y{PWf>XU;N77SeEZK465t|2VcJutaQejr3cOyBL4xVTRa z_8R{Ba(n2!QN<(yRF-O6q!cSK+4lOr(tj(d4$}qUZ~w#nR5O@(Gft4*9Fuc7U#k$d z_2E!*^B0Y70(VWt(0|vM{F2Cu2yui~M`5Va7?XOcv0JE`a^#`Z7BSPrWnZd~#r?zk zo{gEyjSRAH&qb+H;f!N)*y9!0x#zp=c)UU6&yA0~zq!dNdSqME6b{^Vb>2xmeXHDh agA?+dPYi4A)-agtLrQY0vgIg~!2bat@1INn literal 0 HcmV?d00001 diff --git a/admin/orguser/import.php b/admin/orguser/import.php new file mode 100644 index 0000000..f4939cd --- /dev/null +++ b/admin/orguser/import.php @@ -0,0 +1,462 @@ +lang('name_email_empty')))); + if(!isemail($email)) exit(json_encode(array('error'=>'email'.lang('format_error')))); + + $isappend=intval($_GET['append']); + /* + if($sendmail){ //随机密码时重新设置密码为随机数; + $_GET['password']=random(8); + }*/ + $exist=0; + + //检查用户是否已经存在 + if(($user=C::t('user')->fetch_by_email($email)) || ($user=C::t('user')->fetch_by_username($_GET['username']))){//用户已经存在时 + $uid=$user['uid']; + $exist=1; + if($isfounder=C::t('user')->checkfounder($user)) $isappend=1;//创始人不支持覆盖导入 + if($isappend){//增量添加,如果原先没有nickname,增加 + $sitename=$_G['setting']['sitename']; + $appendfield=array(); + + if($_GET['mobile'] && empty($user['phone'])){ + if(!preg_match("/^\d+$/",$_GET['mobile'])){ + exit(json_encode(array('error'=>lang('phone_number_illegal')))); + } + if(C::t('user')->fetch_by_phone($_GET['mobile']) ) { + exit(json_encode(array('error'=>lang('user_phone_exist')))); + } + $appendfield['phone']=$_GET['mobile']; + + } + if($_GET['weixinid'] && empty($user['weixinid'])){ + if(!preg_match("/^[a-zA-Z\d_]{5,}$/i",$_GET['weixinid'])){ + exit(json_encode(array('error'=>lang('weixin_illegal')))); + } + if(C::t('user')->fetch_by_weixinid($_GET['weixinid']) ) { + exit(json_encode(array('error'=>lang('weixin_exist')))); + } + $appendfield['weixinid']=$_GET['weixinid']; + } + if($appendfield) C::t('user')->update($uid,$appendfield); + }else{ //覆盖导入时,覆盖用户的姓名和密码 + $sitename=$_G['setting']['sitename']; + $salt=substr(uniqid(rand()), -6); + if(!check_username($_GET['username'])) exit(json_encode(array('error'=>lang('user_name_sensitive')))); + $setarr=array('username'=>$_GET['username'], + 'password'=>md5(md5($_GET['password']).$salt), + 'salt'=>$salt + ); + + if($_GET['mobile'] && $_GET['mobile']!=$user['phone']){ + if(!preg_match("/^\d+$/",$_GET['mobile'])){ + exit(json_encode(array('error'=>lang('phone_number_illegal')))); + } + if(C::t('user')->fetch_by_phone($_GET['mobile']) ) { + exit(json_encode(array('error'=>lang('user_phone_exist')))); + } + $setarr['phone']=$_GET['mobile']; + + } + if($_GET['weixinid'] && $_GET['weixinid']!=$user['weixinid']){ + if(!preg_match("/^[a-zA-Z\d_]{5,}$/i",$_GET['weixinid'])){ + exit(json_encode(array('error'=>lang('weixin_illegal')))); + } + if(C::t('user')->fetch_by_weixinid($_GET['weixinid']) ) { + exit(json_encode(array('error'=>lang('weixin_exist')))); + } + $setarr['weixinid']=$_GET['weixinid']; + } + C::t('user')->update($uid,$setarr); + if($sendmail){ //发送密码到用户邮箱,延时发送 + $email_password_message = <<尊敬的用户$member[username],您好!

    +

    您收到这封邮件,是由于 $sitename 的管理员编辑成员信息时使用了这个邮箱地址。如果您不知道 $sitename 请忽略这封邮件。您不需要退订或进行其他进一步的操作。

    +

    登录帐号和密码

    +

    登录帐号:$email

    +

    登录密码:$_GET[password]

    +

    感谢您的访问,祝您使用愉快!

    +EOT; + + if(!sendmail_cron("$_GET[username] <$email>", lang('email_password_subject'), $email_password_message)) { + runlog('sendmail', "$email 发送失败"); + } + } + } + }else{ //新添用户 + if(!check_username($_GET['username'])) exit(json_encode(array('error'=>lang('user_name_sensitive')))); + + + $user=uc_add_user($_GET['username'], $_GET['password'], $email); + + $uid=$user['uid']; + if($uid<1) exit(json_encode(array('error'=>lang('import_failure')))); + $base = array( + 'uid' => $uid, + 'adminid' => 0, + 'groupid' =>9, + 'regdate' => TIMESTAMP, + 'emailstatus' => 1, + ); + if($_GET['mobile']){ + if(!preg_match("/^\d+$/",$_GET['mobile'])){ + }elseif(C::t('user')->fetch_by_phone($_GET['mobile']) ) { + }else{ + $base['phone']=$_GET['mobile']; + } + } + if($_GET['weixinid']){ + if(!preg_match("/^[a-zA-Z\d_]{5,}$/i",$_GET['weixinid'])){ + }elseif(C::t('user')->fetch_by_weixinid($_GET['weixinid'])) { + }else{ + $base['weixinid']=$_GET['weixinid']; + } + } + $sitename=$_G['setting']['sitename']; + C::t('user')->update($uid,$base); + if($sendmail){ //发送密码到用户邮箱,延时发送 + $email_password_message = <<尊敬的用户$member[username],您好!

    +

    您收到这封邮件,是由于 $sitename 的管理员添加成员时使用了这个邮箱地址。如果您不知道 $sitename 请忽略这封邮件。您不需要退订或进行其他进一步的操作。

    +

    登录帐号和密码

    +

    登录帐号:$email

    +

    登录密码:$_GET[password]

    +

    感谢您的访问,祝您使用愉快!

    +EOT; + + if(!sendmail_cron("$_GET[username] <$email>", lang('email_password_subject'), $email_password_message)) { + runlog('sendmail', "$email 发送失败"); + } + } + } + //处理用户资料 + $_GET['gender']=trim($_GET['gender']); + $_GET['birth']=trim($_GET['birth']); + $_GET['telephone']=trim($_GET['telephone']); + //$_GET['mobile']=trim($_GET['mobile']); + + if($exist && $isappend){ //增量时 + $oldprofile=C::t('user_profile')->fetch($uid); + $profile=array(); + if(!empty($_GET['birth']) && empty($oldprofile['birthyear'])){ + $birth=strtotime($_GET['birth']); + if($birth0){ + $arr=getdate($birth); + $profile['birthyear']=$arr['year']; + $profile['birthmonth']=$arr['mon']; + $profile['birthday']=$arr['mday']; + } + } + if(!empty($_GET['gender']) && empty($oldprofile['gender'])){ + if($_GET['gender']==lang('man')) $profile['gender']=1; + elseif($_GET['gender']==lang('woman')) $profile['gender']=2; + else $profile['gender']=0; + } + + if(!empty($_GET['telephone']) && empty($oldprofile['telephone'])){ + $profile['telephone']=$_GET['telephone']; + } + foreach($_GET as $key=>$value){ + if(!empty($_GET[$key]) && empty($oldprofile[$key])){ + if(checkprofile($key,$value)) $profile[$key]=$value; + } + } + + if($profile){ + $profile['uid']=$uid; + C::t('user_profile')->insert($profile); + } + }else{ + $profile=array(); + if(!empty($_GET['birth'])){ + $birth=strtotime(trim($_GET['birth'])); + if($birth0){ + $arr=getdate($birth); + $profile['birthyear']=$arr['year']; + $profile['birthmonth']=$arr['mon']; + $profile['birthday']=$arr['mday']; + } + } + if(!empty($_GET['gender'])){ + if($_GET['gender']==lang('man')) $profile['gender']=1; + elseif($_GET['gender']==lang('woman')) $profile['gender']=2; + else $profile['gender']=0; + } + + if(!empty($_GET['telephone'])){ + $profile['telephone']=$_GET['telephone']; + } + + foreach($_GET as $key=>$value){ + if(checkprofile($key,$value)) $profile[$key]=$value; + } + + $profile['uid']=$uid; + + C::t('user_profile')->insert($profile); + + //插入用户状态表 + $status = array( + 'uid' => $uid, + 'regip' => '', + 'lastip' => '', + 'lastvisit' => '', + 'lastactivity' => '', + 'lastsendmail' => 0 + ); + C::t('user_status')->insert($status, false, true); + } + //处理部门和职位 + $orgid=intval($_GET['orgid']); + + $_GET['orgname']=!empty($_GET['orgname'])?explode('/',$_GET['orgname']):array(); + $_GET['job']=!empty($_GET['job'])?explode('/',$_GET['job']):array(); + + //创建机构和部门 + foreach($_GET['orgname'] as $key => $orgname){ + if(empty($orgname)) continue; + if($porgid=DB::result_first("select orgid from %t where forgid=%d and orgname=%s",array('organization',$orgid,$orgname))){ + $orgid=$porgid; + }else{ + $setarr=array('forgid'=>$orgid, + 'orgname'=>$orgname, + 'fid'=>0, + 'disp'=>100, + 'indesk'=>0, + 'dateline'=>TIMESTAMP, + ); + if($porgid=C::t('organization')->insert_by_orgid($setarr)){ + $orgid=$porgid; + } + } + } + + //用户加入机构 + if($isappend){//增量导入时 + C::t('organization_user')->insert_by_orgid($orgid,$uid); + }else{ + C::t('organization_user')->delete_by_uid($uid,0); + C::t('organization_user')->insert_by_orgid($orgid,$uid); + } + if($orgid){ + foreach($_GET['job'] as $key =>$jobname){ //处理职位 + $jobid=0; + if($pjobid=DB::result_first("select jobid from %t where orgid=%d and name=%s",array('organization_job',$orgid,$jobname))){ + $jobid=$pjobid; + }else{ + $setarr=array('orgid'=>$orgid, + 'name'=>$_GET['job'][$key], + 'dateline'=>TIMESTAMP, + 'opuid'=>$_G['uid'] + ); + if($pjobid=C::t('organization_job')->insert($setarr,1)){ + $jobid=$pjobid; + } + } + if($jobid){ + if($isappend){//增量导入时 + if(!DB::result_first("select COUNT(*) from %t where uid=%d and orgid=%d and jobid>0 ",array('organization_user',$uid,$orgid))){ + DB::update('organization_user',array('jobid'=>$jobid),"uid='{$uid}' and orgid='{$orgid}'"); + } + }else{//覆盖导入时 + DB::update('organization_user',array('jobid'=>$jobid),"uid='{$uid}' and orgid='{$orgid}'"); + } + } + } + } + exit(json_encode(array('msg'=>'success'))); +}elseif($do=='list'){ + require_once DZZ_ROOT.'./core/class/class_PHPExcel.php'; + $inputFileName = $_G['setting']['attachdir'].$_GET['file']; + if(!is_file($inputFileName)){ + showmessage('orguser_import_user_table',MOD_URL.'&op=import'); + } + $inputFileType = PHPExcel_IOFactory::identify($inputFileName); + $objReader = PHPExcel_IOFactory::createReader($inputFileType); + $objPHPExcel = $objReader->load($inputFileName); + $sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,true); + //获取导入数据的字段 + $h0=array('username'=>lang('compellation'),'email'=>lang('email'),'nickname'=>lang('username'),'birth'=>lang('date_birth'),'gender'=>lang('gender'),'mobile'=>lang('cellphone'),'weixinid'=>lang('weixin'),'orgname'=>lang('category_department'),'job'=>lang('department_position'),'password'=>lang('user_login_password')); + $h1=getProfileForImport(); + $h0=array_merge($h0,$h1); + //获取可导入的用户资料 + $h=array(); + foreach($sheetData[1] as $key =>$value){ + $value=trim($value); + foreach($h0 as $fieldid=>$title){ + if($title==$value){ + $h[$key]=$fieldid; + break; + } + } + } + + if(!in_array('username',$h)){ + showmessage('lack_required_fields_name'); + }elseif(!in_array('email',$h) && !in_array('username',$h)){ + showmessage('lack_required_fields_name_email'); + } + if(!in_array('email',$h)){ + $h=array_merge(array('_'=>'email'),$h); + } + $list=array(); + foreach($sheetData as $key=> $value){ + if($key<=1) continue; + $temp=array(); + foreach($value as $col =>$val){ + if(trim($val)=='') continue; + if($h[$col]=='orgname'){ + $temp[$h[$col]][]=$val; + }elseif($h[$col]=='job'){ + $temp[$h[$col]][]=$val; + }elseif($key1=='birth'){ + $arr=explode('-',$value[$value1]); + if(count($arr)==3){ + $temp[$key1]=dgmdate(strtotime($arr[2].'-'.$arr[0].'-'.$arr[1]),'Y-m-d'); + }else{ + $temp[$key1]=$val; + } + }else{ + if($h[$col]) $temp[$h[$col]]=$val; + } + } + if(empty($temp['email'])) $temp['email']=random(10,true).'@163.com'; + if(isset($list[$temp['email']])){ + foreach($h as $key1 => $value1){ + if(!empty($temp[$key1])){ + $list[$temp['email']][$key1]=$temp[$key1]; + } + } + }else{ + if($temp) $list[$temp['email']]=$temp; + } + } + $h=array_unique($h); + $orgpath=C::t('organization')->getPathByOrgid($orgid); + if(empty($orgpath)) $orgpath=lang('choose_import_agency_department'); + + //默认选中 + $open=array(); + $patharr=getPathByOrgid($orgid); + $arr=(array_keys($patharr)); + array_pop($arr); + $count=count($arr); + if($open[$arr[$count-1]]){ + if(count($open[$arr[$count-1]])>$count) $open[$arr[count($arr)-1]]=$arr; + }else{ + $open[$arr[$count-1]]=$arr; + } + $openarr=json_encode(array('orgid'=>$open)); + include template('import_list'); +}else{ + if(submitcheck('importfilesubmit')){ + if($_FILES['importfile']['tmp_name']){ + $allowext=array('xls','xlsx'); + $ext=strtolower(substr(strrchr($_FILES['importfile']['name'], '.'), 1, 10)); + if(!in_array($ext,$allowext)) showmessage('orguser_import_xls_xlsx',dreferer()); + if($file=uploadtolocal($_FILES['importfile'],'cache','',array('xls','xlsx'))){ + $url=outputurl($_G['siteurl'].MOD_URL.'&op=import&do=list&file='.urlencode($file)); + @header("Location: $url"); + exit(); + showmessage('orguser_import_user_message',outputurl($_G['siteurl'].MOD_URL.'&op=import&do=list&file='.urlencode($file))); + }else{ + showmessage('orguser_import_tautology',dreferer()); + } + }else{ + showmessage('orguser_import_user_message_table',dreferer()); + } + }else{ + + include template('import_guide'); + } +} +function checkprofile($fieldid,&$value){ + global $_G; + if(empty($_G['cache']['profilesetting'])) { + loadcache('profilesetting'); + } + $field = $_G['cache']['profilesetting'][$fieldid]; + if(empty($field) || in_array($fieldid, array('department','realname','gender','birthyear','birthmonth','birthday','birth','constellation','zodiac','email','nickname','password','orgname','job','username'))) { + return false; + } + + if($field['choices']) { + $field['choices'] = explode("\n", $field['choices']); + } + if($field['formtype'] == 'text' || $field['formtype'] == 'textarea') { + $value = getstr($value); + if($field['size'] && strlen($value) > $field['size']) { + return false; + } else { + $field['validate'] = !empty($field['validate']) ? $field['validate'] : ($_G['profilevalidate'][$fieldid] ? $_G['profilevalidate'][$fieldid] : ''); + if($field['validate'] && !preg_match($field['validate'], $value)) { + return false; + } + } + } elseif($field['formtype'] == 'checkbox' || $field['formtype'] == 'list') { + $arr = array(); + $value=explode('\n',$value); + foreach ($value as $op) { + if(in_array(trim($op), trim($field['choices']))) { + $arr[] = trim($op); + } + } + $value = implode("\n", $arr); + if($field['size'] && count($arr) > $field['size']) { + return false; + } + } elseif($field['formtype'] == 'radio' || $field['formtype'] == 'select') { + if(!in_array($value, $field['choices'])){ + return false; + } + } + return true; + +} +function getProfileForImport(){ + global $_G; + if(empty($_G['cache']['profilesetting'])) { + loadcache('profilesetting'); + } + $profilesetting=$_G['cache']['profilesetting']; + $ret=array(); + foreach($profilesetting as $key=> $value){ + if(in_array($key,array('department','realname','gender','birthyear','birthmonth','birthday','constellation','zodiac'))) continue; + elseif($value['formtype']=='file') continue; + elseif($value['formtype']=='select' || $value['formtype']=='radio'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'|',$value['choices']).')':'')*/; + }elseif( $value['formtype']=='checkbox'){ + $ret[$key]=$value['title']/*.($value['choices']?'('.preg_replace("/[\r\n]/i",'-',$value['choices']).')':'')*/; + }else{ + $ret[$key]=$value['title']; + } + } + return $ret; +} + +?> diff --git a/admin/orguser/index.php b/admin/orguser/index.php new file mode 100644 index 0000000..9907268 --- /dev/null +++ b/admin/orguser/index.php @@ -0,0 +1,30 @@ + fetch_orgids_by_uid($_G['uid']); + foreach ($orgids as $orgid) { + $arr = C::t('organization')->fetch_parent_by_orgid($orgid, true); + $count = count($arr); + if ($orgtree[$arr[$count - 1]]) { + if (count($orgtree[$arr[$count - 1]]) > $count) + $orgtree[$arr[count($arr) - 1]] = $arr; + } else { + $orgtree[$arr[$count - 1]] = $arr; + } + } +} +$orgtree = json_encode($orgtree); +include template('main'); +?> diff --git a/admin/orguser/language/en-US/lang.php b/admin/orguser/language/en-US/lang.php new file mode 100644 index 0000000..25cf9d6 --- /dev/null +++ b/admin/orguser/language/en-US/lang.php @@ -0,0 +1,164 @@ + 'Institutional users', + 'explorer_gropuperm'=>array( + 'Collaborative member ', + 'Administrator ', + 'The Founder' + ), + 'orgname'=>' Organization name', + 'orgname_placeholder'=>' Enter the institution name ', + 'change' => 'change', + 'org_description' => 'introduction', + 'org_description_placeholder'=>' Enter brief description of institutions ', + 'org_space_assign'=>' assign space size ', + 'org_space_assign_tip'=>' maximum available space that can be allocated ', + 'org_space_assign_tips'=>'
  • Unit m, left blank or 0 means no limit, - 1 means no space
  • limit the amount of space that can be used by the whole organization or department (including all subordinate departments) (the total amount of space used by all departments under the organization cannot exceed this limit)
  • the space allocated by a department can only be divided from the available space of the superior department; Once allocated, the remaining space of the superior department will be reduced accordingly, regardless of whether the allocated space is actually used up
  • ', + 'space_use_department'=>' department space usage ', + 'space_use_org'=>' total organization space usage ', + 'space_use_org_tips'=>'
  • Limit the space available to the entire organization or department (including all subordinate departments).
  • the space allocated by subordinate departments will be allocated from the available space of superior departments
  • ', + 'org_update_success'=>' Update data successfully, will jump for you in 3 seconds ', + 'org_img_uploaded_tip'=>' The image has been uploaded, just check it ', + 'clicktoupload'=>' clicktoupload', + // admin/orguser/tree.html + 'orguser_tree_delete'=>' Are you sure you want to delete this user completely (all of the user’s data and files will be completely deleted)? ', + 'orguser_tree_permission_delete'=>' Delete this user, only remove this user from the department, you may not have permission to operate this user after removal, are you sure you want to remove this user? ', + 'orguser_tree_batch_delete'=>' Organizations or departments do not support batch deletion ', + 'orguser_tree_all_delete'=>' Before deleting a department, you must delete all subordinate departments of this department and delete files in the shared directory. Are you sure you want to delete this department? ', + // admin/orguser/ajax.php + 'orguser_ajax_delete'=>' The user in the organization or department cannot be completely deleted, please delete from the organization or department first and try again ', + 'no_parallelism_jurisdiction'=>' no jurisdiction of the corresponding department ', + // admin/orguser/edituser.php + 'orguser_edituser_add_user'=>'
    sorry! You do not have permission to add users under this organization or department

    you can select the Department with permission on the left, and then try to add
    ', + 'orguser_edituser_add_user1'=>'
    sorry! You do not have administrative rights for this user

    you can select the user with permission management on the left side, and then retry adding
    ', + // admin/orguser/import.php + 'orguser_import_user'=>' No permission, only system administrators can import users ', + 'orguser_import_user_table'=>' Staff information table upload failed, please re-upload ', + 'orguser_import_xls_xlsx'=>' only XLS, XLSX files can be imported ', + 'orguser_import_user_message'=>' Staff information table uploaded successfully, going to import page ', + 'orguser_import_tautology'=>' Failed to upload info table, please try again later ', + 'orguser_import_user_message_table'=>' Please select the Personnel information table', + // admin/orguser/vidw.php + 'orguser_vidw_delete'=>'
    i’m sorry! You don’t have the administrative authority of this department!

    You can select the Department with permission management on the left
    ', + // admin/orguser/detail_org.html + 'export_excl'=>' Export all users of this department to an excL file ', + 'detail_org_no_enable'=>' If not enabled, all subordinate departments will not be able to use the shared directory; The shared directory is displayed on the enterprise disk only after this function is enabled. ', + 'detail_org_explorerapp_enable'=>' When enabled, the organization or department directory can be used in applications such as web disk. ', + 'detail_org_enable'=>' The shared directory of this department will be displayed in the enterprise disk organization only after the "detail_org_enable" function is enabled. ', + 'detail_org_creation'=>' When the detail_org_creation shortcut is created, the member desktop will have the shortcut by default. ', + 'group_org_no_enable'=>' After this function is enabled, Resource Manager will display the organization group option. ', + 'group_org_enable'=>' If not enabled, resource Manager will not display the organization group option. ', + 'detail_org_administrator'=>' Note: +
  • Authority of institution administrator: set administrators of all departments under the institution, manage all personnel in the institution, and manage all shared directories of the institution
  • +
  • Department Administrator permissions: set administrators of all sub departments under the Department, manage all personnel in the Department, and manage all shared directories of the Department
  • ', + 'Select organization to set organization information'=>' Select organization to set organization information', + 'Select department to set department information'=>' Select department to set department information', + 'Select personnel to set personnel information'=>' Select personnel to set personnel information', + 'Personnel, departments and institutions can directly drag and move to change positions. Move refers to changing the Department to which the person belongs, and Changing the superior organization or department of the department.'=>' People, departments, and organizations can be dragged and moved to change positions. The movement is to change the department of the personnel, and change the superior organization or superior department of the department. ', + 'Hold' => 'Hold', + 'Key to move personnel or departments to copy. It is used to join personnel to multiple departments at the same time.'=>'Key to move people or departments for replication. Add people to multiple departments at the same time.', + 'Key can be used for multiple selections, and release after multiple selections'=>'Key can be multi - selected, multi - selected after release', + 'Key movement is batch movement. Do not loosen'=>' Key to move for batch Loosen. Don’t loosen ', + 'Right click departments, institutions and personnel to open the right-click menu. There are corresponding more operations in the Menu.'=>' Right-click the department, organization, or personnel to display the right-click menu. There are more operations in the menu. ', + 'Delete user description'=>' Delete user description', + 'Deleting users from all institutions or departments is only removing users from their own institutions or departments. Users can no longer have all the use rights of their own institutions or departments. It is not deleting users from the system.'=>'If a user is deleted from an organization or department, the user cannot have all the permission to use the organization or department. This does not mean the user is deleted from the system.', + 'When the system administrator deletes the user from the "list of non institutional users", the user will be completely deleted in the system, and all system data and saved files of the user will be deleted. Please use it cautiously by the administrator, and delete it after confirming that the member is to be deleted.'=>'If the system administrator deletes a user from the User List, the user will be completely deleted from the system, and all system data and saved files of the user will be deleted. Use caution before deleting a member.', + 'Key to move to batch copy.'=>' Key to move to batch copy. ', + 'Organization management instructions'=>' Organization Management instructions', + 'inport_guide_download'=>' Download the person information import template ', + 'inport_guide_template'=>' template items will be automatically generated based on the number of user profile items ', + 'inport_guide_user.'=>' Edit the required personnel information table according to the template. ', + 'inport_guide_step'=>' Step 3: Select Excel ', + 'inport_guide_layout'=>' Select the edited staff layout, support. XLS,. XLSX format ', + 'inport_guide_notice'=>' Edit staff information sheet notes ', + 'inport_guide_notice_text'=>'
  • 1. Edit the personnel information to be imported according to the template fields. If there is already a file information table, you only need to change the name of the relevant field in the existing file information table to be consistent with the name provided in the template. As long as the name corresponds, the position of the field does not affect the result
  • +
  • 2. The "user name" field in the template is required, and other fields can be filled in as required
  • +
  • 3. The information in the mailbox and user name fields in the table must be unique and cannot be duplicate. If the mailbox is empty, the system will randomly generate the mailbox address when importing
  • +
  • 4. Multi level department creation: Method 1: add multiple columns of "subordinate departments" to the table. From left to right, they are level-1 departments, level-2 departments and level-3 departments. The system will create departments, subordinate departments and lower subordinate departments according to the principle from left to right. Method 2: use a single column in the table, and the superior and subordinate departments use "/" to divide (for example, primary school / grade 1 / class 1)
  • +
  • 5. Importing users can only import by organization. Multiple organizations need to be imported in batches
  • +
  • 6. The "login password" field in the table can be blank, and administrators can set unified passwords for users in batches when importing. The user can modify the unified password after logging in
  • +
  • 7. There are two import methods in the import interface: incremental and overwrite. Incremental method: when encountering the same user, only the missing field information of the user will be added, and the original information will not change. (for example, there is a user a in the system with a password of 123. In the batch import table, there is also a user a, whose unified password is set to ABC when importing. After importing, the passwords of other users are all ABC, and the original user a still keeps his original password, 123.) Overwrite import: completely replace the original user information in the system with the information in the table
  • +
  • 8. If there are many people to import, it is recommended to make a test table for a small number of people first, and then import all users in an incremental way after the test is correct
  • ', + 'import_list_organization'=>' select the organization to import. If no organization is imported, a new organization and department will be generated according to the Department in the user information table. If no organization is imported, it will be directly imported to "personnel without organization ', + 'import_list_password'=>' default user password. When the login password item is not set, the password set here will be used as the password of the newly imported user ', + 'import_list_coverage'=>' incremental import method: the newly imported user information is intelligently added to the original user information; Overwrite import: the newly imported information overwrites the information of the original user. It is recommended to use the incremental method. ', + 'import_list_text'=>'
  • User name and mailbox items are required
  • +
  • Click the content of the import item below to edit it temporarily. When editing a department, please note that each line of the Department is a parent-child relationship, and the previous line is the parent department of the next line
  • +
  • Items that do not need to be imported can be deleted by clicking "X" on the right
  • +
  • Click the import button to import the current project. Click the import all button to import all items in sequence. You can click stop again in the middle
  • ', + // admin/member/adduser.html + 'adduser_login_email_text'=>' This parameter is mandatory. It can be used for system login. When employees pay attention to the enterprise ID, the enterprise ID will be matched according to the email address. ', + 'adduser_compellation_text'=>' Required, displayed in system, easy to identify ', + 'adduser_phone_number_text'=>' Set this parameter to the mobile phone number bound to wechat. When an employee pays attention to the enterprise number, it will be matched according to the mobile phone bound to wechat. ', + 'adduser_weixin_text'=>' indicates the employee’s wechat ID. When an employee follows the enterprise ID, it will match according to the employee’s wechat ID. ', + 'adduser_exceptional_space_text'=>' Unit M, additional user storage space (total user space=default space + extra space) ', + 'adduser_disable_user_text'=>' After the user is disabled, the user cannot log in to the system. Perform this operation with caution ', + 'adduser_usergroup_text'=>' After you set the user as the system administrator, this user will have the system management rights. Please be cautious! ', + // admin/member/edituser.html + 'edituser_login_email_text'=>' This parameter is optional and can be used for system login. When employees pay attention to the enterprise number, it will be matched according to the employee’s email address. ', + 'edituser_weixin_text'=>' Select, employee’s wechat ID. When employees follow enterprise ID, it will be matched according to the employee’s wechat ID. If you have paid attention to it, this item cannot be modified. ', + 'supervisor_position'=>' supervisor position', + 'send_password_user_mailbox'=>' Send password to mailbox', + 'login_email_required'=>' Required for login ', + 'name_will'=>' username required ', + 'none_write_login_password'=>' No login password yet ', + 'none_write_affirm_password'=>' affirm_password has not been filled in ', + 'phone_number'=>' mobile phone number', + 'phone_number_illegal'=>' mobile phone number is illegal', + 'weixin_phone_number'=>' wechat bound mobile phone number', + 'weixin_illegal'=>' wechat illegal', + 'user_weixin'=>' employee weixin', + 'weixin_exist'=>' wechat already exists ', + 'random_password'=>' Generate random password', + 'exceptional_space'=>' extra space', + 'disable_user'=>' Disable this user', + 'block_up' => 'stop', + 'set_system_administrator'=>' Set as system administrator', + 'add_a_item'=>' add an item', + 'add_user'=>' Add user', + 'add_user_success'=>' User added successfully ', + 'edit_user_success'=>' Modify user information successfully ', + 'export_user'=>' Export user', + 'shared_directory_set'=>' shared directory setting ', + 'group_on_set'=>' Group function Settings ', + 'shared_directory_desktop_shortcut'=>' Shared directory desktop shortcut', + 'position_management'=>' position management', + 'add_position'=>' Add position', + 'position_name'=>' position name', + 'organization_department'=>' Organization Department', + 'share_enable_successful'=>' The shared directory is enabled successfully! ', + 'share_close_successful'=>' The shared directory is closed successfully! ', + 'group_on_successful'=>' The group function has been enabled successfully! ', + 'group_close_successful'=>' The group function is disabled successfully! ', + 'login_username_placeholder'=>' Login username ', + 'login_username_text'=>' required, available for system login ', + 'required_used_login_system'=>' required, available for system login ', + 'space_not_change_password'=>' Leave blank, do not change password', + 'export_range_user'=>' Select the export range, all users in this range will export ', + 'export_data'=>' Export data item ', + 'import_nbsp'=>'The import', + 'creation_agency'=>' New agency', + 'creation_bottom_section'=>' Create the bottom_section', + 'creation_equally_section'=>' New sibling department ', + 'please_select_same_type_node'=>' Please select a node of the same type ', + 'please_select_same_section_node'=>' Please select a node in the same department ', + 'add_administrator_unsuccess'=>' Failed to add administrator ', + 'no_open_Shared_directory'=>' cannot be set because the shared directory is not enabled ', + 'please_select_range_export'=>' Please select the export scope ', + 'please_select_project_export'=>' Please select export project ', + 'user_information_table'=>' Person information table', + 'bulk_import_user_template'=>' Import user templates in batches ', + 'name_email_empty'=>' Username and mailbox cannot be empty', + 'lack_required_fields_name'=>' lacks the required field "user name"', + 'lack_required_fields_name_email'=>'The required field user name or mailbox is missing', + 'bulking' => 'delta', + 'coverage' => 'cover', + 'user_phone_illegal'=>' User’s phone number is illegal', + 'user_phone_exist'=>' The phone number already exists ', + 'user_phone_registered'=>' User phone number has been registered', + 'weixin_registered'=>' the wechat signal has been registered', + 'user_registered_retry'=>' The user name has been registered, please change the user name and try again ', + 'email_registered_retry'=>' The mailbox has been registered, please change the mailbox and try again ', + 'import_user'=>' import user', +); +?> \ No newline at end of file diff --git a/admin/orguser/language/zh-cn/lang.php b/admin/orguser/language/zh-cn/lang.php new file mode 100644 index 0000000..2845504 --- /dev/null +++ b/admin/orguser/language/zh-cn/lang.php @@ -0,0 +1,164 @@ + '机构用户', + 'explorer_gropuperm'=>array( + '协作成员', + '管理员', + '创始人' + ), + 'orgname'=>'机构名称', + 'orgname_placeholder'=>'输入机构(群组)名称', + 'change'=>'更换', + 'org_description'=>'简介', + 'org_description_placeholder'=>'输入机构(群组)简要介绍', + 'org_space_assign'=>'分配空间大小', + 'org_space_assign_tip'=>'当前可以分配的最大可用空间', + 'org_space_assign_tips'=>'
  • 单位M,留空或者0表示不限制,-1表示无空间
  • 限制整个机构或部门(包括下级所有部门)可以使用的空间大小(机构下所有部门的空间使用总和不能超过这个限制)
  • 部门分配的空间只能从上级部门的可用空间里面划分;一旦分配,上级部门的剩余空间就会相应减少,不管这些分配的空间是否实际使用完
  • ', + 'space_use_department'=>'部门空间使用', + 'space_use_org'=>'机构总空间使用', + 'space_use_org_tips'=>'
  • 限制整个机构或部门(包括下级所有部门)可以使用的空间大小
  • 下级部门分配的空间会从上级的可用空间里面分配
  • ', + 'org_update_success'=>'更新资料成功,3秒后将为您跳转', + 'org_img_uploaded_tip'=>'该图片已经上传过了,只需勾选即可', + 'clicktoupload'=>'点击上传', + // admin/orguser/detail_org.html + 'export_excl'=>'导出此部门的所有用户到excl文件', + 'detail_org_no_enable'=>'如不启用,下级所有部门中将不能使用共享目录;启用后,企业盘才会显示共享目录。', + 'detail_org_explorerapp_enable'=>'开启后,可在网盘等应用中能够使用该机构或部门的目录。', + 'detail_org_enable'=>'启用后,企业盘机构下才会显示此部门的共享目录。', + 'detail_org_creation'=>'创建快捷方式后,所属成员桌面默认都会有相应快捷方式。', + 'group_org_no_enable'=>'开启后,资源管理器会显示该机构群组选项。', + 'group_org_enable'=>'不开启,资源管理器不会显示该机构群组选项。', + 'detail_org_administrator'=>'注: +
  • 机构管理员权限:设置本机构下所有部门管理员,管理本机构中所有人员,管理本机构所有共享目录。
  • +
  • 部门管理员权限:设置本部门下所有子部门管理员,管理本部门中所有人员,管理本部门所有共享目录。
  • ', + 'Select organization to set organization information'=>'选中机构为设置机构信息', + 'Select department to set department information'=>'选中部门为设置部门信息', + 'Select personnel to set personnel information'=>'选中人员为设置人员信息', + 'Personnel, departments and institutions can directly drag and move to change positions. Move refers to changing the Department to which the person belongs, and changing the superior organization or department of the Department.'=>'人员、部门、机构可直接拖拽移动更换位置。移动是更换人员所属部门、和更换部门上级机构或上级部门。', + 'Hold'=>'按住', + 'Key to move personnel or departments to copy. It is used to join personnel to multiple departments at the same time.'=>'键移动人员或部门为复制。用于将人员同时加入多个部门。', + 'Key can be used for multiple selections, and release after multiple selections'=>'键可多选,多选后松开', + 'Key movement is batch movement. Do not loosen'=>'键移动为批量移动。 不松开', + 'Right click departments, institutions and personnel to open the right-click menu. There are corresponding more operations in the menu.'=>'在部门、机构、人员上点鼠标右键可出现右键菜单。菜单中有对应的更多操作。', + 'Delete user description'=>'删除用户说明', + 'Deleting users from all institutions or departments is only removing users from their own institutions or departments. Users can no longer have all the use rights of their own institutions or departments. It is not deleting users from the system.'=>'所有机构、部门中删除用户,只是从本机构,或部门中移除,用户将不能再拥有本机构或部门的所有使用权限,不是将用户从系统中删除。', + 'When the system administrator deletes the user from the "list of non institutional users", the user will be completely deleted in the system, and all system data and saved files of the user will be deleted. Please use it cautiously by the administrator, and delete it after confirming that the member is to be deleted.'=>'系统管理员在“未加入机构用户列表”中删除用户,用户会在系统中彻底删除,并且删除用户所有系统数据及保存文件。请管理员谨慎使用,确定成员要删除后再删除。', + 'Key to move to batch copy.'=>'键移动为批量复制。', + 'Organization management instructions'=>'组织管理说明', + 'inport_guide_download'=>'下载人员信息导入模板', + 'inport_guide_template'=>'模板的项目会根据用户资料项的多少自动生成', + 'inport_guide_user.'=>'根据模板编辑需要人员信息表。', + 'inport_guide_step'=>'步骤3:选择excel表', + 'inport_guide_layout'=>'选择编辑好的人员信息表,支持 .xls、.xlsx格式', + 'inport_guide_notice'=>'编辑人员信息表注意事项', + 'inport_guide_notice_text'=>'
  • 1、根据模板字段来编辑需要导入的人员信息,如果已经有档案信息表,则只需将现有的档案信息表中的相关字段名称改为与“模板”里提供的名称一致即可,只要名称对应,字段的位置不影响结果。
  • +
  • 2、模板中“用户名”字段必填,其他字段根据需要填写。
  • +
  • 3、表中“邮箱”、“用户名”字段中的信息必须是唯一的,不可重复。如果邮箱为空,系统导入时将随机生成邮箱地址。
  • +
  • 4、多级部门创建:方法1:表中添加多列“所属部门”,从左到右分别为一级部门、二级部门、三级部门,顺序排列,系统会根据从左到右的原则,依次创建部门、下级部门、下下级部门等。方法2:表格中使用单列,上下级部门使用“/”来分割(例如:小学/一年级/一班)。
  • +
  • 5、导入用户只能按机构导入,多个机构需要分批导入。
  • +
  • 6、表中“登录密码”字段可为空,管理员在导入时能够为用户批量设置统一的密码。用户使用统一密码登录后可自行修改。
  • +
  • 7、导入界面中有“增量”、“覆盖”两种导入方式。增量方式为:遇到相同用户,只会增加用户缺少的字段信息,原有信息不变。(例如:系统中已有用户A,密码为123。在批量导入表格中,也有用户A,导入时设置了统一密码为abc。导入完成后,其他用户的密码都为abc,原用户A还是保持他的原有密码,即123。)覆盖导入:将系统中原有的用户信息完全替换为表格中的信息。
  • +
  • 8、若需导入的人员较多,建议先做一个少量人员的测试表,测试无误后,再使用增量方式导入所有用户。
  • ', + 'import_list_organization'=>'选择要导入到的机构,如果不导入任何机构,会根据用户信息表中的所属部门来生成新的机构和部门,没有则会直接导入到"无机构人员"下', + 'import_list_password'=>'默认用户密码,当登录密码项未设置时,会使用此处设置的密码作为新导入的用户的密码', + 'import_list_coverage'=>'增量导入方式:新导入的用户信息智能的增加到原有用户信息中;覆盖导入:新导入的信息覆盖原有用户的信息,建议使用增量方式。', + 'import_list_text'=>'
  • 用户名和邮箱项目为必填项
  • +
  • 点击下面的导入项的内容,可以临时编辑,编辑部门时注意,部门每行是上下级的关系,上一行为下一行的上级部门
  • +
  • 不需要导入的项目,可以点击右侧的"X"删除掉
  • +
  • 点击导入按钮,导入当前项目,全部导入按钮,按顺序导入所有项,中途可以再次点击停止
  • ', + // admin/orguser/tree.html + 'orguser_tree_delete'=>'您确定要彻底删除此用户(用户的所有数据和文件都会彻底删除)吗?', + 'orguser_tree_permission_delete'=>'此处删除,仅从部门中移除此用户,移除后您可能没有操作此用户的权限,您确定要移除此用户吗?', + 'orguser_tree_batch_delete'=>'机构或部门不支持批量删除', + 'orguser_tree_all_delete'=>'删除部门前,必须先删除此部门的所有下级部门,并且删除共享目录中的文件,您确定要删除此部门吗?', + // admin/orguser/ajax.php + 'orguser_ajax_delete'=>'在机构或部门中的用户,不支持彻底删除,请先从机构或部门中删除后重试', + 'no_parallelism_jurisdiction'=>'没有对应部门的权限', + // admin/orguser/edituser.php + 'orguser_edituser_add_user'=>'
    抱歉!您没有在此机构或部门下添加用户的权限!

    可以在左侧选择有权限的部门,再重试添加
    ', + 'orguser_edituser_add_user1'=>'
    抱歉!您没有此用户的管理权限!

    可以在左侧选择有权限管理的用户,再重试添加
    ', + // admin/orguser/import.php + 'orguser_import_user'=>'没有权限,只有系统管理员才能导入用户', + 'orguser_import_user_table'=>'人员信息表上传未成功,请重新上传', + 'orguser_import_xls_xlsx'=>'只允许导入xls,xlsx类型的文件', + 'orguser_import_user_message'=>'人员信息表上传成功,正在调转到导入页面', + 'orguser_import_tautology'=>'上传信息表未成功,请稍候重试', + 'orguser_import_user_message_table'=>'请选择人员信息表', + // admin/orguser/vidw.php + 'orguser_vidw_delete'=>'
    抱歉!您没有此部门的管理权限!

    可以在左侧选择有权限管理的部门
    ', + // admin/member/adduser.html + 'adduser_login_email_text'=>'必填,可用于系统登录,员工关注企业号时,会根据邮箱来匹配。', + 'adduser_compellation_text'=>'必填,系统中显示,便于同事辨识', + 'adduser_phone_number_text'=>'选填,微信绑定的手机号码,员工关注企业号时,会根据员工微信绑定的手机来匹配。', + 'adduser_weixin_text'=>'选填,员工微信号,员工关注企业号时,会根据员工的微信号来匹配。', + 'adduser_exceptional_space_text'=>'单位M,额外增加用户存储空间(用户的总空间=默认空间+额外空间)', + 'adduser_disable_user_text'=>'用户停用后,该用户将不能登录系统,请谨慎操作', + 'adduser_usergroup_text'=>'设置用户为系统管理员后,此用户将拥有系统管理权限,请慎重!', + // admin/member/edituser.html + 'edituser_login_email_text'=>'选填,可用于系统登录,员工关注企业号时,会根据员工的邮箱来匹配。', + 'edituser_weixin_text'=>'选填,员工微信号,员工关注企业号时,会根据员工的微信号来匹配。如果已经关注,此项不能修改。', + 'supervisor_position'=>'上司职位', + 'send_password_user_mailbox'=>'发送密码到用户邮箱', + 'login_email_required'=>'登录邮箱必填', + 'name_will'=>'用户名必填', + 'none_write_login_password'=>'还没有填写登录密码', + 'none_write_affirm_password'=>'还没有填写确认密码', + 'phone_number'=>'手机号码', + 'phone_number_illegal'=>'手机号码不合法', + 'weixin_phone_number'=>'微信绑定的手机号码', + 'weixin_illegal'=>'微信号不合法', + 'user_weixin'=>'员工微信号', + 'weixin_exist'=>'微信号已经存在', + 'random_password'=>'生成随机密码', + 'exceptional_space'=>'额外空间', + 'disable_user'=>'停用此用户', + 'block_up'=>'停用', + 'set_system_administrator'=>'设为系统管理员', + 'add_a_item'=>'增加一项', + 'add_user'=>'添加用户', + 'add_user_success'=>'添加用户成功', + 'edit_user_success'=>'修改用户信息成功', + 'email_registered_retry'=>'邮箱已经被注册,请更换邮箱再试', + 'export_user'=>'导出用户', + 'shared_directory_set'=>'共享目录设置', + 'group_on_set'=>'群组功能设置', + 'shared_directory_desktop_shortcut'=>'共享目录桌面快捷方式', + 'position_management'=>'职位管理', + 'add_position'=>'添加职位', + 'position_name'=>'职位名称', + 'organization_department'=>'机构部门', + 'share_enable_successful'=>'共享目录启用成功!', + 'share_close_successful'=>'共享目录关闭成功!', + 'group_on_successful'=>'群组功能开启成功!', + 'group_close_successful'=>'群组功能关闭成功!', + 'login_username_placeholder'=>'登录用户名', + 'login_username_text'=>'必填,可用于系统登录', + 'required_used_login_system'=>'必填,可用于系统登录', + 'space_not_change_password'=>'留空,不修改密码', + 'export_range_user'=>'选择导出范围,此范围内的所有用户都会导出', + 'export_data'=>'导出资料项', + 'import_nbsp'=>'导 入', + 'creation_agency'=>'新建机构', + 'creation_bottom_section'=>'新建下级部门', + 'creation_equally_section'=>'新建同级部门', + 'please_select_same_type_node'=>'请选择相同类型的节点', + 'please_select_same_section_node'=>'请选择相同部门的节点', + 'add_administrator_unsuccess'=>'添加管理员失败', + 'no_open_Shared_directory'=>'没有开启共享目录,无法设置', + 'please_select_range_export'=>'请选择导出范围', + 'please_select_project_export'=>'请选择导出项目', + 'user_information_table'=>'人员信息表', + 'bulk_import_user_template'=>'批量导入用户模板', + 'name_email_empty'=>'用户名和邮箱不能为空', + 'lack_required_fields_name'=>'缺少必填字段"用户名"', + 'lack_required_fields_name_email'=>'缺少必填字段”用户名“或”邮箱“', + 'bulking'=>'增量', + 'coverage'=>'覆盖', + 'user_phone_illegal'=>'用户手机号码不合法', + 'user_phone_exist'=>'手机号码已经存在', + 'user_phone_registered'=>'用户手机号码已经被注册', + 'weixin_registered'=>'该微信号已经被注册', + 'user_registered_retry'=>'该用户名已经被注册,请更换用户名再试', + 'import_user'=>'导入用户', +); +?> \ No newline at end of file diff --git a/admin/orguser/scripts/orguser.js b/admin/orguser/scripts/orguser.js new file mode 100644 index 0000000..ab0ea07 --- /dev/null +++ b/admin/orguser/scripts/orguser.js @@ -0,0 +1,539 @@ +/* + * @copyright Leyun internet Technology(Shanghai)Co.,Ltd + * @license http://www.dzzoffice.com/licenses/license.txt + * @package DzzOffice + * @link http://www.dzzoffice.com + * @author zyx(zyx@dzz.cc) + */ +function checkAdminLogin(str){ + if(str.match(/id=\"loginform\"/i)){ + return true; + }else{ + return false; + } +} +function show_guide(){ + jQuery('#orguser_container').load(ajaxurl+'do=guide',function(){ + location.hash=''; + }); +} +function delDepart(obj){ + jQuery(obj).parent().parent().remove(); +} +var tpml_index=0; +function addorgsel(){ + jQuery('#selorg_container').append(' '); + tpml_index++; +} + +function selJob(obj){ + var jobid=jQuery(obj).attr('_jobid'); + var li=jQuery(obj).parent().parent().parent(); + var html=obj.innerHTML; + li.find('.dropdown-toggle').attr('_jobid',jobid).find('span').html(html); + li.find('input').val(jobid); +} +function selDepart(obj){ + var orgid=jQuery(obj).val(); + var li=jQuery(obj).parent(); + li.parent().find('.job .dropdown-menu').load(ajaxurl+'do=getjobs&orgid='+orgid,function(html){ + if(checkAdminLogin(html)){ + location.reload(); + } + if(li.parent().find('.job .dropdown-menu li').length>1) li.parent().find('.job .dropdown-toggle').trigger('click'); + }); + li.parent().find('.job .dropdown-toggle').attr('_jobid',0).find('span').html(__lang.none); + li.parent().find('.job input').val('0'); +} +function errormessage(id, msg,passlevel) { + if(jQuery('#'+id).length > 0) { + msg = !msg ? '' : msg; + if(msg == 'succeed') { + msg = ''; + jQuery('#suc_' + id).addClass('p_right'); + } else if(msg !== '') { + jQuery('#suc_' + id).removeClass('p_right'); + } + jQuery('#chk_' + id).find('kbd').html(msg); + if(msg && !passlevel) jQuery('#'+id).parent().parent().addClass('has-warning'); + else jQuery('#'+id).parent().parent().removeClass('has-warning'); + } +} + +function checkemail(id) { + errormessage(id); + var email = trim(jQuery('#'+id).val()); + email=email.toLowerCase(); + if(jQuery('#'+id).parent()[0].className.match(/ p_right/) && (email == '' || email == lastemail ) || email == lastemail) { + return; + } + if(email.match(/<|"/ig)) { + errormessage(id, __lang.Email_sensitivity); + return; + } + + var x = new Ajax(); + jQuery('#suc_' + id).removeClass('p_right'); + jQuery.getJSON('user.php?mod=ajax&inajax=yes&infloat=register&handlekey=register&ajaxmenu=1&action=checkemail&email=' + email, function(json) { + if(json.error){ + errormessage(id, json.error); + }else{ + errormessage(id, 'succeed'); + } + + }); +} +function checknick(id) { + errormessage(id); + var username = trim(jQuery('#'+id).val()); + if(jQuery('#chk_' + id).parent()[0].className.match(/ p_right/) && (username == '' || username == lastusername) || username == lastusername) { + return; + } + if(username.match(/<|"/ig)) { + errormessage(id, __lang.profile_nickname_illegal); + return; + } + if(username){ + var unlen = username.replace(/[^\x00-\xff]/g, "**").length; + if(unlen < 3 || unlen > 30) { + errormessage(id, unlen < 3 ? __lang.username_character : __lang.username_character); + return; + } + var x = new Ajax(); + jQuery('#suc_' + id).removeClass('p_right'); + jQuery.getJSON('user.php?mod=ajax&inajax=yes&infloat=register&handlekey=register&ajaxmenu=1&action=checkusername&username=' + encodeURI(username), function(json) { + if(json.error){ + errormessage(id, json.error); + }else{ + errormessage(id, 'succeed'); + } + }); + } +} +function checkPwdComplexity(firstObj, secondObj, modify) { + modifypwd = modify || false; + firstObj.onblur = function () { + if(firstObj.value == '') { + var pwmsg = !modifypwd ? __lang.register_password_tips : __lang.js_change_password; + if(pwlength > 0) { + pwmsg += ', '+__lang.register_password_length_tips1+pwlength+__lang.register_password_length_tips2; + } + if(!modifypwd) errormessage(firstObj.id, pwmsg); + }else{ + errormessage(firstObj.id, !modifypwd ? 'succeed' : __lang.js_change_password); + } + checkpassword(firstObj.id, secondObj.id); + }; + firstObj.onkeyup = function () { + if(pwlength == 0 || jQuery('#'+firstObj.id).value.length >= pwlength) { + var passlevels = new Array('',__lang.weak,__lang.center,__lang.strong); + var passlevel = checkstrongpw(firstObj.id); + + errormessage(firstObj.id, ''+__lang.intension+':'+passlevels[passlevel]+'','passlevel'); + } + }; + secondObj.onblur = function () { + if(secondObj.value == '') { + if(!modifypwd) errormessage(secondObj.id, !modifypwd ?'succeed' : __lang.register_repassword_tips); + } + checkpassword(firstObj.id, secondObj.id); + }; +} +function checkstrongpw(id) { + var passlevel = 0; + var el=document.getElementById(id); + var val=el.value; + if(val && val.match(/\d+/g)) { + passlevel ++; + } + if(val && val.match(/[a-z]+/ig)) { + passlevel ++; + } + if(val && val.match(/[^a-z0-9]+/ig)) { + passlevel ++; + } + return passlevel; +} +function checkpassword(id1, id2) { + if(!document.getElementById(id1).value && !document.getElementById(id2).value) { + //return; + } + if(pwlength > 0) { + if(document.getElementById(id1).value.length < pwlength) { + errormessage(id1, __lang.password_too_short+pwlength+__lang.register_password_length_tips2); + return; + } + } + if(strongpw) { + var strongpw_error = false, j = 0; + var strongpw_str = new Array(); + for(var i in strongpw) { + if(strongpw[i] === 1 && !document.getElementById(id1).value.match(/\d+/g)) { + strongpw_error = true; + strongpw_str[j] = __lang.strongpw_1; + j++; + } + if(strongpw[i] === 2 && !document.getElementById(id1).value.match(/[a-z]+/g)) { + strongpw_error = true; + strongpw_str[j] = __lang.strongpw_2; + j++; + } + if(strongpw[i] === 3 && !document.getElementById(id1).value.match(/[A-Z]+/g)) { + strongpw_error = true; + strongpw_str[j] = __lang.strongpw_3; + j++; + } + if(strongpw[i] === 4 && !document.getElementById(id1).value.match(/[^A-Za-z0-9]+/g)) { + strongpw_error = true; + strongpw_str[j] = __lang.strongpw_4; + j++; + } + } + if(strongpw_error) { + errormessage(id1, __lang.password_weak+strongpw_str.join(',')); + return; + } + } + errormessage(id2); + if(document.getElementById(id1).value !=document.getElementById(id2).value) { + errormessage(id2, __lang.profile_passwd_notmatch); + } else { + if(modifypwd) errormessage(id1, 'succeed' ); + errormessage(id2, 'succeed' ); + + } +} +function jstree_search(val){ + console.log(val); + if(val=='stop'){ + jQuery('#jstree_search_input').val(''); + jQuery('#searchval').val(''); + jQuery('.classtree-search').slideUp(500); + jQuery("#classtree").jstree(true).search(); + }else{ + if(val==''){ + jQuery('#jstree_search_input').val(''); + jQuery('#searchval').val(''); + jQuery('.classtree-search').slideUp(500); + } + jQuery("#classtree").jstree(true).search(val); + } +} +function jstree_create_organization(){ + var inst = jQuery("#classtree").jstree(true); + jQuery.post(ajaxurl+'do=create',{'forgid':0,'t':new Date().getTime()},function(json){ + if(!json || json.error){ + showmessage(json.error,'danger',3000,1); + }else if(json.orgid>0){ + var arr={"id":json.orgid,"text":json.orgname,"type":"organization","icon":'dzz/system/images/organization.png'} + inst.create_node(inst.get_node('#'), arr, "first", function (new_node) { + setTimeout(function () { inst.edit(new_node); },0); + }); + } + },'json'); +} +function jstree_create_dir(){ + var inst = jQuery("#classtree").jstree(true),obj; + if(inst.get_selected(true).length>0){ + obj=inst.get_selected(true); + obj=obj[0]; + }else{ + showmessage(__lang.please_select_one_organization_department,'danger',1000,1); + return; + } + if(obj.type=='user'){ + showmessage(__lang.please_select_one_organization_department,'danger',1000,1); + return true; + } + if(inst.is_disabled(obj)){ + return true; + } + var inst = jQuery("#classtree").jstree(true); + jQuery.post(ajaxurl+'do=create',{'forgid':obj.id,'t':new Date().getTime()},function(json){ + if(!json || json.error){ + showmessage(json.error,'danger',3000,1); + }else if(json.orgid>0){ + var arr={"id":json.orgid,"text":json.orgname,"type":"organization","icon":(json.forgid>0)?'dzz/system/images/department.png':'dzz/system/images/organization.png'} + inst.create_node(obj, arr, "first", function (new_node) { + setTimeout(function () { inst.edit(new_node); },0); + }); + } + },'json'); + +} +function jstree_create_user(flag){ + var inst = jQuery("#classtree").jstree(true),obj; + if(inst.get_selected(true).length>0){ + obj=inst.get_selected(true); + obj=obj[0]; + }else{ + if(flag) flag=0; + obj=inst.get_node('#'); + } + if(obj.type=='user'){ + obj=inst.get_node(obj.parent); + } + if(inst.is_disabled(obj)){ + return true; + } + showDetail(0,'user',null,obj.id); +} + +function showDetail(id,idtype,ajaxdo,orgid){ + var hash=idtype+'_'+id; + var urladd='' + if(ajaxdo){ + hash+='_'+ajaxdo; + urladd+='&do='+ajaxdo + } + if(orgid){ + hash+='_'+orgid; + urladd+='&orgid='+orgid + } + currentHash=hash; + location.hash=hash; + //console..log(hash); + urladd+='&t='+new Date().getTime() + + jQuery('#orguser_container').load(baseurl+'op=view&id='+id+'&idtype='+idtype+urladd,function(html){ + if(checkAdminLogin(html)){ + location.reload(); + } + }); +} + +function open_node_dg(inst,node,arr){ //自动打开有权限的目录树 + inst.open_node(node,function(node){ + var i=jQuery.inArray(node.id,arr); + if(i-1 && document.getElementById(arr[i+1])) open_node_dg(inst,document.getElementById(arr[i+1]),arr); + else{ + // inst.select_node(node); + } + }); + } + +function job_show_editor(jobid,orgid,obj){ + var el=jQuery(obj).addClass('hide'); + el.parent().find('.edit').removeClass('hide'); + el.parent().find('input').focus(); + jQuery(document).on('click.job_edit_'+jobid,function(event){ + if(!jQuery(event.target).closest(el.parent()).length){ + job_save(jobid,orgid); + jQuery(document).off('click.job_edit_'+jobid); + } + }); +} + +function job_save(jobid,orgid){ + var el=jQuery('#job_'+jobid); + var oname=trim(el.find('.job-name').html()); + var name=trim(el.find('.job-edit-control input').val()); + if(oname==name){ + el.find('.job-name').removeClass('hide'); + el.find('.edit').addClass('hide'); + return; + } + jQuery.post(ajaxurl+'do=jobedit',{'name':name,'jobid':jobid,'orgid':orgid,'t':new Date().getTime()},function(json){ + if(json.error){ + el.find('.job-name').html(oname).removeClass('hide'); + el.find('.edit').addClass('hide'); + el.find('.job-edit-control input').val(oname); + }else if(json.jobid>0){ + el.find(' .job-name').html(json.name).removeClass('hide'); + el.find('.edit').addClass('hide'); + el.find('.job-edit-control input').val(json.name); + } + },'json'); +} +function job_show_add_editor(orgid,obj){ + var el=jQuery(obj); + el.addClass('hide'); + el.parent().find('.new-job-control').removeClass('hide'); + el.parent().find('.new-job-control input').focus(); + jQuery(document).on('click.new-job-'+orgid,function(event){ + if(!jQuery(event.target).closest(el.parent()).length){ + job_cancel_add_editor(orgid); + jQuery(document).off('click.new-job-'+orgid); + } + }); +} +function job_cancel_add_editor(orgid){ + var el=jQuery('.jobs .new-job'); + el.find('.new-job-control').addClass('hide'); + el.find('a').removeClass('hide'); + +} +function job_del(jobid,orgid){ + var el=jQuery('#job_'+jobid); + jQuery.post(ajaxurl+'do=jobdel',{'jobid':jobid,'orgid':orgid,'t':new Date().getTime()},function(json){ + if(json.error){ + showmessage(json.error,'danger',3000,1); + }else if(json.jobid>0){ + el.remove(); + } + },'json'); +} + +function job_add(orgid){ + var newjob=jQuery('.jobs .new-job'); + var name=newjob.find('.new-job-text').val(); + if(name==''){ + newtodo.find('.new-job-text').focus(); + return; + } + jQuery.post(ajaxurl+'do=jobadd',{'name':name,'orgid':orgid,'t':new Date().getTime()},function(json){ + + if(json.jobid>0){ + appendjob(json); + newjob.find('.new-job-text').val('').focus(); + }else{ + showmessage(json.error,'danger',3000,1); + } + },'json'); +} +function appendjob(json){ + var html=''; + html+='
    '; + html+=' '; + html+='
    '; + html+='
    '; + html+=' '; + html+='
    '; + html+=' '; + html+=' '; + html+='
    '; + html+='
    '; + jQuery('.jobs .new-job').before(html); +} +function callback_moderators(ids,data,orgid){ + console.log(ids);console.log(orgid); + //删除不在选择列表内的用户 + jQuery('.moderators-container .user-item').each(function(){ + var uid=jQuery(this).attr('uid'); + if(jQuery.inArray(uid,ids)===-1){ + jQuery(this).find('.delete').trigger('click'); + } + }); + for(var i=0;i '; + html+=' '; + html+='
    '; + html+='
    '; + html+='
    '; + html+=' '+json.avatar; + html+='
    '; + html+='
    '; + html+='

    '+json.username+'

    '; + html+=' '; + jQuery('#moderators_container_'+json.orgid+' .moderators-acceptor').after(html); + var inst = jQuery("#classtree").jstree(true); + + var node= inst.get_node('#'+json.orgid); + inst.refresh_node(node); +} +function moderator_del(id,orgid,obj){ + jQuery.post(ajaxurl+'do=moderator_del',{'orgid':orgid,'id':id,'t':new Date().getTime()},function(json){ + if(json.error) showmessage(json.error,'danger',3000,1); + else{ + jQuery(obj).parent().remove(); + } + + },'json'); +} + +function folder_available(available,orgid){ + jQuery.post(ajaxurl+'do=folder_available',{'orgid':orgid,'available':available,'t':new Date().getTime()},function(json){ + if(json.error){ + showmessage(json.error,'danger',3000,1); + }else{ + if(available){ + showmessage(__lang.share_enable_successful,'success',3000,1); + //jQuery('#indesk').show(); + }else{ + showmessage(__lang.share_close_successful,'success',3000,1); + //jQuery('#indesk').hide(); + } + } + },'json'); +} +function group_on(on,orgid){ + jQuery.post(ajaxurl+'do=group_on',{'orgid':orgid,'available':on,'t':new Date().getTime()},function(json){ + if(json.error){ + showmessage(json.error,'danger',3000,1); + }else{ + if(on){ + showmessage(__lang.group_on_successful,'success',3000,1); + }else{ + showmessage(__lang.group_close_successful,'success',3000,1); + } + } + },'json'); +} +function folder_indesk(indesk,orgid){ + jQuery.post(ajaxurl+'do=folder_indesk',{'orgid':orgid,'indesk':indesk,'t':new Date().getTime()},function(json){ + if(json.error) showmessage(json.error,'danger',3000,1); + },'json'); +} +function set_org_logo(orgid,aid){ + jQuery.post(ajaxurl+'do=set_org_logo',{'orgid':orgid,'aid':aid},function(json){ + if(json.error) showmessage(json.error,'danger',3000,1); + },'json'); +} +/*function set_org_bgphoto(orgid,aid){ + jQuery.post(ajaxurl+'&do=set_org_bgphoto',{'orgid':orgid,'aid':aid},function(json){ + if(json.error) showmessage(json.error,'danger',3000,1); + },'json'); +}*/ +function set_org_orgname(orgid,obj){ + var oldname=jQuery(obj).data('oldname'); + console.log(oldname); + jQuery.post(ajaxurl+'do=set_org_orgname',{'orgid':orgid,'orgname':obj.value},function(json){ + if(json.error){ + obj.value=oldname; + showmessage(json.error,'danger',3000,1); + }else{ + jQuery(obj).data('oldname',obj.value); + jQuery('#title_orgname').html(obj.value); + var node=jQuery("#classtree").jstree(true).get_node('#'+orgid); + jQuery("#classtree").jstree('refresh',node); + } + },'json'); +} +function set_org_desc(orgid,desc){ + jQuery.post(ajaxurl+'do=set_org_desc',{'orgid':orgid,'desc':desc},function(json){ + if(json.error){ + showmessage(json.error,'danger',3000,1); + } + },'json'); +} +function folder_maxspacesize(obj,orgid){ + jQuery.post(ajaxurl+'do=folder_maxspacesize',{'orgid':orgid,'maxspacesize':obj.value,'t':new Date().getTime()},function(json){ + if(json.error){ + obj.value=json.val; + showmessage(json.error,'danger',3000,1); + }else{ + jQuery('#'+orgid+' a.jstree-clicked').trigger('click'); + showmessage('空间大小设置成功','success',3000,1); + } + },'json'); +} diff --git a/admin/orguser/template.xlsx b/admin/orguser/template.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..4f464cf52274aa8d0a8e189245e9351e9563fda3 GIT binary patch literal 9918 zcmeHt1y>x~x@|+_!9BRUOCW*Z5ZqmYHr{xU;O_1o+@%Q?Bm@a=f#5-c27)%F>PHwhO>R$jeMQFn1<1Yqgp{)`4xX7eKM4zyA-k!mP!vtsJB*~&~mwhkJ zbtq}%v2nkREYb&14=Yz#L90;z?4p zo0l4fuv;y4m5XU*596tpeGL}H7`9lAHag<65q=`?Q8x#ZLT7|1?&i9f?se7t`fbNY zSEe__6S7a;#=WcI^z(F1VQ2}en*gQ6RiYTM;$k$wzTr_vXBe9U1+dDql6zLcs$Q%P zX5h4cQN+8g9>dX{owM8M#iF(5$ZxNjy`F}SPET4qqsa7~T_*+r9v*-I<-cjLL4$+( z3`#6{sKlNCMqvz{K(@~8Y`=~a`Gfz}-v1iSMJ0?Wc5|Ti9!R%|uixz0Nh9SIwaQDk zQmT`EqS+^Jh%TTJxi}932FRK&d^z756V_YW-?UOECoy4H>~3KYg>ajA&RDxwA=eFY^Cx9v3#A!i zLo$JQCs~tN12KmFNqEz2(3M+H|)g1#%5 zT^e_O#!xqeezyPQy1!6T>M8U}3zX|b03;Z9TlPQc?q=^~V`6V_^J~WW7xm$OQ6D-t z{r|mHCXC7UaA5Wx1RP*)+D%qdQDyE+2DMvz`^Cv;)`79P)^b0#=jAU1gW6BAFU|We z?zqzT_H9Ud5b1UTwUqH_kxuDmm)ua6GPW`iF?;6qUc$wq(9z6J&1fwUknn8DtzS!1 zwYsaWq^%VsnUTa~L|}f|QY4-zeLnPcpmapkje!s3!9FrzJjI zpo15Py-+s2CB`hMXpVT+5yPZP&~-Xv*|@0tPmVHq*Ph41$8Nt*I?*vODV;XEMBNra zkB=qsrA=_&q8e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-R`>1 zY~x)5u= zY*X{*jQz@`utH+J{Te=@wVv(M_ec@nYRjSj1nA9l9{*Bw#+q3_&!W25E9`lC)~Mu5 zUB5L=qSK24q|whmvMvP&7QPF`Q!~_}ipKR`$w{~_y9Q|uKX-^UvOwQuy&|%^3udMb z%dEbnvMwtW9~*x*>p^{3EEd;2elIMPVTY5ySKB)yQpu`XuvOz6Yl1dSZK z&pFxavkMh8@|`cAJHo86*%Q561`~#MofNYGlJ2BF$gjYy#y0r+YLtv1cw+`3jnK)8 zRP|fvx`h7>4XEuj&{Lp-5QGW>^RI$1c5wKw9)2m|&n+vl({6zSHRJ&P96e+|I?ISK zLPV3Zkoc`O1R&GOO+N`y*29*VmcBks1~)s-XK&&RM z8b2{cBW_m=61AOd7D@IwC2uX$kUcdB-+1HBhg-1Lvi88s+P;1D!^#&0S-awZl4lxF zqPK%+lTUBxc)n&?tK!5~F3}`@g3X%iQoSyyApk_POMq0rqf|fESH3{H8*enCwwgL> z5$_fC+a$AMs@;hB@A zbSKEvo+E(fJGP_!2hnQ-Fy*muSgP}?zw!Frr%PnV<~J{P1Mh(R{6_L!p7lpyfLlg; zUvJ;a+M%qhV%;@pk^5yxdk3)B>Nr)hp@PyRoy=xp4E{}S2wCQmnOdNL(epDe{Ogw< zM7{{^`mD#NXg@ipk_2noeV}aplglu$tkBZRKd-_0_qY4^`5#u~D9imF;O`3v{%!c{ z90YyjUzQU*HvD@v_OFHx(CqR5y*B$8=W&JZH&P)qcz;x{du;r;-t^lT2j$PG|8e!{ zF~Z|=!Eb~V)c<+>|EqZL81Qla{5Rk zo4zD?{4&2o%*QB?U9{gQyd;01JaW+f(P4WG`gcF%HzWX1L<#`>hgb60{O_aoU(FjS c{$l>GF + + +
    + +
    + + + + +
    + +
    + +

     

    + + + + {lang adduser_login_email_text} +
    +
    +
    + +
    + + + + + {lang login_username_tips} +
    +
    +
    + +
    + + {lang adduser_phone_number_text} +
    +
    +
    + +
    + + {lang edituser_weixin_text} +
    +
    +
    + +
    + + + + + +
    +
    +
    + +
    + + + + + +
    +
    +
    + +
    + +
    +
    +
    + +
    + disabled="disabled" value="1" checked> + {lang adduser_disable_user_text} +
    +
    +
    + +
    + + {lang adduser_usergroup_text} +
    +
    +
    + +
    +
    +
    + + + + +
    +
    +
    +
    +
    + +
    +
    +
    +
    + +
    +
    +
    +
    +
    +
    + + +
    +
    + +
    +
    +
    + \ No newline at end of file diff --git a/admin/orguser/template/detail_org.htm b/admin/orguser/template/detail_org.htm new file mode 100644 index 0000000..a0ea75c --- /dev/null +++ b/admin/orguser/template/detail_org.htm @@ -0,0 +1,281 @@ + +
    + +
    +
    +
    +
    + +
    + +
    +
    +
    + +
    +
      +
    • $org['avatar']
    • +
    • + +
    • +
    • + +
    • +
    +
    +
    +
    + +
    + +
    +
    + +
    + +
    +
    + 0}-->checked="checked" onclick="folder_available(1,'$orgid');" /> + +
    +
    + checked="checked" onclick="folder_available(0,'$orgid');" /> + +
    + + {lang detail_org_explorerapp_enable} + + {lang detail_org_enable} + +
    +
    + + +
    + +
    +
    + + M +
    +
      +
    • {lang org_space_assign_tip}:{eval echo ($allowallotspace == 0) ? lang('no_limit'):formatsize($allowallotspace);} +
    • {lang org_space_assign_tips} +
    +
    +
    + +
    + +
    +
    +
    {eval echo formatsize($org[usesize])}/{eval if($org[maxallotspacesize] == -1) echo formatsize($org[usesize]);else echo ($org[maxallotspacesize] == 0)?lang('no_limit'):formatsize($org[maxallotspacesize])} +
    +
    +
    {eval echo formatsize($org[usesize])}/{eval if($org[maxallotspacesize] == -1) echo formatsize($org[usesize]);else echo ($org[maxallotspacesize] == 0)?lang('no_limit'):formatsize($org[maxallotspacesize])}
    +
      + {lang space_use_org_tips} +
    +
    +
    +
    + +
    + +
    + +
    +
    +
    + +
    + + +
    +
    +
    + +
    + {lang add_position} +
    +
    + +
    + + +
    +
    +
    + +
    +
    + +
    +
      + +
    • +
      +
      +
      + +
      +
      +
    • + + +
    • + +
       
      + +
      +
      +
      + {eval echo avatar_block($value[uid]);} +
      +
      +

      $value[username]

      +
    • + + +
    + +
      + {lang detail_org_administrator} +
    +
    +
    +
    +
    + + + \ No newline at end of file diff --git a/admin/orguser/template/edituser.htm b/admin/orguser/template/edituser.htm new file mode 100644 index 0000000..8c3bddd --- /dev/null +++ b/admin/orguser/template/edituser.htm @@ -0,0 +1,301 @@ +
    + +
    +
    + +
    + + + + +
    + +
    + disabled="disabled"> +

     

    + + + + {lang required_used_login_system} +
    +
    +
    + +
    + disabled="disabled"> + + + + {lang login_username_tips} +
    +
    + +
    + +
    +

    +
    +
    +
    + +
    +

    $user[regip]

    +
    +
    + +
    + +
    +

    +
    +
    + +
    + +
    + disabled="disabled"> + {lang adduser_phone_number_text} +
    +
    +
    + +
    + disabled="disabled"> + {lang edituser_weixin_text} +
    +
    +
    + +
    + disabled="disabled"> + + + + +
    +
    +
    + +
    + disabled="disabled"> + + + + +
    +
    +
    + +
    +
    + disabled="disabled"name="userspace" value="$userfield[userspace]" autocomplete="off"> + M +
    +
      +
    • {lang user_allocable_space}:{eval echo ($allowallotspace == 0) ? '{lang no_limit}':formatsize($currentuserAllotspace);}
    • +
    • {lang user_set_space_text}
    • +
    +
    +
    +
    + +
    +
    + checked disabled="disabled"> + +
    +
    +
    +
    + +
    + + {lang adduser_usergroup_text} +
    +
    +
    + +
    +
    + + + + +
    +
    +
    +
    + +
    +
    +
    + +
    +
    +
    +
    +
    + +
    +
    +
    + \ No newline at end of file diff --git a/admin/orguser/template/export.htm b/admin/orguser/template/export.htm new file mode 100644 index 0000000..70c969b --- /dev/null +++ b/admin/orguser/template/export.htm @@ -0,0 +1,71 @@ + + + + +
    +
    + +
    +
    +
    +
    + + +
    + +
    + + {lang export_range_user}
    +
    + +
    + +
    + +
    + + +
    + + +
    + +
    +
    + +
    +
    +
    +
    +
    +
    +
    + + diff --git a/admin/orguser/template/guide.htm b/admin/orguser/template/guide.htm new file mode 100644 index 0000000..2895a0d --- /dev/null +++ b/admin/orguser/template/guide.htm @@ -0,0 +1,20 @@ +
    +

    {lang Organization management instructions}

    +
      +
    •  {lang Select organization to set organization information}
    • +
    •  {lang Select department to set department information}
    • +
    •  {lang Select personnel to set personnel information}
    • +
    • {lang Personnel, departments and institutions can directly drag and move to change positions. Move refers to changing the Department to which the person belongs, and changing the superior organization or department of the Department.}
    • +
    • {lang Hold} {lang Key to move personnel or departments to copy. It is used to join personnel to multiple departments at the same time.}
    • +
    • {lang Hold} {lang Key can be used for multiple selections, and release after multiple selections} {lang Key movement is batch movement. Do not loosen} {lang Key to move to batch copy.}
    • +
    • {lang Right click departments, institutions and personnel to open the right-click menu. There are corresponding more operations in the menu.}
    • +
    +
    +

    {lang Delete user description}:

    +
      +
    • {lang Organization management instructions}
    • +
    • {lang Deleting users from all institutions or departments is only removing users from their own institutions or departments. Users can no longer have all the use rights of their own institutions or departments. It is not deleting users from the system.}
    • +
    • {lang When the system administrator deletes the user from the "list of non institutional users", the user will be completely deleted in the system, and all system data and saved files of the user will be deleted. Please use it cautiously by the administrator, and delete it after confirming that the member is to be deleted.}
    • +
    +
    +
    \ No newline at end of file diff --git a/admin/orguser/template/header_left.htm b/admin/orguser/template/header_left.htm new file mode 100644 index 0000000..d9119b8 --- /dev/null +++ b/admin/orguser/template/header_left.htm @@ -0,0 +1,13 @@ + + +
    + +
    + +
    +
    + +
    + + {lang appname} +
    \ No newline at end of file diff --git a/admin/orguser/template/header_search.htm b/admin/orguser/template/header_search.htm new file mode 100644 index 0000000..715c4d9 --- /dev/null +++ b/admin/orguser/template/header_search.htm @@ -0,0 +1,25 @@ + + + + + \ No newline at end of file diff --git a/admin/orguser/template/import_guide.htm b/admin/orguser/template/import_guide.htm new file mode 100644 index 0000000..67c2308 --- /dev/null +++ b/admin/orguser/template/import_guide.htm @@ -0,0 +1,71 @@ + + + + + + +
    +
    +
    + +
    +
    +
    +
    + +
    + {lang inport_guide_download} + {lang inport_guide_template} +
    +
    +
    + +
    + {lang inport_guide_user.} +
    +
    +
    + + +
    + +
    + + {lang inport_guide_layout} +
    +
    +
    + +
    +
    +
    +

    {lang inport_guide_notice}

    +
      + {lang inport_guide_notice_text} +
    +
    +
    +
    +
    +
    + \ No newline at end of file diff --git a/admin/orguser/template/import_list.htm b/admin/orguser/template/import_list.htm new file mode 100644 index 0000000..529b01b --- /dev/null +++ b/admin/orguser/template/import_list.htm @@ -0,0 +1,209 @@ + + + + + +
    +
    + +
    +
    + +
    +
    + +
    + {lang import_list_organization} +
    +
    +
    + +
    + + {lang import_list_password} +
    +
    +
    + +
    +
    + + +
    +
    + + +
    + {lang import_list_coverage} +
    +
    +
      + {lang import_list_text} +
    +
    + + + + + + + + + + {eval $i=0;} + + + + + + + + + + + + + {eval $i++;} + + +
    $h0[$value]
    +

    $value2

    +

    $value[$value1]

    +     
    +
    +
    +
    +
    + + diff --git a/admin/orguser/template/main.htm b/admin/orguser/template/main.htm new file mode 100644 index 0000000..bb471f4 --- /dev/null +++ b/admin/orguser/template/main.htm @@ -0,0 +1,87 @@ + + + + + + + + +
    +
    + +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    + +
    + + + + + + + + + + + + \ No newline at end of file diff --git a/admin/orguser/template/profile.htm b/admin/orguser/template/profile.htm new file mode 100644 index 0000000..8067691 --- /dev/null +++ b/admin/orguser/template/profile.htm @@ -0,0 +1,55 @@ +
    + +
    +
    +
    +
    + + + + + + +
    + +
    + $htmls[$key] +
    +
    + + +
    + +
    +
    +
    + + + + + + + \ No newline at end of file diff --git a/admin/orguser/template/tree.htm b/admin/orguser/template/tree.htm new file mode 100644 index 0000000..d1c1e3f --- /dev/null +++ b/admin/orguser/template/tree.htm @@ -0,0 +1,420 @@ +
    + + + + + + + + +
    + +
    + + \ No newline at end of file diff --git a/admin/orguser/view.php b/admin/orguser/view.php new file mode 100644 index 0000000..371128a --- /dev/null +++ b/admin/orguser/view.php @@ -0,0 +1,60 @@ + ismoderator_by_uid_orgid($orgid, $_G['uid'])) { + exit(lang('orguser_vidw_delete')); + } + if($org = C::t('organization') -> fetch($orgid)){ + $org['avatar'] = avatar_group($org['orgid'],array($org['orgid']=>array('aid'=>$org['aid'],'orgname'=>$org['orgname']))); + } + if ($org && $org['forgid'] > 0) { + $toporgid = C::t('organization') -> getTopOrgid($orgid); + $toporg = C::t('organization') -> fetch($toporgid); + $folder_available = $toporg['available']; + $group_on = $toporg['syatemon']; + } else { + $folder_available = 1; + $group_on = 1; + } + + //可分配空间 + $allowallotspace = C::t('organization')->get_allowallotspacesize_by_orgid($orgid); + //获取已使用空间 + $org['usesize'] = C::t('organization')->get_orgallotspace_by_orgid($orgid,0,false); + /*echo formatsize($org['usesize']); + die;*/ + //获取总空间 + if($org['maxspacesize'] == 0){ + $maxspacesize = C::t('organization')->get_parent_maxspacesize_by_pathkey($org['pathkey'],$orgid); + $org['maxallotspacesize'] = $maxspacesize['maxspacesize']; + }else{ + if($org['maxspacesize'] == -1){ + $org['maxallotspacesize'] = -1; + }else{ + $org['maxallotspacesize'] = $org['maxspacesize']*1024*1024; + } + + } + $pmoderator = C::t('organization_admin') -> ismoderator_by_uid_orgid($org['forgid'], $_G['uid']); + $jobs = C::t('organization_job') -> fetch_all_by_orgid($orgid); + $moderators = C::t('organization_admin') -> fetch_moderators_by_orgid($orgid); + //$grouppic= C::t('resources_grouppic')->fetch_user_pic(); + include template('detail_org'); +} +?> diff --git a/admin/setting/template/main.htm b/admin/setting/template/main.htm index b2918c7..0fbe249 100644 --- a/admin/setting/template/main.htm +++ b/admin/setting/template/main.htm @@ -695,6 +695,12 @@ + + +
    + +
    +
    diff --git a/admin/setting/template/perm_group.htm b/admin/setting/template/perm_group.htm index 25fdc0f..4668b58 100644 --- a/admin/setting/template/perm_group.htm +++ b/admin/setting/template/perm_group.htm @@ -63,7 +63,8 @@ - $v[pername] + + $v[pername]

    {lang system_default}

    @@ -130,7 +131,7 @@ var html =' ' + '' + - ''+data['success']['pername']+''+ + '' + data['success']['pername'] + ' '+''+ '' + '' + '
    ' + diff --git a/admin/system/xtxx.php b/admin/system/xtxx.php index ba7e50a..6602858 100644 --- a/admin/system/xtxx.php +++ b/admin/system/xtxx.php @@ -41,7 +41,7 @@ if($do == 'phpinfo'){ $env_items = array ( '操作系统' => array('c' => 'PHP_OS', 'r' => '不限制', 'b' => 'Linux'), - 'PHP 版本' => array('c' => 'PHP_VERSION', 'r' => '5.3+', 'b' => 'php7+'), + 'PHP 版本' => array('c' => 'PHP_VERSION', 'r' => '7+', 'b' => 'php7+'), '附件上传' => array('r' => '不限制', 'b' => '50M'), 'GD 库' => array('r' => '1.0', 'b' => '2.0'), '磁盘空间' => array('r' => '50M', 'b' => '10G以上'), diff --git a/core/api/OneDrive/Client.php b/core/api/OneDrive/Client.php index dfdf742..92e43ab 100644 --- a/core/api/OneDrive/Client.php +++ b/core/api/OneDrive/Client.php @@ -25,7 +25,7 @@ class Client { //const API_URL_OneDrive = 'https://apis.live.net/v5.0/'; - const API_URL = 'https://api.onedrive.com/'; + const API_URL = 'https://api.onedrive.com/v1.0'; // The base URL for authorization requests. const AUTH_URL = 'https://login.live.com/oauth20_authorize.srf'; diff --git a/core/class/class_FileDownload.php b/core/class/class_FileDownload.php index ba2859c..67c5b16 100644 --- a/core/class/class_FileDownload.php +++ b/core/class/class_FileDownload.php @@ -29,6 +29,7 @@ class FileDownload{ // class start if(!$fp = fopen($file, 'rb')){ topshowmessage(lang('file_not_exist1')); } + $charset = CHARSET; $db = DB::object(); $db->close(); @ob_end_clean(); @@ -36,11 +37,21 @@ class FileDownload{ // class start if(!$file_size) $file_size = filesize($file); $ranges = $this->getRange($file_size); - header('cache-control:public'); - header('Date: '.gmdate('D, d M Y H:i:s', $dateline).' GMT'); - header('Last-Modified: '.gmdate('D, d M Y H:i:s', $dateline).' GMT'); - header('content-type:application/octet-stream'); - header('content-disposition:attachment; filename='.$name); + header('cache-control:public'); + header('Date: '.gmdate('D, d M Y H:i:s', $dateline).' GMT'); + header('Last-Modified: '.gmdate('D, d M Y H:i:s', $dateline).' GMT'); + header('content-type:application/octet-stream'); + if (preg_match("/Firefox/", $_SERVER["HTTP_USER_AGENT"])) { + $attachment = 'attachment; filename*='.$charset.'\'\'' . $name; + } elseif (!preg_match("/Chrome/", $_SERVER["HTTP_USER_AGENT"]) && preg_match("/Safari/", $_SERVER["HTTP_USER_AGENT"])) { + $name = trim($name,'"'); + $filename = rawurlencode($name); // 注意:rawurlencode与urlencode的区别 + $attachment = 'attachment; filename*='.$charset.'\'\'' . $filename; + } else{ + $attachment = 'attachment; filename='.$name; + } + //header('content-disposition:attachment; filename='.$name); + header('content-disposition:'.$attachment); if($reload && $ranges!=null){ // 使用续传 header('HTTP/1.1 206 Partial Content'); header('Accept-Ranges:bytes'); diff --git a/core/class/class_core.php b/core/class/class_core.php index 6f7db91..591ee22 100644 --- a/core/class/class_core.php +++ b/core/class/class_core.php @@ -104,7 +104,10 @@ class core } public static function import($name, $folder = '', $force = true) { - + //如果文件名为空或者false,阻止向下进行 + if(preg_match('/^\s*$/',$name) || $name == false){ + return false; + } $key = $folder.$name; if(!isset(self::$_imports[$key])) { if($folder){ @@ -146,7 +149,10 @@ class core } public static function handleException($exception) { - dzz_error::exception_error($exception); + global $_config; + if($_config['debug']>0){ + dzz_error::exception_error($exception); + } } diff --git a/core/class/class_template.php b/core/class/class_template.php index 9d0abaa..8d0c920 100644 --- a/core/class/class_template.php +++ b/core/class/class_template.php @@ -144,7 +144,8 @@ class template { } function parse_template(&$template) { - $var_regexp = "((\\\$[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*(\-\>)?[a-zA-Z0-9_\x7f-\xff]*)(\[[a-zA-Z0-9_\-\.\"\'\[\]\$\x7f-\xff]+\])*)"; + $template = str_replace('self.$', 'self.$', $template); + $var_regexp = "((?!\\\$[a-zA-Z]+\()(\\\$[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*(\-\>)?[a-zA-Z0-9_\x7f-\xff]*)(\[[a-zA-Z0-9_\-\.\"\'\[\]\$\x7f-\xff]+\])*)"; $const_regexp = "([A-Z_\x7f-\xff][A-Z0-9_\x7f-\xff]*)"; $template = preg_replace("/([\n\r]+)\t+/s", "\\1", $template); @@ -174,7 +175,7 @@ class template { $template = str_replace("{LF}", "", $template); $template = preg_replace("/\{(\\\$[a-zA-Z0-9_\-\>\[\]\'\"\$\.\x7f-\xff]+)\}/s", "", $template); $template = preg_replace_callback("/[\n\r\t]*\{Hook\s+([\w]+)\}[\n\r\t]*/is", array($this, 'parse_template_callback_hook'), $template);//钩子解析 - //$template = preg_replace_callback("/[\n\r\t]*\{Hook\s+([\w]+)\#(.+?)\#\}[\n\r\t]*/is", array($this, 'parse_template_callback_hook'), $template);//钩子解析,传参形式 + $template = preg_replace_callback("/[\n\r\t]*\{Hook\s+([\w]+)\#(.+?)\#\}[\n\r\t]*/is", array($this, 'parse_template_callback_hook_1'), $template);//钩子解析,传参形式 $template = preg_replace_callback("/$var_regexp/s", array($this, 'parse_template_callback_addquote_1'), $template); $template = preg_replace_callback("/\<\?\=\<\?\=$var_regexp\?\>\?\>/s", array($this, 'parse_template_callback_addquote_1'), $template); @@ -199,6 +200,7 @@ class template { $template = preg_replace_callback("/[\n\r\t]*\{block\s+([a-zA-Z0-9_\[\]]+)\}(.+?)\{\/block\}/is", array($this, 'parse_template_callback_stripblock_12'), $template); $template = preg_replace("/\<\?(\s{1})/is", "/is", "", $template); + $template = str_replace('self.$','self.$', $template); } function parse_template_callback_javascript($matches) { @@ -206,9 +208,11 @@ class template { } function parse_template_callback_hook($matches){ - - //return ""; + return ""; + } + function parse_template_callback_hook_1($matches){ + $param=array($matches[2]); + return ""; //传参形式 } function replace_js_language_var($arr) { @@ -592,4 +596,4 @@ class template { } } -?> \ No newline at end of file +?> diff --git a/core/class/dzz/Hook.php b/core/class/dzz/Hook.php index c2076ed..d044e8a 100644 --- a/core/class/dzz/Hook.php +++ b/core/class/dzz/Hook.php @@ -4,10 +4,12 @@ class Hook { private static $tags = array(); + public static $usetag = array(); /** * 动态添加行为扩展到某个标签 * @param string $tag 标签名称 * @param mixed $behavior 行为名称 + * @param mixed $behavior 行为名称 * @param bool $first 是否放到开头执行 * @return void */ diff --git a/core/class/dzz/apprun.php b/core/class/dzz/apprun.php index 8c55179..023976c 100644 --- a/core/class/dzz/apprun.php +++ b/core/class/dzz/apprun.php @@ -3,7 +3,7 @@ namespace core\dzz; use \core as C; -class apprun{ +class Apprun{ public function run(){ diff --git a/core/class/dzz/config.php b/core/class/dzz/config.php index 34c6154..0034b12 100644 --- a/core/class/dzz/config.php +++ b/core/class/dzz/config.php @@ -1,7 +1,7 @@ $v){ $this->$k = $v; } @@ -77,11 +77,21 @@ class dzz_app extends dzz_base{ public function init() { if(!$this->initated) { - $this->_init_setting(); - $this->_init_user(); - $this->_init_session(); - $this->_init_cron(); - $this->_init_misc(); + if($this->init_setting){ + $this->_init_setting(); + } + if($this->init_user){ + $this->_init_user(); + } + if($this->init_session){ + $this->_init_session(); + } + if($this->init_cron){ + $this->_init_cron(); + } + if($this->init_misc){ + $this->_init_misc(); + } } $this->initated = true; } @@ -140,6 +150,7 @@ class dzz_app extends dzz_base{ 'PHP_SELF' => '', 'siteurl' => '', + 'localurl' => '', 'siteroot' => '', 'siteport' => '', @@ -169,11 +180,15 @@ class dzz_app extends dzz_base{ } $_G['isHTTPS'] = $this->is_HTTPS();//($_SERVER['HTTPS'] && strtolower($_SERVER['HTTPS']) != 'off') ? true : false; $_G['siteurl'] = dhtmlspecialchars('http'.($_G['isHTTPS'] ? 's' : '').'://'.$_SERVER['HTTP_HOST'].$sitepath.'/'); - + if(strpos($_SERVER['HTTP_HOST'],'127.')!==false && strpos($_SERVER['HTTP_HOST'],'localhost')!==false){ + $_G['localurl']=dhtmlspecialchars('http'.($_G['isHTTPS'] ? 's' : '').'://127.0.0.1'.$sitepath.'/'); + }else{ + $_G['localurl']=$_G['siteurl']; + } $url = parse_url($_G['siteurl']); $_G['siteroot'] = isset($url['path']) ? $url['path'] : ''; - $_G['siteport'] = empty($_SERVER['SERVER_PORT']) || $_SERVER['SERVER_PORT'] == '80' || $_SERVER['SERVER_PORT'] == '443' ? '' : ':'.$_SERVER['SERVER_PORT']; - + $_G['siteport'] = (empty($_SERVER['SERVER_PORT']) || $_SERVER['SERVER_PORT'] == '80' || $_SERVER['SERVER_PORT'] == '443' || $_SERVER['HTTP_X_FORWARDED_PORT'] == '443')? '' : ':'.$_SERVER['SERVER_PORT']; + if(defined('SUB_DIR')) { $_G['siteurl'] = str_replace(SUB_DIR, '/', $_G['siteurl']); $_G['siteroot'] = str_replace(SUB_DIR, '/', $_G['siteroot']); @@ -192,6 +207,8 @@ class dzz_app extends dzz_base{ }elseif($_SERVER['SERVER_PORT'] == 443){ //其他 return TRUE; }elseif($_SERVER['REQUEST_SCHEME'] == 'https'){ //其他 + return TRUE; + }elseif(isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https'){ //其他 return TRUE; } return FALSE; @@ -357,6 +374,9 @@ class dzz_app extends dzz_base{ if($this->config['output']['forceheader']) { @header('Content-Type: text/html; charset='.CHARSET); } + if($this->config['localurl']){ + setglobal('localurl', $this->config['localurl']); + } } @@ -441,7 +461,9 @@ class dzz_app extends dzz_base{ } if($this->var['uid'] && !$sessionclose && ($this->session->isnew || ($this->session->get('lastactivity') + 600) < TIMESTAMP)) { + Hook::listen("core_session",$this->session); $this->session->set('lastactivity', TIMESTAMP); + $this->session->update(); if($this->session->isnew) { if($this->var['member']['lastip'] && $this->var['member']['lastvisit']) { dsetcookie('lip', $this->var['member']['lastip'].','.$this->var['member']['lastvisit']); @@ -528,7 +550,6 @@ class dzz_app extends dzz_base{ } private function _init_misc() { - global $_G; if(!$this->init_misc) { return false; } @@ -627,6 +648,7 @@ class dzz_app extends dzz_base{ } private function _init_setting() { + global $_G; if($this->init_setting) { if(empty($this->var['setting'])) { $this->cachelist[] = 'setting'; @@ -639,7 +661,7 @@ class dzz_app extends dzz_base{ !empty($this->cachelist) && loadcache($this->cachelist); if(!is_array($this->var['setting'])) { - $this->var['setting'] = array(); + $this->var['setting'] =C::t('setting')->fetch_all(); } if($ismobile=helper_browser::ismobile()) define('IN_MOBILE',$ismobile); define('VERHASH',isset($this->var['setting']['verhash'])?$this->var['setting']['verhash']:random(3)); diff --git a/core/class/dzz/dzz_io.php b/core/class/dzz/dzz_io.php index c364310..b4d0245 100644 --- a/core/class/dzz/dzz_io.php +++ b/core/class/dzz/dzz_io.php @@ -381,13 +381,22 @@ class dzz_io public function clean($str) {//清除路径 if(is_array($str)){ foreach($str as $key=> $value){ - $str[$key]=str_replace(array( "\n", "\r", '../'), '', $value); + $str[$key]=self::clean_path(str_replace(array( "\n", "\r", '../'), '', $value)); } }else{ - $str= str_replace(array( "\n", "\r", '../'), '', $str); + $str= self::clean_path(str_replace(array( "\n", "\r", '../'), '', $str)); } + return $str; } + private function clean_path($str){ + if(preg_match("/\.\.\//",$str)){ + $str=str_replace('../','',$str); + return self::clean_path($str); + }else{ + return $str; + } + } public function name_filter($name){ return str_replace(array('/','\\',':','*','?','<','>','|','"',"\n"),'',$name); } diff --git a/core/class/dzz/modrun.php b/core/class/dzz/modrun.php index 58cf9d3..c8c7140 100644 --- a/core/class/dzz/modrun.php +++ b/core/class/dzz/modrun.php @@ -48,6 +48,7 @@ class Modrun{ //加载文件 private static function loadFile($files = null){ + global $_config,$_G; if(is_array($files)){ diff --git a/core/class/dzz/route.php b/core/class/dzz/route.php index b7a4879..ccae296 100644 --- a/core/class/dzz/route.php +++ b/core/class/dzz/route.php @@ -11,7 +11,8 @@ class Route{ public static function dzzRoute(&$params,$extra=null,&$break) { - global $_G,$_config; + global $_G,$_config,$_GET; + //判断是否开启pathinfo,默认不开启,测试时将其设为1 $mod = !empty($params[MOULD]) ? $params[MOULD]:$_config['default_mod']; $op = !empty($params[DIVIDE]) ? $params[DIVIDE]:$_config['default_op']; @@ -29,7 +30,7 @@ class Route{ }else{ if(strpos(strtolower($mod),':')!==false){ - + define('CURMODULE',str_replace(':', '/', $mod)); $patharr=explode(':',$mod); foreach($patharr as $path){ @@ -50,7 +51,7 @@ class Route{ } }else{ - + define('CURMODULE',$mod); if(!preg_match("/^\w+$/i",$mod) && $mod !== '') showmessage('undefined_action'); if(!preg_match("/^\w+$/i",$op)) showmessage('undefined_action'); diff --git a/core/class/helper/helper_browser.php b/core/class/helper/helper_browser.php index 69a6f23..6b405dd 100644 --- a/core/class/helper/helper_browser.php +++ b/core/class/helper/helper_browser.php @@ -114,18 +114,20 @@ class helper_browser return false;//return 'WindowsWechat';pc微信客户端打开pc版 } elseif (preg_match("/macintosh/i", $agent) && preg_match("/MicroMessenger/i", $agent)) { - return false;//苹果电脑系统pc端 - } - elseif (preg_match("/MicroMessenger/i", $agent)) { - return 'wechat'; - } - elseif (preg_match("/iphone/i", $agent) && preg_match("/mac os/i", $agent)) { - return 'iPhone'; - } elseif (preg_match("/ipod/i", $agent) && preg_match("/mac os/i", $agent)) { - return 'iPod'; - } elseif (preg_match("/linux/i", $agent) && preg_match("/Android/i", $agent)) { - return 'Android'; - } + return false;//苹果电脑系统pc端 + } + elseif (preg_match("/MicroMessenger/i", $agent)) { + return 'wechat'; + } + elseif (preg_match("/iphone/i", $agent) && preg_match("/mac os/i", $agent)) { + return 'iPhone'; + } elseif (preg_match("/ipod/i", $agent) && preg_match("/mac os/i", $agent)) { + return 'iPod'; + } elseif (preg_match("/ipad/i", $agent) && preg_match("/mac os/i", $agent)) { + return 'iPad'; + } elseif (preg_match("/linux/i", $agent) && preg_match("/Android/i", $agent)) { + return 'Android'; + } return false; } @@ -153,7 +155,9 @@ class helper_browser $os = array('Windows' => '8'); } elseif (preg_match("/win/i", $agent) && preg_match("/nt 6.3/i", $agent)) { $os = array('Windows' => '8.1'); - } elseif (preg_match("/win/i", $agent) && preg_match("/nt/i", $agent)) { + } elseif (preg_match("/win/i", $agent) && preg_match("/nt 10/i", $agent)) { + $os = array('Windows' => '10'); + }elseif (preg_match("/win/i", $agent) && preg_match("/nt/i", $agent)) { $os = array('Windows' => 'nt'); } elseif (preg_match("/ipad/i", $agent) && preg_match('/mac os/i', $agent)) { $os = array('iPad' => true); diff --git a/core/class/io/io_dzz.php b/core/class/io/io_dzz.php index 3d8c7d7..eac0958 100644 --- a/core/class/io/io_dzz.php +++ b/core/class/io/io_dzz.php @@ -129,7 +129,7 @@ class io_dzz extends io_api global $_G;//123 if (strpos($path, 'attach::') === 0) { $attach = C::t('attachment')->fetch(intval(str_replace('attach::', '', $path))); - Hook::listen('io_dzz_getstream_attach',$attach);//挂载点 + Hook::listen('io_dzz_getstream_attach',$attach);//挂载点 $bz = io_remote::getBzByRemoteid($attach['remote']); if ($bz == 'dzz') { return $_G['setting']['attachdir'] . $attach['attachment']; @@ -145,7 +145,7 @@ class io_dzz extends io_api } elseif (preg_match('/\w{32}/i', $path)) { $icoid = trim($path); $icoarr = C::t('resources')->fetch_by_rid($path); - Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 + Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 $bz = io_remote::getBzByRemoteid($icoarr['remote']); if ($bz == 'dzz') { if ($icoarr['type'] == 'video' || $icoarr['type'] == 'dzzdoc' || $icoarr['type'] == 'link') { @@ -166,7 +166,7 @@ class io_dzz extends io_api return false; } $icoarr = C::t('resources')->fetch_by_rid($rid); - Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 + Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 $bz = io_remote::getBzByRemoteid($icoarr['remote']); if ($bz == 'dzz') { if ($icoarr['type'] == 'video' || $icoarr['type'] == 'dzzdoc' || $icoarr['type'] == 'link') { @@ -188,14 +188,13 @@ class io_dzz extends io_api global $_G; if (strpos($path, 'attach::') === 0) { $attach = C::t('attachment')->fetch(intval(str_replace('attach::', '', $path))); - Hook::listen('io_dzz_getstream_attach',$attach);//挂载点 - $bz = io_remote::getBzByRemoteid($attach['remote']); + Hook::listen('io_dzz_getstream_attach',$attach);//挂载点 + $bz = io_remote::getBzByRemoteid($attach['remote']); if ($bz == 'dzz') { return $_G['siteurl'] . $_G['setting']['attachurl'] . $attach['attachment']; } else { return IO::getFileUri($bz . '/' . $attach['attachment'], $fop); } - } elseif (strpos($path, 'dzz::') === 0) { if (strpos($path, './') !== false) return ''; return $_G['siteurl'] . $_G['setting']['attachurl'] . preg_replace("/^dzz::/", '', $path); @@ -207,7 +206,7 @@ class io_dzz extends io_api if ($icoarr['aid']) { $attachment = C::t('attachment')->fetch($icoarr['aid']); $icoarr['remote'] = $attachment['remote']; - Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 + Hook::listen('io_dzz_getstream_attach',$icoarr);//挂载点 $bz = io_remote::getBzByRemoteid($icoarr['remote']); if ($bz == 'dzz') { if ($icoarr['type'] == 'video' || $icoarr['type'] == 'dzzdoc' || $icoarr['type'] == 'link') { diff --git a/core/class/table/table_resources_statis.php b/core/class/table/table_resources_statis.php index edfd93e..a417950 100644 --- a/core/class/table/table_resources_statis.php +++ b/core/class/table/table_resources_statis.php @@ -126,7 +126,7 @@ class table_resources_statis extends dzz_table $uid = getglobal('uid'); $data = array(); $param = array($this->_table,$uid); - $wheresql = " where uid = $uid and fid = 0 and rid != '' "; + $wheresql = " where uid = %d and fid = 0 and rid != '' "; $orderby = ' order by edits desc,views desc,editdateline desc,opendateline desc'; $limitsql = ' limit '.$limit; diff --git a/core/core_version.php b/core/core_version.php index 3f266d0..819e0ec 100644 --- a/core/core_version.php +++ b/core/core_version.php @@ -14,7 +14,7 @@ if(!defined('CORE_VERSION')) { define('CORE_VERSION', '2.02'); define('CORE_RELEASE', '20180909'); define('CORE_FIXBUG' , '20000000'); - define('CORE_XHVERSION', '1.86.1'); - define('CORE_XHRELEASE', '20230909'); - define('CORE_XHFIXBUG' , '20230922'); + define('CORE_XHVERSION', '1.87'); + define('CORE_XHRELEASE', '20240110'); + define('CORE_XHFIXBUG' , '20240110'); } \ No newline at end of file diff --git a/core/function/function_core.php b/core/function/function_core.php index c0f73c4..4a15525 100644 --- a/core/function/function_core.php +++ b/core/function/function_core.php @@ -3156,40 +3156,38 @@ function get_resources_some_setting() 'allownewcat'=>false, 'finallydelete'=>false ); - if (!isset($setting['explorer_usermemoryOn'])) { - $data['useronperm'] = true; - } else { - //用户存储开启 - if ($setting['explorer_usermemoryOn'] == 1) { - $spaceon = isset($setting['explorer_mermoryusersetting']) ? $setting['explorer_mermoryusersetting'] : ''; - if ($spaceon == 'appoint') {//指定用户时 - $usersarr = explode(',', $setting['explorer_memoryorgusers']); - $uesrs = array(); - foreach ($usersarr as $v) { - //群组id - if (preg_match('/^\d+$/', $v)) { - foreach (C::t('organization_user')->get_all_user_byorgid($v) as $val) { - $users[] = $val['uid']; - } - } elseif ($v == 'other') { - foreach (C::t('user')->fetch_uid_by_groupid(9) as $val) { - $users[] = $val['uid']; - } - } elseif (preg_match('/^uid_\d+$/', $v)) { - $users[] = preg_replace('/uid_/', '',$v); + //用户存储开启 + if ($setting['explorer_usermemoryOn'] == 1) { + $spaceon = isset($setting['explorer_mermoryusersetting']) ? $setting['explorer_mermoryusersetting'] : ''; + if ($spaceon == 'appoint') {//指定用户时 + $usersarr = explode(',', $setting['explorer_memoryorgusers']); + $uesrs = array(); + foreach ($usersarr as $v) { + //群组id + if (preg_match('/^\d+$/', $v)) { + foreach (C::t('organization_user')->get_all_user_byorgid($v) as $val) { + $users[] = $val['uid']; } - - } - $users = array_unique($users); - $data['userallowonperm'] = $users; - if (in_array($_G['uid'], $data['userallowonperm'])) { - $data['useronperm'] = true; + } elseif ($v == 'other') { + foreach (C::t('user')->fetch_uid_by_groupid(9) as $val) { + $users[] = $val['uid']; + } + } elseif (preg_match('/^uid_\d+$/', $v)) { + $users[] = preg_replace('/uid_/', '',$v); } - } else {//未指定用户时 + } + $users = array_unique($users); + $data['userallowonperm'] = $users; + if (!in_array($_G['uid'], $data['userallowonperm'])) { $data['useronperm'] = true; } + + } else {//未指定用户时 + $data['useronperm'] = true; } + }else {//未指定用户时 + $data['useronperm'] = true; } if (!isset($setting['fileVersion']) || (isset($setting['fileVersion']) && $setting['fileVersion'] == 1)) { diff --git a/core/language/en-US/lang.php b/core/language/en-US/lang.php index a05bf8e..3f32be9 100644 --- a/core/language/en-US/lang.php +++ b/core/language/en-US/lang.php @@ -1266,6 +1266,7 @@ Important! 'Congratulations' =>' Congratulations ', 'login_success' => 'Login successful! ', 'no_relevant_content'=>' no relevant_content yet ', + 'degree_exhaust '=> 'times exhausted', ); ?> \ No newline at end of file diff --git a/core/language/zh-cn/lang.php b/core/language/zh-cn/lang.php index 2ed5842..218bb02 100644 --- a/core/language/zh-cn/lang.php +++ b/core/language/zh-cn/lang.php @@ -1293,6 +1293,7 @@ $_G[siteurl]', 'congratulations' => '恭喜您', 'login_success' => '登录成功!', 'no_relevant_content' => '没有相关的内容…', + 'degree_exhaust'=>'次数用尽', ); ?> \ No newline at end of file diff --git a/core/template/default/common/adminlogin.htm b/core/template/default/common/adminlogin.htm index 167f955..5ef23f7 100644 --- a/core/template/default/common/adminlogin.htm +++ b/core/template/default/common/adminlogin.htm @@ -3,9 +3,6 @@ + + +
    +
    +
    + light year admin +

    $_G[setting][loginset][title]$_G[setting][sitename]

    +

    请选择下列用户登录

    +
    + +

    +
    +
    + + + + + + \ No newline at end of file diff --git a/user/profile/index.php b/user/profile/index.php index 53afc3e..7746bd5 100644 --- a/user/profile/index.php +++ b/user/profile/index.php @@ -27,8 +27,7 @@ $verify = C::t('user_verify')->fetch($_G['uid']);//验证信息 $space = C::t('user_profile')->get_userprofile_by_uid($uid);//用户资料信息 $userstatus = C::t('user_status')->fetch($uid);//用户状态 -$scdlsj=dgmdate($userstatus['lastvisit']); -$zcsj=dgmdate($space['regdate']); +$users = getuserbyuid($uid); $qqlogin = DB::fetch_first("select openid,unbind from %t where uid=%d", array('user_qqconnect', $uid)); //读取缓存 diff --git a/user/profile/password.php b/user/profile/password.php index b701f3c..169c42c 100644 --- a/user/profile/password.php +++ b/user/profile/password.php @@ -141,7 +141,7 @@ elseif($do == 'login'){ 'op' => $_GET['op'], 'do' => $_GET['do'] ); - $theurl = BASESCRIPT . "?" . url_implode($gets); + $theurl = CURSCRIPT . "?" . url_implode($gets); $logdir = DZZ_ROOT.'./data/log/'; $logfiles = get_log_files($logdir, $operation); diff --git a/user/profile/template/profile.htm b/user/profile/template/profile.htm index de22dc9..26ba226 100644 --- a/user/profile/template/profile.htm +++ b/user/profile/template/profile.htm @@ -82,14 +82,14 @@
    $_G[username]    {lang do_unbind}
    -
    +
    -
    $scdlsj +
    - -
    $zcsj + +
    diff --git a/user/register/register.php b/user/register/register.php index aefdee1..e2ceac2 100644 --- a/user/register/register.php +++ b/user/register/register.php @@ -137,8 +137,8 @@ if(!submitcheck('regsubmit', 0, $seccodecheck)) { 'comment'=>replacesitevar($_G['setting']['welcomemsgtxt']), ); - $action = 'register'; - $type = 'register_' . $result['uid']; + $action = 'registers'; + $type = 'registers_' . $result['uid']; dzz_notification::notification_add($result['uid'], $type, $action, $notevars); } diff --git a/user/space/about.php b/user/space/about.php index ccf4261..7476fec 100644 --- a/user/space/about.php +++ b/user/space/about.php @@ -12,13 +12,12 @@ if(!defined('IN_DZZ')) { $verify = C::t('user_verify')->fetch($_G['uid']); $about=array(); $identify=$_GET['modname']; -$navtitle="关于"; $appConfig=DZZ_ROOT.'./dzz/'.$identify.'/config/config.php'; if($identify && file_exists($appConfig)){ $config=include($appConfig); if(isset($config['about'])){ $about=$config['about']; - $about['sitelogo']=$_G['setting']['sitelogo']?'index.php?mod=io&op=thumbnail&size=small&path='.dzzencode('attach::'.$_G['setting']['sitelogo']):'static/image/common/logo.png'; + $about['sitelogo']=$_G['setting']['sitelogo']?\IO::getFileUri('attach::'.$_G['setting']['sitelogo']):'static/image/common/logo.png'; $appinfo=C::t('app_market')->fetch_by_identifier($identify); if(empty($about['logo'])){ $about['logo']=$_G['setting']['attachurl'].$appinfo['appico']; @@ -33,7 +32,7 @@ if(empty($appinfo['appname'])){ $about['name_en']=$_G['setting']['sitename'];//英文名称,注意前面的dzz去掉,留空不显示 $about['version']='V'.CORE_VERSION;//版本信息,留空不显示 //中间大图 - $about['logo']=$_G['setting']['sitelogo']?'index.php?mod=io&op=thumbnail&size=small&path='.dzzencode('attach::'.$_G['setting']['sitelogo']):'static/image/common/logo.png'; + $about['logo']=$_G['setting']['sitelogo']?\IO::getFileUri('attach::'.$_G['setting']['sitelogo']):'static/image/common/logo.png'; } //站点logo,留空不显示 diff --git a/user/space/index.php b/user/space/index.php index 7ad1b92..7ca817f 100644 --- a/user/space/index.php +++ b/user/space/index.php @@ -14,19 +14,20 @@ $navtitle="用户资料"; include_once libfile('function/profile'); include_once libfile('function/organization'); $uid=intval($_GET['uid']?$_GET['uid']:$_G['uid']); +$users = getuserbyuid($uid); $userstatus = C::t('user_status')->fetch($uid);//用户状态 -$scdlsj=dgmdate($userstatus['lastvisit']); $space = C::t('user_profile')->get_user_info_by_uid($uid); - $privacy = $space['privacy']['profile'] ? $space['privacy']['profile'] : array(); $space['regdate'] = dgmdate($space['regdate']); if($space['lastvisit']) $profiles['lastvisit']=array('title'=>lang('last_visit'),'value'=>dgmdate($space['lastvisit'])); - -$profiles['regdate']=array('title'=>lang('registration_time'),'value'=>$space['regdate']); - +if($users['regip']){ + $profiles['regdate']=array('title'=>lang('registration_time'),'value'=>$space['regdate']); +}else{ + $profiles['regdate']=array('title'=>lang('add_time'),'value'=>$space['regdate']); +} $user=array(); $space['fusesize']=formatsize($space['usesize']); diff --git a/user/space/lang.php b/user/space/lang.php new file mode 100644 index 0000000..5d6a529 --- /dev/null +++ b/user/space/lang.php @@ -0,0 +1,24 @@ +'error'))); +}else{ + if($_G['uid']) C::t('user')->update($_G['uid'], array('language' => ($langset))); + dsetcookie('language',$langset,60*60*24*30); + include libfile('function/cache'); + cleartemplatecache(); + C::memory()->clear(); + exit(json_encode(array('msg'=>'success'))); +} \ No newline at end of file diff --git a/user/space/template/navmenu.htm b/user/space/template/navmenu.htm index 348c625..6edadee 100644 --- a/user/space/template/navmenu.htm +++ b/user/space/template/navmenu.htm @@ -11,7 +11,7 @@ -
    \ No newline at end of file +
    + \ No newline at end of file diff --git a/user/space/template/space.htm b/user/space/template/space.htm index 43f2ec7..c68936f 100644 --- a/user/space/template/space.htm +++ b/user/space/template/space.htm @@ -31,7 +31,14 @@
    系统中的手机号:$space['phone']
    -
    最近在线时间:$scdlsj
    + +
    邮箱状态:已验证未验证
    +
    {lang registration_time}{lang add_time}:
    +
    {lang register} IP:$users[regip]
    +
    上次登录 IP:$userstatus['lastip']
    +
    上次登录时间:
    + +
    最近访问时间:
    diff --git a/user/space/yuyan.php b/user/space/yuyan.php deleted file mode 100644 index c156c6d..0000000 --- a/user/space/yuyan.php +++ /dev/null @@ -1,39 +0,0 @@ -update($_G['uid'], array('language' => ($url_sub)))) { - if ($fwq){ - header("Location: $fwq"); - }else{ - header("Location: /"); - } - }else{ - if ($fwq){ - header("Location: $fwq"); - }else{ - header("Location: /"); - } -} -}else{ - header("Location: /"); -} -}else{ - header("Location: /"); -} -exit(); \ No newline at end of file