mirror of
https://github.com/zyx0814/dzzoffice.git
synced 2025-01-05 10:27:33 +08:00
更新到 2.01
This commit is contained in:
parent
80c35ce30a
commit
6d4db4fab3
58
README.md
58
README.md
@ -2,7 +2,6 @@
|
||||
|
||||
### 官方网站:http://dzzoffice.com
|
||||
### 演示地址:http://demo.dzzoffice.com
|
||||
### Docker部署: [点我传送](https://github.com/n3uz/dzzoffice/blob/master/docker/README.MD)
|
||||
|
||||
### DzzOffice 介绍:
|
||||
|
||||
@ -34,4 +33,59 @@
|
||||
|
||||
企业根据需要可以只使用一款工具,也可以多款工具组合使用。例如团队需要一个任务管理工具,可以只安装一个任务板,登陆系统会直接进入任务板工具,没有其他工具的干扰。如果多个工具组合使用,可以设置默认登陆到哪个工具里。
|
||||
|
||||
除了以上自己开发了一些工具,套件里还集成了大量的其他开源工具,如网盘里用到的在线压缩、解压,各类媒体文件预览,各类文档预览与编辑的支持,是各类开源程序的综合利用。
|
||||
除了以上自己开发了一些工具,套件里还集成了大量的其他开源工具,如网盘里用到的在线压缩、解压,各类媒体文件预览,各类文档预览与编辑的支持,是各类开源程序的综合利用。
|
||||
|
||||
### DzzOffice2.01主要更新内容
|
||||
|
||||
1. 增加 云设置和管理 ,支持阿里云存储、七牛云存储、FTP/SFTP、本地磁盘等存储方式;
|
||||
|
||||
2. 增加 用户资料管理 ,支持自定义用户资料项,资料审核、认证和审核;
|
||||
|
||||
3. 修改应用市场应用在线安装方式,提高应用下载速度;
|
||||
|
||||
4. 增加伪静态支持,可以通过应用“伪静态管理”灵活配置各个页面的伪静态规则;
|
||||
|
||||
5. 机构和用户管理 优化添加部门管理员的体验;
|
||||
|
||||
6. 导入导出用户功能优化调整;
|
||||
|
||||
7. 部分页面移动端适配;
|
||||
|
||||
8. 增加首次安装引导页,引导管理员首次能正确配置系统;
|
||||
|
||||
9. 开放讨论板应用(可在应用市场内在线安装);
|
||||
|
||||
10. 开放任务板应用(可在应用市场内在线安装);
|
||||
|
||||
11. 其他功能完善、及beta版反馈问题的修复;
|
||||
|
||||
|
||||
### DzzOffice在线更新方法
|
||||
|
||||
1. 进入您原来的系统,关闭您的站点。进行数据备份;
|
||||
|
||||
2. 备份文件(如果有程序文件或风格文件的改动);
|
||||
|
||||
3. 进入 管理 -> 系统工具 -> 在线更新,按提示完成更新任务;
|
||||
|
||||
4. 系统工具 -> 更新系统缓存;
|
||||
|
||||
5. 系统设置 -> 打开站点。
|
||||
|
||||
### DzzOffice离线更新方法
|
||||
|
||||
1. 进入您原来的系统,关闭您的站点。进行数据备份;
|
||||
|
||||
2. 备份文件(如果有程序文件或风格文件的改动);
|
||||
|
||||
3. 下载并解压缩最新版的程序包;
|
||||
|
||||
4. 程序包解压缩后,并且将文件上传到网站根目录覆盖;
|
||||
|
||||
5. 访问 http://您的域名/install/update.php。
|
||||
|
||||
6. 按照程序提示,直至所有升级完毕。删除install/update.php 程序,以免被恶意利用。
|
||||
|
||||
7. 进入管理员桌面,更新缓存。
|
||||
|
||||
8. 系统设置 -> 打开站点。
|
||||
|
62
UPDATE.md
Normal file
62
UPDATE.md
Normal file
@ -0,0 +1,62 @@
|
||||
|
||||
|
||||
### DzzOffice的下载及技术支持
|
||||
|
||||
1. 官方网站: http://www.dzzoffice.com
|
||||
2. github地址:https://github.com/zyx0814/dzzoffice
|
||||
3. 码云地址: https://gitee.com/zyx0814/dzzoffice
|
||||
|
||||
### DzzOffice2.01主要更新内容
|
||||
|
||||
1. 增加 云设置和管理 ,支持阿里云存储、七牛云存储、FTP/SFTP、本地磁盘等存储方式;
|
||||
|
||||
2. 增加 用户资料管理 ,支持自定义用户资料项,资料审核、认证和审核;
|
||||
|
||||
3. 修改应用市场应用在线安装方式,提高应用下载速度;
|
||||
|
||||
4. 增加伪静态支持,可以通过应用“伪静态管理”灵活配置各个页面的伪静态规则;
|
||||
|
||||
5. 机构和用户管理 优化添加部门管理员的体验;
|
||||
|
||||
6. 导入导出用户功能优化调整;
|
||||
|
||||
7. 部分页面移动端适配;
|
||||
|
||||
8. 增加首次安装引导页,引导管理员首次能正确配置系统;
|
||||
|
||||
9. 开放讨论板应用(可在应用市场内在线安装);
|
||||
|
||||
10. 开放任务板应用(可在应用市场内在线安装);
|
||||
|
||||
11. 其他功能完善、及beta版反馈问题的修复;
|
||||
|
||||
|
||||
### DzzOffice在线更新方法
|
||||
|
||||
1. 进入您原来的系统,关闭您的站点。进行数据备份;
|
||||
|
||||
2. 备份文件(如果有程序文件或风格文件的改动);
|
||||
|
||||
3. 进入 管理 -> 系统工具 -> 在线更新,按提示完成更新任务;
|
||||
|
||||
4. 系统工具 -> 更新系统缓存;
|
||||
|
||||
5. 系统设置 -> 打开站点。
|
||||
|
||||
### DzzOffice离线更新方法
|
||||
|
||||
1. 进入您原来的系统,关闭您的站点。进行数据备份;
|
||||
|
||||
2. 备份文件(如果有程序文件或风格文件的改动);
|
||||
|
||||
3. 下载并解压缩最新版的程序包;
|
||||
|
||||
4. 程序包解压缩后,并且将文件上传到网站根目录覆盖;
|
||||
|
||||
5. 访问 http://您的域名/install/update.php。
|
||||
|
||||
6. 按照程序提示,直至所有升级完毕。删除install/update.php 程序,以免被恶意利用。
|
||||
|
||||
7. 进入管理员桌面,更新缓存。
|
||||
|
||||
8. 系统设置 -> 打开站点。
|
@ -34,7 +34,7 @@ if( $applist ){
|
||||
if( $v["upgrade_version"] ){
|
||||
$num++;
|
||||
}else{
|
||||
if( $v["mid"]==80 ){
|
||||
//if( $v["mid"]==80 ){
|
||||
//根据当前版本查询是否需要更新
|
||||
$info=array_merge($v,$appinfo);
|
||||
$response = $dzz_upgrade->check_upgrade_byversion( $info );
|
||||
@ -46,7 +46,7 @@ if( $applist ){
|
||||
$re=C::t('app_market')->update($v['appid'],$map);//C::tp_t('app_market')->where("appid=".$v['appid'])->save( $map );
|
||||
$num++;
|
||||
}
|
||||
}
|
||||
//}
|
||||
}
|
||||
}else{//本地检测
|
||||
$file = DZZ_ROOT . './'.$v['app_path'].'/' . $v['identifier'] . '/dzz_app_' . $v['identifier'] . '.xml';
|
||||
|
@ -10,6 +10,7 @@
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
//define('DZZ_OUTPUTED', 1);
|
||||
$navtitle=lang('appname');
|
||||
include libfile('function/organization');
|
||||
$op='cloudappmarket';
|
||||
@ -65,4 +66,29 @@ function curlcloudappmarket( $url="",$post_data="", $token="" ){
|
||||
}
|
||||
return($response);
|
||||
}
|
||||
|
||||
function striplinks($document)
|
||||
{
|
||||
preg_match_all("'<\s*a\s.*?href\s*=\s* # find <a href=
|
||||
([\"\'])? # find single or double quote
|
||||
(?(1) (.*?)\\1 | ([^\s\>]+)) # if quote found, match up to next matching
|
||||
# quote, otherwise match up to next space
|
||||
'isx", $document, $links);
|
||||
|
||||
|
||||
// catenate the non-empty matches from the conditional subpattern
|
||||
|
||||
while (list($key, $val) = each($links[2])) {
|
||||
if (!empty($val))
|
||||
$match[] = $val;
|
||||
}
|
||||
|
||||
while (list($key, $val) = each($links[3])) {
|
||||
if (!empty($val))
|
||||
$match[] = $val;
|
||||
}
|
||||
|
||||
// return the links
|
||||
return $match;
|
||||
}
|
||||
?>
|
||||
|
@ -76,7 +76,7 @@ elseif ($do == 'import') {//导入应用
|
||||
if ($apparray['app']['identifier']) {
|
||||
if(empty($apparray['app']['app_path'])) $apparray['app']['app_path']='dzz';
|
||||
if (!is_dir(DZZ_ROOT . './'.$apparray['app']['app_path'].'/' . $apparray['app']['identifier'])) {
|
||||
showmessage('list_cp_Application_directory_exist',array('app_path'=>$app['app_path'],'identifier'=>$app['identifier']));
|
||||
showmessage(lang('list_cp_Application_directory_exist',array('app_path'=>$app['app_path'],'identifier'=>$app['identifier'])));
|
||||
}
|
||||
$extra = $apparray['app']['extra'];
|
||||
$filename = $extra['installfile'];
|
||||
@ -255,7 +255,7 @@ elseif ($do == 'uninstall') {//卸载应用
|
||||
if (!empty($apparray['app']['extra']['uninstallfile']) && preg_match('/^[\w\.]+$/', $apparray['app']['extra']['uninstallfile'])) {
|
||||
$filename = $entrydir . '/' . $apparray['app']['extra']['uninstallfile'];
|
||||
if (file_exists($filename)) {
|
||||
$confirm_uninstall_url= MOD_URL.'&op=cp&do=uninstall_confirm&appid='.$appid.'&refer='.urlencode($refer);
|
||||
$confirm_uninstall_url= outputurl( $_G['siteurl'].MOD_URL.'&op=cp&do=uninstall_confirm&appid='.$appid.'&refer='.urlencode($refer) );
|
||||
@include $filename;
|
||||
} else {
|
||||
$finish = TRUE;
|
||||
@ -271,6 +271,9 @@ elseif ($do == 'uninstall') {//卸载应用
|
||||
if ($finish) {
|
||||
C::t('app_market') -> delete_by_appid($appid);
|
||||
cron_delete($app);
|
||||
//删除安装临时文件
|
||||
$temp_install=DZZ_ROOT.'./data/update/app/'.$app['app_path'].'/'.$app['identifier'];
|
||||
removedirectory($temp_install);
|
||||
writelog('otherlog', "卸载应用 ".$app['appname']);
|
||||
showmessage($msg, ADMINSCRIPT . '?mod=appmarket', array(), array('alert' => 'right'));
|
||||
}
|
||||
|
@ -1255,7 +1255,7 @@ GoAGoAFoABqABqABaAAagAagAWgAGoAG8L+seLyPK1YBDHscwLBVAD1sfaDpVtmQ+DMHEI2Ep4B2
|
||||
D0LYANolfmuDYDQSHgSOAc+AZZd3fFniPCZxpxSf/vO0ngZzW/4NAGb7tdo8MPIcAAAAAElFTkSu
|
||||
QmCC
|
||||
]]></item>
|
||||
<item id="appdesc"><![CDATA[]]></item>
|
||||
<item id="appdesc"><![CDATA[应用管理,应用市场,支持应用在线安装,在线升级等]]></item>
|
||||
<item id="appurl"><![CDATA[{adminscript}?mod=appmarket]]></item>
|
||||
<item id="appadminurl"><![CDATA[]]></item>
|
||||
<item id="noticeurl"><![CDATA[]]></item>
|
||||
|
53
admin/appmarket/function/function_appmarket.php
Normal file
53
admin/appmarket/function/function_appmarket.php
Normal file
@ -0,0 +1,53 @@
|
||||
<?php
|
||||
/* @authorcode codestrings
|
||||
* @copyright Leyun internet Technology(Shanghai)Co.,Ltd
|
||||
* @license http://www.dzzoffice.com/licenses/license.txt
|
||||
* @package DzzOffice
|
||||
* @link http://www.dzzoffice.com
|
||||
* @author qchlian(3580164@qq.com)
|
||||
*/
|
||||
if(!defined('IN_DZZ')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
|
||||
function dzzunzip($filename,$path,$md5file){
|
||||
if( file_exists( $filename )){//压缩包存在
|
||||
//打开压缩包
|
||||
$resource = zip_open($filename);
|
||||
$i = 1;
|
||||
//遍历读取压缩包里面的一个个文件
|
||||
while ($dir_resource = zip_read($resource)) {
|
||||
//如果能打开则继续
|
||||
if (zip_entry_open($resource,$dir_resource)) {
|
||||
//获取当前项目的名称,即压缩包里面当前对应的文件名
|
||||
$file_name = $path.zip_entry_name($dir_resource);
|
||||
//以最后一个“/”分割,再用字符串截取出路径部分
|
||||
$file_path = substr($file_name,0,strrpos($file_name, "/"));
|
||||
//如果路径不存在,则创建一个目录,true表示可以创建多级目录
|
||||
if(!is_dir($file_path)){
|
||||
mkdir($file_path,0777,true);
|
||||
}
|
||||
//如果不是目录,则写入文件
|
||||
if(!is_dir($file_name)){
|
||||
//读取这个文件
|
||||
if( $file_name==$md5file){
|
||||
continue; //排查md5文件,dzzmdfile会重新生成
|
||||
}
|
||||
$file_size = zip_entry_filesize($dir_resource);
|
||||
//最大读取6M,如果文件过大,跳过解压,继续下一个
|
||||
//if($file_size<(1024*1024*300)){
|
||||
$file_content = zip_entry_read($dir_resource,$file_size);
|
||||
if(file_exists( $file_name)){
|
||||
@unlink($file_name);
|
||||
}
|
||||
file_put_contents($file_name,$file_content);
|
||||
}
|
||||
//关闭当前
|
||||
zip_entry_close($dir_resource);
|
||||
}
|
||||
}
|
||||
//关闭压缩包
|
||||
zip_close($resource);
|
||||
}
|
||||
}
|
||||
?>
|
@ -9,11 +9,12 @@
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
error_reporting(E_ALL);
|
||||
|
||||
@set_time_limit(0);
|
||||
include_once DZZ_ROOT . './core/core_version.php';
|
||||
include_once libfile('function/admin');
|
||||
include_once libfile('function/cache');
|
||||
include_once libfile('function/cache');
|
||||
include_once libfile('function/appmarket');
|
||||
$step = intval($_GET['step']);
|
||||
$op = $_GET['op'];
|
||||
$step = $step ? $step : 1;
|
||||
@ -139,7 +140,7 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
exit(json_encode($return));
|
||||
exit();
|
||||
}
|
||||
|
||||
|
||||
$step = intval($_REQUEST['step']);
|
||||
$step = $step ? $step : 1;
|
||||
|
||||
@ -155,24 +156,15 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$upgrade_version = unserialize($appinfo["upgrade_version"]);
|
||||
$upgradeinfo = $upgrade_version[$operation];
|
||||
$appinfo["upgradeinfo"]=$upgradeinfo;*/
|
||||
|
||||
|
||||
$dzz_upgrade = new dzz_upgrade_app();
|
||||
if($step != 5) {
|
||||
$updatefilelist = $dzz_upgrade->fetch_installfile_list( $baseinfo );
|
||||
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
//$updatefilelist = $dzz_upgrade->fetch_installfile_list( $baseinfo );
|
||||
$theurl = ADMINSCRIPT . '?mod=appmarket&op=install_app_ajax&operation=' . $operation .'&locale=' . $locale . '&charset=' . $charset;
|
||||
}
|
||||
|
||||
if($step == 1) {
|
||||
$linkurl=$theurl. '&step=2';
|
||||
$updatefilelist=$updatefilelist ;
|
||||
if($step == 1) {
|
||||
$linkurl=$theurl. '&step=2';
|
||||
$return["percent"]=15;
|
||||
$return["second"]=1;
|
||||
$return["url"]=$linkurl;
|
||||
@ -183,32 +175,43 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
}
|
||||
|
||||
elseif($step == 2) {
|
||||
//start 下载zip.md5
|
||||
$updatefilelist = $dzz_upgrade->fetch_installapp_zip( $baseinfo );
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
//end
|
||||
|
||||
$return["msg"]=lang("app_upgrade_downloading");
|
||||
$return["step"]=2;
|
||||
$percent = 60;
|
||||
|
||||
$fileseq = intval($_GET['fileseq']);
|
||||
$fileseq = $fileseq ? $fileseq : 1;
|
||||
//$position = intval($_GET['position']);
|
||||
//$position = $position ? $position : 0;
|
||||
//$offset = 1000 * 1024;
|
||||
|
||||
$position = intval($_GET['position']);
|
||||
$position = $position ? $position : 0;
|
||||
$offset = 1024 * 1024;
|
||||
$packagesize = $baseinfo["packagesize"];
|
||||
if($fileseq > count($updatefilelist)) {
|
||||
$linkurl = $theurl.'&step=3';
|
||||
$percent = 100;
|
||||
$return["step"]=3;
|
||||
$return["msg"]= lang('app_upgrade_download_complete', array('upgradeurl' => upgradeinformation_app(6)));
|
||||
} else {
|
||||
$downloadstatus = $dzz_upgrade->download_file($baseinfo, $updatefilelist[$fileseq-1], '', $updatemd5filelist[$fileseq-1]);//, $position, $offset);
|
||||
$downloadstatus = $dzz_upgrade->download_file($baseinfo, $updatefilelist[$fileseq-1], '', $updatemd5filelist[$fileseq-1] , $position, $offset);
|
||||
if($downloadstatus == 1) {
|
||||
$linkurl = $theurl.'&step=2&fileseq='.$fileseq.'&position='.($position+$offset);
|
||||
$percent = 60+sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$percent = 60+ sprintf("%2d", 40 * $position/$packagesize);//60+sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$file = $updatefilelist[$fileseq-1];
|
||||
} elseif($downloadstatus == 2) {
|
||||
$linkurl = $theurl.'&step=2&fileseq='.($fileseq+1);
|
||||
$percent = 60+sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$percent = 60+ sprintf("%2d", 40 * $position/$packagesize);//60+sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$file = $updatefilelist[$fileseq-1];
|
||||
} else {
|
||||
} else {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_downloading_error', array('file' => $updatefilelist[$fileseq-1], 'upgradeurl'=>upgradeinformation_app(-3) )) ;
|
||||
exit(json_encode($return));
|
||||
@ -228,19 +231,37 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$return["second"]=1;
|
||||
$return["msg"]= lang("app_upgrade_check_download_complete");
|
||||
$return["step"]=3;
|
||||
//此处应检查验证是否下载完毕所有更新文件
|
||||
//此处应下载压缩包内文件的md5文件
|
||||
$updatefilelist = $dzz_upgrade->fetch_installfile_list( $baseinfo );
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
//解压压缩包
|
||||
$zippath= DZZ_ROOT . 'data/update/app/'.$baseinfo["app_path"].'/'.$baseinfo["identifier"].'/'.$baseinfo['version'].'/';
|
||||
$zipfile=$zippath.$baseinfo["identifier"].".zip";
|
||||
$md5file =$zippath.$baseinfo["identifier"].".md5.dzz";
|
||||
dzzunzip($zipfile,$zippath,$md5file);
|
||||
|
||||
|
||||
$linkurl = $theurl.'&step=4';
|
||||
$return["url"]=$linkurl;
|
||||
exit(json_encode($return));
|
||||
exit;
|
||||
}
|
||||
elseif($step==4){
|
||||
elseif($step==4){
|
||||
$return["percent"]=80;
|
||||
$return["second"]=1;
|
||||
$return["msg"]= lang("app_upgrade_installing");
|
||||
$return["step"]=4;
|
||||
|
||||
//start 下载更新文件的.md5
|
||||
$updatefilelist = $dzz_upgrade->fetch_installfile_list( $baseinfo );
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
//end
|
||||
|
||||
|
||||
$confirm = $_GET['confirm'];
|
||||
if (!$confirm) {
|
||||
$checkupdatefilelist = $updatefilelist;
|
||||
|
@ -196,7 +196,7 @@
|
||||
}
|
||||
|
||||
function start_check_install(url,mid,data){
|
||||
jQuery.post({
|
||||
jQuery.ajax({
|
||||
type:'post',
|
||||
async: true,
|
||||
url:url,
|
||||
@ -300,7 +300,7 @@
|
||||
}
|
||||
|
||||
function start_check_upgrade(url,mid){
|
||||
jQuery.post({
|
||||
jQuery.ajax({
|
||||
type:'post',
|
||||
async: true,
|
||||
url:url,
|
||||
|
@ -126,7 +126,8 @@
|
||||
if( jQuery(obj).hasClass("isdefault1") ){
|
||||
return false;
|
||||
}
|
||||
jQuery.post({
|
||||
jQuery.ajax({
|
||||
type:'post',
|
||||
url:'{MOD_URL}&op=extopen',
|
||||
data:{'extid':extid ,'do':'setdefault'},
|
||||
success:function(json){
|
||||
|
@ -103,7 +103,7 @@
|
||||
<div class="bs-main-container">
|
||||
<div class="all-center-top clearfix">
|
||||
<div class="app-info pull-left">
|
||||
<a href="{BASESCRIPT}?mod=appmarket">{lang total}<span class="num">$count</span>{lang ge}{lang app}</a>
|
||||
<a href="{MOD_URL}">{lang total}<span class="num">$count</span>{lang ge}{lang app}</a>
|
||||
<span class="select-info">{lang selected}<span class="num">$count</span>{lang ge}{lang app}</span>
|
||||
</div>
|
||||
|
||||
@ -123,7 +123,7 @@
|
||||
</div>
|
||||
|
||||
<div class="group-filter dropdown pull-right">
|
||||
<a href="{BASESCRIPT}?mod=appmarket&group=$group" data-toggle="dropdown" role="button" id="drop-group" class="dropdown-toggle btn btn-link">{eval echo $group?$grouptitle[$group]:lang('group_permissions');}<b class="caret"></b></a>
|
||||
<a href="{MOD_URL}&group=$group" data-toggle="dropdown" role="button" id="drop-group" class="dropdown-toggle btn btn-link">{eval echo $group?$grouptitle[$group]:lang('group_permissions');}<b class="caret"></b></a>
|
||||
<ul aria-labelledby="drop-group" role="menu" class="dropdown-menu" id="drop-group-menu">
|
||||
<!--{loop $grouptitle $key $value}-->
|
||||
<li role="presentation">
|
||||
@ -134,14 +134,14 @@
|
||||
</div>
|
||||
|
||||
<div class="button_add_content">
|
||||
<a href="{BASESCRIPT}?mod=appmarket&op=edit&do=add&refer=$refer" id="button_add1" title="{lang add_app}" class="hide">+</a>
|
||||
<a href="{BASESCRIPT}?mod=appmarket&op=import&refer=$refer" id="button_add2" class="hide" title="{lang import_type_app}" style="font-size:20px ;"><i class="glyphicon glyphicon-download-alt"></i></a>
|
||||
<a href="{MOD_URL}&op=edit&do=add&refer=$refer" id="button_add1" title="{lang add_app}" class="hide">+</a>
|
||||
<a href="{MOD_URL}&op=import&refer=$refer" id="button_add2" class="hide" title="{lang import_type_app}" style="font-size:20px ;"><i class="glyphicon glyphicon-download-alt"></i></a>
|
||||
<a href="javascript:;" id="button_add" style="z-index: 10;">+</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="main-content clearfix" style="border-top:1px solid #FFF;padding:0;">
|
||||
<form id="appform" name="appform" class="form-horizontal" action="{BASESCRIPT}?mod=appmarket" method="post">
|
||||
<form id="appform" name="appform" class="form-horizontal" action="{MOD_URL}" method="post">
|
||||
<input type="hidden" name="appsubmit" value="true" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<table class="table table-hover">
|
||||
@ -158,8 +158,11 @@
|
||||
<td>
|
||||
<a href="$value[appurl]" target="_blank" class="appicon" style="float: left;padding-right: 5px;"><img src="$value[appico]" style="margin:0" /></a>
|
||||
<p class="appname">
|
||||
<a href="$value[appurl]" target="_blank" class="">$value[appname]</a>
|
||||
<!--{if $value[appadminurl]}--><a href="$value[appadminurl]" target="_blank" style="color: #999;">(设置)</a><!--{/if}-->
|
||||
<!--{if $value[appadminurl]}-->
|
||||
<a href="$value[appadminurl]" target="_blank" >$value[appname]</a>
|
||||
<!--{else}-->
|
||||
<a href="$value[appurl]" target="_blank" >$value[appname]</a>
|
||||
<!--{/if}-->
|
||||
</p>
|
||||
<div class="appdesc" title="$value['appdesc']">{eval echo $value['appdesc']?$value['appdesc']:lang('none');}</div>
|
||||
<!-- </div> -->
|
||||
@ -168,7 +171,7 @@
|
||||
<td>
|
||||
<div class="tag-td-wrapper">
|
||||
<!--{loop $value[tags] $key $value1}-->
|
||||
<a href="{BASESCRIPT}?mod=appmarket&tagid=$value1[tagid]">$value1[tagname]</a>
|
||||
<a href="{MOD_URL}&tagid=$value1[tagid]">$value1[tagname]</a>
|
||||
<!--{/loop}-->
|
||||
</div>
|
||||
</td>
|
||||
@ -192,22 +195,25 @@
|
||||
</td>
|
||||
|
||||
<td>
|
||||
<a class="btn btn-primary-outline btn-small" href="{BASESCRIPT}?mod=appmarket&op=edit&do=edit&appid=$value[appid]&refer=$refer" title="{lang edit}">{lang edit}</a>
|
||||
<a class="btn btn-primary-outline btn-small" href="{BASESCRIPT}?mod=appmarket&op=cp&do=export&appid=$value[appid]&refer=$refer" title="{lang export}" target="_blank">{lang export}</a>
|
||||
<!--{if $value[appadminurl]}-->
|
||||
<a class="btn btn-small btn-info-outline" href="$value[appadminurl]">设置</a>
|
||||
<!--{/if}-->
|
||||
<a class="btn btn-primary-outline btn-small" href="{MOD_URL}&op=edit&do=edit&appid=$value[appid]&refer=$refer" title="{lang edit}">{lang edit}</a>
|
||||
|
||||
|
||||
<!--{if $value["system"]!=2}-->
|
||||
<!--{if $value["available"]==1}-->
|
||||
<a class="btn btn-warning-outline btn-small" href="{BASESCRIPT}?mod=appmarket&op=cp&do=disable&appid=$value[appid]&refer=$refer" title="{lang close}">{lang close}</a>
|
||||
<a class="btn btn-warning-outline btn-small" href="{MOD_URL}&op=cp&do=disable&appid=$value[appid]&refer=$refer" title="{lang close}">{lang close}</a>
|
||||
<!--{else}-->
|
||||
<a class="btn btn-success-outline btn-small" href="{BASESCRIPT}?mod=appmarket&op=cp&do=enable&appid=$value[appid]&refer=$refer" title="{lang enable}">{lang enable}</a>
|
||||
<a class="btn btn-danger-outline btn-small" href="{BASESCRIPT}?mod=appmarket&op=cp&do=uninstall&appid=$value[appid]&refer=$refer" title="{lang uninstall}" onclick="if(confirm('{lang list_uninstall_application}'))return true;else return false">{lang uninstall}</a>
|
||||
<a class="btn btn-success-outline btn-small" href="{MOD_URL}&op=cp&do=enable&appid=$value[appid]&refer=$refer" title="{lang enable}">{lang enable}</a>
|
||||
<a class="btn btn-danger-outline btn-small" href="{MOD_URL}&op=cp&do=uninstall&appid=$value[appid]&refer=$refer" title="{lang uninstall}" onclick="if(confirm('{lang list_uninstall_application}'))return true;else return false">{lang uninstall}</a>
|
||||
<!--{/if}-->
|
||||
<!--{else}-->
|
||||
<!--{if $value["available"]!=1}-->
|
||||
<a class="btn btn-small btn-success-outline" href="{BASESCRIPT}?mod=appmarket&op=cp&do=enable&appid=$value[appid]&refer=$refer" title="{lang enable}">{lang enable}</a>
|
||||
<a class="btn btn-small btn-success-outline" href="{MOD_URL}&op=cp&do=enable&appid=$value[appid]&refer=$refer" title="{lang enable}">{lang enable}</a>
|
||||
<!--{/if}-->
|
||||
<!--{/if}-->
|
||||
|
||||
<!--<a class="btn btn-success-outline hidden" id="{$value[appid]}_update" href="{BASESCRIPT}?mod=appmarket&op=upgrade_app&operation=upgrade&appid=$value[appid]&checking=1&refer=$refer" title="{lang update}">{lang update}</a>-->
|
||||
<a class="btn btn-primary-outline btn-small" href="{MOD_URL}&op=cp&do=export&appid=$value[appid]&refer=$refer" title="{lang export}" target="_blank">{lang export}</a>
|
||||
</td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
@ -224,7 +230,7 @@
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
function screen_app(tagid,group){
|
||||
var url = '{BASESCRIPT}?mod=appmarket';
|
||||
var url = MOD_URL;
|
||||
if(tagid){
|
||||
url += '&tagid='+tagid;
|
||||
}
|
||||
@ -246,7 +252,7 @@
|
||||
jQuery.post({
|
||||
type:'post',
|
||||
async: true,
|
||||
url:'{BASESCRIPT}?mod=appmarket&op=upgrade_app_ajax&operation=check_upgrade&appid='+appid+'&t='+new Date().getTime(),
|
||||
url:'{MOD_URL}&op=upgrade_app_ajax&operation=check_upgrade&appid='+appid+'&t='+new Date().getTime(),
|
||||
data:{},
|
||||
success:function(json){
|
||||
if(json.status==0){
|
||||
|
@ -280,8 +280,8 @@
|
||||
nowupgradeappid=appid;
|
||||
}
|
||||
|
||||
jQuery.post({
|
||||
type:'json',
|
||||
jQuery.ajax({
|
||||
type:'GET',
|
||||
async: false,
|
||||
url:url,
|
||||
data:{},
|
||||
@ -311,7 +311,7 @@
|
||||
|
||||
function startupgrade(url,s){
|
||||
jQuery.ajax({
|
||||
type:'json',
|
||||
type:'GET',
|
||||
async: false,
|
||||
url:url,
|
||||
data:{},
|
||||
@ -331,7 +331,7 @@
|
||||
|
||||
function startgetcrossorpatchfile(url,s){
|
||||
jQuery.ajax({
|
||||
type:'json',
|
||||
type:'GET',
|
||||
async: false,
|
||||
url:url,
|
||||
data:{},
|
||||
@ -355,7 +355,7 @@
|
||||
|
||||
function startupgradefile(url,s){
|
||||
jQuery.ajax({
|
||||
type:'json',
|
||||
type:'GET',
|
||||
async: false,
|
||||
url:url,
|
||||
data:{},
|
||||
@ -379,7 +379,7 @@
|
||||
|
||||
function upgradeover(url,s){
|
||||
jQuery.ajax({
|
||||
type:'json',
|
||||
type:'GET',
|
||||
async: false,
|
||||
url:url,
|
||||
data:{},
|
||||
|
@ -9,11 +9,12 @@
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
error_reporting(E_ALL);
|
||||
|
||||
@set_time_limit(0);
|
||||
include_once DZZ_ROOT . './core/core_version.php';
|
||||
include_once libfile('function/admin');
|
||||
include_once libfile('function/cache');
|
||||
include_once libfile('function/cache');
|
||||
include_once libfile('function/appmarket');
|
||||
$step = intval($_GET['step']);
|
||||
$op = $_GET['op'];
|
||||
$step = $step ? $step : 1;
|
||||
@ -234,12 +235,11 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$dzz_upgrade = new dzz_upgrade_app();
|
||||
if($step != 5 && !$_GET['fileupgrade'] ) {//$_GET['fileupgrade']是判断还未移动文件。因为移动文件后 updatefilelist 为空
|
||||
//获取新版本文件列表
|
||||
$updatefilelist = $dzz_upgrade->fetch_updatefile_list_bymd5($appinfo);
|
||||
/*$updatefilelist = $dzz_upgrade->fetch_updatefile_list_bymd5($appinfo);
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
//echo "更新文件丢失";exit;
|
||||
exit(json_encode($return));
|
||||
}
|
||||
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
@ -252,12 +252,12 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_exchange_none', array('upgradeurl' => upgradeinformation_app(-9)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
}*/
|
||||
$theurl = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=' . $operation . '&appid=' .$appid. '&locale=' . $locale . '&charset=' . $charset;
|
||||
}
|
||||
|
||||
if($step == 1) {
|
||||
$linkurl=$theurl. '&step=2';
|
||||
$updatefilelist=$updatefilelist ;
|
||||
$linkurl=$theurl. '&step=2';
|
||||
$return["percent"]=15;
|
||||
$return["second"]=1;
|
||||
$return["url"]=$linkurl;
|
||||
@ -268,31 +268,43 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
}
|
||||
|
||||
elseif($step == 2) {
|
||||
//start 下载zip.md5
|
||||
$updatefilelist = $dzz_upgrade->fetch_installapp_zip( $upgradeinfo );
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
//end
|
||||
|
||||
$return["msg"]= lang('app_upgrade_downloading' );
|
||||
$return["step"]=2;
|
||||
$percent = 60;
|
||||
|
||||
$fileseq = intval($_GET['fileseq']);
|
||||
$fileseq = $fileseq ? $fileseq : 1;
|
||||
$fileseq = $fileseq ? $fileseq : 1;
|
||||
$position = intval($_GET['position']);
|
||||
$position = $position ? $position : 0;
|
||||
$offset = 1024 * 1024;
|
||||
$packagesize = $upgradeinfo["packagesize"];
|
||||
|
||||
if($fileseq > count($updatefilelist)) {
|
||||
/*if($upgradeinfo['isupdatedb']) {
|
||||
$downloadstatus=$dzz_upgrade->download_file($appinfo, 'update.php');
|
||||
}*/
|
||||
if($fileseq > count($updatefilelist)) {
|
||||
$linkurl = $theurl.'&step=3';
|
||||
$percent = 100;
|
||||
$return["step"]=3;
|
||||
$return["msg"]=lang('app_upgrade_download_complete', array('upgradeurl' => upgradeinformation_app(6)));
|
||||
} else {
|
||||
$downloadstatus = $dzz_upgrade->download_file($appinfo, $updatefilelist[$fileseq-1], '', $updatemd5filelist[$fileseq-1]);//, $position, $offset);
|
||||
$downloadstatus = $dzz_upgrade->download_file($appinfo, $updatefilelist[$fileseq-1], '', $updatemd5filelist[$fileseq-1] , $position, $offset);
|
||||
|
||||
if($downloadstatus == 1) {
|
||||
$linkurl = $theurl.'&step=2&fileseq='.$fileseq.'&position='.($position+$offset);
|
||||
$percent =60+ sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$percent =60+ sprintf("%2d", 40 * $position/$packagesize);//60+ sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$file = $updatefilelist[$fileseq-1];
|
||||
} elseif($downloadstatus == 2) {
|
||||
$linkurl = $theurl.'&step=2&fileseq='.($fileseq+1);
|
||||
$percent =60+ sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$percent =60+ sprintf("%2d", 40 * $position/$packagesize);//60+ sprintf("%2d", 40 * $fileseq/count($updatefilelist));
|
||||
$file = $updatefilelist[$fileseq-1];
|
||||
} else {
|
||||
$return["status"]=0;
|
||||
@ -313,7 +325,36 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$return["percent"]=55;
|
||||
$return["second"]=300;
|
||||
$return["msg"]= lang('app_upgrade_newversion_ing' );
|
||||
$return["step"]=3;
|
||||
$return["step"]=3;
|
||||
|
||||
//start此处应下载压缩包内文件的md5文件 并对比
|
||||
$updatefilelist = $dzz_upgrade->fetch_updatefile_list_bymd5($appinfo);
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_none', array('upgradeurl' => upgradeinformation_app(-1)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
|
||||
//与本地文件对比过滤出更新文件
|
||||
list($updatefilelist, $updatemd5filelist) = $dzz_upgrade->compare_basefile_bymd5($appinfo, $updatefilelist,$updatemd5filelist);
|
||||
$theurl = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=' . $operation . '&appid=' .$appid. '&locale=' . $locale . '&charset=' . $charset;
|
||||
if(empty($updatefilelist)) {
|
||||
$return["status"]=0;
|
||||
$return["msg"]= lang('app_upgrade_exchange_none', array('upgradeurl' => upgradeinformation_app(-9)));
|
||||
exit(json_encode($return));
|
||||
}
|
||||
//end
|
||||
|
||||
//start 解压压缩包
|
||||
$zippath= DZZ_ROOT . 'data/update/app/'.$upgradeinfo["app_path"].'/'.$upgradeinfo["identifier"].'/'.$upgradeinfo['version'].'/';
|
||||
$zipfile=$zippath.$upgradeinfo["identifier"].".zip";
|
||||
$md5file =$zippath.$upgradeinfo["identifier"].".md5.dzz";
|
||||
dzzunzip($zipfile,$zippath,$md5file);
|
||||
//end
|
||||
|
||||
$linkurl = $theurl.'&step=4';
|
||||
$return["url"]=$linkurl;
|
||||
exit(json_encode($return));
|
||||
@ -325,6 +366,12 @@ elseif($operation == 'cross' || $operation == 'patch'){
|
||||
$return["msg"]=lang('app_upgrade_newversion_ing' );
|
||||
$return["step"]=4;
|
||||
|
||||
$updatefilelist = $dzz_upgrade->fetch_updatefile_list_bymd5($appinfo);
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
//与本地文件对比过滤出更新文件
|
||||
list($updatefilelist, $updatemd5filelist) = $dzz_upgrade->compare_basefile_bymd5($appinfo, $updatefilelist,$updatemd5filelist);
|
||||
|
||||
$confirm = $_GET['confirm'];
|
||||
if (!$confirm) {
|
||||
$checkupdatefilelist = $updatefilelist;
|
||||
|
45
admin/cloud/add.php
Normal file
45
admin/cloud/add.php
Normal file
@ -0,0 +1,45 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$operation='setting';
|
||||
|
||||
if(submitcheck('addcloudsubmit')){
|
||||
$_GET=dhtmlspecialchars($_GET);
|
||||
$error=array();
|
||||
if(empty($_GET['name'])){
|
||||
$error[] = lang('name_cannot_empty');
|
||||
}
|
||||
if(empty($_GET['bz'])){
|
||||
$error[] = lang('identifier_can_not_empty');
|
||||
}
|
||||
if(DB::result_first("select COUNT(*) from ".DB::table('connect')." where bz='{$_GET[bz]}'")){
|
||||
$error[] = lang('designator') . $_GET['bz'] . lang('already_existed');
|
||||
}
|
||||
if ($error)
|
||||
showmessage(implode('<br>', $error), dreferer());
|
||||
if($_GET['type']=='pan'){
|
||||
$setarr = array('name' => $_GET['name'], 'root' => trim($_GET['root']), 'key' => trim($_GET['key']), 'secret' => trim($_GET['secret']));
|
||||
|
||||
}elseif($_GET['type']=='storage'){
|
||||
$setarr = array('name' => $_GET['name']);
|
||||
}elseif($_GET['type']=='ftp'){
|
||||
$setarr = array('name' => $_GET['name']);
|
||||
}
|
||||
$setarr['bz']=$_GET['bz'];
|
||||
$setarr['dname']=$_GET['dname'];
|
||||
$setarr['type']=$_GET['type'];
|
||||
$setarr['available']=0;
|
||||
C::t('connect')->insert($setarr);
|
||||
|
||||
showmessage('do_success',BASESCRIPT.'?mod=cloud');
|
||||
}
|
||||
include template('add');
|
||||
?>
|
1284
admin/cloud/dzz_app_cloud.xml
Normal file
1284
admin/cloud/dzz_app_cloud.xml
Normal file
File diff suppressed because it is too large
Load Diff
127
admin/cloud/edit.php
Normal file
127
admin/cloud/edit.php
Normal file
@ -0,0 +1,127 @@
|
||||
<?php
|
||||
/*
|
||||
* @copyright Leyun internet Technology(Shanghai)Co.,Ltd
|
||||
* @license http://www.dzzoffice.com/licenses/license.txt
|
||||
* @package DzzOffice
|
||||
* @version DzzOffice 1.1 release 2014.7.05
|
||||
* @link http://www.dzzoffice.com
|
||||
* @author zyx(zyx@dzz.cc)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
|
||||
if($_GET['do']=='usercloud'){
|
||||
$bz=trim($_GET['bz']);
|
||||
$cloud=C::t('connect')->fetch($bz);
|
||||
$navtitle=$cloud['name'].' - '.lang('using_user');
|
||||
if(submitcheck('cloudsubmit')){
|
||||
$dids=$_GET['delete'];
|
||||
foreach($dids as $id){
|
||||
C::t($cloud['dname'])->delete_by_id($id);
|
||||
}
|
||||
showmessage('do_success',dreferer());
|
||||
}else{
|
||||
$list=array();
|
||||
|
||||
$page = empty($_GET['page'])?1:intval($_GET['page']);
|
||||
$perpage=20;
|
||||
$start=($page-1)*$perpage;
|
||||
$theurl=BASESCRIPT.'?mod=cloud&op=edit&do=usercloud&bz='.$bz;
|
||||
$dname=$cloud['dname'];
|
||||
$count=DB::result_first("select COUNT(*) from ".DB::table($dname)." where bz='{$bz}' and uid>0");
|
||||
foreach(DB::fetch_all("select * from ".DB::table($dname)." where bz='{$bz}' and uid>0 order by dateline DESC limit $start,$perpage") as $value1){
|
||||
if($cloud['type']=='pan'){
|
||||
if(!$value1['cloudname']) $value1['cloudname']=$cloud['name'].':'.($value1['cusername']?$value1['cusername']:$value1['cuid']);
|
||||
$value1['bz']=$value['bz'];
|
||||
$value1['icoid']=md5($value['bz'].':'.$value1['id'].':'.$value['root']);
|
||||
$value1['img']='dzz/images/default/system/'.$cloud['bz'].'.png';
|
||||
|
||||
}elseif($cloud['type']=='storage'){
|
||||
$value1['access_id']=authcode($value1['access_id'],'DECODE',$value1['type'])?authcode($value1['access_id'],'DECODE',$value1['type']):$value1['access_id'];
|
||||
if(!$value1['cloudname']) $value1['cloudname']=$cloud['name'].':'.($value1['bucket']?$value1['bucket']:cutstr($value1['access_id'], 4, $dot = ''));
|
||||
$value1['bz']=$value['bz'];
|
||||
$value1['img']='dzz/images/default/system/'.$cloud['bz'].'.png';
|
||||
}else{
|
||||
|
||||
$value1['bz']=$value['bz'];
|
||||
$value1['img']='dzz/images/default/system/'.$cloud['bz'].'.png';
|
||||
}
|
||||
$user=getuserbyuid($value1['uid']);
|
||||
$value1['username']=$user['username'];
|
||||
$value1['dateline']=dgmdate($value1['dateline']);
|
||||
$list[]=$value1;
|
||||
}
|
||||
$multi=multi($count, $perpage, $page, $theurl,'pull-right');
|
||||
include template('edit');
|
||||
}
|
||||
}elseif($_GET['do']=='getBucket'){
|
||||
$id=$_GET['id'];
|
||||
$key=$_GET['key'];
|
||||
if($re=io_ALIOSS::getBucketList($id,$key)){
|
||||
echo json_encode($re);
|
||||
}else{
|
||||
echo json_encode(array());
|
||||
}
|
||||
exit();
|
||||
|
||||
}else{
|
||||
$bz=$_GET['bz'];
|
||||
$cloud=C::t('connect')->fetch($bz);
|
||||
$navtitle=$cloud['name'].' - '.lang('set');
|
||||
if(submitcheck('editsubmit')){
|
||||
$_GET=dhtmlspecialchars($_GET);
|
||||
if($cloud['type']=='pan'){
|
||||
$setarr=array(
|
||||
'name'=>$_GET['name'],
|
||||
'root'=>trim($_GET['root']),
|
||||
'key'=>trim($_GET['key']),
|
||||
'secret'=>trim($_GET['secret']),
|
||||
'available'=>intval($_GET['available']),
|
||||
);
|
||||
if(empty($setarr['key']) || empty($setarr['secret'])) {
|
||||
$setarr['available']=0;
|
||||
}
|
||||
|
||||
}elseif($cloud['type']=='storage' || $cloud['type']=='ftp'){
|
||||
$setarr=array(
|
||||
'name'=>$_GET['name'],
|
||||
'available'=>intval($_GET['available'])>1?2:1,
|
||||
);
|
||||
}elseif($cloud['type']=='local'){
|
||||
$setarr=array(
|
||||
'name'=>$_GET['name'],
|
||||
'available'=>1,
|
||||
);
|
||||
}else{
|
||||
$setarr=array(
|
||||
'name'=>$_GET['name'],
|
||||
'available'=>intval($_GET['available'])>1?2:1,
|
||||
);
|
||||
}
|
||||
if(!is_file(DZZ_ROOT.'./core/class/io/io_'.($cloud['bz']).'.php')){
|
||||
$setarr['available']=0;
|
||||
}
|
||||
C::t('connect')->update($bz,$setarr);
|
||||
/*if($cloud['type']=='local'){//更新缓存$_G['setting']['storage'];
|
||||
$settings['storage']=array('on'=>$setarr['available']>1?'1':'0',
|
||||
'ACCESS_ID'=>$setarr['id'],
|
||||
'ACCESS_KEY'=>$setarr['secret'],
|
||||
'BUCKET'=>$setarr['root']
|
||||
);
|
||||
if($settings) {
|
||||
C::t('setting')->update_batch($settings);
|
||||
}
|
||||
include libfile('function/cache');
|
||||
updatecache('setting');
|
||||
}*/
|
||||
showmessage('do_success',dreferer());
|
||||
}else{
|
||||
|
||||
if(!is_file(DZZ_ROOT.'./core/class/io/io_'.($cloud['bz']).'.php')){
|
||||
$cloud['warning'] = lang('cloud_index_api') . ($cloud['bz']) . lang('cloud_edit_php');
|
||||
}
|
||||
include template('edit');
|
||||
}
|
||||
}
|
||||
?>
|
44
admin/cloud/images/connect.css
Normal file
44
admin/cloud/images/connect.css
Normal file
@ -0,0 +1,44 @@
|
||||
|
||||
.menu{ width:100px;}
|
||||
.menu-text{width:70px;}
|
||||
|
||||
|
||||
.thumbnails .cloud-item{
|
||||
margin:15px;
|
||||
width:165px;
|
||||
float:left;
|
||||
}
|
||||
.thumbnails>li img{
|
||||
cursor:pointer;
|
||||
}
|
||||
.thumbnails>li.hover .thumbnail{
|
||||
background:#F7F7F7;
|
||||
}
|
||||
.thumbnails>li.Selected .thumbnail {
|
||||
background:#F7F7F7/*RGBA(200,200,200,0.8)*/;
|
||||
|
||||
}
|
||||
.thumbnails .thumbnail{
|
||||
position:relative;
|
||||
}
|
||||
.thumbnails>li .selectbox{
|
||||
position:absolute;
|
||||
width:16px;
|
||||
height:16px;
|
||||
right:0px;
|
||||
top:0px;
|
||||
background:url(checkbox.png) no-repeat;
|
||||
display:none;
|
||||
}
|
||||
|
||||
.thumbnails>li.hover .selectbox {
|
||||
display:block;
|
||||
}
|
||||
.thumbnails>li.Selected .selectbox{
|
||||
background:url(selected_folder.png) no-repeat;
|
||||
display:block;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
60
admin/cloud/index.php
Normal file
60
admin/cloud/index.php
Normal file
@ -0,0 +1,60 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$operation=trim($_GET['operation']);
|
||||
$navtitle=lang('cloud_set');
|
||||
if(empty($operation)) $operation='setting';
|
||||
if($operation=='setting'){
|
||||
if(!submitcheck('cloudsubmit')){
|
||||
$list=array();
|
||||
foreach(DB::fetch_all("select * from ".DB::table('connect')." where 1 order by disp") as $value){
|
||||
|
||||
if($value['type']=='pan' && (empty($value['key']) || empty($value['secret']))){
|
||||
$value['available']=0;
|
||||
$value['warning'] = lang('please_open_after_setting');
|
||||
}
|
||||
if(!is_file(DZZ_ROOT.'./core/class/io/io_'.($value['bz']).'.php')){
|
||||
$value['warning'] = lang('cloud_index_api') . ($value['bz']) . lang('cloud_index_php');
|
||||
}
|
||||
$list[]=$value;
|
||||
}
|
||||
}else{
|
||||
$_GET=dhtmlspecialchars($_GET);
|
||||
foreach($_GET['name'] as $bz => $value){
|
||||
if(empty($value)) continue;
|
||||
$setarr=array('name'=>$value,
|
||||
'disp'=>intval($_GET['disp'][$bz]),
|
||||
'available'=>intval($_GET['available'][$bz])
|
||||
);
|
||||
if($bz=='dzz' && $setarr['available']<1) $setarr['available']=1;
|
||||
//没有定义api文件不能开启
|
||||
if(!is_file(DZZ_ROOT.'./core/class/io/io_'.($bz).'.php')) $setarr['available']=0;
|
||||
$connect=C::t('connect')->fetch($bz);
|
||||
//网盘类没有设置key或secret 不能启用
|
||||
if($connect['type']=='pan' && (empty($connect['key']) || empty($connect['secret']))){
|
||||
$setarr['available']=0;
|
||||
}
|
||||
C::t('connect')->update($bz,$setarr);
|
||||
}
|
||||
showmessage('do_success',dreferer());
|
||||
}
|
||||
}elseif($operation=='delete'){
|
||||
$bz=trim($_GET['bz']);
|
||||
if(is_file(DZZ_ROOT.'./core/class/io/io_'.($bz).'.php')){
|
||||
showmessage(lang('cloud_index_sign') . $bz . lang('cloud_index_sign1') . DZZ_ROOT . './core/class/io/io_' . ($bz) . lang('cloud_index_sig2'), dreferer());
|
||||
}
|
||||
C::t('connect')->delete_by_bz($bz);
|
||||
showmessage('delete_success', dreferer());
|
||||
|
||||
}
|
||||
|
||||
include template('cloud');
|
||||
?>
|
5
admin/cloud/language/zh-cn/lang.php
Normal file
5
admin/cloud/language/zh-cn/lang.php
Normal file
@ -0,0 +1,5 @@
|
||||
<?php
|
||||
$lang = array (
|
||||
'appname'=>'云设置和管理',
|
||||
);
|
||||
?>
|
66
admin/cloud/movetool.php
Normal file
66
admin/cloud/movetool.php
Normal file
@ -0,0 +1,66 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$navtitle=lang('migration_tool');
|
||||
if(submitcheck('movesubmit')){
|
||||
$_GET=dhtmlspecialchars($_GET);
|
||||
$gets = array(
|
||||
'mod'=>'cloud',
|
||||
'op'=>'movetool_run',
|
||||
'oremoteid'=>intval($_GET['oremoteid']),
|
||||
'remoteid' =>intval($_GET['remoteid']),
|
||||
'exts'=>trim($_GET['router']['exts']),
|
||||
'sizelt'=>$_GET['router']['size']['lt'],
|
||||
'sizegt'=>$_GET['router']['size']['gt'],
|
||||
);
|
||||
$runurl = BASESCRIPT."?".url_implode($gets);
|
||||
if(!$sourcedata=C::t('local_storage')->fetch_by_remoteid($gets['oremoteid'])){
|
||||
showmessage('storage_location_exist', dreferer());
|
||||
}
|
||||
$sourcedata['fusesize']=formatsize($sourcedata['usesize']);
|
||||
if ($sourcedata['totalsize'])
|
||||
$sourcedata['ftotalsize'] = formatsize($sourcedata['totalsize']);
|
||||
else
|
||||
$sourcedata['ftotalsize'] = lang('unlimited');
|
||||
if(!$targetdata=C::t('local_storage')->fetch_by_remoteid($gets['remoteid'])){
|
||||
showmessage('target_storage_location_exist', dreferer());
|
||||
}
|
||||
|
||||
$targetdata['fusesize']=formatsize($targetdata['usesize']);
|
||||
if ($targetdata['totalsize'])
|
||||
$targetdata['ftotalsize'] = formatsize($targetdata['totalsize']);
|
||||
else
|
||||
$targetdata['ftotalsize'] = lang('unlimited');
|
||||
|
||||
//获取需要迁移的数据量
|
||||
$movesize=C::t('attachment')->getAttachByFilter($gets,1);
|
||||
$fmovesize=formatsize($movesize);
|
||||
if(!$first=C::t('attachment')->getAttachByFilter($gets)){
|
||||
showmessage('movetool_move_data', dreferer());
|
||||
}
|
||||
$first['fsize']=formatsize($first['filesize']);
|
||||
include template('movetool_run');
|
||||
}else{
|
||||
$spaces=array();
|
||||
foreach(C::t('local_storage')->fetch_all_orderby_disp() as $key=>$value){
|
||||
if($arr=C::t('local_storage')->update_sizecount_by_remoteid($value['remoteid'])){
|
||||
$value['fusesize']=formatsize($arr['usesize']);
|
||||
if ($arr['totalsize'])
|
||||
$value['ftotalsize'] = formatsize($arr['totalsize']);
|
||||
else
|
||||
$value['ftotalsize'] = lang('unlimited');
|
||||
}
|
||||
$spaces[$value['remoteid']]=$value;
|
||||
}
|
||||
$spaces_json=json_encode($spaces);
|
||||
include template('movetool');
|
||||
}
|
||||
?>
|
64
admin/cloud/movetool_run.php
Normal file
64
admin/cloud/movetool_run.php
Normal file
@ -0,0 +1,64 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
@ini_set('max_execution_time',0);
|
||||
@set_time_limit(0);
|
||||
$gets = array(
|
||||
'mod'=>'cloud',
|
||||
'op'=>'movetool_run',
|
||||
'oremoteid'=>intval($_GET['oremoteid']),
|
||||
'remoteid' =>intval($_GET['remoteid']),
|
||||
'exts'=>trim($_GET['exts']),
|
||||
'sizelt'=>$_GET['sizelt'],
|
||||
'sizegt'=>$_GET['sizegt'],
|
||||
|
||||
);
|
||||
$runurl = BASESCRIPT."?".url_implode($gets);
|
||||
$gets['aid']=intval($_GET['aid']);
|
||||
$gets['dateline']=intval($_GET['dateline']);
|
||||
|
||||
//获取需要迁移的数据量
|
||||
if($attach=C::t('attachment')->getAttachByFilter($gets)){
|
||||
//print_r($attach);exit($runurl);
|
||||
try{
|
||||
updatesession();
|
||||
if($re=io_remote::Migrate($attach,$gets['remoteid'])){
|
||||
include template('common/header_common');
|
||||
echo "<script type=\"text/javascript\">";
|
||||
echo "parent.setProgress(".json_encode($re).");";
|
||||
if(!$re['error']){
|
||||
echo "window.location.href='".$runurl."&dateline=".$attach['dateline']."';";
|
||||
}
|
||||
echo "</script>";
|
||||
include template('common/footer');
|
||||
exit();
|
||||
}
|
||||
}catch(Exception $e){
|
||||
$attach['error']=$e->getMessage();
|
||||
include template('common/header_common');
|
||||
echo "<script type=\"text/javascript\">";
|
||||
echo "parent.setProgress(".json_encode($attach).");";
|
||||
echo "</script>";
|
||||
include template('common/footer');
|
||||
exit();
|
||||
}
|
||||
}else{
|
||||
//完成;
|
||||
include template('common/header_common');
|
||||
echo "<script type=\"text/javascript\">";
|
||||
echo "parent.setComplete();";
|
||||
echo "</script>";
|
||||
include template('common/footer');
|
||||
exit();
|
||||
}
|
||||
|
||||
|
||||
?>
|
33
admin/cloud/oauth.php
Normal file
33
admin/cloud/oauth.php
Normal file
@ -0,0 +1,33 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$clouds=DB::fetch_all("select * from ".DB::table('connect')." where 1 order by disp",array(),'bz');
|
||||
$bz=$_GET['bz'];
|
||||
$navtitle=lang('add_storage_location').' - '.lang('space_management');
|
||||
if($_GET['do']=='getBucket'){
|
||||
$id=$_GET['id'];
|
||||
$key=$_GET['key'];
|
||||
$bz=empty($_GET['bz'])?'ALIOSS':$_GET['bz'];
|
||||
$class='io_'.$bz;
|
||||
$p=new $class($bz);
|
||||
$re=$p->getBucketList($id,$key);
|
||||
|
||||
if($re){
|
||||
echo json_encode($re);
|
||||
}else{
|
||||
echo json_encode(array());
|
||||
}
|
||||
exit();
|
||||
}else{
|
||||
IO::authorize($bz);
|
||||
exit();
|
||||
}
|
||||
?>
|
47
admin/cloud/router.php
Normal file
47
admin/cloud/router.php
Normal file
@ -0,0 +1,47 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$navtitle=lang('routing_management');
|
||||
if(submitcheck('routersubmit')){
|
||||
$_GET=dhtmlspecialchars($_GET);
|
||||
$delete=$_GET['delete'];
|
||||
foreach($_GET['name'] as $routerid => $value){
|
||||
if(in_array($routerid,$delete)) continue;
|
||||
$setarr=array(
|
||||
'priority'=>intval($_GET['priority'][$routerid]),
|
||||
'available'=>intval($_GET['available'][$routerid]),
|
||||
);
|
||||
if(!empty($value)) $setarr['name']=$value;
|
||||
C::t('local_router')->update($routerid,$setarr);
|
||||
}
|
||||
C::t('local_router')->delete($delete);
|
||||
showmessage('do_success',dreferer());
|
||||
}else{
|
||||
|
||||
$storage=array();
|
||||
foreach(C::t('local_storage')->fetch_all_orderby_disp() as $key=>$value){
|
||||
$value['fusesize']=formatsize($value['usesize']);
|
||||
if($value['totalsize']) $value['ftotalsize']=formatsize($value['totalsize']);
|
||||
else $value['ftotalsize']=lang('unlimited');
|
||||
$storage[$value['remoteid']]=$value;
|
||||
}
|
||||
$list=array();
|
||||
foreach(C::t('local_router')->fetch_all_orderby_priority() as $value){
|
||||
$value['position']=$storage[$value['remoteid']]['name'];
|
||||
$value['bz_available']=$storage[$value['remoteid']]['available'];
|
||||
$value['bz']=$storage[$value['remoteid']]['bz'];
|
||||
$list[$value['routerid']]=$value;
|
||||
}
|
||||
}
|
||||
include template('router');
|
||||
|
||||
|
||||
?>
|
39
admin/cloud/routeredit.php
Normal file
39
admin/cloud/routeredit.php
Normal file
@ -0,0 +1,39 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
if(submitcheck('addroutersubmit')){
|
||||
$routerid=intval($_GET['routerid']);
|
||||
$router=dhtmlspecialchars($_GET['router']);
|
||||
if(empty($router['name'])){
|
||||
showmessage('name_cannot_empty', dreferer());
|
||||
|
||||
}
|
||||
$router['router']['exts']=empty($router['router']['exts'])?array():explode(',',trim($router['router']['exts']));
|
||||
$router['router']['size']['lt']=is_numeric($router['router']['size']['lt'])?intval($router['router']['size']['lt']):'';
|
||||
$router['router']['size']['gt']=is_numeric($router['router']['size']['gt'])?intval($router['router']['size']['gt']):'';
|
||||
$router['remoteid']=intval($router['remoteid']);
|
||||
$router['priority']=empty($router['priority'])?100:intval($router['priority']);
|
||||
if($routerid){
|
||||
C::t('local_router')->update($routerid,$router);
|
||||
}else{
|
||||
$router['dateline']=TIMESTAMP;
|
||||
C::t('local_router')->insert($router);
|
||||
}
|
||||
|
||||
showmessage('do_success',BASESCRIPT.'?mod=cloud&op=router');
|
||||
}else{
|
||||
$routerid=intval($_GET['routerid']);
|
||||
$router=C::t('local_router')->fetch_by_routerid($routerid);
|
||||
$spaces=C::t('local_storage')->fetch_all_orderby_disp();
|
||||
$navtitle=lang('routing_management').' - '.lang('add_routing');
|
||||
include template('routeredit');
|
||||
}
|
||||
?>
|
59
admin/cloud/space.php
Normal file
59
admin/cloud/space.php
Normal file
@ -0,0 +1,59 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$cloud=DB::fetch_first("select * from %t where bz='dzz'",array('connect'));
|
||||
$navtitle=$cloud['name'].' - '.lang('space_management');
|
||||
if($_GET['do']=='checkspace'){
|
||||
$remoteid=intval($_GET['remoteid']);
|
||||
if($arr=C::t('local_storage')->update_sizecount_by_remoteid($remoteid)){
|
||||
$arr['fusesize']=formatsize($arr['usesize']);
|
||||
if ($arr['totalsize'])
|
||||
$arr['ftotalsize'] = formatsize($arr['totalsize']);
|
||||
else
|
||||
$arr['ftotalsize'] = lang('unlimited');
|
||||
}
|
||||
echo json_encode($arr);
|
||||
exit();
|
||||
}elseif($_GET['do']=='delete'){
|
||||
$remoteid=intval($_GET['remoteid']);
|
||||
$re=C::t('local_storage')->delete_by_remoteid($remoteid);
|
||||
if($re['error']) showmessage($re['error'],dreferer());
|
||||
showmessage('do_success',dreferer());
|
||||
}else{
|
||||
if(submitcheck('cloudsubmit')){
|
||||
$isdefault=intval($_GET['isdefault']);
|
||||
foreach($_GET['name'] as $remoteid => $value){
|
||||
$setarr=array(
|
||||
'disp'=>intval($_GET['disp'][$remoteid]),
|
||||
'isdefault'=>($remoteid==$isdefault)?1:0
|
||||
);
|
||||
if(!empty($value)) $setarr['name']=getstr($value);
|
||||
C::t('local_storage')->update($remoteid,$setarr);
|
||||
}
|
||||
showmessage('do_success',dreferer());
|
||||
}else{
|
||||
$list=array();
|
||||
foreach(C::t('local_storage')->fetch_all_orderby_disp() as $key=>$value){
|
||||
|
||||
if($arr=C::t('local_storage')->update_sizecount_by_remoteid($value['remoteid'])){
|
||||
$value['fusesize']=formatsize($value['usesize']);
|
||||
if ($value['totalsize'])
|
||||
$value['ftotalsize'] = formatsize($value['totalsize']);
|
||||
else
|
||||
$value['ftotalsize'] = lang('unlimited');
|
||||
}
|
||||
|
||||
$list[]=$value;
|
||||
}
|
||||
}
|
||||
include template('space');
|
||||
}
|
||||
?>
|
22
admin/cloud/spaceadd.php
Normal file
22
admin/cloud/spaceadd.php
Normal file
@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$clouds=DB::fetch_all("select * from ".DB::table('connect')." where 1 order by disp",array(),'bz');
|
||||
$cloud=$clouds['dzz'];
|
||||
$navtitle=$cloud['name'].' - '.lang('add_storage_location');
|
||||
$list=array();
|
||||
foreach(C::t('connect')->fetch_all_by_available() as $value){
|
||||
//if($value['type']!='storage' && $value['type']!='ftp') continue; //限制只有云存储 ftp才能使用
|
||||
$list[$value['type']]['list'][]=$value;
|
||||
$list[$value['type']]['header'] = lang('cloud_type_' . $value['type']);
|
||||
}
|
||||
include template("spaceadd");
|
||||
?>
|
90
admin/cloud/template/add.htm
Normal file
90
admin/cloud/template/add.htm
Normal file
@ -0,0 +1,90 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
|
||||
<div class="main-content" style="padding:15px;border-top:1px solid #FFF">
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=add" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="addcloudsubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang name}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="name" class="form-control" value="">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang designator}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="bz" value="" class="form-control">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_designator_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang type}:</dt>
|
||||
<dd class="clearfix">
|
||||
<label class="radio radio-inline">
|
||||
<input type="radio" name="type" value="storage" checked="checked" onclick="document.getElementById('area_pan').style.display='none'">
|
||||
{lang typename_storage}</label>
|
||||
<label class="radio radio-inline"><input type="radio" name="type" value="pan" onclick="document.getElementById('area_pan').style.display=''" />{lang typename_pan}</label>
|
||||
<label class="radio radio-inline"><input type="radio" name="type" value="ftp" onclick="document.getElementById('area_pan').style.display='none'">FTP</label>
|
||||
</dd>
|
||||
</dl>
|
||||
<div id="area_pan" style="display:none">
|
||||
<dl>
|
||||
<dt>{lang root_directory}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="root" value="" >
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_root_directory_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>API Key:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="key" value="" >
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_API_KEY_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>Secret Key</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="secret" value="" class="span4">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_Secret_KEY_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang cloud_add_data_table_name}</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="dname" value="" class="span4">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_data_table_name_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<input class="btn btn-primary" name="addcloudsubmit" value="{lang add}" type="submit">
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
94
admin/cloud/template/cloud.htm
Normal file
94
admin/cloud/template/cloud.htm
Normal file
@ -0,0 +1,94 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<style type="text/css">
|
||||
/*修改*/
|
||||
/*.bs-main-container{
|
||||
padding: 15px 30px;
|
||||
}
|
||||
.table>tbody>tr>td:nth-child(1), .table>tbody>tr>th:nth-child(1), .table>tfoot>tr>td:nth-child(1), .table>tfoot>tr>th:nth-child(1), .table>thead>tr>td:nth-child(1), .table>thead>tr>th:nth-child(1){
|
||||
padding: 8px 0px;
|
||||
|
||||
}*/
|
||||
/*结束*/
|
||||
</style>
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
|
||||
</div>
|
||||
<div class="bs-main-container clearfix" >
|
||||
|
||||
<div class="main-content clearfix" style="padding:0">
|
||||
<form id="appform" name="appform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud" method="post" >
|
||||
<input type="hidden" name="cloudsubmit" value="true" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="table-responsive" style="margin-top: 8px;">
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="40">{lang sort}</th>
|
||||
<th width="150">{lang name}</th>
|
||||
<th width="90">{lang designator}</th>
|
||||
<th width="100">{lang type}</th>
|
||||
<th>{lang available}</th>
|
||||
<th width="100">{lang set}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr>
|
||||
<td width="40">
|
||||
<!--{if $value[bz]=='dzz'}-->
|
||||
<input type="hidden" name="disp[{$value[bz]}]" value="$value[disp]" />
|
||||
<!--{else}-->
|
||||
<input type="text" name="disp[{$value[bz]}]" class="form-control" value="$value[disp]" style="width:45px;" />
|
||||
<!--{/if}-->
|
||||
</td>
|
||||
<td width="150">
|
||||
<input type="text" class="form-control" name="name[{$value[bz]}]" value="$value[name]" style="max-width:150px;" /></td>
|
||||
<td><strong>$value[bz]</strong></td>
|
||||
<td>{echo lang('cloud_type_'.$value[type])}</td>
|
||||
<td>
|
||||
<!--{if $value[bz]=='dzz'}-->
|
||||
<input type="hidden" name="available[{$value[bz]}]" value="2" />
|
||||
<!--{else}-->
|
||||
<input type="checkbox" name="available[{$value[bz]}]" value="{eval echo ($value[available]?$value[available]:1)}" <!--{if $value[available]>0}-->checked<!--{/if}--> <!--{if $value[warning]}-->disabled<!--{/if}--> > <span class="text-danger" style="padding-left:3px">$value[warning]</span>
|
||||
<!--{/if}-->
|
||||
</td>
|
||||
<td><a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$value[bz]">{lang set}</a>
|
||||
<!--{if $value[warning]}-->
|
||||
<!-- <br /> -->
|
||||
<a class="text-danger" href="{BASESCRIPT}?mod=cloud&operation=delete&bz=$value[bz]" style="margin-left:15px;">{lang delete}</a>
|
||||
<!--{/if}-->
|
||||
</td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<th valign="middle" colspan="7" style="border:none">
|
||||
<input type="submit" class="btn btn-primary" value="{lang save_set}" />
|
||||
</th>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
</form>
|
||||
<div class="tip" style="margin: 20px;color: #444;text-shadow: 1px 1px 1px #FFF;line-height: 1.8;">
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<h5>{lang board_message}</h5>
|
||||
<ul>
|
||||
{lang cloud_cloud_board_message_text}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
262
admin/cloud/template/edit.htm
Normal file
262
admin/cloud/template/edit.htm
Normal file
@ -0,0 +1,262 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<style type="text/css">
|
||||
/*修改*/
|
||||
/*.bs-main-container{
|
||||
padding: 15px 30px;
|
||||
}*/
|
||||
|
||||
/*结束*/
|
||||
</style>
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix" >
|
||||
<!--{if $cloud['type']=='local'}-->
|
||||
<div class="main-header clearfix">
|
||||
<!--{template right_header}-->
|
||||
</div>
|
||||
<div class="main-content" style="padding:20px;border-top:1px solid #FFF;">
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="editsubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang name}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="name" class="form-control" value="$cloud[name]">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang designator}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="" class="form-control" value="$cloud[bz]" disabled="disabled">
|
||||
</dd>
|
||||
<dd class="clearfix">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_edit_designator_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<input class="btn btn-primary" name="editsubmit" value="{lang save_changes}" type="submit">
|
||||
</form>
|
||||
</div>
|
||||
<!--{elseif $cloud['type']=='pan'}-->
|
||||
<div class="main-header clearfix" >
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if empty($_GET[do])}-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz">{lang set}</a>
|
||||
</li>
|
||||
<!--{if $cloud['available']>0}-->
|
||||
<li <!--{if $_GET[do]=='usercloud' }-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz&do=usercloud">{lang using_user}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content clearfix" style="padding:15px;border-top:1px solid #FFF;">
|
||||
<!--{if $_GET[do]=='usercloud'}-->
|
||||
<form id="appform" name="appform" class="form-horizontal form-horizontal-left" style="margin:-15px -15px 0;" action="{BASESCRIPT}?mod=cloud&op=edit&do=usercloud" method="post" >
|
||||
<input type="hidden" name="cloudsubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="$bz" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="30"></th>
|
||||
<th>{lang name}</th>
|
||||
<th>{lang username}</th>
|
||||
<th>{lang add_time}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr>
|
||||
<td width="40"><input type="checkbox" name="delete[]" value="$value[id]" /></td>
|
||||
<td ><img src="$value[img]" />$value[cloudname]</td>
|
||||
<td>$value[username]</td>
|
||||
<td> $value[dateline] </td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<td colspan="5"><input type="checkbox" name="chkall" id="chkall" onclick="checkAll('prefix', this.form, 'del')">
|
||||
{lang del}
|
||||
<input type="submit" class="btn btn-primary" value="{lang submit}" />
|
||||
$multi </td>
|
||||
</thead>
|
||||
</table>
|
||||
</form>
|
||||
<!--{else}-->
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="editsubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang name}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="name" class="form-control" value="$cloud[name]">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang whether_allow_users_add}:</dt>
|
||||
<dd class="clearfix">
|
||||
<!--{if $cloud[available]>0}-->
|
||||
<label class="radio radio-inline"><input type="radio" name="available" value="2" <!--{if $cloud[available]>1}-->checked="checked"<!--{/if}--> />{lang yes}</label>
|
||||
<label class="radio radio-inline"><input type="radio" name="available" value="1" <!--{if $cloud[available]<2}-->checked="checked"<!--{/if}--> />{lang no}</label>
|
||||
<!--{else}-->
|
||||
<input type="hidden" name="available" value="$cloud[available]" />
|
||||
<!--{/if}-->
|
||||
<ul class="help-block">
|
||||
<!--{if $cloud[warning]}-->
|
||||
<li><span class=" text-danger">$cloud[warning]</span></li>
|
||||
<!--{/if}-->
|
||||
<!--{if $cloud[available]<1}-->
|
||||
<li><span class=" text-danger">{lang cloud_edit_enabled_name}</span></li>
|
||||
<!--{else}-->
|
||||
<li>{lang cloud_edit_enabled_cloud}</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang designator}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="bz" value="$cloud[bz]" disabled="disabled">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang root_directory}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="root" class="form-control" value="$cloud[root]" >
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_root_directory_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>API Key:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="key" class="form-control" value="$cloud[key]" >
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_API_KEY_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>Secret Key</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="secret" class="form-control" value="$cloud[secret]" class="span4">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_Secret_KEY_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang cloud_add_data_table_name}</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="dname" value="$cloud[dname]" class="span4">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_add_data_table_name_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<input class="btn btn-primary" name="editsubmit" value="{lang save_changes}" type="submit">
|
||||
</form>
|
||||
<!--{/if}-->
|
||||
</div>
|
||||
<!--{else}-->
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if empty($_GET[do])}-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz">{lang set}</a>
|
||||
</li>
|
||||
<!--{if $cloud['available']>0}-->
|
||||
<li <!--{if $_GET[do]=='usercloud' }-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz&do=usercloud">{lang using_user}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content" style="padding:15px;border-top:1px solid #FFF;">
|
||||
<!--{if $_GET[do]=='usercloud'}-->
|
||||
<form id="appform" name="appform" class="form-horizontal form-horizontal-left" style="margin:-15px -15px 0;" action="{BASESCRIPT}?mod=cloud&op=edit&do=usercloud" method="post" >
|
||||
<input type="hidden" name="cloudsubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="$bz" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="30"></th>
|
||||
<th>{lang name}</th>
|
||||
<th>{lang username}</th>
|
||||
<th>{lang add_time}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr>
|
||||
<td width="40"><input type="checkbox" name="delete[]" value="$value[id]" /></td>
|
||||
<td ><img src="$value[img]" />$value[cloudname]</td>
|
||||
<td>$value[username]</td>
|
||||
<td> $value[dateline] </td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<td colspan="5"><input type="checkbox" name="chkall" id="chkall" onclick="checkAll('prefix', this.form, 'del')">
|
||||
{lang del}
|
||||
<input type="submit" class="btn btn-primary" value="{lang submit}" />
|
||||
$multi </td>
|
||||
</thead>
|
||||
</table>
|
||||
</form>
|
||||
<!--{else}-->
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="editsubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang name}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" class="form-control" name="name" value="$cloud[name]">
|
||||
<span class="help-inline text-muted">{lang name} </span> </dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang whether_allow_users_add}:</dt>
|
||||
<dd class="clearfix">
|
||||
<!--{if $cloud[available]>0}-->
|
||||
<label class="radio radio-inline"> <input type="radio" name="available" value="2" <!--{if $cloud[available]>1}-->checked="checked"<!--{/if}--> />{lang yes}</label>
|
||||
<label class="radio radio-inline"> <input type="radio" name="available" value="1" <!--{if $cloud[available]<2}-->checked="checked"<!--{/if}--> />{lang no}</label>
|
||||
<!--{else}-->
|
||||
<input type="hidden" name="available" value="$cloud[available]" />
|
||||
<!--{/if}-->
|
||||
<ul class="help-block">
|
||||
<!--{if $cloud[warning]}-->
|
||||
<li><span class=" text-danger">$cloud[warning]</span></li>
|
||||
<!--{/if}-->
|
||||
<!--{if $cloud[available]<1}-->
|
||||
<li><span class=" text-danger">{lang cloud_edit_enabled_name}</span></li>
|
||||
<!--{else}-->
|
||||
<li>{lang cloud_edit_enabled_cloud}</li>
|
||||
<!--{/if}-->
|
||||
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang designator}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="bz" class="form-control" value="$cloud[bz]" disabled="disabled">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_edit_designator_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<input class="btn btn-primary" name="editsubmit" value="{lang save_changes}" type="submit">
|
||||
</form>
|
||||
<!--{/if}-->
|
||||
</div>
|
||||
<!--{/if}-->
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
8
admin/cloud/template/header_left.htm
Normal file
8
admin/cloud/template/header_left.htm
Normal file
@ -0,0 +1,8 @@
|
||||
<ul class="nav navbar-nav navbar-nav-left" style="min-width:168px">
|
||||
<li>
|
||||
<a class="leftTopmenu" href="index.php?mod=appmanagement" style="padding:8px"><div class="gb_fc"><span class="dzz dzz-chevron-left" style="display:block"></span></div></a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{MOD_URL}">{lang appname}</a>
|
||||
</li>
|
||||
</ul>
|
10
admin/cloud/template/left.htm
Normal file
10
admin/cloud/template/left.htm
Normal file
@ -0,0 +1,10 @@
|
||||
<!--{eval $bz=$bz?$bz:'dzz';}-->
|
||||
<!--{eval $clouds=DB::fetch_all("select * from ".DB::table('connect')." where 1 order by disp");}-->
|
||||
<ul class="nav-stacked">
|
||||
<li <!--{if $operation=='setting'}-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&operation=setting">{lang cloud_set}</a>
|
||||
</li>
|
||||
<!--{loop $clouds $value}-->
|
||||
<li <!--{if $operation!='setting' && $bz==$value[bz]}-->class="active"<!--{/if}-->> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$value[bz]">$value[name]</a>
|
||||
</li>
|
||||
<!--{/loop}-->
|
||||
</ul>
|
143
admin/cloud/template/movetool.htm
Normal file
143
admin/cloud/template/movetool.htm
Normal file
@ -0,0 +1,143 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<style type="text/css">
|
||||
/*修改*/
|
||||
/*.bs-main-container{
|
||||
padding: 15px 30px;
|
||||
}*/
|
||||
|
||||
/*结束*/
|
||||
</style>
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<!--{template right_header}-->
|
||||
</div>
|
||||
<div class="main-content clearfix" style="padding:15px;border-top:1px solid #FFF" >
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=movetool" class="form-horizontal form-horizontal-left" method="post" name="cpform" onsubmit="return validate(this);">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="movesubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang target_location}:</dt>
|
||||
<dd class="clearfix">
|
||||
<select name="remoteid" class="form-control" style="width:250px">
|
||||
<!--{loop $spaces $value}-->
|
||||
<option value="$value[remoteid]" <!--{if $router[remoteid]==$value[remoteid]}-->selected="selected"
|
||||
<!--{/if}-->>$value[name]($value[fusesize] / $value[ftotalsize])
|
||||
</option>
|
||||
<!--{/loop}-->
|
||||
</select>
|
||||
<ul class="help-block ">
|
||||
<li>{lang cloud_movetool_designator_text}</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang original_location}:</dt>
|
||||
<dd class="clearfix">
|
||||
<select name="oremoteid" class="form-control" style="width:250px">
|
||||
<!--{loop $spaces $value}-->
|
||||
<option value="$value[remoteid]" >$value[name]($value[fusesize] / $value[ftotalsize])</option>
|
||||
<!--{/loop}-->
|
||||
</select>
|
||||
<ul class="help-block ">
|
||||
<li>{lang cloud_movetool_designator_text}</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt> <a href="javascript:;" onclick="jQuery('#filter').toggle(); document.getElementById('filter_guide').className=(document.getElementById('filter_guide').className=='glyphicon glyphicon-chevron-down'?'glyphicon glyphicon-chevron-up':'glyphicon glyphicon-chevron-down');">{lang filtrate_condition} <i id="filter_guide" class="glyphicon glyphicon-chevron-down"></i></a> </dt>
|
||||
</dl>
|
||||
<div id="filter" style="display:none;padding-left:50px;">
|
||||
<dl>
|
||||
<dt>{lang file_type}:</dt>
|
||||
<dd class="clearfix">
|
||||
<textarea type="textarea" id="exts" class="form-control" name="router[exts]" row="6" cols="6" style="width:300px;height:60px"></textarea>
|
||||
</dd>
|
||||
<dd class="clearfix mt10">
|
||||
<a href="javascript:;" onclick="setExts('jpg,jpeg,png,gif')">{lang photograph_class}</a>
|
||||
<a href="javascript:;" onclick="setExts('doc,docx,rtf,odt,htm,html,txt')">word{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('xls,xlsx,ods,sxc,csv,tsv')">excel{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('ppt,pptx,pps,ppsx,odp,sxi')">ppt{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('mp4,avi,wmv,mkv,rmvb,rm,asf,mpg,mpeg,mov')">{lang video_typename_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('txt,ini,conf,log,bat,sql,js,css,htm,html,xml,asp,aspx,php,jsp,json,py,h,c')">text_class</a>
|
||||
</dd>
|
||||
<dd class="clearfix">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_movetool_file_type_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang file_size}:</dt>
|
||||
<dd class="clearfix ">
|
||||
<div class="input-group pull-left" style="width:100px"> <span class="input-group-addon">{lang typename_attach_lt}</span>
|
||||
<input type="text" class="form-control" name="router[size][lt]" style="width:60px;" value="" />
|
||||
<span class="input-group-addon">M</span> </div>
|
||||
<div class="pull-left ml20 mr20" style="line-height:30px;"> AND</div>
|
||||
<div class="input-group pull-left" style="width:100px"> <span class="input-group-addon">{lang typename_attach_gt}</span>
|
||||
<input type="text" class="form-control" name="router[size][gt]" value="" style="width:60px;" />
|
||||
<span class="input-group-addon">M</span> </div>
|
||||
</dd>
|
||||
<dd class="clearfix ">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_movetool_file_size_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<input class="btn btn-primary" name="movesubmit" value="{lang starting_migration}" type="submit">
|
||||
</form>
|
||||
</div>
|
||||
<div class="tip" style="margin: 20px;color: #444;text-shadow: 1px 1px 1px #FFF;line-height: 1.8;">
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<h5>{lang board_message}</h5>
|
||||
<ul>
|
||||
{lang cloud_movetool_board_message_text}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var spaces=$spaces_json;
|
||||
function validate(form) {
|
||||
//验证原和目标位置
|
||||
if(form.remoteid.value == form.oremoteid.value) {
|
||||
alert('目标存储位置不能和原存储位置相同');
|
||||
form.remoteid.focus();
|
||||
return false;
|
||||
}
|
||||
//判断原位置有无数据
|
||||
if(spaces[form.oremoteid.value].usesize<1){
|
||||
alert('{lang cloud_movetool_home_position}');
|
||||
form.oremoteid.focus();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
function setExts(str){
|
||||
var old=trim(document.getElementById('exts').value).replace(/,{1,}/g,',').replace(/,{1,}/g,',').replace(/^\,/g,'');
|
||||
var arr=old?old.split(','):[];
|
||||
var newarr=str.split(',');
|
||||
for(var i=0;i<newarr.length;i++){
|
||||
if(jQuery.inArray(newarr[i],arr)<0){
|
||||
arr.push(newarr[i]);
|
||||
}
|
||||
}
|
||||
document.getElementById('exts').value=arr.join(',');
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
179
admin/cloud/template/movetool_run.htm
Normal file
179
admin/cloud/template/movetool_run.htm
Normal file
@ -0,0 +1,179 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
.thumbnails li {
|
||||
float: left;
|
||||
}
|
||||
.thumbnail {
|
||||
border: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
.progress-title {
|
||||
word-break: break-all;
|
||||
font-weight: normal;
|
||||
max-height: 40px;
|
||||
line-height: 20px;
|
||||
overflow: hidden;
|
||||
}
|
||||
#upload_progress .back {
|
||||
position: absolute;
|
||||
width: 200px;
|
||||
text-align: center;
|
||||
color: #900;
|
||||
font-weight: bold;
|
||||
}
|
||||
#upload_progress .back span {
|
||||
padding: 0 5px;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix" style="min-width:570px;">
|
||||
<div class="main-header ">
|
||||
<!--{template right_header}-->
|
||||
</div>
|
||||
<div class="main-content clearfix" style="padding:20px 20px 10px;border-top:1px solid #FFF">
|
||||
<div class="clearfix" style="margin:0 auto">
|
||||
<p id="operation" class="text-center" style="width:500px;">
|
||||
<button class="btn btn-success start" onclick="moveing_start('start')">{lang starting_migration}</button>
|
||||
|
||||
<button class="btn btn-danger stop" onclick="moveing_start('stop')" disabled="disabled">{lang stop}</button>
|
||||
</p>
|
||||
<ul class="thumbnails list-unstyled clearfix" style="width:570px;">
|
||||
<li id="source_space" style="width:150px;">
|
||||
<div class="thumbnail">
|
||||
<!--{if $sourcedata[bz]=='dzz'}-->
|
||||
<img src="dzz/images/default/system/home.png" width="100">
|
||||
<!--{else}-->
|
||||
<img src="dzz/images/default/system/$sourcedata[bz].png" width="100">
|
||||
<!--{/if}-->
|
||||
<h5 class="text-center" style="line-height:20px;margin-bottom:5px"><a href="javascript:;" title="$sourcedata[name]">$sourcedata[name] </a></h5>
|
||||
</div>
|
||||
</li>
|
||||
<li id="moveinfo">
|
||||
<div id="upload_progress" style="width:200px;overflow:hidden">
|
||||
<h5 class="progress-subject" style="margin-top:5px"></h5>
|
||||
<h5 class="progress-title">$first[attachment]</h5>
|
||||
<div class="progress progress-striped active">
|
||||
<div class="back"><span id="moved">$first[fsize]</span>/<span>$fmovesize</span></div>
|
||||
<div class="progress-bar" style="width:1%;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li id="target_space" style="width:150px;">
|
||||
<div class="thumbnail">
|
||||
<!--{if $targetdata[bz]=='dzz'}-->
|
||||
<img src="dzz/images/default/system/home.png" width="100">
|
||||
<!--{else}-->
|
||||
<img src="dzz/images/default/system/$targetdata[bz].png" width="100">
|
||||
<!--{/if}-->
|
||||
<h5 class="text-center" style="line-height:20px;margin-bottom:5px"><a href="javascript:;" title="$targetdata[name]">$targetdata[name]</a></h5>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="tip" style="margin:10px;">
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<h5>{lang board_message}</h5>
|
||||
<ul>
|
||||
{lang cloud_movetool_board_message_text1}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<iframe id="hideframe" name="hideframe" src="about:blank" frameborder="0" marginheight="0" marginwidth="0" width="0" height="0" allowtransparency="true" style="display:none;z-index:-99999"></iframe>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var runurl = '$runurl';
|
||||
var sizemoved = 0;
|
||||
var totalsize = parseInt('$movesize');
|
||||
var ignore = [];
|
||||
var ignore_attach = {};
|
||||
var attach = {};
|
||||
var ignoreTimer = null;
|
||||
|
||||
function setProgress(data) {
|
||||
attach = data;
|
||||
var el = jQuery('#upload_progress');
|
||||
if(data.error) {
|
||||
el.find('.progress-title').html(data.attachment);
|
||||
var html = '';
|
||||
html += '<p><span class="text-danger">' + data.error + '</span></p>';
|
||||
html += '<p><span class="text-info">{lang filename}:' + data.attachment + '</span>';
|
||||
html += '<p><span class="text-info">{lang big_small}:' + formatSize(data.filesize) + '</span></p>';
|
||||
html += '<p><a href="javascript:;" onclick="moveing_start(\'retry\')">{lang founder_upgrade_reset}</a> <a href="javascript:;" onclick="moveing_start(\'ignore\');">{lang ignore_continue}</a></p>';
|
||||
ignoreTimer = window.setTimeout(function() { moveing_start('ignore'); }, 1000);
|
||||
el.find('.progress-subject').html(html);
|
||||
} else {
|
||||
el.find('.progress-subject').html('{lang moving}');
|
||||
sizemoved += parseInt(data.filesize);
|
||||
el.find('.progress-title').html(data.attachment);
|
||||
el.find('#moved').html(formatSize(sizemoved));
|
||||
jQuery('#upload_progress .progress-bar').css('width', Math.floor((sizemoved / totalsize) * 100));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function setComplete() {
|
||||
var html = '';
|
||||
html += '<p><span class="text-success">{lang migration_completed}</span></p>';
|
||||
if(ignore.length > 0) {
|
||||
html += '<p class="text-warning">' + ignore.length + '{lang cloud_movetool_file_neglect}</p>';
|
||||
}
|
||||
jQuery('#upload_progress .progress-bar').css('width', '100%');
|
||||
jQuery('#upload_progress .progress-subject').html(html);
|
||||
jQuery('#operation .stop').attr('disabled', true);
|
||||
jQuery('#operation .start').attr('disabled', true);
|
||||
}
|
||||
|
||||
function moveing_start(op) {
|
||||
if(ignoreTimer) window.clearTimeout(ignoreTimer);
|
||||
if(op == 'start') {
|
||||
jQuery('#operation .stop').removeAttr('disabled');
|
||||
jQuery('#operation .start').attr('disabled', true);
|
||||
jQuery('#upload_progress .progress-subject').html('{lang moving}');
|
||||
jQuery('#upload_progress .progress-bar').css('width', Math.floor((sizemoved / totalsize) * 100));
|
||||
window.frames['hideframe'].location = runurl + '&dateline=' + (attach.dateline || 0);;
|
||||
} else if(op == 'stop') {
|
||||
jQuery('#operation .start').removeAttr('disabled');
|
||||
jQuery('#operation .stop').attr('disabled', true);
|
||||
window.frames['hideframe'].location = 'about:blank';
|
||||
jQuery('#upload_progress .progress-subject').html('{lang stopped}');
|
||||
} else if(op == 'ignore') {
|
||||
ignore.push(attach.aid);
|
||||
ignore_attach[attach.aid] = attach;
|
||||
jQuery('#upload_progress .progress-subject').html('{lang ignored}');
|
||||
sizemoved += parseInt(attach.filesize);
|
||||
jQuery('#upload_progress .progress-bar').css('width', Math.floor((sizemoved / totalsize) * 100));
|
||||
window.frames['hideframe'].location = runurl + '&dateline=' + attach.dateline;
|
||||
} else if(op == 'retry') {
|
||||
jQuery('#upload_progress .progress-subject').html('{lang are_retry}');
|
||||
jQuery('#upload_progress .progress-bar').css('width', Math.floor((sizemoved / totalsize) * 100));
|
||||
window.frames['hideframe'].location = runurl + '&dateline=' + attach.dateline;;
|
||||
} else if(op == 'refresh') {
|
||||
window.location.reload();
|
||||
}
|
||||
}
|
||||
|
||||
function formatSize(bytes) {
|
||||
var i = -1;
|
||||
do {
|
||||
bytes = bytes / 1024;
|
||||
i++;
|
||||
} while (bytes > 99);
|
||||
|
||||
return Math.max(bytes, 0).toFixed(1) + ['kB', 'MB', 'GB', 'TB', 'PB', 'EB'][i];
|
||||
};
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
155
admin/cloud/template/oauth_ALIOSS.htm
Normal file
155
admin/cloud/template/oauth_ALIOSS.htm
Normal file
@ -0,0 +1,155 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
.form-horizontal-left .control-label{
|
||||
width:150px;
|
||||
}
|
||||
.form-horizontal-left .help-block{
|
||||
padding-left:150px;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=oauth&bz=ALIOSS">{lang oauth_ALIOSS_add_ALY}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content clearfix" style="border-top:1px solid #FFF;padding:30px 0">
|
||||
<div style="">
|
||||
<!--<h4 style="margin-bottom:20px">{lang set}Accesscess Key ID & Access Key Secret</h4>-->
|
||||
<form name="aliform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=oauth" method="post" onsubmit="return validate(this)">
|
||||
<input type="hidden" name="alisubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="ALIOSS" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="access_id">Access Key ID</label>
|
||||
|
||||
<input type="text" id="access_id" class="form-control" name="access_id" autocomplete="off" value="$ali[access_id]" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');getBucket();}">
|
||||
<span class="help-block">{lang oauth_ALIOSS_ALY_storage}Access Key ID</span>
|
||||
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="access_key">Access Key Secret</label>
|
||||
|
||||
<input type="password" class="form-control" id="access_key" name="access_key" autocomplete="off" value="$ali[access_id]" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');getBucket();}">
|
||||
|
||||
<span class="help-inline">{lang oauth_ALIOSS_ALY_storage}Access Key Secret</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label"><a href="javascript:;" onclick="getBucket()">{lang oauth_ALIOSS_click_gain}</a></label>
|
||||
|
||||
<select id="bucket" name="bucket" class="form-control" onchange="setBucketHost()">
|
||||
</select>
|
||||
<span class="help-inline">{lang oauth_ALIOSS_bucket}</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="hostname">
|
||||
<div class="dropdown" > <a id="hostname_dropmenu" role="button" data-toggle="dropdown" href="#">{lang select_node_address} <span class="caret"></span></a>
|
||||
<ul id="menu3" class="dropdown-menu" role="menu" aria-labelledby="drop6" style="max-height:300px;overflow-y:auto;">
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-hangzhou.aliyuncs.com" onclick="selectHostName(this);return false;">{lang oauth_ALIOSS_node1}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-hangzhou-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node2}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-qingdao.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node3}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-qingdao-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node4}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-beijing.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node5}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-beijing-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node6}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-hongkong.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node7}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-hongkong-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node8}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-shenzhen.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node9}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-shenzhen-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node10}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-shanghai.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node11}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-cn-shanghai-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node12}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-us-west-1.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node13}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-us-west-1-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node14}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-ap-southeast-1.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node15}</a></li>
|
||||
<li role="presentation"><a role="menuitem" tabindex="-1" href="javascript:;" hostname="oss-ap-southeast-1-internal.aliyuncs.com" onclick="document.getElementById('hostname').value=jQuery(this).attr('hostname');return false;">{lang oauth_ALIOSS_node16}</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</label>
|
||||
|
||||
<input type="text" class="form-control" id="hostname" name="hostname" autocomplete="off" value="$ali[hostname]" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');}">
|
||||
<span class="help-inline">{lang oauth_ALIOSS_node17}</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<input type="submit" class="btn btn-primary" value="{lang add}">
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
|
||||
function setBucketHost() {
|
||||
jQuery('#hostname').val('');
|
||||
jQuery("#bucket").parent().parent().removeClass('has-warning');
|
||||
}
|
||||
|
||||
function selectHostName(obj) {
|
||||
jQuery('#hostname').val(jQuery(obj).attr('hostname'));
|
||||
jQuery("#hostname").parent().parent().removeClass('has-warning');
|
||||
jQuery('#hostname_dropmenu').html(jQuery(obj).html() + '<span class="caret"></span>');
|
||||
}
|
||||
|
||||
function getBucket() {
|
||||
var id = jQuery("#access_id").val();
|
||||
var key = jQuery("#access_key").val();
|
||||
console.log('aaaaaaaaaaaa');
|
||||
if(id == '' || key == '') {
|
||||
return;
|
||||
}
|
||||
jQuery.getJSON('{BASESCRIPT}?mod=cloud&op=oauth&do=getBucket', { id: id, key: key }, function(json) {
|
||||
console.log(json);
|
||||
if(json.length > 0) {
|
||||
var html = '';
|
||||
for(var i in json) {
|
||||
html += '<option value="' + json[i] + '" >' + json[i] + '</option>';
|
||||
}
|
||||
console.log(html);
|
||||
jQuery('#bucket').html(html);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function validate(form) {
|
||||
if(jQuery("#access_id").val() == '') {
|
||||
jQuery("#access_id").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
} else if(jQuery("#access_key").val() == '') {
|
||||
jQuery("#access_key").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
} else if(jQuery("#bucket").val() == '') {
|
||||
jQuery("#bucket").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
} else if(jQuery("#hostname").val() == '') {
|
||||
jQuery("#hostname").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
92
admin/cloud/template/oauth_disk.htm
Normal file
92
admin/cloud/template/oauth_disk.htm
Normal file
@ -0,0 +1,92 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
.form-horizontal-left .control-label{
|
||||
width:150px;
|
||||
}
|
||||
.form-horizontal-left .help-block{
|
||||
padding-left:150px;
|
||||
}
|
||||
.main-content{
|
||||
padding:30px 0;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=oauth&bz=disk">{lang add}{lang cloud_type_disk}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="main-content clearfix">
|
||||
<form name="aliform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=oauth" method="post" onsubmit="return validate(this)">
|
||||
<input type="hidden" name="disksubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="disk" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang disk_name}</label>
|
||||
<input type="text" class="form-control required" name="config[cloudname]" value="">
|
||||
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang disk_dir}</label>
|
||||
<input type="text" class="form-control required" name="config[attachdir]" value="">
|
||||
<span class="help-block">{lang disk_dir_tip}</span>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang disk_encode}</label>
|
||||
|
||||
<select class="form-control" name="config[charset]">
|
||||
<option value="GBK">GBK</option>
|
||||
<option value="UTF-8" selected="selected">UTF-8</option>
|
||||
<option value="BIG5">BIG5</option>
|
||||
</select>
|
||||
<span class="help-block">{lang disk_encode_tip}</span>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<input type="submit" class="btn btn-primary" style="padding:6px 25px" value="{lang add}">
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
function validate(form) {
|
||||
var i = 0;
|
||||
jQuery("input.required").each(function() {
|
||||
if(jQuery(this).val() == '') {
|
||||
jQuery(this).focus();
|
||||
return false;
|
||||
}
|
||||
i++;
|
||||
});
|
||||
if(i < jQuery("input.required").length) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
110
admin/cloud/template/oauth_ftp.htm
Normal file
110
admin/cloud/template/oauth_ftp.htm
Normal file
@ -0,0 +1,110 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
.form-horizontal-left .control-label{
|
||||
width:150px;
|
||||
}
|
||||
.form-horizontal-left .help-block{
|
||||
padding-left:150px;
|
||||
}
|
||||
.main-content{
|
||||
padding:30px 0;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=oauth&bz=ftp">{lang add_FTP_storage}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content clearfix" style="border-top:1px solid #FFF">
|
||||
<form name="aliform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=oauth" method="post" onsubmit="return validate(this)">
|
||||
<input type="hidden" name="ftpsubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="ftp" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang site_name}</label>
|
||||
<input type="text" class="form-control required" name="config[cloudname]" value="">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang IP_address}</label>
|
||||
<input type="text" class="form-control required" name="config[host]" value="" placeholder="{lang host_IP_address}">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang port}</label>
|
||||
<input type="text" class="form-control required" name="config[port]" value="21" placeholder="{lang port}">
|
||||
<span class="help-inline"></span> </div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang username}</label>
|
||||
<input type="text" class="form-control required" name="config[username]" value="" placeholder="{lang FTP_account_user_name}">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang password}</label>
|
||||
<input type="password" class="form-control required" name="config[password]" value="" placeholder="{lang FTP_account_user_password}">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang FTP_encode}</label>
|
||||
<select class="form-control" name="config[charset]">
|
||||
<option value="GBK" selected="selected">GBK</option>
|
||||
<option value="UTF-8">UTF-8</option>
|
||||
<option value="BIG5">BIG5</option>
|
||||
</select>
|
||||
<span class="help-inline">{lang oauth_ftp_encode_set}</span> </div>
|
||||
|
||||
<!--{if function_exists('ssh2_connect')}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<label class="radio-inline"><input type="radio" name="config[ssl]" checked="checked" value="0" onclick="$('#pasv').show();">{lang way_FTP_connection}</label>
|
||||
|
||||
<label class="radio-inline"><input type="radio" name="config[ssl]" value="2" onclick="$('#pasv').hide();">{lang use_ssh2_sftp}</label>
|
||||
</div>
|
||||
<!--{/if}-->
|
||||
<div id="pasv" class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<label class="checkbox-inline"><input type="checkbox" name="config[pasv]" checked="checked" value="1" >{lang use_Passive_Mode}</label>
|
||||
<label class="checkbox-inline"><input type="checkbox" name="config[ssl]" value="1" >{lang enable_secure_link}</label>
|
||||
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<input type="submit" class="btn btn-primary" value="{lang add}">
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
|
||||
function validate(form) {
|
||||
var i = 0;
|
||||
jQuery("input.required").each(function() {
|
||||
if(jQuery(this).val() == '') {
|
||||
jQuery(this).focus();
|
||||
return false;
|
||||
}
|
||||
i++;
|
||||
});
|
||||
if(i < jQuery("input.required").length) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
99
admin/cloud/template/oauth_qiniu.htm
Normal file
99
admin/cloud/template/oauth_qiniu.htm
Normal file
@ -0,0 +1,99 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
.form-horizontal-left .control-label{
|
||||
width:150px;
|
||||
}
|
||||
.form-horizontal-left .help-block{
|
||||
padding-left:150px;
|
||||
}
|
||||
.main-content{
|
||||
padding:30px 0;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide" >
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=oauth&bz&bz=qiniu">{lang oauth_qinniu_add}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content clearfix">
|
||||
|
||||
<form name="aliform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=oauth" method="post" onsubmit="return validate(this)">
|
||||
<input type="hidden" name="qiniusubmit" value="true" />
|
||||
<input type="hidden" name="bz" value="qiniu" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="access_id">AK:</label>
|
||||
|
||||
<input type="text" id="access_id" class="form-control" name="access_id" autocomplete="off" value="$ali[access_id]" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');}" onfocus="jQuery(this).parent().parent().removeClass('has-warning');" />
|
||||
<span class="help-inline">{lang oauth_qinniu_storage} AK</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="access_key">SK:</label>
|
||||
|
||||
<input type="password" class="form-control" id="access_key" name="access_key" autocomplete="off" value="$ali[access_id]" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');}" onfocus="jQuery(this).parent().parent().removeClass('has-warning');" />
|
||||
<span class="help-inline">{lang oauth_qinniu_storage} SK</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">bucket{lang name}</label>
|
||||
|
||||
<input type="text" id="bucket" name="bucket" class="form-control" value="" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');}" onfocus="jQuery(this).parent().parent().removeClass('has-warning');" />
|
||||
<span class="help-inline">{lang oauth_qinniu_manage_bucket}</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="hostname">{lang visit_domain_name}</label>
|
||||
|
||||
<input type="text" class="form-control" id="hostname" name="hostname" autocomplete="off" value="$ali[hostname]" onfocus="jQuery(this).parent().parent().removeClass('has-warning');" onblur="if(this.value==''){jQuery(this).parent().parent().addClass('has-warning');}else{jQuery(this).parent().parent().removeClass('has-warning');}" />
|
||||
<span class="help-inline">{lang oauth_qinniu_storage_bucket}</span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="region">{lang storage_region}</label>
|
||||
<div class="controls">
|
||||
<!--{loop $HOSTS $key $value}-->
|
||||
<label class="radio-inline"><input type="radio" <!--{if $key=='huadong'}--> checked="checked"<!--{/if}--> name="region" value="$key" /> $value['title']</label>
|
||||
<!--{/loop}-->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<input type="submit" class="btn btn-primary" value="{lang add}">
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
function validate(form){
|
||||
if(jQuery("#access_id").val()==''){
|
||||
jQuery("#access_id").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
}else if(jQuery("#access_key").val()==''){
|
||||
jQuery("#access_key").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
}else if(jQuery("#bucket").val()==''){
|
||||
jQuery("#bucket").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
}else if(jQuery("#hostname").val()==''){
|
||||
jQuery("#hostname").parent().parent().addClass('has-warning');
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
|
||||
<!--{template common/footer_simple}-->
|
10
admin/cloud/template/right_header.htm
Normal file
10
admin/cloud/template/right_header.htm
Normal file
@ -0,0 +1,10 @@
|
||||
<ul class="nav navbar-nav nav-pills-bottomguide">
|
||||
<li <!--{if $_GET[op]=='edit'}-->class="active"<!--{/if}-->><a href="{BASESCRIPT}?mod=cloud&op=edit&bz=$bz"> {lang set}</a>
|
||||
</li>
|
||||
<li <!--{if $_GET[op]=='space' || $_GET[op]=='spaceadd'}-->class="active"<!--{/if}-->><a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a>
|
||||
</li>
|
||||
<li <!--{if $_GET[op]=='router' || $_GET[op]=='routeredit'}-->class="active"<!--{/if}-->><a href="{BASESCRIPT}?mod=cloud&op=router">{lang routing_management}</a>
|
||||
</li>
|
||||
<li <!--{if $_GET[op]=='movetool'}-->class="active"<!--{/if}-->><a href="{BASESCRIPT}?mod=cloud&op=movetool">{lang migration_tool}</a>
|
||||
</li>
|
||||
</ul>
|
103
admin/cloud/template/router.htm
Normal file
103
admin/cloud/template/router.htm
Normal file
@ -0,0 +1,103 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<script src="admin/scripts/admin.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<style type="text/css">
|
||||
/*修改*/
|
||||
/*.bs-main-container{
|
||||
padding: 15px 30px;
|
||||
}*/
|
||||
|
||||
/*结束*/
|
||||
</style>
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix" style="min-width:680px;">
|
||||
<div class="main-header clearfix">
|
||||
<!--{template right_header}-->
|
||||
</div>
|
||||
<div class="main-content clearfix" style="border-top:1px solid #FFF">
|
||||
<form id="appform" name="appform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=router" method="post">
|
||||
<input type="hidden" name="routersubmit" value="true" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<th width="20"> </th>
|
||||
<th width="80">{lang priority}</th>
|
||||
<th width="150">{lang name}</th>
|
||||
<th width="100">{lang use_storage}</th>
|
||||
<th>{lang routing_rule}</th>
|
||||
<th width="60">{lang enable}</th>
|
||||
<th width="60">{lang edit}</th>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr>
|
||||
<td width="20"><input type="checkbox" name="delete[]" value="$value[routerid]" style="width:20px;" /></td>
|
||||
<td width="80"><input type="text" class="form-control" name="priority[{$value[routerid]}]" value="$value[priority]" style="width:45px;" /></td>
|
||||
<td width="150"><input type="text" class="form-control" name="name[{$value[routerid]}]" value="$value[name]" /></td>
|
||||
<td width="100">$value[position]
|
||||
<!--{if $value[bz_available]<1}-->
|
||||
<span class="text-danger">{lang router_routing_failure}</span>
|
||||
<!--{/if}--></td>
|
||||
<td style="word-break:break-all">$value[drouter]</td>
|
||||
<td width="60"><input type="checkbox" name="available[{$value[routerid]}]" value="1" <!--{if $value[available]>0}-->checked<!--{/if}-->></td>
|
||||
<td width="60"><a href="{BASESCRIPT}?mod=cloud&op=routeredit&routerid=$value[routerid]" class="glyphicon glyphicon-edit " title="{lang edit}"> </a></td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<td valign="middle" colspan="7"><input type="checkbox" name="chkall" id="chkall" onclick="checkAll('prefix', this.form, 'delete')">
|
||||
{lang del}
|
||||
<input type="submit" class="btn btn-primary" value="{lang save_set}" />
|
||||
<a href="{BASESCRIPT}?mod=cloud&op=routeredit" title="{lang add_routing}" class="btn btn-success">{lang add_routing}</a>
|
||||
|
||||
</td>
|
||||
</thead>
|
||||
</table>
|
||||
</form>
|
||||
<div class="tip" style="margin: 20px;color: #444;text-shadow: 1px 1px 1px #FFF;line-height: 1.8;">
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<h5>{lang board_message}</h5>
|
||||
<ul>
|
||||
{lang router_board_message_text}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
|
||||
function checkspace(obj, routerid) {
|
||||
jQuery(obj).html('<img src="admin/images/loadding.gif">');
|
||||
jQuery.getJSON('{ADMINSCRIPT}?mod=cloud&op=space&do=checkspace&routerid=' + routerid, function(json) {
|
||||
if(json.error) {
|
||||
jQuery(this).html('<i class="icon-refresh"></i><span class="text-danger">' + json.error + '</span>');
|
||||
} else {
|
||||
jQuery('#spaceinfo_' + routerid + ' .spacecheck a').html('<span class="text-success" >{lang already_update}</span>');
|
||||
jQuery('#spaceinfo_' + routerid + ' .spacesize').html(json.fusesize + ' / ' + json.ftotalsize).hide().fadeIn('slow');
|
||||
if(json.usesize < 1) {
|
||||
jQuery('delete_' + routerid).show();
|
||||
} else {
|
||||
jQuery('delete_' + routerid).hide();
|
||||
}
|
||||
window.setTimeout(function() {
|
||||
jQuery('#spaceinfo_' + routerid + ' .spacecheck a').html('<i class="icon-refresh"></i>');
|
||||
}, 5000);
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
111
admin/cloud/template/routeredit.htm
Normal file
111
admin/cloud/template/routeredit.htm
Normal file
@ -0,0 +1,111 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide" >
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=router">{lang routing_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=rootedit">{lang add_routing}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content" style="padding:15px;border-top:1px solid #FFF">
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=cloud&op=routeredit" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" name="routerid" value="$routerid">
|
||||
<input type="hidden" value="addroutersubmit" name="true">
|
||||
<dl>
|
||||
<dt>{lang routing_name}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="router[name]" class="form-control" value="$router[name]">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang priority}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input type="text" name="router[priority]" class="form-control" value="$router[priority]">
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang storage_location}:</dt>
|
||||
<dd class="clearfix">
|
||||
<select name="router[remoteid]" class="form-control">
|
||||
<!--{loop $spaces $value}-->
|
||||
<option value="$value[remoteid]" <!--{if $router[remoteid]==$value[remoteid]}-->selected="selected"<!--{/if}-->> $value[name]
|
||||
<!--{if $value[available]<1}-->({lang router_routing_failure})<!--{/if}-->
|
||||
</option>
|
||||
<!--{/loop}-->
|
||||
</select>
|
||||
<ul class="help-block ">
|
||||
<li>{lang cloud_movetool_designator_text}</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang file_type}:</dt>
|
||||
<dd class="clearfix">
|
||||
<textarea type="textarea" id="exts" class="form-control" name="router[router][exts]" row="6" cols="6" style="width:300px;height:60px">{eval echo implode(',',$router[router][exts])}</textarea>
|
||||
</dd>
|
||||
<dd class="clearfix mt10">
|
||||
<a href="javascript:;" onclick="setExts('jpg,jpeg,png,gif')">{lang photograph_class}</a>
|
||||
<a href="javascript:;" onclick="setExts('doc,docx,rtf,odt,htm,html,txt')">word{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('xls,xlsx,ods,sxc,csv,tsv')">excel{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('ppt,pptx,pps,ppsx,odp,sxi')">ppt{lang type_attach}</a>
|
||||
<a href="javascript:;" onclick="setExts('mp4,avi,wmv,mkv,rmvb,rm,asf,mpg,mpeg,mov')">{lang video_typename_attach}</a> <a href="javascript:;" onclick="setExts('txt,ini,conf,log,bat,sql,js,css,htm,html,xml,asp,aspx,php,jsp,json,py,h,c')">{lang text_class}</a>
|
||||
</dd>
|
||||
<dd class="clearfix mt10">
|
||||
<ul class="help-inline ">
|
||||
{lang cloud_movetool_file_type_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang file_size}:</dt>
|
||||
<dd class="clearfix ">
|
||||
<div class="input-group pull-left" style="width:100px"> <span class="input-group-addon">{lang typename_attach_lt}</span>
|
||||
<input type="text" class="form-control" name="router[router][size][lt]" style="width:60px;" value="$router[router][size][lt]" />
|
||||
<span class="input-group-addon">M</span> </div>
|
||||
<div class="pull-left ml20 mr20" style="line-height:30px;"> AND</div>
|
||||
<div class="input-group pull-left" style="width:100px"> <span class="input-group-addon">{lang typename_attach_gt}</span>
|
||||
<input type="text" class="form-control" name="router[router][size][gt]" value="$router[router][size][gt]" style="width:60px;" />
|
||||
<span class="input-group-addon">M</span> </div>
|
||||
</dd>
|
||||
<dd class="clearfix ">
|
||||
<ul class="help-block ">
|
||||
{lang cloud_movetool_file_size_text}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<input class="btn btn-primary" name="addroutersubmit" value="<!--{if $routerid}-->{lang edit}<!--{else}-->{lang add}<!--{/if}-->" type="submit">
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
function setExts(str) {
|
||||
var old = trim(document.getElementById('exts').value).replace(/,{1,}/g, ',').replace(/,{1,}/g, ',').replace(/^\,/g, '');
|
||||
var arr = old ? old.split(',') : [];
|
||||
var newarr = str.split(',');
|
||||
for(var i = 0; i < newarr.length; i++) {
|
||||
if(jQuery.inArray(newarr[i], arr) < 0) {
|
||||
arr.push(newarr[i]);
|
||||
}
|
||||
}
|
||||
document.getElementById('exts').value = arr.join(',');
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
97
admin/cloud/template/space.htm
Normal file
97
admin/cloud/template/space.htm
Normal file
@ -0,0 +1,97 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<style type="text/css">
|
||||
/*修改*/
|
||||
/*.bs-main-container{
|
||||
padding: 15px 30px;
|
||||
}*/
|
||||
|
||||
/*结束*/
|
||||
</style>
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
</div>
|
||||
<div class="bs-main-container clearfix" style="min-width:660px;">
|
||||
<div class="main-header clearfix">
|
||||
<!--{template right_header}-->
|
||||
<!--<div class="button_add_content">
|
||||
<a href="{BASESCRIPT}?mod=cloud&op=spaceadd" title="{lang add_storage_location}" id="button_add">+</a>
|
||||
</div> -->
|
||||
</div>
|
||||
<div class="main-content clearfix" >
|
||||
<form id="appform" name="appform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=cloud&op=space" method="post" >
|
||||
<input type="hidden" name="cloudsubmit" value="true" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<table class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="30">{lang sort}</th>
|
||||
<th width="150">{lang storage_location}</th>
|
||||
<th width="50">{lang default}</th>
|
||||
<th>{lang used_surplus}</th>
|
||||
<th width="50"> </th>
|
||||
</tr>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr>
|
||||
<td width="40"><input type="text" class="form-control" name="disp[{$value[remoteid]}]" value="$value[disp]" style="width:45px;" /></td>
|
||||
<td width="150"><input type="text" class="form-control" name="name[{$value[remoteid]}]" value="$value[name]" /></td>
|
||||
<td><label class="checkbox-inline"><input type="radio" name="isdefault" value="$value[remoteid]" <!--{if $value[isdefault]>0}-->checked<!--{/if}--> ></label></td>
|
||||
<td><div id="spaceinfo_{$value[remoteid]}"> <span class="spacesize" style="padding:0 5px">$value[fusesize] / $value[ftotalsize]</span> <span class="spacecheck" style="padding:0 5px"><a href="javascript:;" title="{lang to_obtain}" onclick="checkspace(this,'$value[remoteid]')"><i class="glyphicon glyphicon-refresh"></i></a></span>
|
||||
<!--{if $value[available]<1}-->
|
||||
<span class="text-danger">{lang space_storage_failure}</span>
|
||||
<!--{/if}-->
|
||||
</div></td>
|
||||
<td><a id="delete_{$value[remoteid]}" <!--{if $value[bz]=='dzz' || $value[usesize]>0}-->style="display:none"<!--{/if}-->class="text-danger" href="{BASESCRIPT}?mod=cloud&op=space&do=delete&remoteid=$value[remoteid]" onclick="if(confirm('{lang space_del_storage}')){return true;}else{return false}" >{lang delete}</a></td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
|
||||
<th valign="middle" colspan="7"><input type="submit" class="btn btn-primary" value="{lang save_set}" /> <a href="{BASESCRIPT}?mod=cloud&op=spaceadd" title="{lang add_storage_location}" class="btn btn-success">{lang add_storage_location}</a>
|
||||
</thead>
|
||||
</table>
|
||||
</form>
|
||||
<div class="tip" style="margin: 20px;color: #444;text-shadow: 1px 1px 1px #FFF;line-height: 1.8;">
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<h5>{lang board_message}</h5>
|
||||
<ul>
|
||||
{lang space_board_message_text}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
|
||||
function checkspace(obj,remoteid){
|
||||
jQuery(obj).html('<img src="admin/images/loadding.gif">');
|
||||
jQuery.getJSON('{ADMINSCRIPT}?mod=cloud&op=space&do=checkspace&remoteid='+remoteid,function(json){
|
||||
if(json.error){
|
||||
jQuery(this).html('<i class="glyphicon glyphicon-refresh"></i><span class="text-danger">'+json.error+'</span>');
|
||||
}else{
|
||||
jQuery('#spaceinfo_' + remoteid + ' .spacecheck a').html('<span class="text-success" >{lang already_update}</span>');
|
||||
jQuery('#spaceinfo_'+remoteid+' .spacesize').html(json.fusesize+' / '+json.ftotalsize).hide().fadeIn('slow');
|
||||
if(json.usesize<1){
|
||||
jQuery('delete_'+remoteid).show();
|
||||
}else{
|
||||
jQuery('delete_'+remoteid).hide();
|
||||
}
|
||||
|
||||
window.setTimeout(function(){
|
||||
jQuery('#spaceinfo_'+remoteid+' .spacecheck a').html('<i class="glyphicon glyphicon-refresh"></i>');
|
||||
},5000);
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
85
admin/cloud/template/spaceadd.htm
Normal file
85
admin/cloud/template/spaceadd.htm
Normal file
@ -0,0 +1,85 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="{MOD_PATH}/images/connect.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide" >
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=edit&bz=dzz"> {lang set}</a> </li>
|
||||
<li> <a href="{BASESCRIPT}?mod=cloud&op=space">{lang space_management}</a> </li>
|
||||
<li class="active"> <a href="{BASESCRIPT}?mod=cloud&op=spaceadd">{lang add_storage_location}</a> </li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content clearfix" style="border-top:1px solid #FFF">
|
||||
<div style="padding:15px;">
|
||||
<!--{loop $list $key $value}-->
|
||||
<h4>$value[header]</h4>
|
||||
<ul class="thumbnails list-unstyled clearfix">
|
||||
<!--{loop $value[list] $value1}-->
|
||||
<li bz="$value1[bz]" data_type="$key" class="cloud-item span2">
|
||||
<div class="thumbnail"> <img src="dzz/images/default/system/$value1[bz].png" width="100" />
|
||||
<h5 class="text-center" style="height:20px;line-height:20px;overflow:hidden;margin-bottom:5px">$value1[name]</h5>
|
||||
</div>
|
||||
</li>
|
||||
<!--{/loop}-->
|
||||
</ul>
|
||||
<!--{/loop}-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
|
||||
function connect_start(bz, type) { //开始云连接
|
||||
switch(type) {
|
||||
case 'pan':
|
||||
url = '{ADMINSCRIPT}?mod=cloud&bz=' + bz + '&op=oauth';
|
||||
window.location.href = url;
|
||||
break;
|
||||
case 'storage':
|
||||
url = '{ADMINSCRIPT}?mod=cloud&bz=' + bz + '&op=oauth';
|
||||
window.location.href = url;
|
||||
break;
|
||||
case 'ftp':
|
||||
url = '{ADMINSCRIPT}?mod=cloud&bz=' + bz + '&op=oauth';
|
||||
window.location.href = url;
|
||||
break;
|
||||
case 'disk':
|
||||
url = '{ADMINSCRIPT}?mod=cloud&bz=' + bz + '&op=oauth';
|
||||
window.location.href = url;
|
||||
break;
|
||||
default:
|
||||
url = '{ADMINSCRIPT}?mod=cloud&bz=' + bz + '&op=oauth';
|
||||
window.location.href = url;
|
||||
break;
|
||||
}
|
||||
}
|
||||
jQuery(document).ready(function(e) {
|
||||
jQuery('.thumbnails li').mouseenter(function() {
|
||||
jQuery(this).addClass('hover');
|
||||
}).mouseleave(function() {
|
||||
jQuery(this).removeClass('hover');
|
||||
}).click(function() {
|
||||
var bz = jQuery(this).attr('bz');
|
||||
var type = jQuery(this).attr('data_type');
|
||||
connect_start(bz, type);
|
||||
});
|
||||
jQuery(document).mousedown(function() {
|
||||
jQuery('.thumbnails li').removeClass('Selected');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
@ -1257,7 +1257,7 @@ AAiAAAjA0ceJaY9cOQAbHgBslgMw5wHATDkAL4CtFBe/Crw+NUAUBrscfYz4PYXFrwGdURj89xmQ
|
||||
KWXvsNKmERgG7gJXqeCmpQrHvn1uzQMTURj8KXZCRjZPSx9Q3fFvAHpKcdrrHql1AAAAAElFTkSu
|
||||
QmCC
|
||||
]]></item>
|
||||
<item id="appdesc"><![CDATA[]]></item>
|
||||
<item id="appdesc"><![CDATA[管理和查看系统所有文件]]></item>
|
||||
<item id="appurl"><![CDATA[{adminscript}?mod=filemanage]]></item>
|
||||
<item id="appadminurl"><![CDATA[]]></item>
|
||||
<item id="noticeurl"><![CDATA[]]></item>
|
||||
|
@ -274,7 +274,7 @@ function upgradeinformation($status = 0) {
|
||||
foreach($update as $key => $value) {
|
||||
$data .= $key.'='.rawurlencode($value).'&';
|
||||
}
|
||||
$upgradeurl = 'ht'.'tp:/'.'/dev'.'.'.'d'.'zzo'.'ffice.'.'c'.'om/upg'.'rade'.'.p'.'hp?'.'os=d'.'zzoff'.'ice&update='.rawurlencode(base64_encode($data)).'×tamp='.TIMESTAMP;
|
||||
$upgradeurl = APP_CHECK_URL."market/system/upgrade/".rawurlencode(base64_encode($data))."/".TIMESTAMP;
|
||||
return '<img src="'.$upgradeurl.'" width="0" height="0" />';
|
||||
}
|
||||
|
||||
|
@ -874,6 +874,7 @@ $lang = array
|
||||
// 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'=>'开启后,资源管理器会显示该机构群组选项。',
|
||||
@ -912,7 +913,7 @@ $lang = array
|
||||
<li>3、表中“邮箱”、“用户名”字段中的信息必须是唯一的,不可重复。如果邮箱为空,系统导入时将随机生成邮箱地址。</li>
|
||||
<li class="danger">4、多级部门创建:方法1:表中添加多列“所属部门”,从左到右分别为一级部门、二级部门、三级部门,顺序排列,系统会根据从左到右的原则,依次创建部门、下级部门、下下级部门等。方法2:表格中使用单列,上下级部门使用“/”来分割(例如:小学/一年级/一班)。</li>
|
||||
<li>5、导入用户只能按机构导入,多个机构需要分批导入。</li>
|
||||
<li>6、表中“用户密码”字段可为空,管理员在导入时能够为用户批量设置统一的密码。用户使用统一密码登录后可自行修改。</li>
|
||||
<li>6、表中“登录密码”字段可为空,管理员在导入时能够为用户批量设置统一的密码。用户使用统一密码登录后可自行修改。</li>
|
||||
<li>7、导入界面中有“增量”、“覆盖”两种导入方式。增量方式为:遇到相同用户,只会增加用户缺少的字段信息,原有信息不变。(例如:系统中已有用户A,密码为123。在批量导入表格中,也有用户A,导入时设置了统一密码为abc。导入完成后,其他用户的密码都为abc,原用户A还是保持他的原有密码,即123。)覆盖导入:将系统中原有的用户信息完全替换为表格中的信息。</li>
|
||||
<li>8、若需导入的人员较多,建议先做一个少量人员的测试表,测试无误后,再使用增量方式导入所有用户。</li>',
|
||||
|
||||
|
@ -60,6 +60,7 @@ if ($this -> cpaccess == -3) {
|
||||
html_login_footer();
|
||||
|
||||
function html_login_header($form = true) {
|
||||
global $_G;
|
||||
$uid = getglobal('uid');
|
||||
$charset = CHARSET;
|
||||
$lang = &lang();
|
||||
@ -71,6 +72,7 @@ function html_login_header($form = true) {
|
||||
<html>
|
||||
<head>
|
||||
<title>$title</title>
|
||||
<base href="{$_G['siteurl']}">
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=$charset" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
|
||||
<link rel="stylesheet" href="static/bootstrap/css/bootstrap.min.css" type="text/css" media="all" />
|
||||
|
1293
admin/member/dzz_app_member.xml
Normal file
1293
admin/member/dzz_app_member.xml
Normal file
File diff suppressed because it is too large
Load Diff
BIN
admin/member/images/icons_24.png
Normal file
BIN
admin/member/images/icons_24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 7.0 KiB |
94
admin/member/images/member.css
Normal file
94
admin/member/images/member.css
Normal file
@ -0,0 +1,94 @@
|
||||
.jstree-root{
|
||||
padding:5px 0 0 10px;
|
||||
line-height:24px;
|
||||
}
|
||||
.classtree-topbar{
|
||||
position:relative;
|
||||
bottom:0px;
|
||||
left:0px;
|
||||
background:#F7F7F7;
|
||||
border-bottom:1px solid #D2D2D2;
|
||||
border-top:1px solid #FFF;
|
||||
padding:7px 10px 3px 10px;
|
||||
}
|
||||
|
||||
.classtree-topbar a{
|
||||
display:inline-block;
|
||||
margin:0px 5px;
|
||||
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{
|
||||
|
||||
}
|
||||
|
||||
.classtree-search{
|
||||
position:absolute;
|
||||
left:1px;
|
||||
top:2px;
|
||||
display:none;
|
||||
}
|
||||
.classtree-search .form-control{
|
||||
padding:5px 40px 5px 5px;
|
||||
}
|
||||
.classtree-search .form-control:focus{
|
||||
box-shadow:none;
|
||||
}
|
||||
.classtree-search .search{
|
||||
position:absolute;
|
||||
right:28px;
|
||||
top:8px;
|
||||
}
|
||||
.classtree-search .delete{
|
||||
position:absolute;
|
||||
right:8px;
|
||||
top:8px;
|
||||
}
|
||||
/*重定义图标*/
|
||||
.jstree-default a i{
|
||||
_filter: Alpha(opacity=80);
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
.jstree-default .jstree-anchor>.jstree-themeicon {
|
||||
background-image:url(icons.png);
|
||||
width:24px;height:24px;margin:4px 0;
|
||||
}
|
||||
.jstree-open .jstree-anchor>.jstree-icon-book{
|
||||
background-position:-4px -24px;
|
||||
}
|
||||
.jstree-closed .jstree-anchor>.jstree-icon-book{
|
||||
background-position:-4px 0;
|
||||
}
|
||||
|
||||
.jstree-leaf .jstree-anchor>.jstree-icon-book{
|
||||
background-position:-4px 0;
|
||||
}
|
||||
.jstree-node .jstree-anchor>.jstree-icon-file{
|
||||
background-position:-4px -48px;
|
||||
}
|
BIN
admin/member/images/themes/default/32px.png
Normal file
BIN
admin/member/images/themes/default/32px.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.0 KiB |
BIN
admin/member/images/themes/default/40px.png
Normal file
BIN
admin/member/images/themes/default/40px.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.0 KiB |
BIN
admin/member/images/themes/default/organization.png
Normal file
BIN
admin/member/images/themes/default/organization.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 903 B |
917
admin/member/images/themes/default/style.css
Normal file
917
admin/member/images/themes/default/style.css
Normal file
@ -0,0 +1,917 @@
|
||||
/* jsTree default theme */
|
||||
.jstree-node,
|
||||
.jstree-children,
|
||||
.jstree-container-ul {
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
list-style-type: none;
|
||||
list-style-image: none;
|
||||
}
|
||||
.jstree-node {
|
||||
white-space: nowrap;
|
||||
}
|
||||
.jstree-anchor {
|
||||
display: inline-block;
|
||||
color: black;
|
||||
white-space: nowrap;
|
||||
padding: 0 4px 0 1px;
|
||||
margin: 0;
|
||||
vertical-align: top;
|
||||
}
|
||||
.jstree-anchor:focus {
|
||||
outline: 0;
|
||||
}
|
||||
.jstree-anchor,
|
||||
.jstree-anchor:link,
|
||||
.jstree-anchor:visited,
|
||||
.jstree-anchor:hover,
|
||||
.jstree-anchor:active {
|
||||
text-decoration: none;
|
||||
color: inherit;
|
||||
}
|
||||
.jstree-icon {
|
||||
display: inline-block;
|
||||
text-decoration: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
vertical-align: top;
|
||||
text-align: center;
|
||||
}
|
||||
.jstree-icon:empty {
|
||||
display: inline-block;
|
||||
text-decoration: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
vertical-align: top;
|
||||
text-align: center;
|
||||
}
|
||||
.jstree-ocl {
|
||||
cursor: pointer;
|
||||
}
|
||||
.jstree .jstree-open > .jstree-children {
|
||||
display: block;
|
||||
}
|
||||
.jstree .jstree-closed > .jstree-children,
|
||||
.jstree .jstree-leaf > .jstree-children {
|
||||
display: none;
|
||||
}
|
||||
.jstree-anchor > .jstree-themeicon {
|
||||
margin-right: 2px;
|
||||
}
|
||||
.jstree-no-icons .jstree-themeicon,
|
||||
.jstree-anchor > .jstree-themeicon-hidden {
|
||||
display: none;
|
||||
}
|
||||
.jstree-rtl .jstree-anchor {
|
||||
padding: 0 1px 0 4px;
|
||||
}
|
||||
.jstree-rtl .jstree-anchor > .jstree-themeicon {
|
||||
margin-left: 2px;
|
||||
margin-right: 0;
|
||||
}
|
||||
.jstree-rtl .jstree-node {
|
||||
margin-left: 0;
|
||||
}
|
||||
.jstree-rtl .jstree-container-ul > .jstree-node {
|
||||
margin-right: 0;
|
||||
}
|
||||
.jstree-wholerow-ul {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
min-width: 100%;
|
||||
}
|
||||
.jstree-wholerow-ul .jstree-anchor,
|
||||
.jstree-wholerow-ul .jstree-icon {
|
||||
position: relative;
|
||||
}
|
||||
.jstree-wholerow-ul .jstree-wholerow {
|
||||
width: 100%;
|
||||
cursor: pointer;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
.vakata-context {
|
||||
display: none;
|
||||
z-index:10000;
|
||||
}
|
||||
.vakata-context,
|
||||
.vakata-context ul {
|
||||
margin: 0;
|
||||
padding: 2px;
|
||||
position: absolute;
|
||||
background: #f5f5f5;
|
||||
border: 1px solid #979797;
|
||||
-moz-box-shadow: 5px 5px 4px -4px #666666;
|
||||
-webkit-box-shadow: 2px 2px 2px #999999;
|
||||
box-shadow: 2px 2px 2px #999999;
|
||||
}
|
||||
.vakata-context ul {
|
||||
list-style: none;
|
||||
left: 100%;
|
||||
margin-top: -2.7em;
|
||||
margin-left: -4px;
|
||||
}
|
||||
.vakata-context .vakata-context-right ul {
|
||||
left: auto;
|
||||
right: 100%;
|
||||
margin-left: auto;
|
||||
margin-right: -4px;
|
||||
}
|
||||
.vakata-context li {
|
||||
list-style: none;
|
||||
display: inline;
|
||||
}
|
||||
.vakata-context li > a {
|
||||
display: block;
|
||||
padding: 0 2em 0 2em;
|
||||
text-decoration: none;
|
||||
width: auto;
|
||||
color: black;
|
||||
white-space: nowrap;
|
||||
line-height: 2.4em;
|
||||
-moz-text-shadow: 1px 1px 0 white;
|
||||
-webkit-text-shadow: 1px 1px 0 white;
|
||||
text-shadow: 1px 1px 0 white;
|
||||
-moz-border-radius: 1px;
|
||||
-webkit-border-radius: 1px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.vakata-context li > a:hover {
|
||||
position: relative;
|
||||
background-color: #e8eff7;
|
||||
-moz-box-shadow: 0 0 2px #0a6aa1;
|
||||
-webkit-box-shadow: 0 0 2px #0a6aa1;
|
||||
box-shadow: 0 0 2px #0a6aa1;
|
||||
}
|
||||
.vakata-context li > a.vakata-context-parent {
|
||||
background-image: url("data:image/gif;base64,R0lGODlhCwAHAIAAACgoKP///yH5BAEAAAEALAAAAAALAAcAAAIORI4JlrqN1oMSnmmZDQUAOw==");
|
||||
background-position: right center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
.vakata-context li > a:focus {
|
||||
outline: 0;
|
||||
}
|
||||
.vakata-context .vakata-context-hover > a {
|
||||
position: relative;
|
||||
background-color: #e8eff7;
|
||||
-moz-box-shadow: 0 0 2px #0a6aa1;
|
||||
-webkit-box-shadow: 0 0 2px #0a6aa1;
|
||||
box-shadow: 0 0 2px #0a6aa1;
|
||||
}
|
||||
.vakata-context .vakata-context-separator a,
|
||||
.vakata-context .vakata-context-separator a:hover {
|
||||
background: white;
|
||||
border: 0;
|
||||
border-top: 1px solid #e2e3e3;
|
||||
height: 1px;
|
||||
min-height: 1px;
|
||||
max-height: 1px;
|
||||
padding: 0;
|
||||
margin: 0 0 0 2.4em;
|
||||
border-left: 1px solid #e0e0e0;
|
||||
-moz-text-shadow: 0 0 0 transparent;
|
||||
-webkit-text-shadow: 0 0 0 transparent;
|
||||
text-shadow: 0 0 0 transparent;
|
||||
-moz-box-shadow: 0 0 0 transparent;
|
||||
-webkit-box-shadow: 0 0 0 transparent;
|
||||
box-shadow: 0 0 0 transparent;
|
||||
-moz-border-radius: 0;
|
||||
-webkit-border-radius: 0;
|
||||
border-radius: 0;
|
||||
}
|
||||
.vakata-context .vakata-contextmenu-disabled a,
|
||||
.vakata-context .vakata-contextmenu-disabled a:hover {
|
||||
color: silver;
|
||||
background-color: transparent;
|
||||
border: 0;
|
||||
box-shadow: 0 0 0;
|
||||
}
|
||||
.vakata-context li > a > i {
|
||||
text-decoration: none;
|
||||
display: inline-block;
|
||||
width: 2.4em;
|
||||
height: 2.4em;
|
||||
background: transparent;
|
||||
margin: 0 0 0 -2em;
|
||||
vertical-align: top;
|
||||
text-align: center;
|
||||
line-height: 2.4em;
|
||||
}
|
||||
.vakata-context li > a > i:empty {
|
||||
width: 2.4em;
|
||||
line-height: 2.4em;
|
||||
}
|
||||
.vakata-context li > a .vakata-contextmenu-sep {
|
||||
display: inline-block;
|
||||
width: 1px;
|
||||
height: 2.4em;
|
||||
background: white;
|
||||
margin: 0 0.5em 0 0;
|
||||
border-left: 1px solid #e2e3e3;
|
||||
}
|
||||
.vakata-context .vakata-contextmenu-shortcut {
|
||||
font-size: 0.8em;
|
||||
color: silver;
|
||||
opacity: 0.5;
|
||||
display: none;
|
||||
}
|
||||
.vakata-context-rtl ul {
|
||||
left: auto;
|
||||
right: 100%;
|
||||
margin-left: auto;
|
||||
margin-right: -4px;
|
||||
}
|
||||
.vakata-context-rtl li > a.vakata-context-parent {
|
||||
background-image: url("data:image/gif;base64,R0lGODlhCwAHAIAAACgoKP///yH5BAEAAAEALAAAAAALAAcAAAINjI+AC7rWHIsPtmoxLAA7");
|
||||
background-position: left center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
.vakata-context-rtl .vakata-context-separator > a {
|
||||
margin: 0 2.4em 0 0;
|
||||
border-left: 0;
|
||||
border-right: 1px solid #e2e3e3;
|
||||
}
|
||||
.vakata-context-rtl .vakata-context-left ul {
|
||||
right: auto;
|
||||
left: 100%;
|
||||
margin-left: -4px;
|
||||
margin-right: auto;
|
||||
}
|
||||
.vakata-context-rtl li > a > i {
|
||||
margin: 0 -2em 0 0;
|
||||
}
|
||||
.vakata-context-rtl li > a .vakata-contextmenu-sep {
|
||||
margin: 0 0 0 0.5em;
|
||||
border-left-color: white;
|
||||
background: #e2e3e3;
|
||||
}
|
||||
#jstree-marker {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border-right: 0;
|
||||
border-top: 5px solid transparent;
|
||||
border-bottom: 5px solid transparent;
|
||||
border-left: 5px solid;
|
||||
width: 0;
|
||||
height: 0;
|
||||
font-size: 0;
|
||||
line-height: 0;
|
||||
}
|
||||
#jstree-dnd {
|
||||
line-height: 16px;
|
||||
margin: 0;
|
||||
padding: 4px;
|
||||
}
|
||||
#jstree-dnd .jstree-icon,
|
||||
#jstree-dnd .jstree-copy {
|
||||
display: inline-block;
|
||||
text-decoration: none;
|
||||
margin: 0 2px 0 0;
|
||||
padding: 0;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
#jstree-dnd .jstree-ok {
|
||||
background: green;
|
||||
}
|
||||
#jstree-dnd .jstree-er {
|
||||
background: red;
|
||||
}
|
||||
#jstree-dnd .jstree-copy {
|
||||
margin: 0 2px 0 2px;
|
||||
}
|
||||
.jstree-default .jstree-node,
|
||||
.jstree-default .jstree-icon {
|
||||
background-repeat: no-repeat;
|
||||
background-color: transparent;
|
||||
}
|
||||
.jstree-default .jstree-anchor,
|
||||
.jstree-default .jstree-wholerow {
|
||||
transition: background-color 0.15s, box-shadow 0.15s;
|
||||
}
|
||||
.jstree-default .jstree-hovered {
|
||||
background: #e7f4f9;
|
||||
border-radius: 2px;
|
||||
box-shadow: inset 0 0 1px #ccc;
|
||||
}
|
||||
.jstree-default .jstree-clicked {
|
||||
background: #beebff;
|
||||
border-radius: 2px;
|
||||
box-shadow: inset 0 0 1px #999;
|
||||
}
|
||||
.jstree-default .jstree-no-icons .jstree-anchor > .jstree-themeicon {
|
||||
display: none;
|
||||
}
|
||||
.jstree-default .jstree-disabled {
|
||||
background: transparent;
|
||||
color: #666;
|
||||
}
|
||||
.jstree-default .jstree-disabled.jstree-hovered {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
}
|
||||
.jstree-default .jstree-disabled.jstree-clicked {
|
||||
background: #efefef;
|
||||
}
|
||||
.jstree-default .jstree-disabled > .jstree-icon {
|
||||
opacity: 0.8;
|
||||
filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'jstree-grayscale\'><feColorMatrix type=\'matrix\' values=\'0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0\'/></filter></svg>#jstree-grayscale");
|
||||
/* Firefox 10+ */
|
||||
filter: gray;
|
||||
/* IE6-9 */
|
||||
-webkit-filter: grayscale(100%);
|
||||
/* Chrome 19+ & Safari 6+ */
|
||||
}
|
||||
.jstree-default .jstree-search {
|
||||
font-style: italic;
|
||||
color: #8b0000;
|
||||
font-weight: bold;
|
||||
}
|
||||
.jstree-default .jstree-no-checkboxes .jstree-checkbox {
|
||||
display: none !important;
|
||||
}
|
||||
.jstree-default.jstree-checkbox-no-clicked .jstree-clicked {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
}
|
||||
.jstree-default.jstree-checkbox-no-clicked .jstree-clicked.jstree-hovered {
|
||||
background: #e7f4f9;
|
||||
}
|
||||
.jstree-default.jstree-checkbox-no-clicked > .jstree-wholerow-ul .jstree-wholerow-clicked {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default.jstree-checkbox-no-clicked > .jstree-wholerow-ul .jstree-wholerow-clicked.jstree-wholerow-hovered {
|
||||
background: #e7f4f9;
|
||||
}
|
||||
#jstree-dnd.jstree-default .jstree-ok,
|
||||
#jstree-dnd.jstree-default .jstree-er {
|
||||
background-image: url("32px.png");
|
||||
background-repeat: no-repeat;
|
||||
background-color: transparent;
|
||||
}
|
||||
#jstree-dnd.jstree-default i {
|
||||
background: transparent;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
#jstree-dnd.jstree-default .jstree-ok {
|
||||
background-position: -9px -71px;
|
||||
}
|
||||
#jstree-dnd.jstree-default .jstree-er {
|
||||
background-position: -39px -71px;
|
||||
}
|
||||
.jstree-default > .jstree-striped {
|
||||
background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAkCAMAAAB/qqA+AAAABlBMVEUAAAAAAAClZ7nPAAAAAnRSTlMNAMM9s3UAAAAXSURBVHjajcEBAQAAAIKg/H/aCQZ70AUBjAATb6YPDgAAAABJRU5ErkJggg==") left top repeat;
|
||||
}
|
||||
.jstree-default > .jstree-wholerow-ul .jstree-hovered,
|
||||
.jstree-default > .jstree-wholerow-ul .jstree-clicked {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
border-radius: 0;
|
||||
}
|
||||
.jstree-default .jstree-wholerow {
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.jstree-default .jstree-wholerow-hovered {
|
||||
background: #e7f4f9;
|
||||
}
|
||||
.jstree-default .jstree-wholerow-clicked {
|
||||
background: #beebff;
|
||||
background: -moz-linear-gradient(top, #beebff 0%, #a8e4ff 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #beebff), color-stop(100%, #a8e4ff));
|
||||
background: -webkit-linear-gradient(top, #beebff 0%, #a8e4ff 100%);
|
||||
background: -o-linear-gradient(top, #beebff 0%, #a8e4ff 100%);
|
||||
background: -ms-linear-gradient(top, #beebff 0%, #a8e4ff 100%);
|
||||
background: linear-gradient(to bottom, #beebff 0%, #a8e4ff 100%);
|
||||
/*filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='@color1', endColorstr='@color2',GradientType=0 );*/
|
||||
}
|
||||
.jstree-default .jstree-node {
|
||||
min-height: 24px;
|
||||
line-height: 24px;
|
||||
margin-left: 24px;
|
||||
min-width: 24px;
|
||||
}
|
||||
.jstree-default .jstree-anchor {
|
||||
line-height: 24px;
|
||||
height: 24px;
|
||||
}
|
||||
.jstree-default .jstree-icon {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
}
|
||||
.jstree-default .jstree-icon:empty {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-node {
|
||||
margin-right: 24px;
|
||||
}
|
||||
.jstree-default .jstree-wholerow {
|
||||
height: 24px;
|
||||
}
|
||||
.jstree-default .jstree-node,
|
||||
.jstree-default .jstree-icon {
|
||||
background-image: url("32px.png");
|
||||
}
|
||||
.jstree-default .jstree-node {
|
||||
background-position: -292px -4px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default .jstree-open > .jstree-ocl {
|
||||
background-position: -132px -4px;
|
||||
}
|
||||
.jstree-default .jstree-closed > .jstree-ocl {
|
||||
background-position: -100px -4px;
|
||||
}
|
||||
.jstree-default .jstree-leaf > .jstree-ocl {
|
||||
background-position: -68px -4px;
|
||||
}
|
||||
.jstree-default .jstree-anchor > .jstree-themeicon {
|
||||
background-position: -260px -4px;
|
||||
}
|
||||
.jstree-default > .jstree-no-dots .jstree-node,
|
||||
.jstree-default > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -36px -4px;
|
||||
}
|
||||
.jstree-default > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: -4px -4px;
|
||||
}
|
||||
.jstree-default .jstree-disabled {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default .jstree-disabled.jstree-hovered {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default .jstree-disabled.jstree-clicked {
|
||||
background: #efefef;
|
||||
}
|
||||
.jstree-default .jstree-checkbox {
|
||||
background-position: -164px -4px;
|
||||
}
|
||||
.jstree-default .jstree-checkbox:hover {
|
||||
background-position: -164px -36px;
|
||||
}
|
||||
.jstree-default .jstree-clicked > .jstree-checkbox {
|
||||
background-position: -228px -4px;
|
||||
}
|
||||
.jstree-default .jstree-clicked > .jstree-checkbox:hover {
|
||||
background-position: -228px -36px;
|
||||
}
|
||||
.jstree-default .jstree-anchor > .jstree-undetermined {
|
||||
background-position: -196px -4px;
|
||||
}
|
||||
.jstree-default .jstree-anchor > .jstree-undetermined:hover {
|
||||
background-position: -196px -36px;
|
||||
}
|
||||
.jstree-default > .jstree-striped {
|
||||
background-size: auto 48px;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAACAQMAAAB49I5GAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjAAMOBgAAGAAJMwQHdQAAAABJRU5ErkJggg==");
|
||||
background-position: 100% 1px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-open > .jstree-ocl {
|
||||
background-position: -132px -36px;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-closed > .jstree-ocl {
|
||||
background-position: -100px -36px;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-leaf > .jstree-ocl {
|
||||
background-position: -68px -36px;
|
||||
}
|
||||
.jstree-default.jstree-rtl > .jstree-no-dots .jstree-node,
|
||||
.jstree-default.jstree-rtl > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default.jstree-rtl > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -36px -36px;
|
||||
}
|
||||
.jstree-default.jstree-rtl > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: -4px -36px;
|
||||
}
|
||||
.jstree-default .jstree-themeicon-custom {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
}
|
||||
.jstree-default > .jstree-container-ul .jstree-loading > .jstree-ocl {
|
||||
background: url("throbber.gif") center center no-repeat;
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAACAQMAAAB49I5GAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjAAMOBgAAGAAJMwQHdQAAAABJRU5ErkJggg==");
|
||||
}
|
||||
.jstree-default.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small .jstree-node {
|
||||
min-height: 18px;
|
||||
line-height: 18px;
|
||||
margin-left: 18px;
|
||||
min-width: 18px;
|
||||
}
|
||||
.jstree-default-small .jstree-anchor {
|
||||
line-height: 18px;
|
||||
height: 18px;
|
||||
}
|
||||
.jstree-default-small .jstree-icon {
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
line-height: 18px;
|
||||
}
|
||||
.jstree-default-small .jstree-icon:empty {
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
line-height: 18px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-node {
|
||||
margin-right: 18px;
|
||||
}
|
||||
.jstree-default-small .jstree-wholerow {
|
||||
height: 18px;
|
||||
}
|
||||
.jstree-default-small .jstree-node,
|
||||
.jstree-default-small .jstree-icon {
|
||||
background-image: url("32px.png");
|
||||
}
|
||||
.jstree-default-small .jstree-node {
|
||||
background-position: -295px -7px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default-small .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small .jstree-open > .jstree-ocl {
|
||||
background-position: -135px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-closed > .jstree-ocl {
|
||||
background-position: -103px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-leaf > .jstree-ocl {
|
||||
background-position: -71px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-anchor > .jstree-themeicon {
|
||||
background-position: -263px -7px;
|
||||
}
|
||||
.jstree-default-small > .jstree-no-dots .jstree-node,
|
||||
.jstree-default-small > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -39px -7px;
|
||||
}
|
||||
.jstree-default-small > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: -7px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-disabled {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small .jstree-disabled.jstree-hovered {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small .jstree-disabled.jstree-clicked {
|
||||
background: #efefef;
|
||||
}
|
||||
.jstree-default-small .jstree-checkbox {
|
||||
background-position: -167px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-checkbox:hover {
|
||||
background-position: -167px -39px;
|
||||
}
|
||||
.jstree-default-small .jstree-clicked > .jstree-checkbox {
|
||||
background-position: -231px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-clicked > .jstree-checkbox:hover {
|
||||
background-position: -231px -39px;
|
||||
}
|
||||
.jstree-default-small .jstree-anchor > .jstree-undetermined {
|
||||
background-position: -199px -7px;
|
||||
}
|
||||
.jstree-default-small .jstree-anchor > .jstree-undetermined:hover {
|
||||
background-position: -199px -39px;
|
||||
}
|
||||
.jstree-default-small > .jstree-striped {
|
||||
background-size: auto 36px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAACAQMAAAB49I5GAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjAAMOBgAAGAAJMwQHdQAAAABJRU5ErkJggg==");
|
||||
background-position: 100% 1px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-open > .jstree-ocl {
|
||||
background-position: -135px -39px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-closed > .jstree-ocl {
|
||||
background-position: -103px -39px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-leaf > .jstree-ocl {
|
||||
background-position: -71px -39px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl > .jstree-no-dots .jstree-node,
|
||||
.jstree-default-small.jstree-rtl > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -39px -39px;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: -7px -39px;
|
||||
}
|
||||
.jstree-default-small .jstree-themeicon-custom {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
}
|
||||
.jstree-default-small > .jstree-container-ul .jstree-loading > .jstree-ocl {
|
||||
background: url("throbber.gif") center center no-repeat;
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAACAQMAAABv1h6PAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjAAMHBgAAiABBI4gz9AAAAABJRU5ErkJggg==");
|
||||
}
|
||||
.jstree-default-small.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large .jstree-node {
|
||||
min-height: 32px;
|
||||
line-height: 32px;
|
||||
margin-left: 32px;
|
||||
min-width: 32px;
|
||||
}
|
||||
.jstree-default-large .jstree-anchor {
|
||||
line-height: 32px;
|
||||
height: 32px;
|
||||
}
|
||||
.jstree-default-large .jstree-icon {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
}
|
||||
.jstree-default-large .jstree-icon:empty {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-node {
|
||||
margin-right: 32px;
|
||||
}
|
||||
.jstree-default-large .jstree-wholerow {
|
||||
height: 32px;
|
||||
}
|
||||
.jstree-default-large .jstree-node,
|
||||
.jstree-default-large .jstree-icon {
|
||||
background-image: url("32px.png");
|
||||
}
|
||||
.jstree-default-large .jstree-node {
|
||||
background-position: -288px 0px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default-large .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large .jstree-open > .jstree-ocl {
|
||||
background-position: -128px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-closed > .jstree-ocl {
|
||||
background-position: -96px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-leaf > .jstree-ocl {
|
||||
background-position: -64px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-anchor > .jstree-themeicon {
|
||||
background-position: -256px 0px;
|
||||
}
|
||||
.jstree-default-large > .jstree-no-dots .jstree-node,
|
||||
.jstree-default-large > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -32px 0px;
|
||||
}
|
||||
.jstree-default-large > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: 0px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-disabled {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large .jstree-disabled.jstree-hovered {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large .jstree-disabled.jstree-clicked {
|
||||
background: #efefef;
|
||||
}
|
||||
.jstree-default-large .jstree-checkbox {
|
||||
background-position: -160px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-checkbox:hover {
|
||||
background-position: -160px -32px;
|
||||
}
|
||||
.jstree-default-large .jstree-clicked > .jstree-checkbox {
|
||||
background-position: -224px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-clicked > .jstree-checkbox:hover {
|
||||
background-position: -224px -32px;
|
||||
}
|
||||
.jstree-default-large .jstree-anchor > .jstree-undetermined {
|
||||
background-position: -192px 0px;
|
||||
}
|
||||
.jstree-default-large .jstree-anchor > .jstree-undetermined:hover {
|
||||
background-position: -192px -32px;
|
||||
}
|
||||
.jstree-default-large > .jstree-striped {
|
||||
background-size: auto 64px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAACAQMAAAB49I5GAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjAAMOBgAAGAAJMwQHdQAAAABJRU5ErkJggg==");
|
||||
background-position: 100% 1px;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-open > .jstree-ocl {
|
||||
background-position: -128px -32px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-closed > .jstree-ocl {
|
||||
background-position: -96px -32px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-leaf > .jstree-ocl {
|
||||
background-position: -64px -32px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl > .jstree-no-dots .jstree-node,
|
||||
.jstree-default-large.jstree-rtl > .jstree-no-dots .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl > .jstree-no-dots .jstree-open > .jstree-ocl {
|
||||
background-position: -32px -32px;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl > .jstree-no-dots .jstree-closed > .jstree-ocl {
|
||||
background-position: 0px -32px;
|
||||
}
|
||||
.jstree-default-large .jstree-themeicon-custom {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
}
|
||||
.jstree-default-large > .jstree-container-ul .jstree-loading > .jstree-ocl {
|
||||
background: url("throbber.gif") center center no-repeat;
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-node {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAACAQMAAAAD0EyKAAAABlBMVEUAAAAdHRvEkCwcAAAAAXRSTlMAQObYZgAAAAxJREFUCNdjgIIGBgABCgCBvVLXcAAAAABJRU5ErkJggg==");
|
||||
}
|
||||
.jstree-default-large.jstree-rtl .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
@media (max-width: 768px) {
|
||||
.jstree-default-responsive {
|
||||
/*
|
||||
.jstree-open > .jstree-ocl,
|
||||
.jstree-closed > .jstree-ocl { border-radius:20px; background-color:white; }
|
||||
*/
|
||||
}
|
||||
.jstree-default-responsive .jstree-icon {
|
||||
background-image: url("40px.png");
|
||||
}
|
||||
.jstree-default-responsive .jstree-node,
|
||||
.jstree-default-responsive .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-responsive .jstree-node {
|
||||
min-height: 40px;
|
||||
line-height: 40px;
|
||||
margin-left: 40px;
|
||||
min-width: 40px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.jstree-default-responsive .jstree-anchor {
|
||||
line-height: 40px;
|
||||
height: 40px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-icon,
|
||||
.jstree-default-responsive .jstree-icon:empty {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
}
|
||||
.jstree-default-responsive > .jstree-container-ul > .jstree-node {
|
||||
margin-left: 0;
|
||||
}
|
||||
.jstree-default-responsive.jstree-rtl .jstree-node {
|
||||
margin-left: 0;
|
||||
margin-right: 40px;
|
||||
}
|
||||
.jstree-default-responsive.jstree-rtl .jstree-container-ul > .jstree-node {
|
||||
margin-right: 0;
|
||||
}
|
||||
.jstree-default-responsive .jstree-ocl,
|
||||
.jstree-default-responsive .jstree-themeicon,
|
||||
.jstree-default-responsive .jstree-checkbox {
|
||||
background-size: 120px 200px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-leaf > .jstree-ocl {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-responsive .jstree-open > .jstree-ocl {
|
||||
background-position: 0 0px !important;
|
||||
}
|
||||
.jstree-default-responsive .jstree-closed > .jstree-ocl {
|
||||
background-position: 0 -40px !important;
|
||||
}
|
||||
.jstree-default-responsive.jstree-rtl .jstree-closed > .jstree-ocl {
|
||||
background-position: -40px 0px !important;
|
||||
}
|
||||
.jstree-default-responsive .jstree-anchor > .jstree-themeicon {
|
||||
background-position: -40px -40px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-checkbox,
|
||||
.jstree-default-responsive .jstree-checkbox:hover {
|
||||
background-position: -40px -80px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-clicked > .jstree-checkbox,
|
||||
.jstree-default-responsive .jstree-clicked > .jstree-checkbox:hover {
|
||||
background-position: 0 -80px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-anchor > .jstree-undetermined,
|
||||
.jstree-default-responsive .jstree-anchor > .jstree-undetermined:hover {
|
||||
background-position: 0 -120px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-anchor {
|
||||
font-weight: bold;
|
||||
font-size: 1.1em;
|
||||
text-shadow: 1px 1px white;
|
||||
}
|
||||
.jstree-default-responsive > .jstree-striped {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-responsive .jstree-wholerow {
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.7);
|
||||
border-bottom: 1px solid rgba(64, 64, 64, 0.2);
|
||||
background: #ebebeb;
|
||||
height: 40px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-wholerow-hovered {
|
||||
background: #e7f4f9;
|
||||
}
|
||||
.jstree-default-responsive .jstree-wholerow-clicked {
|
||||
background: #beebff;
|
||||
}
|
||||
.jstree-default-responsive .jstree-children .jstree-last > .jstree-wholerow {
|
||||
box-shadow: inset 0 -6px 3px -5px #666666;
|
||||
}
|
||||
.jstree-default-responsive .jstree-children .jstree-open > .jstree-wholerow {
|
||||
box-shadow: inset 0 6px 3px -5px #666666;
|
||||
border-top: 0;
|
||||
}
|
||||
.jstree-default-responsive .jstree-children .jstree-open + .jstree-open {
|
||||
box-shadow: none;
|
||||
}
|
||||
.jstree-default-responsive .jstree-node,
|
||||
.jstree-default-responsive .jstree-icon,
|
||||
.jstree-default-responsive .jstree-node > .jstree-ocl,
|
||||
.jstree-default-responsive .jstree-themeicon,
|
||||
.jstree-default-responsive .jstree-checkbox {
|
||||
background-image: url("40px.png");
|
||||
background-size: 120px 200px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-node {
|
||||
background-position: -80px 0;
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.jstree-default-responsive .jstree-last {
|
||||
background: transparent;
|
||||
}
|
||||
.jstree-default-responsive .jstree-leaf > .jstree-ocl {
|
||||
background-position: -40px -120px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-last > .jstree-ocl {
|
||||
background-position: -40px -160px;
|
||||
}
|
||||
.jstree-default-responsive .jstree-themeicon-custom {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
}
|
||||
}
|
||||
.jstree-default > .jstree-container-ul > .jstree-node {
|
||||
margin-left: 0;
|
||||
margin-right: 0;
|
||||
}
|
1
admin/member/images/themes/default/style.min.css
vendored
Normal file
1
admin/member/images/themes/default/style.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
BIN
admin/member/images/themes/default/throbber.gif
Normal file
BIN
admin/member/images/themes/default/throbber.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.7 KiB |
BIN
admin/member/images/themes/default/user.png
Normal file
BIN
admin/member/images/themes/default/user.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 599 B |
38
admin/member/index.php
Normal file
38
admin/member/index.php
Normal file
@ -0,0 +1,38 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
if (!$_G['cache']['usergroups']) {
|
||||
loadcache('usergroups');
|
||||
}
|
||||
$op=$_GET['op'];
|
||||
//error_reporting(E_ALL);
|
||||
//资料审核员和实名认证员跳转到对应的页面
|
||||
if ($_G['member']['grid'] == '4') {
|
||||
if ($_G['setting']['verify'][1]['available']) {
|
||||
$op = 'verify';
|
||||
$_GET['vid'] = 1;
|
||||
require MOD_PATH.'./admin/member/verify.php';
|
||||
exit();
|
||||
|
||||
} else {
|
||||
showmessage('contact_administrator');
|
||||
}
|
||||
} elseif ($_G['member']['grid'] == '5') {
|
||||
$op = 'verify';
|
||||
$_GET['vid'] = 0;
|
||||
require MOD_PATH.'/verify.php';
|
||||
exit();
|
||||
|
||||
}else{
|
||||
$op = 'verify';
|
||||
require MOD_PATH.'/verify.php';
|
||||
exit();
|
||||
}
|
@ -11,15 +11,12 @@ if(!defined('IN_DZZ')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
|
||||
class table_market_class extends dzz_table
|
||||
{
|
||||
public function __construct() {
|
||||
$lang = array
|
||||
(
|
||||
|
||||
'appname'=>'用户资料管理'
|
||||
|
||||
);
|
||||
|
||||
$this->_table = 'market_class';
|
||||
$this->_pk = 'classid';
|
||||
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
167
admin/member/profileset.php
Normal file
167
admin/member/profileset.php
Normal file
@ -0,0 +1,167 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$op=$_GET['op'];
|
||||
$profilevalidate = array(
|
||||
'telephone' => '/^((\\(?\\d{3,4}\\)?)|(\\d{3,4}-)?)\\d{7,8}$/',
|
||||
'mobile' => '/^(\+)?(86)?0?1\\d{10}$/',
|
||||
'zipcode' => '/^\\d{5,6}$/',
|
||||
'revenue' => '/^\\d+$/',
|
||||
'height' => '/^\\d{1,3}$/',
|
||||
'weight' => '/^\\d{1,3}$/',
|
||||
'qq' => '/^[1-9]*[1-9][0-9]*$/'
|
||||
);
|
||||
$fieldid = $_GET['fieldid'] ? $_GET['fieldid'] : '';
|
||||
$do=$_GET['do'] ? $_GET['do'] : '';
|
||||
if($do=='delete'){
|
||||
C::t('user_profile_setting')->delete_by_fieldid($fieldid);
|
||||
require_once libfile('function/cache');
|
||||
updatecache(array('profilesetting', 'fields_required', 'fields_optional', 'fields_register', 'setting'));
|
||||
showmessage('data_del_success',dreferer(),array(),array('alert'=>'right'));
|
||||
|
||||
}elseif($fieldid) {
|
||||
$_G['setting']['privacy'] = !empty($_G['setting']['privacy']) ? $_G['setting']['privacy'] : array();
|
||||
$_G['setting']['privacy'] = is_array($_G['setting']['privacy']) ? $_G['setting']['privacy'] : dunserialize($_G['setting']['privacy']);
|
||||
$field = C::t('user_profile_setting')->fetch($fieldid);
|
||||
$fixedfields1 = array('uid', 'constellation', 'zodiac');
|
||||
$fixedfields2 = array('gender', 'birthday','department');
|
||||
$field['isfixed1'] = in_array($fieldid, $fixedfields1);
|
||||
$field['isfixed2'] = $field['isfixed1'] || in_array($fieldid, $fixedfields2);
|
||||
//$field['customable'] = preg_match('/^field[1-8]$/i', $fieldid);
|
||||
$field['validate'] = $field['validate'] ? $field['validate'] : ($profilevalidate[$fieldid]?$profilevalidate[$fieldid]:'');
|
||||
if(!submitcheck('editsubmit')) {
|
||||
|
||||
$checkLanguage = checkLanguage();
|
||||
include template('profileset_edit');
|
||||
exit();
|
||||
} else {
|
||||
|
||||
$setarr = array(
|
||||
'invisible' => intval($_POST['invisible']),
|
||||
'showincard' => intval($_POST['showincard']),
|
||||
'showinregister' => intval($_POST['showinregister']),
|
||||
'allowsearch' => intval($_POST['allowsearch']),
|
||||
'displayorder' => intval($_POST['displayorder'])
|
||||
);
|
||||
if(!$field['isfixed2']) {
|
||||
$_POST['title'] = dhtmlspecialchars(trim($_POST['title']));
|
||||
if(empty($_POST['title'])) {
|
||||
showmessage('data_name_empty', ADMINSCRIPT.'?mod=member&op=profileset&fieldid='.$fieldid, array(),array('alert'=>'error'));
|
||||
}
|
||||
$setarr['title'] = $_POST['title'];
|
||||
$setarr['description'] = dhtmlspecialchars(trim($_POST['description']));
|
||||
}
|
||||
if(!$field['isfixed1']) {
|
||||
$setarr['required'] = intval($_POST['required']);
|
||||
$setarr['available'] = intval($_POST['available']);
|
||||
$setarr['unchangeable'] = intval($_POST['unchangeable']);
|
||||
$setarr['needverify'] = intval($_POST['needverify']);
|
||||
}
|
||||
if(!$field['isfixed2']) {
|
||||
$setarr['formtype'] = $fieldid == 'realname' ? 'text' : strtolower(trim($_POST['formtype']));
|
||||
$setarr['size'] = intval($_POST['size']);
|
||||
if($_POST['choices']) {
|
||||
$_POST['choices'] = trim($_POST['choices']);
|
||||
$ops = explode("\n", $_POST['choices']);
|
||||
$parts = array();
|
||||
foreach ($ops as $op) {
|
||||
$parts[] = dhtmlspecialchars(trim($op));
|
||||
}
|
||||
$_POST['choices'] = implode("\n", $parts);
|
||||
}
|
||||
$setarr['choices'] = $_POST['choices'];
|
||||
if($_POST['validate'] && $_POST['validate'] != $profilevalidate[$fieldid]) {
|
||||
$setarr['validate'] = $_POST['validate'];
|
||||
} elseif(empty($_POST['validate'])) {
|
||||
$setarr['validate'] = '';
|
||||
}
|
||||
}
|
||||
//print_r($setarr);exit($fieldid);
|
||||
C::t('user_profile_setting')->update($fieldid, $setarr);
|
||||
if($_GET['fieldid'] == 'birthday') {
|
||||
C::t('user_profile_setting')->update('birthmonth', $setarr);
|
||||
C::t('user_profile_setting')->update('birthyear', $setarr);
|
||||
}
|
||||
|
||||
|
||||
require_once libfile('function/cache');
|
||||
if(!isset($_G['setting']['privacy']['profile']) || $_G['setting']['privacy']['profile'][$fieldid] != $_POST['privacy']) {
|
||||
$_G['setting']['privacy']['profile'][$fieldid] = intval($_POST['privacy']);
|
||||
C::t('setting')->update('privacy', $_G['setting']['privacy']);
|
||||
}
|
||||
updatecache(array('profilesetting','fields_required', 'fields_optional', 'fields_register', 'setting'));
|
||||
|
||||
showmessage('subscriber_data_edit_success', ADMINSCRIPT.'?mod=member&op=profileset', array(),array('alert'=>'right'));
|
||||
}
|
||||
}else {
|
||||
|
||||
if(!submitcheck('ordersubmit')) {
|
||||
$list = array();
|
||||
foreach(C::t('user_profile_setting')->range() as $fieldid => $value) {
|
||||
$list[$fieldid] = array(
|
||||
'title'=>$value['title'],
|
||||
'displayorder'=>$value['displayorder'],
|
||||
'available'=>$value['available'],
|
||||
'invisible'=>$value['invisible'],
|
||||
'showincard'=>$value['showincard'],
|
||||
'showinregister'=>$value['showinregister'],
|
||||
'customable'=>$value['customable']);
|
||||
}
|
||||
|
||||
unset($list['birthyear']);
|
||||
unset($list['birthmonth']);
|
||||
|
||||
$fieldid='';
|
||||
|
||||
} else {
|
||||
foreach($_GET['displayorder'] as $fieldid => $value) {
|
||||
$setarr = array(
|
||||
'displayorder' => intval($value),
|
||||
'invisible' => intval($_GET['invisible'][$fieldid]) ? 0 : 1,
|
||||
'available' => intval($_GET['available'][$fieldid]),
|
||||
'showincard' => intval($_GET['showincard'][$fieldid]),
|
||||
'showinregister' => intval($_GET['showinregister'][$fieldid]),
|
||||
);
|
||||
C::t('user_profile_setting')->update($fieldid, $setarr);
|
||||
|
||||
if($fieldid == 'birthday') {
|
||||
C::t('user_profile_setting')->update('birthmonth', $setarr);
|
||||
C::t('user_profile_setting')->update('birthyear', $setarr);
|
||||
|
||||
}
|
||||
}
|
||||
foreach($_GET['add']['displayorder'] as $key => $value) {
|
||||
$setarr = array(
|
||||
'displayorder' => intval($value),
|
||||
'invisible' => intval($_GET['add']['invisible'][$key]) ? 0 : 1,
|
||||
'available' => intval($_GET['add']['available'][$key]),
|
||||
'showincard' => intval($_GET['add']['showincard'][$key]),
|
||||
'showinregister' => intval($_GET['add']['showinregister'][$key]),
|
||||
'title'=>dhtmlspecialchars($_GET['add']['title'][$key]),
|
||||
'fieldid'=>dhtmlspecialchars($_GET['add']['fieldid'][$key])
|
||||
);
|
||||
if(empty($setarr['title']) || empty($setarr['fieldid'])) continue;
|
||||
if(DB::result_first("select COUNT(*) from %t where fieldid=%s",array('user_profile_setting',$settarr['fieldid']))){
|
||||
continue;
|
||||
}
|
||||
C::t('user_profile_setting')->insert($setarr);
|
||||
|
||||
}
|
||||
require_once libfile('function/cache');
|
||||
updatecache(array('profilesetting', 'fields_required', 'fields_optional', 'fields_register', 'setting'));
|
||||
showmessage('subscriber_data_item_edit_success',dreferer(),array(),array('alert'=>'right'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
include template('profileset');
|
||||
|
||||
?>
|
173
admin/member/scripts/orguser.js
Normal file
173
admin/member/scripts/orguser.js
Normal file
@ -0,0 +1,173 @@
|
||||
/*
|
||||
* @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 delDepart(obj){
|
||||
jQuery(obj).parent().parent().remove();
|
||||
}
|
||||
|
||||
var tpml_index=0;
|
||||
function addorgsel(){
|
||||
jQuery('#selorg_container').append(' <ul class="nav nav-pills">'+(orgsel_html.replace(/orgid_tpml/ig,'orgid_tpml_'+tpml_index))+'</ul>');
|
||||
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('admin.php?mod=member&op=ajax&do=getjobs&orgid='+orgid,function(html){
|
||||
|
||||
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($(id)) {
|
||||
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($(id).value);
|
||||
if($(id).parentNode.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');
|
||||
x.get('user.php?mod=ajax&inajax=yes&infloat=register&handlekey=register&ajaxmenu=1&action=checkemail&email=' + email, function(s) {
|
||||
s=s.replace(/<a(.+?)<\/a>/i,'');
|
||||
errormessage(id, s);
|
||||
});
|
||||
}
|
||||
function checknick(id) {
|
||||
errormessage(id);
|
||||
var username = trim($(id).value);
|
||||
if($('chk_' + id).parentNode.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');
|
||||
x.get('user.php?mod=ajax&inajax=yes&infloat=register&handlekey=register&ajaxmenu=1&action=checkusername&username=' + encodeURI(username), function(s) {
|
||||
s=s.replace(/<a(.+?)<\/a>/i,'');
|
||||
errormessage(id, s);
|
||||
});
|
||||
}
|
||||
}
|
||||
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 || $(firstObj.id).value.length >= pwlength) {
|
||||
var passlevels = new Array('',__lang.weak,__lang.center,_lang.strong);
|
||||
var passlevel = checkstrongpw(firstObj.id);
|
||||
|
||||
errormessage(firstObj.id, '<span class="passlevel passlevel'+passlevel+'">'+__lang.intension+':'+passlevels[passlevel]+'</span>','passlevel');
|
||||
}
|
||||
};
|
||||
secondObj.onblur = function () {
|
||||
if(secondObj.value == '') {
|
||||
if(!modifypwd) errormessage(secondObj.id, !modifypwd ?'succeed' :__lang.register_repassword_tips);
|
||||
}
|
||||
checkpassword(firstObj.id, secondObj.id);
|
||||
};
|
||||
}
|
||||
|
||||
function checkpassword(id1, id2) {
|
||||
if(!$(id1).value && !$(id2).value) {
|
||||
//return;
|
||||
}
|
||||
if(pwlength > 0) {
|
||||
if($(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 && !$(id1).value.match(/\d+/g)) {
|
||||
strongpw_error = true;
|
||||
strongpw_str[j] = __lang.strongpw_1;
|
||||
j++;
|
||||
}
|
||||
if(strongpw[i] === 2 && !$(id1).value.match(/[a-z]+/g)) {
|
||||
strongpw_error = true;
|
||||
strongpw_str[j] = __lang.strongpw_2;
|
||||
j++;
|
||||
}
|
||||
if(strongpw[i] === 3 && !$(id1).value.match(/[A-Z]+/g)) {
|
||||
strongpw_error = true;
|
||||
strongpw_str[j] = __lang.strongpw_3;
|
||||
j++;
|
||||
}
|
||||
if(strongpw[i] === 4 && !$(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($(id1).value != $(id2).value) {
|
||||
errormessage(id2, __lang.profile_passwd_notmatch);
|
||||
} else {
|
||||
if(modifypwd) errormessage(id1, 'succeed' );
|
||||
errormessage(id2, 'succeed' );
|
||||
|
||||
}
|
||||
}
|
||||
|
30
admin/member/template/left.htm
Normal file
30
admin/member/template/left.htm
Normal file
@ -0,0 +1,30 @@
|
||||
<ul class="nav nav-pills nav-stacked nav-pills-leftguide">
|
||||
|
||||
<!--{if $_G['adminid']==1 || $_G['member']['grid']==5}-->
|
||||
<li <!--{if $op=='verify' && !$vid}-->class="active"<!--{/if}-->>
|
||||
<a href="{MOD_URL}&op=verify">{lang members_verify_profile}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
<!--{if $_G['adminid']==1}-->
|
||||
<li <!--{if $op=='profileset' }-->class="active"<!--{/if}-->>
|
||||
<a href="{MOD_URL}&op=profileset">{lang data_set}</a>
|
||||
</li>
|
||||
<li <!--{if $op=='verifyset' }-->class="active"<!--{/if}-->>
|
||||
<a href="{MOD_URL}&op=verifyset">{lang members_verify}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
|
||||
<!--{loop $_G[setting][verify] $key $value}-->
|
||||
<!--{if $value[available]}-->
|
||||
<!--{if $key==1 && ($_G['adminid']==1 || $_G['member']['grid']==4)}-->
|
||||
<li <!--{if $op=='verify' && $vid==$key}-->class="active"<!--{/if}-->>
|
||||
<a href="{MOD_URL}&op=verify&vid=$key">$value['title']</a>
|
||||
</li>
|
||||
<!--{elseif $_G['adminid']==1}-->
|
||||
<li <!--{if $op=='verify' && $vid==$key}-->class="active"<!--{/if}-->>
|
||||
<a href="{MOD_URL}&op=verify&vid=$key">$value['title']</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
<!--{/if}-->
|
||||
<!--{/loop}-->
|
||||
</ul>
|
99
admin/member/template/profile.htm
Normal file
99
admin/member/template/profile.htm
Normal file
@ -0,0 +1,99 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 150px;
|
||||
top: 0;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 150px;
|
||||
overflow: auto;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
|
||||
<div class="bs-container clearfix" style="padding-top:0">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header" style="padding:0 15px">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li>
|
||||
<a href="{BASESCRIPT}?mod=member">{lang member_list}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{BASESCRIPT}?mod=member&op=edituser&uid=$uid">{lang basic_information}</a>
|
||||
</li>
|
||||
<li class="active">
|
||||
<a href="{BASESCRIPT}?mod=member&op=edituser&do=profile&uid=$uid">{lang details_information}</a>
|
||||
</li>
|
||||
<!-- <li><a href="{BASESCRIPT}?mod=member&op=import">从文件导入</a></li>
|
||||
<li><a href="{BASESCRIPT}?mod=member&op=invite">Email邀请</a></li>-->
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="main-body" style="padding:15px 15px 15px 22px;">
|
||||
<div id="return_edituserprofile"></div>
|
||||
<form id="accountform" name="accountform" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod=member&op=edituser&do=profile" method="post" onsubmit="account_submit();return false">
|
||||
<input type="hidden" name="profilesubmit" value="true" />
|
||||
<input type="hidden" name="uid" value="$uid" />
|
||||
<input type="hidden" name="handlekey" value="edituserprofile" />
|
||||
<input type="hidden" name="formhash" value="{FORMHASH}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label">{lang compellation}</label>
|
||||
<div class="controls">
|
||||
<p class="form-control-static">$space[username]</p>
|
||||
</div>
|
||||
</div>
|
||||
<!--{loop $settings $key $value}-->
|
||||
<!--{if $value[available]}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="$key">$value[title]</label>
|
||||
<div class="controls">
|
||||
$htmls[$key]
|
||||
</div>
|
||||
</div>
|
||||
<!--{/if}-->
|
||||
<!--{/loop}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label"></label>
|
||||
<div class="controls">
|
||||
<input type="submit" class="btn btn-primary" value="{lang save_changes}">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript" reload="1">
|
||||
function account_submit() {
|
||||
ajaxpost('accountform', 'ajaxwaitid', 'return_edituserprofile');
|
||||
return false;
|
||||
}
|
||||
|
||||
function succeedhandle_edituserprofile(url, message, values) {
|
||||
showmessage(message, 'success', 3000, 1);
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
176
admin/member/template/profileset.htm
Normal file
176
admin/member/template/profileset.htm
Normal file
@ -0,0 +1,176 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/icheck/skins/minimal/blue.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 150px;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 150px;
|
||||
overflow: hidden;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.form-horizontal-left .radio-inline {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.itemContainer {
|
||||
overflow: auto;
|
||||
}
|
||||
#table-header th:nth-child(6),#table-header th:nth-child(7){
|
||||
display:none;
|
||||
}
|
||||
.itemContainer td:nth-child(6),.itemContainer td:nth-child(7){
|
||||
display:none;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix" style="padding-top:0px;">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="bs-main-container clearfix" >
|
||||
<div class="main-header">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if !$fieldid}-->class="active"<!--{/if}-->>
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset">{lang data_item_list}</a>
|
||||
</li>
|
||||
<!--{if $fieldid}-->
|
||||
<li class="active">
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset&fieldid=$fieldid">{lang data_edit}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</div>
|
||||
<table id="table-header" class="table" style="margin:0;font-size:12px;">
|
||||
|
||||
<thead>
|
||||
<th width="60">{lang sort}</th>
|
||||
<th width="120">{lang identifier}</th>
|
||||
<th>{lang name}</th>
|
||||
<th width="60">{lang enable}</th>
|
||||
<th width="60">{lang data_show}</th>
|
||||
<th width="60">{lang business_card_show}</th>
|
||||
<th width="60">{lang registration_page_display}</th>
|
||||
<th width="120">{lang operation}</th>
|
||||
</thead>
|
||||
|
||||
</table>
|
||||
<div class="itemContainer">
|
||||
<div class="main-content">
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=member&op=profileset" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="ordersubmit">
|
||||
<table class="table table-hover">
|
||||
<!--{loop $list $fieldid $value}-->
|
||||
<tr>
|
||||
|
||||
<td width="60"><input type="text" class="form-control input-sm" name="displayorder[$fieldid]" value="$value[displayorder]"></td>
|
||||
<td class="fieldid <!--{if !$value[customable]}-->gray<!--{/if}-->" width="120">$fieldid</td>
|
||||
<td>$value[title] </td>
|
||||
<td width="60"><input type="checkbox" class="checkbox" name="available[$fieldid]" <!--{if $value[available]}-->checked="checked"<!--{/if}-->value="1"></td>
|
||||
<td width="60"><input type="checkbox" class="checkbox" name="invisible[$fieldid]" <!--{if !$value[invisible]}-->checked="checked"<!--{/if}-->value="1"></td>
|
||||
<td width="60"><input type="checkbox" class="checkbox" name="showincard[$fieldid]" <!--{if $value[showincard]}-->checked="checked"<!--{/if}-->value="1"></td>
|
||||
<td width="60"><input type="checkbox" class="checkbox" name="showinregister[$fieldid]" <!--{if $value[showinregister]}-->checked="checked"<!--{/if}-->value="1"></td>
|
||||
<td width="100">
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset&fieldid=$fieldid" class="ibtn glyphicon glyphicon-edit " title="{lang edit}"></a>
|
||||
<!--{if $value['customable']}-->
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset&do=delete&fieldid=$fieldid" onclick="return confirm('{lang profileset_delete}')" class="ibtn glyphicon glyphicon-trash " title="{lang delete}"></a>
|
||||
<!--{/if}-->
|
||||
</td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<tr>
|
||||
<td colspan="20"><button type="button" class="btn btn-default btn-width" onclick="addRow(this)"><i class="glyphicon glyphicon-plus"></i>{lang add_data}</button></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="20"><input class="btn btn-primary btn-width" type="submit" value="{lang save_set}" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout(initHeight);
|
||||
var url = '{BASESCRIPT}?mod=member';
|
||||
|
||||
jQuery(document).ready(function(e) {
|
||||
jQuery('input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
jQuery('input').on('ifChecked', function(e) {
|
||||
jQuery(this).trigger('click');
|
||||
});
|
||||
|
||||
jQuery(document).on('blur', 'input[required]', function() {
|
||||
var self = this;
|
||||
var val = this.value;
|
||||
if(this.value == '') {
|
||||
jQuery(this).addClass('input-error');
|
||||
} else if(jQuery(this).hasClass('fieldid')) {
|
||||
jQuery('.fieldid').not(this).each(function() {
|
||||
if(jQuery(this).is('td') && this.innerHTML == val) {
|
||||
jQuery(self).addClass('input-error');
|
||||
showmessage('{lang identifier_use}', 'danger', 3000, 1);
|
||||
return;
|
||||
} else if(jQuery(this).is('input') && this.value == val) {
|
||||
jQuery(self).addClass('input-error');
|
||||
showmessage('{lang identifier_use}', 'danger', 3000, 1);
|
||||
return;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
jQuery(this).removeClass('input-error');
|
||||
}
|
||||
});
|
||||
jQuery(document).on('change', 'input[required]', function() {
|
||||
if(this.value == '') { jQuery(this).addClass('input-error') } else { jQuery(this).removeClass('input-error'); }
|
||||
});
|
||||
});
|
||||
|
||||
function initHeight() {
|
||||
jQuery('.itemContainer').css('height', document.documentElement.clientHeight-jQuery('.navbar').outerHeight(true)- jQuery('.main-header').outerHeight(true) - jQuery('#table-header').outerHeight(true));
|
||||
}
|
||||
|
||||
function addRow(obj) {
|
||||
var html = '<tr class="add">' +
|
||||
'<td width="60"><input type="text" class="form-control input-sm" name="add[displayorder][]" value="0" ></td>' +
|
||||
'<td width="120"><input type="text" class="form-control input-sm fieldid" name="add[fieldid][]" value="" placeholder="{lang can_not_repeat}" required="true"></td>' +
|
||||
'<td ><input type="text" class="form-control input-sm" name="add[title][]" value="" style="max-width:150px;" placeholder="{lang data_name}"></td>' +
|
||||
'<td width="60"><input type="checkbox" class="checkbox" name="add[available][]" value="1"></td>' +
|
||||
'<td width="60"><input type="checkbox" class="checkbox" name="add[invisible][]" value="1"></td>' +
|
||||
'<td width="60"><input type="checkbox" class="checkbox" name="add[showincard][]" value="1"></td>' +
|
||||
'<td width="60"><input type="checkbox" class="checkbox" name="add[showinregister][]" value="1"></td>' +
|
||||
'<td width="120"><a href="javascript:;" onclick="jQuery(this).parent().parent().remove()"><i class="ibtn glyphicon glyphicon-trash"></i></a></td>';
|
||||
jQuery(html).insertBefore(jQuery(obj).parent().parent());
|
||||
jQuery('.add input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
|
||||
}
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/icheck/icheck.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
252
admin/member/template/profileset_edit.htm
Normal file
252
admin/member/template/profileset_edit.htm
Normal file
@ -0,0 +1,252 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/icheck/skins/minimal/blue.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/select2/select2.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/select2/select2-bootstrap.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
text-shadow: 1px 1px 1px #FFF;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 150px;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 150px;
|
||||
overflow: auto;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.form-horizontal-left .radio-inline {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.form-horizontal-left .form-group .controls {
|
||||
min-width: 250px;
|
||||
}
|
||||
|
||||
.form-horizontal-left .form-group .controls-adapt {
|
||||
padding-left: 130px;
|
||||
}
|
||||
|
||||
.form-horizontal-left .form-group label {
|
||||
min-width: 125px;
|
||||
}
|
||||
|
||||
.form-horizontal-left .control-label {
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.icheckbox_minimal-blue,
|
||||
.iradio_minimal-blue {
|
||||
margin-left: -20px;
|
||||
}
|
||||
textarea.form-control{
|
||||
border-width:1px 1px 1px 1px;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix" style="padding-top:0px;">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if !$fieldid}-->class="active"<!--{/if}-->>
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset">{lang data_item_list}</a>
|
||||
</li>
|
||||
<!--{if $fieldid}-->
|
||||
<li class="active">
|
||||
<a href="{BASESCRIPT}?mod=member&op=profileset&fieldid=$fieldid">{lang data_edit}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content" style="padding:15px 0 0 10px;">
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=member&op=profileset" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="editsubmit">
|
||||
<input type="hidden" value="$fieldid" name="fieldid">
|
||||
<input type="hidden" value="$field[displayorder]" name="displayorder">
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang name}:</label>
|
||||
<input type="text" class="form-control" value="$field[title]" name="title" required="required" <!--{if $field[isfixed2]}-->disabled="disabled"
|
||||
<!--{/if}-->/>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang introduce}:</label>
|
||||
<input type="text" class="form-control" value="$field[description]" name="description" <!--{if $field[isfixed2]}-->disabled="disabled"
|
||||
<!--{/if}-->/>
|
||||
</div>
|
||||
|
||||
<!--{if !$field[isfixed2]}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang form_type}:</label>
|
||||
<div class="controls-adapt">
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="text" onclick="$('valuenumber').style.display = '';$('fieldchoices').style.display = 'none';$('fieldvalidate').style.display = '';" <!--{if $field[formtype]=='text'}-->checked="checked"<!--{/if}-->>{lang HtmlInputText}</label>
|
||||
<!--{if $fieldid!='realname'}-->
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="textarea" onclick="$('valuenumber').style.display = '';$('fieldchoices').style.display = 'none';$('fieldvalidate').style.display = '';" <!--{if $field[formtype]=='textarea'}-->checked="checked"<!--{/if}-->>{lang HtmlTextArea}</label>
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="radio" onclick="$('valuenumber').style.display = 'none';$('fieldchoices').style.display = '';$('fieldvalidate').style.display = 'none';" <!--{if $field[formtype]=='radio'}-->checked="checked"<!--{/if}-->>{lang radio}</label>
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="checkbox" onclick="$('valuenumber').style.display = '';$('fieldchoices').style.display = '';$('fieldvalidate').style.display = 'none';" <!--{if $field[formtype]=='checkbox'}-->checked="checked"<!--{/if}-->>{lang checkBox}</label>
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="select" onclick="$('valuenumber').style.display = 'none';$('fieldchoices').style.display = '';$('fieldvalidate').style.display = 'none';" <!--{if $field[formtype]=='select'}-->checked="checked"<!--{/if}-->>{lang combobox}</label>
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="list" onclick="$('valuenumber').style.display = '';$('fieldchoices').style.display = '';" <!--{if $field[formtype]=='list'}-->checked="checked"<!--{/if}-->>{lang more_choose_list}</label>
|
||||
<label class="radio-inline"><input type="radio" name="formtype" value="file" onclick="$('valuenumber').style.display = '';$('fieldchoices').style.display = 'none';$('fieldvalidate').style.display = 'none';" <!--{if $field[formtype]=='file'}-->checked="checked"<!--{/if}-->>{lang upload_image}</label>
|
||||
<!--{/if}-->
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" id="valuenumber" <!--{if $field[formtype]=='select' || $field[formtype]=='radio' }-->style="display:none"<!--{/if}-->>
|
||||
<label class="control-label ">{lang hawkeye_shellinit}:</label>
|
||||
<input name="size" value="$field[size]" type="text" class="form-control">
|
||||
<span class="help-inline">{lang profileset_edit_delete}</span>
|
||||
</div>
|
||||
<div class="form-group" id="fieldchoices" <!--{if $field[formtype]=='text' || $field[formtype]=='textarea' || $field[formtype]=='file' }-->style="display:none"<!--{/if}-->>
|
||||
<label class="control-label ">{lang option_values}:</label>
|
||||
<textarea rows="6" name="choices" id="choices" class="form-control">$field[choices]</textarea>
|
||||
<span class="help-inline">{lang profileset_edit_value}:<br>{lang beijing}<br>{lang shanghai}<br></span>
|
||||
</div>
|
||||
<div class="form-group" id="fieldvalidate" <!--{if $field[formtype]=='radio' || $field[formtype]=='select' || $field[formtype]=='list' || $field[formtype]=='checkbox' || $field[formtype]=='file' }-->style="display:none"<!--{/if}-->>
|
||||
<label class="control-label ">{lang regular_verification}:</label>
|
||||
<input name="validate" value="$field[validate]" type="text" class="form-control">
|
||||
<span class="help-inline">{lang profileset_edit_edit}</span>
|
||||
</div>
|
||||
|
||||
<!--{/if}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang members_verify_enable}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="available" value="1" <!--{if $field[available]}-->checked="checked"<!--{/if}-->>{lang enable}</label>
|
||||
<label class="radio-inline"><input type="radio" name="available" value="0" <!--{if !$field[available]}-->checked="checked"<!--{/if}-->>{lang no_enable}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--{if !$field[ isfixed1]}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang submit_hou}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="unchangeable" value="1" <!--{if $field[unchangeable]}-->checked="checked"<!--{/if}-->>{lang no_modification}</label>
|
||||
<label class="radio-inline"><input type="radio" name="unchangeable" value="0" <!--{if !$field[unchangeable]}-->checked="checked"<!--{/if}-->>{lang revisability}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang modification_hou}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="needverify" value="1" <!--{if $field[needverify]}-->checked="checked"<!--{/if}-->>{lang need_moderate}</label>
|
||||
<label class="radio-inline"><input type="radio" name="needverify" value="0" <!--{if !$field[needverify]}-->checked="checked"<!--{/if}-->>{lang no_need_moderate}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang if_required}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="required" value="1" <!--{if $field[required]}-->checked="checked"<!--{/if}-->>{lang required}</label>
|
||||
<label class="radio-inline"><input type="radio" name="required" value="0" <!--{if !$field[required]}-->checked="checked"<!--{/if}-->>{lang certificate}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang data_page}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="invisible" value="1" <!--{if $field[invisible]}-->checked="checked"<!--{/if}-->>{lang hide}</label>
|
||||
<label class="radio-inline"><input type="radio" name="invisible" value="0" <!--{if !$field[invisible]}-->checked="checked"<!--{/if}-->>{lang show}</label>
|
||||
</div>
|
||||
<span class="help-inline">{lang profileset_edit_hide}</span>
|
||||
</div>
|
||||
<!--{/if}-->
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang default_privacy}:</label>
|
||||
<div class="contols-adapt">
|
||||
<label class="radio-inline"><input type="radio" name="privacy" value="-1" <!--{if $_G['setting']['privacy']['profile'][$fieldid]=='-1'}-->checked="checked"<!--{/if}-->>{lang secret}</label>
|
||||
<label class="radio-inline"><input type="radio" name="privacy" value="0" <!--{if empty($_G['setting']['privacy']['profile'][$fieldid])}-->checked="checked"<!--{/if}-->>{lang public}</label>
|
||||
<label class="radio-inline"><input type="radio" name="privacy" value="1" <!--{if $_G['setting']['privacy']['profile'][$fieldid]=='1'}-->checked="checked"<!--{/if}-->>{lang department_visible}</label>
|
||||
<label class="radio-inline"><input type="radio" name="privacy" value="2" <!--{if $_G['setting']['privacy']['profile'][$fieldid]=='2'}-->checked="checked"<!--{/if}-->>{lang institution_visible}</label>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang business_card}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="showincard" value="1" <!--{if $field[showincard]}-->checked="checked"<!--{/if}-->>{lang show}</label>
|
||||
<label class="radio-inline"><input type="radio" name="showincard" value="0" <!--{if !$field[showincard]}-->checked="checked"<!--{/if}-->>{lang no_show}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang registration_page}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="showinregister" value="1" <!--{if $field[showinregister]}-->checked="checked"<!--{/if}-->>{lang show}</label>
|
||||
<label class="radio-inline"><input type="radio" name="showinregister" value="0" <!--{if !$field[showinregister]}-->checked="checked"<!--{/if}-->>{lang no_show}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label ">{lang allow_search}:</label>
|
||||
<div class="controls">
|
||||
<label class="radio-inline"><input type="radio" name="allowsearch" value="1" <!--{if $field[allowsearch]}-->checked="checked"<!--{/if}-->>{lang allow_search}</label>
|
||||
<label class="radio-inline"><input type="radio" name="allowsearch" value="0" <!--{if !$field[allowsearch]}-->checked="checked"<!--{/if}-->>{lang no_allow_search}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label "></label>
|
||||
<div class="controls">
|
||||
<input type="submit" class="btn btn-primary btn-width" name="editsubmit" value="{lang save_set}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var url = '{BASESCRIPT}?mod=member';
|
||||
jQuery(document).ready(function(e) {
|
||||
jQuery('input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
jQuery('input').on('ifChecked', function(e) {
|
||||
jQuery(this).trigger('click');
|
||||
});
|
||||
|
||||
jQuery(document).on('blur', 'input[required]', function() {
|
||||
var self = this;
|
||||
var val = this.value;
|
||||
if(this.value == '') {
|
||||
jQuery(this).addClass('input-error');
|
||||
} else if(jQuery(this).hasClass('fieldid')) {
|
||||
jQuery('.fieldid').not(this).each(function() {
|
||||
if(jQuery(this).is('td') && this.innerHTML == val) {
|
||||
jQuery(self).addClass('input-error');
|
||||
showmessage('{lang identifier_use}', 'danger', 3000, 1);
|
||||
return;
|
||||
} else if(jQuery(this).is('input') && this.value == val) {
|
||||
jQuery(self).addClass('input-error');
|
||||
showmessage('{lang identifier_use}', 'danger', 3000, 1);
|
||||
return;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
jQuery(this).removeClass('input-error');
|
||||
}
|
||||
});
|
||||
jQuery(document).on('change', 'input[required]', function() {
|
||||
if(this.value == '') { jQuery(this).addClass('input-error') } else { jQuery(this).removeClass('input-error'); }
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/icheck/icheck.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/select2/select2.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/select2/select2_locale_$checkLanguage.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
294
admin/member/template/verify.htm
Normal file
294
admin/member/template/verify.htm
Normal file
@ -0,0 +1,294 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/icheck/skins/minimal/blue.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="admin/scripts/admin.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 150px;
|
||||
top: 0
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 150px;
|
||||
overflow: auto;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.form-horizontal-left .radio-inline {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.mod_validate td {
|
||||
background: #dff0d8 !important;
|
||||
}
|
||||
|
||||
.mod_refusal td {
|
||||
background: #f2dede !important;
|
||||
}
|
||||
|
||||
.table-sub tr {
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
.table td img {
|
||||
max-width: 50px;
|
||||
max-height: 50px;
|
||||
margin: 0px;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
|
||||
<div class="bs-container clearfix" style="padding-top:0px;">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if $anchor=='authstr' }-->class="active"<!--{/if}-->>
|
||||
<a href="{BASESCRIPT}?mod=member&op=verify&anchor=authstr&vid=$vid">{lang members_verify_nav_authstr}</a>
|
||||
</li>
|
||||
<li <!--{if $anchor=='refusal' }-->class="active"<!--{/if}-->>
|
||||
<a href="{BASESCRIPT}?mod=member&op=verify&anchor=refusal&vid=$vid">{lang members_verify_nav_refusal}</a>
|
||||
</li>
|
||||
<!--{if $vid}-->
|
||||
<li <!--{if $anchor=='pass' }-->class="active"<!--{/if}-->>
|
||||
<a href="{BASESCRIPT}?mod=member&op=verify&anchor=pass&vid=$vid">{lang already_passed}</a>
|
||||
</li>
|
||||
<!--{/if}-->
|
||||
</ul>
|
||||
</div>
|
||||
<div class=" " style="padding:15px 15px 0 15px;font-size:85%;">
|
||||
<form action="{BASESCRIPT}" method="get">
|
||||
<table cellspacing="5" cellpadding="5" style="min-width:390px">
|
||||
<tbody>
|
||||
<tr height="35">
|
||||
<th>{lang user_name}*</th>
|
||||
<td><input type="text" name="username" value="$_GET[username]" class="form-control input-sm" style="width:120px;"></td>
|
||||
<th style="text-align:right">UID:</th>
|
||||
<td><input type="text" name="uid" value="$_GET[uid]" class="form-control input-sm" style="width:125px;"></td>
|
||||
</tr>
|
||||
<!--{if $anchor!='pass'}-->
|
||||
<tr height="35">
|
||||
<th>{lang members_verify_dateline}:</th>
|
||||
<td colspan="3"><input type="text" name="dateline1" value="$_GET[dateline1]" class="form-control input-sm" style="width:120px;display:inline-block" onclick="showcalendar(event, this)" /> ~
|
||||
<input type="text" name="dateline2" value="$_GET[dateline2]" class="form-control input-sm" style="width:125px;display:inline-block" onclick="showcalendar(event, this)" /></td>
|
||||
</tr>
|
||||
<!--{/if}-->
|
||||
<tr height="35">
|
||||
<th>{lang result_ranking}:</th>
|
||||
<td colspan="3">
|
||||
<!--{if $anchor!='pass'}-->
|
||||
<select name="orderby" class="form-control input-sm" style="width:95px;display:inline-block">
|
||||
<option value="dateline">{lang members_verify_dateline}</option>
|
||||
</select>
|
||||
<!--{else}-->
|
||||
<select name="orderby" class="form-control input-sm" style="width:95px;display:inline-block">
|
||||
<option value="uid">UID</option>
|
||||
</select>
|
||||
<!--{/if}-->
|
||||
<select name="ordersc" class="form-control input-sm" style="width:73px;display:inline-block">
|
||||
<option value="desc" <!--{if $_GET[ordersc]=='desc' }-->selected="selected"<!--{/if}-->>{lang pass_subtract}</option>
|
||||
<option value="asc" <!--{if $_GET[ordersc]=='asc' }-->selected="selected"<!--{/if}-->>{lang pass_add}</option>
|
||||
</select>
|
||||
<select name="perpage" class="form-control input-sm" style="width:125px;display:inline-block">
|
||||
<option value="10" <!--{if $_GET[perpage]=='10' }-->selected="selected"<!--{/if}-->>{lang logs_lpp}10{lang individual}</option>
|
||||
<option value="20" <!--{if $_GET[perpage]=='20' }-->selected="selected"<!--{/if}-->>{lang logs_lpp}20{lang individual}</option>
|
||||
<option value="50" <!--{if $_GET[perpage]=='50' }-->selected="selected"<!--{/if}-->>{lang logs_lpp}50{lang individual}</option>
|
||||
<option value="100" <!--{if $_GET[perpage]=='100' }-->selected="selected"<!--{/if}-->>{lang logs_lpp}100{lang individual}</option>
|
||||
</select>
|
||||
<input type="hidden" name="mod" value="member">
|
||||
<input type="hidden" name="op" value="verify">
|
||||
<input type="hidden" name="vid" value="$vid">
|
||||
<input type="hidden" name="anchor" value="$anchor"></td>
|
||||
</tr>
|
||||
<tr height="45">
|
||||
<td> </td>
|
||||
<td colspan="3"><input type="submit" name="searchsubmit" value="{lang search}" class="btn btn-default btn-sm btn-width">
|
||||
<span class="help-inline"> *{lang fuzzy_search}</span></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
<script type="text/javascript" src="static/js/calendar.js?{VERHASH}"></script>
|
||||
</div>
|
||||
<div class="main-content" style="border-top:1px solid #DDD">
|
||||
<iframe id="frame_profile" name="frame_profile" style="display: none"></iframe>
|
||||
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=member&op=verify" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="verifysubmit">
|
||||
<input type="hidden" value="$vid" name="vid">
|
||||
<input type="hidden" name="anchor" value="$anchor">
|
||||
<table class="table table-hover" style="font-size:12px;">
|
||||
<!--{if $anchor!='pass'}-->
|
||||
<thead>
|
||||
<th width="90" style="text-align:center">{lang username}</th>
|
||||
<th width="120">{lang members_verify_dateline}</th>
|
||||
<th>{lang members_verify_info}</th>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr id="mod_{$value[vid]}_row" verifyid="{$value[vid]}" class="hover">
|
||||
<td width="90" align="center">$value[username]</td>
|
||||
<td width="120">$value[dateline]</td>
|
||||
<td>$value[fieldstr]</td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<td colspan="15">
|
||||
|
||||
<input type="submit" class="btn btn-primary" id="submit_batchverifysubmit" name="batchverifysubmit" title="" value="{lang submit}">
|
||||
<a href="javascript:;" class="btn btn-link" onclick="mod_setbg_all('validate')">{lang all_validate}</a>
|
||||
<a class="btn btn-link" href="javascript:;" onclick="mod_setbg_all('refusal')">{lang select_all_refuse}</a>
|
||||
<a class="btn btn-link" href="javascript:;" onclick="mod_cancel_all();">{lang cancel_select}</a>
|
||||
$multi
|
||||
</td>
|
||||
</thead>
|
||||
<!--{else}-->
|
||||
<thead>
|
||||
<th width="80"></th>
|
||||
<th width="90" style="text-align:center">{lang username}</th>
|
||||
|
||||
<th>{lang members_verify_info}</th>
|
||||
</thead>
|
||||
<!--{loop $list $value}-->
|
||||
<tr id="mod_{$value[uid]}_row" verifyid="{$value[uid]}" class="hover">
|
||||
<td width="80">$value[opstr]</td>
|
||||
<td width="90" align="center">$value[username]</td>
|
||||
<td>$value[fieldstr]</td>
|
||||
</tr>
|
||||
<!--{/loop}-->
|
||||
<thead>
|
||||
<td colspan="15">
|
||||
<input type="submit" class="btn btn-primary" id="submit_batchverifysubmit" name="batchverifysubmit" title="" value="{lang submit}">
|
||||
<a href="javascript:;" class="btn btn-link" onclick="mod_setbg_all('export')">{lang select_all_export}</a>
|
||||
<a class="btn btn-link" href="javascript:;" onclick="mod_setbg_all('refusal')">{lang select_all_refuse}</a>
|
||||
<a class="btn btn-link" href="{ADMINSCRIPT}?mod=member&op=verify&vid=$vid&anchor=pass&verifysubmit=yes">{lang all_export}</a>
|
||||
$multi
|
||||
</td>
|
||||
</thead>
|
||||
<!--{/if}-->
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <table width="96%">
|
||||
<thead>
|
||||
<tr height="30">
|
||||
<th width="30" >拒绝</th>
|
||||
<th width="100">审核项</th>
|
||||
<th>提交信息</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody id="verifyitem_28">
|
||||
<tr height="30">
|
||||
<td ><input type="checkbox" name="refusal[28][company]" value="company" onclick="$('refusal28').click();"></td>
|
||||
<td>公司:</td>
|
||||
<td>灌灌灌灌hhhhhhhhhhh</td>
|
||||
</tr>
|
||||
<tr height="30">
|
||||
<td ><input type="checkbox" name="refusal[28][occupation]" value="occupation" onclick="$('refusal28').click();"></td>
|
||||
<td>职业:</td>
|
||||
<td>顶顶顶顶顶hhhhhhhhhhhh</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody>
|
||||
<tr height="30">
|
||||
<td colspan="5"><label class="radio-inline"><input type="radio" name="verify[28]" value="validate" onclick="mod_setbg(28, 'validate');showreason(28, 0);">通过</label>
|
||||
<label class="radio-inline"><input type="radio" name="verify[28]" value="refusal" id="refusal28" onclick="mod_setbg(28, 'refusal');showreason(28, 1);"> 拒绝</label>
|
||||
<span id="reason_28" style="display: none;">
|
||||
<input type="text" class="form-control input-sm" name="reason[28]" style="margin: 0px;" placeholder="操作理由">
|
||||
</span>
|
||||
<input type="button" value="审核" name="singleverifysubmit" class="btn btn-success btn-sm" onclick="singleverify(28);"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>-->
|
||||
<script type="text/javascript">
|
||||
function showreason(vid, flag) {
|
||||
var reasonobj = $('reason_' + vid);
|
||||
if(reasonobj) {
|
||||
reasonobj.style.display = flag ? '' : 'none';
|
||||
}
|
||||
if(!flag && $('verifyitem_' + vid) != null) {
|
||||
var checkboxs = $('verifyitem_' + vid).getElementsByTagName('input');
|
||||
for(var i in checkboxs) {
|
||||
if(checkboxs[i].type == 'checkbox') {
|
||||
checkboxs[i].checked = '';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function mod_setbg(vid, value) {
|
||||
$('mod_' + vid + '_row').className = 'mod_' + value;
|
||||
}
|
||||
|
||||
function mod_setbg_all(value) {
|
||||
checkAll('option', $('cpform'), value);
|
||||
var trs = $('cpform').getElementsByTagName('TR');
|
||||
for(var i in trs) {
|
||||
if(trs[i].id && trs[i].id.substr(0, 4) == 'mod_') {
|
||||
trs[i].className = 'mod_' + value;
|
||||
showreason(trs[i].getAttribute('verifyid'), value == 'refusal' ? 1 : 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function mod_cancel_all() {
|
||||
var inputs = $('cpform').getElementsByTagName('input');
|
||||
for(var i in inputs) {
|
||||
if(inputs[i].type == 'radio') {
|
||||
inputs[i].checked = '';
|
||||
}
|
||||
}
|
||||
var trs = $('cpform').getElementsByTagName('TR');
|
||||
for(var i in trs) {
|
||||
if(trs[i].id && trs[i].id.match(/^mod_(\d+)_row$/)) {
|
||||
trs[i].className = "mod_cancel";
|
||||
showreason(trs[i].getAttribute('verifyid'), 0)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function singleverify(vid) {
|
||||
var formobj = $('cpform');
|
||||
var oldaction = formobj.action;
|
||||
formobj.action = oldaction + '&singleverify=' + vid;
|
||||
formobj.target = "frame_profile";
|
||||
formobj.submit();
|
||||
formobj.action = oldaction;
|
||||
formobj.target = "";
|
||||
}
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var url = '{BASESCRIPT}?mod=member';
|
||||
|
||||
jQuery(document).ready(function(e) {
|
||||
/*jQuery('input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
jQuery('input').on('ifChecked',function(e){
|
||||
jQuery(this).trigger('click');
|
||||
});*/
|
||||
|
||||
});
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/icheck/icheck.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
117
admin/member/template/verifyset.htm
Normal file
117
admin/member/template/verifyset.htm
Normal file
@ -0,0 +1,117 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/icheck/skins/minimal/blue.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 150px;
|
||||
top: 0
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 150px;
|
||||
overflow: auto;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.form-horizontal .form-control {
|
||||
min-width: 90px;
|
||||
max-width: 250px;
|
||||
}
|
||||
textarea.form-control,select.form-control{
|
||||
border-width:1px 1px 1px 1px;
|
||||
}
|
||||
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix" style="padding-top:0px;">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li class="active">
|
||||
<a href="{MOD_URL}&op=verifyset">{lang members_verify}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class=" alert alert-warning " style="margin:10px;padding-left:0;font-size:85%;line-height:2">
|
||||
<ul>
|
||||
{lang verifyset_members_verify_text}
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content" style="border-top:1px solid #DDD">
|
||||
<form id="cpform" action="{MOD_URL}&op=verifyset" class="form-horizontal" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="verifysubmit">
|
||||
<table class="table table-hover" style="font-size:12px;">
|
||||
<thead>
|
||||
<th width="60">{lang enable}</th>
|
||||
<th width="120">{lang authentication_code}</th>
|
||||
<th>{lang members_verify_title}</th>
|
||||
<th width="120">{lang edit}</th>
|
||||
</thead>
|
||||
<!--{eval for($i=1;$i<8;$i++){}-->
|
||||
{eval $value=$_G['setting']['verify'][$i]}
|
||||
<tr>
|
||||
<td width="60"><input type="checkbox" name="settingnew[verify][$i][available]" <!--{if $value[available]}-->checked="checked"<!--{/if}-->value="1" /></td>
|
||||
<td width="120">verify{$i}</td>
|
||||
<td>
|
||||
<!--{if $value[readonly]}-->
|
||||
$value[title]<input type="hidden" name="settingnew[verify][$i][title]" value="$value[title]" />
|
||||
<!--{else}-->
|
||||
<input type="text" class="form-control input-sm" name="settingnew[verify][$i][title]" value="$value[title]">
|
||||
<!--{/if}-->
|
||||
<!--{if $value['icon']}-->
|
||||
<img src="$value[icon]" />
|
||||
<!--{/if}-->
|
||||
</td>
|
||||
<td width="120">
|
||||
<a href="{MOD_URL}&op=verifyset&do=edit&vid=$i" class="ibtn glyphicon glyphicon-edit " title="{lang edit}"></a>
|
||||
</td>
|
||||
</tr>
|
||||
<!--{eval }}-->
|
||||
|
||||
<tr>
|
||||
<td colspan="20">
|
||||
<input class="btn btn-primary btn-width" type="submit" value="{lang save_set}" />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var url = '{MOD_URL}';
|
||||
|
||||
jQuery(document).ready(function(e) {
|
||||
jQuery('input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
jQuery('input').on('ifChecked', function(e) {
|
||||
jQuery(this).trigger('click');
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/icheck/icheck.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
187
admin/member/template/verifyset_edit.htm
Normal file
187
admin/member/template/verifyset_edit.htm
Normal file
@ -0,0 +1,187 @@
|
||||
<!--{template common/header_simple_start}-->
|
||||
<link href="static/css/common.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<link href="static/icheck/skins/minimal/blue.css?{VERHASH}" rel="stylesheet" media="all">
|
||||
<script type="text/javascript" src="static/js/jquery.leftDrager.js?{VERHASH}"></script>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
overflow: hidden;
|
||||
background: #FBFBFB;
|
||||
}
|
||||
|
||||
.bs-left-container {
|
||||
width: 120px;
|
||||
top: 0
|
||||
}
|
||||
|
||||
.bs-main-container {
|
||||
margin-left: 120px;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
|
||||
.form-horizontal-left .checkbox-inline {
|
||||
margin: 0;
|
||||
min-width: 130px;
|
||||
}
|
||||
textarea.form-control,select.form-control{
|
||||
border-width:1px 1px 1px 1px;
|
||||
}
|
||||
</style>
|
||||
<!--{template common/header_simple_end}-->
|
||||
<!--{template common/commer_header}-->
|
||||
<div class="bs-container clearfix" style="padding-top:0">
|
||||
<div class="bs-left-container clearfix">
|
||||
<!--{template left}-->
|
||||
</div>
|
||||
<div class="left-drager">
|
||||
<div class="left-drager-op">
|
||||
<div class="left-drager-sub"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bs-main-container clearfix">
|
||||
<div class="main-header">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li>
|
||||
<a href="{MOD_URL}&op=verifyset">{lang members_verify}</a>
|
||||
</li>
|
||||
<li class="active">
|
||||
<a href="{MOD_URL}&op=verifyset&do=edit&vid=$vid">{lang edit}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="main-content" style="padding:20px;">
|
||||
<form id="cpform" action="{MOD_URL}&op=verifyset&do=edit" class="form-horizontal form-horizontal-left" method="post" name="cpform" enctype="multipart/form-data">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="verifysubmit">
|
||||
<input type="hidden" value="$vid" name="vid">
|
||||
<dl>
|
||||
<dt>{lang members_verify_title}:</dt>
|
||||
<dd class="clearfix">
|
||||
<input name="verify[title]" value="$verifyarr[title]" type="text" class="form-control" <!--{if $verifyarr[readonly]}-->disabled="disabled"<!--{/if}-->>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang members_verify_synopsis}:</dt>
|
||||
<dd class="clearfix">
|
||||
<textarea name="verify[desc]" type="textarea" class="form-control" rows="3">$verifyarr[desc]</textarea>
|
||||
<span class="help-inline">{lang verifyset_verify_synopsis_text}</span>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang members_verify_enable}:</dt>
|
||||
<dd class="clearfix">
|
||||
<label class="radio-inline"><input type="radio" name="verify[available]" value="1" <!--{if $verifyarr[available]}-->checked="checked"<!--{/if}--> />{lang enable}</label>
|
||||
<label class="radio-inline"><input type="radio" name="verify[available]" value="0" <!--{if !$verifyarr[available]}-->checked="checked"<!--{/if}--> />{lang no_enable}</label>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang members_verify_icon}:</dt>
|
||||
<dd class="clearfix">
|
||||
<label class="radio-inline"><input type="radio" name="verify[showicon]" value="1" <!--{if $verifyarr[showicon]}-->checked="checked"<!--{/if}--> onclick="document.('hidden_verify_showicon').style.display = '';" />{lang show}</label>
|
||||
<label class="radio-inline"><input type="radio" name="verify[showicon]" value="0" <!--{if !$verifyarr[showicon]}-->checked="checked"<!--{/if}--> onclick="document.getElementById('hidden_verify_showicon').style.display = 'none';" />{lang no_show}</label>
|
||||
</dd>
|
||||
<dd id="hidden_verify_showicon" class="clearfix mt10" <!--{if !$verifyarr[showicon]}-->style="display:none"<!--{/if}-->>
|
||||
<dl>
|
||||
<dt>{lang members_unverify_icon}:</dt>
|
||||
<dd class="clearfix">
|
||||
<table>
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<div>
|
||||
<input id="fileQ3_0" style="display:" name="unverifyiconnew" value="" type="file" class="form-control uploadbtn marginbot" accept="image/jpeg,image/gif,image/png,image/jpg">
|
||||
<input id="fileQ3_1" style="display:none" name="TMPunverifyiconnew" value="$verifyarr[unverifyicon]" type="text" class="form-control marginbot" accept="image/jpeg,image/gif,image/png,image/jpg">
|
||||
</div>
|
||||
<div>
|
||||
<a id="fileQ3_0a" class="btn btn-link" style="font-weight:bold;" href="javascript:;" onclick="document.getElementById('fileQ3_1a').style.fontWeight = '';this.style.fontWeight = 'bold';document.getElementById('fileQ3_1').name = 'TMPunverifyiconnew';document.getElementById('fileQ3_0').name = 'unverifyiconnew';document.getElementById('fileQ3_0').style.display = '';document.getElementById('fileQ3_1').style.display = 'none'">{lang web_upload}</a>
|
||||
<a id="fileQ3_1a" class="btn btn-link" style="" href="javascript:;" onclick="document.getElementById('fileQ3_0a').style.fontWeight = '';this.style.fontWeight = 'bold';document.getElementById('fileQ3_0').name = 'TMPunverifyiconnew';document.getElementById('fileQ3_1').name = 'unverifyiconnew';document.getElementById('fileQ3_1').style.display = '';document.getElementById('fileQ3_0').style.display = 'none'">{lang input}URL</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="ml20">$unverifyiconhtml</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang members_verify_icon}:</dt>
|
||||
<dd class="clearfix">
|
||||
<table>
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<div>
|
||||
<input id="fileO4_0" style="display:" name="iconnew" value="" type="file" class="form-control uploadbtn marginbot" accept="image/jpeg,image/gif,image/png,image/jpg">
|
||||
<input id="fileO4_1" style="display:none" name="TMPiconnew" value="$verifyarr[icon]" type="text" class="form-control marginbot" accept="image/jpeg,image/gif,image/png,image/jpg">
|
||||
</div>
|
||||
<div>
|
||||
<a id="fileO4_0a" class="btn btn-link" style="font-weight:bold" href="javascript:;" onclick="document.getElementById('fileO4_1a').style.fontWeight = '';this.style.fontWeight = 'bold';document.getElementById('fileO4_1').name = 'TMPiconnew';document.getElementById('fileO4_0').name = 'iconnew';document.getElementById('fileO4_0').style.display = '';document.getElementById('fileO4_1').style.display = 'none'">{lang web_upload}</a>
|
||||
<a class="btn btn-link" id="fileO4_1a" style="" href="javascript:;" onclick="document.getElementById('fileO4_0a').style.fontWeight = '';this.style.fontWeight = 'bold';document.getElementById('fileO4_0').name = 'TMPiconnew';document.getElementById('fileO4_1').name = 'iconnew';document.getElementById('fileO4_1').style.display = '';document.getElementById('fileO4_0').style.display = 'none'">{lang input}URL</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="ml20">$verificonhtml</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang choosable_data}:</dt>
|
||||
<dd class="clearfix">
|
||||
<!--{loop $fieldarr $value}-->
|
||||
<label class="checkbox-inline"> <input type="checkbox" name="verify[field][{$value[fieldid]}]" value="$value[fieldid]" <!--{if $verifyarr[field][$value[fieldid]]}-->checked="checked"<!--{/if}-->>$value[title]</label>
|
||||
<!--{/loop}-->
|
||||
</dd>
|
||||
<dd class="clearfix">
|
||||
<span class="help-block danger">{lang verifyset_choosable_data_text}</span>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>{lang members_verify_group}:</dt>
|
||||
<dd class="clearfix">
|
||||
<select name="verify[groupid][]" multiple="multiple" class="form-control" size="7">
|
||||
<!--{loop $usergroups $value}-->
|
||||
<option value="$value[groupid]" <!--{if in_array($value[groupid],$verifyarr[groupid])}-->selected="selected"<!--{/if}-->>$value[grouptitle]</option>
|
||||
<!--{/loop}-->
|
||||
</select>
|
||||
<span class="help-inline">{lang verifyset_verify_group_text}</span>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dd class="clearfix">
|
||||
<input type="submit" class="btn btn-primary btn-width" name="verifysubmit" value="{lang save_set}">
|
||||
</dd>
|
||||
</dl>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.left-drager').leftDrager_layout();
|
||||
var url = '{MOD_URL}';
|
||||
|
||||
jQuery(document).ready(function(e) {
|
||||
<!--{if $verifyarr['icon']}-->
|
||||
jQuery('#fileO4_1a').trigger('click');
|
||||
<!--{/if}-->
|
||||
<!--{if $verifyarr['unverifyicon']}-->
|
||||
jQuery('#fileQ3_1a').trigger('click');
|
||||
<!--{/if}-->
|
||||
jQuery('input').iCheck({
|
||||
checkboxClass: 'icheckbox_minimal-blue',
|
||||
radioClass: 'iradio_minimal-blue',
|
||||
});
|
||||
jQuery('input').on('ifChecked', function(e) {
|
||||
jQuery(this).trigger('click');
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<script src="static/bootstrap/js/bootstrap.min.js?{VERHASH}"></script>
|
||||
<script type="text/javascript" src="static/icheck/icheck.min.js?{VERHASH}"></script>
|
||||
<!--{template common/footer_simple}-->
|
350
admin/member/verify.php
Normal file
350
admin/member/verify.php
Normal file
@ -0,0 +1,350 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
//error_reporting(E_ALL);
|
||||
include_once libfile('function/profile', '', 'user');
|
||||
include_once libfile('function/admin');
|
||||
loadcache('profilesetting');
|
||||
$vid = intval($_GET['vid']);
|
||||
$anchor = in_array($_GET['anchor'], array('authstr', 'refusal', 'pass', 'add')) ? $_GET['anchor'] : 'authstr';
|
||||
$current = array($anchor => 1);
|
||||
$op=$_GET['op'];
|
||||
//判断管理权限
|
||||
if ($vid) {
|
||||
if ($vid == 1) {
|
||||
if ($_G['member']['grid'] != 4 && $_G['adminid'] != 1)
|
||||
showmessage('contact_administrator1');
|
||||
} else {
|
||||
if ($_G['adminid'] != 1)
|
||||
showmessage('contact_administrator2');
|
||||
}
|
||||
} else {
|
||||
if ($_G['member']['grid'] != 5 && $_G['adminid'] != 1)
|
||||
showmessage('contact_administrator3');
|
||||
}
|
||||
if ($anchor != 'pass') {
|
||||
$_GET['verifytype'] = $vid;
|
||||
} else {
|
||||
$_GET['verify' . $vid] = 1;
|
||||
$_GET['orderby'] = 'uid';
|
||||
}
|
||||
if (!submitcheck('verifysubmit', true)) {
|
||||
$navtitle = $vid ? $_G['setting']['verify'][$vid]['title'] : lang('members_verify_profile');
|
||||
|
||||
$thurl = ADMINSCRIPT . '?mod=member&op=verify&anchor=' . $anchor . '&vid=' . $vid;
|
||||
if ($anchor == 'refusal') {
|
||||
$_GET['flag'] = -1;
|
||||
} elseif ($anchor == 'authstr') {
|
||||
$_GET['flag'] = 0;
|
||||
}
|
||||
$intkeys = array('uid', 'verifytype', 'flag', 'verify1', 'verify2', 'verify3', 'verify4', 'verify5', 'verify6', 'verify7');
|
||||
$strkeys = array();
|
||||
$randkeys = array();
|
||||
$likekeys = array('username');
|
||||
$results = getwheres($intkeys, $strkeys, $randkeys, $likekeys, 'v.');
|
||||
foreach ($likekeys as $k) {
|
||||
$_GET[$k] = dhtmlspecialchars($_GET[$k]);
|
||||
}
|
||||
$thurl .= '&' . implode('&', $results['urls']);
|
||||
$wherearr = $results['wherearr'];
|
||||
if ($_GET['dateline1']) {
|
||||
$wherearr[] = "v.dateline >= '" . strtotime($_GET['dateline1']) . "'";
|
||||
$thurl .= '&dateline1=' . $_GET['dateline1'];
|
||||
}
|
||||
if ($_GET['dateline2']) {
|
||||
$wherearr[] = "v.dateline <= '" . strtotime($_GET['dateline2']) . "'";
|
||||
$thurl .= '&dateline2=' . $_GET['dateline2'];
|
||||
}
|
||||
|
||||
$wheresql = empty($wherearr) ? '1' : implode(' AND ', $wherearr);
|
||||
|
||||
$orders = getorders(array('dateline', 'uid'), 'dateline', 'v.');
|
||||
$ordersql = $orders['sql'];
|
||||
if ($orders['urls'])
|
||||
$thurl .= '&' . implode('&', $orders['urls']);
|
||||
$orderby = array($_GET['orderby'] => ' selected');
|
||||
$ordersc = array($_GET['ordersc'] => ' selected');
|
||||
|
||||
$orders = in_array($_G['orderby'], array('dateline', 'uid')) ? $_G['orderby'] : 'dateline';
|
||||
$ordersc = in_array(strtolower($_GET['ordersc']), array('asc', 'desc')) ? $_GET['ordersc'] : 'desc';
|
||||
|
||||
$perpage = empty($_GET['perpage']) ? 0 : intval($_GET['perpage']);
|
||||
if (!in_array($perpage, array(10, 20, 50, 100)))
|
||||
$perpage = 10;
|
||||
$perpages = array($perpage => ' selected');
|
||||
$thurl .= '&perpage=' . $perpage;
|
||||
|
||||
$page = empty($_GET['page']) ? 1 : intval($_GET['page']);
|
||||
if ($page < 1)
|
||||
$page = 1;
|
||||
$start = ($page - 1) * $perpage;
|
||||
|
||||
$multi = '';
|
||||
if ($anchor != 'pass') {
|
||||
$count = C::t('user_verify_info') -> count_by_search($_GET['uid'], $vid, $_GET['flag'], $_GET['username'], strtotime($_GET['dateline1']), strtotime($_GET['dateline2']));
|
||||
} else {
|
||||
$wheresql = (!empty($_GET['username']) ? str_replace('v.username', 'm.username', $wheresql) : $wheresql) . ' AND v.uid=m.uid ';
|
||||
$count = C::t('user_verify') -> count_by_search($_GET['uid'], $vid, $_GET['username']);
|
||||
}
|
||||
if ($count) {
|
||||
|
||||
if ($anchor != 'pass') {
|
||||
$verifyusers = C::t('user_verify_info') -> fetch_all_search($_GET['uid'], $vid, $_GET['flag'], $_GET['username'], strtotime($_GET['dateline1']), strtotime($_GET['dateline2']), $orders, $start, $perpage, $ordersc);
|
||||
} else {
|
||||
$verifyusers = C::t('user_verify') -> fetch_all_search($_GET['uid'], $vid, $_GET['username'], 'v.uid', $start, $perpage, $ordersc);
|
||||
$verifyuids = array_keys($verifyusers);
|
||||
$profiles = C::t('user_profile1') -> fetch_all($verifyuids, false, 0);
|
||||
}
|
||||
$list = array();
|
||||
foreach ($verifyusers as $uid => $value) {
|
||||
if ($anchor == 'pass') {
|
||||
$value = array_merge($value, $profiles[$uid]);
|
||||
}
|
||||
$value['username'] = '<a href="user.php?&uid=' . $value['uid'] . '" target="_blank"><img src="avatar.php?uid=' . $value['uid'] . '&size=small"><br/><br/>' . $value['username'] . '</a>';
|
||||
if ($anchor != 'pass') {
|
||||
$fields = $anchor != 'pass' ? dunserialize($value['field']) : $_G['setting']['verify'][$vid]['field'];
|
||||
$value['verifytype'] = $value['verifytype'] ? $_G['setting']['verify'][$value['verifytype']]['title'] : lang('members_verify_profile');
|
||||
$fieldstr = '<table class="table-sub" width="96%">';
|
||||
$i = 0;
|
||||
$fieldstr .= '<tr>' . ($anchor == 'authstr' ? '<td width="35">' . lang('refuse') . '</td>' : '') . '<td width="100">' . lang('members_verify_fieldid') . '</td><td>' . lang('members_verify_newvalue') . '</td></tr><tbody id="verifyitem_' . $value['vid'] . '">';
|
||||
$i++;
|
||||
|
||||
foreach ($fields as $key => $field) {
|
||||
if (in_array($key, array('constellation', 'zodiac', 'birthyear', 'birthmonth'))) {
|
||||
continue;
|
||||
}
|
||||
if ($_G['cache']['profilesetting'][$key]['formtype'] == 'file') {
|
||||
if ($field) {
|
||||
$field = '<a href="' . (getglobal('setting/attachurl') . $field) . '" target="_blank"><img src="' . (getglobal('setting/attachurl') . $field) . '" class="verifyimg" /></a>';
|
||||
} else {
|
||||
$field = lang('members_verify_pic_removed');
|
||||
}
|
||||
} elseif (in_array($key, array('gender', 'birthday', 'department'))) {
|
||||
|
||||
$field = profile_show($key, $fields);
|
||||
}
|
||||
$fieldstr .= '<tr>' . ($anchor == 'authstr' ? '<td><input type="checkbox" name="refusal[' . $value['vid'] . '][' . $key . ']" value="' . $key . '" onclick="$(\'refusal' . $value['vid'] . '\').click();" /></td>' : '') . '<td>' . $_G['cache']['profilesetting'][$key]['title'] . ':</td><td>' . $field . '</td></tr>';
|
||||
$i++;
|
||||
}
|
||||
$opstr = "";
|
||||
|
||||
if ($anchor == 'authstr') {
|
||||
$opstr .= "<label class=\"radio-inline\"><input type=\"radio\" name=\"verify[$value[vid]]\" value=\"validate\" onclick=\"mod_setbg($value[vid], 'validate');showreason($value[vid], 0);\">" . lang('validate') . "</label><label class=\"radio-inline\"><input type=\"radio\" name=\"verify[$value[vid]]\" value=\"refusal\" id=\"refusal$value[vid]\" onclick=\"mod_setbg($value[vid], 'refusal');showreason($value[vid], 1);\">" . lang('refuse') . "</label>";
|
||||
} elseif ($anchor == 'refusal') {
|
||||
$opstr .= "<label class=\"radio-inline\"><input type=\"radio\" name=\"verify[$value[vid]]\" value=\"validate\" onclick=\"mod_setbg($value[vid], 'validate');\">" . lang('validate') . "</label>";
|
||||
}
|
||||
|
||||
$fieldstr .= "</tbody><tr><td colspan=\"5\">$opstr <span id=\"reason_$value[vid]\" style=\"display: none;\" title=\"" . lang('moderate_reasonpm') . "\" ><input type=\"text\" class=\"form-control input-sm\" placeholder=\"" . lang('moderate_reasonpm') . "\" name=\"reason[$value[vid]]\" style=\"margin: 0px;\"></span><input type=\"button\" value=\"" . lang('moderate') . "\" name=\"singleverifysubmit\" class=\"btn btn-default btn-sm ml10\" onclick=\"singleverify($value[vid]);\"></td></tr></table>";
|
||||
$value['fieldstr'] = $fieldstr;
|
||||
$value['dateline'] = dgmdate($value['dateline'], 'u');
|
||||
$list[$uid] = $value;
|
||||
// = array($value['username'], $verifytype, dgmdate($value['dateline'], 'dt'), $fieldstr);
|
||||
//showtablerow("id=\"mod_$value[vid]_row\" verifyid=\"$value[vid]\"", $cssarr, $valuearr);
|
||||
} else {
|
||||
$fields = $_G['setting']['verify'][$vid]['field'];
|
||||
$value['verifytype'] = $vid ? $_G['setting']['verify'][$vid]['title'] : lang('members_verify_profile');
|
||||
|
||||
$fieldstr = '<table class="table-sub" width="96%">';
|
||||
$fieldstr .= '<tr><td width="100">' . lang('members_verify_fieldid') . '</td><td>' . lang('members_verify_newvalue') . '</td></tr>';
|
||||
|
||||
foreach ($fields as $key => $field) {
|
||||
if (!in_array($key, array('constellation', 'zodiac', 'birthyear', 'birthmonth'))) {
|
||||
if (in_array($key, array('gender', 'birthday', 'department'))) {
|
||||
$value[$field] = profile_show($key, $value);
|
||||
}
|
||||
if ($_G['cache']['profilesetting'][$key]['formtype'] == 'file') {
|
||||
if ($value[$field]) {
|
||||
$value[$field] = '<a href="' . (getglobal('setting/attachurl') . $value[$field]) . '" target="_blank"><img src="' . (getglobal('setting/attachurl') . $value[$field]) . '" class="verifyimg" /></a>';
|
||||
} else {
|
||||
$value[$field] = lang('members_verify_pic_removed');
|
||||
}
|
||||
}
|
||||
$fieldstr .= '<tr><td width="100">' . $_G['cache']['profilesetting'][$key]['title'] . ':</td><td>' . $value[$field] . '</td></tr>';
|
||||
}
|
||||
}
|
||||
$fieldstr .= "</table>";
|
||||
$value['fieldstr'] = $fieldstr;
|
||||
$opstr = "<ul class=\"list-unstyled\"><li><label class=\"radio-inline\"><input type=\"radio\" name=\"verify[$value[uid]]\" value=\"export\" onclick=\"mod_setbg($value[uid], 'export');\">".lang('export')."</label></li><li><label class=\"radio-inline\"><input type=\"radio\" name=\"verify[$value[uid]]\" value=\"refusal\" onclick=\"mod_setbg($value[uid], 'refusal');\">" . lang('refuse') . "</label></li></ul>";
|
||||
$value['opstr'] = $opstr;
|
||||
$value['dateline'] = dgmdate($value['dateline'], 'u');
|
||||
$list[$uid] = $value;
|
||||
//showtablerow("id=\"mod_$value[uid]_row\"", $cssarr, $valuearr);
|
||||
}
|
||||
}
|
||||
$multi = multi($count, $perpage, $page, $thurl, 'pull-right');
|
||||
}
|
||||
|
||||
} else {
|
||||
if ($anchor == 'pass') {
|
||||
$verifyuids = array();
|
||||
|
||||
foreach ($_GET['verify'] as $uid => $type) {
|
||||
if ($type == 'export') {
|
||||
$verifyuids['export'][] = $uid;
|
||||
} elseif ($type == 'refusal') {
|
||||
$verifyuids['refusal'][] = $uid;
|
||||
//发送通知
|
||||
$notevars = array('from_id' => 0, 'from_idtype' => '', 'author' => $_G['username'], 'authorid' => $_G['uid'], 'url' => 'user.php?mod=profile&vid=' . $vid, 'profile' => $fieldtitle, 'dataline' => dgmdate(TIMESTAMP), 'title' => $vid ? $_G['setting']['verify'][$vid]['title'] : lang('members_verify_profile'), 'reason' => $_GET['reason'][$value['vid']], );
|
||||
|
||||
$action = 'user_profile_pass_refusal';
|
||||
$type = 'user_profile_pass_refusal_' . $vid;
|
||||
|
||||
dzz_notification::notification_add($uid, $type, $action, $notevars, 1);
|
||||
}
|
||||
}
|
||||
if (is_array($verifyuids['refusal']) && !empty($verifyuids['refusal'])) {
|
||||
C::t('user_verify') -> update($verifyuids['refusal'], array("verify$vid" => '0'));
|
||||
if ($vid == 1)
|
||||
C::t('user') -> update($uid, array('grid' => '0'));
|
||||
}
|
||||
if (is_array($verifyuids['export']) && !empty($verifyuids['export']) || empty($verifyuids['refusal'])) {
|
||||
$uids = array();
|
||||
if (is_array($verifyuids['export']) && !empty($verifyuids['export'])) {
|
||||
$uids = $verifyuids['export'];
|
||||
}
|
||||
$fields = $_G['setting']['verify'][$vid]['field'];
|
||||
$fields = array_reverse($fields);
|
||||
$fields['username'] = 'username';
|
||||
$fields = array_reverse($fields);
|
||||
$title = $verifylist = '';
|
||||
$showtitle = true;
|
||||
$verifyusers = C::t('user_verify') -> fetch_all_by_vid($vid, 1, $uids);
|
||||
$verifyuids = array_keys($verifyusers);
|
||||
$members = C::t('user') -> fetch_all($verifyuids, false, 0);
|
||||
$profiles = C::t('user_profile1') -> fetch_all($verifyuids, false, 0);
|
||||
foreach ($verifyusers as $uid => $value) {
|
||||
$value = array_merge($value, $members[$uid], $profiles[$uid]);
|
||||
$str = $common = '';
|
||||
foreach ($fields as $key => $field) {
|
||||
if (in_array($key, array('constellation', 'zodiac', 'birthyear', 'birthmonth', 'birthprovince', 'birthdist', 'birthcommunity', 'resideprovince', 'residedist', 'residecommunity'))) {
|
||||
continue;
|
||||
}
|
||||
if ($showtitle) {
|
||||
$title .= $common . ($key == 'username' ? lang('username') : $_G['cache']['profilesetting'][$key]['title']);
|
||||
}
|
||||
if (in_array($key, array('gender', 'birthday', 'department'))) {
|
||||
$value[$field] = profile_show($key, $value);
|
||||
}
|
||||
$str .= $common . $value[$field];
|
||||
$common = "\t";
|
||||
}
|
||||
$verifylist .= $str . "\n";
|
||||
$showtitle = false;
|
||||
}
|
||||
$verifylist = $title . "\n" . $verifylist;
|
||||
$filename = date('Ymd', TIMESTAMP) . '.xls';
|
||||
|
||||
define('FOOTERDISABLED', true);
|
||||
ob_end_clean();
|
||||
header("Content-type:application/vnd.ms-excel");
|
||||
header('Content-Encoding: none');
|
||||
header('Content-Disposition: attachment; filename=' . $filename);
|
||||
header('Pragma: no-cache');
|
||||
header('Expires: 0');
|
||||
if ($_G['charset'] != 'gbk') {
|
||||
$verifylist = diconv($verifylist, $_G['charset'], 'GBK');
|
||||
}
|
||||
echo $verifylist;
|
||||
exit();
|
||||
} else {
|
||||
showmessage('members_verify_succeed', ADMINSCRIPT . '?mod=member&op=verify&vid=' . $vid . '&anchor=pass', array(), array('alert' => 'right'));
|
||||
}
|
||||
} else {
|
||||
$vids = array();
|
||||
$single = intval($_GET['singleverify']);
|
||||
$verifyflag = empty($_GET['verify']) ? false : true;
|
||||
if ($verifyflag) {
|
||||
if ($single) {
|
||||
$_GET['verify'] = array($single => $_GET['verify'][$single]);
|
||||
}
|
||||
foreach ($_GET['verify'] as $id => $type) {
|
||||
$vids[] = $id;
|
||||
}
|
||||
|
||||
$verifysetting = $_G['setting']['verify'];
|
||||
$verify = $refusal = array();
|
||||
foreach (C::t('user_verify_info')->fetch_all($vids) as $value) {
|
||||
if (in_array($_GET['verify'][$value['vid']], array('refusal', 'validate'))) {
|
||||
$fields = dunserialize($value['field']);
|
||||
$verifysetting = $_G['setting']['verify'][$value['verifytype']];
|
||||
|
||||
if ($_GET['verify'][$value['vid']] == 'refusal') {
|
||||
$refusalfields = !empty($_GET['refusal'][$value['vid']]) ? $_GET['refusal'][$value['vid']] : $verifysetting['field'];
|
||||
$fieldtitle = $common = '';
|
||||
$deleteverifyimg = false;
|
||||
foreach ($refusalfields as $key => $field) {
|
||||
$fieldtitle .= $common . $_G['cache']['profilesetting'][$field]['title'];
|
||||
$common = ',';
|
||||
if ($_G['cache']['profilesetting'][$field]['formtype'] == 'file') {
|
||||
$deleteverifyimg = true;
|
||||
@unlink(getglobal('setting/attachdir') . $fields[$key]);
|
||||
$fields[$field] = '';
|
||||
}
|
||||
}
|
||||
if ($deleteverifyimg) {
|
||||
C::t('user_verify_info') -> update($value['vid'], array('field' => serialize($fields)));
|
||||
}
|
||||
if ($value['verifytype']) {
|
||||
$verify["verify"]['-1'][] = $value['uid'];
|
||||
}
|
||||
$verify['flag'][] = $value['vid'];
|
||||
//发送通知
|
||||
$notevars = array('from_id' => 0, 'from_idtype' => '', 'author' => $_G['username'], 'authorid' => $_G['uid'], 'url' => 'user.php?mod=profile&vid=' . $vid, 'profile' => $fieldtitle, 'dataline' => dgmdate(TIMESTAMP), 'title' => $vid ? $_G['setting']['verify'][$vid]['title'] : lang('members_verify_profile'), 'reason' => $_GET['reason'][$value['vid']], );
|
||||
|
||||
$action = 'user_profile_moderate_refusal';
|
||||
$type = 'user_profile_moderate_refusal_' . $vid;
|
||||
|
||||
} else {
|
||||
C::t('user_profile1') -> update(intval($value['uid']), $fields);
|
||||
if ($fields['department']) {//含有department时审核通过后,把此用户加入相应的部门
|
||||
C::t('organization_user') -> insert($value['uid'], $fields['department']);
|
||||
}
|
||||
$verify['delete'][] = $value['vid'];
|
||||
if ($value['verifytype']) {
|
||||
$verify["verify"]['1'][] = $value['uid'];
|
||||
}
|
||||
//发送通知
|
||||
$notevars = array('from_id' => 0, 'from_idtype' => '', 'author' => $_G['username'], 'authorid' => $_G['uid'], 'url' => 'user.php?mod=profile&vid=' . $vid, 'dataline' => dgmdate(TIMESTAMP), 'title' => $vid ? $_G['setting']['verify'][$vid]['title'] : lang('members_verify_profile'), );
|
||||
|
||||
$action = 'user_profile_moderate_pass';
|
||||
$type = 'user_profile_moderate_pass_' . $vid;
|
||||
|
||||
}
|
||||
dzz_notification::notification_add($value['uid'], $type, $action, $notevars, 1);
|
||||
}
|
||||
}
|
||||
if ($vid && !empty($verify["verify"])) {
|
||||
foreach ($verify["verify"] as $flag => $uids) {
|
||||
$flag = intval($flag);
|
||||
C::t('user_verify') -> update($uids, array("verify$vid" => $flag));
|
||||
if ($vid == 1)
|
||||
C::t('user') -> update($uids, array('grid' => 6));
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($verify['delete'])) {
|
||||
C::t('user_verify_info') -> delete($verify['delete']);
|
||||
}
|
||||
|
||||
if (!empty($verify['flag'])) {
|
||||
C::t('user_verify_info') -> update($verify['flag'], array('flag' => '-1'));
|
||||
}
|
||||
}
|
||||
if ($single) {
|
||||
echo "<script type=\"text/javascript\">var trObj = parent.$('mod_{$single}_row');trObj.parentNode.removeChild(trObj);</script>";
|
||||
} else {
|
||||
showmessage('members_verify_succeed', ADMINSCRIPT . '?mod=member&op=verify&vid=' . $vid . '&anchor=' . $_GET['anchor'], array(), array('alert' => 'right'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
include template('verify');
|
||||
?>
|
154
admin/member/verifyset.php
Normal file
154
admin/member/verifyset.php
Normal file
@ -0,0 +1,154 @@
|
||||
<?php
|
||||
/*
|
||||
* @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)
|
||||
*/
|
||||
//error_reporting(E_ALL);
|
||||
if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$op=$_GET['op'];
|
||||
if ($_G['adminid'] != 1)
|
||||
showmessage('no_privilege');
|
||||
include_once libfile('function/cache');
|
||||
$do = $_GET['do'] ? $_GET['do'] : '';
|
||||
|
||||
if ($do == 'edit') {
|
||||
$vid = $_GET['vid'] < 8 ? intval($_GET['vid']) : 0;
|
||||
$verifyarr = $_G['setting']['verify'][$vid];
|
||||
if (!submitcheck('verifysubmit')) {
|
||||
|
||||
$verificonhtml = '';
|
||||
if ($verifyarr['icon']) {
|
||||
$icon_url = parse_url($verifyarr['icon']);
|
||||
$prefix = !$icon_url['host'] && strpos($verifyarr['icon'], $_G['setting']['attachurl']) === false ? $_G['setting']['attachurl'] : '';
|
||||
|
||||
$verificonhtml = '<label class="radio-inline"><input type="checkbox" class="checkbox" name="deleteicon[' . $vid . ']" value="yes" />'.lang('del1').'</label> <img src="' . $prefix . $verifyarr['icon'] . '?t=' . TIMESTAMP . '" />';
|
||||
}
|
||||
$unverifyiconhtml = '';
|
||||
if ($verifyarr['unverifyicon']) {
|
||||
$unverifyiconurl = parse_url($verifyarr['unverifyicon']);
|
||||
|
||||
$prefix = !$unverifyiconurl['host'] && strpos($verifyarr['unverifyicon'], $_G['setting']['attachurl']) === false ? $_G['setting']['attachurl'] : '';
|
||||
$unverifyiconhtml = '<label class="radio-inline"><input type="checkbox" class="checkbox" name="delunverifyicon[' . $vid . ']" value="yes" />'.lang('del1').'</label> <img src="' . $prefix . $verifyarr['unverifyicon'] . '?t=' . TIMESTAMP . '" />';
|
||||
}
|
||||
|
||||
$fieldarr = C::t('user_profile_setting') -> fetch_all_by_available(1);
|
||||
unset($fieldarr['birthyear']);
|
||||
unset($fieldarr['birthmonth']);
|
||||
unset($fieldarr['zodiac']);
|
||||
unset($fieldarr['constellation']);
|
||||
$groupselect = array();
|
||||
$usergroups = C::t('usergroup') -> fetch_all_not(array(6, 7));
|
||||
} else {
|
||||
foreach ($_G['setting']['verify'] as $key => $value) {
|
||||
$_G['setting']['verify'][$key]['icon'] = str_replace($_G['setting']['attachurl'], '', $value['icon']);
|
||||
$_G['setting']['verify'][$key]['unverifyicon'] = str_replace($_G['setting']['attachurl'], '', $value['unverifyicon']);
|
||||
}
|
||||
$verifynew = getgpc('verify');
|
||||
$verifynew['readonly'] = $_G['setting']['verify'][$vid]['readonly'];
|
||||
if ($vid == 1) {
|
||||
$verifynew['title'] = $_G['setting']['verify'][$vid]['title'];
|
||||
}
|
||||
if ($verifynew['available'] == 1 && !trim($verifynew['title'])) {
|
||||
showmessage('members_verify_title_empty', dreferer());
|
||||
}
|
||||
if ($icon = getverifyicon('iconnew', 'common/verify/' . $vid . '/verify_icon.jpg'))
|
||||
$verifynew['icon'] = $icon;
|
||||
else
|
||||
$verifynew['icon'] = $_G['setting']['verify'][$vid]['icon'];
|
||||
if ($uicon = getverifyicon('unverifyiconnew', 'common/verify/' . $vid . '/unverify_icon.jpg'))
|
||||
$verifynew['unverifyicon'] = $uicon;
|
||||
else
|
||||
$verifynew['unverifyicon'] = $_G['setting']['verify'][$vid]['unverifyicon'];
|
||||
if ($_GET['deleteicon']) {
|
||||
$verifynew['icon'] = delverifyicon($verifyarr['icon']);
|
||||
}
|
||||
if ($_GET['delunverifyicon']) {
|
||||
$verifynew['unverifyicon'] = delverifyicon($verifyarr['unverifyicon']);
|
||||
}
|
||||
|
||||
if (!empty($verifynew['field']['birthday'])) {
|
||||
$verifynew['field']['birthyear'] = 'birthyear';
|
||||
$verifynew['field']['birthmonth'] = 'birthmonth';
|
||||
}
|
||||
|
||||
$verifynew['groupid'] = !empty($verifynew['groupid']) && is_array($verifynew['groupid']) ? $verifynew['groupid'] : array();
|
||||
$_G['setting']['verify'][$vid] = $verifynew;
|
||||
$_G['setting']['verify']['enabled'] = false;
|
||||
for ($i = 1; $i < 8; $i++) {
|
||||
if ($_G['setting']['verify'][$i]['available'] && !$_G['setting']['verify']['enabled']) {
|
||||
$_G['setting']['verify']['enabled'] = true;
|
||||
}
|
||||
if ($_G['setting']['verify'][$i]['icon']) {
|
||||
$icon_url = parse_url($_G['setting']['verify'][$i]['icon']);
|
||||
}
|
||||
$_G['setting']['verify'][$i]['icon'] = !$icon_url['host'] ? str_replace($_G['setting']['attachurl'], '', $_G['setting']['verify'][$i]['icon']) : $_G['setting']['verify'][$i]['icon'];
|
||||
}
|
||||
C::t('setting') -> update('verify', $_G['setting']['verify']);
|
||||
|
||||
updatecache(array('setting'));
|
||||
showmessage('members_verify_save_success', ADMINSCRIPT . '?mod=member&op=verifyset', array(), array('alert' => 'right'));
|
||||
}
|
||||
include template('verifyset_edit');
|
||||
} else {
|
||||
if (!submitcheck('verifysubmit')) {
|
||||
for ($i = 1; $i < 8; $i++) {
|
||||
$url = parse_url($_G['setting']['verify'][$i]['icon']);
|
||||
if (!$url['host'] && $_G['setting']['verify'][$i]['icon'] && strpos($_G['setting']['verify'][$i]['icon'], $_G['setting']['attachurl']) === false) {
|
||||
$_G['setting']['verify'][$i]['icon'] = $_G['setting']['attachurl'] . $_G['setting']['verify'][$i]['icon'];
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
$settingnew = getgpc('settingnew');
|
||||
$enabled = false;
|
||||
foreach ($settingnew['verify'] as $key => $value) {
|
||||
if ($value['available'] && !$value['title']) {
|
||||
showmessage('members_verify_title_empty', dreferer());
|
||||
}
|
||||
if ($value['available']) {
|
||||
$enabled = true;
|
||||
}
|
||||
$_G['setting']['verify'][$key]['available'] = intval($value['available']);
|
||||
$_G['setting']['verify'][$key]['title'] = $value['title'];
|
||||
}
|
||||
$_G['setting']['verify']['enabled'] = $enabled;
|
||||
C::t('setting') -> update('verify', $_G['setting']['verify']);
|
||||
updatecache(array('setting'));
|
||||
|
||||
showmessage('members_verify_success', dreferer(), array(), array('alert' => 'right'));
|
||||
}
|
||||
include template('verifyset');
|
||||
}
|
||||
function getverifyicon($iconkey = 'iconnew', $target) {
|
||||
global $_G, $_GET, $_FILES;
|
||||
|
||||
if ($_FILES[$iconkey]) {
|
||||
$iconnew = uploadtolocal($_FILES[$iconkey], 'common', $target);
|
||||
} elseif ($_GET['' . $iconkey]) {
|
||||
$icon_url = parse_url($_GET['' . $iconkey]);
|
||||
if ($icon_url['host'])
|
||||
$iconnew = imagetolocal($_GET['' . $iconkey], 'common', $target);
|
||||
else
|
||||
$iconnew = $_GET['' . $iconkey];
|
||||
} else {
|
||||
$iconnew = '';
|
||||
}
|
||||
return $iconnew;
|
||||
}
|
||||
|
||||
function delverifyicon($icon) {
|
||||
global $_G;
|
||||
|
||||
$valueparse = parse_url($icon);
|
||||
if (!isset($valueparse['host']) && preg_match('/^' . preg_quote($_G['setting']['attachurl'], '/') . '/', $icon)) {
|
||||
@unlink($icon);
|
||||
}
|
||||
return '';
|
||||
}
|
||||
?>
|
@ -345,6 +345,7 @@ if ($do == 'upload') {//上传图片文件
|
||||
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'))));
|
||||
|
@ -36,16 +36,24 @@ if ($do == 'add') {
|
||||
}
|
||||
if (!$orgids && $_G['adminid'] != 1)
|
||||
showmessage('no_parallelism_jurisdiction');
|
||||
//用户名验证
|
||||
$username = trim($_GET['username']);
|
||||
$usernamelen = dstrlen($_GET['username']);
|
||||
if ($usernamelen < 3) {
|
||||
showmessage('profile_username_tooshort');
|
||||
} elseif ($usernamelen > 30) {
|
||||
showmessage('profile_username_toolong');
|
||||
}
|
||||
$censorexp = '/^(' . str_replace(array('\\*', "\r\n", ' '), array('.*', '|', ''), preg_quote(($_G['setting']['censoruser'] = trim($_G['setting']['censoruser'])), '/')) . ')$/i';
|
||||
if ($_G['setting']['censoruser'] && @preg_match($censorexp, $username)) {
|
||||
showmessage('profile_username_protect');
|
||||
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();
|
||||
//如果输入手机号码,检查手机号码不能重复
|
||||
@ -70,25 +78,7 @@ if ($do == 'add') {
|
||||
}
|
||||
$user_extra['weixinid'] = $weixinid;
|
||||
}
|
||||
//用户名验证
|
||||
$nickname = trim($_GET['nickname']);
|
||||
if ($nickname) {
|
||||
$nicknamelen = dstrlen($_GET['nickname']);
|
||||
if ($nicknamelen < 3) {
|
||||
showmessage('profile_nickname_tooshort');
|
||||
} elseif ($nicknamelen > 30) {
|
||||
showmessage('profile_nickname_toolong');
|
||||
}
|
||||
if ($_G['setting']['censoruser'] && @preg_match($censorexp, $nickname)) {
|
||||
showmessage('profile_username_protect');
|
||||
}
|
||||
//如果输入用户名,检查用户名不能重复
|
||||
|
||||
if (C::t('user') -> fetch_by_nickname($nickname)) {
|
||||
showmessage('user_registered_retry');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
//邮箱验证部分
|
||||
$email = strtolower(trim($_GET['email']));
|
||||
@ -115,11 +105,11 @@ if ($do == 'add') {
|
||||
}
|
||||
if ($uid <= 0) {
|
||||
if ($uid == -1) {
|
||||
showmessage('profile_nickname_illegal');
|
||||
showmessage('profile_username_illegal');
|
||||
} elseif ($uid == -2) {
|
||||
showmessage('profile_nickname_protect');
|
||||
showmessage('profile_username_protect');
|
||||
} elseif ($uid == -3) {
|
||||
showmessage('profile_nickname_duplicate');
|
||||
showmessage('profile_username_duplicate');
|
||||
} elseif ($uid == -4) {
|
||||
showmessage('profile_email_illegal');
|
||||
} elseif ($uid == -5) {
|
||||
@ -153,7 +143,7 @@ if ($do == 'add') {
|
||||
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']) {
|
||||
$email_password_message = lang('email_password_message', array('sitename' => $_G['setting']['sitename'], 'siteurl' => $_G['siteurl'], 'email' => $_GET['email'], 'password' => $_GET['password']));
|
||||
|
||||
@ -214,7 +204,11 @@ if ($do == 'add') {
|
||||
|
||||
showmessage('edit_user_success', ADMINSCRIPT . '?mod=orguser#user_' . $uid, array());
|
||||
}
|
||||
|
||||
|
||||
//用户名验证
|
||||
$username = trim($_GET['username']);
|
||||
|
||||
$usernamelen = dstrlen($_GET['username']);
|
||||
if ($usernamelen < 3) {
|
||||
showmessage('profile_username_tooshort');
|
||||
@ -223,33 +217,17 @@ if ($do == 'add') {
|
||||
} elseif (!check_username(addslashes(trim(stripslashes($username))))) {
|
||||
showmessage('profile_username_illegal');
|
||||
}
|
||||
$censorexp = '/^(' . str_replace(array('\\*', "\r\n", ' '), array('.*', '|', ''), preg_quote(($_G['setting']['censoruser'] = trim($_G['setting']['censoruser'])), '/')) . ')$/i';
|
||||
if ($_G['setting']['censoruser'] && @preg_match($censorexp, $username)) {
|
||||
showmessage('profile_username_protect');
|
||||
}
|
||||
|
||||
//用户名验证
|
||||
$nickname = trim($_GET['nickname']);
|
||||
if ($nickname) {
|
||||
$nicknamelen = dstrlen($_GET['nickname']);
|
||||
if ($nicknamelen < 3) {
|
||||
showmessage('profile_nickname_tooshort');
|
||||
} elseif ($nicknamelen > 30) {
|
||||
showmessage('profile_nickname_toolong');
|
||||
} elseif (!check_username(addslashes(trim(stripslashes($nickname))))) {
|
||||
showmessage('profile_nickname_illegal');
|
||||
//如果输入用户名,检查用户名不能重复
|
||||
if ($username != $user['username']) {
|
||||
if (C::t('user') -> fetch_by_username($username)) {
|
||||
showmessage('user_registered_retry');
|
||||
}
|
||||
|
||||
//如果输入用户名,检查用户名不能重复
|
||||
if ($nickname != $user['nickname']) {
|
||||
if (C::t('user') -> fetch_by_nickname($nickname)) {
|
||||
showmessage('user_registered_retry');
|
||||
}
|
||||
if ($_G['setting']['censoruser'] && @preg_match($censorexp, $nickname)) {
|
||||
showmessage('profile_username_protect');
|
||||
}
|
||||
if ($_G['setting']['censoruser'] && @preg_match($censorexp, $username)) {
|
||||
showmessage('profile_username_protect');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//如果输入手机号码,检查手机号码不能重复
|
||||
$phone = trim($_GET['phone']);
|
||||
@ -279,7 +257,7 @@ if ($do == 'add') {
|
||||
} elseif (!check_emailaccess($email)) {
|
||||
showmessage('profile_email_domain_illegal', '', array(), array('handle' => false));
|
||||
}
|
||||
if ($email != $user['email']) {
|
||||
if ($email != strtolower($user['email'])) {
|
||||
//邮箱不能重复
|
||||
if (C::t('user') -> fetch_by_email($email)) {
|
||||
showmessage('email_registered_retry');
|
||||
@ -301,13 +279,13 @@ if ($do == 'add') {
|
||||
$password = $_GET['password'];
|
||||
if ($password) {
|
||||
$salt = substr(uniqid(rand()), -6);
|
||||
$setarr = array('salt' => $salt, 'password' => md5(md5($password) . $salt), 'username' => $username, 'nickname' => $nickname, 'phone' => $phone, 'weixinid' => $weixinid, 'secques' => '', 'email' => $email, 'status' => intval($_GET['status']));
|
||||
$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, 'nickname' => $nickname, 'phone' => $phone, 'weixinid' => $weixinid, 'status' => intval($_GET['status']));
|
||||
$setarr = array('username' => $username, 'email' => $email, 'phone' => $phone, 'weixinid' => $weixinid, 'status' => intval($_GET['status']));
|
||||
}
|
||||
C::t('user') -> update($uid, $setarr);
|
||||
wx_updateUser($uid);
|
||||
|
||||
//处理管理员
|
||||
C::t('user') -> setAdministror($uid, intval($_GET['groupid']));
|
||||
//处理额外空间和用户空间
|
||||
@ -325,8 +303,8 @@ if ($do == 'add') {
|
||||
//处理上司职位;
|
||||
|
||||
C::t('organization_upjob') -> insert_by_uid($uid, intval($_GET['upjobid']));
|
||||
Hook::listen('syntoline_user',$uid);//注册绑定到钉钉部门表
|
||||
showmessage('edit_user_success', ADMINSCRIPT . '?mod=orguser#user_' . $uid, array());
|
||||
|
||||
} else {
|
||||
require_once libfile('function/organization');
|
||||
|
||||
|
@ -12,7 +12,7 @@ if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
require_once libfile('function/organization');
|
||||
require_once DZZ_ROOT.'./core/class/class_PHPExcel.php';
|
||||
if($_G['adminid']!=1) showmessage('system_administrator_export',dreferer());
|
||||
$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'));
|
||||
$h0=array('username'=>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']);
|
||||
|
@ -9,7 +9,7 @@
|
||||
if(!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
exit('Access Denied');
|
||||
}
|
||||
$h0=array('username'=>lang('compellation'),'email'=>lang('email'),'nickname'=>lang('username'),'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'));
|
||||
$h0=array('username'=>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');
|
||||
|
@ -141,6 +141,11 @@
|
||||
.moderators-container .user-item-avatar .avatar-face{
|
||||
width:90px;height:90px;margin:5px
|
||||
|
||||
}.moderators-container .user-item-avatar .avatar-face .Topcarousel {
|
||||
width:90px;height:90px;
|
||||
font-size:40px;
|
||||
line-height: 90px
|
||||
|
||||
}
|
||||
.moderators-container .user-item-avatar img{
|
||||
width:100%;
|
||||
|
@ -16,10 +16,7 @@ if($do=='importing'){
|
||||
//判断邮箱是否存在
|
||||
require_once libfile('function/user','','user');
|
||||
$email=trim($_GET['email']);
|
||||
$_GET['nickname']=addslashes(trim(stripslashes(trim($_GET['nickname']))));
|
||||
$_GET['username']=addslashes(trim(stripslashes(trim($_GET['username']))));
|
||||
|
||||
$_GET['nickname']=str_replace('...','',getstr($_GET['nickname'],30));
|
||||
$_GET['username']=str_replace('...','',getstr($_GET['username'],30));
|
||||
$_GET['password']=empty($_GET['password'])?trim($_GET['pswdefault']):trim($_GET['password']);
|
||||
|
||||
@ -38,17 +35,13 @@ if($do=='importing'){
|
||||
$exist=0;
|
||||
|
||||
//检查用户是否已经存在
|
||||
if(($user=C::t('user')->fetch_by_email($email)) || ($_GET['nickname'] && ($user=C::t('user')->fetch_by_nickname($_GET['nickname'])))){//用户已经存在时
|
||||
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,增加
|
||||
$appendfield=array();
|
||||
if($_GET['nickname'] && empty($user['nickname'])){
|
||||
if(check_username($_GET['nickname']) && !C::t('user')->fetch_by_nickname($_GET['nickname'])){
|
||||
$appendfield['nickname']=$_GET['nickname'];
|
||||
}
|
||||
}
|
||||
|
||||
if($_GET['mobile'] && empty($user['phone'])){
|
||||
if(!preg_match("/^\d+$/",$_GET['mobile'])){
|
||||
exit(json_encode(array('error'=>lang('phone_number_illegal'))));
|
||||
@ -76,11 +69,7 @@ if($do=='importing'){
|
||||
'password'=>md5(md5($_GET['password']).$salt),
|
||||
'salt'=>$salt
|
||||
);
|
||||
if($_GET['nickname']){
|
||||
if($_GET['nickname']!=$user['nickname'] && check_username($_GET['nickname']) && !C::t('user')->fetch_by_nickname($_GET['nickname'])){
|
||||
$setarr['nickname']=$_GET['nickname'];
|
||||
}
|
||||
}
|
||||
|
||||
if($_GET['mobile'] && $_GET['mobile']!=$user['phone']){
|
||||
if(!preg_match("/^\d+$/",$_GET['mobile'])){
|
||||
exit(json_encode(array('error'=>lang('phone_number_illegal'))));
|
||||
@ -117,13 +106,8 @@ if($do=='importing'){
|
||||
}else{ //新添用户
|
||||
if(!check_username($_GET['username'])) exit(json_encode(array('error'=>lang('user_name_sensitive'))));
|
||||
|
||||
if($_GET['nickname']){
|
||||
if(check_username($_GET['nickname']) && !C::t('user')->fetch_by_nickname($_GET['nickname'])){
|
||||
}else{
|
||||
$_GET['nickname']='';
|
||||
}
|
||||
}
|
||||
$user=uc_add_user($_GET['username'], $_GET['password'], $email, $_GET['nickname']);
|
||||
|
||||
$user=uc_add_user($_GET['username'], $_GET['password'], $email);
|
||||
|
||||
$uid=$user['uid'];
|
||||
if($uid<1) exit(json_encode(array('error'=>lang('import_failure'))));
|
||||
|
@ -13,7 +13,7 @@ function checkAdminLogin(str){
|
||||
}
|
||||
}
|
||||
function show_guide(){
|
||||
jQuery('#orguser_container').load(ajaxurl+'&do=guide',function(){
|
||||
jQuery('#orguser_container').load(ajaxurl+'do=guide',function(){
|
||||
location.hash='';
|
||||
});
|
||||
}
|
||||
@ -36,7 +36,7 @@ function selJob(obj){
|
||||
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){
|
||||
li.parent().find('.job .dropdown-menu').load(ajaxurl+'do=getjobs&orgid='+orgid,function(html){
|
||||
if(checkAdminLogin(html)){
|
||||
location.reload();
|
||||
}
|
||||
@ -63,6 +63,7 @@ function errormessage(id, msg,passlevel) {
|
||||
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;
|
||||
}
|
||||
@ -220,7 +221,7 @@ function jstree_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){
|
||||
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){
|
||||
@ -248,7 +249,7 @@ function jstree_create_dir(){
|
||||
return true;
|
||||
}
|
||||
var inst = jQuery("#classtree").jstree(true);
|
||||
jQuery.post(ajaxurl+'&do=create',{'forgid':obj.id,'t':new Date().getTime()},function(json){
|
||||
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){
|
||||
@ -294,7 +295,7 @@ function showDetail(id,idtype,ajaxdo,orgid){
|
||||
//console..log(hash);
|
||||
urladd+='&t='+new Date().getTime()
|
||||
|
||||
jQuery('#orguser_container').load(baseurl+'&op=view&id='+id+'&idtype='+idtype+urladd,function(html){
|
||||
jQuery('#orguser_container').load(baseurl+'op=view&id='+id+'&idtype='+idtype+urladd,function(html){
|
||||
if(checkAdminLogin(html)){
|
||||
location.reload();
|
||||
}
|
||||
@ -332,7 +333,7 @@ function job_save(jobid,orgid){
|
||||
el.find('.edit').addClass('hide');
|
||||
return;
|
||||
}
|
||||
jQuery.post(ajaxurl+'&do=jobedit',{'name':name,'jobid':jobid,'orgid':orgid,'t':new Date().getTime()},function(json){
|
||||
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');
|
||||
@ -364,7 +365,7 @@ function job_cancel_add_editor(orgid){
|
||||
}
|
||||
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){
|
||||
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){
|
||||
@ -380,7 +381,7 @@ function job_add(orgid){
|
||||
newtodo.find('.new-job-text').focus();
|
||||
return;
|
||||
}
|
||||
jQuery.post(ajaxurl+'&do=jobadd',{'name':name,'orgid':orgid,'t':new Date().getTime()},function(json){
|
||||
jQuery.post(ajaxurl+'do=jobadd',{'name':name,'orgid':orgid,'t':new Date().getTime()},function(json){
|
||||
|
||||
if(json.jobid>0){
|
||||
appendjob(json);
|
||||
@ -404,6 +405,20 @@ function appendjob(json){
|
||||
html+='</div>';
|
||||
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<ids.length;i++){
|
||||
moderator_add(orgid,ids[i]);
|
||||
}
|
||||
|
||||
}
|
||||
function moderator_add(orgid,uid){
|
||||
if(jQuery('#moderators_container_'+orgid+' .user-item[uid='+uid+']').length){
|
||||
jQuery('#moderators_container_'+orgid+' .user-item[uid='+uid+']').insertAfter(jQuery('#moderators_container_'+orgid+' .moderators-acceptor'));
|
||||
@ -411,7 +426,7 @@ function moderator_add(orgid,uid){
|
||||
return;
|
||||
}
|
||||
jQuery('#moderators_container_'+orgid+' .moderators-acceptor').removeClass('hover');
|
||||
jQuery.post(ajaxurl+'&do=moderator_add',{'orgid':orgid,'uid':uid,'t':new Date().getTime()},function(json){
|
||||
jQuery.post(ajaxurl+'do=moderator_add',{'orgid':orgid,'uid':uid,'t':new Date().getTime()},function(json){
|
||||
if(json.error) showmessage(json.error,'danger',3000,1);
|
||||
else{
|
||||
appendModerator(json);
|
||||
@ -425,7 +440,7 @@ function appendModerator(json){
|
||||
html+=' <div class="avatar-cover"></div>';
|
||||
html+=' <div class="user-item-avatar">';
|
||||
html+=' <div class="avatar-face">';
|
||||
html+=' <img src="avatar.php?uid='+json.uid+'&size=middle">';
|
||||
html+=' '+json.avatar;
|
||||
html+=' </div>';
|
||||
html+=' </div>';
|
||||
html+=' <p class="text-center" style="height:20px;margin:5px 0;line-height:25px;overflow:hidden;"> '+json.username+'</p>';
|
||||
@ -433,7 +448,7 @@ function appendModerator(json){
|
||||
jQuery('#moderators_container_'+json.orgid+' .moderators-acceptor').after(html);
|
||||
}
|
||||
function moderator_del(id,orgid,obj){
|
||||
jQuery.post(ajaxurl+'&do=moderator_del',{'orgid':orgid,'id':id,'t':new Date().getTime()},function(json){
|
||||
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();
|
||||
@ -443,7 +458,7 @@ function moderator_del(id,orgid,obj){
|
||||
}
|
||||
|
||||
function folder_available(available,orgid){
|
||||
jQuery.post(ajaxurl+'&do=folder_available',{'orgid':orgid,'available':available,'t':new Date().getTime()},function(json){
|
||||
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{
|
||||
@ -458,7 +473,7 @@ function folder_available(available,orgid){
|
||||
},'json');
|
||||
}
|
||||
function group_on(on,orgid){
|
||||
jQuery.post(ajaxurl+'&do=group_on',{'orgid':orgid,'available':on,'t':new Date().getTime()},function(json){
|
||||
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{
|
||||
@ -471,12 +486,12 @@ function group_on(on,orgid){
|
||||
},'json');
|
||||
}
|
||||
function folder_indesk(indesk,orgid){
|
||||
jQuery.post(ajaxurl+'&do=folder_indesk',{'orgid':orgid,'indesk':indesk,'t':new Date().getTime()},function(json){
|
||||
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){
|
||||
jQuery.post(ajaxurl+'do=set_org_logo',{'orgid':orgid,'aid':aid},function(json){
|
||||
if(json.error) showmessage(json.error,'danger',3000,1);
|
||||
},'json');
|
||||
}
|
||||
@ -488,7 +503,7 @@ function set_org_logo(orgid,aid){
|
||||
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){
|
||||
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);
|
||||
@ -501,14 +516,14 @@ function set_org_orgname(orgid,obj){
|
||||
},'json');
|
||||
}
|
||||
function set_org_desc(orgid,desc){
|
||||
jQuery.post(ajaxurl+'&do=set_org_desc',{'orgid':orgid,'desc':desc},function(json){
|
||||
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){
|
||||
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);
|
||||
|
@ -6,6 +6,7 @@
|
||||
background-color: #e6e6e6;
|
||||
overflow:visible;
|
||||
padding:4px;
|
||||
max-width:750px;
|
||||
}
|
||||
.progress-relative .progress-cover {
|
||||
position: absolute;
|
||||
@ -65,6 +66,7 @@
|
||||
|
||||
<!--{if $folder_available}-->
|
||||
<dl>
|
||||
<!--原共享目录设置:diron,此处暂时用来控制应用内是否开启共享目录,如网盘群组开关不开启,表示网盘内不显示该目录-->
|
||||
<dt>{lang shared_directory_set}</dt>
|
||||
<dd class="clearfix">
|
||||
<div class="radio-custom radio-primary pull-left"><input type="radio" id="folder_available_1" name="fid" value="1" <!--{if $org[diron]>0}-->checked="checked"<!--{/if}--> onclick="folder_available(1,'$orgid');" /><label>{lang enable}</label>
|
||||
@ -75,7 +77,7 @@
|
||||
</dd>
|
||||
<dd class="clearfix">
|
||||
<!--{if $org['forgid']<1}-->
|
||||
<span class="help-inline ml20">{lang detail_org_no_enable}</span>
|
||||
<span class="help-inline ml20">{lang detail_org_explorerapp_enable}</span>
|
||||
<!--{else}-->
|
||||
<span class="help-inline ml20">{lang detail_org_enable}</span>
|
||||
<!--{/if}-->
|
||||
@ -94,20 +96,20 @@
|
||||
</dl>
|
||||
<!--{/if}-->
|
||||
<!--{if $group_on}-->
|
||||
<dl>
|
||||
<!-- <dl>
|
||||
<dt>{lang group_on_set}</dt>
|
||||
<dd class="clearfix">
|
||||
<div class="radio-custom radio-primary pull-left"><input type="radio" id="folder_syatemon_1" name="syatemon" value="1" <!--{if $org[manageon]>0}-->checked="checked"<!--{/if}--> onclick="group_on(1,'$orgid');" /><label>{lang enable}</label></div>
|
||||
<div class="radio-custom radio-primary ml20 pull-left"><input type="radio" id="folder_syatemon_0" name="syatemon" value="0" <!--{if $org[manageon]<1}-->checked="checked"<!--{/if}--> onclick="group_on(0,'$orgid');" /><label>{lang no_enable}</label></div>
|
||||
<div class="radio-custom radio-primary pull-left"><input type="radio" id="folder_syatemon_1" name="syatemon" value="1" <!–{if $org[manageon]>0}–>checked="checked"<!–{/if}–> onclick="group_on(1,'$orgid');" /><label>{lang enable}</label></div>
|
||||
<div class="radio-custom radio-primary ml20 pull-left"><input type="radio" id="folder_syatemon_0" name="syatemon" value="0" <!–{if $org[manageon]<1}–>checked="checked"<!–{/if}–> onclick="group_on(0,'$orgid');" /><label>{lang no_enable}</label></div>
|
||||
</dd>
|
||||
<dd class="clearfix">
|
||||
<!--{if $org['forgid']<1}-->
|
||||
<!–{if $org['forgid']<1}–>
|
||||
<span class="help-inline ml20">{lang group_org_no_enable}</span>
|
||||
<!--{else}-->
|
||||
<!–{else}–>
|
||||
<span class="help-inline ml20">{lang group_org_enable}</span>
|
||||
<!--{/if}-->
|
||||
<!–{/if}–>
|
||||
</dd>
|
||||
</dl>
|
||||
</dl>-->
|
||||
<!--{/if}-->
|
||||
<!--{if $_G['adminid']==1 || $topmoderator}-->
|
||||
<dl>
|
||||
@ -125,7 +127,7 @@
|
||||
{lang org_space_assign_tips}
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
</dl>
|
||||
<!--{/if}-->
|
||||
<dl>
|
||||
<dt><!--{if $org[forgid]>0}-->{lang space_use_department}<!--{else}-->{lang space_use_org}<!--{/if}--></dt>
|
||||
@ -142,8 +144,7 @@
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
|
||||
|
||||
|
||||
<dl>
|
||||
<dt>{lang position_management}</dt>
|
||||
@ -199,7 +200,7 @@
|
||||
<div class="avatar-cover"></div>
|
||||
<div class="user-item-avatar">
|
||||
<div class="avatar-face">
|
||||
<img src="avatar.php?uid=$value[uid]&size=middle">
|
||||
{eval echo avatar_block($value[uid]);}
|
||||
</div>
|
||||
</div>
|
||||
<p class="text-center" style="height:20px;margin:5px 0;line-height:25px;overflow:hidden;"> $value[username]</p>
|
||||
@ -235,6 +236,14 @@
|
||||
|
||||
return false;
|
||||
}
|
||||
jQuery(document).on('click','.moderators-acceptor',function(){
|
||||
var ids=[];
|
||||
jQuery('.moderators-container .user-item').each(function(){
|
||||
ids.push(jQuery(this).attr('uid'));
|
||||
});
|
||||
showWindow('moderators','index.php?mod=system&op=selorguser&stype=2&multiple=1&callback=callback_moderators&token=$orgid&ids='+ids.join(','),'get',0)
|
||||
|
||||
});
|
||||
jQuery(document).on('click','.headinput-checkbox',function(){
|
||||
if(jQuery(this).prop("checked")){
|
||||
jQuery(this).closest('.head-portrait').siblings('.head-portrait').find('.headinput-checkbox').prop('checked',false).parents('.head-checkbox').removeClass('hover');
|
||||
@ -243,7 +252,7 @@
|
||||
jQuery(this).parents('.head-portrait').find('.head-checkbox').removeClass('hover');
|
||||
}
|
||||
|
||||
})
|
||||
});
|
||||
function upload_bgphoto(obj,fact) {
|
||||
'use strict';
|
||||
jQuery(obj).fileupload({
|
||||
|
@ -227,7 +227,7 @@
|
||||
var orgsel_html = jQuery('#nav').html();
|
||||
var lastusername = '{$user[username]}',
|
||||
lastpassword = '',
|
||||
lastemail = '{$user[email]}',
|
||||
lastemail = '{eval echo strtolower($user[email])}',
|
||||
lastinvitecode = '',
|
||||
stmp = new Array(),
|
||||
modifypwd = true;
|
||||
|
@ -46,7 +46,7 @@
|
||||
<div class="form-group">
|
||||
<label class="control-label " style="width:140px;text-align:left;padding-left:0">{lang inport_guide_step}</label>
|
||||
<div class="controls">
|
||||
<input type="file" name="importfile" class="form-control" style="padding:6px 12px;" />
|
||||
<input type="file" name="importfile" accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" class="form-control" style="padding:6px 12px;" />
|
||||
</div>
|
||||
<span class="help-inline">{lang inport_guide_layout}</span>
|
||||
</div>
|
||||
|
@ -17,8 +17,8 @@
|
||||
|
||||
<script type="text/javascript">
|
||||
var orgtree = $orgtree;
|
||||
var ajaxurl = '{ADMINSCRIPT}?mod=orguser&op=ajax';
|
||||
var baseurl = '{ADMINSCRIPT}?mod=orguser';
|
||||
var ajaxurl = '{ADMINSCRIPT}?mod=orguser&op=ajax&';
|
||||
var baseurl = '{ADMINSCRIPT}?mod=orguser&';
|
||||
jQuery(document).ready(function(e) {
|
||||
|
||||
jQuery("#classtree").jstree({
|
||||
@ -178,6 +178,7 @@
|
||||
|
||||
var inst = jQuery.jstree.reference(data.reference),
|
||||
obj = inst.get_node(data.reference);
|
||||
console.log('aaaaaaa');
|
||||
inst.edit(obj);
|
||||
|
||||
}
|
||||
@ -394,7 +395,8 @@
|
||||
jQuery("#classtree").on('rename_node.jstree', function(e, data) {
|
||||
var inst = jQuery("#classtree").jstree(true);
|
||||
var obj = inst.get_node(data.node);
|
||||
if(data.text == '') {
|
||||
var oldtext = data.old.replace(/<(.+?)>(.+?)<\/(.+?)>/,'');
|
||||
if(data.text == '' || data.text == oldtext) {
|
||||
inst.set_text(obj, data.old);
|
||||
return;
|
||||
}
|
||||
@ -406,6 +408,7 @@
|
||||
}else{
|
||||
jQuery('#title_orgname').html(data.text);
|
||||
jQuery('#orgname').val(data.text).data('oldname',data.text);
|
||||
inst.refresh();
|
||||
}
|
||||
}, 'json');
|
||||
});
|
||||
|
@ -15,7 +15,7 @@ $lang = array
|
||||
(
|
||||
'appname'=>'系统设置',
|
||||
'spaceSet'=>'空间设置',
|
||||
'loginSet'=>'登陆设置',
|
||||
'loginSet'=>'登录设置',
|
||||
'basicSet'=>'基本设置',
|
||||
'permGroupSet'=>'权限包设置',
|
||||
'spaceSet'=>'空间设置',
|
||||
|
@ -316,14 +316,14 @@
|
||||
row="6">$setting[statcode]</textarea>
|
||||
<span class="help-block text-muted">{lang support_html_code}</span></dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<!--<dl>
|
||||
<dt>{lang prompt_leave_platform}:</dt>
|
||||
<dd class="clearfix">
|
||||
<label class="radio-inline"> <input type="radio" name="settingnew[leavealert]" value="1" <!--{if $setting[leavealert]}-->checked<!--{/if}-->>{lang yes}</label>
|
||||
<label class="radio-inline"> <input type="radio" name="settingnew[leavealert]" value="0"<!--{if !$setting[leavealert]}-->checked
|
||||
<!--{/if}-->>{lang no}</label>
|
||||
<span class="help-block"> {lang setting_main_leave}</span>
|
||||
</dl>
|
||||
</dl>-->
|
||||
<dl>
|
||||
<dt>{lang close_terrace}:</dt>
|
||||
<dd class="clearfix">
|
||||
@ -1264,9 +1264,7 @@
|
||||
<dl>
|
||||
<dt>{lang need_words_to_replace}:</dt>
|
||||
<dd class="clearfix">
|
||||
<textarea class="form-control" name="badwords" rows="1" style="width:100%"/>
|
||||
$badwords
|
||||
</textarea>
|
||||
<textarea class="form-control" name="badwords" rows="1" style="width:100%"/>$badwords</textarea>
|
||||
|
||||
<span class="help-block">{lang need_words_to_replace_state}</span></dd>
|
||||
</dl>
|
||||
|
@ -51,7 +51,7 @@ $list = array();
|
||||
if ($count = DB::result_first("SELECT COUNT(*) FROM %t WHERE $sql", $param)) {
|
||||
$list = DB::fetch_all("SELECT * FROM %t WHERE $sql $orderby limit $start,$perpage", $param);
|
||||
foreach ($list as $k=> $value) {
|
||||
$value['sharelink'] = C::t('shorturl')->getShortUrl(getglobal('siteurl').'?index.php&mod=shares&sid='.dzzencode($value['id']));
|
||||
$value['sharelink'] = C::t('shorturl')->getShortUrl(getglobal('siteurl').'index.php?mod=shares&sid='.dzzencode($value['id']));
|
||||
if ($value['dateline'])
|
||||
$value['fdateline'] = dgmdate($value['dateline']);
|
||||
if ($value['password'])
|
||||
|
@ -1,10 +1,10 @@
|
||||
<ul class="nav-stacked">
|
||||
<li <!--{if !$type}-->class="active"<!--{/if}-->>
|
||||
<a href="{ADMINSCRIPT}?mod=share">{lang all}</a>
|
||||
<a href="{MOD_URL}">{lang all}</a>
|
||||
</li>
|
||||
<!--{loop $typearr $key $value}-->
|
||||
<li <!--{if $type==$key}-->class="active"<!--{/if}-->>
|
||||
<a href="{ADMINSCRIPT}?mod={MOD_NAME}&type=$key">$value</a>
|
||||
<a href="{MOD_URL}&type=$key">$value</a>
|
||||
</li>
|
||||
<!--{/loop}-->
|
||||
</ul>
|
@ -1252,7 +1252,7 @@ sKFSVBTBllJZMQSbaoVFEGwrli4cwcZq8UIRbC2XLwzB5vMChSDYfmCiVwhPXAHoFcK8SwC9QBhy
|
||||
DcA0wksXAUwhrBDnNp0EyItwJHvk6rG5LAgtU2cunxtMg5CYN3T94GQ3CG2Tps6fHNUDS0LomDHu
|
||||
i6OzTQhPgV/AHvHhzo7p8tL/0+MD3v4NAFgLFX0uJNkNAAAAAElFTkSuQmCC
|
||||
]]></item>
|
||||
<item id="appdesc"><![CDATA[系统工具,缓存更新,数据库管理等]]></item>
|
||||
<item id="appdesc"><![CDATA[系统维护相关工具集合,如:更新缓存、数据库备份,计划任务,在线升级等]]></item>
|
||||
<item id="appurl"><![CDATA[{adminscript}?mod=system]]></item>
|
||||
<item id="appadminurl"><![CDATA[]]></item>
|
||||
<item id="noticeurl"><![CDATA[]]></item>
|
||||
|
@ -11,6 +11,7 @@ if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
|
||||
}
|
||||
|
||||
$operation = $_GET['operation'] ? $_GET['operation'] : 'updatecache';
|
||||
$url = BASESCRIPT . '?mod=system&op=' . $operation;
|
||||
$url=getglobal('siteurl'). BASESCRIPT . '?mod=system&op=' . $operation;
|
||||
$url = outputurl($url);
|
||||
@header("location: $url");
|
||||
?>
|
||||
|
@ -49,8 +49,9 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
|
||||
if ($_GET['ungetfrom']) {
|
||||
if (md5($_GET['ungetfrom'] . $_G['config']['security']['authkey']) == $_GET['ungetfrommd5']) {
|
||||
$dbreturnurl = $_G['siteurl'] . ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&step=5';
|
||||
dheader('Location: ' . $_G['siteurl'] . 'install/update.php?step=prepare&from=' . rawurlencode($dbreturnurl) . '&frommd5=' . rawurlencode(md5($dbreturnurl . $_G['config']['security']['authkey'])));
|
||||
$dbreturnurl = $_G['siteurl'] . ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&step=5';
|
||||
$url = outputurl( $_G['siteurl'] . 'install/update.php?step=prepare&from=' . rawurlencode($dbreturnurl) . '&frommd5=' . rawurlencode(md5($dbreturnurl . $_G['config']['security']['authkey'])) );
|
||||
dheader('Location: ' . $url);
|
||||
} else {
|
||||
showmessage('upgrade_param_error');
|
||||
}
|
||||
@ -101,7 +102,7 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
$updatefilelist = $dzz_upgrade -> fetch_updatefile_list($upgradeinfo);
|
||||
$updatemd5filelist = $updatefilelist['md5'];
|
||||
$updatefilelist = $updatefilelist['file'];
|
||||
$theurl = ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&locale=' . $locale . '&charset=' . $charset;
|
||||
$theurl = $_G['siteurl'].ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&locale=' . $locale . '&charset=' . $charset;
|
||||
|
||||
if (empty($updatefilelist)) {
|
||||
$msg = '<p style="margin:10px 0;color:red">' . lang('upgrade_download_upgradelist_error', array('upgradeurl' => upgradeinformation(-2))) . '</p>';
|
||||
@ -167,14 +168,12 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
exit();
|
||||
}
|
||||
}
|
||||
} elseif ($step == 3) {
|
||||
list($modifylist, $showlist, $ignorelist) = $dzz_upgrade -> compare_basefile($upgradeinfo, $updatefilelist);
|
||||
if (empty($modifylist) && empty($showlist) && empty($ignorelist)) {
|
||||
} elseif ($step == 3) {
|
||||
list($modifylist, $showlist, $ignorelist,$newlist) = $dzz_upgrade -> compare_basefile($upgradeinfo, $updatefilelist);
|
||||
if (empty($modifylist) && empty($showlist) && empty($ignorelist) && empty($newlist)) {
|
||||
$msg = lang('filecheck_nofound_md5file', array('upgradeurl' => upgradeinformation(-4)));
|
||||
}
|
||||
|
||||
$linkurl = $theurl . '&step=4';
|
||||
|
||||
} elseif ($step == 4) {
|
||||
|
||||
$confirm = $_GET['confirm'];
|
||||
@ -322,7 +321,9 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
exit();
|
||||
|
||||
}
|
||||
dheader('Location: ' . ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&step=5');
|
||||
|
||||
$url = outputurl( $_G['siteurl'].MOD_URL.'&op=systemupgrade&operation=' . $operation . '&version=' . $version . '&step=5' );
|
||||
dheader('Location: ' . $url);
|
||||
|
||||
} elseif ($step == 5) {
|
||||
$file = DZZ_ROOT . './data/update/dzzoffice' . $version . '/updatelist.tmp';
|
||||
@ -345,9 +346,9 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
|
||||
}
|
||||
|
||||
} elseif ($operation == 'check') {
|
||||
}
|
||||
elseif ($operation == 'check') {
|
||||
$msg = '';
|
||||
|
||||
if (!intval($_GET['rechecking'])) {
|
||||
$upgrade_step = C::t('cache') -> fetch('upgrade_step');
|
||||
if (!empty($upgrade_step['cachevalue'])) {
|
||||
@ -377,11 +378,12 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
|
||||
} else {
|
||||
$dzz_upgrade -> check_upgrade();
|
||||
|
||||
dheader('Location: ' . ADMINSCRIPT . '?mod=system&op=systemupgrade&operation=showupgrade');
|
||||
$url = outputurl( $_G['siteurl'].MOD_URL.'&op=systemupgrade&operation=showupgrade' );
|
||||
dheader('Location: ' . $url);
|
||||
}
|
||||
|
||||
} elseif ($operation == 'showupgrade') {
|
||||
}
|
||||
elseif ($operation == 'showupgrade') {
|
||||
|
||||
if ($_G['setting']['upgrade']) {
|
||||
|
||||
@ -429,7 +431,8 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
$msg = lang('upgrade_latest_version');
|
||||
}
|
||||
|
||||
} elseif ($operation == 'recheck') {
|
||||
}
|
||||
elseif ($operation == 'recheck') {
|
||||
$upgrade_step = C::t('cache') -> fetch('upgrade_step');
|
||||
$upgrade_step = dunserialize($upgrade_step['cachevalue']);
|
||||
$file = DZZ_ROOT . './data/update/DzzOffice' . $upgrade_step['version'] . '/updatelist.tmp';
|
||||
@ -441,7 +444,9 @@ if ($operation == 'patch' || $operation == 'cross') {
|
||||
updatecache('setting');
|
||||
$old_update_dir = './data/update/';
|
||||
$dzz_upgrade -> rmdirs(DZZ_ROOT . $old_update_dir);
|
||||
dheader('Location: ' . ADMINSCRIPT . '?mod=system&op=systemupgrade');
|
||||
|
||||
$url = outputurl($_G['siteurl'].MOD_URL.'&op=systemupgrade' );
|
||||
dheader('Location: ' . $url);
|
||||
}
|
||||
include template('upgrade');
|
||||
?>
|
@ -16,13 +16,13 @@
|
||||
<div class="main-header clearfix">
|
||||
<ul class="nav nav-pills nav-pills-bottomguide">
|
||||
<li <!--{if $operation=='export' }-->class="active"<!--{/if}-->>
|
||||
<a hidefocus="true" href="{BASESCRIPT}?mod={MOD_NAME}&op=database&operation=export">{lang export}</a>
|
||||
<a hidefocus="true" href="{MOD_URL}&op=database&operation=export">{lang export}</a>
|
||||
</li>
|
||||
<li <!--{if $operation=='import' }-->class="active"<!--{/if}-->>
|
||||
<a hidefocus="true" href="{BASESCRIPT}?mod={MOD_NAME}&op=database&operation=import">{lang nav_db_import}</a>
|
||||
<a hidefocus="true" href="{MOD_URL}&op=database&operation=import">{lang nav_db_import}</a>
|
||||
</li>
|
||||
<li <!--{if $operation=='runquery' }-->class="active"<!--{/if}-->>
|
||||
<a hidefocus="true" href="{BASESCRIPT}?mod={MOD_NAME}&op=database&operation=runquery">{lang nav_db_runquery}</a>
|
||||
<a hidefocus="true" href="{MOD_URL}&op=database&operation=runquery">{lang nav_db_runquery}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -33,7 +33,7 @@
|
||||
<div class="main-content">
|
||||
<!--{if !$submit}-->
|
||||
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=system&op=database&operation=export&setup=1" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<form id="cpform" action="{MOD_URL}&op=database&operation=export&setup=1" class="form-horizontal form-horizontal-left" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="exportsubmit">
|
||||
<dl>
|
||||
@ -126,7 +126,7 @@
|
||||
<h5>{lang board_message}</h5> {lang db_import_tips}
|
||||
</ul>
|
||||
$do_import_option
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=system&op=database&operation=import" class="form-horizontal form-horizontal-left " method="post" name="cpform">
|
||||
<form id="cpform" action="{MOD_URL}&op=database&operation=import" class="form-horizontal form-horizontal-left " method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="deletesubmit">
|
||||
<table class="table table-hover" style="border-top:1px solid #DDD">
|
||||
@ -212,7 +212,7 @@
|
||||
</div>
|
||||
<!--{else}-->
|
||||
|
||||
<form id="cpform" action="{BASESCRIPT}?mod=system&op=database&operation=runquery" method="post" name="cpform">
|
||||
<form id="cpform" action="{MOD_URL}&op=database&operation=runquery" method="post" name="cpform">
|
||||
<input type="hidden" value="{FORMHASH}" name="formhash">
|
||||
<input type="hidden" value="true" name="sqlsubmit">
|
||||
<dl>
|
||||
|
@ -7,6 +7,6 @@
|
||||
|
||||
<ul class="nav-stacked">
|
||||
<!--{loop $leftmenu $key $value}-->
|
||||
<li $value[active]><a hidefocus="true" href="{BASESCRIPT}?mod={MOD_NAME}&op=$key">$value[title]</a></li>
|
||||
<li $value[active]><a hidefocus="true" href="{MOD_URL}&op=$key">$value[title]</a></li>
|
||||
<!--{/loop}-->
|
||||
</ul>
|
@ -24,7 +24,7 @@
|
||||
<div class="main-content" style="padding:20px;border-top:1px solid #FFF">
|
||||
<div class="well well-sm">
|
||||
<!--{if $step==1}-->
|
||||
<form method="post" class="form-horizontal form-horizontal-left" action="{BASESCRIPT}?mod={MOD_NAME}&op=updatecache&step=2">
|
||||
<form method="post" class="form-horizontal form-horizontal-left" action="{MOD_URL}&op=updatecache&step=2">
|
||||
<input name="formhash" value="{VERHASH}" type="hidden">
|
||||
<p class="clearfix ml20">
|
||||
<label class="checkbox-inline">
|
||||
@ -46,13 +46,13 @@
|
||||
<!--{elseif $step==2}-->
|
||||
<p class="ml20">{lang tools_updatecache_waiting}</p>
|
||||
<p class="text-success ml20">
|
||||
<a href="{BASESCRIPT}?mod=system&op=updatecache&step=3&type=data_tpl" class="lightlink">{lang message_redirect}</a>
|
||||
<a href="{MOD_URL}&op=updatecache&step=3&type=data_tpl" class="lightlink">{lang message_redirect}</a>
|
||||
</p>
|
||||
<script type="text/JavaScript">setTimeout(function(){location.href='{BASESCRIPT}?mod=system&op=updatecache&step=3&type=data_tpl';}, 2000);</script>
|
||||
<script type="text/JavaScript">setTimeout(function(){location.href='{MOD_URL}&op=updatecache&step=3&type=data_tpl';}, 2000);</script>
|
||||
<!--{elseif $step==3}-->
|
||||
<p class="text-success ml20" style="margin:10px;">{lang update_cache_succeed}</p>
|
||||
<script type="text/javascript">
|
||||
window.setTimeout(function() { location.href = '{BASESCRIPT}?mod=system&op=updatecache'; }, 5000);
|
||||
window.setTimeout(function() { location.href = '{MOD_URL}&op=updatecache'; }, 5000);
|
||||
</script>
|
||||
<!--{/if}-->
|
||||
</div>
|
||||
|
@ -56,7 +56,7 @@
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
jQuery('.progress-bar').animate({ width: '100%' }, 3000, function() {
|
||||
window.location.href = '{ADMINSCRIPT}?mod=system&op=systemupgrade&operation=check&checking=1';
|
||||
window.location.href = '{MOD_URL}&op=systemupgrade&operation=check&checking=1';
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
@ -143,7 +143,7 @@
|
||||
<tr>
|
||||
<td class="text-success"> {lang founder_upgrade_normal} <i class="glyphicon glyphicon-ok"></i> $v</td>
|
||||
</tr>
|
||||
<!--{else}-->
|
||||
<!--{elseif isset($newlist[$v])}-->
|
||||
<tr>
|
||||
<td class="text-info"> {lang founder_upgrade_new} <i class="glyphicon glyphicon-plus"></i> $v</td>
|
||||
</tr>
|
||||
|
@ -1249,7 +1249,7 @@ l8I9rb4ZiiEQAUQAEcCySIITuJKyXadxsFEAzKh9zJSm9MUQiAAigAigUZLgHoylbNe2RgLQgb0x
|
||||
BCKACCACaCYAP5vMz+9JAYw3GYCXSQE8bDIAj5ICuIWpJnF+CrcTAahWyt/Qr3aKo5FlEv3Bn7/K
|
||||
QmeGOnBe7TvAPFY3SMKbxGPcrFbKX/6l3BYPT8d1QGvL7wEAjzN1sBVUpBcAAAAASUVORK5CYII=
|
||||
]]></item>
|
||||
<item id="appdesc"><![CDATA[]]></item>
|
||||
<item id="appdesc"><![CDATA[Dzz 日志记录]]></item>
|
||||
<item id="appurl"><![CDATA[{adminscript}?mod=systemlog]]></item>
|
||||
<item id="appadminurl"><![CDATA[{adminscript}?mod=systemlog&op=admin]]></item>
|
||||
<item id="noticeurl"><![CDATA[]]></item>
|
||||
|
@ -18,7 +18,7 @@ $_config = array();
|
||||
* $_config['db']['2']['dbhost'] = 'localhost';
|
||||
* ...
|
||||
*/
|
||||
$_config['db'][1]['dbhost'] = 'localhost';//支持直接加端口如:127.0.0.1:3306或使用UNix socket 如:/tmp/mysql.sock
|
||||
$_config['db'][1]['dbhost'] = 'localhost';//支持三种直接加端口如:127.0.0.1:3306或使用UNix socket 如:/tmp/mysql.sock
|
||||
$_config['db'][1]['dbuser'] = 'root';
|
||||
$_config['db'][1]['dbpw'] = 'root';
|
||||
$_config['db'][1]['dbcharset'] = 'utf8';
|
||||
@ -184,10 +184,10 @@ $_config['security']['querysafe']['afullnote'] = 0;
|
||||
|
||||
$_config['admincp']['founder'] = '1'; // 站点创始人:拥有站点管理后台的最高权限,每个站点可以设置 1名或多名创始人
|
||||
// 可以使用uid,也可以使用用户名;多个创始人之间请使用逗号“,”分开;
|
||||
$_config['admincp']['checkip'] = 1; // 后台管理操作是否验证管理员的 IP, 1=是[安全], 0=否。仅在管理员无法登陆后台时设置 0。
|
||||
$_config['admincp']['runquery'] = 1; // 是否允许后台运行 SQL 语句 1=是 0=否[安全]
|
||||
$_config['admincp']['checkip'] = 1; // 后台管理操作是否验证管理员的 IP, 1=是[安全], 0=否。仅在管理员无法登录后台时设置 0。
|
||||
$_config['admincp']['runquery'] = 0; // 是否允许后台运行 SQL 语句 1=是 0=否[安全]
|
||||
$_config['admincp']['dbimport'] = 0; // 是否允许后台恢复网站数据 1=是 0=否[安全]
|
||||
$_config['userlogin']['checkip'] = 1; //用户登录错误验证ip,对于同一ip同时使用时建议设置为0,否则当有一位用户登录错误次数超过5次,该ip被锁定15分钟,导致其他的同IP用户无法登陆;
|
||||
$_config['userlogin']['checkip'] = 1; //用户登录错误验证ip,对于同一ip同时使用时建议设置为0,否则当有一位用户登录错误次数超过5次,该ip被锁定15分钟,导致其他的同IP用户无法登录;
|
||||
|
||||
//$_config['system_os'] = 'linux'; //windows,linux,mac,系统会自动判断
|
||||
//$_config['system_charset']='utf-8'; //操作系统编码,不设置系统将根据操作系统类型来判断linux:utf-8;windows:gbk;
|
||||
|
@ -11,7 +11,7 @@ define('OSS_ACCESS_KEY', '');
|
||||
define('ALI_LOG', FALSE);
|
||||
|
||||
//自定义日志路径,如果没有设置,则使用系统默认路径,在./logs/
|
||||
//define('ALI_LOG_PATH','');
|
||||
define('ALI_LOG_PATH',DZZ_ROOT.DATA_NAME.BS.'log');
|
||||
|
||||
//是否显示LOG输出
|
||||
define('ALI_DISPLAY_LOG', FALSE);
|
||||
|
@ -10,30 +10,36 @@ global $QINIU_SECRET_KEY;
|
||||
global $HOSTS;
|
||||
$SDK_VER = "6.1.9";
|
||||
$HOSTS=array(
|
||||
'huadong'=>array('title'=>'华东',
|
||||
'z0'=>array('title'=>'华东',
|
||||
'up_http'=>'http://upload.qiniu.com',
|
||||
'up_https'=>'https://up.qbox.me',
|
||||
'io_http'=>'http://iovip.qbox.me',
|
||||
'io_https'=>'https://iovip.qbox.me'
|
||||
)
|
||||
,'huabei'=>array('title'=>'华北',
|
||||
,'z1'=>array('title'=>'华北',
|
||||
'up_http'=>'http://upload-z1.qiniu.com',
|
||||
'up_https'=>'https://up-z1.qbox.me',
|
||||
'io_http'=>'http://iovip-z1.qbox.me',
|
||||
'io_https'=>'https://iovip-z1.qbox.me'
|
||||
)
|
||||
,'huanan'=>array('title'=>'华南',
|
||||
,'z2'=>array('title'=>'华南',
|
||||
'up_http'=>'http://upload-z2.qiniu.com',
|
||||
'up_https'=>'https://up-z2.qbox.me',
|
||||
'io_http'=>'http://iovip-z2.qbox.me',
|
||||
'io_https'=>'https://iovip-z2.qbox.me'
|
||||
)
|
||||
,'beimei'=>array('title'=>'北美',
|
||||
,'na0'=>array('title'=>'北美',
|
||||
'up_http'=>'http://upload-na0.qiniu.com',
|
||||
'up_https'=>'https://up-na0.qbox.me',
|
||||
'io_http'=>'http://iovip-na0.qbox.me',
|
||||
'io_https'=>'https://iovip-na0.qbox.me'
|
||||
)
|
||||
,'as0'=>array('title'=>'东南亚',
|
||||
'up_http'=>'http://up-as0.qiniup.com',
|
||||
'up_https'=>'https://up-as0.qbox.me',
|
||||
'io_http'=>'http://iovip-as0.qbox.me',
|
||||
'io_https'=>'https://iovip-as0.qbox.me'
|
||||
)
|
||||
|
||||
);
|
||||
$QINIU_UP_HOST = 'http://upload.qiniu.com';
|
||||
|
@ -200,23 +200,30 @@ class Wopi
|
||||
$urlsrc=$discovery['actions'][$action][$fileExtension];
|
||||
|
||||
$parts = parse_url($ooServerURL);
|
||||
if ($parts['scheme']=='HTTPS') {
|
||||
if (strtolower($parts['scheme'])=='https') {
|
||||
|
||||
$webSocketProtocol = "wss://";
|
||||
} else {
|
||||
|
||||
$webSocketProtocol = "ws://";
|
||||
}
|
||||
$protocol=$_SERVER['SERVER_PROTOCOL'];
|
||||
$parts = parse_url($ooServerURL);
|
||||
if (strtolower($parts['scheme'])=='https') {
|
||||
$protocol = "https";
|
||||
$webSocketProtocol = "wss://";
|
||||
} else {
|
||||
$protocol = "http";
|
||||
$webSocketProtocol = "ws://";
|
||||
}
|
||||
if (isset($_SERVER['HTTP_HOST'])) {
|
||||
$hostName = $_SERVER['HTTP_HOST'];
|
||||
}
|
||||
|
||||
$webSocket = sprintf("%s%s%s",$webSocketProtocol,$parts['host'],isset($parts['port']) ? ":" . $parts['port'] : "");
|
||||
|
||||
$fileUrl = urlencode($protocol . "://" . $hostName . "/wopi/files/" . $fileID);
|
||||
$fileUrl = urlencode(getglobal('siteurl'). "wopi/files/" . $fileID);
|
||||
$requestUrl = preg_replace("/<.*>/", "", $urlsrc);
|
||||
$requestUrl = $requestUrl . str_replace('{1}', $guid, $wopi_url_temlpate);
|
||||
$requestUrl = str_replace("{0}", $fileUrl, $requestUrl).'&ui=zh-CN&rs=zh-CN';
|
||||
$wopiSrc=$protocol . "://" . $hostName . "/wopi/files/$fileID?access_token=$guid&ui=zh-CN&rs=zh-CN";
|
||||
$wopiSrc=getglobal('siteurl'). "wopi/files/$fileID?access_token=$guid&ui=zh-CN&rs=zh-CN";
|
||||
$ret=array(
|
||||
'fileID'=>$fileID,
|
||||
'protocol'=>$protocol,
|
||||
|
@ -75,37 +75,13 @@ class image {
|
||||
if($dstwidth < 0 || $dstheight < 0) {
|
||||
return $this->returncode(false);
|
||||
}
|
||||
//获取源图相关值
|
||||
$imginfo = @getimagesize($source);
|
||||
|
||||
//原图像大小比列
|
||||
$yratio = $imginfo[0]/$imginfo[1];
|
||||
//目标图片大小比列
|
||||
$oratio = $dstwidth/$dstheight;
|
||||
|
||||
if ($oratio > $yratio) {
|
||||
$new_height = $dstwidth/$yratio;
|
||||
$new_width = $dstwidth;
|
||||
} else {
|
||||
$new_width = $dstheight*$yratio;
|
||||
$new_height = $dstheight;
|
||||
}
|
||||
if(!$srcx){
|
||||
$mid_x = $new_width/2;
|
||||
$srcx = ($mid_x -($dstwidth/2));
|
||||
}
|
||||
if(!$srcy){
|
||||
$mid_y = $new_height/2;
|
||||
$srcy = ($mid_y -($dstheight/2));
|
||||
}
|
||||
$this->param['dstwidth'] = intval($new_width);
|
||||
$this->param['dstheight'] = intval($new_height);
|
||||
$this->param['width'] = intval($dstwidth);
|
||||
$this->param['height'] = intval($dstheight);
|
||||
$this->param['dstwidth'] = intval($dstwidth);
|
||||
$this->param['dstheight'] = intval($dstheight);
|
||||
$this->param['srcx'] = intval($srcx);
|
||||
$this->param['srcy'] = intval($srcy);
|
||||
$this->param['srcwidth'] = intval($imginfo[0]);
|
||||
$this->param['srcheight'] = intval($imginfo[1]);
|
||||
$this->param['srcwidth'] = intval($srcwidth ? $srcwidth : $dstwidth);
|
||||
$this->param['srcheight'] = intval($srcheight ? $srcheight : $dstheight);
|
||||
|
||||
$return = !$this->libmethod ? $this->Cropper_GD() : $this->Cropper_IM();
|
||||
return $this->sleep($return);
|
||||
}
|
||||
@ -420,13 +396,9 @@ class image {
|
||||
return $image;
|
||||
}
|
||||
$newimage = imagecreatetruecolor($this->param['dstwidth'], $this->param['dstheight']);
|
||||
imagecopyresampled($newimage, $image, 0, 0, 0, 0, $this->param['dstwidth'], $this->param['dstheight'], $this->param['srcwidth'], $this->param['srcheight']);
|
||||
$thumb = imagecreatetruecolor($this->param['width'], $this->param['height']);
|
||||
|
||||
imagecopyresampled($thumb, $newimage, 0, 0, $this->param['srcx'], $this->param['srcy'], $this->param['width'], $this->param['height'], $this->param['width'], $this->param['height']);
|
||||
ImageJpeg($thumb, $this->target, 100);
|
||||
imagecopyresampled($newimage, $image, 0, 0, $this->param['srcx'], $this->param['srcy'], $this->param['dstwidth'], $this->param['dstheight'], $this->param['srcwidth'], $this->param['srcheight']);
|
||||
ImageJpeg($newimage, $this->target, 100);
|
||||
imagedestroy($newimage);
|
||||
imagedestroy($thumb);
|
||||
imagedestroy($image);
|
||||
return true;
|
||||
}
|
||||
|
@ -151,7 +151,7 @@ class template {
|
||||
|
||||
$template = preg_replace("/\<\!\-\-\{(.+?)\}\-\-\>/s", "{\\1}", $template);
|
||||
// js的lang替换
|
||||
$template = preg_replace_callback("/<script[^>]+?src=\"(.+?)\".*?>[\s\S]*?/i", array($this, 'parse_template_callback_javascript'), $template);
|
||||
$template = preg_replace_callback("/<script[^>]+?src=\"(.+?)\".*?>[\s\S]*?/is", array($this, 'parse_template_callback_javascript'), $template);
|
||||
// 模版lang替换
|
||||
$template = preg_replace_callback("/\{lang\s+(.+?)\}/is", array($this, 'parse_template_callback_languagevar_1'), $template);
|
||||
// 模版__lang替换
|
||||
@ -202,7 +202,7 @@ class template {
|
||||
}
|
||||
|
||||
function parse_template_callback_javascript($matches) {
|
||||
return $this -> loadjstemplate($matches[1]);
|
||||
return $this -> loadjstemplate($matches);
|
||||
}
|
||||
|
||||
function parse_template_callback_hook($matches){
|
||||
@ -306,7 +306,7 @@ class template {
|
||||
}
|
||||
|
||||
function parse_template_callback_stripscriptamp_12($matches) {
|
||||
return $this -> stripscriptamp($matches[1], $matches[2]);
|
||||
return $this -> stripscriptamp($matches);
|
||||
}
|
||||
|
||||
function parse_template_callback_stripblock_12($matches) {
|
||||
@ -323,7 +323,9 @@ class template {
|
||||
return $jsonencode;
|
||||
}
|
||||
|
||||
function loadjstemplate($parameter) {
|
||||
function loadjstemplate($matches) {
|
||||
global $_G;
|
||||
$parameter = $matches[1];
|
||||
$paramet = trim($parameter,"\0");
|
||||
$parameter = preg_replace_callback('/\{(.+?)\}/i',function($m){
|
||||
$defineds = get_defined_constants();
|
||||
@ -335,7 +337,14 @@ class template {
|
||||
$src = preg_replace('/\?.*/i', '', $src);
|
||||
$jsname = str_replace('.','_',basename($src,'.js'));
|
||||
$content = @file_get_contents($src);
|
||||
if(!$content) return '<script type="text/javascript" src="'.$paramet.'">';
|
||||
$_G['template_paramet_replace_value'] = $paramet;
|
||||
if(!$content){
|
||||
$return = preg_replace_callback("/<script([^>]+?)src=\"(.+?)\"(.*?)>[\s\S]*?/is",function($m){
|
||||
return '<script'.$m[1].'src="'.getglobal('template_paramet_replace_value').'"'.$m[3].'>';
|
||||
},$matches[0]);
|
||||
unset($_G['template_paramet_replace_value']);
|
||||
return $return;
|
||||
}
|
||||
$jslangcontent = array();
|
||||
if(preg_match_all('/__lang\.(\w+)/i',$content,$match)){
|
||||
$jslangcontent[] = 'if(!__lang){var __lang={};}';
|
||||
@ -358,9 +367,18 @@ class template {
|
||||
fwrite($fp, $jscontent);
|
||||
fclose($fp);
|
||||
}
|
||||
return '<script type="text/javascript" src="'.$jscachefile.'"></script><script type="text/javascript" src="'.$paramet.'">';
|
||||
$return = '<script type="text/javascript" src="'.$jscachefile.'"></script>';
|
||||
$return .= preg_replace_callback("/<script([^>]+?)src=\"(.+?)\"(.*?)>[\s\S]*?/is",function($m){
|
||||
return '<script'.$m[1].'src="'.getglobal('template_paramet_replace_value').'"'.$m[3].'>';
|
||||
},$matches[0]);
|
||||
unset($_G['template_paramet_replace_value']);
|
||||
return $return;
|
||||
}
|
||||
return '<script type="text/javascript" src="'.$paramet.'">';
|
||||
$return = preg_replace_callback("/<script([^>]+?)src=\"(.+?)\"(.*?)>[\s\S]*?/is",function($m){
|
||||
return '<script'.$m[1].'src="'.getglobal('template_paramet_replace_value').'"'.$m[3].'>';
|
||||
},$matches[0]);
|
||||
unset($_G['template_paramet_replace_value']);
|
||||
return $return;
|
||||
}
|
||||
// 模版lang替换
|
||||
function languagevar($var) {
|
||||
@ -541,10 +559,16 @@ class template {
|
||||
return $expr . $statement;
|
||||
}
|
||||
|
||||
function stripscriptamp($s, $extra) {
|
||||
$extra = str_replace('\\"', '"', $extra);
|
||||
$s = str_replace('&', '&', $s);
|
||||
return "<script src=\"$s\" type=\"text/javascript\"$extra></script>";
|
||||
function stripscriptamp($matches) {
|
||||
global $_G;
|
||||
$_G['template_extra-replace_val'] = str_replace('\\"', '"', $matches[2]);
|
||||
$_G['template_src_replace_val'] = str_replace('&', '&', $matches[1]);
|
||||
$return = preg_replace_callback("/\<script([^\>]*?)src=\"(.+?)\"(.*?)\>\s*\<\/script\>/is",function($match){
|
||||
return "<script".$match[1]."src=\"".getglobal('template_src_replace_val')."\" ".getglobal('template_extra-replace_val')."></script>";
|
||||
},$matches[0]);
|
||||
unset($_G['template_extra-replace_val']);
|
||||
unset($_G['template_src_replace_val']);
|
||||
return $return;
|
||||
}
|
||||
|
||||
function stripblock($var, $s) {
|
||||
|
@ -433,7 +433,8 @@ class Tpdb {
|
||||
}else{
|
||||
// 查询字段的安全过滤
|
||||
if(!preg_match('/^[A-Z_\|\&\-.a-z0-9\(\)\,]+$/',trim($key))){
|
||||
E(L('_EXPRESS_ERROR_').':'.$key);
|
||||
//E(L('_EXPRESS_ERROR_').':'.$key);
|
||||
echo '表达式错误:'.$key;exit;
|
||||
}
|
||||
// 多条件支持
|
||||
$multi = is_array($val) && isset($val['_multi']);
|
||||
@ -502,7 +503,8 @@ class Tpdb {
|
||||
$data = is_string($val[1])? explode(',',$val[1]):$val[1];
|
||||
$whereStr .= ' ('.$key.' '.strtoupper($val[0]).' '.$this->parseValue($data[0]).' AND '.$this->parseValue($data[1]).' )';
|
||||
}else{
|
||||
E(L('_EXPRESS_ERROR_').':'.$val[0]);
|
||||
//E(L('_EXPRESS_ERROR_').':'.$val[0]);
|
||||
echo '表达式错误:'.$key;exit;
|
||||
}
|
||||
}else {
|
||||
$count = count($val);
|
||||
|
@ -30,7 +30,9 @@ class Tpsqli extends Tpdb{
|
||||
if ( !isset($this->linkID[$linkNum]) ) {
|
||||
if(empty($config)) $config = $this->config;
|
||||
$this->linkID[$linkNum] = new \mysqli($config['hostname'],$config['username'],$config['password'],$config['database'],$config['hostport']?intval($config['hostport']):3306);
|
||||
if (mysqli_connect_errno()) E(mysqli_connect_error());
|
||||
if (mysqli_connect_errno()){
|
||||
echo "数据库连接错误";exit;//E(mysqli_connect_error());
|
||||
}
|
||||
$dbVersion = $this->linkID[$linkNum]->server_version;
|
||||
|
||||
// 设置数据库编码
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user